/* ═══════════════════════════════════════════════════════════
   GOAL RUSH — Neon Pitch Design System
   Fonts: Oswald (display) · Rajdhani (body)
   Palette: #020f02 bg · #39FF14 neon · #ef4444 red
═══════════════════════════════════════════════════════════ */

/* ── Reset ──────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}
html { height: 100%; }

body {
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  background: #020f02;
  color: #e8fce8;
  height: 100%;
  min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ── CSS Variables ──────────────────────────────────────── */
:root {
  --neon: #39FF14;
  --neon-dim: rgba(57,255,20,0.15);
  --neon-glow: 0 0 18px rgba(57,255,20,0.55);
  --red: #ef4444;
  --red-dim: rgba(239,68,68,0.15);
  --red-glow: 0 0 18px rgba(239,68,68,0.55);
  --bg: #020f02;
  --bg-card: rgba(2,15,2,0.88);
  --bg-card-solid: #061206;
  --border: rgba(57,255,20,0.14);
  --text-dim: #6fa96f;
  --text-mid: #8eaf8e;
  --nav-h: 52px;
}


/* ═══════════════════════════════════════════════════════════
   PERSISTENT NAV (above landing + game)
═══════════════════════════════════════════════════════════ */
#desktop-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 100;
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 28px;
  background: rgba(2,15,2,0.97);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.dnav-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.dnav-logo-img {
  height: 46px;
  width: 46px;
  display: block;
  flex-shrink: 0;
  object-fit: contain;
  border-radius: 0;
}
.dnav-logo-icon { display: none; }
.dnav-logo-name {
  display: block;
  font-family: 'Oswald', Arial, sans-serif;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 2.5px;
  color: #CEFF00;
  margin-left: 8px;
  white-space: nowrap;
  line-height: 1;
}
.dnav-logo-tag {
  font-size: 12px;
  color: var(--text-dim);
  letter-spacing: 2px;
  line-height: 1;
}

.dnav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  flex: 1;
}
.dnav-link {
  font-family: 'Oswald', sans-serif;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 1px;
  color: var(--text-mid);
  padding: 5px 13px;
  border-radius: 4px;
  cursor: pointer;
  transition: color 0.18s, background 0.18s;
  user-select: none;
}
.dnav-link:hover { color: var(--neon); background: var(--neon-dim); }
.dnav-link-active { color: var(--neon); }
.dnav-link-dim { opacity: 0.4; cursor: default; }
.dnav-coming-soon {
  font-size: 12px;
  background: var(--neon-dim);
  color: var(--neon);
  padding: 1px 5px;
  border-radius: 3px;
  margin-left: 4px;
  vertical-align: middle;
}

.dnav-right {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
}
.dnav-pill {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 12px;
  border-radius: 20px;
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-mid);
  cursor: pointer;
  transition: all 0.18s;
  white-space: nowrap;
}
.dnav-pill-streak { border-color: rgba(57,255,20,0.4); color: var(--neon); }
.dnav-pill-profile:hover { border-color: var(--neon); color: var(--neon); }
/* Intentionally hidden — replaced by #dnav-live-stats session chips */
.dnav-my-stats {
  display: none !important;
}
.dnav-stat-chip {
  font-family: 'Oswald', sans-serif; font-size: 12px; font-weight: 600;
  letter-spacing: 0.4px; color: var(--text-dim); white-space: nowrap;
  padding: 3px 9px; border-radius: 20px;
  border: 1px solid var(--border); background: transparent;
}
.dnav-stat-streak { border-color: rgba(57,255,20,0.35); color: var(--neon); }

@media (max-width: 920px) {
  #desktop-nav { display: none; }
  #fomo-ticker { display: none !important; }
}

/* ═══════════════════════════════════════════════════════════
   LANDING PAGE  (#start-overlay)
═══════════════════════════════════════════════════════════ */
#start-overlay {
  position: fixed;
  inset: 0;
  padding-top: var(--nav-h);
  background: var(--bg);
  z-index: 1;
  overflow: hidden;
}

/* Football pitch SVG background */
#pitch-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 0.7;
}
/* Pitch SVG — no vertical flip; orientation is consistent across all widths */

.landing-grid {
  display: grid;
  grid-template-columns: 240px 1fr 240px;
  height: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 20px 20px 16px;
  gap: 20px;
  position: relative;
  z-index: 1;
}

/* ── Left & Right columns — cards take natural height ── */
.landing-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-self: start;
}

/* ── Landing cards ── */
.lcard {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.lcard-title {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-dim);
  text-transform: uppercase;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

/* Stats card — auto height, no stretch */
.lcard-stats { flex: none; }

.dstat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
}
.dstat-row:last-child { border-bottom: none; }
.dstat-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-mid);
  letter-spacing: 0.3px;
}
.dstat-sub {
  font-size: 12px;
  color: var(--text-dim);
  letter-spacing: 0.5px;
  margin-top: 1px;
}
.dstat-val {
  font-family: 'Oswald', sans-serif;
  font-size: 19px;
  font-weight: 700;
  color: #fff;
}
.dstat-val-green { color: var(--neon); }

/* Daily challenge card */
.lcard-daily {
  cursor: pointer;
  transition: border-color 0.18s, transform 0.15s;
  flex-shrink: 0;
}
.lcard-daily:hover { border-color: var(--neon); transform: translateY(-2px); }
.lcard-daily:focus { outline: 2px solid var(--neon); outline-offset: 2px; }
.lcard-icon { font-size: 26px; }
.lcard-name {
  font-family: 'Oswald', sans-serif;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #e8fce8;
}
.lcard-desc { font-size: 13px; color: var(--text-dim); line-height: 1.5; overflow-wrap: break-word; word-break: break-word; }
.lcard-badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 4px;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  width: fit-content;
}
.lcard-badge-orange { background: rgba(255,140,0,0.12); color: #ff9500; border: 1px solid rgba(255,140,0,0.28); }
.lcard-badge-dim    { background: rgba(255,255,255,0.05); color: var(--text-dim); border: 1px solid var(--border); }
.lcard-badge-neon   { background: var(--neon-dim); color: var(--neon); border: 1px solid rgba(57,255,20,0.35); }
.lcard-dim { opacity: 0.55; cursor: default; }
.lcard-cs-pill {
  display: inline-block;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  padding: 2px 7px;
  border-radius: 4px;
  background: rgba(255,140,0,0.15);
  color: #ff9500;
  border: 1px solid rgba(255,140,0,0.35);
  vertical-align: middle;
  margin-left: 6px;
}
.lcard-cs  { opacity: 0.55; cursor: pointer; }

/* Leaders card — auto height, no stretch */
.lcard-leaders { flex: none; overflow: hidden; }
.dlb-list { display: flex; flex-direction: column; gap: 2px; }
.dlb-empty { font-size: 11px; color: var(--text-dim); text-align: center; padding: 10px 0; }
.dlb-row {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 0;
  border-bottom: 1px solid var(--border);
}
.dlb-row:last-child { border-bottom: none; }
.dlb-medal { font-size: 14px; width: 18px; flex-shrink: 0; }
.dlb-name {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: #e8fce8;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: 0.3px;
}
.dlb-you {
  font-size: 12px;
  background: var(--neon-dim);
  color: var(--neon);
  padding: 1px 4px;
  border-radius: 3px;
  margin-left: 3px;
}
.dlb-score {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: var(--neon);
  flex-shrink: 0;
}
.dlb-see-all {
  background: none;
  border: none;
  color: var(--neon);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  letter-spacing: 0.5px;
  padding: 6px 0 0;
  opacity: 0.7;
  transition: opacity 0.15s;
  text-align: left;
  font-family: 'Rajdhani', sans-serif;
}
.dlb-see-all:hover { opacity: 1; }

/* ── CENTER COLUMN — V4-A layout ── */
.landing-center {
  position: relative;
  height: 100%;
  text-align: center;
}

/* Title pinned to top of centre column */
.landing-title-wrap {
  position: absolute;
  top: 20px;
  left: 0;
  right: 0;
  text-align: center;
  pointer-events: none;
}

.landing-title {
  font-family: 'Oswald', 'Impact', sans-serif;
  font-size: clamp(60px, 7vw, 90px);
  font-weight: 700;
  line-height: 0.88;
  letter-spacing: -1px;
  color: #fff;
  text-shadow: 0 0 60px rgba(57,255,20,0.2), 0 2px 0 rgba(0,0,0,0.5);
  margin: 0;
  padding: 0;
}
.landing-center-logo {
  width: clamp(160px, 30vw, 240px);
  height: auto;
  display: block;
  margin: 0 auto;
  object-fit: contain;
  pointer-events: none;
  user-select: none;
  filter: drop-shadow(0 0 40px rgba(57,255,20,0.15));
}

/* Play button anchored to pitch centre circle
   Pitch SVG centre: (650,390) in 1300×780 viewBox = 50% × 50% of viewport.
   Grid starts at --nav-h + 20px from top.
   Wrap is 128px tall → centre at 64px. */
.play-btn-anchor {
  position: absolute;
  top: calc((100vh - var(--nav-h)) / 2 - 64px);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Tabs + chips pinned to bottom */
.landing-bottom-group {
  position: absolute;
  bottom: 16px;
  left: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
/* Play button region with pulse rings */
.play-btn-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 128px;
  height: 128px;
}

.pulse-ring {
  position: absolute;
  border-radius: 50%;
  border: 2px solid rgba(57,255,20,0.35);
  width: 100%;
  height: 100%;
  animation: pulse-expand 2.4s cubic-bezier(0.4,0,0.6,1) infinite;
}
.pr-2 { animation-delay: 0.7s; }
.pr-3 { animation-delay: 1.4s; }

@keyframes pulse-expand {
  0%   { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(1.8); opacity: 0; }
}

.play-btn {
  position: relative;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 3px solid var(--neon);
  background: radial-gradient(circle at 38% 38%, rgba(57,255,20,0.22), rgba(2,15,2,0.92));
  box-shadow: var(--neon-glow), inset 0 0 20px rgba(57,255,20,0.06);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s, box-shadow 0.15s;
  z-index: 2;
}
.play-btn:hover {
  transform: scale(1.07);
  box-shadow: 0 0 36px rgba(57,255,20,0.75), inset 0 0 20px rgba(57,255,20,0.1);
}
.play-btn:active { transform: scale(0.97); }
.play-btn-icon {
  font-size: 32px;
  color: var(--neon);
  line-height: 1;
  margin-left: 5px;
}

.play-label {
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--neon);
  margin-top: 10px;
}


.social-proof {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-dim);
  margin-bottom: 5px;
}

.days-played-badge {
  font-size: 11px;
  font-weight: 700;
  color: var(--neon);
  letter-spacing: 1px;
}

.dhero-date-hidden { display: none; }

/* Mobile-only leaderboard button */
.mobile-lb-btn {
  display: none;
  margin: 16px auto 0;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  padding: 8px 20px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-mid);
  cursor: pointer;
  transition: all 0.18s;
}
.mobile-lb-btn:hover { border-color: var(--neon); color: var(--neon); }

/* Ko-fi mobile landing button — hidden on desktop */
.kofi-mobile-landing-btn {
  display: none;
  margin: 10px auto 0;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  padding: 8px 20px;
  border-radius: 20px;
  border: 1px solid #FF5E5B;
  background: transparent;
  color: #FF5E5B;
  cursor: pointer;
  transition: all 0.18s;
}
.kofi-mobile-landing-btn:hover { background: rgba(255,94,91,0.12); }

.build-version {
  position: fixed;
  bottom: 6px;
  left: 8px;
  font-family: monospace;
  font-size: 10px;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.3px;
  pointer-events: none;
  z-index: 9999;
  user-select: text;
}
/* Hide build version watermark during gameplay (only show on landing) */
body.gameplay-active .build-version,
body.in-game .build-version { display: none !important; }

/* Footer legal links — sit in the bottom-right of the landing page,
   muted; hidden during gameplay just like the build-version watermark. */
.legal-footer-links {
  position: fixed;
  bottom: 6px;
  right: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  letter-spacing: 1.2px;
  color: rgba(143,175,143,0.55);
  z-index: 9999;
}
.legal-footer-links a {
  color: rgba(143,175,143,0.7);
  text-decoration: none;
  padding: 2px 4px;
  transition: color 0.15s;
}
.legal-footer-links a:hover { color: var(--neon); }
body.gameplay-active .legal-footer-links,
body.in-game .legal-footer-links { display: none !important; }
@media (max-width: 600px) {
  .legal-footer-links { font-size: 10px; gap: 4px; right: 6px; }
}

/* Floating points reward animation — appears above the button on guess */
.float-pts {
  position: fixed;
  transform: translate(-50%, 0);
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 28px;
  letter-spacing: 0.5px;
  pointer-events: none;
  z-index: 10000;
  animation: float-pts-anim 1.2s cubic-bezier(0.22, 0.68, 0.36, 1) forwards;
  text-shadow: 0 2px 12px rgba(0,0,0,0.6);
  white-space: nowrap;
}
.float-pts-good { color: #39FF14; }
.float-pts-bad  { color: #FF5E5B; }
@keyframes float-pts-anim {
  0%   { transform: translate(-50%, 10px) scale(0.7); opacity: 0; }
  15%  { transform: translate(-50%, 0) scale(1.15); opacity: 1; }
  35%  { transform: translate(-50%, -20px) scale(1); opacity: 1; }
  100% { transform: translate(-50%, -90px) scale(0.85); opacity: 0; }
}

/* ═══════════════════════════════════════════════════════════
   GAME CONTAINER — Iris Portal (clip-path transition)
═══════════════════════════════════════════════════════════ */
#game-container {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  background: #000;
  /* Iris starts closed */
  clip-path: circle(0% at 50% 58%);
  transition: clip-path 1.35s cubic-bezier(0.35, 0, 0.2, 1);
  pointer-events: none;
}
#game-container.iris-open {
  clip-path: circle(160% at 50% 58%);
  pointer-events: auto;
}

