/* Category page banner: styles live in components/category-page-banner.jinja (IBS parity). */

/* ─── Breadcrumb — match PDP pd-info-toolbar--bc-bar (cream bar) ─── */
.ath-cat-page .breadcrumb-section,
body.ath-bc-bar .ath-cat-page .breadcrumb-section,
body.ath-bc-bar .ath-cat-page.ath-cat-page--theme-bg .breadcrumb-section,
body:not(.ath-bc-bar) .ath-cat-page.ath-cat-page--theme-bg .breadcrumb-section {
  margin: 0;
  width: 100%;
  max-width: none;
  border-bottom: none;
  padding: 30px 16px !important;
  background: #fef8f3 !important;
  background-color: #fef8f3 !important;
  box-sizing: border-box;
}
.ath-cat-page .breadcrumb {
  margin-bottom: 0;
  background: transparent;
  padding: 0;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  width: 100%;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #002e2d;
}
.ath-cat-page .breadcrumb-item,
.ath-cat-page .breadcrumb-item a,
.ath-cat-page .breadcrumb-item a:hover,
.ath-cat-page .breadcrumb-item.active {
  color: #002e2d;
  text-decoration: none;
  font-weight: 500;
  font-size: inherit;
}
.ath-cat-page .breadcrumb-item + .breadcrumb-item::before {
  content: "/";
  color: #002e2d;
  opacity: 1;
  font-weight: 500;
  padding-inline: 0.35rem;
  float: none;
}

/* Theme Colors → Background by page → Categories */
.ath-cat-page.ath-cat-page--theme-bg {
  background: var(--ath-cat-page-bg);
}
/* ─── Category page head: title + flex-wrap tabs (no images) ─── */
.ath-cat-head {
  padding: 20px 0 8px;
}
@media (min-width: 768px) {
  .ath-cat-head {
    padding: 28px 0 12px;
  }
}
.ath-cat-head__title {
  margin: 0 0 16px;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 26px;
  font-weight: 700;
  line-height: 1.25;
  color: #002e2d;
  text-align: start;
}
@media (min-width: 768px) {
  .ath-cat-head__title {
    margin-bottom: 20px;
    font-size: 32px;
    font-weight: 900;
  }
}

.ath-cat-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px 10px;
  margin: 0 0 8px;
  padding: 0 0 16px;
  border-bottom: 1px solid #ececec;
}
@media (min-width: 768px) {
  .ath-cat-tabs {
    gap: 10px 12px;
    padding-bottom: 20px;
  }
}

.ath-cat-tabs__item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  flex: 0 0 auto;
  min-height: 40px;
  padding: 10px 16px;
  border: 1px solid #d9d9d9;
  border-radius: 8px;
  background: #ffffff;
  color: #002e2d;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.35;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  max-width: 100%;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}
.ath-cat-tabs__item:hover {
  border-color: #002e2d;
  color: #002e2d;
  text-decoration: none;
}
.ath-cat-tabs__item.is-active {
  background: #002e2d;
  border-color: #002e2d;
  color: #ffffff;
}
.ath-cat-tabs__item.is-active:hover {
  background: #002e2d;
  border-color: #002e2d;
  color: #ffffff;
}
@media (min-width: 768px) {
  .ath-cat-tabs__item {
    min-height: 44px;
    padding: 11px 18px;
    font-size: 15px;
  }
}

/* ─── Empty category / subcategory — Coming Soon (single centered line) ─── */
.ath-shop-top__result-p--empty-hidden {
  visibility: hidden;
  min-height: 1em;
}
.ath-cat-soon {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: clamp(220px, 36vh, 360px);
  padding: 48px 20px;
  text-align: center;
}
.ath-cat-soon__text {
  margin: 0;
  font-family: var(--ath-body-font-family, inherit);
  font-size: clamp(22px, 3.2vw, 32px);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.02em;
  color: #002e2d;
}

