@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,600&family=Public+Sans:ital,wght@0,400;0,500;0,600;0,700;1,400&family=IBM+Plex+Mono:wght@400;500&display=swap');

/* ════════════════════════════════════════════════════════════
   TOKENS — "Ink & Paper"
   Light = paper file, Dark = ink. Gold is document foil (receipt
   numbers), flag-red is reserved for the stamp + alerts.
   ════════════════════════════════════════════════════════════ */
:root,
[data-theme="light"] {
  --bg: #f3f4f0;
  --surface: #ffffff;
  --surface2: #eaece5;
  --border: #dcdfd6;
  --shadow: rgba(28, 34, 44, 0.07);
  --ink: #1d2530;
  --text: #232a34;
  --text-muted: #5b636e;
  --text-dim: #949ca6;
  --gold: #8c6a1d;
  --gold-dim: rgba(140, 106, 29, 0.12);
  --blue: #2757a5;
  --blue-dim: rgba(39, 87, 165, 0.10);
  --green: #22713b;
  --green-dim: rgba(34, 113, 59, 0.10);
  --purple: #6644b8;
  --purple-dim: rgba(102, 68, 184, 0.10);
  --orange: #a85511;
  --orange-dim: rgba(168, 85, 17, 0.10);
  --red: #b31942;
  --red-dim: rgba(179, 25, 66, 0.09);
  --stamp: #b31942;
  --hdr-bg: rgba(243, 244, 240, 0.88);
}

[data-theme="dark"] {
  --bg: #0d1420;
  --surface: #141d2d;
  --surface2: #1b2638;
  --border: #2a364d;
  --shadow: rgba(0, 0, 0, 0.35);
  --ink: #e9edf4;
  --text: #dde3ec;
  --text-muted: #93a0b2;
  --text-dim: #5c6a80;
  --gold: #d9b25c;
  --gold-dim: rgba(217, 178, 92, 0.13);
  --blue: #7ea6e8;
  --blue-dim: rgba(126, 166, 232, 0.12);
  --green: #57c075;
  --green-dim: rgba(87, 192, 117, 0.12);
  --purple: #b79bf0;
  --purple-dim: rgba(183, 155, 240, 0.12);
  --orange: #ee9a4d;
  --orange-dim: rgba(238, 154, 77, 0.12);
  --red: #f2698c;
  --red-dim: rgba(242, 105, 140, 0.11);
  --stamp: #f2698c;
  --hdr-bg: rgba(13, 20, 32, 0.88);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Public Sans', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  transition: background .3s, color .3s;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--gold-dim); }

a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
  border-radius: 4px;
}

code {
  font-family: 'IBM Plex Mono', monospace;
  font-size: .85em;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 5px;
}

/* ── Shared primitives ─────────────────────────────────────── */
.wrap { max-width: 920px; margin: 0 auto; padding: 0 20px; }

.eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.mono { font-family: 'IBM Plex Mono', monospace; }

/* ════════════════════════════════════════════════════════════
   HEADER — slim sticky bar
   ════════════════════════════════════════════════════════════ */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--hdr-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.hdr-inner {
  max-width: 920px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }

.brand-seal {
  width: 34px; height: 34px;
  flex: none;
  border: 1px solid var(--gold);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  background: var(--gold-dim);
}

.brand-name {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 17px;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-tag {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 99px;
  padding: 2px 8px;
  white-space: nowrap;
}

.theme-controls { display: flex; align-items: center; gap: 8px; flex: none; }

.auto-badge {
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--text-muted);
  background: none;
  border: 1px solid var(--border);
  border-radius: 99px;
  padding: 4px 10px;
  cursor: pointer;
  transition: color .2s, border-color .2s;
}
.auto-badge.active { color: var(--gold); border-color: var(--gold); }

.theme-toggle-btn {
  width: 52px; height: 28px;
  border: 1px solid var(--border);
  border-radius: 99px;
  background: var(--surface2);
  cursor: pointer;
  position: relative;
  transition: background .2s;
}
.toggle-thumb {
  position: absolute;
  top: 2px; left: 2px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
  transition: transform .25s;
}
[data-theme="dark"] .toggle-thumb { transform: translateX(24px); }

/* ════════════════════════════════════════════════════════════
   HERO
   ════════════════════════════════════════════════════════════ */
.hero { padding: clamp(36px, 7vw, 72px) 0 clamp(20px, 4vw, 36px); text-align: center; }

.hero .eyebrow { color: var(--gold); }

