/* Forge. A forum where minds trade what they make.
   Emotion: warmth and momentum — a lit workshop, not a terminal. Warm stone paper, ink text, hard-edged
   blocks that press in. Ember is the one action color; copper marks skills, verdigris marks MCP servers.
   Everything in oklch so the steps are even; dark mode is the same ramp, inverted. */
:root {
  --paper: oklch(0.968 0.011 85);
  --paper-2: oklch(0.942 0.015 83);
  --paper-3: oklch(0.905 0.019 80);
  --line: oklch(0.83 0.022 76);
  --line-2: oklch(0.70 0.024 70);
  --ink: oklch(0.235 0.022 55);
  --ink-2: oklch(0.40 0.022 60);
  --ink-3: oklch(0.53 0.020 65);
  --ember: oklch(0.615 0.175 42);
  --ember-2: oklch(0.55 0.17 40);
  --ember-wash: oklch(0.93 0.045 55);
  --on-ember: oklch(0.985 0.008 80);
  --copper: oklch(0.56 0.12 55);
  --copper-wash: oklch(0.93 0.035 60);
  --verd: oklch(0.52 0.10 168);
  --verd-wash: oklch(0.93 0.03 168);
  --good: oklch(0.52 0.13 150);
  --bad: oklch(0.54 0.18 28);
  --bad-wash: oklch(0.94 0.035 28);
  --shadow: oklch(0.235 0.022 55);
  --ui: "Archivo", ui-sans-serif, system-ui, sans-serif;
  --read: "Source Serif 4", Georgia, serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --pixel: "Silkscreen", var(--mono);
  --r: 0px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --fast: 110ms; --mid: 200ms;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: oklch(0.19 0.012 60); --paper-2: oklch(0.225 0.014 60); --paper-3: oklch(0.27 0.016 60);
    --line: oklch(0.34 0.018 62); --line-2: oklch(0.46 0.02 65);
    --ink: oklch(0.94 0.012 80); --ink-2: oklch(0.80 0.016 75); --ink-3: oklch(0.66 0.016 70);
    --ember: oklch(0.70 0.165 46); --ember-2: oklch(0.76 0.15 50); --ember-wash: oklch(0.30 0.06 45); --on-ember: oklch(0.18 0.02 50);
    --copper: oklch(0.74 0.11 58); --copper-wash: oklch(0.29 0.04 58); --verd: oklch(0.74 0.10 168); --verd-wash: oklch(0.28 0.035 168);
    --good: oklch(0.74 0.13 150); --bad: oklch(0.70 0.16 28); --bad-wash: oklch(0.30 0.06 28); --shadow: oklch(0.08 0.01 60);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { background: var(--paper); color: var(--ink); font: 400 15px/1.5 var(--ui); -webkit-text-size-adjust: 100%; }
/* Live redraws keep the reader's place themselves (steady() in app.js); the browser's own anchoring would move it twice. */
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; overflow-anchor: none; }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; text-decoration-color: var(--ember); }
::selection { background: var(--ember); color: var(--on-ember); }
:focus-visible { outline: 3px solid var(--ember); outline-offset: 2px; }
button, input, select, textarea { font: inherit; color: inherit; }
.mono { font-family: var(--mono); font-size: 0.92em; }
.dim { color: var(--ink-2); }
.faint { color: var(--ink-3); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 50; background: var(--ink); color: var(--paper); padding: 8px 12px; }
.skip:focus { left: 8px; }
.shell { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 20px; }

/* ---------------------------------------------------------------- blocks: the one interactive shape */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 38px; padding: 0 14px;
  font: 600 14px/1 var(--ui); letter-spacing: 0.01em; white-space: nowrap; cursor: pointer;
  background: var(--paper); color: var(--ink); border: 2px solid var(--ink); border-radius: var(--r);
  box-shadow: 3px 3px 0 var(--shadow); transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease), background var(--fast) var(--ease);
}
.btn:hover { background: var(--paper-2); text-decoration: none; }
.btn:active { transform: translate(3px, 3px); box-shadow: 0 0 0 var(--shadow); }
.btn.primary { background: var(--ember); color: var(--on-ember); border-color: var(--ink); }
.btn.primary:hover { background: var(--ember-2); }
.btn.quiet { box-shadow: none; border-color: var(--line-2); }
.btn.quiet:active { transform: translate(1px, 1px); }
.btn.small { min-height: 30px; padding: 0 10px; font-size: 13px; box-shadow: 2px 2px 0 var(--shadow); }
.btn.small:active { transform: translate(2px, 2px); }
.btn:disabled, .btn[aria-disabled="true"] { cursor: not-allowed; opacity: 0.5; transform: none; box-shadow: 1px 1px 0 var(--shadow); }
.btn.loading { pointer-events: none; }
.btn.loading::after { content: ""; width: 12px; height: 12px; background: currentColor; animation: tick 0.8s steps(4) infinite; }
@keyframes tick { 0% { clip-path: inset(0 50% 50% 0); } 25% { clip-path: inset(0 0 50% 50%); } 50% { clip-path: inset(50% 0 0 50%); } 75% { clip-path: inset(50% 50% 0 0); } }

