/* Shadu v2 — scroll-driven hero + keychain spotlight */
:root {
  --navy: #13284A;
  --red: #B3262E;
  --sh-vh: 100vh;
}
@supports (height: 100svh) { :root { --sh-vh: 100svh; } }

/* ---------- Scroll hero: static base (no JS / reduced motion) ---------- */
.sh { position: relative; background: var(--cream); }
.sh-stage {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 1rem;
  padding: 2.5rem 1.25rem 3rem;
  max-width: var(--max);
  margin: 0 auto;
}
.sh-giant { display: none; }
.sh-word-0 { display: none; }
.sh-props {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 0.5rem;
  order: 2;
}
.sh-tote, .sh-cue, .sh-panel { display: none; }
.sh-bear img { width: auto; height: min(42vw, 300px); }
.sh-copy { order: 1; }
.sh-copy .hero-title { font-size: clamp(2.3rem, 6vw, 3.6rem); }
@media (min-width: 860px) {
  .sh-stage { grid-template-columns: 1.05fr 1fr; align-items: center; padding-top: 4rem; padding-bottom: 4rem; }
  .sh-props { order: 2; }
}

/* ---------- Animated mode (html.sh-on set by hero.js) ---------- */
html.sh-on .sh { background: transparent; }
html.sh-on .sh-stage {
  display: block;
  max-width: none;
  margin: 0;
  padding: 0;
  height: var(--sh-vh);
  min-height: 520px;
  background: var(--cream);
  isolation: isolate;
}
html.sh-on .sh-giant {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
html.sh-on .sh-word {
  position: absolute;
  left: 0;
  top: 52%;
  width: 100%;
  text-align: center;
  font-family: var(--font);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.035em;
  line-height: 0.86;
  font-size: min(13.5vw, 19vh);
  white-space: nowrap;
  opacity: 0;
  will-change: transform, opacity;
}
html.sh-on .sh-word em { font-style: normal; color: var(--red); }
html.sh-on .sh-word-0 { display: flex; flex-direction: column; align-items: center; opacity: 1; color: var(--green); }
html.sh-on .sh-word-0 .sh-ar {
  font-family: var(--arabic);
  font-weight: 700;
  font-size: min(44vw, 52vh);
  line-height: 1;
  letter-spacing: 0;
  opacity: 0.09;
  text-transform: none;
}
html.sh-on .sh-word-0 .sh-en {
  margin-top: -0.32em;
  font-size: min(21vw, 24vh);
  letter-spacing: -0.04em;
  opacity: 0.12;
}
html.sh-on .sh-word-1 { color: var(--green); }
html.sh-on .sh-word-2 { color: var(--cream-soft); }
html.sh-on .sh-word-2 em { color: var(--tan-soft); }
html.sh-on .sh-word-3 { color: var(--cream-soft); }
html.sh-on .sh-word-3 em { color: #E0525A; }

html.sh-on .sh-props {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}
html.sh-on .sh-bear,
html.sh-on .sh-tote {
  display: block;
  position: absolute;
  left: 50%;
  top: 50%;
  width: auto;
  will-change: transform;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
html.sh-on .sh-bear img {
  height: calc(var(--sh-vh) * 0.5);
  width: auto;
  max-width: none;
  filter: drop-shadow(0 18px 24px rgba(15, 30, 40, 0.22));
  animation: sh-float 5.5s ease-in-out infinite;
}
html.sh-on .sh-girl img { animation-delay: -2.6s; }
html.sh-on .sh-tote { height: calc(var(--sh-vh) * 0.6); }
html.sh-on .sh-tote-back { z-index: 1; filter: drop-shadow(0 16px 18px rgba(0, 0, 0, 0.22)); }
html.sh-on .sh-bear { z-index: 2; }
/* front panel of the bag (below the opening) sits over the bears */
html.sh-on .sh-tote-front { z-index: 3; clip-path: inset(39.8% 0 0 0); -webkit-clip-path: inset(39.8% 0 0 0); }

@keyframes sh-float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-12px) rotate(1.2deg); }
}

html.sh-on .sh-copy {
  position: absolute;
  z-index: 4;
  left: 0;
  right: 0;
  top: 0;
  padding: calc(var(--sh-vh) * 0.05) 1.25rem 0;
  max-width: var(--max);
  margin: 0 auto;
  will-change: transform, opacity;
}
html.sh-on .sh-copy-inner { max-width: 29rem; }
html.sh-on .sh-copy .hero-lede { font-size: 1rem; }

html.sh-on .sh-cue {
  display: flex;
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 1.1rem;
  transform: translateX(-50%);
  margin: 0;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
html.sh-on .sh-cue::after {
  content: "";
  width: 1px;
  height: 28px;
  background: currentColor;
  animation: sh-cue 1.8s ease-in-out infinite;
  transform-origin: top;
}
@keyframes sh-cue { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(0); transform-origin: bottom; } }

html.sh-on .sh-panel {
  display: flex;
  position: absolute;
  z-index: 6;
  left: 0;
  right: 0;
  bottom: 0;
  height: 100%;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  padding: calc(var(--sh-vh) * 0.12) 1.25rem 0;
  background: var(--cream);
  border-radius: 2.25rem 2.25rem 0 0;
  box-shadow: 0 -30px 60px rgba(0, 0, 0, 0.18);
  transform: translateY(102%);
  will-change: transform;
}
html.sh-on .sh-panel .eyebrow { font-size: 0.8rem; }
.sh-panel-title {
  margin: 0;
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2rem, 6vw, 4.2rem);
  line-height: 1.05;
  color: var(--green);
}

