/* ==========================================================================
   GONE. — a ledger, not a landing page.
   Plum ink, acid lime, bone type, hard rules, no softness.
   ========================================================================== */

:root {
  --ink: #12061b;
  --ink-2: #1b0a29;
  --ink-3: #0c0413;
  --plum: #3a0f57;
  --plum-2: #5b1e8a;
  --grape: #7a2baf;
  --acid: #c6ff3d;
  --acid-2: #a3e635;
  --moss: #1f7a3d;
  --bone: #ede6d6;
  --dim: #a99bc0;
  --line: rgba(198, 255, 61, 0.22);
  --line-2: rgba(198, 255, 61, 0.5);
  --hot: #ff3d6e;

  --display: "Anton", "Arial Narrow", "Haettenschweiler", sans-serif;
  --mono: "Space Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --rule: 2px;
  --pad: clamp(18px, 2.4vw, 30px);
  --shadow: 5px 5px 0 var(--plum-2);
}

* { box-sizing: border-box; }

html { scrollbar-color: var(--plum-2) var(--ink); }

body {
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font-family: var(--mono);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  position: relative;
  min-height: 100vh;
}

/* A faint printed-paper grain so the flat colour isn't perfectly flat. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

::selection { background: var(--acid); color: var(--ink); }

a { color: var(--acid); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

:focus-visible { outline: 3px dashed var(--acid); outline-offset: 2px; }

h1, h2, h3 { margin: 0; font-weight: 400; }

code { font-family: var(--mono); background: var(--ink-3); padding: 1px 5px; border: 1px solid var(--line); }

/* --- masthead ------------------------------------------------------------ */

.masthead {
  border-bottom: var(--rule) solid var(--acid);
  background: var(--ink-2);
}

.masthead__row {
  max-width: 1180px;
  margin: 0 auto;
  padding: 12px var(--pad);
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.brand { display: inline-flex; align-items: center; gap: 9px; font-family: var(--display); letter-spacing: 0.05em; }
.brand__mark { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; display: block; border: 2px solid var(--acid); box-shadow: 2px 2px 0 var(--plum-2); }
.brand__word { font-size: 21px; color: var(--bone); }
.brand__dot { color: var(--acid); font-size: 21px; }
.brand:hover { text-decoration: none; }

.nav { display: flex; gap: 4px; flex-wrap: wrap; margin-right: auto; }
.nav a {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--dim);
  padding: 6px 10px;
  border: 1px solid transparent;
}
.nav a:hover { color: var(--acid); text-decoration: none; }
.nav a.is-active { color: var(--ink); background: var(--acid); }

.who { display: flex; align-items: center; gap: 10px; }
.who form { display: inline; }
.who__chip { display: inline-flex; align-items: center; gap: 8px; color: var(--bone); }
.who__chip:hover { text-decoration: none; }
.who__name { font-size: 13px; }
.who__chip:hover .who__name { color: var(--acid); }

.chip {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  flex: 0 0 auto;
  background: var(--sw, var(--acid));
  color: var(--ink);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  border: 2px solid var(--ink);
  box-shadow: 2px 2px 0 var(--plum-2);
  vertical-align: middle;
}

/* --- buttons ------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--mono);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 13px;
  padding: 11px 18px;
  border: var(--rule) solid var(--acid);
  background: transparent;
  color: var(--bone);
  cursor: pointer;
  transition: transform 0.06s ease, box-shadow 0.06s ease;
}
.btn:hover { text-decoration: none; transform: translate(-2px, -2px); box-shadow: 4px 4px 0 var(--plum-2); }
.btn:active { transform: translate(0, 0); box-shadow: none; }
.btn--solid { background: var(--acid); color: var(--ink); border-color: var(--acid); }
.btn--solid:hover { background: var(--acid-2); }
.btn--ghost { border-color: var(--line-2); color: var(--dim); }
.btn--ghost:hover { color: var(--acid); border-color: var(--acid); }
.btn--sm { padding: 7px 12px; font-size: 11px; }
.btn--xs { padding: 4px 8px; font-size: 10px; letter-spacing: 0.06em; }
.btn--lg { padding: 15px 26px; font-size: 16px; }
.btn--full { width: 100%; }

/* --- ticker -------------------------------------------------------------- */

