/* Social Group Games — flat glass, mobile only (on a computer it opens as the same phone column) */
:root {
  --bg: #0B0A1A;
  --ink: #F5F4FF;
  --ink2: rgba(245, 244, 255, .68);
  --ink3: rgba(245, 244, 255, .42);
  --glass: rgba(255, 255, 255, .075);
  --glass2: rgba(255, 255, 255, .12);
  --edge: rgba(255, 255, 255, .14);
  --edge2: rgba(255, 255, 255, .26);
  --c: #8B5CF6;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", system-ui, Roboto, "Google Sans", "Segoe UI", sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: #06050F; color: var(--ink); font-family: var(--font); overflow: hidden; }
body { -webkit-font-smoothing: antialiased; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; overscroll-behavior: none; touch-action: manipulation; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
button:disabled { cursor: default; opacity: .4; }
[hidden] { display: none !important; }
input { -webkit-user-select: text; user-select: text; }

/* the phone column: full screen on a phone, a centered phone-width column on a computer */
.phone {
  position: relative; height: 100%; height: 100dvh; max-width: 440px; margin: 0 auto; overflow: hidden; isolation: isolate;
  background: linear-gradient(165deg, #221E44 0%, #14122B 45%, #0B0A1A 100%);
}
@media (min-width: 520px) { .phone { box-shadow: 0 0 0 1px rgba(255, 255, 255, .06); } }

/* glass + the iOS-style continuous corner (squircle where the browser has it, round elsewhere) */
.glass {
  background: var(--glass); border: 1px solid var(--edge);
  -webkit-backdrop-filter: blur(18px) saturate(150%); backdrop-filter: blur(18px) saturate(150%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .10);
}
.sq { border-radius: var(--r, 22px); }
@supports (corner-shape: squircle) { .sq { corner-shape: squircle; border-radius: calc(var(--r, 22px) * 1.7); } }
@media (prefers-reduced-transparency: reduce) { .glass { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(36, 33, 60, .94); } }

.scr { position: absolute; inset: 0; display: flex; flex-direction: column; }

/* ---------- home ---------- */
.home { padding-top: var(--safe-t); padding-bottom: var(--safe-b); }
.bar { height: 56px; flex: none; display: flex; align-items: center; justify-content: space-between; padding: 0 16px 0 18px; }
.brand { margin: 0; font-size: 19px; font-weight: 700; letter-spacing: -.01em; white-space: nowrap; }
.badge { --r: 13px; flex: none; width: 58px; height: 26px; font-size: 12px; font-weight: 700; letter-spacing: .02em; }
.badge.trial { visibility: hidden; }
.badge.free { color: var(--ink2); }
.badge.pro { color: #1A1206; background: linear-gradient(135deg, #FFD36E, #FFAE45); border-color: rgba(255, 220, 140, .7); }

.tiles { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: repeat(6, minmax(0, 1fr)); gap: 10px; padding: 2px 14px 4px; }
.tile {
  --r: 20px; position: relative; min-height: 0; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start;
  padding: 11px 13px 10px; text-align: left; overflow: hidden; color: var(--ink);
  background: linear-gradient(150deg, var(--c) 0%, var(--d) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35), 0 6px 18px -10px var(--d);
  transition: transform .14s ease, box-shadow .2s ease;
}
.tile::before { content: ""; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(180deg, rgba(255, 255, 255, .34), rgba(255, 255, 255, 0) 55%); pointer-events: none; }
.tile > * { position: relative; }
.tile:active { transform: scale(.965); }
.tile .ico { width: 32px; height: 32px; color: var(--ink); opacity: .9; flex: none; }
.tile .ico svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
.tile .nm { display: block; font-size: 15px; font-weight: 700; line-height: 1.15; letter-spacing: -.005em; }
.tile .left { display: block; font-size: 11.5px; font-weight: 700; opacity: .85; margin-top: 1px; }
.tile .left:empty { display: none; }
.tile .lock { position: absolute; top: 9px; right: 10px; width: 11px; height: 11px; opacity: 0; fill: none; stroke: var(--ink); stroke-width: 1.4; }
.tile.locked .lock { opacity: .45; }
.tile.today { box-shadow: 0 0 0 3px #fff, 0 8px 28px -6px var(--c), inset 0 1px 0 rgba(255, 255, 255, .35); }
@media (max-height: 620px) { .tile .ico { width: 24px; height: 24px; } .tile .nm { font-size: 14px; } .tiles { gap: 8px; } }

.foot { height: 44px; flex: none; display: flex; align-items: center; justify-content: center; gap: 7px; font-size: 12px; color: var(--ink3); padding: 0 10px; white-space: nowrap; }
.foot .ph { cursor: default; }
.foot a, .foot .link, .addr { color: var(--ink2); text-decoration: none; font-size: 12px; }
.addr { display: inline-flex; align-items: center; gap: 5px; }
.addr svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; }

/* ---------- game screen ---------- */
.game { background: radial-gradient(110% 70% at 50% -5%, color-mix(in srgb, var(--c) 50%, transparent), transparent 62%), radial-gradient(80% 50% at 50% 110%, color-mix(in srgb, var(--c) 22%, transparent), transparent 70%), var(--bg); }
.stage { position: absolute; inset: 0; padding: calc(var(--safe-t) + 50px) 18px calc(var(--safe-b) + 50px); display: flex; flex-direction: column; }
.cx { position: absolute; z-index: 5; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .12); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); touch-action: none; }
.cx.tl { top: calc(var(--safe-t) + 10px); left: 10px; } .cx.tr { top: calc(var(--safe-t) + 10px); right: 10px; }
.cx.bl { bottom: calc(var(--safe-b) + 10px); left: 10px; } .cx.br { bottom: calc(var(--safe-b) + 10px); right: 10px; }
.cx .x { width: 10px; height: 10px; fill: none; stroke: var(--ink2); stroke-width: 1.6; stroke-linecap: round; }

.gv { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 14px; }
.g-title { text-align: center; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink3); flex: none; }
.g-main { flex: 1; min-height: 0; display: flex; flex-direction: column; justify-content: flex-start; align-items: center; gap: 16px; text-align: center; overflow-y: auto; overflow-x: hidden; padding: 2px; scrollbar-width: none; }
.g-main::-webkit-scrollbar { display: none; }
.g-act { flex: none; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 10px; }
.g-act:empty { display: none; }
.g-kick { font-size: 14px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: color-mix(in srgb, var(--c) 45%, #fff); }
.g-h { margin: 0; font-size: 30px; font-weight: 750; letter-spacing: -.02em; }
.g-how { margin: 0; font-size: 16px; line-height: 1.45; color: var(--ink2); max-width: 330px; }
.g-note { margin: 0; font-size: 14px; color: var(--ink2); line-height: 1.4; }
.g-label { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink3); margin-bottom: -8px; }
.big-ico { width: 74px; height: 74px; color: color-mix(in srgb, var(--c) 50%, #fff); }
.big-ico svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.big { font-size: clamp(30px, 10vw, 46px); font-weight: 800; letter-spacing: -.02em; line-height: 1.08; overflow-wrap: anywhere; }
.huge { font-size: clamp(44px, 15vw, 72px); }
.letter { font-size: clamp(90px, 34vw, 150px); font-weight: 850; line-height: 1; color: color-mix(in srgb, var(--c) 35%, #fff); }

.card { --r: 26px; width: 100%; min-height: 150px; padding: 24px 22px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; font-size: 22px; font-weight: 650; line-height: 1.32; }
.card.xl { font-size: 25px; min-height: 210px; }
.card.tap { min-height: 220px; background: linear-gradient(145deg, color-mix(in srgb, var(--c) 26%, transparent), rgba(255, 255, 255, .05)); }
.card.tap.on { background: linear-gradient(145deg, color-mix(in srgb, var(--c) 46%, transparent), color-mix(in srgb, var(--c) 12%, transparent)); border-color: color-mix(in srgb, var(--c) 60%, #fff); }
.card-small { font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink2); }
.card-big { font-size: 26px; font-weight: 750; }
.card-note { font-size: 15px; font-weight: 500; color: var(--ink2); max-width: 290px; }

.btn { --r: 18px; height: 54px; padding: 0 10px; font-size: 17px; font-weight: 700; letter-spacing: -.005em; display: flex; align-items: center; justify-content: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: transform .12s ease, filter .12s ease; }
.btn:active { transform: scale(.97); }
.btn.ghost { background: var(--glass); border: 1px solid var(--edge); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.btn.pri { background: linear-gradient(180deg, rgba(255, 255, 255, .28), rgba(255, 255, 255, 0) 60%), linear-gradient(150deg, var(--c), var(--d, var(--c))); color: var(--ink, #15112B); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .4), 0 6px 16px -10px var(--d, var(--c)); }
.btn.pri:disabled { background: rgba(255, 255, 255, .14); color: var(--ink2); box-shadow: none; opacity: 1; }
.btn.warn { background: rgba(248, 113, 113, .22); border: 1px solid rgba(248, 113, 113, .5); color: #FFD5D5; }

.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; width: 100%; }
.bigbtn { --r: 26px; height: 170px; font-size: 26px; font-weight: 800; display: flex; align-items: center; justify-content: center; background: linear-gradient(150deg, color-mix(in srgb, var(--c) 40%, transparent), rgba(255, 255, 255, .05)); }
.bigbtn.alt { background: linear-gradient(150deg, rgba(56, 189, 248, .42), rgba(255, 255, 255, .05)); }
.bigbtn:active { transform: scale(.97); }

.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; max-width: 360px; }
.chip { --r: 18px; height: 36px; padding: 0 14px; font-size: 14px; font-weight: 650; }
.chip.on { background: linear-gradient(150deg, var(--c), var(--d, var(--c))); color: var(--ink, #15112B); border-color: transparent; }

.stepper { display: flex; align-items: center; gap: 14px; }
.stepper .slab { font-size: 15px; color: var(--ink2); margin-right: 4px; }
.stepper .sbtn { --r: 14px; width: 44px; height: 44px; font-size: 22px; font-weight: 600; }
.stepper .snum { min-width: 40px; font-size: 28px; font-weight: 800; }

.toggle { display: flex; align-items: center; gap: 12px; font-size: 15px; color: var(--ink2); }
.toggle .sw { width: 50px; height: 30px; border-radius: 15px; background: rgba(255, 255, 255, .16); position: relative; transition: background .2s; }
.toggle .sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; transition: transform .2s; }
.toggle.on .sw { background: linear-gradient(150deg, var(--c), var(--d, var(--c))); } .toggle.on .sw::after { transform: translateX(20px); }

.tbar { width: 100%; height: 6px; border-radius: 3px; background: rgba(255, 255, 255, .12); overflow: hidden; flex: none; }
.tbar i { display: block; height: 100%; transition: transform .1s linear; background: linear-gradient(90deg, var(--c), var(--d, var(--c))); transform-origin: left center; }
.ring { position: relative; width: 120px; height: 120px; flex: none; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 8; stroke-linecap: round; }
.ring .rt { stroke: rgba(255, 255, 255, .12); } .ring .rp { stroke: var(--c); }
.ring .rn { position: absolute; inset: 0; display: grid; place-items: center; font-size: 36px; font-weight: 800; }

.list { --r: 20px; width: 100%; padding: 8px 14px; text-align: left; max-height: 240px; overflow-y: auto; }
.li { padding: 9px 2px; font-size: 16px; font-weight: 600; border-bottom: 1px solid rgba(255, 255, 255, .07); display: flex; justify-content: space-between; gap: 10px; }
.li:last-child { border-bottom: 0; }
.li.ok::after { content: "\2713"; color: #4ADE80; } .li.no { color: var(--ink3); }
.li.dead { color: var(--ink3); text-decoration: line-through; }
.li .k { color: var(--ink2); font-weight: 500; }
.kv { display: flex; justify-content: space-between; width: 100%; gap: 12px; font-size: 18px; } .kv .k { color: var(--ink2); font-weight: 500; } .kv .v { font-weight: 750; }

.grid-n { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; width: 100%; }
.num { --r: 16px; height: 58px; font-size: 22px; font-weight: 800; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; }
.num .ls { font-size: 9px; letter-spacing: 1.5px; font-weight: 600; opacity: .75; }
.num:active { transform: scale(.95); }
.num.dead { text-decoration: line-through; }
.num.sel { background: linear-gradient(150deg, var(--c), var(--d, var(--c))); color: var(--ink, #15112B); }

.opt { --r: 24px; width: 100%; padding: 22px 18px; font-size: 21px; font-weight: 700; line-height: 1.3; position: relative; transition: transform .12s; }
.opt.a { background: linear-gradient(145deg, color-mix(in srgb, var(--c) 34%, transparent), rgba(255, 255, 255, .04)); }
.opt.b { background: linear-gradient(145deg, rgba(251, 146, 60, .34), rgba(255, 255, 255, .04)); }
.opt .cnt { position: absolute; top: 8px; right: 12px; font-size: 13px; font-weight: 800; opacity: .8; }
.opt:active { transform: scale(.98); }
.or { font-size: 13px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--ink3); margin: -6px 0; }
.split { width: 100%; display: flex; height: 40px; border-radius: 14px; overflow: hidden; font-size: 14px; font-weight: 800; }
.split div { display: grid; place-items: center; min-width: 0; transition: flex .4s; }
.split .sa { background: linear-gradient(150deg, var(--c), var(--d, var(--c))); color: var(--ink, #15112B); } .split .sb { background: #FB923C; color: #1A0E04; }

.cats { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.cat { --r: 14px; padding: 9px 14px; font-size: 16px; font-weight: 700; }

.tcard { --r: 26px; width: 100%; overflow: hidden; }
.tcard .tw { padding: 22px 16px; font-size: 32px; font-weight: 850; background: color-mix(in srgb, var(--c) 40%, transparent); }
.tcard .tf { padding: 12px 16px 16px; display: grid; gap: 4px; }
.tcard .tfi { font-size: 19px; font-weight: 600; color: #FFC7C7; padding: 3px 0; }
.score { display: flex; gap: 10px; width: 100%; }
.sc { --r: 18px; flex: 1; padding: 12px; } .sc.on { border-color: var(--c); box-shadow: 0 0 0 1px var(--c); }
.sc-t { font-size: 13px; font-weight: 700; color: var(--ink2); } .sc-n { font-size: 30px; font-weight: 850; }

.bomb { width: 120px; height: 120px; color: #FCA5A5; transition: transform .1s; }
.bomb svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.bomb.pulse { transform: scale(1.08); }

.canvas { --r: 22px; flex: 1; width: 100%; min-height: 0; background: #FBFAF7; overflow: hidden; touch-action: none; position: relative; }
.canvas canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; }
.tools { display: flex; gap: 8px; justify-content: center; align-items: center; flex: none; }
.dotc { width: 32px; height: 32px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .25); }
.dotc.on { border-color: #fff; box-shadow: 0 0 0 2px var(--c); }
.tool { --r: 12px; height: 34px; padding: 0 12px; font-size: 13px; font-weight: 700; }
.gv.draw .g-main { justify-content: flex-start; align-items: stretch; overflow: hidden; gap: 10px; }

.gv.night { --c: #818CF8; }
.flash-ok .g-main { animation: fok .6s ease; } .flash-no .g-main { animation: fno .6s ease; }
@keyframes fok { 0% { background: rgba(74, 222, 128, .35); } 100% { background: transparent; } }
@keyframes fno { 0% { background: rgba(251, 146, 60, .35); } 100% { background: transparent; } }
.boom .g-main { animation: boom .9s ease; }
@keyframes boom { 0% { background: rgba(255, 90, 95, .8); transform: scale(1.04); } 100% { background: transparent; transform: none; } }
.pop { animation: pop .35s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- sheet (Pro, today's pick) ---------- */
.sheet { position: absolute; inset: 0; z-index: 40; display: flex; align-items: flex-end; background: rgba(4, 3, 12, .55); animation: fade .2s ease; }
.sheet .panel { --r: 30px; position: relative; width: 100%; padding: 26px 20px calc(var(--safe-b) + 20px); background: rgba(24, 21, 44, .97); border-bottom: 0; border-bottom-left-radius: 0; border-bottom-right-radius: 0; animation: up .28s cubic-bezier(.2, .9, .3, 1); display: flex; flex-direction: column; }
.sx { position: absolute; top: 12px; right: 12px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .08); }
.sx svg { width: 10px; height: 10px; fill: none; stroke: var(--ink2); stroke-width: 1.6; stroke-linecap: round; }
.sh-h { margin: 0 0 4px; font-size: 24px; font-weight: 800; letter-spacing: -.02em; }
.sh-p { margin: 0 0 16px; font-size: 15px; color: var(--ink2); line-height: 1.45; }
.sh-price { font-size: 40px; font-weight: 850; letter-spacing: -.02em; margin: 4px 0 2px; }
.sh-price small { font-size: 16px; font-weight: 600; color: var(--ink2); }
.sh-col { display: grid; gap: 10px; }
.field { --r: 16px; width: 100%; height: 54px; padding: 0 16px; font-size: 17px; background: rgba(255, 255, 255, .08); border: 1px solid var(--edge); outline: none; }
.field:focus { border-color: var(--edge2); }
.sh-line { font-size: 14px; color: #FFC7A0; min-height: 0; margin: 2px 0 0; }
.sh-small { font-size: 13px; color: var(--ink3); margin: 12px 0 0; text-align: center; line-height: 1.4; }

.sheet .btn.pay { background: #FFC439; color: #111; }
@keyframes up { from { transform: translateY(100%); } to { transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.toast { --r: 18px; position: absolute; left: 50%; bottom: calc(var(--safe-b) + 58px); transform: translateX(-50%); z-index: 70; padding: 11px 18px; font-size: 14px; font-weight: 600; white-space: nowrap; max-width: 92%; overflow: hidden; text-overflow: ellipsis; animation: fade .2s; background: rgba(40, 36, 66, .9); }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

/* pause + sound row, pause cover */
.g-ctl { flex: none; display: flex; justify-content: center; gap: 10px; margin-top: -6px; }
.ctl { --r: 14px; width: 40px; height: 34px; display: grid; place-items: center; }
.ctl svg { width: 18px; height: 18px; fill: none; stroke: var(--ink2); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.pausecv { position: absolute; inset: -4px; z-index: 6; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px; background: rgba(11, 10, 26, .82); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); border-radius: 24px; animation: fade .15s; }
.pausecv .btn { width: 200px; }
/* names, QR */
.names { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; max-height: 46vh; overflow-y: auto; margin-bottom: 12px; }
.names .field { height: 46px; font-size: 16px; }
.mini { --r: 12px; height: 32px; padding: 0 12px; font-size: 13px; font-weight: 700; color: var(--ink2); }
.qr { align-self: center; padding: 12px; background: #fff; border-radius: 22px; margin: 4px 0 2px; }
.qr img { display: block; width: 220px; height: 220px; }
/* score rows (Name–Place–Animal–Thing) */
.srows { width: 100%; display: grid; gap: 8px; }
.srow { --r: 16px; display: flex; align-items: center; justify-content: space-between; padding: 8px 10px 8px 14px; gap: 10px; }
.srow .nm { font-size: 16px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; flex: 1; }
.srow .tot { font-size: 12px; color: var(--ink3); margin-left: 6px; font-weight: 600; }
.srow .pts { min-width: 34px; text-align: center; font-size: 20px; font-weight: 800; }
.srow .sbtn { --r: 12px; width: 38px; height: 38px; font-size: 20px; font-weight: 700; }
.num .nmx { font-size: 14px; font-weight: 750; max-width: 100%; padding: 0 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.spicy { display: flex; align-items: center; gap: 8px; }
.spicy .tag { font-size: 11px; font-weight: 800; letter-spacing: .06em; padding: 3px 7px; border-radius: 8px; background: linear-gradient(150deg, #FCD34D, #F59E0B); color: #15112B; }

/* --- v4 fixes (review) --- */
.g-main::before, .g-main::after { content: ""; flex: 1 0 0; min-height: 0; }   /* centers when there is room, never pushes the top out of view */
.gv { animation: fadeup .16s ease-out; }
@keyframes fadeup { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (max-height: 700px) {
  .big-ico { display: none; }
  .g-how { font-size: 14px; line-height: 1.4; }
  .g-main { gap: 10px; }
  .g-h { font-size: 25px; }
  .card.xl { font-size: 22px; }
  /* Home: tiles become a row (icon beside the name) so nothing is clipped */
  .tile { flex-direction: row; align-items: center; justify-content: flex-start; gap: 9px; padding: 8px 10px; }
  .tile .ico { width: 22px; height: 22px; }
  .tile .nm { font-size: 13.5px; }
  .tile .left { font-size: 11px; }
  .tile .lock { top: 6px; right: 7px; }
  .bar { height: 50px; } .foot { height: 40px; }
}
/* 2. no pink anywhere */
.tcard .tfi { color: #FCD34D; }
.btn.warn { background: rgba(249, 115, 22, .2); border-color: rgba(249, 115, 22, .55); color: #FDBA74; }
.bomb { color: #FB923C; }
.g-kick { color: var(--kick, color-mix(in srgb, var(--c) 45%, #fff)); }
@keyframes boom { 0% { background: rgba(249, 115, 22, .85); transform: scale(1.04); } 100% { background: transparent; transform: none; } }
/* 4. game cards carry the Home tile look */
.card, .opt.a, .num.sel, .tcard .tw {
  background: linear-gradient(180deg, rgba(255, 255, 255, .26), rgba(255, 255, 255, 0) 55%), linear-gradient(150deg, var(--c), var(--d, var(--c)));
  color: var(--ink, #15112B); border-color: rgba(255, 255, 255, .28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35), 0 10px 26px -16px var(--d, var(--c));
}
.card.tap, .card.tap.on { background: linear-gradient(180deg, rgba(255, 255, 255, .26), rgba(255, 255, 255, 0) 55%), linear-gradient(150deg, var(--c), var(--d, var(--c))); }
.card .card-small, .card .card-note { color: var(--ink, #15112B); opacity: .72; }
.opt.b { background: linear-gradient(180deg, rgba(255, 255, 255, .26), rgba(255, 255, 255, 0) 55%), linear-gradient(150deg, #FDBA74, #EA580C); color: #15112B; border-color: rgba(255, 255, 255, .28); }
.card.xl { font-size: 27px; min-height: 36vh; }
.gv.night .card { --c: #818CF8; --d: #4338CA; --ink: #fff; }
/* 5. bigger controls, more room above the bottom corners */
.ctl { width: 44px; height: 44px; }
.stage { padding-bottom: calc(var(--safe-b) + 62px); }
/* 6. toast wraps */
.toast { white-space: normal; text-align: center; max-width: 86%; width: max-content; line-height: 1.35; }
/* 7. Heads Up: huge word, full-screen flash */
.hu-word { font-size: clamp(50px, 19vw, 104px); line-height: 1.02; font-weight: 850; letter-spacing: -.02em; overflow-wrap: break-word; hyphens: none; }
.game::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; z-index: 4; }
.game.fl-ok::after { background: #22C55E; animation: flash .4s ease-out; }
.game.fl-no::after { background: #F97316; animation: flash .4s ease-out; }
@keyframes flash { from { opacity: .92; } to { opacity: 0; } }
/* Pro sheet: perks, restore link */
.perks { list-style: none; margin: 2px 0 14px; padding: 0; display: grid; gap: 6px; }
.perks li { font-size: 15px; font-weight: 600; color: var(--ink); padding-left: 24px; position: relative; }
.perks li::before { content: ""; position: absolute; left: 2px; top: 5px; width: 12px; height: 7px; border-left: 2.5px solid var(--c); border-bottom: 2.5px solid var(--c); transform: rotate(-45deg); }
.restore { font-size: 13px; color: var(--ink2); text-decoration: underline; padding: 6px 0 0; }
#sheet-body { --c: #FCD34D; --d: #F59E0B; --ink: #15112B; display: flex; flex-direction: column; }
#sheet-body .perks li, #sheet-body .sh-h, #sheet-body .sh-price { color: #F5F4FF; }
.panel { outline: none; transition: transform .2s ease; }

/* language picker */
#lang { display: inline-flex; align-items: center; gap: 4px; font-weight: 700; letter-spacing: .02em; }
#lang svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.3; }
.langpop { --r: 20px; position: absolute; z-index: 60; right: 10px; bottom: calc(var(--safe-b) + 46px); width: 230px; max-height: 58vh; overflow-y: auto; padding: 6px; background: rgba(26, 23, 46, .97); animation: fade .15s; }
.lang-opt { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 12px; border-radius: 12px; font-size: 15px; color: var(--ink); text-align: left; }
.lang-opt.on { background: rgba(255, 255, 255, .12); font-weight: 700; }
.lang-opt .lang-code { font-size: 11px; font-weight: 700; color: var(--ink3); letter-spacing: .06em; }
[dir="rtl"] .lang-opt, [dir="rtl"] .foot, [dir="rtl"] .bar { direction: rtl; }
[dir="rtl"] .tile, [dir="rtl"] .srow .nm, [dir="rtl"] .list, [dir="rtl"] .g-main { text-align: right; }
[dir="rtl"] .tile { align-items: flex-end; }
[dir="rtl"] .tile .lock { right: auto; left: 10px; }
[dir="rtl"] .bar { padding: 0 18px 0 16px; }
[dir="rtl"] .sx { right: auto; left: 12px; }
[dir="rtl"] .perks li { padding-left: 0; padding-right: 24px; }
[dir="rtl"] .perks li::before { left: auto; right: 2px; }
[dir="rtl"] .langpop { right: auto; left: 10px; }

/* the footer never pushes past the edge on a narrow phone */
.foot { gap: 6px; min-width: 0; }
.addr { min-width: 0; overflow: hidden; text-overflow: ellipsis; flex: 0 1 auto; }
.foot a, .foot .link { flex: none; }
@media (max-width: 380px) { .foot { font-size: 11px; gap: 5px; padding: 0 8px; } .foot a, .foot .link, .addr { font-size: 11px; } .addr svg { width: 12px; height: 12px; } }

/* ---------- Home restyle: logo header, glow, colour art, arrows, footer pill ---------- */
.home { background: radial-gradient(120% 55% at 100% 0%, rgba(99, 102, 241, .38), transparent 60%), radial-gradient(90% 45% at 0% 100%, rgba(168, 85, 247, .30), transparent 65%), radial-gradient(70% 40% at 0% 30%, rgba(34, 211, 238, .10), transparent 70%), linear-gradient(170deg, #1A1640 0%, #0D0B22 55%, #070614 100%); }
.bar { height: 68px; padding: 0 14px 0 14px; gap: 10px; }
.brandbox { display: flex; align-items: center; gap: 10px; min-width: 0; }
.logo { width: 44px; height: 44px; flex: none; filter: drop-shadow(0 0 10px rgba(168, 85, 247, .55)); }
.logo svg { width: 100%; height: 100%; display: block; overflow: visible; }
.btx { min-width: 0; }
.brand { font-size: 21px; font-weight: 800; letter-spacing: -.015em; line-height: 1.1; background: linear-gradient(90deg, #FFFFFF 0%, #FFFFFF 52%, #C4B5FD 72%, #A78BFA 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tagline { margin: 2px 0 0; font-size: 12.5px; font-style: italic; font-weight: 500; color: var(--ink2); letter-spacing: .01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile { color: #fff; padding: 8px 10px 10px 12px; background: linear-gradient(180deg, var(--hc) 0%, var(--hd) 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .5), inset 0 -3px 0 rgba(0, 0, 0, .14), 0 10px 24px -12px var(--hd), 0 0 0 1px rgba(255, 255, 255, .12); }
.tile::before { background: linear-gradient(180deg, rgba(255, 255, 255, .42), rgba(255, 255, 255, 0) 48%); }
.tile .ico.art { flex: 1 1 auto; width: auto; height: auto; min-height: 30px; max-height: 64px; aspect-ratio: 1 / 1; opacity: 1; align-self: center; filter: drop-shadow(0 4px 5px rgba(0, 0, 0, .28)); }
.tile .ico.art svg { display: block; width: 100%; height: 100%; fill: none; stroke: none; overflow: visible; }
.tile .tx { display: block; flex: none; width: 100%; padding-right: 27px; }
.tile .nm { color: #fff; font-size: 15px; font-weight: 800; text-shadow: 0 1px 2px rgba(0, 0, 0, .35); }
.tile .left { color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, .3); }
.tile .lock { stroke: #fff; }
.tile .go { position: absolute; right: 8px; bottom: 9px; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .26); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .6); }
.tile .go svg { width: 14px; height: 14px; fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.foot { margin: 0 12px calc(6px + var(--safe-b)); height: 40px; border-radius: 20px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .12); }
.home { padding-bottom: 0; }
@media (max-width: 380px) { .brand { font-size: 19px; } .tagline { font-size: 11.5px; } .logo { width: 38px; height: 38px; } }
@media (max-height: 700px) {
  .bar { height: 56px; } .logo { width: 34px; height: 34px; } .brand { font-size: 18px; } .tagline { font-size: 11px; margin-top: 1px; }
  .tile { padding: 7px 9px; }
  .tile .ico.art { flex: none; width: 34px; height: 34px; min-height: 0; max-height: none; align-self: center; }
  .tile .tx { padding-right: 0; width: auto; flex: 1 1 auto; min-width: 0; }
  .tile .nm { font-size: 13.5px; }
  .tile .go { display: none; }
  .tile .nm { hyphens: auto; -webkit-hyphens: auto; }
  .foot { height: 36px; margin-bottom: calc(5px + var(--safe-b)); }
}
[dir="rtl"] .tile .tx { padding-right: 0; padding-left: 30px; }
[dir="rtl"] .tile .go { right: auto; left: 9px; }
[dir="rtl"] .tile .go svg { transform: scaleX(-1); }
@media (max-height: 700px) { [dir="rtl"] .tile { padding: 7px 9px; align-items: center; } [dir="rtl"] .tile .tx { padding-left: 0; } }

/* game intro: the same colour art as the Home tile, on its own colour badge */
.big-ico.art { --r: 24px; width: 88px; height: 88px; padding: 11px; position: relative; overflow: hidden; background: linear-gradient(180deg, var(--hc), var(--hd)); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .5), 0 12px 30px -12px var(--hd), 0 0 0 1px rgba(255, 255, 255, .12); }
.big-ico.art::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(255, 255, 255, .4), rgba(255, 255, 255, 0) 50%); pointer-events: none; }
.big-ico.art svg { position: relative; fill: none; stroke: none; overflow: visible; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .25)); }

.sh-spam { margin-top: -4px; font-size: 13px; color: var(--ink3); }
/* price: the big amount, then "/ month · cancel anytime" wraps as one tidy block beside or under it */
.sh-price { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 6px; row-gap: 2px; line-height: 1.05; }
.sh-price small { flex: 1 1 140px; min-width: 0; line-height: 1.3; }
