/* Gando 9.7.36 — product-card alignment + storefront dark-mode legibility. */

/* Keep the price/purchase baseline identical even when only some products have
   optional usage/season chips. Equal-height rails/grids can now push purchase
   information to the same bottom edge instead of letting optional metadata shift it. */
.home-product-zone .product-card-v62,
.home-product-stacks .product-card-v62,
.catalog-grid .product-card-v62,
.pdp-carousel-track .product-card-v62,
.pdp-related .product-card-v62{
  display:flex;
  flex-direction:column;
}
.home-product-zone .product-card-v62__body,
.home-product-stacks .product-card-v62__body,
.catalog-grid .product-card-v62__body,
.pdp-carousel-track .product-card-v62__body,
.pdp-related .product-card-v62__body{
  display:flex;
  flex:1 1 auto;
  flex-direction:column;
  min-height:0;
}
.home-product-zone .product-card-v63__purchase,
.home-product-stacks .product-card-v63__purchase,
.catalog-grid .product-card-v63__purchase,
.pdp-carousel-track .product-card-v63__purchase,
.pdp-related .product-card-v63__purchase{
  margin-top:auto!important;
}

/* Homepage: white/glass labels were designed for the light hero. Keep them
   intentional and readable when the document is dark. */
html[data-theme="dark"] .home .float-chip,
html[data-theme="dark"] .home .btn-ghost,
html[data-theme="dark"] body.home .float-chip,
html[data-theme="dark"] body.home .btn-ghost{
  background:rgba(20,31,24,.92)!important;
  border-color:#33463a!important;
  color:#e9f3ec!important;
}
html[data-theme="dark"] body.home .float-chip b,
html[data-theme="dark"] body.home .btn-ghost:hover{
  color:#b6dec1!important;
}
html[data-theme="dark"] body.home .product-zone-head__copy p,
html[data-theme="dark"] body.home .product-zone-head__main p{
  color:#aab8ae!important;
}

/* PDP dark-mode contrast. A number of late PDP refinements use fixed light-mode
   greens instead of theme variables; override only inside single-product pages. */
html[data-theme="dark"] body.single-product .pdp,
html[data-theme="dark"] body.single-product .purchase{
  color:#eef5f0;
}
html[data-theme="dark"] body.single-product .pdp-title,
html[data-theme="dark"] body.single-product .pdp h1,
html[data-theme="dark"] body.single-product .pdp h2,
html[data-theme="dark"] body.single-product .pdp h3,
html[data-theme="dark"] body.single-product .pdp h4,
html[data-theme="dark"] body.single-product .pdp .option-head b,
html[data-theme="dark"] body.single-product .pdp .product-story-card h2,
html[data-theme="dark"] body.single-product .pdp .story-care-list li,
html[data-theme="dark"] body.single-product .pdp .purchase-service b,
html[data-theme="dark"] body.single-product .pdp .scroll-buy__copy b{
  color:#f0f6f2!important;
}
html[data-theme="dark"] body.single-product .pdp .sku,
html[data-theme="dark"] body.single-product .pdp .pdp-breadcrumb,
html[data-theme="dark"] body.single-product .pdp .breadcrumbs,
html[data-theme="dark"] body.single-product .pdp .breadcrumbs a,
html[data-theme="dark"] body.single-product .pdp .option-head>span,
html[data-theme="dark"] body.single-product .pdp .purchase-service small,
html[data-theme="dark"] body.single-product .pdp .gando-story-copy,
html[data-theme="dark"] body.single-product .pdp .gando-story-copy p,
html[data-theme="dark"] body.single-product .pdp .story-card p,
html[data-theme="dark"] body.single-product .pdp .pdp-section-heading p{
  color:#a9b8ae!important;
}