.ticker {
  background: var(--plum);
  border-bottom: var(--rule) solid var(--acid);
  overflow: hidden;
  white-space: nowrap;
}
.ticker__track {
  display: inline-block;
  padding: 7px 0;
  animation: slide 48s linear infinite;
}
.ticker:hover .ticker__track { animation-play-state: paused; }
.tick__item {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--acid);
  padding: 0 26px;
  border-right: 1px solid var(--line);
}
.tick__item b { color: var(--bone); }
@keyframes slide { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker__track { animation: none; } }

/* --- page shell ---------------------------------------------------------- */

.page {
  max-width: 1180px;
  margin: 0 auto;
  padding: var(--pad);
  display: flex;
  flex-direction: column;
  gap: clamp(18px, 2.4vw, 30px);
}

.panel {
  background: var(--ink-2);
  border: var(--rule) solid var(--line);
  padding: var(--pad);
}
.panel__title {
  font-family: var(--display);
  font-size: 22px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--bone);
  padding-bottom: 8px;
  margin-bottom: 16px;
  border-bottom: var(--rule) solid var(--acid);
}
.panel__head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.panel__head .panel__title { flex: 1 1 auto; }
.panel__lede { color: var(--dim); margin: 0 0 16px; }
.panel__fine { color: var(--dim); font-size: 12px; margin: 12px 0 0; }
.panel__acts { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 4px; }
.link { font-size: 12px; text-transform: uppercase; letter-spacing: 0.12em; }

/* --- hero ---------------------------------------------------------------- */

.hero {
  display: grid;
  grid-template-columns: 1.45fr 0.9fr;
  gap: clamp(18px, 2.4vw, 30px);
  align-items: start;
}