.hero-title {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(30px, 5.4vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 12px auto 14px;
  max-width: 15ch;
}

.hero-sub {
  color: var(--text-muted);
  font-size: clamp(14px, 1.8vw, 16px);
  max-width: 56ch;
  margin: 0 auto;
}

/* ════════════════════════════════════════════════════════════
   CARDS / SECTIONS
   ════════════════════════════════════════════════════════════ */
.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 1px 3px var(--shadow);
  padding: clamp(16px, 3vw, 26px);
  margin-bottom: 22px;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.sec-label {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 18px;
  color: var(--ink);
}

.section-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 34px 0 18px;
}
.section-divider-line { flex: 1; height: 1px; background: var(--border); }
.section-divider-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--text-muted);
  white-space: nowrap;
}

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  border-radius: 8px;
  padding: 9px 16px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background .15s, border-color .15s, transform .1s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; }

.btn-primary { background: var(--ink); color: var(--bg); }
.btn-primary:hover:not(:disabled) { opacity: .9; }
[data-theme="dark"] .btn-primary { background: var(--gold); color: #10151f; }

.btn-ghost {
  background: none;
  color: var(--text-muted);
  border-color: var(--border);
}
.btn-ghost:hover { color: var(--text); border-color: var(--text-dim); }

/* ── File drop + textarea ──────────────────────────────────── */
.file-drop {
  display: flex;
  align-items: center;
  gap: 14px;
  border: 1.5px dashed var(--border);
  border-radius: 10px;
  padding: 16px 18px;
  cursor: pointer;
  transition: border-color .2s, background .2s;
  margin-bottom: 12px;
}
.file-drop:hover { border-color: var(--gold); background: var(--gold-dim); }
.file-drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.fdrop-icon { font-size: 22px; }
.fdrop-text strong { display: block; font-size: 14px; color: var(--text); }
.fdrop-text span { font-size: 12.5px; color: var(--text-muted); }

textarea#jsonInput {
  width: 100%;
  min-height: 150px;
  resize: vertical;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--text);
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 13px 15px;
  transition: border-color .2s;
}
textarea#jsonInput:focus { outline: none; border-color: var(--blue); }
textarea#jsonInput::placeholder { color: var(--text-dim); }

.error-bar {
  display: none;
  margin-top: 12px;
  background: var(--red-dim);
  border: 1px solid var(--red);
  color: var(--red);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 13px;
}
.error-bar.show { display: block; }

/* ── Quick Fetch ───────────────────────────────────────────── */
.qf-row { display: flex; gap: 10px; flex-wrap: wrap; }

.qf-input {
  flex: 1;
  min-width: 200px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 15px;
  letter-spacing: .08em;
  color: var(--gold);
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  text-transform: uppercase;
  transition: border-color .2s;
}
.qf-input:focus { outline: none; border-color: var(--gold); }
.qf-input::placeholder { color: var(--text-dim); letter-spacing: .04em; }

.qf-check {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-muted);
  cursor: pointer;
  user-select: none;
}
.qf-check input {
  margin-top: 3px;
  width: 15px; height: 15px;
  accent-color: var(--gold);
  cursor: pointer;
  flex: none;
}

.qf-url-display {
  display: none;
  margin-top: 12px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11.5px;
  line-height: 1.7;
  color: var(--text-muted);
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 12px;
  word-break: break-all;
  white-space: pre-line;
}
.qf-url-display.visible { display: block; }

.qf-hint { margin-top: 16px; font-size: 13px; color: var(--text-muted); }

.api-step {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 7px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.55;
}
.api-step strong { color: var(--text); }
.step-num {
  flex: none;
  width: 19px; height: 19px;
  margin-top: 1px;
  border-radius: 50%;
  border: 1px solid var(--gold);
  color: var(--gold);
  font-size: 11px;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

.fine-print { margin-top: 10px; font-size: 11.5px; color: var(--text-dim); line-height: 1.6; }

/* ── Collapsible reference sections ────────────────────────── */
details.ref {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 14px;
  overflow: hidden;
}
details.ref > summary {
  list-style: none;
  cursor: pointer;
  padding: 15px 20px;
  font-weight: 600;
  font-size: 14px;
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
details.ref > summary::-webkit-details-marker { display: none; }
details.ref > summary::after {
  content: '+';
  font-family: 'IBM Plex Mono', monospace;
  color: var(--text-muted);
  font-size: 16px;
}
details.ref[open] > summary::after { content: '−'; }
details.ref > summary:hover { color: var(--gold); }
.ref-body {
  padding: 0 20px 18px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.65;
}
.ref-body p { margin-bottom: 8px; }

.sc-table { width: 100%; border-collapse: collapse; margin-top: 6px; font-size: 12.5px; }
.sc-table th {
  text-align: left;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 6px 10px 6px 0;
  border-bottom: 1px solid var(--border);
}
.sc-table td {
  padding: 7px 10px 7px 0;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
  color: var(--text-muted);
}
.sc-table tr:last-child td { border-bottom: none; }
.sc-code {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 500;
  color: var(--gold);
  white-space: nowrap;
}
.sc-group td {
  padding-top: 14px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-dim);
  border-bottom: 1px solid var(--border);
}

/* ════════════════════════════════════════════════════════════
   OUTPUT — stats, cards, badges
   ════════════════════════════════════════════════════════════ */
.stat-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 8px;
}

