/* Arcade site pages (home, credits, 404). Builds on arcade.css: same palette, same buttons and bars.
   Identity: night-indigo surfaces, coin gold for anything you can earn or press, mint for "yours / done",
   a condensed display face for titles, and the dotted "marquee" rule under every section head. */
:root {
  --ink: #0b0d1a; --surface: #12162c; --surface-2: #181d3a; --surface-3: #212750;
  --line-2: rgba(255, 255, 255, .2); --violet: #7a6bff; --pink: #ff5c9a; --sky: #6cc7ff; --gold-deep: #a8660a;
  --display: "Bahnschrift", "DIN Alternate", "Avenir Next Condensed", "Roboto Condensed", "Segoe UI", system-ui, sans-serif;
  --t-xs: 12px; --t-sm: 13.5px; --t-md: 15px; --t-lg: 17px; --t-xl: 22px; --t-2xl: 30px;
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px; --s8: 72px;
  --r-sm: 10px; --r-md: 16px; --r-lg: 22px; --r-xl: 28px;
  --gutter: clamp(16px, 4vw, 40px); --shadow: 0 24px 70px rgba(0, 0, 0, .5);
  --ease: cubic-bezier(.2, .8, .2, 1);
}
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
html, body { height: auto; min-height: 100%; }
body.home { font-size: var(--t-md); line-height: 1.45; overflow-x: hidden; }
body.home::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(900px 620px at 88% -8%, rgba(122, 107, 255, .34), transparent 62%), radial-gradient(760px 560px at -8% 18%, rgba(255, 92, 154, .17), transparent 60%), radial-gradient(900px 700px at 50% 120%, rgba(108, 199, 255, .1), transparent 60%), var(--ink); }
p { margin: 0; } ul, ol, dl, dd { margin: 0; padding: 0; list-style: none; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--accent); color: var(--accent-ink); font-weight: 800; padding: 10px 14px; border-radius: 10px; }
.skip:focus { top: 12px; }
.ic { width: 1.2em; height: 1.2em; flex: none; vertical-align: -.22em; }
.logo { width: 30px; height: 30px; flex: none; filter: drop-shadow(0 3px 10px rgba(255, 171, 46, .35)); }
.coins { display: inline-flex; align-items: center; gap: 5px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.coins b { color: var(--accent); }
.kicker { font-size: var(--t-xs); font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--accent); }
h1, h2, .feat-title, .poster b { font-family: var(--display); font-stretch: 82%; text-transform: uppercase; letter-spacing: .015em; line-height: 1; }
h3 { font-size: var(--t-lg); }

/* buttons (extends .btn from arcade.css) */
.home .btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; white-space: nowrap; box-shadow: 0 1px 0 rgba(255, 255, 255, .35) inset, 0 8px 22px rgba(255, 171, 46, .18); transition: transform .12s var(--ease), filter .15s, box-shadow .2s, background .2s; }
.home .btn:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 1px 0 rgba(255, 255, 255, .35) inset, 0 12px 30px rgba(255, 171, 46, .3); }
.home .btn:active:not(:disabled) { transform: translateY(1px) scale(.98); }
.home .btn.ghost { box-shadow: 0 0 0 1px var(--line) inset; background: rgba(255, 255, 255, .08); }
.home .btn.ghost:hover:not(:disabled) { background: rgba(255, 255, 255, .15); box-shadow: 0 0 0 1px var(--line-2) inset; }
.home .btn.big { padding: 14px 22px; font-size: var(--t-lg); border-radius: 14px; font-weight: 800; }
.home .btn.on, .home .btn.on:disabled { background: rgba(95, 242, 192, .14); color: var(--good); box-shadow: 0 0 0 1px rgba(95, 242, 192, .35) inset; opacity: 1; cursor: default; }
.home .btn.locked { color: var(--muted); cursor: not-allowed; }
.home .btn.bad { background: var(--bad); color: #2a0008; box-shadow: none; }
.home .btn .coins b { color: inherit; }
.iconbtn { display: inline-grid; place-items: center; width: 38px; height: 38px; flex: none; padding: 0; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, .06); color: var(--text); transition: background .15s, border-color .15s, transform .12s var(--ease); }
.iconbtn:hover { background: rgba(255, 255, 255, .14); border-color: var(--line-2); transform: translateY(-1px); }
.iconbtn .ic { width: 20px; height: 20px; }
.linkbtn { background: none; border: 0; padding: 0; }

/* header */
header.site { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: var(--s5); padding: 10px var(--gutter); border-bottom: 1px solid var(--line); }
/* the blur lives on a pseudo-element: a backdrop-filter on the header itself would trap the fixed phone nav inside it */
header.site::before { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(11, 13, 26, .8); backdrop-filter: blur(14px) saturate(1.3); }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-stretch: 82%; font-weight: 700; font-size: 26px; letter-spacing: .06em; text-transform: uppercase; }
.sitenav { display: flex; gap: 4px; flex: 1; }
.sitenav a { position: relative; display: flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; font-weight: 700; font-size: var(--t-sm); color: var(--muted); transition: color .15s, background .15s; }
.sitenav a .ic { display: none; }
.sitenav a:hover { color: var(--text); background: rgba(255, 255, 255, .07); }
.sitenav a[aria-current] { color: var(--text); background: rgba(255, 255, 255, .1); }
.sitenav .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--pink); box-shadow: 0 0 0 3px rgba(255, 92, 154, .25); }
.who { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.pill { position: relative; overflow: hidden; display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255, 255, 255, .06); font-weight: 800; font-size: var(--t-sm); font-variant-numeric: tabular-nums; transition: border-color .15s, background .15s; }
.pill:hover { border-color: var(--line-2); background: rgba(255, 255, 255, .12); }
.pill.level i { position: absolute; left: 0; bottom: 0; height: 3px; background: linear-gradient(90deg, var(--good), var(--sky)); transition: width .5s var(--ease); }
.pill.wallet b { color: var(--accent); }