.hero__left { padding-top: 6px; }
.kicker {
  margin: 0 0 6px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.3em;
  color: var(--acid);
}
.subject {
  font-family: var(--display);
  font-size: clamp(52px, 10vw, 116px);
  line-height: 0.86;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--bone);
  text-shadow: 4px 4px 0 var(--plum);
  word-break: break-word;
}
.bigclock {
  font-size: clamp(38px, 8.4vw, 92px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--acid);
  margin: 14px 0 4px;
  font-variant-numeric: tabular-nums;
}
.hero__cap {
  margin: 0;
  color: var(--dim);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.hero__cap b { color: var(--bone); }

/* --- status -------------------------------------------------------------- */

.status {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 28px);
  flex-wrap: wrap;
  border: var(--rule) solid var(--line-2);
  padding: 16px var(--pad);
}
.status__flag {
  font-family: var(--display);
  font-size: clamp(20px, 3vw, 30px);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
}
.status__body { flex: 1 1 300px; }
.status__reason { margin: 0; font-size: 17px; color: var(--bone); }
.status__reason em { color: var(--dim); font-style: italic; }
.status__meta { margin: 4px 0 0; color: var(--dim); font-size: 13px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.status__meta b { color: var(--bone); }
.status__clock {
  font-size: clamp(30px, 5vw, 52px);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  margin: 6px 0 0;
  letter-spacing: -0.01em;
}
.status__hint { margin: 2px 0 0; color: var(--dim); font-size: 12px; text-transform: uppercase; letter-spacing: 0.12em; }
.status__acts { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.status__acts form { display: inline; }

.status--out { background: var(--plum); border-color: var(--acid); }
.status--out .status__flag { color: var(--acid); }
.status--in .status__flag { color: var(--dim); }
.status--in .status__reason { color: var(--bone); }

.lamp {
  display: inline-block;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: var(--acid);
  box-shadow: 0 0 0 3px rgba(198, 255, 61, 0.18);
  animation: pulse 1.3s ease-in-out infinite;
  vertical-align: middle;
  margin-right: 6px;
}
.lamp--off { background: #4a3a5c; box-shadow: none; animation: none; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
@media (prefers-reduced-motion: reduce) { .lamp { animation: none; } }

/* --- punch panel --------------------------------------------------------- */

.panel--punch, .panel--gate, .panel--busy { background: var(--ink-2); }
.panel--punch { border-color: var(--acid); }
.panel--gate { border-style: dashed; }
.panel--busy { border-color: var(--line-2); }

.reasons {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: 1fr;
  gap: 8px;
  margin: 4px 0 18px;
}
.reason input { position: absolute; opacity: 0; pointer-events: none; }
.reason { display: flex; }
.reason__label {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 9px 11px;
  border: var(--rule) solid var(--line);
  color: var(--bone);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  cursor: pointer;
  text-align: center;
  transition: background 0.08s ease, color 0.08s ease;
}
.reason__label:hover { border-color: var(--acid); }
.reason input:checked + .reason__label {
  background: var(--acid);
  color: var(--ink);
  border-color: var(--acid);
  font-weight: 700;
}
.reason input:focus-visible + .reason__label { outline: 3px dashed var(--acid); outline-offset: 2px; }

.field { display: block; margin-bottom: 14px; }
.field__label {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--dim);
  margin-bottom: 6px;
}
.field__hint { color: var(--plum-2); text-transform: none; letter-spacing: 0; }
.field__input {
  width: 100%;
  font-family: var(--mono);
  font-size: 14px;
  padding: 11px 12px;
  background: var(--ink-3);
  border: var(--rule) solid var(--line);
  color: var(--bone);
}
.field__input::placeholder { color: #6f6086; }
.field__input:focus { border-color: var(--acid); outline: none; }
.field__input--inline { width: auto; display: inline-block; padding: 6px 8px; }

/* --- stats --------------------------------------------------------------- */

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: var(--rule) solid var(--line);
  background: var(--ink-2);
}
.stat {
  padding: 18px var(--pad);
  border-left: var(--rule) solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.stat:first-child { border-left: 0; }
.stat__label { font-size: 11px; text-transform: uppercase; letter-spacing: 0.16em; color: var(--acid); }
.stat__value { font-size: clamp(22px, 3vw, 32px); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--bone); }
.stat__sub { font-size: 11px; color: var(--dim); }

.translated {
  margin: 0;
  padding: 14px var(--pad);
  border-left: 6px solid var(--acid);
  background: var(--ink-2);
  color: var(--dim);
  font-size: 13px;
}
.translated b { color: var(--acid); }

/* --- grids & charts ------------------------------------------------------ */

.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(18px, 2.4vw, 30px); }
.grid2 > *, .hero > * { min-width: 0; }
.tablewrap { max-width: 100%; }

.charts { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(18px, 2.4vw, 30px); }
.chart { background: var(--ink-2); border: var(--rule) solid var(--line); padding: var(--pad); }
.chart__title {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--bone);
  margin-bottom: 18px;
}
.chart__title span { color: var(--dim); letter-spacing: 0.04em; text-transform: none; }