.stat-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 14px;
  text-align: center;
}
.stat-pill-val {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(22px, 3vw, 30px);
  color: var(--ink);
  line-height: 1.15;
}
.stat-pill-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 4px;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 6px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 20px;
}

.card-title {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 16px;
  color: var(--ink);
  margin-bottom: 12px;
}
.card-title-icon {
  width: 28px; height: 28px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 14px;
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.detail-row:last-child { border-bottom: none; }
.detail-key { color: var(--text-muted); flex: none; }
.detail-val { text-align: right; font-weight: 500; color: var(--text); word-break: break-word; }

/* ── Badges ────────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  border-radius: 99px;
  padding: 3px 10px;
  border: 1px solid transparent;
}
.badge .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-blue   { color: var(--blue);   background: var(--blue-dim);   border-color: var(--blue); }
.badge-green  { color: var(--green);  background: var(--green-dim);  border-color: var(--green); }
.badge-gold   { color: var(--gold);   background: var(--gold-dim);   border-color: var(--gold); }
.badge-purple { color: var(--purple); background: var(--purple-dim); border-color: var(--purple); }
.badge-orange { color: var(--orange); background: var(--orange-dim); border-color: var(--orange); }
.badge-red    { color: var(--red);    background: var(--red-dim);    border-color: var(--red); }
.badge-gray   { color: var(--text-muted); background: var(--surface2); border-color: var(--border); }

/* ── Notices ───────────────────────────────────────────────── */
.notice-item { padding: 13px 0; border-bottom: 1px solid var(--border); }
.notice-item:last-child { border-bottom: none; padding-bottom: 2px; }
.notice-item:first-child { padding-top: 2px; }
.notice-top { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px; }
.notice-type { font-weight: 600; font-size: 14px; color: var(--text); }
.notice-date { font-size: 12px; color: var(--text-muted); }
.notice-appt { margin-top: 5px; font-size: 13px; color: var(--gold); }
.notice-meta { margin-top: 4px; font-size: 11.5px; font-family: 'IBM Plex Mono', monospace; color: var(--text-dim); }

/* ════════════════════════════════════════════════════════════
   TIMELINE — case ledger
   ════════════════════════════════════════════════════════════ */
.timeline-item {
  display: grid;
  grid-template-columns: 118px 30px 1fr;
  gap: 6px;
}

.tl-date { text-align: right; padding: 16px 6px 0 0; }
.tl-date-main { font-size: 13px; font-weight: 600; color: var(--text); line-height: 1.35; }
.tl-date-time { font-size: 11px; font-family: 'IBM Plex Mono', monospace; color: var(--text-dim); margin-top: 2px; }

.tl-spine { display: flex; flex-direction: column; align-items: center; }
.tl-dot {
  width: 13px; height: 13px;
  flex: none;
  margin-top: 19px;
  border-radius: 50%;
  border: 2.5px solid var(--text-dim);
  background: var(--bg);
}
.tl-line { flex: 1; width: 2px; background: var(--border); margin-top: 4px; }

.tl-content {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 15px 18px;
  margin: 6px 0 14px;
  min-width: 0;
}
.tl-content-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  flex-wrap: wrap;
}
.tl-event-name { font-weight: 600; font-size: 14.5px; color: var(--text); }
.tl-event-code, .tl-silent-code {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .05em;
  color: var(--gold);
  background: var(--gold-dim);
  border: 1px solid var(--gold);
  border-radius: 5px;
  padding: 2px 7px;
  white-space: nowrap;
}
.tl-silent-code { color: var(--purple); background: var(--purple-dim); border-color: var(--purple); }
.tl-badges { margin: 7px 0 8px; }
.tl-event-desc { font-size: 13px; color: var(--text-muted); line-height: 1.65; }
.tl-event-id {
  margin-top: 9px;
  padding-top: 8px;
  border-top: 1px dashed var(--border);
  font-size: 11px;
  font-family: 'IBM Plex Mono', monospace;
  color: var(--text-dim);
  word-break: break-word;
}