/* page frame */
main { max-width: 1280px; margin: 0 auto; padding: var(--s5) var(--gutter) var(--s8); }
main > section { margin-top: var(--s8); scroll-margin-top: 84px; }
main > section.first { margin-top: 0; }
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--s4) var(--s5); flex-wrap: wrap; padding-bottom: var(--s4); margin-bottom: var(--s5);
  background: radial-gradient(circle, rgba(255, 255, 255, .28) 1.2px, transparent 1.6px) left bottom / 10px 4px repeat-x; }
.head h2 { font-size: clamp(28px, 3.4vw, 40px); margin-top: 6px; }
.head-note { font-weight: 600; font-size: var(--t-sm); }
.head-meter { display: grid; gap: 6px; min-width: 200px; font-size: var(--t-sm); font-weight: 700; text-align: right; }
.panel { background: linear-gradient(180deg, var(--surface-2), var(--surface)); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s5); }
.panel h3 { font-size: var(--t-xs); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: var(--s4); }
.empty { color: var(--muted); padding: var(--s4) 0; }
.bar { height: 8px; border-radius: 999px; background: rgba(255, 255, 255, .1); }
.bar i { border-radius: 999px; transition: width .5s var(--ease); }
.bar.thin { height: 4px; } .bar.ghostbar { visibility: hidden; }

/* covers: a generated poster sits under every cover image */
.cover { position: relative; overflow: hidden; container-type: inline-size; background: hsl(var(--h) 45% 14%); }
.poster { position: absolute; inset: 0; display: grid; place-items: center; padding: 8%;
  background: radial-gradient(110% 90% at 88% 6%, hsl(calc(var(--h) + 42) 85% 58% / .85), transparent 58%), radial-gradient(90% 100% at 0% 100%, hsl(calc(var(--h) - 34) 78% 42% / .9), transparent 62%), linear-gradient(135deg, hsl(var(--h) 62% 24%), hsl(calc(var(--h) + 24) 58% 11%)); }