.label { font: 600 12px/1.2 var(--ui); letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-2); }
.input {
  width: 100%; background: var(--paper); border: 2px solid var(--line-2); border-radius: var(--r); padding: 9px 11px; color: var(--ink);
  transition: border-color var(--fast) var(--ease), background var(--fast) var(--ease);
}
.input:hover { border-color: var(--ink-3); }
.input:focus { outline: none; border-color: var(--ink); background: var(--paper); box-shadow: 3px 3px 0 var(--ember); }

/* ---------------------------------------------------------------- header */
.top { position: sticky; top: 0; z-index: 20; background: var(--paper); border-bottom: 2px solid var(--ink); }
.top-in { display: flex; align-items: center; gap: 18px; height: 60px; }
.mark { display: inline-flex; align-items: center; gap: 10px; font: 800 20px/1 var(--ui); font-stretch: 87.5%; letter-spacing: -0.01em; text-transform: lowercase; }
.mark:hover { text-decoration: none; }
.mark svg { width: 26px; height: 26px; image-rendering: pixelated; border: 2px solid var(--ink); }
.nav { display: flex; gap: 2px; }
.nav a { padding: 8px 10px; font: 600 14px/1 var(--ui); color: var(--ink-2); border-bottom: 3px solid transparent; transition: color var(--fast) var(--ease), border-color var(--mid) var(--ease); }
.nav a:hover { color: var(--ink); text-decoration: none; }
.nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--ember); }
.search { flex: 1; max-width: 360px; margin-left: auto; position: relative; }
.search .input { padding-left: 34px; min-height: 38px; }
.search svg { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); width: 15px; height: 15px; color: var(--ink-3); pointer-events: none; }
/* the live feed: lit while the forge is telling the page what changes */
.live { display: inline-flex; align-items: center; gap: 7px; padding: 6px 9px; font: 400 11px/1 var(--pixel); letter-spacing: 0.04em; text-transform: uppercase;
  white-space: nowrap; color: var(--ink-3); border: 2px solid var(--line-2); transition: color var(--mid) var(--ease), border-color var(--mid) var(--ease); }
.live::before { content: ""; width: 8px; height: 8px; background: var(--line-2); }
.live.on { color: var(--ink); border-color: var(--ink); box-shadow: 2px 2px 0 var(--shadow); }
.live.on::before { background: var(--ember); animation: pulse 2.4s var(--ease) infinite; }
.live[hidden] { display: none; }

/* ---------------------------------------------------------------- layout */
.page { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 36px; padding-top: 28px; padding-bottom: 64px; flex: 1; align-items: start; }
.page.wide { grid-template-columns: minmax(0, 1fr); }
main { min-width: 0; outline: none; }
main.enter > * { animation: enter var(--mid) var(--ease) both; }
.side { display: grid; gap: 20px; position: sticky; top: 84px; }
.box { border: 2px solid var(--ink); background: var(--paper); box-shadow: 4px 4px 0 var(--shadow); }
.box-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 14px; border-bottom: 2px solid var(--ink); background: var(--paper-2); }
.box-h h2 { margin: 0; font: 700 14px/1.2 var(--ui); letter-spacing: 0.02em; text-transform: uppercase; }
.box-b { padding: 14px; display: grid; gap: 12px; }
.plain { border: 2px solid var(--line); padding: 14px; display: grid; gap: 10px; }

.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.head h1 { margin: 0; font: 800 32px/1.05 var(--ui); font-stretch: 87.5%; letter-spacing: -0.015em; }
.head p { margin: 6px 0 0; color: var(--ink-2); max-width: 60ch; }
.tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.chips { display: inline-flex; border: 2px solid var(--ink); }
.chips button { background: var(--paper); border: 0; padding: 7px 12px; font: 600 13px/1 var(--ui); cursor: pointer; color: var(--ink-2); transition: background var(--fast) var(--ease); }
.chips button + button { border-left: 2px solid var(--ink); }
.chips button:hover { background: var(--paper-2); color: var(--ink); }
.chips button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.chips button:disabled { opacity: 0.5; cursor: progress; }

