/* RECEIPTS — LAB KOL tracker. Skin shares the LAB design system with
   lab-launchpad (dark ink + acid) and lab-landing (Rubik / Dela Gothic One). */

@font-face {
  font-family: "Rubik";
  src: url("/fonts/Rubik.woff2") format("woff2");
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Dela Gothic One";
  src: url("/fonts/DelaGothicOne.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --acid: #a0ff06;
  --acid-soft: #cfff8a;
  --ink: #050505;
  --panel: #101208;
  --panel-2: #14160c;
  --line: #343434;
  --line-soft: #232323;
  --up: #4daf62;
  --down: #d3485d;
  --text: #f5f6f1;
  --muted: #9b9b9b;
  --dim: #858585;
  --orange: #ffb649;
  --font: "Rubik", ui-sans-serif, system-ui, sans-serif;
  --display: "Dela Gothic One", "Rubik", sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, monospace;
  --max: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--ink); }
body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 78% 3%, rgba(160, 255, 6, .08), transparent 26rem),
    #050505;
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--acid); outline-offset: 2px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* ── header ── */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(5,5,5,.86); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.header-row { display: flex; align-items: center; gap: 18px; height: 60px; }
.brand { display: flex; align-items: baseline; gap: 10px; text-decoration: none; }
.brand-word { font-family: var(--display); font-size: 17px; letter-spacing: .02em; color: var(--text); }
.brand-word em { font-style: normal; color: var(--acid); }
.brand-sub { font-size: 10px; letter-spacing: .28em; color: var(--dim); text-transform: uppercase; }
.header-nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.header-nav a {
  text-decoration: none; color: var(--muted); font-size: 13px; font-weight: 600;
  padding: 8px 12px; border-radius: 10px; transition: color .15s, background .15s;
}
.header-nav a:hover, .header-nav a.active { color: var(--text); background: rgba(255,255,255,.05); }
.cta-btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--acid); color: #0a0f00; border: 0; cursor: pointer;
  font-weight: 800; font-size: 13px; padding: 9px 16px; border-radius: 12px;
  text-decoration: none; transition: transform .15s, box-shadow .15s;
}
.cta-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 24px rgba(160,255,6,.25); }
.cta-btn.ghost { background: transparent; color: var(--acid); border: 1px solid rgba(160,255,6,.4); }
.cta-btn.ghost:hover { box-shadow: none; background: rgba(160,255,6,.08); }