/* ════════════════════════════════════════════════════════════
   SUMMARY — the stamped decision page
   ════════════════════════════════════════════════════════════ */
.summary-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: clamp(18px, 3.5vw, 30px);
  margin-bottom: 26px;
}

.sum-header { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }

/* Signature element: the rubber stamp */
.sum-icon {
  flex: none;
  width: 58px; height: 58px;
  border: 2px dashed var(--stamp);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px;
  transform: rotate(-8deg);
  color: var(--stamp);
}

.sum-title {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(17px, 2.6vw, 22px);
  color: var(--ink);
  word-break: break-word;
}
.sum-sub { font-size: 13px; color: var(--text-muted); margin-top: 2px; }

.sum-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}
.sum-stat {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  text-align: center;
}
.sum-stat-val { font-family: 'Fraunces', serif; font-weight: 600; font-size: 22px; color: var(--ink); }
.sum-stat-lbl { font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); margin-top: 2px; }

/* Progress track */
.progress-track {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 16px 16px;
  margin-bottom: 20px;
  overflow-x: auto;
}
.progress-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.progress-steps { display: flex; align-items: flex-start; min-width: 480px; }
.progress-step { flex: none; }
.progress-step-inner { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 74px; }
.progress-step-dot {
  width: 26px; height: 26px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
  font-weight: 700;
  border: 2px solid var(--border);
  color: var(--text-dim);
  background: var(--surface);
}
.progress-step-dot.done { border-color: var(--green); background: var(--green); color: var(--surface); }
.progress-step-dot.active { border-color: var(--gold); color: var(--gold); }
.progress-step-name { font-size: 10.5px; font-weight: 600; text-align: center; color: var(--text-muted); line-height: 1.3; }
.progress-connector { flex: 1; height: 2px; background: var(--border); margin-top: 12px; min-width: 14px; }
.progress-connector.filled { background: var(--green); }
.progress-connector.active { background: var(--gold); }

.sum-body { font-size: 14px; line-height: 1.75; color: var(--text-muted); }
.sum-body p { margin-bottom: 11px; }
.sum-body strong { color: var(--text); }

.hl   { color: var(--gold);  font-weight: 600; }
.hl-g { color: var(--green); font-weight: 600; }
.hl-r { color: var(--red);   font-weight: 600; }

/* ════════════════════════════════════════════════════════════
   EMPTY STATE / DISCLAIMER / FOOTER
   ════════════════════════════════════════════════════════════ */
.empty-state {
  text-align: center;
  padding: 44px 20px;
  border: 1.5px dashed var(--border);
  border-radius: 14px;
  margin-bottom: 26px;
}
.empty-icon { font-size: 34px; margin-bottom: 10px; }
.empty-title { font-family: 'Fraunces', serif; font-weight: 600; font-size: 19px; color: var(--ink); }
.empty-desc { font-size: 13.5px; color: var(--text-muted); margin-top: 6px; max-width: 46ch; margin-inline: auto; }

.disclaimer {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 20px;
  margin-bottom: 30px;
}
.disclaimer-title { font-weight: 700; font-size: 13px; color: var(--red); margin-bottom: 8px; }
.disclaimer-body { font-size: 12px; color: var(--text-muted); line-height: 1.7; }
.disclaimer-body p { margin-bottom: 7px; }
.disclaimer-body p:last-child { margin-bottom: 0; }

.footer { border-top: 1px solid var(--border); padding: 20px 0 32px; }
.footer-inner {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text-muted);
}
.footer .brand-word { color: var(--gold); font-weight: 600; }

/* ════════════════════════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════════════════════════ */
@media (max-width: 780px) {
  .grid-2 { grid-template-columns: 1fr; }
  .stat-bar { grid-template-columns: repeat(2, 1fr); }
  .brand-tag { display: none; }
}

@media (max-width: 560px) {
  body { font-size: 14.5px; }
  .timeline-item { grid-template-columns: 22px 1fr; }
  .tl-date {
    grid-column: 2;
    grid-row: 1;
    text-align: left;
    padding: 0 0 4px 2px;
    display: flex;
    align-items: baseline;
    gap: 8px;
  }
  .tl-spine { grid-column: 1; grid-row: 1 / span 2; }
  .tl-dot { margin-top: 3px; }
  .tl-content { grid-column: 2; grid-row: 2; margin-top: 2px; }
  .sum-stats { grid-template-columns: 1fr; }
  .sum-header { flex-direction: column; align-items: flex-start; gap: 10px; }
  .qf-row .btn { width: 100%; justify-content: center; }
  .panel-head .input-actions { width: 100%; display: flex; gap: 8px; }
  .panel-head .input-actions .btn { flex: 1; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
