/* Home, leaderboard, shop, more and the "play computer" setup screen. */
.page { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; padding: calc(var(--safe-t) + 14px) 16px 28px; }
.page::-webkit-scrollbar { display: none; }
.sec { display: flex; align-items: baseline; justify-content: space-between; margin: 24px 0 10px; font: 800 19px var(--sans); letter-spacing: .1px; color: var(--ink); }
.sec button, .sec a { font-size: 15px; font-weight: 700; color: var(--link); }
.sec, .page > h1, .tier, .row-set > span { text-shadow: 0 0 8px var(--halo), 0 0 14px var(--halo), 0 0 3px var(--halo); }
.page > h1 { font: 700 30px var(--sans); margin: 4px 0 14px; color: var(--ink); }
.panel, .list, .recent, .rankbar, .me-card, .board, .item-card, .profile, .opp-hero, .botbtn, .setup .link, .statgrid div {
  border: 1px solid var(--line); box-shadow: 0 1px 0 #fff3, 0 3px 10px var(--shadow);
}
body[data-mode="dark"] .panel, body[data-mode="dark"] .list, body[data-mode="dark"] .recent,
body[data-mode="dark"] .rankbar, body[data-mode="dark"] .me-card, body[data-mode="dark"] .board,
body[data-mode="dark"] .item-card, body[data-mode="dark"] .profile, body[data-mode="dark"] .opp-hero,
body[data-mode="dark"] .botbtn, body[data-mode="dark"] .setup .link, body[data-mode="dark"] .statgrid div {
  box-shadow: none;
}
body[data-mode="dark"] .hd { box-shadow: none; }

