/* #region Basical */

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

img {
    display: block
}

h1,
h3,
h4,
h5,
h6 {
    font-weight: 500;
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #2E2F42;
    margin: 0;
}

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

p {
    margin: 0;
}

body {
    font-family: "Roboto", sans-serif;
    color: #434455;
    background-color: #ffffff;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    font-style: normal;
}

a {
    text-decoration: none;
    color: inherit;
}

header {}

/* #endregion */

/* #region Common */

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

.accent-background {
    background-color: #2E2F42;
    color: #F4F4FD;
}

.accent-background-cloud {
    background-color: #F4F4FD;
}

.accent-text {
    color: #4D5AE5;
    font-weight: 700;
    font-size: 18px;
    line-height: 1.17;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    font-family: "Raleway", sans-serif;
    text-decoration: none;
}

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

.section {
    padding: 120px 0;
}
.animation {
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
/* #endregion */

/* #region Navigation */
.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);
}

.nav-con {
    display: flex;
    align-items: center;
}

.navigation {
    display: flex;
}

.navigation-list{
    display: flex;
    gap: 40px;
    margin-left: 76px;
    padding-left: 0;
}

.nav-logo {
    margin-top: 24px;
    margin-bottom: 24px;
}

.nav-studio {
    color: #2E2F42;
}
.navigation-list-link {
    font-weight: 500;
    color: #2E2F42;
    display: block;
    padding: 24px 0;
    position: relative;
    transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.active {
    position: relative;
    color: #404bbf;
}

.active::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -1px;
    
    width: 100%;
    height: 4px;
    
    background-color: #404bbf;
    border-radius: 2px;
}

.contacts {
    display: inline-block;
    margin-left: auto;
}

.contacts-list {
    display: flex;
    gap: 40px;
    padding-left: 0;
}

.contacts-list-link {
    text-decoration: none;
    font-style: normal;
    color: #434455;
    display: flex;
    margin-top: 24px;
    margin-bottom: 24px;
    transition: color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.navigation-list-link:hover,
.navigation-list-link:focus,
.contacts-list-link:hover,
.contacts-list-link:focus {
    color: #404BBF;
}

/* #endregion */

/* #region Hero */
.hero {
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    
    padding: 188px 0;
    
    background-image:
        linear-gradient(rgba(46, 47, 66, 0.7), rgba(46, 47, 66, 0.7)),
        url("../images/office.jpg");
    
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
}

.hero-con {
    text-align: center;
    padding-right: 316px;
    padding-left: 316px;
}

.hero-headline {
    font-weight: 700;
    font-size: 56px;
    line-height: 1.07;
    letter-spacing: 0.02em;
    color: #fff;
    max-width: 496px;
    margin-bottom: 48px;
}

.btn {
    font-family: "Roboto", sans-serif;
    background-color: #4D5AE5;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.04em;
    text-align: left;
    cursor: pointer;
    color: #ffffff;
    border-radius: 4px;
    padding: 16px 32px;
    min-width: 169px;
    box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.15);
    border: none;
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.btn:hover,
.btn:focus {
    background-color: #404BBF;
}
/* #endregion */

/* #region Features */
.features {
    padding: 120px 0;
}

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

.features-list-item {
    width: calc((100% - 72px) / 4);
}

.features-headline {
    margin-bottom: 8px;
}
.features-icon {
    width: 100%;
    height: 112px;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #F4F4FD;
    border: 1px solid #8e8f99;
    border-radius: 4px;
    margin-bottom: 8px;
}
.features-desc {}
/* #endregion */

/* #region Team */
.team {
    padding: 120px 0;
}

.team-con {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.team-headline {
    padding-bottom: 72px;
}

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

.team-list-con {
    padding: 32px 16px;
}

.team-list-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);
    width: calc((100% - 72px) / 4);
    
}
.team-icon {
    height: 260px;
    width: 264px;
}

.team-list-item-member {
    text-align: center;
    margin-bottom: 8px;
}

