/* A quiet instrument panel: ink surfaces, precise numerals, semantic energy colours. */
:root {
  color-scheme: dark;
  --bg: #0b1119;
  --panel: #121c28;
  --panel-hi: #182433;
  --line: #2a394a;
  --ink: #e9eff4;
  --muted: #a3b3c4;
  --quiet: #8192a6;
  --accent: #b7e6d6;
  --accent-ink: #0f2a24;
  --solar: #f5c65a;
  --home: #a9c9eb;
  --ev: #58cee2;
  --import: #f58e81;
  --export: #ba9cf1;
  --charge: #72d9a0;
  --discharge: #5ebbaf;
  --warn: #ffd18b;
  --radius: 12px;
  font-family: "Aptos", "Segoe UI", "Helvetica Neue", sans-serif;
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.45;
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}
button,
select,
input[type="datetime-local"] {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel-hi);
  color: var(--ink);
  padding: 8px 13px;
}
button {
  cursor: pointer;
  white-space: nowrap;
  transition:
    background 0.15s,
    border-color 0.15s;
}
button:hover,
select:hover {
  background: #213347;
  border-color: #516a81;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
button[aria-pressed="true"] {
  background: #25473f;
  border-color: #72c7ac;
  color: #dbfff2;
}
.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
  font-weight: 700;
}
.primary:hover {
  background: #d2f4e8;
  border-color: #d2f4e8;
}
.quiet {
  background: transparent;
}
.badge {
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}
.warn {
  color: var(--warn);
  border-color: #6a5636;
}
.micro {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.55;
}
.dim {
  color: var(--quiet);
}
.eyebrow {
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.15em;
  color: var(--muted);
}
a {
  color: inherit;
}
h1,
h2,
p {
  margin: 0;
}
h1 {
  font-size: 21px;
  letter-spacing: -0.025em;
  font-weight: 550;
}
h2 {
  font-size: 19px;
  font-weight: 550;
  letter-spacing: -0.02em;
}
strong,
time,
output {
  font-variant-numeric: tabular-nums;
}
strong {
  font-weight: 600;
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
[hidden] {
  display: none !important;
}
.skip {
  position: fixed;
  top: -100px;
  left: 12px;
  z-index: 100;
  background: var(--accent);
  color: #000;
  padding: 15px;
}
.skip:focus {
  top: 12px;
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  padding: 19px 28px 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.clock-block {
  min-width: 310px;
}
.eyebrow a {
  text-decoration: none;
}
.divider {
  padding: 0 9px;
  color: #536478;
}
.clock-line {
  display: flex;
  gap: 15px;
  align-items: center;
  margin: 6px 0 3px;
  line-height: 1.15;
  white-space: nowrap;
}
#date,
#clock {
  font-size: clamp(19px, 1.75vw, 30px);
  font-weight: 550;
  letter-spacing: -0.045em;
}
#clock {
  color: var(--accent);
}
.transport {
  display: flex;
  gap: 4px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
}
.transport #previous,
.transport #next {
  font-size: 26px;
  padding: 0;
  min-width: 34px;
}
.transport #stop {
  padding: 8px 12px;
}
.transport #speed {
  min-width: 65px;
}
.transport #pace {
  width: 100%;
  text-align: center;
  margin-top: 2px;
}
.top-actions {
  display: flex;
  align-items: center;
  gap: 9px;
}
.top-actions #range-open {
  text-align: left;
  min-width: 210px;
}
.button-caption {
  font-size: 9px;
  letter-spacing: 0.1em;
  display: block;
  color: var(--muted);
  margin-bottom: 3px;
}
.top-actions #scientist {
  font-size: 12px;
  min-height: 54px;
}
#version-open {
  min-height: 44px;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}
