/* Sellout / Купено. Based on docs/mockups/sellout.html (the reference design). */
:root {
  --serif-font: "Instrument Serif";
  --serif-weight: 400;
  --desk: #E8E2D3;
  --paper: #FCFAF4;
  --ink: #17140E;
  --ink2: #5E584B;
  --line: rgba(23, 20, 14, .18);
  --ledger: rgba(23, 20, 14, .055);
  --stamp: #C4122F;
  --honest: #0B6B48;
  --mark-bg: linear-gradient(transparent 56%, #FFE24A 56%);
  --mark-ink: inherit;
  --band: #17140E;
  --on-band: #FCFAF4;
  --band-accent: #FFE24A;
  --shadow: rgba(60, 45, 15, .30);
  --stamp-blend: multiply;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --desk: #0E0D0B;
    --paper: #1B1A16;
    --ink: #F2EEE3;
    --ink2: #A8A292;
    --line: rgba(242, 238, 227, .20);
    --ledger: rgba(242, 238, 227, .04);
    --stamp: #FF5568;
    --honest: #5BD9A8;
    --mark-bg: none;
    --mark-ink: #FFD93B;
    --band: #F2EEE3;
    --on-band: #17140E;
    --band-accent: #C4122F;
    --shadow: rgba(0, 0, 0, .65);
    --stamp-blend: normal;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --desk: #0E0D0B;
  --paper: #1B1A16;
  --ink: #F2EEE3;
  --ink2: #A8A292;
  --line: rgba(242, 238, 227, .20);
  --ledger: rgba(242, 238, 227, .04);
  --stamp: #FF5568;
  --honest: #5BD9A8;
  --mark-bg: none;
  --mark-ink: #FFD93B;
  --band: #F2EEE3;
  --on-band: #17140E;
  --band-accent: #C4122F;
  --shadow: rgba(0, 0, 0, .65);
  --stamp-blend: normal;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--desk);
  background-image: linear-gradient(to bottom, transparent 31px, var(--ledger) 31px);
  background-size: 100% 32px;
  color: var(--ink);
  font: 400 15px/1.55 "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.serif { font-family: var(--serif-font), "Iowan Old Style", "Palatino Linotype", Georgia, serif; font-weight: var(--serif-weight); letter-spacing: -.012em; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 32px; } }
a { color: inherit; }
:focus-visible { outline: 2.5px solid var(--stamp); outline-offset: 3px; }
mark { background: var(--mark-bg); color: var(--mark-ink); padding: 0 .06em; }

/* ---------- top bar ---------- */
.top { display: flex; align-items: center; gap: 14px; padding-top: 18px; padding-bottom: 14px; }
.brand { display: flex; align-items: baseline; gap: 10px; text-decoration: none; margin-right: auto; min-width: 0; }
.brand-name { font-size: 34px; line-height: 1; font-style: italic; }
.brand-sub { font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink2); white-space: nowrap; }
.top-nav { display: none; gap: 22px; font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; }
.top-nav a { text-decoration: none; border-bottom: 1.5px solid transparent; }
.top-nav a:hover { border-color: var(--ink); }
.mock-pill { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; border: 1.5px dashed var(--stamp); color: var(--stamp); padding: 4px 8px; border-radius: 4px; white-space: nowrap; }
.theme { width: 38px; height: 38px; border-radius: 50%; border: 1.5px solid var(--ink); background: transparent; color: var(--ink); font-size: 16px; cursor: pointer; flex: none; }
@media (max-width: 520px) { .brand-sub { display: none; } }
@media (min-width: 900px) { .top-nav { display: flex; } }

