/* --------------------------------------------------------------
   sip.sportscasterpro.com — operator dashboard

   Drawn from rack gear rather than dashboards: anodised panel
   faces, silkscreen labels in small letterspaced caps, monospace
   readouts, and real status lamps. The one flourish is the expiry
   bar on each channel strip, which drains as a registration ages
   and refills when the endpoint checks in.
   -------------------------------------------------------------- */

:root {
  --panel-deep:  #131519;
  --panel-face:  #1b1e24;
  --panel-lift:  #22262d;
  --edge:        #2c313a;
  --edge-bright: #3a4049;

  --ink:         #e9ecf1;
  --ink-dim:     #949ba6;
  --ink-faint:   #656c77;

  --lamp-good:   #43d787;
  --lamp-warn:   #f0a326;
  --lamp-dead:   #f2545b;
  --lamp-off:    #454b55;

  --backlight:   #56cfe1;

  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "Roboto Mono", Menlo, Consolas, monospace;
  --sans: ui-sans-serif, system-ui, "Segoe UI", Inter, Roboto, sans-serif;

  --radius: 5px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--panel-deep);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

code, pre { font-family: var(--mono); }

/* ---------- header ---------- */

.rack {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 24px;
  height: 60px;
  background: linear-gradient(180deg, var(--panel-lift), var(--panel-face));
  border-bottom: 1px solid var(--edge);
  position: sticky;
  top: 0;
  z-index: 5;
}

.rack-id { display: flex; align-items: center; gap: 11px; min-width: 0; }

.rack-mark {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--lamp-good);
  box-shadow: 0 0 9px rgba(67, 215, 135, .75);
  flex: none;
}

.rack-name {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .02em;
  color: var(--ink-dim);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rack nav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }

.rack nav a {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .13em;
  padding: 7px 12px;
  border-radius: var(--radius);
  border: 1px solid transparent;
}

.rack nav a:hover { color: var(--ink); background: rgba(255,255,255,.04); }

.rack nav a.on {
  color: var(--backlight);
  border-color: var(--edge-bright);
  background: rgba(86, 207, 225, .07);
}

.rack nav a.quiet { color: var(--ink-faint); margin-left: 10px; }

/* ---------- layout ---------- */

main { max-width: 1080px; margin: 0 auto; padding: 30px 24px 72px; }

.head { margin-bottom: 26px; }

.head h1 {
  margin: 0;
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -.015em;
}

.sub { margin: 4px 0 0; color: var(--ink-faint); font-size: 13px; }

.group { margin-bottom: 34px; }

.group-label {
  font-family: var(--mono);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .17em;
  color: var(--ink-faint);
  padding-bottom: 8px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--edge);
}

/* ---------- channel strip ---------- */

.strip {
  display: grid;
  grid-template-columns: 14px minmax(150px, 1.1fr) minmax(0, 1.5fr) 190px;
  align-items: center;
  gap: 16px;
  padding: 13px 16px;
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  margin-bottom: 7px;
}

.strip.check { grid-template-columns: 14px minmax(150px, 1fr) minmax(0, 2.4fr); }

.lamp {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--lamp-off);
  display: inline-block;
  flex: none;
}

.lamp.good { background: var(--lamp-good); box-shadow: 0 0 8px rgba(67,215,135,.65); }
.lamp.warn { background: var(--lamp-warn); box-shadow: 0 0 8px rgba(240,163,38,.6); }
.lamp.dead { background: var(--lamp-dead); box-shadow: 0 0 8px rgba(242,84,91,.6); }
.lamp.off  { background: var(--lamp-off); }

.strip-name { display: flex; flex-direction: column; gap: 2px; min-width: 0; }

