/* Brand CMS layout — sized like PHP brand_details + influencer reels */

.brand-layout-section,
.brand-banners-section,
#fixed-header.brand-subnav {
  overflow-x: clip;
  overflow-y: visible;
}

/* Keep Bootstrap .container max-widths on desktop; only box-sizing + padding safety */
.brand-layout-section .container,
.brand-banners-section .container,
#fixed-header.brand-subnav > .container {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

.brand-layout-section {
  margin: 12px 0 20px;
}

.brand-layout-section .storefront-carousel,
.brand-layout-section .storefront-carousel__viewport {
  max-width: 100%;
  overflow-x: hidden;
  overflow-y: visible;
}

/* Product rails — keep card bottoms (buttons/shadow) inside the clip box */
.brand-layout-section--product .storefront-carousel,
.brand-layout-section--product .storefront-carousel__viewport {
  padding-bottom: 14px;
  box-sizing: content-box;
}

.brand-layout-section--product .storefront-carousel__slide,
.brand-layout-section--product .storefront-carousel__native-slide {
  padding-bottom: 10px;
  height: auto;
}

.brand-layout-section .storefront-carousel__container {
  /* Avoid negative gap margin pushing past the page edge */
  margin-left: 0;
}

.brand-layout-section .storefront-carousel__slide {
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.brand-layout-section img,
.brand-banners__tile img,
.brand-media__img,
.brand-media__thumb-video,
.banner-size {
  max-width: 100% !important;
  box-sizing: border-box;
}

.brand-layout-section .title-dc {
  margin-bottom: 15px;
}

/* Match PHP custom.css .product-sectionz .title-dc h2 (Playfair, not bold caps) */
.brand-layout-section .title-dc h2 {
  font-size: 1.49rem;
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 400;
  letter-spacing: 1px;
  color: #1f1f1f;
  margin: 0;
  text-transform: capitalize;
}

/* PHP .slider-6 — six product cards across on desktop only */
@media (min-width: 693px) {
  .brand-layout-section--size-6 .storefront-carousel {
    --sf-slides-per-view: 6;
    --sf-gap: 10px;
  }
}

@media (min-width: 693px) and (max-width: 1124px) {
  .brand-layout-section--size-6 .storefront-carousel {
    --sf-slides-per-view: 5;
  }
}

@media (min-width: 693px) and (max-width: 900px) {
  .brand-layout-section--size-6 .storefront-carousel {
    --sf-slides-per-view: 4;
  }
}

/*
 * Mobile brand product rails — match PHP brand_details.php @max-width 684px:
 * .slider-3 / .slider-4 / .slider-6 > div { width: 46%; min-width: 45%; }
 * (~2 cards visible, not home's 1.5 or category's ~30%)
 */
@media (max-width: 684px) {
  .brand-layout-section--product .storefront-carousel {
    width: 100%;
    max-width: 100%;
    --sf-slides-per-view: 2.15;
    --sf-gap: 10px;
  }

  .brand-layout-section--product .storefront-carousel,
  .brand-layout-section--product .storefront-carousel__viewport {
    overflow-x: hidden;
    overflow-y: visible;
    padding-bottom: 16px;
  }

  .brand-layout-section--product .storefront-carousel--native-scroll .storefront-carousel__native-track {
    width: 100%;
    max-width: 100%;
    gap: 0;
    padding: 0 0 14px;
    margin: 0;
    overflow-x: auto !important;
    overflow-y: visible !important;
    -webkit-overflow-scrolling: touch;
  }

  .brand-layout-section--product .storefront-carousel--native-scroll .storefront-carousel__native-slide {
    width: 46% !important;
    min-width: 45% !important;
    max-width: 48%;
    flex: 0 0 auto !important;
    padding-bottom: 8px;
    box-sizing: border-box;
  }

  /* Embla before/without native-scroll — same ~2-up as PHP unslick */
  .brand-layout-section--product .storefront-carousel:not(.storefront-carousel--native-scroll) .storefront-carousel__slide {
    flex: 0 0 calc(100% / 2.15);
    max-width: calc(100% / 2.15);
    min-width: 0;
    padding-bottom: 12px;
  }

  .brand-layout-section--product .product-card-container {
    width: 100%;
    max-width: 100%;
    margin: 0.5rem !important;
    overflow: visible;
    box-sizing: border-box;
  }

  .brand-layout-section--product .product-card-content {
    min-height: 0 !important;
    padding-bottom: 10px !important;
  }

  .brand-layout-section--product .product-card-btns {
    flex-shrink: 0;
    gap: 6px;
    min-width: 0;
  }

  .brand-layout-section--product .product-card-btns .btn-notify-me,
  .brand-layout-section--product .product-card-btns .btn-pink {
    min-width: 0;
    flex: 1 1 auto;
    font-size: 12px;
    padding: 6px 8px;
  }
}

.brand-layout-slide {
  height: auto;
  display: flex;
  width: 100%;
}

.brand-layout-section--video .brand-layout-slide {
  height: auto;
  display: flex;
  justify-content: center;
}

/* Equal-height product cards in a rail (buttons align across the row) */
.brand-layout-section .storefront-carousel__container,
.brand-layout-section .storefront-carousel__native-track {
  align-items: stretch;
}

.brand-layout-section .storefront-carousel__slide,
.brand-layout-section .storefront-carousel__native-slide {
  display: flex;
  align-items: stretch;
}

.brand-layout-tile {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  height: 100%;
  box-shadow: 0 1px 3px rgba(17, 17, 24, 0.06);
}

.brand-layout-tile--hero {
  box-shadow: none;
  border-radius: 14px;
  width: 100%;
  margin: 0;
  height: auto;
}

.brand-layout-tile--reel {
  border-radius: 14px;
  width: 100%;
  max-width: min(243px, 100%);
  margin: 0 auto;
  background: #111;
  height: auto;
  overflow: hidden;
  box-sizing: border-box;
}

.brand-layout-tile__link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.brand-layout-tile__title {
  margin: 0;
  padding: 10px 8px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #333;
  text-align: center;
  line-height: 1.35;
}

.brand-layout-product {
  height: 100%;
  width: 100%;
  padding: 0;
  display: flex;
}

.brand-layout-product .product-card-container,
.brand-layout-product .product-box-5 {
  height: 100%;
  width: 100%;
  display: flex;
  flex-direction: column;
  overflow: visible;
  /* Prefer slide padding over large bottom margin so overflow clip doesn't cut buttons */
  margin-bottom: 0 !important;
}

/* Edge-to-edge product image (no globals.css 12px padding on legacy cards) */
.brand-layout-product .product-card-img,
.brand-layout-product .product-card-image {
  padding: 0 !important;
}

.brand-layout-product .product-card-image {
  width: 100%;
  display: block;
}

.brand-layout-product .product-card-content {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: auto;
  overflow: visible;
  padding-bottom: 12px !important;
}

/* Keep clear gap between price-drop pill and Notify Me / Add to Bag */
.brand-layout-product .product-card-btns {
  margin-top: auto;
  padding-top: 12px;
  flex-shrink: 0;
}

/* ---- Media shells ---- */
.brand-media {
  position: relative;
  display: block;
  width: 100%;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
  overflow: hidden;
}

/* Static CMS images — natural height (no black letterbox) */
.brand-media--hero,
.brand-media--landscape,
.brand-media--square {
  aspect-ratio: auto;
  max-height: none;
  height: auto;
  border-radius: 14px;
}

.brand-media--landscape,
.brand-media--square {
  border-radius: 10px;
}

/* Video posters / playing players keep a framed box */
.brand-media--lite.brand-media--hero,
.brand-media--lite.brand-media--landscape,
.brand-media--playing.brand-media--hero,
.brand-media--playing.brand-media--landscape {
  aspect-ratio: 16 / 9;
  max-height: min(480px, 56vw);
  background: #111;
}

.brand-media--lite.brand-media--landscape,
.brand-media--playing.brand-media--landscape {
  max-height: 320px;
}

.brand-media--reel,
.brand-media--lite.brand-media--reel,
.brand-media--playing.brand-media--reel {
  aspect-ratio: 9 / 16;
  width: 100%;
  max-width: min(243px, 100%);
  max-height: 426px;
  min-height: 0;
  margin: 0 auto;
  border-radius: 14px;
  background: #111;
  position: relative;
  box-sizing: border-box;
}

/* In-flow poster so the reel shell cannot collapse to 0 height */
.brand-media--reel:not(.brand-media--playing) .brand-media__img,
.brand-media--reel:not(.brand-media--playing) .brand-media__thumb-video {
  position: static !important;
  inset: auto !important;
  display: block;
  width: 100%;
  height: auto !important;
  aspect-ratio: 9 / 16;
  max-height: 426px;
  object-fit: cover;
}

.brand-media--lite.brand-media--square,
.brand-media--playing.brand-media--square {
  aspect-ratio: 1 / 1;
  max-height: 360px;
  border-radius: 10px;
  background: #111;
}

.brand-media--playing {
  cursor: default;
  background: #000;
}

.brand-media__img,
.brand-media__thumb-video,
.brand-media__frame,
.brand-media__video {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  border: 0;
}

/* Fill framed video shells (non-reel posters / playing players) */
.brand-media--lite:not(.brand-media--reel) .brand-media__img,
.brand-media--lite:not(.brand-media--reel) .brand-media__thumb-video,
.brand-media--playing .brand-media__frame,
.brand-media--playing .brand-media__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100% !important;
  object-fit: cover;
}

