/* Emote: the taunts players fire at each other mid-battle. Two round blob players stand on their pads in a small
   arena under a lilac sky, yours blue, your rival's red, and fire speech bubbles with hand-drawn faces across it:
   laugh, cry, thumbs-up, angry. The pot sits in the big gold-rimmed bubble in the middle; the winner's bubble lands
   last. The header is the emote tray (grape, with its lighter lip), the hero is the sky over the arena floor. Supercell-
   style cartoon system: thick outline on letters and objects, 3-stop gradients, a hard drop under everything that can be
   pressed. Fonts are self-hosted (SIL Open Font License): Coiny, M PLUS Rounded 1c. No Supercell artwork. */
@font-face { font-family: 'Coiny'; src: url('/fonts/coiny.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'M PLUS Rounded 1c'; src: url('/fonts/mplus-500.woff2') format('woff2'); font-weight: 400 500; font-display: swap; }
@font-face { font-family: 'M PLUS Rounded 1c'; src: url('/fonts/mplus-700.woff2') format('woff2'); font-weight: 600 700; font-display: swap; }
@font-face { font-family: 'M PLUS Rounded 1c'; src: url('/fonts/mplus-800.woff2') format('woff2'); font-weight: 800 900; font-display: swap; }

:root {
  --ink: #24163d;
  --page: #fdf6ea;
  --felt: #3b2170;
  --felt-deep: #24113f;
  --on-felt: #24163d;
  --on-felt-muted: #655a78;
  --on-dark: #f3eefc;
  --on-dark-muted: #c4b6e4;
  --panel: #fffdf9;
  --panel-2: #f3eef9;
  --line: #e4dcef;
  --text: #24163d;
  --muted: #655a78;
  --tang: #ffc928;
  --tang-soft: #ffe1dc;
  --link: #5a2fc0;
  --lime: #ffd23f;
  --red: #e0382e;
  --plus: #258a49;
  --beech: #4f2c8c;
  --beech-deep: #2b1650;
  --teal: #2f93f2;
  --teal-deep: #1659b5;
  --gold: #ffc928;
  --gold-deep: #a66804;
  --pink: #8460d2;
  /* the buttons are the yellow of the faces */
  --g-act: linear-gradient(180deg, #fff3a6 0%, #ffc928 52%, #d68a00 100%);
  --g-tang: linear-gradient(180deg, #fff3a6 0%, #ffc928 52%, #c47f06 100%);
  --g-you: linear-gradient(180deg, #a9dcff 0%, #2f93f2 52%, #1659b5 100%);
  --g-gold: linear-gradient(180deg, #fff3a6 0%, #ffc928 52%, #c47f06 100%);
  --g-beech: linear-gradient(180deg, #8460d2 0%, #4f2c8c 52%, #2b1650 100%);
  --g-iron: linear-gradient(180deg, #ffffff 0%, #f6f1fd 52%, #d8cdeb 100%);
  --g-rival: linear-gradient(180deg, #ffb2a0 0%, #f4473a 52%, #9c1d14 100%);
  --g-elixir: linear-gradient(180deg, #b597f0 0%, #6b43c4 52%, #3b2170 100%);
  /* the sky over the arena */
  --sky: linear-gradient(180deg, #bfaef5 0%, #e3dafd 55%, #fbf3ff 100%);
  --g-wall: radial-gradient(60% 50% at 20% 26%, rgba(255, 255, 255, .7) 0 30%, transparent 31%) 0 0 / 0 0 no-repeat, var(--sky);
  /* the arena floor: warm sand with a dashed lane */
  --floor: repeating-linear-gradient(90deg, rgba(185, 138, 68, .45) 0 10px, transparent 10px 18px) 0 60% / 100% 2px no-repeat, linear-gradient(180deg, #f8e3b4 0%, #eccb8a 60%, #d8ad66 100%);
  --mat: var(--floor);
  --grain: linear-gradient(transparent, transparent);
  --stitch: linear-gradient(180deg, #a88be6, #7c5bc9);
  --rope: var(--stitch);
  --posts: linear-gradient(transparent, transparent);
  /* the sheen of a glossy bubble on coloured surfaces */
  --blocks: linear-gradient(180deg, rgba(255, 255, 255, .16) 0 42%, transparent 42%);
  /* paper fibre */
  --nap: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .25 0 0 0 0 .15 0 0 0 0 .35 0 0 0 .45 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='.09'/%3E%3C/svg%3E");
  --table: var(--sky);
  --display: 'Coiny', 'Arial Rounded MT Bold', 'Arial Black', sans-serif;
  --body: 'M PLUS Rounded 1c', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --edge: 3px solid var(--ink);
  --lift: inset 0 3px 0 #fff, 0 6px 0 var(--ink);
  --wrap: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column; overflow-x: clip;
  background: var(--nap), radial-gradient(1400px 900px at 70% -10%, #fffdf8 0%, rgba(255, 253, 248, 0) 70%), linear-gradient(180deg, #fffaf1 0%, var(--page) 55%, #f1e6d6 100%); background-color: var(--page); color: var(--text); font: 500 17px/1.5 var(--body); -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p, ol, ul, dl, dd { margin: 0; }
ol, ul { padding: 0; list-style: none; }
a { color: inherit; }
img, svg { display: block; }
button, input { font: inherit; color: inherit; }
::selection { background: #8460d2; color: #fff; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; }
[hidden] { display: none !important; }

.ico { width: 1.3em; height: 1.3em; flex: none; }
.ico.line { width: 1.1em; height: 1.1em; }
/* white lettering with a dark outline and a hard drop, the look of every title in the game */
h1, h2, .plate, .btn, .brand-name, .vs, .p-vs, .p-side b, .callout h3, .badge, .step-no, .splitbar i, .steps li::before {
  font-family: var(--display); font-weight: 400; color: #fff;
  -webkit-text-stroke: .09em var(--ink); paint-order: stroke fill; text-shadow: 0 .08em 0 var(--ink); letter-spacing: .02em;
}
h1, h2 { line-height: 1.08; letter-spacing: .03em; }
.small { font-size: 14px; }
.muted { color: var(--muted); }
.center { text-align: center; justify-content: center; }
.mono { font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.grow { flex: 1; min-width: 0; }
.stack { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.row { display: flex; align-items: center; gap: 10px; }
.row.between { justify-content: space-between; }
.row.wrap { flex-wrap: wrap; }
.row.tight { gap: 6px; justify-content: flex-end; }
.fine { font-size: 14px; font-weight: 700; color: var(--muted); }
.lede { font-size: 20px; line-height: 1.45; font-weight: 500; max-width: 33em; color: var(--on-felt); }
.more { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--link); text-underline-offset: 4px; }
.card .more { color: var(--link); }
.linkish { padding: 0; border: 0; background: none; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; font-weight: 700; color: var(--link); }

/* short labels in Coiny, set in capitals */
.prize-box i, .reward i, .res-tag, .form-strip i, .code-in, .tiles span { text-transform: uppercase; }

/* ---------- top bar: the emote tray, grape with a lighter lip along its foot ---------- */
.top { position: sticky; top: 0; z-index: 30; padding-bottom: 12px; background: radial-gradient(60% 140% at 50% 0%, rgba(190, 160, 255, .28), transparent 70%), linear-gradient(180deg, #55309a, #3b2170 60%, #2b1650); box-shadow: 0 5px 0 rgba(36, 22, 61, .2); }
.top::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 12px; background: linear-gradient(180deg, #b79cf0, #8460d2); border-top: 3px solid var(--ink); border-bottom: 3px solid var(--ink); }
.top-in { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark { width: 50px; height: 50px; flex: none; filter: drop-shadow(0 3px 0 rgba(20, 8, 40, .45)); }
.brand-name { font-size: 31px; line-height: 1; padding-bottom: 3px; }
.brand-name b { font-weight: 400; color: var(--lime); }
.hud { display: flex; align-items: center; gap: 10px; }
.navlinks { display: none; gap: 24px; margin-right: 8px; }
.navlinks a { font: 600 16px/1 var(--body); text-decoration: none; color: var(--on-dark); padding: 8px 0; border-bottom: 3px solid transparent; }
.navlinks a:hover { border-color: var(--lime); }
.net-note { font: 600 13px/1.2 var(--body); color: var(--on-dark-muted); white-space: nowrap; text-transform: capitalize; }
@media (min-width: 960px) { .navlinks { display: flex; } }
@media (max-width: 560px) {
  .top .stats-btn, .net-note + .net-note { display: none; }
  .brand-name { font-size: 25px; } .brand-mark { width: 40px; height: 40px; }
  .top-in { padding: 0 14px; gap: 8px; min-height: 66px; } .hud { gap: 8px; }
}
@media (max-width: 370px) { .net-note { display: none; } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; position: relative;
  min-height: 52px; padding: 0 22px 2px; border: var(--edge); border-radius: 14px; background: var(--g-act);
  font-size: 19px; line-height: 1; letter-spacing: .02em; text-decoration: none; white-space: nowrap; cursor: pointer;
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, .6), inset 0 -5px 0 rgba(0, 0, 0, .14), 0 5px 0 var(--ink);
  transition: transform .08s, box-shadow .08s, filter .12s;
}
.btn .ico { -webkit-text-stroke: 0; }
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: translateY(4px); box-shadow: inset 0 3px 0 rgba(255, 255, 255, .6), inset 0 -5px 0 rgba(0, 0, 0, .14), 0 1px 0 var(--ink); }
.btn.ink { background: var(--g-beech); color: #fff; }
.btn.ghost { background: var(--g-iron); color: var(--ink); -webkit-text-stroke: 0 transparent; text-shadow: 0 2px 0 #fff; }
.top .btn.ghost { background: linear-gradient(180deg, #ffffff 0%, #f3eefc 52%, #cbbde6 100%); }
.btn.sm { min-height: 42px; padding: 0 15px 2px; border-radius: 11px; font-size: 16px; }
.btn.lg { min-height: 68px; padding: 0 30px 3px; border-radius: 18px; font-size: 26px; }
.btn.wide { width: 100%; }
.btn.wide, .btn.lg { white-space: normal; text-align: center; padding-block: 8px 9px; }
@media (max-width: 520px) { .btn.lg { font-size: 21px; padding-inline: 18px; min-height: 62px; } }
.btn.icon-btn { width: 46px; min-height: 46px; padding: 0; border-radius: 12px; }
.btn.icon-btn .ico { margin: 0; }
.top .icon-btn { width: 42px; min-height: 42px; }
.btn .wicon { width: 28px; height: 28px; border-radius: 6px; }
.btn.loading { color: transparent !important; -webkit-text-stroke: 0 transparent; text-shadow: none; pointer-events: none; }
.btn.loading > * { visibility: hidden; }
.btn.loading::after { content: ""; position: absolute; width: 24px; height: 24px; border: 4px solid #fff; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
.btn.ghost.loading::after { border-color: var(--ink); border-right-color: transparent; }
body.busy .btn:not(.loading) { opacity: .65; pointer-events: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- forms ---------- */
.field { display: block; margin-bottom: 6px; font: 700 14px/1.2 var(--body); color: var(--muted); }
input {
  width: 100%; min-width: 0; height: 52px; padding: 0 14px; border: var(--edge); border-radius: 12px; background: #fff; color: var(--text);
  font: 700 17px/1 var(--body); appearance: none; box-shadow: inset 0 4px 0 rgba(25, 26, 44, .07);
}
input::placeholder { color: #a497b8; }
input:focus-visible { outline: 3px solid var(--tang); outline-offset: 2px; }
.row > input.grow { width: auto; }
.big-in { height: 72px; font: 400 32px/1 var(--display); letter-spacing: .02em; }
.code-in { font: 400 22px/1 var(--display); text-transform: uppercase; letter-spacing: .14em; }
.code-in::placeholder { letter-spacing: .02em; text-transform: none; }
.segs { display: inline-flex; border: var(--edge); border-radius: 12px; overflow: hidden; background: var(--panel-2); }
.segs.wide { display: flex; }
.seg { flex: 1; min-height: 46px; padding: 0 12px; border: 0; border-left: var(--edge); background: none; color: var(--text); cursor: pointer; font: 700 15px/1.1 var(--body); }
.seg:first-child { border-left: 0; }
.seg:hover { background: #e9e0f6; }
.seg.on { background: var(--g-you); color: #fff; text-shadow: 0 2px 0 rgba(25, 26, 44, .6); box-shadow: inset 0 3px 0 rgba(255, 255, 255, .35); }
.divider { display: flex; align-items: center; gap: 12px; font: 700 14px/1 var(--body); color: var(--muted); }
.divider::before, .divider::after { content: ""; flex: 1; height: 3px; border-radius: 3px; background: var(--line); }

/* ---------- cards ---------- */
.card { position: relative; min-width: 0; padding: 20px; background: var(--panel); color: var(--text); border: var(--edge); border-radius: 20px; box-shadow: var(--lift); }
.card a:not(.btn) { color: var(--link); }
.plate {
  margin: -20px -20px 18px; padding: 10px 20px 12px; border-bottom: var(--edge); border-radius: 17px 17px 0 0;
  position: relative; background: var(--blocks), var(--g-beech); box-shadow: inset 0 3px 0 rgba(255, 255, 255, .3); font-size: 23px; line-height: 1.15; text-align: center;
}
/* the plate is a speech bubble: its tail hangs down on the left */
.plate::before, .plate::after { content: ""; position: absolute; left: 30px; top: 100%; width: 22px; height: 15px; clip-path: polygon(0 0, 100% 0, 10% 100%); }
.plate::before { background: var(--ink); margin-top: 0; width: 28px; height: 19px; left: 27px; }
.plate::after { background: #2f1858; margin-top: -1px; }
.plate.hot::after { background: #c98706; }
.plate.hot { background: var(--blocks), var(--g-tang); }
.well { padding: 11px 14px; border-radius: 12px; background: var(--panel-2); color: var(--text); }
.note { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: var(--edge); border-radius: 14px; background: #fff1c2; color: var(--text); }
.note > .ico { width: 30px; height: 30px; }
.note.bad { background: var(--tang-soft); align-items: flex-start; }
/* small facts set in text, never as pills */
.chip { display: inline-flex; align-items: center; gap: 6px; font: 700 14px/1.4 var(--body); color: var(--muted); white-space: nowrap; }
.chip b { color: var(--text); font-weight: 700; }
.chip.yours { color: var(--teal-deep); }
.chip.prize { color: var(--gold-deep); }
.chip.prize b { color: var(--gold-deep); }
.chips { display: flex; flex-wrap: wrap; gap: 2px 16px; margin-top: 2px; }
.mode-tag { font: 700 13px/1.4 var(--body); color: var(--beech-deep); white-space: nowrap; }
.mode-tag.m-team { color: var(--teal-deep); }
.badge {
  display: inline-grid; place-items: center; width: 50px; height: 50px; flex: none; padding-bottom: 3px; border: var(--edge); border-radius: 13px;
  background: var(--g-you); font-size: 24px; line-height: 1; text-transform: uppercase; box-shadow: inset 0 3px 0 rgba(255, 255, 255, .5), 0 3px 0 var(--ink);
}
.badge.red { background: var(--g-rival); }
.badge.none { background: var(--panel-2); border-style: dashed; color: var(--muted); -webkit-text-stroke: 0 transparent; text-shadow: none; box-shadow: none; }
.corner-label { display: block; font: 700 13px/1.3 var(--body); color: var(--teal-deep); }

/* ---------- timer: the grape bar runs down ---------- */
.clock { display: flex; align-items: center; gap: 10px; }
.clock > .ico { width: 32px; height: 32px; }
.clock .bar { flex: 1; height: 20px; border: var(--edge); border-radius: 999px; background: #ebe3f6; overflow: hidden; }
.clock .bar i { display: block; height: 100%; background: var(--g-elixir); box-shadow: inset 0 3px 0 rgba(255, 255, 255, .45); transition: width 1s linear; }
.clock time { font: 400 22px/1 var(--display); color: var(--text); font-variant-numeric: tabular-nums; min-width: 3.1ch; text-align: right; }
.clock.low .bar i { background: var(--g-rival); }
.clock.low time { color: var(--red); }

/* ---------- main page ---------- */
#app { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; flex: 1; }
body[data-page="home"] #app { max-width: none; padding: 0; }
.boot { min-height: 60vh; display: grid; place-content: center; justify-items: center; gap: 16px; font-weight: 600; color: var(--muted); }
.boot .brand-mark { width: 84px; height: 84px; animation: bob 1.1s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-8px); } }

/* the hero is the sky over the arena: lilac light, two soft clouds, the sand floor along its foot */
.hero { position: relative; overflow: hidden; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 40'%3E%3Cpath d='M8 30a10 10 0 0 1 16-7 13 13 0 0 1 24 1 9 9 0 0 1 4 16H13a8 8 0 0 1-5-10z' fill='%23fff' fill-opacity='.7'/%3E%3C/svg%3E") 6% 18% / 200px auto no-repeat, url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 40'%3E%3Cpath d='M8 30a10 10 0 0 1 16-7 13 13 0 0 1 24 1 9 9 0 0 1 4 16H13a8 8 0 0 1-5-10z' fill='%23fff' fill-opacity='.6'/%3E%3C/svg%3E") 94% 8% / 150px auto no-repeat, linear-gradient(180deg, #c9baf7 0%, #e6defd 45%, #fbf4ff 80%, #fdf6ea 100%); }
.hero::after { content: ""; position: absolute; left: -2%; right: -2%; bottom: 0; height: 64px; border-top: 3px solid var(--ink); border-radius: 50% 50% 0 0 / 22px 22px 0 0; background: var(--floor); }
.hero-in { position: relative; z-index: 1; max-width: var(--wrap); margin: 0 auto; padding: 34px 20px 92px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: center; }
.hero-copy { min-width: 0; }
.hero h1 { margin: 0 0 22px; font-size: clamp(38px, 10vw, 84px); line-height: 1.06; }
.hero h1 em, .final h2 em { display: block; font-style: normal; color: var(--tang); }
.hero .cta { margin-top: 30px; }
.hero .fine { margin-top: 24px; color: var(--muted); }
@media (max-width: 520px) { .lede { font-size: 18px; } .hero-in { padding-top: 26px; } .split { gap: 10px; } .split div { padding-left: 9px; border-left-width: 6px; } }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 22px; }
.cta.center { margin-top: 30px; }
@media (min-width: 960px) {
  .hero-in { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); padding: 60px 20px 100px; }
  .hero h1 { font-size: clamp(50px, 4.4vw, 64px); }
}

/* the duel card: the arena with both blobs, their emotes in flight, the pot in the big bubble between them */
.poster-wrap { display: grid; justify-items: center; }
.poster { position: relative; width: min(510px, 100%); overflow: hidden; background: var(--panel); color: var(--text); border: 4px solid var(--ink); border-radius: 30px; box-shadow: inset 0 3px 0 #fff, 0 10px 0 var(--ink), 0 26px 40px rgba(43, 22, 80, .28); rotate: -1.5deg; }
.stage { background: var(--g-wall); border-bottom: var(--edge); }
.stage-art { width: 100%; height: auto; overflow: visible; }
.prize-cur { font: 400 11px var(--display); letter-spacing: .16em; fill: var(--ink); }
/* the pot is written in the big bubble */
.pot-label { font-family: var(--display); fill: var(--ink); letter-spacing: .01em; }
/* the pot bubble floats a little; the two emotes in flight bob out of step */
.box { transform-box: fill-box; transform-origin: 50% 100%; animation: float 5s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
.fly { transform-box: fill-box; transform-origin: 50% 100%; animation: bobble 3.2s ease-in-out infinite; }
.fly-b { animation-delay: -1.6s; }
@keyframes bobble { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-4px) rotate(-2deg); } }
.p-fight { position: relative; display: grid; grid-template-columns: 1fr 1fr; }
.p-side { min-width: 0; padding: 14px 14px 12px; text-align: center; background: var(--blocks), var(--g-you); box-shadow: inset 0 4px 0 rgba(255, 255, 255, .35); }
.p-side.rival { background: var(--blocks), var(--g-rival); border-left: var(--edge); }
.p-side span { display: block; font: 600 14px/1.2 var(--body); color: #fff; text-shadow: 0 2px 0 rgba(25, 26, 44, .55); }
.p-side b { display: block; margin-top: 4px; font-size: clamp(28px, 8vw, 38px); line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 6px 4px; }
.p-side b.long { font-size: clamp(19px, 5vw, 24px); line-height: 1.9; }
.p-vs { position: absolute; left: 50%; top: 50%; translate: -50% -50%; rotate: -8deg; width: 62px; height: 62px; display: grid; place-items: center; padding-bottom: 4px; border: 4px solid var(--ink); border-radius: 50%; background: var(--g-gold); font-size: 22px; line-height: 1; box-shadow: inset 0 3px 0 rgba(255, 255, 255, .6), 0 4px 0 var(--ink); }
.p-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 16px; border-top: var(--edge); font: 600 13px/1.2 var(--body); color: var(--muted); }
.p-foot span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 520px) { .poster { rotate: -1deg; } .p-foot { font-size: 12px; padding: 9px 12px; } }
.poster-btn { position: relative; margin-top: 30px; }
.gate .poster-wrap { display: none; }
@media (min-width: 960px) { .gate .poster-wrap { display: grid; } }

.sec { max-width: var(--wrap); margin: 0 auto; padding: 80px 20px 0; scroll-margin-top: 70px; }
.sec-head { margin-bottom: 28px; }
.sec-head h2 { font-size: clamp(34px, 7vw, 54px); }
.sec-head .sub { margin-top: 10px; font-size: 19px; color: var(--muted); max-width: 40em; }
.reveal { opacity: 0; transform: translateY(18px); }
.reveal.in { opacity: 1; transform: none; transition: opacity .5s, transform .5s; }

/* the three steps, each with its own picture */
.rounds { display: grid; grid-template-columns: minmax(0, 1fr); gap: 26px; }
.rounds li { overflow: hidden; background: var(--panel); color: var(--text); border: var(--edge); border-radius: 26px; box-shadow: var(--lift); }
.step-art { position: relative; height: 184px; display: grid; place-items: center; padding: 14px 14px 4px; background: var(--g-wall); border-bottom: var(--edge); }
.step-art svg { width: 100%; height: 160px; overflow: visible; }
.step-art::after { content: ""; position: absolute; left: -4%; right: -4%; bottom: 0; height: 24px; background: var(--floor); border-top: 3px solid var(--ink); border-radius: 50% 50% 0 0 / 10px 10px 0 0; z-index: 0; }
.step-art svg { position: relative; z-index: 1; }
.step-no { position: absolute; left: 14px; top: 8px; z-index: 2; font-size: 40px; line-height: 1; color: var(--lime); }
.rounds h3 { margin: 18px 22px 6px; font: 400 26px/1.1 var(--display); }
.rounds p { margin: 0 22px 22px; }
@media (min-width: 820px) { .rounds { grid-template-columns: repeat(3, 1fr); } }

.modes2 { display: grid; grid-template-columns: minmax(0, 1fr); gap: 26px; }
.mode-card { overflow: hidden; background: var(--panel); color: var(--text); border: var(--edge); border-radius: 22px; box-shadow: var(--lift); }
/* the cards float in the sky above the arena floor */
.mode-card { border-radius: 26px; }
.mode-art { min-height: 156px; padding: 26px 14px; display: flex; align-items: center; justify-content: center; gap: 12px; border-bottom: var(--edge); background: linear-gradient(180deg, transparent calc(100% - 14px), #d8ad66 calc(100% - 14px)), var(--sky); }
.deck { display: flex; gap: 5px; }
.pc { width: 38px; height: 50px; display: grid; place-items: center; border: var(--edge); border-radius: 9px; background: #fffdf9; box-shadow: inset 0 3px 0 rgba(255, 255, 255, .5), 0 3px 0 var(--ink); }
.pc .ico { width: 25px; height: 25px; }
.deck.you .pc, .pick-a { background: var(--blocks), var(--g-you); }
.deck.rival .pc, .pick-b { background: var(--blocks), var(--g-rival); }
.eq { font: 400 36px/1 var(--display); color: #fff; -webkit-text-stroke: 6px var(--ink); paint-order: stroke fill; }
.deck.offer { gap: 10px; }
.deck.offer .pc { width: 56px; height: 74px; border-radius: 10px; }
.deck.offer .pc .ico { width: 36px; height: 36px; }
.pick-a { translate: 0 -9px; }
.pick-b { translate: 0 9px; }
.mode-copy { padding: 18px 22px 22px; }
.mode-copy h3 { margin-bottom: 6px; font: 400 28px/1.1 var(--display); }
.points { display: grid; gap: 22px; margin-top: 36px; }
.points li { display: flex; gap: 14px; }
.points .ico { width: 54px; height: 54px; filter: drop-shadow(0 4px 0 rgba(36, 22, 61, .2)); }
.points h3 { font: 400 20px/1.25 var(--display); }
.points h3 { color: var(--text); }
.points p { color: var(--muted); }
@media (min-width: 820px) { .modes2 { grid-template-columns: 1fr 1fr; } .points { grid-template-columns: repeat(3, 1fr); } .pc { width: 44px; height: 58px; } .pc .ico { width: 29px; height: 29px; } }

.money-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 26px; }
.money-grid h3 { margin-bottom: 14px; font: 400 23px/1.15 var(--display); display: flex; align-items: center; gap: 10px; }
.money-grid h3 .ico { width: 38px; height: 38px; }
.money-grid .card p + p, .money-grid .card p + a, .money-grid .card a + a { margin-top: 12px; }
.money-grid .card .more { display: flex; }
.splitbar { display: flex; height: 70px; border: var(--edge); border-radius: 16px; overflow: hidden; }
.splitbar i { display: grid; place-items: center; padding-bottom: 4px; font-style: normal; font-size: 24px; line-height: 1; }
.splitbar .w { flex: 1; background: var(--g-gold); box-shadow: inset 0 4px 0 rgba(255, 255, 255, .5); }
.splitbar .s { width: 30px; background: var(--g-beech); border-left: var(--edge); }
.split { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 18px; }
.split div { padding-left: 12px; border-left: 8px solid var(--gold); border-radius: 4px; }
.split .s { border-color: var(--beech); }
.split .r { border-color: var(--teal); }
.split b { display: block; font: 400 clamp(24px, 6vw, 38px)/1.1 var(--display); }
.split span { display: block; margin-top: 2px; font-size: 14px; line-height: 1.3; color: var(--muted); }
@media (min-width: 820px) { .money-grid { grid-template-columns: 1fr 1fr; } .split-card { grid-column: 1 / -1; } }

.faq { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.faq details { overflow: hidden; background: var(--panel); color: var(--text); border: var(--edge); border-radius: 20px; box-shadow: inset 0 3px 0 #fff, 0 5px 0 var(--ink); }
.faq summary { position: relative; padding: 15px 56px 13px 18px; font: 600 18px/1.3 var(--body); cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 14px; top: 50%; translate: 0 -50%; width: 32px; height: 32px; display: grid; place-items: center; padding-bottom: 3px; border: 3px solid var(--ink); border-radius: 50%; background: var(--g-gold); font: 400 22px/1 var(--display); }
.faq summary:hover { background: var(--panel-2); }
.faq details[open] summary { background: var(--panel-2); border-bottom: 2px solid var(--line); }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 14px 18px 18px; max-width: 62em; }

/* the end of the page: the arena floor runs along its top, then the grape tray under a soft light */
.final { position: relative; margin-top: 96px; overflow: hidden; background: radial-gradient(52% 80% at 50% 0%, rgba(190, 160, 255, .35) 0%, rgba(190, 160, 255, .08) 45%, transparent 75%), linear-gradient(180deg, #4c2a8c 0%, #3b2170 55%, #24113f 100%); border-top: 4px solid var(--ink); }
.final::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 22px; background: var(--floor); border-bottom: 3px solid var(--ink); }
.final-in { max-width: var(--wrap); margin: 0 auto; padding: 56px 20px 80px; display: grid; justify-items: center; gap: 18px; text-align: center; }
.final-art { width: min(380px, 86vw); padding: 22px 0 6px; border-radius: 30px; background: linear-gradient(180deg, transparent calc(100% - 22px), #e6c181 calc(100% - 22px)), var(--sky); border: var(--edge); box-shadow: 0 6px 0 var(--ink); }
.final-art svg { width: 100%; height: auto; overflow: visible; }
.final h2 { font-size: clamp(36px, 8vw, 72px); max-width: 12em; }
.final p { font-size: 21px; font-weight: 600; color: var(--on-dark); text-shadow: 0 2px 0 rgba(0, 0, 0, .4); margin-bottom: 8px; }

/* ---------- footer ---------- */
.foot { margin-top: 72px; background: var(--ink); color: #e4dcf3; border-top: 4px solid var(--gold); }
body[data-page="home"] .foot { margin-top: 0; }
.foot-in { max-width: var(--wrap); margin: 0 auto; padding: 36px 20px 44px; display: grid; gap: 26px; }
.foot-brand { display: flex; align-items: center; gap: 12px; }
.foot-brand .brand-name { -webkit-text-stroke: 0 transparent; text-shadow: none; font-size: 28px; }
.foot-brand p { margin-top: 2px; font-size: 15px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.foot-links a { font: 700 16px/1 var(--body); color: #fff; text-decoration: none; padding: 6px 0; border-bottom: 3px solid transparent; }
.foot-links a:hover { border-color: var(--lime); }
.foot-legal { display: grid; gap: 8px; font-size: 14px; max-width: 70em; }
.disclaimer { color: #a99cc2; }
.disclaimer b { color: #fff; }
@media (min-width: 820px) { .foot-in { grid-template-columns: 1fr auto; align-items: center; } .foot-legal { grid-column: 1 / -1; } }

/* ---------- the game ---------- */
.callout { display: flex; align-items: center; gap: 14px; margin-top: 24px; padding: 14px 18px; background: var(--g-gold); color: var(--text); border: var(--edge); border-radius: 18px; box-shadow: inset 0 3px 0 rgba(255, 255, 255, .6), 0 6px 0 var(--ink); }
.callout > .ico { width: 48px; height: 48px; }
.callout h3 { font-size: 23px; line-height: 1.1; overflow-wrap: anywhere; }
.callout p { margin-top: 4px; font-size: 16px; font-weight: 700; }
.callout.gone { background: var(--panel); }
.callout.gone h3 { color: var(--text); -webkit-text-stroke: 0 transparent; text-shadow: none; }
@media (max-width: 560px) { .callout { flex-wrap: wrap; } .callout > .btn { width: 100%; } }

.gate { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: center; padding-top: 36px; }
.gate-copy h1 { margin: 0 0 14px; font-size: clamp(40px, 10vw, 72px); }
.gate-copy .lede { margin-bottom: 26px; }
.gate-copy .card { max-width: 520px; }
.gate-copy h1 + .card { margin-top: 24px; }
.gate + .fightcard { margin-top: 44px; }
@media (min-width: 960px) { .gate { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); padding-top: 52px; } }

.who-row { display: flex; align-items: center; gap: 14px; }
.who-row h2 { font-size: 26px; overflow-wrap: anywhere; }
@media (max-width: 520px) { .who-row { gap: 10px; } .who-row h2 { font-size: 21px; } .who-row .icon-btn { width: 40px; min-height: 40px; } }

.dash { display: grid; grid-template-columns: minmax(0, 1fr); gap: 30px; padding-top: 30px; align-items: start; }
.dash.in-fight { max-width: 720px; margin: 0 auto; }
@media (min-width: 980px) {
  .dash:not(.in-fight) { grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); grid-template-areas: "player lobby" "ring lobby" "ring log"; grid-template-rows: auto auto 1fr; }
  .dash:not(.in-fight) .a-player { grid-area: player; }
  .dash:not(.in-fight) .a-ring { grid-area: ring; }
  .dash:not(.in-fight) .a-lobby { grid-area: lobby; }
  .dash:not(.in-fight) .a-log { grid-area: log; }
}
.form-strip { display: flex; align-items: center; gap: 6px; margin-top: 16px; padding-top: 14px; border-top: 2px solid var(--line); }
.form-strip span { margin-right: 6px; font: 700 14px/1 var(--body); color: var(--muted); }
.form-strip i { width: 28px; height: 28px; display: grid; place-items: center; padding-bottom: 2px; border: 2px solid var(--ink); border-radius: 8px; font: 400 13px/1 var(--display); font-style: normal; color: #fff; background: #a497b8; }
.form-strip .f-W { background: var(--g-you); }
.form-strip .f-L { background: var(--g-rival); }
.settings { margin-top: 18px; padding-top: 18px; border-top: 2px solid var(--line); }

.list-head { display: flex; align-items: baseline; gap: 10px; font: 400 20px/1.1 var(--display); }
.list-head span { font: 700 16px/1 var(--body); color: var(--muted); }
.bouts { display: grid; }
.bout { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 12px; padding: 12px 0; border-top: 2px solid var(--line); }
.bout:first-child { border-top: 0; padding-top: 2px; }
.bout:last-child { padding-bottom: 2px; }
.who { min-width: 0; }
.who b { display: block; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.who b i { font-style: normal; font-weight: 600; color: var(--muted); }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; margin-top: 1px; font-size: 14px; color: var(--muted); }
.meta i { font-style: normal; }
.prize-col { text-align: right; }
.prize-col b { display: block; font: 400 22px/1.1 var(--display); color: var(--gold-deep); }
.prize-col span { font: 700 12px/1.3 var(--body); color: var(--muted); white-space: nowrap; }
.live-mark { width: 50px; display: grid; place-items: center; }
.live-mark .ico { width: 34px; height: 34px; }
.res-tag { width: 36px; height: 36px; display: grid; place-items: center; padding-bottom: 2px; border: 2px solid var(--ink); border-radius: 10px; background: #a497b8; color: #fff; font: 400 16px/1 var(--display); }
.res-tag.win { background: var(--g-you); }
.res-tag.loss { background: var(--g-rival); }
.res-tag.void { background: var(--panel-2); color: var(--muted); }
.bout.done .prize-col b, .pay.plus { color: var(--plus); }
.pay { display: inline-flex; align-items: center; gap: 6px; font: 400 19px/1.1 var(--display); color: var(--text); text-decoration: none; white-space: nowrap; }
a.pay:hover { text-decoration: underline; }
.pay .ico { width: 14px; height: 14px; }
.pay.minus { color: var(--red); }
.score { display: inline-flex; align-items: center; gap: 3px; font-weight: 700; color: var(--teal-deep); --crown: url(#g-you); --crown-band: #1659b5; }
.score.red { color: #b52a1f; --crown: url(#g-rival); --crown-band: #9c1d14; }
.score .ico { width: 18px; height: 18px; }
@media (max-width: 560px) {
  .bout { grid-template-columns: auto minmax(0, 1fr) auto; }
  .bout > .btn, .bout > .row, .bout > .chip { grid-column: 1 / -1; justify-self: end; }
}

.stake-row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.quick { display: flex; gap: 8px; margin-top: 12px; }
.quick .btn { flex: 1; padding: 3px 6px 0; }
.prize-box { display: grid; align-content: center; justify-items: center; padding: 12px 14px 10px; border: var(--edge); border-radius: 16px; background: var(--g-gold); text-align: center; box-shadow: inset 0 4px 0 rgba(255, 255, 255, .55); }
.prize-box span { font: 700 14px/1.2 var(--body); color: #7a3d00; }
.prize-box b { padding: 4px 0 6px; font: 400 clamp(44px, 11vw, 62px)/1 var(--display); color: #fff; -webkit-text-stroke: .08em var(--ink); paint-order: stroke fill; text-shadow: 0 .07em 0 var(--ink); }
.prize-box i { font: 400 16px/1 var(--display); font-style: normal; color: var(--ink); }
@media (min-width: 560px) { .stake-row { grid-template-columns: 1fr 1fr; } }

.tape { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: stretch; }
.corner { display: grid; justify-items: center; align-content: start; gap: 8px; padding: 0 10px 14px; overflow: hidden; border: var(--edge); border-radius: 18px; background: linear-gradient(180deg, #dcefff, var(--panel) 70%); text-align: center; min-width: 0; }
.corner.red { background: linear-gradient(180deg, #ffe3dc, var(--panel) 70%); }
.corner .corner-label { justify-self: stretch; margin: 0 -10px 6px; padding: 7px 4px 5px; background: var(--g-you); border-bottom: var(--edge); color: #fff; text-shadow: 0 2px 0 rgba(25, 26, 44, .55); }
.corner.red .corner-label { background: var(--g-rival); }
.corner-name { max-width: 100%; font: 400 clamp(18px, 4.6vw, 26px)/1.15 var(--display); overflow-wrap: anywhere; }
.corner-sub { font-size: 14px; color: var(--muted); }
.corner.empty { border-style: dashed; background: var(--panel-2); }
.corner.empty .corner-label { background: #a497b8; }
.corner.empty .corner-name { color: var(--muted); }
.vs { align-self: center; z-index: 1; width: 58px; height: 58px; margin: 0 -13px; display: grid; place-items: center; padding-bottom: 3px; border: var(--edge); border-radius: 50%; background: var(--g-gold); font-size: 20px; line-height: 1; rotate: -8deg; box-shadow: inset 0 3px 0 rgba(255, 255, 255, .6), 0 4px 0 var(--ink); }
.fight-facts { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 18px; }
.tiles { display: flex; justify-content: center; gap: 7px; }
.tiles span { width: 48px; height: 60px; display: grid; place-items: center; padding-bottom: 3px; border: var(--edge); border-radius: 12px; background: var(--g-gold); color: var(--text); box-shadow: inset 0 3px 0 rgba(255, 255, 255, .6), 0 4px 0 var(--ink); font: 400 27px/1 var(--display); }
@media (max-width: 400px) { .tiles span { width: 40px; height: 52px; font-size: 23px; } }
.watching { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 12px; background: var(--panel-2); font-size: 15px; font-weight: 700; }
.watching .ico { width: 30px; height: 30px; transform-origin: 50% 100%; animation: hop 1.6s ease-in-out infinite; }
@keyframes hop { 0%, 60%, 100% { transform: none; } 25% { transform: translateY(-6px) rotate(-6deg); } 45% { transform: scaleY(.92); } }
.teams { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 0; }
.team-col { display: grid; gap: 8px; align-content: start; min-width: 0; }
.team-col:last-child .corner-label { color: #a8251c; text-align: right; }
.seat { display: flex; align-items: center; gap: 10px; padding: 8px; border: var(--edge); border-radius: 14px; background: #fff; min-width: 0; }
.seat.free { border-style: dashed; background: var(--panel-2); }
.seat .badge { width: 38px; height: 38px; border-radius: 10px; font-size: 20px; }
@media (max-width: 480px) { .seat .badge { display: none; } }

.steps { counter-reset: step; display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
.steps li { counter-increment: step; position: relative; padding-left: 54px; min-height: 40px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 40px; height: 40px; display: grid; place-items: center; padding-bottom: 3px; border: var(--edge); border-radius: 50%; background: var(--g-you); font-size: 18px; line-height: 1; box-shadow: inset 0 3px 0 rgba(255, 255, 255, .45); }
.steps h3 { font: 700 18px/1.3 var(--body); padding-top: 7px; }
.steps p, .steps .row, .steps form, .steps .modes { margin-top: 8px; }
.modes { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.mode { display: inline-flex; align-items: center; gap: 4px; font: 700 15px/1.4 var(--body); }
.mode .ico { width: 20px; height: 20px; }
.mode.no { color: var(--muted); text-decoration: line-through; }
.ok-line { display: flex; align-items: center; gap: 4px; }
.ok-line .ico { width: 20px; height: 20px; }
.buy-sol { margin-top: -4px; }
.dev { margin-top: 36px; padding: 14px; border: 3px dashed rgba(36, 22, 61, .25); border-radius: 16px; }
.dev h3 { margin-bottom: 12px; font: 600 14px/1.2 var(--body); color: var(--muted); }
.error-card { max-width: 480px; margin: 60px auto 0; }

/* ---------- stats ---------- */
.page-head { padding: 44px 0 26px; }
.page-head h1 { margin-bottom: 10px; font-size: clamp(40px, 9vw, 72px); }
.page-head p { color: var(--muted); max-width: 44em; }
/* one card that reads like a score sheet: your blob laughing next to the volume, then a list of lines */
.ledger { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; padding: 24px; }
.ledger-pot { display: flex; align-items: center; gap: 18px; }
.ledger-knight { width: 118px; flex: none; overflow: visible; }
.ledger-pot span { display: block; font: 700 15px/1.2 var(--body); color: var(--muted); }
.ledger-pot b { display: block; padding-top: 6px; font: 400 clamp(40px, 9vw, 62px)/1.05 var(--display); color: var(--gold-deep); }
.ledger-list { display: grid; grid-template-columns: minmax(0, 1fr); column-gap: 30px; }
.ledger-list div { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; padding: 10px 0 8px; border-bottom: 2px dashed var(--line); }
.ledger-list dt { color: var(--muted); font-weight: 700; }
.ledger-list dd { font: 400 20px/1.1 var(--display); white-space: nowrap; }
@media (min-width: 680px) { .ledger-list { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .ledger { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); align-items: center; } }
.stat-card h2 { margin-bottom: 6px; font-size: 23px; color: var(--text); -webkit-text-stroke: 0 transparent; text-shadow: none; }
.an-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 30px; margin-top: 30px; }
@media (min-width: 900px) { .an-grid { grid-template-columns: 1fr 1fr; } }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 16px; margin: 18px 0 6px; }
.facts div { padding-top: 8px; border-top: 4px solid var(--line); }
.facts b { display: block; padding-top: 2px; font: 400 25px/1.15 var(--display); }
.facts span { font-size: 14px; color: var(--muted); }
.links { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 14px 0 4px; }
.links a, .tbl a { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; text-underline-offset: 3px; }
.links .ico, .tbl .ico { width: 14px; height: 14px; }
.tbl-wrap { overflow-x: auto; margin-top: 14px; }
.tbl, .as-table table { width: 100%; border-collapse: collapse; font-size: 15px; }
.tbl th, .as-table th { padding: 8px 10px 8px 0; text-align: left; font: 700 13px/1.2 var(--body); color: var(--muted); border-bottom: 3px solid var(--line); white-space: nowrap; }
.tbl td, .as-table td { padding: 10px 10px 10px 0; border-bottom: 1px solid var(--line); white-space: nowrap; font-variant-numeric: tabular-nums; }
.empty { margin-top: 14px; padding: 11px 14px; border-radius: 12px; background: var(--panel-2); font-size: 15px; color: var(--muted); }
.chart { position: relative; margin-top: 14px; }
.chart svg { width: 100%; height: auto; overflow: visible; }
.chart .grid { stroke: var(--line); stroke-dasharray: 3 4; }
.chart .axis { stroke: var(--ink); stroke-width: 2; }
.chart .tick { font: 700 12px var(--body); fill: var(--muted); }
.chart .hit { outline: none; }
.chart .hit:hover, .chart .hit:focus-visible { fill: rgba(132, 96, 210, .12); }
.tip { position: absolute; top: 0; translate: -50% 0; display: grid; gap: 2px; padding: 7px 10px; border-radius: 10px; background: var(--ink); color: #fff; font-size: 13px; white-space: nowrap; pointer-events: none; z-index: 2; }
.tip i, .legend i { display: inline-block; width: 10px; height: 10px; margin-right: 6px; border-radius: 3px; }
.chart-empty { position: absolute; inset: 30% 0 auto; text-align: center; font-size: 15px; color: var(--muted); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 8px; font-size: 14px; }
.as-table { margin-top: 10px; font-size: 14px; }
.as-table summary { cursor: pointer; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.hbars { display: grid; gap: 10px; margin-top: 18px; }
.hbars > div { display: grid; grid-template-columns: 92px 1fr 30px; align-items: center; gap: 10px; font-size: 15px; }
.hbars .track { height: 20px; border: 2px solid var(--ink); border-radius: 999px; background: #fff; overflow: hidden; }
.hbars .track i { display: block; height: 100%; background: var(--g-tang); }
.hbars b { font: 400 17px/1 var(--display); text-align: right; }

/* ---------- result ---------- */
#overlay { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; overflow: auto; background: rgba(36, 22, 61, .76); }
#overlay.win { background: rgba(43, 22, 80, .92); }
.result { position: relative; width: min(470px, 100%); padding: 0 22px 24px; overflow: hidden; background: var(--panel); color: var(--text); border: 4px solid var(--ink); border-radius: 30px; box-shadow: inset 0 4px 0 #fff, 0 10px 0 var(--ink); text-align: center; animation: pop .35s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes pop { from { scale: .8; opacity: 0; } }
.result-art { margin: 0 -22px 6px; padding: 18px 30px 0; background: linear-gradient(180deg, transparent calc(100% - 16px), #e6c181 calc(100% - 16px)), var(--sky); border-bottom: var(--edge); }
.result-art svg { width: min(280px, 100%); height: auto; margin: 0 auto; overflow: visible; }
#overlay.win .result-art svg use { animation: burst .5s cubic-bezier(.2, 1.3, .4, 1) both; transform-origin: 50% 60%; transform-box: fill-box; }
@keyframes burst { from { scale: .6; opacity: 0; } }
#overlay:not(.win) .result-art svg { width: min(250px, 100%); padding-bottom: 6px; }
.result h1 { margin: 14px 0 16px; font-size: clamp(44px, 13vw, 66px); color: var(--lime); }
#overlay.loss .result h1 { color: #ff6f6a; }
#overlay.draw .result h1 { color: #fff; }
.scoreline { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 10px; }
.scoreline .vs { all: unset; font: 400 30px/1 var(--display); color: var(--muted); }
.side { min-width: 0; padding: 8px 8px 10px; border: var(--edge); border-radius: 18px; background: linear-gradient(180deg, #dcefff, var(--panel)); }
.side.red { background: linear-gradient(180deg, #ffe3dc, var(--panel)); }
.side span { display: block; font: 700 14px/1.3 var(--body); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side b { display: block; padding-top: 4px; font: 400 46px/1.1 var(--display); color: var(--teal-deep); }
.side.red b { color: #a8251c; }
.crown-row { display: flex; justify-content: center; gap: 2px; --crown: url(#g-you); --crown-band: #1659b5; }
.crown-row.red { --crown: url(#g-rival); --crown-band: #9c1d14; }
.crown-row .ico { width: 26px; height: 26px; }
.crown-row .ico.off { opacity: .2; filter: grayscale(1); }
.reward { margin-top: 14px; padding: 10px 12px 8px; border: var(--edge); border-radius: 16px; background: var(--g-gold); box-shadow: inset 0 4px 0 rgba(255, 255, 255, .55); }
.reward span { display: block; font: 700 14px/1.2 var(--body); color: #7a3d00; }
.reward b { padding-top: 4px; font: 400 48px/1.15 var(--display); color: #fff; -webkit-text-stroke: .08em var(--ink); paint-order: stroke fill; text-shadow: 0 .07em 0 var(--ink); }
.reward i { margin-left: 8px; font: 400 18px/1 var(--display); font-style: normal; }
.status { margin: 16px 0; font-size: 16px; }
.status a { color: var(--red); }

/* ---------- toast ---------- */
#toast {
  position: fixed; left: 50%; bottom: 20px; z-index: 60; width: max-content; max-width: min(92vw, 520px); padding: 12px 18px;
  background: var(--ink); color: #fff; border: 3px solid var(--tang); border-radius: 18px; box-shadow: 0 6px 0 rgba(36, 22, 61, .3); font: 700 16px/1.4 var(--body);
  translate: -50% 0; transform: translateY(24px); opacity: 0; visibility: hidden; pointer-events: none;
  transition: transform .2s, opacity .2s, visibility 0s .2s;
}
#toast.ok { border-color: var(--lime); }
#toast.show { transform: none; opacity: 1; visibility: visible; transition: transform .2s, opacity .2s; }

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

/* the $EMOTE strip above the header, shown once the coin is switched on */
.launch { background: #1a0f2e; color: var(--on-dark); font: 700 14px/1.25 var(--body); border-bottom: 3px solid var(--gold); }
.launch[hidden] { display: none; }
.launch-in { max-width: var(--wrap); margin: 0 auto; padding: 8px 20px; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px 16px; }
.launch-text b { font: 400 15px/1 var(--display); letter-spacing: .02em; color: var(--gold); }
.launch-ca { display: inline-flex; align-items: center; gap: 7px; padding: 4px 10px; border: 2px solid rgba(243, 238, 252, .28); border-radius: 8px; background: rgba(243, 238, 252, .06); color: var(--on-dark); font: 700 13px/1.25 ui-monospace, 'SF Mono', Menlo, Consolas, monospace; cursor: pointer; transition: border-color .15s, color .15s; }
.launch-ca:hover { border-color: var(--gold); color: #fff; }
.launch-ca .ico, .launch-go .ico { width: 15px; height: 15px; }
.ca-short { display: none; }
.launch-go { display: inline-flex; align-items: center; gap: 6px; color: var(--gold); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.launch-go:hover { color: #fff; }
.fee-card .ca { margin: 4px 0 10px; }
.fee-card .ca span { display: block; margin-bottom: 4px; font: 700 12px/1.2 var(--body); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.fee-card .ca .linkish { display: inline-flex; align-items: center; gap: 8px; text-align: left; word-break: break-all; font: 700 13px/1.35 ui-monospace, 'SF Mono', Menlo, Consolas, monospace; }
.fee-card .ca .ico { width: 15px; height: 15px; flex: none; }
@media (max-width: 880px) { .ca-full { display: none; } .ca-short { display: inline; } }
@media (max-width: 520px) { .launch { font-size: 13px; } .launch-in { padding: 7px 14px; gap: 6px 10px; } }

/* narrow phones: the two mirror decks must fit side by side */
@media (max-width: 440px) { .mode-art { gap: 6px; padding-inline: 8px; } .deck { gap: 3px; } .pc { width: 29px; height: 39px; border-width: 2.500px; } .pc .ico { width: 20px; height: 20px; } .eq { font-size: 30px; } .deck.offer .pc { width: 52px; height: 68px; } }