.tag {
  font-weight: 600;
  font-size: 14.5px;
  letter-spacing: -.005em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ua, .detail {
  font-size: 11.5px;
  color: var(--ink-faint);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.strip-wire { display: flex; align-items: center; gap: 9px; min-width: 0; }

.strip-wire code {
  font-size: 12px;
  color: var(--ink-dim);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chip {
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--lamp-warn);
  border: 1px solid rgba(240,163,38,.32);
  border-radius: 3px;
  padding: 2px 6px;
  white-space: nowrap;
  flex: none;
}

/* the signature: a contact draining toward expiry */

.strip-timer { display: flex; align-items: center; gap: 11px; }

.bar {
  flex: 1;
  height: 3px;
  background: var(--panel-deep);
  border-radius: 2px;
  overflow: hidden;
  border: 1px solid var(--edge);
}

.bar i {
  display: block;
  height: 100%;
  background: var(--backlight);
  transition: width .9s linear;
}

.readout {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--ink-dim);
  min-width: 56px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ---------- meters ---------- */

.meters { display: flex; gap: 7px; flex-wrap: wrap; }

.meter {
  flex: 1 1 150px;
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  padding: 18px 20px;
}

.meter-value {
  display: block;
  font-family: var(--mono);
  font-size: 30px;
  color: var(--backlight);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}

.meter-value small { font-size: 16px; color: var(--ink-faint); }

.meter-label {
  display: block;
  margin-top: 6px;
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .13em;
  color: var(--ink-faint);
}

/* ---------- tables ---------- */

.grid {
  width: 100%;
  border-collapse: collapse;
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  overflow: hidden;
}

.grid th {
  text-align: left;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .13em;
  color: var(--ink-faint);
  font-weight: 500;
  padding: 11px 14px;
  border-bottom: 1px solid var(--edge);
  background: var(--panel-lift);
}

.grid td {
  padding: 11px 14px;
  border-bottom: 1px solid rgba(44,49,58,.55);
  font-size: 13.5px;
  vertical-align: middle;
}

.grid tr:last-child td { border-bottom: 0; }
.grid code { font-size: 12px; color: var(--ink-dim); }
.grid .dim { color: var(--ink-faint); font-size: 12.5px; }
.grid .tag { display: block; font-size: 13.5px; }

.actions { white-space: nowrap; text-align: right; }
.actions form { display: inline; }

/* ---------- controls ---------- */

button.link {
  background: none;
  border: 0;
  color: var(--backlight);
  font-family: var(--sans);
  font-size: 11.5px;
  cursor: pointer;
  padding: 3px 7px;
  border-radius: 3px;
}

button.link:hover { background: rgba(86,207,225,.1); }
button.link.danger { color: var(--lamp-dead); }
button.link.danger:hover { background: rgba(242,84,91,.1); }

button.primary {
  width: 100%;
  padding: 11px;
  background: var(--backlight);
  color: #0d1013;
  border: 0;
  border-radius: var(--radius);
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  margin-top: 6px;
}

button.primary:hover { filter: brightness(1.08); }

:focus-visible {
  outline: 2px solid var(--backlight);
  outline-offset: 2px;
}

/* ---------- notices ---------- */

.notice {
  padding: 11px 15px;
  border-radius: var(--radius);
  font-size: 13px;
  margin-bottom: 18px;
  border: 1px solid var(--edge);
  background: var(--panel-face);
}

.notice.good { border-color: rgba(67,215,135,.35); color: var(--lamp-good); }
.notice.bad  { border-color: rgba(242,84,91,.35); color: var(--lamp-dead); }

.empty {
  padding: 52px 24px;
  text-align: center;
  border: 1px dashed var(--edge);
  border-radius: var(--radius);
  color: var(--ink-dim);
}

.empty p { margin: 0 0 5px; }

.pointer {
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  padding: 18px 20px;
  font-size: 13px;
  color: var(--ink-dim);
}

.pointer p { margin: 0 0 12px; }

.pointer pre {
  margin: 0;
  padding: 12px 14px;
  background: var(--panel-deep);
  border: 1px solid var(--edge);
  border-radius: 4px;
  overflow-x: auto;
  font-size: 12px;
  color: var(--ink);
}

/* ---------- sign in ---------- */

body.centred {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}

.signin {
  width: 100%;
  max-width: 330px;
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: 7px;
  padding: 32px 28px;
}

.signin-mark { display: flex; justify-content: center; margin-bottom: 18px; }

.signin h1 {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 400;
  color: var(--ink-dim);
  text-align: center;
  margin: 0 0 24px;
  letter-spacing: .01em;
}

.signin label { display: block; margin-bottom: 14px; }

.signin label span {
  display: block;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .13em;
  color: var(--ink-faint);
  margin-bottom: 6px;
}

.signin input {
  width: 100%;
  padding: 10px 12px;
  background: var(--panel-deep);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 13px;
}

.signin input:focus { border-color: var(--backlight); outline: none; }

/* ---------- narrow screens ---------- */

@media (max-width: 720px) {
  .strip, .strip.check { grid-template-columns: 14px 1fr; row-gap: 9px; }
  .strip-wire, .strip-timer { grid-column: 2; }
  .rack { height: auto; padding: 12px 16px; flex-direction: column; align-items: flex-start; }
  main { padding: 22px 16px 56px; }
  .grid { display: block; overflow-x: auto; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}

/* ---------- update ---------- */

.upload { display: flex; flex-direction: column; gap: 12px; }

.drop {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 40px 24px;
  border: 1px dashed var(--edge-bright);
  border-radius: var(--radius);
  background: var(--panel-face);
  cursor: pointer;
  text-align: center;
}

.drop.over { border-color: var(--backlight); background: rgba(86,207,225,.05); }
.drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.drop-main { font-size: 14px; color: var(--ink); }
.drop-main code { font-size: 12.5px; color: var(--backlight); }
.drop-sub { font-size: 12px; color: var(--ink-faint); }

button.primary:disabled { opacity: .4; cursor: not-allowed; }
.notice code { color: var(--backlight); font-size: 12px; }

/* ---------- calls ---------- */

.patch {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr) 170px;
  align-items: center;
  gap: 16px;
  padding: 14px 16px;
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  margin-bottom: 7px;
}

.patch-ends { display: flex; align-items: center; gap: 14px; min-width: 0; }

.patch-ends .end {
  font-weight: 600;
  font-size: 14.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* the patch cord between the two endpoints */
.link-line {
  flex: 1;
  min-width: 24px;
  height: 1px;
  background: linear-gradient(90deg,
    var(--edge-bright) 0%, var(--backlight) 50%, var(--edge-bright) 100%);
  position: relative;
}

.link-line::before,
.link-line::after {
  content: "";
  position: absolute;
  top: -2px;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--backlight);
}

.link-line::before { left: -1px; }
.link-line::after  { right: -1px; }

.patch-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.state {
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: .1em;
  padding: 2px 7px;
  border-radius: 3px;
  border: 1px solid var(--edge-bright);
  color: var(--ink-dim);
  white-space: nowrap;
}

.state.good { color: var(--lamp-good); border-color: rgba(67,215,135,.32); }
.state.warn { color: var(--lamp-warn); border-color: rgba(240,163,38,.32); }

.quiet-row {
  padding: 18px 16px;
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  color: var(--ink-faint);
  font-size: 13px;
}

@media (max-width: 720px) {
  .patch { grid-template-columns: 14px 1fr; row-gap: 9px; }
  .patch-meta { grid-column: 2; justify-content: flex-start; }
}

/* ---------- offline rows ---------- */

.strip.is-off { opacity: .62; }
.strip.is-off .tag { color: var(--ink-dim); font-weight: 500; }

.readout.off {
  color: var(--ink-faint);
  min-width: 56px;
  text-align: right;
}

.group-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.group-count {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .1em;
  color: var(--ink-faint);
  text-transform: none;
  flex: none;
}

/* ---------- codec badge and NAT marker ---------- */

.codec {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--backlight);
  border: 1px solid rgba(86,207,225,.28);
  background: rgba(86,207,225,.06);
  border-radius: 3px;
  padding: 2px 7px;
  white-space: nowrap;
  max-width: 130px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nat-dot {
  font-family: var(--mono);
  font-style: normal;
  font-size: 9px;
  color: var(--lamp-warn);
  border: 1px solid rgba(240,163,38,.4);
  border-radius: 2px;
  padding: 0 3px;
  margin-left: 6px;
  vertical-align: middle;
}

@media (max-width: 720px) {
  .patch-meta { flex-wrap: wrap; }
}

.patch-ends .end { display: flex; flex-direction: column; gap: 1px; }
.end-name { font-weight: 600; font-size: 14.5px; white-space: nowrap; }
.end-owner {
  font-size: 10.5px;
  color: var(--ink-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 160px;
}

/* ---------- connection detail panel ---------- */

.call {
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  margin-bottom: 9px;
  overflow: hidden;
}

.call-top {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 15px 18px;
  background: var(--panel-lift);
  border-bottom: 1px solid var(--edge);
}

.call-route { display: flex; align-items: center; gap: 16px; min-width: 0; }
.call-route .end { display: flex; flex-direction: column; gap: 1px; min-width: 0; }

.call-status { display: flex; align-items: center; gap: 12px; flex: none; }

.readout.big {
  font-size: 15px;
  color: var(--ink);
  min-width: 72px;
}

/* facts grid */

.call-facts {
  margin: 0;
  padding: 14px 18px 16px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px 28px;
}

.fact { display: grid; grid-template-columns: 74px minmax(0, 1fr); align-items: baseline; gap: 12px; }
.fact.wide { grid-column: 1 / -1; }

.fact dt {
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--ink-faint);
}

.fact dd {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  min-width: 0;
}

.fact dd code { font-size: 12px; color: var(--ink); }
.fact dd code.dim { color: var(--ink-faint); font-size: 11px; word-break: break-all; }

.muted { font-size: 11.5px; color: var(--ink-faint); }

.fact .chip {
  font-size: 9px;
  padding: 1px 5px;
}

@media (max-width: 720px) {
  .call-top { grid-template-columns: 14px 1fr; row-gap: 10px; }
  .call-status { grid-column: 2; }
  .call-facts { grid-template-columns: 1fr; }
  .call-route { flex-wrap: wrap; }
}

/* ---------- search ---------- */

.head.with-search {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.search { display: flex; align-items: center; gap: 10px; flex: none; }

.search input[type=search] {
  width: 260px;
  padding: 8px 12px;
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 12.5px;
}

.search input[type=search]:focus { border-color: var(--backlight); outline: none; }
.search input[type=search]::placeholder { color: var(--ink-faint); }

.search-clear,
a.plain {
  color: var(--backlight);
  font-size: 11.5px;
  text-decoration: none;
}

.search-clear:hover, a.plain:hover { text-decoration: underline; }

/* ---------- users ---------- */

.inline-form { display: flex; align-items: center; gap: 7px; }

.inline-form input[type=password] {
  width: 150px;
  padding: 5px 9px;
  background: var(--panel-deep);
  border: 1px solid var(--edge);
  border-radius: 3px;
  color: var(--ink);
  font-family: var(--mono);
  font-size: 11.5px;
}

.inline-form input[type=password]:focus { border-color: var(--backlight); outline: none; }

.add-row {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  flex-wrap: wrap;
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  padding: 18px 20px;
}

.add-row label { display: flex; flex-direction: column; gap: 6px; }

.add-row label span {
  font-family: var(--mono);
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--ink-faint);
}

.add-row input {
  width: 220px;
  padding: 9px 11px;
  background: var(--panel-deep);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 12.5px;
}

.add-row input:focus { border-color: var(--backlight); outline: none; }

button.primary.compact { width: auto; margin-top: 0; padding: 9px 18px; }

.chip.you {
  color: var(--backlight);
  border-color: rgba(86,207,225,.32);
  margin-left: 7px;
}

@media (max-width: 720px) {
  .search input[type=search] { width: 100%; }
  .search { width: 100%; }
  .add-row input { width: 100%; }
  .add-row label { width: 100%; }
}

/* ---------- applications ---------- */

.app {
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  margin-bottom: 9px;
  overflow: hidden;
}

.app.is-off { opacity: .58; }

.app-top {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  background: var(--panel-lift);
  border-bottom: 1px solid var(--edge);
}

.app-scopes { display: flex; gap: 6px; flex-wrap: wrap; }

.app-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-top: 1px solid var(--edge);
  background: rgba(0,0,0,.14);
}

.app-actions form { display: inline; }

/* the one-time key reveal */

.keybox {
  background: var(--panel-face);
  border: 1px solid rgba(86,207,225,.34);
  border-radius: var(--radius);
  padding: 20px;
}

.keybox-warn {
  margin: 0 0 12px;
  font-size: 12px;
  color: var(--lamp-warn);
}

.keyval {
  display: block;
  padding: 13px 15px;
  background: var(--panel-deep);
  border: 1px solid var(--edge);
  border-radius: 4px;
  color: var(--backlight);
  font-size: 13px;
  word-break: break-all;
  user-select: all;
}

.keybox-actions { display: flex; gap: 14px; margin-top: 12px; }
.keybox-actions .link { text-decoration: none; }

.keybox-note {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--ink-faint);
  line-height: 1.55;
}

