/* Flight-first phone HUD. Desktop layout and simulation are unchanged. */
.mobile-only{display:none}
#flightSheet{padding:18px;width:min(480px,calc(100vw - 20px));max-width:none;max-height:calc(100dvh - 24px);border-radius:14px;background:#0d191f;overscroll-behavior:contain}
#flightSheet [hidden]{display:none!important}
.sheet-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}.sheet-heading small{font:9px monospace;letter-spacing:1px;color:var(--amber);margin:0}.sheet-heading h2{font-size:21px;margin:7px 0 14px}.sheet-heading button{width:44px;height:44px;flex:none;font-size:28px;background:transparent}
.sheet-tabs{display:flex;gap:6px;margin:0 0 18px}.sheet-tabs button{flex:1;min-height:44px;font:11px monospace}.sheet-tabs button[aria-pressed=true]{background:#d5b37c;color:#102026}
#flightSheet .ship-panel,#flightSheet .contract,#flightSheet .radar{position:static;inset:auto;width:100%;max-width:none;display:block;padding:16px;margin:0 0 12px;pointer-events:auto;box-shadow:none}
#flightSheet .ship-panel .eyebrow,#flightSheet .ship-panel .eyebrow span,#flightSheet .ship-stats,#flightSheet .hold-title,#flightSheet .hold-value,#flightSheet .cargo-rows,#flightSheet .contract-progress,#flightSheet .contract-bottom,#flightSheet .radar-key{display:flex}
#flightSheet .cargo-rows{display:block;max-height:none}#flightSheet .ship-identity{margin:4px 0 18px}#flightSheet .ship-identity>img{width:42px;height:42px}#flightSheet .ship-identity h2{font-size:23px}
#flightSheet .gauge label,#flightSheet .hold-title,#flightSheet .cargo-row,#flightSheet .ship-stats>span,#flightSheet .heat small{font-size:11px}#flightSheet .gauge{margin:16px 0}#flightSheet .gauge>div{height:4px;margin-top:8px}#flightSheet .cargo-row{line-height:32px}#flightSheet .hold-value{font-size:10px}#flightSheet .radar canvas{height:180px;object-fit:contain}#flightSheet .radar .eyebrow{font-size:10px}#flightSheet .radar-key{font-size:9px}#flightSheet .scan-button{min-height:44px;font-size:11px;justify-content:center;gap:8px}
#flightSheet .contract h2{font-size:22px}#flightSheet .contract p,#flightSheet p{font:13px/1.65 Arial,sans-serif;white-space:pre-line}#flightSheet .contract-progress{display:block}#flightSheet .contract-bottom{font-size:10px}
.sheet-actions{display:grid;grid-template-columns:1fr 1fr;gap:9px}.sheet-actions button{min-height:70px;text-align:left;padding:12px;overflow-wrap:anywhere}.sheet-actions b{font:11px monospace}.sheet-actions span{display:block;font:12px/1.4 Arial,sans-serif;color:var(--muted);margin-top:7px}
#sheetRoute>button,#sheetGuideRow>button{min-height:44px;width:100%;padding:10px;margin-bottom:10px;font:10px monospace}#sheetEvade{border-color:var(--red);color:#ffbb96}#sheetReturn{width:100%;min-height:48px;margin-top:18px;background:#d5b37c;color:#102026;font:11px monospace}#sheetSaveStatus{font-size:11px!important}#sheetOps>a{font:11px monospace;display:inline-block;min-height:44px;padding-top:12px}
.compact-flight{--safe-bottom:max(8px,env(safe-area-inset-bottom));--safe-top:env(safe-area-inset-top)}
.compact-flight .topbar{height:calc(44px + var(--safe-top));padding:var(--safe-top) max(10px,env(safe-area-inset-right)) 0 max(10px,env(safe-area-inset-left));background:linear-gradient(#080e12eb,#080e1290);border:0}.compact-flight .topbar .wordmark b{font-size:11px;letter-spacing:1px}.compact-flight .brand-mark{font-size:24px}.compact-flight .topbar .wordmark{gap:6px}.compact-flight .topbar button{min-height:44px;min-width:54px;font:10px monospace}.compact-flight .topbar .sector,.compact-flight #sound,.compact-flight #help{display:none}.compact-flight .topbar kbd{display:none}
.compact-flight .hud>.ship-panel,.compact-flight .hud>.contract,.compact-flight .hud>.radar,.compact-flight .hud>.sector-label,.compact-flight .hud>.expedition-hints,.compact-flight #notice,.compact-flight .hud>footer{display:none}
.compact-flight .overlay{inset:calc(44px + var(--safe-top)) 0 0;padding:12px}
.compact-flight .hud .mobile-only{display:none}.compact-flight.in-flight .hud .mobile-only{display:flex}
.compact-flight #mobileVitals{position:absolute;top:calc(44px + var(--safe-top));left:max(10px,env(safe-area-inset-left));right:max(10px,env(safe-area-inset-right));width:calc(100% - 20px);min-height:44px;border-radius:6px;border:1px solid #91b4ad2b;background:#0e191eda;justify-content:space-around;align-items:center;padding:4px 3px;gap:3px}
#mobileVitals>span{font:8px monospace;letter-spacing:.6px;color:#a4b6b2}#mobileVitals b{display:block;font:13px/1.4 monospace;letter-spacing:0;color:#e3e8d6}#mobileVitals .danger b{color:#ffa081}#mobileVitals .warm b{color:#edc178}
.compact-flight #mobileMessage{position:absolute;top:calc(96px + var(--safe-top));left:max(10px,env(safe-area-inset-left));right:max(10px,env(safe-area-inset-right));min-height:44px;max-height:52px;padding:6px 10px;border:0;background:#0c1a21b8;border-radius:6px;font:11px/1.45 Arial,sans-serif;color:#c2cec5;text-align:left;align-items:center;gap:8px}
.compact-flight #mobileMessage[hidden]{display:none}#mobileMessage>span{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;flex:1}#mobileMessage>b{font:22px monospace;color:#d6b77d}#mobileMessage.danger{color:#ffbd97!important;border-left:3px solid #e49c6d!important;background:#2b1915eb!important}
.compact-flight .flight-bottom{left:max(10px,env(safe-area-inset-left));right:max(10px,env(safe-area-inset-right));bottom:calc(106px + var(--safe-bottom));transform:none;width:auto;max-width:none;display:flex;gap:6px;height:44px;pointer-events:none}
.compact-flight .campaign-shortcuts{display:contents}.compact-flight .campaign-shortcuts>button{display:none}.compact-flight.in-flight #mapButton,.compact-flight.in-flight #mobileMenu{display:flex;align-items:center;justify-content:center;min-height:44px;width:54px;flex:none;font:10px monospace;padding:3px;letter-spacing:0;margin:0}
.compact-flight #mapButton{order:0}.compact-flight #mobileMenu{order:2}.compact-flight .toolstrip{order:1;flex:1;min-width:0;margin:0;gap:5px}.compact-flight .tool{padding:5px 2px;gap:0;justify-content:center;min-width:0;min-height:44px;border-radius:4px}.compact-flight .tool b{font:9px monospace;letter-spacing:0}.compact-flight .tool small,.compact-flight .tool-icon,.compact-flight .tool kbd,.compact-flight .flight-bottom kbd,.compact-flight .controls{display:none}
.compact-flight .context-action{display:none;position:absolute;bottom:52px;left:50%;transform:translateX(-50%);min-height:44px;max-width:100%;width:max-content;padding:8px 12px;font:10px monospace;border-radius:6px}.compact-flight.in-flight.has-context .context-action{display:block}
.compact-flight .touch-controls{display:flex;left:max(10px,env(safe-area-inset-left));right:max(10px,env(safe-area-inset-right));bottom:var(--safe-bottom);height:98px;align-items:center;justify-content:space-between;pointer-events:none}.compact-flight .touch-left{display:grid;grid-template-columns:repeat(3,48px);gap:5px}.compact-flight .touch-left button{width:48px;height:48px;font-size:25px;background:#13282ba8;border-radius:7px;border-color:#91b9b03b;touch-action:none}.compact-flight .touch-left button[data-hold=brake]{grid-column:1/3;width:100%;height:44px;font:10px monospace}.compact-flight .touch-left button[data-hold=boost]{grid-column:3;width:48px;height:44px;font:9px monospace}
.compact-flight .touch-fire{width:76px;height:76px;border-radius:50%;background:#b39558bd;border-color:#ddbd7b;font:12px monospace;touch-action:none}.compact-flight .touch-controls button.held{background:#e6bc78;color:#122127}.compact-flight:not(.in-flight) .touch-controls,.compact-flight:not(.in-flight) .flight-bottom{display:none}
@media(max-height:500px) and (orientation:landscape){
 .compact-flight #mobileVitals{top:var(--safe-top);left:30%;right:20%;width:50%;min-height:44px}.compact-flight #mobileVitals>span{font-size:7px}.compact-flight #mobileVitals b{font-size:12px}.compact-flight .topbar .wordmark b{font-size:9px}.compact-flight .topbar{background:transparent;pointer-events:none}.compact-flight .topbar a,.compact-flight .topbar button{pointer-events:auto}
 .compact-flight #mobileMessage{top:calc(50px + var(--safe-top));left:27%;right:20%;font-size:10px;max-height:48px;background:#0c1a2199}
 .compact-flight .flight-bottom{left:calc(174px + env(safe-area-inset-left));right:calc(102px + env(safe-area-inset-right));bottom:var(--safe-bottom);height:44px}.compact-flight .context-action{bottom:51px}.compact-flight .touch-controls{bottom:var(--safe-bottom)}
 .compact-flight #flightSheet{max-height:calc(100dvh - 16px)}
}

#mobileCap{display:none}.compact-flight #mobileCap{display:block;font:10px/1.5 monospace;color:#f4e4bb}.compact-flight #mobileCap.danger{color:#ffb296}.compact-flight .mobile-only,#flightSheet button{transition:none}
#mobileVitals:after{content:'›';font:18px monospace;color:#ddbd7b;padding-right:4px}
.sheet-heading{position:sticky;top:-18px;background:#0d191f;z-index:2;padding-top:6px;padding-bottom:5px}

.sheet-actions [data-fullscreen],.sheet-actions [data-fullscreen-note]{grid-column:1/-1}.sheet-actions [data-fullscreen]{min-height:48px;text-align:center;font:11px monospace}.sheet-actions [data-fullscreen-note]{margin:0;font:12px/1.5 Arial,sans-serif}#helpDialog [data-fullscreen]{min-height:44px}
