:root {
  color-scheme: dark;
  --ink: #071315;
  --panel: rgba(9, 27, 29, .91);
  --panel-solid: #102a2c;
  --bone: #eadfbd;
  --muted: #9eb3a9;
  --rust: #c94d36;
  --rust-bright: #ed7951;
  --acid: #d7d66a;
  --violet: #a770e8;
  --line: rgba(234, 223, 189, .2);
  --shadow: 0 18px 45px rgba(0, 0, 0, .44);
  font-family: "Arial Narrow", "Trebuchet MS", Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body { min-height: 100%; margin: 0; background: #061012; color: var(--bone); }

body {
  overflow-x: hidden;
  background:
    radial-gradient(circle at 50% -20%, rgba(58, 110, 108, .35), transparent 45%),
    linear-gradient(180deg, #102c2e, #071315 68%);
}

button, input, select { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid var(--acid); outline-offset: 3px; }

.game-shell { min-height: 100vh; min-height: 100svh; position: relative; }
.screen { min-height: calc(100vh - 66px); min-height: calc(100svh - 66px); }
.screen[hidden], [hidden] { display: none !important; }

.topbar {
  height: 66px;
  padding: 7px max(14px, env(safe-area-inset-right)) 7px max(14px, env(safe-area-inset-left));
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 40;
  border-bottom: 1px solid var(--line);
  background: rgba(5, 17, 18, .92);
  backdrop-filter: blur(10px);
}

.brand { width: max-content; padding: 0; border: 0; background: none; display: flex; flex-direction: column; align-items: flex-start; line-height: .85; cursor: pointer; letter-spacing: .08em; }
.brand span { font-size: .72rem; color: var(--muted); }
.brand strong { font: 900 1.2rem/1 Impact, "Arial Black", sans-serif; color: var(--rust-bright); }
.crown-score { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.crown-score small { color: var(--acid); font-weight: 900; letter-spacing: .12em; }
.crown-score strong { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .9rem; }
.crown-score span { color: var(--rust-bright); font-weight: 900; }
.icon-button, .close-button { justify-self: end; width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 50%; background: rgba(255,255,255,.06); font-weight: 900; font-size: 1.25rem; cursor: pointer; }
.icon-button:hover, .close-button:hover { background: var(--rust); }

.menu-screen {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #0d2426 url("../images/title-art.webp") center 52% / cover no-repeat;
}
.menu-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(3,10,11,.92) 0%, rgba(3,10,11,.56) 45%, rgba(3,10,11,.08) 78%), linear-gradient(0deg, rgba(3,10,11,.78), transparent 42%); }
.menu-content { position: relative; width: min(1180px, 100%); padding: clamp(28px, 5vw, 72px); justify-self: center; }
.eyebrow { margin: 0 0 8px; color: var(--acid); font-size: clamp(.7rem, 1.1vw, .9rem); font-weight: 900; letter-spacing: .25em; }
h1 { margin: 0; width: min-content; font: 900 clamp(4.1rem, 10vw, 8.2rem)/.72 Impact, "Arial Black", sans-serif; letter-spacing: -.025em; text-shadow: 0 8px 0 #050b0c, 0 15px 28px rgba(0,0,0,.8); transform: rotate(-1deg); }
h1 em { font-style: normal; color: var(--rust-bright); }
.menu-copy { max-width: 520px; margin: 24px 0; color: #d6ded6; font: 700 clamp(1rem, 1.8vw, 1.25rem)/1.45 Georgia, serif; }

.start-card { width: min(630px, 100%); padding: 16px; border: 1px solid var(--line); background: rgba(5, 17, 18, .82); box-shadow: var(--shadow); backdrop-filter: blur(8px); }
.start-card label { display: block; margin-bottom: 8px; font-size: .72rem; font-weight: 900; letter-spacing: .18em; color: var(--muted); }
.name-row { display: flex; gap: 8px; }
input { min-width: 0; flex: 1; height: 50px; padding: 0 14px; border: 1px solid #52645e; border-radius: 3px; background: #071416; color: var(--bone); font-size: 1rem; font-weight: 900; text-transform: uppercase; }
input::placeholder { color: #687c73; }
.form-message { min-height: 1.1em; margin: 7px 0 0; color: #ff9a72; font-size: .78rem; }
.privacy-note { margin: 7px 0 0; color: var(--muted); font-size: .68rem; line-height: 1.45; }
.privacy-note a { color: var(--bone); text-underline-offset: 3px; }
.privacy-note a:hover, .privacy-note a:focus-visible { color: var(--acid); }

.primary-button, .ghost-button, .panel-button, .ability-button, .shop-item { border-radius: 3px; cursor: pointer; }
.primary-button { min-height: 50px; padding: 0 24px; border: 0; background: var(--rust); color: #fff5df; box-shadow: inset 0 -4px 0 rgba(73, 13, 8, .45), 0 6px 18px rgba(0,0,0,.26); font-weight: 1000; letter-spacing: .08em; }
.primary-button:hover { background: var(--rust-bright); transform: translateY(-1px); }
.primary-button:active { transform: translateY(2px); box-shadow: inset 0 -2px 0 rgba(73,13,8,.45); }
.primary-button:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.menu-actions { margin-top: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ghost-button, .panel-button { min-height: 40px; padding: 0 14px; border: 1px solid var(--line); background: rgba(5,17,18,.78); font-size: .72rem; font-weight: 900; letter-spacing: .08em; }
.ghost-button:hover, .panel-button:hover { border-color: var(--acid); color: var(--acid); }
.gore-select { min-height: 40px; padding: 0 10px; display: flex; gap: 8px; align-items: center; border: 1px solid var(--line); background: rgba(5,17,18,.78); color: var(--muted); font-size: .65rem; font-weight: 900; letter-spacing: .08em; }
.gore-select select { border: 0; background: transparent; color: var(--bone); font-size: .72rem; font-weight: 900; }
.title-id { margin: 10px 0 0; color: rgba(234,223,189,.46); font-size: .62rem; letter-spacing: .15em; }

.game-screen { background: #081719; padding: 10px; }
.game-hud { width: min(1500px, 100%); margin: 0 auto 8px; display: grid; grid-template-columns: 1fr 1.25fr 1fr; gap: 8px; }
.hud-card { min-height: 58px; padding: 7px 12px; display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto 1fr; column-gap: 10px; align-items: center; border: 1px solid var(--line); background: #0e2527; box-shadow: 0 5px 15px rgba(0,0,0,.25); }
.hud-card small { color: var(--muted); font-size: .62rem; font-weight: 900; letter-spacing: .16em; }
.hud-card strong { grid-row: 1 / 3; font: 900 1.85rem/1 Impact, sans-serif; color: var(--rust-bright); }
.hud-card span { font-size: .72rem; font-weight: 900; letter-spacing: .06em; }
.score-card { text-align: center; grid-template-columns: 1fr auto 1fr; }
.score-card small { text-align: right; }
.score-card strong { grid-column: 2; }
.score-card span { text-align: left; }
.ammo-card { text-align: right; }
.ammo-card strong { grid-column: 2; }

.playfield-wrap { position: relative; width: min(1500px, 100%, calc((100svh - 300px) * 16 / 9)); aspect-ratio: 16 / 9; min-width: 320px; margin: 0 auto; overflow: hidden; border: 1px solid #395052; background: #0c292c; box-shadow: var(--shadow); }
#game-canvas { display: block; width: 100%; height: 100%; cursor: default; }
.vignette { pointer-events: none; position: absolute; inset: 0; box-shadow: inset 0 0 90px rgba(0,0,0,.62), inset 0 -70px 90px rgba(0,0,0,.5); }
.weather-panel, .upgrade-panel { position: absolute; top: 18px; width: 158px; padding: 10px; border: 1px solid var(--line); background: var(--panel); box-shadow: var(--shadow); backdrop-filter: blur(6px); }
.weather-panel { left: 18px; }
.upgrade-panel { right: 18px; }
.weather-panel > p, .upgrade-panel > p { margin: 0 0 9px; color: var(--muted); font-size: .62rem; font-weight: 900; letter-spacing: .18em; }
.wind-readout { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-block: 1px solid var(--line); }
.wind-readout > strong { font-size: 2rem; color: var(--acid); }
.wind-readout span { display: flex; flex-direction: column; }
.wind-readout b { font-size: .78rem; }
.wind-readout small { color: var(--muted); }
.condition { min-height: 38px; display: flex; gap: 8px; align-items: center; font-weight: 900; }
.condition span { color: var(--violet); }
.golem-condition { border-top: 1px solid var(--line); }
.golem-condition span { color: var(--rust-bright); }
.panel-button { width: 100%; background: rgba(255,255,255,.05); }

.ability-button { width: 100%; min-height: 48px; margin-top: 6px; padding: 5px 7px; display: grid; grid-template-columns: 28px 1fr; grid-template-rows: auto auto; text-align: left; border: 1px solid var(--line); background: rgba(255,255,255,.055); }
.ability-button span { grid-row: 1/3; align-self: center; color: var(--acid); font-size: 1.3rem; }
.ability-button strong { font-size: .7rem; letter-spacing: .08em; }
.ability-button small { color: var(--muted); font-size: .6rem; }
.ability-button:not(:disabled):hover { border-color: var(--acid); background: rgba(215,214,106,.12); }
.ability-button:disabled { opacity: .4; cursor: not-allowed; }

.aim-hint { position: absolute; left: 50%; bottom: 24px; translate: -50% 0; min-width: 290px; padding: 10px 18px; display: flex; flex-direction: column; align-items: center; border: 1px solid rgba(234,223,189,.25); background: rgba(5,17,18,.8); pointer-events: none; animation: breathe 2s infinite; }
.aim-hint strong { font-size: .8rem; letter-spacing: .12em; }
.aim-hint span { margin-top: 3px; color: var(--muted); font: italic .78rem Georgia, serif; }
.callout { position: absolute; left: 50%; top: 16%; translate: -50% -50%; max-width: 70%; padding: 9px 15px; opacity: 0; background: #eee1bd; color: #152326; box-shadow: 5px 5px 0 rgba(0,0,0,.35); font: 900 clamp(1rem, 2.2vw, 1.8rem)/1 Impact, sans-serif; text-align: center; transform: rotate(-1deg); pointer-events: none; }
.callout.pop { animation: callout 1.9s ease both; }
.skip-button { position: absolute; bottom: 18px; right: 18px; min-height: 34px; border: 1px solid var(--line); background: rgba(5,17,18,.8); font-weight: 900; cursor: pointer; }

.aim-deck { width: min(980px, 100%); min-height: 154px; margin: 9px auto 0; padding: 9px 18px; display: grid; grid-template-columns: minmax(210px, 1fr) 138px minmax(190px, 1fr); align-items: center; gap: 24px; border: 1px solid var(--line); background: linear-gradient(135deg, rgba(15,40,42,.98), rgba(6,18,20,.98)); box-shadow: var(--shadow); }
.aim-instruction { display: flex; flex-direction: column; }
.aim-instruction small { color: var(--acid); font-size: .6rem; font-weight: 900; letter-spacing: .16em; }
.aim-instruction strong { margin-top: 5px; font: 900 1.05rem/1 Impact, sans-serif; letter-spacing: .05em; }
.aim-instruction span { max-width: 290px; margin-top: 6px; color: var(--muted); font: italic .76rem/1.35 Georgia, serif; }
.aim-pad { --aim-direction: 146deg; position: relative; width: 132px; aspect-ratio: 1; justify-self: center; border: 3px solid #8f865f; border-radius: 50%; background: radial-gradient(circle, #c94d36 0 9%, #e5dcb9 10% 25%, #34494a 26% 43%, #d4c899 44% 62%, #152c2e 63% 100%); box-shadow: inset 0 0 22px rgba(0,0,0,.65), 0 6px 20px rgba(0,0,0,.4); cursor: grab; touch-action: none; user-select: none; }
.aim-pad:active { cursor: grabbing; }
.aim-pad.disabled { opacity: .45; filter: grayscale(.5); cursor: not-allowed; }
.aim-pad::before { content: ""; position: absolute; left: 50%; top: calc(50% - 2px); width: 43%; height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--rust-bright), var(--acid)); transform-origin: left center; transform: rotate(var(--aim-direction)); box-shadow: 0 0 8px rgba(215,214,106,.8); }
.aim-pad::after { content: ""; position: absolute; right: 6px; top: 50%; width: 7px; height: 7px; margin-top: -4px; border: solid rgba(234,223,189,.65); border-width: 2px 2px 0 0; transform: rotate(45deg); }
.aim-ring { position: absolute; border: 1px solid rgba(6,18,20,.35); border-radius: 50%; pointer-events: none; }
.ring-one { inset: 24%; }.ring-two { inset: 41%; }
.aim-axis { position: absolute; display: block; background: rgba(6,18,20,.28); pointer-events: none; }
.aim-axis.horizontal { left: 8%; right: 8%; top: 50%; height: 1px; }.aim-axis.vertical { top: 8%; bottom: 8%; left: 50%; width: 1px; }
.aim-stick { --stick-x: 0px; --stick-y: 0px; position: absolute; z-index: 3; left: 50%; top: 50%; width: 30px; height: 30px; margin: -15px 0 0 -15px; border: 3px solid #f0e6c5; border-radius: 50%; background: #b94332; box-shadow: 0 3px 9px rgba(0,0,0,.55); transform: translate(var(--stick-x), var(--stick-y)); pointer-events: none; }
.aim-stick b { position: absolute; inset: 8px; border-radius: 50%; background: var(--acid); }
.aim-readout { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.aim-readout div { padding: 8px; border: 1px solid var(--line); background: rgba(255,255,255,.04); }
.aim-readout small { display: block; color: var(--muted); font-size: .54rem; font-weight: 900; letter-spacing: .1em; }
.aim-readout strong { display: block; margin-top: 3px; color: var(--rust-bright); font: 900 1rem/1 Impact, sans-serif; }
.aim-readout > span { grid-column: 1 / -1; padding: 6px 8px; color: var(--acid); border: 1px solid rgba(215,214,106,.25); font-size: .62rem; font-weight: 900; letter-spacing: .08em; text-align: center; }

.result-screen { display: grid; place-items: center; padding: 24px; background: radial-gradient(circle at 50% 25%, #1d4a49, #071315 60%); }
.result-card { width: min(680px, 100%); padding: clamp(24px, 5vw, 54px); text-align: center; border: 1px solid var(--line); background: rgba(8,25,27,.94); box-shadow: var(--shadow); }
.result-card > p:first-child { color: var(--acid); font-size: .72rem; font-weight: 900; letter-spacing: .18em; }
.result-card h2 { margin: 8px 0 20px; font: 900 clamp(3rem, 9vw, 6rem)/.9 Impact, sans-serif; color: var(--rust-bright); }
.final-score { display: flex; flex-direction: column; }
.final-score small { color: var(--muted); letter-spacing: .18em; }
.final-score strong { font: 900 3rem/1 Impact, sans-serif; }
.run-stats { margin: 24px 0; display: grid; grid-template-columns: repeat(3, 1fr); border-block: 1px solid var(--line); }
.run-stats div { padding: 14px; border-right: 1px solid var(--line); }
.run-stats div:last-child { border: 0; }
.run-stats dt { color: var(--muted); font-size: .65rem; font-weight: 900; letter-spacing: .1em; }
.run-stats dd { margin: 5px 0 0; font-size: 1.25rem; font-weight: 900; }
.save-status { min-height: 1.4em; color: var(--muted); }
.result-actions { display: flex; justify-content: center; gap: 8px; }

.game-dialog { width: min(760px, calc(100% - 28px)); max-height: calc(100svh - 28px); padding: 0; overflow: auto; border: 1px solid #566964; border-radius: 4px; background: #0d2426; color: var(--bone); box-shadow: 0 28px 90px rgba(0,0,0,.7); }
.game-dialog::backdrop { background: rgba(2,9,10,.78); backdrop-filter: blur(4px); }
.dialog-head { padding: 18px 20px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); }
.dialog-head small { color: var(--muted); font-size: .62rem; font-weight: 900; letter-spacing: .18em; }
.dialog-head h2 { margin: 2px 0 0; font: 900 1.8rem/1 Impact, sans-serif; color: var(--rust-bright); }
.close-button { flex: 0 0 auto; }
.how-list { list-style: none; margin: 0; padding: 20px; counter-reset: field; }
.how-list li { min-height: 76px; display: grid; grid-template-columns: 56px 1fr; grid-template-rows: auto auto; align-content: center; column-gap: 12px; border-bottom: 1px solid var(--line); counter-increment: field; }
.how-list li::before { content: counter(field); grid-row: 1/3; align-self: center; color: var(--rust-bright); font: 900 2.8rem/1 Impact, sans-serif; }
.how-list strong { letter-spacing: .1em; }
.how-list span { color: var(--muted); line-height: 1.4; }
.dialog-note { margin: 0; padding: 14px 20px 20px; color: var(--muted); font: italic .85rem/1.5 Georgia, serif; }

.map-dialog { width: min(980px, calc(100% - 28px)); }
#map-canvas { display: block; width: calc(100% - 32px); height: auto; margin: 16px; border: 1px solid var(--line); background: #cdbf91; }
.map-key { padding: 0 18px; display: flex; gap: 20px; flex-wrap: wrap; font-size: .68rem; font-weight: 900; letter-spacing: .08em; }
.map-key span { display: flex; align-items: center; gap: 7px; }
.map-key i { width: 11px; height: 11px; display: inline-block; border-radius: 50%; }
.key-target { background: #b84333; }.key-tower { background: #7442a5; }.key-wall { background: #554e48; }.key-golem { background: #2d2d27; }.key-optional { background: #b18c26; }

.shop-dialog { width: min(1060px, calc(100% - 28px)); text-align: center; }
.shop-summary { padding: 22px 20px 18px; background: linear-gradient(135deg, #1c4140, #0b2022); border-bottom: 1px solid var(--line); }
.shop-summary p { margin: 0; color: var(--acid); font-size: .7rem; font-weight: 900; letter-spacing: .15em; }
.shop-summary h2 { margin: 5px 0 12px; font: 900 2.6rem/1 Impact, sans-serif; color: var(--rust-bright); }
.shop-summary div { display: flex; align-items: baseline; justify-content: center; gap: 8px; }
.shop-summary strong { font: 900 1.6rem/1 Impact, sans-serif; }
.shop-summary span { margin-right: 15px; color: var(--muted); font-size: .62rem; font-weight: 900; }
.shop-title { margin: 18px 0 12px; font-size: .72rem; font-weight: 900; letter-spacing: .17em; color: var(--muted); }
.shop-items { padding: 0 18px 18px; display: grid; gap: 9px; }
.shop-category { border: 1px solid var(--line); background: rgba(255,255,255,.025); }
.shop-category-toggle { width: 100%; min-height: 48px; padding: 8px 13px; display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 8px; border: 0; background: rgba(255,255,255,.045); color: var(--bone); text-align: left; cursor: pointer; }
.shop-category-toggle:hover { background: rgba(215,214,106,.08); }
.shop-category-toggle > span { color: var(--acid); font-size: 1.25rem; }
.shop-category-toggle strong { display: block; font-size: .76rem; letter-spacing: .1em; }
.shop-category-toggle small { display: block; margin-top: 2px; color: var(--muted); font-size: .6rem; }
.shop-category-toggle b { color: var(--rust-bright); font-size: 1rem; }
.shop-category-grid { padding: 9px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; border-top: 1px solid var(--line); }
.shop-category-grid[hidden] { display: none; }
.shop-item { min-height: 132px; padding: 14px; display: grid; grid-template-columns: 38px 1fr; grid-template-rows: auto auto 1fr auto; text-align: left; border: 1px solid var(--line); background: rgba(255,255,255,.045); }
.shop-item:hover:not(:disabled) { border-color: var(--acid); background: rgba(215,214,106,.1); }
.shop-item:disabled { opacity: .45; cursor: not-allowed; }
.shop-item > span { grid-row: 1/5; font-size: 1.7rem; color: var(--acid); }
.shop-item strong { font-size: .82rem; letter-spacing: .07em; }
.shop-item em { margin-top: 3px; color: var(--rust-bright); font-style: normal; font-size: .65rem; font-weight: 900; }
.shop-item small { margin-top: 7px; color: var(--muted); line-height: 1.35; }
.shop-item b { margin-top: 7px; }
.shop-dialog > .primary-button { margin: 0 18px 20px; width: calc(100% - 36px); }

.leader-list { list-style: none; margin: 0; padding: 10px 20px; counter-reset: rank; }
.leader-list li { min-height: 49px; display: grid; grid-template-columns: 40px 1fr auto; align-items: center; border-bottom: 1px solid var(--line); counter-increment: rank; }
.leader-list li::before { content: counter(rank); color: var(--muted); font: 900 1.2rem Impact, sans-serif; }
.leader-list li:first-child::before { content: "♛"; color: var(--acid); }
.leader-list strong { overflow: hidden; text-overflow: ellipsis; }
.leader-list span { color: var(--rust-bright); font-weight: 900; }

.legal-page { min-height: 100vh; min-height: 100svh; padding: clamp(18px, 4vw, 48px); }
.legal-shell { width: min(820px, 100%); margin: 0 auto; border: 1px solid var(--line); background: rgba(8, 25, 27, .96); box-shadow: var(--shadow); }
.legal-header { padding: clamp(22px, 5vw, 44px); border-bottom: 1px solid var(--line); background: linear-gradient(135deg, #153a3b, #091a1c); }
.legal-header .eyebrow { margin-bottom: 10px; }
.legal-header h1 { width: auto; font-size: clamp(2.4rem, 8vw, 4.8rem); line-height: .9; transform: none; }
.legal-header p:last-child { max-width: 620px; margin: 16px 0 0; color: var(--muted); line-height: 1.55; }
.legal-content { padding: clamp(22px, 5vw, 44px); }
.legal-content section + section { margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); }
.legal-content h2 { margin: 0 0 10px; color: var(--rust-bright); font: 900 1.35rem/1.1 Impact, "Arial Black", sans-serif; letter-spacing: .04em; }
.legal-content p, .legal-content li { color: #d3dcd3; line-height: 1.65; }
.legal-content ul { padding-left: 1.25rem; }
.legal-content a, .legal-footer a { color: var(--acid); text-underline-offset: 3px; }
.legal-content code { padding: .12rem .35rem; border: 1px solid var(--line); background: #071416; color: var(--bone); }
.legal-footer { padding: 18px clamp(22px, 5vw, 44px); display: flex; flex-wrap: wrap; gap: 10px 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: .78rem; }

@keyframes breathe { 50% { transform: translateY(-4px); border-color: rgba(215,214,106,.5); } }
@keyframes callout { 0% { opacity: 0; transform: scale(.65) rotate(-2deg); } 10%, 70% { opacity: 1; transform: scale(1) rotate(-1deg); } 100% { opacity: 0; transform: translateY(-15px) rotate(1deg); } }

@media (max-width: 780px) {
  .topbar { grid-template-columns: auto 1fr auto; }
  .crown-score { justify-content: center; }
  .crown-score small { display: none; }
  .crown-score strong { max-width: 120px; }
  .menu-screen { background-position: 43% center; }
  .menu-shade { background: linear-gradient(0deg, rgba(3,10,11,.94) 0%, rgba(3,10,11,.72) 72%, rgba(3,10,11,.22)); }
  .menu-content { align-self: end; padding: 28px 18px max(24px, env(safe-area-inset-bottom)); }
  h1 { font-size: clamp(3.6rem, 19vw, 6rem); }
  .menu-copy { margin: 14px 0; }
  .name-row { flex-direction: column; }
  .menu-actions { align-items: stretch; }
  .menu-actions > * { flex: 1 1 45%; }
  .gore-select { justify-content: center; }
  .game-screen { padding: 5px; }
  .game-hud { gap: 4px; }
  .hud-card { min-height: 50px; padding: 5px 7px; column-gap: 5px; }
  .hud-card strong { font-size: 1.35rem; }
  .hud-card span { font-size: .55rem; }
  .score-card { grid-template-columns: auto 1fr; text-align: left; }
  .score-card small { text-align: left; }
  .score-card strong { grid-column: 2; }
  .score-card span { display: none; }
  .playfield-wrap { width: min(100%, calc((100svh - 285px) * 16 / 9)); min-width: 0; }
  .weather-panel, .upgrade-panel { top: 8px; width: auto; padding: 6px; }
  .weather-panel { left: 8px; }
  .upgrade-panel { right: 8px; display: flex; gap: 4px; }
  .weather-panel > p, .upgrade-panel > p, .condition:not(.golem-condition) { display: none; }
  .golem-condition { min-height: 24px; max-width: 112px; font-size: .54rem; line-height: 1.1; }
  .wind-readout { border: 0; padding: 0; }
  .wind-readout > strong { font-size: 1.35rem; }
  .wind-readout b { font-size: .64rem; }.wind-readout small { font-size: .58rem; }
  .panel-button { margin-top: 3px; min-height: 30px; padding: 0 7px; font-size: .6rem; }
  .aim-deck { min-height: 128px; padding: 7px 10px; grid-template-columns: 1fr 106px 1fr; gap: 10px; }
  .aim-pad { width: 102px; }
  .aim-stick { width: 26px; height: 26px; margin: -13px 0 0 -13px; }
  .aim-instruction strong { font-size: .82rem; }.aim-instruction span { font-size: .63rem; }
  .aim-readout div { padding: 5px; }.aim-readout strong { font-size: .78rem; }.aim-readout > span { font-size: .52rem; }
  .aim-hint { bottom: 14px; min-width: 250px; padding: 8px; }
  .aim-hint strong { font-size: .68rem; }.aim-hint span { font-size: .67rem; }
  .shop-category-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
  .topbar { height: 58px; }
  .screen { min-height: calc(100svh - 58px); }
  .brand span { font-size: .55rem; }.brand strong { font-size: .9rem; }
  .crown-score strong { max-width: 92px; font-size: .7rem; }.crown-score span { font-size: .72rem; }
  .icon-button { width: 36px; height: 36px; }
  .menu-actions > * { flex-basis: 100%; }
  .hud-card small { font-size: .5rem; }.hud-card strong { font-size: 1.1rem; }.hud-card span { font-size: .47rem; }
  .run-stats div { padding: 9px 3px; }
  .result-actions { flex-direction: column; }
  .aim-deck { grid-template-columns: 1fr 96px; }
  .aim-instruction { display: none; }
  .aim-pad { width: 92px; }
  .shop-category-grid { grid-template-columns: 1fr; }
}

@media (max-height: 520px) and (orientation: landscape) {
  .topbar { height: 46px; padding-block: 3px; }
  .screen { min-height: calc(100svh - 46px); }
  .menu-content { padding-block: 15px; }
  h1 { font-size: 3.8rem; }
  .menu-copy { display: none; }
  .start-card { padding: 10px; }
  .game-screen { padding: 3px; }
  .game-hud { position: absolute; z-index: 15; left: 50%; top: 50px; translate: -50% 0; width: min(700px, 60%); pointer-events: none; opacity: .9; }
  .playfield-wrap { width: min(100%, calc((100svh - 172px) * 16 / 9)); min-height: 0; }
  .aim-deck { width: min(620px, 100%); min-height: 106px; grid-template-columns: 1fr 86px 1fr; padding: 5px 8px; }
  .aim-pad { width: 82px; }
  .aim-instruction strong { font-size: .7rem; }.aim-instruction span { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}