#changelog-content {
  max-height: 65dvh;
  overflow: auto;
  line-height: 1.7;
}
main {
  max-width: 1780px;
  margin: auto;
  padding: 20px 28px 126px;
}
.section-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}
.views {
  display: flex;
  gap: 4px;
  overflow: auto;
  padding-bottom: 4px;
}
.views button {
  background: transparent;
  border-color: transparent;
  font-size: 12px;
  min-height: 40px;
  padding: 8px 15px;
  color: var(--muted);
}
.views button[aria-pressed="true"] {
  color: var(--ink);
  background: var(--panel-hi);
  border-color: var(--line);
}
.recording {
  font-size: 11px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.recording button {
  border-radius: 50%;
  min-height: 30px;
  width: 30px;
  padding: 0;
}
.snapshot-panel,
.chart-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  padding: 20px 22px;
}
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
}
.section-head .eyebrow {
  margin-bottom: 5px;
}
.snapshot-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 255px;
  gap: 24px;
}
.energy-ledger {
  min-width: 0;
}
.ledger-head,
.energy-row,
.ledger-foot {
  display: grid;
  grid-template-columns: minmax(145px, 0.85fr) minmax(110px, 1fr) minmax(
      130px,
      1fr
    );
  gap: 24px;
  align-items: center;
}
.ledger-head {
  color: var(--muted);
  font-size: 11px;
  margin-bottom: 12px;
}
.ledger-head > span:first-child {
  font-size: 10px;
  letter-spacing: 0.12em;
}
.ledger-head > span:not(:first-child) {
  text-align: right;
}
.energy-row {
  min-height: 31px;
}
.energy-row[data-detail] {
  cursor: pointer;
  border-radius: 8px;
  transition: background 0.12s ease;
}
.energy-row[data-detail]:hover,
.energy-row[data-detail]:focus-visible {
  background: rgba(255, 255, 255, 0.05);
  outline: none;
}
.energy-row[data-detail]:focus-visible {
  box-shadow: 0 0 0 1.5px #4a6578;
}
.energy-label {
  display: flex;
  gap: 9px;
  align-items: center;
  font-size: 12px;
}
.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--metric);
  flex-shrink: 0;
}
.bar-cell {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.bar-track {
  height: 5px;
  background: #263342;
  border-radius: 4px;
  flex: 1;
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  background: var(--metric);
  border-radius: 4px;
}
.bar-value {
  min-width: 64px;
  text-align: right;
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.partial-mark {
  color: var(--warn);
}
.ledger-foot {
  border-top: 1px solid var(--line);
  padding-top: 12px;
  margin-top: 10px;
  font-size: 12px;
}
.ledger-foot strong {
  text-align: right;
}
#energy-coverage {
  margin-top: 9px;
}
.hour-card {
  padding: 15px 18px;
  border-left: 1px solid var(--line);
  background: #0e1722;
  border-radius: 0 8px 8px 0;
}
.hour-window {
  font-size: 20px;
  margin: 8px 0 14px;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
}
.hour-metric {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  padding: 5px 0;
}
.hour-metric strong {
  font-size: 16px;
}
.hour-metric small {
  font-size: 11px;
  color: var(--muted);
  font-weight: 400;
}
#hour-note {
  margin-top: 12px;
}
.context-grid {
  display: grid;
  grid-template-columns: 1.22fr 1fr 1fr 1fr;
  gap: 12px;
  margin: 12px 0 20px;
}
.context-card {
  padding: 17px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}
