@charset "UTF-8";
:root {
  color-scheme: light;
  --ink: #4e392d;
  --muted: #887d70;
  --paper: #fffaf0;
  --accent: #c77846;
  --ambient: #e8eee3;
  --ambient-accent: #dcebf0;
  --app-height: 100dvh;
  --scene-sky: #a9dcf0;
  --scene-ground: #c9b586;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --record-top: calc(var(--safe-top) + 20px);
  font-family: "Avenir Next", "Nunito", "Trebuchet MS", system-ui, sans-serif;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { height: 100%; background: var(--scene-sky); overscroll-behavior: none; overflow: hidden; }
body { margin: 0; color: var(--ink); width: 100%; height: var(--app-height); overflow: hidden; background: linear-gradient(var(--scene-sky) 0%, var(--ambient) 75%, var(--scene-ground) 100%); overscroll-behavior: none; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; cursor: pointer; color: inherit; border: 0; touch-action: manipulation; }
button:disabled { cursor: wait; opacity: .6; }
button:focus-visible, a:focus-visible, canvas:focus-visible { outline: 3px solid #b66c3d; outline-offset: 4px; }
button { transition: background .18s, transform .18s, box-shadow .18s; }
button:active:not(:disabled) { transform: translateY(2px) scale(.98); }
.icon-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 22px; height: 22px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.app { position: relative; width: min(100%, calc(var(--app-height) * .5625)); height: var(--app-height); margin: 0 auto; }
.best-badge { position: absolute; z-index: 5; left: 50%; top: var(--record-top); transform: translateX(-50%); display: flex; align-items: center; justify-content: center; gap: 6px; height: 30px; max-width: clamp(64px, calc(100cqw - 244px), 112px); padding: 4px 10px; border: 1px solid #fffaf04d; background: #fffaf052; border-radius: 18px; color: #685443; pointer-events: none; }
.best-badge .icon { width: 16px; height: 16px; color: #a77836; }
.best-badge b { min-width: 0; overflow: hidden; text-overflow: ellipsis; color: var(--ink); font-size: 16px; line-height: 20px; font-weight: 750; font-variant-numeric: tabular-nums; }
.game-shell { position: relative; isolation: isolate; width: 100%; height: 100%; overflow: hidden; background: var(--scene-sky); container-type: inline-size; touch-action: none; user-select: none; -webkit-user-select: none; }
#game { display: block; width: 100%; height: 100%; outline-offset: -7px; }
.scene-grain { position: absolute; z-index: 1; inset: 0; pointer-events: none; opacity: .12; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Cpath fill='%234a3b2a' filter='url(%23n)' opacity='.2' d='M0 0h180v180H0z'/%3E%3C/svg%3E"); }
.hud { position: absolute; z-index: 5; top: calc(var(--safe-top) + 14px); left: calc(var(--safe-left) + 18px); right: calc(var(--safe-right) + 18px); height: 105px; pointer-events: none; }
.hud-actions { position: absolute; right: 0; top: 0; display: flex; gap: 7px; pointer-events: auto; }
.icon-button { width: 44px; height: 44px; display: grid; place-items: center; background: #fffaf0b5; border: 1px solid #ffffff8c; border-radius: 50%; box-shadow: 0 2px 3px #483b2520; color: #685443; }
.icon-button:hover { background: #fffaf0; }
.icon-button .icon { width: 19px; height: 19px; }
.score-wrap { position: absolute; left: 50%; top: 53px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; }
.score-caption { font-size: 9px; font-weight: 800; letter-spacing: 2px; color: #5e7166; }
#score { font-size: clamp(38px, 14cqw, 58px); line-height: 1.15; letter-spacing: -2px; font-weight: 850; color: #fffdf2; text-shadow: 0 3px 0 #4c594957, 0 0 15px #3c644417; -webkit-text-stroke: 1px #5c715963; font-variant-numeric: tabular-nums; }
#score.bump { animation: score-bump .2s ease-out; }
.milk-badge { position: absolute; z-index: 5; top: calc(var(--record-top) + 35px); left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 4px; min-height: 18px; white-space: nowrap; color: #785134; font-size: 10px; font-weight: 700; pointer-events: none; }
.milk-badge .icon { width: 13px; height: 13px; }
body:not([data-chrome-record="true"]) .score-wrap { top: 66px; }
.menu-overlay { position: absolute; z-index: 3; inset: var(--safe-top) var(--safe-right) var(--safe-bottom) var(--safe-left); text-align: center; pointer-events: none; }
.menu-heading { position: absolute; top: 14%; left: 0; width: 100%; }
.eyebrow { margin: 0; font-size: clamp(7px, 2.15cqw, 9px); font-weight: 800; letter-spacing: 1.55px; color: #665c49; }
h1 { margin: 8px 0 5px; font-size: clamp(60px, 22cqw, 96px); line-height: 1; letter-spacing: -4px; font-weight: 850; color: #56382a; text-shadow: 0 3px 0 #fff9ec9c; }
h1 span { color: #c58250; }
.menu-bottom { position: absolute; top: 65%; left: 50%; width: min(72%, 330px); transform: translateX(-50%); }
.primary-button { display: flex; justify-content: center; align-items: center; gap: 19px; width: 100%; min-height: 55px; padding: 10px 18px; border-radius: 17px; font-size: 16px; font-weight: 800; color: #fffaf2; background: #ab613c; box-shadow: 0 4px 0 #82462c, inset 0 1px 0 #ddab7f82, 0 8px 14px #855e3730; pointer-events: auto; }
.primary-button:hover { background: #b66d45; }
.primary-button:active:not(:disabled) { transform: translateY(3px); box-shadow: 0 1px 0 #82462c, inset 0 1px 0 #ddab7f82; }
.primary-button .icon { width: 21px; height: 21px; }
.flight-button { min-height: 58px; gap: 13px; font-size: 19px; letter-spacing: .1px; }
.flight-button .flight-wing { width: 25px; height: 25px; fill: #fffaf2; stroke: #edcdb0; stroke-width: 1.25; }
.flight-wing-right { transform: scaleX(-1); }
.tap-hint { display: flex; align-items: center; justify-content: center; gap: 7px; white-space: nowrap; font-size: clamp(11px, 3cqw, 13px); color: #65705a; font-weight: 600; margin: 13px 0 0; }
.tap-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px #fff8e65e; }
.loading-overlay { position: absolute; z-index: 10; inset: 0; display: grid; place-content: center; background: var(--scene-sky); color: #79654d; font-size: 14px; text-align: center; }
.loading-dots { display: inline; }
.modal-overlay { position: absolute; z-index: 6; inset: 0; display: flex; justify-content: center; align-items: center; background: #344b4442; backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); padding: calc(var(--safe-top) + 22px) calc(var(--safe-right) + 22px) calc(var(--safe-bottom) + 22px) calc(var(--safe-left) + 22px); }
.dialog-card { width: 100%; max-width: 350px; max-height: 100%; overflow-y: auto; background: #fffaef; border: 1px solid #fff; box-shadow: 0 15px 45px #2e372f20; padding: 24px 23px 14px; border-radius: 26px; text-align: center; animation: card-in .2s ease-out; }
.card-symbol { width: 49px; height: 49px; border-radius: 50%; background: #f2e4cd; color: #b17d48; display: grid; place-items: center; margin: 0 auto 17px; }
.card-symbol .icon { width: 24px; height: 24px; }
h2 { font-size: clamp(23px, 8.2cqw, 31px); margin: 9px 0 0; line-height: 1.15; letter-spacing: -1px; }
.card-description { margin: 12px 0 24px; font-size: 13px; color: var(--muted); }
.text-button { background: transparent; font-weight: 600; font-size: 12px; color: #89745f; padding: 17px 10px 7px; min-height: 40px; }
.text-button:hover { color: #a45e39; }
.result-stats { display: flex; align-items: center; justify-content: center; gap: 35px; margin: 24px 0 16px; }
.result-stats div { display: flex; flex-direction: column; min-width: 60px; }
.result-stats span { font-size: 11px; color: var(--muted); }
.result-stats strong { font-size: 41px; line-height: 1.3; letter-spacing: -1px; font-variant-numeric: tabular-nums; }
.result-stats div:last-child strong { color: #b68650; }
.stat-divider { height: 41px; width: 1px; background: #e9dfcd; }
.result-caption { color: #8a795f; font-size: 11px; line-height: 1.5; min-height: 32px; margin: 0 0 16px; }
.milestone-toast { position: absolute; z-index: 5; left: 50%; bottom: calc(var(--safe-bottom) + 100px); transform: translateX(-50%); display: flex; align-items: center; gap: 11px; padding: 11px 15px; white-space: nowrap; border-radius: 16px; background: #fff9e8ee; border: 1px solid #fff; box-shadow: 0 6px 20px #4f3c2926; pointer-events: none; }
.milestone-toast>span { font-size: 25px; font-weight: 800; color: #b57b44; }
.milestone-toast strong { display: block; font-size: 12px; }
.milestone-toast small { display: block; font-size: 10px; color: #8b7b62; margin-top: 3px; }
.season-picker { position: absolute; bottom: 6px; left: 16px; right: 16px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 0; pointer-events: auto; }
.season-picker button { position: relative; isolation: isolate; display: flex; justify-content: center; align-items: center; gap: 5px; padding: 9px 2px; min-height: 44px; background: transparent; border-radius: 14px; color: #766047; font-size: 11px; font-weight: 650; }
.season-picker button::before { content: ""; position: absolute; z-index: -1; inset: 6px 5px; border-radius: 11px; background: transparent; transition: background .18s; }
.season-picker .icon { width: 17px; height: 17px; stroke-width: 1.6; }
.season-picker button[aria-pressed="true"] { color: #80542d; }
.season-picker button[aria-pressed="true"]::before { background: #fff6df59; }
@media (hover: hover) { .season-picker button:hover::before { background: #fffaf035; } }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.noscript { padding: 15px; background: var(--paper); border-radius: 12px; }
body[data-state="over"] .hud, body[data-state="paused"] .hud { opacity: .45; pointer-events: none; }
body[data-state="over"] .hud-actions, body[data-state="paused"] .hud-actions { pointer-events: none; }
body[data-state="over"] .best-badge, body[data-state="paused"] .best-badge { opacity: .45; }
body[data-state="over"] .milk-badge, body[data-state="paused"] .milk-badge { opacity: .45; }
@keyframes score-bump { 50% { transform: scale(1.18); } }
@keyframes card-in { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
@media (hover: hover) {
  .game-shell { box-shadow: 0 0 90px #556a4920; }
}
@media (max-width: 340px) {
  .hud { left: calc(var(--safe-left) + 12px); right: calc(var(--safe-right) + 12px); }
  .best-badge { padding-inline: 8px; }
  .season-picker { left: 10px; right: 10px; }
  .season-picker button { font-size: 10px; gap: 3px; }
  .primary-button { font-size: 15px; }
  .flight-button { font-size: 18px; gap: 10px; }
}
body[data-compact="true"] .menu-heading { top: 9%; }
body[data-compact="true"] h1 { font-size: clamp(50px, 19cqw, 76px); }
body[data-compact="true"] .menu-bottom { top: 62%; }
body[data-compact="true"] .menu-bottom .primary-button { min-height: 46px; }
body[data-compact="true"] .tap-hint { margin-top: 8px; font-size: 11px; }
body[data-compact="true"] .dialog-card { padding: 18px 18px 12px; }
body[data-compact="true"] .card-symbol { width: 36px; height: 36px; margin-bottom: 10px; }
body[data-compact="true"] .result-stats { margin: 14px 0 10px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