/* Exit / Home button */
#exit-btn {
  position: absolute;
  top: 14px;
  left: 16px;
  z-index: 80;
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: rgba(232,252,232,0.85);
  background: rgba(2,15,2,0.88);
  border: 1.5px solid rgba(57,255,20,0.35);
  padding: 8px 18px 8px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: color 0.18s, border-color 0.18s, background 0.18s;
  display: flex;
  align-items: center;
  gap: 7px;
}
#exit-btn:hover { color: var(--neon); border-color: var(--neon); background: rgba(57,255,20,0.08); }

/* ── Video wrapper fills entire game container ── */
#video-wrapper {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: #000;
}

/* Flash effects */
#video-wrapper.flash-green { animation: flash-g 0.65s ease; }
#video-wrapper.flash-red   { animation: flash-r 0.65s ease; }
@keyframes flash-g {
  0%,100% { box-shadow: none; }
  30% { box-shadow: inset 0 0 80px rgba(57,255,20,0.45); }
}
@keyframes flash-r {
  0%,100% { box-shadow: none; }
  30% { box-shadow: inset 0 0 80px rgba(239,68,68,0.45); }
}

#game-container.shake { animation: shake-anim 0.45s cubic-bezier(.36,.07,.19,.97); }
@keyframes shake-anim {
  0%,100% { transform: none; }
  20% { transform: translateX(-7px) rotate(-0.4deg); }
  40% { transform: translateX(7px) rotate(0.4deg); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

/* Videos — YouTube cinema mode: aspect-ratio preserved, centered at 85% with ambient blur visible around */
#playerA, #playerB {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 85%;
  height: 85%;
  object-fit: contain;
  display: block;
  background: transparent;
}
#playerA.active, #playerB.active { opacity: 1; z-index: 3; }
#playerA.hidden, #playerB.hidden { opacity: 0; z-index: 2; }

/* Ambient background — blurred, scaled copy of active video filling the empty bands */
#ambient-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.18);
  filter: blur(42px) saturate(1.45) brightness(0.65);
  z-index: 1;
  display: block;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s ease;
  will-change: opacity, transform;
}
#ambient-bg.active { opacity: 0.85; }
#playerA.zoom-enter { animation: zoom-in 0.4s ease; }
@keyframes zoom-in {
  from { transform: translate(-50%, -50%) scale(1.06); }
  to   { transform: translate(-50%, -50%) scale(1); }
}

/* Context badge */
#context-badge {
  position: absolute;
  top: 56px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  font-family: 'Oswald', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 3px;
  color: var(--neon);
  background: rgba(2,15,2,0.9);
  border: 1px solid rgba(57,255,20,0.35);
  padding: 6px 18px;
  border-radius: 20px;
  white-space: nowrap;
  transition: opacity 0.6s;
  text-shadow: 0 0 12px rgba(57,255,20,0.4);
}
#context-badge.fade-out { opacity: 0; pointer-events: none; }

/* Game-paused badge — shown while a popup freezes the game */
#game-paused-badge {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 25;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.75);
  background: rgba(0,0,0,0.45);
  border: 1px solid rgba(255,255,255,0.2);
  padding: 4px 14px;
  border-radius: 20px;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}
#game-paused-badge.visible { opacity: 1; }

/* Loading overlay */
#loading-overlay {
  position: absolute;
  inset: 0;
  z-index: 60;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(2,15,2,0.9);
  gap: 14px;
}
#loading-overlay.show { display: flex; }
.loading-spinner {
  width: 44px;
  height: 44px;
  border: 3px solid var(--border);
  border-top-color: var(--neon);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-dim);
}

/* ── Result overlay — centered stamp ── */
#result-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.6);
  z-index: 55;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s, transform 0.28s cubic-bezier(0.2,0,0,1.35);
}
#result-overlay.show {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}
#result-emoji {
  font-size: 88px;
  line-height: 1;
  filter: drop-shadow(0 4px 24px rgba(0,0,0,0.7));
}


/* ── Skip button ── */
#skip-btn {
  position: absolute;
  bottom: 180px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 45;
  display: none;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: rgba(232,252,232,0.7);
  background: rgba(2,15,2,0.8);
  border: 1px solid var(--border);
  padding: 8px 18px;
  border-radius: 20px;
  cursor: pointer;
  transition: color 0.18s;
}
#skip-btn.show { display: block; }
#skip-btn:hover { color: var(--neon); }

/* ── Transition screen (between clips) ── */
#transition-screen {
  position: absolute;
  inset: 0;
  z-index: 65;
  background: rgba(2,15,2,0.96);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  gap: 0;
  overflow-y: auto;
  padding: 6dvh 16px 24px;
}
#transition-screen.show { display: flex; }

.tr-brand-logo {
  width: 130px;
  height: 130px;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
  margin-bottom: 4px;
  opacity: 0.9;
}

.transition-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}
.tr-result { font-size: 80px; line-height: 1; margin-bottom: 8px; }
.tr-streak {
  font-family: 'Oswald', sans-serif;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--neon);
}
.tr-diff, .tr-round {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-dim);
  text-transform: uppercase;
}
.tr-combo {
  font-family: 'Oswald', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: #FFD700;
  display: none;
}
.tr-combo.show { display: block; }
.tr-pb { font-size: 12px; color: var(--text-dim); letter-spacing: 1px; }

/* SHARE + NEXT large pills (approved spec) */
.transition-btns {
  display: flex;
  gap: 14px;
}
.tr-btn {
  font-family: 'Oswald', sans-serif;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 1.5px;
  padding: 14px 36px;
  border-radius: 32px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  gap: 8px;
}
.tr-btn-share {
  background: rgba(2,15,2,0.85);
  border: 2px solid rgba(232,252,232,0.25);
  color: rgba(232,252,232,0.8);
}
.tr-btn-share:hover { border-color: rgba(232,252,232,0.6); color: #fff; }
.tr-btn-replay {
  background: rgba(57,255,20,0.08);
  border: 2px solid rgba(57,255,20,0.7);
  color: var(--neon);
}
.tr-btn-replay:hover {
  background: rgba(57,255,20,0.15);
  border-color: var(--neon);
  box-shadow: 0 0 12px rgba(57,255,20,0.35);
}
.tr-btn-next {
  background: var(--neon);
  border: 2px solid var(--neon);
  color: #020f02;
}
.tr-btn-next:hover { transform: scale(1.05); box-shadow: var(--neon-glow); }

/* ── Transition scorecard ── */
.tr-scorecard {
  margin-top: 8px;
  background: rgba(0,0,0,0.45);
  border: 1px solid rgba(57,255,20,0.38);
  border-radius: 10px;
  padding: 10px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 200px;
}
.tsc-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-family: 'Rajdhani', sans-serif;
  font-size: 13px;
}
.tsc-label {
  color: rgba(232,252,232,0.55);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-size: 11px;
}
.tsc-val {
  color: rgba(232,252,232,0.95);
  font-weight: 600;
}
.tsc-pts { color: var(--neon); }

@keyframes tsc-slide-in {
  from { opacity: 0; transform: translateX(-12px); }
  to   { opacity: 1; transform: translateX(0); }
}
.tsc-reveal {
  animation: tsc-slide-in 0.22s ease forwards;
}

@keyframes pts-pop {
  0%   { transform: scale(0.45); opacity: 0; }
  55%  { transform: scale(1.22); opacity: 1; }
  80%  { transform: scale(0.95); }
  100% { transform: scale(1);    opacity: 1; }
}
.tsc-pts-pop {
  display: inline-block;
  animation: pts-pop 0.42s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
  font-size: 17px;
  text-shadow: 0 0 14px rgba(57,255,20,0.7), 0 0 28px rgba(57,255,20,0.35);
}
.tsc-pts-row { margin-top: 3px; }


/* ── FOMO Ticker ── */
#fomo-ticker {
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 30;
  background: rgba(57,255,20,0.08);
  border-bottom: 1px solid rgba(57,255,20,0.18);
  padding: 5px 12px;
  text-align: center;
  font-family: 'Rajdhani', sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: rgba(57,255,20,0.85);
  letter-spacing: 0.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
#fomo-ticker.show { display: block; }

/* ── 4 Corner overlay cards ── */
.cc {
  position: absolute;
  z-index: 25;
  width: 168px;
  background: rgba(2,15,2,0.88);
  border: 1px solid rgba(57,255,20,0.16);
  border-radius: 10px;
  padding: 12px 13px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  pointer-events: none;
}
.cc-tl { top: 56px; left: 14px; }
.cc-tr { top: 56px; right: 14px; }
.cc-bl { bottom: 134px; left: 14px; }
.cc-br { bottom: 134px; right: 14px; }

.cc-title {
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--neon);
  border-bottom: 1px solid rgba(57,255,20,0.14);
  padding-bottom: 5px;
  margin-bottom: 3px;
}
.cc-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.cc-label { font-size: 11px; color: var(--text-dim); font-weight: 600; }
.cc-val {
  font-family: 'Oswald', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #fff;
}
.cc-val-green { color: var(--neon); }
.cc-row-sub span { font-size: 12px; color: var(--text-dim); }
.cc-lb-stub { font-size: 11px; color: var(--text-dim); line-height: 1.5; }
.cc-coming-soon {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #ff9500;
}

@media (max-width: 900px) { .cc { display: none; } }

/* ── Controls bar (bottom of game view) ── */
#controls {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-bottom: calc(22px + env(safe-area-inset-bottom, 0px));
  gap: 8px;
  background: linear-gradient(transparent, rgba(2,15,2,0.78) 55%);
}

/* Streak display hidden (JS compat) */
#streak-display { display: none; }

/* Lives */
#lives-display {
  display: flex;
  gap: 4px;
  margin-bottom: 2px;
}
.life-heart {
  font-size: 19px;
  transition: transform 0.3s, opacity 0.3s;
  display: inline-block;
  filter: drop-shadow(0 0 5px rgba(255,255,255,0.8)) drop-shadow(0 0 2px rgba(255,80,80,0.9));
}
.life-heart.lost { opacity: 0.2; filter: grayscale(1); }
.life-heart.pulse { animation: heart-pulse 0.45s ease; }
@keyframes heart-pulse {
  0%,100% { transform: scale(1); }
  40% { transform: scale(1.5); }
}

/* Guess area: [NO GOAL] [Ring Timer] [GOAL] */
#guess-area {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
}

/* ── Circular guess buttons (88px) ── */
.guess-btn { background: none; border: none; padding: 0; }

.circ-btn {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  border: 3px solid;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform 0.15s, box-shadow 0.15s, opacity 0.2s;
}
.circ-btn:disabled { opacity: 0.3; cursor: default; pointer-events: none; }
.circ-btn:not(:disabled):hover { transform: scale(1.08); }
.circ-btn:not(:disabled):active { transform: scale(0.95); }

.circ-btn-neon {
  border-color: var(--neon);
  background: radial-gradient(circle at 38% 38%, rgba(57,255,20,0.2), rgba(2,15,2,0.9));
  box-shadow: var(--neon-glow);
}
.circ-btn-neon.active { box-shadow: 0 0 28px rgba(57,255,20,0.7); }
.circ-btn-neon:not(:disabled):hover { box-shadow: 0 0 36px rgba(57,255,20,0.8); }

.circ-btn-red {
  border-color: var(--red);
  background: radial-gradient(circle at 38% 38%, rgba(239,68,68,0.2), rgba(2,15,2,0.9));
  box-shadow: var(--red-glow);
}
.circ-btn-red.active { box-shadow: 0 0 28px rgba(239,68,68,0.7); }
.circ-btn-red:not(:disabled):hover { box-shadow: 0 0 36px rgba(239,68,68,0.8); }

.circ-icon {
  font-size: 26px;
  line-height: 1;
}
.circ-label {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  line-height: 1;
}
.circ-btn-neon .circ-label { color: var(--neon); }
.circ-btn-red  .circ-label { color: var(--red); }

/* Ripple */
.btn-ripple {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  pointer-events: none;
}
.circ-btn.ripple-active .btn-ripple { animation: ripple-neon 0.5s ease; }
.circ-btn-red.ripple-active .btn-ripple { animation: ripple-red 0.5s ease; }
@keyframes ripple-neon {
  0%   { box-shadow: 0 0 0 0 rgba(57,255,20,0.55); }
  100% { box-shadow: 0 0 0 26px rgba(57,255,20,0); }
}
@keyframes ripple-red {
  0%   { box-shadow: 0 0 0 0 rgba(239,68,68,0.55); }
  100% { box-shadow: 0 0 0 26px rgba(239,68,68,0); }
}

/* ── Ring timer (112px) ── */
#ring-timer {
  position: relative;
  width: 112px;
  height: 112px;
  display: flex;
  align-items: center;
  justify-content: center;
}
#ring-timer svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
#ring-progress {
  transition: stroke-dashoffset 0.85s linear, stroke 0.3s ease;
}
#countdown-num {
  position: relative;
  z-index: 2;
  font-family: 'Oswald', sans-serif;
  font-size: 40px;
  font-weight: 700;
  color: var(--neon);
  line-height: 1;
  text-align: center;
  transition: color 0.3s;
  min-width: 1ch;
}
#countdown-num.urgent {
  color: var(--red);
  animation: num-pulse 0.55s ease infinite alternate;
}
@keyframes num-pulse {
  from { transform: scale(1); }
  to   { transform: scale(1.1); }
}