/* ─── Products page: category circles strip ─── */
.ath-pl-cats {
  padding-top: 1.5rem;
  padding-bottom: 0.5rem;
}
.ath-pl-cats[hidden] {
  display: none !important;
}
.ath-pl-cats__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 16px;
  justify-items: center;
}
@media (min-width: 768px) {
  .ath-pl-cats__grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    gap: 28px 48px;
  }
}
@media (min-width: 1200px) {
  .ath-pl-cats__grid {
    gap: 32px 64px;
  }
}
.ath-pl-cats__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
  max-width: 150px;
  width: 100%;
  transition: opacity 0.2s ease;
}
.ath-pl-cats__card:hover {
  opacity: 0.92;
  text-decoration: none;
  color: inherit;
}
.ath-pl-cats__thumb {
  /* Fixed equal sides — avoid aspect-ratio stretching into ovals */
  width: 150px;
  height: 150px;
  max-width: 100%;
  border-radius: 50%;
  overflow: hidden;
  background: color-mix(in srgb, var(--primary-color, #57837f) 12%, #f5f5f5);
  flex-shrink: 0;
}
.ath-pl-cats__thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.35s ease;
}
.ath-pl-cats__card:hover .ath-pl-cats__thumb img {
  transform: scale(1.04);
}
.ath-pl-cats__name {
  margin: 0;
  padding: 0 4px;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.35;
  text-align: center;
  color: var(--primary-color, #57837f);
  word-break: break-word;
}
@media (min-width: 768px) {
  .ath-pl-cats__name {
    font-size: 18px;
  }
}
@media (min-width: 1200px) {
  .ath-pl-cats__name {
    font-size: 20px;
  }
}

/* Carousel (Slick) — mobile shows 2; desktop row of circles */
.ath-pl-cats--carousel .ath-pl-cats__slider {
  margin: 0 -6px;
}
.ath-pl-cats--carousel .ath-pl-cats__slider.slick-initialized {
  margin: 0;
}
.ath-pl-cats--carousel .ath-pl-cats__slide {
  padding: 0 8px;
}
.ath-pl-cats--carousel .ath-pl-cats__card {
  margin: 0 auto;
}
@media (max-width: 767.98px) {
  .ath-pl-cats--carousel.category-page-slider .categories-slider.slick-initialized,
  .ath-pl-cats--carousel .categories-slider.slick-initialized {
    overflow: visible !important;
    white-space: normal !important;
    height: auto !important;
  }
  .ath-pl-cats--carousel .categories-slider.slick-initialized .category-item,
  .ath-pl-cats--carousel .categories-slider.slick-initialized .cat-col {
    width: auto !important;
    max-width: none;
    display: block !important;
    vertical-align: unset !important;
  }
  .ath-pl-cats--carousel .categories-slider.slick-initialized .cat-col {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  .ath-pl-cats--carousel .ath-pl-cats__card {
    max-width: none;
  }
  .ath-pl-cats__thumb {
    width: 110px;
    height: 110px;
  }
}
@media (max-width: 575.98px) {
  .ath-pl-cats--carousel .slick-arrow {
    display: none !important;
  }
}
.ath-pl-cats--carousel .slick-arrow {
  width: 40px;
  height: 40px;
  z-index: 2;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95) !important;
  box-shadow: 0 2px 12px rgba(26, 26, 26, 0.1);
}
.ath-pl-cats--carousel .slick-arrow:before {
  display: none;
}
.ath-pl-cats--carousel .slick-arrow span {
  font-size: 20px;
  line-height: 40px;
  color: #1a1a1a;
  display: block;
  text-align: center;
}
.ath-pl-cats--carousel .slick-prev {
  left: 4px;
}
.ath-pl-cats--carousel .slick-next {
  right: 4px;
}

/* ─── Products area ─── */
.ath-cat-page .products-container {
  padding-top: 1.25rem !important;
}

/* ─── All categories index — Figma 353:2325 / 356:2187 ─── */
/* Keep side gutters — shorthand padding: … 0 … was wiping .main-container x-padding */
.ath-cat-index__wrap {
  padding-top: 26px;
  padding-bottom: 48px;
  padding-left: max(16px, var(--theme-main-container-gutter-x, 16px));
  padding-right: max(16px, var(--theme-main-container-gutter-x, 16px));
}
@media (min-width: 992px) {
  .ath-cat-index__wrap {
    padding-top: 96px;
    padding-bottom: 96px;
    padding-left: var(--theme-main-container-gutter-x, 16px);
    padding-right: var(--theme-main-container-gutter-x, 16px);
  }
}

.ath-cat-index__head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  margin-bottom: 20px;
  padding-bottom: 8px;
  width: 100%;
}
@media (min-width: 992px) {
  .ath-cat-index__head {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 48px;
    padding-bottom: 0;
  }
}

.ath-cat-index__titles {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  width: 100%;
}
@media (min-width: 992px) {
  .ath-cat-index__titles {
    gap: 8px;
    width: auto;
  }
}

.ath-cat-index__kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
@media (min-width: 992px) {
  .ath-cat-index__kicker {
    gap: 10px;
  }
}

.ath-cat-index__kicker-line {
  display: block;
  width: 24px;
  height: 1.5px;
  background: #c79667;
  flex-shrink: 0;
}
@media (min-width: 992px) {
  .ath-cat-index__kicker-line {
    width: 28px;
  }
}

.ath-cat-index__kicker-text {
  margin: 0;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  color: #c79667;
  white-space: nowrap;
}

.ath-cat-index__title {
  margin: 0;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.3;
  color: #0e4a44;
  text-align: start;
}
@media (min-width: 992px) {
  .ath-cat-index__title {
    font-size: 36px;
    font-weight: 900;
    line-height: normal;
    color: #002e2d;
  }
}

.ath-cat-index__all {
  display: none;
  align-items: center;
  gap: 6px;
  color: #c79667;
  text-decoration: none;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 14px;
  font-weight: 500;
  line-height: normal;
  white-space: nowrap;
}
.ath-cat-index__all:hover {
  color: #c79667;
  opacity: 0.85;
  text-decoration: none;
}
@media (min-width: 992px) {
  .ath-cat-index__all {
    display: inline-flex;
  }
}
.ath-cat-index__all-icon {
  display: block;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
/* Arrow art points left (RTL). Flip for English LTR. */
html[dir="ltr"] .ath-cat-index__all-icon,
[dir="ltr"] .ath-cat-index__all-icon {
  transform: scaleX(-1);
}

.ath-cat-index__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 12px;
  justify-items: center;
  align-items: start;
  width: 100%;
}
@media (min-width: 992px) {
  .ath-cat-index__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px 24px;
  }
}

