/* bum — one stylesheet, no imports, no fonts fetched. */

:root {
  --bg:    #0a0710;
  --panel: #100b18;
  --panel2:#160f20;
  --ink:   #ded8ec;
  --dim:   #8b82a3;
  --faint: #5d5573;
  --line:  #271f36;
  --line2: #3a2f4e;
  --hot:   #b967ff;
  --ok:    #5fe3a1;
  --warn:  #f5c469;
  --bad:   #ff6f81;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 92px; }
html, body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 13.5px/1.55 var(--mono); -webkit-text-size-adjust: 100%;
}
body { padding: 0 20px 96px; max-width: 1040px; margin: 0 auto; }
a { color: var(--hot); }

/* ---------- masthead ---------- */
header.top { padding: 34px 0 16px; }
h1 { font-size: 15px; font-weight: 700; margin: 0 0 2px; letter-spacing: .04em; }
h1 .blink { color: var(--hot); animation: blink 1.2s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.lede { color: var(--dim); margin: 8px 0 0; max-width: 68ch; }
.lede b { color: var(--ink); font-weight: 400; }
.lede em { color: var(--hot); font-style: normal; }

/* ---------- sticky bar ---------- */
.bar {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  margin: 22px -20px 0; padding: 10px 20px;
}
.bar .row { margin: 0; }
nav.jump { display: flex; flex-wrap: wrap; gap: 0 13px; margin-top: 8px; font-size: 12px; }
nav.jump a { color: var(--faint); text-decoration: none; }
nav.jump a:hover { color: var(--ink); }
#topline { font-size: 12px; color: var(--dim); margin-top: 8px; line-height: 1.7; }
#topline b { color: var(--ink); font-weight: 400; }
#topline .sep { color: var(--line2); margin: 0 6px; }

/* ---------- sections ---------- */
section {
  border-top: 1px solid var(--line); padding: 22px 0 28px;
  display: grid; grid-template-columns: 186px 1fr; gap: 20px;
}
section > aside { color: var(--dim); font-size: 12.5px; }
section > aside h2 { color: var(--ink); font-size: 13.5px; font-weight: 700; margin: 0 0 6px; letter-spacing: .03em; }
section > aside h2 i { color: var(--faint); font-style: normal; }
section > aside p { margin: 0 0 8px; }
@media (max-width: 700px) { section { grid-template-columns: 1fr; gap: 10px; } }

/* ---------- controls ---------- */
button, select, input[type=text], input[type=number] {
  font: inherit; background: transparent; color: var(--ink);
  border: 1px solid var(--line2); padding: 5px 11px; border-radius: 0; cursor: pointer;
}
button:hover:not([disabled]), select:hover:not([disabled]) { border-color: var(--ink); }
button:focus-visible, select:focus-visible, input:focus-visible { outline: 1px solid var(--hot); outline-offset: 2px; }
button[disabled], select[disabled] { color: var(--faint); border-color: var(--line); cursor: not-allowed; }
button.on { border-color: var(--hot); color: var(--hot); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--hot) 25%, transparent); }
button.tiny { padding: 3px 8px; font-size: 12px; }
button.danger:hover:not([disabled]) { border-color: var(--bad); color: var(--bad); }
button.solo.on { border-color: var(--warn); color: var(--warn); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 25%, transparent); }
button.mute.on { border-color: var(--bad); color: var(--bad); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--bad) 25%, transparent); }
select { background: var(--panel); max-width: 100%; }
select.wide { min-width: 250px; }
label.chk { display: inline-flex; align-items: center; gap: 6px; color: var(--dim); cursor: pointer; font-size: 12.5px; }
input[type=range] { accent-color: var(--hot); vertical-align: middle; width: 130px; }
input[type=range].short { width: 96px; }
input[type=text], input[type=number] { cursor: text; }
.row { display: flex; flex-wrap: wrap; gap: 9px; align-items: center; margin-bottom: 12px; }
.row.tight { gap: 6px; }
.row.last { margin-bottom: 0; }
.spacer { flex: 1; }

/* ---------- key/value + pills ---------- */
.kv { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px 20px; margin-bottom: 10px; }
.kv.wide { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.kv div { color: var(--ink); overflow-wrap: anywhere; }
.kv span { color: var(--dim); }
.kv div.live { color: var(--hot); }
.kv:last-child { margin-bottom: 0; }

.pill { display: inline-block; padding: 0 6px; border: 1px solid var(--line2); font-size: 11.5px; color: var(--dim); white-space: nowrap; }
.pill.ok   { color: var(--ok);   border-color: color-mix(in srgb, var(--ok) 45%, transparent); }
.pill.warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, transparent); }
.pill.bad  { color: var(--bad);  border-color: color-mix(in srgb, var(--bad) 45%, transparent); }
.pill.hot  { color: var(--hot);  border-color: color-mix(in srgb, var(--hot) 55%, transparent); }

/* ---------- capability grid ---------- */
.caps { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 5px 20px; }
.cap { font-size: 12.5px; }
.cap b { font-weight: 400; }
.cap.yes b { color: var(--ok); }
.cap.no  b { color: var(--faint); }
.cap.part b { color: var(--warn); }
.cap.no, .cap.no em { color: var(--faint); }
.cap em { color: var(--dim); font-style: normal; }
h3.sub { font-size: 12.5px; font-weight: 400; color: var(--faint); margin: 16px 0 7px; letter-spacing: .06em; text-transform: uppercase; }
h3.sub.first { margin-top: 2px; }

