[hidden] {
  display: none !important;
}
#final-section:not([hidden]) {
  display: grid;
}
:root {
  color-scheme: light;
  --bg: #f1ecde;
  --paper: #fffdf7;
  --paper-2: #ebe4d2;
  --ink: #111111;
  --muted: #5d5546;
  --line: #111111;
  --accent: #1452ff;
  --accent-soft: #dce6ff;
  --good: #1e6b35;
  --good-soft: #ddf2e3;
  --warn: #8f5a10;
  --shadow: 5px 5px 0 #111111;
  --radius: 0;
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.7), transparent 28%),
    linear-gradient(180deg, #f3eedf 0%, var(--bg) 100%);
  color: var(--ink);
  font: 16px/1.5 "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}
button,
input,
a {
  color: inherit;
  font: inherit;
}
button,
a.buttonlike,
input {
  border: 2px solid var(--line);
  background: var(--paper);
}
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 14px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 140ms ease, box-shadow 140ms ease, background 140ms ease, color 140ms ease;
}
button:hover,
button:focus-visible,
input:focus-visible,
a:focus-visible {
  outline: none;
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 var(--line);
}
button:disabled,
input:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  box-shadow: none;
  transform: none;
}
h1,
h2,
h3,
p,
pre,
ul {
  margin: 0;
}
ul {
  padding: 0;
  list-style: none;
}
.shell {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 20px 0 48px;
}
.app-shell {
  display: grid;
  gap: 18px;
}
.panel {
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow);
  padding: 20px;
}
.inset {
  background: var(--paper-2);
  box-shadow: none;
}
.stack {
  display: grid;
  gap: 16px;
}
.compact-gap {
  gap: 10px;
}
.split,
.section-head,
.status-row,
.alloc-meta,
.diff-head,
.diff-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
.hero {
  display: grid;
  gap: 16px;
  padding-bottom: 16px;
}
.hero-top {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(240px, 360px);
  gap: 16px;
  align-items: start;
}
.hero h1 {
  max-width: 11ch;
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
}
.eyebrow,
.label {
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.lede,
.muted,
.status-line {
  color: var(--muted);
}
.lede {
  max-width: 44ch;
}
.wallet-status,
.score,
.amount {
  font-weight: 700;
}
.sign-in-panel {
  padding: 14px 16px;
  gap: 8px;
}
.wallet-actions {
  gap: 10px;
}
.wallet-actions button {
  min-height: 38px;
  padding: 8px 14px;
}
.page-grid {
  display: grid;
  gap: 18px;
}
.hero-progress {
  display: grid;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid rgba(17, 17, 17, 0.12);
}
.compact-section-head {
  align-items: end;
}
.progress-card {
  gap: 8px;
}
.progress-track {
  overflow: hidden;
  height: 12px;
  border: 2px solid var(--line);
  background: rgba(17, 17, 17, 0.08);
}
.progress-bar {
  width: 0%;
  height: 100%;
  background: repeating-linear-gradient(135deg, var(--accent) 0, var(--accent) 16px, #7ea0ff 16px, #7ea0ff 32px);
  transition: width 220ms ease;
}
.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.pill,
.kbd,
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 4px 10px;
  border: 2px solid var(--line);
  background: var(--paper);
  font-size: 0.85rem;
}
.kbd {
  min-width: 28px;
  padding-inline: 8px;
  background: var(--paper-2);
  font-weight: 700;
}
.empty-state {
  display: grid;
  gap: 8px;
  border-style: dashed;
}
.compare-shell {
  display: grid;
  gap: 18px;
}
.compare-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px 16px;
}
.compare-toolbar h2 {
  max-width: 48ch;
  font-size: clamp(0.95rem, 1.6vw, 1.15rem);
  line-height: 1.25;
}
.compare-toolbar h2 .muted {
  font-weight: 400;
  font-size: 0.85em;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.alloc-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.alloc-card {
  display: grid;
  gap: 16px;
}
.alloc-card.active-left {
  background: linear-gradient(180deg, rgba(220, 230, 255, 0.55), transparent 40%), var(--paper);
}
.alloc-card.active-right {
  background: linear-gradient(180deg, rgba(221, 242, 227, 0.75), transparent 40%), var(--paper);
}
.alloc-title-row {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
}
.alloc-card h3 {
  font-size: 1.05rem;
  line-height: 1.25;
}
.alloc-meta {
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 0.88rem;
}
.alloc-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.stat-box {
  border: 2px solid var(--line);
  background: rgba(255, 255, 255, 0.44);
  padding: 10px 12px;
}
.stat-box .muted {
  font-size: 0.82rem;
}
.repo-link {
  word-break: break-word;
}
.diff-panel {
  display: grid;
  gap: 14px;
}
.diff-table {
  display: grid;
  gap: 10px;
}
.diff-row {
  align-items: center;
  padding: 12px 14px;
  border: 2px solid var(--line);
  background: rgba(255, 255, 255, 0.52);
}
.diff-row.is-tie {
  opacity: 0.76;
}
.diff-left,
.diff-right {
  min-width: 72px;
  font-weight: 700;
}
.diff-center {
  flex: 1;
  display: grid;
  gap: 6px;
}
.diff-project {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
}
.diff-bar-track {
  overflow: hidden;
  width: 100%;
  height: 12px;
  border: 2px solid var(--line);
  background: rgba(17, 17, 17, 0.08);
}
.diff-bar-stack {
  display: grid;
  grid-template-columns: var(--left, 0fr) var(--right, 0fr);
  height: 100%;
}
.diff-bar-left {
  background: var(--accent-soft);
}
.diff-bar-right {
  background: var(--good-soft);
}
.delta {
  font-size: 0.85rem;
  color: var(--muted);
}
.delta strong {
  color: var(--ink);
}
.vote-panel {
  position: sticky;
  bottom: 16px;
  z-index: 10;
  padding: 16px 18px;
  background: var(--paper);
  border-width: 3px;
  border-color: var(--ink);
  box-shadow: 4px 4px 0 rgba(17,17,17,0.5);
}
.vote-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.vote-button {
  min-height: 56px;
  padding: 12px 14px;
  line-height: 1.35;
}
.vote-left {
  background: var(--accent-soft);
}
.vote-right {
  background: var(--good-soft);
}
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.secondary {
  background: var(--paper-2);
}
.vote-footer {
  display: flex;
  align-items: center;
  gap: 12px;
}
.vote-shortcuts {
  font-size: 0.82rem;
}
.vote-panel .secondary {
  min-height: 34px;
  padding: 6px 12px;
  font-size: 0.85rem;
}
.envelope {
  overflow-x: auto;
  min-height: 260px;
  padding: 16px;
  border: 2px solid var(--line);
  background: #f8f3e8;
  white-space: pre-wrap;
  word-break: break-word;
}
.success-text {
  color: var(--good);
}
.warning-text {
  color: var(--warn);
}
.status-line:empty {
  display: none;
}
@media (max-width: 980px) {
  .hero-top,
  .alloc-grid,
  .vote-actions,
  .alloc-stats {
    grid-template-columns: 1fr;
  }
  .vote-panel {
    position: static;
  }
}
@media (max-width: 760px) {
  .shell {
    width: min(100% - 24px, 1240px);
    padding-top: 16px;
  }
  .section-head,
  .status-row,
  .compare-toolbar,
  .diff-row,
  .alloc-title-row,
  .alloc-meta {
    flex-direction: column;
    align-items: flex-start;
  }
  .pill-row {
    justify-content: flex-start;
  }
  .diff-left,
  .diff-right {
    min-width: 0;
  }
}
