/* Base Styles */
.collection-container {
  max-width: 1670px;
  margin: 0 auto;
  padding: 20px;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased; /* Улучшает рендеринг шрифтов на iOS */
}

/* Full Width Banner */
.full-width-banner {
  width: 100%;
  height: 655px;
  background-image: url("https://images.unsplash.com/photo-1584302179602-e4c3d3fd629d?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=2070&q=80");
  background-size: cover;
  background-position: center;
  background-attachment: scroll; /* Улучшает поведение фона на iOS */
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 40px;
  position: relative;
}

.full-width-banner::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.3);
  z-index: 0;
}

.banner-content {
  text-align: center;
  color: white;
  position: relative;
  z-index: 1;
  padding: 0 20px;
}

.banner-content h2 {
  font-size: 42px;
  font-weight: 300;
  letter-spacing: 6px;
  margin-bottom: 20px;
  font-family: "Forum", serif;
  font-display: swap;
}

.banner-content p {
  font-size: 18px;
  margin-bottom: 30px;
}

.banner-btn {
  padding: 12px 30px;
  background-color: transparent;
  border: 1px solid white;
  color: white;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.3s ease, color 0.3s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.banner-btn:hover {
  background-color: white;
  color: #242323;
}

/* Collection Header Styles */
.collection-header {
  text-align: center;
  margin-bottom: 30px;
}

.collection-header h1 {
  font-size: 28px;
  font-weight: 300;
  letter-spacing: 4px;
  margin-bottom: 20px;
  font-family: "Forum", serif;
  font-display: swap;
}

.description {
  max-width: 800px;
  margin: 0 auto;
  font-size: 14px;
  line-height: 1.5;
}

/* Navigation Styles */
.nav-buttons {
  display: flex;
  justify-content: center;
  gap: 10px;
  padding-bottom: 85px;
}

.nav-buttons button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border: 1px solid #c2c2c2;
  background-color: transparent;
  font-size: 14px;
  cursor: pointer;
  min-width: 120px;
  flex-direction: row-reverse;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
/* Добавить в collectionInfoPage.css или создать отдельный файл */

/* Добавить в collectionInfoPage.css или создать отдельный файл */

.favorite-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    background: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    z-index: 10;
    padding: 0;
}

.favorite-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.favorite-icon {
    transition: all 0.3s ease;
    stroke: #242323;
    fill: none;
}

.favorite-icon.filled {
    fill: #242323;
    stroke: #242323;
}

/* Анимация при клике */
.favorite-btn:active {
    transform: scale(0.95);
}

/* Адаптивность для больших карточек */
.collection-product-card.large .favorite-btn {
    width: 45px;
    height: 45px;
    top: 25px;
    right: 25px;
}

.collection-product-card.large .favorite-icon {
    width: 28px;
    height: 28px;
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .favorite-btn {
        width: 35px;
        height: 35px;
        top: 15px;
        right: 15px;
    }

    .favorite-icon {
        width: 20px;
        height: 20px;
    }
}
.nav-buttons button img {
  vertical-align: middle;
  width: 20px;
  height: 20px;
  transition: filter 0.3s ease;
}

.nav-buttons button.active {
  background-color: #242323;
  color: white;
}

.nav-buttons button.active img {
  filter: invert(100%) sepia(100%) saturate(0%) hue-rotate(180deg) brightness(100%) contrast(100%);
}

/* Filters Styles */
.filters {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
}

.filter-label {
  font-size: 14px;
  margin-right: 10px;
}

/* Collection Products Container Styles */
.collection-products-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 40px;
  width: 100%;
  -webkit-overflow-scrolling: touch;
}

/* Product Row Styles */
.product-row {
  display: grid;
  gap: 20px;
  width: 100%;
}

/* Row specific layouts */
.row-1,
.row-3 {
  grid-template-columns: 1fr 1fr 2fr;
}

.row-2,
.row-4 {
  grid-template-columns: repeat(4, 1fr);
}

/* Product Card Styles - Regular Cards */
.collection-product-card {
  display: flex;
  flex-direction: column;
  gap: 15px;
  width: 100%;
  box-sizing: border-box;
}