.add-row label.check {
  flex-direction: row;
  align-items: center;
  gap: 8px;
  width: auto;
  padding-bottom: 9px;
}

.add-row label.check input { width: auto; }

.add-row label.check span {
  font-size: 12px;
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink-dim);
}

/* ---------- date range selector ---------- */

.rangebar { display: flex; gap: 5px; margin: -10px 0 22px; flex-wrap: wrap; }

.range {
  font-family: var(--mono);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .11em;
  color: var(--ink-faint);
  text-decoration: none;
  padding: 6px 12px;
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  background: var(--panel-face);
}

.range:hover { color: var(--ink); border-color: var(--edge-bright); }

.range.on {
  color: var(--backlight);
  border-color: var(--edge-bright);
  background: rgba(86,207,225,.08);
}

.meters.tight { margin-bottom: 12px; }
.meters.tight .meter { padding: 14px 16px; }
.meters.tight .meter-value { font-size: 24px; }

/* ---------- level meters ---------- */

.lvl-panels { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 9px; }

.lvl-panel {
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  padding: 16px 18px;
}

.lvl-head {
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .16em;
  color: var(--ink-faint);
  margin-bottom: 14px;
}

.lvl { display: grid; grid-template-columns: 16px 1fr 54px; align-items: center; gap: 11px; margin-bottom: 9px; }

