/* איפה בכנרת? — design system
   Ground: cool paper-white. Ink: deep navy. One accent: lake blue.
   The photo and the map are the colour; the interface stays neutral around them. */
@font-face { font-family: "Heebo"; src: url("fonts/Heebo.ttf") format("truetype"); font-weight: 100 900; font-display: swap; }

:root {
  --bg: #f3f5f8; --surface: #fff; --surface-2: #f6f8fb; --line: #e1e6ed; --line-2: #cdd5e0;
  --ink: #0f1b2d; --ink-2: #3a4a61; --ink-3: #5b6a80;
  --accent: #0b5bd3; --accent-press: #094aac; --accent-tint: #e8f0fd; --accent-lip: #083f94; --accent-on-dark: #8cb9ff;
  --navy: #0b1522; --navy-2: #131f31; --navy-line: #263650;
  --great: #0b8f55; --good: #5d9a0a; --mid: #cf8200; --low: #d43549;
  --great-t: #e4f6ec; --good-t: #eef6dc; --mid-t: #fdf0d6; --low-t: #fbe4e7;
  --gold: #a96f00; --gold-bright: #f2b01e;
  --r-sm: 10px; --r: 14px; --r-lg: 20px;
  --sh-1: 0 1px 2px rgba(0, 0, 0, .07), 0 6px 14px -8px rgba(0, 0, 0, .14);
  --sh-2: 0 10px 28px -10px rgba(0, 0, 0, .34), 0 2px 6px rgba(0, 0, 0, .1);
  --ease: cubic-bezier(.23, 1, .32, 1);
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; accent-color: var(--accent); scrollbar-color: #b7c2d1 transparent; scrollbar-width: thin; }
body { margin: 0; background: var(--bg) linear-gradient(180deg, #d3e8ff 0, #e8f2ff 240px, var(--bg) 560px) no-repeat; color: var(--ink); font: 400 16px/1.5 "Heebo", system-ui, sans-serif; min-height: 100dvh; text-rendering: optimizeLegibility; font-feature-settings: "tnum" 1; }
::selection { background: rgba(11, 91, 211, .22); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
a { color: var(--accent); text-underline-offset: .18em; text-decoration-thickness: 1px; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; letter-spacing: -.012em; }
p { text-wrap: pretty; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
button:disabled { cursor: default; }
input { caret-color: var(--accent); }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--ink-3); }
.small { font-size: 14px; }
.center { text-align: center; }
.grow { flex: 1; min-width: 0; }

.i { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.gl { width: 15px; height: 15px; flex: none; fill: currentColor; fill-opacity: .16; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; color: var(--gold); margin-inline-end: 4px; vertical-align: -2px; }
.spinner { width: 26px; height: 26px; border-radius: 50%; border: 3px solid var(--line-2); border-top-color: var(--accent); animation: spin .8s linear infinite; display: block; }
@keyframes spin { to { transform: rotate(360deg); } }
.boot { min-height: 100dvh; display: grid; place-items: center; }

/* ---------- pages ---------- */
.page { max-width: 520px; margin: 0 auto; padding: calc(14px + var(--safe-t)) 18px calc(104px + var(--safe-b)); }
.page > * { animation: rise .5s var(--ease) backwards; }
.page > :nth-child(2) { animation-delay: 40ms; } .page > :nth-child(3) { animation-delay: 80ms; }
.page > :nth-child(4) { animation-delay: 120ms; } .page > :nth-child(5) { animation-delay: 160ms; } .page > :nth-child(n+6) { animation-delay: 200ms; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
.page > * + * { margin-top: 16px; }
.bar { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; min-height: 44px; margin-bottom: 8px; }
.bar h1 { font-size: 19px; font-weight: 700; text-align: center; }
.iconbtn { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; color: var(--ink); text-decoration: none; transition: transform .16s var(--ease), background-color .16s; }
.iconbtn:active { transform: scale(.94); }
@media (hover: hover) and (pointer: fine) { .iconbtn:hover { background: rgba(15, 27, 45, .06); } }
.section-title { font-size: 13px; font-weight: 600; color: var(--ink-3); margin: 28px 4px 8px; letter-spacing: .01em; }

/* ---------- buttons ---------- */
.btn { --lip: var(--accent-lip); display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 54px; padding: 0 20px; border-radius: 16px; background: var(--accent); color: #fff; font-weight: 800; font-size: 17px; text-decoration: none; text-align: center; box-shadow: 0 4px 0 var(--lip); transition: transform .12s var(--ease), box-shadow .12s var(--ease), background-color .16s, opacity .16s; user-select: none; }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--lip); background: var(--accent-press); }
.btn:disabled { opacity: .45; box-shadow: 0 4px 0 var(--lip); }
.btn.busy { opacity: .7; pointer-events: none; }
.btn.ghost { --lip: #c3ccd9; background: var(--surface); color: var(--ink); }
.btn.ghost:active { background: var(--surface-2); }
.btn.light { --lip: rgba(0, 0, 0, .22); background: #fff; color: #0b1c33; }
.btn.light:active { background: #e8eef8; }
.btn.wa { --lip: #0a5a2b; background: #12803f; }
.btn.wa:active { background: #0e6a34; }
.btn.compact { width: auto; min-height: 44px; padding: 0 16px; font-size: 16px; border-radius: 13px; }
.btn .coin { width: 20px; height: 20px; }
.btn-row { display: grid; gap: 10px; }
@media (hover: hover) and (pointer: fine) { .btn:hover { filter: brightness(1.05); } }

/* ---------- surfaces ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh-1); padding: 18px; }
.group { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh-1); overflow: hidden; }
.row { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 12px 16px; color: var(--ink); text-decoration: none; transition: background-color .16s; }
.row + .row { box-shadow: inset 0 1px 0 var(--line); }
a.row:active { background: var(--surface-2); }
@media (hover: hover) and (pointer: fine) { a.row:hover { background: var(--surface-2); } }
.row .ico { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--accent-tint); color: var(--accent); flex: none; }
.row .t { font-weight: 600; font-size: 16.5px; line-height: 1.25; }
.row .s { font-size: 14px; color: var(--ink-3); line-height: 1.3; }
.row .go { color: var(--line-2); width: 20px; height: 20px; }
.row .end { font-weight: 700; font-variant-numeric: tabular-nums; }
.row .end.gold { color: var(--gold); }

/* ---------- tab bar ---------- */
.tabbar { position: fixed; inset-inline: 0; bottom: 0; z-index: 10; background: rgba(255, 255, 255, .96); box-shadow: 0 -1px 0 var(--line); padding-bottom: var(--safe-b); }
.tabbar nav { max-width: 520px; margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); }
.tabbar a { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 7px; color: var(--ink-3); text-decoration: none; font-size: 12px; font-weight: 600; transition: color .16s, transform .16s var(--ease); }
.tabbar a:active { transform: scale(.94); }
.tabbar a[aria-current] { color: var(--accent); }

/* ---------- identity ---------- */
.av { --s: 44px; width: var(--s); height: var(--s); border-radius: 50%; display: inline-grid; place-items: center; flex: none; font-weight: 800; font-size: calc(var(--s) * .42); line-height: 1; color: #fff; background: #5d6f8a; user-select: none; }
.av.t2 { background: var(--accent); }
.av.t3 { background: var(--navy); box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--gold-bright); }
.av.t4 { background: linear-gradient(145deg, #7a5200, #d99a00 55%, #f6cf5a); color: #fff; box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--gold-bright); }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 99px; background: var(--surface); box-shadow: var(--sh-1); font-weight: 700; font-size: 14.5px; font-variant-numeric: tabular-nums; }
.chip .i { width: 17px; height: 17px; }
.chip.gold { color: var(--gold); }
.chip.on-dark { background: rgba(255, 255, 255, .14); color: #fff; box-shadow: none; }
.xp { height: 5px; border-radius: 4px; background: var(--line); overflow: hidden; }
.xp i { display: block; height: 100%; border-radius: 4px; background: var(--accent); transform-origin: right; animation: grow .8s var(--ease) .2s backwards; }
@keyframes grow { from { transform: scaleX(0); } }

/* ---------- login ---------- */
.welcome { margin: calc(-14px - var(--safe-t)) -18px 0; padding: calc(52px + var(--safe-t)) 24px 40px; color: #fff; background: linear-gradient(180deg, rgba(8, 21, 40, .55), rgba(8, 21, 40, .92)), url("map.webp") 34% 52% / 330% auto; border-radius: 0 0 28px 28px; }
.welcome h1 { font-size: 40px; font-weight: 800; line-height: 1.05; letter-spacing: -.025em; }
.welcome p { margin-top: 10px; color: #cfdcf0; font-size: 17px; max-width: 26ch; }
.brandmark { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; margin-bottom: 36px; }
.brandmark .mk { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: #fff; color: var(--accent); }
.brandmark .mk .i { width: 22px; height: 22px; stroke-width: 2; fill: currentColor; fill-opacity: .12; }
.field label { display: block; font-size: 14px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.field input { width: 100%; height: 52px; padding: 0 16px; border-radius: var(--r); border: 0; box-shadow: inset 0 0 0 1.5px var(--line-2); background: var(--surface); font-size: 17px; transition: box-shadow .16s; }
.field input:focus { outline: 0; box-shadow: inset 0 0 0 2px var(--accent); }
.or { display: flex; align-items: center; gap: 12px; color: var(--ink-3); font-size: 13px; margin: 18px 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.gbox { display: flex; justify-content: center; min-height: 44px; }
.gbox .btn { margin: 0; }

/* ---------- home ---------- */
.masthead { display: flex; align-items: center; justify-content: space-between; min-height: 40px; }
.masthead .brandmark { margin: 0; font-size: 19px; color: var(--ink); }
.masthead .brandmark .mk { background: var(--accent); color: #fff; }
.me { display: flex; align-items: center; gap: 14px; }
.me .grow { display: grid; gap: 5px; }
.me b { font-size: 18px; font-weight: 700; line-height: 1.1; display: flex; align-items: center; }
.me .rk { font-size: 13.5px; color: var(--ink-3); }
.hero { position: relative; overflow: hidden; border-radius: var(--r-lg); padding: 22px 20px 20px; color: #fff; background: linear-gradient(100deg, rgba(8, 21, 40, .93) 30%, rgba(8, 21, 40, .38)), url("map.webp") 34% 44% / 300% auto; box-shadow: var(--sh-2); min-height: 232px; display: flex; flex-direction: column; }
.hero .date { font-size: 14px; font-weight: 500; color: #b9cbe6; }
.hero h2 { font-size: 31px; font-weight: 800; line-height: 1.08; margin-top: 4px; letter-spacing: -.02em; }
.hero .sub { color: #cfdcf0; font-size: 15px; margin-top: 8px; max-width: 28ch; }
.hero .foot { margin-top: auto; padding-top: 22px; display: flex; align-items: center; gap: 12px; }
.hero .btn { flex: 1; }
.hero .result { font-size: 13px; color: #b9cbe6; line-height: 1.25; }
.hero .result b { display: block; font-size: 22px; color: #fff; font-weight: 800; }

/* ---------- segmented control ---------- */
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 3px; padding: 3px; border-radius: 12px; background: #e6eaf0; }
.seg a { display: grid; place-items: center; min-height: 40px; border-radius: 9px; color: var(--ink-2); font-weight: 600; font-size: 15px; text-decoration: none; transition: background-color .2s var(--ease), color .2s, box-shadow .2s; }
.seg a[aria-current] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(15, 27, 45, .14); }
.seg.sm a { min-height: 34px; font-size: 14px; }

/* ---------- leaderboard ---------- */
.lb .row { min-height: 60px; }
.rank-n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 14px; color: var(--ink-3); flex: none; font-variant-numeric: tabular-nums; }
.rank-n.p1 { background: #f6cf5a; color: #5a3b00; } .rank-n.p2 { background: #d9dee6; color: #3a4658; } .rank-n.p3 { background: #e8b78a; color: #5a2f10; }
.lb .me-row { background: var(--accent-tint); }
.lb .name { display: flex; align-items: center; font-weight: 600; }
.empty { padding: 36px 20px; text-align: center; color: var(--ink-3); }

/* ---------- profile ---------- */
.profile-head { display: flex; align-items: center; gap: 16px; }
.profile-head h2 { font-size: 24px; font-weight: 800; display: flex; align-items: center; }
.profile-head .rk { color: var(--ink-3); font-size: 14.5px; margin-bottom: 8px; }
.dl > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 12px 16px; }
.dl > div + div { box-shadow: inset 0 1px 0 var(--line); }
.dl dt { color: var(--ink-2); font-size: 15px; }
.dl dd { margin: 0; font-weight: 700; font-size: 16px; font-variant-numeric: tabular-nums; }
.dl { margin: 0; }
.ach { display: flex; align-items: center; gap: 14px; padding: 12px 16px; }
.ach + .ach { box-shadow: inset 0 1px 0 var(--line); }
.ach .ico { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: #eef1f6; color: var(--ink-3); flex: none; }
.ach.got .ico { background: #fbefd0; color: var(--gold); }
.ach .t { font-weight: 600; line-height: 1.25; } .ach .s { font-size: 13.5px; color: var(--ink-3); }
.ach:not(.got) .t { color: var(--ink-2); }
.ach .rw { font-size: 13px; font-weight: 700; color: var(--ink-3); display: flex; align-items: center; gap: 4px; }
.ach .rw .i { width: 15px; height: 15px; }
.ach.got .rw { color: var(--gold); }

/* ---------- shop ---------- */
.banner { display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: var(--r-lg); color: #fff; background: linear-gradient(120deg, #0b2a5c, #0b5bd3); box-shadow: var(--sh-2); }
.banner .ico { width: 52px; height: 52px; border-radius: 14px; background: rgba(255, 255, 255, .14); display: grid; place-items: center; flex: none; transition: transform .3s var(--ease); }
.banner .ico .i { width: 28px; height: 28px; }
.banner .ico.shake { animation: shake .55s var(--ease); }
@keyframes shake { 20% { transform: rotate(-12deg) scale(1.1); } 50% { transform: rotate(10deg) scale(1.12); } 80% { transform: rotate(-6deg); } }
.banner b { display: block; font-size: 17px; } .banner span { display: block; font-size: 13px; color: #c3d6f5; line-height: 1.35; margin-top: 2px; }
.banner .btn { width: auto; min-height: 44px; padding: 0 14px; font-size: 16px; }
.items { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.item { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 8px 8px 12px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-1); }
.item .stage { height: 84px; border-radius: 13px; background: linear-gradient(160deg, #c9d6c2, #9fb4a0 55%, #b6bfa7); display: grid; place-items: center; overflow: hidden; }
.item canvas { width: 100%; height: 100%; }
.item .meta { padding: 0 6px; }
.item .nm { font-weight: 700; font-size: 15.5px; line-height: 1.2; }
.rar { font-size: 12.5px; font-weight: 600; color: var(--ink-3); }
.rar.rare { color: #1b6fd1; } .rar.epic { color: #7d4bd8; } .rar.legendary { color: var(--gold); } .rar.mythic { color: #c2306b; }
.item .act { margin: 0 4px; }
.item .btn { min-height: 40px; font-size: 14.5px; border-radius: 11px; padding: 0 10px; }
.item.on { border-color: var(--accent); outline: 1px solid var(--accent); }
.item .badge-on { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; font-weight: 700; font-size: 14.5px; color: var(--accent); }
.item .badge-on .i { width: 17px; height: 17px; stroke-width: 2.4; }
.item .lockhint { display: flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 4px; font-size: 13px; color: var(--ink-3); line-height: 1.25; }
.item .lockhint .i { width: 16px; height: 16px; }

/* ---------- online ---------- */
.code { font-size: 54px; font-weight: 800; letter-spacing: .14em; text-align: center; color: var(--ink); direction: ltr; padding-inline-start: .14em; }
.pulse { display: flex; align-items: center; gap: 10px; color: var(--ink-3); font-size: 14px; justify-content: center; width: 100%; }
.pulse .spinner { width: 16px; height: 16px; border-width: 2px; }
.codeinput { text-align: center; text-transform: uppercase; letter-spacing: .3em; font-size: 28px !important; font-weight: 700; direction: ltr; }

/* ---------- summary ---------- */
.scorecard { text-align: center; padding: 8px 0 4px; }
.scorecard .big-n { font-size: 68px; font-weight: 800; letter-spacing: -.035em; line-height: 1; font-variant-numeric: tabular-nums; }
.scorecard .of { color: var(--ink-3); font-size: 15px; margin-top: 4px; }
.scorecard .headline { font-size: 21px; font-weight: 800; margin-bottom: 6px; }
.dots { display: flex; justify-content: center; gap: 5px; margin-top: 16px; }
.dots i { width: 22px; height: 6px; border-radius: 3px; background: var(--line-2); }
.dots i.great, .tick.great { background: var(--great); } .dots i.good, .tick.good { background: var(--good); } .dots i.mid, .tick.mid { background: var(--mid); } .dots i.low, .tick.low { background: var(--low); }
.rewards { display: grid; gap: 0; }
.rewards .line { display: flex; align-items: center; gap: 10px; padding: 12px 16px; font-weight: 600; }
.rewards .line + .line { box-shadow: inset 0 1px 0 var(--line); }
.rewards .line .i { color: var(--gold); }
.rewards .line .v { margin-inline-start: auto; font-weight: 800; font-variant-numeric: tabular-nums; }
.rewards .unlock { background: #fff8e6; }
.sumMap { height: 46vh; min-height: 280px; border-radius: var(--r-lg); overflow: hidden; background: #0b1522; box-shadow: var(--sh-1); }
.sumMap canvas { display: block; width: 100%; height: 100%; }
.ledger .lr { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 14px; text-align: start; transition: background-color .16s; }
.ledger .lr + .lr { box-shadow: inset 0 1px 0 var(--line); }
.ledger .lr:active, .ledger .lr[aria-pressed="true"] { background: var(--accent-tint); }
.ledger .no { width: 18px; font-weight: 700; color: var(--ink-3); font-size: 14px; text-align: center; }
.ledger img { width: 64px; height: 40px; object-fit: cover; border-radius: 8px; flex: none; background: var(--line); }
.ledger .bar2 { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; margin-top: 7px; }
.ledger .bar2 i { display: block; height: 100%; border-radius: 3px; transform-origin: right; animation: grow .7s var(--ease) backwards; }
.ledger .pts { font-weight: 800; font-size: 16px; }
.ledger .sub { font-size: 12.5px; color: var(--ink-3); }
.tick { background: var(--line-2); }
.ledger .grow, .ledger .bar2, .ledger .sub, .ledger .grow b { display: block; }
.ledger .grow b { font-size: 15.5px; line-height: 1.2; }
.versus { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; text-align: center; }
.versus .side b { display: block; font-size: 40px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.versus .side span { display: flex; justify-content: center; align-items: center; gap: 8px; font-weight: 600; }
.versus .side.win b { color: var(--great); }
.versus em { font-style: normal; color: var(--ink-3); font-size: 22px; }
.duelrow { display: grid; grid-template-columns: 1fr auto auto; gap: 16px; align-items: center; padding: 11px 16px; font-variant-numeric: tabular-nums; }
.duelrow + .duelrow { box-shadow: inset 0 1px 0 var(--line); }
.duelrow .win { font-weight: 800; color: var(--great); }

/* ---------- playing screen ---------- */
.game { position: fixed; inset: 0; display: flex; flex-direction: column; background: var(--navy); color: #fff; }
.hud { display: flex; align-items: center; gap: 10px; padding: calc(8px + var(--safe-t)) 10px 8px; }
.hud .iconbtn { color: #cfd9e8; width: 40px; height: 40px; }
@media (hover: hover) and (pointer: fine) { .hud .iconbtn:hover { background: rgba(255, 255, 255, .1); } }
.where { flex: 1; min-width: 0; }
.where .t { display: flex; align-items: baseline; gap: 8px; font-weight: 700; font-size: 15.5px; }
.where .t small { font-weight: 500; font-size: 13px; color: #9fb2cf; }
.ticks { display: flex; gap: 3px; margin-top: 6px; }
.ticks i { flex: 1; height: 4px; border-radius: 2px; background: var(--navy-line); transition: background-color .3s; }
.ticks i.now { background: #fff; }
.ticks i.great { background: #2fcf79; } .ticks i.good { background: #9bd32a; } .ticks i.mid { background: #f5b223; } .ticks i.low { background: #f0566a; }
.timer { position: relative; width: 78px; height: 38px; border-radius: 12px; background: var(--navy-2); box-shadow: inset 0 0 0 1px var(--navy-line); overflow: hidden; display: grid; place-items: center; flex: none; }
.timer i { position: absolute; inset-block: 0; inset-inline-start: 0; background: rgba(60, 130, 246, .5); width: 100%; transition: width .1s linear; }
.timer b { position: relative; font-size: 19px; font-weight: 800; font-variant-numeric: tabular-nums; }
.timer.low i { background: rgba(240, 86, 106, .65); }
.play { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 8px; padding: 0 8px calc(8px + var(--safe-b)); }
.photo, .mapbox { position: relative; min-width: 0; min-height: 0; overflow: hidden; border-radius: var(--r-lg); background: #060d17; }
.photo { flex: 0 0 min(35%, 60vw); transition: flex-basis .35s var(--ease); }
.mapbox { flex: 1; }
.play.revealed .photo { flex-basis: 21%; }
.photo.full { position: fixed; inset: 0; z-index: 20; border-radius: 0; flex: none; }
.play canvas { display: block; width: 100%; height: 100%; touch-action: none; user-select: none; }
.mapbox canvas { cursor: crosshair; }
.fab { position: absolute; width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; color: #fff; background: rgba(11, 21, 34, .72); box-shadow: 0 2px 8px rgba(0, 0, 0, .3); transition: transform .16s var(--ease), background-color .16s; }
.fab:active { transform: scale(.92); }
.fab[aria-pressed="false"] { color: #9fb2cf; }
.fab .i { width: 21px; height: 21px; }
#expand { inset-block-end: 10px; inset-inline-start: 10px; }
.photo.full #expand { inset-block: calc(10px + var(--safe-t)) auto; }
#fit { inset-block-start: 10px; inset-inline-start: 10px; }
#labels { inset-block-start: 10px; inset-inline-end: 10px; }
.hint { position: absolute; inset-block-start: 14px; inset-inline: 62px; margin: 0 auto; width: fit-content; max-width: calc(100% - 124px); background: rgba(11, 21, 34, .78); padding: 7px 12px; border-radius: 10px; font-size: 13px; line-height: 1.35; text-align: center; pointer-events: none; color: #e2eaf6; }
.dock { position: absolute; inset-inline: 10px; inset-block-end: 10px; max-width: 560px; margin-inline: auto; }
.dock > .btn { min-height: 54px; box-shadow: 0 8px 22px rgba(0, 0, 0, .35); }
.dock > .btn:disabled { opacity: 1; background: rgba(11, 21, 34, .82); color: #b4c4dc; box-shadow: none; font-weight: 600; font-size: 15.5px; }
.sheet { background: var(--surface); color: var(--ink); border-radius: 22px; padding: 16px 16px 14px; box-shadow: 0 -2px 30px rgba(0, 0, 0, .35); animation: sheet .38s var(--ease); }
@keyframes sheet { from { transform: translateY(24px); opacity: 0; } }
.sheet .top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.sheet .verdict { font-size: 22px; font-weight: 800; line-height: 1.1; letter-spacing: -.015em; }
.sheet .where2 { font-size: 13px; color: var(--ink-3); margin-top: 3px; }
.sheet .pts { text-align: end; line-height: 1; }
.sheet .pts b { font-size: 44px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; display: block; }
.sheet .pts small { font-size: 12.5px; color: var(--ink-3); }
.sheet.great .verdict, .sheet.great .pts b { color: var(--great); } .sheet.good .verdict, .sheet.good .pts b { color: var(--good); }
.sheet.mid .verdict, .sheet.mid .pts b { color: var(--mid); } .sheet.low .verdict, .sheet.low .pts b { color: var(--low); }
.meters { display: grid; gap: 10px; margin: 14px 0; }
.meter { display: grid; gap: 6px; }
.meter .mh { display: flex; align-items: baseline; gap: 10px; font-size: 14px; }
.meter .k { font-weight: 700; color: var(--ink); }
.meter .sub { flex: 1; color: var(--ink-3); font-size: 13.5px; }
.meter .v { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.meter .v b { color: var(--ink); font-size: 15px; }
.meter .track { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; }
.meter .track i { display: block; height: 100%; border-radius: 4px; background: var(--accent); transform-origin: right; animation: grow .7s var(--ease) .1s backwards; }
.sheet .btn { min-height: 50px; }
.sheet.duel { padding-bottom: 12px; }
.sheet .duelrow { padding-inline: 4px; }
.overlay { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; background: rgba(6, 13, 23, .88); padding: 20px; color: #fff; }
.overlay .box { background: var(--surface); color: var(--ink); border-radius: var(--r-lg); padding: 22px; width: min(340px, 100%); text-align: center; display: grid; gap: 14px; }
.countdown { font-size: 132px; font-weight: 800; line-height: 1; letter-spacing: -.04em; animation: tick 1s var(--ease) infinite; }
@keyframes tick { from { transform: scale(1.18); opacity: .4; } 40% { opacity: 1; } }

@media (min-width: 860px) and (orientation: landscape), (orientation: landscape) and (max-height: 560px) {
  .play { flex-direction: row; }
  .photo, .play.revealed .photo { flex: 0 0 44%; }
}

#toast { position: fixed; z-index: 50; inset-inline: 0; bottom: calc(92px + var(--safe-b)); margin-inline: auto; width: fit-content; max-width: 88vw; padding: 11px 18px; border-radius: 14px; background: var(--ink); color: #fff; font-size: 15px; font-weight: 500; text-align: center; opacity: 0; transform: translateY(8px); pointer-events: none; transition: opacity .2s var(--ease), transform .2s var(--ease); box-shadow: var(--sh-2); }
#toast.show { opacity: 1; transform: none; }
.game ~ #toast { bottom: 120px; }
@media (prefers-reduced-motion: reduce) { *, ::before, ::after { animation: none !important; transition-duration: .01ms !important; } }
