/* Hero: WebGL aisle stage, headline, aisle rail, product reveal panel */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  height: clamp(560px, calc(100svh - var(--hdr-h) - 36px), 940px);
  background: radial-gradient(120% 90% at 70% 40%, #FFFFFF 0%, var(--ivory) 55%, var(--ivory-2) 100%);
}
.hero__stage { position: absolute; inset: 0; z-index: -2; }
.hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transition: opacity 1.4s var(--ease-out); touch-action: pan-y; }
.hero.is-ready .hero__canvas { opacity: 1; }
.hero.is-hovering .hero__canvas { cursor: pointer; }
.hero__fallback {
  position: absolute; inset: 0; opacity: .9;
  background:
    radial-gradient(40% 50% at 72% 46%, color-mix(in srgb, var(--brand) 14%, transparent), transparent 70%),
    radial-gradient(30% 40% at 88% 70%, rgba(246, 185, 40, .16), transparent 70%);
  transition: opacity 1s;
}
.hero.is-ready .hero__fallback { opacity: 0; }
.hero.no-webgl .hero__fallback { opacity: 1; background-size: cover; background-position: center; }
.hero.no-webgl .hero__fallback::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, var(--ivory) 30%, rgba(250, 247, 241, .2)); }

.hero__veil {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(250, 247, 241, .94) 0%, rgba(250, 247, 241, .8) 26%, rgba(250, 247, 241, 0) 52%),
    linear-gradient(0deg, rgba(250, 247, 241, .9) 0%, rgba(250, 247, 241, 0) 22%);
}
/* Inside an aisle the shelves fill the frame: give the copy a calmer field. */
.hero__veil::after {
  content: ''; position: absolute; inset: 0; opacity: 0; transition: opacity .9s var(--ease-out);
  background: linear-gradient(90deg, rgba(250, 247, 241, .97) 0%, rgba(250, 247, 241, .93) 36%, rgba(250, 247, 241, .55) 47%, rgba(250, 247, 241, 0) 58%);
}
.hero.is-zoned .hero__veil::after { opacity: 1; }

.hero__inner { position: relative; height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 32px; padding-bottom: 104px; pointer-events: none; }
.hero__inner > * { pointer-events: auto; }
.hero__copy { max-width: 610px; }
.hero__title {
  margin-top: 22px;
  font: 800 clamp(50px, min(7.3vw, 11svh), 116px)/.88 var(--font-display);
  font-stretch: 78%; letter-spacing: -.018em; text-transform: uppercase;
}
.hero__title .ln { display: block; animation: rise 1.1s var(--ease-out) both; }
.hero__title .ln:nth-child(2) { animation-delay: .08s; }
.hero__title .ln:nth-child(3) { animation-delay: .16s; }
.hero__accent { color: var(--brand); transition: color .5s; }
@keyframes rise { from { opacity: 0; transform: translateY(.35em); } }
.hero__lede { max-width: 480px; margin: 24px 0 32px; font-size: 17.5px; line-height: 1.55; color: var(--ink-2); animation: rise 1.1s .24s var(--ease-out) both; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; animation: rise 1.1s .3s var(--ease-out) both; }
.hero__proof { display: flex; flex-wrap: wrap; gap: 10px 26px; margin-top: 34px; font-size: 13.5px; color: var(--ink-2); animation: rise 1.1s .38s var(--ease-out) both; }
.hero__proof li { display: inline-flex; align-items: center; gap: 5px; }
.hero__proof li + li::before { content: ''; width: 4px; height: 4px; margin-right: 18px; border-radius: 50%; background: var(--ink-3); opacity: .5; }
.hero__proof b { color: var(--ink); font-weight: 700; }
.ico-star .ico { width: 14px; height: 14px; color: var(--sun); fill: var(--sun); stroke: none; }

/* product reveal panel */
.aisle-panel { width: 372px; flex: none; padding: 18px; border-radius: var(--r-l); animation: panel-in .55s var(--ease-out); }
@keyframes panel-in { from { opacity: 0; transform: translateX(24px) scale(.98); } }
.ap__head { display: flex; align-items: flex-start; gap: 12px; padding: 2px 2px 14px; border-bottom: 1px solid var(--line); }
.ap__icon { width: 46px; height: 46px; flex: none; border-radius: 14px; display: grid; place-items: center; background: var(--accent); color: #fff; }
.ap__icon .ico { width: 22px; height: 22px; }
.ap__titles { flex: 1; min-width: 0; }
.ap__aisle { font: 700 11px/1 var(--font-ui); letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.ap__name { margin-top: 5px; font: 700 23px/1.05 var(--font-display); font-stretch: 88%; letter-spacing: -.02em; }
.ap__blurb { margin-top: 4px; font-size: 13px; color: var(--ink-2); }
.ap__close { width: 34px; height: 34px; flex: none; border-radius: 50%; display: grid; place-items: center; color: var(--ink-2); transition: background .2s; }
.ap__close:hover { background: rgba(18, 22, 43, .07); color: var(--ink); }
.ap__list { display: grid; gap: 4px; padding-block: 10px; }
.ap__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink-2); }
.ap__foot .btn { --h: 38px; padding: 0 14px; font-size: 13.5px; }

/* compact product row (hero panel, search, drawers) */
.mini { display: grid; grid-template-columns: 58px 1fr auto; align-items: center; gap: 12px; padding: 7px; border-radius: 14px; transition: background .2s; }
.mini:hover { background: rgba(255, 255, 255, .7); }
.mini__img { width: 58px; height: 58px; border-radius: 12px; overflow: hidden; background: var(--tint, var(--ivory-2)); }
.mini__img img { width: 100%; height: 100%; object-fit: cover; }
.mini__name { display: block; text-align: left; font: 600 14px/1.25 var(--font-ui); }
.mini__name:hover { color: var(--brand); }
.mini__meta { margin-top: 3px; font-size: 12px; color: var(--ink-3); }
.mini__price { margin-top: 3px; font: 700 14px/1 var(--font-ui); }
.mini__price s { margin-left: 5px; font-weight: 400; font-size: 12px; color: var(--ink-3); }
.mini__price .off { margin-left: 5px; font-size: 11.5px; color: var(--fresh); }