/* ── verdict ticker ── */
.ticker-shell { overflow: hidden; border-bottom: 1px solid var(--line-soft); background: #080908; }
.verdict-ticker { height: 34px; display: flex; align-items: center; width: max-content; animation: ticker 55s linear infinite; }
.verdict-ticker:hover { animation-play-state: paused; }
.ticker-item {
  display: flex; align-items: center; gap: 8px; padding: 0 20px;
  border-right: 1px solid var(--line-soft); font-size: 10.5px; white-space: nowrap;
  color: var(--muted); text-decoration: none;
}
.ticker-item:hover { background: rgba(160,255,6,.06); }
.ticker-item b { color: var(--text); letter-spacing: .04em; }
.ticker-item .t-dt { font-family: var(--mono); color: var(--acid); font-variant-numeric: tabular-nums; }
.ticker-item .t-flag { color: var(--orange); }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ── case hero: the headline is the verdict, the chart is the evidence ── */
.case-hero { padding: 50px 0 0; }
.case-eyebrow {
  margin: 0 0 14px; font-family: var(--mono); font-size: 10.5px; letter-spacing: .22em;
  text-transform: uppercase; color: var(--dim);
}
.case-headline {
  font-family: var(--display); font-size: clamp(24px, 4vw, 46px);
  line-height: 1.14; margin: 0; letter-spacing: .01em; max-width: 24ch;
}
.case-headline em { font-style: normal; color: var(--acid); }
.case-headline a {
  color: inherit; text-decoration: underline; text-decoration-thickness: 3px;
  text-decoration-color: rgba(160,255,6,.55); text-underline-offset: 7px;
}
.case-headline a:hover { text-decoration-color: var(--acid); }
.case-lede { color: var(--dim); font-size: 13px; line-height: 1.7; margin: 18px 0 0; max-width: 74ch; }

.case-stage { position: relative; margin-top: 26px; border-bottom: 1px solid var(--line-soft); }
.case-stage canvas { width: 100%; height: 430px; display: block; }

/* the receipt: a paper artifact on a dark terminal — the one loud thing */
.receipt-paper {
  --paper: #f2efe8;
  position: absolute; right: max(22px, calc((100vw - var(--max)) / 2 + 20px)); bottom: 30px;
  width: 272px; background: var(--paper); color: #17150f;
  font-family: var(--mono); text-decoration: none;
  padding: 14px 16px 12px; display: flex; flex-direction: column; gap: 6px;
  box-shadow: 0 22px 60px rgba(0,0,0,.55);
  transform: rotate(1.6deg); transition: transform .2s ease;
}
.receipt-paper:hover { transform: rotate(.4deg) translateY(-3px); }
.receipt-teeth {
  position: absolute; left: 0; right: 0; height: 7px;
  background:
    linear-gradient(45deg, var(--paper) 3.5px, transparent 0) 0 0 / 14px 7px repeat-x,
    linear-gradient(-45deg, var(--paper) 3.5px, transparent 0) 7px 0 / 14px 7px repeat-x;
}
.receipt-teeth.top { top: -7px; transform: scaleY(-1); }
.receipt-teeth.bottom { bottom: -7px; }
.r-head {
  font-size: 9px; letter-spacing: .2em; text-align: center;
  border-bottom: 1px dashed rgba(23,21,15,.3); padding-bottom: 7px; margin-bottom: 2px;
}
.r-line { display: flex; justify-content: space-between; gap: 10px; font-size: 10.5px; }
.r-line b { font-weight: 700; text-align: right; }
.r-rule { border-top: 1px dashed rgba(23,21,15,.25); margin: 3px 0; }
.r-open { text-align: center; font-weight: 800; font-size: 10px; letter-spacing: .16em; margin-top: 2px; }
.r-stamp {
  position: absolute; top: 44%; left: 50%;
  transform: translate(-50%, -50%) rotate(-9deg);
  border: 2.5px solid rgba(211,72,93,.72); color: rgba(211,72,93,.78);
  font-family: var(--font); font-weight: 900; font-size: 14px; letter-spacing: .12em;
  padding: 4px 10px; border-radius: 4px; pointer-events: none; white-space: nowrap;
}
.r-barcode {
  height: 24px; margin-top: 5px; opacity: .82;
  background: repeating-linear-gradient(90deg,
    #17150f 0 2px, transparent 2px 4px, #17150f 4px 5px, transparent 5px 9px,
    #17150f 9px 12px, transparent 12px 14px, #17150f 14px 15px, transparent 15px 19px);
}

/* ── sections ── */
.section { padding: 40px 0; }
.section-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 18px; }
.section-head h2 { font-family: var(--display); font-size: clamp(19px, 2.6vw, 26px); margin: 0; }
.section-head span { color: var(--dim); font-size: 12px; }

/* ── board table ── */
.board { border: 1px solid var(--line-soft); border-radius: 18px; overflow: hidden; background: var(--panel); }
.board-row {
  display: grid; grid-template-columns: minmax(180px, 1.4fr) repeat(4, minmax(86px, 1fr)) minmax(120px, 1fr);
  gap: 10px; align-items: center; padding: 14px 18px;
  border-bottom: 1px solid var(--line-soft); text-decoration: none;
  transition: background .15s; cursor: pointer;
}
.board-row:last-child { border-bottom: 0; }
.board-row:hover { background: rgba(160,255,6,.04); }
.board-row.head { cursor: default; background: #0b0c07; font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--dim); padding-block: 10px; }
.board-row.head:hover { background: #0b0c07; }
.b-kol { display: flex; align-items: center; gap: 12px; min-width: 0; }
.avatar {
  width: 38px; height: 38px; border-radius: 12px; flex: none;
  font-family: var(--display); font-size: 15px; color: #0a0f00;
  display: flex; align-items: center; justify-content: center;
}
.b-kol .names { min-width: 0; }
.b-kol .names b { display: block; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.b-kol .names span { font-size: 11.5px; color: var(--dim); }
.b-num { font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 14px; }
.b-num.acid { color: var(--acid); font-weight: 700; }
.b-num.down { color: var(--down); }
.b-num.up { color: var(--up); }
.b-num small { display: block; font-family: var(--font); font-size: 9.5px; letter-spacing: .1em; color: var(--dim); text-transform: uppercase; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip {
  font-size: 9.5px; font-weight: 700; letter-spacing: .06em; padding: 3px 8px;
  border-radius: 999px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap;
}
.chip.warn { color: var(--orange); border-color: rgba(255,182,73,.4); }
.chip.bad { color: var(--down); border-color: rgba(211,72,93,.42); }
.chip.good { color: var(--up); border-color: rgba(77,175,98,.42); }
.chip.acid { color: var(--acid); border-color: rgba(160,255,6,.4); }

/* ── feed ── */
.feed { display: grid; gap: 10px; }
.call-row {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center;
  border: 1px solid var(--line-soft); border-radius: 16px; background: var(--panel);
  padding: 14px 16px; text-decoration: none; transition: background .15s, border-color .15s;
}
.call-row:hover { background: rgba(160,255,6,.04); border-color: rgba(160,255,6,.25); }
.call-row .avatar { width: 34px; height: 34px; font-size: 13px; }
.call-main { min-width: 0; }
.call-main .c-top { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; font-size: 12px; color: var(--dim); }
.call-main .c-top b { color: var(--text); font-size: 13px; }
.dir { font-family: var(--mono); font-size: 10px; font-weight: 800; padding: 1px 7px; border-radius: 6px; }
.dir.long { color: var(--up); background: rgba(77,175,98,.12); }
.dir.short { color: var(--down); background: rgba(211,72,93,.12); }
.call-quote {
  margin: 6px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.call-quote.paraphrase { font-style: italic; }
.call-side { text-align: right; }
.call-side .t-dt { font-family: var(--mono); font-size: 15px; color: var(--acid); font-weight: 700; }
.call-side small { display: block; font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); margin-top: 2px; }

/* ── how strip ── */
.how-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.how-cell { border: 1px solid var(--line-soft); border-radius: 16px; background: var(--panel); padding: 18px; }
.how-cell b { font-family: var(--display); font-size: 14px; display: block; margin-bottom: 8px; }
.how-cell b i { font-style: normal; color: var(--acid); margin-right: 8px; }
.how-cell p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; }

.honesty-note {
  margin-top: 16px; border: 1px dashed rgba(160,255,6,.3); border-radius: 14px;
  padding: 14px 16px; color: var(--dim); font-size: 12px; line-height: 1.6; background: rgba(160,255,6,.03);
}
.honesty-note b { color: var(--muted); }

/* ── kol page ── */
.kol-head { display: flex; align-items: center; gap: 18px; padding: 40px 0 8px; flex-wrap: wrap; }
.kol-head .avatar { width: 62px; height: 62px; border-radius: 18px; font-size: 24px; }
.kol-id h1 { font-family: var(--display); margin: 0; font-size: clamp(22px, 3.4vw, 34px); }
.kol-id .k-sub { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; color: var(--dim); font-size: 12.5px; margin-top: 6px; }
.k-addr { font-family: var(--mono); font-size: 11.5px; color: var(--muted); text-decoration: none; border-bottom: 1px dotted var(--line); }
.k-addr:hover { color: var(--acid); }
.kol-head .cta-btn { margin-left: auto; }
.verdict-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 22px 0; }
.v-card { border: 1px solid var(--line-soft); border-radius: 16px; background: var(--panel); padding: 16px; }
.v-card b { display: block; font-family: var(--display); font-size: clamp(18px, 2.4vw, 26px); color: var(--acid); }
.v-card.down b { color: var(--down); }
.v-card.up b { color: var(--up); }
.v-card.plain b { color: var(--text); }
.v-card span { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.v-card small { display: block; margin-top: 6px; color: var(--dim); font-size: 11px; line-height: 1.45; }

.panel-cols { display: grid; grid-template-columns: 1.25fr .75fr; gap: 16px; align-items: start; }
.panel-box { border: 1px solid var(--line-soft); border-radius: 18px; background: var(--panel); overflow: hidden; }
.panel-box > h3 {
  margin: 0; padding: 13px 18px; font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--dim); border-bottom: 1px solid var(--line-soft); background: #0b0c07;
}
.panel-box .call-row { border: 0; border-bottom: 1px solid var(--line-soft); border-radius: 0; background: transparent; }
.panel-box .call-row:last-child { border-bottom: 0; }
.fact-list { margin: 0; padding: 8px 0; list-style: none; }
.fact-list li { display: flex; justify-content: space-between; gap: 14px; padding: 9px 18px; font-size: 13px; color: var(--muted); }
.fact-list li + li { border-top: 1px solid var(--line-soft); }
.fact-list b { font-family: var(--mono); color: var(--text); font-variant-numeric: tabular-nums; text-align: right; }
.fact-list b.acid { color: var(--acid); }
.fact-list b.down { color: var(--down); }
.fact-list b.up { color: var(--up); }

/* ── call page ── */
.call-hero { padding: 36px 0 0; }
.crumbs { font-size: 12px; color: var(--dim); margin-bottom: 14px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--acid); }
.quote-card {
  border: 1px solid var(--line-soft); border-left: 3px solid var(--acid); border-radius: 16px;
  background: var(--panel); padding: 18px 20px; margin: 14px 0 20px;
}
.quote-card .q-top { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; font-size: 12.5px; color: var(--dim); }
.quote-card .q-top b { color: var(--text); }
.quote-text { margin: 0; font-size: clamp(15px, 2.2vw, 19px); line-height: 1.55; color: var(--text); }
.quote-text.paraphrase { font-style: italic; color: var(--muted); }
.q-meta { display: flex; gap: 14px; margin-top: 12px; flex-wrap: wrap; font-size: 11.5px; color: var(--dim); }
.q-meta a { color: var(--muted); }
.q-meta a:hover { color: var(--acid); }

.chart-panel { border: 1px solid var(--line-soft); border-radius: 18px; background: var(--panel); padding: 16px; position: relative; }
.chart-panel .ch-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 10px; flex-wrap: wrap; }
.chart-panel .ch-head b { font-family: var(--display); font-size: 16px; }
.chart-panel .ch-head span { font-size: 11px; color: var(--dim); }
.chart-panel .tf { margin-left: auto; display: flex; gap: 4px; }
.tf button {
  background: transparent; border: 1px solid var(--line-soft); color: var(--muted);
  font-size: 11px; font-weight: 700; border-radius: 8px; padding: 4px 9px; cursor: pointer;
}
.tf button.active { color: #0a0f00; background: var(--acid); border-color: var(--acid); }
#callChart { width: 100%; height: 380px; display: block; cursor: crosshair; }
.chart-note { margin-top: 10px; font-size: 11px; color: var(--dim); display: flex; gap: 16px; flex-wrap: wrap; }
.lg { display: inline-flex; align-items: center; gap: 6px; }
.lg i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.lg.said i { background: var(--acid); }
.lg.buy i { background: var(--up); }
.lg.sell i { background: var(--down); }
.chart-status { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--dim); font-size: 13px; }

.join-facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 18px 0; }