.lvl-label {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-faint);
}

.lvl-track {
  position: relative;
  height: 12px;
  background: var(--panel-deep);
  border: 1px solid var(--edge);
  border-radius: 2px;
  overflow: hidden;
}

.lvl-bar {
  display: block;
  height: 100%;
  background: var(--lamp-good);
  transition: width .25s linear;
}

.lvl-bar.warm  { background: var(--lamp-warn); }
.lvl-bar.hot   { background: var(--lamp-dead); }
.lvl-bar.quiet { background: var(--lamp-off); }

.lvl-peak {
  position: absolute;
  top: 0; bottom: 0;
  width: 2px;
  background: var(--ink);
  opacity: .85;
}

.lvl-peak.hot  { background: var(--lamp-dead); opacity: 1; }
.lvl-peak.warm { background: var(--lamp-warn); }

.lvl-val {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--ink-dim);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.lvl-foot {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--edge);
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-dim);
}

/* ---------- charts ---------- */

.chart {
  background: var(--panel-face);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  padding: 14px 16px 12px;
  margin-bottom: 9px;
}

.chart-title {
  display: flex;
  justify-content: space-between;
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--ink-faint);
  margin-bottom: 10px;
}

.chart-max { color: var(--ink-dim); letter-spacing: .08em; }