.brand-media--playing .brand-media__frame,
.brand-media--playing .brand-media__video {
  object-fit: contain;
}

.brand-media__play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 56px;
  height: 56px;
  margin: -28px 0 0 -28px;
  border-radius: 50%;
  background: rgba(136, 1, 62, 0.92);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.28);
  pointer-events: none;
  z-index: 2;
}

.brand-media--hero .brand-media__play {
  width: 64px;
  height: 64px;
  margin: -32px 0 0 -32px;
}

.brand-media__play::before {
  content: "";
  position: absolute;
  left: 22px;
  top: 18px;
  border-style: solid;
  border-width: 10px 0 10px 16px;
  border-color: transparent transparent transparent #fff;
}

.brand-media--hero .brand-media__play::before {
  left: 26px;
  top: 20px;
  border-width: 12px 0 12px 18px;
}

.brand-media__badge {
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  background: rgba(17, 17, 24, 0.82);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 999px;
  pointer-events: none;
  z-index: 2;
}

.brand-media__ig-ph {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: 180px;
  color: #fff;
  font-weight: 700;
}

.brand-share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 40px;
  padding: 0 14px;
  border: 1px solid rgba(136, 1, 62, 0.25);
  border-radius: 999px;
  background: #fff;
  color: #88013e;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}

