/* Native demo director: a single compact surface, with details only on demand.
   range-polish.js reserves the actual measured dock height for the network. */
#aegis-demo-session{position:fixed;z-index:9600;inset:auto 0 0;display:none;max-height:min(380px,46dvh);overflow:auto;padding:10px 22px 7px;box-sizing:border-box;color:#e9f2ff;background:linear-gradient(110deg,#071321 0%,#091629 65%,#0b2031 100%);border-top:1px solid #225672;box-shadow:0 -12px 36px #01091455;font:13px/1.4 "Century Gothic","Segoe UI",sans-serif;scrollbar-gutter:stable;overscroll-behavior:contain}
#aegis-demo-session.is-open{display:flex;flex-direction:column}#aegis-demo-session *{box-sizing:border-box}#aegis-demo-session>header,#aegis-demo-session>div,#aegis-demo-session>footer,#aegis-demo-session>label{flex-shrink:0}
#aegis-demo-session .demo-session-head{display:flex;align-items:center;gap:18px;margin:0 0 7px;padding:0;border:0;position:static;z-index:auto;background:none;box-shadow:none;backdrop-filter:none;min-width:0;min-height:0;height:auto}
.demo-title{flex:1;min-width:0}.demo-session-kicker{font-size:11px;letter-spacing:.13em;color:#45d6ff;font-weight:700}.demo-mode{margin-left:9px;padding:2px 5px;border-radius:4px;background:#142b3d;color:#b9cddc;font-size:10px;letter-spacing:.06em}.demo-title h2{font-size:15px;line-height:1.2;margin:3px 0 0;color:#f0f6ff;font-weight:700;overflow-wrap:anywhere}
.demo-progress{display:flex;gap:14px;align-items:center;flex-shrink:0}.demo-progress span{display:flex;gap:5px;align-items:center;color:#a2b8cc;font-size:11px;white-space:nowrap}.demo-progress i{display:grid;place-items:center;width:19px;height:19px;border:1px solid #2a4057;border-radius:50%;font-style:normal;font-size:10px}.demo-progress .is-current{color:#52daff}.demo-progress .is-current i{border-color:#39ccf8;background:#123b50;box-shadow:0 0 12px #12b8f333}.demo-progress .is-complete{color:#8fc7bc}.demo-progress .is-complete i{border-color:#2e7065;background:#11372f}
.demo-observation{display:flex;align-items:center;gap:18px;min-height:32px}.demo-caption{flex:1;min-width:0;max-height:3.2em;overflow:auto;color:#f1f7ff;font-size:15px;line-height:1.45;padding:0 0 5px;overflow-wrap:anywhere}.demo-phase{font-size:11px;font-weight:600;white-space:nowrap;color:#91b3cf}
.demo-story{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;padding:6px 0 7px;border-top:1px solid #173146;border-bottom:1px solid #173146}.demo-story>div{min-width:0;display:flex;gap:8px;align-items:baseline}.demo-story span{font-size:11px;letter-spacing:.11em;color:#89afcb;white-space:nowrap;font-weight:700}.demo-story strong{color:#cadcec;font-size:13px;font-weight:500;overflow-wrap:anywhere}.demo-story>div:nth-child(2) span{color:#e2b365}.demo-story>div:nth-child(3) span{color:#61d6b0}
.demo-session-controls{display:flex;align-items:center;gap:10px;justify-content:space-between;margin-top:7px;min-width:0}.demo-primary,.demo-client{display:flex;gap:6px;align-items:center;flex-wrap:wrap;min-width:0}.demo-client{margin-left:auto;flex-shrink:0}
#aegis-demo-session button,#aegis-demo-session select{font:600 13px/1.2 "Century Gothic","Segoe UI",sans-serif;min-height:34px;max-width:100%;padding:6px 9px;border-radius:6px;border:1px solid #294960;background:#0c1e30;color:#d8e9f8;cursor:pointer;white-space:normal}
#aegis-demo-session .demo-session-head>button{font-size:19px;line-height:1;min-width:30px;padding:4px;flex-shrink:0;background:transparent;border-color:transparent;color:#a1b8cb}
#aegis-demo-session button:focus-visible,#aegis-demo-session select:focus-visible{outline:2px solid #58d9ff;outline-offset:2px}#aegis-demo-session button:hover:not(:disabled){border-color:#51bad9;background:#143247}#aegis-demo-session button:disabled{opacity:.48;cursor:not-allowed}#aegis-demo-session button.demo-cta{background:#19badf;border-color:#46d7f7;color:#031820;font-weight:800}#aegis-demo-session button.demo-cta:hover:not(:disabled),#aegis-demo-session button.demo-cta:focus-visible{background:#62e0f7;border-color:#62e0f7;color:#03121e}#aegis-demo-session button.demo-mlc-link{background:#102c42;color:#70dcff;border-color:#29617a}#aegis-demo-session button[aria-expanded=true]{border-color:#5bcce9;color:#65e0ff;background:#12344a}
.demo-speed select{min-width:58px}.demo-consent{display:flex;align-items:center;gap:7px;margin:6px 0 0;color:#a5bbce;font-size:11px}.demo-consent input{accent-color:#21bddf}.demo-footer-status{display:flex;justify-content:space-between;gap:16px;margin-top:5px;color:#a5b9cc;font-size:11px;line-height:1.35}.demo-visual-state{text-align:right;color:#90acc0}.demo-sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.demo-drawer{flex:0 1 210px;min-height:0;margin:9px 0 0;padding:10px 0 4px;border-top:1px solid #2c4b63;max-height:210px;overflow:auto;overscroll-behavior:contain}.demo-drawer-heading{position:sticky;top:0;z-index:1;display:flex;align-items:center;gap:10px;margin-bottom:8px;background:#091629}.demo-drawer-heading b{font-size:12px;color:#d6efff}.demo-drawer-heading>span{font-size:11px;color:#adc1d4;margin-right:auto}.demo-drawer-heading>button:last-child{margin-left:auto}.demo-script ol{list-style:none;margin:0;padding:0;display:grid;gap:7px}.demo-script li{padding:5px 10px;border-left:2px solid #24b9df;background:#0a1c2e}.demo-script li>span{font-size:11px;text-transform:uppercase;letter-spacing:.08em;color:#73bfd8}.demo-script p{margin:3px 0;font-size:14px;line-height:1.5;color:#d3e6f4}.demo-note{font-size:12px;color:#8ca7c1;line-height:1.4}.demo-proof-summary{display:grid;gap:5px;color:#adc5da;font-size:11px}.demo-proof-summary b{color:#d4e8f5;margin-right:7px}.demo-evidence details>summary{font-size:12px;cursor:pointer;color:#58d6f5}.demo-evidence pre{font-size:12px;white-space:pre-wrap;word-break:break-word;color:#b5d2e8;max-height:150px;overflow:auto}
/* Retire the competing presentation windows only while the director owns the run. */
.aegis-demo-active #nar,.aegis-demo-active #dcc-dest,.aegis-demo-active #nexus-net-banner{display:none!important}
/* The accessibility entry remains usable, above the reserved dock. Common native
   IDs are scoped so an unrelated details element is never repositioned. */
.aegis-demo-active #aegis-topology-a11y,.aegis-demo-active #accessible-topology,.aegis-demo-active #a11y-topology,.aegis-demo-active #aegisAccessibleTopology{bottom:calc(var(--aegis-session-height,180px) + 10px)!important;left:12px!important;right:auto!important;max-width:min(320px,35vw);z-index:9500!important}
.aegis-demo-focusing #nodes .node{opacity:.42;transition:opacity .45s ease}.aegis-demo-focusing #nodes .node.demo-observed,.aegis-demo-focusing #nodes .node.demo-blocked{opacity:1}.aegis-demo-active .node.demo-observed .chassis{stroke:#35dbff!important;stroke-width:3;filter:drop-shadow(0 0 10px #12c7ff99);animation:demo-node-bloom 2.4s ease-in-out var(--demo-focus-delay,0ms) infinite}.aegis-demo-active .node.demo-blocked .chassis{stroke:#fb7c87!important;stroke-width:3;filter:drop-shadow(0 0 10px #f5658299)}.demo-focus-ring{fill:none;stroke:#3adbff;stroke-width:1.5;opacity:.6;pointer-events:none;transform-box:fill-box;transform-origin:center;animation:demo-focus-ripple 2.4s ease-out var(--demo-focus-delay,0ms) infinite}.demo-blocked .demo-focus-ring{stroke:#ff8991}.demo-evaluated-route{fill:none;stroke:#39dcf6;stroke-width:3;stroke-dasharray:8 14;animation:demo-route-motion 1.2s linear infinite;pointer-events:none}
@keyframes demo-route-motion{to{stroke-dashoffset:-44}}@keyframes demo-focus-ripple{0%{opacity:.85;transform:scale(.96)}70%,100%{opacity:0;transform:scale(1.13)}}@keyframes demo-node-bloom{0%,100%{stroke-opacity:.8}50%{stroke-opacity:1;filter:drop-shadow(0 0 15px #12c7ffcc)}}
.aegis-demo-active:has(#aegis-demo-session[data-phase=paused]) .demo-focus-ring,.aegis-demo-active:has(#aegis-demo-session[data-phase=paused]) .demo-evaluated-route,.aegis-demo-active:has(#aegis-demo-session[data-phase=paused]) .demo-observed .chassis{animation-play-state:paused}
@media(max-width:1100px){#aegis-demo-session{padding:9px 14px 7px}.demo-progress{gap:8px}.demo-progress span{font-size:11px}.demo-title h2{font-size:14px}.demo-caption{font-size:14px}.demo-story{gap:10px}.demo-story>div{gap:4px;flex-direction:column}.demo-session-controls{gap:6px}}
@media(max-width:800px){.demo-progress{display:none}.demo-session-controls{align-items:flex-start;flex-wrap:wrap}.demo-client{margin-left:0}.demo-footer-status{flex-direction:column;gap:2px}.demo-visual-state{text-align:left}.demo-phase{display:none}.demo-story strong{font-size:12px}#aegis-demo-session{max-height:48dvh}.demo-title h2{font-size:13px}}
@media(prefers-reduced-motion:reduce){.demo-focus-ring,.demo-evaluated-route,.demo-observed .chassis{animation:none!important}.demo-focus-ring{opacity:.5}.aegis-demo-focusing #nodes .node{transition:none}.demo-observed .chassis,.demo-blocked .chassis{filter:none!important}}
.aegis-demo-overview #nodes .node .chassis{animation:demo-overview 2.2s ease-in-out infinite;stroke:#3b96b5!important}@keyframes demo-overview{0%,100%{stroke-opacity:.45}50%{stroke-opacity:1;filter:drop-shadow(0 0 6px #1cbedd66)}}
.aegis-demo-active:has(#aegis-demo-session[data-phase=paused]).aegis-demo-overview #nodes .node .chassis{animation-play-state:paused}@media(prefers-reduced-motion:reduce){.aegis-demo-overview #nodes .node .chassis{animation:none!important}}
/* Waiting for audio never advances the visible effect timeline. */
.aegis-demo-active:has(#aegis-demo-session[data-motion=hold]) .demo-focus-ring,.aegis-demo-active:has(#aegis-demo-session[data-motion=hold]) .demo-evaluated-route,.aegis-demo-active:has(#aegis-demo-session[data-motion=hold]) .demo-observed .chassis,.aegis-demo-active:has(#aegis-demo-session[data-motion=hold]).aegis-demo-overview #nodes .node .chassis{animation-play-state:paused}
/* Focus is a camera operation on the original graph. Hide context only while
   inspecting one member; Full network restores all native objects. */
.aegis-demo-scene #nodes .node:not(.demo-observed){visibility:hidden}
.aegis-demo-scene #edges,.aegis-demo-scene #groups{visibility:hidden}
.aegis-demo-scene .demo-focus-ring{display:none}
.aegis-demo-scene #stage .node.demo-observed .chassis{animation:none!important;filter:none!important;stroke:#35dbff!important;stroke-width:2}
/* The compact control-evaluation scene: one large measured control state, a short phase
   marker and the two declared flow outcomes side by side, all readable at 1366×768. The
   identifiers stay in the expandable Evidence drawer instead of filling this surface. */
.demo-control-scene{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr) minmax(0,1fr);gap:14px;border-block:1px solid #294960;padding:7px 0}
.demo-control-scene>div{min-width:0;display:flex;flex-direction:column;gap:3px}
.demo-control-scene>div>span{color:#9fbdd4;font-size:11px;font-weight:700;letter-spacing:.07em;text-transform:uppercase;overflow-wrap:anywhere}
.demo-control-scene small span{color:inherit;font:inherit}
.demo-control-scene strong{font-size:14px;color:#f1f7ff;overflow-wrap:anywhere}
.demo-control-now strong{display:flex;align-items:center;gap:9px;flex-wrap:wrap}
.demo-control-scene small{font-size:11px;color:#a6bed1;overflow-wrap:anywhere}
.demo-control-scene small em{font-style:normal;font-weight:700;color:#cfe3f3}
.demo-control-scene .demo-control-note{color:#ffe5a1}
.demo-control-scene b{display:inline-block;padding:1px 11px;border:1px solid #73d6ed;border-radius:5px;color:#bdf5ff;font:800 21px/1.25 "Century Gothic","Segoe UI",sans-serif;letter-spacing:.04em}
.demo-control-scene b[data-control-state=OFF]{color:#ffd0aa;border-color:#e2a46b}
.demo-control-scene b[data-control-state=PENDING],.demo-control-scene b[data-control-state=UNKNOWN]{color:#ffe5a1;border-color:#dec680}
/* Lane identity, not a verdict: the prohibited and approved flows differ by label, border
   shape and hue so the pair is never confused, whatever either result turns out to be. */
.demo-flow{padding-left:10px;border-left:3px solid #56607e}
.demo-flow[data-flow=prohibited]{border-left-style:dashed;border-left-color:#b48cf8}
.demo-flow[data-flow=approved]{border-left-style:solid;border-left-color:#3fb8a4}
.demo-flow strong{font:800 19px/1.2 "Century Gothic","Segoe UI",sans-serif}
.demo-flow strong i{font-style:normal;font-size:11px;font-weight:700;letter-spacing:.08em;text-transform:uppercase}
.demo-scene-nav{display:flex;gap:6px;margin-top:5px}
#aegis-demo-session .demo-scene-nav button{min-height:28px;font-size:12px}
#aegis-demo-session .demo-sections{display:flex;flex-wrap:wrap;padding:3px 0;gap:4px}
#aegis-demo-session .demo-sections button{font-size:12px;min-height:29px;padding:4px 7px}
/* Collapsed selector: all eight destinations stay present, operable and labeled, on one
   scrollable row, so the running scene keeps the vertical space. */
#aegis-demo-session .demo-sections[data-compact=true]{flex-wrap:nowrap;overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:thin}
#aegis-demo-session .demo-sections[data-compact=true] button{min-height:25px;padding:2px 7px;font-size:11px;white-space:nowrap;flex:0 0 auto}
#aegis-demo-session{max-height:min(304px,40dvh)}
/* Reading evidence or the script deliberately borrows more height; the scene alone does not. */
#aegis-demo-session[data-drawer=script],#aegis-demo-session[data-drawer=evidence]{max-height:min(470px,56dvh)}
.demo-phase-table{width:100%;border-collapse:collapse;margin:5px 0 0;font-size:11px;color:#c6dcec}
.demo-phase-table th,.demo-phase-table td{border:1px solid #23415a;padding:3px 6px;text-align:left;overflow-wrap:anywhere}
.demo-phase-table thead th{color:#9fbdd4;font-size:10px;letter-spacing:.06em;text-transform:uppercase}
/* Saved-control panel: a pending or unknown state is never coloured as a success, and
   a measured flow result stays neutral so neither outcome is pre-painted as good news. */
.demo-control-scene strong[data-flow-result=PENDING],.demo-control-scene strong[data-flow-result=UNKNOWN]{color:#ffe5a1}
/* A retained value is explicitly stale, never the current measured result. */
.demo-control-scene strong[data-flow-stale=true]{color:#ffe5a1}
.demo-control-scene strong[data-flow-stale=true] i{color:#ffbf6b}
.demo-control-scene .demo-control-class{grid-column:1/-1;margin:3px 0 0;font:700 10px/1.5 "Century Gothic","Segoe UI",sans-serif;letter-spacing:.09em;text-transform:uppercase;color:#ffd79a;overflow-wrap:anywhere}
@media(max-width:1100px){.demo-control-scene{gap:10px}.demo-control-scene b{font-size:19px}.demo-flow strong{font-size:17px}}
@media(max-width:800px){.demo-control-scene{grid-template-columns:1fr}.demo-control-scene b{font-size:18px}.demo-flow strong{font-size:16px}}
.aegis-demo-scene #grid,.aegis-demo-scene .groupbox,.aegis-demo-scene .grouplbl{visibility:hidden}
/* The focused native control names itself and shows its measured state on the canvas. */
.demo-rule-label{pointer-events:none}.demo-rule-label text{font:700 11px "Segoe UI",sans-serif;fill:#eaf7ff}
.demo-rule-label .demo-rule-state{font-size:15px;font-weight:800;letter-spacing:.05em}
.demo-rule-label[data-rule-state=OFF] .demo-rule-state{fill:#ffd0aa}
.demo-rule-label[data-rule-state=PENDING] .demo-rule-state,.demo-rule-label[data-rule-state=UNKNOWN] .demo-rule-state{fill:#ffe5a1}
