/* ============================================================
   EXUDE — hero360.css
   Scroll-driven 360° hero. Loaded AFTER home.css / responsive.css,
   so it deliberately overrides the old static-banner hero rules.

   Structure
     .hero            tall scroll "runway" (height = how long the bottle spins)
       .hero__stage   sticky 100vh viewport that stays on screen
         .hero__media    depth layers (parallax)
         .hero__title    giant wordmark BEHIND the bottle
         .hero__bottle   canvas player
         .hero__mist     cursor mist canvas
         .hero__inner    copy + glass card + CTAs
   JS sets --p (0→1 scroll progress) on .hero__stage.
   ============================================================ */

/* ---------- Runway + sticky stage ---------- */

.hero {
  display: block;
  height: 100vh;            /* single screen — bottle no longer rotates on scroll */
  min-height: 0;
  overflow: visible;        /* sticky needs this */
  background-color: #070809;
  text-align: left;
}

.hero__stage {
  --p: 0;
  position: sticky;
  top: 0;
  --off: 0px;               /* announcement-bar height still visible above the hero (set by JS) */
  height: calc(100vh - var(--off));
  height: calc(100svh - var(--off));
  overflow: hidden;
  isolation: isolate;
  color: var(--white);
}

/* ---------- Backdrop: cold frost glow, gold rings, film grain ---------- */

.hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.hero__layer {
  position: absolute;
  inset: -8%;
  will-change: transform;
  pointer-events: none;
}

.hero__layer--glow {
  background:
    radial-gradient(ellipse 52% 50% at 50% 48%, rgba(70, 120, 136, 0.55) 0%, rgba(24, 42, 50, 0.7) 42%, transparent 75%),
    radial-gradient(ellipse 40% 30% at 85% 95%, rgba(212, 175, 55, 0.12) 0%, transparent 70%),
    linear-gradient(180deg, #0b1013 0%, #070809 100%);
}

.hero__layer--halo::before,
.hero__layer--halo::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.hero__layer--halo::before {
  width: 74vmin;
  height: 74vmin;
  border: 1px solid rgba(212, 175, 55, 0.2);
}

.hero__layer--halo::after {
  width: 54vmin;
  height: 54vmin;
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.hero__layer--grain {
  opacity: 0.09;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

.hero__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 85% 75% at 50% 50%, transparent 40%, rgba(0, 0, 0, 0.6) 100%);
  pointer-events: none;
}

/* ---------- Wordmark behind the bottle ---------- */

.hero__title {
  position: absolute;
  z-index: 1;
  left: 50%;
  top: 24%;
  width: 100%;
  text-align: center;
  white-space: nowrap;
  font-size: clamp(4rem, 14.5vw, 13.5rem);
  line-height: 0.9;
  letter-spacing: 0.1em;
  text-indent: 0.1em;
  color: rgba(245, 240, 232, 0.94);
  text-shadow: 0 30px 90px rgba(0, 0, 0, 0.5);
  transform: translate3d(-50%, calc(var(--p) * -9vh), 0);
  opacity: calc(1 - var(--p) * 0.55);
  pointer-events: none;
}

/* Front copy of the wordmark: outlined glass lettering that passes OVER the bottle */
.hero__title--front {
  z-index: 4;
  color: rgba(245, 240, 232, 0.16);
  -webkit-text-stroke: 2px rgba(232, 200, 90, 0.95);
  text-shadow: 0 0 24px rgba(212, 175, 55, 0.35);
  opacity: 1;
  mix-blend-mode: normal;
  top: 24%;
  transform: translate3d(-50%, calc(var(--p) * -9vh), 0);
}

/* ---------- Bottle ---------- */

.hero__bottle {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 50%;
  height: min(64vh, 680px);
  aspect-ratio: 0.72;
  margin: calc(min(64vh, 680px) / -2 + 3vh) 0 0 calc(min(64vh, 680px) * 0.72 / -2);
  cursor: default;
  touch-action: pan-y;       /* vertical scroll still works on touch */
  -webkit-user-select: none;
  user-select: none;
  /* "pop-up" entrance — released by JS adding .is-loaded */
  opacity: 0;
  transform: scale(0.86) translateY(24px);
  filter: blur(14px);
}

.hero__bottle.is-loaded {
  opacity: 1;
  transform: none;
  filter: none;
  transition: opacity 1.4s var(--ease-out), transform 1.8s var(--ease-out), filter 1.4s var(--ease-out);
}

/* Breathing glow behind the bottle */
.hero__bottle::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 52%;
  width: 150%;
  height: 120%;
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse at center, rgba(120, 190, 210, 0.32) 0%, rgba(212, 175, 55, 0.08) 40%, transparent 68%);
  filter: blur(18px);
  z-index: -1;
  pointer-events: none;
  animation: bottleGlow 5.5s ease-in-out infinite;
}

@keyframes bottleGlow {
  0%, 100% { opacity: 0.55; transform: translate(-50%, -50%) scale(0.92); }
  50%      { opacity: 1;    transform: translate(-50%, -50%) scale(1.08); }
}

