/* Rink DJ · app.css
   Dark, high-contrast, big touch targets: built to be read at a glance in a bright rink. */

@font-face { font-family: 'Barlow Condensed'; font-weight: 600; font-display: swap; src: url(fonts/barlow-condensed-600.woff2) format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-weight: 700; font-display: swap; src: url(fonts/barlow-condensed-700.woff2) format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 400; font-display: swap; src: url(fonts/inter-400.woff2) format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 500; font-display: swap; src: url(fonts/inter-500.woff2) format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 600 700; font-display: swap; src: url(fonts/inter-600.woff2) format('woff2'); }

:root {
  --bg: #0B0F14; --s1: #161C24; --s2: #1F2731; --line: #2A3441;
  --tx: #F3F6F9; --mu: #A3AFBD; --soft: #C4CDD8;
  --blue: #56C2FF; --red: #FF5A47; --amber: #FFC857; --dim: #3A4554;
  --disp: 'Barlow Condensed', 'Arial Narrow', 'Helvetica Neue', sans-serif;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { height: 100%; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100%; background: var(--bg); color: var(--tx);
  font: 400 15px/1.35 Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  touch-action: manipulation; -webkit-user-select: none; user-select: none; overscroll-behavior-y: none;
}
button, input, textarea { font: inherit; color: inherit; }
button { border: 0; background: none; padding: 0; margin: 0; cursor: pointer; text-align: inherit; }
button:disabled { opacity: .35; cursor: default; }
input, textarea { -webkit-user-select: text; user-select: text; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
[hidden] { display: none !important; }
h1, h2, p { margin: 0; }
svg { flex: 0 0 auto; }
.disp { font-family: var(--disp); font-weight: 700; letter-spacing: .03em; }
.filepick { position: fixed; left: -200px; top: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* ---------- layout ---------- */
#app { max-width: 460px; margin: 0 auto; }
.scr {
  min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; gap: 14px;
  padding: calc(16px + env(safe-area-inset-top)) 16px calc(16px + env(safe-area-inset-bottom));
}
.center-all { align-items: center; justify-content: center; text-align: center; }
.hd { display: flex; align-items: center; gap: 12px; min-height: 48px; }
.hd-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.hd-col.top { flex: 0 0 auto; margin: 8px 0 4px; gap: 8px; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .1em; color: var(--mu); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.eyebrow.disp { font-size: 13px; font-weight: 600; letter-spacing: .14em; }
.h1 { font: 700 32px/1.02 var(--disp); }
.h1.sm { font-size: 27px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h2 { font-size: 17px; font-weight: 600; line-height: 1.25; }
.mu { color: var(--mu); }
.sm { font-size: 13px; }
.center { text-align: center; }
.lead { font-size: 14px; margin-top: -6px; }
.warn { color: var(--amber); }
.pad { padding: 16px; }
.col { display: flex; flex-direction: column; gap: 8px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.sec { display: flex; flex-direction: column; gap: 8px; }
.sec.tight { gap: 6px; }
.grow { flex: 1 1 auto; }
.sec-t, .sec-h h2 { font-size: 12px; font-weight: 600; letter-spacing: .08em; color: var(--mu); }
.sec-h { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.sec-h > span { font-size: 12px; color: var(--mu); text-align: right; }
.sec-note { margin-top: -4px; }
.foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; padding-top: 8px; }

/* ---------- buttons ---------- */
.sqbtn { width: 44px; height: 44px; flex: 0 0 44px; display: flex; align-items: center; justify-content: center; border-radius: 12px; background: var(--s1); }
.card .sqbtn, .sheet .sqbtn { background: var(--s2); }
.btn { min-height: 48px; padding: 0 16px; border-radius: 14px; display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 15px; font-weight: 600; text-align: center; }
.btn.primary { background: var(--blue); color: var(--bg); }
.btn.white { background: var(--tx); color: var(--bg); }
.btn.dark { background: var(--s1); font-weight: 500; }
.sheet .btn.dark { background: var(--s2); }
.btn.line { border: 2px solid var(--blue); color: var(--blue); }
.btn.ghost { color: var(--blue); font-weight: 500; min-height: 44px; }
.btn.danger { background: var(--red); color: var(--bg); }
.btn.ghost.danger { background: none; color: #FF8C7E; }
.btn.dashed { border: 2px dashed var(--line); color: var(--blue); }
.btn.sm { min-height: 44px; padding: 0 14px; border-radius: 12px; flex: 0 0 auto; font-size: 15px; }
.btn.ghost.sm { font-size: 13px; }
.btn.disp { font-size: 19px; font-weight: 700; letter-spacing: .04em; }
.btn.big { min-height: 58px; font-size: 21px; border-radius: 16px; }
.btn.huge { min-height: 64px; font-size: 24px; border-radius: 18px; gap: 10px; }
.backbtn { align-self: flex-start; min-height: 44px; padding: 0 16px 0 10px; border-radius: 12px; gap: 6px; }
.btn:active, .bigbtn:active, .tile:active, .chip:active, .pick:active, .net button:active, .round:active { transform: scale(.97); filter: brightness(1.12); }

/* ---------- cards, forms ---------- */
.card { background: var(--s1); border-radius: 16px; }
.card.pad { display: flex; flex-direction: column; gap: 10px; }
.card.note { border: 1px solid var(--blue); }
#installSlot { display: flex; flex-direction: column; }
.card.info { flex-direction: row; align-items: center; gap: 12px; color: var(--soft); font-size: 14px; }
.card.info svg { color: var(--blue); }
.lab { display: block; margin-top: 4px; font-size: 13px; font-weight: 600; color: var(--soft); }
.inp { width: 100%; min-height: 48px; padding: 10px 14px; border-radius: 12px; border: 2px solid var(--line); background: var(--bg); font-size: 16px; }
.inp:focus { outline: none; border-color: var(--blue); }
.inp::placeholder { color: #7C8998; }
.inp.area { resize: none; font-size: 14px; line-height: 1.4; }
.rows > * + * { border-top: 1px solid var(--line); }
.chk { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 10px 12px 10px 14px; cursor: pointer; }
.chk input[type=checkbox] { width: 22px; height: 22px; margin: 0; flex: 0 0 22px; accent-color: var(--blue); }
.chk > span { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.chk b { font-size: 15px; font-weight: 500; }
.chk small { font-size: 13px; color: var(--mu); }
.chk.stat { cursor: default; }
.chk.stat > svg { color: var(--blue); }
.chk.st-warn > svg { color: var(--amber); }
.stepper { display: flex; align-items: center; gap: 4px; flex: 0 0 auto; }
.step-v { min-width: 58px; text-align: center; font-size: 15px; font-weight: 600; }
.tog { position: relative; width: 56px; height: 44px; flex: 0 0 56px; }
.tog::before { content: ''; position: absolute; left: 2px; top: 6px; width: 52px; height: 32px; border-radius: 16px; background: var(--line); }
.tog i { position: absolute; top: 9px; left: 5px; width: 26px; height: 26px; border-radius: 50%; background: var(--mu); transition: left .15s; }
.tog.on::before { background: var(--blue); }
.tog.on i { left: 25px; background: var(--bg); }
.plain { margin: 0; padding-left: 18px; color: var(--soft); font-size: 14px; display: flex; flex-direction: column; gap: 6px; }
.kv { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.kv span { color: var(--mu); }
.kv b { font-weight: 600; text-align: right; }
.inrow { display: flex; gap: 8px; align-items: center; }
.inrow .inp { flex: 1; }
.numname { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; }

/* ---------- pre-game ---------- */
.pick { min-height: 84px; padding: 8px; border-radius: 16px; border: 2px solid var(--line); background: var(--s1); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; text-align: center; }
.pick b { font-size: 26px; line-height: 1; }
.pick span { font-size: 13px; color: var(--mu); }
.pick.on { background: var(--tx); border-color: var(--tx); color: var(--bg); }
.pick.on span { color: var(--bg); font-weight: 500; }

/* ---------- game day ---------- */
/* The game screen fits one screen whenever it can (the scorer tiles flex), and scrolls only on small phones with big rosters. */
.game { gap: 10px; height: 100vh; height: 100dvh; overflow-y: auto; padding-top: calc(12px + env(safe-area-inset-top)); padding-bottom: calc(12px + env(safe-area-inset-bottom)); }
.game .hd { min-height: 44px; }
.game > * { flex: 0 0 auto; }
.game > .grow { flex: 1 1 0; }
.teambtn { flex: 1; min-width: 0; min-height: 44px; display: flex; flex-direction: column; justify-content: center; gap: 3px; }
.teamname { display: inline-flex; align-items: center; gap: 6px; font-size: 28px; line-height: 1; }
.teamname svg { color: var(--mu); }
.np { padding: 10px 14px; display: flex; flex-direction: column; gap: 3px; }
.np-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.np-status { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; letter-spacing: .08em; color: var(--mu); white-space: nowrap; }
.np-status.live { color: var(--blue); }
.np-status i { width: 8px; height: 8px; border-radius: 50%; background: var(--blue); }
.np-top .mu { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-title { font-size: 28px; line-height: 1.08; letter-spacing: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-artist { font-size: 14px; color: var(--mu); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar { position: relative; height: 8px; margin-top: 8px; border-radius: 4px; background: var(--line); }
.bar-clip, .bar-fill { position: absolute; top: 0; bottom: 0; border-radius: 4px; }
.bar-clip { background: rgba(86, 194, 255, .35); }
.bar-fill { background: var(--blue); }
.bar-mark { position: absolute; top: -4px; width: 2px; height: 16px; background: var(--tx); }
.np-times { display: flex; justify-content: space-between; margin-top: 4px; font-size: 13px; color: var(--mu); }
.np-times b { color: var(--tx); font-weight: 600; }
.main2 { display: grid; grid-template-columns: 3fr 2fr; gap: 12px; }
.bigbtn { min-height: 84px; border-radius: 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font-size: 24px; letter-spacing: .04em; }
.bigbtn.fill { background: var(--blue); color: var(--bg); }
.bigbtn small { font: 500 14px/1.2 Inter, system-ui, sans-serif; letter-spacing: 0; }
.sheet .bigbtn { width: 100%; font-size: 30px; }
.bigbtn.line { border: 2px solid var(--blue); color: var(--blue); font-size: 20px; }
.chip { min-height: 44px; padding: 0 10px; border-radius: 12px; border: 2px solid var(--line); background: var(--s1); font-size: 15px; font-weight: 500; text-align: center; }
.chip.on { background: var(--tx); border-color: var(--tx); color: var(--bg); font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips .chip { flex: 1 1 auto; }
.sec-h h2.goal-h { font-size: 20px; letter-spacing: .04em; color: var(--red); }
/* --r5 / --r6 = number of tile rows at 5 or 6 columns (set by the app). Rows flex between 44px and 72px tall. */
.tiles {
  --rows: var(--r5, 3); --rmin: 44px; --rgap: 8px;
  flex: 1 1 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); grid-auto-rows: 1fr; gap: var(--rgap);
  min-height: calc(var(--rows) * var(--rmin) + (var(--rows) - 1) * var(--rgap));
  max-height: calc(var(--rows) * 72px + (var(--rows) - 1) * var(--rgap));
}
.tile { min-width: 0; min-height: 0; overflow: hidden; padding: 2px; border-radius: 14px; background: var(--s2); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.tile b { font-size: 26px; line-height: 1; }
.tile span { max-width: 100%; padding: 0 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; color: var(--soft); }
.tile.team { background: var(--red); color: var(--bg); }
.tile.team span { color: var(--bg); font-size: 16px; line-height: 1; }
.net { display: flex; align-items: center; gap: 8px; min-height: 60px; padding: 7px 8px; border-radius: 14px; background: var(--s1); border: 1px solid var(--line); }
.net.ask { padding-left: 12px; flex-wrap: wrap; }
.net-q { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.net-q b { font-size: 17px; line-height: 1.1; letter-spacing: .04em; color: var(--blue); }
.net-q small { font-size: 11px; color: var(--mu); }
.net-pick { min-height: 44px; padding: 0 12px; border: 2px solid var(--blue); border-radius: 10px; display: inline-flex; align-items: center; gap: 6px; }
.net-pick b { font-size: 22px; line-height: 1; color: var(--blue); }
.net-pick span { font-size: 14px; font-weight: 600; }
.net-num { position: relative; width: 44px; height: 44px; flex: 0 0 44px; border-radius: 10px; background: var(--s2); display: flex; align-items: center; justify-content: center; font-size: 22px; }
.net-num em, .sq em, .mo-num em { position: absolute; top: -5px; right: -5px; width: 16px; height: 16px; border-radius: 5px; background: var(--blue); color: var(--bg); display: flex; align-items: center; justify-content: center; font: normal 700 10px/1 Inter, system-ui, sans-serif; letter-spacing: 0; }
.net-who { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.net-who small { font-size: 10px; font-weight: 600; letter-spacing: .1em; color: var(--mu); }
.net-who b { font-size: 15px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.net-intro { min-height: 44px; padding: 0 10px; border: 2px solid var(--blue); border-radius: 10px; color: var(--blue); font-size: 17px; letter-spacing: .04em; }
.net-save { min-height: 44px; padding: 0 12px; border-radius: 10px; background: var(--blue); color: var(--bg); display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font-size: 17px; line-height: 1; letter-spacing: .04em; white-space: nowrap; }
.net-swap { width: 44px; height: 44px; flex: 0 0 44px; border-radius: 10px; background: var(--s2); display: flex; align-items: center; justify-content: center; }
.dots { display: inline-flex; gap: 4px; }
.dots i { width: 5px; height: 5px; border-radius: 50%; background: rgba(11, 15, 20, .3); }
.dots i.on { background: var(--bg); }
.mom { border: 1px solid var(--line); font-size: 18px; }

/* ---------- goal and save screens ---------- */
.mo { gap: 16px; }
.mo-card { flex: 1 1 auto; min-height: 360px; padding: 24px; border-radius: 28px; color: var(--bg); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; text-align: center; }
.mo-card.red { background: var(--red); }
.mo-card.blue { background: var(--blue); }
.mo-h { font-size: 108px; line-height: .9; letter-spacing: .02em; }
.mo-h.long { font-size: 80px; }
.mo-num { position: relative; margin-top: 8px; min-width: 120px; height: 120px; padding: 0 14px; border-radius: 26px; background: var(--bg); display: flex; align-items: center; justify-content: center; font-size: 76px; line-height: 1; }
.red .mo-num { color: var(--red); }
.blue .mo-num { color: var(--blue); }
.mo-num em { top: -8px; right: -8px; width: 30px; height: 30px; border-radius: 9px; background: var(--tx); font-size: 15px; }
.mo-name { max-width: 100%; font-size: 44px; line-height: 1; letter-spacing: .04em; text-transform: uppercase; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mo-under { font-size: 12px; font-weight: 600; letter-spacing: .12em; }
.mo-rule { width: 100%; height: 2px; margin: 6px 0; background: rgba(11, 15, 20, .2); }
.mo-song { max-width: 100%; display: flex; align-items: center; gap: 10px; text-align: left; }
.mo-song div { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mo-song b { font-size: 18px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mo-song span { font-size: 14px; }
.mo-prog { width: 100%; margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.mo-bar { height: 8px; border-radius: 4px; background: rgba(11, 15, 20, .22); overflow: hidden; }
#mo-fill { width: 0; height: 100%; border-radius: 4px; background: var(--bg); }
.mo-meta { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; font-weight: 500; }
.mo-pill { margin-top: 4px; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: rgba(11, 15, 20, .14); font-size: 13px; font-weight: 600; }
.mo-pill .dots i { width: 6px; height: 6px; }

/* ---------- setup ---------- */
.pill { align-self: flex-start; min-height: 44px; margin: -8px 0; padding: 0 2px; display: inline-flex; align-items: center; gap: 6px; color: var(--amber); font-size: 13px; font-weight: 600; }
.pill.ok { color: var(--blue); }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; padding: 4px; border-radius: 14px; background: var(--s1); }
.seg-b { min-height: 44px; border-radius: 10px; font-size: 14px; font-weight: 500; text-align: center; }
.seg-b.on { background: var(--tx); color: var(--bg); font-weight: 600; }
.prow, .lrow-main { width: 100%; min-width: 0; min-height: 60px; padding: 8px 12px; border-radius: 14px; background: var(--s1); display: flex; align-items: center; gap: 12px; text-align: left; }
.prow.tall { min-height: 76px; }
.prow > svg:last-child, .lrow-main > svg:last-child { color: var(--mu); }
.lrow { display: flex; align-items: stretch; gap: 6px; }
.lrow-main { flex: 1; }
.mini { width: 44px; flex: 0 0 44px; border-radius: 12px; background: var(--s1); display: flex; align-items: center; justify-content: center; }
.sq { position: relative; width: 44px; height: 44px; flex: 0 0 44px; border-radius: 12px; background: var(--s2); display: flex; align-items: center; justify-content: center; font-size: 22px; }
.sq.blue { color: var(--blue); }
.lrow-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.lrow-txt b { font-size: 15px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lrow-txt small { font-size: 13px; color: var(--mu); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lrow-txt small.warn { color: var(--amber); }
.tag { flex: 0 0 auto; padding: 4px 8px; border-radius: 8px; background: rgba(86, 194, 255, .14); color: var(--blue); font-size: 12px; font-weight: 600; white-space: nowrap; }
.tag.line { padding: 3px 8px; background: none; border: 1px solid var(--blue); }
.tag.on { background: var(--blue); color: var(--bg); }

/* ---------- "pick the best part" editor ---------- */
.cue { gap: 12px; }
.songcard { display: flex; align-items: center; gap: 12px; padding: 12px; }
.songcard b { font-size: 24px; line-height: 1.08; letter-spacing: 0; }
.ovwrap { display: flex; flex-direction: column; gap: 2px; }
.ovlab { display: flex; justify-content: space-between; font-size: 11px; font-weight: 600; letter-spacing: .08em; color: var(--mu); }
.ov { position: relative; height: 28px; touch-action: none; cursor: pointer; }
.ov::before { content: ''; position: absolute; left: 0; right: 0; top: 11px; height: 6px; border-radius: 3px; background: var(--line); }
.ov-clip { position: absolute; top: 11px; height: 6px; min-width: 3px; border-radius: 3px; background: var(--blue); }
.ov-ph { position: absolute; top: 4px; width: 3px; height: 20px; margin-left: -1px; border-radius: 2px; background: var(--red); }
.wave { position: relative; padding: 10px 12px; }
#cue-wave { display: block; width: 100%; height: 104px; touch-action: none; cursor: grab; }
.wave-ph { position: absolute; top: 4px; bottom: 4px; left: 50%; width: 2px; margin-left: -1px; background: var(--red); pointer-events: none; }
.wave-msg { position: absolute; left: 12px; right: 12px; bottom: 8px; padding: 2px 6px; border-radius: 6px; background: rgba(22, 28, 36, .88); color: var(--soft); font-size: 12px; text-align: center; pointer-events: none; }
.cue-plays { text-align: center; font-size: 14px; color: var(--soft); }
.cue-plays b { color: var(--tx); }
.cue-time { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.cue-time span { font-size: 48px; line-height: 1; letter-spacing: 0; }
.cue-time small { font-size: 11px; font-weight: 600; letter-spacing: .1em; color: var(--mu); }
.cue-ctl { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; }
.cue-ctl .btn { min-height: 58px; font-size: 21px; font-weight: 700; }
/* Save stays in reach at the bottom of the screen while the editor scrolls. */
.sticky { position: sticky; bottom: 0; z-index: 2; margin: auto -16px calc(-16px - env(safe-area-inset-bottom)); padding: 10px 16px calc(12px + env(safe-area-inset-bottom)); background: var(--bg); border-top: 1px solid var(--line); display: flex; flex-direction: column; }
.round { width: 64px; height: 64px; border-radius: 50%; background: var(--tx); color: var(--bg); display: flex; align-items: center; justify-content: center; }

/* ---------- sheets and toasts ---------- */
#overlay { display: none; }
#overlay.open { display: block; position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 20; }
.sheet-bg { position: absolute; top: 0; right: 0; bottom: 0; left: 0; background: rgba(4, 6, 9, .72); }
.sheet { position: absolute; left: 0; right: 0; bottom: 0; max-width: 460px; max-height: 92%; margin: 0 auto; padding: 20px 16px calc(16px + env(safe-area-inset-bottom)); overflow-y: auto; border-radius: 22px 22px 0 0; background: var(--s1); display: flex; flex-direction: column; gap: 10px; }
.sheet .card { background: var(--bg); }
#toast { position: fixed; top: calc(12px + env(safe-area-inset-top)); left: 16px; right: 16px; z-index: 30; max-width: 428px; margin: 0 auto; padding: 12px 16px; border-radius: 14px; background: var(--tx); color: var(--bg); font-size: 14px; font-weight: 500; text-align: center; opacity: 0; transform: translateY(-8px); transition: opacity .15s, transform .15s; pointer-events: none; }
#toast.show { opacity: 1; transform: none; }

@media (max-height: 720px) {
  .game { gap: 8px; }
  .game .bigbtn { min-height: 60px; flex-direction: row; gap: 8px; }
  .game .sec-t { display: none; }
  .tiles { --rows: var(--r6, 3); --rmin: 42px; --rgap: 6px; grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .tile b { font-size: 23px; }
  .mo-h { font-size: 84px; }
  .mo-h.long { font-size: 64px; }
  .mo-num { min-width: 96px; height: 96px; font-size: 60px; }
  .mo-card { min-height: 300px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
