/* AIR RABBIT rough MVP - shared sister UI, copied VERBATIM (read-only source, not linked):
   /Users/yuhei/Game/games/koba-chicken-race-mvp/src/sister-ui.css (the Goma-derived common UI that Shiba / Jinbe /
   Koba also load). Only the blocks this MVP uses are copied; each block notes its source line range. Lane dots,
   ranking, name entry, audio consent and the site introduction are intentionally NOT copied (see REPORT_UI.md). */

/* --- source lines 1-5: layout variables, base font/colours, buttons, mode options, hud, round, notice, controls, modal, result card */
/* Keep the 360px layout below the minimum width; wider screens retain their viewport units. */
:root{--layout-vw:1vw;--layout-vh:1vh;--layout-dvh:1dvh;--layout-svh:1svh;--small-screen-scale:1}
html.small-screen{zoom:var(--small-screen-scale);--layout-vw:3.6px;--layout-vh:calc(1vh / var(--small-screen-scale));--layout-dvh:calc(1dvh / var(--small-screen-scale));--layout-svh:calc(1svh / var(--small-screen-scale))}
html.small-screen #game{overflow-anchor:none}
:root{font-family:"Hiragino Kaku Gothic ProN","Yu Gothic",sans-serif;color:#244951;background:#dceef0;font-synthesis:none;-webkit-tap-highlight-color:transparent}*{box-sizing:border-box}body{margin:0;min-height:calc(100 * var(--layout-svh));display:flex;align-items:center;justify-content:center;gap:100px;background:radial-gradient(ellipse at 40% 20%,#f6faf4,#dceef0 60%,#c8e2e7)}button,select,input{font:inherit}button{cursor:pointer;border:0;color:inherit;touch-action:manipulation}button:focus-visible,select:focus-visible{outline:2px solid #68b9dc;outline-offset:3px}button:disabled{opacity:.5}.game-frame{width:min(calc(100 * var(--layout-vw)),460px);height:calc(100 * var(--layout-dvh));max-height:940px;min-height:550px;position:relative;overflow:hidden;background:#87cbd6;isolation:isolate;box-shadow:0 20px 100px #39616c24}#world{display:block;width:100%;height:100%;position:absolute;inset:0}.vignette{position:absolute;inset:0;pointer-events:none;box-shadow:inset 0 -100px 90px -80px #27768566}[hidden]{display:none!important}.screen{position:absolute;inset:0;pointer-events:none}.screen button,.screen select,.screen input{pointer-events:auto}.eyebrow{font-size:10px;letter-spacing:.14em;font-weight:700}.hero{padding:calc(33px + env(safe-area-inset-top)) 28px 0;position:relative}.hero h1{font-size:36px;letter-spacing:.02em;line-height:1.35;font-weight:800;margin:13px 0 10px}.hero h1 span{margin-left:22px}.hero p{font-size:12px;letter-spacing:.08em;margin:0}.menu-card{position:absolute;bottom:0;left:0;right:0;background:#f9fbf3f5;border-radius:28px 28px 0 0;padding:23px 24px calc(15px + env(safe-area-inset-bottom));box-shadow:0 -9px 45px #27536813;pointer-events:auto}.section-label{display:flex;justify-content:space-between;align-items:center;font-size:11px;font-weight:700;margin-bottom:12px}.section-label span:last-child{font-size:10px;letter-spacing:.07em;color:#708a8c}.mode-options{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.mode-options button{background:#eaf1ed;border:1px solid transparent;border-radius:12px;padding:13px 5px}.mode-options strong{display:block;font-size:15px}.mode-options small{display:block;font-size:10px;margin-top:4px;opacity:.65}.mode-options button[aria-pressed=true]{background:#d4e8e3;border-color:#719e95;color:#285b52}.control-select{display:flex;justify-content:space-between;align-items:center;margin:14px 0;font-size:11px}.control-select select{max-width:215px;border:1px solid #d7e4df;color:#46675f;background:transparent;border-radius:7px;padding:7px 3px;font-size:11px}.primary{display:flex;align-items:center;justify-content:space-between;width:100%;min-height:52px;background:#285f59;border-radius:12px;color:#fffef3;font-weight:700;font-size:14px;padding:13px 19px;box-shadow:0 4px 0 #214f4a}.primary:hover{background:#347069}.primary:active{transform:translateY(2px);box-shadow:0 2px 0 #214f4a}.primary span{font-size:21px;font-weight:400}.menu-foot{display:flex;align-items:center;justify-content:space-between;margin-top:16px;gap:8px}.menu-foot>span{font-size:9px;color:#8b9b93}.text-button{background:none;text-decoration:underline;text-underline-offset:4px;font-size:11px;padding:5px 0;color:#54776f;min-height:30px}.local-note{font-size:9px;line-height:1.7;color:#7b8d85;margin:8px 0 0}.hud{position:absolute;top:0;left:0;right:0;padding:calc(21px + env(safe-area-inset-top)) 22px 14px;display:flex;justify-content:space-between;align-items:flex-start;background:linear-gradient(#e6f5efdd,transparent)}.distance{font-family:ui-rounded,"Arial Rounded MT Bold",sans-serif;line-height:1.1;font-weight:800;font-size:47px;letter-spacing:-.03em;margin-top:6px;font-variant-numeric:tabular-nums}.distance small{font-size:17px;margin-left:6px}.round{width:44px;height:44px;border-radius:50%;background:#fbfff5b5;border:1px solid #ffffff8f;font-size:16px;box-shadow:0 2px 9px #205c6810}.notice{position:absolute;top:calc(119px + env(safe-area-inset-top));left:50%;transform:translateX(-50%);border:1px solid #ffffffe6;background:#fffff0d9;border-radius:30px;font-size:11px;padding:10px 16px;white-space:nowrap;color:#55756e}.controls{position:absolute;bottom:0;left:0;right:0;padding:17px 15px calc(11px + env(safe-area-inset-bottom));background:linear-gradient(transparent,#e6f5edd9 40%);user-select:none}.lane-dots{display:flex;justify-content:center;gap:10px;padding:10px}.lane-dots span{width:7px;height:7px;background:#eefaf79c;border-radius:50%;border:1px solid #517d8580}.lane-dots span.active{background:#285f59;border-color:#285f59;transform:scale(1.3)}.pad-row{display:flex;gap:9px;align-items:stretch}.pad-row button{width:46px;flex:none;background:#fbfff2cf;border:1px solid #ffffff;border-radius:14px;font-size:32px;font-weight:300}.thumb-pad{flex:1;min-width:0;height:62px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:11px;background:#f4fff1bf;border:1px solid #ffffffe0;border-radius:15px;touch-action:none;cursor:ew-resize;font-size:11px;letter-spacing:.07em}.pad-line{width:54px;height:3px;border-radius:4px;background:#759e9399}.controls p{font-size:9px;text-align:center;letter-spacing:.03em;color:#355e64;margin:9px 0 0}.modal{position:absolute;inset:0;display:grid;place-items:center;background:#163c4550;backdrop-filter:blur(5px);padding:25px}.result-card{background:#f9fbf1;border:1px solid #fff;border-radius:25px;width:100%;padding:29px 25px 22px;box-shadow:0 20px 50px #143c4322;text-align:center}.result-card h2{font-size:21px;margin:13px 0 5px}.result-card>p{font-size:12px;line-height:1.8}.result-distance{font-family:ui-rounded,sans-serif;font-size:67px;letter-spacing:-.05em;font-weight:800;padding:15px 0 0}.result-distance small{font-size:22px;margin-left:7px}.best-row{border-top:1px solid #dfe8dc;border-bottom:1px solid #dfe8dc;margin:19px 0 24px;display:flex;justify-content:space-between;padding:13px 0;font-size:11px}.wide{display:block;width:100%;padding:17px 0 7px}.result-card .local-note{font-size:9px}.result-card .primary{margin-top:20px}.model-screen header{padding:35px 25px}.model-screen h2{font-size:22px}.model-screen p{font-size:11px}.model-controls{position:absolute;bottom:0;padding:30px 26px calc(28px + env(safe-area-inset-bottom));width:100%;background:#f9fbf3eb}.model-controls label{font-size:12px}.model-controls input{width:100%;display:block;margin:20px 0;accent-color:#285f59;touch-action:none}.model-controls p{color:#789286;font-size:10px;margin:0 0 20px}.load-message{position:absolute;inset:0;display:grid;place-items:center;padding:30px;background:#e6f4ef;font-size:14px;line-height:1.8;text-align:center;z-index:10}.desktop-note{width:250px;flex:none}.desktop-note h2{font-size:37px;line-height:1.6;font-weight:600;letter-spacing:.07em;margin:28px 0}.desktop-note p{font-size:13px;line-height:2;color:#718b8d}.note-rule{width:33px;height:1px;background:#aac3c4;margin:35px 0 25px}.desktop-note .small{font-size:11px}.prototype-tag{display:inline-block;margin-top:26px;border:1px solid #adc9c8;border-radius:40px;padding:7px 12px;font-size:10px;color:#6d9290;letter-spacing:.08em}@media(max-width:860px){body{gap:0}.desktop-note{display:none}}@media(min-width:861px){.game-frame{border-left:1px solid #fff9;border-right:1px solid #fff9}}@media(max-height:720px){.hero{padding-top:22px}.hero h1{font-size:28px;margin:9px 0}.hero p{font-size:10px}.hero .eyebrow{font-size:8px}.menu-card{padding-top:15px}.mode-options button{padding:9px 5px}.control-select{margin:9px 0}.menu-foot{margin-top:10px}.menu-card .local-note{font-size:8px}.menu-card .primary{min-height:46px}.section-label{margin-bottom:8px}}@media(prefers-reduced-motion:reduce){button{transition:none}}

/* --- source lines 7-59: brand palette, Zen Maru Gothic, home layout, buttons, keyboard keycaps, modal secondary */
/* Second draft: the supplied brand and the blue-white ice palette. */
:root{font-family:"Zen Maru Gothic","Hiragino Maru Gothic ProN","Yu Gothic",sans-serif;color:#153c64;background:#d5effb}
.distance,.result-distance{font-family:inherit}
body{background:radial-gradient(ellipse at 38% 14%,#f8fdff,#deeff8 62%,#c1e2f4)}
.hero{padding:12px 22px 0;text-align:center;background:linear-gradient(#fffffff2,#ffffff96 70%,#ffffff00)}
.hero h1{margin:0 auto;line-height:0;width:min(280px,calc(75 * var(--layout-vw)))}
.hero img{width:100%;height:auto;mix-blend-mode:normal;opacity:1}
.hero p{font-size:11px;font-weight:700;color:#126797;margin-top:-5px;text-shadow:0 1px #fff}
.home{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:clamp(20px,calc(4 * var(--layout-vh)),32px);padding:calc(24px + env(safe-area-inset-top)) 24px calc(28px + env(safe-area-inset-bottom))}
.home .hero{flex:0 0 auto;width:calc(100% + 16px);display:flex;align-items:center;justify-content:center;padding:0;background:none}
.home .hero h1{margin:0;width:100%;max-width:360px;line-height:0}
.home .hero img{display:block;width:100%;height:auto;object-fit:contain;animation:home-logo-pulse 5s ease-in-out infinite}
@keyframes home-logo-pulse{0%,100%{transform:translateY(0) scale(1)}50%{transform:translateY(-2px) scale(1.02)}}
@media(prefers-reduced-motion:reduce){.home .hero img{animation:none}}
.home-menu{width:100%;max-width:340px;flex:0 0 auto;pointer-events:auto}
.home-menu .section-label{justify-content:center;margin-bottom:14px;font-size:20px;color:#153c64;text-shadow:0 1px 3px #ffffffb3}
.home-menu .section-label span:last-child{font-size:inherit;letter-spacing:.04em;color:inherit}
#home-best{display:flex;align-items:baseline;gap:7px;-webkit-text-stroke:5px #fff;paint-order:stroke fill;text-shadow:0 2px 4px #12497155}
#home-best-score{font-size:40px;line-height:1;font-variant-numeric:tabular-nums}
.bgm-toggle{position:absolute;top:calc(16px + env(safe-area-inset-top));right:16px;width:44px;height:44px;padding:11px;display:grid;place-items:center;border-radius:50%;background:#f4fbffe8;border:1px solid #fff;color:#245574;box-shadow:0 2px 8px #18587b14}
.bgm-toggle svg{width:22px;height:22px}
.bgm-toggle .bgm-off{display:none}
.bgm-toggle[data-muted=true] .bgm-on{display:none}
.bgm-toggle[data-muted=true] .bgm-off{display:block}
.audio-consent{z-index:7}
.audio-consent .result-card{max-width:360px;padding:28px 24px}
.audio-consent h2{margin:0 0 24px;font-size:clamp(20px,calc(5.2 * var(--layout-vw)),25px);line-height:1.45}
.audio-consent .primary{justify-content:center;text-align:center}
.pause-audio{min-width:150px;margin:12px auto 2px;padding:9px 20px;border:2px solid #fff;border-radius:999px;background:#e4f5fc;color:#1c5c80;font-size:15px;font-weight:700;box-shadow:0 3px 0 #99cfe3}
.home-menu>.primary{margin-top:16px}
.home-menu .mode-options strong{font-size:clamp(13px,calc(3.7 * var(--layout-vw)),15px);white-space:nowrap}
.home-menu .mode-options small{font-size:clamp(12px,calc(3.3 * var(--layout-vw)),13px);font-weight:700;line-height:1.4;letter-spacing:.02em;white-space:nowrap;opacity:1;color:#35617b}
#start,#resume,#quit,#retry,#back{justify-content:center;text-align:center;letter-spacing:.16em;font-size:16px}
.controls .thumb-pad{width:100%;display:none}
.keyboard-controls{display:flex;align-items:center;justify-content:center;gap:10px;min-height:62px;padding:5px 0 9px;color:#235b7b;font-size:13px;font-weight:700}
.keyboard-controls kbd{position:relative;display:grid;place-items:center;width:44px;height:40px;background:linear-gradient(145deg,#fffffffa 4%,#edfafff5 44%,#bcecf7f2);border:2px solid #fff;border-radius:13px;font-family:inherit;font-size:25px;line-height:1;color:#17739c;text-shadow:0 1px #fff;box-shadow:0 5px 0 #83c7e0,0 7px 10px #246a8d25,inset 0 -2px 0 #d1f2fc;transition:transform .1s ease-out,box-shadow .1s ease-out}
.keyboard-controls kbd:before{content:"";position:absolute;top:4px;left:6px;width:13px;height:4px;border-radius:50%;background:#fff;opacity:.85;transform:rotate(-18deg)}
.keyboard-controls kbd.pressed{transform:translateY(3px);box-shadow:0 2px 0 #83c7e0,0 3px 5px #246a8d20,inset 0 1px 3px #7fcce333;background:linear-gradient(145deg,#e8fbff,#a7e4f6)}
.keyboard-controls span{margin-left:5px;letter-spacing:.02em;text-shadow:0 1px 0 #fff,0 -1px 0 #ffffffa6}
@media(prefers-reduced-motion:reduce){.keyboard-controls kbd{transition:none}}
.modal .primary{min-height:52px}
.result-card .secondary{margin-top:14px;background:#c8e9f8;color:#235b7b;box-shadow:0 4px 0 #a0cee3}
.result-card .secondary:hover{background:#d5effb}
.result-card .secondary:active{box-shadow:0 2px 0 #a0cee3}
@media(pointer:coarse){.controls .thumb-pad{display:flex}.keyboard-controls{display:none}}
.menu-card{background:#f7fcffed;border:1px solid #fff;border-bottom:0;padding-top:19px;box-shadow:0 -8px 35px #15589720}
.mode-options button{background:#e9f4fb;color:#275b7e}
.mode-options button[aria-pressed=true]{background:#fff1a8;border-color:#fff1a8;color:#153c64}
.primary{background:linear-gradient(#1089bf,#07639b);box-shadow:0 4px 0 #084c7b;color:#fff}
.primary:hover{background:linear-gradient(#199bcf,#0676ae)}
.primary:active{box-shadow:0 2px 0 #084c7b}
#retry:focus-visible{outline:none;text-decoration:underline;text-underline-offset:5px}
#result:focus{outline:none}

/* --- source lines 64-67: HUD */
.hud{background:linear-gradient(#e9f9ffeb,transparent);color:#113e68;padding-top:calc(17px + env(safe-area-inset-top))}
.hud .eyebrow{font-size:14px;letter-spacing:.08em}
.hud .distance{font-size:56px}
.hud .distance small{font-size:21px}

/* --- source lines 88-92: hit cue, notice, controls, thumb pad colours */
.hit-cue{position:absolute;z-index:2;pointer-events:none;transform:translate(-50%,-100%);padding:6px 10px 9px;border:2px solid #fff;border-radius:16px;background:#fffdf4;color:#fb6586;font-size:27px;font-weight:700;line-height:1;box-shadow:0 3px 10px #16497726;filter:drop-shadow(0 1px 0 #bfdef0)}
.hit-cue:after{content:"";position:absolute;left:calc(50% - 5px);bottom:-6px;width:10px;height:10px;background:#fffdf4;transform:rotate(45deg);border-right:2px solid #fff;border-bottom:2px solid #fff}
.notice{top:calc(76px + env(safe-area-inset-top));left:auto;right:18px;transform:none;max-width:calc(50% - 20px);width:max-content;padding:10px 13px;white-space:pre;text-align:center;line-height:1.5;background:#f8fdffed;color:#285772;border-color:white;font-size:13px;font-weight:700}
.controls{background:linear-gradient(transparent,#d7f1ffe0 50%)}
.thumb-pad,.pad-row button{background:#f5fcffe3;color:#276586;border-color:white}

/* --- source lines 100-102: result card / best rows */
.controls p{color:#28607e}.result-card{background:#f4fbff}.best-row{border-color:#d2e7f2}
.best-row{align-items:center;flex-wrap:wrap;gap:8px 16px;font-size:14px}
.best-row strong{margin-left:auto;font-size:22px;line-height:1.3;font-variant-numeric:tabular-nums}

/* --- source lines 107-111: 3-2-1 start sequence */
.start-sequence{position:absolute;inset:0;z-index:4;display:grid;place-items:center;pointer-events:none;padding:0 12px;color:#49c5ed;text-align:center;font-family:"Zen Maru Gothic",sans-serif;font-weight:700;line-height:1;white-space:nowrap;text-shadow:0 5px 14px #126a9e78}
.start-sequence span{display:block;max-width:100%;font-size:clamp(98px,calc(34 * var(--layout-vw)),150px);-webkit-text-stroke:7px #fff;paint-order:stroke fill;animation:start-cue-pop .52s cubic-bezier(.2,1.35,.35,1) both}
.start-sequence[data-phase=go] span{font-size:clamp(45px,calc(15 * var(--layout-vw)),70px);letter-spacing:-.04em;-webkit-text-stroke:5px #fff;animation:start-cue-pop .55s cubic-bezier(.2,1.35,.35,1) both}
@keyframes start-cue-pop{from{opacity:0;transform:scale(.55) translateY(15px)}to{opacity:1;transform:scale(1) translateY(0)}}
@media(prefers-reduced-motion:reduce){.start-sequence span,.start-sequence[data-phase=go] span{animation:none}}

/* --- source lines 117-120: full-screen frame, version label, result width, desktop home sizes */
.game-frame{width:calc(100 * var(--layout-vw));max-width:none;height:calc(100 * var(--layout-dvh));max-height:none;min-height:0;border:0;box-shadow:none}
.version-label{display:block;margin-top:16px;text-align:center;font-size:13px;font-weight:700;letter-spacing:.08em;color:#f3fdff;text-shadow:0 1px 4px #0d5274,0 1px 1px #0d5274}
.result-card{max-width:440px}
@media(min-width:861px){.home .hero h1{max-width:clamp(360px,calc(32 * var(--layout-vw)),480px)}.home-menu{max-width:clamp(340px,calc(29 * var(--layout-vw)),425px)}.home-menu .section-label{font-size:25px}#home-best-score{font-size:50px}.home-menu .mode-options button{padding:16px 7px}.home-menu .mode-options strong{font-size:19px}.home-menu .mode-options small{font-size:16px}.home-menu>.primary{min-height:65px;font-size:20px}.version-label{font-size:15px}}

/* --- source lines 122-131: canvas against every viewport edge, text-only thumb pad */
/* Keep the canvas against every viewport edge, including wide desktop windows. */
html,body{width:100%;height:100%;overflow:hidden}
body{display:block}
.game-frame{position:fixed;inset:0;width:100%;height:calc(100 * var(--layout-dvh));flex:none}
/* The touch target stays large while the prompt itself remains text-only. */
.controls .thumb-pad{height:58px;background:none;border:0;border-radius:0;box-shadow:none;color:#16496b;cursor:ew-resize;font-size:clamp(17px,calc(4.4 * var(--layout-vw)),21px);font-weight:700;letter-spacing:.02em;text-shadow:0 1px 2px #fff,0 2px 6px #ffffffb8}
.controls .thumb-pad span{white-space:nowrap}
.game-frame.touch-play{touch-action:none}
.controls .pad-line{display:none}
.keyboard-controls span{font-size:17px}

/* --- source line 234: tall result cards scroll */
.result-card{max-height:calc(calc(100 * var(--layout-dvh)) - 50px);overflow-y:auto}

/* Keep name entry focus in the sky-blue palette; avoid the shared orange ring. */
input:focus-visible{outline:none;border-color:#68b9dc;box-shadow:0 0 0 2px #68b9dc26}

.dialog-close:focus-visible{outline:none;box-shadow:none;color:#0b8fc1}