.hero__bottle canvas {
  width: 100%;
  height: 100%;
  will-change: transform;
}

/* Floor glow under the bottle */
.hero__bottle::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -2%;
  width: 96%;
  height: 7%;
  --lift: 0;
  --sx: 0px;
  transform: translateX(calc(-50% + var(--sx))) scale(calc(1.08 - var(--lift) * 0.3), calc(1.1 - var(--lift) * 0.4));
  opacity: calc(1 - var(--lift) * 0.45);
  background: radial-gradient(ellipse at center, rgba(170, 215, 228, 0.5) 0%, transparent 70%);
  filter: blur(8px);
  z-index: -1;
}

.hero__mist {
  position: absolute;
  inset: 0;
  z-index: 4;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* ---------- Copy layer ---------- */

.hero__inner {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(200px, 24vw) minmax(0, 1fr);
  align-items: end;
  padding: calc(var(--nav-height) + 2rem) var(--gutter, 2rem) 8.5rem;
  pointer-events: none;   /* let the bottle receive drags; re-enabled below */
}

.hero__inner a,
.hero__card {
  pointer-events: auto;
}

.hero__col--left {
  grid-column: 1;
  max-width: 34ch;
}

.hero__col--right {
  grid-column: 3;
  justify-self: end;
  width: 100%;
  max-width: 300px;
}

.hero__tagline {
  margin: 0;
  max-width: 14ch;
  font-size: clamp(1.7rem, 3vw, 2.6rem);
  line-height: 1.18;
}

.hero__title-rule {
  display: block;
  margin: var(--space-md) 0;
}

.hero__sub {
  margin: 0;
  max-width: 34ch;
}

.hero__actions {
  flex-direction: column;
  align-items: stretch;
  margin-top: var(--space-md);
}

.hero__actions .btn {
  justify-content: center;
  text-align: center;
}

/* ---------- Glassmorphism product card ---------- */

.hero__card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 1.25rem 1.5rem 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 4px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.03));
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  backdrop-filter: blur(20px) saturate(1.5);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 30px 80px rgba(0, 0, 0, 0.35);
}

.hero__card-kicker {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
  color: var(--gold);
}

.hero__card-name {
  font-family: var(--font-heading);
  font-size: 1.7rem;
  font-weight: 400;
  line-height: 1.15;
  color: var(--ivory);
}

.hero__card-meta {
  font-family: var(--font-quote);
  font-style: italic;
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.7);
}

.hero__card-track {
  position: relative;
  height: 1px;
  margin: 0.8rem 0 0.5rem;
  background: rgba(255, 255, 255, 0.18);
}

.hero__card-track i {
  position: absolute;
  inset: 0;
  background: var(--gold);
  transform-origin: left center;
  transform: scaleX(0);
}

.hero__card-hint {
  font-size: 0.68rem;
  letter-spacing: var(--ls-wide);
  color: rgba(255, 255, 255, 0.6);
  font-variant-numeric: tabular-nums;
}

.hero__card-hint b {
  font-weight: 400;
  color: var(--white);
}

/* ---------- Bottom strip + scroll cue (re-anchored to the stage) ---------- */

/* The old "Scroll" cue is replaced by the hint inside the glass card.
   Remove this rule (and tweak position) if you want it back. */
.hero__scroll {
  display: none;
}

.hero__meta {
  z-index: 6;
}

/* ---------- Tablet / mobile ---------- */

@media (max-width: 900px) {
  .hero {
    height: 100vh;
  }

  .hero__title {
    top: 13%;
    font-size: clamp(3.6rem, 21vw, 8rem);
  }

  .hero__bottle {
    height: 44vh;
    margin: calc(44vh / -2 + 1vh) 0 0 calc(44vh * 0.72 / -2);
  }

  .hero__inner {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    padding: var(--nav-height) 1.25rem 5.5rem;
    text-align: center;
  }

  .hero__col--left,
  .hero__col--right {
    width: 100%;
    max-width: 320px;
  }

  .hero__col--left {
    order: 1;
  }

  .hero__col--right {
    order: 2;
    margin-top: 0.75rem;
  }

  .hero__col--left .hero__eyebrow,
  .hero__sub,
  .hero__title-rule,
  .hero__card,
  .hero__actions .btn-outline--light,
  .hero__scroll {
    display: none;
  }

  .hero__tagline {
    max-width: none;
    font-size: 1.35rem;
  }

  .hero__actions {
    margin-top: 0;
  }
}

@media (max-height: 560px) and (orientation: landscape) {
  .hero {
    height: 100vh;
  }

  .hero__title {
    display: none;
  }

  .hero__bottle {
    height: 58vh;
    margin: calc(58vh / -2) 0 0 calc(58vh * 0.72 / -2);
  }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  .hero__bottle::before { animation: none; }
  .hero__bottle,
  .hero__bottle.is-loaded {
    opacity: 1;
    transform: none;
    filter: none;
    transition: none;
  }
}