.team-list-item-desc {
    text-align: center;
}
.team-socials {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    align-items: center;
    justify-content: center;
    margin-top: 8px;
}
.team-socials-link {
    background-color: #4D5AE5;
    border-radius: 50%;
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
    width: 40px;
    height: 40px;
}
.team-socials-con {
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    display: flex;
    background-color: #4D5AE5;
    border-radius: 50%;
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}
.team-socials-icon {
    align-items: center;
    justify-content: center;
    display: flex;
    width: 16px;
    height: 16px;
    color: #F4F4FD;
    fill: #F4F4FD;
}

.team-socials-con:hover, 
.team-socials-con:focus {
    background-color: #404BBF;
}

.team-socials-link:hover,
.team-socials-link:focus {
    background-color: #404BBF;
}
/* #endregion */

/* #region Portfolio */
.portfolio {
    padding: 120px 0;
}

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

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

.portfolio-list-con {
    padding: 32px 16px;
    border: 1px solid #e7e9fc;
    border-top: none;
    position: relative;
    z-index: 2;
    background-color: #fff;
}

.portfolio-item {
    background-color: #fff;
    position: relative;
    overflow: hidden;
    transition: box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1);
    width: calc((100% - 48px) / 3);
}

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

.portfolio-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
}
.portfolio-thumb {
    position: relative;
    overflow: hidden;
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background-color: #4D5AE5;
    color: #f4f4fd;
    padding: 40px 32px;

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

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

/* #endregion */

/* #region Footer */

.footer {
    background-color: #2e2f42;
    padding: 100px 0;
}

.footer-container {
    display: flex;
    align-items: baseline;
}

/* Left side */

.footer-left {
    max-width: 264px;
    margin-right: 120px;
}

.footer-logo {
    font-family: "Raleway", sans-serif;
    font-weight: 700;
    font-size: 18px;
    letter-spacing: 0.02em;
    text-decoration: none;
    color: #4d5ae5;
    text-transform: uppercase
}

.footer-logo-accent {
    color: #f4f4fd;
}

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

/* Social block */

.footer-socials {
    margin-right: 80px;
}

.footer-social-title {
    font-weight: 500;
    color: #ffffff;
    margin-bottom: 16px;
}

.footer-social-list {
    display: flex;
    gap: 16px;
    padding: 0;
    margin: 0;
    list-style: none;
}

.footer-social-item {
    width: 40px;
    height: 40px;
}

.footer-social-link {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 100%;
    height: 100%;

    background-color: #4d5ae5;
    border-radius: 50%;

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

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

.footer-social-icon {
    width: 24px;
    height: 24px;
    fill: #f4f4fd;
}

.footer-btn {
    display: flex;
    width: 165px;
    height: 40px;
    padding: 8px 24px;
    align-items: center;
    font-family: "Roboto", sans-serif;
    background-color: #4D5AE5;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.04em;
    text-align: left;
    cursor: pointer;
    color: #ffffff;
    border-radius: 4px;
    border: none;
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.footer-btn:focus,
.footer-btn:hover {
    background-color: #31d0aa;
}

.footer-subscribe {
}

.footer-subscribe-desc {
    font-weight: 500;
    color: #fff;
    margin-bottom: 16px;
}

.footer-form {
    display: flex;
    gap: 24px;
}

.footer-form-label {}

.footer-form-field {
    outline: none;
    background-color: transparent;
    border: 1px solid #fff;
    border-radius: 4px;
    width: 264px;
    height: 40px;
    padding: 8px 16px;
    color: #fff;
    transition: border-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
    font-size:12px;
    line-height: 2;
    letter-spacing: 0.04em;
}

.footer-form-field::placeholder {
    color: #ffffff;
}
.footer-form-field:focus {
    border-color: #31d0aa;
    outline: none;
}
.footer-btn-icon {
    margin-left: 16px;
}

/* #endregion */

/* #region Modal */
.backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background-color: rgb(46 47 66 / 40%);

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

    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.backdrop.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: initial;
    transition-delay: 0ms;
}

.modal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translateX(-50%) translateY(-70%);
    opacity: 0;

    width: 408px;
    min-height: 584px;
    padding: 72px 24px 24px;
    border-radius: 4px;
    background-color: #fcfcfc;

    transition: opacity 250ms cubic-bezier(0.4, 0, 0.2, 1), transform 250ms cubic-bezier(0.4, 0, 0.2, 1);
    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);
}

.backdrop.is-open .modal {
    opacity: 1;
    transform: translateX(-50%) translateY(-50%);
    transition-delay: 300ms;
}

