:root {
  color: #e7edf4;
  background: #070b10;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at 70% -20%, #182737 0, #070b10 42%); }
main { width: min(100% - 32px, 1500px); margin: 0 auto; padding: 32px 0 48px; }
header { display: flex; align-items: end; justify-content: space-between; gap: 24px; }
.eyebrow { margin: 0 0 4px; color: #8da1b6; font: 600 11px/1.4 ui-monospace, monospace; letter-spacing: .16em; }
h1 { margin: 0; font-size: clamp(28px, 5vw, 48px); font-weight: 650; letter-spacing: -.04em; }
.health { color: #8da1b6; font: 12px ui-monospace, monospace; }
.controls { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 28px; }
label { color: #aebdcb; font-size: 13px; }
input, button { border: 1px solid #2a3a49; border-radius: 7px; color: #e7edf4; background: #101821; }
input { width: 130px; padding: 10px 12px; font: 600 15px ui-monospace, monospace; text-transform: uppercase; }
input:focus, button:focus-visible { outline: 2px solid #6ba7d9; outline-offset: 2px; }
.ranges, .scales, .navigation { display: flex; gap: 5px; }
.control-label { color: #aebdcb; font-size: 13px; margin-left: 8px; }
button { padding: 10px 14px; cursor: pointer; font-weight: 600; }
button:hover { background: #172433; }
button.active { border-color: #6ba7d9; background: #19324a; color: #fff; }
.navigation button { min-width: 42px; }
.hint, .meta { color: #8193a5; font: 12px/1.5 ui-monospace, monospace; }
.hint { margin: 10px 0 18px; }
.chart-shell { position: relative; min-height: 300px; border: 1px solid #1c2a37; border-radius: 10px; background: #070b10; overflow: hidden; box-shadow: 0 24px 80px #0008; }
.chart-view { position: relative; width: 100%; height: 672px; overflow: hidden; }
#chart { display: none; width: 100%; height: 672px; background: #070b10; cursor: grab; touch-action: none; user-select: none; }
#chart.dragging { cursor: grabbing; }
.tooltip { position: absolute; z-index: 3; max-width: 290px; padding: 8px 10px; border: 1px solid #365069; border-radius: 6px; color: #e7edf4; background: #0b131deF; box-shadow: 0 8px 30px #000a; pointer-events: none; white-space: pre; font: 11px/1.45 ui-monospace, monospace; }
.loading { position: absolute; inset: 0; display: grid; place-items: center; color: #90a4b8; font: 13px ui-monospace, monospace; background: #070b10e8; z-index: 1; }
.meta { min-height: 18px; margin: 0; padding: 9px 12px; border-top: 1px solid #17232e; }
@media (max-width: 620px) {
  main { width: min(100% - 16px, 1500px); padding-top: 18px; }
  header { align-items: start; }
  .controls { align-items: stretch; }
  .ranges, .scales, .navigation { width: 100%; }
  button { flex: 1; padding-inline: 7px; }
  .chart-view, #chart { height: 560px; }
}