/* ---------- buttons ---------- */
.btn {
  font: 600 12.5px/1 "IBM Plex Mono", ui-monospace, monospace; letter-spacing: .06em; text-transform: uppercase;
  padding: 14px 18px; border-radius: 6px; border: 1.5px solid var(--ink); background: transparent; color: var(--ink);
  cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  transition: transform .12s ease, box-shadow .12s ease; box-shadow: 0 3px 0 var(--ink);
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 4px 0 var(--ink); }
.btn:active { transform: translateY(3px); box-shadow: 0 0 0 var(--ink); }
.btn-ink { background: var(--ink); color: var(--desk); box-shadow: 0 3px 0 var(--stamp); }
.btn-ink:hover { box-shadow: 0 4px 0 var(--stamp); }
.btn-stamp { background: var(--stamp); border-color: var(--stamp); color: #fff; box-shadow: 0 3px 0 var(--ink); }
.btn-sm { padding: 10px 12px; font-size: 11.5px; box-shadow: 0 2px 0 var(--ink); }
.btn-sm.btn-ink { box-shadow: 0 2px 0 var(--stamp); }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }

/* ---------- hero ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1fr); gap: 30px; padding-top: 22px; padding-bottom: 40px; }
.eyebrow { display: flex; align-items: center; gap: 9px; font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase; margin: 0 0 6px; color: var(--ink2); }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--stamp); animation: pulse 1.6s ease-in-out infinite; flex: none; }
@keyframes pulse { 50% { opacity: .25; } }
h1 { font-size: clamp(46px, 8.2vw, 96px); line-height: .95; margin: 0 0 18px; text-wrap: balance; }
.lede { max-width: 46ch; margin: 0 0 22px; color: var(--ink2); }
.lede b { color: var(--ink); font-weight: 600; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.fine { font-size: 12px; color: var(--ink2); margin: 16px 0 0; }
.tally { display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 0; padding: 14px 0 0; border-top: 1.5px solid var(--ink); font-size: 12px; letter-spacing: .04em; }
.tally b { font-family: var(--serif-font), "Iowan Old Style", "Palatino Linotype", Georgia, serif; font-weight: 400; font-size: 26px; line-height: 1; display: block; letter-spacing: -.01em; }
.hero-r { display: flex; flex-direction: column; align-items: center; }
.slot { width: min(100%, 480px); height: 16px; border-radius: 9px; background: var(--ink); box-shadow: inset 0 -5px 0 rgba(127, 127, 127, .35); position: relative; z-index: 2; }
.slot-label { font-size: 9.5px; letter-spacing: .2em; text-transform: uppercase; color: var(--ink2); margin: 0 0 6px; }
#heroReceipt { width: min(100% - 28px, 440px); margin-top: -6px; }
@media (min-width: 900px) {
  .hero { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); grid-template-rows: auto 1fr; gap: 26px 56px; padding-top: 44px; padding-bottom: 72px; align-items: start; }
  .hero-r { grid-column: 2; grid-row: 1 / span 2; }
  .tally { grid-column: 1; grid-row: 2; }
  #heroReceipt { transform: rotate(-1.3deg); transform-origin: top center; }
}

/* ---------- receipt ---------- */
.rc-wrap { filter: drop-shadow(0 16px 16px var(--shadow)); width: 100%; max-width: 460px; }
.rc-wrap.printing { animation: print .95s steps(13, end) both; }
@keyframes print { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
.rc {
  background: var(--paper); color: var(--ink); padding: 18px 18px 30px; font-size: 12.5px; line-height: 1.5;
  background-image: linear-gradient(90deg, rgba(0, 0, 0, .035), transparent 10%, transparent 90%, rgba(0, 0, 0, .04));
  -webkit-mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / 14px 100%;
          mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / 14px 100%;
}
.rc-head { display: flex; justify-content: space-between; gap: 10px; font-weight: 600; font-size: 10.5px; letter-spacing: .1em; }
.rc-rule { border-top: 1.5px dashed var(--ink); opacity: .4; margin: 11px 0; }
.rc-q { margin: 0; display: flex; gap: 9px; align-items: baseline; }
.rc-q b, .dlg-q b { flex: none; display: inline-grid; place-items: center; width: 19px; height: 19px; background: var(--ink); color: var(--paper); font-size: 11px; border-radius: 3px; }
.rc-a { font-size: 27px; line-height: 1.16; margin: 10px 0 2px; overflow-wrap: anywhere; }
.rc-rows { margin: 0; }
.rc-rows div { display: flex; align-items: baseline; gap: 6px; }
.rc-rows dt { text-transform: uppercase; letter-spacing: .06em; font-size: 11px; white-space: nowrap; }
.rc-rows i { flex: 1; border-bottom: 1.5px dotted var(--ink); opacity: .35; transform: translateY(-3px); min-width: 12px; }
.rc-rows dd { margin: 0; text-align: right; font-weight: 500; overflow-wrap: anywhere; max-width: 70%; }
.rc-honest { margin-top: 12px; }
.rc-honest summary { cursor: pointer; color: var(--honest); font-weight: 600; font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; list-style: none; }
.rc-honest summary::-webkit-details-marker { display: none; }
.rc-honest summary::before { content: "[ ] "; }
.rc-honest[open] summary::before { content: "[x] "; }
.rc-honest p { margin: 6px 0 0; font-family: var(--serif-font), "Iowan Old Style", "Palatino Linotype", Georgia, serif; font-style: italic; font-size: 20px; line-height: 1.2; color: var(--honest); }
.rc-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; min-height: 54px; }
.barcode { height: 40px; flex: 1; max-width: 170px; background: repeating-linear-gradient(90deg, var(--ink) 0 2px, transparent 2px 4px, var(--ink) 4px 5px, transparent 5px 9px, var(--ink) 9px 12px, transparent 12px 14px, var(--ink) 14px 15px, transparent 15px 17px); opacity: .85; }
.stamp {
  display: inline-block; font: 600 25px/1 "IBM Plex Mono", ui-monospace, monospace; letter-spacing: .2em; text-indent: .2em;
  color: var(--stamp); border: 5px double var(--stamp); border-radius: 8px; padding: 6px 10px; transform: rotate(-11deg);
  mix-blend-mode: var(--stamp-blend); opacity: .92; white-space: nowrap;
}
.stamp.honest { color: var(--honest); border-color: var(--honest); transform: rotate(7deg); font-size: 19px; }
.rc-thanks { text-align: center; font-size: 10px; letter-spacing: .16em; color: var(--ink2); margin: 12px 0 0; }
.rc-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.rc-actions .btn { flex: 1 1 auto; }

