/* GPS Kids daily game: one screen, one action. Brand: paper / navy / blue / yellow, DM Sans + Young Serif. */
:root {
  --paper: #fbf8ef; --surface: #ffffff; --ink: #14213d; --muted: #536079;
  --line: #dbe3ee; --blue: #1458d4; --yellow: #f3bd35; --yellow-soft: #fff4d1;
  --red: #de4a3e; --green: #1faa53; --wa: #25d366; --navy: #14213d;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: "DM Sans", system-ui, sans-serif; line-height: 1.4; -webkit-font-smoothing: antialiased; }
button { font-family: inherit; }
.emoji, .big-emoji, .play-emoji, .badge { font-family: "Noto Color Emoji", "Apple Color Emoji", "Segoe UI Emoji", sans-serif; }

/* Home: fits one phone screen */
.screen { min-height: calc(100vh - 44px); min-height: calc(100svh - 44px); max-width: 520px; margin: 0 auto; padding: 16px 20px calc(18px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; }
.topline { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.brand { font-family: "Young Serif", Georgia, serif; font-size: 1.25rem; }
.streak { background: var(--yellow-soft); border: 2px solid var(--yellow); color: var(--ink); font-weight: 800; font-size: .98rem; padding: 6px 12px; border-radius: 999px; white-space: nowrap; }
.streak.hot { background: var(--yellow); }
.kicker { margin: 18px 0 0; display: flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.free-pill { background: var(--green); color: #fff; padding: 3px 9px; border-radius: 999px; letter-spacing: .08em; font-size: .74rem; }
.hero { flex: 1; display: flex; flex-direction: column; justify-content: center; text-align: center; padding: 10px 0; }
.big-emoji { font-size: 5.2rem; line-height: 1; margin-bottom: 10px; }
h1 { font-family: "Young Serif", Georgia, serif; font-weight: 400; font-size: 2.7rem; line-height: 1.05; margin: 0 0 14px; text-wrap: balance; }
.howto { font-size: 1.3rem; line-height: 1.35; margin: 0 auto; max-width: 22ch; color: var(--ink); text-wrap: balance; }
.actions { display: grid; gap: 12px; }
.btn { display: block; width: 100%; text-align: center; text-decoration: none; font-weight: 800; font-size: 1.3rem; padding: 20px 18px; border-radius: 20px; border: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.btn:active { transform: scale(.98); }
.btn-start { background: var(--blue); color: #fff; font-size: 1.55rem; padding: 24px 18px; box-shadow: 0 12px 30px rgba(20, 88, 212, .30); }
.btn-start span { font-size: 1.05rem; font-weight: 700; opacity: .85; margin-left: 6px; }
.btn-start.again { background: var(--navy); }
.btn-wa { background: var(--wa); color: #0b3d1f; box-shadow: 0 10px 26px rgba(37, 211, 102, .28); }
.btn-ghost { background: transparent; color: var(--ink); border: 2px solid var(--line); font-size: 1.05rem; padding: 16px; }
.done-row { margin: 14px 0 0; text-align: center; font-weight: 800; font-size: 1.15rem; color: var(--green); }
.tomorrow { margin: 12px 0 0; text-align: center; font-size: 1rem; color: var(--muted); }
.tomorrow::before { content: "🔔 "; }

/* Below the fold: funnel */
.next { max-width: 520px; margin: 0 auto; padding: 22px 20px 40px; border-top: 1px solid var(--line); }
.next h2 { font-size: 1.15rem; margin: 0 0 12px; }
.step { display: flex; gap: 14px; align-items: center; text-decoration: none; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px; margin: 0 0 10px; }
.step b { font-size: 1.8rem; font-family: "Noto Color Emoji", "Apple Color Emoji", sans-serif; }
.step strong { display: block; font-size: 1.05rem; }
.step small { display: block; color: var(--muted); font-size: .9rem; margin-top: 2px; }
.small { text-align: center; font-size: .92rem; margin: 14px 0 0; }
.small a { color: var(--blue); font-weight: 700; }
footer { margin-top: 22px; text-align: center; color: var(--muted); font-size: .85rem; line-height: 1.6; }

/* Play mode */
.overlay { position: fixed; inset: 0; z-index: 30; background: var(--paper); display: flex; flex-direction: column; padding: 16px 20px calc(20px + env(safe-area-inset-bottom)); max-width: 520px; margin: 0 auto; }
.play-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.x { width: 46px; height: 46px; border-radius: 50%; border: 2px solid var(--line); background: var(--surface); font-size: 1.2rem; color: var(--ink); cursor: pointer; }
.round { font-weight: 800; letter-spacing: .1em; text-transform: uppercase; font-size: .85rem; color: var(--blue); }
.clock { min-width: 96px; border: none; border-radius: 16px; background: var(--navy); color: #fff; font-family: "DM Sans", sans-serif; font-weight: 800; font-size: 1.5rem; padding: 8px 12px; cursor: pointer; font-variant-numeric: tabular-nums; }
.clock.paused { background: var(--muted); }
.clock.up { background: var(--red); }
.play-body { flex: 1; display: flex; flex-direction: column; justify-content: center; text-align: center; overflow-y: auto; }
.play-emoji { font-size: 3.6rem; margin-bottom: 14px; }
.play-step { font-size: 1.45rem; line-height: 1.4; font-weight: 700; margin: 0; }
.play-win { margin: 18px 0 0; background: var(--yellow-soft); border-radius: 14px; padding: 12px 14px; font-size: 1rem; text-align: left; }
.play-dots { display: flex; justify-content: center; gap: 10px; margin: 14px 0; }
.play-dots i { width: 14px; height: 14px; border-radius: 50%; background: var(--line); }
.play-dots i.on { background: var(--blue); }

/* Celebration */
.party { overflow: hidden; }
.party .x { position: absolute; top: 16px; right: 20px; z-index: 2; }
.party-body { flex: 1; display: flex; flex-direction: column; justify-content: center; text-align: center; gap: 10px; position: relative; z-index: 1; overflow-y: auto; }
.badge { font-size: 4.6rem; width: 132px; height: 132px; margin: 0 auto; border-radius: 50%; display: grid; place-items: center; background: var(--yellow); box-shadow: 0 0 0 8px var(--yellow-soft); animation: pop .6s cubic-bezier(.2, 1.6, .4, 1) both; }
.party h2 { font-family: "Young Serif", Georgia, serif; font-weight: 400; font-size: 2.4rem; margin: 10px 0 0; }
.party-streak { font-size: 1.4rem; font-weight: 800; margin: 0; }
.party-badge { margin: 0 0 6px; color: var(--muted); font-weight: 700; }
.party .tomorrow { margin: 6px 0 0; }
.bonus { text-align: left; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; }
.bonus summary { font-weight: 800; cursor: pointer; }
.bonus ol { margin: 8px 0 0; padding-left: 20px; }
.bonus li { margin: 4px 0; }
.confetti i { position: absolute; top: -20px; width: 10px; height: 16px; border-radius: 3px; animation: fall 2.6s linear forwards; }
@keyframes pop { from { transform: scale(.2); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes fall { to { transform: translateY(110vh) rotate(720deg); opacity: .9; } }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 12px; font-size: .95rem; z-index: 40; max-width: 90vw; text-align: center; }
@media (max-height: 700px) { .big-emoji { font-size: 3.8rem; } h1 { font-size: 2.2rem; } .howto { font-size: 1.12rem; } .btn-start { padding: 18px; } .btn { padding: 16px; } }
@media (prefers-reduced-motion: reduce) { .badge, .confetti i { animation: none; } }
/* netlify.app preview hosts show a "Powered by Netlify" badge bottom-right */
.on-preview-host .screen { padding-bottom: 70px; }
.done-row.nudge { color: var(--red); }
.tomorrow.link::before { content: ""; }
.tomorrow.link a { color: var(--blue); font-weight: 800; }
