:root {
  --bg: #0b0c0f;
  --panel: #121318;
  --panel2: #17181e;
  --line: #25272e;
  --text: #dde1e8;
  --dim: #82878f;
  --accent: #22d3ee;   /* player / lap A */
  --ref: #fb923c;      /* reference / lap B */
  --green: #34d399;
  --red: #f87171;
  --yellow: #fbbf24;
  --f1red: #e10600;    /* chrome accent, never a data color */
  --card: linear-gradient(180deg, rgba(25,26,32,.92), rgba(14,15,18,.9));
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background: var(--bg); color: var(--text);
  font: 14px/1.45 "Titillium Web", -apple-system, "Segoe UI", Roboto, sans-serif;
  /* Titillium has no 900-italic face; never synthesize (it clips glyphs) */
  font-synthesis: none;
  display: flex; flex-direction: column; overflow: hidden;
}

/* ---------- header ---------- */
header {
  display: flex; align-items: center; gap: 14px;
  padding: 9px 16px; border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #16171c, #101114);
}
.brand {
  font-weight: 700; font-style: italic; font-size: 19px;
  letter-spacing: .5px; display: flex; align-items: center; gap: 6px;
}
.brand b {
  background: var(--f1red); color: #fff; font-weight: 700;
  padding: 0 7px 1px 6px; border-radius: 5px;
  transform: skewX(-8deg); display: inline-block;
}
.brand span { color: var(--text); letter-spacing: 2px; }
.spacer { flex: 1; }
.chip {
  font-size: 11px; font-weight: 700; letter-spacing: 1px;
  padding: 3px 10px; border-radius: 999px;
}
.chip.live { background: #052e1f; color: var(--green); }
.chip.live::before { content: "● "; animation: blink 1.2s infinite; }
.chip.idle { background: #1d2230; color: var(--dim); }
.chip.warn { background: #3a2410; color: var(--yellow); }
@keyframes blink { 50% { opacity: .3; } }
#status-detail { color: var(--dim); font-size: 12px; }
/* ---------- themed dropdowns (native select stays hidden inside) ---------- */
.dd { position: relative; display: inline-block; }
.dd select { display: none; }
.dd-btn {
  display: flex; align-items: center; gap: 10px; max-width: 360px;
  background: var(--panel2); color: var(--text);
  border: 1px solid var(--line); border-radius: 6px; padding: 6px 11px;
  font-family: inherit; font-size: 12px; font-weight: 600; cursor: pointer;
}
.dd-btn span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dd-btn:hover { border-color: var(--accent); }
.dd-arr {
  color: var(--f1red); font-style: normal; font-size: 9px;
  transition: transform .15s;
}
.dd.open .dd-arr { transform: rotate(180deg); }
.dd-menu {
  display: none; position: absolute; top: calc(100% + 6px); right: 0;
  min-width: 100%; z-index: 60; padding: 5px;
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,.022) 0 2px, transparent 2px 5px),
    linear-gradient(168deg, rgba(40,48,64,.97), rgba(10,12,17,.99) 58%);
  border: 1px solid #2c3444;
  border-radius: 3px 12px 3px 12px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 14px 34px rgba(0,0,0,.6);
  white-space: nowrap;
}
.dd-menu::before {
  content: ""; position: absolute; left: 0; top: 0; height: 2px; width: 62%;
  background: linear-gradient(90deg, var(--f1red), rgba(225,6,0,0));
}
.dd.open .dd-menu { display: block; }
.dd-item {
  padding: 6px 12px; font-size: 12px; color: var(--text);
  border-radius: 4px; cursor: pointer;
}
.dd-item:hover { background: #1b2330; color: var(--accent); }
.dd-item.sel {
  color: var(--accent); font-weight: 700;
  border-left: 3px solid var(--f1red); border-radius: 0 4px 4px 0;
}

/* ---------- layout ---------- */
#layout { flex: 1; display: flex; min-height: 0; }
#sidebar {
  width: 275px; flex: none; border-right: 1px solid var(--line);
  background: var(--panel); display: flex; flex-direction: column; min-height: 0;
}
.side-head {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 8px;
  padding: 10px 12px 6px; font-size: 11px; font-weight: 700;
  letter-spacing: 1px; color: var(--dim);
}
.hint { font-weight: 400; letter-spacing: 0; font-size: 10px; flex: 1; }
#side-toggle {
  background: #14202b; border: 1px solid #2c4a56; color: var(--accent);
  font-family: inherit; font-size: 13px; font-weight: 700;
  border-radius: 5px; padding: 1px 10px; cursor: pointer; line-height: 1.4;
}
#side-toggle:hover { border-color: var(--accent); background: #123a44; }
#side-rail {
  display: none; cursor: pointer; align-items: center;
  flex-direction: column; gap: 10px; padding-top: 10px; height: 100%;
}
#side-rail .rail-arrow {
  font-size: 13px; font-weight: 700; color: var(--dim);
  border: 1px solid var(--line); border-radius: 5px; padding: 0 6px 2px;
}
#side-rail b {
  writing-mode: vertical-rl; font-size: 10px; font-weight: 700;
  font-style: italic; letter-spacing: 2px; color: var(--dim);
}
#side-rail:hover .rail-arrow, #side-rail:hover b { color: var(--accent); }
#sidebar.collapsed { width: 32px; }
#sidebar.collapsed > :not(#side-rail) { display: none; }
#sidebar.collapsed #side-rail { display: flex; }
#lap-controls {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  padding: 0 10px 8px; border-bottom: 1px solid var(--line);
}
.seg.small button { padding: 4px 8px; font-size: 9px; letter-spacing: 1px; }
.toggle {
  background: none; border: 1px solid var(--line); color: var(--dim);
  font-family: inherit; font-size: 9px; font-weight: 700; font-style: italic;
  letter-spacing: 1px; border-radius: 7px; padding: 5px 9px; cursor: pointer;
}
.toggle:hover { border-color: var(--dim); }
.toggle.on { background: #123a44; border-color: var(--accent); color: var(--accent); }
#lap-list { overflow-y: auto; flex: 1; }
#list-foot {
  flex: none; border-top: 1px solid var(--line); padding: 5px 12px;
  text-align: right;
}
#list-foot button {
  background: none; border: none; color: #58627a; cursor: pointer;
  font-family: inherit; font-size: 10px; letter-spacing: .4px;
}
#list-foot button:hover { color: #f87171; }
.lap-row .rank {
  flex: none; width: 16px; text-align: right; font-size: 10px;
  font-weight: 800; font-style: italic; color: var(--dim);
}
.lap-row .gap { font-size: 10px; font-weight: 600; color: var(--dim); }
.sess-head {
  position: sticky; top: 0; z-index: 1;
  padding: 6px 12px 4px; font-size: 10px; font-weight: 700;
  letter-spacing: .8px; color: var(--dim); text-transform: uppercase;
  background: var(--panel); border-bottom: 1px solid var(--line);
  cursor: pointer; user-select: none;
}
.sess-head:hover { color: var(--text); }
.sess-head .tri { margin-right: 5px; color: #4d5a70; }
.lap-row {
  display: flex; align-items: center; gap: 8px;
  padding: 7px 10px; cursor: pointer; border-bottom: 1px solid #161b26;
}
.lap-row:hover { background: var(--panel2); }
.lap-row.sel { background: #0c2b33; box-shadow: inset 3px 0 0 var(--accent); }
.lap-row.ref-sel { box-shadow: inset -3px 0 0 var(--ref); }
.lap-row.sel.ref-sel { box-shadow: inset 3px 0 0 var(--accent), inset -3px 0 0 var(--ref); }
.badge {
  font-size: 9px; font-weight: 900; padding: 2px 6px; border-radius: 3px;
  letter-spacing: 1px; flex: none; transform: skewX(-8deg);
}
.badge.player { background: #123a44; color: var(--accent); }
.badge.rival  { background: #3a2410; color: var(--ref); }
.badge.pb_ghost { background: #262c3a; color: #9aa7bd; }
.badge.guest { background: #2a2140; color: #b7a4f5; }   /* imported lap */
.lap-main { flex: 1; min-width: 0; }
.lap-time { font-weight: 700; font-variant-numeric: tabular-nums; }
.lap-sub { font-size: 11px; color: var(--dim); font-variant-numeric: tabular-nums; }
.lap-row .inv { color: var(--red); font-size: 10px; font-weight: 700; }
.lap-row .pb {
  color: var(--green); font-size: 9px; font-weight: 800; letter-spacing: 1px;
  margin-left: 3px;
}
.refbtn {
  background: none; border: 1px solid #333947; color: #566075;
  font-family: inherit; font-size: 10px; font-weight: 800; font-style: italic;
  letter-spacing: 1px; border-radius: 4px; padding: 4px 16px; cursor: pointer;
  flex: none;
}
.refbtn:hover { border-color: var(--ref); color: var(--ref); }
.refbtn.on { background: var(--ref); border-color: var(--ref); color: #1b0f02; }
.del {
  background: none; border: none; color: #3d4657; font-size: 13px;
  cursor: pointer; padding: 2px 2px; visibility: hidden;
}
.lap-row:hover .del { visibility: visible; }
.del:hover { color: var(--red); }
.empty-list { padding: 18px 14px; color: var(--dim); font-size: 12px; }

/* full-window target shown while a file is dragged over the app */
#drop-veil {
  position: fixed; inset: 0; z-index: 60;
  display: flex; align-items: center; justify-content: center;
  background: rgba(11, 12, 15, .78);
  pointer-events: none;   /* keep drag events flowing to the window */
}
#drop-veil div {
  border: 2px dashed var(--accent); color: var(--accent);
  border-radius: 12px; padding: 26px 48px;
  font-size: 18px; font-weight: 700; font-style: italic; letter-spacing: 3px;
}

/* ---------- main / stage ---------- */
#main { flex: 1; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
#stage {
  position: relative; flex: 1; min-height: 220px;
  /* faint carbon-fibre weave */
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,.015) 0 2px, transparent 2px 5px),
    repeating-linear-gradient(-45deg, rgba(255,255,255,.015) 0 2px, transparent 2px 5px);
}
#map { position: absolute; inset: 0; width: 100%; height: 100%; }
#map-legend {
  position: absolute; left: 12px; top: 10px; font-size: 11px;
  color: var(--dim); display: flex; gap: 14px;
}
#map-legend .k::before {
  content: "●"; margin-right: 4px;
}
#map-legend .kA::before { color: var(--accent); }
#map-legend .kB::before { color: var(--ref); }

