h1,h2,h3,h4,h5,h6,p{
    margin: 0;
}

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

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

/* common */
.container{
    max-width: 1158px;
    padding-left: 15px;
    padding-right: 15px;
    margin-left: auto;
    margin-right: auto;
}

img{
    display: block;
}

/* #region header */
.header{
    background-color: #FFFFFF;
    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);
}

.head-flex{
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-ul{
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    /* HW3 */
    
    gap: 40px;
}

a{
    text-decoration: none;
}

ul,
ol{
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.logo{
    font-family: "Raleway", sans-serif;
    font-weight: 700;
    font-size: 18px;
    line-height: 1.17;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    text-decoration: none;
    color: #4D5AE5;
    /* HW3 */
    display: inline-block ;
    margin-right: 76px;
}

.address{
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    font-style: normal;
    margin-left: auto;  
}

.header-ul .item-link{
    color: #2e2f42;
}

.address-ul{
    gap: 40px;
}

.item-link{
    position: relative;
    display: block; /* For display LINK on full height */
    padding-top: 24px;
    padding-bottom: 24px;

    transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.address-ul .item-link{
    color: #434455;
}

.header-nav 
.logo-studio{
    color: #2E2F42;
}

.footer
.logo-studio{
    color: #F4F4FD;
}

.logo:hover,
.logo:focus{
    cursor:default;
}

.item-link:hover,
.item-link:focus,
.item-link.current {
    color: #404BBF;
}
/*
.item-link.current{
    position: relative;
}*/

.item-link::after{
    content: "";

    position: absolute;
    left: 0;
    bottom: -1px;

    width: 100%;
    height: 4px;

    border-radius: 2px;

    background-color: #404bbf;

    opacity: 0;

    transition: opacity 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.item-link:hover::after,
.item-link:focus::after,
.item-link.current::after{
    opacity: 1;
}

/* #endregion */

/* #region hero*/
.hero{
    background-color: #2E2F42;
    background-position: center;
    background-size: cover;
    /* ---HW3---*/
    padding-top: 188px;
    padding-bottom: 188px;
    /*-- HW4 --*/
    max-width: 1440px;
    margin-left: auto;
    margin-right: auto;
    background-image:
        linear-gradient(to bottom,
            rgba(46, 47, 66, 0.7),
            rgba(46, 47, 66, 0.7)),
        url("../images/people-office.jpg");
    background-repeat: no-repeat;
    /*background-size: 1440px;*/
}

.hero-title{
    font-weight: 700;
    font-size: 56px;
    line-height: 1.07143;
    letter-spacing: 0.02em;
    text-align: center;
    color: #FFFFFF;
    /* ---HW3---*/
    max-width: 496px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    margin-bottom: 48px;
}

.button{
    cursor: pointer;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.04em;
    color: #FFFFFF;
    background-color: #4D5AE5;
    /* ---HW3---*/
    display: block;
    min-width: 169px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 0;
    border-radius: 4px;
    padding-top: 16px;
    padding-bottom: 16px;
    padding-left: 0;
    padding-right: 0;
    border: 0;

    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.button:hover,
.button:focus{
    background-color: #404BBF;
}

.icon {
    display: inline-flex;
    margin: 24px 100px;
  }
  

.vision-icon{
    border: 1px solid #8e8f99;
    border-radius: 4px;
    width: 264px;
    height: 112px;
    background: #f4f4fd;
    margin-bottom: 8px;

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


.vision{
    padding: 120px 0;
}

.vision-ul-list{
    display: flex;
    justify-content: space-between;
    gap: 24px;
}

.vision-name{
    font-weight: 500;
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #2E2F42;

    margin-bottom: 8px;
}

.vision-h2{
    text-transform: capitalize;
}

.vision-text{
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    width: calc((1128px - 72px) / 4);
    /*width: 264px;*/
}

.team{
    background-color: #f4f4fd;
    text-transform: capitalize;
    padding: 120px 0;
}

.team-list{
    display: flex;
    justify-content: space-between;
    /* HW3 */
    gap: 24px;
    /*margin-top: 72px;*/
}

.team-item{
    background-color: #FFFFFF;
    border-radius: 0 0 4px 4px;
    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);
}


.team-title{
    font-weight: 700;
    font-size: 36px;
    line-height: 1.11;
    letter-spacing: 0.02em;
    text-align: center;
    color: #2E2F42;
    /* HW3 */
    margin-bottom: 72px;
}

.team-person{
    padding: 32px 0;
    /*-- HW4 --*/
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 8px;
}

.team-name{
    font-weight: 500;
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    text-align: center;
    color: #2E2F42;
    /*margin-bottom: 8px;*/
}

.team-special{
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    text-align: center;
    /*margin-bottom: 8px;*/
}


.team-person .team-social-links {
    display: flex;
    gap: 24px;
    flex-shrink: 0;
    align-self: center;
    justify-content: center;
  }
  
  .team-social-links .social-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);
  }
  
  .team-person .team-social-links .social-link:hover,
  .team-person .team-social-links .social-link:focus {
    background-color: #404bbf;
  }
  
  .team-social-links .social-icon {
    fill: #F4F4FD;
  }

.portfolio{
    text-transform: capitalize;
    padding: 120px 0;
}

.portfolio-title{
    font-weight: 700;
    font-size: 36px;
    line-height: 1.11;
    letter-spacing: 0.02em;
    text-align: center;
    color: #2E2F42;
    /* HW3 */
    margin-bottom: 72px;
}

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

.portfolio-top{
    overflow: hidden;
    position: relative;    
}

.portfolio-li:hover .portfolio-text-overlay{
    transform: translateY(0);    
}

.portfolio-li{
    transition: box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-li:hover{
    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);
}

.portfolio-text-overlay{
    position: absolute;
    padding: 40px 32px;
    height: 100%;
    width: 100%;
    
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;

    color: #f4f4fd;
    background-color: #4d5ae5;

    top: 0;
    left: 0;
    transform: translateY(100%);
    transition: transform 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

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

.portfolio-name{
    font-weight: 500;
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #2E2F42;
    margin-bottom: 8px;
}

.portfolio-type{
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
}
/* #endregion */

/* #region footer */
.footer-logo{
    margin-bottom: 16px;
}

.footer{
    background-color: #2e2f42;
    /*padding-top: 101.5px;
    padding-bottom: 100px;*/
    padding: 100px 0;
}

.footer-logo-main{
    margin-right: 120px;
}

.footer-text{
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #f4f4fd;
    width: 264px;
}

.footer-flex{
    display: flex;
    justify-content: flex-start;
    align-items: baseline;
}

.social-footer-text{
    margin-bottom: 16px;

    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #fff;
}

.social-media .team-social-links{
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}


.team-social-links{
    gap: 16px;
}

.social-media .team-social-links .social-link:hover,
.social-media .team-social-links .social-link:focus {
    background-color: #31d0aa;
}

.open-form{
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.input{
    padding-top: 8px;
    padding-bottom: 8px;
    padding-left: 16px;

    margin-top: 16px;
    background-color: transparent;
    border-color: #FFFFFF;
    border-radius: 4px;
}

input::placeholder {
    color: #FFFFFF;
}

.lab-inpt .label{
    display: flex;
    flex-direction: column;
}

.label{
    color: #FFFFFF;
    margin-left: 80px;
}

.btn-sub{
    color: #FFFFFF;
    background-color: #4d5ae5;
    padding-top: 8px;
    padding-bottom: 8px;
    padding-left: 24px;
    border: 0;
    border-radius: 4px;
    margin-left: 24px;
    max-width: 264px;
}

.icon-send{
    fill: #FFFFFF;
}
/* #endregion */