@font-face {
  font-family: "Archivo";
  src: url("/fonts/archivo-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --gold: #F0B90B;
  --ink: #000;
  --paper: #F6F4EF;
  --white: #fff;
  --grey: #5B5B57;
  --line: #000;
  --peach: #F6CDA3;
  --sky: #6CC6F2;
  --life: #FFD400;
  --sans: "Archivo", "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  --pad: clamp(20px, 4vw, 56px);
  --max: 1200px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { animation: none !important; transition: none !important; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.55 var(--sans);
  font-stretch: 100%;
}

a { color: inherit; }
img { display: block; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }

[hidden] { display: none !important; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--white); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }

/* ── Header ─────────────────────────────────────── */
.top {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; gap: 24px;
  padding: 14px var(--pad);
  background: var(--gold);
  border-bottom: 2px solid var(--ink);
}
.mark {
  font-weight: 900; font-stretch: 70%; font-size: 30px; line-height: 1;
  letter-spacing: -0.01em; text-decoration: none;
}
.nav { display: flex; gap: 28px; margin-left: auto; }
.nav a { text-decoration: none; font-weight: 600; font-size: 15px; }
.nav a:hover { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 2px; }
.tools { display: flex; gap: 10px; align-items: center; }
.lang {
  font: 700 15px/1 var(--sans); min-width: 44px; height: 40px; padding: 0 10px;
  background: var(--white); color: var(--ink); border: 2px solid var(--ink); border-radius: 999px; cursor: pointer;
}
.lang:hover { background: var(--ink); color: var(--gold); }
.menu { display: none; width: 44px; height: 40px; background: none; border: 2px solid var(--ink); border-radius: 10px; cursor: pointer; padding: 0 10px; }
.menu span { display: block; height: 2px; background: var(--ink); margin: 5px 0; }

/* ── Hero ───────────────────────────────────────── */
.hero {
  background: var(--gold);
  padding: clamp(28px, 4vw, 56px) var(--pad) clamp(44px, 6vw, 88px);
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(32px, 5vw, 80px); align-items: start;
  border-bottom: 2px solid var(--ink);
}
.hero > * { max-width: 680px; }
h1 {
  margin: 0 0 22px;
  font-weight: 900; font-stretch: 62%;
  font-size: clamp(60px, 8vw, 124px); line-height: 0.88; letter-spacing: -0.015em;
}
html[lang="zh-CN"] h1 { font-size: clamp(44px, 5.6vw, 84px); line-height: 1.02; letter-spacing: 0; }
.lede { font-size: clamp(17px, 1.5vw, 20px); max-width: 34em; margin: 0 0 24px; }

.steps { list-style: none; margin: 0 0 26px; padding: 0; display: grid; gap: 0; counter-reset: s; max-width: 560px; }
.steps li {
  counter-increment: s; display: grid; grid-template-columns: 44px 1fr; column-gap: 14px;
  padding: 9px 0; border-top: 2px solid var(--ink);
}
.steps li:last-child { border-bottom: 2px solid var(--ink); }
.steps li::before {
  content: counter(s); grid-row: span 2;
  width: 36px; height: 36px; border-radius: 50%; background: var(--ink); color: var(--gold);
  display: grid; place-items: center; font-weight: 800; font-size: 17px; margin-top: 2px;
}
.steps b { font-size: 19px; font-weight: 750; }
.steps span { color: #2b2610; font-size: 16px; }

.cta { display: flex; flex-wrap: wrap; gap: 14px 22px; align-items: center; }
.buy {
  display: inline-flex; align-items: center; min-height: 56px; padding: 0 28px;
  background: var(--ink); color: var(--gold); border-radius: 999px;
  font-weight: 800; font-size: 18px; text-decoration: none;
}
.buy[aria-disabled="true"] { background: transparent; color: var(--ink); border: 2px dashed var(--ink); cursor: default; }
.buy:not([aria-disabled="true"]):hover { background: #222; }
.more { font-weight: 700; text-underline-offset: 5px; text-decoration-thickness: 2px; }

.ca { margin-top: 18px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14px; font-weight: 700; }
.ca code { background: var(--white); border: 2px solid var(--ink); border-radius: 8px; padding: 6px 10px; font: 600 13px/1.3 ui-monospace, Menlo, monospace; word-break: break-all; }
.ca button { font: 700 14px/1 var(--sans); padding: 9px 14px; border-radius: 999px; border: 2px solid var(--ink); background: var(--ink); color: var(--gold); cursor: pointer; }

/* The split slip: the one loud thing on the page */
.slip {
  margin: 0; background: var(--white); border: 2px solid var(--ink); border-radius: 18px;
  box-shadow: 8px 8px 0 var(--ink); overflow: hidden; justify-self: end; width: 100%;
}
.slip::before {
  content: ""; display: block; height: 18px;
  background: linear-gradient(90deg, var(--gold) 0 25%, var(--ink) 25% 50%, var(--peach) 50% 75%, var(--sky) 75% 100%);
  border-bottom: 2px solid var(--ink);
}
.slip figcaption { padding: 20px 22px 6px; display: grid; gap: 2px; }
.slip figcaption b { font-size: 22px; font-weight: 800; font-stretch: 85%; }
.slip figcaption span { color: var(--grey); font-size: 14px; }
.rows { list-style: none; margin: 0; padding: 0 22px; }
.row {
  display: grid; grid-template-columns: 32px minmax(0, 1fr) auto;
  grid-template-areas: "icon name amt" "icon name usd";
  column-gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid #d9d6cc;
}
.row:last-child { border-bottom: 0; }
.row img { grid-area: icon; width: 32px; height: 32px; border-radius: 50%; }
.row .name { grid-area: name; font-weight: 700; }
.row .amt { grid-area: amt; font-weight: 800; font-size: 24px; line-height: 1.1; font-stretch: 80%; font-variant-numeric: tabular-nums; text-align: right; }
.row .usd { grid-area: usd; color: var(--grey); font-size: 13px; text-align: right; }
.slipfoot { margin: 0; padding: 12px 22px 18px; font-size: 13px; color: var(--grey); border-top: 2px solid var(--ink); background: var(--paper); }
.stamp { white-space: nowrap; }
.stamp.stale { color: #9a2b00; }

/* ── Sections ───────────────────────────────────── */
main > section:not(.hero) { padding: clamp(56px, 8vw, 112px) var(--pad); max-width: calc(var(--max) + 2 * var(--pad)); margin: 0 auto; }
h2 {
  margin: 0 0 10px; font-weight: 900; font-stretch: 68%;
  font-size: clamp(40px, 5.6vw, 76px); line-height: 0.95; letter-spacing: -0.01em;
}
html[lang="zh-CN"] h2 { font-size: clamp(32px, 4.2vw, 56px); line-height: 1.1; letter-spacing: 0; }
.intro { margin: 0 0 36px; color: var(--grey); font-size: 18px; max-width: 36em; }

.coinrow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 2px solid var(--ink); border-radius: 18px; overflow: hidden; background: var(--white); }
.coin { padding: 26px 22px 28px; border-left: 2px solid var(--ink); position: relative; }
.coin:first-child { border-left: 0; }
.coin::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 10px; border-bottom: 2px solid var(--ink); }
.coin[data-coin="bnb"]::before { background: var(--gold); }
.coin[data-coin="life"]::before { background: var(--ink); }
.coin[data-coin="aster"]::before { background: var(--peach); }
.coin[data-coin="giggle"]::before { background: var(--sky); }
.coin img { width: 56px; height: 56px; border-radius: 50%; margin: 14px 0 16px; border: 2px solid var(--ink); }
.coin h3 { margin: 0; font-size: 26px; font-weight: 850; font-stretch: 80%; }
.coin .price { margin: 2px 0 12px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--grey); }
.coin p:last-child { margin: 0; font-size: 16px; }

.flow { list-style: none; margin: 32px 0 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; counter-reset: f; }
.flow li { counter-increment: f; padding: 0 22px 0 0; display: grid; align-content: start; gap: 8px; }
.flow li::before {
  content: counter(f); font-weight: 900; font-stretch: 62%; font-size: 64px; line-height: 0.9;
  border-bottom: 2px solid var(--ink); padding-bottom: 10px; margin-bottom: 6px;
}
.flow b { font-size: 19px; font-weight: 800; line-height: 1.25; }
.flow span { font-size: 16px; color: #2c2c29; }
.aside { margin: 40px 0 0; font-size: 16px; color: var(--grey); }

/* Payout calculator */
.payout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.calc label { display: block; font-weight: 700; margin: 18px 0 8px; }
.field { display: flex; align-items: center; gap: 8px; background: var(--white); border: 2px solid var(--ink); border-radius: 12px; padding: 0 14px; }
.field:focus-within { box-shadow: 4px 4px 0 var(--ink); }
.field input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; font: 800 24px/1 var(--sans); font-stretch: 85%; padding: 14px 0; font-variant-numeric: tabular-nums; color: var(--ink); }
.field .pre { font-weight: 800; font-size: 22px; }
.hint { color: var(--grey); font-size: 14px; white-space: nowrap; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.chips button { font: 700 15px/1 var(--sans); padding: 10px 14px; border-radius: 999px; border: 2px solid var(--ink); background: var(--paper); cursor: pointer; color: var(--ink); }
.chips button[aria-pressed="true"] { background: var(--ink); color: var(--gold); }
.result { background: var(--white); border: 2px solid var(--ink); border-radius: 18px; padding: 8px 0 0; }
.total { margin: 0; padding: 16px 22px; display: flex; justify-content: space-between; align-items: baseline; gap: 12px; border-bottom: 2px solid var(--ink); }
.total span { font-weight: 700; }
.total b { font-weight: 900; font-stretch: 70%; font-size: clamp(36px, 4vw, 52px); line-height: 1; font-variant-numeric: tabular-nums; }
.result .row { grid-template-areas: "icon name amt"; }
.result .row img { width: 28px; height: 28px; }
.result .row .amt { font-size: 20px; }
.fine { margin: 0; padding: 12px 22px 16px; font-size: 13px; color: var(--grey); border-top: 1px solid #d9d6cc; }

.know dl { margin: 32px 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border-top: 2px solid var(--ink); }
.know dl > div { padding: 22px 24px 26px 0; border-bottom: 1px solid #cfccc2; }
.know dt { font-weight: 800; font-size: 19px; margin-bottom: 6px; }
.know dd { margin: 0; font-size: 16px; color: #2c2c29; max-width: 30em; }

.foot { background: var(--ink); color: var(--paper); padding: 40px var(--pad); display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; }
.foot .mark { color: var(--gold); font-size: 40px; }
.foot p { margin: 0; }
.foot .links { margin-left: auto; display: flex; gap: 20px; font-weight: 700; }
.foot a { color: var(--paper); }

/* ── Responsive ─────────────────────────────────── */
@media (max-width: 1080px) {
  .flow { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 36px; }
  .coinrow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .coin:nth-child(3) { border-left: 0; }
  .coin:nth-child(n+3) { border-top: 2px solid var(--ink); }
  .know dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .slip { justify-self: stretch; }
  .payout { grid-template-columns: 1fr; }
  .menu { display: block; }
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; gap: 0; background: var(--gold); border-bottom: 2px solid var(--ink);
  }
  .nav.open { display: flex; }
  .nav a { padding: 16px var(--pad); border-top: 1px solid rgba(0,0,0,.25); font-size: 18px; }
  .tools { margin-left: auto; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .flow { grid-template-columns: 1fr; }
  .flow li { grid-template-columns: 56px 1fr; column-gap: 14px; padding: 0; }
  .flow li::before { grid-row: span 2; font-size: 48px; border-bottom: 0; padding: 0; margin: 0; }
  .coinrow { grid-template-columns: 1fr; }
  .coin { border-left: 0; }
  .coin:nth-child(n+2) { border-top: 2px solid var(--ink); }
  .know dl { grid-template-columns: 1fr; }
    .foot .links { margin-left: 0; }
}