/* Desktop: copy left, bears right */
@media (min-width: 860px) {
  html.sh-on .sh-word-0 { left: 0; width: 100%; }
  html.sh-on .sh-word-1, html.sh-on .sh-word-2, html.sh-on .sh-word-3 { top: 42%; }
  html.sh-on .sh-copy { top: 50%; transform: translateY(-50%); padding-top: 0; }
  html.sh-on .sh-copy .hero-title { font-size: clamp(2.6rem, 4.6vw, 4rem); }
}
/* Mobile */
@media (max-width: 859px) {
  html.sh-on .sh-bear img { height: calc(var(--sh-vh) * 0.27); }
  html.sh-on .sh-word { top: 36%; }
  html.sh-on .sh-word-0 { top: 47%; }
  html.sh-on .sh-tote { height: calc(var(--sh-vh) * 0.46); }
  html.sh-on .sh-copy .hero-title { font-size: clamp(1.9rem, 8.4vw, 2.6rem); margin-bottom: 0.6rem; }
  html.sh-on .sh-copy .arabic-mark { display: none; }
  html.sh-on .sh-copy .hero-lede { font-size: 0.92rem; margin-bottom: 0.7rem; line-height: 1.5; }
  html.sh-on .sh-copy .hero-status { margin-bottom: 0.9rem; }
  html.sh-on .sh-copy .hero-cta { gap: 0.5rem; }
  html.sh-on .sh-copy .hero-cta .btn { padding: 0.65rem 1.05rem; font-size: 0.85rem; }
  html.sh-on .sh-word { font-size: min(15.5vw, 15vh); }
}
@media (max-width: 859px) and (max-height: 700px) {
  html.sh-on .sh-copy .hero-status { display: none; }
}

/* ---------- Keychain spotlight ---------- */
.spot {
  position: relative;
  background: var(--navy);
  color: var(--cream-soft);
  overflow: hidden;
}
.spot-stage { padding: 4rem 0; }
.spot-grid { display: grid; gap: 2rem; align-items: center; }
.spot-visual {
  position: relative;
  height: min(78vw, 440px);
  display: grid;
  place-items: center;
}
.spot-ring {
  position: absolute;
  width: min(72vw, 420px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 45%, rgba(224, 82, 90, 0.55), rgba(179, 38, 46, 0.25) 45%, transparent 70%);
}
.spot-boy, .spot-girl {
  position: absolute;
  height: 92%;
  width: auto;
  max-width: none;
  filter: drop-shadow(0 24px 34px rgba(0, 0, 0, 0.45));
  will-change: transform;
}
.spot-boy { z-index: 2; transform: translateX(-14%); }
.spot-girl { z-index: 1; height: 70%; transform: translateX(46%) translateY(10%) rotate(8deg); opacity: 0.95; }
.spot-copy .eyebrow { color: var(--tan-soft); }
.spot-title {
  margin: 0 0 0.75rem;
  font-family: var(--font);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.03em;
  line-height: 0.92;
  font-size: clamp(2.3rem, 6.4vw, 4.6rem);
  color: var(--cream-soft);
}
.spot-lede { margin: 0 0 1rem; color: rgba(255, 251, 243, 0.82); max-width: 32rem; }
.spot-list { margin: 0 0 1.2rem; padding: 0; list-style: none; display: grid; gap: 0.45rem; font-size: 0.95rem; }
.spot-list li { position: relative; padding-left: 1.3rem; color: rgba(255, 251, 243, 0.9); }
.spot-list li::before { content: ""; position: absolute; left: 0; top: 0.55em; width: 0.5rem; height: 0.5rem; border-radius: 50%; background: #E0525A; }
.spot-price { margin: 0 0 1.2rem; font-size: 1.5rem; font-weight: 700; color: var(--cream-soft); }
.spot-price .demo-tag { vertical-align: middle; }
.spot-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
.spot .btn-primary { background: var(--cream-soft); color: var(--navy); box-shadow: 0 10px 28px rgba(0, 0, 0, 0.3); }
.spot .btn-primary:hover, .spot .btn-primary:focus-visible { background: #fff; }
.spot .spot-ghost { color: var(--cream-soft); }
@media (min-width: 860px) {
  .spot-grid { grid-template-columns: 1.1fr 1fr; gap: 3rem; }
  .spot-visual { height: min(70vh, 560px); }
  .spot-ring { width: min(46vw, 540px); }
  html.sh-on .spot-stage { min-height: var(--sh-vh); display: flex; align-items: center; padding: 3rem 0; }
  html.sh-on .spot-stage > .wrap { width: 100%; }
}

/* the lineup section follows the panel up */
html.sh-on .sh-next { position: relative; z-index: 1; margin-top: calc(var(--sh-vh) * -0.62); padding-top: 0; }

@media (prefers-reduced-motion: reduce) {
  .sh-bear img, .sh-cue::after { animation: none !important; }
}
.spot .demo-tag { color: var(--tan-soft); border-color: rgba(221, 176, 129, 0.6); background: rgba(221, 176, 129, 0.12); }
html.sh-on .spot-boy, html.sh-on .spot-girl { transform: none; }

/* open straight into the animation */
.sh-copy, html.sh-on .sh-copy { display: none !important; }
