/* PlayFPV - night-session UI. Palette + type tokens first; everything below reads them. */
:root {
  --ink: #0B0B14; --panel: #151522; --panel2: #1D1D2E; --line: #2B2B42;
  --text: #F3F2FF; --muted: #9C9AB8; --volt: #D4FF3A; --pink: #FF3D7F; --cyan: #3DD9FF;
  --warn: #FFB23D; --bad: #FF4D4D;
  --glass: rgba(11, 11, 20, .80); --glass-hi: rgba(21, 21, 34, .86);
  --f-display: "Bricolage Grotesque", "Space Grotesk", system-ui, sans-serif;
  --f-ui: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;
  --r-s: 10px; --r-m: 14px; --r-l: 22px;
  --snap: cubic-bezier(.2, .9, .25, 1.15); --t-fast: 120ms; --t-mid: 170ms;
  --rail: 224px; --gut: clamp(16px, 2.2vw, 32px);
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--ink); color: var(--text); overflow: hidden; }
body { font: 500 15px/1.45 var(--f-ui); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
::selection { background: var(--volt); color: var(--ink); }
:focus { outline: none; }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; border-radius: 8px; }
[tabindex="-1"]:focus, [tabindex="-1"]:focus-visible { outline: none; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
[hidden] { display: none !important; }
* { scrollbar-width: thin; scrollbar-color: var(--line) var(--panel2); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--panel2); border-radius: 10px; }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 10px; border: 2px solid var(--panel2); }
::-webkit-scrollbar-thumb:hover { background: #45456a; }

/* ---------------------------------------------------------------- layers */
#stage { position: fixed; inset: 0; z-index: 0; background: var(--ink); }
#ui { position: fixed; inset: 0; z-index: 10; pointer-events: none; }
#ui > * { pointer-events: auto; }
#ui > .hud-layer { pointer-events: none; }
.scr { position: absolute; inset: 0; animation: scr-in var(--t-mid) var(--snap) both; }
@keyframes scr-in { from { opacity: 0; transform: translateY(10px); } }
.noscript { position: fixed; inset: 0; display: grid; place-items: center; padding: 24px; text-align: center; z-index: 50; }

/* ---------------------------------------------------------------- type */
.display { font-family: var(--f-display); font-weight: 800; letter-spacing: -.035em; line-height: .86;
  font-variation-settings: "opsz" 96, "wdth" 100; transform: skewX(-7deg); transform-origin: 0 100%; margin: 0; text-transform: uppercase; }
.display .volt { color: var(--volt); }
.display .pink { color: var(--pink); }
.eyebrow { font: 700 12px/1 var(--f-ui); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.mono { font-family: var(--f-mono); font-weight: 700; font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
kbd { font: 700 11px/1 var(--f-mono); padding: 3px 6px 4px; border-radius: 6px; border: 1.5px solid var(--line);
  border-bottom-width: 3px; background: var(--panel2); color: var(--text); white-space: nowrap; }
a { color: var(--cyan); }
.ic { width: 20px; height: 20px; flex: none; display: block; }

/* ---------------------------------------------------------------- logo */
.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; }
.logo-mark { width: 38px; height: 38px; transform: rotate(-6deg); transition: transform var(--t-mid) var(--snap); }
.logo:hover .logo-mark { transform: rotate(-16deg) scale(1.05); }
.logo-word { font: 800 25px/1 var(--f-display); letter-spacing: -.04em; transform: skewX(-7deg); display: inline-block; }
.logo-word b { color: var(--volt); font-weight: 800; }
.logo-lg .logo-mark { width: 54px; height: 54px; }
.logo-lg .logo-word { font-size: 36px; }
.logo-sm .logo-mark { width: 28px; height: 28px; }
.logo-sm .logo-word { font-size: 19px; }

/* ---------------------------------------------------------------- buttons */
.btn { --bg: var(--volt); --fg: var(--ink); --sh: var(--pink);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; padding: 10px 20px;
  background: var(--bg); color: var(--fg); border: 2px solid var(--ink); border-radius: var(--r-m);
  box-shadow: 4px 4px 0 var(--sh); font: 700 15px/1 var(--f-ui); letter-spacing: .01em; text-decoration: none; white-space: nowrap;
  transition: transform var(--t-fast) var(--snap), box-shadow var(--t-fast) var(--snap), background var(--t-fast), color var(--t-fast);
  user-select: none; -webkit-tap-highlight-color: transparent; }
.btn:hover:not(:disabled) { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--sh); }
.btn:active:not(:disabled) { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--sh); transition-duration: 60ms; }
.btn:focus-visible { outline: 3px solid var(--cyan); outline-offset: 4px; border-radius: var(--r-m); }
.btn:disabled { opacity: .45; cursor: not-allowed; box-shadow: 2px 2px 0 var(--sh); }
.btn .ic { width: 20px; height: 20px; }
.btn-pink { --bg: var(--pink); --fg: var(--ink); --sh: var(--volt); }
.btn-cyan { --bg: var(--cyan); --fg: var(--ink); --sh: var(--pink); }
.btn-ghost { --bg: var(--panel2); --fg: var(--text); --sh: #000; border-color: var(--line); }
.btn-ghost:hover:not(:disabled) { border-color: var(--volt); }
.btn-quiet { background: none; border: 0; box-shadow: none; color: var(--muted); padding: 8px 10px; min-height: 36px; font-weight: 700; }
.btn-quiet:hover:not(:disabled), .btn-quiet:active:not(:disabled), .btn-quiet:disabled { color: var(--text); transform: none; box-shadow: none; }
.btn-quiet:disabled { color: #5f5d7c; opacity: 1; }
.btn-lg { min-height: 60px; padding: 14px 28px; font-size: 19px; border-radius: 16px; box-shadow: 5px 5px 0 var(--sh); }
.btn-lg:hover:not(:disabled) { box-shadow: 8px 8px 0 var(--sh); transform: translate(-3px, -3px); }
.btn-sm { min-height: 34px; padding: 7px 12px; font-size: 13px; border-radius: 11px; box-shadow: 3px 3px 0 var(--sh); }
.btn-block { width: 100%; }
.btn .spin { width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid currentColor; border-right-color: transparent; animation: spin .6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------------------------------------------------------------- stickers + chips */
.sticker { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px 6px; border: 2px solid var(--ink); border-radius: 9px;
  background: var(--pink); color: var(--ink); font: 700 12px/1 var(--f-ui); letter-spacing: .08em; text-transform: uppercase;
  transform: rotate(-3deg); box-shadow: 2px 2px 0 var(--ink); white-space: nowrap; }
.sticker.volt { background: var(--volt); }
.sticker.cyan { background: var(--cyan); }
.sticker.warn { background: var(--warn); }
.sticker.ink { background: var(--ink); color: var(--text); border-color: var(--line); box-shadow: 2px 2px 0 #000; }
.sticker.flat { transform: none; }
.sticker.r { transform: rotate(2.5deg); }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 999px; background: var(--panel2);
  border: 1.5px solid var(--line); font: 700 12px/1.2 var(--f-ui); color: var(--muted); white-space: nowrap; }
.chip b { color: var(--text); }
.rec { display: inline-flex; align-items: center; gap: 7px; font: 700 12px/1 var(--f-mono); letter-spacing: .12em; color: var(--text); }
.rec::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--bad); box-shadow: 0 0 10px var(--bad); animation: blink 1.1s steps(2, jump-none) infinite; }
@keyframes blink { 50% { opacity: .15; } }
.dots { display: inline-flex; gap: 3px; vertical-align: middle; }
.dots i { width: 8px; height: 8px; border-radius: 2px; background: var(--line); transform: skewX(-12deg); }
.dots i.on { background: var(--pink); }

/* ---------------------------------------------------------------- analog video texture + OSD brackets */
.vhs::before, .vhs::after { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.vhs::before { background: repeating-linear-gradient(to bottom, rgba(255,255,255,.035) 0 1px, transparent 1px 3px);
  mix-blend-mode: overlay; animation: roll 7s linear infinite; }
.vhs::after { opacity: .10; mix-blend-mode: overlay; animation: grain .5s steps(4) infinite;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
@keyframes roll { to { background-position: 0 90px; } }
@keyframes grain { 0% { transform: translate(0,0); } 25% { transform: translate(-3%,2%); } 50% { transform: translate(2%,-3%); } 75% { transform: translate(-1%,-1%); } }
.osd-corners { position: absolute; inset: 14px; pointer-events: none; z-index: 1; }
.osd-corners i { position: absolute; width: 34px; height: 34px; border: 3px solid rgba(243,242,255,.55); }
.osd-corners i:nth-child(1) { left: 0; top: 0; border-right: 0; border-bottom: 0; }
.osd-corners i:nth-child(2) { right: 0; top: 0; border-left: 0; border-bottom: 0; }
.osd-corners i:nth-child(3) { left: 0; bottom: 0; border-right: 0; border-top: 0; }
.osd-corners i:nth-child(4) { right: 0; bottom: 0; border-left: 0; border-top: 0; }

/* ---------------------------------------------------------------- landing */
.landing { display: grid; grid-template-rows: auto 1fr auto; padding: 26px calc(var(--gut) + 18px) 28px; overflow: hidden; }
.landing .shade { position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(11,11,20,.92) 0%, rgba(11,11,20,.66) 38%, rgba(11,11,20,.12) 70%, rgba(11,11,20,.05) 100%),
              linear-gradient(0deg, rgba(11,11,20,.92) 0%, rgba(11,11,20,0) 38%),
              radial-gradient(120% 90% at 50% 50%, transparent 55%, rgba(0,0,0,.55) 100%); }
.landing > .topbar, .landing > .hero, .landing > .props { position: relative; z-index: 2; }
.topbar { display: flex; align-items: center; gap: 14px; min-height: 48px; }
.topbar .sp { flex: 1; }
.hero { align-self: center; max-width: 900px; padding: 10px 0 18px; }
.hero .stickers { display: flex; gap: 10px; margin-bottom: clamp(12px, 2.4vh, 26px); flex-wrap: wrap; }
.hero h1 { font-size: clamp(50px, min(9vw, 11.6vh), 176px); }
.hero h1 span { display: block; }
.hero .tag { margin: clamp(14px, 2.6vh, 26px) 0 0; font: 700 clamp(17px, 1.5vw, 22px)/1.3 var(--f-ui); color: var(--text); max-width: 34ch; }
.hero .tag em { font-style: normal; color: var(--volt); }
.hero .ctas { display: flex; align-items: center; gap: 16px; margin-top: clamp(16px, 3vh, 32px); flex-wrap: wrap; }
.byo { display: flex; align-items: center; gap: 14px; margin-top: clamp(12px, 2.2vh, 22px); color: var(--muted); font-weight: 700; font-size: 14px; }
.byo .kit { display: inline-flex; gap: 6px; color: var(--text); }
.byo .kit span { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--panel2); border: 1.5px solid var(--line); }
.byo .kit .ic { width: 20px; height: 20px; }
.props { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; max-width: 1080px; }
.prop { position: relative; padding: 16px 18px 17px; border-radius: var(--r-l); background: var(--glass); border: 2px solid var(--line);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); transition: transform var(--t-fast) var(--snap), border-color var(--t-fast); }
.prop:hover { transform: translateY(-3px); border-color: var(--c, var(--volt)); }
.prop .n { font: 700 12px/1 var(--f-mono); color: var(--c, var(--volt)); letter-spacing: .1em; }
.prop h3 { margin: 8px 0 5px; font: 800 21px/1.05 var(--f-display); letter-spacing: -.02em; transform: skewX(-6deg); transform-origin: 0 100%; }
.prop p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.4; }
.osd-live { position: absolute; right: calc(var(--gut) + 30px); top: 50%; transform: translateY(-50%); z-index: 2; display: grid; gap: 8px; text-align: right;
  font: 700 13px/1 var(--f-mono); color: rgba(243,242,255,.85); text-shadow: 0 1px 2px #000; }
.osd-live b { color: var(--volt); font-weight: 700; }

/* ---------------------------------------------------------------- panels */
.glass { background: var(--glass); border: 2px solid var(--line); border-radius: var(--r-l); -webkit-backdrop-filter: blur(16px) saturate(1.15); backdrop-filter: blur(16px) saturate(1.15); }
.card { position: relative; background: var(--panel); border: 2px solid var(--line); border-radius: 18px; transition: transform var(--t-fast) var(--snap), border-color var(--t-fast), box-shadow var(--t-fast) var(--snap); }
button.card { text-align: left; padding: 0; width: 100%; color: inherit; display: block; }
button.card:hover { border-color: #45456a; transform: translate(-2px, -2px); box-shadow: 4px 4px 0 #000; }
.card.sel, button.card.sel:hover { border-color: var(--volt); box-shadow: 4px 4px 0 var(--volt); transform: translate(-2px, -2px); }
.card.sel .selmark { opacity: 1; transform: rotate(-8deg) scale(1); }
.selmark { position: absolute; top: 10px; right: 10px; width: 28px; height: 28px; border-radius: 9px; background: var(--volt); color: var(--ink);
  border: 2px solid var(--ink); display: grid; place-items: center; opacity: 0; transform: rotate(-8deg) scale(.6); transition: all var(--t-fast) var(--snap); z-index: 2; }
.selmark .ic { width: 16px; height: 16px; }

/* ---------------------------------------------------------------- auth */
.auth { display: grid; grid-template-rows: auto 1fr; padding: 26px calc(var(--gut) + 18px); }
.auth .shade { position: absolute; inset: 0; background: rgba(11,11,20,.62); pointer-events: none; }
.auth > * { position: relative; }
.auth-card { align-self: center; justify-self: center; width: min(470px, 100%); padding: 30px 32px 28px; position: relative; }
.auth-card h2 { font-size: 52px; margin: 14px 0 10px; }
.auth-card p.lede { margin: 0 0 22px; color: var(--muted); font-size: 15px; }
.auth-card p.lede b { color: var(--text); }
.auth-card .sticker { position: absolute; top: -14px; right: 22px; }
.field { display: grid; gap: 7px; margin-bottom: 16px; }
.field label { font: 700 12px/1 var(--f-ui); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.input { width: 100%; height: 54px; padding: 0 16px; border-radius: var(--r-m); background: var(--panel2); border: 2px solid var(--line);
  font: 700 18px/1 var(--f-ui); color: var(--text); transition: border-color var(--t-fast), box-shadow var(--t-fast); }
.input::placeholder { color: #5f5d7c; }
.input:focus { border-color: var(--volt); box-shadow: 3px 3px 0 var(--volt); }
.input:focus-visible, .code input:focus-visible { outline: none; }
.input.bad { border-color: var(--bad); box-shadow: 3px 3px 0 var(--bad); }
.msg { min-height: 20px; font-size: 13.5px; font-weight: 700; color: var(--bad); margin: 2px 0 10px; }
.msg.ok { color: var(--volt); }
.code { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; margin: 4px 0 8px; }
.code input { width: 100%; height: 70px; text-align: center; border-radius: var(--r-m); background: var(--panel2); border: 2px solid var(--line);
  font: 700 32px/1 var(--f-mono); color: var(--text); caret-color: var(--volt); transition: border-color var(--t-fast), transform var(--t-fast) var(--snap), box-shadow var(--t-fast); }
.code input:nth-child(3) { margin-right: 8px; }
.code input:focus { border-color: var(--volt); box-shadow: 3px 3px 0 var(--volt); transform: translate(-1px, -1px); }
.code input.filled { border-color: #5a5a86; }
.code.bad input { border-color: var(--bad); animation: shake .32s linear; }
.code.ok input { border-color: var(--volt); color: var(--volt); }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.devnote { border: 2px dashed var(--warn); border-radius: var(--r-m); padding: 11px 14px; margin: 0 0 16px; color: var(--warn); font-size: 13.5px; font-weight: 700;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; background: rgba(255,178,61,.06); }
.devnote .mono { font-size: 20px; letter-spacing: .18em; color: var(--text); }
.auth-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.auth-foot { margin-top: 18px; padding-top: 16px; border-top: 1.5px dashed var(--line); display: flex; justify-content: space-between; align-items: center; gap: 12px; color: var(--muted); font-size: 13.5px; }
.suggest { display: flex; gap: 8px; flex-wrap: wrap; margin: -4px 0 16px; }
.suggest button { border: 1.5px dashed var(--line); background: transparent; border-radius: 999px; padding: 6px 12px; font-weight: 700; font-size: 13px; color: var(--muted); transition: all var(--t-fast); }
.suggest button:hover { color: var(--ink); background: var(--cyan); border-color: var(--cyan); border-style: solid; }

/* ---------------------------------------------------------------- menu shell */
.menu { display: grid; grid-template-columns: var(--rail) minmax(0, var(--panel-w, 760px)) minmax(0, 1fr); gap: 18px; padding: 18px; }
.menu .shade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(90deg, rgba(11,11,20,.75) 0%, rgba(11,11,20,.35) 55%, rgba(11,11,20,0) 80%); }
.menu > * { position: relative; }
.rail { display: flex; flex-direction: column; gap: 6px; padding: 18px 14px 14px; min-height: 0; }
.rail .logo { padding: 0 6px 14px; }
.nav { display: grid; gap: 4px; }
.nav button { display: flex; align-items: center; gap: 12px; height: 48px; padding: 0 12px; border-radius: 13px; border: 2px solid transparent;
  background: transparent; color: var(--muted); font: 700 16px/1 var(--f-ui); text-align: left; transition: all var(--t-fast) var(--snap); position: relative; }
.nav button .k { margin-left: auto; font: 700 11px/1 var(--f-mono); color: #57557a; }
.nav button:hover { color: var(--text); background: var(--panel2); }
.nav button[aria-current="page"] { color: var(--ink); background: var(--volt); border-color: var(--ink); box-shadow: 3px 3px 0 var(--pink); transform: translate(-1px, -1px); }
.nav button[aria-current="page"] .k { color: rgba(11,11,20,.55); }
.rail .sp { flex: 1; }
.me { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 14px; background: var(--panel2); border: 2px solid var(--line); min-width: 0; }
.me .av { width: 36px; height: 36px; flex: none; border-radius: 11px; background: var(--pink); color: var(--ink); display: grid; place-items: center;
  font: 800 17px/1 var(--f-display); border: 2px solid var(--ink); transform: rotate(-4deg); }
.me .who { min-width: 0; flex: 1; }
.me .who b { display: block; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me .who span { display: block; font-size: 12px; color: var(--muted); }
.me.guest .av { background: var(--panel); color: var(--muted); border-color: var(--line); }
.rail-foot { display: flex; justify-content: space-between; align-items: center; padding: 10px 4px 0; font-size: 12px; color: #6a6890; }

.main { display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.main-head { display: flex; align-items: flex-end; gap: 14px; padding: 24px 28px 18px; border-bottom: 2px solid var(--line); flex: none; }
.main-head h2 { font-size: clamp(44px, 6.4vh, 64px); }
.main-head .sticker { margin-bottom: 8px; }
.main-head .sp { flex: 1; }
.main-body { flex: 1; min-height: 0; overflow: auto; padding: 22px 28px 28px; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.main-body::-webkit-scrollbar { width: 10px; }
.main-body::-webkit-scrollbar-thumb { background: var(--line); border-radius: 10px; border: 3px solid transparent; background-clip: padding-box; }
.main-foot { flex: none; display: flex; align-items: center; gap: 14px; padding: 16px 28px; border-top: 2px solid var(--line); background: rgba(21,21,34,.6); border-radius: 0 0 var(--r-l) var(--r-l); }
.main-foot .sp { flex: 1; }
.hint { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); font-weight: 700; align-items: center; }
.hint span { display: inline-flex; gap: 6px; align-items: center; }
.view-tag { align-self: end; justify-self: end; display: grid; gap: 8px; justify-items: end; padding: 0 12px 12px 0; text-shadow: 0 1px 3px #000; }
.view-tag .where { font: 800 26px/1 var(--f-display); transform: skewX(-7deg); letter-spacing: -.02em; }
.sec-h { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; }
.sec-h h3 { margin: 0; font: 700 12px/1 var(--f-ui); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.sec-h .line { flex: 1; height: 2px; background: var(--line); border-radius: 2px; }
.sec + .sec { margin-top: 26px; }

/* freestyle */
.maps { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.mapcard { overflow: hidden; }
.mapcard .art { height: 118px; position: relative; overflow: hidden; border-bottom: 2px solid var(--line);
  background: radial-gradient(120% 140% at 80% 0%, var(--c) 0%, transparent 60%), linear-gradient(160deg, var(--panel2), var(--ink)); }
.mapcard .art::before { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(-12deg, transparent 0 22px, rgba(255,255,255,.05) 22px 24px); }
.mapcard .art .big { position: absolute; left: 14px; bottom: -10px; font: 800 64px/1 var(--f-display); color: rgba(11,11,20,.55); letter-spacing: -.05em; transform: skewX(-8deg); text-transform: uppercase; white-space: nowrap; }
.mapcard .art .sticker { position: absolute; top: 12px; left: 12px; }
.mapcard .art.shot { background-size: cover; background-position: center; }
.mapcard .art.shot::before { background: linear-gradient(0deg, rgba(11,11,20,.7) 0%, rgba(11,11,20,0) 55%); }
.mapcard .art.shot .big { color: rgba(243,242,255,.9); font-size: 40px; bottom: 6px; text-shadow: 3px 3px 0 var(--ink); }
.mapcard .txt { padding: 13px 16px 16px; }
.mapcard h4 { margin: 0 0 4px; font: 800 22px/1.05 var(--f-display); letter-spacing: -.02em; transform: skewX(-6deg); transform-origin: 0 100%; }
.mapcard p { margin: 0; color: var(--muted); font-size: 13.5px; line-height: 1.4; }
.quick { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; }
.qbox { padding: 14px 16px; border-radius: 16px; background: var(--panel); border: 2px solid var(--line); display: grid; gap: 10px; align-content: start; }
.qbox .top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.qbox .val { font: 800 21px/1.1 var(--f-display); transform: skewX(-6deg); transform-origin: 0 100%; letter-spacing: -.02em; }
.qbox .sub { font-size: 13px; color: var(--muted); }
.swatch { display: inline-block; width: 12px; height: 12px; border-radius: 4px; border: 2px solid var(--ink); vertical-align: -1px; margin-right: 6px; background: var(--c); }

/* segmented + switches + sliders */
.seg { display: inline-flex; padding: 3px; border-radius: 13px; background: var(--ink); border: 2px solid var(--line); gap: 3px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; border-radius: 9px; padding: 8px 13px; min-height: 36px; font: 700 14px/1 var(--f-ui); color: var(--muted); transition: all var(--t-fast) var(--snap); white-space: nowrap; }
.seg button:hover { color: var(--text); background: var(--panel2); }
.seg button[aria-pressed="true"] { background: var(--volt); color: var(--ink); box-shadow: 2px 2px 0 var(--pink); }
.seg button small { display: block; font: 700 10.5px/1 var(--f-mono); margin-top: 4px; opacity: .7; }
.seg.full { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); width: 100%; }
.seg.full button { padding: 8px 4px; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.switch { position: relative; width: 58px; height: 32px; flex: none; border-radius: 999px; border: 2px solid var(--line); background: var(--ink); padding: 0; transition: background var(--t-fast), border-color var(--t-fast); }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--muted); transition: transform var(--t-fast) var(--snap), background var(--t-fast); }
.switch[aria-checked="true"] { background: var(--volt); border-color: var(--ink); box-shadow: 2px 2px 0 var(--pink); }
.switch[aria-checked="true"]::after { transform: translateX(26px); background: var(--ink); }
.range { display: flex; align-items: center; gap: 14px; width: 100%; }
.range output { min-width: 64px; text-align: right; font: 700 15px/1 var(--f-mono); color: var(--volt); }
input[type=range] { -webkit-appearance: none; appearance: none; flex: 1; height: 28px; background: transparent; margin: 0; cursor: pointer; }
input[type=range]::-webkit-slider-runnable-track { height: 8px; border-radius: 8px; background: linear-gradient(90deg, var(--volt) var(--p, 50%), var(--line) var(--p, 50%)); }
input[type=range]::-moz-range-track { height: 8px; border-radius: 8px; background: linear-gradient(90deg, var(--volt) var(--p, 50%), var(--line) var(--p, 50%)); }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; margin-top: -7px; border-radius: 7px; background: var(--text); border: 2px solid var(--ink); box-shadow: 2px 2px 0 var(--pink); transform: rotate(-8deg); }
input[type=range]::-moz-range-thumb { width: 18px; height: 18px; border-radius: 7px; background: var(--text); border: 2px solid var(--ink); box-shadow: 2px 2px 0 var(--pink); }
input[type=range]:focus-visible { outline: none; }
input[type=range]:focus-visible::-webkit-slider-thumb { outline: 3px solid var(--cyan); outline-offset: 2px; }

/* settings */
.set-tabs { margin-bottom: 18px; }
.rows { display: grid; }
.row { display: grid; grid-template-columns: minmax(150px, 210px) minmax(0, 1fr); gap: 18px; align-items: center; padding: 14px 0; border-bottom: 1.5px dashed var(--line); }
.row:last-child { border-bottom: 0; }
.row .lab b { display: block; font-size: 15px; }
.row .lab span { display: block; font-size: 12.5px; color: var(--muted); margin-top: 2px; line-height: 1.35; }
.row .ctl-wrap { display: grid; gap: 8px; min-width: 0; }
.row .explain { font-size: 13.5px; color: var(--muted); min-height: 19px; }
.row .explain b { color: var(--text); }
.row.stack { grid-template-columns: minmax(0, 1fr); gap: 10px; }
.row.inline .ctl-wrap { display: flex; align-items: center; gap: 12px; justify-content: space-between; }
.modes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.modes button { text-align: left; padding: 10px 12px 11px; border-radius: 13px; border: 2px solid var(--line); background: var(--panel); transition: all var(--t-fast) var(--snap); }
.modes button b { display: block; font: 800 18px/1.05 var(--f-display); transform: skewX(-6deg); transform-origin: 0 100%; letter-spacing: -.02em; }
.modes button span { display: block; font-size: 12px; color: var(--muted); margin-top: 4px; line-height: 1.3; }
.modes button:hover { border-color: #45456a; }
.modes button[aria-pressed="true"] { border-color: var(--volt); background: var(--volt); color: var(--ink); box-shadow: 3px 3px 0 var(--pink); transform: translate(-1px, -1px); }
.modes button[aria-pressed="true"] span { color: rgba(11,11,20,.72); }
.ctl-host { min-height: 200px; }

/* race */
.race { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 18px; align-items: start; }
.tracks { display: grid; gap: 10px; }
.card.trackcard { padding: 13px 15px 14px; }
.trackcard .l1 { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; padding-right: 30px; }
.trackcard h4 { margin: 0; font: 800 21px/1.05 var(--f-display); letter-spacing: -.02em; transform: skewX(-6deg); transform-origin: 0 100%; }
.trackcard .meta { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.trackcard .meta .dots { margin-left: auto; flex: none; }
.trackcard .l1 .dots { margin-left: auto; }
.trackcard .best { margin-top: 8px; font: 700 13px/1 var(--f-mono); color: var(--muted); }
.trackcard .best b { color: var(--volt); }
.detail { padding: 18px 18px 16px; border-radius: 18px; background: var(--panel); border: 2px solid var(--line); display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; min-width: 0; }
.detail .blurb { margin: 0; color: var(--muted); font-size: 14px; }
.stats3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stat { padding: 10px 12px; border-radius: 12px; background: var(--ink); border: 1.5px solid var(--line); }
.stat span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font: 700 10.5px/1 var(--f-ui); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.stat b { display: block; margin-top: 6px; font: 700 19px/1 var(--f-mono); white-space: nowrap; }
.stat b.volt { color: var(--volt); }
.board { width: 100%; border-collapse: collapse; font-size: 14px; table-layout: fixed; }
.board col.rk { width: 40px; } .board col.af { width: 44px; } .board col.t { width: 84px; }
.board th { text-align: left; font: 700 10.5px/1 var(--f-ui); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); padding: 0 8px 8px; }
.board td { padding: 7px 8px; border-top: 1.5px solid var(--line); white-space: nowrap; }
.board td.t { text-align: right; font: 700 14px/1 var(--f-mono); }
.board th.t { text-align: right; }
.board td.rk { font: 700 13px/1 var(--f-mono); color: var(--muted); }
.board td.nm { overflow: hidden; text-overflow: ellipsis; font-weight: 700; }
.board td.af { overflow: hidden; text-overflow: ellipsis; }
.board td.af { color: var(--muted); font-size: 12.5px; }
.board tr.p1 td.rk { color: var(--volt); } .board tr.p2 td.rk { color: var(--cyan); } .board tr.p3 td.rk { color: var(--pink); }
.board tr.mine td { background: rgba(212,255,58,.08); }
.board tr.mine td.nm::after { content: "YOU"; margin-left: 8px; font: 700 10px/1 var(--f-mono); padding: 2px 5px; border-radius: 5px; background: var(--volt); color: var(--ink); vertical-align: 1px; }
.empty { padding: 18px; border-radius: 14px; border: 2px dashed var(--line); text-align: center; color: var(--muted); font-size: 14px; }
.empty b { color: var(--text); display: block; font: 800 20px/1.1 var(--f-display); margin-bottom: 4px; transform: skewX(-6deg); }
.skel { height: 30px; border-radius: 8px; margin: 6px 0; background: linear-gradient(90deg, var(--panel2) 0%, var(--line) 50%, var(--panel2) 100%); background-size: 200% 100%; animation: shimmer 1s linear infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* hangar */
.hangar { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.afcard { overflow: hidden; display: flex; flex-direction: column; }
.afcard .band { height: 104px; position: relative; overflow: hidden; border-bottom: 2px solid var(--line);
  background: radial-gradient(90% 120% at 70% 110%, var(--c) 0%, transparent 62%), linear-gradient(160deg, var(--panel2), var(--ink)); }
.afcard .band .size { position: absolute; right: 10px; bottom: -18px; font: 800 96px/1 var(--f-display); letter-spacing: -.06em; color: rgba(243,242,255,.10); transform: skewX(-8deg); }
.afcard .band svg { position: absolute; left: 16px; top: 16px; width: 72px; height: 72px; color: var(--c); filter: drop-shadow(3px 3px 0 var(--ink)); }
.afcard .body { padding: 13px 15px 15px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.afcard .body > :last-child { margin-top: auto; }
.afcard .band.shot { background-size: cover; background-position: center; }
.afcard .band.shot svg { display: none; }
.afcard .band.shot .size { color: rgba(243,242,255,.16); }
.afcard h4 { margin: 0; font: 800 22px/1.05 var(--f-display); letter-spacing: -.02em; transform: skewX(-6deg); transform-origin: 0 100%; }
.afcard p { margin: 0; color: var(--muted); font-size: 13.5px; line-height: 1.4; min-height: 38px; }
.bars { display: grid; gap: 7px; }
.bar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 5px 8px; align-items: center; font-size: 12px; }
.bar i { grid-column: 1 / -1; }
.bar span { color: var(--muted); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; font-size: 10.5px; }
.bar i { height: 8px; border-radius: 8px; background: var(--line); position: relative; overflow: hidden; }
.bar i::after { content: ""; position: absolute; inset: 0; width: calc(var(--v) * 100%); background: var(--c, var(--volt)); border-radius: 8px; transition: width 300ms var(--snap); }
.bar em { font: 700 12px/1 var(--f-mono); font-style: normal; text-align: right; }
.fine { font: 700 11.5px/1.4 var(--f-mono); color: #7d7ba0; }

/* profile */
.prof { display: grid; grid-template-columns: auto 1fr; gap: 20px; align-items: center; padding: 20px; border-radius: 18px; background: var(--panel); border: 2px solid var(--line); }
.prof .av { width: 86px; height: 86px; border-radius: 22px; background: var(--pink); color: var(--ink); display: grid; place-items: center; font: 800 46px/1 var(--f-display); border: 3px solid var(--ink); box-shadow: 4px 4px 0 var(--volt); transform: rotate(-4deg); }
.prof h3 { margin: 0; font: 800 38px/1 var(--f-display); letter-spacing: -.03em; transform: skewX(-7deg); transform-origin: 0 100%; overflow-wrap: anywhere; }
.prof .em { color: var(--muted); font-size: 14px; margin-top: 6px; }
.prof .acts { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.edit-name { display: flex; gap: 10px; align-items: flex-start; margin-top: 12px; flex-wrap: wrap; }
.edit-name .input { width: 240px; height: 44px; font-size: 16px; }
.bests { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.bests .stat b { font-size: 20px; }
.bests .stat small { display: block; margin-top: 5px; color: var(--muted); font-size: 12px; }

/* ---------------------------------------------------------------- overlays: pause + results */
.overlay { position: absolute; inset: 0; display: grid; place-items: center; padding: 24px; background: rgba(11,11,20,.62);
  -webkit-backdrop-filter: blur(6px) saturate(.8); backdrop-filter: blur(6px) saturate(.8); animation: fade var(--t-mid) ease-out both; }
@keyframes fade { from { opacity: 0; } }
.sheet { width: min(600px, 100%); max-height: calc(100vh - 48px); display: flex; flex-direction: column; position: relative; animation: pop var(--t-mid) var(--snap) both; }
@keyframes pop { from { transform: translateY(14px) scale(.97); opacity: 0; } }
.sheet.wide { width: min(920px, 100%); }
.sheet-head { padding: 24px 26px 16px; display: flex; align-items: flex-end; gap: 14px; }
.sheet-head .seg { flex-wrap: nowrap; }
.sheet-head h2 { font-size: 62px; }
.sheet-head .sp { flex: 1; }
.sheet-body { padding: 0 26px 24px; overflow: auto; min-height: 0; }
.pause-actions { display: grid; gap: 12px; }
.pause-actions .btn { justify-content: space-between; min-height: 56px; font-size: 17px; }
.pause-actions .btn kbd { background: rgba(11,11,20,.14); border-color: rgba(11,11,20,.35); color: inherit; }
.pause-actions .btn-ghost kbd { background: var(--panel); border-color: var(--line); }
.pause-where { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; }
.res-top { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.bigtime { font: 700 clamp(52px, 8vh, 76px)/1 var(--f-mono); letter-spacing: -.04em; color: var(--volt); text-shadow: 4px 4px 0 var(--pink); margin: 4px 0 10px; font-variant-numeric: tabular-nums; }
.res-badges { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.laps { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; counter-reset: lap; }
.laps li { display: grid; grid-template-columns: 104px 1fr auto; gap: 10px; align-items: center; padding: 9px 12px; border-radius: 12px; background: var(--panel); border: 1.5px solid var(--line); font: 700 15px/1 var(--f-mono); }
.laps li .n { color: var(--muted); font-size: 12px; letter-spacing: .08em; }
.laps li .d { font-size: 12.5px; color: var(--muted); }
.laps li .d.neg { color: var(--volt); } .laps li .d.pos { color: var(--pink); }
.laps li.best { border-color: var(--volt); background: rgba(212,255,58,.07); }
.laps li.best .n::after { content: " BEST"; color: var(--volt); }
.res-actions { display: flex; gap: 14px; padding: 18px 26px 22px; border-top: 2px solid var(--line); align-items: center; }
.res-actions .sp { flex: 1; }
.res-note { font-size: 13.5px; color: var(--muted); font-weight: 700; }
.res-note.bad { color: var(--warn); }

/* ---------------------------------------------------------------- HUD layer: toasts, pill, lap feed */
.hud-layer { position: absolute; inset: 0; z-index: 30; }
.hud-layer > * { pointer-events: auto; }
.pill { position: absolute; top: 18px; right: 20px; display: inline-flex; align-items: center; gap: 8px; padding: 7px 13px 7px 11px; border-radius: 999px;
  background: var(--glass); border: 2px solid var(--line); font: 700 13px/1 var(--f-ui); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); transition: opacity var(--t-mid), transform var(--t-mid) var(--snap); }
.pill::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--volt); box-shadow: 0 0 0 3px rgba(212,255,58,.22); animation: pulse 1.8s ease-in-out infinite; }
.pill b { font-family: var(--f-mono); }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(212,255,58,0); } }
.pill.bump { transform: scale(1.08); }
.ui-flight .pill { top: calc(30% - 40px); bottom: auto; right: 16px; opacity: .8; font-size: 11.5px; padding: 5px 10px 5px 9px; }
.feed { position: absolute; bottom: 96px; right: 20px; display: grid; gap: 8px; justify-items: end; width: 320px; pointer-events: none; }
.ui-flight .feed { top: 30%; bottom: auto; right: 16px; }
.ui:has(.overlay:not(.loader)) .feed, .ui:has(.overlay:not(.loader)) .pill { opacity: 0; pointer-events: none; }
.feed .it { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 12px; background: var(--glass); border: 2px solid var(--line);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); font-size: 13px; font-weight: 700; max-width: 100%; animation: feed-in var(--t-mid) var(--snap) both; }
.feed .it.out { animation: feed-out 200ms ease-in both; }
.feed .it .ic { width: 16px; height: 16px; color: var(--volt); }
.feed .it .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 120px; }
.feed .it .tm { font-family: var(--f-mono); color: var(--volt); }
.feed .it .tr { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.feed .it.pb { border-color: var(--pink); }
@keyframes feed-in { from { transform: translateX(30px); opacity: 0; } }
@keyframes feed-out { to { transform: translateX(30px); opacity: 0; } }
.toasts { position: absolute; right: 20px; top: 64px; display: grid; gap: 10px; justify-items: end; width: min(440px, calc(100% - 32px)); pointer-events: none; }
.ui-flight .toasts { right: 50%; transform: translateX(50%); top: 18%; justify-items: center; }
.ui:has(.pill:not([hidden])) .topbar { padding-right: 150px; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 12px; padding: 12px 14px 12px 16px; border-radius: 14px; background: var(--panel2); border: 2px solid var(--ink);
  box-shadow: 4px 4px 0 var(--k, var(--cyan)); font-weight: 700; font-size: 14.5px; max-width: 100%; animation: toast-in var(--t-mid) var(--snap) both; }
.toast::before { content: ""; width: 10px; height: 10px; flex: none; border-radius: 3px; background: var(--k, var(--cyan)); transform: rotate(45deg); }
.toast.good { --k: var(--volt); } .toast.bad { --k: var(--bad); } .toast.warn { --k: var(--warn); } .toast.pink { --k: var(--pink); }
.toast button { border: 0; background: none; color: var(--muted); padding: 2px; margin-left: 4px; display: grid; }
.toast button:hover { color: var(--text); }
.toast button .ic { width: 16px; height: 16px; }
.toast.out { animation: toast-out 160ms ease-in both; }
@keyframes toast-in { from { transform: translateX(24px) scale(.96); opacity: 0; } }
@keyframes toast-out { to { transform: translateX(24px); opacity: 0; } }

/* ---------------------------------------------------------------- made-for-desktop note */
.mobile { position: absolute; inset: 0; display: grid; place-items: center; padding: 24px; z-index: 40; background: rgba(11,11,20,.9); }
.mobile .glass { padding: 28px 24px; max-width: 420px; text-align: center; display: grid; gap: 14px; justify-items: center; }
.mobile h2 { font-size: 46px; }
.mobile p { margin: 0; color: var(--muted); }
.mobile .ic { width: 44px; height: 44px; color: var(--volt); }

/* ---------------------------------------------------------------- flight mode: UI gets out of the way */
.ui-flight .scr:not(.overlay) { display: none; }

/* ---------------------------------------------------------------- responsive (desktop-first; 1280x720 is the floor we design to) */
@media (max-width: 1440px) { :root { --rail: 206px; } .menu { --panel-w: 700px; } }
@media (max-height: 800px) {
  .main-head { padding: 18px 24px 14px; } .main-body { padding: 18px 24px 22px; } .main-foot { padding: 12px 24px; }
  .mapcard .art { height: 96px; } .afcard .band { height: 84px; } .afcard .band svg { width: 58px; height: 58px; top: 13px; }
  .prop { padding: 13px 16px 14px; } .prop h3 { font-size: 19px; } .prop p { font-size: 13px; }
  .sheet-head h2 { font-size: 52px; } .row { padding: 11px 0; }
}
@media (max-width: 1180px) { .menu { grid-template-columns: var(--rail) minmax(0, 1fr); } .view-tag { display: none; } .osd-live { display: none; } }
@media (max-width: 980px) { .race, .res-top { grid-template-columns: 1fr; } .hangar { grid-template-columns: 1fr; } .modes { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 760px) {
  .props { grid-template-columns: 1fr; }
  .menu { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); gap: 10px; padding: 10px; }
  .rail { flex-direction: row; align-items: center; gap: 6px; padding: 6px 8px; overflow-x: auto; overflow-y: hidden; }
  .rail > .btn-quiet { flex: none; }
  .rail .logo { padding: 0 4px 0 2px; }
  .rail .logo-word, .rail .sp, .rail-foot { display: none; }
  .nav { grid-auto-flow: column; grid-auto-columns: max-content; gap: 2px; }
  .nav button { height: 42px; padding: 0 9px; gap: 5px; font-size: 0; }
  .nav button .k { font-size: 11px; margin-left: 0; }
  .me { flex: none; padding: 4px; margin-left: auto; }
  .me .who { display: none; }
  .me .av { width: 32px; height: 32px; }
  .main-head { padding: 14px 16px 12px; }
  .main-head .sticker { display: none; }
  .main-body { padding: 14px 16px 18px; }
  .main-foot { flex-wrap: wrap; padding: 12px 16px; gap: 10px; }
  .main-foot .hint, .main-foot .res-note { flex: 1 1 100%; }
  .main-foot .sp { display: none; }
  .main-foot .btn { flex: 1 1 100%; min-width: 0; white-space: normal; text-align: center; }
  .quick { grid-template-columns: minmax(0, 1fr); }
  .row { grid-template-columns: minmax(0, 1fr); gap: 8px; }
}
@media (max-height: 520px) and (min-width: 761px) {
  .rail { overflow-y: auto; padding: 10px; gap: 4px; }
  .rail .logo { padding-bottom: 6px; }
  .nav button { height: 38px; }
  .rail-foot { display: none; }
  .me .who span { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
}
.afcard .btn-sm .ic { width: 16px; height: 16px; }
@media (max-width: 480px) { .nav button { padding: 0 9px; gap: 0; } .nav button .k { display: none; } .rail .logo-mark { width: 30px; height: 30px; } }

/* first-flights controls legend (js/ui/legend.js): names the controls for the device in hand until ~20 s flown */
.flight-legend { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); z-index: 2; pointer-events: none;
  display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border-radius: 12px; background: rgba(11,11,20,.62);
  border: 1.5px solid var(--line); color: var(--text); font: 500 12.5px/1.2 var(--f-ui); backdrop-filter: blur(4px);
  transition: opacity .18s ease; max-width: 44vw; }
.flight-legend b { font: 700 10.5px/1 var(--f-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--volt); }
.flight-legend span { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.flight-legend kbd { min-width: 26px; text-align: center; }
.flight-legend.out { opacity: 0; }
@media (max-width: 640px), (max-height: 420px) { .flight-legend { font-size: 11px; gap: 4px; padding: 8px 10px; } }
.flight-legend kbd { letter-spacing: .12em; }