/* Center the last odd card on mobile (Figma lone accessories card) */
@media (max-width: 991.98px) {
  .ath-cat-index__card:last-child:nth-child(odd) {
    grid-column: 1 / -1;
    justify-self: center;
    width: calc((100% - 12px) / 2);
    max-width: 173px;
  }
}

.ath-cat-index__card {
  position: relative;
  display: block;
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.ath-cat-index__frame {
  box-sizing: border-box;
  width: 100%;
  /* Shorter than raw 384/516 so cards don't tower on wide screens */
  aspect-ratio: 4 / 5;
  border: 1px solid rgba(199, 150, 103, 0.5);
  /* Full half-capsule top — matches Figma arch at any card width */
  border-radius: 9999px 9999px 4px 4px;
  overflow: hidden;
  padding: clamp(4px, 1.8%, 7px);
  background: transparent;
  transition: border-color 0.35s ease, box-shadow 0.35s ease, transform 0.35s ease;
}
@media (min-width: 992px) {
  .ath-cat-index__frame {
    border-radius: 9999px 9999px 6px 6px;
  }
}
.ath-cat-index__card:hover .ath-cat-index__frame {
  border-color: rgba(199, 150, 103, 0.95);
  box-shadow: 0 18px 42px rgba(0, 46, 45, 0.16);
  transform: translateY(-4px);
}

.ath-cat-index__media {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 9999px 9999px 2px 2px;
  /* Soft plate — never solid ugly green fill */
  background: linear-gradient(180deg, #f4f6f5 0%, #e4e9e6 48%, #c5d0cc 100%);
}

.ath-cat-index__img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  border-radius: inherit;
  pointer-events: none;
  image-rendering: auto;
  -ms-interpolation-mode: bicubic;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  transform: translateZ(0) scale(1);
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}
.ath-cat-index__card:hover .ath-cat-index__img {
  transform: scale(1.07);
}
.ath-cat-index__img--empty {
  background: linear-gradient(180deg, #f7f8f7 0%, #e7ece9 42%, #cfd8d4 100%);
}

.ath-cat-index__shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  border-radius: inherit;
  background: linear-gradient(
    180deg,
    rgba(0, 46, 45, 0) 42%,
    rgba(0, 46, 45, 0.55) 72%,
    rgba(0, 46, 45, 0.92) 100%
  );
  transition: background 0.35s ease;
}
@media (min-width: 992px) {
  .ath-cat-index__shade {
    background: linear-gradient(
      180deg,
      rgba(0, 46, 45, 0) 40%,
      rgba(0, 46, 45, 0.58) 70%,
      rgba(0, 46, 45, 0.94) 100%
    );
  }
}
.ath-cat-index__card:hover .ath-cat-index__shade {
  background: linear-gradient(
    180deg,
    rgba(0, 46, 45, 0) 36%,
    rgba(0, 46, 45, 0.62) 68%,
    rgba(0, 46, 45, 0.96) 100%
  );
}

.ath-cat-index__content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 0 10px 14px;
  pointer-events: none;
  transition: transform 0.35s ease;
}
@media (min-width: 992px) {
  .ath-cat-index__content {
    gap: 16px;
    padding: 0 22px 24px;
  }
}
.ath-cat-index__card:hover .ath-cat-index__content {
  transform: translateY(-3px);
}