/* ── Guess phase activation flash ── */
#guess-area.guess-live {
  animation: guess-pop-in 0.28s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
@keyframes guess-pop-in {
  from { transform: scale(0.86); opacity: 0.5; }
  to   { transform: scale(1);    opacity: 1;   }
}
#guess-area.guess-live #ring-timer {
  filter: drop-shadow(0 0 12px rgba(57,255,20,0.7));
}
#guess-area.guess-live .circ-btn-neon {
  animation: neon-btn-pulse 0.6s ease 0.15s 2 alternate;
}
@keyframes neon-btn-pulse {
  from { box-shadow: var(--neon-glow); }
  to   { box-shadow: 0 0 36px rgba(57,255,20,0.9), 0 0 60px rgba(57,255,20,0.4); }
}

/* ═══════════════════════════════════════════════════════════
   OVERLAYS (modals, dialogs)
═══════════════════════════════════════════════════════════ */
#account-prompt, #profile-panel, #leaderboard-screen,
#daily-result-screen, #exhausted-screen, #game-over-screen,
#tipjar, #share-popover {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(2,15,2,0.88);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
#account-prompt.show, #profile-panel.show, #leaderboard-screen.show,
#daily-result-screen.show, #exhausted-screen.show, #game-over-screen.show,
#tipjar.show, #share-popover.show { display: flex; }

/* ── Exhausted ── */
#exhausted-screen {
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  padding: 40px 24px;
}
.exh-title {
  font-family: 'Oswald', sans-serif;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--neon);
}
.exh-sub { font-size: 13px; color: var(--text-mid); letter-spacing: 1px; max-width: 300px; }
#exh-replay-btn, #exh-share-btn, #exh-leaderboard-btn {
  font-family: 'Oswald', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1.5px;
  padding: 12px 32px;
  border-radius: 28px;
  cursor: pointer;
  min-width: 210px;
  transition: all 0.15s;
}
#exh-replay-btn { background: var(--neon); border: 2px solid var(--neon); color: #020f02; }
#exh-replay-btn:hover { transform: scale(1.04); box-shadow: var(--neon-glow); }
#exh-share-btn, #exh-leaderboard-btn {
  background: transparent;
  border: 2px solid var(--border);
  color: var(--text-mid);
}
#exh-share-btn:hover, #exh-leaderboard-btn:hover { border-color: var(--neon); color: var(--neon); }

/* ── Account prompt ── */
#account-prompt.show {
  align-items: flex-start;
  padding: 20px 0;
  overflow-y: auto;
}
.prompt-card {
  background: var(--bg-card-solid);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px 28px;
  width: 90%;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: auto;
}
.prompt-card h2 {
  font-family: 'Oswald', sans-serif;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--neon);
}
.prompt-card p { font-size: 13px; color: var(--text-mid); line-height: 1.5; }
.prompt-form { display: flex; flex-direction: column; gap: 10px; }
.prompt-form input {
  background: rgba(57,255,20,0.04);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  font-family: 'Rajdhani', sans-serif;
  font-size: 14px;
  color: #e8fce8;
  outline: none;
  transition: border-color 0.18s;
}
.prompt-form input:focus { border-color: var(--neon); }
.prompt-form input::placeholder { color: var(--text-dim); }
.prompt-submit {
  font-family: 'Oswald', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1.5px;
  padding: 11px;
  border-radius: 8px;
  background: var(--neon);
  border: none;
  color: #020f02;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.prompt-submit:hover { transform: scale(1.03); box-shadow: var(--neon-glow); }
.prompt-skip {
  background: none;
  border: none;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-dim);
  cursor: pointer;
  text-align: center;
  letter-spacing: 0.5px;
  transition: color 0.15s;
  font-family: 'Rajdhani', sans-serif;
}
.prompt-skip:hover { color: var(--text-mid); }
.msg { display: none; font-size: 12px; padding: 8px 12px; border-radius: 6px; letter-spacing: 0.5px; }
.msg.show { display: block; }
.msg.success { background: var(--neon-dim); color: var(--neon); }
.msg.error   { background: var(--red-dim); color: var(--red); }

/* ── Profile panel ── */
.profile-card {
  background: var(--bg-card-solid);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px 28px;
  width: 90%;
  max-width: 380px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  position: relative;
  transform: translateZ(0);
  -webkit-font-smoothing: antialiased;
  isolation: isolate;
}
.close-btn {
  position: absolute; top: 14px; right: 16px;
  background: none; border: none; color: var(--text-dim);
  font-size: 22px; cursor: pointer; line-height: 1; transition: color 0.15s;
}
.close-btn:hover { color: var(--neon); }
.profile-avatar {
  width: 80px; height: 80px; border-radius: 50%;
  background: var(--neon-dim); border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.profile-username {
  font-family: 'Oswald', sans-serif;
  font-size: 20px; font-weight: 700; letter-spacing: 1px; color: var(--neon);
}
.profile-guest { font-size: 11px; color: var(--text-dim); text-align: center; }
.profile-stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 8px; width: 100%; margin-top: 4px;
}
.prof-stat {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  background: rgba(57,255,20,0.04); border: 1px solid var(--border);
  border-radius: 8px; padding: 10px 6px;
}
.prof-stat .val { font-family: 'Oswald', sans-serif; font-size: 20px; font-weight: 700; color: var(--neon); }
.prof-stat .lbl { font-size: 12px; color: var(--text-dim); letter-spacing: 0.5px; }
.prof-days-played { font-size: 12px; color: var(--neon); font-weight: 700; letter-spacing: 1px; }