.brand-share-btn:hover {
  background: rgba(136, 1, 62, 0.06);
}

@media (max-width: 767.98px) {
  .brand-share-btn {
    width: 40px;
    min-width: 40px;
    padding: 0;
  }
}

/* Brand banners (top strip) — same shell as hero CMS tiles */
.brand-banners-section {
  margin: 16px 0 12px;
  padding: 0;
}

.brand-banners {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  margin: 0;
  gap: 12px;
}

.brand-banners__item {
  flex: 1 1 0;
  min-width: 0;
}

.brand-banners__item--solo {
  flex: 1 1 100%;
}

.brand-banners__tile {
  display: block;
  width: 100%;
  border-radius: 14px;
  overflow: hidden;
  background: transparent;
  text-decoration: none;
}

.brand-banners__tile img,
.brand-banners__tile .banner-size {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: auto;
  max-height: none;
  object-fit: contain;
}

/* Brand category menu — same Bootstrap .container as banners/hero */
#fixed-header.brand-subnav {
  position: sticky;
  z-index: 20;
  background: #fff;
  border-bottom: 1px solid rgba(136, 1, 62, 0.12);
  box-shadow: 0 4px 16px rgba(15, 17, 17, 0.06);
}

#fixed-header.brand-subnav > .container {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 16px;
  padding-right: 16px;
}

/* Product grid cards on brand PLP */
.brand-product-col {
  margin-bottom: 12px;
}

.brand-product-col .product-card-container,
.brand-product-col .product-box-5 {
  height: 100%;
}

@media (min-width: 768px) {
  .brand-share-btn {
    display: none;
  }
}