/* ---------- ticker band ---------- */
.band { background: var(--band); color: var(--on-band); overflow: hidden; white-space: nowrap; font-size: 12.5px; letter-spacing: .03em; }
.band-track { display: inline-flex; gap: 44px; padding: 11px 22px; animation: tick 60s linear infinite; }
.band-track b { color: var(--band-accent); font-weight: 600; }
@keyframes tick { to { transform: translateX(-50%); } }

/* ---------- sections ---------- */
section { padding: 56px 0; }
h2 { font-size: clamp(36px, 5.6vw, 60px); line-height: 1; margin: 0 0 12px; text-wrap: balance; }
h2 i { color: var(--stamp); }
.sub { color: var(--ink2); max-width: 60ch; margin: 0 0 26px; }
.kicker { font-size: 11.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink2); margin: 0 0 10px; }

/* ask */
.askbar { display: flex; align-items: stretch; gap: 0; background: var(--paper); border: 1.5px solid var(--ink); border-radius: 8px; box-shadow: 0 5px 0 var(--ink); max-width: 780px; }
.askbar .qm { display: grid; place-items: center; width: 52px; flex: none; font-family: var(--serif-font), "Iowan Old Style", "Palatino Linotype", Georgia, serif; font-size: 30px; border-right: 1.5px dashed var(--line); }
.askbar input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--ink); font: 400 16px/1.2 "IBM Plex Mono", ui-monospace, monospace; padding: 18px 12px; }
.askbar input:focus { outline: none; }
.askbar:focus-within { box-shadow: 0 5px 0 var(--stamp); }
.askbar button { border: 0; border-left: 1.5px solid var(--ink); background: var(--ink); color: var(--desk); font: 600 13px/1 "IBM Plex Mono", ui-monospace, monospace; letter-spacing: .08em; text-transform: uppercase; padding: 0 20px; cursor: pointer; border-radius: 0 6px 6px 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 0; max-width: 860px; }
.chip { font: 400 12.5px/1.2 "IBM Plex Mono", ui-monospace, monospace; background: transparent; color: var(--ink); border: 1.5px solid var(--line); border-radius: 999px; padding: 8px 12px; cursor: pointer; text-align: left; }
.chip:hover { border-color: var(--ink); background: var(--paper); }
.chip small { color: var(--ink2); margin-left: 6px; }
#tray { margin-top: 28px; min-height: 12px; }