/* aisle rail */
.hero__rail { position: absolute; left: 0; right: 0; bottom: 22px; z-index: 3; }
.rail { display: flex; align-items: center; gap: 8px; padding: 8px; border-radius: 22px; }
.rail__label { flex: none; width: 150px; padding: 0 6px 0 10px; line-height: 1.25; }
.rail__label span { display: block; font: 600 13px/1.2 var(--font-ui); }
.rail__label small { display: block; margin-top: 2px; font-size: 12px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rail__nav { width: 40px; height: 40px; flex: none; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .7); transition: background .2s; }
.rail__nav:hover { background: #fff; }
.rail__track {
  flex: 1; min-width: 0; display: flex; gap: 6px; overflow-x: auto; scroll-behavior: smooth; scrollbar-width: none;
  mask-image: linear-gradient(90deg, transparent, #000 16px, #000 calc(100% - 16px), transparent);
}
.rail__track::-webkit-scrollbar { display: none; }
.rail__chip {
  flex: none; display: flex; align-items: center; gap: 9px; height: 48px; padding: 0 14px 0 6px;
  border-radius: 15px; font: 500 13.5px/1.1 var(--font-ui); text-align: left; color: var(--ink);
  transition: background .25s, color .25s, transform .25s var(--ease);
}
.rail__chip:hover { background: rgba(255, 255, 255, .85); }
.rail__chip small { display: block; font-size: 10.5px; color: var(--ink-3); letter-spacing: .06em; }
.rail__ico { width: 36px; height: 36px; flex: none; border-radius: 11px; display: grid; place-items: center; background: var(--tint); color: var(--accent); transition: background .25s, color .25s; }
.rail__ico .ico { width: 19px; height: 19px; }
.rail__chip[aria-pressed="true"] { background: var(--ink); color: #fff; }
.rail__chip[aria-pressed="true"] small { color: rgba(255, 255, 255, .6); }
.rail__chip[aria-pressed="true"] .rail__ico { background: var(--accent); color: #fff; }

/* 3D hover tooltip */
.aisle-tip {
  position: absolute; z-index: 4; left: 0; top: 0; pointer-events: none;
  padding: 10px 12px; border-radius: 14px; min-width: 170px;
  background: rgba(18, 22, 43, .9); color: #fff; box-shadow: var(--shadow-2);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  transform: translate(-50%, calc(-100% - 18px)); font-size: 12.5px;
}
.aisle-tip b { display: block; font-size: 13.5px; }
.aisle-tip span { color: rgba(255, 255, 255, .65); }
.aisle-tip em { font-style: normal; font-weight: 700; color: #9DF0C3; }

/* Short laptop screens (≈720–800px tall): keep the aisle rail above the fold. */
@media (max-height: 800px) and (min-width: 901px) {
  .hero__inner { padding-bottom: 92px; }
  .hero__title { margin-top: 16px; font-size: clamp(46px, min(7vw, 9.6svh), 96px); }
  .hero__lede { margin: 16px 0 22px; font-size: 16px; }
  .hero__proof { display: none; }
  .aisle-panel { padding: 14px; }
  .ap__blurb { display: none; }
  .ap__list .mini:nth-child(4) { display: none; }
}
@media (max-width: 1100px) {
  .aisle-panel { width: 330px; }
  .hero__veil { background: linear-gradient(90deg, rgba(250, 247, 241, .95) 0%, rgba(250, 247, 241, .82) 40%, rgba(250, 247, 241, 0) 75%), linear-gradient(0deg, rgba(250, 247, 241, .9) 0%, rgba(250, 247, 241, 0) 22%); }
}
@media (max-width: 900px) {
  .hero { height: auto; min-height: 820px; }
  .hero__inner { flex-direction: column; align-items: stretch; justify-content: flex-start; padding-top: 30px; padding-bottom: 340px; }
  .hero__veil { background: linear-gradient(180deg, rgba(250, 247, 241, .96) 0%, rgba(250, 247, 241, .85) 42%, rgba(250, 247, 241, 0) 62%), linear-gradient(0deg, rgba(250, 247, 241, .92) 0%, rgba(250, 247, 241, 0) 18%); }
  .hero__veil::after { background: linear-gradient(180deg, rgba(250, 247, 241, .97) 0%, rgba(250, 247, 241, .9) 46%, rgba(250, 247, 241, 0) 62%); }
  .hero__title { font-size: clamp(44px, 12.5vw, 76px); }
  .hero__lede { font-size: 16px; margin: 18px 0 24px; }
  .hero__proof { margin-top: 24px; gap: 8px 18px; }
  .hero__proof li + li::before { margin-right: 12px; }
  .aisle-panel { position: absolute; left: var(--gutter); right: var(--gutter); bottom: 100px; width: auto; padding: 12px; }
  .ap__head { padding-bottom: 10px; }
  .ap__blurb { display: none; }
  .ap__list { grid-auto-flow: column; grid-auto-columns: 82%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
  .ap__list .mini { scroll-snap-align: start; background: rgba(255, 255, 255, .6); }
  .ap__foot { display: none; }
  .rail__label { display: none; }
}
@media (max-width: 560px) {
  .hero { min-height: 860px; }
  .rail__nav { display: none; }
  .rail { padding: 6px; border-radius: 18px; }
  .hero__ctas .btn { flex: 1; }
}
