body{
    font-family: "Roboto", sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #434455;
    background-color: #fff;
    margin: 0;
    padding: 0;
}

a {
    text-decoration: none;
    color: #434455;
    font-style: normal;
}

address {
    font-style: normal;

}

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

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

h1, h2, h3 {
    margin: 0;
}

p {
    margin: 0;
}

.text-center {
    text-align: center;
}

.header {
  border-bottom: 1px solid #e7e9fc;
  padding: 0;
  background: #fff;
  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);

}

.container {
    max-width: 320px;
    padding: 0 16px;
    margin: 0 auto;
}

.logo {
    font-family: "Raleway", sans-serif;
    font-weight: 700;
    font-size: 18px;
    line-height: 1.17;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #2e2f42;
}

.accent {
    color: #4d5ae5;
}

.nav {
    display: none;
}

.link {
    padding: 24px 0;
    display: block;
    transition-property: color;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.link:hover, 
.link:focus {
    color: #404bbf;
}

.main-link {
    color: #2e2f42;
    font-weight: 500;
    padding: 24px 0;
    display: block;
    transition: color;
    transition-property: color;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.main-link:hover, .main-link:focus {
    color: #404bbf;
}

.nav-link {
  font-weight: 500;
  padding: 24px 0;
  display: block;
  color: #2e2f42;
  transition: color;
  transition-property: color;
  transition-duration: 250ms;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  line-height: 1.17;       /* 🔥 обязательно */
letter-spacing: 0.04em;
}

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

.start-point {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 56px;
}

.burger-btn {
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;

  display: flex;
  align-items: center;
  justify-content: center;
  fill:#2f2f37;
}

.aligner {
    display: flex;
    align-items: center;
}

.contacts {
  display: none;
}

.main-page {
    background-color: #2e2f42;
    background-image: linear-gradient(
        rgba(46,47,66,0.7),
        rgba(46,47,66,0.7)
    ),
    url("../images/Dark-bg.jpg");

  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;

  max-width: 320px;
  margin: 0 auto;

  padding: 72px 0; /* ← ВАЖНО: вместо flex */
  text-align: center;
}

@media (min-resolution: 192dpi) {
    .main-page {
        background-image: linear-gradient(
            rgba(46,47,66,0.7),
            rgba(46,47,66,0.7)
        ),
        url("../images/Dark-bg@2x.jpg");
    }
}

.main-title {
    font-weight: 700;
    font-size: 36px;
    line-height: 1.11;
    letter-spacing: 0.02em;
    text-align: center;
    color: #fff;
    max-width: 216px;
    margin: 0 auto 72px;
}

.main-page-button {
    box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.15);
    background-color: #4d5ae5;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.04em;
    color: #fff;
    cursor: pointer;
    border: none;
    padding: 16px 32px;
    border-radius: 4px;
    transition-property: background-color;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    display: block;
    margin: 0 auto;
}

.main-page-button:hover,
.main-page-button:focus {
    background-color: #404bbf;
}

.mini-title {
  font-weight: 700;         
  font-size: 36px;           
  line-height: 1.11;
  letter-spacing: 0.02em;

  text-align: center;       
  color: #2e2f42;

  margin-bottom: 8px;
}

.feature-list {
  display: flex;
  flex-direction: column;
  gap: 72px;
}

.feature-icon-box {
  display: none;
}

.feature-item {
  width: 100%;
}

.features-text {
  text-align: left;
  margin-bottom: 0;
  font-weight: 500;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: #434455;
}

.features-section {
  padding: 96px 0;
}

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

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

.our-team-wrapper {
  background: #f4f4fd;
  padding: 96px 0;
  text-align: center;
}

.our-team-list {
    display: flex;
    flex-direction: column;
    gap: 72px;
    align-items: center;
}

.our-team-item {
  background-color: #fff;
  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: 100%;
  max-width: 264px;
}

.team-bottom-text {
  padding: 32px 16px;
}

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

.team-description {
  text-align: center;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: #434455;
}

.social-list {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-top: 8px;
}

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

.social-link {
    width: 100%;
    height: 100%;

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

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

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

.social-icon {
    fill: #f4f4fd;
}

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

.portfolio-list {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.portfolio-item {
    background: #fff;
    width: 100%;
    cursor: pointer;

  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);

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

.portfolio-image-wrapper {
    position: relative;
    overflow: hidden;
}

/* overlay есть, но НЕ активен */
.portfolio-overlay {
    display: none;
}

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

.portfolio-description {
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.02em;
    color: #434455;
    text-align: left;
}

.our-portfolio-wrapper {
    padding: 96px 0;
}

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

.ending {
    background-color: #2e2f42;
    color: #f4f4fd;
     padding: 96px 0;
}

.ending-logo {
    color: #f4f4fd;
    font-family: "Raleway", sans-serif;
    font-weight: 700;
    font-size: 18px;
    line-height: 1.17;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    display: inline-block; /* или block */
    margin-bottom: 16px;
}

.ending-text {
  max-width: 264px;
  margin-top: 0px;
  text-align: left;

}

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

.footer-social-list {
    display: flex;
    gap: 16px;
}

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

.footer-social-link {
    width: 100%;
    height: 100%;

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

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

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

.footer-social-icon {
    fill: #f4f4fd;
}

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

.footer-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 72px;
}

.plane {
    fill: #ffffff;
}

.footer-form {
    display: flex;
 flex-direction: column;
 align-items: center;
    gap: 16px;
}

.footer-input::placeholder {
color: #fff;
font-weight: 400;
font-size: 12px;
line-height: 2;
letter-spacing: 0.04em;
}

.footer-input {
    width: 264px;
    height: 40px;

    border: 1px solid #ffffff;
    border-radius: 4px;
    background-color: transparent;
    color: #fff;

    padding-left: 16px;

font-weight: 400;
font-size: 12px;

line-height: 2;
letter-spacing: 0.04em;
color: #fff;

box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.15);

    /* ✅ transition в базовом состоянии */
    transition-property: border-color;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.footer-input:focus {
    border-color: #31d0aa;
    outline: none;
}

.footer-subscribe {
    display: flex;
    flex-direction: column;
    margin-left: 0;
}


.footer-subscribe-text {
    margin-bottom: 16px;
    font-weight: 500;
font-size: 16px;

/* line-height: 24px; */ 
line-height: 1.5;
letter-spacing: 0.02em;
color: #fff;
}

.footer-btn {
    display: flex;
    align-items: center;
    
    gap: 16px;

    padding: 8px 24px;

    border-radius: 4px;
width: 169px;
height: 40px;

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

    border: none;
    cursor: pointer;

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

    font-weight: 500;
font-size: 16px;

/* line-height: 24px; */ 
line-height: 1.5;
letter-spacing: 0.04em;
text-align: center;
color: #fff;
}

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

.backdrop {
    position: fixed;
    inset: 0;
    background-color: rgba(46,47,66,0.4);

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

    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: relative;

    width: 288px;
    min-height: 584px;

    padding: 72px 16px 24px;
    background: #fcfcfc;
    border-radius: 4px;

    transform: scale(0.9);

    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);

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

.backdrop.is-open .modal {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 24px;
    right: 24px;

    width: 24px;
    height: 24px;

    background-color: #e7e9fc;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.1);

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

    cursor: pointer;

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

.modal-close:hover,
.modal-close:focus {
    background-color: #404bbf;
    border-color: #404bbf;
}

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

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

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

.form-field {
    margin-bottom: 8px;
}

.form-field:last-of-type {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    font-size: 12px;
    margin-bottom: 4px;
    color:#8e8f99;
}

.input-wrap {
    position: relative;
}

.form-input {
    width: 100%;
    height: 40px;

    border: 1px solid rgba(46, 47, 66, 0.4);
    border-radius: 4px;

    padding-left: 38px;

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

.form-input:focus {
    border-color: #4d5ae5;
    outline: none;
}

.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);

    fill: #2e2f42;

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

.form-input:focus + .input-icon {
    fill: #4d5ae5;
}

.form-textarea {
    width: 100%;
    height: 120px;

    border: 1px solid rgba(46, 47, 66, 0.4);
    border-radius: 4px;

    padding: 8px 16px;
    resize: none;

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

.form-textarea:focus {
    border-color: #4d5ae5;
    outline: none;
}

.form-textarea::placeholder {
    font-size: 12px;
    letter-spacing: 0.04em;
    color: rgba(46, 47, 66, 0.4);
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
}

.custom-checkbox {
    width: 16px;
    height: 16px;

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

    border: 1px solid rgba(46, 47, 66, 0.4);
    border-radius: 2px;

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

.accept-icon {
    fill: #f4f4fd;
    opacity: 0;

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

.checkbox-input:checked + .checkbox-label .accept-icon {
    opacity: 1;
}

.checkbox-input:checked + .checkbox-label .custom-checkbox {
    background-color: #404bbf;
    border-color: #404bbf;
}

.checkbox-text {
    font-size: 12px;
    color: #8e8f99;
}

.checkbox-link {
    color: #4d5ae5;
    text-decoration: underline;
}

.modal-btn {
    display: block;
    margin: 24px auto 0;

    min-width: 169px;
    height: 56px;

    border: none;
    border-radius: 4px;

    background: #4d5ae5;
    color: #fff;

    cursor: pointer;

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

    font-weight: 500;
    font-size: 16px;
}
/* -------- Mobile-menu --------*/

.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;

    width: 100%;
    height: 100%;
    background-color: #fff;
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 250ms ease;
    z-index: 999;
}

.mobile-menu.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.mobile-menu-container {
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 72px 16px 40px;
}

.mobile-menu-close {
    position: absolute;
    top: 24px;
    right: 24px;

    width: 24px;
    height: 24px;

    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.1);
    background-color: #e7e9fc;

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

    cursor: pointer;

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

.mobile-menu-close:hover,
.mobile-menu-close:focus {
    background-color: #404bbf;
    border-color: #404bbf;
}

.mobile-menu-close:hover .close-icon,
.mobile-menu-close:focus .close-icon {
    fill: #ffffff;
}

.mobile-menu-close:hover .modal-close-icon,
.mobile-menu-close:focus .modal-close-icon {
    fill: #ffffff;
}

.modal-close-icon {
    fill: #2e2f42;;

    transition: fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-nav {
    margin-bottom: auto;
}

.mobile-main-link {
  color: #404bbf;
  font-size: 36px;
  font-weight: 700;
  line-height: 1.11111;
  letter-spacing: 0.02em;
}

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

.mobile-nav-link {
    font-size: 36px;
    font-weight: 700;
    color: #2e2f42;
    line-height: 1.11111;
    letter-spacing: 0.02em;
}

.mobile-bottom {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.mobile-contact-link {
    font-size: 20px;
    color: #434455;
}

.mobile-phone-link {
    font-size: 20px;
    color: #4D5AE5
}

.mobile-socials {
    display: flex;
    justify-content: space-between;
    gap: 40px;
}

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

.mobile-social-link {
    width: 100%;
    height: 100%;

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

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

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

.mobile-social-link:hover,
.mobile-social-link:focus {
    background-color: #404bbf;
}

.mobile-social-link .footer-social-icon {
    fill: #f4f4fd;
}

.mobile-contacts {
  margin-top: 0;
  padding-top: 0;

  display: flex;
  flex-direction: column;
  gap: 24px;
  font-weight: 500;
  font-size: 20px;
}














/*--------TABLET--------*/

@media screen and (min-width: 768px) {

.header {
    max-height: 72px;
}

.container {
    max-width: 768px;
}

  .start-point {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
  }



  .aligner {
    display: flex;
    align-items: center;
    gap: 120px;
  }

  .contacts-list {
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin: 0;
    padding: 0;
    gap: 12px;
}

  .contacts {
    display: flex;
  }

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

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

.burger-btn {
    display: none;
}

.current::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -1px;

    width: 100%;
    height: 4px;

    background-color: #404bbf;
    border-radius: 2px;
}

.contacts-list {
    display: flex;
    flex-direction: column;
}

.main-page {
    max-width: 768px;
    padding: 112px 0;
    background-image: linear-gradient(
        rgba(46,47,66,0.7),
        rgba(46,47,66,0.7)
    ),
    url("../images/Dark-bg-tablet.jpg");
    
}

.main-title {
    font-size: 56px;
    max-width: 496px;
    line-height: 1.07;
    margin: 0 auto 36px;
}

.mini-title {
    text-align: left;
}

.feature-list {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 72px 24px;
}

.feature-item {
    flex-basis: calc((100% - 24px) / 2);
}

.features-text {
    text-align: left;
}

.our-team-list {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;   /* 🔥 ОБЯЗАТЕЛЬНО */
    gap: 64px 24px;
}

.our-team-item {
    width: 264px;
}

.portfolio-list {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 72px 24px;
}

.portfolio-item {
    flex-basis: calc((100% - 24px) / 2);
}

.portfolio-overlay {
    display: none;
}

.footer-wrapper {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 72px 24px;
    align-items: flex-start;
    margin: 0 auto;
}

.footer-info {
    align-items: flex-start;
}

.ending-logo {
    text-align: left;
}

.ending-text {
    text-align: left;
    margin: 0;
}

.footer-social {
    align-items: flex-start;
}

.footer-social-title {
    text-align: left;
}

.footer-subscribe {
    align-items: flex-start;
}

.footer-subscribe-text {
    text-align: left;
}

.footer-form {
    flex-direction: row;
    gap: 24px;
    align-items: flex-start;
}

.footer-input {
    width: 264px;
    max-width: none;
}

.modal {
    width: 408px;
    min-height: 584px;

    padding: 72px 24px 24px;
}

.mobile-menu {
    display: none;
}

}

@media (min-width: 768px) and (min-resolution: 192dpi) {
    .main-page {
    background-image: linear-gradient(
        rgba(46,47,66,0.7),
        rgba(46,47,66,0.7)
    ),
    url("../images/Dark-bg-tablet@2x.jpg");
}
}

@media (min-width: 768px) and (max-width: 1157px)
{
    .footer-wrapper {
        max-width: 568px;
    }

    .link {
    padding: 0;
    font-weight: 400;
    font-size: 12px;
    line-height: 1.17;       /* 🔥 обязательно */
    letter-spacing: 0.04em;
}
}












/* ------ DESKTOP ------ */


@media screen and (min-width: 1158px) {

.container {
max-width: 1158px; 
padding: 0 15px;
}

.contacts-list {
  flex-direction: row;
  gap: 40px;
}

.main-page {
    max-width: 1440px;
    padding: 188px 0;
    background-image: linear-gradient(
        rgba(46,47,66,0.7),
        rgba(46,47,66,0.7)
    ),
    url("../images/hero.jpg");
}

.main-page-button {
    box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.15);
    background-color: #4d5ae5;
    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.04em;
    color: #fff;
    cursor: pointer;
    border: none;
    padding: 16px 32px;
    border-radius: 4px;
    transition-property: background-color;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

main {
    flex-shrink: 1;
}

.main-title {
    margin: 0 auto 48px;
}

.mini-title {
    font-weight: 500;
    font-size: 20px;
    line-height: 1.2;
    letter-spacing: 0.02em;
    color: #2e2f42;
    margin-bottom: 8px;
    margin-top: 0;
    text-align: left;
}

 .aligner {
    gap: 76px;
  }

.feature-list {
   flex-wrap: nowrap;
   gap: 24px;
}

.feature-item {
    flex-basis: calc((100% - 72px) / 4);
}

.feature-icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 112px;
    margin-bottom: 8px;
    background-color: #f4f4fd;
    border: 1px solid #8e8f99;
    border-radius: 4px;
}

.features-section {
    padding: 120px 0;
}

.features-text {
    text-align: left;
    margin-bottom: 0;
    font-weight: 400;
    font-size: 16px;
}

.team-section-title {
    padding-top: 0
}

.our-team-wrapper {
   padding: 120px 0;
}

.our-team-list {
    flex-wrap: nowrap;
    justify-content: center;
    gap: 24px;
    margin-top: 0
}

.our-team-item {
    flex-basis: calc((100% - 72px) / 4)
}

.team-name {
    margin-top: 0;
}

.social-link:hover,
.social-link:focus {
    background-color: #404bbf;
}

.our-portfolio-wrapper {
    padding: 120px 0;
}

.portfolio-image-wrapper {
    position: relative;
    overflow: hidden;
}

.portfolio-overlay {
    display: flex;
    position: absolute;
    top: 0;
    left: 0;

    width: 100%;
    height: 100%;

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

    padding: 40px 32px;

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

.portfolio-item {
    flex-basis: calc((100% - 48px) / 3);
    cursor: pointer;
    box-shadow: none;
    transition-property: box-shadow;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);

}

.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:hover .portfolio-overlay {
    transform: translateY(0);
}

.portfolio-mini-title {
    padding: 0;
}

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

.portfolio-description {
    margin: 0;
    padding: 0;
}

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

.ending {
   padding: 100px 0;
}

.footer-wrapper {
    flex-wrap: nowrap;
}

.footer-info {
    margin-right: 120px;
}

.footer-subscribe {
    margin-left: auto;
}

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

.main {
    flex-grow: 1;
}

.backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background-color: rgba(46, 47, 66, 0.4);

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

    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 {
    width: 408px;
    min-height: 584px;

    background: #fcfcfc;
    border-radius: 4px;

    padding: 72px 24px 24px;

    position: relative;

    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);

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

.backdrop.is-open .modal {
    transform: scale(1);
}

label {
    color:#8e8f99;
}

.modal-close {
    position: absolute;
    top: 24px;
    right: 24px;

    width: 24px;
    height: 24px;

    background-color: #e7e9fc;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.1);

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

    cursor: pointer;

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

.modal-close:hover,
.modal-close:focus {
    background-color: #404bbf;
    border-color: #404bbf;
}

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

.close-icon {
fill: #2e2f42;;
   
transition: fill 250ms cubic-bezier(0.4, 0, 0.2, 1);
transition-duration: 250ms;
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-title {
   font-weight: 500;
font-size: 16px;

/* line-height: 24px; */ 
line-height: 1.5;
letter-spacing: 0.02em;
text-align: center;
color: #2e2f42;
margin-bottom: 16px;
}

.form-field {
    margin-bottom: 8px;
}

.form-field:last-of-type {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    font-size: 12px;
    margin-bottom: 4px;
}

.form-input {
    width: 100%; 
    height: 40px; 
    border: 1px solid rgba(46, 47, 66, 0.4); 
    border-radius: 4px; 
    padding: 8px; 
    transition-property: border-color; 
    transition-duration: 250ms; 
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); 
}

.form-input:focus {
    border: 1px solid #4d5ae5;
    outline: none;
}

.form-textarea {
    width: 100%;
    height: 120px;

    border: 1px solid rgba(46, 47, 66, 0.4);
    border-radius: 4px;

    padding: 8px 16px;
    resize: none;

    transition-property: border-color;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.form-textarea:focus {
    border-color: #4d5ae5;
    outline: none;
}

.form-textarea::placeholder {
font-weight: 400;
font-size: 12px;
line-height: 1.16667;
letter-spacing: 0.04em;
color: rgba(46, 47, 66, 0.4);
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.custom-checkbox {
  width: 16px;
  height: 16px;

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

  border: 1px solid rgba(46, 47, 66, 0.4);
  border-radius: 2px;

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

.accept-icon {
    justify-content: center;
    fill: #f4f4fd;
    opacity: 0;

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

.checkbox-input:checked + .checkbox-label .accept-icon {
  fill: #fff;
  opacity: 1;
}

.checkbox-link {
    color: #4d5ae5;
    text-decoration: underline;

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

.checkbox-link:hover,
.checkbox-link:focus {
    color: #404bbf;
}

.checkbox-input:checked + .checkbox-label .custom-checkbox {
    background-color: #404bbf;
    border-color: #404bbf;
    border: 1px solid #404bbf;
border-radius: 2px;
}

.checkbox-text {
    font-weight: 400;
font-size: 12px;

line-height: 1.16667;
letter-spacing: 0.04em;
color: #8e8f99;
}

.modal-btn {
    display: block;
    margin: 24px auto 0;
    min-width: 169px;
    height: 56px;

    padding: 16px 32px;
    border: none;
    border-radius: 4px;

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

    cursor: pointer;

    transition-property: background-color;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);

    font-weight: 500;
    font-size: 16px;
    line-height: 1.5;
letter-spacing: 0.04em;
}

.modal-btn:hover,
.modal-btn:focus {
    background-color: #404bbf;
}

.input-wrap {
    position: relative;
}

.form-input {
    padding-left: 38px; /* ← ВАЖНО */

}

.form-input:focus + .input-icon {
    fill: #4d5ae5;
    transition-property: fill;
    transition-duration: 250ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);

}



.input-icon {
      position: absolute;
    left: 16px;
    top: 50%;                 /* ← ключ */
    transform: translateY(-50%); /* ← ключ */

    fill: #2e2f42;

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

.mobile-menu {
        display: none;
    }

} 

@media (min-width: 1158px) and (min-resolution: 192dpi) {
    .main-page {
    background-image: linear-gradient(
        rgba(46,47,66,0.7),
        rgba(46,47,66,0.7)
    ),
    url("../images/hero@2x.jpg");
}
}