/* Задаем базовые стили */

body {
    margin: 0;
    padding: 0;

    font-family: "Roboto", Arial, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 24px;
    color:#000000;

    background-color: #ffffff;
}

a {
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

.visually-hidden,
input[type="checkbox"].visually-hidden,
input[type="radio"].visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    border: 0;
    padding: 0;
    clip: rect(0 0 0 0);
    overflow: hidden;
}

.container {
    box-sizing: border-box;
    width: 1200px;

    margin: 0 auto;
    padding: 0 20px;
}

/* Button Design */

.button-red,
.button-green,
.button-yellow,
.button-gray {
    display: inline-block;
    padding: 16px 0;
    font-size: 16px;
    line-height: 18px;
    text-align: center;
    text-transform: uppercase;
    color: #ffffff;
    border-radius: 2px;
}

.slider-button {
    width: 240px;
}

.features-button {
    width: 160px;
}

.map-button {
    margin-top: 34px;
    width: 219px;
    border: none;
    border-radius: 2px;
}

.filter-button {
    margin-top: 1px;
    margin-bottom: 20px;
    width: 260px;
    border: none;
    border-radius: 2px;
}

.button-email {
    width: 260px;
    border: none;
    border-radius: 2px;
}

.map-button:active,
.filter-button:active,
.button-email:active {
    outline: none;
}

.button-red:active,
.button-green:active,
.button-yellow:active,
.button-red-email:active {
    color: rgba(255, 255, 255, 0.3);
}

.button-red {
    background-color: #fb565a;
}

.button-red:hover {
    background-color: #e74246;
}

.button-red:active {
    background-color: #d7373b;
    box-shadow: inset 0 3px 0 rgba(0, 1, 1, 0.1);
}

.button-green {
    background-color: #00ca74;
}

.button-green:hover {
    background-color: #00bc6c;
}

.button-green:active {
    background-color: #00aa62;
    box-shadow: inset 0 3px 0 rgba(0, 1, 1, 0.1);
}

.button-yellow {
    background-color: #efc84a;
}

.button-yellow:hover {
    background-color: #eab534;
}

.button-yellow:active {
    background-color: #e5a722;
    box-shadow: inset 0 3px 0 rgba(0, 1, 1, 0.1);
}

.button-gray {
    background-color: #eeeeee;
    color: #000000;
    font-weight: 500;
}

.button-gray:hover {
    background-color: #dfdfdf;
}

.button-gray:active {
    color: #959595;
    background-color: #dfdfdf;
    box-shadow: inset 0 3px 0 rgba(0, 1, 1, 0.1);
}


/* ----- Размечаем шапку ----- */

.page-top-wrapper {
    background-color: #eeeeee;
}

.main-header {
    padding-top: 49px;
}

.main-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;

    font-size: 16px;
    line-height: 30px;
    font-weight: 500;
    color: #000000;
    text-transform: uppercase;
}

.main-header-logo {
    margin: 0;
    padding: 0;

    width: 160px;
    height: 65px;
}

.main-header-logo:hover {
    opacity: 0.8;
}

.main-header-logo:active {
    opacity: 0.3;
}

.navigation-wrapper {
    width: 798px;
    display: flex;
    justify-content: space-between;
}

.site-navigation {
    margin: 0;
    margin-top: 17px;
    padding: 0;

    display: flex;
    justify-content: space-between;
    list-style: none;

}

.site-navigation li {
    margin-right: 46px;
}

.site-navigation-current {
    position: relative;
}

.site-navigation-current::after {
    content: "";

    position: absolute;
    top: 28px;
    left: 0;

    width: 100%;
    height: 2px;
    background-color: #fb565a;
}

.cart {
    position: relative;

    margin: 0;
    margin-top: 17px;
    padding: 0;

    list-style: none;
}

.cart a {
    padding-left: 40px;
}

.cart a::before {
    position: absolute;
    top: 7px;
    left: 0;

    width: 15px;
    height: 15px;

    background: url("../img/cart-icon.svg") no-repeat;
    content: "";
    opacity: 0.3;
}