.bars { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.bar { display: grid; grid-template-columns: minmax(96px, 136px) 1fr minmax(84px, auto); align-items: center; gap: 12px; }
.bar__label { font-size: 12.5px; color: var(--bone); line-height: 1.15; overflow-wrap: anywhere; }
.bar__track { height: 16px; background: var(--ink-3); border: 1px solid var(--line); }
.bar__fill { display: block; height: 100%; background: var(--acid); }
.bar__value { font-size: 12px; color: var(--dim); text-align: right; font-variant-numeric: tabular-nums; }

.bars--v { flex-direction: row; align-items: flex-end; gap: 3px; height: 150px; }
.vbar { flex: 1 1 0; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 5px; }
.vbar i {
  display: block;
  width: 66%;
  min-height: 3px;
  background: var(--acid);
  border: 1px solid var(--ink);
}
.vbar:hover i { background: var(--grape); }
.bars--v .vbar i { background: var(--acid); }
.bars--v7 .vbar i { background: var(--acid-2); }
.vbar em { font-size: 9px; color: var(--dim); font-style: normal; height: 12px; letter-spacing: 0.05em; }

.empty { color: var(--dim); font-style: italic; margin: 0; }

/* --- ledger table -------------------------------------------------------- */

.tablewrap { overflow-x: auto; border: var(--rule) solid var(--line); background: var(--ink-2); }
.ledger { width: 100%; border-collapse: collapse; min-width: 680px; }
.ledger thead th {
  text-align: left;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--acid);
  background: var(--plum);
  padding: 10px 14px;
  border-bottom: var(--rule) solid var(--acid);
  white-space: nowrap;
}
.ledger td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: top; font-size: 13px; }
.ledger tbody tr:nth-child(even) { background: rgba(198, 255, 61, 0.03); }
.ledger tbody tr:hover { background: rgba(198, 255, 61, 0.07); }
.cell-id { color: var(--acid); font-weight: 700; white-space: nowrap; }
.cell-when b { display: block; color: var(--bone); font-weight: 700; }
.cell-when span { color: var(--dim); font-size: 11px; }
.cell-reason { color: var(--bone); }
.cell-note { display: block; color: var(--dim); font-size: 12px; font-style: italic; }
.cell-who { white-space: nowrap; }
.cell-dur { font-variant-numeric: tabular-nums; font-weight: 700; color: var(--acid); white-space: nowrap; }
.running { color: var(--ink); background: var(--acid); padding: 1px 6px; font-size: 11px; text-transform: uppercase; }
.is-void { opacity: 0.45; }
.is-void .cell-reason { text-decoration: line-through; }
.stamp-void {
  display: inline-block;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--hot);
  border: 1px solid var(--hot);
  padding: 0 4px;
  transform: rotate(-2deg);
}

/* --- ledger page --------------------------------------------------------- */

.page__title {
  font-family: var(--display);
  font-size: clamp(34px, 6vw, 60px);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.95;
  color: var(--bone);
  text-shadow: 3px 3px 0 var(--plum);
}
.page__lede { color: var(--dim); max-width: 62ch; }
.page__lede b { color: var(--acid); }

.filters { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 14px; }
.pill {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 6px 11px;
  border: 1px solid var(--line);
  color: var(--dim);
}
.pill:hover { border-color: var(--acid); color: var(--acid); text-decoration: none; }
.pill.is-on { background: var(--acid); color: var(--ink); border-color: var(--acid); }
.pill--gap { border: none; color: var(--dim); }
.pager { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }

.ledgerhead { border-bottom: var(--rule) solid var(--line); padding-bottom: 18px; }

/* --- auth ---------------------------------------------------------------- */

.auth { display: grid; place-items: start center; padding-top: 20px; }
.auth__card { width: min(460px, 100%); background: var(--ink-2); border: var(--rule) solid var(--acid); padding: var(--pad); box-shadow: var(--shadow); }
.auth__title { font-family: var(--display); font-size: 40px; text-transform: uppercase; letter-spacing: 0.03em; margin-bottom: 8px; }
.auth__lede { color: var(--dim); margin: 0 0 20px; }
.auth__alt { color: var(--dim); font-size: 13px; margin: 16px 0 0; }
.auth__card--err { border-color: var(--hot); }
.err__code { font-family: var(--display); font-size: 90px; line-height: 1; color: var(--hot); margin: 0; }

.alert {
  border: var(--rule) solid var(--acid);
  background: var(--plum);
  color: var(--bone);
  padding: 10px 12px;
  font-size: 13px;
  margin: 0 0 18px;
}
.alert::before { content: "! "; color: var(--acid); font-weight: 700; }

/* --- embed --------------------------------------------------------------- */

.embed__preview { margin: 0; padding: 16px; background: var(--ink-3); border: 1px solid var(--line); overflow-x: auto; }
.code {
  margin: 0;
  padding: 14px;
  background: var(--ink-3);
  border: 1px solid var(--line);
  color: var(--acid);
  font-size: 12px;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-all;
  cursor: copy;
}

