/* global styles */
.hidden {
    display: none;
}

body {
    font-family: "Roboto", sans-serif;
    color: #434455;
    background-color: #FFFFFF;
}
ol,
ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
}
h1,
h2,
h3,
h4,
h5,
h6,
p {
    margin: 0;
}
a {
    text-decoration: none;
}
img {
    display: block;
    max-width: 100%;
    height: auto;
}
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    border: 0;
    padding: 0;
    white-space: nowrap;
    clip-path: inset(100%);
    clip: rect(0 0 0 0);
    overflow: hidden;
}
.container {
    max-width: 320px;
    padding: 0 16px;
    margin: 0 auto;
    justify-content: space-between;
}
button {
    cursor: pointer;
}
@media screen and (min-width: 768px) {
    .container {
        max-width: 768px;     
}
}
@media screen and (min-width: 1158px) {
    .container {
        max-width: 1158px;
        padding: 0 15px;
    }
}
.no-scroll { overflow: hidden; 
}
:root {
--color-label: #8e8f99;
--color-checked-bg: #404bbf;
--icon-fill-color: #f4f4fd;
--link-color: #4d5ae5;
--cloud: #f4f4fd;
}

/* header */
.header {
    border-bottom: 1px solid #e7e9fc;
    box-shadow: 0 1px 6px 0 rgba(46, 47, 66, 0.08), 0 1px 1px 0 rgba(46, 47, 66, 0.16), 0 2px 1px 0 rgba(46, 47, 66, 0.08);
}
.header-container {
    display: flex;
    align-items: center;
}
.list-nav, address {
    display: none;
}
.logo {
    font-family: "Raleway", sans-serif;
    font-weight: 700;
    font-size: 18px;
    line-height: 1.17;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #4d5ae5;
}
.logo-name {
    color: #2e2f42;
}
.header-logo {
    padding: 16px 0;
    display: block;
}
.burger-btn {
    padding: 0;
    border: none;
    background-color: transparent;
}
.burger-icon {
    display: block;
    fill: #2f2f37;
}
@media screen and (min-width: 768px) {
    .burger-btn {
        display: none;
    }
    .header-nav {
        display: flex;
        align-items: center;
    }
    .list-nav {
        display: flex;
        align-items: center;
        gap: 40px;
    }
    .header-logo {
        padding: 24px 0;
        margin-right: 120px;
    }
    .link-nav {
        display: block;
        padding: 24px 0;
        font-weight: 500;
        font-size: 16px;
        line-height: 1.5;
        letter-spacing: 0.02em;
        color: #2e2f42;
        transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
    }
    .link-nav::after {
        content: '';
        width: 100%;
        height: 4px;
        position: absolute;
        left: 0;
        bottom: -1px;
        background-color: #404bbf;
        border-radius: 2px;
        opacity: 0;
        transition: opacity 250ms cubic-bezier(0.4, 0, 0.2, 1);
    }
    .link-nav:hover::after,
    .link-nav:focus::after,
    .link-nav.current::after {
        opacity: 1;
    }
    .link-nav:hover,
    .link-nav:focus,
    .link-contacts:hover,
    .link-contacts:focus,
    .link-nav.current {
        color: #404bbf;
    }
    .address {
        font-style: normal;
        display: block;
    }
    .list-contacts {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
    .link-contacts {
        display: block;
        font-size: 12px;
        line-height: 1.17;
        letter-spacing: 0.04em;
        color: #434455;
        transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
    }
}
@media screen and (min-width: 1158px) {
    .header-logo {
        margin-right: 76px;
    }
    .list-contacts {
        flex-direction: row;
        align-items: center;
        gap: 40px;
    }
    .link-contacts {
        padding: 24px 0;
        font-size: 16px;
        line-height: 1.5;
        letter-spacing: 0.02em;
    }
}

/* mobail menu */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #FFFFFF;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 999;
    transition: opacity 250ms cubic-bezier(0.4, 0, 0.2, 1),
                visibility 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.mobile-menu.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.mobile-menu-container {
    position: relative;
    padding: 72px 24px 40px;
    display: flex;
    flex-direction: column;
    height: 100%;
    margin-left: 0;
    overflow: auto;
}
.mobile-menu-close {
    width: 24px;
    height: 24px;
    position: absolute;
    top: 24px;
    right: 24px;
    padding: 0;
    cursor: pointer;
    border-radius: 50%;
    background-color: #e7e9fc;
    border: 1px solid rgba(0, 0, 0, 0.1);
    stroke-width: 1px;
    stroke:#2e2f42;
    fill: #e7e9fc;
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1),
        border 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.mobile-menu-close:hover,
.mobile-menu-close:focus {
    background-color: #404bbf;
    border: none;
}
.mobile-menu-close:hover .button-mobile-close-icon,
.mobile-menu-close:focus .button-mobile-close-icon {
    transition: fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
    fill: #ffffff;
}
.header-nav-mobile {
    margin-bottom: auto;
}
.list-nav-mobile {
    list-style: none;
    padding: 0;
    margin: 0;
}
.item-nav-mobile:not(:last-child) {
    margin-bottom: 40px;
}
.link-nav-mobile {
    display: block;
    font-size: 36px;
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: 0.02em;
    text-decoration: none;
    color: #2e2f42;
    transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.link-contacts-mobile {
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #434455;
    transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.link-nav-mobile.current,
.link-nav-mobile:hover,
.link-nav-mobile:focus, 
.link-contacts-mobile:hover,
.link-contacts-mobile:focus {
    color: #404bbf;
}
.mobile-menu-social {
    display: flex;
    justify-content: center;
    gap: 24px; 
}
.address-mobile-container {
    margin-top: auto;
    padding-top: 20px;
}
.mobile-menu .address-mobile {
    display: block;
    font-style: normal;
}
.mobile-menu .list-contacts {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0 0 32px 0;
    padding: 0;
}
.mobile-menu .link-contacts {
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #434455;
}
.mobile-menu .link-contacts.phone {
    font-weight: 600;
    color: #4d5ae5;
}
.social-icons {
    display: flex;
    gap: 40px;
    list-style: none;
    padding: 0;
    margin: 0;
    margin-top: 48px;
}
.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #4d5ae5;
    border-radius: 50%;
    fill: #fff;
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.social-icon-item a:hover,
.social-icon-item a:focus {
    background-color: #404bbf;
}
@media screen and (min-width: 768px) {
    .mobile-menu {
        display: none;
    }
}

/* section 1 */
.section {
    padding: 60px 16px;
    box-sizing: border-box;
}
.section-title {
    width: 100%;
    min-height: 432px;
    padding: 0;
    margin: 0 auto;
    position: relative; 
    background-image: 
        linear-gradient(rgba(46,47,66,.7), rgba(46,47,66,.7)),
        url("../images/people-office/people-office-mob-min.jpg");
    
    
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
@media (min-resolution: 192dpi), (-webkit-min-device-pixel-ratio: 2) {
.section-title {
    background-image: 
        linear-gradient(rgba(46,47,66,.7), rgba(46,47,66,.7)),
        url("../images/people-office/people-office-mob@2x-min.jpg");
}
}
.container-title {
    width: 100%;
    max-width: 320px;
    min-height: 432px;     
    margin: 0 auto;
    position: relative;    
    text-align: center;
    padding-top: 24px;     
}
.title {
    display: none;
    font-weight: 700;
    font-size: max(28px, 4vw);
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #fff;
    max-width: 90%;
    margin: 0 auto;
}
.button {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 72px;         
    width: 169px;
    height: 56px;
    padding: 16px 32px;
    background-color: #4d5ae5;
    color: #fff;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.04em;
    border: none;
    border-radius: 4px;
    box-shadow: 0 4px 4px rgba(0,0,0,.15);
    cursor: pointer;
    white-space: nowrap;
    transition: background-color 250ms cubic-bezier(.4,0,.2,1);
}
.button:hover,
.button:focus { background-color: #404bbf; }
@media (min-width: 768px) {
.section-title {
    width: 100%;
    min-height: 436px;
    padding: 160px 32px;
    background-image:
    linear-gradient(rgba(46,47,66,.7), rgba(46,47,66,.7)),
    url("../images/people-office/people-office-tab-min.jpg");
}
@media (min-width: 768px) and (min-resolution: 192dpi),
        (min-width: 768px) and (-webkit-min-device-pixel-ratio: 2) {
    .section-title {
    background-image:
        linear-gradient(rgba(46,47,66,.7), rgba(46,47,66,.7)),
        url("../images/people-office/people-office-tab@2x-min.jpg");
    }
}
.container-title {
    max-width: 720px;
    min-height: auto;      
    padding-top: 0;
    display: flex;        
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 36px;
}
.title {
    display: block;
    font-weight: 700;
    font-size: 56px;     
    line-height: 1.08;   
    letter-spacing: 0.02em;
    text-align: center;
    color: #fff;
    max-width: 560px;    
    margin: 0 auto;
    text-wrap: balance;
    word-break: normal;
    overflow-wrap: normal;
}
.button {
    position: static;      
    transform: none;
    width: 160px;
    height: 52px;
    padding: 14px 28px;
    font-size: 15px;
}
}
@media (min-width: 1158px) {
.section-title {
    width: 100%;
    min-height: 600px;
    max-width: none;
    padding: 188px 0;
    background-image:
    linear-gradient(rgba(46,47,66,.7), rgba(46,47,66,.7)),
    url("../images/people-office/people-office-desk-min.jpg");
}
@media (min-width: 1158px) and (min-resolution: 192dpi),
        (min-width: 1158px) and (-webkit-min-device-pixel-ratio: 2) {
    .section-title {
    background-image:
        linear-gradient(rgba(46,47,66,.7), rgba(46,47,66,.7)),
        url("../images/people-office/people-office-desk@2x-min.jpg");
    }
}
.container-title {
    max-width: 1158px;
    gap: 48px;
}
.title {
    font-size: 56px;
    max-width: 496px;
    margin-bottom: 0;
}
.button {
    width: 169px;
    height: 56px;
    padding: 16px 32px;
    font-size: 16px;
}
}

/* section 2 */
.section-benefits {
    padding: 96px 0;
}
.title-benefits {
    font-weight: 700;
    font-size: 36px;
    line-height: 1.11;
    letter-spacing: 0.02em;
    text-align: center;
    color: #2e2f42;
    margin-bottom: 72px;
}
.list-benefits {
    display: flex;
    flex-direction: column; 
    gap: 72px; 
}
.item-benefits {
    width: 100%;
}
.icon-benefits {
display: none;
}
.title-benefits-name {
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 36px;      
    line-height: 1.11;
    letter-spacing: 0.02em;
    text-align: center;
    color: #2e2f42;
}
.text-benefits {
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #434455;
    text-align: left; 
}
@media (min-width: 768px) {
.section-benefits {
    padding: 96px 0;
}
.list-benefits {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 24px;      
    row-gap: 72px;   
}
.item-benefits {
    width: calc((100% - 24px) / 2); 
}
.title-benefits-name {
    text-align: left;
    font-weight: 700;
    font-size: 36px; 
    line-height: 1.11;
}
.text-benefits {
    text-align: left;
}
}
@media (min-width: 1158px) {
.section-benefits {
    padding: 120px 0; 
}
.list-benefits {
    gap: 24px;
    row-gap: 0;
}
.item-benefits {
    width: calc((100% - 72px) / 4);
}
.icon-benefits {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 264px;
    height: 112px;
    padding: 24px 100px;       
    margin-bottom: 8px;
    background: #f4f4fd;
    border: 1px solid #8e8f99;
    border-radius: 4px;
}
.title-benefits-name {
    font-size: 20px;
    line-height: 1.2;
    text-align: left;
}
}

/* section 3 */
.hero {
    padding: 96px 0;               
    background-color: #f4f4fd;
}
.title-hero {
    margin-bottom: 72px;
    font-weight: 700;
    font-size: 36px;               
    line-height: 1.11;
    letter-spacing: 0.02em;
    text-transform: capitalize;
    text-align: center;
    color: #2e2f42;
}
.list-hero {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;                     
    row-gap: 72px;                
    justify-content: center;       
}
.item-hero {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background-color: #ffffff;
    border-radius: 0 0 4px 4px;
    box-shadow:
        0px 1px 6px rgba(46, 47, 66, 0.08),
        0px 1px 1px rgba(46, 47, 66, 0.16),
        0px 2px 1px rgba(46, 47, 66, 0.08);
    overflow: hidden;
}
.item-hero img {
    display: block;
    width: 100%;
    height: auto;
}
.card-hero {
    padding: 32px 16px;           
}
.title-hero-name {
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #2e2f42;
}
.text-hero {
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #434455;
    text-align: center;
}
.social-list {
    display: flex;
    justify-content: center;      
    gap: 24px;                  
    margin-top: 8px;
    width: 100%;
}
.social-item {
    width: 40px;
    height: 40px;
}
.social-link {
    width: 100%;
    height: 100%;
    background-color: #4d5ae5;    
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.social-link:hover,
.social-link:focus {
    background-color: #404bbf;   
}
.social-icon {
    fill: #f4f4fd;
}
@media (min-width: 768px) and (max-width: 1157.98px) {
.hero {
    padding: 96px 0;           
}
.list-hero {
    justify-content: center;  
}
.item-hero {
    width: 246px;
    height: 428px;
}
.card-hero {
    padding: 32px 0;         
    height: calc(100% - 260px); 
    display: flex;
    flex-direction: column;
    justify-content: center;  
    align-items: center;
    box-sizing: border-box;
}
.social-list {
    justify-content: center;
    width: 100%;
}
}
@media (min-width: 1158px) {
.hero {
    padding: 120px 0;           
}
.list-hero {
    row-gap: 0;
    gap: 24px;
    justify-content: center;   
}
.item-hero {
    width: calc((100% - 3 * 24px) / 4); 
    height: auto;                         
}
.card-hero {
    padding: 32px 0;            
}
.social-list {
    justify-content: center;
}
}

/* section 4 */
.portfolio { padding: 96px 0; 
}
.title-portfolio {
    margin-bottom: 72px;
    font-weight: 700;
    font-size: 36px;
    line-height: 1.11;
    letter-spacing: 0.02em;
    text-align: center;
    color: #2e2f42;
}
.list-portfolio {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    row-gap: 48px;
    justify-content: flex-start;
}
.item-portfolio {
    width: 100%;
    background: #fff; 
    transition: box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.card-portfolio {
    position: relative;
    overflow: hidden; 
}
.card-portfolio picture,
.card-portfolio img {
    display: block;
    width: 100%;
    height: auto;
}
.overlay-text {
    position: absolute;
    inset: 0;
    padding: 40px 32px;
    background-color: #4d5ae5;
    color: #f4f4fd;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    transform: translateY(100%);
    transition: transform 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.container-portfolio-name {
    padding: 32px 16px;
    border: 1px solid #e7e9fc;
    border-top: none;
    background: #fff;
}
.title-portfolio-name {
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #2e2f42;
}
.text-portfolio {
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #434455;
}
@media (max-width: 1157.98px) {
.item-portfolio {
    box-shadow: 0 1px 6px rgba(46, 47, 66, 0.08); 
}
}
@media (min-width: 768px) {
.portfolio { padding: 96px 0; }
.item-portfolio { width: calc((100% - 24px) / 2); }
}
@media (min-width: 1158px) {
.portfolio { padding: 120px 0; 
}
.item-portfolio { width: calc((100% - 48px) / 3); 
}
.item-portfolio { box-shadow: none; 
}
.item-portfolio:hover,
.item-portfolio:focus {
    box-shadow:
        0px 2px 1px rgba(46, 47, 66, 0.08),
        0px 1px 1px rgba(46, 47, 66, 0.16),
        0px 1px 6px rgba(46, 47, 66, 0.08);
}
.item-portfolio:hover .overlay-text,
.item-portfolio:focus .overlay-text {
    transform: translateY(0%);
}
}

/* footer */
.footer {
    background-color: #2e2f42;
    padding: 96px 0; 
}
.container-footer-father {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 72px;
}
.container-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 320px;
}
.footer-logo-link {
    font-family: "Raleway", sans-serif;
    font-weight: 700;
    font-size: 18px;
    line-height: 1.17;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #4d5ae5;
    margin-bottom: 16px;
    display: inline-block;
    text-align: center;
}
.footer-logo-name { color: var(--cloud); 
}
.text-footer {
    color: var(--cloud);
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    max-width: 264px;
    text-align: center;
}
.social-footer { color: #fff; text-align: center; }
.social-footer-text {
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #fff;
    margin-bottom: 16px;
}
.social-footer-list {
    display: flex;
    justify-content: center;
    gap: 16px;
}
.social-footer-link {
    width: 40px;
    height: 40px;
    background-color: #4d5ae5; 
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 250ms cubic-bezier(0.4,0,0.2,1);
}
.social-footer-icons { fill: #f4f4fd; transition: fill 250ms cubic-bezier(0.4,0,0.2,1); }
.social-footer-link:hover,
.social-footer-link:focus { background-color: #31d0aa; }
.footer-subscribe { width: 100%; }
.footer-subscribe-title {
    font-weight: 500;
    margin-bottom: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #fff;
    text-align: center;
}
.footer-subscribe-form {
    display: flex;
    flex-wrap: wrap;  
    gap: 16px;
    justify-content: center;
}
.footer-subscribe-label { width: 100%; }
.footer-subscribe-input {
    width: 100%;
    height: 40px;
    padding: 8px 16px;
    border: 1px solid #fff;
    border-radius: 4px;
    box-shadow: 0 4px 4px rgba(0,0,0,0.15);
    background-color: transparent;
    color: #fff;
    font-size: 12px;
    line-height: 2;
    letter-spacing: 0.04em;
}
.footer-subscribe-input::placeholder {
    font-weight: 400;
    font-size: 12px;
    line-height: 2;
    letter-spacing: 0.04em;
    color: #fff;
}
.footer-subscribe-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 165px;
    height: 40px;
    background-color: #4d5ae5;
    color: #fff;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.04em;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 250ms cubic-bezier(0.4,0,0.2,1);
}
.footer-subscribe-btn:hover,
.footer-subscribe-btn:focus { background-color: #31d0aa; }
.footer-subscribe-icon { margin-left: 16px; fill: #fff; }
@media (min-width: 768px) and (max-width: 1157.98px) {
.footer { padding: 96px 0; }
.container-footer-father {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 24px;
    row-gap: 72px;
    align-items: start;
    padding: 0 108px;
}
.container-footer { align-items: flex-start; text-align: left; max-width: none; }
.text-footer { text-align: left; }
.social-footer {
    justify-self: start; 
    text-align: left;
}
.social-footer-list {
    justify-content: flex-start;  
}
.footer-subscribe {
    grid-column: 1 / -1;
    width: 100%;
}
.footer-subscribe-title { text-align: left; }
.footer-subscribe-form {
    display: grid;
    grid-template-columns: 264px 165px; 
    gap: 24px;
    justify-content: start;
}
.footer-subscribe-label { width: auto; }
.footer-subscribe-input {
    width: 264px;
    height: 40px;
}
}
@media (min-width: 1158px) {
.footer { padding: 100px 0; }
.container-footer-father {
    display: flex;
    flex-direction: row;
    align-items: baseline;
    gap: 0;
    padding: 0;
}
.container-footer {
    width: 264px;
    margin-right: 120px;
    align-items: flex-start;
}
.social-footer { margin-right: 80px; }
.footer-subscribe {
    margin-left: auto;
    width: auto;
}
.footer-subscribe-title { text-align: left; }
.footer-subscribe-form {
    display: flex;
    flex-wrap: nowrap;
    gap: 24px;
    justify-content: flex-start;
}
.footer-subscribe-input {
    width: 264px;
    height: 40px;
}
}

/* modal window */
.backdrop {
    position: fixed;
    inset: 0;
    background-color: rgba(46, 47, 66, 0.4);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition:
        opacity 250ms cubic-bezier(0.4, 0, 0.2, 1),
        visibility 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.backdrop.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.modal {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 288px; /* mobile width */
    min-height: auto;
    padding: 72px 16px 24px;
    transform: translate(-50%, -50%);
    box-shadow:
    0 1px 1px rgba(0, 0, 0, 0.14),
    0 1px 3px rgba(0, 0, 0, 0.12),
    0 2px 1px rgba(0, 0, 0, 0.2);
    background-color: #fcfcfc;
    border-radius: 4px;
    transition: transform 250ms cubic-bezier(0.4, 0, 0.2, 1);
    box-sizing: border-box;
}
.backdrop:not(.is-open) .modal {
    transform: translate(-50%, -100%) scale(1);
}
.button-modal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    cursor: pointer;
    border-radius: 50%;
    background-color: #e7e9fc;
    border: 1px solid rgba(0, 0, 0, 0.1);
    stroke-width: 1px;
    fill: #2e2f42;
    transition:
        background-color 250ms cubic-bezier(0.4, 0, 0.2, 1),
        border 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.button-modal-close:hover,
.button-modal-close:focus {
    background-color: #404bbf;
    border: none;
    fill: #ffffff;
}
.button-modal-close-icon {
    transition: fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.modal-text {
    width: 100%;
    margin: 0 auto 16px;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    text-align: center;
    color: #2e2f42;
}
.modal-wrapper {
    margin-bottom: 8px;
}
.modal-wrapper-comment {
    margin-bottom: 16px;
}
.modal-form {
    display: block;
    margin-bottom: 4px;
    font-weight: 400;
    font-size: 12px;
    line-height: 1.17;
    letter-spacing: 0.04em;
    color: var(--color-label);
}
.modal-form-field,
.modal-form-textarea {
    width: 100%;
    height: 40px;
    border: 1px solid rgba(46, 47, 66, 0.4);
    border-radius: 4px;
    padding-left: 38px; 
    padding-right: 16px;
    outline: transparent;
    background-color: transparent;
    transition: border-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 12px;
    line-height: 1.17;
    letter-spacing: 0.04em;
    box-sizing: border-box;
}
.modal-form-textarea {
    height: 120px;
    padding: 8px 16px;
    resize: none;
    color: rgba(46, 47, 66, 0.8);
    display: block;
    margin: 0 auto 24px;
}
.modal-form-field:focus,
.modal-form-textarea:focus {
    border-color: #4d5ae5;
    box-shadow: 0 0 0 4px rgba(77, 90, 229, 0.2);
}
.modal-wrapper-icons {
    position: relative;
}
.modal-wrapper-icons svg {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    fill: #2e2f42;
    transition: fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.modal-form-field:hover + svg,
.modal-form-field:focus + svg {
    fill: #4d5ae5;
}
.modal-wrapper-checkbox {
    margin-bottom: 24px;
}
.modal-form-checkbox {
    display: inline-flex;
    flex-wrap: wrap;         
    align-items: baseline;   
    white-space: normal;
    font-size: 12px;
    line-height: 1.17;
    letter-spacing: 0.04em;
    color: var(--color-label);
}
.modal-form-checkbox .form-custom-checkbox {
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 8px;  
    fill: transparent;
    border-radius: 2px;
    border: 1px solid rgba(46, 47, 66, 0.4);
    transition:
    background-color 250ms cubic-bezier(0.4, 0, 0.2, 1),
    border 250ms cubic-bezier(0.4, 0, 0.2, 1),
    fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
#user-privacy:checked + .modal-form-checkbox > .form-custom-checkbox {
    fill: var(--icon-fill-color);
    background-color: var(--color-checked-bg);
    border: none;
    border-radius: 2px;
}
.privacy-policy-link {
    white-space: nowrap; 
    color: var(--link-color);
    line-height: 1.3;
    text-decoration: underline;
    text-decoration-skip-ink: none;
}
.button-modal {
    display: block;
    margin: 0 auto;
    width: 169px;
    height: 56px;
    padding: 16px 32px;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: 0.04em;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.modal .button,
.modal .button-modal {
    position: static;
    transform: none;
}
@media (min-width: 768px) {
.modal {
    width: 408px;
    min-height: 584px;
    padding: 72px 24px 24px;
}
}
@media (min-width: 1158px) {
.modal {
    width: 408px;
}
}

@media (max-width: 767.99px) {
.modal-form-checkbox {
    display: inline-block;        
    position: relative;           
    padding: 7.5px 0;             
    padding-left: 24px;           
    line-height: 1.33;
    white-space: normal;          
}
.modal-form-checkbox .form-custom-checkbox {
    position: absolute;
    left: 0;                     
    top: 50%;
    transform: translateY(-50%);  
    margin-right: 0;              
    width: 16px;
    height: 16px;
}
.modal-form-checkbox .privacy-policy-link {
    white-space: nowrap;
}
}