/* ── Profile new elements ── */
.prof-rank-badge {
  font-family: 'Oswald', sans-serif; font-size: 11px; font-weight: 700;
  letter-spacing: 1.5px; color: #020f02; background: var(--neon);
  border-radius: 20px; padding: 2px 12px; margin: 2px auto 4px;
}
.prof-edit-row {
  display: flex; align-items: center; gap: 6px; width: 100%; margin: 4px 0;
}
.prof-edit-input {
  flex: 1; background: rgba(57,255,20,0.06); border: 1px solid var(--border);
  border-radius: 8px; color: #fff; font-family: 'Oswald', sans-serif;
  font-size: 14px; padding: 6px 10px; outline: none;
}
.prof-edit-input:focus { border-color: var(--neon); }
.prof-save-btn {
  background: var(--neon); color: #020f02; border: none; border-radius: 8px;
  font-family: 'Oswald', sans-serif; font-size: 12px; font-weight: 700;
  letter-spacing: 1px; padding: 7px 12px; cursor: pointer;
  white-space: nowrap;
}
.prof-cancel-btn {
  background: none; color: var(--text-dim); border: 1px solid var(--border);
  border-radius: 8px; font-size: 14px; padding: 6px 10px; cursor: pointer;
}
.prof-edit-btn {
  background: none; border: none; color: var(--text-dim); font-size: 12px;
  cursor: pointer; letter-spacing: 0.5px; padding: 0; transition: color 0.15s;
}
.prof-edit-btn:hover { color: var(--neon); }
.prof-logout-btn {
  width: 100%; margin-top: 8px; padding: 10px; border-radius: 8px;
  background: none; border: 1px solid rgba(255,60,60,0.3);
  color: rgba(255,100,100,0.8); font-family: 'Oswald', sans-serif;
  font-size: 13px; font-weight: 600; letter-spacing: 1px; cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.prof-logout-btn:hover { background: rgba(255,60,60,0.12); color: #ff6060; }

/* ── Mobile first-play message ── */
.mob-first-play-msg {
  font-family: 'Oswald', sans-serif; font-size: 13px; font-weight: 600;
  letter-spacing: 0.5px; color: var(--neon); text-align: center;
  padding: 8px 16px; opacity: 0.85;
}
/* Hide on desktop — title overlap; sidebar handles first-play context */
@media (min-width: 921px) { .mob-first-play-msg { display: none !important; } }

/* ── Leaderboard screen ── */
.lb-card {
  background: var(--bg-card-solid);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px 24px 20px;
  width: 90%; max-width: 480px;
  max-height: 85dvh; overflow-y: auto;
  display: flex; flex-direction: column; gap: 14px; position: relative;
  transform: translateZ(0);
  -webkit-font-smoothing: antialiased;
  isolation: isolate;
}
.lb-close {
  position: absolute; top: 16px; right: 18px;
  background: none; border: none; color: var(--text-dim);
  font-size: 18px; cursor: pointer; transition: color 0.15s;
}
.lb-close:hover { color: var(--neon); }
.lb-title {
  font-family: 'Oswald', sans-serif; font-size: 20px; font-weight: 700;
  letter-spacing: 1.5px; color: var(--neon); padding-right: 30px;
}
.lb-tabs { display: flex; gap: 8px; }
.lb-tab {
  font-family: 'Oswald', sans-serif; font-size: 11px; font-weight: 600;
  letter-spacing: 1.5px; padding: 6px 18px; border-radius: 20px;
  border: 1px solid var(--border); background: transparent; color: var(--text-dim);
  cursor: pointer; transition: all 0.15s;
}
.lb-tab.active, .lb-tab:hover { border-color: var(--neon); color: var(--neon); background: var(--neon-dim); }
.lb-subtitle { font-family: 'Oswald', sans-serif; font-size: 11px; font-weight: 600; letter-spacing: 2px; color: var(--text-dim); }
.lb-panel {
  display: flex; flex-direction: column; gap: 8px;
  overflow-y: auto; max-height: 380px;
  scrollbar-width: thin;
  scrollbar-color: var(--neon) rgba(57,255,20,0.08);
}
.lb-panel::-webkit-scrollbar { width: 5px; }
.lb-panel::-webkit-scrollbar-track { background: rgba(57,255,20,0.06); border-radius: 4px; }
.lb-panel::-webkit-scrollbar-thumb { background: var(--neon); border-radius: 4px; box-shadow: 0 0 6px var(--neon); }
.lb-list { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.lb-row {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; border-radius: 8px;
  background: rgba(57,255,20,0.03); border: 1px solid transparent;
}
.lb-row.highlight { border-color: var(--border); background: var(--neon-dim); }
.lb-rank { font-family: 'Oswald', sans-serif; font-size: 15px; font-weight: 700; width: 22px; text-align: center; color: var(--text-dim); flex-shrink: 0; }
.lb-rank.gold { color: #FFD700; }
.lb-rank.silver { color: #C0C0C0; }
.lb-rank.bronze { color: #CD7F32; }
.lb-rank-badge { font-size: 16px; flex-shrink: 0; line-height: 1; }
.lb-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Oswald', sans-serif; font-size: 12px; font-weight: 700; color: #fff; flex-shrink: 0;
}
.lb-mid { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.lb-username {
  font-family: 'Oswald', sans-serif; font-size: 15px; font-weight: 600;
  color: #e8fce8; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.lb-stats-row {
  display: flex; gap: 10px;
  font-size: 12px; color: var(--text-dim); letter-spacing: 0.3px;
}
.lb-pts-wrap { display: flex; flex-direction: column; align-items: flex-end; flex-shrink: 0; }
.lb-pts { font-family: 'Oswald', sans-serif; font-size: 18px; font-weight: 700; color: var(--neon); line-height: 1; }
.lb-pts-label { font-size: 12px; color: var(--text-dim); letter-spacing: 1px; margin-top: 1px; }
.lb-separator { text-align: center; color: var(--text-dim); font-size: 12px; padding: 4px; }
.lb-total { font-size: 11px; color: var(--text-dim); text-align: center; letter-spacing: 1px; padding-top: 6px; }
.lb-empty { display: none; font-size: 12px; color: var(--text-dim); text-align: center; padding: 16px 0; }
.lb-loading { display: none; font-family: 'Oswald', sans-serif; font-size: 11px; letter-spacing: 2px; color: var(--text-dim); text-align: center; }
.lb-loading.show { display: block; }

/* ── Game Over ── */
#gameover-score { display: none; }

#game-over-screen {
  flex-direction: column; align-items: center; text-align: center; gap: 12px;
}
.gameover-icon { font-size: 52px; }
.gameover-title {
  font-family: 'Oswald', sans-serif; font-size: 30px; font-weight: 700;
  letter-spacing: 2px; color: var(--red);
}
.gameover-msg { font-size: 13px; font-weight: 600; letter-spacing: 2px; color: var(--text-dim); }
.gameover-stat { font-family: 'Oswald', sans-serif; font-size: 15px; font-weight: 600; color: var(--text-mid); letter-spacing: 1px; }
.gameover-best { color: var(--neon); }
.gameover-percentile { font-size: 12px; color: #facc15; letter-spacing: 0.5px; min-height: 18px; }
.gameover-btns { margin-top: 10px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
#gameover-share-btn {
  font-family: 'Oswald', sans-serif; font-size: 14px; font-weight: 600; letter-spacing: 1.5px;
  padding: 12px 30px; border-radius: 28px; background: var(--neon); border: none; color: #020f02;
  cursor: pointer; transition: transform 0.15s, box-shadow 0.15s;
}
#gameover-share-btn:hover { transform: scale(1.04); box-shadow: var(--neon-glow); }
.gameover-nav { display: flex; gap: 10px; margin-top: 2px; }
.gameover-nav-btn {
  font-family: 'Oswald', sans-serif; font-size: 13px; font-weight: 600; letter-spacing: 1px;
  padding: 9px 22px; border-radius: 22px; border: 1px solid var(--border);
  background: transparent; color: var(--text-mid); cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.gameover-nav-btn:hover { border-color: var(--neon); color: var(--neon); }
.gameover-play-again { border-color: rgba(57,255,20,0.4); color: var(--neon); }

/* ── Daily Result ── */
.daily-result-card {
  background: var(--bg-card-solid); border: 1px solid var(--border);
  border-radius: 16px; padding: 28px 24px;
  width: 90%; max-width: 380px;
  display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center;
}
.daily-header {
  font-family: 'Oswald', sans-serif; font-size: 18px; font-weight: 700;
  letter-spacing: 1.5px; color: var(--neon);
}
.daily-challenge-num { font-size: 12px; color: var(--text-dim); letter-spacing: 1px; }
.lcard-cta {
  margin-top: 10px;
  font-family: 'Oswald', sans-serif;
  font-size: 11px; font-weight: 600; letter-spacing: 1px;
  color: var(--neon); opacity: 0.75;
}
.lcard-dim .lcard-cta { display: none; }

/* ── Pitch idle ball animation — hidden ── */
.pitch-idle-ball { display: none !important; }
.daily-score { font-family: 'Oswald', sans-serif; font-size: 36px; font-weight: 700; color: #fff; }
.daily-emoji-grid { font-size: 28px; letter-spacing: 4px; }
.daily-streak-info, .daily-rank-info { font-size: 12px; color: var(--text-dim); letter-spacing: 1px; }
.daily-day-streak-info {
  display: flex; align-items: center; gap: 6px; justify-content: center;
  font-family: 'Oswald', sans-serif; font-size: 16px; font-weight: 700;
  letter-spacing: 1px; color: #ffa726; margin: 2px 0;
}
.daily-day-streak-info .streak-flame { font-size: 18px; }
.daily-streak-badge {
  display: flex; align-items: center; gap: 5px; justify-content: center;
  margin-top: 6px; padding: 4px 10px; border-radius: 12px;
  background: rgba(255, 167, 38, 0.12); border: 1px solid rgba(255, 167, 38, 0.25);
}
.daily-streak-flame { font-size: 14px; line-height: 1; }
#daily-streak-count {
  font-family: 'Oswald', sans-serif; font-size: 15px; font-weight: 700;
  color: #ffa726;
}
.daily-streak-label {
  font-size: 11px; color: var(--text-dim); letter-spacing: 0.5px; text-transform: uppercase;
}
#daily-share-btn {
  font-family: 'Oswald', sans-serif; font-size: 14px; font-weight: 600;
  letter-spacing: 1.5px; padding: 12px 28px; border-radius: 28px;
  background: var(--neon); border: none; color: #020f02; cursor: pointer; width: 100%;
  transition: transform 0.15s;
}
#daily-share-btn:hover { transform: scale(1.03); }
.daily-back {
  font-family: 'Oswald', sans-serif; font-size: 12px; font-weight: 600;
  letter-spacing: 1px; padding: 9px 20px; border-radius: 20px;
  border: 1px solid var(--border); background: transparent; color: var(--text-mid);
  cursor: pointer; width: 100%; transition: all 0.15s;
}
.daily-back:hover { border-color: var(--neon); color: var(--neon); }

/* ── Daily History screen ── */
#daily-history-screen {
  position: fixed; inset: 0; z-index: 9000;
  display: none; justify-content: center; align-items: center;
  background: rgba(0,0,0,0.85); backdrop-filter: blur(6px);
}
#daily-history-screen.show { display: flex; }
.dh-card {
  background: var(--bg-card-solid); border: 1px solid var(--border);
  border-radius: 16px; padding: 24px 20px;
  width: 92%; max-width: 400px; max-height: 80vh;
  display: flex; flex-direction: column; gap: 12px; position: relative;
  overflow: hidden;
}
.dh-close {
  position: absolute; top: 12px; right: 14px;
  background: none; border: none; color: var(--text-dim);
  font-size: 18px; cursor: pointer; z-index: 2;
}
.dh-close:hover { color: #fff; }
.dh-title {
  font-family: 'Oswald', sans-serif; font-size: 18px; font-weight: 700;
  letter-spacing: 1.5px; color: var(--neon); text-align: center;
}
.dh-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  text-align: center; padding: 8px 0; border-bottom: 1px solid var(--border);
}
.dh-stat-box { display: flex; flex-direction: column; gap: 2px; }
.dh-stat-val {
  font-family: 'Oswald', sans-serif; font-size: 22px; font-weight: 700; color: #fff;
}
.dh-stat-label {
  font-size: 9px; font-weight: 600; letter-spacing: 1px; color: var(--text-dim);
  text-transform: uppercase;
}
.dh-list {
  display: flex; flex-direction: column; gap: 8px;
  overflow-y: auto; flex: 1; padding-right: 4px;
  min-height: 0;
}
.dh-list::-webkit-scrollbar { width: 4px; }
.dh-list::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
.dh-row {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 10px;
  background: rgba(255,255,255,0.04); border: 1px solid var(--border);
}
.dh-row-date {
  font-family: 'Oswald', sans-serif; font-size: 11px; font-weight: 600;
  letter-spacing: 0.5px; color: var(--text-mid); min-width: 60px;
}
.dh-row-num {
  font-size: 9px; color: var(--text-dim); letter-spacing: 0.5px;
}
.dh-row-grid { font-size: 18px; letter-spacing: 2px; flex: 1; text-align: center; }
.dh-row-score {
  font-family: 'Oswald', sans-serif; font-size: 16px; font-weight: 700;
  color: #fff; min-width: 32px; text-align: right;
}
.dh-row-perfect .dh-row-score { color: var(--neon); }
.dh-empty {
  font-size: 13px; color: var(--text-dim); text-align: center;
  padding: 24px 0; display: none;
}
.dh-empty.show { display: block; }

/* ── Tip Jar modal ── */
#tipjar { flex-direction: column; align-items: center; text-align: center; gap: 14px; padding: 40px 32px; }
.tipjar-icon { font-size: 40px; line-height: 1; }
#tipjar h2 { font-family: 'Oswald', sans-serif; font-size: 22px; font-weight: 700; letter-spacing: 1px; color: var(--neon); margin: 0; }
#tipjar p { font-size: 13px; color: var(--text-mid); max-width: 280px; line-height: 1.6; margin: 0; }
.kofi-cta-btn {
  display: inline-block;
  font-family: 'Oswald', sans-serif; font-size: 15px; font-weight: 700; letter-spacing: 1.5px;
  padding: 13px 32px; border-radius: 30px;
  background: #FF5E5B; color: #fff; border: none;
  text-decoration: none; cursor: pointer;
  transition: transform 0.12s, box-shadow 0.12s;
  box-shadow: 0 0 18px rgba(255,94,91,0.45);
}
.kofi-cta-btn:hover { transform: translateY(-2px); box-shadow: 0 0 28px rgba(255,94,91,0.65); }
.close-tip {
  font-family: 'Oswald', sans-serif; font-size: 11px; font-weight: 600; letter-spacing: 1.5px;
  padding: 8px 22px; border-radius: 20px;
  border: 1px solid var(--border); background: transparent; color: var(--text-mid);
  cursor: pointer; transition: all 0.15s;
}
.close-tip:hover { border-color: var(--neon); color: var(--neon); }

/* ── Ko-fi landing button (right column, below Multiplayer) ── */
.kofi-landing-btn {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  width: 100%; padding: 11px 16px; border-radius: 12px; margin-top: 2px;
  font-family: 'Oswald', sans-serif; font-size: 13px; font-weight: 600; letter-spacing: 1px;
  background: rgba(255,94,91,0.1); border: 1px solid rgba(255,94,91,0.35); color: #FF8C8A;
  cursor: pointer; transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.kofi-landing-btn:hover { background: rgba(255,94,91,0.2); border-color: #FF5E5B; color: #fff; }
@media (max-width: 920px) { .kofi-landing-btn { display: none; } }

/* ── Ko-fi floating button (right side of game screen) ── */
.kofi-game-btn {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  z-index: 50;
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,94,91,0.15); border: 1px solid rgba(255,94,91,0.4);
  color: #FF8C8A; font-size: 18px; line-height: 1;
  cursor: pointer; transition: background 0.15s, border-color 0.15s, transform 0.15s;
  display: flex; align-items: center; justify-content: center;
  padding: 0;
}
.kofi-game-btn:hover { background: rgba(255,94,91,0.3); border-color: #FF5E5B; transform: translateY(-50%) scale(1.12); }

/* ── Ko-fi transition screen button ── */
.kofi-tr-btn {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-family: 'Oswald', sans-serif; font-size: 11px; font-weight: 600; letter-spacing: 1px;
  padding: 7px 20px; border-radius: 20px; margin: 0 auto;
  background: rgba(255,94,91,0.1); border: 1px solid rgba(255,94,91,0.3); color: #FF8C8A;
  cursor: pointer; transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.kofi-tr-btn:hover { background: rgba(255,94,91,0.22); border-color: #FF5E5B; color: #fff; }

/* Hidden top-bar (JS compat) */
#top-bar { display: none; }

/* ── Combo overlay ── */
#combo-overlay {
  position: fixed; top: 30%; left: 50%; transform: translateX(-50%);
  z-index: 300; pointer-events: none;
  font-family: 'Oswald', sans-serif; font-size: 30px; font-weight: 700;
  letter-spacing: 2px; color: #FFD700;
  text-shadow: 0 0 20px rgba(255,215,0,0.7);
  opacity: 0;
}
#combo-overlay.show {
  opacity: 1;
  animation: combo-pop 0.5s cubic-bezier(0.2,0,0,1.4);
}
@keyframes combo-pop {
  0%   { transform: translateX(-50%) scale(0.5); opacity: 0; }
  70%  { transform: translateX(-50%) scale(1.2); }
  100% { transform: translateX(-50%) scale(1); opacity: 1; }
}

/* ── Toast ── */
.toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%) translateY(70px);
  z-index: 400;
  background: rgba(2,15,2,0.97); border: 1px solid var(--border);
  border-radius: 24px; padding: 10px 22px;
  font-size: 13px; font-weight: 600; letter-spacing: 0.5px; color: var(--neon);
  font-family: 'Rajdhani', sans-serif;
  opacity: 0; transition: transform 0.3s, opacity 0.3s;
  pointer-events: none; white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── Share popover ── */
.share-popover-card {
  background: var(--bg-card-solid); border: 1px solid var(--border);
  border-radius: 18px; padding: 24px 20px;
  width: 90%; max-width: 360px;
  display: flex; flex-direction: column; gap: 9px;
}
.share-popover-title {
  font-family: 'Oswald', sans-serif; font-size: 17px; font-weight: 700;
  letter-spacing: 1.5px; color: var(--neon); margin-bottom: 0;
}
.share-popover-sub {
  font-size: 12px; color: var(--text-dim); letter-spacing: 0.3px;
  margin-bottom: 4px;
}
.share-primary-row {
  display: flex; gap: 8px;
}
.share-primary-row .share-opt-btn {
  flex: 1; justify-content: center;
}
.share-opt-btn {
  font-family: 'Oswald', sans-serif; font-size: 14px; font-weight: 600;
  letter-spacing: 1px; padding: 12px 14px; border-radius: 10px;
  border: 1px solid var(--border); background: rgba(57,255,20,0.04);
  color: #e8fce8; cursor: pointer; transition: all 0.15s;
  display: flex; align-items: center; gap: 10px;
}
.share-opt-btn:hover { transform: translateY(-1px); }
.share-icon { display: flex; align-items: center; flex-shrink: 0; }

.share-primary-cta {
  font-size: 15px; padding: 14px 12px;
}
.share-secondary {
  font-size: 12px; padding: 9px 12px; opacity: 0.75;
}
.share-secondary:hover { opacity: 1; }

/* Brand-specific share buttons */
.share-opt-whatsapp {
  border-color: rgba(37,211,102,0.35);
  background: rgba(37,211,102,0.07);
  color: #25D366;
}
.share-opt-whatsapp:hover { border-color: #25D366; background: rgba(37,211,102,0.14); }

.share-opt-tiktok {
  border-color: rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.05);
  color: #fff;
}
.share-opt-tiktok:hover { border-color: rgba(255,255,255,0.5); background: rgba(255,255,255,0.1); }

.share-opt-instagram {
  border-color: rgba(228,64,95,0.35);
  background: linear-gradient(135deg, rgba(64,93,230,0.08), rgba(228,64,95,0.08), rgba(253,188,76,0.08));
  color: #e4405f;
}
.share-opt-instagram:hover { border-color: #e4405f; background: linear-gradient(135deg, rgba(64,93,230,0.14), rgba(228,64,95,0.14), rgba(253,188,76,0.14)); }

.share-opt-twitter {
  border-color: rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.08);
  color: #fff;
}
.share-opt-twitter:hover { border-color: #fff; background: rgba(255,255,255,0.14); }

.share-opt-copy {
  border-color: var(--neon);
  background: rgba(57,255,20,0.12);
  color: var(--neon);
}
.share-opt-copy:hover { background: rgba(57,255,20,0.22); }

.share-opt-native {
  border-color: var(--neon);
  background: rgba(57,255,20,0.12);
  color: var(--neon);
  font-size: 15px;
}
.share-opt-native:hover { background: rgba(57,255,20,0.2); }

.share-popover-close {
  font-size: 12px; font-weight: 600; padding: 6px; background: none; border: none;
  color: var(--text-dim); cursor: pointer; text-align: center; transition: color 0.15s;
  font-family: 'Rajdhani', sans-serif;
}
.share-popover-close:hover { color: var(--text-mid); }

/* ── Auth buttons (Google / Apple) ── */
.auth-social-btns {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}
.auth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: 'Oswald', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1px;
  padding: 13px 18px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.18s;
  width: 100%;
}
.auth-btn-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}
.auth-btn-google {
  background: #fff;
  border: 1.5px solid rgba(255,255,255,0.25);
  color: #3c4043;
}
.auth-btn-google:hover { background: #f5f5f5; box-shadow: 0 2px 12px rgba(0,0,0,0.2); }

.auth-btn-apple {
  background: #000;
  border: 1.5px solid rgba(255,255,255,0.15);
  color: #fff;
}
.auth-btn-apple:hover { background: #1a1a1a; box-shadow: 0 2px 12px rgba(0,0,0,0.4); }

.auth-btn-soon { opacity: 0.42; cursor: not-allowed; }
.auth-btn-soon:hover { transform: none !important; box-shadow: none !important; }
.auth-soon-badge {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(57,255,20,0.12);
  color: var(--neon);
  border: 1px solid rgba(57,255,20,0.3);
  margin-left: auto;
}

.auth-btn-facebook {
  background: #1877F2;
  border: 1.5px solid #1877F2;
  color: #fff;
}
.auth-btn-facebook:hover { background: #1565d0; box-shadow: 0 2px 12px rgba(24,119,242,0.4); }

.auth-btn-phone {
  background: rgba(57,255,20,0.08);
  border: 1.5px solid rgba(57,255,20,0.35);
  color: var(--neon);
}
.auth-btn-phone:hover { background: rgba(57,255,20,0.15); box-shadow: 0 2px 12px rgba(57,255,20,0.2); }

.auth-btn[disabled] { opacity: 0.42; cursor: not-allowed; pointer-events: none; }

/* Auth button loading spinner */
@keyframes auth-spin {
  to { transform: rotate(360deg); }
}
.auth-btn.auth-btn-loading,
.auth-phone-action-btn.auth-btn-loading {
  pointer-events: none;
  opacity: 0.75;
  position: relative;
}
.auth-btn.auth-btn-loading::after,
.auth-phone-action-btn.auth-btn-loading::after {
  content: '';
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 15px;
  height: 15px;
  border: 2px solid transparent;
  border-top-color: currentColor;
  border-radius: 50%;
  animation: auth-spin 0.65s linear infinite;
}

/* ── Phone OTP flow ─────────────────────────────────────── */
.auth-phone-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 4px;
}
.auth-phone-form[hidden],
#auth-phone-step1[hidden],
#auth-phone-step2[hidden],
#auth-social-section[hidden] { display: none !important; }
.auth-phone-label {
  font-size: 13px;
  color: var(--text-mid);
  text-align: center;
  margin: 0 0 2px;
}
.phone-input-wrap {
  display: flex;
  gap: 8px;
}
.phone-country-select {
  background: var(--card);
  border: 1.5px solid var(--border);
  color: var(--text);
  border-radius: 10px;
  padding: 12px 8px;
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  width: 110px;
  flex-shrink: 0;
  cursor: pointer;
}
.phone-country-select:focus { border-color: var(--neon); outline: none; }
.phone-number-input {
  flex: 1;
  background: var(--card);
  border: 1.5px solid var(--border);
  color: var(--text);
  border-radius: 10px;
  padding: 12px 14px;
  font-family: 'Oswald', sans-serif;
  font-size: 15px;
  letter-spacing: 1px;
}
.phone-number-input:focus { border-color: var(--neon); outline: none; }
.phone-number-input::placeholder { color: var(--text-dim); font-size: 13px; }
.phone-otp-input {
  width: 100%;
  background: var(--card);
  border: 1.5px solid var(--border);
  color: var(--text);
  border-radius: 10px;
  padding: 14px;
  font-family: 'Oswald', sans-serif;
  font-size: 22px;
  letter-spacing: 8px;
  text-align: center;
  box-sizing: border-box;
}
.phone-otp-input:focus { border-color: var(--neon); outline: none; }
.phone-otp-input::placeholder { color: var(--text-dim); letter-spacing: 4px; font-size: 14px; }
.auth-phone-action-btn {
  width: 100%;
  background: var(--neon);
  color: #020f02;
  border: none;
  border-radius: 10px;
  padding: 14px;
  font-family: 'Oswald', sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 2px;
  cursor: pointer;
  transition: opacity 0.15s;
}
.auth-phone-action-btn:hover { opacity: 0.88; }
.auth-phone-action-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.auth-phone-back-btn {
  background: none;
  border: none;
  color: var(--text-dim);
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  letter-spacing: 1px;
  cursor: pointer;
  text-align: center;
  padding: 4px 0;
  text-decoration: underline;
  display: block;
  width: 100%;
}
.auth-phone-back-btn:hover { color: var(--text); }
.auth-phone-msg {
  font-size: 12px;
  text-align: center;
  min-height: 18px;
  color: var(--text-dim);
}
.auth-phone-msg.error { color: #ff5252; }
.auth-phone-msg.success { color: var(--neon); }
#recaptcha-container { display: flex; justify-content: center; margin-top: 4px; }
.prompt-subtext { font-size: 13px; color: var(--text-mid); line-height: 1.5; margin-bottom: 4px; }

.auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 0;
  color: var(--text-dim);
  font-size: 11px;
  letter-spacing: 2px;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.auth-divider span { flex-shrink: 0; }


/* ═══════════════════════════════════════════════════════════
   MOBILE RESPONSIVE  (≤ 920px — phones + tablets)
   Targets: iPhone SE (375×667) · iPhone 14/15/16 (390×844)
            iPhone Pro Max / Pixel (430×932) · Samsung (360–412px)
            iPad mini/Air portrait (768px) · other tablets < 920px
═══════════════════════════════════════════════════════════ */
@media (max-width: 920px) {
  :root { --nav-h: 0px; }

  #start-overlay {
    padding-top: 0;
    overflow: hidden;
  }
  .landing-grid {
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
    height: 100svh;
    min-height: unset;
    padding: 0;
    gap: 0;
  }
  .landing-col-left,
  .landing-col-right { display: none; }

  .landing-brand-logo { display: block; width: 60px; height: 60px; margin: 4px auto 0; }

  /* ── FLEXBOX column layout ── no position:absolute for landing elements */
  .landing-center {
    position: relative;           /* keep for pitch SVG backdrop */
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    overflow: visible;            /* #start-overlay already clips */
    padding-top: env(safe-area-inset-top, 0px);
    padding-bottom: calc(60px + env(safe-area-inset-bottom, 0px));
  }

  /* Title — fixed at top, no absolute positioning */
  .landing-title-wrap {
    position: static;
    transform: none;
    margin-top: 12px;
    flex-shrink: 0;
    text-align: center;
    width: 100%;
    pointer-events: none;
  }
  .landing-title { font-size: clamp(44px, 13vw, 68px); line-height: 0.9; }

  /* Original join counter hidden on mobile (replaced by mob-join-counter) */
  #join-counter { display: none !important; }

  /* Mobile join counter — shown inside title-wrap, directly below GOAL RUSH */
  .mob-join-counter {
    display: block !important;
    font-family: 'Oswald', sans-serif;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 2px;
    color: var(--neon);
    text-transform: uppercase;
    text-align: center;
    margin-top: 8px;
    opacity: 0;
    transition: opacity 0.5s;
  }
  .mob-join-counter.visible { opacity: 0.8; }

  /* Play button — flows naturally in column, takes remaining center space */
  .play-btn-anchor {
    position: relative;
    top: auto;
    left: auto;
    transform: none;
    z-index: 2;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 160px;
  }

  /* Stats strip — sits directly below play button */
  .mob-stats-strip {
    position: static !important;
    transform: none !important;
    top: auto !important;
    left: auto !important;
    flex-shrink: 0;
    width: calc(100% - 28px);
    margin: 0 0 8px;
  }

  /* Bottom group — howto + mode tabs + chips above mobile nav */
  .landing-bottom-group {
    position: static !important;
    bottom: auto !important;
    flex-shrink: 0;
    width: 100%;
    padding: 0 14px 8px;
    gap: 8px;
    display: flex !important;
    flex-direction: column;
    align-items: center;
  }

  /* How-to strip: tighter */
  .howto-strip {
    padding: 8px 10px;
    margin-bottom: 0;
    max-width: 100%;
  }
  .howto-icon { font-size: 22px; }
  .howto-label { font-size: 12px; }
  .howto-desc { font-size: 12px; }

  /* Iris origin for mobile */
  #game-container { clip-path: circle(0% at 50% 50%); }
  #game-container.iris-open { clip-path: circle(160% at 50% 50%); }

  /* Exit button clears notch */
  #exit-btn { top: calc(14px + env(safe-area-inset-top, 0px)); }

  /* Mobile nav: home indicator safe area */
  #mobile-nav {
    padding-bottom: env(safe-area-inset-bottom, 0px);
    height: calc(60px + env(safe-area-inset-bottom, 0px));
  }
  .mnav-btn { padding: 8px 4px; }

  /* Game controls tighter on mobile */
  .circ-btn { width: 76px; height: 76px; }
  .circ-icon { font-size: 22px; }
  #ring-timer { width: 96px; height: 96px; }
  #countdown-num { font-size: 32px; }
  #guess-area { gap: 14px; }
  #skip-btn { bottom: 165px; }

  /* Transition buttons — wrap in 2 columns instead of full stack */
  .transition-btns { flex-direction: row; flex-wrap: wrap; gap: 8px; justify-content: center; max-width: 340px; }
  .tr-btn { padding: 10px 20px; font-size: 13px; justify-content: center; flex: 0 0 auto; }
  .tr-btn-next { flex: 1 1 100%; }

  /* Transition screen compact for portrait mobile — top inset ensures first element is always visible */
  #transition-screen {
    padding: max(4dvh, calc(env(safe-area-inset-top, 0px) + 16px)) 16px 20px;
    gap: 0;
    -webkit-overflow-scrolling: touch;
  }
  .tr-result { font-size: 56px; margin-bottom: 4px; }
  .tr-streak { font-size: 18px; }
  .transition-body { gap: 6px; margin-bottom: 12px; }
  .tr-scorecard { padding: 8px 12px; }
  .kofi-tr-btn { font-size: 11px; padding: 6px 14px; margin-top: 6px; }
}

/* ═══════════════════════════════════════════════════════════
   TABLET  (768px – 920px — iPad Mini portrait, large phones)
   Single-column mobile layout, but with more breathing room.
═══════════════════════════════════════════════════════════ */
@media (min-width: 768px) and (max-width: 920px) {
  /* Larger title benefits from the extra width */
  .landing-title { font-size: clamp(60px, 10vw, 84px); }

  /* Wider play button wrap gives a more tablet-native feel */
  .play-btn-wrap { width: 148px; height: 148px; }
  .play-btn      { width: 116px; height: 116px; }
  .play-btn-icon { font-size: 38px; }
  .play-label    { font-size: 15px; letter-spacing: 3px; }

  /* Stats strip: use more of the tablet width */
  .mob-stats-strip  { width: calc(100% - 60px); max-width: 560px; }
  .mob-stat-val     { font-size: 24px; }
  .mob-stat-label   { font-size: 11px; }

  /* How-to strip: wider and more readable */
  .howto-strip { max-width: 560px; padding: 12px 20px; }
  .howto-icon  { font-size: 26px; }
  .howto-label { font-size: 13px; }
  .howto-desc  { font-size: 13px; }

  /* Mobile join counter: slightly larger on tablet */
  .mob-join-counter { font-size: 15px; letter-spacing: 2.5px; }

  /* Bottom group: give a bit more vertical padding */
  .landing-bottom-group { padding: 0 30px 12px; }
}

/* ═══════════════════════════════════════════════════════════
   SMALL PHONES  (≤ 390px — iPhone SE, Samsung A-series)
═══════════════════════════════════════════════════════════ */
@media (max-width: 390px) {
  .landing-title { font-size: clamp(40px, 12vw, 56px); }
  .play-btn-wrap { width: 110px; height: 110px; }
  .play-btn { width: 84px; height: 84px; }
  .play-btn-icon { font-size: 28px; }
  .play-label { font-size: 12px; }
  .howto-strip { padding: 7px 8px; }
  .howto-icon { font-size: 20px; }
  .howto-step { gap: 4px; }
}

/* ── Very small (≤375px — iPhone SE, 360px Androids) ── */
@media (max-width: 375px) {
  .landing-title { font-size: 44px; }
  .mob-stats-strip { display: none !important; }
  .circ-btn { width: 66px; height: 66px; }
  .circ-icon { font-size: 19px; }
  #ring-timer { width: 80px; height: 80px; }
  #countdown-num { font-size: 26px; }
  #guess-area { gap: 10px; }
}

/* ═══════════════════════════════════════════════════════════
   LANDSCAPE PHONES  (height ≤ 500px — any phone rotated)
   iPhone 14/15/16 landscape: 844×390, Galaxy S24: 780×360
═══════════════════════════════════════════════════════════ */
@media (max-height: 500px) and (max-width: 932px) {
  .landing-center {
    padding-top: env(safe-area-inset-top, 0px);
    padding-bottom: calc(48px + env(safe-area-inset-bottom, 0px));
  }
  .landing-title { font-size: clamp(28px, 5vh, 38px); line-height: 0.85; }
  .landing-title-wrap { margin-top: 4px; }
  .play-btn-wrap { width: 86px; height: 86px; }
  .play-btn { width: 66px; height: 66px; }
  .play-btn-icon { font-size: 22px; }
  .play-label { display: none !important; }
  .howto-strip { padding: 5px 10px; }
  .howto-icon { font-size: 18px; }
  .howto-label { font-size: 12px; }
  .howto-desc { display: none; }
  .mob-stats-strip { display: none !important; }
  #mobile-nav {
    height: calc(48px + env(safe-area-inset-bottom, 0px));
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .mnav-icon { font-size: 16px; }
  .mnav-label { font-size: 12px; }

  /* ── Game controls — compact for landscape phones ── */
  #controls { padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px)); gap: 4px; }
  .circ-btn { width: 52px; height: 52px; }
  .circ-icon { font-size: 16px; }
  .circ-label { font-size: 9px; letter-spacing: 0.5px; }
  #ring-timer { width: 58px; height: 58px; }
  #countdown-num { font-size: 22px; }
  #guess-area { gap: 8px; }
  #lives-display { gap: 2px; margin-bottom: 0; }
  .life-heart { font-size: 14px; }
  #mobile-streak-pill { font-size: 10px; padding: 2px 8px; }
  #exit-btn { padding: 5px 10px 5px 8px; font-size: 11px; top: 6px; left: 6px; gap: 4px; }
  #context-badge { top: 6px; font-size: 11px; padding: 4px 12px; }
  #skip-btn { bottom: 110px; font-size: 12px; padding: 6px 16px; }
  .kofi-game-btn, .game-share-fab { width: 32px; height: 32px; font-size: 14px; }

  /* Transition screen compact landscape */
  .tr-brand-logo { display: none; }
  #transition-screen { padding: 3dvh 16px 16px; overflow-y: auto; }
  .tr-result { font-size: 48px; margin-bottom: 4px; }
  .tr-streak { font-size: 16px; }
  .tr-diff, .tr-round { font-size: 10px; }
  .transition-btns { flex-direction: row; gap: 8px; flex-wrap: wrap; justify-content: center; }
  .tr-btn { padding: 8px 20px; font-size: 12px; }
  .tr-scorecard { padding: 6px 12px; min-width: unset; }
  .tr-live-stats { padding: 4px 10px; }
  .kofi-tr-btn { font-size: 11px; padding: 5px 12px; margin-top: 4px; }
}

/* ═══════════════════════════════════════════════════════════
   TABLET  (921px – 1100px) — compact 3-column, centre stays
   mathematically centred on the pitch SVG at all widths.
═══════════════════════════════════════════════════════════ */
@media (min-width: 921px) and (max-width: 1100px) {
  .landing-grid {
    grid-template-columns: 160px 1fr 160px;
    padding: 12px;
    gap: 12px;
  }
  .lcard { padding: 12px 10px; }
  .lcard-title { font-size: 12px; letter-spacing: 1.5px; }
  .landing-title { font-size: clamp(44px, 5.5vw, 72px); }
  .howto-strip { max-width: 280px; }
}

/* ═══════════════════════════════════════════════════════════
   HOW TO PLAY — always-visible strip above mode tabs
═══════════════════════════════════════════════════════════ */
.howto-strip {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 12px 14px;
  background: rgba(57,255,20,0.04);
  border: 1px solid rgba(57,255,20,0.12);
  border-radius: 12px;
  width: 100%;
  max-width: 320px;
  margin-bottom: 8px;
}

/* keep class for any leftover refs */
.mobile-howto {
  display: none;
}
.howto-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex: 1;
}
.howto-icon {
  font-size: 28px;
  line-height: 1;
}
.howto-label {
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--neon);
}
.howto-desc {
  font-size: 12px;
  color: var(--text-dim);
  text-align: center;
  line-height: 1.3;
}
.howto-arrow {
  font-size: 16px;
  color: rgba(57,255,20,0.3);
  padding: 0 4px;
  margin-bottom: 18px;
}

/* ═══════════════════════════════════════════════════════════
   MOBILE GUESS PREVIEW (landing dead-zone filler)
═══════════════════════════════════════════════════════════ */
.mobile-guess-preview {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-top: 24px;
  pointer-events: none;
}
.mgp-hint {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-dim);
  text-transform: uppercase;
}
.mgp-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 36px;
}
.mgp-vs {
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--text-dim);
  opacity: 0.5;
}
.mgp-btn {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 2.5px solid;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  opacity: 0.55;
}
.mgp-miss {
  border-color: var(--red);
  background: radial-gradient(circle at 38% 38%, rgba(239,68,68,0.16), rgba(2,15,2,0.88));
  box-shadow: 0 0 12px rgba(239,68,68,0.2);
}
.mgp-goal {
  border-color: var(--neon);
  background: radial-gradient(circle at 38% 38%, rgba(57,255,20,0.16), rgba(2,15,2,0.88));
  box-shadow: 0 0 12px rgba(57,255,20,0.2);
}
.mgp-icon { font-size: 24px; line-height: 1; }
.mgp-lbl {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
}
.mgp-miss .mgp-lbl { color: var(--red); }
.mgp-goal .mgp-lbl { color: var(--neon); }