/* header */
.hd { display: flex; align-items: center; gap: 10px; padding: 6px 8px 6px 6px; border-radius: 14px; background: var(--glass); border: 1px solid var(--line); box-shadow: 0 2px 8px var(--shadow); }
.hd .me .avatar { width: 46px; height: 46px; border-radius: 9px; }
.hd .who { line-height: 1.15; min-width: 0; }
.hd .who small { display: block; color: var(--muted); font-weight: 600; font-size: 12px; letter-spacing: .04em; }
.hd .who b { display: block; font: 700 19px var(--sans); color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 150px; }
.hd .grow { flex: 1; }
.streak { display: flex; align-items: center; gap: 2px; font: 800 20px var(--sans); color: var(--ink); }
.streak .ic { font-size: 26px; color: #b3a384; }
.streak.hot .ic { color: #e27d33; }
.icon-btn { position: relative; width: 44px; height: 44px; display: grid; place-items: center; font-size: 26px; color: var(--muted); border-radius: 10px; }
.icon-btn:active { background: #00000012; }
.icon-btn .badge { top: 3px; left: auto; right: 1px; box-shadow: 0 0 0 2px var(--glass); }

/* rank strip */
.rankbar { margin-top: 14px; display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: 14px; background: var(--surface); }
.rankbar .medal { width: 54px; height: 54px; border-radius: 12px; display: grid; place-items: center; font-size: 30px; color: #fff; background: linear-gradient(150deg, var(--accent), var(--accent-d)); box-shadow: inset 0 0 0 2px #fff3; }
.rankbar .rk { flex: 1; min-width: 0; }
.rankbar .rk small { color: var(--muted); font-weight: 700; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.rankbar .rk b { display: block; font: 700 25px/1.1 var(--sans); color: var(--ink); }
.bar-rp { margin-top: 7px; height: 8px; border-radius: 4px; background: var(--bg2); overflow: hidden; }
.bar-rp i { display: block; height: 100%; min-width: 8px; background: var(--accent); border-radius: 4px; }
.rankbar .rk .nx { display: block; margin-top: 4px; color: var(--muted); font-size: 12.5px; font-weight: 600; }
.rankbar .rp { text-align: right; font: 800 28px/1 var(--sans); color: var(--ink); }
.rankbar .rp small { display: block; margin-top: 3px; font: 800 11px var(--sans); letter-spacing: .1em; color: var(--muted); }

/* the two games */
.games { display: flex; flex-direction: column; gap: 12px; }
.game { position: relative; overflow: hidden; display: block; width: 100%; text-align: left; border-radius: 14px; color: #fff; padding: 14px 16px; height: 144px; box-shadow: 0 1px 0 #fff3, 0 4px 12px var(--shadow); }
.game:active { transform: scale(.99); }
body[data-mode="dark"] .game { border: 1px solid var(--line); box-shadow: none; }
.game.nk { background: linear-gradient(140deg, #2e7a47 0%, #21604f 60%, #1c4d58 100%); }
.game.ss { background: linear-gradient(140deg, #2d6f93 0%, #285a86 55%, #233f6b 100%); }
.game::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: repeating-linear-gradient(90deg, #f1e8cf10 0 10px, transparent 10px 34px), repeating-linear-gradient(0deg, #f1e8cf0d 0 10px, transparent 10px 34px); }
body[data-mode="dark"] .game.nk { background: linear-gradient(140deg, #202a24, #1a2220); }
body[data-mode="dark"] .game.ss { background: linear-gradient(140deg, #20272d, #1a2025); }
body[data-mode="dark"] .game::before { background: none; }
.game h2 { position: relative; font: 700 clamp(19px, 5.8vw, 24px)/1.05 var(--serif); text-shadow: 0 2px 0 #0003; }
.game .sub { position: relative; display: block; margin-top: 4px; font-size: 12px; font-weight: 700; color: #f1e8cfcc; letter-spacing: .08em; text-transform: uppercase; }
.game .go { position: absolute; right: 14px; bottom: 12px; height: 40px; padding: 0 18px; border-radius: 9px; background: #f2c14e; color: #2b1f04; font: 800 16px var(--sans); box-shadow: 0 3px 0 #9a6f12; display: flex; align-items: center; gap: 6px; }
body[data-mode="dark"] .game .go { box-shadow: none; }
.game .go .ic { font-size: 18px; color: #2b1f04; }
.game .art { position: absolute; right: 12px; top: 8px; width: 120px; height: 78px; pointer-events: none; }
.game .art .card { position: absolute; transform-origin: 50% 100%; box-shadow: 0 3px 8px #0007; }

/* recent match */
.recent { position: relative; display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 14px; background: var(--surface); }
.recent .faces { display: flex; flex: none; }
.recent .faces .avatar { width: 46px; height: 46px; border-radius: 10px; box-shadow: 0 0 0 3px var(--surface); }
.recent .faces .avatar + .avatar { margin-left: -14px; }
.recent .info { flex: 1; min-width: 0; line-height: 1.25; }
.recent .info b { display: block; font: 800 17px var(--sans); color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent .info span { display: block; color: var(--muted); font-weight: 600; font-size: 13px; }
.recent .res { display: inline-block; margin-right: 6px; padding: 2px 7px; border-radius: 5px; font: 900 11px var(--sans); letter-spacing: .08em; vertical-align: 1px; }
.recent .res.w { background: #4f9a4a30; color: #3b7a36; }
.recent .res.l { background: #cc5a4030; color: #b04a34; }
body[data-mode="dark"] .recent .res.w { color: #8fd08a; }
body[data-mode="dark"] .recent .res.l { color: #f0917c; }
.recent .again { flex: none; width: 54px; height: 50px; border-radius: 10px; display: grid; place-items: center; font-size: 30px; color: #fff; background: var(--accent); box-shadow: 0 4px 0 var(--accent-d); }
.recent .again:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--accent-d); }
.recent.empty { color: var(--muted); font-weight: 600; justify-content: center; text-align: center; padding: 20px 16px; }

/* your hand: the stats as four playing cards */
.handseg { display: inline-flex; gap: 4px; padding: 3px; border-radius: 9px; background: var(--bg2); }
.handseg button { padding: 4px 10px; border-radius: 7px; font: 800 13px var(--sans); color: var(--muted); }
.handseg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px var(--shadow); }
.scards { display: flex; justify-content: center; padding: 10px 0 14px; }
.scard { position: relative; flex: none; width: 82px; height: 116px; margin-left: -12px; border-radius: 9px; background: #fbf7ec; color: #1d1c1a; box-shadow: 0 0 0 1px #0002, 0 5px 12px var(--shadow); transform-origin: 50% 130%; text-align: center; }
.scard:first-child { margin-left: 0; }
.scard.red { color: #bf3a2d; }
.scard .cn { position: absolute; left: 7px; top: 5px; display: flex; flex-direction: column; align-items: center; line-height: 1; font: 800 15px var(--serif); }
.scard .cn i { font-style: normal; font-size: 12px; margin-top: 1px; }
.scard .n { position: absolute; left: 0; right: 0; top: 30px; font: 800 33px/1 var(--serif); letter-spacing: -.02em; }
.scard .l { position: absolute; left: 4px; right: 4px; bottom: 9px; font: 800 10.5px/1.15 var(--sans); letter-spacing: .06em; text-transform: uppercase; color: #6b5f4d; }
.scard.tn .n { font-size: 24px; top: 36px; }

/* leaderboard */
.me-card { display: flex; align-items: center; gap: 14px; background: var(--surface); border-radius: 14px; padding: 14px; margin: 4px 0 6px; }
.me-card[hidden] { display: none; }
.me-card .avatar { width: 56px; height: 56px; }
.me-card b { font: 800 20px var(--sans); color: var(--ink); }
.me-card .sm { color: var(--muted); font-weight: 600; font-size: 14px; }
.me-card .big { margin-left: auto; text-align: right; font: 800 30px var(--sans); line-height: 1; color: var(--ink); }
.me-card .big small { display: block; margin-top: 4px; font: 700 12px var(--sans); color: var(--muted); letter-spacing: .08em; }
.board { background: var(--surface); border-radius: 14px; overflow: hidden; margin-top: 10px; }
.lrow { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 14px; border-top: 1px solid var(--line); text-align: left; min-height: 62px; }
.lrow:first-child { border-top: 0; }
.lrow .pos { width: 22px; font: 800 15px var(--sans); color: var(--muted); text-align: center; }
.lrow:nth-child(1) .pos { color: #d9a420; }
.lrow .avatar { width: 42px; height: 42px; }
.lrow .nm { flex: 1; min-width: 0; }
.lrow .nm b { display: block; font-weight: 800; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lrow .nm small { color: var(--muted); font-size: 13px; font-weight: 600; }
.lrow .rat { font: 800 18px var(--sans); color: var(--ink); text-align: right; }
.lrow .rat small { display: block; font: 700 10px var(--sans); letter-spacing: .1em; color: var(--muted); }
.lrow.you { background: color-mix(in srgb, var(--accent) 16%, var(--surface)); }
body[data-mode="dark"] .lrow.you { background: color-mix(in srgb, var(--accent) 10%, var(--surface)); }
.note-sm { margin-top: 10px; color: var(--muted); font-size: 13px; font-weight: 600; text-align: center; text-shadow: 0 0 8px var(--halo); }
.linkbtn { display: block; margin: 12px auto 0; color: var(--link); font-weight: 800; font-size: 15px; text-shadow: 0 0 8px var(--halo); }

/* shop */
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.item-card { position: relative; background: var(--surface); border-radius: 12px; padding: 16px 10px 12px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.item-card.on { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent), 0 3px 10px var(--shadow); }
.item-card b { font-weight: 800; color: var(--ink); }
.item-card small { color: var(--muted); font-weight: 600; font-size: 13px; }
.item-card .card { --cw: 58px; }
.swatch { width: 100%; height: 66px; border-radius: 9px; box-shadow: inset 0 0 0 1px #ffffff22; }
.soon { margin-top: 18px; padding: 14px; border-radius: 12px; border: 2px dashed var(--line); color: var(--muted); text-align: center; font-weight: 600; }

/* more */
.profile { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; background: var(--surface); border-radius: 14px; padding: 14px; margin-bottom: 4px; }
.profile .avatar { width: 64px; height: 64px; border-radius: 10px; }
.profile b { font: 800 22px var(--sans); display: block; color: var(--ink); }
.profile small { color: var(--muted); font-weight: 600; }
.profile > .ic { margin-left: auto; color: var(--muted); font-size: 22px; }
.list { margin-top: 0; }
.list .item { color: var(--ink); }
.group { margin: 20px 0 8px; font: 800 12px var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); text-shadow: 0 0 8px var(--halo), 0 0 3px var(--halo); }

/* play computer setup */
.setup { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.setup .bar-top { flex: none; display: flex; align-items: center; gap: 6px; margin: calc(var(--safe-t) + 8px) 12px 6px; padding: 4px 12px 4px 4px; border-radius: 14px; background: var(--glass); border: 1px solid var(--line); box-shadow: 0 2px 8px var(--shadow); }
.setup .bar-top h1 { font: 700 24px var(--sans); color: var(--ink); }
.setup .bar-top .icon-btn { color: var(--ink); }
.setup .body { flex: 1; overflow-y: auto; padding: 8px 16px 130px; scrollbar-width: none; }
.opp-hero { display: flex; align-items: center; gap: 14px; background: var(--surface); border-radius: 14px; padding: 14px; }
.opp-hero .avatar { width: 84px; height: 84px; border-radius: 12px; }
.opp-hero b { font: 800 24px var(--sans); display: block; color: var(--ink); }
.opp-hero p { margin-top: 6px; color: var(--muted); font-size: 14px; line-height: 1.3; }
.lvl { display: inline-flex; align-items: center; gap: 8px; margin-top: 3px; }
.lvl .tag { padding: 3px 9px; border-radius: 6px; font: 900 11px var(--sans); letter-spacing: .1em; text-transform: uppercase; color: #fff; background: var(--accent); }
.lvl .tag.Easy { background: #4f9a4a; } .lvl .tag.Medium { background: #3d8fd4; } .lvl .tag.Hard { background: #d28a2c; } .lvl .tag.Expert { background: #c0463a; }
.pips { display: inline-flex; gap: 3px; }
.pips i { width: 9px; height: 9px; border-radius: 2px; background: #00000026; }
body[data-mode="dark"] .pips i { background: #ffffff2a; }
.pips i.on { background: var(--ink); }
.tier { margin: 20px 0 8px; font: 800 13px var(--sans); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.bots { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.botbtn { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 12px; background: var(--surface); text-align: left; min-height: 62px; }
.botbtn.on { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent), 0 3px 10px var(--shadow); background: color-mix(in srgb, var(--accent) 14%, var(--surface)); }
.botbtn .avatar { width: 44px; height: 44px; }
.botbtn b { display: block; font-size: 15px; font-weight: 800; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.botbtn > div { min-width: 0; }
.row-set { display: flex; align-items: center; gap: 12px; margin-top: 10px; }
.row-set > span { font-weight: 700; flex: none; width: 96px; color: var(--ink); }
.row-set .seg { flex: 1; }
.setup .foot { position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 16px calc(14px + var(--safe-b)); background: linear-gradient(transparent, color-mix(in srgb, var(--bg) 92%, transparent) 40%); }
.setup .foot .btn { height: 64px; font-size: 26px; border-radius: 12px; }
.setup .link { display: flex; align-items: center; gap: 10px; width: 100%; margin-top: 12px; padding: 12px 14px; background: var(--surface); border-radius: 12px; font-weight: 700; text-align: left; color: var(--ink); }
.setup .link small { color: var(--muted); font-weight: 600; display: block; }
.setup .link .ic { color: var(--muted); font-size: 22px; }
.setup .link .grow { flex: 1; }

/* sheets: help text, profile editor, inbox, legal */
.sheet ul { margin: 6px 0 0; padding-left: 20px; color: var(--muted); line-height: 1.4; }
.sheet li { margin: 6px 0; }
.sheet li b, .sheet p b { color: var(--ink); }
.sheet input[type=text] { width: 100%; height: 50px; padding: 0 14px; border-radius: 9px; border: 2px solid var(--line); background: var(--bg2); color: var(--text); font: 700 18px var(--sans); user-select: text; -webkit-user-select: text; }
.sheet input[type=email] { width: 100%; height: 50px; padding: 0 14px; border-radius: 9px; border: 2px solid var(--line); background: var(--bg2); color: var(--text); font: 700 18px var(--sans); user-select: text; -webkit-user-select: text; }
.sheet input[type=password] { width: 100%; height: 50px; padding: 0 14px; border-radius: 9px; border: 2px solid var(--line); background: var(--bg2); color: var(--text); font: 700 18px var(--sans); user-select: text; -webkit-user-select: text; }
.sheet input[type=text]:focus { outline: 0; border-color: var(--accent); }
.sheet input[type=email]:focus { outline: 0; border-color: var(--accent); }
.sheet input[type=password]:focus { outline: 0; border-color: var(--accent); }
.account-provider { margin: 12px 0; }
#accountFields { display: grid; gap: 8px; margin-top: 12px; }
#accountFields label { color: var(--ink); font-size: 14px; font-weight: 700; }
#accountFields .row { margin-top: 6px; }
.player-search { display: flex; align-items: center; gap: 8px; margin-top: 12px; }
.player-search input { flex: 1; min-width: 0; }
.player-results { display: grid; gap: 8px; margin-top: 10px; }
.player-result { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; background: var(--bg2); }
button.player-result { width: 100%; border: 0; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.player-result .avatar { flex: none; width: 40px; height: 40px; border-radius: 10px; }
.player-result span { min-width: 0; }
.player-result b, .player-result small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.player-result b { color: var(--ink); }
.player-result small { color: var(--green-d); font-size: 12px; font-weight: 700; }
.player-result .player-actions { display: flex; flex: none; gap: 5px; }
body[data-mode="dark"] .player-result small { color: #8fd08a; }
.avgrid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-top: 8px; }
.avgrid button { border-radius: 10px; padding: 3px; box-shadow: inset 0 0 0 2px transparent; }
.avgrid button.on { box-shadow: inset 0 0 0 3px var(--accent); }
.avgrid .avatar { width: 100% !important; height: auto !important; aspect-ratio: 1; }
.avgrid { grid-template-columns: repeat(4, 1fr); }
.statgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }
.statgrid div { background: var(--bg2); border-radius: 10px; padding: 12px; }
.statgrid b { font: 800 24px var(--sans); display: block; color: var(--ink); }
.statgrid span { color: var(--muted); font-size: 13px; font-weight: 600; }
.toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.toggle-row:first-of-type { border-top: 0; }
.toggle-row .grow { flex: 1; }
.toggle-row b { color: var(--ink); display: block; }
.toggle-row small { color: var(--muted); font-size: 13px; }
.themes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 8px; }
.themes button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px 8px; border-radius: 12px; background: var(--bg2); box-shadow: inset 0 0 0 2px transparent; font-weight: 800; font-size: 13px; color: var(--ink); }
.themes button.on { box-shadow: inset 0 0 0 3px var(--accent); }
.themes .sw { width: 52px; height: 52px; border-radius: 12px; position: relative; box-shadow: inset 0 0 0 1px #0003; }
.themes .sw::after { content: ""; position: absolute; right: 6px; bottom: 6px; width: 18px; height: 18px; border-radius: 6px; background: var(--c); box-shadow: 0 0 0 2px #fffa; }
.inbox { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }
.inbox-item { display: grid; gap: 6px; }
.inbox-actions { display: flex; justify-content: flex-end; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; font-weight: 700; }
.msg { display: block; width: 100%; text-align: left; padding: 12px 14px 12px 28px; border-radius: 12px; background: var(--bg2); position: relative; }
.msg.unread::before { content: ""; position: absolute; left: 12px; top: 18px; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); }
.msg b { display: block; color: var(--ink); font-weight: 800; }
.msg small { display: block; color: var(--muted); font-size: 12px; font-weight: 600; margin-top: 1px; }
.msg p { display: none; margin-top: 8px; color: var(--text); font-size: 15px; line-height: 1.4; }
.msg.open p { display: block; }
.empty-note { margin: 24px 0 8px; text-align: center; color: var(--muted); font-weight: 600; }
.legal h3 { margin-top: 16px; }
.legal p, .legal li { font-size: 14.5px; line-height: 1.45; }
.legal .draft { display: inline-block; margin: 4px 0 6px; padding: 3px 8px; border-radius: 6px; background: color-mix(in srgb, var(--gold) 28%, transparent); color: var(--ink); font: 800 11px var(--sans); letter-spacing: .08em; text-transform: uppercase; }
.rp-table { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 14px; }
.rp-table td, .rp-table th { padding: 7px 6px; border-top: 1px solid var(--line); text-align: left; color: var(--text); }
.rp-table th { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; border-top: 0; }

/* table colour choices live in table.css */
body[data-felt="forest"] { --felt: #1f5d3a; --felt-d: #123a24; }
body[data-felt="midnight"] { --felt: #1d3f66; --felt-d: #0f2542; }
body[data-felt="clay"] { --felt: #7a3f2c; --felt-d: #4d2418; }

/* avatar picker */
.av-now { display: flex; justify-content: center; margin: 10px 0 12px; }
.av-now .avatar { border-radius: 50%; box-shadow: 0 0 0 3px var(--accent), 0 4px 10px var(--shadow); }
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-box { text-align: center; padding-top: 8px; }
.photo-box p { margin-bottom: 4px; }
.photo-box .row { justify-content: center; }
.photo-box .row > * { flex: none; }
.photo-box label.btn { cursor: pointer; }
.usephoto { border-radius: 12px; padding: 3px; box-shadow: inset 0 0 0 3px transparent; }
.usephoto.on { box-shadow: inset 0 0 0 3px var(--accent); }

/* your record */
.record { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px; box-shadow: 0 1px 0 #fff4, 0 3px 10px var(--shadow); }
.rec-top { display: flex; align-items: center; gap: 16px; }
.ring-stat { flex: none; width: 96px; height: 96px; border-radius: 50%; display: grid; place-content: center; text-align: center;
  background: radial-gradient(closest-side, var(--surface) 76%, transparent 78%), conic-gradient(var(--accent) calc(var(--p) * 1%), var(--bg2) 0); }
.ring-stat b { font: 800 22px var(--sans); line-height: 1; color: var(--ink); }
.ring-stat small { font-size: 11px; font-weight: 700; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; margin-top: 3px; }
.rec-nums { flex: 1; display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px 6px; }
.rec-nums div { text-align: left; }
.rec-nums b { display: block; font: 800 20px/1.1 var(--sans); color: var(--ink); }
.rec-nums span { font-size: 11.500px; font-weight: 700; color: var(--muted); }
.form { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); }
.form .lbl { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.form .dots { display: flex; gap: 5px; }
.form i { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font: 800 9px/1 var(--sans); font-style: normal; color: #fff; }
.form i.w { background: #4f9a4e; }
.form i.l { background: #cc5a40; }
.form i.e { background: var(--bg2); box-shadow: inset 0 0 0 1px var(--line); }

/* play modes, rooms */
.roomcode { margin: 12px 0 4px; text-align: center; font: 800 40px var(--sans); letter-spacing: .28em; padding-left: .28em; color: var(--ink); background: var(--bg2); border: 2px dashed var(--line); border-radius: 12px; padding-top: 10px; padding-bottom: 10px; user-select: text; }
.seats { display: grid; gap: 6px; margin-top: 10px; }
.seat-row { padding: 11px 14px; border-radius: 10px; background: var(--bg2); color: var(--ink); }
.seat-row.empty { background: none; border: 2px dashed var(--line); color: var(--muted); }
.seat-row b { font-weight: 700; }
.note-sm { margin-top: 10px; font-size: 13px; color: var(--muted); }
.searching { display: flex; justify-content: center; gap: 10px; margin: 22px 0 14px; }
.searching i { width: 14px; height: 14px; border-radius: 50%; background: var(--accent); animation: bob 1s infinite ease-in-out; }
.searching i:nth-child(2) { animation-delay: .15s; } .searching i:nth-child(3) { animation-delay: .3s; }
@keyframes bob { 0%, 100% { transform: translateY(0); opacity: .45; } 50% { transform: translateY(-9px); opacity: 1; } }
.opt .ic { color: var(--accent-d); }

/* recent games */
.sec.rg-heading { font-weight: 650; }
.rg { background: var(--surface); border-radius: 14px; padding: 4px 12px 6px; }
body[data-mode="dark"] .rg { background: #151617; border: 1px solid #252729; }
.rg-list { list-style: none; margin: 0; padding: 4px 0 0; }
.rg-row { position: relative; display: flex; align-items: center; gap: 10px; min-height: 62px; padding: 6px 0; }
.rg-row + .rg-row { border-top: 1px solid color-mix(in srgb, var(--line) 55%, transparent); }
.rg-face { flex: none; }
.rg-face .avatar { width: 40px; height: 40px; border-radius: 12px; }
.rg-info { flex: 1; min-width: 0; line-height: 1.25; }
.rg-info b { display: block; font: 650 16px var(--sans); color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rg-info small { display: block; color: var(--muted); font: 500 12.5px var(--sans); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rg-res { flex: none; text-align: right; line-height: 1.2; }
.rg-res b { display: block; font: 650 14px var(--sans); }
.rg-row.w .rg-res b { color: #3b7a36; }
.rg-row.l .rg-res b { color: #b04a34; }
body[data-mode="dark"] .rg-row.w .rg-res b { color: #8fd08a; }
body[data-mode="dark"] .rg-row.l .rg-res b { color: #f0917c; }
.rg-again { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-size: 20px; color: var(--accent-d); border: 1.5px solid var(--line); background: transparent; }
body[data-mode="dark"] .rg-again { color: var(--accent); }
.rg-again:active { background: var(--bg2); transform: scale(.94); }
