/* Bontoy: Sales */

.bon-sales-module,
.bon-sales-page {
  --bon-sales-accent: #ae43e3;
  --bon-sales-accent-soft: #f1d9fb;
  --bon-sales-text: #222222;
  --bon-sales-muted: #8c8c8c;
  --bon-sales-gap: 12px;
}

.bon-sales-module {
  width: 100%;
  margin: 48px 0;
}

.bon-sales-module *,
.bon-sales-page * {
  box-sizing: border-box;
}

.bon-sales-module__header {
  margin-bottom: 28px;
  text-align: center;
}

.bon-sales-module__title,
.bon-sales-page__title {
  margin: 0;
  color: var(--bon-sales-text);
  font-size: 30px;
  font-weight: 500;
  line-height: 1.2;
  text-align: flex-start;
}

.bon-sales-module__title a {
  color: inherit;
  text-decoration: none;
}

.bon-sales-slider {
  position: relative;
  width: 100%;
  padding: 0 44px;
}

.bon-sales-slider__viewport {
  width: 100%;
  overflow: hidden;
}

.bon-sales-slider__track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - (var(--bon-sales-gap) * 2)) / 3);
  gap: var(--bon-sales-gap);
  transition: transform 0.35s ease;
  will-change: transform;
}

.bon-sale-card {
  min-width: 0;
}

.bon-sale-card__image-link {
  display: block;
  overflow: hidden;
  width: 100%;
  border-radius: 14px;
  background: #f6f6f6;
}

.bon-sale-card__image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 1;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.bon-sale-card__image-link:hover .bon-sale-card__image {
  transform: scale(1.02);
}

.bon-sale-card__name {
  font-family: var(--bon-font-medium);
  display: flex;
  align-items: center;
  margin: 5px 0 5px;
  min-height: 44px;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.3;
}

.bon-sale-card__name a {
  display: -webkit-box;
  overflow: hidden;
  color: var(--bon-sales-text);
  text-decoration: none;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.bon-sale-card__badge {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 7px 14px;
  border-radius: 8px;
  color: var(--bon-sales-accent);
  background: var(--bon-sales-accent-soft);
  font-size: 12px;
  font-weight: 400;
  line-height: 1;
  text-decoration: none;
}

.bon-sale-card__badge:hover,
.bon-sale-card__badge:focus {
  color: var(--bon-sales-accent);
  text-decoration: none;
}

.bon-sales-slider__arrow {
  position: absolute;
  z-index: 2;
  top: 50%;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid #d9d9d9;
  border-radius: 50%;
  color: #222222;
  background: #ffffff;
  transform: translateY(-70%);
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.bon-sales-slider__arrow::before,
.bon-sales-slider__arrow::after {
  content: "";
  position: absolute;
  top: 50%;
}

.bon-sales-slider__arrow::after {
  width: 13px;
  height: 1px;
  background: currentColor;
}

.bon-sales-slider__arrow::before {
  width: 7px;
  height: 7px;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
}

.bon-sales-slider__arrow--prev {
  left: 0;
}

.bon-sales-slider__arrow--prev::after {
  left: 11px;
}

.bon-sales-slider__arrow--prev::before {
  left: 10px;
  transform: translateY(-50%) rotate(-135deg);
}

.bon-sales-slider__arrow--next {
  right: 0;
  color: #ffffff;
  border-color: var(--bon-sales-accent);
  background: var(--bon-sales-accent);
}

.bon-sales-slider__arrow--next::after {
  right: 11px;
}

.bon-sales-slider__arrow--next::before {
  right: 10px;
  transform: translateY(-50%) rotate(45deg);
}

.bon-sales-slider__arrow:disabled {
  opacity: 0.35;
  cursor: default;
}

.bon-sales-slider__dots {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-top: 14px;
}

.bon-sales-slider__dot {
  width: 6px;
  height: 6px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #e0b8f1;
}

.bon-sales-slider__dot.is-active {
  background: var(--bon-sales-accent);
}

.bon-sales-page {
  padding-top: 10px;
  padding-bottom: 50px;
}

.bon-sales-page__title {
  margin: 0 0 20px;
}

.bon-sales-page__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px 14px;
}

.bon-sales-page__pagination {
  margin-top: 36px;
}

.bon-sale-catalog-banner {
  overflow: hidden;
  width: 100%;
  margin: 0 0 30px;
  border-radius: 16px;
}

.bon-sale-catalog-banner img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 520px;
  object-fit: cover;
}