.card-image {
  position: relative;
  background-color: #f7f7f7;
  height: 551px;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.card-image img {
  width: 328px;
  height: 328px;
  object-fit: cover;
}

.new-label {
  position: absolute;
  top: 20px;
  left: 20px;
  color: #242323;
  font-size: 18px;
  font-family: "Raleway", sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  line-height: 21.6px;
  font-display: swap;
}

/* Favorite Button Styles */
.favorite-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 10;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.favorite-btn i {
  font-size: 24px;
  color: #727272;
  transition: color 0.3s ease;
}

.favorite-btn:hover i {
  color: #242323;
}

.favorite-btn i.fas {
  color: #242323;
}

.carousel-indicators {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 15px;
  position: absolute;
  bottom: 20px;
  left: 0;
  z-index: 20;
  right: 0;
  padding: 10px 0;
}

.carousel-indicators span {
  width: 40px;
  height: 3px;
  background-color: rgba(36, 35, 35, 0.3);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.carousel-indicators span::before {
  content: "";
  position: absolute;
  top: -8px;
  left: 0;
  right: 0;
  bottom: -8px;
}

.carousel-indicators span:hover {
  background-color: rgba(36, 35, 35, 0.6);
  width: 50px;
}

.carousel-indicators span.active {
  background-color: #242323;
  width: 60px;
}

.product-info {
  position: relative;
  height: 54px;
  width: 100%;
}

.product-info h3 {
  color: #242323;
  font-size: 18px;
  font-family: "Raleway", sans-serif;
  font-weight: 500;
  text-transform: uppercase;
  line-height: 21.6px;
  position: absolute;
  left: 13px;
  top: 0;
  margin: 0;
  font-display: swap;
}

.product-info .code {
  color: #727272;
  font-size: 18px;
  font-family: "Forum", serif;
  font-weight: 400;
  text-transform: capitalize;
  line-height: 21.6px;
  position: absolute;
  right: 0;
  top: 0;
  margin: 0;
}

.product-info .price-label {
  color: #727272;
  font-size: 18px;
  font-family: "Raleway", sans-serif;
  font-weight: 400;
  text-transform: uppercase;
  line-height: 21.6px;
  position: absolute;
  left: 13px;
  bottom: 0;
  margin: 0;
}

.product-info .price {
  color: #727272;
  font-size: 18px;
  font-family: Arial !important;

  /*font-family: "Raleway", sans-serif;*/
  font-weight: 400;
  text-transform: uppercase;
  line-height: 21.6px;
  position: absolute;
  right: 0;
  bottom: 0;
  margin: 0;
}

/* Large Product Card Styles */
.collection-product-card.large {
  grid-row: span 2;
  width: 87%;
  margin-left: 100px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-sizing: border-box;
}

.collection-product-card.large:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  border-radius: 5px;
}

.collection-product-card.large .card-image {
  height: 800px;
  background-color: #f7f7f7;
  border-bottom: 2px solid #d8d8d8;
}

.collection-product-card.large .card-image img {
  width: 400px;
  height: 400px;
  transition: transform 0.3s ease;
}

.collection-product-card.large:hover .card-image img {
  transform: scale(1.05);
}

.collection-product-card.large .favorite-btn i {
  font-size: 28px;
}

.collection-product-card.large .carousel-indicators {
  bottom: 30px;
}

.collection-product-card.large .carousel-indicators span {
  width: 50px;
  height: 4px;
}

.collection-product-card.large .carousel-indicators span.active {
  width: 70px;
}
.product-new-label {
    position: absolute;
    top: 20px;
    left: 20px;
    color: #242323;
    font-size: 18px;
    font-family: 'Raleway', sans-serif;
    font-weight: 600;
    text-transform: uppercase;
    line-height: 21.6px;
}
.collection-product-card.large .product-info {
  height: 60px;
  width: 97%;
  padding: 0 5px;
}

/* Footer Styles */
footer {
  text-align: center;
}

.pagination {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 40px 0;
}

.pagination .load-more {
  margin-top: 10px;
  padding: 12px 24px;
  font-size: 16px;
  color: #000000;
  cursor: pointer;
  border-radius: 5px;
  transition: background-color 0.3s;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.pagination .load-more:hover {
  background-color: #6e6e6e;
  color: #ffffff;
}

.load-more {
  padding: 10px 40px;
  border: 1px solid #c2c2c2;
  background-color: transparent;
  font-size: 14px;
  cursor: pointer;
}

/* Responsive Styles */
@media (max-width: 1200px) {
  .collection-container {
    padding: 15px;
  }

  .card-image img {
    width: 280px;
    height: 280px;
  }

  .collection-product-card.large .card-image img {
    width: 350px;
    height: 350px;
  }

  .collection-product-card.large .card-image {
    height: 700px;
  }
}

@media (max-width: 1170px) {
  .row-1,
  .row-3 {
    grid-template-columns: 1fr 1fr 1.5fr;
  }

  .row-2,
  .row-4 {
    grid-template-columns: repeat(3, 1fr);
  }

  .card-image {
    height: 500px;
  }

  .collection-product-card.large .card-image {
    height: 650px;
  }

  .card-image img {
    width: 260px;
    height: 260px;
  }

  .collection-product-card.large .card-image img {
    width: 320px;
    height: 320px;
  }
}

@media (max-width: 896px) {
  .collection-container {
    padding: 10px;
  }
  .collection-product-card.large .product-info {
    height: 60px;
    padding: 0 0;
  }
  /* Обычные карточки - всегда 2 в ряду */
  .row-1,
  .row-2,
  .row-3,
  .row-4 {
    grid-template-columns: 1fr 1fr;
    gap: 15px;
  }
  .product-info {
    position: relative;
    height: 54px;
    width: 100%;
  }
  /* ИСПРАВЛЕНИЕ: убираем все специальные стили для больших карточек в мобильной версии */
  .collection-product-card.large {
    grid-column: auto; /* убираем grid-column: 1 / -1 */
    grid-row: auto; /* убираем grid-row: span 2 */
    width: 207%; /* стандартная ширина */
    margin-left: 0;
    margin-right: 0;
  }

  /* Все карточки имеют одинаковую высоту изображения */
  .card-image,
  .collection-product-card.large .card-image {
    width: 100%;
    height: 400px;
    border-radius: 15px;
  }

  /* Все изображения одинакового размера */
  .card-image img,
  .collection-product-card.large .card-image img {
    width: 100%;
    height: 100%;
  }

  .full-width-banner {
    height: 500px;
  }

  .banner-content h2 {
    font-size: 32px;
  }

  .favorite-btn i {
    font-size: 20px;
  }

  .carousel-indicators {
    gap: 8px;
    bottom: 15px;
  }

  .carousel-indicators span,
  .collection-product-card.large .carousel-indicators span {
    width: 30px;
    height: 2px;
  }

  .carousel-indicators span:hover,
  .carousel-indicators span.active,
  .collection-product-card.large .carousel-indicators span:hover,
  .collection-product-card.large .carousel-indicators span.active {
    width: 45px;
  }

  .product-info h3,
  .product-info .code,
  .product-info .price-label,
  .product-info .price {
    font-size: 16px;
  }

  .nav-buttons button {
    min-width: 60px;
    min-height: 70px;
    padding: 8px;
    border-radius: 10px;
    font-size: 12px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    gap: 6px;
  }

  .nav-buttons button img {
    width: 18px;
    height: 18px;
  }
}

/* iPhone и мобильные устройства - исправленная адаптивность */
@media (max-width: 768px) {
  .collection-container {
    padding: 10px;
  }
      .code{
        display: none;
    }
  .collection-product-card.large .product-info {
    height: 60px;
    padding: 0 0;
  }
  /* Обычные карточки - всегда 2 в ряду */
  .row-1,
  .row-2,
  .row-3,
  .row-4 {
    grid-template-columns: 1fr 1fr;
    gap: 15px;
  }
  .product-info {
    position: relative;
    height: 54px;
    width: 100%;
  }
  /* ИСПРАВЛЕНИЕ: убираем все специальные стили для больших карточек в мобильной версии */
  .collection-product-card.large {
    grid-column: auto; /* убираем grid-column: 1 / -1 */
    grid-row: auto; /* убираем grid-row: span 2 */
    width: 207%; /* стандартная ширина */
    margin-left: 0;
    margin-right: 0;
  }

  /* Все карточки имеют одинаковую высоту изображения */
  .card-image,
  .collection-product-card.large .card-image {
    width: 100%;
    height: 400px;
    border-radius: 15px;
  }

  /* Все изображения одинакового размера */
  .card-image img,
  .collection-product-card.large .card-image img {
    width: 100%;
    height: 220px;
  }

  .full-width-banner {
    height: 500px;
  }

  .banner-content h2 {
    font-size: 32px;
  }

  .favorite-btn i {
    font-size: 20px;
  }

  .carousel-indicators {
    gap: 8px;
    bottom: 15px;
  }

  .carousel-indicators span,
  .collection-product-card.large .carousel-indicators span {
    width: 30px;
    height: 2px;
  }

  .carousel-indicators span:hover,
  .carousel-indicators span.active,
  .collection-product-card.large .carousel-indicators span:hover,
  .collection-product-card.large .carousel-indicators span.active {
    width: 45px;
  }

  .product-info h3,
  .product-info .code,
  .product-info .price-label,
  .product-info .price {
    font-size: 16px;
  }

  .nav-buttons button {
    min-width: 60px;
    min-height: 70px;
    padding: 8px;
    border-radius: 10px;
    font-size: 12px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    gap: 6px;
  }

  .nav-buttons button img {
    width: 18px;
    height: 18px;
  }
}

/* iPhone-specific styles */
@media only screen and (max-width: 428px) {
  .collection-container {
    padding: 10px;
  }
  .collection-product-card.large .product-info {
    height: 60px;
    padding: 0 0;
  }
  /* Обычные карточки - всегда 2 в ряду */
  .row-1,
  .row-2,
  .row-3,
  .row-4 {
    grid-template-columns: 1fr 1fr;
    gap: 15px;
  }
  .product-info {
    position: relative;
    height: 54px;
    width: 100%;
  }
        .code{
        display: none;
    }
  /* ИСПРАВЛЕНИЕ: убираем все специальные стили для больших карточек в мобильной версии */
  .collection-product-card.large {
    grid-column: auto; /* убираем grid-column: 1 / -1 */
    grid-row: auto; /* убираем grid-row: span 2 */
    width: 207%; /* стандартная ширина */
    margin-left: 0;
    margin-right: 0;
  }

  /* Все карточки имеют одинаковую высоту изображения */
  .card-image,
  .collection-product-card.large .card-image {
    width: 100%;
    height: 400px;
    border-radius: 15px;
  }

  /* Все изображения одинакового размера */
  .card-image img,
  .collection-product-card.large .card-image img {
    width: 100%;
    height: 220px;
  }

  .full-width-banner {
    height: 500px;
  }

  .banner-content h2 {
    font-size: 32px;
  }

  .favorite-btn i {
    font-size: 20px;
  }

  .carousel-indicators {
    gap: 8px;
    bottom: 15px;
  }

  .carousel-indicators span,
  .collection-product-card.large .carousel-indicators span {
    width: 30px;
    height: 2px;
  }

  .carousel-indicators span:hover,
  .carousel-indicators span.active,
  .collection-product-card.large .carousel-indicators span:hover,
  .collection-product-card.large .carousel-indicators span.active {
    width: 45px;
  }

  .product-info h3,
  .product-info .code,
  .product-info .price-label,
  .product-info .price {
    font-size: 16px;
  }

  .nav-buttons button {
    min-width: 60px;
    min-height: 70px;
    padding: 8px;
    border-radius: 10px;
    font-size: 12px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    gap: 6px;
  }

  .nav-buttons button img {
    width: 18px;
    height: 18px;
  }
}

@media only screen and (max-width: 390px) {
  .collection-container {
    padding: 8px;
  }
      .code{
        display: none;
    }
  /* Обычные карточки - 2 в ряду */
  .row-1,
  .row-2,
  .row-3,
  .row-4 {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  /* ИСПРАВЛЕНИЕ: все карточки одинакового размера */
  .collection-product-card.large {
    grid-column: auto;
    grid-row: auto;
    width: 204%;
    margin: 0;
  }

  .collection-product-card.large .product-info {
    height: 60px;
    padding: 0 0px;
  }

  /* Все карточки одинаковой высоты */
  .card-image,
  .collection-product-card.large .card-image {
    height: 320px;
    border-radius: 10px;
  }

  /* Все изображения одинакового размера */
  .card-image img,
  .collection-product-card.large .card-image img {
    width: 160px;
    height: 160px;
  }

  .product-info h3,
  .product-info .code,
  .product-info .price-label,
  .product-info .price {
    font-size: 13px;
    line-height: 15px;
  }
}