/* Desktop chapters occupy exactly one viewport; the footer keeps its scroll range. */
@media(min-width:901px) and (prefers-reduced-motion:no-preference){
 .hero-sequence,.scroll-story{height:calc(100svh + 1px)}
 .reveal-track{min-height:100svh}
 #connect,#builder-section,#your-content,#control,.closing{height:100svh;min-height:0;box-sizing:border-box}
 .builder-scene{height:100%;min-height:0;padding:100px var(--gutter) 24px;gap:18px}
 .builder-heading{margin:0;flex:none}
 .builder-root{height:auto;min-height:0;flex:1;width:100%}
 #your-content{display:flex;flex-direction:column;padding:100px 0 20px;gap:16px}
 #your-content>.section-shell{width:100%;flex:none}
 #your-content .section-heading{margin:0}
 #your-content .section-heading h2{font-size:clamp(34px,3.8vw,58px);line-height:1.05}
 .source-rail-toolbar{margin-top:0;margin-bottom:0;flex:none}
 .source-rail{min-height:0;flex:1;padding-top:0;padding-bottom:12px;overflow-y:hidden}
 .social-source{height:100%;flex-shrink:0}
 .source-rail .source-format{margin-bottom:10px}
 .source-rail .source-mount,.source-rail .source-mount.reel{height:calc(100% - 34px);overflow:hidden}
 .source-rail .source-mount>*{transform:scale(var(--source-fit,1));transform-origin:top center}
 #control{display:flex;flex-direction:column;justify-content:center;padding-block:100px 32px}
 #control .section-heading{margin-bottom:clamp(24px,5vh,64px)}
 #control .section-heading h2{font-size:clamp(34px,3.8vw,58px)}
 .closing-track{height:100svh}
 .closing-track>.closing{position:relative;top:auto;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;padding:100px var(--gutter) 40px}
 .closing h2{font-size:clamp(40px,5vw,76px);line-height:1.04;margin:24px 0 32px}
 .v1-tail{margin-top:0}
}
/* No partially overlaid CTA, including narrower layouts. */
.closing-track{height:auto}
.closing-track>.closing{position:relative;top:auto}
.v1-tail{margin-top:0}
.section-reveal-word{display:inline-block;white-space:pre}
#v1-inline-root .blob-ui-content{visibility:hidden;opacity:0!important}
#v1-inline-root .mobile-indications{display:none}
.tail-creator-copy{position:fixed;inset:0;z-index:35;display:flex;align-items:center;justify-content:center;pointer-events:none;padding:110px max(24px,10vw) 80px;color:#fff;opacity:0;visibility:hidden;transition:opacity 220ms ease,visibility 220ms}
.tail-creator-copy.is-visible{opacity:1;visibility:visible}
.tail-creator-copy h2{max-width:1000px;text-align:center;font-size:clamp(28px,3.8vw,54px);font-weight:300;line-height:1.18;letter-spacing:-.035em}
@media(prefers-reduced-motion:reduce){.tail-creator-copy{transition:none}}
@media(min-width:901px) and (max-height:700px) and (prefers-reduced-motion:no-preference){
 .connect-section{padding-top:90px;padding-bottom:16px}
 .connect-intro h2{font-size:32px;margin:8px 0 12px}
 .connect-lead{font-size:14px;line-height:1.4}
 .connect-care{margin-top:10px}
 .connect-steps-list{margin-top:16px}
 .connect-step{padding:8px 0}
 .connect-step p{font-size:13px}
 .connect-trust{margin-top:8px;font-size:11px}
 .connect-body{min-height:min(var(--connect-demo-height,500px),calc(100svh - 200px))}
 .account-row{min-height:44px;padding-top:4px;padding-bottom:4px}
 .account-mark{width:30px;height:30px}
 .connect-head,.connect-actions{padding-top:10px;padding-bottom:10px}
 .app-offer{padding-top:12px;padding-bottom:12px}
 .suggest-lead{font-size:18px;padding-bottom:12px}
 .care-note{padding-top:10px;padding-bottom:10px}
}

/* Only one text scene owns the stage, including during reverse playback. */
#v1-inline-root[data-text-scene]:not([data-text-scene=circle]) .text-picker{visibility:hidden!important;opacity:0!important;pointer-events:none!important}
.tail-creator-copy:not(.is-visible){opacity:0;visibility:hidden;transition:none}
/* An outlined silhouette keeps the logo legible as the content portal expands. */
.hero-logo-transition{position:fixed;inset:0;z-index:20;pointer-events:none;color:var(--ink);will-change:opacity}
.hero-logo-transition[hidden]{display:none}
.hero-logo-transition>.portal-logo{display:block;width:100%;height:100%;overflow:visible}
.portal-logo>g>path{fill:color-mix(in srgb,var(--ink) calc(var(--portal-fill,1)*100%),transparent);stroke:var(--ink);stroke-width:1.5px;stroke-linejoin:round}
.portal-logo>g>circle{fill:color-mix(in srgb,var(--accent) calc(var(--portal-fill,1)*100%),transparent);stroke:var(--accent);stroke-width:1.5px}

/* The CTA stays still while the next chapter covers it. */
@media(min-width:901px) and (prefers-reduced-motion:no-preference){
 .closing-track{height:200svh}
 .closing-track>.closing{position:sticky;top:0}
 .v1-tail{margin-top:-100svh;position:relative;z-index:2}
 #your-content{gap:12px}
 #your-content .section-heading h2{font-size:clamp(26px,2.5vw,40px);line-height:1.1}
 #your-content .source-rail{overflow-x:hidden;scrollbar-width:none}
}
.closing-mark{top:clamp(96px,14svh,150px);bottom:auto;right:clamp(24px,3vw,48px)}

/* The introduction clears as the live demo expands into the whole chapter. */
#builder-section{overflow-anchor:none}
.builder-scene{position:relative}
@media(min-width:901px) and (prefers-reduced-motion:no-preference){
 .builder-scene.is-demo-focused .builder-root{position:absolute;top:88px;bottom:24px;left:24px;right:24px;width:auto;height:auto;max-width:none;transform-origin:top left}
 .builder-scene.is-demo-focused .builder-heading{position:absolute;top:100px;left:var(--gutter);right:var(--gutter);pointer-events:none}
 #builder-section[data-builder-scene=focused] .builder-heading{visibility:hidden}
}

/* Production is the current design with only the unreleased chapters hidden. */
html[data-environment=production] :is(#connect,#builder-section,#your-content,#control){display:none!important}
html[data-environment=production] :is([data-jump-builder],a[href="#connect"],a[href="#your-content"]){display:none!important}
html[data-environment=production] .hero-sequence>.reveal-track{display:none}
html[data-environment=production]{--release-stage-height:max(100svh,640px);--release-scroll-height:calc(var(--release-stage-height) + 1px)}
/* The CTA is revealed as a full viewport, then shrinks to the space above the rising
   footer (closing-stage.mjs). The track stacks above the footer so the watermark can
   spill over it; their boxes never overlap, so only the watermark crosses the seam. */
html[data-environment=production] .closing-track{margin-top:calc(-1 * var(--release-scroll-height));height:var(--release-scroll-height);z-index:12;pointer-events:none}
html[data-environment=production] .closing-track>.closing{position:sticky;top:0;height:var(--release-closing-height,100dvh);min-height:min-content;overflow:visible;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;padding:clamp(96px,12svh,128px) var(--gutter) clamp(40px,6svh,72px)}
html[data-environment=production] .closing-track>.closing[inert]{pointer-events:none}
html[data-environment=production] .closing-mark{pointer-events:none}
html[data-environment=production] #v1-tail{height:auto;min-height:0;margin-top:0;z-index:11;overflow:visible;clip-path:none;mask-repeat:no-repeat;-webkit-mask-repeat:no-repeat;mask-mode:alpha}
html[data-environment=production] #v1-inline-root .scroll-container{height:auto;min-height:0}
html[data-environment=production] #v1-inline-root .footer-wrapper{margin-top:0}
html[data-environment=production] #v1-inline-root :is(.content-sticky,.section__wrapper,.name-container,.tail-creator-copy,.controls){display:none!important}
@media(prefers-reduced-motion:reduce){
 html[data-environment=production] .closing-track{margin-top:0;height:auto}
 html[data-environment=production] .closing-track>.closing{position:relative;top:0;height:auto;mask:none!important;-webkit-mask:none!important;opacity:1!important}
}

/* Public teaser chrome has a single sign-up action. Development keeps all controls. */
html[data-environment=production] :is(.site-header nav,.site-header .accent-trigger,.site-header .menu-trigger,#mobile-menu,#intro-actions [data-jump-knowledge]){display:none!important}

/* Each gesture starts one timed hero beat; the custom scrollbar tracks its phase. */
html[data-environment=production] :is(.hero-sequence,.scroll-story){height:var(--release-scroll-height)}
html[data-environment=production] [data-development-only]{display:none!important}
@media(prefers-reduced-motion:reduce){html[data-environment=production] :is(.hero-sequence,.scroll-story){height:auto}html[data-environment=production] #v1-tail{mask:none!important;-webkit-mask:none!important;opacity:1!important}}
/* Let the footer occupy its content height and keep its glass cursor whole at the edge. */
html[data-environment=production] :is(#v1-inline-root,#v1-inline-root main,#v1-inline-root .index__wrapper){height:auto;min-height:0}
html[data-environment=production] #v1-inline-root:not(:hover) .cursor__wrapper{visibility:hidden}
html[data-environment=production] #v1-inline-root .cursor__wrapper .text-wrapper{color:var(--ink)}
html[data-environment=production] #v1-inline-root .footer{display:flex;flex-direction:column;min-height:0;padding:clamp(48px,8svh,96px) clamp(20px,4vw,64px) 0;gap:clamp(24px,4vw,56px);box-sizing:border-box}
html[data-environment=production] #v1-inline-root .footer-slogan{padding:0;margin:0;max-width:none;opacity:1!important;transform:none!important}
html[data-environment=production] #v1-inline-root .logo-wrapper{padding:0;width:100%;height:auto}
html[data-environment=production] #v1-inline-root .logo-wrapper svg{display:block;width:100%;height:auto}
html[data-environment=production] #v1-inline-root .content-size{display:none}
html[data-environment=production] #v1-inline-root .footer>.legal-links{display:flex!important;position:relative;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;margin:0;padding:0 0 max(16px,env(safe-area-inset-bottom));pointer-events:auto}
html[data-environment=production] #v1-inline-root .footer>.legal-links button{min-height:44px;font:10px/1.4 'Geist Mono',monospace}