/* --- admin strip --------------------------------------------------------- */

.admin { border: var(--rule) dashed var(--plum-2); background: var(--ink-2); padding: 12px var(--pad); }
.admin form { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.admin__tag {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  background: var(--plum-2);
  color: var(--bone);
  padding: 3px 8px;
}
.admin__field { font-size: 13px; color: var(--dim); display: inline-flex; align-items: center; gap: 8px; }

/* --- footer -------------------------------------------------------------- */

.foot {
  max-width: 1180px;
  margin: 30px auto 0;
  padding: 18px var(--pad) 40px;
  border-top: var(--rule) solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  color: var(--dim);
  font-size: 12px;
}
.foot__meta { color: var(--plum-2); }

/* --- responsive ---------------------------------------------------------- */

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
  .grid2, .charts { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n + 3) { border-top: var(--rule) solid var(--line); }
  .masthead__row { gap: 10px; }
  .nav { order: 3; width: 100%; margin-right: 0; }
}

@media (max-width: 520px) {
  .stats { grid-template-columns: 1fr; }
  .stat { border-left: 0; }
  .stat + .stat { border-top: var(--rule) solid var(--line); }
  .reasons { grid-template-columns: 1fr; }
  .bar { grid-template-columns: 1fr 2fr; }
  .bar__value { grid-column: 2; text-align: left; }
}

/* ==========================================================================
   Instruments — the odometer, the lobby, the barcode, the dial, the tally,
   the staircase, and the receipt.
   ========================================================================== */

/* --- odometer ------------------------------------------------------------ */

.odometer { display: flex; align-items: flex-end; gap: 8px; margin: 20px 0 8px; }
.od__group { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.od__digits { display: flex; gap: 3px; }
.od__d {
  display: grid;
  place-items: center;
  min-width: 0.66em;
  padding: 4px 7px;
  font-size: clamp(28px, 6vw, 60px);
  font-weight: 700;
  line-height: 1;
  color: var(--ink);
  background: var(--acid);
  border: 2px solid var(--ink);
  box-shadow: inset 0 -6px 0 rgba(0, 0, 0, 0.18), 4px 4px 0 var(--plum-2);
  font-variant-numeric: tabular-nums;
}
.od__lab { font-size: 9px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--dim); }
.od__sep { font-size: clamp(26px, 5vw, 54px); font-weight: 700; color: var(--plum-2); padding-bottom: 22px; }

.hero__status {
  margin: 16px 0 0;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--bone);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.hero__status b { font-variant-numeric: tabular-nums; }
.hero__status em { color: var(--dim); font-style: italic; text-transform: none; letter-spacing: 0; }
.hero__status.is-out { color: var(--acid); }

/* --- lobby --------------------------------------------------------------- */

.panel--lobby { border-color: var(--acid); }
.lobby__state { font-size: 11px; text-transform: uppercase; letter-spacing: 0.14em; color: var(--dim); }
.lobby__state.is-out { color: var(--acid); }

