/* ============================================================================
   GARAGE GALS . THEATRICAL LAYER  ("Showtime")
   ----------------------------------------------------------------------------
   Stages the hero like a theater: a warm spotlight wash, a cinematic vignette
   to focus the centre, and a row of glowing gold "footlight" bulbs along the
   stage edge. Pairs with the gold CTA system. Pure CSS, GPU-friendly.
   ============================================================================ */

/* --- Warm spotlight washing the hero from above-centre --------------------- */
.hero__spotlight {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(58% 48% at 50% 30%,
    rgba(255, 224, 150, 0.22) 0%,
    rgba(230, 58, 45, 0.13) 38%,
    transparent 72%);
  mix-blend-mode: screen;
  animation: gg-spot 7.5s ease-in-out infinite;
  will-change: transform, opacity;
}
@keyframes gg-spot {
  0%, 100% { opacity: 0.88; transform: scale(1) translateY(0); }
  50%      { opacity: 1;    transform: scale(1.05) translateY(-1%); }
}

/* --- Cinematic vignette: darken the edges, focus the stage ----------------- */
.hero__vignette {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(125% 86% at 50% 36%,
    transparent 50%,
    rgba(0, 0, 0, 0.42) 78%,
    rgba(0, 0, 0, 0.66) 100%);
}

/* --- Gold footlight bulbs along the bottom stage edge ---------------------- */
.hero__footlights {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 34px;
  z-index: 3;
  pointer-events: none;
  background:
    radial-gradient(circle at center,
      #FFEFC2 0,
      #F4D572 1.7px,
      rgba(244, 213, 114, 0) 4.2px) bottom left / 34px 34px repeat-x;
  filter:
    drop-shadow(0 -3px 7px rgba(244, 213, 114, 0.55))
    drop-shadow(0 0 2px rgba(255, 239, 194, 0.9));
  animation: gg-footlights 2.6s ease-in-out infinite;
}
.hero__footlights::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 150px;
  background: linear-gradient(to top, rgba(244, 213, 114, 0.12), transparent 80%);
  pointer-events: none;
}
@keyframes gg-footlights {
  0%, 100% { opacity: 0.7; }
  50%      { opacity: 1; }
}

/* --- Curtain-up entrance: the stage lifts into the lights on load ---------- */
.js .hero__content { animation: gg-curtain-up 1100ms cubic-bezier(0.16, 1, 0.3, 1) both; }
@keyframes gg-curtain-up {
  from { opacity: 0; transform: translateY(26px) scale(0.985); filter: brightness(0.6); }
  to   { opacity: 1; transform: translateY(0)    scale(1);     filter: brightness(1); }
}

/* --- Respect reduced-motion ------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  .hero__spotlight,
  .hero__footlights { animation: none; }
  .js .hero__content { animation: none; }
}

/* ============================================================================
   ACT 2 . THE REVEAL  (scroll-pinned cinematic before/after)
   The "before" wipes away to the "after" as you scroll. Driven by --p (0..1)
   set on .reveal-act__stage by js/reveal-act.js.
   ============================================================================ */
.reveal-act { position: relative; background: #000; }
.reveal-act__scroll { height: 220vh; }
.reveal-act__pin {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
}
.reveal-act__stage { position: absolute; inset: 0; --p: 0; }

.reveal-act__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
/* the messy "before" on top, clipped away from the left as you scroll */
.reveal-act__beforewrap {
  position: absolute;
  inset: 0;
  z-index: 2;
  clip-path: inset(0 0 0 calc(var(--p) * 100%));
  will-change: clip-path;
}

/* glowing gold wipe seam that tracks the reveal edge */
.reveal-act__seam {
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--p) * 100%);
  width: 3px;
  margin-left: -1.5px;
  z-index: 4;
  background: linear-gradient(180deg, rgba(255,239,194,0) 0%, #F4D572 16%, #FFEFC2 50%, #F4D572 84%, rgba(255,239,194,0) 100%);
  box-shadow: 0 0 16px rgba(244,213,114,0.85), 0 0 44px rgba(244,213,114,0.45);
  will-change: left;
  opacity: calc(0.25 + var(--p) * 0.75);
}

/* cinematic vignette + a top scrim so the headline stays legible */
.reveal-act__vignette {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(0,0,0,0.74) 0%, rgba(0,0,0,0.18) 28%, transparent 46%),
    radial-gradient(135% 92% at 50% 42%, transparent 54%, rgba(0,0,0,0.58) 100%);
}