html[data-theme="dark"] body.single-product .pdp-stock{
  background:#173020!important;
  border-color:#2f6d45!important;
  color:#9fe0b0!important;
}
html[data-theme="dark"] body.single-product .pdp-stock::before{background:#54d47a!important}
html[data-theme="dark"] body.single-product .pdp .size-guide-trigger{
  background:#1b3022!important;
  color:#b9e0c4!important;
  border-color:#36513e!important;
}
html[data-theme="dark"] body.single-product .pdp .size-stock-message{color:#a9d9b5!important}
html[data-theme="dark"] body.single-product .pdp .size-stock-message::before{background:#54d47a!important}

html[data-theme="dark"] body.single-product .pdp-price{
  color:#a9dcb7!important;
}
html[data-theme="dark"] body.single-product .pdp-price .amount,
html[data-theme="dark"] body.single-product .pdp-price .woocommerce-Price-amount,
html[data-theme="dark"] body.single-product .pdp-price .woocommerce-Price-currencySymbol{
  color:inherit!important;
}
/* Sale price must stay visually distinct from the struck-through old price in dark mode too. */
html[data-theme="dark"] body.single-product .pdp-price del,
html[data-theme="dark"] body.single-product .pdp-price del .amount,
html[data-theme="dark"] body.single-product .pdp-price del .woocommerce-Price-amount,
html[data-theme="dark"] body.single-product .pdp-price del .woocommerce-Price-currencySymbol{
  color:#7f9184!important;
}
html[data-theme="dark"] body.single-product .pdp-price ins{
  background:rgba(255,163,0,.14)!important;
}
html[data-theme="dark"] body.single-product .pdp-price ins .amount,
html[data-theme="dark"] body.single-product .pdp-price ins .woocommerce-Price-amount,
html[data-theme="dark"] body.single-product .pdp-price ins .woocommerce-Price-currencySymbol{
  color:#ffb733!important;
}
html[data-theme="dark"] body.single-product .pdp-attribute-groups .pdp-attribute-group{
  background:#17271d!important;
  border-color:#33483a!important;
  color:#d8e9dc!important;
}
html[data-theme="dark"] body.single-product .pdp-attribute-group small{color:#92a69a!important}
html[data-theme="dark"] body.single-product .pdp-attribute-group b{color:#c0e1c8!important}
html[data-theme="dark"] body.single-product .pdp-installment-inline{
  background:linear-gradient(105deg,#14261a,#172b1d)!important;
  border-color:#36513e!important;
  color:#e8f3eb!important;
}
html[data-theme="dark"] body.single-product .pdp-installment-inline:hover{
  background:linear-gradient(105deg,#183020,#1c3323)!important;
  border-color:#486752!important;
}
html[data-theme="dark"] body.single-product .pdp-installment-copy b{color:#bde0c6!important}
html[data-theme="dark"] body.single-product .pdp-installment-copy small{color:#9eb0a4!important}
html[data-theme="dark"] body.single-product .pdp-installment-more{color:#b9dcc2!important}
html[data-theme="dark"] body.single-product .purchase-service{
  background:#131f17!important;
  border-color:#31453a!important;
  color:#edf5ef!important;
}
html[data-theme="dark"] body.single-product .purchase-service:hover{background:#192a20!important;border-color:#45604d!important}
html[data-theme="dark"] body.single-product .purchase-service>span:first-child{
  background:#1f3527!important;
  color:#a7dab5!important;
}
html[data-theme="dark"] body.single-product .story-card{
  background:#132018!important;
  border-color:#2d4035!important;
}
html[data-theme="dark"] body.single-product .story-card__eyebrow .kicker,
html[data-theme="dark"] body.single-product .story-card__icon{color:#9fd4ad!important}
html[data-theme="dark"] body.single-product .story-care-list li{
  background:#16241b!important;
  border-color:#30453a!important;
}
html[data-theme="dark"] body.single-product .story-care-list li::marker{color:#84c899}
html[data-theme="dark"] body.single-product .spec,
html[data-theme="dark"] body.single-product .pdp .policy-card{
  background:#142119!important;
  border-color:#2e4236!important;
}
html[data-theme="dark"] body.single-product .spec b{color:#edf5ef!important}
html[data-theme="dark"] body.single-product .spec span{color:#a7b5ac!important}
html[data-theme="dark"] body.single-product .article-comments,
html[data-theme="dark"] body.single-product .gando-product-comments{
  color:#eaf3ed;
}
html[data-theme="dark"] body.single-product .gando-product-comments h2,
html[data-theme="dark"] body.single-product .gando-product-comments h3,
html[data-theme="dark"] body.single-product .gando-product-comments label,
html[data-theme="dark"] body.single-product .gando-product-comments strong{color:#eef6f0!important}
html[data-theme="dark"] body.single-product .gando-product-comments p,
html[data-theme="dark"] body.single-product .gando-product-comments small{color:#a6b5ab!important}
html[data-theme="dark"] body.single-product .gando-product-comments input,
html[data-theme="dark"] body.single-product .gando-product-comments textarea{
  background:#101b14!important;
  border-color:#31453a!important;
  color:#eef6f0!important;
}

/* Sticky PDP bar: fixed green labels from older refinements become readable. */
html[data-theme="dark"] body.single-product .pdp-scroll-buy,
html[data-theme="dark"] body.single-product .mobile-sticky-buy{
  color:#162019;
}
html[data-theme="dark"] body.single-product .pdp-scroll-buy .scroll-buy__copy b,
html[data-theme="dark"] body.single-product .pdp-scroll-buy [data-gando-sticky-price]{color:#173522!important}

@media(max-width:700px){
  .home-product-zone .product-card-v62__body,
  .home-product-stacks .product-card-v62__body{min-height:142px}
}

/* Product recommendation/care-card foregrounds on dark PDP. */
html[data-theme="dark"] body.single-product .product-card-v62__price strong,
html[data-theme="dark"] body.single-product .pdp-care-card__price strong,
html[data-theme="dark"] body.single-product .care-product-card__price strong{color:#dff0e4!important}
html[data-theme="dark"] body.single-product .product-card-v62__price small,
html[data-theme="dark"] body.single-product .pdp-care-card__price small{color:#9fb0a5!important}
html[data-theme="dark"] body.single-product .pdp-care-card__body>b,
html[data-theme="dark"] body.single-product .care-product-card__details b{color:#edf5ef!important}
html[data-theme="dark"] body.single-product .pdp-care-card__body small,
html[data-theme="dark"] body.single-product .care-product-card__details small{color:#a4b5aa!important}
html[data-theme="dark"] body.single-product .pdp-care-card__action,
html[data-theme="dark"] body.single-product .pdp-care-card__wish{
  background:#1a2b20!important;
  border-color:#385040!important;
  color:#b9dec2!important;
}

/* ===== Sticky bottom buy bar (`pdp-scroll-buy`) — corrected =====
   Real root cause of BOTH the "still Light in Dark" and the overflow was the
   decorative `.pdp-scroll-buy::before` pseudo-element, not the element itself.
   It was an OPAQUE WHITE plate (`background:rgba(255,255,255,.97)`) whose
   insets were computed with `calc((100vw - 1400px)/2)` / `100vw`. Because `v828`
   forced the bar element to `background:transparent !important`, the visible
   light surface came ENTIRELY from that pseudo-element — so darkening the bar
   had no visible effect, and the `100vw`-based plate could escape the viewport.
   The `::before` only painted a background/border/shadow, so it is removed
   (`content:none`) and the element itself now owns its token surface in both
   themes (resolved via `--paper` / `--line` / `--ink`). Higher specificity
   (`.is-visible`) + `!important` + later load beats `v828`'s transparent rule. */
.single-product .pdp-scroll-buy::before{content:none!important;display:none!important}
.single-product .pdp-scroll-buy.is-visible{
  background:color-mix(in srgb, var(--paper,#ffffff) 97%, transparent)!important;
  border:1px solid var(--line,#e3e8e4)!important;
  color:var(--ink,#16211a)!important;
  box-shadow:0 12px 34px rgba(13,35,25,.16)!important;
}
html[data-theme="dark"] body.single-product .pdp-scroll-buy.is-visible{
  background:color-mix(in srgb, var(--paper,#141b16) 97%, transparent)!important;
  border-color:var(--line,#2a342d)!important;
  color:var(--ink,#f1f5f2)!important;
  box-shadow:0 12px 34px rgba(0,0,0,.42)!important;
}
/* Light foreground on the dark plate (overrides the legacy `#173522` title/price). */
html[data-theme="dark"] body.single-product .pdp-scroll-buy.is-visible .scroll-buy__copy b,
html[data-theme="dark"] body.single-product .pdp-scroll-buy.is-visible [data-gando-sticky-price]{
  color:var(--ink,#f1f5f2)!important;
}
html[data-theme="dark"] body.single-product .pdp-scroll-buy.is-visible .scroll-buy__copy span{color:#a5d7b2!important}
html[data-theme="dark"] body.single-product .pdp-scroll-buy.is-visible .scroll-buy__qty{
  background:var(--surface-2,#101b14)!important;
  border-color:var(--line,#2a342d)!important;
  color:#edf4ef!important;
}
html[data-theme="dark"] body.single-product .pdp-scroll-buy.is-visible .scroll-buy__qty button{color:#9fd3ad!important}
html[data-theme="dark"] body.single-product .pdp-scroll-buy.is-visible .scroll-buy__variant select{
  background:var(--surface-2,#101b14)!important;
  border-color:var(--line,#2a342d)!important;
  color:var(--ink,#f1f5f2)!important;
}
/* Viewport containment — keep the rail and its rows within the container on
   320/360/390/430. No `body{overflow-x:hidden}` is used. */
.single-product .pdp-scroll-buy.is-visible,
.single-product .pdp-scroll-buy .scroll-buy__copy,
.single-product .pdp-scroll-buy .scroll-buy__sizes{min-width:0;max-width:100%}