/* ═══════════════════════════════════════════════════════════
   STICKY MOBILE BOTTOM NAV
═══════════════════════════════════════════════════════════ */
#mobile-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 300;
  grid-template-columns: repeat(4, 1fr);
  height: 60px;
  background: rgba(2,10,2,0.97);
  border-top: 1px solid rgba(57,255,20,0.18);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.mnav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px 4px;
  color: var(--text-dim);
  transition: color 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.mnav-btn:active,
.mnav-btn:focus { color: var(--neon); }
.mnav-icon { font-size: 18px; line-height: 1; }
.mnav-label {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.mnav-btn-play {
  color: var(--neon);
}
.mnav-btn-play .mnav-icon { font-size: 22px; }

/* Show mobile-only elements on narrow screens (override base display:none rules above) */
@media (max-width: 920px) {
  #mobile-nav           { display: grid; }
  #mobile-streak-pill   { display: flex; }
  /* .mobile-guess-preview intentionally hidden — new layout has no dead zone */
}

/* ═══════════════════════════════════════════════════════════
   MOBILE STREAK PILL — in-game controls bar
═══════════════════════════════════════════════════════════ */
#mobile-streak-pill {
  display: none;
  align-items: center;
  gap: 2px;
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--neon);
  padding: 3px 11px;
  background: rgba(57,255,20,0.09);
  border: 1px solid rgba(57,255,20,0.25);
  border-radius: 20px;
  line-height: 1;
  min-width: 48px;
  justify-content: center;
}