/* ---------- map toolbar ---------- */
#map-toolbar {
  position: absolute; left: 12px; right: 12px; bottom: 12px; display: flex;
  align-items: center; gap: 12px; pointer-events: none;
}
#map-toolbar > * { pointer-events: auto; }
.seg {
  display: flex; background: var(--card); border: 1px solid var(--line);
  border-radius: 7px; overflow: hidden;
}
.seg button {
  background: none; border: none; color: var(--dim); cursor: pointer;
  font-family: inherit; font-size: 10px; font-weight: 700; font-style: italic;
  letter-spacing: 1.5px; padding: 6px 14px;
}
.seg button.on { background: var(--f1red); color: #fff; }
.seg button:disabled { opacity: .35; cursor: default; }
#color-legend {
  display: flex; align-items: center; gap: 7px;
  background: var(--card); border: 1px solid var(--line); border-radius: 7px;
  padding: 5px 10px;
  font-size: 10px; color: var(--dim); font-variant-numeric: tabular-nums;
}
#leg-title {
  font-size: 9px; font-weight: 700; font-style: italic; letter-spacing: 1.5px;
  color: var(--text); border-left: 3px solid var(--f1red);
  padding-left: 6px; margin-right: 3px;
}
#leg-lo, #leg-hi { font-weight: 700; letter-spacing: .5px; }
#leg-bar {
  width: 84px; height: 7px; border-radius: 4px;
  outline: 1px solid rgba(219,226,238,.18);
}
#zoom-chip {
  display: flex; align-items: center; gap: 8px;
  background: var(--card); border: 1px solid var(--line); border-radius: 7px;
  padding: 5px 10px; font-size: 10px; font-weight: 700;
  color: var(--accent); font-variant-numeric: tabular-nums;
}
#zoom-chip button {
  background: none; border: 1px solid #333947; color: var(--dim);
  font-family: inherit; font-size: 9px; font-weight: 800; font-style: italic;
  letter-spacing: 1px; border-radius: 4px; padding: 2px 7px; cursor: pointer;
}
#zoom-chip button:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- broadcast cards (telemetry / timing / setup) ----------
   Shared look: carbon weave over a steep dark gradient, asymmetric
   corners, a red racing stripe fading out along the top edge. */