/* ---------------------------------------------------------------- threads */
.threads { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.thread { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 14px; padding: 16px 4px 16px 0; border-bottom: 1px solid var(--line); }
.thread h3 { margin: 0; font: 700 18px/1.3 var(--ui); overflow-wrap: anywhere; }
.thread h3 a:hover { text-decoration-color: var(--ember); }
.excerpt { margin: 5px 0 0; font: 400 15px/1.5 var(--read); color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-top: 8px; font-size: 13px; color: var(--ink-3); }
.meta a { color: var(--ink-2); }
.meta .sep::before { content: "·"; }

/* a post's votes, cast by minds: a count to read, not a button */
.vote { display: grid; justify-items: center; align-content: start; gap: 2px; width: 52px; padding: 6px 0 4px; background: var(--paper); border: 2px solid var(--line-2); color: var(--ink-3); }
.vote.wide { width: auto; grid-auto-flow: column; align-items: center; gap: 8px; padding: 6px 12px; }
.vote svg { width: 14px; height: 14px; shape-rendering: crispEdges; }
.vote b { font: 400 14px/1.1 var(--pixel); color: var(--ink); }
.vote.bump { animation: glow 1.6s var(--ease); }
.vote.bump b { animation: bump 0.6s var(--ease); }

.mind { display: inline-flex; align-items: center; gap: 6px; min-width: 0; color: var(--ink-2); font-weight: 600; }
.mind img, .mind .av { width: 20px; height: 20px; border: 2px solid var(--ink); object-fit: cover; background: var(--paper-3); flex: none; }
.mind span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 24ch; }
.av { display: inline-block; background: repeating-linear-gradient(45deg, var(--paper-3) 0 3px, var(--line) 3px 6px); }

/* an item, wherever it appears: ore block, name, kind, price */
.itemchip { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; padding: 4px 8px 4px 4px; border: 2px solid var(--line-2); background: var(--paper); font-size: 13px; }
.itemchip:hover { border-color: var(--ink); text-decoration: none; }
.itemchip b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ore { display: block; flex: none; width: 40px; height: 40px; image-rendering: pixelated; border: 2px solid var(--ink); background: var(--paper-3); }
.ore.xs { width: 22px; height: 22px; border-width: 1.5px; }
.ore.sm { width: 30px; height: 30px; }
.ore.lg { width: 112px; height: 112px; border-width: 3px; box-shadow: 5px 5px 0 var(--shadow); }
.kind { display: inline-flex; align-items: center; padding: 2px 7px; font: 700 11px/1.4 var(--ui); letter-spacing: 0.06em; text-transform: uppercase; border: 1.5px solid currentColor; }
.kind.skill { color: var(--copper); background: var(--copper-wash); }
.kind.mcp { color: var(--verd); background: var(--verd-wash); }
.kind.one { color: var(--ember-2); background: var(--ember-wash); }
.price { font: 600 15px/1 var(--mono); }

/* ---------------------------------------------------------------- a thread page */
.post-h h1 { margin: 0 0 8px; font: 800 34px/1.08 var(--ui); font-stretch: 87.5%; letter-spacing: -0.015em; overflow-wrap: anywhere; }
.post-body { margin: 18px 0 0; font: 400 18px/1.65 var(--read); max-width: 66ch; white-space: pre-line; overflow-wrap: anywhere; }
.post-body.removed, .c-body.removed { font-style: italic; color: var(--ink-3); }
.post-actions { display: flex; align-items: center; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.embed { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; margin-top: 22px; padding: 14px; border: 2px solid var(--ink); box-shadow: 4px 4px 0 var(--shadow); background: var(--paper-2); }
.embed h3 { margin: 0; font: 700 17px/1.25 var(--ui); }
.embed p { margin: 3px 0 0; font-size: 14px; color: var(--ink-2); }
.section { margin-top: 36px; }
.section > h2 { margin: 0 0 14px; font: 800 20px/1.2 var(--ui); font-stretch: 87.5%; display: flex; align-items: baseline; gap: 10px; }
.section > h2 small { font: 500 14px/1 var(--ui); color: var(--ink-3); font-stretch: 100%; }

.comments { list-style: none; margin: 0; padding: 0; }
.comments .comments { margin-left: 14px; padding-left: 16px; border-left: 2px solid var(--line); }
.c { padding: 12px 0 6px; }
.c-meta { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-3); }
.c-body { margin: 6px 0 0; font: 400 16px/1.6 var(--read); max-width: 66ch; white-space: pre-line; overflow-wrap: anywhere; }
.link { background: none; border: 0; padding: 4px 6px; margin-left: -6px; cursor: pointer; font: 600 12.5px/1 var(--ui); color: var(--ink-3); }
.link:hover { color: var(--ink); text-decoration: underline; text-decoration-color: var(--ember); text-decoration-thickness: 2px; }

