/* STRUCT-WAVE-4: canonical shell for the final structural queue slice. */
html.iot-struct-wave-4 :is(.quarto-title-block,#title-block-header,h1.title,.quarto-title-meta,.quarto-categories),
html.iot-struct-wave-4 #interactive-game > :is(h1,h2) { display:none !important; }
html.iot-struct-wave-4 :is(.page-columns,main.content,#quarto-content,#quarto-document-content) { display:block !important; width:100% !important; max-width:none !important; margin-right:auto !important; margin-left:auto !important; }

:is(#sensorGame,#spgGame,#tsoptGame,#tsqGame,#topoGame,#ucSim,#ztGame,#ztSim).sw4-shell {
  --sw4-teal:#197F8D; --sw4-blue:#3E68A6; --sw4-green:#2F8D57; --sw4-amber:#B96824; --sw4-red:#B9484D;
  --sw4-ink:#20343D; --sw4-muted:#526A73; --sw4-line:#D8E3E8;
  --sw4-tint:color-mix(in srgb,var(--pc-main) 7%,white); --sw4-tint-strong:color-mix(in srgb,var(--pc-main) 13%,white);
  --sw4-border:color-mix(in srgb,var(--pc-main) 42%,white); --sw4-module-ink:color-mix(in srgb,var(--pc-main) 72%,#20343D);
  width:min(1180px,calc(100vw - 32px)) !important; max-width:none !important; margin:0 0 32px 50% !important; padding:16px !important;
  transform:translateX(-50%) !important; color:var(--sw4-ink) !important; background:var(--sw4-tint) !important;
  border:1px solid var(--sw4-border) !important; border-radius:8px !important; box-shadow:none !important;
  font:16px/1.5 Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif !important;
}
:is(#sensorGame,#spgGame,#tsoptGame,#tsqGame,#topoGame,#ucSim,#ztGame,#ztSim).sw4-shell,
:is(#sensorGame,#spgGame,#tsoptGame,#tsqGame,#topoGame,#ucSim,#ztGame,#ztSim).sw4-shell * { box-sizing:border-box; }
.sw4-hero { padding:24px !important; margin:0 0 14px !important; color:var(--sw4-ink) !important; text-align:left !important; background:var(--sw4-tint-strong) !important; border:1px solid var(--sw4-border) !important; border-radius:8px !important; box-shadow:0 14px 34px rgba(32,52,61,.10) !important; }
.sw4-kicker { display:flex !important; flex-wrap:wrap; gap:8px; margin:0 0 14px !important; }
.sw4-pill { display:inline-flex; align-items:center; min-height:26px; padding:4px 10px; color:var(--sw4-module-ink) !important; background:#fff !important; border:1px solid var(--sw4-border) !important; border-radius:999px; font-size:12px !important; font-weight:850; letter-spacing:.05em; text-transform:uppercase; }
.sw4-hero :is(h1,h2) { margin:0 0 10px !important; color:var(--sw4-ink) !important; font-size:clamp(32px,4vw,40px) !important; line-height:1.08 !important; letter-spacing:-.025em !important; }
.sw4-hero p { max-width:850px; margin:0 !important; color:#38515B !important; font-size:17px !important; line-height:1.5 !important; }
.sw4-metrics { display:grid !important; grid-template-columns:repeat(4,minmax(0,1fr)) !important; gap:10px !important; max-width:850px; margin-top:18px !important; }
.sw4-metric { min-width:0; padding:10px 12px !important; text-align:left !important; background:#fff !important; border:1px solid var(--sw4-border) !important; border-radius:8px !important; }
.sw4-metric strong,.sw4-metric span { display:block; } .sw4-metric strong { color:var(--sw4-ink) !important; font-size:16px !important; } .sw4-metric span { margin-top:2px; color:var(--sw4-muted) !important; font-size:12px !important; }
.sw4-ramp { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; margin:12px 0; }
.sw4-ramp-card,.sw4-boundaries,.sw4-legend { padding:12px 14px; background:#fff; border:1px solid var(--sw4-line); border-radius:8px; }
.sw4-ramp-card strong,.sw4-ramp-card span { display:block; } .sw4-ramp-card strong { color:var(--sw4-teal); font-size:12px; font-weight:850; letter-spacing:.05em; text-transform:uppercase; } .sw4-ramp-card span { margin-top:4px; color:#38515B; font-size:14px; line-height:1.45; }
.sw4-legend { display:flex; flex-wrap:wrap; gap:8px 14px; margin:12px 0; color:var(--sw4-muted); font-size:12px; font-weight:750; }
.sw4-legend i { display:inline-block; width:10px; height:10px; margin-right:5px; border-radius:50%; vertical-align:-1px; }
.sw4-legend .identity { background:var(--sw4-tint-strong); border:2px solid var(--pc-main); } .sw4-legend .current { background:var(--sw4-teal); } .sw4-legend .reference { background:var(--sw4-blue); } .sw4-legend .success { background:var(--sw4-green); } .sw4-legend .caution { background:var(--sw4-amber); } .sw4-legend .error { background:var(--sw4-red); }
.sw4-boundaries { margin-top:14px; color:#38515B; font-size:14px; line-height:1.5; } .sw4-boundaries strong { color:var(--sw4-ink); }
.sw4-shell :is(.scenario-card,[class$="-status"],[class$="-panel"],[class$="-body"],[class$="-game-area"],[class$="-reference-material"],select,input) { border-radius:8px !important; }
.sw4-shell button { min-height:40px; border-radius:8px !important; font-weight:800 !important; }
.sw4-shell :is(#sensSubmit,#spgRun,#tsoptSubmit,#tsqSubmit,#topoSubmit,#ucAnalyze,#ztSubmit,#ztEvaluate) { color:#fff !important; background:var(--sw4-teal) !important; border-color:var(--sw4-teal) !important; }
.sw4-shell :is(#spgRestart,#tsoptRestart,#tsqRestart,#ucReset,#ztResetScenario,#ztResetPolicies) { color:var(--sw4-ink) !important; background:#fff !important; border:1px solid #A9BCC5 !important; }
.sw4-shell input[type="range"] { accent-color:var(--sw4-teal); }
.sw4-shell :is(.active,.selected,.is-selected,[aria-pressed="true"]) { box-shadow:0 0 0 2px color-mix(in srgb,var(--sw4-teal) 18%,transparent); }
.sw4-shell :is(.uc-body,.zt-body) { background:transparent !important; border:0 !important; padding:0 !important; }
#ztGame.sw4-shell .policy-options { min-width:0; margin:-2px; padding:2px; }
@media (max-width:700px) {
  :is(#sensorGame,#spgGame,#tsoptGame,#tsqGame,#topoGame,#ucSim,#ztGame,#ztSim).sw4-shell { width:calc(100vw - 32px) !important; padding:10px !important; }
  .sw4-hero { padding:18px !important; } .sw4-metrics,.sw4-ramp { grid-template-columns:1fr !important; } .sw4-legend { align-items:flex-start; flex-direction:column; }
  .sw4-shell :is(.uc-layout,.zt-layout,.uc-guidance,.zt-guidance,.uc-insight-grid) { grid-template-columns:1fr !important; }
  #ucSim.sw4-shell .uc-cost-bar { grid-template-columns:minmax(0,72px) minmax(0,1fr) minmax(0,52px) !important; }
  #ucSim.sw4-shell .uc-cost-label { min-width:0; overflow-wrap:anywhere; }
}
@media (prefers-reduced-motion:reduce) { .sw4-shell *,.sw4-shell *::before,.sw4-shell *::after { animation-duration:.001ms !important; animation-iteration-count:1 !important; transition-duration:.001ms !important; } }