#hud, #sector-card, #setup-card {
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,.022) 0 2px, transparent 2px 5px),
    linear-gradient(168deg, rgba(40,48,64,.88), rgba(10,12,17,.95) 58%);
  border: 1px solid #2c3444;
  border-radius: 3px 14px 3px 14px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 10px 32px rgba(0,0,0,.55);
}
#hud::before, #sector-card::before, #setup-card::before {
  content: ""; position: absolute; left: 0; top: 0; height: 2px; width: 62%;
  background: linear-gradient(90deg, var(--f1red), rgba(225,6,0,0));
  border-radius: 3px 0 0 0;
}

/* ---------- broadcast card tags ---------- */
.card-tag {
  position: absolute; top: -8px; left: 12px;
  background: var(--f1red); color: #fff;
  font-size: 8px; font-weight: 700; font-style: italic;
  letter-spacing: 1.5px; padding: 2px 9px; border-radius: 3px;
  transform: skewX(-12deg);
}

/* ---------- sector card ---------- */
#sector-card {
  position: absolute; right: 14px; top: 10px;
  padding: 8px 12px;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  font-size: 12px; font-variant-numeric: tabular-nums;
}
/* every red card tag is clickable: TIMING and TELEMETRY fold in place
   (▾/▸), SETUP closes (it reopens from the toolbar button) */
