/* Jump the Frog: "neon pond" theme. Dark glass cards on a gradient ink background, lime-to-cyan accents. */
/* Tropical daylight theme: sunny sky blues, lush greens, mango and coral accents, light cards with dark text. */
:root {
  --bg: #0ea5e9;
  --bg2: rgba(255, 255, 255, 0.55);
  --card: rgba(255, 255, 255, 0.86);
  --line: rgba(8, 47, 73, 0.12);
  --text: #0b2a3a;
  --muted: #4b6b7c;
  --lime: #2bb673;
  --cyan: #0891b2;
  --violet: #7c3aed;
  --pink: #ff5c8a;
  --green: #16a34a;
  --yellow: #f59e0b;
  --red: #e11d48;
  --accent: linear-gradient(135deg, #ffb703 0%, #fb7a3a 55%, #ff5c8a 100%);
  --glow: 0 12px 34px -12px rgba(251, 122, 58, 0.65);
  --font: 'Fredoka', 'Plus Jakarta Sans', 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg); color: var(--text); font-family: var(--font); line-height: 1.45; -webkit-font-smoothing: antialiased; min-height: 100vh;
  position: relative; overflow-x: hidden;
}
body::before, body::after {
  content: ''; position: fixed; z-index: -1; border-radius: 50%; filter: blur(90px); opacity: .55; pointer-events: none;
}
body::before { width: 520px; height: 520px; left: -200px; top: -200px; background: radial-gradient(circle, #ffe08a, transparent 65%); opacity: .9; }
body::after { width: 520px; height: 520px; right: -220px; top: 42vh; background: radial-gradient(circle, #5eead4, transparent 65%); opacity: .6; }
a { color: var(--cyan); text-decoration: none; }
h1, h2, .logo, .v, .btn, .jumpbtn, .prize-table .a { font-family: 'Fredoka', var(--font); letter-spacing: 0; }
.app { max-width: 430px; margin: 0 auto; padding: 14px 16px 48px; }
header { display: flex; align-items: center; justify-content: space-between; padding: 6px 0 14px; }
.logo { font-weight: 800; font-size: 20px; letter-spacing: -0.4px; }
.logo { color: #fff; text-shadow: 0 1px 2px rgba(2,48,71,.4); }
.logo span { color: #ffe08a; }
.small { font-size: 12px; color: var(--muted); }
.app > .small, .app > p.small { color: #e0f2fe; }
.app > p.small a { color: #ffe08a; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 18px; margin: 12px 0;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 1px 0 rgba(255,255,255,.6) inset, 0 18px 40px -24px rgba(2,48,71,.55);
}
h1 { font-size: 28px; font-weight: 800; letter-spacing: -1px; margin: 0 0 8px; line-height: 1.1; }
h2 { font-size: 17px; font-weight: 800; margin: 0 0 8px; letter-spacing: -0.2px; }
p { margin: 6px 0; }
label { display: block; font-size: 12px; color: var(--muted); margin: 10px 0 4px; }
input { width: 100%; background: #ffffff; border: 1px solid rgba(8,47,73,.18); color: var(--text); border-radius: 12px; padding: 12px 14px; font: inherit; font-size: 16px; }
input:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(34,211,238,.18); }
input::placeholder { color: #8aa3b2; }
.btn {
  display: inline-block; border: 0; cursor: pointer; font: inherit; font-weight: 800; letter-spacing: .1px;
  background: var(--accent); color: #fff; text-shadow: 0 1px 0 rgba(0,0,0,.15); padding: 14px 20px; border-radius: 16px; font-size: 17px; width: 100%;
  box-shadow: var(--glow); transition: transform .08s ease, filter .2s;
}
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; }
.btn.ghost { background: #ffffff; color: var(--text); border: 1px solid rgba(8,47,73,.18); box-shadow: none; }
.btn.danger { background: linear-gradient(135deg, #fb7185, #f43f5e); color: #fff; box-shadow: none; }
.err { color: var(--red); font-size: 13px; min-height: 18px; margin-top: 6px; }
.hidden { display: none !important; }

/* stats */
.row2 { display: flex; justify-content: space-between; gap: 12px; }
.row2 > div { flex: 1; }
.k { color: var(--muted); font-size: 10.5px; text-transform: uppercase; letter-spacing: 1.4px; }
.v { font-size: 30px; font-weight: 800; letter-spacing: -1px; line-height: 1.1; color: #fb7a3a; }
.row { display: flex; gap: 10px; margin-top: 12px; }
.row .btn { flex: 1; }
.stack { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.bar { height: 10px; background: rgba(0,0,0,.35); border-radius: 999px; overflow: hidden; margin: 10px 0 4px; }
.bar i { display: block; height: 100%; background: var(--accent); width: 0; transition: width .6s; }
.live { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--green); margin-right: 6px; box-shadow: 0 0 10px var(--green); animation: pulse 1.6s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

/* leaderboard */
.lbwrap { max-height: 440px; overflow-y: auto; border: 1px solid var(--line); border-radius: 14px; background: #f6fbfe; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-weight: 600; }
#lb td:first-child, #wk td:first-child { width: 52px; color: var(--muted); font-weight: 700; }
#lb tr:nth-child(1) td:first-child { color: #d9a400; } #lb tr:nth-child(2) td:first-child { color: #8a97a8; } #lb tr:nth-child(3) td:first-child { color: #b5651d; }
#lb tr.you td, #wk tr.you td { background: #fff3c4; color: #9a5b00; font-weight: 800; }
#lbLive { color: var(--green); font-weight: 700; transition: opacity .3s; }

/* game */
.stage { position: relative; border-radius: 22px; overflow: hidden; border: 3px solid #ffffff; background: #7dd3fc; box-shadow: 0 24px 50px -30px rgba(2,48,71,.7); }
canvas { display: block; width: 100%; height: auto; touch-action: none; }
.hud { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; justify-content: space-between; font-weight: 800; font-size: 13px; }
.hud span { background: rgba(255,255,255,.9); color: #0b2a3a; padding: 4px 10px; border-radius: 999px; }
.power { height: 14px; background: rgba(255,255,255,.7); border: 1px solid rgba(8,47,73,.15); border-radius: 999px; overflow: hidden; margin: 12px 0 10px; }
.power i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #2bb673, #ffb703, #fb7a3a, #ff5c8a); }
.jumpbtn {
  width: 100%; padding: 22px; font-size: 21px; font-weight: 700; border-radius: 22px; border: 0; cursor: pointer; color: #fff; text-shadow: 0 1px 0 rgba(0,0,0,.2);
  background: linear-gradient(120deg, #ffb703, #fb7a3a, #ff5c8a, #ffb703); background-size: 300% 100%; animation: shimmer 4s linear infinite;
  box-shadow: var(--glow), 0 6px 0 #c2410c; user-select: none; -webkit-user-select: none; touch-action: manipulation;
}
@keyframes shimmer { 0% { background-position: 0% 50%; } 100% { background-position: 200% 50%; } }
.jumpbtn:active { transform: translateY(4px); box-shadow: var(--glow), 0 2px 0 #c2410c; }
.jumpbtn:disabled { opacity: .5; box-shadow: none; transform: none; animation: none; }
.msg { text-align: center; font-weight: 700; min-height: 22px; margin-top: 10px; color: #fff; text-shadow: 0 1px 2px rgba(2,48,71,.5); }

/* in-game banner widget */
.adslot { display: flex; justify-content: center; align-items: center; min-height: 54px; margin: 0 0 14px; }
.adslot[hidden] { display: none; }
.banner-ph { width: 320px; height: 50px; background: #fff; color: #111; border-radius: 10px; display: flex; align-items: center; gap: 10px; padding: 0 10px; font-size: 13px; }
.banner-ph .tag { font-size: 9px; letter-spacing: 1.5px; text-transform: uppercase; color: #666; border: 1px solid #ccc; padding: 1px 4px; border-radius: 3px; }
.banner-ph b { flex: 1; font-weight: 800; }

/* ad overlay */
.adbg { position: fixed; inset: 0; background: rgba(5,6,15,.88); display: none; align-items: center; justify-content: center; padding: 16px; z-index: 100; backdrop-filter: blur(4px); }
.adbg.open { display: flex; }
.ad { width: 100%; max-width: 360px; background: #fff; color: #111; border-radius: 16px; overflow: hidden; text-align: center; }
.ad .tag { background: #f1f1f4; color: #555; font-size: 11px; text-transform: uppercase; letter-spacing: 2px; padding: 6px; }
.ad .body { padding: 36px 16px; min-height: 240px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; }
.ad .body .brand { font-size: 28px; font-weight: 800; color: #333; }
.ad .foot { padding: 10px; font-size: 13px; color: #555; border-top: 1px solid #eee; }
.ad .foot button { font: inherit; font-weight: 700; border: 0; background: #111; color: #fff; padding: 9px 16px; border-radius: 10px; cursor: pointer; }

/* prizes, unlocks, skins, wallet */
.prize-table { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 10px 0 6px; }
.prize-table div { background: #f6fbfe; border: 1px solid var(--line); border-radius: 14px; padding: 10px 8px; text-align: center; }
.prize-table .r { font-size: 10.5px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }
.prize-table .a { font-size: 20px; font-weight: 800; }
.prize-table div:first-child .a { color: #d9a400; }
.unlock { display: flex; gap: 10px; align-items: flex-start; padding: 9px 0; border-top: 1px solid var(--line); }
.unlock:first-child { border-top: 0; }
.unlock span:first-child { font-size: 18px; line-height: 1.2; }
.unlock.done b { color: var(--green); }
.skins { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.skins button { font: inherit; font-size: 12px; font-weight: 700; padding: 9px 12px; border-radius: 999px; border: 1px solid var(--line); background: #f6fbfe; color: var(--text); cursor: pointer; }
.skins button.on { border-color: var(--pink); color: #c2185b; background: #fff0f5; box-shadow: 0 0 0 3px rgba(255,92,138,.15); }
.skins button:disabled { opacity: .45; cursor: not-allowed; }
.skins button i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; box-shadow: 0 0 8px currentColor; }
.breakdown { background: #f6fbfe; border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; margin: 8px 0 4px; font-size: 14px; }
.breakdown .bl { display: flex; justify-content: space-between; padding: 4px 0; }
.breakdown .bl.total { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 8px; color: var(--green); font-size: 16px; }
.breakdown .note { font-size: 11px; color: var(--muted); padding: 0 0 6px; font-style: italic; }
.po { padding: 6px 0; border-bottom: 1px solid var(--line); }
.coins { display: inline-flex; align-items: center; gap: 6px; background: rgba(251,191,36,.15); color: var(--yellow); font-weight: 800; padding: 4px 10px; border-radius: 999px; font-size: 13px; }
.pill { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; text-transform: uppercase; }
.pill.pending { background: rgba(251,191,36,.15); color: var(--yellow); }
.pill.paid { background: rgba(52,211,153,.15); color: var(--green); }
.pill.rejected { background: rgba(251,113,133,.15); color: var(--red); }
details summary { cursor: pointer; }
mark { background: rgba(251,191,36,.2); color: var(--yellow); padding: 0 4px; border-radius: 4px; }

/* admin */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 12px 0 20px; }
.kpi { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px; }
.kpi .v { font-size: 24px; }
.kpi .k { color: var(--muted); font-size: 10.5px; text-transform: uppercase; letter-spacing: 1px; }
.mini { font-size: 11px; padding: 6px 10px; width: auto; box-shadow: none; }
.mockbox { background: rgba(251,191,36,.12); border: 1px solid rgba(251,191,36,.4); border-radius: 12px; padding: 12px; font-size: 14px; margin-top: 12px; }

/* ---- visual pass: logo, avatars, hero, coin icon ---- */
.logo { display: flex; align-items: center; gap: 8px; }
.logo .mark { display: inline-flex; width: 36px; height: 36px; border-radius: 12px; align-items: center; justify-content: center; background: #ffffff; border: 1px solid rgba(8,47,73,.12); box-shadow: 0 6px 16px -8px rgba(2,48,71,.6); }
.who { font-size: 12px; color: #0b2a3a; background: rgba(255,255,255,.85); border: 1px solid rgba(8,47,73,.12); padding: 4px 10px; border-radius: 999px; }
.av { display: inline-flex; width: 24px; height: 24px; border-radius: 50%; align-items: center; justify-content: center; margin-right: 8px; font-style: normal; font-size: 10px; font-weight: 800; color: #0b2a3a; vertical-align: middle;
  background: linear-gradient(135deg, hsl(var(--h) 90% 70%), hsl(calc(var(--h) + 40) 90% 55%)); box-shadow: 0 0 0 2px rgba(255,255,255,.06); }
#lb td.rk { font-size: 14px; } #lb td.sc { text-align: right; font-weight: 800; white-space: nowrap; }
.coin { display: inline-block; width: 11px; height: 11px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #fff2a8, #f5b800 60%, #a06a00); box-shadow: 0 0 8px rgba(245,184,0,.6); vertical-align: -1px; margin-left: 3px; }
.hero { position: relative; height: 120px; display: flex; align-items: center; justify-content: center; margin: -4px 0 8px; }
.hero-frog { width: 120px; height: 120px; object-fit: contain; position: relative; z-index: 1; animation: bob 2.6s ease-in-out infinite; filter: drop-shadow(0 18px 18px rgba(0,0,0,.5)); }
.hero-glow { position: absolute; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(255,224,138,.9), rgba(94,234,212,.3) 45%, transparent 70%); filter: blur(12px); }
@keyframes bob { 0%,100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-10px) rotate(3deg); } }
h1 .grad { color: #fb7a3a; }
body { background-image: linear-gradient(180deg, #38bdf8 0%, #0ea5e9 40%, #0284c7 100%); }
.card { transition: transform .15s ease; }
.stage { box-shadow: 0 0 0 1px rgba(255,255,255,.05), 0 40px 80px -40px rgba(34,211,238,.6), 0 0 60px -30px rgba(124,58,237,.5); }

/* ---- retention: chips, missions, icon buttons ---- */
.iconbtn { width: 34px; height: 34px; border-radius: 10px; border: 1px solid rgba(8,47,73,.12); background: rgba(255,255,255,.85); cursor: pointer; font-size: 15px; display: inline-flex; align-items: center; justify-content: center; color: var(--text); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 6px; }
.chip { font-size: 12px; font-weight: 700; padding: 5px 10px; border-radius: 999px; background: #eef7fb; border: 1px solid rgba(8,47,73,.12); color: var(--text); }
.chip.hot { background: #fff3c4; border-color: #f59e0b; color: #9a5b00; box-shadow: none; }
.mission { padding: 10px 0; border-top: 1px solid var(--line); }
.mission:first-child { border-top: 0; }
.mission .mt { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.mission .bar { margin: 6px 0; height: 8px; }
.mission.done .mt b { color: var(--green); }
.mission .btn.mini { margin-top: 2px; }
#installCard { background: linear-gradient(160deg, #fff6d5, #ffe9ef); border-color: #f59e0b; }

/* ---- toast + ad-blocker wall ---- */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: rgba(11,42,58,.95); color: #fff; border: 1px solid rgba(255,255,255,.18); padding: 12px 18px; border-radius: 999px; font-weight: 700; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; z-index: 120; max-width: 92vw; text-align: center; box-shadow: 0 10px 40px -10px rgba(255,79,216,.6); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.wall { position: fixed; inset: 0; z-index: 110; background: rgba(2,48,71,.96); color: #fff; display: flex; align-items: center; justify-content: center; padding: 20px; }
.wallbox { max-width: 380px; text-align: center; }
.wallbox h2 { font-size: 24px; margin: 8px 0; }

/* lifetime titles, winners' wall, reminders, personal-best chase */
.ttl { display: inline-block; font-size: 10px; font-weight: 800; letter-spacing: .02em; padding: 1px 7px; border-radius: 999px; margin-left: 5px; vertical-align: 1px; background: #e2f3ff; color: #075985; border: 1px solid rgba(8,47,73,.12); }
.ttl[data-t="Hopper"] { background: #dcfce7; color: #166534; }
.ttl[data-t="Leaper"] { background: #fef3c7; color: #92400e; }
.ttl[data-t="Pond King"] { background: #ede9fe; color: #5b21b6; }
.ttl[data-t="Legend"] { background: linear-gradient(135deg, #ffb703, #fb7a3a); color: #fff; border-color: transparent; }
.who .ttl { vertical-align: middle; }
table.wall { width: 100%; border-collapse: collapse; margin: 6px 0 4px; }
table.wall td { padding: 6px 4px; border-top: 1px solid var(--line); font-size: 14px; }
table.wall td.rk { width: 34px; text-align: center; }
table.wall td.sc { text-align: right; color: var(--muted); white-space: nowrap; }
table.wall td.amt { text-align: right; font-weight: 800; color: var(--green); white-space: nowrap; }
#wall h3, #wkLast h3 { font-size: 14px; margin: 12px 0 2px; }
.paid7 { font-weight: 700; color: var(--text); }
.remind { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 2px 0 8px; }
.btn.mini { padding: 8px 12px; font-size: 13px; border-radius: 10px; width: auto; }
.hud span.gold { background: linear-gradient(135deg, #ffd93d, #fb7a3a); color: #fff; animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(1.08); } }