.site-navigation a,
.cart a {
    color: #000000;
}

.site-navigation a:hover,
.cart a:hover {
    color: #fb565a;
}

.site-navigation a:active,
.cart a:active {
    color: rgba(0, 0, 0, 0.3);
}



.site-navigation-current a{
    border-bottom: 2px solid #fb565a;
}

/* Размечаем главный слайдер */

.main-slider {
    margin-bottom: 80px;

    position: relative;

    background-color: #eeeeee;
}

.main-slider input[type="radio"] {
    display: none;
}

.slider-controls {
    position: absolute;
    bottom: 96px;
    left: 50%;

    margin-left: -44px;

    display: flex;
    justify-content: space-between;

    width: 88px;
}

.slider-controls label {
    position: relative;
    display: inline-block;

    width: 18px;
    height: 18px;

    border-radius: 50%;
    background-color: #ffffff;

    cursor: pointer;
}

.slider-controls label::after {
    position: absolute;
    top: 5px;
    left: 5px;
    content: "";
    width: 4px;
    height: 4px;
    border-radius: 50%;
    border: 2px solid #c2c2c2;
    display: none;
}

.slides {

}

.slides p {
    margin: 0;
    padding: 0;
}

.slide {
    display: none;
}

.slide:nth-child(1) {
    background-image: url("../img/slide1.png");
    background-repeat: no-repeat;
    background-position: 431px 18px;
}

.slide:nth-child(2) {
    background-image: url("../img/slide2.png");
    background-repeat: no-repeat;
    background-position: right;
}

.slide:nth-child(3) {
    background-image: url("../img/slide3.png");
    background-repeat: no-repeat;
    background-position-x: right;
    background-position-y: 20px;
}

.slide .slide-title {
    padding: 0;
    margin: 0;
    padding-top: 78px;
    font-size: 55px;
    font-weight: 500;
    line-height: 55px;

}

.slide .slide-text {
    padding-top: 26px;
    color: #283136;
}

.slide a {
    margin-top: 39px;
    margin-bottom: 80px;
}

#btn-1:checked ~ .slides .slide:nth-child(1),
#btn-2:checked ~ .slides .slide:nth-child(2),
#btn-3:checked ~ .slides .slide:nth-child(3) {
    display: block;
}

#btn-1:checked ~ .slider-controls  label[for="btn-1"]::after,
#btn-2:checked ~ .slider-controls  label[for="btn-2"]::after,
#btn-3:checked ~ .slider-controls  label[for="btn-3"]::after {
    display: block;
}


/* Размечаем основной контент сраницы */

.features {
    margin: 0;
    padding: 0;

    border-bottom: 2px solid #eeeeee;
}

.features-list {
    display: flex;
    margin: 0;
    margin-bottom: 80px;
    padding: 0;

    list-style: none;
}

.feature-item {
    margin: 0;
    margin-right: 100px;
    padding: 0;
    width: 300px;
}

.feature-item:last-child {
    margin-right: 0;
}

.feature-item img {
    margin: 0;
    padding: 0;

    width: 300px;
    height: 146px;
}

.feature-item h2 {
    margin: 0;
    padding: 0;
    padding-top: 18px;

    font-size: 24px;
    line-height: 30px;
    font-weight: bold;
    text-transform: uppercase;
}
.feature-item p {
    margin: 0;
    padding: 0;
    padding-top: 16px;

    max-width: 260px;

    color: #283136;
}

.feature-item a {
    margin-top: 32px;
}

/* ----- Блок "О студии" ----- */

.about-us {
    margin: 0;
    margin-top: 40px;
    padding: 0;
    padding-bottom: 73px;

    display: flex;
    justify-content: space-between;
}

.studio-info {
    margin: 0;
    padding: 0;
    width: 700px;
}

.studio-info h2 {
    margin: 0;
    padding: 0;
    padding-top: 34px;
    font-size: 45px;
    font-weight: 500;
    line-height: 45px;
}

.studio-info p {
    margin: 0;
    padding: 0;
    padding-top: 33px;
    padding-bottom: 39px;

    max-width: 660px;

    color: #283136;
}