.chart-svg {
  display: block;
  width: 100%;
  height: 90px;
  background: var(--panel-deep);
  border: 1px solid var(--edge);
  border-radius: 3px;
}

.chart-svg .grid { stroke: var(--edge); stroke-width: .5; }

.chart-svg .line { fill: none; stroke-width: 1.4; vector-effect: non-scaling-stroke; }
.chart-svg .area { stroke: none; opacity: .16; }

.line.tx,   .area.tx   { stroke: var(--backlight);  fill: var(--backlight); }
.line.tx2,  .area.tx2  { stroke: #7f8cff;           fill: #7f8cff; }
.line.rx,   .area.rx   { stroke: var(--lamp-good);  fill: var(--lamp-good); }
.line.rx2,  .area.rx2  { stroke: #4fd1a5;           fill: #4fd1a5; }
.line.loss, .area.loss { stroke: var(--lamp-dead);  fill: var(--lamp-dead); }
.line.jit,  .area.jit  { stroke: var(--lamp-warn);  fill: var(--lamp-warn); }
.line.rtt,  .area.rtt  { stroke: #9d8cff;           fill: #9d8cff; }

.chart-scale {
  display: flex;
  justify-content: space-between;
  font-family: var(--mono);
  font-size: 9.5px;
  color: var(--ink-faint);
  margin-top: 5px;
}

.meter-value.bad { color: var(--lamp-dead); }

@media (max-width: 720px) {
  .lvl-panels { grid-template-columns: 1fr; }
}

.drop-form { display: inline; margin-left: 4px; }
.call-status .link { font-size: 11px; }

.row-off { opacity: .5; }
.ord {
  width: 58px; padding: 4px 7px;
  background: var(--panel-deep); border: 1px solid var(--edge);
  border-radius: 3px; color: var(--ink);
  font-family: var(--mono); font-size: 11.5px;
}
.ord:focus { border-color: var(--backlight); outline: none; }
.add-row select {
  width: 220px; padding: 9px 11px;
  background: var(--panel-deep); border: 1px solid var(--edge);
  border-radius: var(--radius); color: var(--ink);
  font-family: var(--mono); font-size: 12.5px;
}
.add-row select:focus { border-color: var(--backlight); outline: none; }

.tickbox {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; color: var(--lamp-warn); margin-right: 8px;
}
.tickbox input { width: auto; margin: 0; }
.app-actions .inline-form input {
  padding: 5px 9px; background: var(--panel-deep);
  border: 1px solid var(--edge); border-radius: 3px;
  color: var(--ink); font-family: var(--mono); font-size: 11.5px;
}
.app-actions .inline-form input:focus { border-color: var(--backlight); outline: none; }
button.link:disabled { opacity: .35; cursor: not-allowed; }

.limitbar {
  display: flex; align-items: center; gap: 16px;
  padding: 10px 14px; margin-bottom: 8px;
  background: var(--panel-face); border: 1px solid var(--edge);
  border-radius: var(--radius);
}
.limit-label {
  font-family: var(--mono); font-size: 9.5px;
  text-transform: uppercase; letter-spacing: .14em;
  color: var(--ink-faint);
}