.slot {
  display: flex;
  align-items: center;
  gap: 12px;
  border: var(--rule) solid var(--line);
  padding: 12px;
  background: var(--ink-3);
  position: relative;
  overflow: hidden;
}
.slot--afk {
  border-color: var(--acid);
  background: repeating-linear-gradient(45deg, #2e0d48, #2e0d48 10px, #3b1160 10px, #3b1160 20px);
}
.slot__tag { font-size: 10px; color: var(--dim); letter-spacing: 0.1em; position: absolute; top: 5px; right: 9px; }
.slot__ava {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  overflow: hidden;
  background: var(--acid);
  color: var(--ink);
  font-family: var(--display);
  font-size: 22px;
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--plum-2);
}
.slot__ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
.slot--afk .slot__ava { background: #20102f; color: var(--acid); }
.slot__meta { display: flex; flex-direction: column; flex: 1 1 auto; min-width: 0; }
.slot__name { font-family: var(--display); font-size: 22px; text-transform: uppercase; letter-spacing: 0.03em; color: var(--bone); }
.slot__state { font-size: 11px; text-transform: uppercase; letter-spacing: 0.14em; color: var(--dim); }
.slot--afk .slot__state { color: var(--acid); }
.slot__time { font-weight: 700; font-variant-numeric: tabular-nums; font-size: 20px; color: var(--acid); }
.slot__badge { background: var(--acid); color: var(--ink); padding: 4px 9px; font-size: 12px; font-weight: 700; letter-spacing: 0.16em; }

.lobby__controls { margin-top: 16px; border-top: var(--rule) solid var(--line); padding-top: 16px; }
.waiting { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.waiting__label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.2em; color: var(--dim); }
.waiting__chips { display: flex; gap: 8px; flex-wrap: wrap; }
.wchip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); padding: 3px 8px 3px 3px; font-size: 12px; color: var(--dim); }
.wchip b { color: var(--acid); }
.wchip .chip { width: 20px; height: 20px; font-size: 9px; box-shadow: none; }

/* --- barcode ------------------------------------------------------------- */

.barcode { display: flex; flex-direction: column; gap: 3px; margin-top: 8px; }
.barcode__axis { display: grid; grid-template-columns: 34px 1fr 46px; gap: 10px; align-items: center; }
.axis__cells { display: grid; grid-template-columns: repeat(24, 1fr); gap: 2px; }
.axis__cells span { text-align: center; font-size: 9px; color: var(--dim); }
.brow { display: grid; grid-template-columns: 34px 1fr 46px; gap: 10px; align-items: center; }
.brow__lab { display: flex; flex-direction: column; align-items: center; line-height: 1.05; font-size: 10px; color: var(--dim); }
.brow__lab b { color: var(--bone); font-size: 11px; }
.brow.is-today .brow__lab b { color: var(--acid); }
.brow__cells { display: grid; grid-template-columns: repeat(24, 1fr); gap: 2px; }
.bcell { display: block; height: 17px; background: var(--ink-3); border: 1px solid rgba(198, 255, 61, 0.08); }
.bcell.is-on { background: var(--acid); border-color: var(--acid); opacity: calc(0.4 + var(--i, 0.5) * 0.6); }
.brow.is-today .bcell { outline: 1px solid rgba(198, 255, 61, 0.25); outline-offset: -1px; }
.brow__tot { font-size: 10px; color: var(--dim); text-align: right; font-variant-numeric: tabular-nums; }

/* --- radial dial --------------------------------------------------------- */

