/* jump-game.css — standalone, responsive Doodle Jump-style game page. */
body { background: #f7eff9; }
.bg { background: linear-gradient(145deg, #fff5ed 0%, #fae9f0 48%, #ece9ff 100%); }
.game-page { width: min(600px, 100%); min-height: 100vh; min-height: 100dvh; margin: 0 auto; padding: calc(18px + var(--safe-t)) 20px calc(24px + var(--safe-b)); }
.game-page-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.game-back { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 8px 12px; border: 1px solid rgba(255,255,255,.8); border-radius: 999px; color: #75647f; background: rgba(255,255,255,.48); box-shadow: inset 0 1px 0 rgba(255,255,255,.8); font-size: 12px; font-weight: 700; white-space: nowrap; }
.game-back span:first-child { font-size: 18px; line-height: 1; }
.game-page-header .seg { width: min(240px, 58vw); margin: 0; }
.game-page-header .seg button { min-width: 0; padding: 8px 2px; font-size: 11px; }
.game-intro { padding: 27px 8px 19px; text-align: center; }
.game-eyebrow { margin: 0 0 7px; color: #a18aa9; font-size: 10px; font-weight: 800; letter-spacing: .18em; }
.game-intro h1 { margin: 0; color: #493c52; font-size: clamp(30px, 7vw, 42px); line-height: 1.15; letter-spacing: -.04em; }
.game-intro > p:last-child { max-width: 430px; margin: 9px auto 0; color: #766c80; font-size: 13px; line-height: 1.7; }
.game-card { max-width: 480px; margin: 0 auto; padding: 14px; border: 1px solid rgba(255,255,255,.82); border-radius: 27px; background: linear-gradient(145deg,rgba(255,255,255,.78),rgba(255,255,255,.48)); box-shadow: 0 22px 58px rgba(110,83,127,.16), inset 0 1px 0 rgba(255,255,255,.96); }
.game-stats { display: grid; grid-template-columns: 1fr 1fr auto; align-items: center; gap: 10px; padding: 1px 2px 12px; }
.game-stat { display: flex; align-items: baseline; gap: 7px; color: #93879a; font-size: 11px; }
.game-stat strong { color: #b75f83; font-size: 17px; font-variant-numeric: tabular-nums; }
.game-pause { min-width: 72px; min-height: 36px; padding: 7px 13px; border: 1px solid rgba(255,255,255,.9); border-radius: 999px; color: #786984; background: rgba(255,255,255,.68); font-size: 11px; font-weight: 800; cursor: pointer; }
.game-pause:disabled { opacity: .52; cursor: default; }
.jump-stage { position: relative; overflow: hidden; border: 1px solid rgba(255,255,255,.76); border-radius: 20px; background: #f6eff9; box-shadow: inset 0 1px 0 rgba(255,255,255,.92); }
#jumpCanvas { display: block; width: 100%; height: clamp(280px, 53vh, 440px); touch-action: none; }
.jump-overlay { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 22px; background: rgba(251,246,251,.48); text-align: center; -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.jump-overlay p { max-width: 270px; margin: 0; color: #64566c; font-size: 14px; font-weight: 700; line-height: 1.65; }
.jump-start { min-height: 45px; padding: 10px 24px; border: 1px solid rgba(255,255,255,.9); border-radius: 999px; color: #fff; background: linear-gradient(135deg,#d68aa5,#9e8bc7); box-shadow: 0 8px 18px rgba(150,111,165,.26), inset 0 1px 0 rgba(255,255,255,.42); font-size: 13px; font-weight: 800; cursor: pointer; }
.jump-start:active { transform: scale(.97); }
.jump-stage.is-playing .jump-overlay { display: none; }
.jump-controls { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 11px; }
.jump-control { display: flex; align-items: center; justify-content: center; gap: 9px; min-height: 50px; border: 1px solid rgba(255,255,255,.9); border-radius: 16px; color: #75647f; background: rgba(255,255,255,.72); box-shadow: inset 0 1px 0 rgba(255,255,255,.92), 0 5px 14px rgba(110,83,127,.07); font-size: 13px; font-weight: 800; cursor: pointer; touch-action: none; user-select: none; -webkit-user-select: none; }
.jump-control span:first-child[aria-hidden="true"], .jump-control span:last-child[aria-hidden="true"] { font-size: 18px; }
.jump-control:active, .jump-control.is-pressed { color: #a95f83; background: #f8e8f0; transform: translateY(1px); }
.game-instructions { display: flex; justify-content: center; flex-wrap: wrap; gap: 5px 18px; padding: 10px 2px 1px; }
.game-instructions p { margin: 0; color: #998ca0; font-size: 10px; text-align: center; }
.game-footer { padding: 18px 0 0; text-align: center; }
.game-footer a { color: #a18aa9; font-size: 11px; font-weight: 700; }
.game-back:focus-visible, .game-pause:focus-visible, .jump-start:focus-visible, .jump-control:focus-visible { outline: 3px solid rgba(183,95,131,.42); outline-offset: 3px; }

@media (max-width: 560px) {
  .game-page { padding: calc(12px + var(--safe-t)) 14px calc(18px + var(--safe-b)); }
  .game-page-header { gap: 7px; }
  .game-back { gap: 5px; min-height: 36px; padding: 7px 9px; font-size: 10px; }
  .game-page-header .seg { width: clamp(148px, 49vw, 190px); padding: 3px; }
  .game-page-header .seg button { padding: 7px 1px; font-size: 10px; }
  .game-intro { padding: 22px 5px 15px; }
  .game-intro > p:last-child { font-size: 12px; }
  .game-card { padding: 11px; border-radius: 23px; }
  #jumpCanvas { height: clamp(265px, 48vh, 370px); }
  .jump-controls { gap: 8px; }
  .jump-control { min-height: 47px; }
}
@media (prefers-reduced-motion: reduce) { .jump-control, .jump-start { transition: none; } }