/* ── footer ── */
.site-footer { border-top: 1px solid var(--line-soft); margin-top: 48px; padding: 26px 0 40px; }
.footer-row { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; color: var(--dim); font-size: 12px; }
.footer-row a { color: var(--muted); text-decoration: none; }
.footer-row a:hover { color: var(--acid); }
.footer-row .spacer { flex: 1; }

/* ── reveal animation ── */
[data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
[data-reveal].revealed { opacity: 1; transform: none; }

/* ── loading / empty ── */
.loading, .empty-state { padding: 60px 20px; text-align: center; color: var(--dim); font-size: 14px; }

/* ── avatar palettes (launchpad art-*) ── */
.art-acid { background: linear-gradient(135deg, #a0ff06, #3f6b00); }
.art-aqua { background: linear-gradient(135deg, #55e6c1, #0a5a4a); color: #eafff9; }
.art-ember { background: linear-gradient(135deg, #ff9a3c, #7a2d00); color: #fff3e8; }
.art-violet { background: linear-gradient(135deg, #b06bff, #3c1a66); color: #f4eaff; }
.art-rose { background: linear-gradient(135deg, #ff6b9d, #66102f); color: #ffeaf2; }
.art-ice { background: linear-gradient(135deg, #7cc7ff, #123c66); color: #eaf6ff; }
.art-sun { background: linear-gradient(135deg, #ffe066, #806000); color: #1a1400; }
.art-mono { background: linear-gradient(135deg, #d7d7d7, #3a3a3a); color: #101010; }

/* ── responsive ── */
@media (max-width: 960px) {
  .case-stage canvas { height: 300px; }
  .receipt-paper { position: relative; right: auto; bottom: auto; margin: 18px auto 0; transform: none; width: min(300px, calc(100% - 44px)); }
  .case-stage { padding-bottom: 24px; }
  .panel-cols { grid-template-columns: 1fr; }
  .verdict-grid, .join-facts { grid-template-columns: repeat(2, 1fr); }
  .how-strip { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .board-row { grid-template-columns: minmax(140px, 1.6fr) repeat(2, minmax(70px, 1fr)); }
  .board-row .hide-m { display: none; }
  .call-row { grid-template-columns: auto minmax(0, 1fr); }
  .call-side { grid-column: 2; text-align: left; display: flex; gap: 10px; align-items: baseline; }
  .kol-head .cta-btn { margin-left: 0; }
  #callChart { height: 280px; }
  .header-nav a.nav-link { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .verdict-ticker { animation: none; }
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  .receipt-paper { transition: none; }
}

/* utility rows (CSP: no inline style attributes) */
.crumbs-pad { padding-top: 22px; }
.cta-row { display: flex; gap: 12px; margin: 22px 0 10px; flex-wrap: wrap; }
.flags-row { margin-bottom: 8px; }

/* source attribution (validator: show whose words these are) */
.c-top .via { color: var(--dim); font-size: 11px; }
.q-note { margin: 10px 0 0; font-size: 11.5px; color: var(--dim); line-height: 1.55; border-top: 1px dashed var(--line-soft); padding-top: 8px; }