/* how */
.steps { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.step { background: var(--paper); border: 1.5px solid var(--ink); border-radius: 8px; padding: 18px; position: relative; }
.step .n { font-family: var(--serif-font), "Iowan Old Style", "Palatino Linotype", Georgia, serif; font-size: 44px; line-height: .9; color: var(--stamp); }
.step h3 { margin: 6px 0 6px; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; }
.step p { margin: 0; color: var(--ink2); font-size: 13.5px; }
.ladder { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 4px; margin: 26px 0 8px; font-size: 13px; }
.ladder span { border: 1.5px solid var(--ink); border-radius: 4px; padding: 5px 9px; background: var(--paper); font-weight: 600; }
.ladder span.hot { background: var(--stamp); border-color: var(--stamp); color: #fff; }
.ladder em { font-style: normal; color: var(--ink2); padding: 0 2px; }
@media (min-width: 820px) { .steps { grid-template-columns: repeat(3, 1fr); } }

/* feed + docket */
.two { display: grid; grid-template-columns: minmax(0, 1fr); gap: 44px; }
@media (min-width: 980px) { .two { grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); gap: 48px; } }
.feed { list-style: none; margin: 0; padding: 0; border-top: 1.5px solid var(--ink); }
.feed li { display: grid; grid-template-columns: 46px minmax(0, 1fr) auto; gap: 10px; align-items: baseline; padding: 11px 0; border-bottom: 1.5px dashed var(--line); font-size: 13px; }
.feed li.new { animation: drop .5s ease both; }
@keyframes drop { from { opacity: 0; transform: translateY(-8px); } }
.feed time { color: var(--ink2); font-size: 11.5px; }
.feed .txt b { font-weight: 500; }
.feed .txt span { color: var(--ink2); }
.feed .amt { font-weight: 600; text-align: right; white-space: nowrap; }
.tag { display: inline-block; font-size: 9.5px; letter-spacing: .1em; font-weight: 600; padding: 2px 5px; border-radius: 3px; border: 1.5px solid currentColor; margin-left: 6px; vertical-align: 1px; }
.tag.flip { color: var(--stamp); }
.tag.fresh { color: var(--honest); }
.docket { border-top: 1.5px solid var(--ink); }
.row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 14px; padding: 13px 0; border-bottom: 1.5px dashed var(--line); align-items: center; }
.row .q { font-family: var(--serif-font), "Iowan Old Style", "Palatino Linotype", Georgia, serif; font-size: 22px; line-height: 1.12; }
.row .says { grid-column: 1; color: var(--ink2); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .says b { color: var(--ink); font-weight: 500; }
.row .meta { grid-column: 1; font-size: 11.5px; color: var(--ink2); letter-spacing: .03em; }
.row .act { grid-column: 2; grid-row: 1 / span 3; }
.bars { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; margin-right: 8px; vertical-align: -2px; }
.bars u { width: 4px; background: var(--stamp); display: block; text-decoration: none; }

/* share */
.share { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; align-items: center; }
@media (min-width: 900px) { .share { grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: 64px; } }
.phone { background: var(--paper); border: 1.5px solid var(--ink); border-radius: 28px; padding: 18px 14px 16px; box-shadow: 8px 8px 0 var(--ink); max-width: 420px; }
.phone-top { text-align: center; font-size: 11px; color: var(--ink2); letter-spacing: .08em; margin-bottom: 12px; }
.bubble { max-width: 86%; padding: 9px 12px; border-radius: 16px; font: 400 14px/1.35 -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; margin: 6px 0; width: fit-content; }
.bubble.me { margin-left: auto; background: var(--ink); color: var(--desk); border-bottom-right-radius: 5px; }
.bubble.them { background: var(--desk); color: var(--ink); border-bottom-left-radius: 5px; }
.bubble.card { padding: 0; background: transparent; width: 86%; }
.og { background: var(--desk); color: var(--ink); border: 1.5px solid var(--ink); border-radius: 14px; padding: 14px; font-family: "IBM Plex Mono", ui-monospace, monospace; position: relative; overflow: hidden; }
.og-top { display: flex; justify-content: space-between; font-size: 9.5px; letter-spacing: .12em; font-weight: 600; }
.og-q { font-size: 15px; line-height: 1.2; margin: 10px 0 2px; color: var(--ink2); font-family: "IBM Plex Mono", ui-monospace, monospace; }
.og-a { font-size: 25px; line-height: 1.12; margin: 0 0 30px; overflow-wrap: anywhere; }
.og-bot { font-size: 10.5px; letter-spacing: .04em; color: var(--ink2); border-top: 1.5px dashed var(--line); padding-top: 9px; }
.og .stamp { position: absolute; right: 10px; bottom: 30px; font-size: 17px; padding: 4px 7px; border-width: 4px; }
.typing { display: inline-flex; gap: 4px; padding: 11px 13px; background: var(--desk); border-radius: 16px; margin-top: 6px; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--ink2); animation: pulse 1s infinite; }
.typing i:nth-child(2) { animation-delay: .2s; } .typing i:nth-child(3) { animation-delay: .4s; }
.linkbar { display: flex; align-items: center; gap: 10px; background: var(--paper); border: 1.5px solid var(--ink); border-radius: 8px; padding: 8px 8px 8px 14px; margin: 20px 0 12px; max-width: 560px; }
.linkbar code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 500 13px/1.3 "IBM Plex Mono", ui-monospace, monospace; }

