/* The document remains the native scroll surface. The landing scenes are
   composed in this fixed viewport; the controller supplies their travel. */
.landing-viewport { display: contents; }
.landing-scroll-space { display: none; }
body.landing-fixed .landing-scroll-space { display: block; pointer-events: none; }
body.landing-fixed {
  overflow-x: hidden;
}

body.landing-fixed .landing-viewport {
  position: fixed;
  display: block;
  inset: 0;
  z-index: 0;
  height: 100svh;
  overflow: clip;
  isolation: isolate;
  background: #0c0e16;
}

body.landing-fixed .landing-viewport > #main {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

body.landing-fixed .landing-scene {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: auto;
  min-height: 100svh;
  opacity: 0;
  pointer-events: none;
  z-index: 0;
  visibility: hidden;
  overflow: clip;
  overflow-anchor: none;
}

body.landing-fixed .landing-scene[data-scene-visible="true"] {
  visibility: visible;
  will-change: transform, opacity;
}

body.landing-fixed .landing-scene[data-scene-active="true"] {
  opacity: 1;
  pointer-events: auto;
}

/* The outer scroll stage now owns all travel. Keep the existing hero and
   research layouts, but remove their old document-length sticky spacers. */
body.landing-fixed.hero-pinned .cover-group {
  height: 100svh;
  min-height: 100svh;
}

body.landing-fixed.hero-pinned .hero {
  position: relative;
  top: auto;
  height: 100svh;
  min-height: 0;
  overflow: clip;
}

body.landing-fixed.story-pinned .research-story {
  height: auto;
  min-height: 100svh;
}

body.landing-fixed.story-pinned .research-stage {
  position: relative;
  top: auto;
  height: 100svh;
  min-height: 0;
}

/* Short sections fill the frame. Their content may grow beyond one frame,
   including opened answers, journal cards, and footer links on phones. */
body.landing-fixed .buyer-tension,
body.landing-fixed .review,
body.landing-fixed .connected,
body.landing-fixed .buyer-questions,
body.landing-fixed .journal,
body.landing-fixed .finale,
body.landing-fixed .site-footer {
  min-height: 100svh;
  height: auto;
}

body.landing-fixed .buyer-tension,
body.landing-fixed .review,
body.landing-fixed .connected,
body.landing-fixed .buyer-questions,
body.landing-fixed .journal,
body.landing-fixed .site-footer {
  padding-top: max(105px, calc(var(--header, 86px) + 24px));
}

body.landing-fixed .finale-copy {
  padding-top: max(120px, calc(var(--header, 86px) + 24px));
}

@media (max-width: 600px) {
  body.landing-fixed .buyer-tension,
  body.landing-fixed .review,
  body.landing-fixed .connected,
  body.landing-fixed .buyer-questions,
  body.landing-fixed .journal,
  body.landing-fixed .site-footer {
    padding-top: calc(var(--header, 80px) + 24px + env(safe-area-inset-top, 0px));
  }

  body.landing-fixed .finale-copy {
    padding-top: calc(var(--header, 80px) + 24px + env(safe-area-inset-top, 0px));
  }
}

@media (prefers-reduced-motion: reduce) {
  body.landing-fixed .landing-scene {
    transition: none;
  }
}
