/* Hero scene styles. The curtain and the Bez AI / Z AI switch were removed in unit 59; what remains is the depth-of-field bands, the first-screen
   staging, the Co-CEO caption, the cinematic light overlays and the opening's sentences. */
#experience .dof{position:absolute;inset:0;pointer-events:none;overflow:hidden}
#experience .dof[hidden]{display:none}
#experience .dof i{position:absolute;left:0;right:0;-webkit-backdrop-filter:blur(2.4px);backdrop-filter:blur(2.4px)}
#experience .dof i:first-child{top:0;height:14%;-webkit-mask-image:linear-gradient(#000,#0000);mask-image:linear-gradient(#000,#0000)}
#experience .dof i:last-child{bottom:0;height:18%;-webkit-mask-image:linear-gradient(#0000,#000);mask-image:linear-gradient(#0000,#000)}
/* Unit 51: the first screen, directed one thing at a time. */
/* The city fades in over its own poster, then the poster leaves. */
#experience .city-poster{transition:visibility 0s linear .95s}
#experience #viewport.hero-enter canvas{animation:hero-in .9s ease-out both}
@keyframes hero-in{from{opacity:0}to{opacity:1}}
/* Each firm's first story case lights up in turn with one soft ring. */
#experience .city-signal{white-space:nowrap;will-change:opacity,scale}
#experience .city-signal span{max-width:none}
#experience .city-signal.ignite:after{content:'';position:absolute;inset:-1px;border-radius:inherit;border:2px solid #d9644f;opacity:0;pointer-events:none;animation:sig-ring .9s cubic-bezier(.2,.7,.2,1) forwards}
@keyframes sig-ring{0%{opacity:.9;transform:scale(1)}100%{opacity:0;transform:scale(1.22,1.7)}}
#experience #ai-label{transition:opacity .6s ease-out}
#experience.hero-stage:not(.hero-orb) #ai-label{opacity:0}
/* The Co-CEO caption hangs off the orb on a short leader, on whichever side has room. */
#experience:not(.focused) #ai-label{padding:5px 9px;border-radius:6px;white-space:nowrap;max-width:none;transform:translate(calc(-100% - 44px),-50%)}
#experience:not(.focused) #ai-label.side-r{transform:translate(44px,-50%)}
#experience:not(.focused) #ai-label span{font-size:12px;font-weight:700}
#experience:not(.focused) #ai-label small{font-size:11px;margin-top:1px;display:block}
#experience:not(.focused) #ai-label:before{content:'';position:absolute;top:50%;width:26px;height:1px;background:#4f5f48}
#experience:not(.focused) #ai-label:after{content:'';position:absolute;top:50%;width:5px;height:5px;margin-top:-2px;border-radius:50%;background:#4f5f48}
#experience:not(.focused) #ai-label.side-r:before{right:100%;margin-right:0}
#experience:not(.focused) #ai-label.side-r:after{right:calc(100% + 24px)}
#experience:not(.focused) #ai-label.side-l:before{left:100%}
#experience:not(.focused) #ai-label.side-l:after{left:calc(100% + 24px)}
#experience .view-options>summary{font:600 24px/1 Inter,Arial,sans-serif;padding:0 0 5px;letter-spacing:0}
#experience .view-controls #motion{min-width:44px;white-space:nowrap}
@media(max-width:700px){
 #experience:not(.focused) #ai-label small{display:none}
 #experience:not(.focused) #ai-label{padding:3px 6px;transform:translate(calc(-100% - 26px),-50%)}
 #experience:not(.focused) #ai-label.side-r{transform:translate(26px,-50%)}
 #experience:not(.focused) #ai-label:before{width:14px}
 #experience:not(.focused) #ai-label.side-r:after{right:calc(100% + 12px)}
 #experience:not(.focused) #ai-label.side-l:after{left:calc(100% + 12px)}
}
/* The ⋯ menu opens above the whole card, not over its own label. */
#experience:not(.focused) .control-row{position:static}
/* Unit 57: cinematic light over the baked atlases. One low light from the left of the frame, cool in Bez AI and warm in Z AI, plus a vignette.
   Two alpha layers crossfade by --cp (AI progress) */