/* before / after chips */
.reveal-act__tag {
  position: absolute;
  bottom: clamp(2.4rem, 1.6rem + 2vw, 3.4rem);
  z-index: 5;
  font-family: var(--font-mono);
  font-size: var(--fs-caption);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 0.42rem 0.95rem;
  border-radius: 999px;
  background: rgba(0,0,0,0.5);
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
  border: 1px solid rgba(255,255,255,0.18);
  color: var(--cream-50);
}
.reveal-act__tag--after  { left: clamp(1rem, 0.4rem + 2vw, 2.6rem); border-color: rgba(244,213,114,0.6); color: #F4D572; }
.reveal-act__tag--before { right: clamp(1rem, 0.4rem + 2vw, 2.6rem); }

/* title card */
.reveal-act__copy {
  position: absolute;
  top: clamp(3.5rem, 1.5rem + 6vh, 7rem);
  left: 0;
  right: 0;
  z-index: 6;
  text-align: center;
  padding-inline: var(--gutter);
  /* fade the title card out as the "Garage YES!" payoff blooms in */
  opacity: calc(1.2 - var(--p) * 1.7);
}
.reveal-act__title {
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  font-size: clamp(2.6rem, 1.5rem + 5vw, 6rem);
  line-height: 0.98;
  letter-spacing: var(--tracking-tightest);
  color: var(--cream-50);
  text-shadow: 0 4px 30px rgba(0,0,0,0.65);
}
.reveal-act__title em { font-style: italic; color: var(--red-400); }
.reveal-act__cap {
  margin-top: 0.9rem;
  color: rgba(245,239,228,0.85);
  font-size: var(--fs-lead);
  max-width: 42ch;
  margin-inline: auto;
  text-shadow: 0 2px 14px rgba(0,0,0,0.75);
}

/* the payoff blooms in as the clean garage lands */
.reveal-act__payoff {
  position: absolute;
  inset: 0;
  z-index: 6;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 800;
  font-size: clamp(3rem, 1.8rem + 7vw, 8rem);
  color: var(--cream-50);
  text-shadow: 0 0 44px rgba(244,213,114,0.55), 0 6px 30px rgba(0,0,0,0.6);
  opacity: calc((var(--p) - 0.68) * 3.2);
  pointer-events: none;
}
.reveal-act__payoff em { font-style: italic; color: #F4D572; }

/* progress bar = reveal progress */
.reveal-act__progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  z-index: 6;
  background: rgba(255,255,255,0.12);
}
.reveal-act__progress-fill {
  display: block;
  height: 100%;
  width: calc(var(--p) * 100%);
  background: var(--grad-gold-cta, linear-gradient(90deg, #F4D572, #B68A2E));
  box-shadow: 0 0 12px rgba(244,213,114,0.75);
}

/* ============================================================================
   REUSABLE STAGE PARTS . drop into any positioned section
   ============================================================================ */
.stage-spotlight {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(58% 52% at 50% 40%,
    rgba(255, 224, 150, 0.18) 0%, rgba(230, 58, 45, 0.10) 40%, transparent 72%);
  mix-blend-mode: screen;
}
.stage-vignette {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(132% 92% at 50% 46%, transparent 52%, rgba(0,0,0,0.55) 100%);
}
.stage-footlights {
  position: absolute; left: 0; right: 0; bottom: 0; height: 32px; z-index: 3; pointer-events: none;
  background: radial-gradient(circle at center, #FFEFC2 0, #F4D572 1.7px, rgba(244,213,114,0) 4.2px) bottom left / 32px 32px repeat-x;
  filter: drop-shadow(0 -3px 7px rgba(244,213,114,0.5)) drop-shadow(0 0 2px rgba(255,239,194,0.9));
  animation: gg-footlights 2.6s ease-in-out infinite;
}
.stage-footlights::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 140px;
  background: linear-gradient(to top, rgba(244,213,114,0.1), transparent 80%);
}

/* ============================================================================
   ACT 3 . THE METHOD as a lit stage (steps auto-spotlight one at a time)
   ============================================================================ */
#method { position: relative; }
#method .container { position: relative; z-index: 2; }
#method .step { position: relative; transition: opacity 0.55s ease, transform 0.55s ease, filter 0.55s ease; }
/* only dim once the stage is active (lets the entrance reveal play first) */
.js #method.is-staged .step:not(.is-lit) { opacity: 0.62; transform: translateY(2px); }
.js #method.is-staged .step.is-lit { opacity: 1; transform: translateY(-4px); }
#method .step__num { transition: color 0.5s ease, text-shadow 0.5s ease, -webkit-text-fill-color 0.5s ease; }
.js #method.is-staged .step.is-lit .step__num {
  background: var(--grad-gold-cta, linear-gradient(135deg, #F4D572, #B68A2E));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  text-shadow: 0 0 34px rgba(244, 213, 114, 0.5);
}
/* a soft spotlight pooled on the lit step */
.js #method.is-staged .step.is-lit::before {
  content: ""; position: absolute; inset: -28% -14% -18%;
  z-index: -1; pointer-events: none;
  background: radial-gradient(62% 70% at 50% 42%, rgba(255, 224, 150, 0.16), transparent 70%);
}

/* ============================================================================
   ACT 4 . THE FINALE . final CTA staged like the hero (book-end)
   ============================================================================ */
/* overflow:visible so the section divider (footlights + glowing rail) is not
   clipped by .final-cta's overflow:hidden — the bulbs sit above the top edge */
#quote.final-cta { position: relative; overflow: visible; }
#quote .container { position: relative; z-index: 2; }

/* ============================================================================
   ACT 5 . KINETIC TYPE . shimmering gold "metal" on the celebratory words
   ============================================================================ */
.gold-shimmer {
  background: linear-gradient(100deg, #B68A2E 0%, #F4D572 24%, #FFF8E0 46%, #F4D572 62%, #B68A2E 86%);
  background-size: 250% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: gg-sheen 5.5s linear infinite;
}
@keyframes gg-sheen { to { background-position: -250% 0; } }

@media (prefers-reduced-motion: reduce) {
  .stage-footlights { animation: none; }
  .gold-shimmer { animation: none; }
}