#sector-card .card-tag, #hud .card-tag, #setup-card .card-tag { cursor: pointer; }
#sector-card .card-tag:hover, #hud .card-tag:hover,
#setup-card .card-tag:hover { filter: brightness(1.25); }
/* folded: the card reduces to its floating TIMING tag, same spot */
#sector-card.closed {
  width: 96px; height: 8px; padding: 0;
  background: none; border: none; box-shadow: none;
  backdrop-filter: none; -webkit-backdrop-filter: none;
}
#sector-card.closed::before { display: none; }
#sector-card table { border-collapse: collapse; }
#sector-card th {
  font-size: 9px; font-weight: 800; letter-spacing: 1px; color: var(--dim);
  padding: 2px 10px 3px 0; text-align: right;
}
#sector-card th.s1 { color: #f87171; }
#sector-card th.s2 { color: #60a5fa; }
#sector-card th.s3 { color: #fbbf24; }
#sector-card td {
  padding: 2px 10px 2px 0; text-align: right; color: var(--text);
}
#sector-card td.rowlbl {
  font-size: 9px; font-weight: 800; letter-spacing: 1px; color: var(--dim);
  text-align: left; padding-right: 8px;
}
#sector-card td.neg { color: var(--green); }
#sector-card td.pos { color: var(--red); }
#sector-card td.laptime { font-weight: 700; }

/* ---------- setup / assists card ---------- */
#setup-card {
  position: absolute; left: 14px; top: 34px; z-index: 6;
  /* no inner scroll and no backdrop-filter: Chromium paints a composited
     scrollable overlay above the canvas with a white backing store */
  padding: 10px 12px 8px;
  font-size: 11px; font-variant-numeric: tabular-nums;
}
#setup-card table { border-collapse: collapse; }
#setup-card th {
  font-size: 9px; font-weight: 800; letter-spacing: 1px;
  padding: 2px 10px 3px 0; text-align: right;
}
#setup-card th.cA { color: var(--accent); }
#setup-card th.cB { color: var(--ref); }
#setup-card td { padding: 1px 10px 1px 0; text-align: right; color: var(--text); }
#setup-card td.rowlbl {
  color: var(--dim); text-align: left; padding-right: 12px; font-size: 10px;
}
#setup-card td.grp {
  font-size: 9px; font-weight: 800; letter-spacing: 1px; color: #5b6576;
  text-align: left; text-transform: uppercase; padding-top: 7px; max-width: 240px;
}
#setup-card td.asst-cell {
  max-width: 150px; white-space: normal; font-size: 10px; line-height: 1.5;
}