/* rules */
.rules { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
@media (min-width: 820px) { .rules { grid-template-columns: 1fr 1fr; } }
.rulebox { border: 1.5px solid var(--ink); border-radius: 8px; padding: 20px; background: var(--paper); }
.rulebox h3 { margin: 0 0 10px; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; }
.rulebox ul { margin: 0; padding: 0; list-style: none; font-size: 13.5px; }
.rulebox li { padding: 7px 0 7px 26px; position: relative; border-top: 1.5px dashed var(--line); }
.rulebox li:first-child { border-top: 0; }
.rulebox li::before { position: absolute; left: 0; top: 7px; font-weight: 600; }
.no li::before { content: "✕"; color: var(--stamp); }
.yes li::before { content: "✓"; color: var(--honest); }

.foot { border-top: 1.5px solid var(--ink); padding: 22px 0 44px; font-size: 12px; color: var(--ink2); display: flex; flex-wrap: wrap; gap: 8px 22px; }
.foot a { color: var(--ink); }

/* dialog */
dialog { border: 1.5px solid var(--ink); border-radius: 12px; background: var(--paper); color: var(--ink); padding: 0; width: min(520px, calc(100vw - 24px)); box-shadow: 10px 10px 0 var(--ink); font: inherit; }
dialog::backdrop { background: rgba(10, 8, 4, .62); }
#buyForm { padding: 20px; display: grid; gap: 14px; }
.dlg-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.dlg-head h3 { margin: 0; font-size: 34px; line-height: 1; }
.x { border: 0; background: transparent; color: var(--ink); font-size: 26px; line-height: 1; cursor: pointer; padding: 2px 6px; }
.dlg-q { margin: 0; display: flex; gap: 9px; align-items: baseline; font-size: 13.5px; }
#buyForm label.f { display: grid; gap: 6px; font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; font-weight: 600; }
#buyForm label.f .hint { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--ink2); }
#buyForm input[type="text"] { font: 400 16px/1.2 "IBM Plex Mono", ui-monospace, monospace; padding: 12px; border: 1.5px solid var(--ink); border-radius: 6px; background: var(--desk); color: var(--ink); width: 100%; }
.locks { border: 0; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.locks legend { font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; font-weight: 600; padding: 0; margin-bottom: 6px; }
.locks label { border: 1.5px solid var(--line); border-radius: 6px; padding: 9px 8px; font-size: 12.5px; cursor: pointer; display: grid; gap: 2px; }
.locks label:has(input:checked) { border-color: var(--ink); background: var(--desk); }
.locks input { position: absolute; opacity: 0; pointer-events: none; }
.locks small { color: var(--ink2); font-size: 11px; }
.check { margin: 0; font-size: 12.5px; padding: 10px 12px; border-radius: 6px; border: 1.5px dashed var(--line); color: var(--ink2); min-height: 44px; }
.check.ok { color: var(--honest); border-color: var(--honest); }
.check.bad { color: var(--stamp); border-color: var(--stamp); }
.dlg-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.total span { display: block; font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink2); }
.total b { font-family: var(--serif-font), "Iowan Old Style", "Palatino Linotype", Georgia, serif; font-weight: 400; font-size: 38px; line-height: 1; }
#toast { position: fixed; left: 50%; bottom: 22px; transform: translate(-50%, 30px); background: var(--ink); color: var(--desk); padding: 11px 16px; border-radius: 8px; font-size: 13px; opacity: 0; transition: .25s; pointer-events: none; z-index: 50; max-width: calc(100vw - 32px); }
#toast.on { opacity: 1; transform: translate(-50%, 0); }

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

/* ===================================================================== */
/* Production additions                                                   */
/* ===================================================================== */
.ed-bg { --serif-font: "Cormorant"; --serif-weight: 600; }
.ed-bg h1 { font-size: clamp(46px, 8.2vw, 98px); line-height: .92; }
.ed-bg .rc-a { font-size: 30px; line-height: 1.1; hyphens: auto; }
.ed-bg .stamp { font-size: 20px; letter-spacing: .14em; text-indent: .14em; padding: 6px 9px; }
.ed-bg .stamp.honest { font-size: 16px; }
.ed-bg .tally b, .ed-bg .total b, .ed-bg .rc-honest p { font-weight: 600; }
.ed-bg .rc-honest p { font-size: 22px; line-height: 1.15; }

.skip { position: absolute; left: -9999px; top: 8px; background: var(--ink); color: var(--desk); padding: 8px 12px; border-radius: 6px; z-index: 60; }
.skip:focus { left: 12px; }
h1 i, h2 i { color: var(--stamp); }
.hero h1 { overflow-wrap: anywhere; }
.mock-pill { cursor: help; }
@media (max-width: 420px) { .mock-pill { font-size: 9px; padding: 3px 6px; letter-spacing: .08em; } .brand-name { font-size: 30px; } }

/* receipt extras */
.rc-q a { text-decoration: none; }
.rc-q a:hover { text-decoration: underline; }
.honest-a { color: var(--honest); font-style: italic; }
.rc-nfs .honest-a, .rc-review .honest-a { color: var(--ink2); }
.stamp.gray { color: var(--ink2); border-color: var(--ink2); }
.rc-note { margin: 8px 0 0; font-size: 12px; color: var(--ink2); border-left: 3px solid var(--stamp); padding: 2px 0 2px 9px; }
.rc-links { margin: 12px 0 0; font-size: 11.5px; color: var(--ink2); text-align: center; letter-spacing: .03em; }
.rc-links a { color: var(--ink2); }
.rc-links a:hover { color: var(--ink); }
#tray .rc-wrap, #pageReceipt .rc-wrap { margin: 0 auto; }
#tray { display: flex; flex-direction: column; align-items: flex-start; }
#tray .tray-link { margin: 14px 0 0; font-size: 12.5px; }
.ask-err { color: var(--stamp); font-size: 13px; margin: 14px 0 0; }
.askbar button[disabled] { opacity: .6; cursor: progress; }
.empty { color: var(--ink2); font-size: 13.5px; border-top: 1.5px solid var(--ink); padding: 14px 0 0; margin: 0; max-width: 52ch; }
.feed a { text-decoration: none; }
.feed a:hover b { text-decoration: underline; }
.row a.q { text-decoration: none; }
.row a.q:hover { text-decoration: underline; }

/* buy sheet */
#buyForm, .wait { padding: 20px; display: grid; gap: 14px; }
#buyStep1 { display: grid; gap: 14px; }
#buyForm label.f, .form label.f, .wait label.f { display: grid; gap: 6px; font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; font-weight: 600; }
label.f .hint { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--ink2); }
#buyForm input[type="text"], .form input[type="text"], .form input[type="email"], .form textarea, .wait input, .inline-form input {
  font: 400 16px/1.3 "IBM Plex Mono", ui-monospace, monospace; padding: 12px; border: 1.5px solid var(--ink); border-radius: 6px; background: var(--desk); color: var(--ink); width: 100%; }