@media (max-width: 767.98px) {
  .brand-media--hero,
  .brand-media--landscape,
  .brand-media--square {
    max-height: none;
    max-width: 100%;
    border-radius: 10px;
  }

  .brand-media--lite.brand-media--hero,
  .brand-media--playing.brand-media--hero {
    max-height: min(280px, 58vw);
  }

  .brand-media--lite.brand-media--landscape,
  .brand-media--playing.brand-media--landscape {
    max-height: 220px;
  }

  .brand-media--reel,
  .brand-media--lite.brand-media--reel,
  .brand-media--playing.brand-media--reel {
    max-height: 380px;
    min-height: 0;
    max-width: min(200px, 100%);
  }

  .brand-media--reel:not(.brand-media--playing) .brand-media__img,
  .brand-media--reel:not(.brand-media--playing) .brand-media__thumb-video {
    max-height: 380px;
  }

  .brand-layout-tile--reel {
    max-width: min(200px, 100%);
  }

  .brand-layout-tile--hero {
    border-radius: 10px;
    max-width: 100%;
  }

  .brand-banners__tile {
    border-radius: 10px;
    max-width: 100%;
  }

  .brand-banners__tile img,
  .brand-banners__tile .banner-size {
    max-height: none;
    max-width: 100%;
    height: auto;
  }

  /* Brand reels rail — keep slides inside the viewport */
  .brand-layout-section .sf-carousel--reels .storefront-carousel__slide {
    flex: 0 0 calc(100% / 2.15);
    max-width: calc(100% / 2.15);
  }

  #fixed-header.brand-subnav > .container {
    padding-left: 12px;
    padding-right: 12px;
  }

  #fixed-header.brand-subnav .row {
    margin-left: 0;
    margin-right: 0;
    --bs-gutter-x: 8px;
    max-width: 100%;
  }

  #fixed-header.brand-subnav [class*="col-"] {
    padding-left: 4px;
    padding-right: 4px;
    min-width: 0;
  }

  #fixed-header .brand-search {
    max-width: 100%;
    min-width: 0;
  }
}

/* Brand details subnav / search / filters (moved from inline <style> to avoid hydration mismatch) */
#fixed-header {
  position: sticky;
  z-index: 20;
  border-bottom: 1px solid rgba(136, 1, 62, 0.12);
  box-shadow: 0 4px 16px rgba(15, 17, 17, 0.06);
  backdrop-filter: saturate(1.1);
}

.brand-search {
  box-shadow: inset 0 1px 2px rgba(15, 17, 17, 0.08);
  padding: 8px 36px 8px 14px;
  border-radius: 10px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.brand-search:focus {
  outline: none;
  border-color: rgba(136, 1, 62, 0.45);
  box-shadow: 0 0 0 3px rgba(136, 1, 62, 0.12);
}

.search-icon {
  top: 9px;
  right: 14px;
  border: none;
  font-size: 15px;
  color: #555;
}

#fixed-header .navbar-collapse ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 4px 0;
  gap: 4px 2px;
}

#fixed-header .nav-item {
  position: relative;
}

#fixed-header .nav-link,
#fixed-header .sub-nav-drop {
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-transform: capitalize;
  white-space: nowrap;
  color: #2a2a2a;
  padding: 8px 12px !important;
  border-radius: 999px;
  transition: background-color 0.18s ease, color 0.18s ease;
  background: #f1f1f1;
}

#fixed-header .nav-link:hover,
#fixed-header .sub-nav-drop:hover,
#fixed-header .nav-link:focus-visible,
#fixed-header .sub-nav-drop:focus-visible {
  background: rgba(136, 1, 62, 0.08);
  color: #88013e;
  outline: none;
}

#fixed-header .dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 1000;
  min-width: 260px;
  max-height: min(70vh, 420px);
  overflow-y: auto;
  padding: 8px;
  background: #fff;
  border: 1px solid rgba(136, 1, 62, 0.1);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(15, 17, 17, 0.12);
  scrollbar-width: thin;
  scrollbar-color: rgba(136, 1, 62, 0.35) transparent;
}

#fixed-header .dropdown-menu.show {
  display: block;
  animation: brand-dd-in 0.16s ease-out;
}

@keyframes brand-dd-in {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  #fixed-header .dropdown-menu.show {
    animation: none;
  }
}

#fixed-header a.dropdown-toggle::before {
  display: none !important;
}

#fixed-header .dropdown-item {
  border-radius: 8px;
  padding: 10px 12px !important;
  font-size: 13.5px;
  font-weight: 500;
  color: #333;
  transition: background-color 0.15s ease, color 0.15s ease;
}

#fixed-header .dropdown-item:hover,
#fixed-header .dropdown-item:focus-visible {
  background: rgba(136, 1, 62, 0.07);
  color: #88013e;
  outline: none;
}

.dropdown-item.active {
  border: 1px solid rgba(136, 1, 62, 0.35) !important;
  background: rgba(136, 1, 62, 0.08) !important;
  color: #88013e !important;
  font-weight: 600;
}

.dropdown-toggle.active,
#fixed-header .nav-link.active,
#fixed-header .sub-nav-drop.active,
#fixed-header a.single-link.active {
  color: #fff !important;
  background: #88013e !important;
  text-decoration: none;
}

