body {
    font-family: 'Roboto', sans-serif;
    color: #434455;
    background-color: #FFFFFF;
    margin: 0;
}

h1,
h4,
h5,
h6{
margin-top: 0;
margin-bottom: 0;
}

h2 {
    font-weight: 700;
    font-size: 36px;
    line-height: 1.11;
    letter-spacing: 0.02em;
    color: #2E2F42;
    text-align: center;
    margin-top: 0;
    margin-bottom: 0;
}

h3 {
    font-weight: 500;
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #2E2F42;
    margin-top: 0;
    margin-bottom: 0;
}

p {
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #434455;
    margin-top: 0;
    margin-bottom: 0;
}

ul {
    list-style-type: none;
    margin-top: 0;
    margin-bottom: 0;
    padding-left: 0;
}

img {
    display: block;
}

.section {
    padding-top: 120px;
    padding-bottom: 120px;
}
.container {
   max-width: 1158px;
   width: 100%;
    padding: 0 15px;
    display: flex;
    margin: 0 auto;
}

.page-header {
    border-bottom: 1px solid #E7E9FC;
    box-shadow: 0 2px 1px 0 rgba(46, 47, 66, 0.08), 0 1px 1px 0 rgba(46, 47, 66, 0.16), 0 1px 6px 0 rgba(46, 47, 66, 0.08);
width: 100%;
}


.page-header .container { 
justify-content: space-between;
}

.page-nav {
    display: flex;
    gap: 76px;
}

.nav-list {
display: flex;
gap: 40px;
}

.logo-link {
    font-family: Raleway, sans-serif;
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
    color: #2E2F42;
    text-transform: uppercase;
    line-height: 1.17;
    letter-spacing: 0.03em;
    display: flex;
        align-items: flex-start;
        padding-top: 24px;
        padding-bottom: 24px;
}

.logo-accent {
    color: #4D5AE5;
}

