body,input,select,textarea,button,.link-button{font-family:var(--font-ui);font-variant-numeric:tabular-nums}
h1,h2,.hud-metric strong,#mobile-flight-strip strong{font-family:var(--font-display);font-weight:500;letter-spacing:-.02em}
button,.link-button,input,select,textarea{min-height:44px;border-radius:var(--radius-control);border:1px solid var(--line);background:var(--panel);color:var(--text);box-shadow:none;letter-spacing:normal;transition:background 150ms ease-out,border-color 150ms ease-out}
button:hover,.link-button:hover{background:#2c343d;border-color:#718295}
button:active{background:#384451}
button:disabled{opacity:.45;cursor:not-allowed}
button.primary,.link-button.primary-link{background:var(--accent);color:#101820;border-color:transparent;box-shadow:none}
button.primary:hover{background:#a4d1ff;box-shadow:none}
:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
input,textarea{caret-color:var(--accent)}
::selection{background:var(--accent);color:var(--ink)}
.panel,.hud-panel,#minimap,#annunciator,.multiplayer-drawer,#chat-form{background:var(--hfs-glass);border:1px solid var(--line);border-radius:var(--radius-panel);box-shadow:none;-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur)}
.eyebrow,.hangar-stage-header,.hangar-stage-readout,.auth-meta-row,.auth-feature-grid,.auth-briefing{display:none}
.brief,.message,small{color:var(--muted)}
#auth-screen{background:var(--ink)}
.auth-copy h1{font-size:clamp(36px,5vw,72px);line-height:1.05;max-width:12ch}
.auth-backdrop{opacity:.15}
.training-objective{background:var(--hfs-glass);border:1px solid var(--line);border-radius:var(--radius-panel);padding:16px;color:var(--text);box-shadow:none}
#combat-fire,#combat-retry,#mobile-controls button{min-height:48px;min-width:48px}
#hud strong{font-variant-numeric:tabular-nums;color:var(--text)}
[data-instrument-profile="modern"] #hud{font-family:system-ui,sans-serif}
[data-instrument-profile="modern"] #hud strong{font-family:system-ui,sans-serif}
[data-instrument-profile="fighter"] #attitude-card{border-color:var(--accent)}
[data-instrument-profile="classic"] #attitude-canvas{border-radius:50%}
#settings-dialog{background:var(--panel-strong)}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
.hfs-reduced-motion *{animation:none!important;transition:none!important;scroll-behavior:auto!important}

#select-screen #fly-practice-button,#settings-dialog #settings-resume-button{background:var(--accent);color:var(--ink);border-color:transparent;box-shadow:none}
#select-screen #solo-mode{width:100%;max-width:none;min-width:0}
#select-screen #aircraft-detail-visual{background:#191d21}
#select-screen .aircraft-detail-visual::before,#select-screen .aircraft-detail-visual::after{display:none}
#app-shell{background:var(--ink)}
#auth-panel{background:var(--panel-strong);box-shadow:none}
#aircraft-detail #fly-practice-button .select-action-label{color:var(--ink)}
#select-screen #select-header .select-account{gap:8px}
#select-screen #select-header .account-action-label{font-size:14px}

button:focus,a:focus,input:focus,select:focus,textarea:focus,[tabindex]:focus{outline:2px solid var(--accent);outline-offset:3px}
/* One angular frame language for menus, flight overlays and preflight. */
#app-shell .panel,#app-shell .hud-panel,#app-shell .training-objective,#app-shell .multiplayer-drawer,#app-shell #minimap,#app-shell #annunciator{border-radius:var(--radius-panel);border-color:var(--line);background:var(--hfs-glass);box-shadow:none}
#app-shell button,#app-shell .link-button,#app-shell input,#app-shell select,#app-shell .language-toggle{border-radius:var(--radius-control)}
#app-shell button,#app-shell .link-button{font-weight:500;letter-spacing:.02em}
#app-shell button.primary{clip-path:polygon(0 0,calc(100% - var(--control-cut)) 0,100% var(--control-cut),100% 100%,var(--control-cut) 100%,0 calc(100% - var(--control-cut)));border:0}
#app-shell button:focus,#app-shell .link-button:focus{outline-offset:-3px}
#app-shell .language-toggle{display:flex;gap:0;padding:4px;border:1px solid var(--line);background:var(--ink)}
#app-shell .language-toggle button{flex:1;background:transparent;border:0;box-shadow:none}
#app-shell .language-toggle button.active,#app-shell .language-toggle button[aria-pressed="true"]{background:var(--accent);color:var(--ink)}
#app-shell #auth-screen{background:#10161c;gap:clamp(32px,6vw,96px)}
#auth-screen::before,#auth-screen::after{display:none}
#auth-screen .auth-backdrop{opacity:.35;filter:saturate(.45);background-position:center;background-size:cover}
#auth-screen .auth-copy{position:relative;padding:32px 0;align-self:center}
#auth-screen .auth-copy h1{font-size:clamp(40px,5.2vw,76px);line-height:1.02;max-width:13ch;margin:0 0 24px}
#auth-screen .auth-copy p{max-width:40ch;color:var(--muted);font-size:16px;line-height:1.65}
#app-shell #auth-panel{position:relative;align-self:center;padding:32px;width:100%;max-width:420px;background:#17212b;border:1px solid #506779;clip-path:polygon(var(--panel-cut) 0,100% 0,100% calc(100% - var(--panel-cut)),calc(100% - var(--panel-cut)) 100%,0 100%,0 var(--panel-cut))}
#auth-panel .auth-panel-heading{padding:0 0 24px;margin:0;border-bottom:1px solid var(--line)}
#auth-panel .auth-panel-heading .status-chip{display:none}
#auth-panel h2{font-size:28px;line-height:1.15;margin:0}
#auth-panel #auth-form{gap:24px}
#auth-panel input{background:#0d151d;min-height:52px;border-color:#506779;padding:12px 16px}
#auth-panel #auth-submit{min-height:56px;font-family:var(--font-display);font-size:18px}
#auth-panel .legal-links{justify-content:flex-start}
#auth-panel .legal-links a{min-height:24px;border:0;padding:0;background:transparent;color:var(--muted);font-size:12px}
@media(max-height:500px) and (orientation:landscape){#app-shell #auth-screen{gap:24px;padding:16px}#auth-screen .auth-copy h1{font-size:36px}#auth-screen .auth-copy p{font-size:13px}#app-shell #auth-panel{padding:20px;max-width:340px}#auth-panel #auth-form{gap:12px}#auth-panel .auth-panel-heading{padding-bottom:12px}#auth-panel h2{font-size:22px}#auth-panel .auth-connection-note{font-size:12px;margin:0}}
/* Login language menu shares the angular control system. */
#auth-panel .auth-panel-heading{display:flex;position:relative;align-items:center;justify-content:space-between;gap:16px}
#auth-panel h2{font-size:26px}
#auth-panel .auth-language{position:relative;flex:0 0 44px;z-index:10}
#auth-panel .auth-language summary{display:flex;align-items:center;justify-content:center;width:44px;height:44px;cursor:pointer;list-style:none;border:1px solid var(--line);background:#0d151d}
#auth-panel .auth-language summary::-webkit-details-marker{display:none}
#auth-panel .auth-language summary img{filter:invert(1);opacity:.9}
#auth-panel .auth-language summary:hover,#auth-panel .auth-language[open] summary{border-color:var(--accent);background:#253a4b}
#auth-panel .auth-language summary:focus{outline:2px solid var(--accent);outline-offset:2px}
#auth-panel .auth-language #language-toggle{position:absolute;right:0;top:52px;min-width:160px;display:flex;flex-direction:column;padding:4px;background:#0d151d;border:1px solid #506779;box-shadow:0 12px 24px #0006}
#auth-panel .auth-language:not([open]) #language-toggle{display:none}
#auth-panel .auth-language #language-toggle button{width:100%;text-align:left;padding:12px 16px;min-height:44px}
#auth-panel .auth-language #language-toggle button:hover{background:#253a4b}
#auth-panel .auth-language #language-toggle button.active{background:var(--accent);color:var(--ink)}
#auth-message:empty{display:none}
#app-shell #auth-screen{background:#0d1723}
#auth-screen .auth-backdrop{position:absolute;inset:0;background:url('https://hamfs-assets.743.world/releases/r20261031-1514/assets/ui/hfs-login-dusk-night.webp') center center/cover no-repeat;opacity:1;filter:none;pointer-events:none}
#auth-screen .auth-backdrop::before{content:"";position:absolute;inset:0;background:linear-gradient(90deg,rgba(5,12,22,.5),rgba(5,12,22,.15) 58%,rgba(5,12,22,.28))}
#auth-screen .auth-copy{z-index:1;text-shadow:0 3px 16px #0009}
#auth-screen .auth-copy h1{max-width:11ch}
#auth-screen .auth-copy p{color:#f1f4f7;max-width:35ch}
#app-shell #auth-panel{z-index:2;background:rgba(17,29,41,.96);overflow:visible}

/* Flight surfaces share the same translucent material as menus and preflight. */
#app-shell .panel, #app-shell .hud-panel, #app-shell .training-objective,
#app-shell .multiplayer-drawer, #app-shell #minimap, #app-shell #annunciator,
#app-shell #settings-button, #app-shell #hud-mode-button, #app-shell #flight-network-chip,
#app-shell #mobile-flight-strip, #app-shell .mobile-throttle, #app-shell #chat-form,
#app-shell #mobile-controls button, #app-shell #pilot-menu[open],
#app-shell #hangar-mode-panel, #app-shell #auth-panel {
  color: var(--text);
  background: var(--hfs-glass);
  border: 1px solid var(--glass-line);
  border-radius: var(--radius-panel);
  box-shadow: none;
  -webkit-backdrop-filter: var(--glass-blur);
  backdrop-filter: var(--glass-blur);
}
#app-shell .hud-panel::before, #app-shell #minimap::before,
#app-shell #minimap::after { display: none; }
#app-shell button, #app-shell .link-button, #app-shell input, #app-shell select,
#app-shell textarea { background: var(--glass-control); border-color: var(--glass-line); color: var(--text); }
#app-shell button:hover, #app-shell .link-button:hover { background: rgba(175,215,255,.22); }
#app-shell button:active { background: rgba(175,215,255,.32); }
#app-shell button.primary, #app-shell #fly-practice-button,
#app-shell #settings-resume-button { background: var(--accent); color: var(--ink); }
#app-shell button.primary:hover { background: #a4d1ff; }
#app-shell select option { color: var(--text); background: #30485e; }
#app-shell input[type=checkbox] { min-height: 20px; accent-color: var(--accent); }
#app-shell input[type=range] { accent-color: var(--accent); border: 0; background: transparent; }
#app-shell .toggle-row, #app-shell .range-row, #app-shell .select-row,
#app-shell .multiplayer-session-status, #app-shell .multiplayer-roster-item,
#app-shell .training-checklist li { background: rgba(204,229,250,.06); border-color: var(--glass-line); border-radius: 0; box-shadow: none; }
#app-shell .settings-label, #app-shell .hud-label { color: var(--text); font-family: var(--font-ui); letter-spacing: normal; }
#app-shell #settings-scrim, #app-shell #server-node-scrim, #app-shell #changelog-scrim {
  background: rgba(41,65,86,.18); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px);
}
#app-shell #settings-dialog, #app-shell .multiplayer-drawer,
#app-shell #server-node-dialog, #app-shell #changelog-dialog { background: var(--hfs-glass-strong); }
#app-shell #settings-dialog { padding: 24px; top: max(16px,var(--safe-top)); bottom: max(16px,var(--safe-bottom)); max-height: none; width: min(460px,calc(100vw - 32px)); }
#app-shell #settings-header { padding: 0 0 16px; margin: 0; }
#app-shell #settings-header h2 { font-size: 28px; }
#app-shell #settings-resume-button { min-height: 48px; }
#app-shell .settings-section { border-top: 1px solid var(--glass-line); padding-top: 20px; margin-top: 20px; gap: 12px; }
#app-shell .settings-section .settings-label { font-size: 16px; font-weight: 500; }
#app-shell .keybind-row { border-radius: 0; background: transparent; border-color: var(--glass-line); }
#app-shell .keybind-row strong { font-family: var(--font-ui); font-size: 12px; }
#app-shell .settings-session-actions .button-row { display: grid; grid-template-columns: 1fr 1fr; }
#app-shell .settings-session-actions p { display: none; }
#app-shell .training-objective > span { display: none; }
#app-shell .training-objective strong { font-family: var(--font-ui); font-size: 14px; letter-spacing: 0; }
#app-shell .training-objective p { font-size: 12px; line-height: 1.5; color: var(--text); }
#app-shell .training-objective small { font-family: var(--font-ui); color: #d5e5f3; }
#app-shell #hud { opacity: 1; filter: none; pointer-events: none; }
#app-shell #hud strong, #app-shell #mobile-flight-strip strong { color: var(--text); font-family: var(--font-ui); font-weight: 500; }
#app-shell .hud-mode-button-label { color: var(--text); }
#app-shell #hud-mode-button { font-family: var(--font-ui); }
#app-shell #hud-mode-button strong { font-family: var(--font-ui); font-size: 12px; letter-spacing: .02em; }
#app-shell #flight-network-chip { font-family: var(--font-ui); min-height: 44px; }
#app-shell #flight-network-chip > span { display: none; }
#app-shell #flight-network-chip strong { font-family: var(--font-ui); font-size: 12px; }
#app-shell #attitude-canvas { background: transparent; border-radius: 0; }
#app-shell .hud-data-state, #app-shell .hud-data-header, #app-shell .hud-label-stack,
#app-shell .hud-lever-bank { display: none !important; }
#app-shell .hud-panel-header { justify-content: flex-end; }
#app-shell .hud-heading-readout { display: flex; align-items: baseline; gap: 8px; }
#app-shell .hud-heading-readout span, #app-shell .hud-attitude-foot span { color: #d5e5f3; font-size: 11px; letter-spacing: .03em; }
#app-shell .hud-heading-readout strong, #app-shell .hud-attitude-foot strong { font-size: 13px; }
#app-shell .hud-attitude-foot > div { display: flex; align-items: baseline; gap: 6px; }
#app-shell .hud-metric { border: 0; background: transparent; }
#app-shell .hud-metric span { color: #d5e5f3; font-family: var(--font-ui); font-weight: 400; letter-spacing: .04em; }
#app-shell .hud-metric strong.engaged { color: var(--accent); }
#app-shell .hud-metric[data-system=brake] strong.engaged,
#app-shell .hud-metric[data-system=spoiler] strong.engaged { color: var(--caution); }
#app-shell #hud strong.disabled { color: #c2d2df; opacity: .7; }
#app-shell #annunciator { font-family: var(--font-ui); border-radius: 0; padding: 10px 16px; }
#app-shell #annunciator.standby { display: none; }
#app-shell #annunciator strong { color: var(--text); }
#app-shell #annunciator .annunciator-item-warning strong { color: var(--caution); }
#app-shell #annunciator .annunciator-item-danger strong { color: var(--danger); }
/* Explicit desktop geometry: controls, telemetry, chart never share a slot. */
#app-shell #game-screen:not(.mobile-controls-enabled) #settings-button { top: max(16px,var(--safe-top)); left: max(16px,var(--safe-left)); right: auto; height: 48px; min-width: 96px; padding: 0 12px; }
#app-shell #game-screen:not(.mobile-controls-enabled) #hud-mode-button { top: max(16px,var(--safe-top)); left: calc(max(16px,var(--safe-left)) + 104px); right: auto; height: 48px; min-width: 96px; padding: 0 12px; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-compact #hud {
  top: calc(max(16px,var(--safe-top)) + var(--hfs-desktop-hud-inset,0px)); bottom: auto;
  left: 50%; right: auto; width: min(464px,calc(100vw - 492px)); height: 56px;
  transform: translateX(-50%) scale(var(--hfs-desktop-hud-scale,1)); display: block;
}
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-compact #hud-strip { width: 100%; min-width: 0; height: 56px; padding: 8px 12px; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-compact .hud-data-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-compact .hud-metric { padding: 0; gap: 4px; min-width: 0; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-compact .hud-metric strong { font-size: 17px; line-height: 1.2; white-space: nowrap; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-compact .hud-metric span { font-size: 11px; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud {
  left: max(16px,calc(var(--safe-left) + var(--hfs-desktop-hud-inset,0px)));
  bottom: max(16px,calc(var(--safe-bottom) + var(--hfs-desktop-hud-inset,0px))); top: auto; right: auto;
  display: grid; grid-template-columns: 224px minmax(0,1fr); gap: 8px;
  width: 504px; height: 260px; transform: scale(var(--hfs-desktop-hud-scale,1)); transform-origin: left bottom;
}
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud #attitude-card { width: 224px; height: 260px; min-height: 0; padding: 12px; grid-template-rows: 20px 192px 16px; gap: 4px; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #attitude-canvas { width: 192px; height: 192px; max-width: none; max-height: none; justify-self: center; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud #hud-strip { height: 260px; min-width: 0; padding: 16px; display: block; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud-strip .hud-data-grid { display: grid; height: 100%; grid-template-columns: repeat(2,minmax(0,1fr)); grid-template-rows: repeat(5,minmax(0,1fr)); gap: 8px 16px; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud-strip .hud-metric { display: grid; padding: 0; gap: 3px; align-content: center; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud-strip .hud-metric span { font-size: 11px; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud-strip .hud-metric strong { font-size: 17px; white-space: nowrap; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full .hud-metric:nth-child(-n+2) strong { font-size: 23px !important; }
#app-shell #game-screen:not(.mobile-controls-enabled) #minimap { width: 208px; height: 208px; top: max(16px,var(--safe-top)); right: max(16px,var(--safe-right)); transform: none; padding: 0; overflow: hidden; }
#app-shell #minimap-canvas { display: block; width: 100%; height: 100%; border-radius: 0; opacity: 1; }
#app-shell #game-screen:not(.mobile-controls-enabled) #flight-network-chip { top: max(232px,calc(var(--safe-top) + 216px)); right: max(16px,var(--safe-right)); width: auto; min-width: 80px; transform: none; }
#app-shell #game-screen:not(.mobile-controls-enabled) .training-objective { top: max(80px,calc(var(--safe-top) + 64px)); left: max(16px,var(--safe-left)); width: 260px; padding: 12px; gap: 6px; }
#app-shell #game-screen:not(.mobile-controls-enabled) #annunciator { top: 84px; max-width: min(440px,calc(100vw - 560px)); }
#app-shell #game-screen.hud-mode-hidden #hud,
#app-shell #game-screen.hud-mode-hidden #minimap,
#app-shell #game-screen.hud-mode-hidden .training-objective { opacity: 0; visibility: hidden; }
@media(max-width:1000px) {
  #app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-compact #hud { left: max(16px,var(--safe-left)); top: 76px; width: min(400px,calc(100vw - 200px)); transform: none; }
  #app-shell #game-screen:not(.mobile-controls-enabled) #minimap { width: 152px; height: 152px; }
  #app-shell #game-screen:not(.mobile-controls-enabled) #flight-network-chip { top: 176px; }
  #app-shell #game-screen:not(.mobile-controls-enabled) .training-objective { top: 144px; width: 240px; }
  #app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full .training-objective { top: 76px; }
}
@media(max-height:550px) {
  #app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud { transform: scale(.72); }
  #app-shell #game-screen:not(.mobile-controls-enabled) #minimap { width: 144px; height: 144px; }
  #app-shell #game-screen:not(.mobile-controls-enabled) #flight-network-chip { top: 168px; }
}
@media(max-width:600px) {
  #app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud { width: 504px; transform: scale(.66); }
  #app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-compact #hud { width: calc(100vw - 32px); }
  #app-shell #game-screen:not(.mobile-controls-enabled) #minimap { top: 148px; width: 144px; height: 144px; }
  #app-shell #game-screen:not(.mobile-controls-enabled) #flight-network-chip { top: 300px; }
}
#app-shell #game-screen.mobile-controls-enabled #hud-mode-button,
#app-shell #game-screen.mobile-controls-enabled #settings-button { min-height: 48px; height: 48px; }
#app-shell #game-screen.mobile-controls-enabled #mobile-flight-strip { opacity: 1; }
#app-shell #game-screen.mobile-controls-enabled #hud { filter: none; }
#app-shell #game-screen.mobile-controls-enabled #attitude-canvas { background: transparent; }
#app-shell #game-screen.mobile-controls-enabled .mobile-throttle { box-shadow: none; }
#app-shell #game-screen.mobile-controls-enabled #mobile-controls button::after { color: var(--text); font-family: var(--font-ui); }
#app-shell #game-screen.mobile-controls-enabled #minimap { border-radius: 0; padding: 0; overflow: hidden; }
/* Three instruments: primary flight display, systems, total simulated thrust. */
#app-shell #engine-card { display: none; }
#app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud { width: 632px; grid-template-columns: 224px 244px 148px; }
#app-shell #game-screen.hud-mode-full #engine-card { display: grid; align-content: center; gap: 8px; padding: 12px; }
#app-shell #engine-card .instrument-title { text-align: center; color: #e7f1fa; font: 500 11px var(--font-ui); letter-spacing: .06em; }
#app-shell #engine-canvas { width: 100%; height: auto; }
#app-shell #game-screen:not(.mobile-controls-enabled) #minimap { width: 224px; height: 268px; display: grid; grid-template-rows: 224px 44px; }
#app-shell #game-screen:not(.mobile-controls-enabled) #flight-network-chip { top: max(292px,calc(var(--safe-top) + 276px)); }
#app-shell .map-controls { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--glass-line); background: rgba(213,234,254,.05); }
#app-shell .map-controls button { width: 44px; height: 44px; min-height: 44px; padding: 12px; border: 0; background: transparent; }
#app-shell .map-controls button svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 1.5; fill: none; }
#app-shell .map-controls output { font: 12px var(--font-ui); color: var(--text); }
#app-shell #game-screen.mobile-controls-enabled #minimap { height: auto; display: grid; grid-template-rows: auto 44px; }
#app-shell #game-screen.mobile-controls-enabled #minimap-canvas { aspect-ratio: 1; height: auto; }
#app-shell #game-screen.mobile-controls-enabled .map-controls { min-height: 44px; }
#app-shell #game-screen.mobile-controls-enabled.hud-mode-compact #engine-card { display: none; }
#app-shell #game-screen.mobile-controls-enabled.hud-mode-full #engine-card { display: none; }
@media(max-width:1000px) {
  #app-shell #game-screen:not(.mobile-controls-enabled) #minimap { width: 168px; height: 212px; grid-template-rows: 168px 44px; }
  #app-shell #game-screen:not(.mobile-controls-enabled) #flight-network-chip { top: 236px; }
  #app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud { transform: scale(.82); }
}
@media(max-height:550px) {
  #app-shell #game-screen:not(.mobile-controls-enabled) #minimap { width: 144px; height: 188px; grid-template-rows: 144px 44px; }
  #app-shell #game-screen:not(.mobile-controls-enabled) #flight-network-chip { top: 212px; }
  #app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud { transform: scale(.68); }
  #app-shell #game-screen:not(.mobile-controls-enabled) .training-objective small { display: none; }
}
@media(max-width:600px) {
  #app-shell #game-screen:not(.mobile-controls-enabled).hud-mode-full #hud { transform: scale(.65); }
  #app-shell #game-screen:not(.mobile-controls-enabled) #minimap { top: 148px; width: 144px; height: 188px; grid-template-rows: 144px 44px; }
  #app-shell #game-screen:not(.mobile-controls-enabled) #flight-network-chip { top: 344px; }
}
#app-shell #game-screen #hud #attitude-card,
#app-shell #game-screen #hud #hud-strip,
#app-shell #game-screen #hud #engine-card { background: var(--hfs-glass); border: 1px solid var(--glass-line); border-radius: 0; box-shadow: none; -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); }
#app-shell #hud-strip .hud-metric strong:not(.disabled):not(.engaged),
#app-shell #hud-strip .hud-metric:nth-child(2) strong { color: var(--text); }
#app-shell .settings-tab-hidden { display: none !important; }
#app-shell .settings-tabs { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 4px; margin-top: 20px; padding: 0 0 8px; border-bottom: 1px solid var(--glass-line); }
#app-shell .settings-tabs button { padding: 8px 4px; font-size: 13px; border: 0; border-bottom: 2px solid transparent; background: transparent; }
#app-shell .settings-tabs button[aria-selected=true] { border-bottom-color: var(--accent); background: rgba(180,217,255,.14); }
#app-shell #settings-header { background: transparent; position: static; border: 0; box-shadow: none; }
#app-shell .select-row > span { flex: 1 0 auto; white-space: nowrap; }
#app-shell .select-row select { width: auto; flex: 0 1 60%; min-width: 0; }
#app-shell #settings-dialog .settings-tabs + .settings-section,
#app-shell #settings-dialog .graphics-settings-section { border-top: 0; margin-top: 16px; padding-top: 0; }
#app-shell #game-screen.mobile-controls-enabled #settings-button { left: max(12px,var(--safe-left)); top: max(8px,var(--safe-top)); width: 48px; }
#app-shell #game-screen.mobile-controls-enabled #hud-mode-button { left: calc(max(12px,var(--safe-left)) + 56px); top: max(8px,var(--safe-top)); min-width: 88px; }
#app-shell #game-screen.mobile-controls-enabled #mobile-flight-strip { left: max(166px,calc(var(--safe-left) + 154px)); right: max(166px,calc(var(--safe-right) + 154px)); top: max(8px,var(--safe-top)); width: auto; max-width: none; min-height: 48px; height: 48px; padding: 6px 12px; transform: none; display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; border-radius: 0; background: var(--hfs-glass); }
#app-shell #game-screen.mobile-controls-enabled #mobile-flight-strip > div { display: grid; gap: 2px; text-align: left; border: 0; }
#app-shell #game-screen.mobile-controls-enabled #mobile-flight-strip span { font-size: 11px; color: #e0edf8; letter-spacing: .02em; }
#app-shell #game-screen.mobile-controls-enabled #mobile-flight-strip strong { font-size: 14px; }
#app-shell #game-screen.mobile-controls-enabled #minimap { top: max(8px,var(--safe-top)); right: max(12px,var(--safe-right)); width: 144px; height: 188px; grid-template-rows: 144px 44px; transform: none; opacity: 1; }
#app-shell #game-screen.mobile-controls-enabled #flight-network-chip { right: max(12px,var(--safe-right)); top: 204px; min-width: 56px; display: none; }
#app-shell #game-screen.mobile-controls-enabled.hud-mode-full #hud { left: max(12px,var(--safe-left)); top: max(68px,calc(var(--safe-top) + 60px)); width: 252px; height: 140px; display: grid; grid-template-columns: 140px 104px; gap: 8px; transform: none; opacity: 1; pointer-events: none; }
#app-shell #game-screen.mobile-controls-enabled.hud-mode-full #hud #attitude-card { display: grid; width: 140px; min-width: 0; max-width: none; height: 140px; padding: 4px; grid-template-rows: 1fr; }
#app-shell #game-screen.mobile-controls-enabled.hud-mode-full #attitude-canvas { width: 132px; height: 132px; max-width: none; max-height: none; opacity: 1; }
#app-shell #game-screen.mobile-controls-enabled.hud-mode-full #hud-strip { display: none !important; }
#app-shell #game-screen.mobile-controls-enabled.hud-mode-full #engine-card { display: grid; padding: 4px; gap: 0; }
#app-shell #game-screen.mobile-controls-enabled #engine-card .instrument-title { font-size: 11px; }
#app-shell #game-screen.mobile-controls-enabled .training-objective { top: max(68px,calc(var(--safe-top) + 60px)); left: max(12px,var(--safe-left)); width: 230px; padding: 8px 12px; }
#app-shell #game-screen.mobile-controls-enabled.hud-mode-full .training-objective { left: 280px; width: min(210px,calc(100vw - 460px)); }
#app-shell #game-screen.mobile-controls-enabled .training-objective strong { font-size: 12px; }
#app-shell #game-screen.mobile-controls-enabled .training-objective p { font-size: 11px; }
#app-shell #game-screen.mobile-controls-enabled .mobile-throttle { right: max(12px,var(--safe-right)); bottom: max(16px,var(--safe-bottom)); width: 56px; height: 160px; min-height: 160px; --mobile-throttle-length: 110px; }
#app-shell #game-screen.mobile-controls-enabled #mobile-gear-button { right: calc(max(12px,var(--safe-right)) + 64px); left: auto; bottom: max(16px,var(--safe-bottom)); }
#app-shell #game-screen.mobile-controls-enabled #mobile-camera-button { right: calc(max(12px,var(--safe-right)) + 120px); left: auto; bottom: max(16px,var(--safe-bottom)); }
#app-shell #game-screen.mobile-controls-enabled #mobile-flap-button { right: calc(max(12px,var(--safe-right)) + 64px); left: auto; bottom: calc(max(16px,var(--safe-bottom)) + 56px); }
#app-shell #game-screen.mobile-controls-enabled #mobile-chat-button { right: calc(max(12px,var(--safe-right)) + 120px); left: auto; bottom: calc(max(16px,var(--safe-bottom)) + 56px); opacity: 1; }
#app-shell #game-screen.mobile-controls-enabled #mobile-controls button { width: 48px; min-width: 48px; height: 48px; min-height: 48px; }
#app-shell #mobile-stick-knob { background: #b4ddff; border-color: #e1f1ff; box-shadow: none; }
#app-shell #game-screen.mobile-controls-enabled #annunciator { top: 68px; left: 50%; width: auto; min-width: 0; max-width: calc(100vw - 520px); padding: 6px 10px; }
@media(max-width:700px) {
  #app-shell #game-screen.mobile-controls-enabled #hud-mode-button { min-width: 80px; padding: 0 6px; }
  #app-shell #game-screen.mobile-controls-enabled #mobile-flight-strip { left: 156px; right: 164px; padding: 6px 8px; gap: 4px; }
  #app-shell #game-screen.mobile-controls-enabled #mobile-flight-strip strong { font-size: 12px; }
  #app-shell #game-screen.mobile-controls-enabled.hud-mode-full .training-objective { left: 276px; width: calc(100vw - 448px); }
}
#app-shell #game-screen #settings-button,
#app-shell #game-screen #hud-mode-button { background: var(--hfs-glass); border: 1px solid var(--glass-line); border-radius: 0; box-shadow: none; overflow: hidden; -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); }
#app-shell #game-screen.mobile-controls-enabled #hud-mode-button { width: 88px; min-width: 88px; padding: 0 4px; }
#app-shell #game-screen.mobile-controls-enabled #hud-mode-button strong { font-size: 11px; }
#app-shell #game-screen #settings-button::after,
#app-shell #game-screen #hud-mode-button::after { display: none; }
#app-shell #game-screen #mobile-flight-strip > .sr-only { position: absolute; }
#app-shell #game-screen .mobile-stick { border-color: var(--glass-line); background-color: rgba(208,230,255,.06); }
@media(max-width:700px) { #app-shell #game-screen.mobile-controls-enabled #hud-mode-button { width: 80px; min-width: 80px; } }

/* Keep flight inputs outside the joystick's full travel envelope. */
#app-shell #game-screen.mobile-controls-enabled .mobile-button-bank button[data-mobile-hold="yaw-left"],
#app-shell #game-screen.mobile-controls-enabled #mobile-brake-button { left: calc(18vw + var(--mobile-stick-size) * .5 + 12px); }
#app-shell #game-screen.mobile-controls-enabled .mobile-button-bank button[data-mobile-hold="yaw-right"],
#app-shell #game-screen.mobile-controls-enabled #mobile-spoiler-button { left: calc(18vw + var(--mobile-stick-size) * .5 + 68px); }
#app-shell #game-screen.mobile-controls-enabled .mobile-button-bank button[data-mobile-hold="yaw-left"],
#app-shell #game-screen.mobile-controls-enabled .mobile-button-bank button[data-mobile-hold="yaw-right"] { bottom: calc(max(16px,var(--safe-bottom)) + 56px); }
#app-shell #game-screen.mobile-controls-enabled #mobile-brake-button,
#app-shell #game-screen.mobile-controls-enabled #mobile-spoiler-button { bottom: max(16px,var(--safe-bottom)); }
#app-shell #game-screen.mobile-controls-enabled .hud-mode-button-label { display: none; }
#app-shell #game-screen.mobile-controls-enabled #hud-mode-button strong { font-size: 11px; }
@media (max-height:550px) {
  #app-shell #settings-dialog { width: min(600px,calc(100vw - 32px)); padding: 16px; }
  #app-shell #settings-header { min-height: 48px; margin: 0; padding: 0; }
  #app-shell #settings-resume-button { position: absolute; top: 16px; right: 76px; width: 180px; min-height: 44px; margin: 0; }
  #app-shell .settings-tabs { margin-top: 12px; }
}

#app-shell button.primary { color: #101820; }
#app-shell #aircraft-preview-status { font-size: 12px; }
#app-shell .mobile-throttle-value { font-size: 12px; }