/* ---------- halo hud (floating card, wheel above the dial) ---------- */
#hud {
  position: absolute; right: 14px; bottom: 12px; width: 255px;
  cursor: grab;
  padding: 12px 14px 8px;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  touch-action: none; user-select: none;
}
#hud.drag { cursor: grabbing; }
#hud-drag {
  position: absolute; top: -8px; right: 64px; z-index: 1;
  background: var(--card); border: 1px solid var(--line); color: var(--dim);
  font-size: 8px; font-weight: 700; font-style: italic;
  letter-spacing: 1.5px; padding: 2px 9px; border-radius: 3px;
  transform: skewX(-12deg); cursor: grab;
}
#hud:hover #hud-drag, #hud.drag #hud-drag {
  border-color: var(--accent); color: var(--accent);
}
#hud.drag #hud-drag { cursor: grabbing; }
#hud-steer-btn {
  position: absolute; top: -8px; right: 12px; z-index: 1;
  background: var(--card); border: 1px solid var(--line); color: var(--dim);
  font-family: inherit; font-size: 8px; font-weight: 700; font-style: italic;
  letter-spacing: 1.5px; padding: 2px 9px; border-radius: 3px;
  transform: skewX(-12deg); cursor: pointer;
}
#hud-steer-btn.on { border-color: var(--accent); color: var(--accent); }
/* folded: like the TIMING card, only the floating tag remains */
#hud.closed {
  width: 122px; height: 8px; padding: 0;
  background: none; border: none; box-shadow: none;
  backdrop-filter: none; -webkit-backdrop-filter: none;
  cursor: default;
}
#hud.closed::before { display: none; }
#hud.closed #halo, #hud.closed #hud-delta,
#hud.closed #hud-drag, #hud.closed #hud-steer-btn { display: none; }
#halo { width: 100%; display: block; }
.arc-bg { fill: none; stroke: #222a39; stroke-width: 11; stroke-linecap: round; }
.arc { fill: none; stroke-width: 11; stroke-linecap: round; }
.arc.thr { stroke: var(--green); filter: drop-shadow(0 0 4px rgba(52,211,153,.5)); }
.arc.brk { stroke: var(--red); filter: drop-shadow(0 0 4px rgba(248,113,113,.5)); }
.arc-tick { stroke: #2e3748; stroke-width: 2; }
.pill.on-x { fill: #064e3b; stroke: #10b981; }
.speed {
  /* upright face + skewX on the element (see index.html): font-level italic
     ink overhangs its tabular advance box and some rasterizers clip it,
     shaving the right edge of the last digit */
  fill: var(--text); font-size: 56px; font-weight: 700;
  font-family: "Titillium Web", sans-serif;
  text-anchor: middle; font-variant-numeric: tabular-nums;
}
.unit { fill: var(--dim); font-size: 10px; text-anchor: middle; letter-spacing: 3px; }
.gear-badge { fill: #171d29; stroke: #2a3242; }
.gear { fill: var(--yellow); font-size: 19px; font-weight: 800; text-anchor: middle; }
.lbl { fill: #5b6576; font-size: 9px; text-anchor: middle; letter-spacing: 2px; font-weight: 700; }
.pill { fill: #171d29; stroke: #2a3242; }
.pill.on-ot { fill: #3b0764; stroke: #a855f7; }
.pill-txt { fill: #5b6576; font-size: 10px; font-weight: 800; text-anchor: middle; letter-spacing: 1px; }
.wheel-grip {
  fill: none; stroke: #3d4452; stroke-width: 17; stroke-linecap: round;
}
.wheel-gripline line { stroke: #2b3039; stroke-width: 2; stroke-linecap: round; }
.wheel-arm line { stroke: #333947; stroke-width: 9; stroke-linecap: round; }
.wheel-plate { fill: #282d38; stroke: #191d25; stroke-width: 1.5; }
.wheel-screen { fill: #0c0f14; stroke: #454d5c; stroke-width: 1.5; }
.wheel-led circle { fill: #3a4150; }
.wheel-rotary circle { fill: #3d4452; stroke: #1d2129; stroke-width: 1.5; }
.wheel-rotary line { stroke: #b7bfcc; stroke-width: 1.8; stroke-linecap: round; }
.wheel-marker { fill: var(--accent); }
.steer-val {
  fill: var(--text); font-size: 15px; font-weight: 700;
  text-anchor: middle; font-variant-numeric: tabular-nums;
}
.rev-seg { fill: #1c2331; }
.hud-delta {
  text-align: center; font-size: 19px; font-weight: 800;
  font-variant-numeric: tabular-nums; margin-top: 2px;
}
.hud-delta.pos { color: var(--red); }
.hud-delta.neg { color: var(--green); }

/* ---------- transport ---------- */
#transport {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 14px; border-top: 1px solid var(--line); background: var(--panel);
}
#btn-play {
  width: 34px; height: 30px; border-radius: 6px; border: 1px solid var(--line);
  background: var(--panel2); color: var(--text); font-size: 14px; cursor: pointer;
}
#btn-play:hover { border-color: var(--accent); }
#transport .dd { width: 58px; flex: none; }
#transport .dd-btn {
  width: 100%; padding: 6px 7px; gap: 3px; justify-content: space-between;
}
#scrub {
  flex: 1; -webkit-appearance: none; appearance: none;
  height: 7px; border-radius: 4px; background: #1c2331; outline: none;
}
#scrub::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 15px; height: 15px; border-radius: 50%;
  background: var(--text); border: 3px solid var(--accent);
  cursor: pointer; box-shadow: 0 1px 6px rgba(0,0,0,.6);
}
#time-display {
  flex: none; width: 70px; text-align: right;
  font-variant-numeric: tabular-nums; font-weight: 700; font-style: italic;
  font-size: 15px;
}

/* ---------- charts ---------- */
#splitter {
  flex: none; height: 8px; cursor: row-resize; position: relative;
  background: var(--panel); border-top: 1px solid var(--line);
  touch-action: none;
}
#splitter::after {
  content: ""; position: absolute; left: 50%; top: 3px;
  width: 46px; height: 3px; transform: translateX(-50%);
  border-radius: 2px; background: #2a3242;
}
#splitter:hover::after, #splitter.drag::after { background: var(--accent); }
#charts {
  flex: none; height: 40%; min-height: 130px;
  display: flex; flex-direction: column;
  padding: 2px 14px 10px; background: var(--panel);
}
.chart-row {
  flex: 1; min-height: 0;
  display: flex; align-items: stretch; gap: 8px; margin-top: 4px;
}
.chart-row.tall { flex: 1.5; }
/* the chart canvases and the scrub bar share the same x range:
   label width + row gap (8px) = play btn + speed select + gaps on the
   left, and the value cell + row gap = time display + gaps on the right */
.chart-row label {
  width: 104px; flex: none; font-size: 9px; font-weight: 700;
  letter-spacing: 1px; color: var(--dim); padding-top: 4px; text-align: right;
}
/* value of each trace at the playhead, at the right end of its row:
   lap A always in its channel color, the reference lap in the same
   neutral grey-white as its ghost line */
.cv {
  width: 72px; flex: none; align-self: center;
  display: flex; flex-direction: column; gap: 1px;
  font-size: 12px; font-weight: 700; font-style: italic;
  font-variant-numeric: tabular-nums; color: var(--text); line-height: 1.25;
}
.cv .vB { color: #b9c2d0; }
#cv-delta.pos { color: var(--red); }
#cv-delta.neg { color: var(--green); }
#cvA-speed { color: #22d3ee; }
#cvA-thr   { color: #34d399; }
#cvA-brk   { color: #f87171; }
#cvA-steer { color: #a78bfa; }
canvas.chart { flex: 1; min-width: 0; min-height: 0; cursor: crosshair; }

/* ---------- empty ---------- */
#empty-hint {
  position: absolute; inset: 0; pointer-events: none;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 10px;
  text-align: center; color: var(--dim); padding: 30px; z-index: 5;
}
#empty-hint h2 { color: var(--text); font-size: 20px; }
#empty-hint p { max-width: 480px; font-size: 13px; }