.poster::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(118deg, rgba(255, 255, 255, .055) 0 2px, transparent 2px 16px); mask-image: linear-gradient(200deg, #000, transparent 75%); }
.poster b { position: relative; z-index: 1; font-size: clamp(20px, 12cqw, 96px); font-weight: 700; text-align: center; transform: rotate(-4deg); text-shadow: 0 2px 0 hsl(var(--h) 60% 10% / .6), 0 10px 30px rgba(0, 0, 0, .45); text-wrap: balance; }
.poster-mark { position: absolute; right: -6%; bottom: -18%; width: 52%; height: auto; aspect-ratio: 1; color: #fff; opacity: .1; transform: rotate(-12deg); }
.cover-img { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .4s, transform .6s var(--ease); }
.cover-img.in { opacity: 1; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: 999px; font-size: var(--t-xs); font-weight: 800; letter-spacing: .02em; background: rgba(8, 10, 22, .72); border: 1px solid var(--line); backdrop-filter: blur(6px); white-space: nowrap; }
.badge .ic { width: 14px; height: 14px; }
.badge.new { background: var(--pink); border-color: transparent; color: #2a0012; text-transform: uppercase; letter-spacing: .08em; }
.badge.hd { color: var(--sky); border-color: rgba(108, 199, 255, .4); }
.best { display: inline-flex; align-items: center; gap: 6px; font-size: var(--t-sm); color: var(--muted); font-weight: 600; min-width: 0; }
.best b { color: var(--text); font-variant-numeric: tabular-nums; } .best .ic { color: var(--accent); }

/* first screen */
.first { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(320px, 1fr); gap: var(--s5); }
.featured { position: relative; display: flex; min-height: clamp(440px, 56vh, 560px); border-radius: var(--r-xl); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); isolation: isolate; }
.featured > .cover { position: absolute; inset: 0; z-index: -2; }
.featured .poster b { display: none; }
.featured .poster-mark { width: 46%; right: 2%; bottom: -8%; opacity: .14; }
.feat-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(8, 10, 22, .92) 0%, rgba(8, 10, 22, .62) 42%, rgba(8, 10, 22, 0) 78%), linear-gradient(0deg, rgba(8, 10, 22, .85) 0%, rgba(8, 10, 22, 0) 46%); }
.feat-body { align-self: flex-end; display: grid; gap: var(--s3); padding: clamp(20px, 3.4vw, 40px); padding-bottom: clamp(48px, 5vw, 60px); max-width: 600px; }
.feat-title { font-size: clamp(40px, 6.2vw, 84px); font-weight: 700; text-shadow: 0 6px 30px rgba(0, 0, 0, .5); margin: 0; }
.feat-blurb { font-size: var(--t-lg); color: #dfe3fb; max-width: 44ch; text-wrap: pretty; }
.feat-cta { display: flex; align-items: center; flex-wrap: wrap; gap: var(--s3); margin-top: var(--s2); }
.feat-cta .best { margin-left: var(--s2); }
.feat-nav { position: absolute; left: clamp(20px, 3.4vw, 40px); bottom: 18px; display: flex; gap: 6px; }
.feat-nav button { width: 34px; height: 20px; padding: 8px 0; border: 0; background: none; }
.feat-nav i { display: block; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .28); transition: background .2s; }
.feat-nav button:hover i { background: rgba(255, 255, 255, .6); }
.feat-nav [aria-current="true"] i { background: var(--accent); }
.featured.swap .feat-body > * { animation: rise .5s var(--ease) both; }
.featured.swap .feat-body > :nth-child(2) { animation-delay: .04s; } .featured.swap .feat-body > :nth-child(3) { animation-delay: .08s; }
.featured.swap .feat-body > :nth-child(4) { animation-delay: .12s; } .featured.swap .feat-body > :nth-child(5) { animation-delay: .16s; }
.featured.swap > .cover { animation: fade .6s both; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes fade { from { opacity: 0; } }

.player { display: flex; flex-direction: column; border-radius: var(--r-xl); border: 1px solid var(--line); background: linear-gradient(180deg, var(--surface-3), var(--surface) 62%); overflow: hidden; box-shadow: var(--shadow); scroll-margin-top: 84px; }
.stage { position: relative; flex: 1; min-height: 250px; }
.stage-glow { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(60% 55% at 50% 42%, rgba(122, 107, 255, .5), transparent 70%), radial-gradient(46% 16% at 50% 84%, rgba(0, 0, 0, .5), transparent 70%); }
#preview { position: absolute; inset: 0; width: 100%; height: 100%; display: block; cursor: grab; touch-action: pan-y; opacity: 0; transition: opacity .6s; }
#preview.ready { opacity: 1; } #preview.grabbing { cursor: grabbing; }
.stage-wait { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 12px; color: var(--muted); font-size: var(--t-sm); font-weight: 600; text-align: center; padding: 20px; pointer-events: none; }
.stage-wait .logo { width: 54px; height: 54px; animation: bob 1.4s ease-in-out infinite alternate; }
.stage-wait.failed .logo { animation: none; opacity: .5; }
.stage-wait[hidden] { display: none; }
@keyframes bob { to { transform: translateY(-8px) rotate(8deg); } }
.stage-tag { position: absolute; left: 14px; top: 14px; padding: 5px 12px; border-radius: 999px; background: rgba(8, 10, 22, .6); border: 1px solid var(--line); backdrop-filter: blur(6px); font-size: var(--t-xs); font-weight: 800; letter-spacing: .08em; text-transform: uppercase; pointer-events: none; }
.stage-tag:empty { display: none; }
.player-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s4); padding: var(--s4) var(--s5) var(--s5); }
.namerow { display: flex; align-items: center; gap: var(--s3); }
#name { flex: 1; min-width: 0; font-family: var(--display); font-stretch: 82%; font-size: 26px; font-weight: 700; letter-spacing: .02em; padding: 4px 10px; margin-left: -10px; border-radius: 10px; border: 1px solid transparent; background: transparent; text-overflow: ellipsis; }
#name:hover { border-color: var(--line); } #name:focus { border-color: var(--accent); background: rgba(255, 255, 255, .06); outline: none; }
#name::placeholder { color: var(--muted); }
.xp { display: flex; align-items: center; gap: var(--s3); }
.xp-badge { display: grid; place-items: center; width: 46px; height: 46px; flex: none; font-family: var(--display); font-size: 22px; font-weight: 700; color: #06241a; background: linear-gradient(135deg, var(--good), var(--sky)); clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); }
.xp-main { flex: 1; display: grid; gap: 7px; min-width: 0; }
.xp-line { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: var(--t-sm); font-variant-numeric: tabular-nums; }
.xp-line b { font-size: var(--t-md); }
.xpbar i { background: linear-gradient(90deg, var(--good), var(--sky)); }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s2); }
.stats > div { padding: 10px 12px; border-radius: var(--r-md); background: rgba(255, 255, 255, .05); border: 1px solid var(--line); }
.stats dt { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.stats dd { display: flex; align-items: center; gap: 6px; margin-top: 2px; font-size: var(--t-xl); font-weight: 800; font-variant-numeric: tabular-nums; }
.stats dd .ic { width: 18px; height: 18px; color: var(--muted); }
.flame.lit, .lit .flame { color: #ff8a3d !important; filter: drop-shadow(0 0 8px rgba(255, 138, 61, .6)); }

/* the hook */
main > section.pitch { margin-top: var(--s6); display: flex; align-items: center; justify-content: space-between; gap: var(--s4) var(--s6); flex-wrap: wrap; }
.pitch h1 { font-size: clamp(26px, 3.1vw, 38px); font-weight: 700; }
.pitch h1 em { font-style: normal; color: var(--accent); }
.pitch ol { display: flex; gap: var(--s5); flex-wrap: wrap; }
.pitch li { display: flex; align-items: center; gap: 12px; font-size: var(--t-sm); }
.pitch li > .ic { width: 22px; height: 22px; padding: 9px; box-sizing: content-box; border-radius: 12px; background: rgba(255, 255, 255, .07); border: 1px solid var(--line); color: var(--accent); }
.pitch li b { display: block; font-size: var(--t-md); } .pitch li span { color: var(--muted); }

/* continue playing */
main > section#continue { margin-top: var(--s7); }
.rail { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: var(--s4); }
.resume { display: flex; align-items: center; gap: var(--s3); padding: 10px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--surface); transition: transform .2s var(--ease), border-color .2s, background .2s; }
.resume:hover { transform: translateY(-3px); border-color: rgba(255, 201, 77, .55); background: var(--surface-2); }
.resume .cover { width: 104px; aspect-ratio: 16 / 10; border-radius: 12px; flex: none; }
.resume-body { flex: 1; min-width: 0; display: grid; gap: 2px; font-size: var(--t-sm); }
.resume-body b { font-size: var(--t-lg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.resume-go { display: grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 50%; background: var(--accent); color: var(--accent-ink); transition: transform .2s var(--ease); }
.resume:hover .resume-go { transform: scale(1.12); }

/* library */
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chipbtn { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255, 255, 255, .04); color: var(--muted); font-weight: 700; font-size: var(--t-sm); transition: color .15s, background .15s, border-color .15s; }
.chipbtn small { font-size: 11px; font-weight: 800; padding: 1px 7px; border-radius: 999px; background: rgba(255, 255, 255, .1); font-variant-numeric: tabular-nums; }
.chipbtn:hover { color: var(--text); border-color: var(--line-2); }
.chipbtn[aria-pressed="true"], .chipbtn[aria-selected="true"] { background: var(--text); color: var(--ink); border-color: transparent; }
.chipbtn[aria-pressed="true"] small, .chipbtn[aria-selected="true"] small { background: rgba(11, 13, 26, .14); }
.library { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: var(--s5); }
.tile { position: relative; display: flex; flex-direction: column; border-radius: var(--r-lg); overflow: hidden; background: var(--surface); border: 1px solid var(--line); transition: transform .25s var(--ease), border-color .25s, box-shadow .25s; animation: rise .45s var(--ease) both; }
.tile:nth-child(2) { animation-delay: .04s; } .tile:nth-child(3) { animation-delay: .08s; } .tile:nth-child(4) { animation-delay: .12s; } .tile:nth-child(5) { animation-delay: .16s; } .tile:nth-child(6) { animation-delay: .2s; }
.tile::after { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; opacity: 0; transition: opacity .25s; background: radial-gradient(280px circle at var(--mx, 50%) var(--my, 0%), rgba(255, 255, 255, .1), transparent 65%); }
.tile:hover, .tile:focus-within { transform: translateY(-6px); border-color: rgba(255, 201, 77, .6); box-shadow: 0 22px 60px rgba(0, 0, 0, .5), 0 0 0 1px rgba(255, 201, 77, .25); }
.tile:hover::after { opacity: 1; }
.tile-art { position: relative; display: block; }
.tile-art .cover { aspect-ratio: 16 / 10; }
.tile:hover .cover-img, .tile:focus-within .cover-img { transform: scale(1.06); }
.tile:hover .poster b { transform: rotate(-4deg) scale(1.05); } .poster b { transition: transform .5s var(--ease); }
.tile-art .badges { position: absolute; left: 12px; top: 12px; right: 12px; }
.tile-play { position: absolute; right: 14px; bottom: -22px; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); box-shadow: 0 10px 26px rgba(0, 0, 0, .45), 0 0 0 5px var(--surface); transform: scale(.82); transition: transform .25s var(--ease); z-index: 1; }
.tile-play .ic { width: 22px; height: 22px; }
.tile:hover .tile-play, .tile:focus-within .tile-play { transform: scale(1.06) rotate(-6deg); }
.tile-body { display: grid; gap: 8px; padding: var(--s4) var(--s4) var(--s4); flex: 1; align-content: start; }
.tile-top { display: flex; align-items: baseline; gap: 10px; padding-right: 64px; }
.tile h3 { font-family: var(--display); font-stretch: 82%; font-size: 26px; text-transform: uppercase; letter-spacing: .02em; line-height: 1.05; }
.tile h3 a:hover { color: var(--accent); }
.players { display: inline-flex; align-items: center; gap: 5px; font-size: var(--t-xs); font-weight: 800; color: var(--muted); white-space: nowrap; }
.players .ic { width: 14px; height: 14px; }
.blurb { color: var(--muted); font-size: var(--t-sm); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.9em; }
.tile-foot { display: flex; align-items: center; gap: 8px; margin-top: 6px; padding-top: var(--s3); border-top: 1px solid var(--line); }
.tile-foot .best { flex: 1; }
.tile-foot .btn { padding: 9px 18px; }

/* daily */
.daily { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr) minmax(0, 1fr); gap: var(--s5); }
.quests ul { display: grid; gap: var(--s2); }
.quest { display: flex; align-items: center; gap: var(--s3); padding: 12px; border-radius: var(--r-md); background: rgba(255, 255, 255, .04); border: 1px solid var(--line); }
.quest-mark { display: grid; place-items: center; width: 36px; height: 36px; flex: none; border-radius: 50%; background: rgba(255, 255, 255, .08); color: var(--muted); }
.quest-main { flex: 1; min-width: 0; display: grid; gap: 8px; }
.quest-line { display: flex; justify-content: space-between; gap: 10px; font-size: var(--t-sm); }
.quest-line b { font-size: var(--t-md); } .quest-count { color: var(--muted); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.quest-reward { display: inline-flex; align-items: center; gap: 2px; min-width: 62px; justify-content: flex-end; font-weight: 800; color: var(--accent); }
.quest.done { background: rgba(95, 242, 192, .08); border-color: rgba(95, 242, 192, .3); }
.quest.done .quest-mark { background: var(--good); color: #06241a; }
.quest.done .bar i { background: var(--good); } .quest.done .quest-reward { color: var(--good); font-size: var(--t-sm); }
.quest.done .quest-line b { text-decoration: line-through; text-decoration-color: rgba(95, 242, 192, .6); color: var(--muted); }
.streak, .cap { display: flex; flex-direction: column; gap: var(--s3); }
.streak h3, .cap h3 { margin-bottom: 0; }
.streak-top, .cap-top { display: flex; align-items: center; gap: 10px; }
.streak-top b, .cap-top b { font-family: var(--display); font-size: 56px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.streak-top span, .cap-top span { color: var(--muted); font-size: var(--t-sm); font-weight: 700; line-height: 1.25; }
.streak-top .ic { width: 40px; height: 40px; color: var(--muted); } .cap-top .ic { width: 36px; height: 36px; }
.cap-top b { color: var(--accent); }
.pips { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.pips li { display: grid; place-items: center; aspect-ratio: 1; max-height: 40px; border-radius: 10px; background: rgba(255, 255, 255, .06); border: 1px solid var(--line); font-size: var(--t-xs); font-weight: 800; color: var(--muted); }
.pips li.goal { border-color: rgba(255, 201, 77, .5); color: var(--accent); }
.pips li.on { background: linear-gradient(135deg, #ffb24d, #ff6a3d); border-color: transparent; color: #2a0f00; }
.pips li.risk { background: none; border: 1px dashed #ff8a3d; color: #ff8a3d; }
.streak p, .cap p { font-size: var(--t-sm); margin-top: auto; }
.mini { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s2); }
.mini > div { padding: 8px 12px; border-radius: 12px; background: rgba(255, 255, 255, .05); border: 1px solid var(--line); }
.mini dt { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.mini dd { font-size: var(--t-lg); font-weight: 800; font-variant-numeric: tabular-nums; }
.next-goal { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 12px; background: rgba(255, 201, 77, .08); border: 1px solid rgba(255, 201, 77, .3); font-size: var(--t-sm); font-weight: 600; }
.next-goal .coins { margin-left: auto; }

/* trophies */
.trophies { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: var(--s3); }
.trophy { display: flex; align-items: center; gap: var(--s3); padding: 14px; border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--line); transition: transform .2s var(--ease), border-color .2s; }
.trophy:hover { transform: translateY(-2px); border-color: var(--line-2); }
.trophy > div { flex: 1; min-width: 0; display: grid; gap: 1px; font-size: var(--t-sm); }
.trophy > div b { font-size: var(--t-md); }
.medal { position: relative; display: grid; place-items: center; width: 48px; height: 48px; flex: none; border-radius: 50%; background: rgba(255, 255, 255, .06); border: 1px dashed var(--line-2); color: var(--muted); }
.medal > .ic { width: 22px; height: 22px; }
.medal-state { position: absolute; right: -4px; bottom: -4px; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--surface-3); border: 2px solid var(--surface); color: var(--muted); }
.medal-state .ic { width: 11px; height: 11px; }
.trophy-reward { font-weight: 800; opacity: .55; }
.trophy.done { background: linear-gradient(135deg, rgba(255, 201, 77, .13), var(--surface) 60%); border-color: rgba(255, 201, 77, .4); }
.trophy.done .medal { background: linear-gradient(135deg, #ffe08a, #ffab2e); border: 0; color: #4a2c00; box-shadow: 0 6px 20px rgba(255, 171, 46, .35); }
.trophy.done .medal-state { background: var(--good); color: #06241a; }
.trophy.done .trophy-reward { opacity: 1; }
.trophy:not(.done) > div b { color: #cfd4ee; }

/* shop */
.shop-bar { display: flex; align-items: center; justify-content: space-between; gap: var(--s3) var(--s5); flex-wrap: wrap; margin-bottom: var(--s5); }
.shop-bar p { max-width: 62ch; font-size: var(--t-sm); }
.shop-wallet { display: flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 999px; background: rgba(255, 201, 77, .1); border: 1px solid rgba(255, 201, 77, .35); font-size: var(--t-sm); }
.shop-wallet b { font-size: var(--t-xl); color: var(--accent); font-variant-numeric: tabular-nums; line-height: 1; } .shop-wallet .ic { width: 20px; height: 20px; }
.shopgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: var(--s4); }
.item { position: relative; display: flex; flex-direction: column; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); overflow: hidden; transition: transform .25s var(--ease), border-color .25s, box-shadow .25s; }
.item:hover { transform: translateY(-4px); border-color: var(--line-2); box-shadow: 0 18px 44px rgba(0, 0, 0, .45); }
.item.equipped { border-color: rgba(95, 242, 192, .6); box-shadow: 0 0 0 1px rgba(95, 242, 192, .35), 0 14px 40px rgba(95, 242, 192, .08); }
.thumb { position: relative; display: block; width: 100%; aspect-ratio: 1; padding: 0; border: 0; overflow: hidden; background: radial-gradient(70% 60% at 50% 40%, #434aa6, #1a1e42 70%, #12162c); }
.item.equipped .thumb { background: radial-gradient(70% 60% at 50% 40%, #2f8f86, #173a48 70%, #12162c); }
.item.short .thumb img { filter: saturate(.55) brightness(.8); }
.thumb img, .sheet-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: 0; transition: opacity .4s, transform .4s var(--ease), filter .3s; }
.thumb img.in, .sheet-stage img.in { opacity: 1; }
.thumb-wait { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--display); font-size: 64px; font-weight: 700; color: rgba(255, 255, 255, .14); }
img.in + .thumb-wait { display: none; }
.item:hover .thumb img, .thumb:focus-visible img { transform: scale(1.08) translateY(-2%); filter: none; }
.thumb:focus-visible { outline-offset: -4px; border-radius: var(--r-lg) var(--r-lg) 0 0; }
.peek { position: absolute; left: 50%; bottom: 10px; display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; background: rgba(8, 10, 22, .78); border: 1px solid var(--line); font-size: var(--t-xs); font-weight: 800; white-space: nowrap; opacity: 0; transform: translate(-50%, 8px); transition: opacity .2s, transform .2s var(--ease); }
.item:hover .peek, .thumb:focus-visible .peek { opacity: 1; transform: translate(-50%, 0); }
.ribbon { position: absolute; left: 10px; top: 10px; display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px 4px 7px; border-radius: 999px; background: var(--good); color: #06241a; font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; pointer-events: none; }
.ribbon .ic { width: 13px; height: 13px; }
.item-body { display: grid; gap: 10px; padding: 14px; }
.item-line { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.item-line > b { font-size: var(--t-lg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tagline { font-size: var(--t-xs); font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--good); }
.item .btn { width: 100%; }
.confetto { position: fixed; z-index: 200; width: 9px; height: 13px; border-radius: 2px; pointer-events: none; }
.confetto.round { width: 11px; height: 11px; border-radius: 50%; box-shadow: inset 0 0 0 2px rgba(168, 102, 10, .7); }

/* sheets */
dialog.sheet { width: min(640px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; border: 1px solid var(--line-2); border-radius: var(--r-xl); background: var(--surface); color: var(--text); box-shadow: 0 40px 120px rgba(0, 0, 0, .7); overflow: auto; overscroll-behavior: contain; }
dialog.sheet[open] { animation: sheet-in .28s var(--ease); }
dialog.sheet::backdrop { background: rgba(5, 6, 14, .72); backdrop-filter: blur(6px); animation: fade .2s; }
@keyframes sheet-in { from { opacity: 0; translate: 0 18px; } }
.sheet-x { position: sticky; top: 0; z-index: 5; height: 0; display: flex; justify-content: flex-end; margin: 0; }
.sheet-x .iconbtn { margin: 12px; background: rgba(8, 10, 22, .7); backdrop-filter: blur(6px); }
.sheet-art { position: relative; isolation: isolate; }
.sheet-art .cover { aspect-ratio: 2 / 1; }
.sheet-art .poster b { font-size: clamp(20px, 9cqw, 64px); }
.sheet-art .feat-shade { z-index: 1; background: linear-gradient(0deg, var(--surface) 0%, rgba(18, 22, 44, 0) 55%); }
.sheet-body { display: grid; gap: var(--s4); padding: var(--s5) clamp(18px, 4vw, 32px) clamp(20px, 4vw, 32px); }
.sheet.game .sheet-body { margin-top: -44px; position: relative; z-index: 2; }
.sheet-body h2 { font-size: clamp(32px, 6vw, 46px); }
.sheet-body h3 { font-size: var(--t-xs); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-top: var(--s2); }
.sheet-blurb { font-size: var(--t-lg); color: #dfe3fb; text-wrap: pretty; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: var(--s2); }
.facts > div { padding: 10px 14px; border-radius: var(--r-md); background: rgba(255, 255, 255, .05); border: 1px solid var(--line); }
.facts dt { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin-top: 2px; font-size: var(--t-lg); font-weight: 800; }
.invite { display: flex; gap: 12px; padding: 14px; border-radius: var(--r-md); background: rgba(122, 107, 255, .14); border: 1px solid rgba(122, 107, 255, .45); font-size: var(--t-sm); }
.invite .ic { width: 22px; height: 22px; color: #b3a9ff; margin-top: 1px; } .invite b { color: var(--text); } .invite span { color: #d5d3f5; }
.scores { display: grid; gap: 6px; }
.scores li { display: flex; align-items: center; gap: 12px; padding: 8px 12px; border-radius: 12px; background: rgba(255, 255, 255, .04); font-size: var(--t-sm); }
.scores li b { flex: 1; font-size: var(--t-lg); font-variant-numeric: tabular-nums; }
.rank { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: rgba(255, 255, 255, .1); font-size: var(--t-xs); font-weight: 800; }
.scores li:first-child { background: rgba(255, 201, 77, .12); } .scores li:first-child .rank { background: var(--accent); color: var(--accent-ink); } .scores li:first-child b { color: var(--accent); }
.sheet-cta { display: flex; align-items: center; flex-wrap: wrap; gap: var(--s3); margin-top: var(--s2); font-size: var(--t-sm); }
dialog.item-sheet[open] { width: min(860px, calc(100vw - 32px)); display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.item-sheet .sheet-x { grid-column: 1 / -1; }
.sheet-stage { position: relative; min-height: 440px; background: linear-gradient(180deg, var(--surface-3), var(--surface)); border-right: 1px solid var(--line); overflow: hidden; }
.sheet-stage .stage-tag { top: auto; bottom: 14px; left: 50%; transform: translateX(-50%); white-space: nowrap; }
.item-sheet .sheet-body { align-content: center; padding-top: 56px; }

/* settings */
.settings-body { display: grid; gap: var(--s3); padding: clamp(20px, 4vw, 32px); }
dialog.settings { width: min(500px, calc(100vw - 32px)); }
.settings-body h2 { font-size: 36px; margin-bottom: var(--s2); }
.field { display: flex; align-items: center; justify-content: space-between; gap: var(--s4); padding: 12px 14px; border-radius: var(--r-md); background: rgba(255, 255, 255, .04); border: 1px solid var(--line); }
.field > span { display: flex; align-items: center; flex-wrap: wrap; gap: 0 10px; font-weight: 700; }
.field small { flex-basis: 100%; font-weight: 500; font-size: var(--t-xs); color: var(--muted); }
.field .ic { color: var(--muted); }
.field.stack { flex-direction: column; align-items: stretch; gap: 10px; }
.field input { width: 170px; min-width: 0; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line); background: rgba(255, 255, 255, .07); font-weight: 700; }
.field input:focus, .reset-row input:focus { outline: none; border-color: var(--accent); }
.switch { position: relative; width: 52px; height: 30px; flex: none; padding: 0; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(255, 255, 255, .1); transition: background .2s, border-color .2s; }
.switch i { position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #cfd4ee; transition: transform .2s var(--ease), background .2s; }
.switch[aria-checked="true"] { background: rgba(95, 242, 192, .3); border-color: var(--good); }
.switch[aria-checked="true"] i { transform: translateX(22px); background: var(--good); }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 4px; border-radius: 12px; background: rgba(0, 0, 0, .3); }
.seg button { padding: 9px; border: 0; border-radius: 9px; background: none; font-weight: 700; color: var(--muted); transition: background .15s, color .15s; }
.seg button:hover { color: var(--text); }
.seg button[aria-checked="true"] { background: var(--text); color: var(--ink); }
.danger { margin-top: var(--s3); padding-top: var(--s4); border-top: 1px dashed var(--line-2); display: grid; gap: var(--s3); justify-items: start; }
#resetBox { display: grid; gap: 10px; padding: 14px; border-radius: var(--r-md); background: rgba(255, 107, 125, .1); border: 1px solid rgba(255, 107, 125, .45); font-size: var(--t-sm); justify-self: stretch; }
#resetBox[hidden] { display: none; }
.reset-row { display: flex; gap: 8px; flex-wrap: wrap; }
.reset-row input { width: 110px; padding: 7px 10px; border-radius: 10px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .3); font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }

/* toasts */
.toasts { position: fixed; left: 50%; bottom: 24px; z-index: 210; transform: translateX(-50%); display: grid; gap: 8px; justify-items: center; width: max-content; max-width: calc(100vw - 32px); pointer-events: none; }
.toastlet { display: flex; align-items: center; gap: 10px; padding: 12px 18px; border-radius: 14px; background: #262c58; border: 1px solid var(--line-2); box-shadow: 0 16px 40px rgba(0, 0, 0, .5); font-weight: 600; font-size: var(--t-sm); animation: rise .3s var(--ease); transition: opacity .3s, transform .3s; }
.toastlet.good { border-color: rgba(95, 242, 192, .5); } .toastlet.good .ic { color: var(--good); }
.toastlet.out { opacity: 0; transform: translateY(8px); }

/* footer */
footer.site { max-width: 1280px; margin: 0 auto; padding: 0 var(--gutter) var(--s7); display: grid; grid-template-columns: 1fr auto; gap: var(--s3) var(--s5); align-items: center; font-size: var(--t-sm); }
footer.site::before { content: ""; grid-column: 1 / -1; height: 4px; margin-bottom: var(--s5); background: radial-gradient(circle, rgba(255, 255, 255, .28) 1.2px, transparent 1.6px) left top / 10px 4px repeat-x; }
.foot-brand { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; }
.foot-brand b { font-family: var(--display); font-stretch: 82%; font-size: 22px; letter-spacing: .06em; text-transform: uppercase; }
.foot-brand .logo { width: 24px; height: 24px; }
footer.site nav { display: flex; gap: var(--s5); font-weight: 700; }
footer.site nav a:hover, footer.site .linkbtn:hover { color: var(--accent); }
footer.site .linkbtn { font-weight: 700; }
.fine { grid-column: 1 / -1; font-size: var(--t-xs); }
.noscript { text-align: center; padding: 20px; }

/* simple pages: credits, 404 */
.page { max-width: 820px; margin: 0 auto; padding: var(--s7) var(--gutter) var(--s8); display: grid; gap: var(--s5); }
.page h1 { font-size: clamp(40px, 7vw, 72px); }
.page .lead { font-size: var(--t-lg); color: #dfe3fb; max-width: 60ch; }
.page a.inline { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.credit-list { display: grid; gap: var(--s2); }
.credit-list li { display: flex; align-items: center; justify-content: space-between; gap: var(--s3) var(--s4); flex-wrap: wrap; padding: 14px 16px; border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--line); }
.credit-list b { display: block; } .credit-list span { color: var(--muted); font-size: var(--t-sm); }
.lost { min-height: calc(100dvh - 60px); align-content: center; justify-items: center; text-align: center; }
.lost .code { font-family: var(--display); font-stretch: 82%; font-weight: 700; font-size: clamp(110px, 26vw, 220px); line-height: .9; display: flex; align-items: center; gap: .04em; background: linear-gradient(180deg, #fff, #8f96c9); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lost .code svg { width: .78em; height: .78em; animation: bob 1.6s ease-in-out infinite alternate; }
.lost .row { display: flex; gap: var(--s3); flex-wrap: wrap; justify-content: center; }
.lost .picks { display: flex; gap: var(--s2); flex-wrap: wrap; justify-content: center; }

/* responsive */
@media (max-width: 1020px) {
  .first { grid-template-columns: 1fr; }
  .player { flex-direction: row; }
  .player .stage { flex: 0 0 42%; min-height: 280px; }
  .player-body { flex: 1; align-content: center; min-width: 0; }
  .daily { grid-template-columns: 1fr 1fr; }
  .daily .quests { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  html { scroll-padding-top: 70px; }
  header.site { gap: var(--s3); }
  .brand { font-size: 22px; } .brand .logo { width: 26px; height: 26px; }
  .sitenav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; padding: 6px 8px calc(6px + env(safe-area-inset-bottom, 0px)); background: rgba(11, 13, 26, .92); backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
  .sitenav a { flex-direction: column; gap: 2px; padding: 6px 4px; border-radius: 12px; font-size: 11px; justify-content: center; }
  .sitenav a .ic { display: block; width: 22px; height: 22px; }
  .sitenav a[aria-current] { color: var(--accent); background: none; }
  .sitenav .dot { position: absolute; top: 4px; left: calc(50% + 8px); }
  main { padding-top: var(--s4); padding-bottom: var(--s7); }
  main > section { margin-top: var(--s7); }
  footer.site { grid-template-columns: 1fr; padding-bottom: 110px; }
  .toasts { bottom: 84px; }
  .featured { min-height: 460px; }
  .feat-shade { background: linear-gradient(0deg, rgba(8, 10, 22, .96) 0%, rgba(8, 10, 22, .78) 42%, rgba(8, 10, 22, 0) 80%); }
  .feat-blurb { font-size: var(--t-md); }
  .feat-cta .best { flex-basis: 100%; margin-left: 0; }
  .library { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--s4); }
  .chips { flex-wrap: nowrap; overflow-x: auto; margin: 0 calc(-1 * var(--gutter)); padding: 2px var(--gutter); scrollbar-width: none; max-width: 100vw; }
  .chipbtn { flex: none; }
  .head-meter { text-align: left; flex: 1; }
  .shopgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3); }
  .item-body { padding: 12px; } .item .btn { padding: 8px 6px; font-size: 13px; }
  .peek { display: none; }
  dialog.sheet, dialog.item-sheet[open] { width: 100vw; max-width: 100vw; max-height: 92dvh; margin: auto 0 0; border-radius: var(--r-xl) var(--r-xl) 0 0; border-width: 1px 0 0; }
  dialog.item-sheet[open] { grid-template-columns: 1fr; }
  .sheet-stage { min-height: 280px; border-right: 0; border-bottom: 1px solid var(--line); }
  .item-sheet .sheet-body { padding-top: var(--s5); }
  @keyframes sheet-in { from { translate: 0 60px; opacity: 0; } }
}
@media (max-width: 600px) {
  .player { flex-direction: column; }
  .player .stage { flex: none; height: 250px; min-height: 0; }
  .daily { grid-template-columns: 1fr; }
  .pitch ol { gap: var(--s3); flex-direction: column; }
  .who .pill { padding: 0 11px; }
  .trophies { grid-template-columns: 1fr; }
  .field input { width: 130px; }
}
@media (max-width: 380px) {
  .brand span { font-size: 19px; }
  .who { gap: 6px; } .who .pill { padding: 0 9px; height: 36px; } .iconbtn { width: 36px; height: 36px; }
  .stats dd { font-size: 19px; } .stats > div { padding: 8px 9px; }
  .home .btn.big { padding: 13px 16px; }
}
@media (hover: none) { .tile-play { transform: none; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
}