.dialwrap { display: grid; place-items: center; padding: 4px 0 0; }
.radial { width: min(340px, 82%); height: auto; }
.rad__ring { fill: none; stroke: var(--line); stroke-width: 1; }
.rad__wedge { fill: var(--acid); }
.rad__wedge.is-empty { fill: #33224a; }
.rad__wedge:hover { fill: var(--grape); }
.rad__tick { fill: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.1em; }
.rad__cta { fill: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.18em; }
.rad__peak { fill: var(--acid); font-family: var(--display); font-size: 30px; letter-spacing: 0.02em; }
.rad__sum { fill: var(--dim); font-family: var(--mono); font-size: 9px; letter-spacing: 0.1em; }

/* --- tally --------------------------------------------------------------- */

.tally { display: flex; flex-wrap: wrap; gap: 20px 26px; align-items: flex-end; padding: 14px 2px 10px; border-bottom: var(--rule) solid var(--line); }
.tally__g { position: relative; display: inline-flex; align-items: flex-end; gap: 4px; padding: 0 5px 0 0; }
.tally__st { display: block; width: 4px; height: var(--h, 20px); background: var(--t, var(--acid)); }
.tally__diag {
  position: absolute;
  left: -1px;
  right: 4px;
  top: 50%;
  height: 3px;
  background: var(--t, var(--acid));
  transform: translateY(-50%) rotate(-16deg);
  transform-origin: center;
}
.tally-cap { margin: 12px 0 0; font-size: 12px; color: var(--dim); }

/* --- staircase ----------------------------------------------------------- */

.stair { width: 100%; height: auto; display: block; }
.stair__grid { stroke: var(--line); stroke-width: 1; stroke-dasharray: 3 6; vector-effect: non-scaling-stroke; }
.stair__area { fill: rgba(122, 43, 175, 0.34); }
.stair__line { fill: none; stroke: var(--acid); stroke-width: 2.5; vector-effect: non-scaling-stroke; }
.stair__dot { fill: var(--acid); stroke: var(--ink); stroke-width: 2; }
.stair__cap { margin: 10px 0 0; font-size: 12px; color: var(--dim); }
.stair__cap b { color: var(--acid); font-size: 15px; }

/* --- receipt ------------------------------------------------------------- */

.grid2--receipt { grid-template-columns: minmax(250px, 0.74fr) 1.26fr; }
.grid2--receipt .ledger { min-width: 0; }
.grid2--receipt .ledger thead th,
.grid2--receipt .ledger td { padding-left: 9px; padding-right: 9px; }
.receipt { display: flex; justify-content: center; }
.receipt__paper {
  position: relative;
  width: min(340px, 100%);
  background: var(--bone);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 12px;
  padding: 22px 20px 30px;
  box-shadow: 6px 6px 0 var(--plum-2);
  transform: rotate(-0.6deg);
}
.receipt__paper::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 9px;
  background:
    linear-gradient(135deg, var(--ink) 50%, transparent 50%) 0 0 / 12px 12px repeat-x,
    linear-gradient(45deg, var(--ink) 50%, transparent 50%) 6px 0 / 12px 12px repeat-x;
}
.receipt__brand { font-family: var(--display); font-size: 19px; letter-spacing: 0.02em; text-align: center; margin: 0; }
.receipt__sub { text-align: center; letter-spacing: 0.24em; font-size: 10px; margin: 3px 0 10px; }
.receipt__rule { text-align: center; color: #8a7c96; margin: 8px 0; letter-spacing: 2px; white-space: nowrap; overflow: hidden; }
.receipt__row { display: flex; justify-content: space-between; gap: 12px; padding: 2px 0; }
.receipt__row--big { font-weight: 700; font-size: 16px; border-top: 1px dashed #b3a794; border-bottom: 1px dashed #b3a794; padding: 7px 0; margin: 6px 0; }
.receipt__note { margin: 8px 0 0; font-style: italic; color: #5b4d67; }
.receipt__code { display: flex; align-items: flex-end; justify-content: center; gap: 2px; height: 26px; margin: 14px 0 6px; }
.receipt__code i { display: block; width: 2px; background: var(--ink); }
.receipt__thanks { text-align: center; letter-spacing: 0.3em; font-size: 11px; margin: 6px 0 0; }
.receipt__fine { text-align: center; font-size: 10px; color: #8a7c96; margin: 4px 0 0; }
.receipt__none { text-align: center; margin: 26px 0; color: #5b4d67; }

@media (max-width: 900px) {
  .grid2--receipt { grid-template-columns: 1fr; }
  .od__d { padding: 3px 5px; }
}

/* --- meter --------------------------------------------------------------- */

.meter {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 16px;
  background: var(--plum);
  border: var(--rule) solid var(--acid);
  box-shadow: 5px 5px 0 rgba(0, 0, 0, 0.5);
  max-width: calc(100vw - 24px);
}
.meter__lamp { width: 12px; height: 12px; border-radius: 50%; background: var(--acid); animation: pulse 1.3s ease-in-out infinite; flex: 0 0 auto; }
.meter__label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.2em; color: var(--acid); }
.meter__clock { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--bone); }
.meter__reason { font-size: 12px; color: var(--dim); }
.meter form { display: inline; }
@media (prefers-reduced-motion: reduce) { .meter__lamp { animation: none; } }
@media (max-width: 640px) {
  .meter { gap: 8px; padding: 8px 10px; }
  .meter__label, .meter__reason { display: none; }
  .meter__clock { font-size: 18px; }
}