/* ---------- device cards ---------- */
.dev { border: 1px solid var(--line); background: var(--panel); padding: 11px 13px; margin-bottom: 9px; }
.dev.armed { border-color: color-mix(in srgb, var(--hot) 50%, var(--line)); }
.dev .hd { display: flex; flex-wrap: wrap; gap: 8px; align-items: baseline; margin-bottom: 7px; }
.dev .nm { overflow-wrap: anywhere; flex: 1 1 240px; }
.dev .tags { display: flex; flex-wrap: wrap; gap: 5px; }
.dev .kv { margin: 9px 0 2px; font-size: 12px; }
.empty { color: var(--faint); font-size: 12.5px; padding: 6px 0; margin: 0; }

/* ---------- meters ---------- */
.meters { display: grid; gap: 5px; margin-top: 10px; }
.meter { display: grid; grid-template-columns: 40px 1fr 58px; gap: 10px; align-items: center; font-size: 11.5px; color: var(--dim); }
.meter .bar { height: 9px; background: #1a1424; position: relative; overflow: hidden; }
.meter .bar i { position: absolute; inset: 0 auto 0 0; width: 0; background: linear-gradient(90deg, var(--hot), #e0a3ff); transition: width 50ms linear; }
.meter .bar u { position: absolute; top: 0; bottom: 0; width: 2px; left: 0; background: var(--ink); opacity: .85; }
.meter .db { text-align: right; font-variant-numeric: tabular-nums; }
.meter.clip .db { color: var(--bad); }
.meter.clip .bar { box-shadow: inset 0 0 0 1px var(--bad); }

/* ---------- mixer ---------- */
.strip { border: 1px solid var(--line); background: var(--panel); padding: 11px 13px; margin-bottom: 9px; }
.strip.muted { opacity: .5; }
.strip .hd { display: flex; flex-wrap: wrap; gap: 8px; align-items: baseline; margin-bottom: 9px; }
.strip .nm { flex: 1 1 200px; overflow-wrap: anywhere; }
.knobs { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; font-size: 12px; color: var(--dim); }
.knob { display: flex; align-items: center; gap: 7px; }
.knob b { font-weight: 400; color: var(--ink); font-variant-numeric: tabular-nums; min-width: 54px; }
.matrix { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 9px; }
.matrix label { display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--line2); padding: 2px 7px; font-size: 11.5px; color: var(--dim); cursor: pointer; }
.matrix label.on { border-color: var(--hot); color: var(--hot); }
.matrix .lbl { color: var(--faint); align-self: center; margin-right: 4px; font-size: 11.5px; }

/* ---------- pointer pad ---------- */
.pad {
  border: 1px dashed var(--line2); background: var(--panel2); height: 168px;
  position: relative; overflow: hidden; touch-action: none; cursor: crosshair; margin-bottom: 10px;
}
.pad .hint { position: absolute; inset: 0; display: grid; place-items: center; color: var(--faint); font-size: 12px; pointer-events: none; }
.pad canvas { display: block; width: 100%; height: 100%; }

/* ---------- swatches ---------- */
.swatches { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.swatch { width: 42px; height: 22px; border: 1px solid var(--line2); }

/* ---------- video ---------- */
video { width: 100%; max-width: 320px; background: #000; border: 1px solid var(--line); display: block; margin-top: 9px; }

/* ---------- feeds / log ---------- */
.feed, .log {
  border: 1px solid var(--line); background: var(--panel);
  padding: 10px 12px; max-height: 240px; overflow: auto;
  font-size: 12.5px; overflow-wrap: anywhere;
}
.feed { max-height: 170px; }
.feed div, .log div { margin-bottom: 5px; }
.log div::before { content: "> "; color: var(--faint); }
.log div.why { color: var(--dim); padding-left: 2ch; }
.log div.why::before { content: ""; }
.log div.err { color: var(--bad); }
.feed div { color: var(--dim); }
.feed div b { color: var(--ink); font-weight: 400; }
.feed div.new { color: var(--hot); }
.bytes { font-variant-numeric: tabular-nums; color: var(--faint); }

pre.report {
  border: 1px solid var(--line); background: var(--panel); padding: 10px 12px;
  max-height: 300px; overflow: auto; font-size: 11.5px; color: var(--dim);
  white-space: pre-wrap; overflow-wrap: anywhere; margin: 10px 0 0;
}
.note { color: var(--faint); font-size: 12px; margin: 8px 0 0; max-width: 68ch; }
.note b { color: var(--dim); font-weight: 400; }
.note.warn { color: var(--warn); }
footer { border-top: 1px solid var(--line); margin-top: 8px; padding: 18px 0; color: var(--faint); font-size: 12px; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } html { scroll-behavior: auto; } }
.row.spaced { margin-top: 10px; }

/* the UA [hidden] rule loses to `.pad .hint { display: grid }`, so restate it */
.pad .hint[hidden] { display: none; }
