/* v0.3: classroom / mobile control surfaces. The simulation renderer is unchanged. */
.workspace{min-height:0;max-height:none}
.stage{min-height:0}
.header{height:72px}
.workspace{height:calc(100dvh - 124px)}
.controls .section-heading h2,.controls .section-heading label{font-size:14px}
.controls .fine-print{font-size:12px}
#quick-dock,#presentation-dock{display:none}
.guided-entry{border-top:1px solid var(--line);margin-top:16px;padding-top:12px}
.guided-entry button{width:100%;display:flex;justify-content:space-between;font-size:13px}
.guided-entry p{margin-top:8px}
.cooling-plans{display:flex;gap:7px;margin:12px 0 8px}
.cooling-plans button{flex:1;font-size:12px;padding:8px}
.plan-status{background:var(--surface);border:1px solid var(--gold);padding:12px;margin:10px 0;border-radius:8px}
.plan-status strong{font-size:14px}
.plan-status p{font-size:12px;line-height:1.5;margin:5px 0}
.plan-status progress{width:100%;accent-color:var(--gold);height:7px}
.order-reading{display:flex;justify-content:space-between;align-items:center;margin:12px 0;font-size:12px;color:var(--muted)}
.order-reading strong{font-size:20px;color:var(--text);font-weight:500}
.structure-history{margin-top:12px}
.structure-history summary{font-size:12px;cursor:pointer;padding:8px 0}
.structure-history ol{padding-left:18px;font-size:12px;line-height:1.6;color:var(--muted)}
.structure-history li{margin:7px 0}
/* Structure reports geometry. The preparation name is separately identified. */
.scene-heading h2{font-size:16px}
.scene-heading p{font-size:12px}
.structure-badge{position:absolute;right:24px;top:78px;z-index:3;max-width:340px;padding:10px 14px;background:var(--panel);border:1px solid var(--line);border-radius:9px;color:var(--text);pointer-events:none}
.structure-badge>span{display:block;font-size:11px;color:var(--muted);margin-bottom:4px}
.structure-badge strong{font-size:16px;font-weight:550;display:block}
.structure-badge small{display:block;font-size:11px;color:var(--muted);margin-top:5px;line-height:1.5}
.structure-badge small:empty{display:none}
.try-this{position:absolute;top:157px;right:24px;max-width:305px;display:flex;gap:10px;align-items:start;z-index:4;background:var(--panel);border:1px solid var(--line);border-radius:9px;padding:10px 10px 10px 15px;color:var(--text)}
.try-this span{font-size:13px;line-height:1.5;display:block}
.try-this .icon-button{font-size:20px;width:28px;min-height:30px;padding:2px;flex-shrink:0}
.try-this .text-button{margin-top:3px}
.real-speed-button{position:absolute;left:28px;bottom:184px;z-index:3;text-align:left;background:var(--panel);color:var(--text);border:1px solid var(--line);padding:10px 14px;border-radius:9px;max-width:calc(100% - 56px)}
.real-speed-button>span{display:block;color:var(--gold);font-size:13px;margin-bottom:3px}
.real-speed-button strong{font-size:17px;font-weight:500;white-space:normal}
.real-speed-button sup{font-size:.65em}
.graphics-label{display:none}
.scene-metrics{bottom:114px}
.cloud-caption{top:137px}
body.cloud-view .structure-badge{top:26px}
body.cloud-view .try-this{display:none}
/* Presets first, custom colour pickers only on request. */
#display-dialog{width:min(650px,calc(100vw - 32px))}
.visibility-presets{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin:20px 0}
.visibility-presets button{padding:8px;border:1px solid var(--line);font-size:12px;background:var(--surface)}
.visibility-presets button[aria-pressed=true]{border:2px solid var(--gold);padding:7px}
.visibility-presets strong{display:block;font-weight:550;margin-top:7px}
.preset-swatch{height:53px;display:flex;align-items:center;justify-content:center;gap:12px;border-radius:5px}
.preset-swatch i{width:26px;height:26px;border-radius:50%;font-size:12px;display:grid;place-items:center;font-style:normal;font-weight:700}
.preset-swatch i+ i{border-radius:6px}
.swatch-standard{background:#101f29}.swatch-standard i{background:#efb261;color:#17212a}.swatch-standard i+ i{background:#69c9cc}
.swatch-bright{background:#f0f0e7}.swatch-bright i{background:#b75812;color:#fff}.swatch-bright i+ i{background:#00627c}
.swatch-contrast{background:#030d14}.swatch-contrast i{background:#ffd36b;color:#10202b}.swatch-contrast i+ i{background:#74edff}
.swatch-colourvision{background:#10202b}.swatch-colourvision i{background:#e69f00;color:#10202b}.swatch-colourvision i+ i{background:#56b4e9}
#fine-tune{border:1px solid var(--line);border-radius:8px;padding:12px 15px}
#fine-tune summary{cursor:pointer;font-size:14px;min-height:26px}
.visibility-sizes{margin-top:22px}.visibility-sizes h3{font-size:15px;margin-bottom:14px}
.visibility-sizes .setting-row{font-size:13px}
/* Native modal sheets keep focus contained and make Escape predictable. */
dialog.controls-dialog,dialog.temperature-dialog,dialog.view-dialog,dialog.graph-dialog,dialog.speed-dialog{color:var(--text);background:var(--panel);border:1px solid var(--line);border-radius:16px;padding:22px;max-height:calc(100dvh - 32px);overflow:auto}
.sheet-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 16px}
.sheet-heading h2{font-size:23px;letter-spacing:-.4px;line-height:1.2;margin:0}
.sheet-heading .icon-button{min-width:44px;min-height:44px;font-size:27px}
.sheet-note{color:var(--muted);font-size:14px;line-height:1.55;margin:14px 0}
.sheet-done{min-height:46px;margin-top:14px}
.sheet-nav{display:flex;gap:4px;flex-wrap:wrap;border-bottom:1px solid var(--line);padding-bottom:12px;margin-bottom:16px}
.sheet-nav button{font-size:13px;border:1px solid var(--line);min-height:44px}
#controls-dialog{width:min(610px,calc(100vw - 32px));scroll-behavior:auto}
#controls-dialog .controls{display:block;border:none;overflow:visible;background:none;width:100%}
#controls-dialog .control-section{padding:20px 0;border-left:0;border-right:0}
#controls-dialog .learning-toolbar{padding:8px 0 16px;min-height:0;flex-wrap:wrap;border:0}
#controls-dialog .learning-toolbar button,#controls-dialog select{min-height:44px}
#controls-dialog .fine-print{font-size:13px}
#controls-dialog .section-heading h2,#controls-dialog .section-heading label{font-size:16px}
#controls-dialog .switch-grid label{font-size:14px;min-height:44px}
#controls-dialog .explanation p{font-size:16px;line-height:1.6}
#controls-dialog .explanation #explanation-hint{font-size:14px}
#controls-dialog .phase-actions button,#controls-dialog .cooling-plans button{font-size:14px;min-height:46px}
#controls-dialog .preset-grid button{min-height:48px;font-size:14px}
#controls-dialog .setting-check{font-size:14px;min-height:38px}
#temperature-dialog{width:min(620px,calc(100vw - 32px))}
#temperature-dialog .control-section{border:0;padding:12px 0}
#temperature-dialog .section-heading label{font-size:17px}
#temperature-dialog .section-heading span{font-size:13px}
#temperature-dialog .temperature-value output{font-size:72px}
#temperature-dialog .temperature-value>span:first-of-type{font-size:32px}
#temperature-dialog #temperature{height:56px;min-height:56px;touch-action:pan-y}
#temperature-dialog .range-ends{font-size:14px;margin-top:0}
#temperature-dialog .fine-print{font-size:15px}
#view-dialog{width:min(460px,calc(100vw - 32px))}
#view-dialog .scale-tabs{position:static;display:grid;gap:8px;padding:0;border:0;background:none;max-width:none}
#view-dialog .scale-tabs button{padding:16px;font-size:17px;text-align:left;border:1px solid var(--line);min-height:55px;color:var(--text)}
#view-dialog .scale-tabs button[aria-pressed=true]{background:var(--raised)}
#graph-dialog{width:min(780px,calc(100vw - 40px));margin-right:24px}
#graph-dialog .control-section{padding:0;border:0}
#graph-dialog .graph-section>.section-heading{display:none}
#graph-dialog #potential-graph{height:340px}
#graph-dialog .graph-axis-label{font-size:19px;margin-bottom:10px}
#graph-dialog .pair-readings{gap:32px;flex-wrap:wrap}
#graph-dialog .pair-readings span:not(.force-kind){font-size:17px}
#graph-dialog .pair-readings strong{font-size:27px}
#graph-dialog .force-kind{font-size:17px}
#graph-dialog .sandbox-link{font-size:16px;min-height:48px}
#graph-dialog::backdrop{background:#0003}
/* Speed is a measured scale comparison, never a fake unresolvable trajectory. */
#speed-dialog{width:min(920px,calc(100vw - 40px));padding:30px 38px}
#speed-dialog h2{font-size:30px}.speed-intro{font-size:16px;color:var(--muted)}
.speed-hero{display:flex;align-items:baseline;gap:18px;margin:16px 0 0}.speed-hero strong{font-size:clamp(60px,8vw,110px);line-height:1;font-weight:500;letter-spacing:-3px;font-variant-numeric:tabular-nums}.speed-hero>span{font-size:34px}
.speed-kmh{font-size:26px;color:var(--text);margin-top:10px}.speed-kmh span{font-size:16px;color:var(--muted)}
.frame-comparison{margin:25px 0;padding-top:20px;border-top:1px solid var(--line)}
.frame-comparison h3{font-size:23px}.frame-comparison p{font-size:17px;line-height:1.5;margin-top:8px}.frame-comparison>strong{font-size:26px;color:var(--gold);display:block;margin-top:5px}
.length-comparison{display:flex;gap:22px;align-items:center;border:1px solid var(--line);border-radius:9px;padding:14px 20px;margin:16px 0;background:var(--surface)}
.length-comparison>div{flex:1}.length-comparison span{font-size:14px;color:var(--muted)}.length-comparison strong{display:block;font-size:27px;font-weight:500;margin-top:5px}
.frame-comparison .collision-caveat{font-size:14px;color:var(--muted)}
.speed-slowdown{border-top:1px solid var(--line);padding-top:18px;font-size:18px}
.speed-slowdown strong{display:block;font-size:35px;letter-spacing:-.4px;margin:5px 0}.speed-slowdown p{font-size:14px;color:var(--muted)}
/* Presentation: large captions and a separate classroom control strip. */
body.projector:not(.compact) .header{height:62px;padding:0 24px}
body.projector:not(.compact) .header-actions button{font-size:16px;min-height:44px}
body.projector:not(.compact) .workspace{display:block;height:calc(100dvh - 62px);min-height:0}
body.projector:not(.compact) .stage{height:100%;width:100%;min-height:0}
body.projector:not(.compact) .scene-heading{left:30px;top:24px;right:30px}
body.projector:not(.compact) .scene-heading h2{font-size:23px}
body.projector:not(.compact) .scene-heading p{font-size:17px}
body.projector:not(.compact) .status{font-size:17px}
body.projector:not(.compact) .scale-tabs{display:none}
body.projector:not(.compact) .scene-toolbar{display:none}
body.projector:not(.compact) .scene-metrics{bottom:114px;left:auto;right:30px;gap:36px}
body.projector:not(.compact) .scene-metrics span{font-size:17px}
body.projector:not(.compact) .scene-metrics strong{font-size:31px}
body.projector:not(.compact) .scene-metrics small{font-size:20px}
body.projector:not(.compact) .structure-badge{top:95px;left:30px;right:auto;max-width:650px;padding:14px 18px}
body.projector:not(.compact) .structure-badge>span{font-size:17px}
body.projector:not(.compact) .structure-badge strong{font-size:31px}
body.projector:not(.compact) .structure-badge small{font-size:16px}
body.projector:not(.compact) .try-this{display:none}
body.projector:not(.compact) .real-speed-button{bottom:111px;left:30px;padding:10px 16px;max-width:47%}
body.projector:not(.compact) .real-speed-button span{font-size:16px}
body.projector:not(.compact) .real-speed-button strong{font-size:23px}
body.projector:not(.compact) .cloud-caption{top:96px;left:30px;right:auto;font-size:17px;max-width:calc(100% - 60px);gap:12px}
body.projector:not(.compact).cloud-view .structure-badge{display:none}
body.projector:not(.compact) .cloud-caption button:not(.icon-button){font-size:17px;min-height:44px}
body.projector:not(.compact) .cloud-speed-label,body.projector:not(.compact) .cloud-speed-label select{font-size:15px}
body.projector:not(.compact) .presentation-caption{position:absolute;z-index:4;left:30px;bottom:203px;width:min(1150px,calc(100% - 60px));padding:18px 25px;background:var(--panel);border:1px solid var(--line);border-left:4px solid var(--gold);border-radius:12px;color:var(--text);pointer-events:none}
body.projector:not(.compact) .presentation-caption p{font-size:clamp(27px,2.0vw,39px);line-height:1.35;font-weight:450;letter-spacing:-.2px;text-wrap:pretty}
body.projector:not(.compact) #presentation-dock{position:fixed;bottom:0;left:0;right:0;display:flex;justify-content:space-between;align-items:center;gap:12px;padding:12px 24px calc(12px + env(safe-area-inset-bottom));min-height:88px;background:var(--panel);border-top:1px solid var(--line);z-index:8}
#presentation-dock>button{min-height:52px;font-size:19px;border:1px solid var(--line);padding:10px 15px;background:var(--surface)}
#presentation-dock label{display:flex;flex-direction:column;gap:4px;font-size:13px;color:var(--muted)}
#presentation-dock select{font-size:18px;min-height:46px}
#presentation-dock #present-temperature{text-align:left;min-width:140px}
#presentation-dock #present-temperature>span{display:block;font-size:13px;color:var(--muted)}
#presentation-dock #present-temperature>strong{font-size:29px;font-weight:500;line-height:1.2}
#present-explain[aria-pressed=true]{background:var(--raised);border-color:var(--gold)}
body.projector #temperature-dialog .temperature-value output{font-size:86px}
body.projector #temperature-dialog .section-heading label{font-size:23px}
body.projector #temperature-dialog .fine-print,body.projector #temperature-dialog .sheet-note{font-size:19px}
@media(min-width:761px) and (max-width:1250px){
 .structure-badge{top:134px;right:16px;max-width:240px}.structure-badge strong{font-size:14px}.try-this{top:210px;right:16px;max-width:240px}
 body.projector:not(.compact) #presentation-dock{gap:7px;padding:10px 16px}
 #presentation-dock>button{font-size:15px;padding:9px 10px}#presentation-dock #present-temperature{min-width:116px}#presentation-dock select{font-size:15px}
 body.projector:not(.compact) .structure-badge strong{font-size:26px}
 body.projector:not(.compact) .scene-metrics{gap:24px}.scene-metrics>div{min-width:0}
}
@media(min-width:761px) and (max-height:800px){.real-speed-button{bottom:151px}.scene-metrics{bottom:89px}.scene-toolbar{bottom:17px}.real-speed-button strong{font-size:15px}.real-speed-button span{font-size:12px}.structure-badge{top:135px}.try-this{top:205px}.cloud-view .structure-badge{display:none}}
/* Portrait phones use the whole viewport, with accessible persistent controls. */
body.compact{overflow:hidden}
body.compact .header{height:60px;padding:0 12px;gap:8px}
body.compact .brand h1{font-size:21px}
body.compact .brand p{font-size:10px}
body.compact .element{width:30px;height:36px;font-size:19px}
body.compact .header-actions .models-link,body.compact .prototype,body.compact #model-button{display:none}
body.compact .header-actions #present-button{width:auto;padding:8px 9px;min-height:42px}
body.compact #present-button span{display:inline;font-size:11px}
body.compact .workspace,body.compact.projector .workspace{display:block;height:calc(100dvh - 60px - 78px - env(safe-area-inset-bottom));min-height:0;max-height:none}
body.compact .stage,body.compact.projector .stage{height:100%;min-height:0;width:100%}
body.compact .scene-heading{top:16px;left:14px;right:14px}
body.compact .scene-heading h2{font-size:16px}
body.compact .scene-heading p{font-size:11px}
body.compact .status{font-size:10px;padding:6px 8px}
body.compact #stage .scale-tabs{display:none}
body.compact .scene-toolbar{display:none}
body.compact .structure-badge{top:78px;left:14px;right:auto;max-width:calc(100% - 28px);padding:8px 12px}
body.compact .structure-badge>span{font-size:10px}.compact .structure-badge strong{font-size:14px}
body.compact .structure-badge small{font-size:10px;max-width:280px}
body.compact .try-this{top:157px;left:14px;right:14px;max-width:calc(100% - 28px);padding:8px 8px 8px 12px;gap:8px}
body.compact .try-this span{font-size:12px}
body.compact .try-this .text-button{min-height:37px;font-size:13px;margin-top:1px}
body.compact .real-speed-button{left:14px;right:14px;bottom:68px;max-width:none;padding:8px 11px}
body.compact .real-speed-button span{font-size:12px;margin-bottom:2px}.compact .real-speed-button strong{font-size:14px}
body.compact .scene-metrics{left:14px;right:14px;bottom:16px;gap:18px;justify-content:space-between}
body.compact .scene-metrics>div{min-width:0}
body.compact .scene-metrics span{font-size:10px}.compact .scene-metrics strong{font-size:20px}.compact .scene-metrics small{font-size:11px}
body.compact .cloud-caption{left:12px;right:12px;top:76px;max-width:none;gap:8px;font-size:11px;padding:8px}
body.compact .cloud-caption button:not(.icon-button){font-size:12px;min-height:38px}
body.compact .cloud-caption .icon-button{min-height:38px;width:32px}
body.compact .cloud-speed-label{font-size:11px}
body.compact.cloud-view .structure-badge{display:none}
body.compact .slice-caption{top:148px;left:14px}
body.compact #quick-dock{position:fixed;bottom:0;left:0;right:0;display:grid;grid-template-columns:1.15fr .85fr 1fr 1fr;gap:4px;padding:7px 8px calc(7px + env(safe-area-inset-bottom));min-height:78px;background:var(--panel);border-top:1px solid var(--line);z-index:10}
.quick-dock button{border:1px solid var(--line);background:var(--surface);min-height:62px;padding:6px 4px;border-radius:8px;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:4px}
.quick-dock button>span{font-size:11px;color:var(--muted)}.quick-dock button>strong{font-size:13px;font-weight:600;line-height:1.1}
#quick-temperature{border-color:var(--gold)}#quick-temperature-value{font-size:18px}
body.compact dialog.controls-dialog,body.compact dialog.temperature-dialog,body.compact dialog.view-dialog{position:fixed;left:0;right:0;bottom:0;top:auto;margin:0;width:100%;max-width:none;max-height:88dvh;border-radius:18px 18px 0 0;padding:18px 20px calc(24px + env(safe-area-inset-bottom))}
body.compact .controls-dialog .sheet-heading{margin-bottom:8px}
body.compact .sheet-heading h2{font-size:22px}
body.compact .sheet-heading{gap:5px}
body.compact .sheet-nav{gap:4px}
body.compact .sheet-nav button{flex:1;padding:8px 5px;font-size:12px}
body.compact #controls-dialog .learning-toolbar label{width:100%}
body.compact #controls-dialog .learning-toolbar select{flex:1}
body.compact #controls-dialog .learning-toolbar button{min-height:46px;font-size:14px}
body.compact #temperature-dialog .temperature-value output{font-size:65px}
body.compact #temperature-dialog .temperature-change{display:inline;font-size:13px}
body.compact #temperature-dialog .section-heading{flex-direction:row;align-items:center;gap:8px}
body.compact #temperature-dialog .section-heading label{font-size:15px}
body.compact #temperature-dialog .section-heading span{font-size:12px}
body.compact #temperature-dialog .fine-print,body.compact #temperature-dialog .sheet-note{font-size:14px}
body.compact #graph-dialog{width:calc(100vw - 16px);margin:auto;padding:18px;max-height:94dvh}
body.compact #graph-dialog #potential-graph{height:260px}
body.compact #graph-dialog .pair-readings{gap:18px}
body.compact #graph-dialog .pair-readings strong{font-size:22px}
body.compact #graph-dialog .pair-readings span:not(.force-kind){font-size:13px}
body.compact #graph-dialog .force-kind{font-size:13px}
body.compact #graph-dialog .graph-axis-label{font-size:15px}
body.compact #speed-dialog{width:calc(100vw - 16px);padding:20px;max-height:94dvh}
body.compact #speed-dialog h2{font-size:22px}
body.compact .speed-intro{font-size:14px}
body.compact .speed-hero strong{font-size:66px}.compact .speed-hero>span{font-size:23px}
body.compact .speed-kmh{font-size:21px}.compact .speed-kmh span{display:block;font-size:13px}
body.compact .frame-comparison{margin:18px 0;padding-top:16px}
body.compact .frame-comparison h3{font-size:20px}.compact .frame-comparison p{font-size:14px}
body.compact .frame-comparison>strong{font-size:22px}
body.compact .length-comparison{gap:10px;padding:10px}.compact .length-comparison span{font-size:11px}.compact .length-comparison strong{font-size:21px}
body.compact .frame-comparison .collision-caveat{font-size:12px}.compact .speed-slowdown{font-size:14px}.compact .speed-slowdown strong{font-size:28px}
body.compact .visibility-presets{grid-template-columns:repeat(2,1fr);gap:9px}
body.compact #display-dialog{width:calc(100vw - 16px);padding:20px;max-height:94dvh}
body.compact .visibility-presets button{min-height:89px}.compact .visibility-presets strong{font-size:13px}
body.compact .toast{bottom:calc(86px + env(safe-area-inset-bottom));max-width:calc(100vw - 28px);font-size:13px}
/* Landscape phone: a right-hand control rail, not the portrait bar sideways. */
body.compact.landscape .header{height:48px}
body.compact.landscape .brand p,body.compact.landscape .element{display:none}
body.compact.landscape .workspace{height:calc(100dvh - 48px);width:calc(100vw - 218px)}
body.compact.landscape #quick-dock{left:auto;top:48px;bottom:0;right:0;width:218px;min-height:0;border-top:0;border-left:1px solid var(--line);padding:12px;grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr;gap:10px}
body.compact.landscape .quick-dock button{min-height:65px;padding:10px 5px}
body.compact.landscape .quick-dock button>span{font-size:12px}.compact.landscape .quick-dock button>strong{font-size:14px}
body.compact.landscape .scene-heading{top:10px}.compact.landscape .scene-heading p{font-size:10px}
body.compact.landscape .structure-badge{top:66px;padding:7px 10px;max-width:calc(100% - 28px)}
body.compact.landscape .structure-badge>span{display:none}
body.compact.landscape .try-this{display:none}
body.compact.landscape .real-speed-button{bottom:51px;padding:7px 10px}
body.compact.landscape .real-speed-button>span{font-size:11px}.compact.landscape .real-speed-button strong{font-size:13px}
body.compact.landscape .scene-metrics{bottom:7px}.compact.landscape .scene-metrics strong{font-size:18px}.compact.landscape .scene-metrics span{font-size:9px}
body.compact.landscape .cloud-caption{top:65px;gap:5px;padding:4px 7px}
body.compact.landscape .cloud-caption .cloud-kind{display:none}
body.compact.landscape .cloud-caption button:not(.icon-button){font-size:11px;min-height:34px}
body.compact.landscape dialog.controls-dialog,body.compact.landscape dialog.temperature-dialog,body.compact.landscape dialog.view-dialog{left:auto;right:0;top:0;bottom:0;max-height:100dvh;max-width:min(490px,85vw);border-radius:16px 0 0 16px}
@media(max-width:360px){body.compact .quick-dock button>strong{font-size:12px}body.compact .scene-metrics{gap:9px}body.compact .real-speed-button strong{font-size:13px}.sheet-heading h2{font-size:20px}}
/* Never override the semantic hidden attribute with a component display rule. */
[hidden]{display:none!important}
.sheet-extras{display:flex;flex-wrap:wrap;gap:8px;margin:6px 0 12px}
.sheet-extras button{font-size:13px;min-height:44px}
#controls-dialog #controls{scroll-margin-top:0}
body.compact .loading h3{font-size:18px}
body.compact .loading p{font-size:12px}
#phase-panel>summary{font-size:14px;font-weight:550;cursor:pointer;min-height:28px;color:var(--gold)}
#phase-panel[open]>summary{margin-bottom:17px}
body.compact #controls-dialog,body.compact #temperature-dialog,body.compact #view-dialog{width:100%;max-width:none}
body.compact.landscape #controls-dialog,body.compact.landscape #temperature-dialog,body.compact.landscape #view-dialog{width:min(490px,85vw);max-width:min(490px,85vw)}
#controls-dialog .learning-toolbar label{font-size:14px}
#controls-dialog>.sheet-heading{position:sticky;top:-22px;background:var(--panel);z-index:12;padding:8px 0}
#controls-dialog>.sheet-nav{position:sticky;top:44px;background:var(--panel);z-index:11;padding-top:8px}
#controls-dialog .control-section,#controls-dialog #sheet-learning{scroll-margin-top:126px}
body:not(.compact):not(.projector) #sheet-learning,body:not(.compact):not(.projector) .sheet-extras{display:none}
body.compact #controls-dialog>.sheet-heading{top:-18px}
body.compact #controls-dialog #phase-panel>summary{font-size:16px;min-height:44px}
body.projector:not(.compact) #speed-dialog{width:min(1050px,calc(100vw - 48px))}
body.projector:not(.compact) #speed-dialog .frame-comparison p{font-size:21px}
body.projector:not(.compact) #speed-dialog .frame-comparison h3{font-size:26px}
body.projector:not(.compact) #speed-dialog .frame-comparison>strong{font-size:33px}
body.projector:not(.compact) #speed-dialog .collision-caveat{font-size:18px}
body.projector:not(.compact) #speed-dialog .length-comparison strong{font-size:32px}
body.projector:not(.compact) #speed-dialog .length-comparison span{font-size:18px}
body.projector:not(.compact) #speed-dialog .speed-slowdown{font-size:22px}
body.projector:not(.compact) #speed-dialog .speed-slowdown strong{font-size:40px}
body.projector:not(.compact) #speed-dialog .sheet-note{font-size:17px}
@media(min-width:1500px){body.projector:not(.compact) .real-speed-button strong{font-size:27px}}

/* v0.3.1: free-surface samples, honest fast-forward and real-argon references. */
.geometry-control{margin:13px 0 2px;padding:12px;border:1px solid var(--line);border-radius:8px;background:var(--surface)}
.geometry-control .section-heading h3{font-size:12px;margin:0 0 9px;font-weight:600}
.geometry-buttons{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin-bottom:8px}
.geometry-buttons button{min-height:40px;border:1px solid var(--line);background:var(--panel);font-size:12px}
.geometry-buttons button[aria-pressed=true]{border-color:var(--gold);background:var(--raised)}
.argon-temperature-reference{border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding:8px 0;margin:2px 0 10px;display:grid;grid-template-columns:auto 1fr;column-gap:8px;row-gap:2px;line-height:1.4}
.argon-temperature-reference strong{font-size:11px;color:var(--gold);font-weight:600}
.argon-temperature-reference span{font-size:11px;color:var(--text)}
.argon-temperature-reference small{grid-column:1/-1;font-size:10px;color:var(--muted)}
.fast-forward-actions{display:flex;align-items:center;gap:8px;margin:8px 0}
.fast-forward-actions .outline{flex:1;font-size:12px}
.rate-setting>span:last-child{display:flex;align-items:center;gap:8px}
.rate-setting select{font-size:11px;max-width:116px}
.rate-setting output{font-size:10px;color:var(--muted);white-space:nowrap}
.speed-label{flex-wrap:wrap;max-width:230px}
.speed-label output{font-size:10px;color:var(--gold);white-space:nowrap}
#presentation-dock .present-speed{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;line-height:1.1;border-color:var(--gold);min-width:150px}
#presentation-dock .present-speed span{font-size:13px;color:var(--muted)}
#presentation-dock .present-speed strong{font-size:24px;font-weight:520;margin-top:5px;color:var(--text);white-space:nowrap}
body.projector:not(.compact) #presentation-dock .present-speed{background:var(--raised)}
body.compact .geometry-control{padding:12px 10px}
body.compact .geometry-buttons button{min-height:46px;font-size:14px}
body.compact .argon-temperature-reference{padding:10px 0;row-gap:4px}
body.compact .argon-temperature-reference strong,body.compact .argon-temperature-reference span{font-size:13px}
body.compact .argon-temperature-reference small{font-size:12px}
body.compact .rate-setting{display:block}
body.compact .rate-setting>span:last-child{margin-top:8px;justify-content:space-between}
body.compact .rate-setting select{min-height:44px;font-size:14px;max-width:none}
body.compact .rate-setting output{font-size:12px}
body.compact .fast-forward-actions .outline{min-height:46px;font-size:14px}
@media(min-width:761px) and (max-width:1250px){
 #presentation-dock .present-speed{min-width:126px}
 #presentation-dock .present-speed strong{font-size:19px}
 #presentation-dock .present-speed span{font-size:11px}
}
/* v0.3.2: seeded nucleation and faster waiting controls. */
.seed-controls{display:flex;align-items:center;gap:10px;margin:12px 0 6px;flex-wrap:wrap}
.seed-controls .outline{min-height:40px}
.seed-controls .fine-print{margin:0;flex:1 1 150px}
.fast-forward-actions{flex-wrap:wrap}
.fast-forward-actions .outline{min-width:120px}
body.compact .seed-controls{align-items:stretch;flex-direction:column}
body.compact .seed-controls .outline{min-height:46px;font-size:14px}
body.compact .seed-controls .fine-print{flex:0 0 auto}