.nav-link {
    display: block;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #2E2F42;
    text-decoration: none; 
    padding-top: 24px;
        padding-bottom: 24px;
    position: relative;
    transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-link:focus,
.nav-link:hover {
    color: #404BBF;
   
}

/* .nav-link:focus::after,
.nav-link:hover::after {
    content: "";
    width: 100%;
    height: 4px;
    background-color: #404BBF;
    display: block;
    margin-top: 20px;
} */

.nav-link.current {
    color: #404BBF;
}
.nav-link.current::after {
    content: "";
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background-color: #404BBF;
    display: block;
    position: absolute;
   bottom: -1px;
}

.address-list {
font-style: normal;
display: flex;
gap: 40px;
}

.contacts-link {
    font-style: normal;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em; 
    color: #434455;
    text-decoration: none;
    display: block;
    padding-top: 24px;
    padding-bottom: 24px;
    transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.contacts-link:active,
.contacts-link:hover,
.contacts-link:focus {
    color: #404BBF;
}

.section-hero {
    background-color: rgba(46, 47, 66, 0.7);
    background-image: linear-gradient(rgba(46, 47, 66, 0.7), rgba(46, 47, 66, 0.7)), url("../images/hero-img.jpg");
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    padding-bottom: 188px;
    padding-top: 188px;
    margin: auto;
    max-width: 1440px;
}

.section-hero .container {
    flex-direction: column;
    align-items: center;
}
.hero-title {
    font-weight: 700;
    font-size: 56px;
    line-height: 1.07;
    letter-spacing: 0.02em;
    color: #FFFFFF;
    text-align: center;
    margin-bottom: 48px;
    max-width: 496px; 
}
.section-hero-btn {
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.04em;
    background-color: #4D5AE5;
    color: #FFFFFF;
    border: none;
    border-radius: 4px;
    cursor: pointer;
   padding: 16px 32px;
   box-shadow: 0 4px 4px rgba(0, 0, 0, 0.15);
transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}


.section-hero-btn:hover,
.section-hero-btn:focus {
    background-color: #404BBF;
} 

.section-featurs {
    background-color: #fff;
   width: 100%;
}

.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;
}

.featurs-list {
display: flex;
gap: 24px;
}

.featurs-item {
    width: 264px;
   
}

.featurs-icon {
    height: 112px;
    border: 1px solid #8E8F99;
    border-radius: 4px;
    background-color: #F4F4FD;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
} 
.featurs-icon .icon {
    fill: #2E2F42;
}

.featurs-item-title {
    margin-bottom: 8px;
}
.section-teams {
    background-color: #F4F4FD;
    width: 100%;
}

.section-teams .container {
    flex-direction: column;
}
.teams-title {
margin-bottom: 72px;
}

.teams-list {
    display: flex;
    gap: 24px;
}
.teams-card {
    background-color: #FFFFFF;
    width: 264px;
    box-shadow: 0 1px 6px rgba(46, 47, 66, 0.08),0 1px 1px rgba(46, 47, 66, 0.16),0 2px 1px rgba(46, 47, 66, 0.08);
    border-radius: 0 0 4px 4px;
}

.teams-card-img {
    max-width: 100%;
}

.teams-card-content {
    padding: 32px 16px;
    display: flex;
    flex-direction: column;
}

.teams-name {
    text-align: center;
    margin-bottom: 8px;
}
.teams-role {
    text-align: center;
    margin-bottom: 8px;

}

.teams-card-social-list {
    display: flex;
gap: 24px;
    
    
}
.link {
    display: flex;
        justify-content: center;
        align-items: center;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        background-color: #4D5AE5;
        transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.link:focus,
.link:hover {
    background-color: #404bbf;
}

.icon {
    fill: #F4F4FD;
}
.social-link .icon:focus,
.social-link .icon:hover {
    fill: #F4F4FD;
}

.section-portfolio {
    width: 100%;
}
.section-portfolio .container {
    flex-direction: column;
}

.portfolio-title {
    text-align: center;
    margin-bottom: 72px;
}

.portfolio-list {
    display: flex;
    flex-wrap: wrap;
    gap: 48px 24px;
}

.portfolio-card {
    background-color: #FFFFFF;
   text-align: left;
    width: 360px;
transition: box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.overlay-img {
position: relative;
overflow: hidden;
}

.portfolio-card-img {
    max-width: 100%;
    }

.overlay {
    position: absolute;
    padding: 40px 32px;
    background-color: #4D5AE5;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: translateY(100%);
    transition: transform 250ms cubic-bezier(0.4, 0, 0.2, 1);

}
.overlay-text {
color: #F4F4FD;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: 0.02em;
}
.portfolio-card:hover {
box-shadow: 0 1px 6px rgba(46, 47, 66, 0.08), 0 1px 1px rgba(46, 47, 66, 0.16), 0 2px 1px rgba(46, 47, 66, 0.08);
}
.portfolio-card:hover .overlay {
    transform: translateY(0);
}

.portfolio-card-text {
    padding: 32px 16px;
    border: 1px solid #E7E9FC;
    border-top: none;
}

.card-title {
    margin-bottom: 8px;
}

.footer-section {
    background-color: #2E2F42;
    width: 100%;
}
.footer-section .container {
   padding-top: 100px;
    padding-bottom: 100px;
    display: flex;
    align-items: baseline;
    
}

.footer-logo-link {
    font-family: Raleway, sans-serif;
    font-size: 18px;
    font-weight: 700;
    text-decoration: none;
    color: #F4F4FD;
    text-transform: uppercase;
    line-height: 1.17;
    letter-spacing: 0.03em;
}

.footer-logo-link:focus,
.footer-logo-link:hover {
    outline: none;
}

.footer-text {
    color: #F4F4FD;
    width: 264px;
    margin-top: 16px;
}

.footer-social-box {
    margin-left: 120px;
    margin-right: 80px;
}

.footer-title-social-link {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: 0.02em;
    margin-bottom: 16px;
    color: #fff;
}
.footer-social-list{
    gap: 16px;
    display: flex;

}

.footer-social-link .link:focus,
.footer-social-link .link:hover {
    background-color: #31d0aa;
    outline: none;
}

.form-subscribe {
    width: 453px;
        height: 80px;

}

.form-subscribe-label {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #fff;
  display: block;
    margin-bottom: 16px;
}

.input-btn-box {
    display: flex;
    gap: 24px;
    flex-direction: row;
    justify-content:space-between;
}

.footer-email-input {
    width: 100%;
    max-width: 264px;
    height: 40px;
    padding-left: 16px;
    border: 1px solid #fff;
    box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.15);
    border-radius: 4px;
    background-color: #2E2F42;
    color: #fff;
    font-weight: 400;
        font-size: 12px;
    
        /* line-height: 24px; */
        line-height: 2;
        letter-spacing: 0.04em;
        color: #fff;
        transition: border-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.footer-email-input::placeholder {
    color: #fff;
}

.footer-email-input:focus,
.footer-email-input:hover {
    border-color: rgba(49, 208, 170, 1);
    outline: none;
}

.form-subscribe-btn {
    display: flex;
        align-items: center;
        justify-content: center;
        flex-direction: row;
        gap: 16px;
        border-radius: 4px;
            padding-block: 8px;
            padding-inline: 24px;
            min-width: 169px;
            height: 40px;
            background: #4D5AE5;
            font-weight: 500;
                font-size: 16px;
            transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
                /* line-height: 24px; */
                line-height: 1.5;
                letter-spacing: 0.04em;
                /* text-align: center; */
                color: #fff;
                border: none;
    }
    .form-subscribe-btn .icon {
        fill: #fff;
    }

    .form-subscribe-btn:focus,
    .form-subscribe-btn:hover {
        background-color: #31d0aa;
        fill: #fff;
        outline: none;
    }

    .backdrop {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(46, 47, 66, 0.4);
        display: flex;
        justify-content: center;
        align-items: center;
        z-index: 9999;
        transition: opacity 250ms cubic-bezier(0.4, 0, 0.2, 1), visibility 250ms cubic-bezier(0.4, 0, 0.2, 1);
        opacity: 0;
            pointer-events: none;
             visibility: hidden;
    }

    .backdrop.is-open {
        opacity: 1;
        pointer-events: auto;
        visibility: visible;
    }
    
    .modal {
        background-color: #FCFCFC;
        padding: 24px;
        border-radius: 4px;
        width: 408px;
        height: 584px;
        box-shadow: 0 1px 1px 0 rgba(0, 0, 0, 0.14), 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 2px 1px 0 rgba(0, 0, 0, 0.2);
    }

    .modal-close-btn {
        display: flex;
        margin: 0 0 24px auto;
        background-color: #E7E9FC;
        border-radius: 50%;
            width: 24px;
            height: 24px;
        cursor: pointer;
        justify-content: center;
            align-items: center;
            transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(0, 0, 0, 0.1);
    padding: 0;
        }
            
    .modal-close-btn:focus,
    .modal-close-btn:hover {
            background-color: #404BBF;
            outline: none;
    }

        .modal-close-btn .icon { 
            fill: #2E2F42;
                transition: fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
               
        }

    .modal-close-btn:focus .icon,
    .modal-close-btn:hover .icon {
        fill: #fff;
    }

        .modal-text{
            font-weight: 500;
                font-size: 16px;
            margin-bottom: 16px;
                /* line-height: 24px; */
                line-height: 1.5;
                letter-spacing: 0.02em;
                text-align: center;
                color: #2E2F42;
            }

            .modal-form {
                display: flex;
                    align-items: flex-start;
                    justify-content: flex-start;
                    flex-direction: column;
                    border-radius: 4px;
            }

            .modal-form-label {
            font-weight: 400;
                font-size: 12px;
            margin-bottom: 4px;
                /* line-height: 14px; */
                line-height: 1.16667;
                letter-spacing: 0.04em;
                color: #8E8F99;
                display: block;
            }

            .icon-input-box {
    display: flex;
position: relative;
width: 100%;
margin-bottom: 8px;
}
        .icon-input-box .icon {
                            fill: #2E2F42;
                           stroke: #2E2F42;
                           position: absolute;
                            top: 50%;
                            left: 16px;
                            transform: translateY(-50%);
                             transition: fill 250ms cubic-bezier(0.4, 0, 0.2, 1), stroke 250ms cubic-bezier(0.4, 0, 0.2, 1);
                        display: flex;
                        justify-content: center;
                        align-items: center;
                        pointer-events: none;
                            }

.icon-input-box:focus-within .icon,
.icon-input-box:hover .icon {
    fill: #4D5AE5;
    stroke: #4D5AE5;
}

            .modal-form-input {
        border: 1px solid rgba(46, 47, 66, 0.4);
            border-radius: 4px;
            width: 100%;
            height: 40px;
            display: flex;
           padding-left: 38px;
           padding-right: 4px;
        color: #2E2F42;
        transition: border 250ms cubic-bezier(0.4, 0, 0.2, 1);
            }
        
                .modal-form-input:focus,
                .modal-form-input:hover {
                    border: 1px solid rgba(77, 90, 229, 1);
                    outline: none;
                }

            .modal-input-message {
                border: 1px solid rgba(46, 47, 66, 0.4);
                border-radius: 4px;
                width: 100%;
                height: 120px;
                margin-bottom: 16px;
                padding: 8px 16px;
                transition: border 250ms cubic-bezier(0.4, 0, 0.2, 1);
                resize: none;
                font-weight: 400;
                    font-size: 12px;
                
                    /* line-height: 14px; */
                    line-height: 1.16667;
                    letter-spacing: 0.04em;
                    color: #2E2F42;
            }

                        .modal-input-message:focus,
                        .modal-input-message:hover {
                        border: 1px solid rgba(77, 90, 229, 1);
                            outline: none;
                        }

            .modal-input-message::placeholder {
                color: rgba(46, 47, 66, 0.4);
                font-size: 12px;
                    top: 0;
                    left: 0;
            }

            .modal-form-checkbox {
                display: flex;
                   align-items: flex-start;
                    gap: 8px;
                    margin-bottom: 24px;
                    flex-direction: column;
            }

                        .modal-form-checkbox .modal-form-label {
                display: flex;
                    align-items: center;
                    gap: 8px;
                    margin-bottom: 0;
            }

           .input-checkbox:checked + .modal-form-label .custom-checkbox {
    background-color: #404BBF;
    fill: #fff;
        border-radius: 2px;
        border: 1px solid #404BBF;
        opacity: 1;    
}
    .custom-checkbox {
    fill: none;
  /* opacity: 0; */
    width: 16px;
    height: 16px;
    display: flex;
    border: 1px solid rgba(46, 47, 66, 0.4);
    border-radius: 2px;
        justify-content: center;
        align-items: center;    
        transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1), border 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.input-checkbox:hover +.modal-form-label  .custom-checkbox {
    border: 1px solid rgba(77, 90, 229, 1);  
}

.input-checkbox:focus +.modal-form-label .custom-checkbox {
    border: 1px solid rgba(77, 90, 229, 1);  
    
}
         .modal-form-link {
            color: rgba(77, 90, 229, 1);
                text-decoration: none;
                transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
                /* line-height: 16px; */
                    line-height: 1.33333;
                    text-decoration: underline;
                   transition: border 250ms cubic-bezier(0.4, 0, 0.2, 1);
                  }

            .modal-form-link:focus,
            .modal-form-link:hover {
                border: 1px solid rgba(77, 90, 229, 1);
                outline: none;
            }
                  .modal-form-btn{
                    border-radius: 4px;
                       /* padding: 16px 32px; */
                        min-width: 169px;
                        height: 56px;
                        box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.15);
                            background-color: rgba(77, 90, 229, 1);
                            color: #fff;
                            margin: 0 auto;
                            transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
                font-weight: 500;
                    font-size: 16px;
                outline: none;
                border: none;
                    /* line-height: 24px; */
                    line-height: 1.5;
                    letter-spacing: 0.04em;
                    text-align: center;
                    color: #fff;
                        }

                    .modal-form-btn:focus,
                    .modal-form-btn:hover {
                        box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.15);
                            background-color: rgba(64, 75, 191, 1);
                    outline: none;
                }