/* Dunes storyboard, toggled by data-scene="dunes" on <html>. */
html[data-scene="dunes"] { --hero-pin: 610vh; /* 960vh -> 720vh -> 610vh (2026-10-06, the intro a little quicker); easing curve unchanged */ --story-why-tail: 0.0108695652173913; }
html[data-scene="dunes"] .hero-content,
html[data-scene="dunes"] .hero-partners {
  visibility: visible;
  transition: visibility 0s;
}
/* Initial reveal belongs to ui.js, independently of the 3D model or scroll. */
html[data-scene="dunes"] .story-copy-out .hero-content,
html[data-scene="dunes"] .story-copy-out .hero-partners {
  visibility: hidden;
  pointer-events: none;
  transition-delay: 0.85s; /* let the existing line masks finish, even at rest */
}
/* Overlap the empty tail of the hero, so Why us is already pinned at EQ completion. */
html[data-scene="dunes"] .s-why {
  margin-top: calc(-100vh - var(--hero-pin) * var(--story-why-tail));
  /* Native and smooth-scroll anchors must cross the EQ handoff despite pixel rounding. */
  scroll-margin-top: -1px;
}
html[data-scene="dunes"]:not(.story-why-active) .s-why {
  pointer-events: none;
}
/* Section stays hidden until story-why-in fires at EQ completion (story-handoff.js); its
   text is still under its own masks at that instant, so the page's standard line-rise
   plays in view instead of the block simply appearing already open. */
html[data-scene="dunes"] .why-head,
html[data-scene="dunes"] .waveform { visibility: hidden; }
html[data-scene="dunes"].story-why-in .why-head,
html[data-scene="dunes"].story-why-in .waveform { visibility: visible; }

/* ...and the phrases wait under their masks until then, with no transition to unwind */
html[data-scene="dunes"]:not(.story-why-in) .why-line .rli {
  transform: translateY(var(--rise-mask));
  transition: none;
}
@media (prefers-reduced-motion: reduce) {
  html[data-scene="dunes"] { --hero-pin: 200vh; }
  html[data-scene="dunes"] .why-head,
  html[data-scene="dunes"] .waveform,
  html[data-scene="dunes"] .why-line .rli,
  html[data-scene="dunes"] .hero-content,
  html[data-scene="dunes"] .hero-partners { transition: none !important; }
}
