@layer sections {
  .product { position: relative; }
  .product__inner { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: clamp(2rem, 1rem + 5vw, 6.5rem); align-items: start; }
  .product__gallery-col { position: sticky; top: calc(var(--header-h) + 1.25rem); }
  @media (max-width: 989px) {
    .product__inner { grid-template-columns: minmax(0, 1fr); }
    .product__gallery-col { position: static; }
  }

  /* ------------------------------------------------------------------ gallery */
  .gallery { display: grid; gap: 1rem; }
  .gallery__viewport {
    overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; cursor: grab;
    border-radius: var(--radius-xl); background: color-mix(in oklab, var(--fg) 7%, var(--bg)); box-shadow: 0 50px 90px -50px rgb(73 40 17 / 0.55);
  }
  .gallery__viewport::-webkit-scrollbar { display: none; }
  .gallery__viewport.is-dragging { cursor: grabbing; scroll-snap-type: none; }
  .gallery__viewport:focus-visible { outline-offset: 4px; }
  .gallery__track { display: flex; list-style: none; margin: 0; padding: 0; }
  .gallery__slide { position: relative; flex: 0 0 100%; aspect-ratio: 4 / 5; scroll-snap-align: start; overflow: hidden; }
  .gallery__img, .gallery__video { width: 100%; height: 100%; object-fit: cover; user-select: none; -webkit-user-drag: none; }
  .gallery__zoom { position: absolute; inset: 0; z-index: 2; display: grid; place-items: end end; padding: 1rem; color: var(--c-cream); cursor: zoom-in; }
  .gallery__zoom .icon { width: 2.8rem; height: 2.8rem; padding: 0.8rem; border-radius: 50%; background: rgb(21 12 8 / 0.62); backdrop-filter: blur(6px); transition: transform 0.6s var(--ease-spring), background var(--dur-s); }
  .gallery__zoom:hover .icon { background: var(--c-gold); color: var(--c-ink); transform: rotate(90deg) scale(1.08); }
  .gallery__viewport.is-dragging .gallery__zoom { pointer-events: none; }

  .gallery__bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
  .gallery__count { font-size: var(--fs-xs); font-weight: 600; letter-spacing: 0.16em; color: var(--fg-soft); }
  .gallery__buttons { display: flex; gap: 0.5rem; }
  .gallery__buttons .icon-btn:disabled { opacity: 0.35; pointer-events: none; }
  .gallery__thumbs { display: flex; gap: 0.6rem; list-style: none; margin: 0; padding: 0.25rem 0.25rem 0.5rem; overflow-x: auto; scrollbar-width: none; scroll-behavior: smooth; }
  .gallery__thumbs::-webkit-scrollbar { display: none; }
  .gallery__thumb { position: relative; display: block; flex: none; width: 4.75rem; aspect-ratio: 4 / 5; border-radius: var(--radius-m); overflow: hidden; opacity: 0.55; transition: opacity var(--dur-s), transform 0.5s var(--ease-spring), box-shadow var(--dur-s); }
  .gallery__thumb img { width: 100%; height: 100%; object-fit: cover; }
  .gallery__thumb:hover { opacity: 0.9; }
  .gallery__thumb[aria-current='true'] { opacity: 1; transform: translateY(-3px); box-shadow: 0 0 0 2px var(--c-gold), 0 14px 22px -12px rgb(21 12 8 / 0.6); }
  .gallery.is-static .gallery__buttons { display: none; }

  /* ------------------------------------------------------------------ info */
  .product__info { display: grid; gap: 1.6rem; align-content: start; }
  .product__badges { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.75rem; list-style: none; margin: 0; padding: 0; }
  .product__title { max-width: 18ch; text-wrap: balance; }
  .product__price-wrap { display: grid; gap: 0.35rem; }
  .product__price { font-size: clamp(1.6rem, 1.3rem + 1vw, 2.2rem); font-family: var(--font-display); font-weight: 500; letter-spacing: -0.02em; align-items: center; }
  .product__price .price__current { font-weight: 500; font-size: 1em; }
  .product__price .price__compare { font-size: 0.6em; }
  .product__lead { max-width: 44ch; }
  .product__tax { font-size: var(--fs-xs); }

  /* option chips */
  .product__options { display: grid; gap: 1.4rem; }
  .opt { display: grid; gap: 0.8rem; }
  .opt__label { display: flex; align-items: baseline; gap: 0.75rem; font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-soft); margin-bottom: 0.1rem; }
  .opt__selected { color: var(--fg); letter-spacing: 0.02em; text-transform: none; font-size: var(--fs-s); }
  .opt__selected::before { content: '—'; margin-right: 0.7rem; opacity: 0.4; }
  .opt__vals { display: flex; flex-wrap: wrap; gap: 0.6rem; }
  .opt__val { position: relative; cursor: pointer; }
  .opt__val input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
  .opt__val span {
    display: inline-flex; align-items: center; min-height: 3rem; padding: 0 1.4rem; border-radius: var(--radius-pill); border: 1px solid color-mix(in oklab, var(--fg) 28%, transparent);
    font-weight: 600; font-size: var(--fs-s); transition: background var(--dur-s), color var(--dur-s), border-color var(--dur-s), transform 0.5s var(--ease-spring), box-shadow var(--dur-m);
  }
  .opt__val:hover span { border-color: var(--fg); }
  .opt__val input:checked + span { background: var(--c-ink); color: var(--c-cream); border-color: var(--c-ink); transform: translateY(-2px); box-shadow: 0 14px 24px -14px rgb(21 12 8 / 0.7); }
  .opt__val input:focus-visible + span { outline: 2px solid var(--c-maroon); outline-offset: 3px; }
  .opt__val.is-unavailable span { color: var(--fg-soft); text-decoration: line-through; border-style: dashed; }
  .opt__val.is-unavailable input:checked + span { color: var(--c-cream); }

  /* buy area */
  .product__buy-wrap { display: grid; gap: 0.9rem; }
  .product__form { display: grid; gap: 0.9rem; }
  .product__buy { display: flex; gap: 0.75rem; align-items: stretch; }
  .product__buy .qty { height: 4.1rem; }
  .product__buy .qty__btn { width: 2.9rem; }
  .product__buy .qty__input { width: 2.4rem; }
  .product__atc { flex: 1; padding-inline: 1.25rem; gap: 0.6rem; min-width: 0; }
  .product__atc .btn__roll { text-align: center; }
  .product__atc .icon { order: 3; }
  .product__wa { text-decoration: none; }
  .product__note .textarea { min-height: 5rem; }

  .product__delivery { display: flex; align-items: center; gap: 0.9rem; padding: 0.95rem 1.2rem; border-radius: var(--radius-l); background: color-mix(in oklab, var(--c-leaf) 10%, var(--bg)); border: 1px solid color-mix(in oklab, var(--c-leaf) 28%, transparent); font-size: var(--fs-s); line-height: 1.45; }
  .product__delivery strong { display: block; font-weight: 700; }
  .product__delivery [data-cutoff-text] { color: var(--fg-soft); }
  .product__delivery[data-state='closed'] { background: color-mix(in oklab, var(--c-gold) 14%, var(--bg)); border-color: color-mix(in oklab, var(--c-gold) 45%, transparent); }
  .product__delivery[data-state='closed'] .pulse-dot { background: var(--c-gold); }

  .product__trust { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.9rem 1.25rem; list-style: none; margin: 0; padding: 1.4rem 0; border-block: 1px solid var(--line); }
  .product__trust li { display: flex; align-items: center; gap: 0.8rem; font-size: var(--fs-s); font-weight: 600; }
  .product__trust .hex-icon { width: 2.4rem; background: var(--c-bark); color: var(--c-honey); }
  .product__trust .hex-icon .icon { width: 1.05rem; height: 1.05rem; }

  .acc--compact .acc__summary { font-size: 1.2rem; padding-block: 1.15rem; }
  .acc--compact .acc__plus { width: 2.1rem; height: 2.1rem; }
  .acc--compact .acc__body { font-size: var(--fs-s); padding-bottom: 1.4rem; }
  .acc--compact .acc__body .rte, .acc--compact .acc__body.rte { font-size: var(--fs-s); line-height: 1.7; }
  .acc--compact .rte h3, .acc--compact .rte h4 { margin-top: 1.4em; font-size: 1.05rem; }

  .product__share { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
  .product__sku { font-size: var(--fs-xs); letter-spacing: 0.08em; }
  .product__share .btn-link .icon { width: 1.1rem; height: 1.1rem; }

  /* ------------------------------------------------------------------ lightbox */
  .lightbox { position: fixed; inset: 0; width: 100vw; height: 100dvh; background: rgb(10 6 4 / 0.94); color: var(--c-cream); z-index: calc(var(--z-overlay) + 10); opacity: 0; transition: opacity 0.4s var(--ease-out), display 0.4s allow-discrete, overlay 0.4s allow-discrete; }
  .lightbox[open] { opacity: 1; display: grid; grid-template-rows: auto 1fr; }
  @starting-style { .lightbox[open] { opacity: 0; } }
  .lightbox::backdrop { background: transparent; }
  .lightbox__bar { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.25rem; }
  .lightbox__count { font-size: var(--fs-xs); letter-spacing: 0.18em; font-weight: 600; }
  .lightbox__stage { position: relative; display: grid; place-items: center; overflow: hidden; padding: 0 clamp(0.5rem, 6vw, 5rem) 1.5rem; touch-action: pan-y; }
  .lightbox__img { max-width: 100%; max-height: calc(100dvh - 7rem); object-fit: contain; cursor: zoom-in; border-radius: var(--radius-m); transition: transform 0.5s var(--ease-out); }
  .lightbox__img.is-zoomed { transform: scale(2.1); cursor: zoom-out; }
  .lightbox__nav { position: absolute; top: 50%; translate: 0 -50%; color: var(--c-cream); border-color: rgb(255 255 255 / 0.3); z-index: 2; }
  .lightbox__nav--prev { left: clamp(0.5rem, 2vw, 1.5rem); }
  .lightbox__nav--next { right: clamp(0.5rem, 2vw, 1.5rem); }
  @media (max-width: 749px) { .lightbox__nav { display: none; } }

  /* ------------------------------------------------------------------ sticky add-to-cart */
  .sticky-atc {
    position: fixed; inset: auto 0 0 0; z-index: calc(var(--z-sticky) + 5); transform: translateY(110%); transition: transform 0.7s var(--ease-out);
    padding: 0.75rem 0 calc(0.75rem + env(safe-area-inset-bottom)); background: color-mix(in oklab, var(--c-ink) 92%, transparent); color: var(--c-cream);
    backdrop-filter: blur(16px) saturate(1.3); box-shadow: 0 -20px 50px -24px rgb(0 0 0 / 0.6);
  }
  .sticky-atc.is-visible { transform: none; }
  .sticky-atc__inner { display: flex; align-items: center; gap: 1rem; }
  .sticky-atc__img { flex: none; width: 3.4rem; aspect-ratio: 1; border-radius: var(--radius-m); overflow: hidden; }
  .sticky-atc__img img { width: 100%; height: 100%; object-fit: cover; }
  .sticky-atc__info { flex: 1; min-width: 0; }
  .sticky-atc__title { font-family: var(--font-display); font-size: 1.05rem; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sticky-atc__price { font-size: var(--fs-s); color: var(--c-honey); }
  .sticky-atc .price__compare { color: color-mix(in oklab, var(--c-cream) 60%, transparent); }
  html.has-sticky-atc .floating-actions { transform: translateY(-4.6rem); }
  @media (max-width: 749px) { .sticky-atc__img { display: none; } .sticky-atc .btn { padding-inline: 1.25rem; } }

  /* ------------------------------------------------------------------ recommendations */
  .recs__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1.75rem, 1rem + 2.5vw, 3.5rem) clamp(0.9rem, 0.4rem + 2vw, 2rem); list-style: none; margin: 0; padding: 0; }
  @media (min-width: 990px) { .recs__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
  @container (max-width: 15rem) { .pcard__quick span { display: none; } .pcard__quick { padding: 0; width: 2.75rem; justify-content: center; } }
}