/* ═══════════════════════════════════════════════════════════
   CORNER CARDS — fade during guess phase
═══════════════════════════════════════════════════════════ */
.cc {
  transition: opacity 0.4s ease;
}
.cc.cc-faded {
  opacity: 0 !important;
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════
   DAILY COUNTDOWN
═══════════════════════════════════════════════════════════ */
.daily-countdown-wrap {
  margin: 10px 0 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.daily-countdown-label {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2.5px;
  color: var(--text-dim);
  text-transform: uppercase;
}
.daily-countdown {
  font-family: 'Oswald', 'Courier New', monospace;
  font-size: 28px;
  font-weight: 700;
  color: var(--neon);
  letter-spacing: 3px;
  text-shadow: 0 0 16px rgba(57,255,20,0.45);
  line-height: 1;
}

/* ═══════════════════════════════════════════════════════════
   STREAK REVIVAL BUTTON (Game Over)
═══════════════════════════════════════════════════════════ */
.gameover-revive-btn {
  background: linear-gradient(135deg, rgba(255,140,0,0.14), rgba(255,80,0,0.08));
  border: 2px solid rgba(255,140,0,0.55);
  color: #ffaa33;
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 2px;
  padding: 14px 24px;
  border-radius: 8px;
  cursor: pointer;
  width: 100%;
  max-width: 320px;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
  text-transform: uppercase;
  animation: revive-pulse 2.2s ease-in-out infinite;
}
.gameover-revive-btn:hover {
  transform: scale(1.04);
  box-shadow: 0 0 22px rgba(255,140,0,0.35);
  border-color: rgba(255,140,0,0.8);
}
.gameover-revive-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  animation: none;
}
@keyframes revive-pulse {
  0%,100% { box-shadow: 0 0 0 rgba(255,140,0,0); }
  50% { box-shadow: 0 0 18px rgba(255,140,0,0.4); }
}

/* ═══════════════════════════════════════════════════════════
   FOCUS / A11Y
═══════════════════════════════════════════════════════════ */
:focus-visible { outline: 2px solid var(--neon); outline-offset: 3px; }
button:focus-visible { outline: 2px solid var(--neon); }

/* ═══════════════════════════════════════════════════════════
   JOIN COUNTER — social proof on landing
═══════════════════════════════════════════════════════════ */
.join-counter {
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-dim);
  text-transform: uppercase;
  text-align: center;
  padding: 6px 14px;
  margin: 0 auto 6px;
  opacity: 0;
  transition: opacity 0.5s;
}
.join-counter.visible { opacity: 1; }
.mob-join-counter { display: none; }

/* score-pop removed */

/* ═══════════════════════════════════════════════════════════
   SPEED BADGE — in transition screen
═══════════════════════════════════════════════════════════ */
.tr-speed-badge {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 20px;
  display: inline-block;
  margin: 4px auto;
  opacity: 0;
  transition: opacity 0.3s;
}
.tr-speed-badge.show { opacity: 1; }
.tr-speed-badge.instant {
  background: rgba(57,255,20,0.12);
  border: 1px solid rgba(57,255,20,0.4);
  color: var(--neon);
  text-shadow: 0 0 8px rgba(57,255,20,0.5);
}
.tr-speed-badge.sharp {
  background: rgba(0,229,255,0.1);
  border: 1px solid rgba(0,229,255,0.3);
  color: #00e5ff;
}
.tr-speed-badge.patient {
  background: rgba(160,160,160,0.1);
  border: 1px solid rgba(160,160,160,0.25);
  color: #aaa;
}

/* ── Transition auto-advance progress bar + countdown ── */
.tr-progress-wrap {
  width: 220px;
  height: 3px;
  background: rgba(57,255,20,0.12);
  border-radius: 2px;
  overflow: hidden;
  margin: 14px auto 0;
}
.tr-progress-fill {
  height: 100%;
  width: 100%;
  background: var(--neon);
  border-radius: 2px;
  transform-origin: left;
}
.tr-progress-fill.counting {
  animation: tr-shrink 5s linear forwards;
}
@keyframes tr-shrink {
  from { width: 100%; }
  to   { width: 0%; }
}
.tr-countdown {
  font-family: 'Oswald', sans-serif;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 3px;
  color: #ef4444;
  margin-top: 10px;
  min-height: 40px;
  text-align: center;
  text-shadow: 0 0 12px rgba(239,68,68,0.5);
  animation: tr-countdown-pulse 1s ease-in-out infinite;
}
@keyframes tr-countdown-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(1.08); }
}
/* ═══════════════════════════════════════════════════════════
   STREAK MILESTONE OVERLAY — cinematic at 5 / 10 / 25
═══════════════════════════════════════════════════════════ */
#streak-milestone {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  opacity: 0;
  background: transparent;
}
#streak-milestone.show {
  animation: milestone-bg 2.4s ease-in-out forwards;
}
@keyframes milestone-bg {
  0%   { opacity: 0; background: rgba(0,0,0,0); }
  15%  { opacity: 1; background: rgba(0,0,0,0.65); }
  75%  { opacity: 1; background: rgba(0,0,0,0.65); }
  100% { opacity: 0; background: rgba(0,0,0,0); }
}
#streak-milestone-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
  padding: 32px 48px;
  border-radius: 20px;
  transform: scale(0.6);
  transition: none;
}
#streak-milestone.show #streak-milestone-inner {
  animation: milestone-pop 2.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}
@keyframes milestone-pop {
  0%   { transform: scale(0.4); opacity: 0; }
  18%  { transform: scale(1.12); opacity: 1; }
  30%  { transform: scale(0.95); }
  40%  { transform: scale(1); }
  80%  { transform: scale(1); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0; }
}
.milestone-icon {
  font-size: 72px;
  line-height: 1;
  filter: drop-shadow(0 0 20px currentColor);
}
.milestone-title {
  font-family: 'Oswald', sans-serif;
  font-size: clamp(38px, 8vw, 64px);
  font-weight: 700;
  letter-spacing: 4px;
  text-transform: uppercase;
  line-height: 1;
}
.milestone-sub {
  font-family: 'Rajdhani', sans-serif;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  opacity: 0.8;
}
/* colour themes per milestone */
.milestone-fire  { color: #ff6b00; text-shadow: 0 0 30px rgba(255,107,0,0.7); }
.milestone-neon  { color: var(--neon); text-shadow: 0 0 30px rgba(57,255,20,0.8); }
.milestone-gold  { color: #FFD700; text-shadow: 0 0 30px rgba(255,215,0,0.8); }

/* ═══════════════════════════════════════════════════════════
   TROPHIES — profile collectible cards
═══════════════════════════════════════════════════════════ */
.prof-trophies {
  width: 100%;
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.prof-trophies-title {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--text-dim);
  text-align: center;
  margin-bottom: 10px;
}
.prof-trophies-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
.trophy-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 6px;
  border-radius: 10px;
  background: rgba(57,255,20,0.05);
  border: 1px solid rgba(57,255,20,0.15);
  transition: transform 0.15s, box-shadow 0.15s;
}
.trophy-card.locked {
  background: rgba(255,255,255,0.03);
  border-color: rgba(255,255,255,0.06);
  opacity: 0.4;
  filter: grayscale(1);
}
.trophy-card.unlocked {
  background: rgba(57,255,20,0.07);
  border-color: rgba(57,255,20,0.28);
  box-shadow: 0 0 12px rgba(57,255,20,0.1);
}
.trophy-card.unlocked:hover { transform: scale(1.06); }
.trophy-emoji { font-size: 26px; line-height: 1; }
.trophy-name {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-align: center;
  color: var(--text-mid);
  line-height: 1.2;
}
.trophy-req {
  font-size: 12px;
  color: var(--text-dim);
  text-align: center;
}

/* ═══════════════════════════════════════════════════════════
   SHARE CARD CANVAS — in share popover
═══════════════════════════════════════════════════════════ */
.share-card-canvas {
  width: 100%;
  max-width: 360px;
  height: auto;
  border-radius: 10px;
  display: block;
  margin: 0 auto 6px;
  border: 1px solid rgba(57,255,20,0.2);
}
.share-card-dl {
  display: block;
  text-align: center;
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-dim);
  text-decoration: none;
  margin-bottom: 10px;
  cursor: pointer;
  transition: color 0.15s;
}
.share-card-dl:hover { color: var(--neon); }


