:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  background: #0b0c0d;
  color: #f4f1ea;
  --ink: #f4f1ea;
  --muted: #999a9c;
  --line: #292b2e;
  --amber: #ffb23f;
  --green: #7ce0a3;
  --red: #ff716d;
}

* { box-sizing: border-box; }
body { margin: 0; background: radial-gradient(circle at 70% -10%, #3b2a0f 0, transparent 35%), #0b0c0d; }
button { font: inherit; }
.hero, main, footer { width: min(1180px, calc(100% - 32px)); margin-inline: auto; }
.hero { padding: 72px 0 48px; border-bottom: 1px solid var(--line); }
.eyebrow, .kicker { margin: 0 0 10px; color: var(--amber); font: 700 12px/1.2 ui-monospace, monospace; letter-spacing: .15em; text-transform: uppercase; }
h1 { margin: 0; max-width: 900px; font: 800 clamp(54px, 10vw, 124px)/.84 Georgia, serif; letter-spacing: -.07em; }
h1 span { color: var(--amber); }
.lede { max-width: 760px; margin: 28px 0; color: #c8c5be; font-size: clamp(18px, 2vw, 25px); line-height: 1.45; }
.hero-status, .origin, .not-authority { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font: 600 12px/1.2 ui-monospace, monospace; }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 5px #ffb23f20; }
main { display: grid; grid-template-columns: 1.2fr .8fr; gap: 16px; padding: 24px 0 64px; }
.panel { min-width: 0; padding: 24px; border: 1px solid var(--line); border-radius: 18px; background: #121315e8; box-shadow: 0 18px 70px #0004; }
.storefront, .capabilities, .ledger, .proofs { grid-column: 1 / -1; }
.section-title { display: flex; align-items: start; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
h2 { margin: 0; font: 700 26px/1.1 Georgia, serif; }
button { border: 1px solid #3a3c40; border-radius: 10px; background: #1e2023; color: var(--ink); padding: 10px 14px; cursor: pointer; }
button:hover { border-color: var(--amber); }
button:focus-visible { outline: 3px solid #ffb23f80; outline-offset: 2px; }
.quiet { background: transparent; color: var(--muted); }
.catalog { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.product { display: grid; gap: 14px; padding: 18px; min-height: 210px; border: 1px solid var(--line); border-radius: 14px; background: linear-gradient(145deg, #1b1d20, #111214); }
.product h3 { margin: 0; font: 700 19px/1.2 Georgia, serif; }
.product p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.45; }
.product-meta { display: flex; justify-content: space-between; gap: 12px; margin-top: auto; }
.stock { color: var(--green); font: 700 12px ui-monospace, monospace; }
.out { color: var(--red); }
.cart-lines { display: grid; gap: 12px; min-height: 120px; }
.cart-line { display: grid; grid-template-columns: 1fr auto; gap: 6px 14px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.cart-line small { color: var(--muted); }
.total { display: flex; justify-content: space-between; margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 18px; }
.empty { color: var(--muted); }
.capability-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.capability { display: grid; grid-template-columns: 1fr auto; gap: 5px 12px; padding: 13px 15px; border: 1px solid var(--line); border-radius: 10px; }
.capability code, .ledger-entry code { color: var(--ink); }
.capability small { color: var(--muted); grid-column: 1; }
.state { align-self: center; grid-row: 1 / 3; grid-column: 2; border-radius: 999px; padding: 5px 8px; font: 700 10px ui-monospace, monospace; }
.working { color: var(--green); background: #7ce0a315; }
.refusing { color: var(--amber); background: #ffb23f15; }
.unbuilt { color: var(--red); background: #ff716d15; }
.ledger-entries { display: grid; gap: 8px; max-height: 380px; overflow: auto; }
.ledger-entry { display: grid; grid-template-columns: 90px 1fr auto; gap: 12px; align-items: center; padding: 12px; border-left: 3px solid var(--line); background: #0b0c0d; font: 12px/1.4 ui-monospace, monospace; }
.ledger-entry.refused { border-left-color: var(--amber); }
.ledger-entry.changed { border-left-color: var(--green); }
.ledger-entry small { color: var(--muted); }
.proof-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
pre { min-height: 120px; margin: 16px 0 0; padding: 16px; overflow: auto; border-radius: 10px; background: #090a0b; color: #c8fbd9; white-space: pre-wrap; }
footer { padding: 0 0 48px; color: var(--muted); }

@media (max-width: 760px) {
  .hero { padding-top: 48px; }
  main { grid-template-columns: 1fr; }
  .storefront, .capabilities, .ledger, .proofs { grid-column: auto; }
  .catalog, .capability-list { grid-template-columns: 1fr; }
  .section-title { align-items: start; flex-direction: column; }
  .ledger-entry { grid-template-columns: 1fr; }
}