.ath-cat-index__name {
  margin: 0;
  width: 100%;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.35;
  color: #ffffff;
  text-align: center;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.18);
}
@media (min-width: 992px) {
  .ath-cat-index__name {
    font-size: 26px;
    line-height: 1.2;
    white-space: normal;
  }
}

/* Subcategory chips — desktop only; show ALL (no +N truncation) */
.ath-cat-index__subs {
  display: none;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  align-content: center;
  gap: 8px;
  width: 100%;
  max-width: 320px;
}
@media (min-width: 992px) {
  .ath-cat-index__subs {
    display: flex;
  }
}

.ath-cat-index__chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.3;
  text-decoration: none;
  text-align: center;
  white-space: nowrap;
  pointer-events: auto;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.ath-cat-index__chip:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.45);
  color: #ffffff;
  text-decoration: none;
  transform: translateY(-1px);
}
.ath-cat-index__chip--static {
  cursor: default;
}

.ath-cat-index__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 4px;
  background: #ffffff;
  color: #002e2d;
  font-family: var(--ath-body-font-family, inherit);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  text-decoration: none;
  white-space: nowrap;
  pointer-events: auto;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.ath-cat-index__cta:hover {
  color: #002e2d;
  background: #fff;
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(0, 46, 45, 0.16);
}
@media (min-width: 992px) {
  .ath-cat-index__cta {
    padding: 9px 18px;
    font-size: 14px;
    font-weight: 700;
    line-height: normal;
  }
}
.ath-cat-index__cta--disabled {
  opacity: 0.7;
  cursor: default;
  pointer-events: none;
}
.ath-cat-index__cta-icon {
  display: block;
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}
html[dir="ltr"] .ath-cat-index__cta-icon,
[dir="ltr"] .ath-cat-index__cta-icon {
  transform: scaleX(-1);
}
@media (min-width: 992px) {
  .ath-cat-index__cta-icon {
    width: 18px;
    height: 18px;
  }
}

.ath-cat-index__hit {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
}

/* ═══ Product listing grid (products + category templates) ═══════════ */
.products-container .ath-products-grid {
  display: grid;
  grid-template-columns: repeat(var(--ath-pl-cols-xs, 2), minmax(0, 1fr));
  gap: clamp(12px, 2.2vw, 20px);
  margin-bottom: 24px;
  width: 100%;
  align-items: stretch;
}

@media (min-width: 768px) {
  .products-container .ath-products-grid {
    grid-template-columns: repeat(var(--ath-pl-cols-sm, 3), minmax(0, 1fr));
  }
}

@media (min-width: 992px) {
  .products-container .ath-products-grid {
    grid-template-columns: repeat(var(--ath-pl-cols-md, 4), minmax(0, 1fr));
  }
}

@media (min-width: 1200px) {
  .products-container .ath-products-grid {
    grid-template-columns: repeat(var(--ath-pl-cols-lg, 5), minmax(0, 1fr));
  }
}

/*
 * Do NOT set height:100% on grid items — % of an auto-sized grid resolves to auto
 * and breaks row stretch. Default stretch + flex column fills the tallest card.
 */
.ath-products-grid__item {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-self: stretch;
}

.ath-products-grid__item > .product-item,
.ath-products-grid__item > .product-item.pc {
  width: 100%;
  max-width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  align-self: stretch;
  display: flex;
  flex-direction: column;
}