/* ═══════════════════════════════════════════════════════════
   ULTRA-WIDE AMBIENT MODE — 1440px+
   Animated crowd silhouettes extend the pitch edge-to-edge
═══════════════════════════════════════════════════════════ */
@media (min-width: 1440px) {
  #start-overlay { overflow: hidden; }

  #start-overlay::before,
  #start-overlay::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 160px;
    z-index: 0;
    pointer-events: none;
    background-repeat: repeat-x;
    background-position: bottom center;
    background-size: 80px auto;
    animation: crowd-sway 3.2s ease-in-out infinite alternate;
  }

  #start-overlay::before {
    left: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 80 120' width='80' height='120'%3E%3Cg fill='%2339FF14' opacity='0.09'%3E%3Cellipse cx='12' cy='108' rx='8' ry='10'/%3E%3Cellipse cx='12' cy='90' rx='5' ry='14'/%3E%3Cellipse cx='28' cy='110' rx='9' ry='8'/%3E%3Cellipse cx='28' cy='93' rx='5' ry='13'/%3E%3Cellipse cx='44' cy='106' rx='8' ry='10'/%3E%3Cellipse cx='44' cy='89' rx='5' ry='12'/%3E%3Cellipse cx='60' cy='109' rx='8' ry='9'/%3E%3Cellipse cx='60' cy='92' rx='5' ry='13'/%3E%3C/g%3E%3C/svg%3E");
    mask-image: linear-gradient(to right, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to right, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
  }

  #start-overlay::after {
    right: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 80 120' width='80' height='120'%3E%3Cg fill='%2339FF14' opacity='0.09'%3E%3Cellipse cx='12' cy='108' rx='8' ry='10'/%3E%3Cellipse cx='12' cy='90' rx='5' ry='14'/%3E%3Cellipse cx='28' cy='110' rx='9' ry='8'/%3E%3Cellipse cx='28' cy='93' rx='5' ry='13'/%3E%3Cellipse cx='44' cy='106' rx='8' ry='10'/%3E%3Cellipse cx='44' cy='89' rx='5' ry='12'/%3E%3Cellipse cx='60' cy='109' rx='8' ry='9'/%3E%3Cellipse cx='60' cy='92' rx='5' ry='13'/%3E%3C/g%3E%3C/svg%3E");
    mask-image: linear-gradient(to left, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to left, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
    animation-delay: -1.6s;
  }
}

@keyframes crowd-sway {
  0%   { transform: scaleX(1) translateY(0); }
  40%  { transform: scaleX(1.02) translateY(-3px); }
  100% { transform: scaleX(0.98) translateY(2px); }
}

/* ═══════════════════════════════════════════════════════════
   PWA INSTALL BANNER — add to home screen prompt
═══════════════════════════════════════════════════════════ */
#pwa-install-banner {
  position: fixed;
  bottom: 0;
  left: 0; right: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: rgba(6, 24, 6, 0.97);
  border-top: 1px solid rgba(57,255,20,0.25);
  backdrop-filter: blur(12px);
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
#pwa-install-banner.show { transform: translateY(0); }
.pwa-banner-text {
  flex: 1;
  font-family: 'Rajdhani', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #c0dfc0;
  letter-spacing: 0.3px;
}
.pwa-banner-btn {
  background: var(--neon);
  color: #020f02;
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  flex-shrink: 0;
}
.pwa-banner-close {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 16px;
  cursor: pointer;
  padding: 4px 6px;
  flex-shrink: 0;
  line-height: 1;
}
@media (max-width: 920px) {
  #pwa-install-banner { padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px)); }
}
@media (min-width: 921px) {
  #pwa-install-banner {
    top: 0;
    bottom: auto;
    border-top: none;
    border-bottom: 1px solid rgba(57,255,20,0.25);
    transform: translateY(-100%);
  }
  #pwa-install-banner.show { transform: translateY(0); }
}

/* ═══════════════════════════════════════════════════════════
   MOBILE STATS STRIP — visible on phones + tablets (≤920px) only
   Shows streak / accuracy / clips so hero data is always seen
═══════════════════════════════════════════════════════════ */
.mob-stats-strip {
  display: none;
}
@media (max-width: 920px) {
  .mob-stats-strip {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    position: static;
    top: auto;
    left: auto;
    transform: none;
    background: rgba(2,15,2,0.72);
    border: 1px solid rgba(57,255,20,0.18);
    border-radius: 32px;
    padding: 8px 20px;
    backdrop-filter: blur(6px);
    white-space: nowrap;
    pointer-events: none;
  }
  .mob-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 0 14px;
  }
  .mob-stat + .mob-stat {
    border-left: 1px solid rgba(57,255,20,0.15);
  }
  .mob-stat-val {
    font-family: 'Oswald', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: var(--neon);
    line-height: 1;
  }
  .mob-stat-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 1.5px;
    color: var(--text-dim);
    text-transform: uppercase;
  }
}

/* ═══════════════════════════════════════════════════════════
   PUSH NOTIFICATION OPT-IN PROMPT
═══════════════════════════════════════════════════════════ */
#push-opt-in-prompt {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  z-index: 9990;
  width: min(340px, calc(100vw - 32px));
  background: rgba(8, 30, 8, 0.97);
  border: 1px solid rgba(57,255,20,0.3);
  border-radius: 18px;
  padding: 22px 20px 18px;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  backdrop-filter: blur(14px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
}
#push-opt-in-prompt.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.push-prompt-icon { font-size: 32px; margin-bottom: 10px; }
.push-prompt-text {
  font-family: 'Rajdhani', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: #c8e6c8;
  line-height: 1.4;
  margin: 0 0 16px;
}
.push-prompt-btns { display: flex; gap: 10px; justify-content: center; }
.push-prompt-yes {
  background: var(--neon);
  color: #020f02;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  padding: 10px 22px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
}
.push-prompt-no {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.15);
  color: var(--text-dim);
  font-family: 'Rajdhani', sans-serif;
  font-size: 13px;
  font-weight: 500;
  padding: 10px 16px;
  border-radius: 8px;
  cursor: pointer;
}

/* ═══════════════════════════════════════════════════════════
   LIVE NAV STATS — desktop nav real-time chips during play
═══════════════════════════════════════════════════════════ */
.dnav-live-stats {
  display: none;
  align-items: center;
  gap: 6px;
}
.dnav-live-streak {
  border-color: rgba(57,255,20,0.45) !important;
  color: var(--neon) !important;
}
.dnav-live-pts {
  border-color: rgba(255,215,0,0.4) !important;
  color: #FFD700 !important;
}
.dnav-live-acc {
  border-color: rgba(57,255,20,0.3) !important;
  color: var(--neon) !important;
}
/* ═══════════════════════════════════════════════════════════
   FROSTED-GLASS GUESS RESULT POPUP
═══════════════════════════════════════════════════════════ */
#guess-result-popup {
  position: absolute;
  bottom: 190px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  z-index: 62;
  width: min(300px, 88vw);
  background: rgba(2,12,2,0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(57,255,20,0.28);
  border-radius: 14px;
  padding: 14px 18px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.22s ease, transform 0.28s cubic-bezier(0.2,0,0,1.2);
  will-change: opacity, transform;
}
#guess-result-popup.grp-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
#guess-result-popup.grp-hide {
  opacity: 0;
  transform: translateX(-50%) translateY(-12px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}
#guess-result-popup.grp-correct { border-color: rgba(57,255,20,0.5); }
#guess-result-popup.grp-wrong   { border-color: rgba(239,68,68,0.5); }