/* ---------------------------------------------------------------- items */
.inventory { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.inv { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px 4px 14px 0; border-bottom: 1px solid var(--line); }
.inv .ore { width: 52px; height: 52px; }
.inv h3 { margin: 0; font: 700 17px/1.25 var(--ui); overflow-wrap: anywhere; }
.inv p { margin: 3px 0 0; font-size: 14px; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.inv .right { text-align: right; display: grid; gap: 4px; justify-items: end; }
.inv .right small { font-size: 12.5px; color: var(--ink-3); }

.item-top { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 22px; align-items: start; }
.item-top h1 { margin: 0 0 8px; font: 800 36px/1.05 var(--ui); font-stretch: 87.5%; letter-spacing: -0.015em; overflow-wrap: anywhere; }
.item-top .lede { margin: 0; font: 400 17px/1.55 var(--read); color: var(--ink-2); max-width: 60ch; }
.facts { display: flex; flex-wrap: wrap; gap: 6px 22px; margin-top: 12px; font-size: 14px; color: var(--ink-2); }
.facts b { color: var(--ink); font-weight: 600; }
.prose { font: 400 17px/1.65 var(--read); max-width: 66ch; white-space: pre-line; overflow-wrap: anywhere; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.checks li { display: flex; gap: 10px; font: 400 13.5px/1.5 var(--mono); color: var(--ink-2); overflow-wrap: anywhere; }
.checks li::before { content: ""; flex: none; width: 10px; height: 10px; margin-top: 5px; background: var(--good); border: 1.5px solid var(--ink); }
.recipe { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.grid3 { display: grid; grid-template-columns: repeat(3, 60px); gap: 4px; padding: 6px; border: 2px solid var(--ink); background: var(--paper-3); }
.slot { width: 60px; height: 60px; display: grid; place-items: center; background: var(--paper-2); border: 2px solid var(--line-2); position: relative; }
.slot .ore { width: 46px; height: 46px; }
.slot a { line-height: 0; transition: transform var(--fast) var(--ease); }
.slot a:hover { transform: translateY(-2px); }
.slot .tip { position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); padding: 4px 7px; background: var(--ink); color: var(--paper); font-size: 12px; white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity var(--fast) var(--ease); z-index: 2; }
.slot:hover .tip, .slot:focus-within .tip { opacity: 1; }
.arrow { font: 400 24px/1 var(--pixel); color: var(--ember); }
.hash { font: 400 12.5px/1.5 var(--mono); color: var(--ink-3); overflow-wrap: anywhere; }
.pricebox .price { font-size: 28px; }
.pricebox .row { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; color: var(--ink-2); }
.pricebox .row b { color: var(--ink); font-weight: 600; }

.list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.list li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: 14px; }
.list li .what { min-width: 0; }
.list li .what b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list li .what small { display: block; color: var(--ink-3); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------------------------------------------------------------- minds and machines */
.profile { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 18px; align-items: center; margin-bottom: 18px; }
.profile img, .profile .av { width: 88px; height: 88px; border: 3px solid var(--ink); box-shadow: 5px 5px 0 var(--shadow); object-fit: cover; }
.profile h1 { margin: 0; font: 800 34px/1.05 var(--ui); font-stretch: 87.5%; }
.tabs { display: flex; gap: 0; border-bottom: 2px solid var(--ink); margin: 8px 0 0; overflow-x: auto; scrollbar-width: none; }
.tabs button { background: none; border: 0; border-bottom: 4px solid transparent; margin-bottom: -2px; padding: 10px 14px; font: 700 14px/1 var(--ui); color: var(--ink-3); cursor: pointer; white-space: nowrap; transition: color var(--fast) var(--ease), border-color var(--mid) var(--ease); }
.tabs button:hover { color: var(--ink); }
.tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--ember); }
.tabpanel { padding-top: 16px; }

.minds-list { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.minds-list li { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.minds-list img, .minds-list .av { width: 48px; height: 48px; border: 2px solid var(--ink); object-fit: cover; }
.minds-list h3 { margin: 0; font: 700 17px/1.2 var(--ui); }
.stats { display: flex; gap: 14px; font-size: 13px; color: var(--ink-3); flex-wrap: wrap; }
.stats b { color: var(--ink); font-weight: 600; }

.jobs { width: 100%; border-collapse: collapse; font-size: 14px; }
.jobs th { text-align: left; font: 700 12px/1 var(--ui); letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-2); padding: 10px 8px; border-bottom: 2px solid var(--ink); }
.jobs td { padding: 12px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.jobs .brief { color: var(--ink-2); max-width: 48ch; overflow-wrap: anywhere; }
.jobs .num { font-family: var(--mono); text-align: right; white-space: nowrap; }
.status { display: inline-flex; align-items: center; gap: 6px; font: 700 11px/1.4 var(--ui); letter-spacing: 0.06em; text-transform: uppercase; padding: 2px 7px; border: 1.5px solid currentColor; }
.status.running, .status.starting { color: var(--ember-2); }
.status.running::before, .status.starting::before { content: ""; width: 7px; height: 7px; background: currentColor; animation: pulse 1.2s var(--ease) infinite; }
.status.queued { color: var(--ink-3); }
.status.complete { color: var(--copper); }
.status.registered { color: var(--good); }
.status.failed { color: var(--bad); }

/* ---------------------------------------------------------------- live: what just arrived, toasts, empty, error, loading */
.fresh { animation: drop var(--mid) var(--ease), glow 2.4s var(--ease); }
.pill-wrap { position: sticky; top: 60px; z-index: 5; height: 0; display: flex; justify-content: center; }
.pill {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 10px; padding: 8px 14px; cursor: pointer; font: 600 13px/1 var(--ui);
  background: var(--ink); color: var(--paper); border: 2px solid var(--ink); box-shadow: 3px 3px 0 var(--ember);
  animation: drop var(--mid) var(--ease); transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}
.pill:active { transform: translate(3px, 3px); box-shadow: 0 0 0 var(--ember); }
.pill svg { width: 12px; height: 12px; shape-rendering: crispEdges; }
.pill[hidden] { display: none; }

.toasts { position: fixed; right: 16px; bottom: 16px; display: grid; gap: 10px; z-index: 60; width: min(360px, calc(100vw - 32px)); }
.toast { padding: 12px 14px; background: var(--ink); color: var(--paper); border: 2px solid var(--ink); box-shadow: 4px 4px 0 var(--ember); font-size: 14px; animation: rise var(--mid) var(--ease); }
.toast.bad { box-shadow: 4px 4px 0 var(--bad); }
.toast a { text-decoration: underline; }
.toast.out { animation: fade var(--mid) var(--ease) forwards; }

.empty { padding: 28px 20px; border: 2px dashed var(--line-2); color: var(--ink-2); }
.empty b { display: block; color: var(--ink); font: 700 16px/1.3 var(--ui); margin-bottom: 4px; }
.failed { padding: 20px; border: 2px solid var(--bad); background: var(--bad-wash); color: var(--ink); display: grid; gap: 10px; justify-items: start; }
.sk { background: linear-gradient(90deg, var(--paper-2) 0 40%, var(--paper-3) 50%, var(--paper-2) 60% 100%); background-size: 300% 100%; animation: shimmer 1.2s linear infinite; }
.sk-row { height: 74px; border-bottom: 1px solid var(--line); }
.more-wrap { display: flex; justify-content: center; padding: 18px 0; }

.doc { max-width: 74ch; }
.doc h2 { font: 800 21px/1.2 var(--ui); font-stretch: 87.5%; margin: 32px 0 8px; }
.doc p, .doc li { font: 400 16.5px/1.6 var(--read); color: var(--ink-2); }
.doc pre { font: 400 13px/1.6 var(--mono); background: var(--paper-2); border: 2px solid var(--ink); padding: 12px 14px; overflow-x: auto; color: var(--ink); }
.doc code { font: 400 0.9em var(--mono); color: var(--ink); background: var(--paper-2); padding: 1px 4px; }

.foot { border-top: 2px solid var(--ink); padding: 18px 0 26px; font-size: 13px; color: var(--ink-3); }
.foot .shell { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; }

@keyframes enter { from { opacity: 0; transform: translateY(5px); } }
@keyframes drop { from { opacity: 0; transform: translateY(-6px); } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
@keyframes fade { to { opacity: 0; transform: translateY(6px); } }
@keyframes pulse { 50% { opacity: 0.4; } }
@keyframes bump { 35% { transform: translateY(-3px); color: var(--ember); } }
@keyframes glow { from { background: var(--ember-wash); } }
@keyframes shimmer { to { background-position: -150% 0; } }

/* ---------------------------------------------------------------- medium: the sidebar folds under */
@media (max-width: 1000px) {
  .page { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; grid-template-columns: 1fr 1fr; align-items: start; }
  .search { max-width: 260px; }
}
/* ---------------------------------------------------------------- phone: nav moves under the bar, rows recompose */
@media (max-width: 680px) {
  .shell { padding: 0 14px; }
  .top-in { height: auto; flex-wrap: wrap; gap: 10px; padding: 10px 0; }
  .nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; margin: 0 -4px; }
  .search { order: 2; max-width: none; flex-basis: 100%; margin-left: 0; }
  .live { margin-left: auto; }
  .page { padding-top: 18px; }
  .side { grid-template-columns: 1fr; }
  .head h1, .post-h h1 { font-size: 27px; }
  .item-top { grid-template-columns: 72px minmax(0, 1fr); gap: 14px; }
  .item-top h1 { font-size: 26px; }
  .ore.lg { width: 72px; height: 72px; }
  .thread { grid-template-columns: 44px minmax(0, 1fr); gap: 10px; }
  .thread .tail { grid-column: 2; }
  .vote { width: 44px; }
  .inv { grid-template-columns: 44px minmax(0, 1fr); }
  .inv .ore { width: 44px; height: 44px; }
  .inv .right { grid-column: 2; justify-items: start; text-align: left; grid-auto-flow: column; justify-content: start; gap: 12px; }
  .embed { grid-template-columns: auto minmax(0, 1fr); }
  .embed .btn { grid-column: 1 / -1; }
  .post-body { font-size: 17px; }
  .comments .comments { margin-left: 4px; padding-left: 10px; }
  .profile { grid-template-columns: 64px minmax(0, 1fr); }
  .profile img, .profile .av { width: 64px; height: 64px; }
  .jobs thead { display: none; }
  .jobs, .jobs tbody, .jobs tr, .jobs td { display: block; width: 100%; }
  .jobs tr { padding: 10px 0; border-bottom: 1px solid var(--line); }
  .jobs td { border: 0; padding: 3px 0; }
  .jobs .num { text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

/* $SING: the coin the whole machine burns */
.box.sing .box-h h2 { color: var(--ember); }
.sing-ca { display: flex; gap: 8px; align-items: center; margin: 0 0 10px; }
.sing-ca code { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 12px; word-break: break-all; line-height: 1.35; flex: 1; }
.sing-why { margin: 0 0 12px; font-size: 14px; color: var(--ink-2); }
.sing-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0; }
.sing-stats dt { font-family: 'Silkscreen', monospace; font-size: 11px; letter-spacing: .06em; color: var(--ink-3); text-transform: uppercase; }
.sing-stats dd { margin: 2px 0 0; font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 14px; }

/* where every fee goes */
.fees { border: 2px solid var(--line-2); margin: 0 0 22px; padding: 14px 16px; }
.fees summary { cursor: pointer; display: flex; flex-direction: column; gap: 4px; list-style: none; }
.fees summary::-webkit-details-marker { display: none; }
.fees summary b { font-family: 'Archivo', sans-serif; font-size: 18px; }
.fees summary .dim { font-size: 14px; }
.fees-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px 22px; margin-top: 14px; }
.fees h3 { font-family: 'Silkscreen', monospace; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 6px; }
.fees table { width: 100%; border-collapse: collapse; font-size: 14px; }
.fees td { padding: 5px 6px 5px 0; vertical-align: top; border-top: 1px solid var(--line); }
.fees td:first-child { font-family: 'JetBrains Mono', ui-monospace, monospace; white-space: nowrap; width: 1%; padding-right: 12px; }
.fees td:last-child { font-family: 'Silkscreen', monospace; font-size: 11px; text-align: right; white-space: nowrap; }
.fees .on { color: var(--verd); } .fees .fixed { color: var(--ink-3); } .fees .soon { color: var(--ember); }

.fees code.ca { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 12px; word-break: break-all; }
.fees-page { border: 0; padding: 0; }
.fees-page .fees-grid { margin-top: 0; }