.close-button {
    width: 24px;
    height: 24px;
    position: absolute;
    top: 24px;
    right: 24px;
    cursor: pointer;
    border: none;
    background-color: #e7e9fc;  
    border-radius: 100%;
    border: 1px solid rgba(0, 0, 0, 0.1);
    transition: background-color 250ms cubic-bezier(0.4, 0, 0.2, 1), fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.close-icon {
    fill: #2e2f42;
    stroke: #2e2f42;
    top: 50%;
    left: 50%;
    transform: translateX(-50%) translateY(-50%);
    width: 8px;
    height: 8px;
    position: absolute;
}

.close-button:hover,
.close-button:focus {
    background-color: #404bbf;
}
.close-button:hover .close-icon {
    stroke: #ffffff;
    fill: #ffffff;
}
.modal-slogan {
    font-weight: 500;
    text-align: center;
    color: #2e2f42;
    margin-bottom: 16px;
}

.feedback-form {
    gap: 8px;
}

.feedback-wrapper {
    position: relative;
    margin-bottom: 8px;
}

.feedback-label {
    display: block;
    margin-bottom: 4px;
    line-height: 1.17;
    letter-spacing: 0.04em;
    color: #8e8f99;
    font-size: 12px;
}

.feedback-field {
    position: relative;
    transition: border-color 250ms cubic-bezier(0.4, 0, 0.2, 1), fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.feedback-input {
    width: 100%;
    height: 40px;
    padding: 11px 38px;
    border: 1px solid rgba(46, 47, 66, 0.4);
    border-radius: 4px;
    outline: none;
    transition: border-color 250ms cubic-bezier(0.4, 0, 0.2, 1), fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.feedback-input:focus {
    border-color: #4D5AE5;
    transition: border-color 250ms cubic-bezier(0.4, 0, 0.2, 1), fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.feedback-icon {
    position: absolute;
    top: 50%;
    left: 16px;
    width: 18px;
    height: 24px;
    transform: translateY(-50%);
    fill: #2e2f42;
    pointer-events: none;
    transition: fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.feedback-input:focus+.feedback-icon {
    fill: #4D5AE5;
}

.error-icon {
    position: absolute;
    top: 50%;
    right: 24px;
    transform: translateY(-50%);
    opacity: 0;
}

.feedback-input:user-invalid~.error-icon {
    opacity: 1;
}

.feedback-comment {
    width: 100%;
    height: 120px;
    padding: 8px 16px;

    line-height: 1.17;
    letter-spacing: 0.04em;

    color: #2e2f42;

    border: 1px solid rgba(46, 47, 66, 0.4);
    border-radius: 4px;
    outline: none;
    resize: none;
    transition: border-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.feedback-wrapper-comment {
    height: 138px;
}

.feedback-comment:focus {
    border-color: #4D5AE5;
    
    transition: border-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.feedback-comment::placeholder {
    color: rgba(64, 64, 64, 0.3);
}

.feedback-agreement {
    display: inline-flex;
    align-items: center;
    margin-top: 16px;
    margin-bottom: 24px;

    color: rgba(64, 64, 64, 0.6);
    font-size: 12px;
    line-height: 1.33;
    letter-spacing: 0.04em;
    color: #8e8f99;
}

.feedback-agreement-con {
    display: flex;
    align-items: center;
}

.feedback-agreement-text {
    justify-content: center;
}

.feedback-toggler {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    position: relative;
    
    width: 16px;
    height: 16px;
    margin-right: 8px;

    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-color 250ms cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.feedback-checkbox:checked+.feedback-toggler {
    background-color: #404bbf;
    border-color: transparent;
    fill: #ffffff;
}

.feedback-toggler-icon {
    opacity: 0;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translateX(-50%) translateY(-50%);
    width: 10px;
    height: 8px;
}

.feedback-checkbox:checked+.feedback-toggler>.feedback-toggler-icon {
    opacity: 1;
}

.feedback-link {
    text-decoration: underline;
    text-decoration-skip-ink: none;
    color: #4d5ae5;
}

.btn-form {
    display: flex;
    text-align: center;
    justify-content: center;
    margin: 0 auto;
}
/* #endregion */