.bon-sale-catalog-description {
  margin-bottom: 28px;
}

@media (max-width: 991px) {
  .bon-sales-slider__track,
  .bon-sales-page__grid {
    grid-auto-columns: calc((100% - var(--bon-sales-gap)) / 2);
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .bon-sales-module {
    margin: 34px 0;
  }

  .bon-sales-module__header {
    margin-bottom: 18px;
  }

  .bon-sales-module__title,
  .bon-sales-page__title {
    font-size: 24px;
  }

  .bon-sales-slider {
    padding: 0;
  }

  .bon-sales-slider__track {
    grid-auto-columns: 100%;
    gap: 0;
  }

  .bon-sales-slider__arrow {
    display: none;
  }

  .bon-sales-slider__dots {
    display: flex;
  }

  .bon-sale-card__image-link {
    border-radius: 10px;
  }

  .bon-sale-card__name {
    min-height: 0;
    margin-top: 14px;
    font-size: 15px;
  }

  .bon-sale-card__badge {
    min-height: 34px;
    padding: 8px 16px;
  }

  .bon-sales-page__grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .bon-sale-catalog-banner {
    margin-bottom: 20px;
    border-radius: 10px;
  }
}

/* =========================================
   Sales page: first two cards are 50% wide
   ========================================= */

@media (min-width: 992px) {
  .bon-sales-page__grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .bon-sales-page__grid > .bon-sale-card:nth-child(-n + 2) {
    grid-column: span 3;
  }

  .bon-sales-page__grid > .bon-sale-card:nth-child(n + 3) {
    grid-column: span 2;
  }
}

/* =========================================
   Sale page hero
   ========================================= */

.bon-sale-hero {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 28px;
  width: 100%;
}

.bon-sale-hero__media {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 330px;
  max-height: 330px;
  overflow: hidden;
  border-radius: 16px;
  background: #f7f7f7;
}

.bon-sale-hero__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.bon-sale-hero__content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  min-width: 0;
  padding: 24px 12px 24px 0;
}

.bon-sale-hero__title {
  margin: 0 0 18px;
  color: #252525;
  font-size: 24px;
  font-weight: 500;
  line-height: 1.2;
}

.bon-sale-hero__badge {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  margin: 0 0 20px;
  padding: 7px 14px;
  border-radius: 8px;
  color:  var(--bon-color-primary);
  background: #A54BD933;
  font-size: 13px;
  font-weight: 400;
  line-height: 1;
}

.bon-sale-hero__description {
  font-family: var(--bon-font-light);
  max-width: 620px;
  color:  var(--bon-color-muted);
  font-size: 15px;
  font-weight: 300;
  line-height: 25px;
}

.bon-sale-hero__description > :first-child {
  margin-top: 0;
}

.bon-sale-hero__description > :last-child {
  margin-bottom: 0;
}

.bon-sale-hero__description p {
  margin: 0 0 14px;
}

@media (max-width: 991px) {
  .bon-sale-hero {
    gap: 22px;
  }

  .bon-sale-hero__media {
    height: 280px;
    max-height: 280px;
  }

  .bon-sale-hero__title {
    font-size: 26px;
  }
}

@media (max-width: 767px) {
  .bon-sale-hero {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-bottom: 28px;
  }

  .bon-sale-hero__media {
    width: 100%;
    height: auto;
    max-height: none;
    aspect-ratio: 2.15 / 1;
    border-radius: 12px;
  }

  .bon-sale-hero__content {
    width: 100%;
    padding: 0;
  }

  .bon-sale-hero__title {
    margin-bottom: 12px;
    font-size: 22px;
  }

  .bon-sale-hero__badge {
    margin-bottom: 14px;
  }

  .bon-sale-hero__description {
    font-size: 13px;
    line-height: 1.5;
  }
}