.grp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.grp-icon {
  font-family: 'Oswald', sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #e8fce8;
}
.grp-correct .grp-icon { color: var(--neon); }
.grp-wrong   .grp-icon { color: #ef4444; }

.grp-badge {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  padding: 2px 8px;
  border-radius: 20px;
  opacity: 0;
  transition: opacity 0.2s;
}
.grp-badge.instant  { background: rgba(57,255,20,0.18); color: var(--neon); border: 1px solid rgba(57,255,20,0.45); opacity: 1; }
.grp-badge.sharp    { background: rgba(255,215,0,0.15); color: #FFD700;      border: 1px solid rgba(255,215,0,0.45); opacity: 1; }
.grp-badge.patient  { background: rgba(255,255,255,0.08); color: var(--text-mid); border: 1px solid var(--border); opacity: 1; }

.grp-rows {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.grp-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.grp-label {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: rgba(232,252,232,0.5);
  text-transform: uppercase;
  flex-shrink: 0;
}
.grp-val {
  font-family: 'Oswald', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: #e8fce8;
}
.grp-val-pts    { color: var(--neon); }
.grp-val-gold   { color: #FFD700; }
.grp-val-streak { color: #FF9500; }

@media (max-width: 920px) {
  #guess-result-popup {
    bottom: 230px;
    width: min(280px, 84vw);
  }
}
/* ═══════════════════════════════════════════════════════════
   TRANSITION SCREEN — live session stat chips
═══════════════════════════════════════════════════════════ */
.tr-live-stats {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin: 14px 0 4px;
}
.tr-live-stats-label {
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2.5px;
  color: var(--text-dim);
}
.tr-live-chips {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}
.tr-live-chip {
  font-family: 'Oswald', sans-serif;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.5px;
  background: rgba(57,255,20,0.08);
  border: 1px solid rgba(57,255,20,0.25);
  border-radius: 24px;
  padding: 7px 18px;
  white-space: nowrap;
}
.tr-live-streak { border-color: rgba(57,255,20,0.55); color: var(--neon); background: rgba(57,255,20,0.1); }
.tr-live-pts    { border-color: rgba(255,220,0,0.5);  color: #ffd700; background: rgba(255,220,0,0.08); }
.tr-live-acc    { border-color: rgba(99,190,255,0.5); color: #63beff; background: rgba(99,190,255,0.08); }

/* ═══════════════════════════════════════════════════════════
   GAME-OVER — share-to-revive confirmation bar
═══════════════════════════════════════════════════════════ */
.revive-confirm-bar {
  margin: 8px 0 4px;
  padding: 14px 16px;
  background: rgba(57,255,20,0.07);
  border: 1px solid rgba(57,255,20,0.3);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  animation: fade-in-up 0.25s ease;
}
.revive-confirm-bar[hidden] { display: none; }
.revive-confirm-msg {
  font-family: 'Rajdhani', sans-serif;
  font-size: 13px;
  color: rgba(232,252,232,0.75);
  margin: 0;
  text-align: center;
}
.revive-confirm-btn {
  font-family: 'Oswald', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #000;
  background: var(--neon);
  border: none;
  border-radius: 8px;
  padding: 9px 22px;
  cursor: pointer;
  width: 100%;
  max-width: 260px;
  transition: opacity 0.15s;
}
.revive-confirm-btn:hover { opacity: 0.88; }
.revive-cancel-link {
  font-family: 'Rajdhani', sans-serif;
  font-size: 12px;
  color: rgba(232,252,232,0.45);
  background: none;
  border: none;
  cursor: pointer;
  padding: 2px 8px;
}
.revive-cancel-link:hover { color: rgba(232,252,232,0.7); }

/* ═══════════════════════════════════════════════════════════
   PORTRAIT BLOCK — fullscreen wall, mobile portrait only
═══════════════════════════════════════════════════════════ */
.portrait-block {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #020f02;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.portrait-block[hidden] { display: none; }

.portrait-block-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 32px;
}

.portrait-block-icon {
  font-size: 64px;
  animation: pb-rotate 2s ease-in-out infinite;
  display: block;
}

@keyframes pb-rotate {
  0%,  35% { transform: rotate(0deg); }
  55%, 80% { transform: rotate(-90deg); }
  100%     { transform: rotate(0deg); }
}

.portrait-block-title {
  font-family: 'Oswald', sans-serif;
  font-size: clamp(22px, 6vw, 32px);
  font-weight: 700;
  color: var(--neon);
  letter-spacing: 3px;
  text-transform: uppercase;
}

.portrait-block-sub {
  font-family: 'Oswald', sans-serif;
  font-size: 14px;
  color: rgba(232,252,232,0.55);
  letter-spacing: 1px;
}

/* Desktop: never show the portrait block */
@media (min-width: 921px) {
  .portrait-block { display: none !important; }
}

/* ═══════════════════════════════════════════════════════════
   KO-FI MOBILE LANDING — show on mobile, hidden on desktop
═══════════════════════════════════════════════════════════ */
@media (max-width: 920px) {
  .kofi-mobile-landing-btn { display: block; }
  .mobile-lb-btn { display: block; }
}

/* ═══════════════════════════════════════════════════════════
   PWA TRANSITION PILL
═══════════════════════════════════════════════════════════ */
.pwa-tr-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: center;
  margin: 10px auto 0;
  background: rgba(57,255,20,0.08);
  border: 1px solid rgba(57,255,20,0.30);
  border-radius: 24px;
  padding: 8px 16px;
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  color: var(--text-mid);
  letter-spacing: 0.5px;
  max-width: 340px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s;
}
.pwa-tr-pill.show {
  opacity: 1;
  pointer-events: auto;
}
.pwa-tr-install-btn {
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  background: var(--neon);
  color: var(--bg);
  border: none;
  border-radius: 14px;
  padding: 4px 12px;
  cursor: pointer;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════
   PWA GAME-OVER INSTALL CARD
═══════════════════════════════════════════════════════════ */
.pwa-install-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: rgba(57,255,20,0.07);
  border: 1px solid rgba(57,255,20,0.25);
  border-radius: 12px;
  padding: 12px 16px;
  margin: 0 0 12px;
  width: 100%;
  box-sizing: border-box;
}
.pwa-install-card-text {
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  flex: 1;
}
.pwa-install-card-icon {
  font-size: 22px;
  flex-shrink: 0;
}
.pwa-install-card-text strong {
  display: block;
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  color: var(--neon);
  letter-spacing: 0.5px;
}
.pwa-install-card-text span {
  font-size: 11px;
  color: var(--text-mid);
  display: block;
  margin-top: 2px;
}
.pwa-install-card-btn {
  font-family: 'Oswald', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  background: var(--neon);
  color: var(--bg);
  border: none;
  border-radius: 18px;
  padding: 8px 18px;
  cursor: pointer;
  flex-shrink: 0;
  transition: opacity 0.18s;
}
.pwa-install-card-btn:hover { opacity: 0.85; }

/* ═══════════════════════════════════════════════════════════
   PWA LANDING INSTALL BUTTON
═══════════════════════════════════════════════════════════ */
.pwa-landing-install-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.8px;
  color: var(--neon);
  background: rgba(57,255,20,0.08);
  border: 1px solid rgba(57,255,20,0.3);
  border-radius: 20px;
  padding: 8px 20px;
  cursor: pointer;
  transition: background 0.18s, border-color 0.18s;
  margin-top: 6px;
}
.pwa-landing-install-btn:hover {
  background: rgba(57,255,20,0.16);
  border-color: rgba(57,255,20,0.5);
}

/* ═══════════════════════════════════════════════════════════
   MR BEAST VIRALITY — slam, heartbeat, crowd, milestones
═══════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════
   SLAM OVERLAY — ring burst from center + scale-in icon/text
═══════════════════════════════════════════════════════════ */
#slam-overlay {
  position: absolute;
  inset: 0;
  z-index: 600;
  display: none; /* truly hidden — removed from accessibility tree */
  align-items: center;
  justify-content: center;
  pointer-events: none;
  /* CSS custom props toggled by JS classes */
  --slam-color: #39FF14;
  --slam-glow:  rgba(57, 255, 20, 0.75);
}
#slam-overlay.slam-correct { --slam-color: #39FF14; --slam-glow: rgba(57,255,20,0.75); }
#slam-overlay.slam-wrong   { --slam-color: #ff3535; --slam-glow: rgba(255,53,53,0.75); }

/* Visible while slam-in, fades out on slam-out */
#slam-overlay.slam-in  { display: flex; opacity: 1; }
#slam-overlay.slam-out { display: flex; animation: slamOverlayOut 0.28s ease-in forwards; }

@keyframes slamOverlayOut {
  0%   { opacity: 1; }
  100% { opacity: 0; }
}

/* ── Rings ── */
.slam-rings {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.slam-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  width: 70px; height: 70px;
  border-radius: 50%;
  border: 2.5px solid var(--slam-color);
  box-shadow: 0 0 8px var(--slam-glow);
  opacity: 0;
}
#slam-overlay.slam-in .slam-ring-1 { animation: slamRing 1s ease-out   0ms both; }
#slam-overlay.slam-in .slam-ring-2 { animation: slamRing 1s ease-out 160ms both; }
#slam-overlay.slam-in .slam-ring-3 { animation: slamRing 1s ease-out 320ms both; }
#slam-overlay.slam-in .slam-ring-4 { animation: slamRing 1s ease-out 480ms both; }
#slam-overlay.slam-in .slam-ring-5 { animation: slamRing 1s ease-out 640ms both; }
@keyframes slamRing {
  0%   { transform: scale(0.1); opacity: 1; }
  65%  { opacity: 0.45; }
  100% { transform: scale(5.5); opacity: 0; }
}

/* ── Impact flash ── */
.slam-flash {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(circle at 50% 50%, var(--slam-color) 0%, transparent 65%);
  opacity: 0;
  pointer-events: none;
}
#slam-overlay.slam-in .slam-flash { animation: slamFlash 0.7s ease-out both; }
@keyframes slamFlash {
  0%   { opacity: 0; }
  8%   { opacity: 0.22; }
  100% { opacity: 0; }
}

/* ── Icon + word ── */
.slam-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  opacity: 0;
}
#slam-overlay.slam-in .slam-content { animation: slamContentIn 0.55s cubic-bezier(0.22,1,0.36,1) 0.08s both; }
@keyframes slamContentIn {
  0%   { transform: scale(0.05); opacity: 0; }
  45%  { transform: scale(1.16); opacity: 1; }
  65%  { transform: scale(0.93); }
  82%  { transform: scale(1.05); }
  100% { transform: scale(1); opacity: 1; }
}
.slam-icon {
  font-size: 80px;
  line-height: 1;
  filter: drop-shadow(0 0 20px var(--slam-glow));
}
.slam-word {
  font-family: 'Oswald', 'Impact', sans-serif;
  font-size: clamp(48px, 8vw, 72px);
  font-weight: 900;
  letter-spacing: 4px;
  line-height: 1;
  color: var(--slam-color);
  text-shadow: 0 0 28px var(--slam-glow), 0 0 60px var(--slam-glow);
}

/* ── Screen-shake on wrong answer ── */
@keyframes screenShake {
  0%,100% { transform: translateX(0); }
  15%     { transform: translateX(-8px) rotate(-0.6deg); }
  30%     { transform: translateX(8px)  rotate(0.6deg); }
  45%     { transform: translateX(-6px); }
  60%     { transform: translateX(6px); }
  75%     { transform: translateX(-3px); }
  90%     { transform: translateX(3px); }
}
#game-container.screen-shake {
  animation: screenShake 0.45s ease-in-out;
}

/* ── Heartbeat vignette pulse ── */
@keyframes vignettePulse {
  0%,100% { box-shadow: inset 0 0 0 rgba(57,255,20,0); }
  50%     { box-shadow: inset 0 0 80px rgba(57,255,20,0.22); }
}
#game-container.vignette-pulse {
  animation: vignettePulse 0.5s ease-in-out infinite;
}

/* ── Crowd accuracy line on transition ── */
#transition-crowd-accuracy {
  font-family: 'Oswald', sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.8px;
  color: var(--text-mid);
  text-align: center;
  margin-top: 6px;
  min-height: 20px;
}

/* ── Milestone neon particle burst ── */
.milestone-particle {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--neon);
  pointer-events: none;
  animation: particleScatter var(--dur, 1.2s) ease-out forwards;
  transform-origin: center;
  opacity: 1;
}
@keyframes particleScatter {
  0%   { transform: translate(0,0) scale(1); opacity: 1; }
  100% { transform: translate(var(--tx), var(--ty)) scale(0); opacity: 0; }
}
#streak-milestone {
  position: relative;
  overflow: hidden;
}
.milestone-streak-num {
  font-family: 'Oswald', 'Impact', sans-serif;
  font-size: 80px;
  font-weight: 900;
  color: var(--neon);
  text-shadow: 0 0 30px rgba(57,255,20,0.8), 0 0 60px rgba(57,255,20,0.4);
  line-height: 1;
  animation: milestoneNumPop 0.5s cubic-bezier(0.22,1,0.36,1) both;
}
@keyframes milestoneNumPop {
  0%   { transform: scale(0.4); opacity: 0; }
  70%  { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

/* ═══════════════════════════════════════════════════════════
   SHARE / INVITE ELEMENTS
═══════════════════════════════════════════════════════════ */

/* Desktop right-column invite card */
.lcard-invite {
  border-color: rgba(57,255,20,0.2);
}
.invite-share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 10px 16px;
  border-radius: 10px;
  margin-top: 2px;
  font-family: 'Oswald', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.5px;
  background: var(--neon-dim);
  border: 1px solid rgba(57,255,20,0.35);
  color: var(--neon);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.invite-share-btn:hover {
  background: rgba(57,255,20,0.22);
  border-color: var(--neon);
  box-shadow: var(--neon-glow);
}
@media (max-width: 920px) { .lcard-invite { display: none; } }

/* Mobile invite strip (≤920px only) — ghost/secondary, does not compete with Play */
.mob-invite-strip {
  display: none;
  margin: 6px auto 0;
  width: auto;
  padding: 6px 18px;
  border-radius: 20px;
  font-family: 'Oswald', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--text-dim);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.mob-invite-strip:hover {
  border-color: rgba(57,255,20,0.35);
  color: var(--neon);
}
@media (max-width: 920px) { .mob-invite-strip { display: block; } }

/* Transition screen invite button */
.tr-btn-invite {
  background: transparent;
  border: 2px solid rgba(57,255,20,0.35);
  color: var(--neon);
}
.tr-btn-invite:hover {
  background: var(--neon-dim);
  border-color: var(--neon);
}

/* In-game floating share FAB (left side, mirrors kofi-game-btn on right) */
.game-share-fab {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 50;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(57,255,20,0.1);
  border: 1px solid rgba(57,255,20,0.35);
  color: var(--neon);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.game-share-fab:hover {
  background: rgba(57,255,20,0.22);
  border-color: var(--neon);
  transform: translateY(-50%) scale(1.12);
}

/* ── Desktop FAB enlargement (≥921px) ── */
@media (min-width: 921px) {
  .game-share-fab {
    width: auto;
    height: 48px;
    border-radius: 24px;
    padding: 0 20px;
    font-size: 14px;
    font-family: 'Oswald', sans-serif;
    font-weight: 600;
    letter-spacing: 1px;
    gap: 8px;
  }
  .game-share-fab::after {
    content: 'SHARE';
    font-size: 13px;
    font-family: 'Oswald', sans-serif;
    font-weight: 600;
    letter-spacing: 1px;
    margin-left: 4px;
  }
  .kofi-game-btn {
    width: auto;
    height: 48px;
    border-radius: 24px;
    padding: 0 20px;
    font-size: 14px;
    font-family: 'Oswald', sans-serif;
    font-weight: 600;
    letter-spacing: 1px;
  }
  .kofi-game-btn::after {
    content: 'BUY A COFFEE';
    font-size: 13px;
    font-family: 'Oswald', sans-serif;
    font-weight: 600;
    letter-spacing: 1px;
    margin-left: 4px;
  }
  .game-share-fab:hover { transform: translateY(-50%) scale(1.04); }
  .kofi-game-btn:hover { transform: translateY(-50%) scale(1.04); }
}


/* ── CHALLENGE LANDING BANNER (v32) ──────────────────────────── */
#challenge-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9500;
  background: linear-gradient(135deg, #39FF14 0%, #00cc10 100%);
  color: #020f02;
  padding: 11px 48px 11px 16px;
  font-family: 'Rajdhani', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  transform: translateY(-100%);
  transition: transform 0.38s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
  box-shadow: 0 3px 12px rgba(57,255,20,0.35);
  line-height: 1.4;
}
#challenge-banner.show {
  transform: translateY(0);
  pointer-events: auto;
}
#challenge-banner strong {
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.challenge-banner-close {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(2,15,2,0.15);
  border: none;
  border-radius: 50%;
  color: #020f02;
  font-size: 0.85rem;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
  padding: 0;
}
.challenge-banner-close:hover { background: rgba(2,15,2,0.3); }

/* ── iOS Install popup modal ───────────────────────────────────────── */
.ios-install-popup {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.ios-install-popup[hidden] { display: none; }
.ios-install-popup-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(2px);
}
.ios-install-popup-sheet {
  position: relative;
  background: #0d1f0d;
  border: 1px solid rgba(57,255,20,0.25);
  border-radius: 20px 20px 0 0;
  width: 100%;
  max-width: 520px;
  padding: 28px 24px 40px;
  box-shadow: 0 -8px 40px rgba(0,0,0,0.6);
}
.ios-install-popup-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(255,255,255,0.08);
  border: none;
  color: #ccc;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ios-install-popup-close:hover { background: rgba(255,255,255,0.15); color: #fff; }
.ios-install-popup-title {
  font-family: 'Oswald', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--neon);
  letter-spacing: 1px;
  margin-bottom: 20px;
  text-align: center;
}
.ios-install-popup-steps {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.ios-install-step {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(57,255,20,0.06);
  border: 1px solid rgba(57,255,20,0.15);
  border-radius: 12px;
  padding: 14px 16px;
}
.ios-install-step-icon {
  font-size: 28px;
  flex-shrink: 0;
  line-height: 1;
}
.ios-install-step-text {
  font-size: 14px;
  color: #d0d0d0;
  line-height: 1.5;
}
.ios-install-step-text strong { color: #fff; }