.about-us span {
    margin: 0;
    font-weight: 700;
    text-transform: uppercase;
}

.studio-info ul {
    margin: 0;
    padding: 0;
    padding-top: 24px;

    list-style: none;
    color: #283136;
}

.studio-info li {
    position: relative;

    padding-left: 36px;
    padding-bottom: 24px;
}

.studio-info li:last-child {
    padding-bottom: 0;
}

.studio-info li:before {
    content: "";
    position: absolute;
    top: 6px;
    left: 1px;

    width: 25px;
    height: 24px;

    background: linear-gradient(to bottom,  transparent 5px, #fb565a 5px, #fb565a 7px, transparent 7px);
}

.studio-stats {
    width: 360px;
}
.studio-stats .logo-wrapper {
    margin-bottom: 29px;
}

.studio-stats span {
    padding-left: 17px;
}

.studio-efficiency {
    display: flex;
    justify-content: flex-start;

    margin: 0;
    margin-top: 58px;
    padding: 0;

    list-style: none;
}

.studio-efficiency li {
    margin: 0;
    padding: 0;
    padding-right: 22px;
}
.studio-efficiency li:last-child {
    padding-right: 0;
}

.studio-efficiency span {
    padding-left: 0;
    font-size: 45px;
    font-weight: 700;
    line-height: 10px;
}

.studio-efficiency sup {
    font-size: 28px;
}

.studio-efficiency p {
    margin: 0;
    padding: 0;
    padding-top: 19px;
    font-size: 16px;
    line-height: 18px;
}

/* ----- Блок партнёров ----- */

.partners {
    margin-bottom: 80px;

    border-top: 2px solid #eeeeee;
    border-bottom: 2px solid #eeeeee;

    background-image: linear-gradient(to right, transparent 279px, #eeeeee 279px, #eeeeee 281px, transparent 281px, transparent 579px, #eeeeee 579px, #eeeeee 581px, transparent 581px, transparent 879px, #eeeeee 879px, #eeeeee 881px, transparent 881px);
    background-repeat: no-repeat;
    background-size: 100% 52px;
    background-position-y: 50%;
}

.partners-list {
    position: relative;

    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: flex-start;

    padding: 0;
    margin: 0;

    list-style: none;

    box-sizing: border-box;
    min-height: 180px;

}

.partners-list li {
    opacity: 0.2;
}

.partners-list li:hover {
    opacity: 1;
}

.partners-list li:active {
    opacity: 0.1;
}

.partners-list li:nth-child(1) {
    padding-top: 62px;
    padding-left: 31px;
}

.partners-list li:nth-child(2) {
    padding-top: 46px;
    padding-left: 96px;
}

.partners-list li:nth-child(3) {
    padding-top: 65px;
    padding-left: 103px;
}

.partners-list li:nth-child(4) {
    padding-top: 52px;
    padding-left: 121px;
}

/* Размечаем футтер */

.main-footer {

}

.main-footer-top {
    position: relative;

    width: 1440px;
    height: 416px;
    margin: 0 auto;
}

.main-footer-top img {
    position: absolute;
    top: 0;
    left: 0;
}

.main-footer-top iframe {
    position: relative;
}

.our-address {
    position: absolute;
    top: 54px;
    left: 140px;

    box-sizing: border-box;
    padding-top: 49px;
    padding-bottom: 47px;
    padding-left: 50px;

    width: 319px;
    z-index: 1;

    background-color: #ffffff;
}

.our-address h3 {
    margin: 0;
    padding: 0;
    padding-bottom: 23px;

    font-size: 18px;
    line-height: 30px;
}

.our-address p {
    margin: 0;
    padding: 0;
    padding-bottom: 15px;

    font-size: 16px;
    line-height: 18px;
    color: #666666;
}

.tel {
    margin: 0;
    padding: 0;
    color: #666666;
}

.main-footer-bottom {
    display: flex;
    justify-content: flex-start;

    margin-top: 69px;
    padding-bottom: 70px;
}

.social {

}

.social-list {
    display: flex;
    justify-content: space-between;

    margin: 0;
    margin-right: 140px;
    padding: 0;

    min-width: 260px;
    list-style: none;
}

.social-list li {
    margin: 0;
    padding: 0;
}

.social-button {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 78px;
    height: 78px;

    background-color: #e1e1e1;
    border-radius: 50%;
}

.social-button:hover {
    background-color: #e74246;
}

.social-button:active {
    background-color: #d7373b;
    box-shadow: inset 0 3px 0 0 #c13135;
}

.social-button:active svg {
    opacity: 0.3;
}

.social-offer {
    margin-top: 6px;
}

.social-offer strong {
    padding: 0;
    margin: 0;

    font-size: 36px;
    font-weight: 700;
    line-height: 36px;
}

.social-offer p {
    padding: 0;
    padding-top: 9px;
    margin: 0;

    font-size: 16px;
    line-height: 22px;
    color: #444444;
}
/* ----- Разметка внутренних странниц ----- */
/* ---- Разметка страницы каталога ---- */

.catalog-header {
    padding-top: 78px;
    padding-bottom: 108px;
    margin-bottom: 58px;
}

.catalog-header h1 {
    margin: 0;
    padding: 0;

    font-size: 55px;
    font-weight: 500;
    line-height: 55px;
    text-align: center;
}

/* --- Разметка фильтра товаров --- */

.catalog-wrapper {
    display: flex;
    justify-content: space-between;
    padding: 0;
    margin: 0;
}

.catalog-wrapper aside {
    width: 260px;
}

.filter-item {
    margin: 0;
    padding: 0;

    border: none;
}

.filter-item legend {
    font-size: 18px;
    line-height: 24px;
    text-transform: uppercase;
    font-weight: 700;
}

.filter-range {
    width: 260px;
    margin-top: 51px;
    margin-bottom: 57px;
}

.range-controls {
    position: relative;
    height: 41px;
    margin-bottom: 14px;
    padding-top: 39px;
    padding-right: 20px;
    padding-left: 20px;

    background-color: #f1f1f1;

    border-radius: 2px;
}

.range-controls .scale {
    height: 2px;

    background: #d7dcde;
}

.range-controls .bar {
    width: 70%;
    height: 2px;

    background: #00ca74;
}

.range-controls .toggle {
    position: absolute;
    top: 30px;
    left: 0;

    width: 4px;
    height: 4px;
    padding: 0;

    border: 8px solid #ffffff;
    background-color: #ababab;
    box-shadow: 0 3px 1px 0 #cfcfcf;
    border-radius: 50%;
    cursor: pointer;
}

.range-controls .toggle-min {
    left: 18px;
}

.range-controls .toggle-max {
    left: 160px;
}

.price-controls {
    display: flex;
    justify-content: space-between;
}

.price-controls label {
    font-size: 16px;
    line-height: 22px;
    color: #283136;
    text-transform: uppercase;
}

.price-controls input {
    box-sizing: border-box;
    padding-top: 10px;
    padding-bottom: 10px;
    margin-left: 12px;

    width: 80px;

    font-family: Roboto, Arial, sans-serif;
    font-size: 16px;
    text-align: center;
    color: #283136;

    border: none;
    border-radius: 2px;
    background: #f1f1f1;
}

.max-price {
    text-align: right;
}

.filter-item ul {
    margin: 0;
    margin-top: 19px;
    margin-bottom: 48px;
    padding: 0;
    list-style: none;
}

.filter-item li {
    margin: 0;
    margin-bottom: 20px;
    padding: 0;
    padding-left: 36px;

    font-size: 16px;
    line-height: 20px;
    color: #283136;
}

.filter-input-radio + label,
.filter-input-checkbox + label {
    position: relative;
    cursor: pointer;
    user-select: none;
}

.filter-input-radio + label:hover,
.filter-input-checkbox + label:hover {
    position: relative;
    color: #000000;
}

.filter-input-radio:disabled + label,
.filter-input-checkbox:disabled + label {
    position: relative;
    opacity: 0.3;
}

.filter-input-radio + label::before {
    content: "";
    position: absolute;
    top: -3px;
    left: -35px;

    width: 25px;
    height: 25px;

    background-image: url("../img/radio-off.svg");
    background-repeat: no-repeat;
    opacity: 0.4;
}

.filter-input-radio:checked + label::before {
    display: none;
}

.filter-input-radio:checked + label::after {
    content: "";
    position: absolute;
    top: -3px;
    left: -35px;

    width: 25px;
    height: 25px;

    background-image: url("../img/radio-on.svg");
    background-repeat: no-repeat;
    opacity: 0.4;
}

.filter-input-checkbox + label::before {
    content: "";
    position: absolute;

    top: -2px;
    left: -35px;

    width: 23px;
    height: 23px;
    background-image: url("../img/checkbox-off.svg");
    background-repeat: no-repeat;
    opacity: 0.4;
}

.filter-input-checkbox:checked + label::before {
    display: none;
}

.filter-input-checkbox:checked + label::after {
    content: "";
    position: absolute;

    top: -2px;
    left: -35px;

    width: 27px;
    height: 23px;
    background-image: url("../img/checkbox-on.svg");
    background-repeat: no-repeat;
    opacity: 0.4;
}

.filter-input-radio + label:hover::before,
.filter-input-checkbox + label:hover::before,
.filter-input-radio + label:hover::after,
.filter-input-checkbox + label:hover::after{
    opacity: 1;
}

.filter-input-radio + label:disabled::before,
.filter-input-checkbox + label:disabled::before,
.filter-input-radio + label:disabled::after,
.filter-input-checkbox + label:disabled::after{
    opacity: 0.1;
}

.catalog {
    width: 760px;
}

.sort-by {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.sort-by p {
    margin: 0;
    margin-right: auto;

    font-size: 18px;
    line-height: 18px;
    text-transform: uppercase;
    font-weight: 700;
}

.sort-by-type,
.sort-by-direction {
    display: flex;
    margin: 0;
    padding: 0;

    list-style: none;
}

.sort-by li {
    margin: 0;
    padding: 0;
}


.sort-by a {
    display: block;


    font-size: 14px;
    line-height: 18px;
    text-transform: uppercase;
    color: #000000;
}

.sort-by-type {
    justify-content: flex-end;
    margin-right: 47px;
}

.sort-by-type li {
    padding-left: 25px;
}

.sort-by-type a {
    opacity: 0.3;
}

.sort-by-type a:hover {
    opacity: 0.6;
}

.sort-by-direction {
    margin: 0 1px;
}

.sort-by-direction li:first-child {
    margin-right: 18px;
}

.sort-by-direction a {
    opacity: 0.2;
}

.sort-by-direction a:hover {
    opacity: 0.5;
}

.sort-by-active a,
.sort-by-type a:active,
.sort-by-direction a:active{
    opacity: 1;
}

.catalog-items {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;

    padding: 0;
    margin: 0;
    margin-top: 57px;

    list-style: none;
}

.catalog-item  {
    position: relative;
    margin: 0;
    margin-bottom: 33px;
    padding: 0;

    width: 360;
    height: 616px;

    border-radius: 3px;
}

.catalog-item::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 360px;
    height: 40px;
    background-image: url("../img/browser.svg");
    background-repeat: no-repeat;
    opacity: 0.12;
}

.catalog-item:hover::before {
    opacity: 1;
}

.catalog-item img {
    box-sizing: border-box;
    margin: 0;
    margin-top: 40px;
    padding: 0;

    width: 360px;
    height: 576px;
}

.catalog-item-popup {
    display: none;
    position: absolute;
    bottom: 0;
    left: 0;

    margin: 0;
    padding-top: 28px;
    padding-bottom: 43px;
    padding-left: 80px;
    padding-right: 80px;

    text-align: center;

    background-color: #eeeeee;
}

.catalog-item-popup a {
    font-size: 18px;
    font-weight: 700;
    line-height: 30px;

    color: #000000;
    text-transform: uppercase;
}

.catalog-item-popup p {
    margin: 0;
    margin-top: 15px;

    font-size: 16px;
    line-height: 18px;
    color: #666666;
}

.catalog-item-popup .catalog-button {
    margin-top: 30px;
    padding: 16px 0;
    width: 100%;
    font-size: 16px;
    line-height: 18px;
    font-weight: 500;
    color: #ffffff;
}
.catalog-item:hover {

}

.catalog-item:hover .catalog-item-popup {
    display: block;

}

.pagination-list {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    margin: 0;
    margin-top: 27px;
    margin-bottom: 60px;
    padding: 0;

    list-style: none;
}

.pagination-item {
    margin: 0;
    margin-right: 11px;
    padding: 0;
}

.pagination-item a {
    display: block;
    padding: 16px 21px;

    font-size: 16px;
    font-weight: 500;
    line-height: 18px;
    color: #000000;
    text-transform: uppercase;

    border-radius: 2px;
    background-color: #eeeeee;
}

.pagination-item-active a {
    box-shadow: inset 0 0 0 3px #dbdbdb;
    background-color: #ffffff;
}

.pagination-item-next a{
    padding-left: 79px;
    padding-right: 79px;
}
/* ----- Модальное окно ----- */

.modal-email-us {
    display: none;
    position: fixed;
    bottom: 180px;
    left: 50%;

    margin: 0;
    margin-left: -480px;
    padding: 0;
    padding-bottom: 84px;
    padding-left: 100px;
    padding-right: 100px;


    background-color: #ffffff;
    box-shadow: 0 20px 40px rgba(0, 1, 1, 0.75);

    z-index: 1;
}

.modal-email-us-wrapper {
    width: 760px;
}

.modal-email-us h2 {
    margin: 0;
    margin-top: 67px;
    margin-bottom: 41px;
    padding: 0;

    font-size: 45px;
    font-weight: 500;
    line-height: 45px;
}

.name-email-wrapper {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-bottom: 34px;
}

.email-us-form p {
    display: flex;
    flex-direction: column;
    margin: 0;
}

.email-us-form label {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    line-height: 18px;
}

.email-us-form input,
.email-us-form textarea {
    box-sizing: border-box;
    font: inherit;
    margin-top: 9px;
    color: #444444;
    border: 2px solid #d7dcde;
    border-radius: 2px;
}

.email-us-form input {
    width: 360px;
    padding-left: 13px;
    padding-top: 11px;
    padding-bottom: 11px;
}

.email-us-form textarea {
    padding-top: 8px;
    padding-bottom: 10px;
    padding-left: 13px;
}

.email-us-form .button-email {
    margin-top: 47px;
}

.modal-close {
    position: absolute;
    right: 89px;
    top: 78px;
    width: 22px;
    height: 22px;
    font-size: 0;
    border: none;
    background-color: #ffffff;
}

.modal-close::before {
    content: "";
    position: absolute;
    top: 9px;
    right: -2px;
    width: 27px;
    height: 4px;
    background-color: #fb565a;
    opacity: 0.3;
    transform: rotate(45deg);
}

.modal-close::after {
    content: "";
    position: absolute;
    top: 9px;
    right: -2px;
    width: 27px;
    height: 4px;
    background-color: #fb565a;
    opacity: 0.3;
    transform: rotate(-45deg);
}

.modal-close:hover::before,
.modal-close:hover::after {
    opacity: 1;
}

.modal-close:active::before,
.modal-close:active::after {
    opacity: 0.1;
}

.modal-show {
    animation-name: bounce;
    animation-duration: 0.6s;

    display: block;
}

.modal-error {
    animation-name: shake;
    animation-duration: 0.6s;
}

@keyframes bounce {
    0% {
        transform: translateY(-2000px);
    }
    70% {
        transform: translateY(30px);
    }
    90% {
        transform: translateY(-10px);
    }
    100% {
        transform: translateY(0);
    }
}

@keyframes shake {
    0%,
    100% {
        transform: translateX(0);
    }

    10%,
    30%,
    50%,
    70%,
    90% {
        transform: translateX(-10px);
    }

    20%,
    40%,
    60%,
    80% {
        transform: translateX(10px);
    }
}