#experience .cine{position:absolute;inset:0;pointer-events:none;overflow:hidden;--cp:1}
#experience .cine[hidden]{display:none}
#experience .cine i{position:absolute;inset:0}
#experience .cn-cool{opacity:calc(1 - var(--cp));background:radial-gradient(ellipse 82% 78% at 50% 46%,#0000 54%,#1e2c4247 100%),linear-gradient(96deg,#96b2d63d,#96b2d600 56%)}
#experience .cn-warm{opacity:var(--cp);background:radial-gradient(ellipse 82% 78% at 50% 46%,#0000 58%,#4a281040 100%),linear-gradient(96deg,#ffba7059,#ffba7000 58%)}
#experience .cine.cine-room .cn-cool{background:radial-gradient(ellipse 76% 72% at 50% 46%,#0000 46%,#1e2c4260 100%),linear-gradient(96deg,#96b2d647,#96b2d600 60%)}
#experience .cine.cine-room .cn-warm{background:radial-gradient(ellipse 76% 72% at 50% 46%,#0000 50%,#4a281052 100%),linear-gradient(96deg,#ffba706b,#ffba7000 62%)}
/* Cheaper variants: weaker hardware and every phone keep the vignette (and the side light at "lite"); "min" is the vignette only. */
#experience .cine[data-cine="min"] .cn-cool{background:radial-gradient(ellipse 82% 78% at 50% 46%,#0000 54%,#1e2c4238 100%)}
#experience .cine[data-cine="min"] .cn-warm{background:radial-gradient(ellipse 82% 78% at 50% 46%,#0000 58%,#4a281030 100%)}
/* Miniature depth of field in a room or close-up (full quality, desktop only): thinner, softer bands than the city's. */
#experience .dof.dof-room i{-webkit-backdrop-filter:blur(1.8px);backdrop-filter:blur(1.8px)}
#experience .dof.dof-room i:first-child{height:8%}
#experience .dof.dof-room i:last-child{height:11%}
@media(prefers-reduced-motion:reduce){#experience .cine i{transition:none}}
@media(prefers-reduced-motion:reduce){#experience #ai-label{transition:none}#experience .city-signal.ignite:after,#experience #viewport.hero-enter canvas,#experience #viewport.hero-enter .cine,#experience #viewport.hero-enter .dof,#experience .city-story strong[data-line]{animation:none}}

/* Unit 59: until the baked city is loaded and drawn, the static poster is the first frame and nothing the scene draws is visible
   (the canvas, the light overlay and the depth bands); the code-built city never shows. They arrive together, fading over the poster. */
#experience.scene-gated #viewport>*{visibility:hidden}
#experience:not(.focused).scene-ready #viewport{animation:none}
#experience #viewport.hero-enter .cine,#experience #viewport.hero-enter .dof{animation:hero-in .9s ease-out both}
/* The opening is a scene: one sentence at a time under the headline, and a small link once it has played. */
#experience .city-story strong[data-line]{display:block;animation:line-in .55s ease-out both}
@keyframes line-in{from{opacity:0;translate:0 6px}to{opacity:1;translate:0 0}}
#experience .city-story .hero-replay{pointer-events:auto;margin:6px 0 0;padding:6px 0;border:0;background:none;color:#46523e;font:600 12px/1.2 Inter,Arial,sans-serif;letter-spacing:.02em;text-decoration:underline;text-underline-offset:3px;cursor:pointer;animation:line-in .55s ease-out .25s both}
#experience .city-story .hero-replay:hover{color:#2f6b3a}
#experience .city-story .hero-replay:focus-visible{outline:3px solid #fa835b;outline-offset:3px;border-radius:2px}

#experience .city-story:empty{border-left-color:transparent;border-top-color:transparent}
#experience.scene-gated #ai-label{visibility:hidden!important}
@media(min-width:701px){#experience:not(.focused) .city-story strong[data-line]{font-size:18px}}
/* Phone: the opening's sentences take the slot beside the ⋯ menu (where the switch used to be), under the city. */
@media(max-width:700px){
 #experience .control-row .city-story{flex:1;min-width:0;border:0;padding:0;margin:0;min-height:0;max-width:none;align-self:center;text-align:left}
 #experience .control-row .city-story strong{font-size:14px;line-height:1.3;color:#2f3d33}
 #experience .control-row .city-story .hero-replay{padding:4px 0 0;font-size:12px}
}

/* B2: style B is sharp and fully coloured. No tilt-shift strips and no cool/grey cinematic overlay in any state; Bez AI differs by its red signals,
   the counter and idle people, Z AI by the AI layer (ribbons and window light), never by a grey filter. */
#experience .dof,#experience .cine{display:none!important}
