/*font-family: 'Merriweather', serif;*/
/*font-family: 'PT Sans Caption', sans-serif;*/

.visually-hidden {
    /* Удаляем элемент из потока документа */
    position: absolute;
    /* Временное решение для неверно произносимого, размазанного текста */
    white-space: nowrap;
    /* Устанавливаем минимально возможный размер (некоторые скринридеры игнорируют элементы с нулевой высотой и шириной) */
    width: 1px;
    height: 1px;
    /* Скрываем вылезающий за границы контент */
    overflow: hidden;
    /* Сбрасываем любые свойства, которые могут повлиять на размер элемента */
    border: 0;
    padding: 0;
    /* Вырезаем ту часть контента, которая должна отображаться. */
    /* Устаревшее свойство clip для старых браузеров */
    clip: rect(0 0 0 0);
    /* clip-path для новых браузеров. inset(50%) определяет область вставки, которая позволит контенту исчезнуть.  */
    clip-path: inset(50%);
    /* Похоже, никто до конца не понимает, почему тут margin: -1px. Кроме того, это приводит к проблемам (читай: https://github.com/h5bp/html5-boilerplate/issues/1985). */
    margin: -1px;
}

body {
    font-family: 'PT Sans Caption', sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: black;
    background: white;
    /*для мобильной версии*/
    min-width: 280px;
}


* {
    box-sizing: border-box;
}

.container {
    width: 1140px;
    margin-left: auto;
    margin-right: auto;
    margin-top: 0;
    margin-bottom: 0;
}


/* header */

.primary-header {
    background: #193b60;
    background-image: url("../img/bg/bg-header.jpg");
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    height: 100vh;
    /* для мобильных устройств*/
    min-height: 400px;

    color: white;
    text-align: center;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.primary-header a {
    text-decoration: none;
    color: white;
}

.primary-header-title {
    font-size: 56px;
    line-height: 62px;
    margin-bottom: 30px;
    margin-top: -50px;
    font-family: 'Merriweather', serif;
}

.primary-header-slogan {
    font-size: 28px;
    line-height: 42px;
}

.primary-header-arrow {
    font-size: 26px;
    position: absolute;
    bottom: 20px;
    left: 50%;
}

/* main */

.portfolio {
    margin: 0;
    padding: 0;
}

.portfolio-title {
    font-size: 46px;
    margin-top: 60px;
    margin-bottom: 60px;
    font-family: 'Merriweather', serif;
    text-align: center;
}

.horizontal-list {
    padding: 0;
    margin: 0;
}

.horizontal-list:after {
    clear: both;
    content: "";
    display: table;
}

.sample {
    list-style-type: none;
    width: 360px;
    margin-right: 30px;
    margin-bottom: 60px;
    float: left;
    padding: 0;
}

.sample a {
    text-decoration: none;
    color: black;
}

.sample a:hover {
    color: #0052c2;
}


.sample:nth-child(3n) {
    /*у каждого третьего элемента не будет правого отступа*/
    margin-right: 0px;
}

.sample-name {
    font-size: 24px;
    line-height: normal;
    margin-top: 15px;
    margin-bottom: 10px;
    padding: 0;
}

.sample-description {
    margin: 0;
    padding: 0;
}

/*для мобильной версии*/
.sample-icon {
    width: 360px;
    height: 250px;
    display: block;
}


/* footer */

.primary-footer {
    background: #061634;
    color: #6479a2;
    padding-top: 90px;
    padding-bottom: 190px;
}

.primary-footer p {
    margin-top: 0;
    margin-bottom: 15px;
}

.primary-footer-column {
    list-style-type: none;
    width: 360px;
    margin-right: 30px;
    margin-bottom: 60px;
    float: left;
    padding: 0;
}

.primary-footer-column:nth-child(3n) {
    /*у каждого третьего элемента не будет правого отступа*/
    margin-right: 0px;
}

.primary-footer-name {
    font-size: 28px;
    margin-bottom: 10px;
    line-height: normal;
    font-family: 'Merriweather', serif;
}

.primary-footer-social {
    color: white;
}

.primary-footer-social-icons {
    color: white;
    font-size: 32px;
}

.primary-footer-social-icons a {
    color: white;
    text-decoration: none;
    margin-right: 30px;
    transition: 0.3s ease-out; /*плавное изменение*/
}

.primary-footer-social-icons a:last-child {
    margin-right: 0;
}

.primary-footer-social-icons a:hover {
    color: #ffe400;
}

.primary-footer-button {
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    color: white;
    text-transform: uppercase;
    letter-spacing: 1.6px;

    display: inline-block;
    border-width: 2px;
    border-color: white;
    border-style: solid;
    border-radius: 50px;

    padding-top: 8px;
    padding-bottom: 8px;
    padding-left: 23px;
    padding-right: 23px;

    transition: 0.3s ease-out; /*плавное изменение*/
}

.primary-footer-button:hover {
    color: #6479a2;
    background: white;
}

/* single page */

.portfolio-single-page {
    text-align: center;

    /*центрирование по вертикали не работает. Как?*/
    /*display: flex;*/
    /*flex-direction: column;*/
    /*align-items: center;*/
    /*justify-content: center;*/
}

.portfolio-single-page img {
    max-width: 100%;
    height: auto;
}

.button-back-organica {
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    color: #EF924D;
    text-transform: uppercase;
    letter-spacing: 1.6px;

    display: inline-block;
    border-width: 2px;
    border-color: EF924D;
    border-style: solid;
    border-radius: 50px;

    padding-top: 8px;
    padding-bottom: 8px;
    padding-left: 23px;
    padding-right: 23px;

    transition: 0.3s ease-out; /*плавное изменение*/
}

.button-back-organica:hover {
    color: white;
    background: #EF924D;
}

.button-back-apollo {
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    color: #1c4d76;
    text-transform: uppercase;
    letter-spacing: 1.6px;

    display: inline-block;
    border-width: 2px;
    border-color: 1c4d76;
    border-style: solid;
    border-radius: 50px;

    padding-top: 8px;
    padding-bottom: 8px;
    padding-left: 23px;
    padding-right: 23px;

    transition: 0.3s ease-out; /*плавное изменение*/
}

.button-back-apollo:hover {
    color: white;
    background: #1c4d76;
}

/* media */

@media (max-width: 1160px) {

    .container {
        width: 100%;
    }

    .footer-column, .sample {
        width: 100%;

        margin: 0;
        margin-bottom: 30px;
        padding-left: 15px;
        padding-right: 15px;
        text-align: center;
    }

    .main-header {
        padding-left: 15px;
        padding-right: 15px;
    }

    .header-title {
        font-size: 38px;
        line-height: 48px;
        margin-bottom: 15px;
    }

    .header-slogan {
        font-size: 22px;
        line-height: 38px;
    }

    .portfolio {
        padding-top: 40px;
        padding-bottom: 50px;
    }

    .portfolio-title {
        font-size: 36px;
    }

    .main-footer {
        padding-top: 70px;
        padding-bottom: 60px;
    }
}