#fixed-header .nav-link.active:hover,
#fixed-header .sub-nav-drop.active:hover,
#fixed-header .nav-link.active:focus-visible,
#fixed-header .sub-nav-drop.active:focus-visible {
  color: #fff !important;
  background: #6d0132 !important;
}

.accordion-button,
.sub-nav-drop,
.dropdown-item,
.accordion-body a {
  text-transform: capitalize;
}

.mobile-categories .single-link,
.mobile-categories div {
  color: #222;
  border: none !important;
  border-top: 1px solid rgba(0, 0, 0, 0.08) !important;
}

.mobile-categories .single-link.active,
.accordion-header:has(.accordion-button:not(.collapsed)) {
  border-left: 4px solid #88013e !important;
}

.accordion-button:not(.collapsed) {
  color: #222 !important;
  background: #fff !important;
}

.accordion-body {
  background: #f7f7f8;
}

.accordion-body a {
  color: #222;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
  border-radius: 0;
  padding: 10px 14px;
}

.accordion-body a.active {
  background: #88013e !important;
  color: #fff;
}

.column-20 {
  width: 20% !important;
}

@media (max-width: 1080px) {
  .column-20 {
    width: 25% !important;
  }
}

@media (max-width: 767px) {
  .column-20 {
    width: 33.33% !important;
  }
}

@media (max-width: 481px) {
  .column-20 {
    width: 50% !important;
  }
}

.description-section {
  background-color: #f8f9fa;
  padding: 60px 0;
  margin-top: 50px;
  border-top: 1px solid #e9ecef;
  border-bottom: 1px solid #e9ecef;
}

.brand-desc-title {
  font-family: "Playfair Display", serif;
  font-size: 32px;
  font-weight: 700;
  color: #88013e;
  margin-bottom: 25px;
  position: relative;
  display: inline-block;
  padding-bottom: 12px;
}

.brand-desc-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 50px;
  height: 3px;
  background-color: #88013e;
  border-radius: 2px;
}

.brand-desc-content {
  font-size: 16px;
  line-height: 1.8;
  color: #4a4a4a;
}

.footer-detail-unit {
  background: rgba(255, 255, 255, 0.03);
  padding: 15px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 15px;
}

.footer-detail-unit p {
  font-size: 14px;
  color: #ddd !important;
  margin-bottom: 8px !important;
  display: flex;
}

.footer-detail-unit p strong {
  min-width: 85px;
  color: #aaa;
  font-weight: 500;
  margin-right: 5px;
}

.foot-content h1 {
  font-size: 1.3rem !important;
  font-weight: 700 !important;
  color: #fff !important;
  margin-bottom: 25px !important;
  position: relative;
  padding-bottom: 10px;
}

.foot-content h1::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 2px;
  background-color: #88013e;
}

.product-card-image {
  width: 100%;
  height: auto !important;
  aspect-ratio: 1 / 1;
  object-fit: contain;
}

.product-card-content {
  min-height: 0 !important;
}

@media (max-width: 767.98px) {
  .product-card-image {
    max-height: 46vw;
  }

  .product-card-container {
    margin: 4px !important;
  }
}

.load-more.hidden {
  display: none;
}

.brand-filter-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #88013e;
  color: #fff;
  border: none;
  border-radius: 999px;
  font-weight: 600;
  font-size: 13px;
  padding: 8px 14px;
  letter-spacing: 0.02em;
  transition: background-color 0.18s ease, transform 0.18s ease;
}

.brand-filter-btn:hover,
.brand-filter-btn:focus-visible {
  background: #6d0132;
  outline: none;
}

.brand-filter-btn:active {
  transform: scale(0.98);
}

.brand-filter-btn i,
.brand-share-btn i {
  font-size: 18px;
  line-height: 1;
}

@media (max-width: 767.98px) {
  .brand-filter-btn,
  .brand-share-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
    padding: 0;
    gap: 0;
  }

  .brand-filter-btn .brand-action-label,
  .brand-share-btn .brand-action-label {
    display: none;
  }

  #fixed-header.brand-subnav,
  .brand-banners-section,
  .brand-layout-section,
  .product-sectionz.summer {
    max-width: 100vw;
    overflow-x: clip;
  }

  #fixed-header .row {
    flex-wrap: nowrap;
    align-items: center;
  }

  #fixed-header .col-8 {
    flex: 1 1 auto;
    width: auto;
    max-width: none;
    min-width: 0;
  }

  #fixed-header .col-2 {
    flex: 0 0 auto;
    width: auto;
  }
}
