/* #region page */
html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  color: #292929;
  font-size: 16px;
  line-height: 140%;
}
/* #endregion */
/* #region header */
.header {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  
  box-sizing: border-box;
  height: 100vh;
  padding: 64px 120px;
  background-image: url(images/header-bg.png);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.header__top {
    display: flex;
    justify-content: space-between;
}
.header__title {
  margin-top: 40px;
  margin-bottom: 0;
  font-size: 48px;
  line-height: 100%;
  font-style: italic;
  font-weight: 800;
  letter-spacing: -1.5px;
}

 /* #endregion */
/* #region menu */
.menu {

  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  transform: translateX(-100%);
  transition: transform 500ms;

  box-sizing: border-box;
  height: 100vh;
  padding: 64px 120px;
  background-color: #E8EFF9;
  
}
.menu:target{
  transform: translateX(0%);
}
.menu__top {
  display: flex;
  justify-content: space-between;
  margin-bottom: 64px;
}
 /* #endregion */
 /* #region list */
.menu__list {
    list-style: none;
    margin: 0 0 48px; /* Зовнішній відступ: 0 зверху і збоку, 48px знизу */
    padding: 0; /* Зсунення тексту всередині списку */
  }
  
  .menu__item {
    margin-bottom: 32px; /* Внутрішній відступ між пунктами списку */
  }
  
  .menu__link {
    display: inline-block; /* Встановлюємо елемент у блочний і встановлюємо ширину як у тексті */
    padding-bottom: 8px; /* Внутрішній відступ знизу елемента (між текстом і лінією) */
    border-bottom: 1px solid transparent; /* Знижуємо лінію підкреслення, за замовчуванням вона прозора */
    color: #1d1d1d; /* Колір тексту */
    text-decoration: none; /* Видаляємо звичайне оформлення посилань */
    font-weight: 600; /* Жирний шрифт */
    font-size: 22px; /* Розмір шрифту */
    line-height: 22px; /* Висота рядка */
    letter-spacing: 2px; /* Міжлітерний інтервал */
    text-transform: uppercase; /* Перетворюємо текст у верхній регістр */
    transition: border-color .3s; /* Задаємо плавний перехід кольору рамки */
  }
  
  .menu__link:hover {
    border-color: #1d1d1d; /* Змінюємо колір рамки при наведенні на посилання */
  }
 /* #endregion */
  .main {
    padding: 120px;
    background-color: white;
  }
  
/* #region recommended */
  .recommended {
   margin-bottom: 120px;
  }
  
 .recommended__title {
    color: #292929;
    margin-top: 0px;
    margin-bottom: 64px;
    font-size: 48px;
    line-height: 100%;
    font-weight: bold;
    text-align: center;
    letter-spacing: -1.5px;
  }
  
  .recommended__products {
    display: flex;
    justify-content: center;
    gap: 24px;
  }
/* #endregion */
/* #region product */
  .product {
    flex-basis: 324px;
  }
  .product__photo {
    width: 100%;
    margin-bottom: 32px;
  }
  
  .product__title {
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 16px;
    line-height: 140%;
  }
  
  .product__category {
    margin-top: 0;
    margin-bottom: 12px;
  }
  
  .product__price {
    margin: 0;
    font-weight: bold;
  }
  
/* #endregion */
  
/* #region categories */
.categories {
  max-width: 1020px;
  margin: 0 auto;
  margin-bottom: 120px;
}
.categories__title {
  margin-top: 0px;
  margin-bottom: 64px;
  font-size: 48px;
  line-height: 100%;
  font-weight: bold;
  text-align: center;
  letter-spacing: -1.5px;
  }
  
/* #endregion */
/* #region category */
.category {
  margin-bottom: 64px;
}

.category__photos {
  display: flex;
  gap: 3%;
  margin-bottom: 16px;
}

.category__title {
  margin: 0;
}

/* #endregion */
/* #region photo */
.photo-wide {
  width: 65%;

}

.photo-square {
  width: 32%;

}
/* #endregion */
/* #region how-to-buy */
.how-to-buy {
  max-width: 1020px;
  margin: 0 auto;
  display: flex;
  gap: 24px;
}
.how-to-buy__title {
  margin-top: 120px;
  margin-bottom: 64px;
  font-size: 48px;
  line-height: 100%;
  font-weight: bold;
  letter-spacing: -1.5px;
  flex-basis: 50%;
  }
.how-to-buy__content {
  flex-basis: 50%;
}

.how-to-buy__benefits {
  display: flex;
  flex-direction: column;
  gap: 16px;
  list-style: none;
  padding: 0;
  margin: 0;
  margin-bottom: 40px;
  font-weight: bold;
}
  
/* #endregion */
/* #region footer */

.footer {
  position: sticky;
  bottom: 0;
  z-index: -1;
  height: 460px;
  background-image: url(images/footer-bg.png);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

/* #endregion */
@media screen and (max-width: 640px) {
  .header {
    padding-bottom: 20px;
    background-image: url(images/header-bg-m.png);
  }

  .header__title {
    color: #292929;
    font-size: 32px;
  }

  .menu {
    padding-bottom: 20px;
  
  }
  .menu__top {
    margin-bottom: 36px;

  }
  .menu__list {
    margin-bottom: 32px;
  }

  .menu__item {
    margin-bottom: 24px;
  }

  .menu__link {
    font-size: 16px;
  }

  .main {
    padding: 30px;
  }
  .how-to-buy__title {
    margin-top: 60px;
    margin-bottom: 20px;
    line-height: 100%;
}
  .recommended__title,
  .categories__title,
  .how-to-buy__title {
    font-size: 32px;
  }

  .recommended__products {
    flex-direction: column;
    text-align: center;

  }
  .categories {
    margin: 12px;
  }
  .category__photos {
    display: flex;
    gap: 4%;
    margin-bottom: 16px;
    margin-top: 0;
    margin-bottom: 0;
  }
  

  .photo-wide {
    width: 48%;
    object-fit: cover;
    object-position: center;
  }
  .photo-wide-m {
    width: 48%;
    object-fit: cover;
    object-position: right;
  }
  
  .photo-square {
    width: 48%; 
    object-fit: cover;
  }
  .category__photos {
    text-align: center;
    display: flex;
    justify-content: center; /* Вирівнюємо елементи по центру по горизонталі */
  }

  .header {
    padding: 40px 10px;
  }

  .header__bottom {
    margin-top: 20px;
  }

  .header__title {
    font-size: 18px;
  }

  .footer {
    background-image: url(images/footer-bg-m.png);
  }

  .how-to-buy {
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
  }

  .categories {
    justify-content: space-between;

  }
}
@media screen and (max-width: 800px) {

  .recommended__products {
    flex-direction: column;
    text-align: center;

  }
  
}