:root {
  --bg: #0f1216; --panel: #171b21; --line: #2a313b; --text: #d8dee6; --muted: #8a94a3;
  --target: #f2c14e; --chaser: #4ea3f2; --arc: #9ad17a; --burn: #f27a6b; --term: #e08ef0;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text);
  font: 13px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; }
body { display: grid; grid-template-rows: auto 1fr auto; }
header, footer { display: flex; gap: 14px; align-items: center; padding: 6px 12px;
  background: var(--panel); border-bottom: 1px solid var(--line); }
footer { border-top: 1px solid var(--line); border-bottom: 0; }
.brand { font-weight: 600; }
.muted { color: var(--muted); }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; }
select, button, input { background: #222831; color: var(--text); border: 1px solid var(--line);
  border-radius: 4px; padding: 2px 6px; }
input[type=number] { width: 96px; }
button { cursor: pointer; }
#cursor { flex: 1; }
main { display: grid; gap: 6px; padding: 6px; min-height: 0;
  grid-template-columns: 1fr 1fr 360px; grid-template-rows: 1.6fr 1fr;
  grid-template-areas: "inertial synodic controls" "chart chart controls"; }
#view-inertial { grid-area: inertial; } #view-synodic { grid-area: synodic; }
#view-chart { grid-area: chart; } #controls { grid-area: controls; overflow-y: auto; padding: 4px 10px; }
.view, .pane { position: relative; background: var(--panel); border: 1px solid var(--line);
  border-radius: 6px; overflow: hidden; min-height: 0; }
.view canvas { display: block; width: 100%; height: 100%; cursor: grab; }
.view-title { position: absolute; left: 8px; top: 6px; color: var(--muted); font-size: 12px; pointer-events: none; }
.view-tools { position: absolute; right: 6px; top: 4px; display: flex; gap: 4px; }
.view-tools button { font-size: 11px; padding: 1px 6px; }
h3 { margin: 10px 0 4px; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.grid { display: grid; gap: 4px; }
.grid label { display: flex; gap: 6px; align-items: center; justify-content: space-between; }
#result { width: 100%; border-collapse: collapse; font-size: 11.5px; }
#result td { padding: 1px 4px; border-bottom: 1px solid var(--line); }
#result td:nth-child(2) { text-align: right; white-space: nowrap; }
#result td:first-child { font-family: system-ui, sans-serif; color: var(--muted); }
.over { color: var(--burn); font-weight: 600; } .ok { color: var(--arc); }