.form textarea { resize: vertical; }
.buy-preview .rc-wrap { max-width: none; filter: none; }
.buy-preview .rc { padding-bottom: 26px; }
.buy-preview .rc-a { font-size: 22px; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 12px; line-height: 1.45; color: var(--ink2); cursor: pointer; }
.consent input { margin-top: 2px; width: 18px; height: 18px; flex: none; accent-color: var(--stamp); }
.dlg-fine { margin: 0; }
dialog[open] { animation: rise .18s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }
dialog { max-height: calc(100dvh - 24px); overflow-y: auto; }
.locks[hidden] { display: none; }
.btn.busy { cursor: progress; opacity: .75; }

/* question page */
.qpage { display: grid; grid-template-columns: minmax(0, 1fr); gap: 30px; padding-top: 26px; padding-bottom: 30px; }
.q-h1 { font-size: clamp(40px, 6.6vw, 80px); line-height: .98; margin: 0 0 22px; text-wrap: balance; overflow-wrap: anywhere; }
.qpage-share { margin: 0 0 22px; }
.qpage-share h2.kicker { font-size: 11.5px; font-family: inherit; margin: 0; }
.qpage-r { display: flex; flex-direction: column; align-items: center; }
.qpage-r .slot { width: min(100%, 480px); }
#pageReceipt { width: min(100% - 28px, 440px); margin-top: -6px; }
@media (min-width: 900px) {
  .qpage { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 56px; padding-top: 44px; align-items: start; }
  #pageReceipt { transform: rotate(1deg); transform-origin: top center; }
}
.kicker a { color: inherit; }
.ledger { list-style: none; margin: 0; padding: 0; border-top: 1.5px solid var(--ink); max-width: 860px; }
.ledger li { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 4px 14px; padding: 14px 0; border-bottom: 1.5px dashed var(--line); }
.ledger-no { font-size: 12px; color: var(--ink2); grid-row: span 2; padding-top: 6px; }
.ledger-a { font-size: 24px; line-height: 1.15; }
.ledger-live .ledger-a mark { -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.ledger-replaced .ledger-a { color: var(--ink2); text-decoration: line-through; text-decoration-thickness: 1.5px; text-decoration-color: var(--stamp); }
.ledger-meta { font-size: 12px; color: var(--ink2); }
.ledger-meta a { color: var(--ink2); }
.muted { color: var(--ink2); font-size: 13px; }
.linkbar .native-share { flex: none; }

/* plain pages */
.narrow { max-width: 760px; }
.page { padding-top: 30px; padding-bottom: 60px; }
.page-h1 { font-size: clamp(42px, 7vw, 72px); line-height: 1; margin: 0 0 16px; }
.notice { border: 1.5px solid var(--ink); border-radius: 8px; background: var(--paper); padding: 16px 18px; margin: 0 0 22px; }
.notice.ok { border-color: var(--honest); }
.notice.bad { border-color: var(--stamp); }
.notice h2 { margin: 0 0 6px; font-size: 32px; }
.notice ul { margin: 8px 0 0; padding-left: 20px; }
.form { display: grid; gap: 16px; margin: 18px 0 0; }
.radios { border: 0; padding: 0; margin: 0; display: grid; gap: 8px; }
.radios legend { font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; font-weight: 600; margin-bottom: 8px; padding: 0; }
.radios label { display: flex; gap: 10px; align-items: center; font-size: 14px; border: 1.5px solid var(--line); border-radius: 6px; padding: 10px 12px; cursor: pointer; background: var(--paper); }
.radios label:has(input:checked) { border-color: var(--ink); }
.radios input { accent-color: var(--stamp); }
.two-in { display: grid; gap: 16px; }
@media (min-width: 640px) { .two-in { grid-template-columns: 1fr 1fr; } }
.quoted { margin: 0 0 18px; border-left: 4px solid var(--stamp); background: var(--paper); padding: 14px 16px; }
.quoted p { margin: 6px 0; font-size: 24px; line-height: 1.15; }
.quoted small { color: var(--ink2); }
.legal h2 { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; margin: 28px 0 8px; font-family: inherit; }
.legal p, .legal li { font-size: 14px; max-width: 68ch; }
.legal ul { padding-left: 20px; }

/* pretend card reader */
.terminal { background: var(--paper); border: 1.5px solid var(--ink); border-radius: 18px; padding: 18px; box-shadow: 8px 8px 0 var(--ink); }
.terminal-screen { background: #1d2a1f; color: #b8f5c8; border-radius: 10px; padding: 16px; font-size: 13px; margin-bottom: 18px; box-shadow: inset 0 0 0 3px rgba(0,0,0,.3); }
.term-row { display: flex; justify-content: space-between; gap: 10px; font-weight: 600; letter-spacing: .08em; }
.term-q { color: #8fd4a3; margin: 12px 0 4px; }
.term-a { font-size: 16px; margin: 0 0 10px; }
.term-by { margin: 0; color: #8fd4a3; font-size: 12px; }

/* admin */
.admin h2 { font-size: 34px; margin: 34px 0 10px; }
.tbl { overflow-x: auto; border: 1.5px solid var(--ink); border-radius: 8px; background: var(--paper); }
.tbl table { border-collapse: collapse; width: 100%; font-size: 12.5px; }
.tbl th, .tbl td { text-align: left; vertical-align: top; padding: 8px 10px; border-bottom: 1.5px dashed var(--line); }
.tbl th { font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink2); white-space: nowrap; }
.tbl pre { white-space: pre-wrap; font: inherit; color: var(--ink2); margin: 4px 0 0; max-height: 140px; overflow: auto; }
form.inline { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.inline-form { display: flex; gap: 10px; align-items: center; max-width: 640px; grid-template-columns: none; }
.inline-form input { flex: 1; }
.dot { display: inline-block; vertical-align: 1px; }
