:root {
  --bg: #07090c; --panel: #0d1116; --panel2: #131920; --line: #232c36; --line2: #2f3a46;
  --text: #dfe5ec; --muted: #8893a0; --faint: #56606b;
  --cyan: #2fd9ff; --magenta: #ff4fd8; --green: #38e05a; --amber: #ffb020; --red: #ff3b30;
  --ui: "Barlow Semi Condensed", "B612", system-ui, sans-serif; --mono: "B612 Mono", ui-monospace, monospace;
  --top-h: 46px; --panel-h: clamp(230px, 34vh, 400px);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); font-family: var(--ui); overflow: hidden; -webkit-font-smoothing: antialiased; }
button, select, input { font: inherit; color: inherit; }
button { cursor: pointer; }
#app { position: fixed; inset: 0; display: flex; flex-direction: column; }

/* ---------------- top bar ---------------- */
#topbar { height: var(--top-h); flex: none; display: flex; align-items: center; gap: 14px; padding: 0 12px; background: linear-gradient(#11161c, #0b0f13); border-bottom: 1px solid var(--line); z-index: 5; }
.brand { display: flex; align-items: center; gap: 8px; color: var(--cyan); }
.brand-name { font-family: var(--mono); font-weight: 700; font-size: 17px; letter-spacing: .06em; color: #fff; }
.brand-sub { font-size: 11px; letter-spacing: .18em; color: var(--muted); font-weight: 600; }
.scen-label { color: var(--muted); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; flex: 1 1 auto; }
.chips { display: flex; gap: 6px; }
.chip { font-family: var(--mono); font-size: 11px; padding: 3px 7px; border-radius: 3px; border: 1px solid currentColor; }
.chip.amber { color: var(--amber); } .chip.cyan { color: var(--cyan); } .chip.red { color: #fff; background: var(--red); border-color: var(--red); animation: blink .6s steps(2) infinite; }
@keyframes blink { 50% { opacity: .35; } }
.seg { display: flex; border: 1px solid var(--line2); border-radius: 6px; overflow: hidden; }
.seg button { background: transparent; border: 0; padding: 6px 11px; font-size: 13px; font-weight: 600; color: var(--muted); border-right: 1px solid var(--line); }
.seg button:last-child { border-right: 0; }
.seg button.on { background: #18303c; color: var(--cyan); }
.seg button:hover { color: #fff; }
.tools { display: flex; gap: 6px; }
.tbtn { background: var(--panel2); border: 1px solid var(--line2); border-radius: 5px; padding: 6px 10px; font-size: 12px; font-weight: 700; letter-spacing: .06em; color: var(--muted); }
.tbtn:hover { color: #fff; border-color: #44515f; }
.tbtn.on { color: var(--green); border-color: #2a5a36; background: #0f2016; }
#b-pause.on { color: var(--amber); border-color: #6a4a10; background: #241a08; }

/* ---------------- 3D view ---------------- */
#view { position: relative; flex: 1 1 auto; min-height: 0; overflow: hidden; background: #000; }
#gl, #hud { position: absolute; left: 0; top: 0; width: 100%; height: 100%; display: block; }
#gl { touch-action: none; }
#hud { pointer-events: none; }
#fps { position: absolute; left: 8px; top: 6px; font: 11px var(--mono); color: #9f9; pointer-events: none; }
#toasts { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 6px; align-items: center; pointer-events: none; z-index: 6; width: min(680px, 92%); }
.toast { background: rgba(10,14,18,.88); border: 1px solid var(--line2); border-left: 3px solid var(--cyan); padding: 8px 14px; border-radius: 5px; font-size: 14px; font-weight: 500; backdrop-filter: blur(6px); transition: opacity .35s, transform .35s; text-align: center; }
.toast.good { border-left-color: var(--green); } .toast.warn { border-left-color: var(--amber); }
.toast.out { opacity: 0; transform: translateY(-6px); }

/* ---------------- instrument panel ---------------- */
#panel { position: relative; flex: none; height: var(--panel-h); display: flex; gap: 8px; padding: 8px; background: linear-gradient(#1a2028, #0f1318); border-top: 1px solid #2b333d; box-shadow: 0 -8px 24px rgba(0,0,0,.5); z-index: 4; }
#app.nopanel #panel { display: none; }
#du-tabs { display: none; }
#displays { flex: 1 1 auto; display: flex; gap: 8px; justify-content: center; min-width: 0; }
.du { position: relative; height: 100%; aspect-ratio: 560 / 600; flex: 0 1 auto; background: #000; border: 6px solid #22282f; border-radius: 6px; box-shadow: inset 0 0 0 1px #000, 0 2px 0 #333b44; min-width: 0; }
.du canvas { width: 100%; height: 100%; display: block; }
.mfd-ctl { position: absolute; right: 6px; top: 34px; display: flex; flex-direction: column; gap: 4px; }
.mfd-ctl button { background: rgba(10,14,18,.8); border: 1px solid var(--line2); color: var(--cyan); font: 700 10px var(--mono); padding: 4px 6px; border-radius: 3px; }
.pcol { flex: none; display: flex; flex-direction: column; gap: 6px; background: #12171d; border: 1px solid var(--line); border-radius: 6px; padding: 8px; overflow: auto; }
#afcs { width: 244px; }
.knob { min-width: 0; }
.afcs-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.afcs-row:first-child { grid-template-columns: repeat(5, 1fr); }
.apb { position: relative; background: #1d242c; border: 1px solid #333d48; border-radius: 4px; padding: 7px 2px 5px; font: 700 11px var(--mono); color: #c9d1da; box-shadow: 0 2px 0 #0a0d10; }
.apb:active { transform: translateY(1px); box-shadow: none; }
.apb .led { display: block; width: 60%; height: 3px; margin: 0 auto 4px; background: #2a333c; border-radius: 2px; }
.apb.on .led { background: var(--green); box-shadow: 0 0 6px var(--green); }
.apb.armed .led { background: #fff; box-shadow: 0 0 5px #fff; }
.knobs { grid-template-columns: 1fr 1fr !important; }
.knob { background: #0b0e12; border: 1px solid var(--line); border-radius: 4px; padding: 4px; text-align: center; }
.klabel { font: 700 10px var(--mono); color: var(--muted); }
.krow { display: flex; align-items: center; justify-content: space-between; gap: 2px; }
.kbtn { flex: none; width: 22px; height: 22px; background: #222a33; border: 1px solid #36414c; border-radius: 12px; font-weight: 700; line-height: 1; padding: 0; }
.kval { font: 700 13px var(--mono); color: var(--cyan); min-width: 0; flex: 1; text-align: center; cursor: ns-resize; }
.ksync { margin-top: 3px; background: none; border: 1px solid var(--line2); border-radius: 3px; font: 600 9px var(--mono); color: var(--muted); padding: 1px 6px; }
#quad { width: 276px; flex-direction: row; gap: 8px; }
.q-col { display: flex; flex-direction: column; gap: 5px; flex: 1; min-width: 0; overflow: hidden; }
.thr-col { flex: none; width: 62px; align-items: center; }
.q-main { display: flex; flex-direction: column; gap: 7px; flex: 1; min-width: 0; }
.q-flaps { display: flex; flex-direction: column; gap: 5px; position: relative; z-index: 1; }
.q-split { display: flex; flex-direction: row; gap: 8px; min-height: 0; flex: 1; }
.qlab { font: 700 9.5px var(--mono); color: var(--muted); letter-spacing: .04em; }
.qval { font: 700 10px var(--mono); color: var(--cyan); text-align: center; }
.thr-wrap { position: relative; flex: 1; display: flex; align-items: stretch; min-height: 0; width: 100%; justify-content: center; }
.detents { position: absolute; left: -2px; top: 4px; bottom: 4px; display: flex; flex-direction: column; justify-content: space-between; font: 8px var(--mono); color: var(--faint); pointer-events: none; }
.thr { writing-mode: vertical-lr; direction: rtl; width: 34px; height: 100%; accent-color: #d8dde3; margin-left: 14px; }
.flapsel { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 3px; width: 100%; }
.flapsel button, .qbtn { background: #1d242c; border: 1px solid #333d48; border-radius: 4px; font: 700 10.5px var(--mono); padding: 6px 2px; color: #c9d1da; }
.flapsel button { min-width: 0; overflow: hidden; text-overflow: clip; white-space: nowrap; padding-left: 0; padding-right: 0; letter-spacing: -0.02em; }
.flapsel.many button { padding: 5px 1px; font-size: 10px; }
.flapsel button.on, .qbtn.on { color: var(--green); border-color: #2a5a36; background: #0f2016; }
.qrow { display: flex; gap: 4px; align-items: center; }
.qrow .qbtn { flex: 1 1 0; min-width: 0; padding-left: 1px; padding-right: 1px; font-size: 9.5px; }
.qbtn.trim { white-space: normal; line-height: 1.1; padding-top: 3px; padding-bottom: 3px; }
.qbtn { white-space: nowrap; overflow: hidden; }
.qrow > * { flex: 1; }
.gearlever { background: #1d242c; border: 1px solid #333d48; border-radius: 6px; height: 56px; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding: 6px; gap: 4px; transition: justify-content .2s; }
.gearlever .wheel { width: 26px; height: 26px; border-radius: 50%; background: radial-gradient(circle, #ddd 0 30%, #777 31% 60%, #222 61%); }
.gearlever.down { justify-content: flex-end; flex-direction: column-reverse; border-color: #2a5a36; }
.gl-txt { font: 700 10px var(--mono); color: var(--muted); }
.gearlever.down .gl-txt { color: var(--green); }

/* ---------------- systems drawer ---------------- */
#systems { position: absolute; top: 0; right: 0; bottom: 0; width: 330px; max-width: 92vw; background: rgba(12,16,21,.96); border-left: 1px solid var(--line2); transform: translateX(105%); transition: transform .25s ease; z-index: 7; overflow-y: auto; padding: 10px 12px 20px; backdrop-filter: blur(8px); }
#systems.open { transform: none; }
.sys-head { display: flex; justify-content: space-between; align-items: center; }
.sys-head h2 { margin: 0; font-size: 18px; letter-spacing: .04em; }
.sys-sect { margin-top: 12px; }
.sys-sect h3 { margin: 0 0 6px; font: 700 11px var(--mono); color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }
.swgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.swgrid.three { grid-template-columns: repeat(3, 1fr); }
.sw { display: flex; align-items: center; gap: 6px; justify-content: center; background: #1a2027; border: 1px solid #333d48; border-radius: 4px; padding: 8px 6px; font: 700 11px var(--mono); color: #c3ccd5; }
.sw .sw-dot { width: 8px; height: 8px; border-radius: 50%; background: #2c353e; flex: none; }
.sw.on .sw-dot { background: var(--green); box-shadow: 0 0 6px var(--green); }
.sw.warn.on .sw-dot { background: var(--red); box-shadow: 0 0 6px var(--red); }
.sw.start:active .sw-dot { background: var(--amber); }
.hint { color: var(--muted); font-size: 13px; line-height: 1.4; margin: 8px 0 0; }
.fld { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); margin: 8px 0; }
.fld select { background: #0b0e12; border: 1px solid var(--line2); border-radius: 4px; padding: 7px; color: var(--text); font: 12px var(--mono); }
#systems .qrow { margin-top: 6px; }
#systems .qrow .kval { flex: 0 0 64px; }

/* ---------------- touch controls ---------------- */
#touch { display: none; }
#app.mobile #touch { display: block; position: absolute; inset: 0; pointer-events: none; z-index: 3; }
.yoke-pad { position: absolute; left: 14px; bottom: 14px; width: 130px; height: 130px; border-radius: 50%; border: 2px solid rgba(255,255,255,.35); background: rgba(0,0,0,.25); pointer-events: auto; touch-action: none; display: grid; place-items: center; }
.yoke-knob { width: 48px; height: 48px; border-radius: 50%; background: rgba(47,217,255,.45); border: 2px solid rgba(255,255,255,.6); }
.touch-right { position: absolute; right: 10px; bottom: 12px; display: flex; gap: 8px; align-items: flex-end; pointer-events: auto; }
.tch-col { display: flex; flex-direction: column; gap: 6px; }
.tch-btn { background: rgba(10,14,18,.75); border: 1px solid rgba(255,255,255,.3); border-radius: 6px; padding: 7px 8px; font: 700 11px var(--mono); min-width: 54px; }
.thr-box { display: flex; flex-direction: column; align-items: center; gap: 4px; font: 700 10px var(--mono); background: rgba(10,14,18,.6); border-radius: 6px; padding: 6px 4px; }
.touch-thr { writing-mode: vertical-lr; direction: rtl; height: 150px; width: 36px; touch-action: none; }

/* ---------------- menu ---------------- */
#menu, #crash { position: fixed; inset: 0; display: none; align-items: center; justify-content: center; z-index: 20; background: radial-gradient(ellipse at center, rgba(4,8,12,.45), rgba(4,6,9,.82)); padding: 16px; }
#menu.open, #crash.open { display: flex; }
.menu-card { width: min(980px, 100%); max-height: calc(100vh - 32px); display: flex; flex-direction: column; background: rgba(13,17,22,.94); border: 1px solid var(--line2); border-radius: 10px; box-shadow: 0 30px 80px rgba(0,0,0,.6); backdrop-filter: blur(10px); }
.menu-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; padding: 20px 22px 0; flex-wrap: wrap; }
.menu-title { font: 700 34px var(--mono); letter-spacing: .08em; color: #fff; line-height: 1; }
.menu-sub { color: var(--muted); font-size: 15px; margin-top: 6px; }
.mtabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); }
.mtabs button { background: none; border: 0; border-bottom: 2px solid transparent; padding: 8px 12px; font-weight: 600; font-size: 15px; color: var(--muted); }
.mtabs button.on { color: var(--cyan); border-bottom-color: var(--cyan); }
.menu-body { padding: 16px 22px; overflow-y: auto; min-height: 0; }
.scen-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.scen { text-align: left; background: #141a21; border: 1px solid var(--line2); border-radius: 8px; padding: 12px 14px; transition: border-color .15s, background .15s; }
.scen:hover { border-color: #46566a; }
.scen.sel { border-color: var(--cyan); background: #10222b; box-shadow: inset 0 0 0 1px var(--cyan); }
.scen-name { font-weight: 700; font-size: 16px; color: #fff; }
.scen-desc { color: var(--muted); font-size: 13.5px; margin-top: 4px; line-height: 1.35; }
.menu-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px 18px; border-top: 1px solid var(--line); }
.cta { background: var(--cyan); color: #00151d; border: 0; border-radius: 6px; padding: 10px 26px; font-weight: 700; font-size: 16px; letter-spacing: .04em; }
.cta:hover { filter: brightness(1.1); }
.cta.ghost { background: transparent; color: var(--text); border: 1px solid var(--line2); }
.settings { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 14px; }
.set-group { background: #11161c; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; }
.set-group h4 { margin: 0 0 8px; font: 700 11px var(--mono); letter-spacing: .1em; color: var(--muted); text-transform: uppercase; }
.set { display: grid; grid-template-columns: 90px 1fr 100px; align-items: center; gap: 8px; font-size: 14px; margin: 6px 0; }
.set-l { color: var(--muted); }
.set input { accent-color: var(--cyan); width: 100%; }
.set output { font: 12px var(--mono); color: var(--cyan); text-align: right; }
.wt-info { font: 11.5px var(--mono); color: var(--text); margin-top: 8px; line-height: 1.5; }
.help table { border-collapse: collapse; width: 100%; font-size: 14px; }
.help td { padding: 5px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.help td:first-child { white-space: nowrap; width: 200px; }
kbd { font: 11px var(--mono); background: #1b222a; border: 1px solid #39444f; border-bottom-width: 2px; border-radius: 3px; padding: 1px 6px; color: #fff; }
.about p { line-height: 1.5; font-size: 15px; max-width: 75ch; }
.crash-card { width: min(460px, 100%); background: rgba(20,10,10,.94); border: 1px solid #5a2620; border-radius: 10px; text-align: center; padding-top: 24px; }
.crash-t { font: 700 30px var(--mono); color: var(--red); letter-spacing: .2em; }
.crash-r { padding: 10px 22px 18px; color: var(--text); font-size: 16px; }
.crash-card .menu-foot { justify-content: center; }
#loading { position: fixed; inset: 0; z-index: 30; background: var(--bg); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; }
.ld-t { font: 700 40px var(--mono); letter-spacing: .1em; }
.ld-s { color: var(--muted); }

/* ---------------- responsive ---------------- */
@media (max-width: 1280px) { #afcs { width: 232px; } #quad { width: 244px; } .brand-sub { display: none; } .kval { font-size: 12px; } }
@media (max-width: 1080px) { .scen-label { display: none; } .tools .tbtn { padding: 6px 7px; } }
@media (max-width: 980px) { #quad { display: none; } #displays.many .du { aspect-ratio: auto; flex: 1 1 0; } }
#app.mobile { --top-h: 44px; --panel-h: 44vh; }
#app.mobile #topbar { gap: 6px; padding: 0 6px; overflow-x: auto; }
#app.mobile .brand-sub, #app.mobile .scen-label, #app.mobile .chips, #app.mobile .seg { display: none; }
#app.mobile .tools { margin-left: auto; }
#app.mobile .seg button { padding: 6px 7px; font-size: 12px; }
#app.mobile .tools { gap: 4px; }
#app.mobile #b-layout, #app.mobile #b-sound { display: none; }
#app.mobile .brand-name { font-size: 14px; }
#app.mobile .tools .tbtn { padding: 6px 6px; font-size: 11px; letter-spacing: .03em; }
#app.mobile .tbtn { padding: 5px 6px; font-size: 10.5px; }
#app.mobile #b-rate, #app.mobile #b-sound { display: none; }
#app.mobile #panel { flex-direction: column; padding: 4px 6px 6px; gap: 4px; }
#app.mobile #du-tabs { display: flex; gap: 2px; flex: none; }
#app.mobile #du-tabs button { flex: 1; background: #161c23; border: 1px solid var(--line); border-radius: 4px; padding: 6px 2px; font: 700 10.5px var(--mono); color: var(--muted); }
#app.mobile #du-tabs button.on { color: var(--cyan); border-color: var(--cyan); }
#app.mobile #displays, #app.mobile #afcs, #app.mobile #quad { display: none; flex: 1 1 auto; min-height: 0; }
#app.mobile #panel[data-tab="pfd"] #displays, #app.mobile #panel[data-tab="mfd"] #displays, #app.mobile #panel[data-tab="eicas"] #displays { display: flex; }
#app.mobile .du { display: block; height: 100%; max-width: 100%; }
#app.mobile #panel[data-tab="pfd"] .du-pfd, #app.mobile #panel[data-tab="mfd"] .du-mfd, #app.mobile #panel[data-tab="eicas"] .du-eicas { display: block; }
#app.mobile #panel[data-tab="afcs"] #afcs { display: flex; width: 100%; }
#app.mobile #panel[data-tab="quad"] #quad { display: flex; width: 100%; }
#app.mobile .menu-title { font-size: 26px; }
#app.mobile .set { grid-template-columns: 80px 1fr 84px; }
#app.mobile .help td:first-child { width: auto; }
@media (max-width: 760px) { .menu-head { padding: 14px 14px 0; } .menu-body { padding: 12px 14px; } .menu-foot { padding: 12px 14px; } .mtabs button { padding: 7px 8px; font-size: 13px; } }

/* ---------------- split panel & layout ---------------- */
#splitter { position: absolute; left: 0; right: 0; top: -5px; height: 10px; cursor: ns-resize; z-index: 6; touch-action: none; }
#splitter::after { content: ""; position: absolute; left: 50%; top: 3px; width: 64px; height: 4px; margin-left: -32px; border-radius: 3px; background: #3a4552; opacity: .7; transition: opacity .15s, background .15s; }
#splitter:hover::after, #splitter.drag::after { background: var(--cyan); opacity: 1; }
#app.mobile #splitter { display: none; }
#displays.wide .du { aspect-ratio: auto; flex: 1 1 0; }
.du-sel { position: absolute; left: 50%; bottom: 6px; transform: translateX(-50%); display: flex; gap: 2px; background: rgba(8,11,14,.86); border: 1px solid var(--line2); border-radius: 5px; padding: 2px; opacity: 0; transition: opacity .15s; z-index: 2; }
.du:hover .du-sel, .du:focus-within .du-sel { opacity: 1; }
.du-sel button { background: none; border: 0; border-radius: 3px; padding: 3px 7px; font: 700 10px var(--mono); color: var(--muted); }
.du-sel button.on { background: #18303c; color: var(--cyan); }
.du-sel button:hover { color: #fff; }
#app.mobile .du-sel { display: none; }
#app.noquad #quad { display: none; }
#app.ap-hidden #afcs { display: none; }
#glare { display: none; flex: none; z-index: 4; background: linear-gradient(#171c22, #0e1216); border-bottom: 1px solid #2b333d; box-shadow: 0 6px 16px rgba(0,0,0,.45); padding: 5px 10px; justify-content: center; }
#app.ap-top #glare { display: flex; }
#app.nopanel.ap-top #glare { display: flex; }
#glare #afcs { width: auto; flex-direction: row; align-items: stretch; gap: 10px; padding: 4px 8px; overflow: visible; background: #11161c; }
#glare .afcs-row { display: flex; gap: 4px; align-items: stretch; }
#glare .afcs-row + .afcs-row { padding-left: 10px; border-left: 1px solid var(--line2); }
#glare .apb { min-width: 46px; padding: 5px 6px 4px; }
#glare .knobs { display: flex !important; gap: 6px; }
#glare .knob { display: grid; grid-template-columns: auto auto; grid-template-rows: auto auto; column-gap: 6px; align-items: center; padding: 3px 6px; }
#glare .klabel { grid-row: 1; grid-column: 1; text-align: left; }
#glare .ksync { grid-row: 1; grid-column: 2; margin: 0; justify-self: end; }
#glare .krow { grid-row: 2; grid-column: 1 / 3; }
#glare .kval { min-width: 56px; }
@media (max-width: 1180px) { #glare .apb { min-width: 38px; font-size: 10px; } #glare .kval { min-width: 46px; } #glare #afcs { gap: 6px; } #glare .afcs-row + .afcs-row { padding-left: 6px; } }
#layout-pop { position: fixed; z-index: 20; width: 320px; background: #0f1419; border: 1px solid var(--line2); border-radius: 8px; box-shadow: 0 14px 40px rgba(0,0,0,.6); padding: 12px 14px 14px; font-size: 13px; }
#layout-pop[hidden] { display: none; }
#layout-pop h3 { margin: 0 0 10px; font: 700 12px var(--mono); letter-spacing: .1em; color: var(--muted); }
.lp-row { margin-bottom: 11px; }
.lp-lab { font-size: 12px; color: var(--muted); margin-bottom: 5px; font-weight: 600; }
.lp-seg { display: flex; border: 1px solid var(--line2); border-radius: 5px; overflow: hidden; }
.lp-seg button { flex: 1; background: transparent; border: 0; border-right: 1px solid var(--line); padding: 6px 4px; font: 700 11px var(--mono); color: var(--muted); }
.lp-seg button:last-child { border-right: 0; }
.lp-seg button.on { background: #18303c; color: var(--cyan); }
.lp-seg button:hover { color: #fff; }
.lp-panes { display: grid; gap: 5px; }
.lp-pane { display: grid; grid-template-columns: 54px 1fr; align-items: center; gap: 6px; }
.lp-pane span { font: 700 11px var(--mono); color: var(--faint); }
.lp-presets { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; }
.lp-presets button { background: #161c23; border: 1px solid var(--line); border-radius: 4px; padding: 6px 4px; font: 600 11px var(--mono); color: var(--text); }
.lp-presets button:hover { border-color: var(--cyan); }
.lp-range { width: 100%; accent-color: var(--cyan); }
.lv-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 8px 0 4px; }
.lv-card { background: #12171d; border: 1px solid var(--line); border-radius: 6px; padding: 8px 6px; text-align: center; font-size: 12px; font-weight: 600; color: var(--muted); }
.lv-card.on { border-color: var(--cyan); color: #fff; }
.lv-sw { height: 26px; border-radius: 4px; margin-bottom: 6px; border: 1px solid #2a323b; }
.lv-card { position: relative; }
.lv-sub { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin: 10px 0 0; }
.lv-x { position: absolute; top: 2px; right: 5px; color: var(--muted); font-size: 14px; line-height: 1; cursor: pointer; }
.lv-x:hover { color: #fff; }

/* ---------------- aircraft picker ---------------- */
.menu-body > div > .lp-lab { margin: 4px 0 8px; font-size: 13px; line-height: 1.35; }
.ac-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; margin-bottom: 14px; }
.ac-card { display: flex; gap: 8px; align-items: center; text-align: left; background: #141a21; border: 1px solid var(--line2); border-radius: 8px; padding: 6px 10px 6px 4px; transition: border-color .15s, background .15s; min-width: 0; }
.ac-card:hover { border-color: #44515f; }
.ac-card.sel { border-color: var(--cyan); background: #10222b; box-shadow: inset 0 0 0 1px var(--cyan); }
.ac-pic { flex: none; width: 92px; height: 70px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.ac-pic canvas { width: 92px !important; height: auto !important; max-height: 70px; object-fit: contain; }
.ac-txt { min-width: 0; }
.ac-name { font-weight: 700; font-size: 16px; color: #fff; }
.ac-cls { font-size: 12px; color: var(--cyan); font-weight: 600; margin-bottom: 2px; }
.ac-spec { font-size: 12px; color: var(--muted); white-space: nowrap; }
.ac-detail { display: flex; gap: 16px; align-items: flex-start; margin: 10px 0 6px; flex-wrap: wrap; }
.ac-detail > div { flex: 1 1 280px; min-width: 0; }
.ac-detail h4 { margin: 0 0 4px; font-size: 17px; color: #fff; }
.spec-t { border-collapse: collapse; width: 100%; font-size: 13px; }
.spec-t td { padding: 3px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.spec-t td:first-child { color: var(--muted); white-space: nowrap; width: 1%; padding-left: 0; }

/* ---------------- region map ---------------- */
#rmap { position: fixed; inset: 0; z-index: 25; background: #0d141c; }
#rmap[hidden] { display: none; }
.rm-cv { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; cursor: grab; display: block; }
.rm-top { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; gap: 12px; padding: 8px 12px; background: linear-gradient(rgba(8,12,17,.92), rgba(8,12,17,.6)); border-bottom: 1px solid var(--line); }
.rm-title { font-family: var(--mono); font-weight: 700; letter-spacing: .12em; color: #fff; font-size: 14px; white-space: nowrap; }
.rm-info { flex: 1; min-width: 0; color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rm-btns { display: flex; gap: 6px; }
.rm-btns .tbtn { min-width: 34px; }
.rm-layers { position: absolute; top: 52px; left: 12px; display: flex; flex-wrap: wrap; gap: 5px; max-width: calc(100% - 340px); }
.chip-t { background: rgba(10,14,19,.85); border: 1px solid var(--line2); color: var(--faint); border-radius: 14px; padding: 4px 11px; font-size: 12px; font-weight: 600; }
.chip-t.on { color: var(--text); border-color: #3e6a80; background: rgba(16,34,43,.9); }
.rm-side { position: absolute; top: 52px; right: 10px; bottom: 10px; width: 290px; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.rm-side > * { pointer-events: auto; }
.rm-h { font-size: 12px; font-weight: 700; letter-spacing: .1em; color: var(--muted); background: rgba(10,14,19,.9); border: 1px solid var(--line2); border-bottom: 0; border-radius: 8px 8px 0 0; padding: 8px 10px 4px; margin-bottom: -8px; }
.rm-list { background: rgba(10,14,19,.9); border: 1px solid var(--line2); border-top: 0; border-radius: 0 0 8px 8px; padding: 2px 4px 6px; overflow-y: auto; flex: 0 1 auto; max-height: 40%; }
.rm-ap { display: flex; width: 100%; align-items: baseline; gap: 8px; background: none; border: 0; border-radius: 5px; padding: 6px; text-align: left; }
.rm-ap:hover { background: #18212a; }
.rm-ap.on { background: #2a2410; }
.rm-icao { font-family: var(--mono); font-weight: 700; color: #fff; font-size: 13px; }
.rm-icao.big { font-size: 18px; color: #ffd24a; }
.rm-apn { flex: 1; min-width: 0; font-size: 13px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rm-apd { font-size: 12px; color: var(--muted); font-family: var(--mono); }
.rm-card { background: rgba(10,14,19,.95); border: 1px solid var(--line2); border-radius: 8px; padding: 10px 12px 12px; overflow-y: auto; flex: 0 1 auto; min-height: 0; }
.rm-card[hidden] { display: none; }
.rm-card-h { display: flex; justify-content: space-between; align-items: center; }
.rm-card-n { font-size: 17px; font-weight: 700; color: #fff; }
.rm-card-s { font-size: 12px; color: var(--cyan); margin-bottom: 6px; font-weight: 600; }
.rm-acts { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.rm-acts-l { font-size: 12px; color: var(--muted); font-weight: 600; margin-top: 4px; }
.rm-row { display: flex; gap: 6px; align-items: center; }
.rm-rw { font-family: var(--mono); font-size: 12px; width: 58px; flex: none; color: var(--text); }
.rm-row .cta { flex: 1; }
.cta.small { padding: 7px 10px; font-size: 13px; }
@media (max-width: 760px) {
  .rm-title { display: none; }
  .rm-layers { max-width: calc(100% - 24px); }
  .rm-side { top: auto; left: 8px; right: 8px; width: auto; bottom: 8px; max-height: 52vh; }
  .rm-list { max-height: 22vh; }
  .rm-side:has(.rm-card:not([hidden])) .rm-list, .rm-side:has(.rm-card:not([hidden])) .rm-h { display: none; }
  .ac-grid { grid-template-columns: 1fr 1fr; }
  .ac-pic { width: 60px; height: 50px; } .ac-pic canvas { width: 60px !important; }
  .ac-card { flex-direction: column; align-items: flex-start; padding: 6px 8px; }
  .ac-spec { white-space: normal; }
}

/* ---------------- flight plan editor ---------------- */
#fpl { position: absolute; top: 0; right: 0; bottom: 0; width: 400px; max-width: 100vw; background: rgba(12,16,21,.97); border-left: 1px solid var(--line2); transform: translateX(105%); transition: transform .25s ease; z-index: 8; overflow-y: auto; padding: 10px 14px 24px; backdrop-filter: blur(8px); }
#fpl.open { transform: none; }
.fpl-grid { display: grid; grid-template-columns: 82px 1fr; gap: 8px 10px; align-items: center; margin-top: 10px; }
.fpl-l { font-size: 12px; font-weight: 700; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; }
.fpl-pair { display: flex; gap: 6px; min-width: 0; }
.fpl-sel { background: var(--panel2); border: 1px solid var(--line2); border-radius: 5px; padding: 6px 6px; font-size: 13px; min-width: 0; flex: 1 1 auto; }
.fpl-sel.small { flex: 0 0 auto; }
.fpl-pair .cta { white-space: nowrap; }
.fpl-row { display: flex; gap: 6px; margin-top: 8px; }
.fpl-in { flex: 1; min-width: 0; background: #0a0e12; border: 1px solid var(--line2); border-radius: 5px; padding: 7px 8px; font: 13px var(--mono); color: #fff; text-transform: uppercase; }
.fpl-in:focus, .fpl-sel:focus, .fpl-alt:focus { outline: 2px solid #2a6a80; outline-offset: 0; }
.fpl-btns { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.fpl-msg { font-size: 12px; color: var(--muted); min-height: 16px; margin-top: 6px; }
.fpl-msg.bad { color: var(--amber); }
.fpl-t { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 13px; }
.fpl-t th { text-align: left; font: 700 10px var(--mono); color: var(--muted); letter-spacing: .1em; padding: 4px; border-bottom: 1px solid var(--line2); }
.fpl-t td { padding: 4px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.fpl-t tr.fixed td { color: var(--muted); }
.fpl-t td.mut { color: var(--muted); font-size: 12px; }
.fpl-id { font: 700 13px var(--mono); color: var(--magenta); }
.fpl-t tr.fixed .fpl-id { color: #b48aa8; }
.fpl-id.vor { color: #7fc8ff; } .fpl-id.usr { color: #ffd24a; }
.fpl-alt { width: 72px; background: #0a0e12; border: 1px solid var(--line2); border-radius: 4px; padding: 3px 5px; font: 12px var(--mono); color: var(--cyan); }
.fpl-act { white-space: nowrap; text-align: right; }
.ib { background: var(--panel2); border: 1px solid var(--line2); border-radius: 4px; width: 24px; height: 24px; padding: 0; font-size: 12px; color: var(--muted); margin-left: 2px; }
.ib:hover { color: #fff; }
.fpl-sum { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 12px; }
.fpl-sum > div { background: var(--panel2); border: 1px solid var(--line); border-radius: 6px; padding: 7px 6px; text-align: center; }
.fpl-sum b { display: block; font: 700 15px var(--mono); color: #fff; }
.fpl-sum b.bad { color: var(--amber); }
.fpl-sum span { font-size: 11px; color: var(--muted); }
.fpl-warn { margin: 10px 0 0; padding: 8px 10px 8px 26px; background: #22190a; border: 1px solid #6a4a10; border-radius: 6px; color: #ffd38a; font-size: 12.5px; }
.fpl-warn li + li { margin-top: 3px; }
.fpl-ok { margin-top: 10px; padding: 8px 10px; background: #0f2016; border: 1px solid #2a5a36; border-radius: 6px; color: #9be8ae; font-size: 12.5px; }
.fpl-go { display: flex; flex-direction: column; gap: 7px; margin-top: 12px; }
.fpl-go .cta { padding: 10px 14px; font-size: 15px; }
.menu-plan { display: flex; gap: 14px; align-items: center; margin-top: 12px; }
.menu-plan .cta { white-space: nowrap; flex: none; }
.menu-plan .hint { margin: 0; }

/* ---------------- ATC panel ---------------- */
#atc { position: absolute; top: 10px; left: 10px; bottom: 10px; width: 360px; max-width: calc(100vw - 20px); display: flex; flex-direction: column; background: rgba(9,13,18,.94); border: 1px solid var(--line2); border-radius: 10px; z-index: 7; transform: translateX(calc(-100% - 20px)); transition: transform .25s ease; backdrop-filter: blur(8px); overflow: hidden; }
#atc.open { transform: none; }
.atc-grip { display: none; }
.atc-head, .atc-tune, .atc-opts, .atc-grip { flex: none; }
.atc-head { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-bottom: 1px solid var(--line); background: linear-gradient(#121920, #0c1116); }
.atc-com { display: flex; flex-direction: column; align-items: center; background: #050708; border: 1px solid #1d2a33; border-radius: 6px; padding: 3px 8px; }
.atc-lab { font: 700 9px var(--mono); color: var(--muted); letter-spacing: .14em; }
.atc-freq { font: 700 19px var(--mono); color: var(--green); letter-spacing: .03em; }
.atc-hmid { flex: 1; min-width: 0; }
.atc-st { font-weight: 700; font-size: 15px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.atc-status { font: 11px var(--mono); color: var(--cyan); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.atc-tune { padding: 7px 10px; border-bottom: 1px solid var(--line); display: flex; }
.atc-tune select { flex: 1; font-family: var(--mono); font-size: 12px; }
.atc-log { flex: 1 1 auto; min-height: 60px; overflow-y: auto; padding: 8px 10px; display: flex; flex-direction: column; gap: 7px; }
.atc-m { border-left: 3px solid var(--line2); padding: 2px 0 2px 8px; font-size: 13.5px; line-height: 1.38; }
.atc-mh { display: flex; gap: 8px; align-items: baseline; font: 700 10px var(--mono); letter-spacing: .05em; color: var(--muted); }
.atc-who { text-transform: uppercase; }
.atc-mf { color: var(--faint); } .atc-t { margin-left: auto; color: var(--faint); font-weight: 400; }
.atc-tx { color: var(--text); }
.atc-m.atc { border-color: var(--cyan); } .atc-m.atc .atc-who { color: var(--cyan); } .atc-m.atc .atc-tx { color: #e9f8ff; }
.atc-m.pilot { border-color: var(--green); } .atc-m.pilot .atc-who { color: var(--green); }
.atc-m.atco { border-color: #2a5d6c; } .atc-m.atco .atc-tx, .atc-m.ai .atc-tx { color: #9aa6b2; font-size: 12.5px; }
.atc-m.ai { border-color: #39424c; }
.atc-m.atis { border-color: #7f6bd8; } .atc-m.atis .atc-who { color: #b4a6ff; } .atc-m.atis .atc-tx { color: #d4cdf7; font-size: 12.5px; }
.atc-m.sys { border-color: var(--amber); } .atc-m.sys .atc-who { color: var(--amber); } .atc-m.sys .atc-tx { color: #f4dcae; font-size: 12.5px; }
.atc-chips { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 5px; }
.chip-t.act { color: var(--cyan); border-color: #2a5d6c; font-family: var(--mono); font-size: 11px; padding: 3px 9px; }
.chip-t.act:hover { background: #10303b; }
.chip-t.act.done { color: var(--green); border-color: #2a5a36; }
.atc-reqs { flex: none; display: flex; flex-wrap: wrap; gap: 5px; padding: 8px 10px; border-top: 1px solid var(--line); max-height: 40%; overflow-y: auto; }
.atc-rq { background: var(--panel2); border: 1px solid var(--line2); border-radius: 5px; padding: 6px 9px; font-size: 13px; font-weight: 600; color: var(--text); }
.atc-rq:hover { border-color: #4b6070; color: #fff; }
.atc-rq.hi { background: #0f2a33; border-color: #2a6a80; color: var(--cyan); }
.atc-opts { border-top: 1px solid var(--line); padding: 6px 10px 9px; font-size: 12px; color: var(--muted); }
.atc-opts summary { cursor: pointer; font-weight: 700; letter-spacing: .05em; }
.atc-togs { display: flex; flex-wrap: wrap; gap: 5px; margin: 7px 0; }
.atc-cs { display: flex; gap: 8px; align-items: center; }
.atc-cs .fpl-in { text-transform: none; }
#b-atc.unread:not(.on) { color: var(--cyan); border-color: #2a6a80; box-shadow: 0 0 0 1px #2a6a80 inset; }
.rm-pick { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 3; display: flex; gap: 12px; align-items: center; background: rgba(36,26,8,.95); border: 1px solid #6a4a10; color: #ffd38a; border-radius: 8px; padding: 8px 10px 8px 14px; font-size: 14px; font-weight: 600; }
.rm-pick[hidden] { display: none; }
@media (max-width: 760px) {
  #atc { position: fixed; top: 34vh; left: 0; right: 0; bottom: 0; width: auto; max-width: none; height: auto; border-radius: 12px 12px 0 0; transform: translateY(105%); z-index: 20; }
  #atc.open { transform: none; }
  .atc-grip { display: block; width: 40px; height: 4px; border-radius: 2px; background: var(--line2); margin: 6px auto 0; }
  .atc-reqs { max-height: 30%; }
  #fpl { position: fixed; top: var(--top-h); width: 100%; z-index: 20; }
  .menu-plan { flex-direction: column; align-items: stretch; }
  .fpl-grid { grid-template-columns: 70px 1fr; }
  .rm-pick { font-size: 12px; width: calc(100% - 24px); }
}

/* taxi diagram */
#taxi { position: absolute; top: 10px; right: 10px; width: min(560px, calc(100vw - 20px)); height: min(620px, calc(100% - 20px)); display: none; flex-direction: column; background: rgba(9,13,18,.96); border: 1px solid var(--line2); border-radius: 10px; z-index: 8; overflow: hidden; backdrop-filter: blur(8px); }
#taxi.open { display: flex; }
.taxi-head { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-bottom: 1px solid var(--line); background: linear-gradient(#121920, #0c1116); }
.taxi-title { font-weight: 700; color: #fff; font-size: 14px; white-space: nowrap; }
.taxi-head select { flex: 1; min-width: 0; font-family: var(--mono); font-size: 12px; }
.taxi-cv { flex: 1 1 auto; width: 100%; min-height: 0; display: block; touch-action: none; cursor: grab; }
.taxi-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; padding: 7px 10px; border-top: 1px solid var(--line); }
.taxi-info { margin-left: auto; font: 11px var(--mono); color: var(--muted); }
/* custom pilot requests */
.atc-talk { flex: none; border-top: 1px solid var(--line); padding: 2px 10px 8px; }
.atc-talk .atc-talk-in { text-transform: none; font-family: var(--mono); font-size: 13px; }
.atc-hint { margin-top: 4px; font-size: 11px; color: var(--muted); line-height: 1.35; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.atc-mic.on { background: #b3261e; color: #fff; }
.atc-custom { flex: none; border-top: 1px solid var(--line); padding: 6px 10px 8px; font-size: 12px; color: var(--muted); }
.atc-custom summary { cursor: pointer; font-weight: 700; letter-spacing: .05em; }
.atc-crow { display: flex; gap: 6px; margin-top: 6px; align-items: center; }
.atc-crow select, .atc-crow input { flex: 1; min-width: 0; font-family: var(--mono); font-size: 12px; }
.atc-crow .atc-rq { flex: none; padding: 5px 10px; }
.atc-quick { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; }
@media (max-width: 760px) { #taxi { top: 0; right: 0; left: 0; width: auto; height: 62vh; border-radius: 0 0 12px 12px; } }
.atc-custom .fpl-in { text-transform: none; min-width: 0; }

/* ---------- systems synoptics ---------- */
#systems { width: 460px; }
.syp { margin-top: 6px; }
.sy-type { font: 600 11px var(--mono); color: var(--muted); margin-bottom: 8px; }
.sy-tabs { display: flex; gap: 2px; position: sticky; top: -10px; z-index: 2; background: rgba(12,16,21,.98); padding: 6px 0; border-bottom: 1px solid var(--line2); }
.sy-tabs button { flex: 1 1 0; min-width: 0; background: #161c22; border: 1px solid #2b343e; color: #9aa6b2; font: 700 9.5px var(--mono); padding: 6px 1px; border-radius: 4px; letter-spacing: .05em; cursor: pointer; }
.sy-tabs button.on { background: #0f2a36; color: var(--cyan); border-color: var(--cyan); }
.sy-body { padding-top: 8px; display: flex; flex-direction: column; gap: 8px; }
.sy-spec { font: 600 11px var(--mono); color: #c3ccd5; }
.sycard { background: #10151b; border: 1px solid #252e38; border-radius: 6px; padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.sycard-h { font: 700 10.5px var(--mono); color: var(--muted); letter-spacing: .1em; }
.sygrid { display: grid; gap: 5px; }
.sygrid.g1 { grid-template-columns: 1fr; } .sygrid.g2 { grid-template-columns: repeat(2, 1fr); } .sygrid.g3 { grid-template-columns: repeat(3, 1fr); } .sygrid.g4 { grid-template-columns: repeat(4, 1fr); }
.syt { background: #0a0e12; border: 1px solid #222a33; border-radius: 4px; padding: 4px 6px; min-width: 0; }
.syt-l { font: 700 9px var(--mono); color: #7d8996; letter-spacing: .06em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.syt-v { font: 700 13px var(--mono); color: #e6edf3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.syt.ok .syt-v { color: var(--green); } .syt.amber .syt-v { color: var(--amber); } .syt.red .syt-v { color: var(--red); } .syt.cyan .syt-v { color: var(--cyan); } .syt.off .syt-v { color: #6b7783; }
.syt.red { border-color: rgba(255,80,80,.5); } .syt.amber { border-color: rgba(255,190,60,.35); }
.sybar { height: 6px; background: #1b222a; border-radius: 3px; overflow: hidden; }
.sybar i { display: block; height: 100%; background: var(--green); transition: width .3s; }
.sybar.lo i { background: var(--amber); } .sybar.ice i { background: #9fd8ff; }
.seg { display: flex; align-items: center; gap: 3px; }
.seg-l { font: 700 9.5px var(--mono); color: var(--muted); margin-right: 3px; }
.seg button { flex: 1; background: #1a2027; border: 1px solid #333d48; color: #c3ccd5; font: 700 10.5px var(--mono); padding: 7px 4px; border-radius: 4px; cursor: pointer; }
.seg button.on { background: #0f2a36; color: var(--cyan); border-color: var(--cyan); }
.sycard .sw, .sygrid .sw { padding: 7px 4px; font-size: 10.5px; }
.sw.used { opacity: .5; }
.hyd-h { font: 800 13px var(--mono); letter-spacing: .1em; color: #e6edf3; }
.hyd-psi .syt-v { font-size: 17px; }
.hyd-u { font: 500 10px var(--ui); color: #7d8996; line-height: 1.3; }
.fire-h { width: 100%; padding: 12px 6px 8px; border-radius: 6px; background: #2a1012; border: 2px solid #5c2025; color: #ffb3b3; font: 800 12px var(--mono); letter-spacing: .06em; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 3px; }
.fire-h small { font: 700 9px var(--mono); color: #c98a8a; }
.fire-h.lit { background: #c0262d; color: #fff; border-color: #ff6b6b; box-shadow: 0 0 14px rgba(255,60,60,.6); }
.fire-h.pulled { transform: translateY(3px); border-style: dashed; }
@media (max-width: 600px) { #systems { width: 100vw; } .sygrid.g4 { grid-template-columns: repeat(2, 1fr); } }

/* ---------- start wizard ---------- */
.wz-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 10px; }
.wz-step { display: flex; align-items: center; gap: 8px; background: #11161c; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; color: var(--muted); font-weight: 600; font-size: 14px; text-align: left; min-width: 0; }
.wz-step .wz-n { flex: none; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: #1d252e; font: 700 12px var(--mono); color: #9aa6b2; }
.wz-step .wz-t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wz-step.done { color: #c9d3dd; } .wz-step.done .wz-n { background: #12382a; color: var(--green); }
.wz-step.on { border-color: var(--cyan); color: #fff; background: #0f2029; } .wz-step.on .wz-n { background: var(--cyan); color: #00151d; }
.wz-sum { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.wz-sum span { background: #141a21; border: 1px solid var(--line); border-radius: 999px; padding: 3px 10px; font-size: 12.5px; color: #aeb9c4; }
.wz-sum b { color: #fff; }
.wz-split { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 14px; align-items: start; }
.wz-acgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 0; }
.wz-detail { background: #11161c; border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; }
.wz-detail svg, .wz-detail canvas { display: block; margin: 0 auto 6px; }
.wz-detail h4 { margin: 4px 0; font-size: 16px; } .wz-detail p { margin: 0 0 8px; color: var(--muted); font-size: 13.5px; line-height: 1.4; }
.wz-opts, .wz-states { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; margin-bottom: 12px; }
.wz-opt { text-align: left; background: #141a21; border: 1px solid var(--line2); border-radius: 8px; padding: 12px 14px; transition: border-color .15s, background .15s; }
.wz-opt:hover { border-color: #46566a; }
.wz-opt.sel { border-color: var(--cyan); background: #10222b; box-shadow: inset 0 0 0 1px var(--cyan); }
.wz-opt.static { cursor: default; margin-bottom: 8px; }
.wz-plan { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 14px; margin-bottom: 10px; }
.wz-plan .fld select { width: 100%; }
.wz-route { grid-column: 1 / -1; background: #0c1116; border: 1px solid var(--line); border-radius: 6px; padding: 8px 10px; }
.wz-rt { font: 600 13px var(--mono); color: var(--cyan); line-height: 1.5; word-break: break-word; }
.wz-where { background: #0c1116; border: 1px solid var(--line); border-radius: 6px; padding: 10px 12px; font-size: 14px; color: #dbe3ea; margin-bottom: 8px; }
.pre-row, .rw-pick { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.pre-btn { background: #141a21; border: 1px solid var(--line2); border-radius: 6px; padding: 7px 12px; color: #c9d3dd; font-weight: 600; font-size: 13.5px; display: flex; flex-direction: column; align-items: flex-start; gap: 1px; }
.pre-btn small { font: 500 11px var(--mono); color: var(--muted); }
.pre-btn.on, .pre-btn:hover { border-color: var(--cyan); }
.pre-btn.on { background: #10222b; color: #fff; }
.menu-foot .grow { flex: 1; }
@media (max-width: 760px) { .wz-steps { grid-template-columns: repeat(4, auto); } .wz-step .wz-t { display: none; } .wz-split, .wz-plan { grid-template-columns: 1fr; } .wz-acgrid { grid-template-columns: 1fr; } }
/* saved flights */
.saves { display: flex; flex-direction: column; gap: 10px; }
.saves .qrow { margin: 6px 0; flex-wrap: wrap; gap: 6px; }
.saves .qrow > .fpl-in { flex: 2 1 180px; text-transform: none; }
.saves .qrow > button { flex: 1 1 auto; }
.save-list { display: flex; flex-direction: column; gap: 6px; max-height: 300px; overflow-y: auto; }
.save-row { display: flex; align-items: center; gap: 10px; padding: 7px 9px; background: #0a0e12; border: 1px solid var(--line); border-radius: 6px; flex-wrap: wrap; }
.save-meta { flex: 1 1 180px; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.save-meta b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.save-meta small { color: var(--dim, #8a97a5); }
.save-act { display: flex; gap: 6px; }
.wz-presets { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 8px; }
.hint.mono { font: 500 11.5px var(--mono); color: #b9c6d2; background: #0e141a; border: 1px solid var(--line2); border-radius: 6px; padding: 6px 8px; overflow-wrap: anywhere; }
/* ground services panel + visual docking guidance */
#gnd { position: absolute; top: 10px; right: 10px; width: min(410px, calc(100vw - 20px)); max-height: calc(100% - 20px); display: none; flex-direction: column; background: rgba(9,13,18,.96); border: 1px solid var(--line2); border-radius: 10px; z-index: 9; overflow: hidden; backdrop-filter: blur(8px); }
#gnd.open { display: flex; }
.gnd-body { flex: 1 1 auto; min-height: 120px; padding: 8px 10px 10px; display: flex; flex-direction: column; gap: 7px; overflow: auto; font-size: 12px; color: var(--muted); }
.gnd-row { display: flex; align-items: center; gap: 7px; }
.gnd-lab { width: 74px; flex: none; font-weight: 700; letter-spacing: .04em; color: var(--faint); font-size: 11px; text-transform: uppercase; }
.gnd-val { flex: 1; min-width: 0; color: var(--text); font-family: var(--mono); font-size: 11.5px; }
.gnd-state { flex: 1; min-width: 0; color: var(--cyan); font-family: var(--mono); font-size: 11.5px; }
.gnd-row .chip-t:disabled, .gnd-body .chip-t:disabled { opacity: .4; cursor: default; }
.gnd-hint { font-size: 11px; line-height: 1.45; color: var(--faint); }
.gnd-log { flex: none; max-height: 58px; font-size: 10.5px !important; overflow: auto; border-top: 1px solid var(--line); padding: 5px 10px 6px; display: flex; flex-direction: column; gap: 3px; font-family: var(--mono); font-size: 11px; color: var(--text); }
.gnd-msg:not(:first-child) { color: var(--faint); }
.gnd-tabs { display: flex; gap: 2px; padding: 5px 6px 0; border-bottom: 1px solid var(--line); overflow-x: auto; flex: none; }
.gnd-tab { background: none; border: 1px solid transparent; border-bottom: none; border-radius: 6px 6px 0 0; padding: 6px 8px; font-size: 11.5px; font-weight: 700; color: var(--faint); white-space: nowrap; cursor: pointer; }
.gnd-tab:hover { color: var(--text); }
.gnd-tab.on { color: #fff; background: #121a22; border-color: var(--line2); }
.gnd-spd { display: flex; border: 1px solid var(--line2); border-radius: 6px; overflow: hidden; }
.gnd-sp { background: none; border: none; color: var(--faint); font-family: var(--mono); font-size: 11px; padding: 4px 7px; cursor: pointer; }
.gnd-sp.on { background: #10303b; color: var(--cyan); }
.gnd-sec { margin-top: 4px; font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); border-bottom: 1px solid var(--line); padding-bottom: 3px; }
.gnd-val.cyan, .gnd-hint.cyan { color: var(--cyan); } .gnd-val.green, .gnd-kv b.green { color: var(--green); }
.gnd-val.amber, .gnd-kv b.amber { color: #f3b33d; } .gnd-val.red, .gnd-kv b.red { color: #ff5a4e; } .gnd-kv b.cyan { color: var(--cyan); }
.gnd-flow { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.gnd-flow .chip-t.big { flex: 1; padding: 7px 10px; font-size: 12px; text-align: center; }
.gnd-btns { display: inline-flex; gap: 4px; }
.gnd-ask { display: flex; flex-direction: column; gap: 6px; padding: 7px 8px; background: #10262e; border: 1px solid #1f5866; border-radius: 6px; }
.gnd-ask-q { color: #e6f6fb; font-size: 12px; line-height: 1.4; }
.gnd-ask .gnd-btns { flex-wrap: wrap; }
.gnd-ask .chip-t.big { padding: 6px 10px; font-size: 12px; }
.gnd-icom { display: flex; flex-direction: column; gap: 3px; font-family: var(--mono); font-size: 10.8px; line-height: 1.35; max-height: 150px; overflow: auto; padding: 5px 7px; background: #0b1015; border: 1px solid var(--line); border-radius: 6px; }
.gnd-icom-l b { color: var(--faint); font-weight: 700; margin-right: 4px; }
.gnd-icom-l.g { color: #d7e4ea; } .gnd-icom-l.c { color: var(--cyan); }
.gnd-svcs { display: flex; flex-direction: column; gap: 5px; }
.gnd-svc { display: flex; flex-direction: column; gap: 3px; padding: 5px 7px; background: #0d1319; border: 1px solid var(--line); border-radius: 6px; }
.gnd-svc-top { display: flex; align-items: center; gap: 7px; }
.gnd-svc-n { font-weight: 700; color: var(--text); white-space: nowrap; }
.gnd-svc-s { flex: 1; min-width: 0; font-family: var(--mono); font-size: 11px; color: var(--cyan); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gnd-dot { width: 7px; height: 7px; border-radius: 50%; background: #39424c; flex: none; }
.gnd-dot.run { background: #f3b33d; box-shadow: 0 0 5px rgba(243,179,61,.7); } .gnd-dot.ok { background: var(--green); }
.gnd-bar { height: 5px; background: #1a222b; border-radius: 3px; overflow: hidden; flex: none; }
.gnd-bar i { display: block; height: 100%; background: linear-gradient(90deg, #2a8aa8, #4fd1ee); }
.gnd-bar.warn i { background: linear-gradient(90deg, #b07a20, #f3b33d); }
.gnd-bar.thin { height: 3px; } .gnd-bar.mini { width: 70px; }
.gnd-row input[type=range], .gnd-body > input[type=range] { width: 100%; accent-color: var(--cyan); }
.gnd-kv { display: grid; grid-template-columns: auto 1fr; gap: 2px 10px; font-size: 11.5px; }
.gnd-kv span { color: var(--faint); } .gnd-kv b { font-family: var(--mono); font-weight: 500; color: var(--text); text-align: right; }
.gnd-ck { display: flex; flex-direction: column; gap: 2px; }
.gnd-ck-r { display: grid; grid-template-columns: 14px 1fr auto; gap: 6px; align-items: center; font-size: 11.5px; }
.gnd-ck-r b { font-family: var(--mono); font-weight: 500; color: #f3b33d; }
.gnd-ck-r.ok b { color: var(--text); } .gnd-tick { color: var(--faint); text-align: center; } .gnd-ck-r.ok .gnd-tick { color: var(--green); }
.gnd-doors { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.gnd-door { display: flex; flex-direction: column; gap: 2px; background: #0d1319; border: 1px solid var(--line2); border-radius: 6px; padding: 5px 4px; color: var(--muted); font-size: 11px; font-weight: 700; cursor: pointer; }
.gnd-door b { font-family: var(--mono); font-size: 10.5px; color: var(--faint); }
.gnd-door.open { border-color: #2a5a36; } .gnd-door.open b { color: var(--green); } .gnd-door.mov b { color: #f3b33d; }
.gnd-cg { position: relative; height: 16px; background: linear-gradient(90deg, #3a1c1c 0 8%, #13301e 8% 86%, #3a1c1c 86%); border-radius: 4px; display: flex; justify-content: space-between; align-items: center; padding: 0 5px; font-family: var(--mono); font-size: 9.5px; color: var(--faint); }
.gnd-cg i { position: absolute; top: -2px; bottom: -2px; width: 3px; margin-left: -1px; background: var(--cyan); box-shadow: 0 0 5px var(--cyan); }
.gnd-ls { font-family: var(--mono); font-size: 11px; line-height: 1.5; color: #d9e2ea; background: #0b1015; border: 1px dashed #3a4652; border-radius: 4px; padding: 6px 8px; }
.gnd-ls.stale { border-color: #8a6420; } .gnd-ls.stale div:first-child { color: #f3b33d; }
#marshal { position: absolute; top: 64px; left: 50%; transform: translateX(-50%); min-width: 150px; padding: 7px 12px; background: rgba(12,16,20,.9); border: 2px solid #e8a321; border-radius: 6px; font-family: var(--mono); color: #ffcc55; text-align: center; z-index: 6; pointer-events: none; display: none; }
#marshal.on { display: block; }
#marshal .mk-h { font-size: 9.5px; letter-spacing: .14em; color: #8a8f94; }
#marshal .mk-s { font-size: 16px; font-weight: 700; letter-spacing: .06em; margin: 2px 0; }
#marshal .mk-d { font-size: 13px; }
#marshal.sig-stop .mk-s, #marshal.sig-chocks .mk-s { color: #ff4c3f; }
#vdgs { position: absolute; top: 64px; left: 50%; transform: translateX(-50%); width: 168px; padding: 8px 10px; background: #050505; border: 3px solid #26292c; border-radius: 4px; font-family: var(--mono); color: #ffb21c; text-align: center; z-index: 6; pointer-events: none; display: none; text-shadow: 0 0 6px rgba(255,170,30,.55); }
#vdgs.on { display: block; }
#vdgs .vd-gate { font-size: 10px; color: #8a8f94; letter-spacing: .12em; text-shadow: none; }
#vdgs .vd-type { font-size: 15px; font-weight: 700; letter-spacing: .08em; margin: 2px 0 4px; }
#vdgs .vd-az { font-size: 12px; margin-bottom: 5px; }
#vdgs .vd-bar { display: flex; flex-direction: column-reverse; gap: 2px; align-items: center; margin-bottom: 5px; }
#vdgs .vd-bar i { display: block; width: 46px; height: 4px; background: #2a2415; }
#vdgs .vd-bar i.on { background: #ffb21c; box-shadow: 0 0 5px rgba(255,170,30,.7); }
#vdgs .vd-dist { font-size: 18px; font-weight: 700; }
#vdgs .vd-dist.red { color: #ff3b2f; text-shadow: 0 0 8px rgba(255,50,40,.7); }

/* ---------- clickable cockpit panels (js/overhead.js) ---------- */
.ovhd { position: fixed; inset: 50px 6px 6px 6px; z-index: 9; background: rgba(10,13,17,.97); border: 1px solid var(--line2); border-radius: 10px; display: none; flex-direction: column; padding: 10px 14px; box-shadow: 0 20px 60px rgba(0,0,0,.6); }
.ovhd.open { display: flex; }
.ovhd-head { display: flex; align-items: center; gap: 12px; }
.ovhd-head h2 { margin: 0; font-size: 16px; letter-spacing: .04em; flex: 1; }
.ovhd-body { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 8px 0; overflow: auto; }
.ovhd-body.zoomed { display: block; cursor: grab; }
.ovhd-body.zoomed > * { margin: 0 auto; }
.ovhd-body > .ov-svg, .ovhd-body > .ov-bizface { flex: none; max-height: none; display: block; box-shadow: 0 8px 30px rgba(0,0,0,.6); border-radius: 6px; }
.ov-livedu { width: 100%; height: 100%; display: block; object-fit: contain; background: #020304; }
.ovhd-zoom button { min-width: 34px; }
.ov-svg { user-select: none; font-family: 'Arial Narrow', Arial, sans-serif; }
.ovhd .hint { margin: 4px 0 0; }
.ov-bg.ab { fill: #3d4a55; } .ov-bg.b7 { fill: #6b7177; }
.ov-pnl { fill: url(#ovPnlAB); stroke: #1f272e; stroke-width: 1.5; }
.ov-bg.b7 ~ .ov-pnl { fill: url(#ovPnlB7); stroke: #4c5156; }
.ov-edgeh { fill: none; stroke: rgba(255,255,255,.16); stroke-width: 1; } .ov-edges { fill: none; stroke: rgba(0,0,0,.35); stroke-width: 1; }
.ov-screw { fill: url(#ovScrew); stroke: #22262a; stroke-width: .5; } .ov-screwt { stroke: #2b2f33; stroke-width: .8; }
.ov-ttlbg { fill: #1d2329; } .ov-ttl { fill: #e8edf2; font-size: 9px; font-weight: 700; letter-spacing: .06em; }
.ov-lbl { fill: #f2f5f7; font-size: 8px; font-weight: 700; }
.ov-sm { fill: #e8edf2; font-size: 7.5px; }
.ov-c { cursor: pointer; } .ov-c:hover .ov-pb, .ov-c:hover .ov-knob, .ov-c:hover .ov-base, .ov-c:hover .ov-btn { stroke: #7fd0ff; }
.ov-pb { fill: url(#ovPb); stroke: #000; stroke-width: 1.5; }
.ov-leg { fill: #3a3f44; font-size: 8px; font-weight: 700; }
.ov-leg.lit-w { fill: #ffffff; } .ov-leg.lit-b { fill: #39b6ff; } .ov-leg.lit-a { fill: #ffb000; } .ov-leg.lit-g { fill: #3df26a; } .ov-leg.lit-r { fill: #ff3b30; }
.ov-leg[class*="lit-"], [class*="lit-"] > .ov-annt, .lit-a .ov-annt, .lit-b .ov-annt, .lit-g .ov-annt, .lit-w .ov-annt, .lit-r .ov-annt, .ov-bar.on, .ov-fire.lit { filter: url(#ovGlow); }
.ov-base { fill: url(#ovBase); stroke: #0b0d0f; stroke-width: 1.5; }
.ov-lev { stroke: #d6dadd; stroke-width: 4; stroke-linecap: round; } .ov-tip { fill: #f4f6f7; }
.ov-knob { fill: url(#ovKnob); stroke: #000; stroke-width: 1.5; } .ov-ptr { stroke: #fff; stroke-width: 3; stroke-linecap: round; }
.ov-ann { fill: #1b1e21; stroke: #000; } .ov-annt { fill: #464b50; font-size: 6.2px; font-weight: 700; }
.lit-a .ov-ann { fill: #3a2700; } .lit-a .ov-annt { fill: #ffb000; }
.lit-b .ov-ann { fill: #062a44; } .lit-b .ov-annt { fill: #49bfff; }
.lit-g .ov-ann { fill: #06331a; } .lit-g .ov-annt { fill: #3df26a; }
.lit-w .ov-ann { fill: #2f3336; } .lit-w .ov-annt { fill: #fff; }
.lit-r .ov-ann { fill: #3d0705; } .lit-r .ov-annt { fill: #ff4b3f; }
.ov-rdbg { fill: #050607; stroke: #000; } .ov-rd { fill: #ffb24a; font-size: 10px; font-family: 'DejaVu Sans Mono', monospace; }
.ov-btn { fill: url(#ovBtn); stroke: #0b0d0f; }
.ov-fire { fill: url(#ovFire); stroke: #000; stroke-width: 2; } .ov-fire.lit { fill: #ff2a1f; } .ov-fire.pulled { stroke: #ffd54a; stroke-width: 3; }
.ov-firet { fill: #fff; font-size: 10px; font-weight: 700; }
.ov-hit { fill: #000; fill-opacity: 0; pointer-events: all; }
.ov-knob2 { fill: #2a2e33; stroke: #0b0d0f; stroke-width: 1; } .ov-grip { stroke: #50565c; stroke-width: 1.4; }
.ov-c:hover .ov-key, .ov-c:hover .ov-slot, .ov-c:hover .ov-fire { stroke: #7fd0ff; }
.ov-win { fill: #050607; stroke: #000; stroke-width: 1.5; }
.ov-seg { fill: #ffb030; font-size: 15px; font-family: 'DejaVu Sans Mono', monospace; font-weight: 700; }
.ov-lcd { fill: #ff9a3a; font-size: 15px; font-family: 'DejaVu Sans Mono', monospace; font-weight: 700; }
.ov-key { fill: url(#ovKey); stroke: #0b0d0f; stroke-width: 1.2; } .ov-keyt { fill: #e8edf2; font-size: 7px; font-weight: 700; }
.ov-bar { fill: #3a3f44; } .ov-bar.on { fill: #39ff7a; }
.ov-mst .ov-key { stroke-width: 2; } .ov-mst.m-r .ov-keyt { fill: #ff6a5f; } .ov-mst.m-a .ov-keyt { fill: #ffb000; }
.ov-mst.m-r .ov-bar.on ~ .ov-keyt, .ov-mst.m-a .ov-bar.on ~ .ov-keyt { fill: #fff; }
.ov-mst.m-r .ov-bar.on { fill: #ff2a1f; } .ov-mst.m-a .ov-bar.on { fill: #ffb000; }
.ov-slot { fill: #0d0f11; stroke: #000; stroke-width: 1.5; } .ov-lvr2d { fill: #d9dde1; stroke: #222; }
.ov-gauge { fill: #0d0f11; stroke: #9aa0a6; stroke-width: 2; } .ov-tick { stroke: #f2f5f7; stroke-width: 1.4; }
.ov-gt { fill: #f2f5f7; font-size: 7px; font-weight: 700; } .ov-needle { stroke: #fff; stroke-width: 2.4; stroke-linecap: round; }
.ov-needle2 { stroke: #ffb000; stroke-width: 1.6; stroke-linecap: round; } .ov-hub { fill: #888; }
.ov-du { fill: url(#ovDu); stroke: #050607; stroke-width: 2; } .ov-duscr { fill: #020304; }
.ov-dul { fill: #3b4148; font-size: 18px; font-weight: 700; }
.ov-plac { fill: #e8edf2; font-size: 7px; font-weight: 700; letter-spacing: .03em; }
.ov-tiny { fill: #e8edf2; font-size: 5.2px; font-weight: 700; }
.ov-cdus { fill: #050607; stroke: #000; } .ov-cdut { fill: #3df26a; font-size: 9px; font-family: 'DejaVu Sans Mono', monospace; white-space: pre; } .ov-cdut.w { fill: #f2f5f7; }
.ov-garm { stroke: #c9cdd1; stroke-width: 6; stroke-linecap: round; } .ov-gknob { fill: #f2f2ee; stroke: #222; stroke-width: 1.5; }
.ov-bg.ab.mp, .ov-bg.ab.gl { fill: #333d47; } .ov-bg.b7.mp, .ov-bg.b7.gl { fill: #4d5257; }
.unlit { }
@media (max-width: 760px) { .ovhd { inset: 46px 4px 4px 4px; padding: 6px; } }

/* ---------- main menu: full-screen MSFS-style shell ---------- */
#menu { padding: 0; align-items: stretch; justify-content: stretch; background:
  linear-gradient(90deg, rgba(3,6,10,.97) 0, rgba(5,9,14,.9) 260px, rgba(6,10,16,.72) 55%, rgba(6,10,16,.38) 100%),
  linear-gradient(0deg, rgba(3,6,10,.85) 0, rgba(3,6,10,0) 22%); }
/* before the first flight nothing is rendered behind the menu: a static dusk-sky backdrop instead */
body:not(.flown) #menu { background:
  linear-gradient(90deg, rgba(3,6,10,.97) 0, rgba(5,9,14,.9) 260px, rgba(6,10,16,.55) 55%, rgba(6,10,16,.15) 100%),
  radial-gradient(120% 70% at 75% 100%, rgba(255,150,70,.35) 0, rgba(255,120,60,.08) 35%, rgba(0,0,0,0) 60%),
  linear-gradient(180deg, #08111d 0, #13263c 45%, #2b3c52 72%, #4b4a52 86%, #151a21 86.4%, #0b0f14 100%); }
/* loading screen between FLY and the first frame of the flight */
#flyload { position: fixed; inset: 0; z-index: 60; display: none; align-items: center; justify-content: center;
  background: radial-gradient(120% 80% at 70% 110%, rgba(255,140,60,.22), rgba(0,0,0,0) 55%), linear-gradient(180deg, #050a11, #0e1b2b 60%, #0a0f15); color: #e8eef5; font-family: 'Barlow Semi Condensed', system-ui, sans-serif; }
#flyload.on { display: flex; }
.fl-box { width: min(460px, 84vw); display: flex; flex-direction: column; gap: 8px; }
.fl-logo { font: 700 44px var(--mono); letter-spacing: .1em; color: #fff; }
.fl-t { font-size: 22px; font-weight: 600; letter-spacing: .04em; }
.fl-s { color: #8fa3b6; font-size: 15px; min-height: 1.2em; }
.fl-bar { height: 4px; border-radius: 2px; background: rgba(255,255,255,.1); overflow: hidden; margin-top: 18px; }
.fl-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #2bb3e0, #7fd9f2); transition: width .25s ease-out; }
.fl-step { color: #7fd9f2; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; }
.ms-shell { flex: 1; display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 0; height: 100vh; font-family: 'Barlow Semi Condensed', system-ui, sans-serif; }
.ms-rail { display: flex; flex-direction: column; gap: 4px; padding: 26px 14px 18px; background: linear-gradient(180deg, rgba(10,15,22,.92), rgba(6,9,14,.96)); border-right: 1px solid rgba(255,255,255,.06); }
.ms-logo { padding: 0 10px 24px; }
.ms-logo-t { font: 700 34px var(--mono); letter-spacing: .1em; color: #fff; line-height: 1; }
.ms-logo-s { font-size: 12px; letter-spacing: .32em; text-transform: uppercase; color: #7fd9f2; margin-top: 6px; }
.ms-nav { display: flex; flex-direction: column; gap: 2px; }
.ms-nav-b { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: none; border: 0; border-left: 3px solid transparent; border-radius: 0 6px 6px 0; padding: 11px 12px; color: #9fb0c0; font: 600 15px 'Barlow Semi Condensed', sans-serif; letter-spacing: .08em; text-transform: uppercase; transition: background .15s, color .15s; }
.ms-nav-b:hover { background: rgba(255,255,255,.05); color: #e9f1f8; }
.ms-nav-b.on { color: #fff; background: linear-gradient(90deg, rgba(47,217,255,.18), rgba(47,217,255,0)); border-left-color: var(--cyan); }
.ms-ico { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linejoin: round; stroke-linecap: round; }
.ms-rail-foot { margin-top: auto; display: flex; flex-direction: column; gap: 8px; }
.ms-ver { padding: 0 12px; font-size: 12px; color: #5f7080; letter-spacing: .06em; }
.ms-build { margin-top: 4px; font-size: 11px; color: #4d5d6b; letter-spacing: .04em; }
.ms-update { display: block; margin-top: 8px; padding: 6px 10px; border: 1px solid #3fb6d8; border-radius: 6px; background: rgba(63, 182, 216, .12); color: #8fe0f5; font: inherit; font-size: 12px; letter-spacing: .02em; cursor: pointer; }
.ms-update:hover { background: rgba(63, 182, 216, .24); }
.ms-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.ms-head { padding: 26px 34px 6px; }
.ms-h1 { font: 700 34px 'Barlow Semi Condensed', sans-serif; letter-spacing: .03em; text-transform: uppercase; color: #fff; line-height: 1.05; }
.ms-h2 { color: #93a4b5; font-size: 15px; margin: 4px 0 14px; letter-spacing: .02em; }
.ms-head .wz-steps { margin: 0; max-width: 980px; display: flex; gap: 0; border-bottom: 1px solid rgba(255,255,255,.1); }
.ms-head .wz-step { flex: 1; background: none; border: 0; border-bottom: 3px solid transparent; border-radius: 0; padding: 10px 6px 11px; font-size: 14.5px; letter-spacing: .06em; text-transform: uppercase; }
.ms-head .wz-step.on { background: none; border-bottom-color: var(--cyan); color: #fff; }
.ms-head .wz-step.done { color: #c9d6e2; }
.ms-body.menu-body { flex: 1; padding: 16px 34px 20px; max-width: 1240px; }
.ms-body .wz-detail, .ms-body .set-group, .ms-body .wz-opt, .ms-body .ac-card, .ms-body .wz-where, .ms-body .wz-route { background: rgba(14,20,28,.82); backdrop-filter: blur(6px); }
.ms-body .ac-card { border-color: rgba(255,255,255,.08); }
.ms-body .ac-card.sel { background: rgba(14,46,60,.85); }
.ms-hangar { margin: -4px -6px 8px; border-radius: 8px; padding: 10px 0 6px; background: radial-gradient(ellipse at 50% 70%, rgba(47,217,255,.16), rgba(47,217,255,0) 65%), repeating-linear-gradient(90deg, rgba(255,255,255,.035) 0 1px, transparent 1px 28px), repeating-linear-gradient(0deg, rgba(255,255,255,.035) 0 1px, transparent 1px 28px); }
.ms-stats { display: grid; gap: 7px; margin-top: 12px; }
.ms-stat { display: grid; grid-template-columns: 70px 1fr 82px; gap: 10px; align-items: center; font-size: 13px; }
.ms-stat-l { color: #93a4b5; text-transform: uppercase; letter-spacing: .08em; font-size: 11.5px; }
.ms-stat-b { height: 6px; background: rgba(255,255,255,.08); border-radius: 3px; overflow: hidden; }
.ms-stat-b i { display: block; height: 100%; background: linear-gradient(90deg, #1f9cc4, var(--cyan)); border-radius: 3px; }
.ms-stat-v { color: #e6eef5; text-align: right; font-variant-numeric: tabular-nums; }
/* bottom flight bar */
.ms-bar.menu-foot { align-items: center; gap: 14px; padding: 12px 34px 16px; border-top: 1px solid rgba(255,255,255,.08); background: linear-gradient(0deg, rgba(4,7,11,.96), rgba(6,10,15,.86)); }
.ms-bar .grow { display: none; }
.ms-acchip { display: flex; align-items: center; gap: 10px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.1); border-radius: 8px; padding: 5px 14px 5px 6px; color: #fff; text-align: left; }
.ms-acchip:hover { border-color: var(--cyan); }
.ms-acchip b { display: block; font-size: 16px; letter-spacing: .03em; } .ms-acchip small { color: #93a4b5; font-size: 12.5px; }
.ms-acchip-pic { width: 74px; height: 46px; border-radius: 5px; background: rgba(47,217,255,.08); display: grid; place-items: center; }
.ms-route { flex: 1; min-width: 0; display: flex; flex-direction: column; padding-left: 4px; }
.ms-route b { font: 700 17px var(--mono); color: #fff; letter-spacing: .04em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ms-route small { color: #93a4b5; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cta.fly { min-width: 168px; padding: 13px 34px; font: 700 19px 'Barlow Semi Condensed', sans-serif; letter-spacing: .22em; text-transform: uppercase; color: #001018; background: linear-gradient(180deg, #6fe6ff, #22c4ec); border-radius: 4px; box-shadow: 0 6px 24px rgba(47,217,255,.28); }
.cta.fly:hover { filter: brightness(1.08); box-shadow: 0 8px 30px rgba(47,217,255,.42); }
/* home tiles */
.ms-body.home { display: flex; }
.ms-home { flex: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: minmax(150px, 1fr); gap: 14px; max-width: 1180px; min-height: 0; }
.ms-tile { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; text-align: left; gap: 4px; padding: 18px 20px; border-radius: 10px; border: 1px solid rgba(255,255,255,.09); color: #fff; background: rgba(14,20,28,.78); backdrop-filter: blur(6px); transition: transform .18s, border-color .18s, box-shadow .18s; }
.ms-tile:hover { transform: translateY(-2px); border-color: rgba(47,217,255,.7); box-shadow: 0 12px 34px rgba(0,0,0,.45), inset 0 0 0 1px rgba(47,217,255,.35); }
.ms-tile::before { content: ''; position: absolute; inset: 0; z-index: -1; opacity: .9; }
.ms-tile.hero { grid-column: span 2; grid-row: span 2; background: radial-gradient(ellipse at 70% 40%, rgba(47,217,255,.22), rgba(47,217,255,0) 60%), linear-gradient(160deg, rgba(20,40,58,.92), rgba(8,13,20,.92)); }
.ms-tile.plan { background: linear-gradient(160deg, rgba(18,44,62,.9), rgba(9,15,22,.9)), repeating-linear-gradient(45deg, rgba(255,255,255,.04) 0 1px, transparent 1px 16px); }
.ms-tile.scen { background: linear-gradient(160deg, rgba(56,36,18,.85), rgba(12,12,14,.9)); }
.ms-tile.free { background: linear-gradient(160deg, rgba(24,50,36,.85), rgba(9,14,14,.9)); }
.ms-tile.hangar { background: linear-gradient(160deg, rgba(36,36,58,.85), rgba(10,11,18,.9)); }
.ms-tile.wx { background: linear-gradient(160deg, rgba(30,52,72,.85), rgba(10,14,20,.9)); }
.ms-tile.saves { background: linear-gradient(160deg, rgba(48,30,48,.8), rgba(12,10,14,.9)); }
.ms-tile-k { font-size: 12px; letter-spacing: .28em; text-transform: uppercase; color: #7fd9f2; }
.ms-tile-t { font: 700 24px 'Barlow Semi Condensed', sans-serif; letter-spacing: .03em; text-transform: uppercase; }
.ms-tile.hero .ms-tile-t { font-size: 40px; }
.ms-tile-d { color: #b3c1ce; font-size: 14px; line-height: 1.35; max-width: 46ch; }
.ms-tile-pic { position: absolute; right: 6%; top: 10%; transform: rotate(-28deg); filter: drop-shadow(0 18px 18px rgba(0,0,0,.5)); opacity: .95; pointer-events: none; }
@media (max-width: 900px) {
  .ms-shell { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); }
  .ms-rail { flex-direction: row; align-items: center; padding: 8px 10px; gap: 8px; overflow-x: auto; }
  .ms-logo { padding: 0 8px 0 4px; } .ms-logo-t { font-size: 22px; } .ms-logo-s { display: none; }
  .ms-nav { flex-direction: row; } .ms-nav-b { padding: 8px 10px; border-left: 0; border-bottom: 3px solid transparent; border-radius: 4px; font-size: 13px; white-space: nowrap; } .ms-nav-b.on { border-bottom-color: var(--cyan); }
  .ms-nav-b .ms-ico { display: none; } .ms-rail-foot { display: none; }
  .ms-head { padding: 12px 14px 4px; } .ms-h1 { font-size: 24px; } .ms-h2 { margin-bottom: 8px; }
  .ms-body.menu-body { padding: 10px 14px; }
  .ms-home { grid-template-columns: 1fr 1fr; grid-auto-rows: minmax(120px, auto); }
  .ms-tile.hero { grid-column: span 2; grid-row: span 1; min-height: 200px; } .ms-tile.hero .ms-tile-t { font-size: 28px; }
  .ms-tile-pic { transform: rotate(-28deg) scale(.7); right: -6%; top: -4%; }
  .ms-bar.menu-foot { padding: 10px 14px; flex-wrap: wrap; } .ms-route { order: -1; flex-basis: 100%; } .ms-acchip { display: none; }
}
.menu-open #topbar, .menu-open #panel, .menu-open #glare { visibility: hidden; }
.ms-grp { grid-column: 1 / -1; font-size: 12px; letter-spacing: .26em; text-transform: uppercase; color: #7fd9f2; padding: 10px 2px 2px; border-bottom: 1px solid rgba(255,255,255,.07); }
.ms-grp:first-child { padding-top: 0; }
.ms-body .wz-detail { position: sticky; top: 0; }
.ms-home { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.ms-tile.wx, .ms-tile.saves { grid-column: span 2; }
.ms-bar.menu-foot { padding-bottom: 24px; }
@media (max-width: 900px) { .ms-home { grid-template-columns: 1fr 1fr; } .ms-tile.wx, .ms-tile.saves { grid-column: span 1; } }
@media (max-width: 900px) { .ms-body.home { display: block; } .ms-home { grid-auto-rows: auto; } .ms-tile { min-height: 130px; } .ms-tile.hero { min-height: 220px; } }
@media (max-width: 900px) { body.menu-open .ms-bar { padding-bottom: 34px; } body.menu-open .scn-attrib { max-width: 96vw !important; } }
.deck-tip { position: fixed; z-index: 20; pointer-events: none; display: none; max-width: 320px; padding: 4px 8px; font-size: 12px; background: rgba(10,13,17,.92); color: #e8edf2; border: 1px solid var(--line2); border-radius: 5px; }
.deck-tip.on { display: block; }
/* simulation level selector (menu aircraft page + settings) */
.simlvl.compact { margin: 10px 0 6px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px; }
.simlvl .lp-seg { min-width: 280px; }
.simlvl .hint { margin-top: 6px; }

/* ---------------------------------------------------------------- MCDU / CDU popup */
#mcdu { position: fixed; right: 18px; top: 64px; z-index: 60; width: 392px; display: none; flex-direction: column; gap: 8px;
  padding: 10px 12px 14px; border-radius: 10px; background: linear-gradient(#5d6166, #45494e); box-shadow: 0 10px 40px rgba(0,0,0,.55), inset 0 1px 0 rgba(255,255,255,.18);
  font: 11px/1.2 system-ui, sans-serif; color: #e8e8e8; user-select: none; outline: none; max-height: calc(100vh - 80px); overflow: auto; }
#mcdu.bo { background: linear-gradient(#3f4347, #2c2f33); }
#mcdu.open { display: flex; }
#mcdu .mc-head { display: flex; align-items: center; gap: 8px; font-weight: 600; letter-spacing: .06em; }
#mcdu .mc-hint { flex: 1; font-weight: 400; font-size: 9.5px; opacity: .65; letter-spacing: 0; }
#mcdu .mc-x { background: none; border: 0; color: #ddd; font-size: 18px; cursor: pointer; padding: 0 4px; }
#mcdu .mc-body { display: grid; grid-template-columns: 26px 1fr 26px; gap: 5px; align-items: stretch; }
#mcdu .mc-lsk { display: flex; flex-direction: column; justify-content: space-around; padding: 22px 0 18px; }
#mcdu .mc-lsk .lsk { height: 16px; padding: 0; }
#mcdu .mc-scr { background: #05080a; border: 3px solid #1a1c1e; border-radius: 4px; padding: 6px 6px; min-height: 300px;
  font: 600 14.5px/19px ui-monospace, 'DejaVu Sans Mono', Menlo, monospace; white-space: pre; overflow: hidden; box-shadow: inset 0 0 18px rgba(0,0,0,.9); }
#mcdu .mc-ln { height: 19px; }
#mcdu .mc-ln.lab { font-size: 11.5px; height: 14px; line-height: 14px; }
#mcdu .mc-scr .sm { font-size: 11.5px; }
#mcdu .mc-fk { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; }
#mcdu .mc-kb { display: grid; grid-template-columns: 3fr 6fr; gap: 8px; }
#mcdu .mc-num { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; align-content: start; }
#mcdu .mc-al { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; align-content: start; }
#mcdu .mc-k { position: relative; min-height: 26px; padding: 2px; border-radius: 4px; border: 1px solid #1d1f22; cursor: pointer;
  background: linear-gradient(#55595e, #383b3f); color: #f3f3f3; font: 600 9.5px/1.05 system-ui, sans-serif; box-shadow: 0 2px 0 #18191b; }
#mcdu.bo .mc-k { background: linear-gradient(#4a4d51, #2a2c2f); }
#mcdu .mc-k.n, #mcdu .mc-k.a { font-size: 13px; }
#mcdu .mc-k.a.w { font-size: 9.5px; }
#mcdu .mc-k:active { transform: translateY(1px); box-shadow: 0 1px 0 #18191b; }
#mcdu .mc-k.blank { visibility: hidden; }
#mcdu .mc-k.exec i { position: absolute; left: 22%; right: 22%; top: 3px; height: 3px; border-radius: 2px; background: #22301f; }
#mcdu .mc-k.exec i.on { background: #6dff5a; box-shadow: 0 0 6px #6dff5a; }
#mcdu .mc-k:focus-visible { outline: 2px solid #8fd3ff; }
@media (max-width: 640px) { #mcdu { right: 4px; left: 4px; width: auto; top: 56px; } }
.ov-bg.b7.b78 { fill: #55585c; } .ov-bg.b7.b78 ~ .ov-pnl { fill: #6e7276; stroke: #3e4144; }

/* ---------------- emergency panel (Shift+E) ---------------- */
#emer { position: absolute; top: 10px; right: 10px; width: min(400px, calc(100vw - 20px)); max-height: calc(100% - 20px); display: none; flex-direction: column; background: rgba(12,10,12,.96); border: 1px solid #4a2a28; border-radius: 10px; z-index: 10; overflow: hidden; backdrop-filter: blur(8px); }
#emer.open { display: flex; }
#emer .taxi-head { background: linear-gradient(#24120f, #140c0b); }
.em-status { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.em-badge { font: 700 10.5px var(--mono); letter-spacing: .08em; padding: 3px 7px; border-radius: 4px; border: 1px solid currentColor; }
.em-badge.green { color: var(--green); } .em-badge.amber { color: #f3b33d; } .em-badge.red { color: #ff5a4e; background: rgba(255,90,78,.1); }
.em-title { color: #fff; font-weight: 700; font-size: 13px; }
.em-g { margin-left: auto; font: 11px var(--mono); color: var(--faint); }
.em-list { color: var(--text); font-size: 12px; line-height: 1.45; display: flex; flex-direction: column; gap: 2px; }
.em-dim { color: var(--faint); font-size: 11.5px; }
.em-kv { display: grid; grid-template-columns: auto 1fr auto 1fr auto 1fr auto 1fr; gap: 2px 7px; font-size: 11.5px; align-items: baseline; }
.em-kv span { color: var(--faint); } .em-kv b { font-family: var(--mono); color: var(--text); }
.em-kv b.green { color: var(--green); } .em-kv b.amber { color: #f3b33d; } .em-kv b.red { color: #ff5a4e; } .em-kv b.cyan { color: var(--cyan); }
.em-fire, .em-unit { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text); }
.em-fire > span:first-child { width: 96px; } .em-unit > span { width: 130px; } .em-unit b { font: 11px var(--mono); color: var(--cyan); font-weight: 400; }
.em-evac { color: #ff6a5e !important; border-color: #7a2c26 !important; font-weight: 700 !important; }
.em-log { max-height: 92px !important; }
.em-report { width: min(560px, 100%); text-align: left; padding: 22px 0 0; }
.em-report .crash-t { text-align: center; } .crash-t.amber { color: #f3b33d; }
.em-rep-sub { text-align: center; color: var(--muted); font-size: 14px; margin-top: 4px; }
.em-rep { padding: 8px 24px 12px; max-height: 55vh; overflow: auto; font-size: 13.5px; color: var(--text); line-height: 1.5; }
.em-rep h5 { margin: 12px 0 4px; font: 700 10.5px var(--mono); letter-spacing: .1em; color: var(--faint); text-transform: uppercase; }
.em-report .menu-foot { justify-content: center; }
.tbtn.alarm { color: #ff6a5e; border-color: #7a2c26; }

/* ---------- CONTROLS panel (sensitivity, joystick pairing / binding) ---------- */
#ctlp, #sensp { position: absolute; top: 10px; right: 10px; width: min(410px, calc(100vw - 20px)); max-height: calc(100% - 20px); display: none; flex-direction: column; background: rgba(9,13,18,.96); border: 1px solid var(--line2); border-radius: 10px; z-index: 11; overflow: hidden; backdrop-filter: blur(8px); }
#ctlp.open, #sensp.open { display: flex; }
.ctl-body { overflow-y: auto; padding-bottom: 12px; }
.ctl-row { margin: 6px 0; }
.ctl-inline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ctl-inline > span { font-size: 12px; color: var(--muted); font-weight: 600; flex: 1; }
.ctl-inline .lp-seg { min-width: 120px; }
.ctl-note { font-size: 11.5px; color: var(--faint); line-height: 1.35; margin: 3px 0 6px; }
.ctl-eff { font: 600 11px var(--mono); color: var(--cyan); margin: 6px 0 8px; }
.ctl-sl { margin: 8px 0; }
.ctl-sl-top { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); font-weight: 600; margin-bottom: 2px; }
.ctl-val { font: 700 11px var(--mono); color: var(--text); }
.ctl-bars { display: grid; gap: 4px; margin: 4px 0 6px; }
.ctl-bar { display: grid; grid-template-columns: 58px 1fr; align-items: center; gap: 8px; }
.ctl-bar span { font: 700 10px var(--mono); color: var(--faint); }
.ctl-bar b, .ctl-livebar { position: relative; display: block; height: 8px; background: #141b22; border: 1px solid var(--line); border-radius: 3px; overflow: hidden; }
.ctl-bar.bi b::after, .ctl-livebar::after { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 1px; background: var(--line2); }
.ctl-bar i, .ctl-live { position: absolute; top: 0; bottom: 0; left: 50%; width: 0; background: var(--cyan); }
.ctl-pair { display: grid; gap: 4px; margin: 4px 0 8px; justify-items: start; }
.ctl-pair.on { border: 1px dashed #2a5d6c; border-radius: 6px; padding: 8px; color: var(--text); font-size: 12.5px; animation: ctlpulse 1.4s ease-in-out infinite; }
@keyframes ctlpulse { 50% { border-color: var(--cyan); } }
.ctl-dev { border: 1px solid var(--line); border-radius: 7px; padding: 7px 8px; margin: 6px 0; background: #0c1116; }
.ctl-dev.off { opacity: .7; }
.ctl-dev-head { display: flex; align-items: center; gap: 6px; }
.ctl-dev-head b { display: block; font-size: 13px; color: #fff; }
.ctl-dev-head small { display: block; font-size: 11px; color: var(--muted); }
.ctl-map { margin-top: 8px; display: grid; gap: 3px; }
.ctl-map-h { font: 700 10px var(--mono); letter-spacing: .08em; color: var(--faint); margin-bottom: 2px; }
.ctl-map-r { display: grid; grid-template-columns: 1fr 92px 56px auto auto auto; align-items: center; gap: 5px; font-size: 12px; }
.ctl-map-r.btn { grid-template-columns: 1fr 92px auto auto; }
.ctl-map-r > span { color: var(--muted); min-width: 0; }
.ctl-map-r em { font: 600 11px var(--mono); font-style: normal; color: var(--text); }
.ctl-map-r.cap em { color: var(--amber); grid-column: span 2; }
.ctl-map-r.cap > b { display: none; }
.ctl-map-r .chip-t[disabled] { opacity: .4; cursor: default; }

/* ---------- top bar groups (drop-down menus) ---------- */
.tools { align-items: center; }
.tsep { width: 1px; height: 22px; background: var(--line2); margin: 0 2px; flex: none; }
.tg-btn { display: inline-flex; align-items: center; gap: 5px; }
.tg-car { font-size: 9px; opacity: .7; transform: translateY(1px); }
.tg-btn[aria-expanded="true"] { color: #fff; border-color: #44515f; background: #18212a; }
.tmenu { position: fixed; z-index: 60; min-width: 240px; display: flex; flex-direction: column; padding: 5px; background: rgba(12,17,22,.98); border: 1px solid var(--line2); border-radius: 8px; box-shadow: 0 10px 28px rgba(0,0,0,.5); }
.tmenu[hidden] { display: none; }
.tm-item { display: grid; grid-template-columns: 10px 1fr auto; align-items: center; gap: 9px; text-align: left; background: transparent; border: 0; border-radius: 5px; padding: 8px 9px; color: var(--text); font-size: 13px; font-weight: 600; }
.tm-item:hover, .tm-item:focus-visible { background: #18232d; color: #fff; outline: none; }
.tm-item kbd { font: 600 10.5px var(--mono); color: var(--faint); background: #10161c; border: 1px solid var(--line); border-radius: 4px; padding: 1px 5px; }
.tm-led { width: 7px; height: 7px; border-radius: 50%; background: #2a333c; }
.tm-item.on .tm-led { background: var(--green); box-shadow: 0 0 6px rgba(80,220,120,.6); }
.tm-item.on { color: var(--green); }
.tm-item.alarm { color: #ff6a5e; }
.tm-item.alarm .tm-led { background: #ff6a5e; }

/* ---------- SPEEDS panel ---------- */
#spdp { position: absolute; top: 10px; left: 10px; width: min(420px, calc(100vw - 20px)); max-height: calc(100% - 20px); display: none; flex-direction: column; background: rgba(9,13,18,.96); border: 1px solid var(--line2); border-radius: 10px; z-index: 11; overflow: hidden; backdrop-filter: blur(8px); }
#spdp.open { display: flex; }
.spd-body { overflow-y: auto; padding-bottom: 12px; }
.spd-live { margin: 0 10px 2px; padding: 7px 9px; border-radius: 6px; font: 700 11.5px var(--mono); letter-spacing: .02em; border: 1px solid var(--line2); color: var(--text); background: #0f151b; }
.spd-live.ok { color: var(--green); border-color: #2a5a36; background: #0d1c13; }
.spd-live.warn { color: var(--amber); border-color: #6b5420; background: #1d180c; }
.spd-live.bad { color: #ff6a5e; border-color: #7a2c26; background: #220f0d; }
.spd-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 4px 0; }
.spd-tile { border: 1px solid var(--line); border-radius: 7px; background: #0c1217; padding: 6px 4px 5px; text-align: center; }
.spd-tile span { display: block; font: 700 10px var(--mono); color: var(--faint); letter-spacing: .06em; }
.spd-tile b { display: block; font: 700 21px var(--mono); color: var(--cyan); line-height: 1.15; }
.spd-tile small { display: block; font-size: 10px; color: var(--muted); }
.spd-rows { display: grid; gap: 1px; }
.spd-row { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; border-bottom: 1px dotted #1c242c; font-size: 12px; }
.spd-row span { color: var(--muted); }
.spd-row b { font: 600 11.5px var(--mono); color: var(--text); text-align: right; }
.spd-row.lim b { color: var(--amber); }
.spd-sub { font-size: 11px; font-weight: 700; color: var(--text); margin-top: 4px; }
.spd-warn { font-size: 11.5px; color: var(--amber); border: 1px solid #6b5420; border-radius: 5px; padding: 5px 7px; }
.spd-warn.red { color: #ff6a5e; border-color: #7a2c26; }
.spd-num { width: 84px; background: #0c1217; border: 1px solid var(--line2); border-radius: 5px; color: var(--text); font: 600 12px var(--mono); padding: 5px 6px; }
.spd-table { display: grid; font: 600 11.5px var(--mono); }
.spd-tr { display: grid; grid-template-columns: 1fr 1fr 1fr 1.3fr; padding: 3px 6px; border-radius: 4px; color: var(--text); }
.spd-tr.hd { color: var(--faint); font-size: 10px; letter-spacing: .06em; }
.spd-tr.cur { background: #12303a; color: var(--cyan); }
.spd-btns { display: flex; gap: 8px; align-items: center; margin-top: 8px; }

/* camera: segmented buttons on wide screens, a drop-down on narrower ones */
.cam-dd { display: none; }
@media (max-width: 1440px) { #topbar > .seg[aria-label="Camera"] { display: none; } .cam-dd { display: inline-flex; } }
#app.mobile .cam-dd { display: inline-flex; }

/* start menu: airline + gate map */
.gpick .fld select { width: 100%; }
.gnote { font-size: 12.5px; line-height: 1.4; border-radius: 6px; padding: 7px 10px; margin: 2px 0 8px; border: 1px solid var(--line2); background: #0e141a; }
.gnote.warn { border-color: rgba(255,176,32,.5); color: #ffd58a; background: rgba(255,176,32,.07); }
.gnote.ok { border-color: rgba(56,224,90,.35); color: #b8f0c4; }
.gmap { position: relative; margin: 6px 0 4px; }
.gmap-cv { width: 100%; display: block; border: 1px solid var(--line2); border-radius: 6px; background: #0a0e12; cursor: crosshair; touch-action: none; }
.gmap-bar { position: absolute; top: 6px; right: 6px; display: flex; gap: 4px; }
.gmap-bar .pre-btn { padding: 3px 8px; font-size: 11px; min-width: 0; }
.gmap-leg { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 6px; font-size: 11.5px; color: var(--muted); }
.gmap-leg i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.gmap-tip { position: absolute; z-index: 3; max-width: 260px; pointer-events: none; background: rgba(10,14,18,.95); border: 1px solid var(--line2); border-radius: 6px; padding: 6px 8px; font-size: 12px; line-height: 1.4; color: var(--text); }
.gmap-tip .bad { color: #ffb4ae; } .gmap-tip .good { color: #9ff0b0; }
.gmap-info { margin-top: 4px; }

/* ---------- First officer panel (copilotpanel.js) and subtitles */
#fop { position: absolute; top: 10px; left: 10px; width: min(430px, calc(100vw - 20px)); max-height: calc(100% - 20px); display: none; flex-direction: column; background: rgba(9,13,18,.96); border: 1px solid var(--line2); border-radius: 10px; z-index: 11; overflow: hidden; backdrop-filter: blur(8px); }
#fop.open { display: flex; }
.fo-togs { display: flex; flex-wrap: wrap; gap: 5px; }
.fo-cmdline { flex-wrap: nowrap; }
.fo-in { flex: 1; min-width: 0; background: #0c1217; border: 1px solid var(--line2); border-radius: 5px; color: var(--text); font: 600 12px var(--mono); padding: 7px 8px; }
.fo-mic { flex: 0 0 auto; padding: 6px 10px; }
.fo-mic.on { color: #ff6a5e; border-color: #7a2c26; }
.fo-flaps { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.fo-flaps > span { font-size: 12px; color: var(--muted); font-weight: 600; margin-right: 4px; }
.fo-flaps .sw { flex: 1; min-width: 34px; padding: 6px 4px; }
.sw.on { color: var(--cyan); border-color: #2a5d6c; background: #10222b; }
.fo-cks { display: flex; flex-wrap: wrap; gap: 5px; }
.fo-cks .chip-t.done { color: var(--green); }
.fo-ckt { border: 1px solid var(--line); border-radius: 7px; padding: 6px 8px; background: #0c1217; display: grid; gap: 1px; }
.fo-ck { display: grid; grid-template-columns: 16px 1fr auto; gap: 6px; align-items: baseline; padding: 3px 0; border-bottom: 1px dotted #1c242c; font-size: 12px; }
.fo-ck i { font-style: normal; font-weight: 700; color: var(--faint); text-align: center; }
.fo-ck b { font: 600 11.5px var(--mono); color: var(--muted); text-align: right; }
.fo-ck.cur { background: #111c24; }
.fo-ck.ok i, .fo-ck.ok b, .fo-ck.crew i { color: var(--green); }
.fo-ck.crew b { color: var(--text); }
.fo-ck.hold i, .fo-ck.hold b, .fo-ck.hold span { color: var(--amber); }
.fo-ck.over i, .fo-ck.over b { color: var(--cyan); }
.fo-ck.rd i { color: var(--cyan); }
.fo-log { display: grid; gap: 2px; font: 600 11.5px var(--mono); color: var(--muted); }
.fo-log > div:first-child { color: var(--text); }
#fosub { position: absolute; left: 50%; bottom: 128px; transform: translateX(-50%); max-width: min(560px, 90%); padding: 5px 12px; border-radius: 6px; background: rgba(6,10,14,.78); color: #e8f1f7; font: 600 13px var(--mono); pointer-events: none; opacity: 0; transition: opacity .25s; z-index: 9; white-space: nowrap; }
#fosub.on { opacity: 1; }

/* panel synoptic lines, switch guards, RMP / ACP details */
.ov-wire { fill: none; stroke: #e8edf2; stroke-width: 1.6; stroke-linecap: round; opacity: .85; }
.ov-guard { fill: rgba(200,30,24,.42); stroke: #8c120d; stroke-width: 1.4; } .ov-guard.open { fill: #b3201a; }
.ov-guardl { stroke: rgba(255,210,200,.55); stroke-width: 1.2; }
.ov-rd.sm { font-size: 8.4px; }
.ov-lcd.sm { font-size: 11px; }
.ov-rxring { fill: none; stroke: #23272b; stroke-width: 1.6; } .ov-rxring.on { stroke: #f4f6f7; filter: url(#ovGlow); }

/* =====================================================================================================
   Launcher (main menu) — top navigation, live 3D hangar, bottom flight bar (js/ui.js buildMenu, js/hangar3d.js)
   ===================================================================================================== */
#menu { background: none !important; padding: 0; }
.lx { position: fixed; inset: 0; display: grid; grid-template-rows: 64px minmax(0, 1fr) auto; font-family: 'Barlow Semi Condensed', system-ui, sans-serif; color: #e9eff5; overflow: hidden; }
.lx-bg { position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(90% 60% at 62% 62%, rgba(120,170,215,.20), rgba(0,0,0,0) 62%),
    linear-gradient(180deg, #0a121c 0%, #142233 46%, #1d2b3b 60%, #0f151d 60.2%, #0a0e13 100%); }
body.flown #menu .lx:not(.tab-home):not(.tab-hangar) .lx-bg { background: linear-gradient(180deg, rgba(5,8,12,.88), rgba(5,8,12,.94)); }
.lx-bg::after { content: ''; position: absolute; inset: 0; background: radial-gradient(130% 90% at 50% 40%, rgba(0,0,0,0) 55%, rgba(0,0,0,.55) 100%); }
.tab-home .lx-bg::before, .tab-hangar .lx-bg::before { content: ''; position: absolute; left: 0; right: 0; top: 60%; height: 40%;
  background: repeating-linear-gradient(90deg, rgba(255,255,255,.035) 0 1px, transparent 1px 120px), radial-gradient(60% 80% at 60% 0%, rgba(140,190,230,.12), rgba(0,0,0,0) 70%); }
.hx-stage { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.hx-stage canvas { width: 100% !important; height: 100% !important; display: block; }
.hx-stage.interactive canvas { pointer-events: auto; cursor: grab; }
.hx-stage.loading::after { content: 'Preparing aircraft…'; position: absolute; left: 50%; top: 52%; transform: translate(-50%, -50%); padding: 8px 16px; border-radius: 20px;
  background: rgba(6,10,15,.7); border: 1px solid rgba(127,217,242,.35); color: #9fe3f5; font-size: 14px; letter-spacing: .12em; text-transform: uppercase; animation: lxpulse 1.2s ease-in-out infinite; }
@keyframes lxpulse { 50% { opacity: .45; } }
.lx-top, .lx-main, .lx-bar { position: relative; z-index: 2; min-width: 0; }
/* top navigation */
.lx-top { display: flex; align-items: center; gap: 22px; padding: 0 22px; background: linear-gradient(180deg, rgba(4,7,11,.92), rgba(4,7,11,.55)); border-bottom: 1px solid rgba(255,255,255,.06); backdrop-filter: blur(8px); }
.lx-logo { display: flex; flex-direction: column; line-height: 1; }
.lx-logo b { font: 700 25px var(--mono); letter-spacing: .1em; color: #fff; }
.lx-logo span { font-size: 10.5px; letter-spacing: .34em; text-transform: uppercase; color: #7fd9f2; margin-top: 4px; }
.lx-nav { display: flex; gap: 2px; height: 100%; overflow-x: auto; scrollbar-width: none; }
.lx-nav button { position: relative; background: none; border: 0; padding: 0 14px; height: 100%; font-size: 15px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: #93a4b5; white-space: nowrap; }
.lx-nav button:hover { color: #fff; }
.lx-nav button.on { color: #fff; }
.lx-nav button.on::after { content: ''; position: absolute; left: 12px; right: 12px; bottom: 0; height: 3px; border-radius: 3px 3px 0 0; background: var(--cyan); box-shadow: 0 0 14px rgba(47,217,255,.7); }
.lx-topr { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.lx-topr .ms-update { margin: 0; }
.lx-user { display: flex; align-items: center; gap: 9px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1); border-radius: 22px; padding: 4px 14px 4px 4px; color: #dfe8f0; font-size: 14px; max-width: 220px; }
.lx-user span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lx-user:hover { border-color: var(--cyan); }
.lx-av { width: 30px; height: 30px; flex: none; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, #2fd9ff, #1f7fb0); color: #001018; font-weight: 700; }
/* bottom bar */
.lx-bar { display: flex; align-items: center; gap: 14px; padding: 12px 22px 14px; background: linear-gradient(0deg, rgba(3,6,10,.96), rgba(4,8,12,.78)); border-top: 1px solid rgba(255,255,255,.07); backdrop-filter: blur(8px); }
.lx-acchip, .lx-route { display: flex; align-items: center; gap: 10px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.1); border-radius: 10px; padding: 5px 14px 5px 6px; color: #fff; text-align: left; min-width: 0; }
.lx-acchip:hover, .lx-route:hover { border-color: rgba(47,217,255,.7); }
.lx-acchip b, .lx-route b { display: block; font-size: 16px; letter-spacing: .03em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lx-acchip small, .lx-route small { display: block; color: #93a4b5; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lx-route { flex-direction: column; align-items: flex-start; gap: 0; padding: 7px 16px; max-width: 46vw; }
.lx-route b { font-family: var(--mono); font-size: 15px; }
.lx-acpic { width: 70px; height: 44px; border-radius: 6px; background: rgba(47,217,255,.08); display: grid; place-items: center; flex: none; }
.lx-grow { flex: 1; }
.lx-ver { color: #4f6070; font-size: 12px; letter-spacing: .05em; white-space: nowrap; }
.lx-bar .cta.fly { min-width: 170px; }
/* main area */
.lx-main { display: flex; flex-direction: column; min-height: 0; }
.lx-scroll { overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.18) transparent; }
.lx-page { flex: 1; padding: 22px 28px 28px; }
.lx-page > * { max-width: 1240px; }
/* buttons, inputs */
.lx-btn { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.16); border-radius: 8px; padding: 10px 18px; color: #eaf2f8; font-size: 15px; font-weight: 600; letter-spacing: .05em; }
.lx-btn:hover { border-color: rgba(47,217,255,.8); background: rgba(47,217,255,.1); }
.lx-btn.primary { background: linear-gradient(180deg, #6fe6ff, #22c4ec); border-color: transparent; color: #001018; }
.lx-btn.primary:hover { filter: brightness(1.08); box-shadow: 0 6px 24px rgba(47,217,255,.35); }
.lx-btn.small { padding: 6px 12px; font-size: 13.5px; }
.lx-btn.ghost { background: none; }
.lx-link { background: none; border: 0; color: #7fd9f2; font-size: 14px; padding: 4px 2px; }
.lx-link:hover { color: #fff; text-decoration: underline; }
.lx-input { background: rgba(0,0,0,.35); border: 1px solid rgba(255,255,255,.14); border-radius: 8px; padding: 9px 12px; color: #fff; font-size: 15px; min-width: 0; }
.lx-input:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(47,217,255,.15); }
.lx-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 10px 0; }
.lx-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.lx-chips button { background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.12); border-radius: 16px; padding: 4px 12px; color: #a9b8c6; font-size: 13px; }
.lx-chips button.on { background: rgba(47,217,255,.16); border-color: rgba(47,217,255,.7); color: #fff; }
.lx-seg { display: flex; background: rgba(0,0,0,.3); border: 1px solid rgba(255,255,255,.1); border-radius: 10px; padding: 3px; gap: 3px; }
.lx-seg button { flex: 1; background: none; border: 0; border-radius: 7px; padding: 8px 10px; color: #93a4b5; font-size: 14px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.lx-seg button.on { background: rgba(47,217,255,.16); color: #fff; }
.lx-seg.wide { max-width: 420px; margin-bottom: 14px; }
.lx-panel { background: rgba(10,15,22,.78); border: 1px solid rgba(255,255,255,.08); border-radius: 14px; padding: 16px 18px; backdrop-filter: blur(10px); margin-bottom: 14px; }
.lx-ph { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; font-size: 13px; letter-spacing: .22em; text-transform: uppercase; color: #7fd9f2; }
.lx-muted { color: #8fa0b0; font-size: 14px; line-height: 1.45; margin: 8px 0; }
.lx-empty { color: #8fa0b0; font-size: 14px; line-height: 1.5; margin: 6px 0; }
.lx-msg { color: #ffd28a; font-size: 14px; margin: 8px 0; }
.lx-banner { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 12px 16px; margin-bottom: 14px; border-radius: 12px; background: linear-gradient(90deg, rgba(47,217,255,.16), rgba(47,217,255,.04)); border: 1px solid rgba(47,217,255,.35); }
/* home */
.lx-home { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) 340px; grid-template-rows: minmax(0, 1fr) auto; gap: 18px 22px; padding: 26px 28px 20px; min-height: 0; }
.lx-hero { align-self: center; max-width: 560px; }
.lx-kicker { font-size: 14px; letter-spacing: .3em; text-transform: uppercase; color: #7fd9f2; }
.lx-title { margin: 6px 0 4px; font: 700 clamp(40px, 5.4vw, 74px)/0.98 'Barlow Semi Condensed', sans-serif; letter-spacing: .01em; color: #fff; text-shadow: 0 4px 30px rgba(0,0,0,.6); }
.lx-sub { color: #c3d0dc; font-size: 18px; min-height: 1.3em; }
.lx-pills { display: flex; flex-wrap: wrap; gap: 6px; margin: 16px 0 22px; }
.lx-pills span { padding: 4px 11px; border-radius: 14px; background: rgba(0,0,0,.35); border: 1px solid rgba(255,255,255,.12); font-size: 13.5px; color: #cfdbe6; }
.lx-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.lx-actions .lx-btn.primary { padding: 13px 30px; font-size: 17px; letter-spacing: .16em; text-transform: uppercase; }
.lx-cards { grid-column: 1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.lx-card { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 3px; text-align: left; padding: 16px 16px 15px; min-height: 118px; border-radius: 12px; border: 1px solid rgba(255,255,255,.1); color: #fff; background: rgba(10,16,24,.78); backdrop-filter: blur(10px); transition: transform .15s, border-color .15s; }
.lx-card::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--c, #2fd9ff); opacity: .85; }
.lx-card.plan { --c: #2fd9ff; } .lx-card.free { --c: #38e05a; } .lx-card.scen { --c: #ffb020; } .lx-card.wx { --c: #a78bff; }
.lx-card:hover { transform: translateY(-2px); border-color: var(--c); }
.lx-card-k { font-size: 11.5px; letter-spacing: .26em; text-transform: uppercase; color: var(--c); }
.lx-card-t { font-size: 21px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
.lx-card-d { font-size: 13.5px; color: #a9b8c6; line-height: 1.35; }
.lx-side { grid-column: 2; grid-row: 1 / span 2; align-self: end; min-height: 0; overflow-y: auto; }
.lx-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.lx-stat { background: rgba(255,255,255,.04); border-radius: 9px; padding: 9px 10px; }
.lx-stat b { display: block; font: 700 20px var(--mono); color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lx-stat span { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: #8fa0b0; }
.lx-signin p { color: #b3c1ce; font-size: 14px; line-height: 1.45; margin: 0 0 12px; }
.lx-signin .lx-btn { margin-right: 8px; }
.lx-flist { display: flex; flex-direction: column; gap: 6px; }
.lx-frow { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 9px 12px; border-radius: 9px; background: rgba(255,255,255,.035); border-left: 3px solid rgba(56,224,90,.7); }
.lx-frow.crashed { border-left-color: var(--red); } .lx-frow.aborted { border-left-color: #6b7785; } .lx-frow.diverted { border-left-color: var(--amber); }
.lx-froute { display: flex; align-items: center; gap: 7px; font-family: var(--mono); font-size: 15px; } .lx-froute i { color: #5f7080; font-style: normal; }
.lx-fmeta { display: flex; flex-wrap: wrap; gap: 4px 12px; color: #a9b8c6; font-size: 13.5px; min-width: 0; }
.lx-fnum { display: flex; gap: 12px; font-size: 13.5px; color: #dfe8f0; font-variant-numeric: tabular-nums; white-space: nowrap; }
.lx-fland { color: #7ee89a; } .lx-fland.hard { color: #ffb020; }
.lx-side .lx-frow { grid-template-columns: 1fr auto; } .lx-side .lx-fmeta { grid-column: 1 / -1; order: 3; }
/* hangar */
.lx-hangar { flex: 1; display: grid; grid-template-columns: 300px minmax(0, 1fr) 380px; min-height: 0; pointer-events: none; }
.lx-hangar > aside { pointer-events: auto; display: flex; flex-direction: column; gap: 10px; min-height: 0; padding: 16px; background: linear-gradient(90deg, rgba(4,7,11,.9), rgba(4,7,11,.7)); }
.lx-hangar > .hx-side { background: linear-gradient(270deg, rgba(4,7,11,.92), rgba(4,7,11,.72)); }
.hx-rows { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 3px; margin: 0 -6px; padding: 0 6px; }
.hx-grp { font-size: 11.5px; letter-spacing: .24em; text-transform: uppercase; color: #7fd9f2; padding: 12px 4px 4px; }
.hx-row { display: flex; align-items: center; gap: 10px; text-align: left; background: none; border: 1px solid transparent; border-radius: 9px; padding: 5px 8px; color: #dfe8f0; }
.hx-row:hover { background: rgba(255,255,255,.05); }
.hx-row.on { background: linear-gradient(90deg, rgba(47,217,255,.2), rgba(47,217,255,.04)); border-color: rgba(47,217,255,.45); }
.hx-pic { width: 64px; height: 40px; flex: none; display: grid; place-items: center; }
.hx-txt { min-width: 0; } .hx-txt b { display: block; font-size: 15.5px; } .hx-txt small { display: block; color: #8fa0b0; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hx-center { position: relative; display: flex; flex-direction: column; justify-content: space-between; padding: 20px 26px 16px; min-width: 0; }
.hx-name { text-shadow: 0 2px 18px rgba(0,0,0,.7); }
.hx-name small { display: block; font-size: 12.5px; letter-spacing: .3em; text-transform: uppercase; color: #7fd9f2; }
.hx-name b { display: block; font: 700 clamp(30px, 3.4vw, 48px)/1.05 'Barlow Semi Condensed', sans-serif; color: #fff; }
.hx-name span { color: #c3d0dc; font-size: 16px; }
.hx-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.hx-views { pointer-events: auto; display: flex; gap: 4px; background: rgba(4,7,11,.6); border: 1px solid rgba(255,255,255,.1); border-radius: 9px; padding: 3px; }
.hx-views button { background: none; border: 0; padding: 5px 11px; border-radius: 6px; color: #a9b8c6; font-size: 13px; }
.hx-views button:hover { background: rgba(255,255,255,.08); color: #fff; }
.hx-hint { color: #8fa0b0; font-size: 13px; text-shadow: 0 1px 6px #000; }
.hx-fallback { position: absolute; inset: 0; display: grid; place-items: center; opacity: .9; pointer-events: none; }
.hx-scroll { flex: 1; min-height: 0; margin: 0 -6px; padding: 0 6px; }
.hx-blurb { color: #c3d0dc; font-size: 14.5px; line-height: 1.5; }
.lv2-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.lv2 { position: relative; display: flex; flex-direction: column; gap: 5px; text-align: left; background: rgba(255,255,255,.035); border: 1px solid rgba(255,255,255,.08); border-radius: 9px; padding: 6px; color: #dfe8f0; font-size: 13px; }
.lv2:hover { border-color: rgba(255,255,255,.28); }
.lv2.on { border-color: var(--cyan); background: rgba(47,217,255,.12); box-shadow: inset 0 0 0 1px rgba(47,217,255,.4); }
.lv2-sw { height: 30px; border-radius: 5px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.25); }
.lv2-n { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lv2 .lv-x { position: absolute; top: 2px; right: 6px; }
/* flight setup */
.lx-flight { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 18px; padding: 18px 24px 16px; min-height: 0; }
.fx-col { min-height: 0; padding: 16px 18px; border-radius: 14px; background: rgba(8,12,18,.8); border: 1px solid rgba(255,255,255,.08); backdrop-filter: blur(10px); }
.fx-h { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: #fff; margin-bottom: 12px; }
.fx-h span { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: rgba(47,217,255,.18); color: #7fd9f2; font-size: 13px; letter-spacing: 0; }
.lx-flight .wz-opt, .lx-flight .wz-where, .lx-flight .wz-route, .lx-flight .set-group { background: rgba(255,255,255,.035); }
/* logbook */
.lx-logtop { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 14px; }
.lx-auth .lx-input { display: block; width: 100%; max-width: 420px; margin: 8px 0; }
/* add-ons */
.ad-list { display: flex; flex-direction: column; gap: 8px; margin: 12px 0; }
.ad-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 11px; background: rgba(10,15,22,.78); border: 1px solid rgba(255,255,255,.08); }
.ad-main { flex: 1; min-width: 0; } .ad-main b { font-size: 16px; } .ad-main small { display: block; color: #8fa0b0; font-size: 13px; }
.ad-err { color: #ff8a80; font-size: 13px; margin-top: 4px; }
.ad-pill { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; padding: 3px 10px; border-radius: 12px; border: 1px solid rgba(255,255,255,.2); color: #a9b8c6; white-space: nowrap; }
.ad-pill.ok { color: #7ee89a; border-color: rgba(56,224,90,.5); } .ad-pill.warn { color: #ffd28a; border-color: rgba(255,176,32,.5); } .ad-pill.bad { color: #ff8a80; border-color: rgba(255,59,48,.5); }
.mk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; margin: 14px 0; }
.mk-card { display: flex; flex-direction: column; text-align: left; padding: 0; overflow: hidden; border-radius: 12px; border: 1px solid rgba(255,255,255,.09); background: rgba(10,15,22,.82); color: #e9eff5; transition: transform .15s, border-color .15s; }
.mk-card:hover { transform: translateY(-2px); border-color: rgba(47,217,255,.6); }
.mk-cover { position: relative; height: 140px; background: linear-gradient(135deg, #1b3348, #0b141e) center / cover no-repeat; }
.mk-kind, .mk-inst { position: absolute; top: 8px; padding: 2px 9px; border-radius: 10px; font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; background: rgba(0,0,0,.6); }
.mk-kind { left: 8px; color: #7fd9f2; } .mk-inst { right: 8px; color: #7ee89a; }
.mk-body { display: flex; flex-direction: column; gap: 3px; padding: 11px 13px 13px; }
.mk-body b { font-size: 17px; } .mk-body small { color: #8fa0b0; font-size: 13px; }
.mk-sum { color: #b3c1ce; font-size: 13.5px; line-height: 1.35; min-height: 2.7em; }
.mk-price { margin-top: 4px; font-weight: 700; color: #fff; }
.mk-detail h2 { margin: 10px 0 2px; font-size: 30px; text-transform: uppercase; letter-spacing: .03em; }
.mk-hero { height: 240px; border-radius: 12px; margin-top: 8px; background: center / cover no-repeat; }
.mk-shots { display: flex; gap: 8px; overflow-x: auto; margin: 12px 0; }
.mk-shots img { height: 150px; border-radius: 8px; }
.mk-desc { white-space: pre-wrap; color: #c3d0dc; font-size: 15px; line-height: 1.55; max-width: 80ch; }
/* add-on utility panels (in flight) */
.addon-panel { position: fixed; z-index: 30; max-width: 92vw; max-height: 80vh; display: flex; flex-direction: column; border-radius: 10px; overflow: hidden; background: rgba(9,13,18,.95); border: 1px solid var(--line2); box-shadow: 0 16px 40px rgba(0,0,0,.5); font-family: var(--ui); }
.addon-panel .ap-head { display: flex; align-items: baseline; gap: 8px; padding: 8px 10px; background: var(--panel2); cursor: move; user-select: none; }
.addon-panel .ap-head b { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; } .addon-panel .ap-head small { color: var(--muted); font-size: 11px; flex: 1; }
.addon-panel .ap-head button { background: none; border: 0; color: var(--muted); }
.addon-panel .ap-body { padding: 10px 12px; overflow: auto; font-size: 14px; }
@media (max-width: 1100px) {
  .lx-hangar { grid-template-columns: 250px minmax(0, 1fr) 320px; }
  .lx-home { grid-template-columns: minmax(0, 1fr) 290px; } .lx-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .lx { grid-template-rows: auto minmax(0, 1fr) auto; }
  .lx-top { flex-wrap: wrap; padding: 8px 12px; gap: 8px; } .lx-nav { order: 3; width: 100%; height: 40px; } .lx-logo span { display: none; }
  .lx-home { display: flex; flex-direction: column; overflow-y: auto; padding: 16px; } .lx-side { align-self: stretch; }
  .lx-hangar { display: flex; flex-direction: column; overflow-y: auto; pointer-events: auto; } .hx-center { min-height: 46vh; }
  .lx-flight, .lx-logtop { grid-template-columns: 1fr; overflow-y: auto; }
  .lx-bar { flex-wrap: wrap; padding: 8px 12px; } .lx-acchip, .lx-ver { display: none; } .lx-route { max-width: none; flex: 1; }
}
.lx:not(.tab-home):not(.tab-hangar) .lx-bg { background: radial-gradient(80% 60% at 70% 30%, rgba(60,110,160,.18), rgba(0,0,0,0) 70%), linear-gradient(180deg, #09111a, #0b141e 60%, #080c11); }
.lx-logtop { align-items: start; }
.lx-chips button { white-space: nowrap; }
#b-addons { white-space: nowrap; }
.lx-card.world { --c: #ff6fd8; } .lx-cards { grid-template-columns: repeat(5, minmax(0, 1fr)); } @media (max-width: 1100px) { .lx-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* world airport picker (js/worldpicker.js) */
.wp { margin: 14px 0 12px; padding: 12px 14px; border-radius: 10px; background: rgba(255,255,255,.035); border: 1px solid rgba(255,255,255,.08); }
.wp-region { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.wp-k { font-size: 11.5px; letter-spacing: .22em; text-transform: uppercase; color: #7fd9f2; }
.wp-in { width: 100%; text-transform: none; letter-spacing: normal; font-family: var(--ui); font-size: 15px; padding: 9px 12px; }
.wp-res { display: flex; flex-direction: column; gap: 3px; margin-top: 6px; max-height: 260px; overflow-y: auto; }
.wp-row { display: grid; grid-template-columns: 52px 40px minmax(0, 1fr) auto; gap: 10px; align-items: center; text-align: left; background: none; border: 1px solid transparent; border-radius: 8px; padding: 6px 8px; color: #dfe8f0; }
.wp-row:hover { background: rgba(47,217,255,.1); border-color: rgba(47,217,255,.4); }
.wp-row b { font-family: var(--mono); } .wp-iata { color: #8fa0b0; font-family: var(--mono); font-size: 13px; }
.wp-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .wp-name small { display: block; color: #8fa0b0; font-size: 12px; }
.wp-go { font-size: 12px; color: #7fd9f2; white-space: nowrap; } .wp-row.here .wp-go { color: #7ee89a; }
.wp-busy { color: #8fa0b0; font-size: 14px; padding: 6px 2px; }