.context-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 13px;
}
.context-head h2 {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
}
.context-head .micro {
  font-size: 10px;
}
.context-card p {
  font-size: 11px;
  color: var(--muted);
  margin-top: 10px;
  line-height: 1.5;
}
.context-card .micro:last-child {
  margin-top: 7px;
  font-size: 10px;
}
.money-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.money-line strong {
  font-size: 25px;
  letter-spacing: -0.035em;
  display: block;
}
.money-line span {
  font-size: 10px;
  color: var(--muted);
}
.money-line > div:last-child {
  text-align: right;
}
.battery-line {
  display: flex;
  align-items: center;
  gap: 12px;
}
.battery-line strong {
  font-size: 28px;
  letter-spacing: -0.03em;
}
.battery-track {
  height: 22px;
  border: 1px solid #4e6970;
  border-radius: 5px;
  position: relative;
  flex: 1;
  background: #0a141c;
  overflow: hidden;
}
.battery-track > div {
  height: 100%;
  background: var(--accent);
  width: 0;
}
.battery-track > span {
  position: absolute;
  left: 10%;
  height: 100%;
  top: 0;
  border-left: 2px dashed #9e7e4a;
}
.battery-line .micro {
  font-size: 9px !important;
  margin: 0 !important;
}
.weather-line {
  display: flex;
  align-items: center;
  gap: 10px;
}
.weather-line strong {
  font-size: 28px;
  letter-spacing: -0.03em;
}
.weather-line #weather-icon {
  color: var(--solar);
  font-size: 29px;
  line-height: 1;
}
.weather-line .micro {
  font-size: 10px;
}
.chart-panel {
  padding-bottom: 16px;
}
.chart-head {
  margin-bottom: 10px;
}
.chart-controls {
  display: flex;
  gap: 10px;
  align-items: center;
}
.chart-controls label {
  font-size: 11px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 7px;
}
.chart-controls select,
.chart-controls button {
  font-size: 11px;
  min-height: 36px;
}
.legend {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.legend button {
  display: flex;
  align-items: center;
  gap: 7px;
  border: 0;
  background: transparent;
  padding: 6px 10px 6px 0;
  min-height: 32px;
  font-size: 11px;
  color: var(--muted);
}
.legend button[aria-pressed="true"] {
  color: var(--ink);
}
.legend button[aria-pressed="false"] {
  opacity: 0.45;
}
.legend .dot {
  width: 8px;
  height: 8px;
}
.chart-wrap {
  position: relative;
  width: 100%;
  height: 255px;
}
.chart-wrap canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: crosshair;
}
.chart-cursor {
  position: absolute;
  top: 10px;
  bottom: 29px;
  border-left: 1px solid var(--accent);
  pointer-events: none;
  transition: none;
}
.chart-cursor:before {
  content: "";
  position: absolute;
  width: 5px;
  height: 5px;
  left: -3px;
  top: 0;
  background: var(--accent);
  border-radius: 50%;
}
.chart-tooltip {
  position: absolute;
  z-index: 5;
  pointer-events: none;
  background: #07101b;
  border: 1px solid #52657b;
  box-shadow: 0 4px 18px #0008;
  padding: 12px;
  border-radius: 7px;
  font-size: 11px;
  min-width: 185px;
  max-width: 280px;
}
.tooltip-heading {
  font-weight: 600;
  margin-bottom: 5px;
}
.tooltip-row {
  display: flex;
  justify-content: space-between;
  gap: 22px;
  padding: 2px 0;
}
.chart-caption {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  font-size: 10px;
  color: var(--muted);
  padding: 8px 0;
}
.focus-summary {
  border-top: 1px solid var(--line);
  padding-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px 28px;
}
.focus-stat {
  font-size: 11px;
  color: var(--muted);
}
.focus-stat strong {
  color: var(--ink);
  font-size: 15px;
  margin-right: 5px;
}
.navigator {
  padding: 16px 0 7px;
}
.navigator-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.navigator-head .micro {
  margin-left: 12px;
}
.navigator-head button {
  font-size: 11px;
  min-height: 32px;
  padding: 4px 10px;
}
.overview-wrap {
  position: relative;
  height: 64px;
  background: #0f1925;
  border: 1px solid var(--line);
  border-radius: 5px;
  margin: 7px 0;
}
.overview-wrap canvas {
  width: 100%;
  height: 100%;
  display: block;
  cursor: crosshair;
  touch-action: none;
}
#overview-window {
  position: absolute;
  top: 0;
  height: 100%;
  border: 1px solid #7a9b96;
  background: #b7e6d609;
  pointer-events: none;
}
#overview-cursor {
  position: absolute;
  top: 0;
  height: 100%;
  border-left: 2px solid var(--accent);
  pointer-events: none;
}
.overview-ends {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 10px;
}
.quality-details {
  border-top: 1px solid var(--line);
  margin-top: 12px;
  padding: 12px 0;
  color: var(--muted);
  font-size: 11px;
}
summary {
  cursor: pointer;
  min-height: 30px;
  padding: 5px 0;
}
.quality-details #quality-details {
  columns: 2;
  column-gap: 36px;
  line-height: 1.7;
}
.quality-details p {
  margin: 8px 0;
}
.quality-details ul {
  padding-left: 17px;
}
.page-footer {
  font-size: 10px;
  color: var(--quiet);
  display: flex;
  gap: 16px;
  justify-content: space-between;
  padding: 14px 0;
}
.scrub-dock {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #111d2b;
  z-index: 21;
  border-top: 1px solid #385065;
  padding: 10px 28px 8px;
  box-shadow: 0 -6px 24px #0003;
}
.scrub-labels {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 10px;
  color: var(--muted);
}
.scrub-labels output {
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
}
input[type="range"] {
  display: block;
  width: 100%;
  height: 26px;
  accent-color: var(--accent);
  margin: 2px 0;
  cursor: ew-resize;
}
.scrub-bottom {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 9px;
  color: var(--muted);
}
.inspector {
  position: fixed;
  z-index: 30;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(560px, 100%);
  background: #111c28;
  border-left: 1px solid #577287;
  box-shadow: -15px 0 50px #0006;
  padding: 22px;
  overflow: auto;
}
.inspector-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 13px;
}
.inspector-head button,
.dialog-head button {
  font-size: 25px;
  min-width: 44px;
  padding: 0;
}
.inspector p {
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 15px;
}
.inspector-actions {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}
.inspector-actions button {
  font-size: 12px;
}
pre {
  font-family: "Cascadia Code", "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
  line-height: 1.8;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: #0a131e;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 14px;
  margin: 4px 0 18px;
  color: #c8d9df;
}
.json-key {
  color: #a9c9eb;
}
.json-string {
  color: #b7e6d6;
}
.json-number {
  color: #f5c65a;
}
.json-null {
  color: #f58e81;
}
dialog {
  background: var(--panel);
  color: var(--ink);
  border: 1px solid #4a5e71;
  border-radius: 14px;
  width: min(640px, calc(100% - 24px));
  max-height: 90dvh;
  overflow: auto;
  padding: 26px;
  box-shadow: 0 20px 90px #0008;
}
dialog::backdrop {
  background: #040a13bd;
}
.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 20px;
}
.dialog-head h2 {
  font-size: 24px;
}
.form-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 16px;
}
.date-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.date-fields input {
  min-width: 0;
  width: 100%;
  font-size: 12px;
}
.presets {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 18px 0 10px;
}
.presets button {
  font-size: 12px;
}
.dialog-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 22px;
}
#range-error {
  color: var(--warn);
  font-size: 12px;
  margin-top: 12px;
}
.prose {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.8;
}
.prose p {
  margin: 0 0 15px;
}
.prose strong {
  color: var(--ink);
}
.prose code {
  font-size: 11px;
  color: var(--accent);
}
.loading {
  padding: 60px 0;
  color: var(--muted);
}
.error {
  border: 1px solid #70513e;
  padding: 24px;
  border-radius: 10px;
  color: var(--warn);
}
@media (min-width: 1700px) {
  .context-card {
    padding: 20px 24px;
  }
  .chart-wrap {
    height: 300px;
  }
  .energy-row {
    min-height: 35px;
  }
  .topbar {
    padding-left: max(28px, calc((100vw - 1724px) / 2));
    padding-right: max(28px, calc((100vw - 1724px) / 2));
  }
}
@media (max-width: 1200px) {
  .topbar {
    flex-wrap: wrap;
    gap: 12px;
    padding: 13px 20px;
  }
  .clock-block {
    flex: 1;
  }
  .top-actions {
    margin-left: auto;
  }
  .transport {
    order: 3;
    width: 100%;
    justify-content: flex-start;
  }
  .transport #pace {
    width: auto;
    margin: 0 0 0 10px;
  }
  .top-actions #range-open {
    min-width: 170px;
  }
  .context-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .snapshot-layout {
    grid-template-columns: minmax(0, 1fr) 230px;
  }
  .ledger-head,
  .energy-row,
  .ledger-foot {
    gap: 15px;
  }
  .recording #recording-meta {
    display: none;
  }
  main {
    padding: 17px 20px 124px;
  }
}
@media (max-width: 850px) {
  .snapshot-layout {
    grid-template-columns: 1fr;
  }
  .hour-card {
    border-left: 0;
    border-top: 1px solid var(--line);
    border-radius: 7px;
  }
  .hour-card #hour-values {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
  }
  .hour-metric {
    gap: 18px;
  }
  .hour-window {
    font-size: 18px;
  }
  .chart-caption {
    flex-direction: column;
    gap: 4px;
  }
  .section-line {
    gap: 4px;
  }
  .views button {
    padding: 8px 11px;
  }
  .context-grid {
    gap: 10px;
  }
  .clock-block {
    min-width: 280px;
  }
  .top-actions #scientist {
    min-height: 44px;
  }
  .top-actions #range-open {
    min-height: 44px;
  }
  .button-caption {
    display: none;
  }
  #range-label {
    font-size: 11px;
  }
  .top-actions {
    flex-wrap: wrap;
  }
  .topbar {
    align-items: flex-start;
  }
  .quality-details #quality-details {
    columns: 1;
  }
}
@media (max-width: 580px) {
  .topbar {
    padding: 12px;
    gap: 10px;
  }
  .clock-block {
    width: 100%;
    flex: initial;
  }
  .clock-line {
    gap: 10px;
  }
  #date,
  #clock {
    font-size: 25px;
  }
  .top-actions {
    position: absolute;
    top: 12px;
    right: 12px;
    max-width: 168px;
    justify-content: flex-end;
  }
  .top-actions #range-open {
    min-width: 0;
    width: 44px;
    padding: 4px;
    font-size: 0;
  }
  .top-actions #range-open:after {
    content: "Date";
    font-size: 11px;
  }
  .top-actions #range-label {
    display: none;
  }
  .top-actions #scientist {
    font-size: 0;
    padding: 5px;
    width: 44px;
  }
  .top-actions #scientist:after {
    content: "{ }";
    font-size: 15px;
  }
  .eyebrow {
    font-size: 9px;
    letter-spacing: 0.12em;
  }
  .clock-block > .eyebrow {
    max-width: 260px;
    font-size: 8px;
  }
  .clock-line .badge {
    font-size: 9px;
  }
  .transport {
    gap: 5px;
  }
  .transport button {
    min-height: 38px;
  }
  main {
    padding: 13px 12px 117px;
  }
  .section-line {
    margin-bottom: 10px;
  }
  .views {
    gap: 0;
  }
  .views button {
    padding: 8px 10px;
    min-height: 44px;
    font-size: 11px;
  }
  .recording {
    display: none;
  }
  .snapshot-panel,
  .chart-panel {
    padding: 16px 12px;
  }
  .section-head {
    gap: 8px;
    margin-bottom: 15px;
  }
  h1 {
    font-size: 17px;
  }
  .section-head .badge {
    font-size: 9px;
  }
  .ledger-head,
  .energy-row,
  .ledger-foot {
    grid-template-columns: 1.05fr 0.8fr 0.8fr;
    gap: 7px;
  }
  .ledger-head {
    font-size: 9px;
  }
  .energy-row {
    min-height: 33px;
  }
  .energy-label {
    font-size: 10px;
    gap: 6px;
  }
  .bar-cell {
    gap: 6px;
  }
  .bar-value {
    font-size: 11px;
    min-width: 45px;
  }
  .bar-track {
    height: 3px;
  }
  .ledger-foot {
    font-size: 10px;
  }
  .hour-card {
    padding: 12px;
  }
  .hour-card #hour-values {
    gap: 4px 18px;
  }
  .hour-metric {
    font-size: 11px;
  }
  .context-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin: 8px 0 14px;
  }
  .context-card {
    padding: 12px;
  }
  .context-head {
    flex-wrap: wrap;
    gap: 3px;
    margin-bottom: 9px;
  }
  .context-head h2 {
    font-size: 12px;
  }
  .context-head .micro {
    font-size: 9px;
  }
  .money-line {
    flex-direction: column;
    gap: 6px;
  }
  .money-line > div:last-child {
    text-align: left;
  }
  .money-line strong {
    font-size: 24px;
  }
  .money-line > div:last-child strong {
    font-size: 18px;
  }
  .battery-line {
    gap: 6px;
    flex-wrap: wrap;
  }
  .battery-line strong {
    font-size: 24px;
  }
  .battery-track {
    min-width: 55px;
  }
  .weather-line {
    flex-wrap: wrap;
    gap: 6px;
  }
  .weather-line strong {
    font-size: 24px;
  }
  .context-card p {
    font-size: 10px;
  }
  .chart-head {
    align-items: flex-start;
    flex-direction: column;
  }
  .chart-controls {
    width: 100%;
    justify-content: space-between;
  }
  .chart-wrap {
    height: 240px;
  }
  .legend {
    gap: 0;
  }
  .legend button {
    font-size: 10px;
    min-height: 40px;
  }
  .chart-caption {
    font-size: 9px;
  }
  .focus-summary {
    gap: 10px 18px;
  }
  .focus-stat {
    font-size: 10px;
  }
  .focus-stat strong {
    font-size: 13px;
  }
  .navigator-head .micro {
    display: block;
    margin: 3px 0;
  }
  .scrub-dock {
    padding: 9px 12px 7px;
  }
  .scrub-labels {
    font-size: 9px;
  }
  .scrub-labels output {
    font-size: 10px;
  }
  .scrub-bottom {
    font-size: 8px;
  }
  .page-footer {
    flex-direction: column;
    gap: 6px;
  }
  .date-fields {
    grid-template-columns: 1fr;
  }
  .inspector {
    padding: 18px;
  }
  dialog {
    padding: 20px;
  }
  .chart-tooltip {
    font-size: 10px;
    max-width: 230px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
.split-col {
  border-left: 1px solid var(--line);
  padding-left: 8px;
}
.head-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}
.context-card[data-detail] {
  cursor: pointer;
}
.context-card[data-detail]:hover,
.context-card[data-detail]:focus-visible {
  border-color: #4a6578;
  outline: none;
}
.open-hint {
  color: var(--accent);
}
.export-block {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.export-block h3 {
  font-size: 13px;
  font-weight: 600;
}
.export-block .money-line strong {
  font-size: 18px;
}
dialog.wide {
  width: min(960px, calc(100% - 24px));
}
#detail-note {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  margin: 0 0 14px;
}
.detail-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}
.detail-stat {
  min-width: 140px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0e1722;
}
.detail-stat strong {
  display: block;
  font-size: 16px;
}
.detail-stat span,
.day-jump span {
  color: var(--muted);
  font-size: 11px;
}
.day-jump {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  text-align: left;
  flex: 1;
  min-width: 220px;
}
.detail-chart {
  margin: 12px 0;
}
.detail-chart-head,
.detail-legend {
  display: flex;
  align-items: center;
  gap: 12px;
}
.detail-chart-head {
  justify-content: space-between;
}
.detail-chart h3 {
  font-size: 14px;
  font-weight: 600;
}
.detail-legend {
  color: var(--muted);
  font-size: 11px;
  margin: 4px 0 6px;
}
.detail-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.detail-plot {
  height: 168px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0e1722;
}
.detail-plot canvas {
  width: 100%;
  height: 100%;
  display: block;
  cursor: ew-resize;
}
.detail-scrub {
  margin-top: 8px;
}
@media (max-width: 580px) {
  .split-col {
    padding-left: 4px;
  }
  dialog.wide {
    width: calc(100% - 16px);
    padding: 16px;
  }
  .detail-plot {
    height: 140px;
  }
}
