@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Thai:wght@400;500;600;700;800;900&display=swap');
:root{--ink:#22099e;--purple:#5200d4;--pink:#ff0448;--paper:#f2f2fa;--blue:#6582ff;--coral:#ff4d4d}*{box-sizing:border-box}body{margin:0;background:var(--paper);color:var(--ink);font-family:'Noto Sans Thai',Tahoma,sans-serif;font-size:16px}button,a{-webkit-tap-highlight-color:transparent}button{font:inherit;cursor:pointer;border:0;color:inherit}button:focus-visible,a:focus-visible{outline:3px solid var(--pink);outline-offset:4px}button:hover{filter:brightness(1.07)}button:active{transform:translateY(2px)}[hidden]{display:none!important}.topbar{max-width:1280px;margin:auto;padding:22px 32px;display:flex;align-items:center;justify-content:space-between;gap:18px}.brand{display:flex;gap:10px;align-items:center;text-decoration:none;color:var(--ink)}.brand img{width:42px;height:42px}.brand span{font-family:Arial,sans-serif;font-size:15px;line-height:1.05;font-weight:900;letter-spacing:1.3px}.top-caption{font:700 11px Arial,sans-serif;letter-spacing:2.6px;opacity:.55}.tools{display:flex;gap:18px;align-items:center}.text-button{background:none;font-weight:600;font-size:14px}.icon-button{height:42px;width:42px;border-radius:50%;border:1px solid #22099e20;background:white;display:grid;place-items:center;font-size:24px;position:relative}.icon-button #sound-slash{position:absolute;font-size:23px}.game-shell{max-width:1216px;margin:2px auto 0;border:1px solid #22099e26;border-radius:28px;overflow:hidden;background:white;box-shadow:0 18px 65px #22099e0c}.stage{position:relative;height:min(640px,calc(100svh - 178px));min-height:520px;isolation:isolate;overflow:hidden;background:#dce3ff;touch-action:none}canvas{position:absolute;inset:0;width:100%;height:100%;display:block}.screen{position:absolute;inset:0;z-index:3}.corner-label{position:absolute;top:23px;left:27px;font-size:13px;font-weight:600;z-index:2;background:#ffffffb8;border:1px solid #ffffffa0;padding:7px 13px;border-radius:20px;backdrop-filter:blur(8px)}.tiny-star{color:var(--purple);padding-right:4px}.home-screen{background:linear-gradient(90deg,#f2f2faef 0%,#f2f2fad9 30%,#f2f2fa00 70%)}.home-copy{position:absolute;left:6%;top:17%;width:50%}.eyebrow{font:700 11px Arial,sans-serif;letter-spacing:2.5px;color:#5200d4}h1{font-size:clamp(55px,7vw,91px);line-height:1.25;letter-spacing:-4px;margin:13px 0 0;font-weight:900}h1 em{font-family:Arial,sans-serif;display:block;font-size:1.19em;line-height:.94;color:var(--pink);position:relative;font-weight:900;letter-spacing:-5px}h1 em span{font-style:normal;font-size:37px;position:absolute;top:0;margin-left:10px}.duo-name{margin-top:20px;font-size:23px;font-weight:800}.duo-name span{font-size:20px;color:#7a72a5;padding:0 7px}.home-description{font-size:16px;margin:9px 0 22px;line-height:1.8}.primary{border-radius:15px;color:white;background:var(--purple);padding:15px 27px;font-weight:700;box-shadow:0 5px 0 #22099e;min-height:52px;transition:transform .15s,filter .15s}.start-button{min-width:224px;font-size:21px;text-align:left;display:inline-flex;justify-content:space-between;gap:45px}.start-button span{font-size:25px}.how-button{margin-left:15px;background:none;font-size:14px;font-weight:600}.how-button span{border:1px solid #22099e40;padding:0 6px;border-radius:100%;margin-left:4px}.home-best{margin-top:23px;color:#686081;font-size:13px}.home-best strong{margin-left:9px;color:var(--ink);font-size:19px}.home-best span{padding-left:5px}.duo-tag{position:absolute;right:12%;bottom:15%;font-size:14px;font-weight:600;background:#fff9;padding:9px 16px;border-radius:99px;transform:rotate(-3deg)}.round-note{position:absolute;bottom:24px;left:6%;font-size:12px;font-weight:500;color:#62597e}.round-note span{padding:0 9px}.game-footer{height:55px;display:flex;align-items:center;justify-content:space-between;padding:0 25px;color:#655c85;font-size:13px}.game-footer button{font-size:13px;background:none;font-weight:600}.keyboard{font:700 10px Arial;border:1px solid #ccc8df;border-bottom:3px solid #ccc8df;border-radius:5px;padding:4px 6px;margin-right:7px}.bottom-note{max-width:1216px;margin:16px auto 20px;display:flex;justify-content:space-between;font-size:12px;color:#746d92;padding:0 8px}.bottom-note span:last-child{font:700 10px Arial;letter-spacing:1.8px;padding-top:5px}.hud{position:absolute;top:20px;left:22px;right:22px;display:flex;align-items:flex-start;justify-content:space-between;z-index:2;pointer-events:none}.hud-card{background:#fffffff0;border:1px solid white;padding:9px 20px;border-radius:17px;min-width:118px;box-shadow:0 6px 20px #22099e0b}.score-card span{display:block;font-size:12px}.score-card strong{font-size:29px;line-height:1.15}.hud-center{text-align:center;background:#ffffffe8;border-radius:18px;padding:8px 18px}.hud-center #hearts{color:var(--pink);font-size:24px;letter-spacing:3px}.timer{font-size:12px;color:#6e648b}.timer span{font-size:22px;font-weight:800;color:var(--ink)}.pause-button{pointer-events:auto;background:white}.skills{position:absolute;bottom:22px;left:22px;display:flex;gap:9px;z-index:2}.skill-chip{display:flex;gap:8px;align-items:center;border-radius:14px;background:#fffef9ef;padding:10px 13px;box-shadow:0 4px 15px #22099e10}.skill-chip>span{font-size:29px}.skill-chip>div{width:100px}.skill-chip b{display:block;font-size:12px}.skill-chip small{display:block;font-size:11px;line-height:1.5}.skill-track{height:4px;background:#e4dcf7;border-radius:5px;margin-top:3px;overflow:hidden}.skill-track i{height:100%;display:block;background:var(--purple);width:0}.pink .skill-track i{background:var(--pink)}.pink>span{color:var(--pink)}.jump-button{position:absolute;right:24px;bottom:21px;border:2px solid white;box-shadow:0 5px 0 #22099e2b;width:84px;height:84px;background:var(--purple);color:white;border-radius:50%;font-size:29px;z-index:3}.jump-button span{display:block;font-size:12px}.speech{position:absolute;top:25%;left:17%;padding:11px 18px;background:white;border:2px solid #22099e;border-radius:17px 17px 17px 2px;box-shadow:4px 4px 0 #22099e15;font-size:15px;font-weight:600;z-index:2;max-width:65%}.countdown{position:absolute;inset:0;display:grid;place-items:center;color:white;background:#22099e45;font:900 110px Arial;z-index:6;text-shadow:0 8px 0 var(--purple)}.result-screen{display:grid;place-items:center;background:#22099e35;backdrop-filter:blur(5px);overflow-y:auto;padding:20px}.result-card{width:min(440px,100%);border-radius:25px;border:2px solid white;background:#fafaff;padding:26px;text-align:center;box-shadow:0 20px 80px #22099e25}.result-card h2{font-size:25px;margin:10px 0 6px}.result-card>p{font-size:13px;color:#7c7194;margin:0}.result-score{padding:17px 0 8px}.result-score>span{display:block;font-size:13px}.result-score>strong{display:block;font:900 68px Arial;letter-spacing:-3px;margin:6px 0;color:var(--purple)}#record-badge{font-size:13px;color:var(--pink);font-weight:700}.result-best{font-size:13px;color:#7c7194}.result-best b{color:var(--ink);margin-left:7px}.result-actions{display:flex;gap:10px;margin-top:22px;justify-content:center}.secondary{background:#ebe7fb;border:1px solid #22099e18;border-radius:14px;padding:12px 18px;min-height:50px;font-weight:600}.campaign-teaser{width:100%;display:flex;align-items:center;gap:12px;text-align:left;background:#f0edfb;border:1px solid #ded7f7;padding:12px;border-radius:13px;margin-top:24px}.campaign-teaser small{display:block;font-size:11px;color:#746a95}.campaign-teaser b{font-size:13px}.campaign-teaser>span:last-child{margin-left:auto}.campaign-symbol{font-size:27px;color:var(--purple)}.loading-screen{display:flex;flex-direction:column;align-items:center;justify-content:center;background:var(--paper);padding:35px;text-align:center;z-index:8}.loading-screen p{font-size:14px;max-width:400px;color:#7b7190}.loading-screen h2{font-size:23px}progress{width:220px;height:8px;accent-color:var(--purple)}dialog{color:var(--ink);font:inherit;border:1px solid white;border-radius:25px;padding:34px;width:min(610px,calc(100% - 28px));max-height:90svh;overflow:auto;box-shadow:0 25px 120px #11003d50;background:#fafaff}dialog::backdrop{background:#18005860;backdrop-filter:blur(6px)}dialog h2{font-size:27px;margin:13px 0 8px}dialog p{font-size:15px;line-height:1.8;color:#6d6385}.close-dialog{position:absolute;right:13px;top:12px;width:33px;height:33px;border-radius:50%;background:#ece8f7;font-size:24px}.help-steps{margin:25px 0}.help-steps>div{padding:13px 0 13px 57px;position:relative;border-bottom:1px solid #22099e10}.step-icon{position:absolute;left:0;top:15px;width:40px;height:40px;display:grid;place-items:center;background:#ece5ff;border-radius:12px;font-size:23px}.help-steps h3{font-size:16px;margin:0}.help-steps p{font-size:14px;margin:5px 0}#help-play{width:100%}#pause-dialog{text-align:center;width:min(380px,calc(100% - 28px))}#pause-dialog button{display:block;width:100%;margin-top:14px}.campaign-partner{font-size:12px;font-weight:700;color:#7c7093;letter-spacing:.3px}.campaign-image{width:132px;height:132px;object-fit:cover;float:right;margin:12px 0 15px 18px;border-radius:12px}.benefits{clear:both;display:grid;gap:9px;margin:21px 0}.benefit{padding:13px;background:#f0edfa;border-radius:12px;font-size:15px;display:flex;gap:12px}.benefit strong{color:var(--purple)}.campaign-note{font-size:13px!important;border-left:3px solid var(--blue);padding-left:12px}.campaign-link{display:block;text-align:center;text-decoration:none;margin:22px 0 13px}.external-note{font-size:12px!important;text-align:center}.campaign-details{font-size:14px;line-height:1.85;margin:18px 0}.campaign-details summary{cursor:pointer;font-weight:600}.campaign-details ul{padding-left:22px}.expired{padding:20px 0;text-align:center}@media(min-width:1450px){.stage{height:690px;max-height:75svh}.home-copy{top:19%}}@media(max-width:800px){.top-caption{display:none}.topbar{padding:16px 20px}.game-shell{margin:0 14px;border-radius:22px}.bottom-note{padding:0 21px}.bottom-note span:last-child{display:none}.home-copy{left:6%;width:55%}h1{font-size:64px}.home-description{max-width:245px}.start-button{min-width:188px}.how-button{display:block;margin:16px 0 0}.home-best{margin-top:12px}.duo-tag{right:5%}.game-footer{padding:0 16px}.footer-detail{display:none}}@media(max-width:540px){.topbar{padding:13px 17px}.brand img{width:35px;height:35px}.brand span{font-size:12px}.tools{gap:7px}.text-button{font-size:12px}.icon-button{width:36px;height:36px}.game-shell{margin:0 10px;border-radius:21px}.stage{height:calc(100svh - 142px);min-height:590px;max-height:760px}.corner-label{font-size:11px;top:15px;left:15px}.home-screen{background:linear-gradient(180deg,#f2f2fadb 0%,#f2f2fa66 49%,#f2f2fa00 70%)}.home-copy{top:10%;width:100%;left:0;text-align:center}.eyebrow{font-size:10px;letter-spacing:2px}h1{font-size:59px;margin-top:10px;line-height:1.2}h1 em{display:inline-block;font-size:1.04em;margin-left:10px;letter-spacing:-3px}h1 em span{display:none}.duo-name{margin-top:8px;font-size:19px}.home-description{font-size:14px;margin:9px auto 18px;max-width:none}.start-button{min-width:225px;font-size:19px;padding:13px 22px}.how-button{display:inline-block;margin:0 0 0 9px;font-size:13px}.home-best{margin-top:16px}.duo-tag{bottom:13%;right:50%;transform:translateX(50%) rotate(-3deg);font-size:12px;white-space:nowrap}.round-note{font-size:11px;left:0;width:100%;text-align:center;bottom:18px}.game-footer{height:43px;font-size:11px}.game-footer button{font-size:12px}.bottom-note{margin:11px 0;font-size:10px;text-align:center;display:block}.hud{top:15px;left:14px;right:14px}.hud-card{min-width:95px;padding:9px 14px}.hud-center{padding:6px 11px}.hud-center #hearts{font-size:20px}.skills{left:12px;bottom:20px;gap:6px}.skill-chip{padding:8px;gap:5px}.skill-chip>div{width:78px}.skill-chip>span{font-size:21px}.skill-chip b{font-size:11px}.jump-button{width:69px;height:69px;right:13px;bottom:22px;font-size:25px}.speech{left:14%;top:24%;font-size:13px}.result-card{padding:22px 18px}.result-card h2{font-size:22px}.result-actions{gap:8px}.result-actions button{font-size:14px;padding:13px 16px}dialog{padding:29px 22px}dialog h2{font-size:24px}.campaign-image{width:95px;height:95px}.campaign-partner{font-size:11px}}@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}
/* SHIFU RUN: title and controls stay in normal flow, with explicit line spacing. */
.bottom-note,.bottom-note span,.site-version{font-family:'Noto Sans Thai',Tahoma,sans-serif;font-size:12px;font-weight:500;letter-spacing:0}
.bottom-note span:last-child{font:inherit;letter-spacing:0;padding-top:0}.site-version{white-space:nowrap}
@media(max-width:800px){.bottom-note{flex-wrap:wrap;justify-content:space-between;gap:5px 14px}.bottom-note span:last-child{display:inline}.site-version{width:auto;text-align:right}}
@media(max-width:540px){.bottom-note span{display:block!important;text-align:center}.site-version{margin-top:3px;text-align:center}}
.home-copy{top:13%;width:45%;display:flex;flex-direction:column;align-items:flex-start}
h1.game-title{display:flex;flex-direction:column;gap:0;margin:0;font-family:Arial,sans-serif;font-size:clamp(50px,6.3vw,78px);line-height:1.04;letter-spacing:-2px}
h1.game-title>span{display:block}h1.game-title em{display:block;font-size:1.12em;line-height:1.03;letter-spacing:-2px;margin:0}
.duo-name{line-height:1.6;margin-top:12px}.home-description{line-height:1.7;margin:7px 0 18px}.home-best{margin-top:17px;line-height:1.8}.how-button{position:static;display:block;margin:15px 0 0;padding:0;line-height:1.6}.round-note{bottom:20px}.duo-tag{right:10%;bottom:12%}.top-caption{font-size:10px;letter-spacing:2px}.tools{gap:12px}.rank-top{white-space:nowrap}.rank-top:first-letter{color:var(--purple)}
button:disabled{opacity:.55;cursor:wait}button:disabled:active{transform:none}#result-duo{position:static;width:180px;height:55px;margin:5px auto 0}.result-score{padding:5px 0}.result-score>strong{font-size:53px}.result-card{width:min(500px,100%)}.result-card>p{font-size:14px}.result-screen{align-items:start;padding:20px}.result-card{margin:auto}.rank-form{text-align:left;margin-top:15px;padding-top:14px;border-top:1px solid #22099e18}.rank-form label{font-size:14px;font-weight:700}.name-row{display:flex;gap:8px;margin-top:7px}.name-row input{font:inherit;font-size:14px;color:var(--ink);border:1px solid #cdc4ed;background:white;border-radius:11px;min-width:0;width:100%;padding:10px 12px}.name-row input:focus{outline:2px solid var(--blue);outline-offset:1px}.name-row button{white-space:nowrap;font-size:14px;padding:10px 13px;min-height:44px}.rank-form small{font-size:12px;color:#766c92;line-height:1.7;display:block;margin-top:7px}#rank-save-status{font-size:13px;line-height:1.6;color:var(--purple);margin:7px 0 0}.rank-result{font-size:14px;margin-top:9px}.result-actions{margin-top:13px}.campaign-teaser{margin-top:16px}.rank-intro{margin:0 0 20px}.rank-crown{color:#ff0448;font-size:30px}.my-rank{background:var(--purple);color:white;border-radius:12px;padding:13px 16px;font-size:15px;font-weight:600;margin:15px 0}.rank-table-wrap{overflow:auto;max-height:47svh;border:1px solid #e6e0f3;border-radius:13px}.rank-table{width:100%;border-collapse:collapse;text-align:left;font-size:15px}.rank-table th{position:sticky;top:0;background:#eee9fa;font-size:13px;padding:12px 16px;z-index:1}.rank-table td{padding:13px 16px;border-bottom:1px solid #eee9f7}.rank-table td:nth-child(2){overflow-wrap:anywhere}.rank-table th:last-child,.rank-table td:last-child{text-align:right;white-space:nowrap;font-weight:700}.rank-table .top-rank{color:var(--purple);font-weight:800}.rank-table tr.is-me{background:#f0e8ff}.rank-note{font-size:12px!important;line-height:1.8;margin-bottom:0}#rank-status{font-size:15px;padding:7px 0}#rank-status:empty{display:none}.skill-chip b,.skill-chip small{font-size:12px}.skill-chip>div{width:112px}
@media(max-width:1000px){.top-caption{display:none}.home-copy{top:13%}.game-title{font-size:64px}.duo-tag{right:7%}}
@media(max-width:540px){.topbar{gap:8px}.tools{gap:6px}.tools .text-button{font-size:12px;padding:3px}.rank-top span{display:none}.rank-top{font-size:22px!important;width:30px}.home-copy{top:10%;width:100%;align-items:center}.home-copy h1.game-title{flex-direction:row;gap:12px;font-size:clamp(39px,11vw,59px);line-height:1.1;letter-spacing:-1px}.home-copy h1.game-title em{font-size:1em;line-height:1.1;margin:0}.duo-name{margin-top:10px;font-size:18px}.home-description{font-size:14px;margin:5px 0 15px}.home-copy .how-button{margin:12px 0 0;font-size:13px}.home-best{margin-top:10px}.duo-tag{right:50%;bottom:12%;transform:translateX(50%) rotate(-3deg)}.result-screen{padding:12px}.result-card{padding:18px 15px}.result-card h2{font-size:21px}.result-score>strong{font-size:46px}.rank-form{margin-top:10px;padding-top:10px}.name-row button{font-size:12px;padding:10px}.rank-table td,.rank-table th{padding:12px 10px}.skill-chip>div{width:81px}.skill-chip b,.skill-chip small{font-size:11px}}
@media(max-height:700px) and (min-width:541px){.home-copy{top:12%}.home-copy h1.game-title{font-size:58px}.duo-name{margin-top:7px}.home-description{margin-bottom:14px}.home-copy .how-button{margin-top:12px}.home-best{margin-top:9px}}
.home-actions{display:flex;align-items:center;gap:17px}.home-actions .how-button{display:inline-flex;align-items:center;gap:4px;margin:0;white-space:nowrap}.home-copy h1.game-title{font-size:clamp(50px,6vw,72px)}.home-best{margin-top:14px}.home-copy .duo-name{margin-top:10px}
@media(max-width:540px){.home-actions{gap:12px}.home-actions .start-button{min-width:195px}.home-copy h1.game-title{font-size:clamp(39px,11vw,59px)}.home-copy .home-best{margin-top:12px}}
@media(max-height:700px) and (min-width:541px){.home-copy h1.game-title{font-size:58px}}

/* Survival edition */
.brand img{width:156px;height:auto;max-height:62px;object-fit:contain}.topbar{padding-top:12px;padding-bottom:12px}.top-caption{display:none}.tools{gap:12px}h1.game-title em .title-star{position:static;display:inline-block;font-style:normal;font-size:.43em;vertical-align:top;margin:5px 0 0 4px;letter-spacing:0}.home-actions{width:100%}.start-button{justify-content:center;gap:38px;text-align:center}.home-bubbles{position:absolute;right:7%;top:18%;width:34%;display:grid;gap:12px;pointer-events:none}.character-bubble{font-size:14px;font-weight:600;line-height:1.6;padding:10px 14px;background:#fff;border:1.5px solid #22099e;border-radius:17px 17px 3px 17px;box-shadow:3px 4px 0 #22099e13}.pui-bubble{border-color:#d770a8;background:#fff2fb;border-radius:17px 17px 17px 3px}.home-bubbles .pui-bubble{margin-right:16%;margin-left:-8%;margin-top:4px}.season-label{font-size:11px;color:var(--purple)}.distance{font-size:13px;font-weight:700}.skills{bottom:22px}.skill-chip>div{width:250px}.skill-chip small{line-height:1.5;max-width:250px}.blast-button{position:absolute;bottom:26px;right:125px;width:74px;height:74px;border-radius:22px;background:#ff0448;color:white;font-size:27px;border:2px solid white;z-index:3;box-shadow:0 5px 0 #22099e25}.blast-button span{display:block;font-size:11px}.blast-button:disabled{cursor:default;opacity:.65}.speech{max-width:70%;top:25%;left:15%;font-size:14px}.end-bubbles{display:grid;gap:6px;margin:8px 0}.end-bubbles .character-bubble{font-size:12px;padding:6px 10px;box-shadow:none}.revive-offers{margin-top:12px;border:1px solid #e6def7;border-radius:16px;padding:12px;background:#f2edff}.revive-offers h3{font-size:16px;margin:0 0 9px}.revive-offers button{width:100%;margin:4px 0;font-size:13px}.revive-offers small{display:block;font-size:11px;line-height:1.7;color:#756990}.revive-offers p{font-size:12px;color:#c01657}.book-cards{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}.book-card{border:1px solid #ddd4f4;border-radius:16px;padding:12px;background:white;text-align:center}.book-card img{width:100%;border-radius:9px;display:block}.book-card h3{font-size:15px;margin:12px 0 5px}.book-card strong{font-size:23px}.book-card a{display:block;margin-top:12px;font-size:13px;padding:11px 8px;text-decoration:none}.book-note{font-size:12px!important}#shop-dialog{width:min(820px,calc(100% - 28px))}#book-reward-progress{position:sticky;top:-34px;z-index:2;background:#ede5ff;padding:14px;border-radius:14px;display:grid;gap:8px;margin:16px 0;border:1px solid #d5c4ff}#book-reward-progress strong{font-size:14px}#book-reward-progress progress{width:100%;height:9px}#book-reward-progress small{font-size:11px}#book-reward-progress button{min-height:44px;padding:10px}.top-rank{font-size:22px;white-space:nowrap}
@media(max-width:700px){.topbar{flex-wrap:wrap;gap:6px;padding:9px 15px}.brand img{width:124px}.tools{gap:7px}.tools .text-button{font-size:12px}.rank-top{width:auto!important;font-size:13px!important}.rank-top span{display:inline!important}.tools #campaign-top{font-size:11px}.book-cards{gap:9px}.book-card{padding:7px}.book-card h3{font-size:12px}.book-card strong{font-size:20px}.book-card a{font-size:12px}.home-bubbles{right:6%;top:47%;width:48%;gap:9px}.character-bubble{font-size:12px;padding:7px 10px}}
@media(max-width:540px){.topbar{justify-content:center}.brand{margin-right:auto}.tools{flex-wrap:wrap;justify-content:flex-end}.tools #campaign-top{display:none}.home-actions{justify-content:center}.home-copy{top:8%}.home-copy h1.game-title{font-size:clamp(34px,9.9vw,52px)}.home-copy h1.game-title em .title-star{display:inline-block;font-size:.42em;margin-top:2px}.home-bubbles{top:43%;width:72%;right:7%;gap:12px}.home-bubbles .afu-bubble{margin-left:16%}.home-bubbles .pui-bubble{margin-right:25%;margin-left:0}.home-description{font-size:13px!important}.home-best{font-size:12px}.skill-chip>div{width:142px}.skill-chip small{font-size:10px}.skills{bottom:20px;left:11px}.blast-button{width:63px;height:65px;right:91px;bottom:22px;border-radius:20px}.jump-button{width:65px;height:65px}.hud-center{padding:6px 9px}.hud-card{min-width:80px;padding:9px 11px}.score-card strong{font-size:24px}.speech{top:25%;left:9%;max-width:82%;font-size:12px}.result-card{margin:0 auto}.book-cards{grid-template-columns:1fr}.book-card{display:grid;grid-template-columns:105px 1fr;align-items:center;column-gap:12px;text-align:left;padding:12px}.book-card img{grid-row:1/4}.book-card h3{font-size:15px;margin:0}.book-card a{margin-top:4px;text-align:center}.book-card strong{font-size:23px}#book-reward-progress{top:-29px}}
@media(max-width:360px){.skill-chip>div{width:108px}.skill-chip b{font-size:10px}.skill-chip small{font-size:9px}.tools{gap:5px}.home-copy h1.game-title{font-size:33px}}
/* Action edition: strong contrast, distinct controls, readable guide. */
.home-best{font-size:14px;font-weight:700;color:#22099e;background:#ffffffed;border:1px solid #ded5f7;border-radius:12px;padding:7px 13px;box-shadow:0 3px 12px #22099e0c}.home-best strong{font-size:21px;font-weight:900}.home-copy .how-button{display:inline-flex;gap:7px;align-items:center;margin:15px 0 0;font-size:14px;padding:3px 4px}.home-actions{justify-content:flex-start}.help-steps h3{font-size:18px;color:#22099e;line-height:1.5}.help-steps p{font-size:14px;line-height:1.9}.help-steps>div{padding-top:20px;padding-bottom:20px}.help-steps strong{color:#5200d4}.share-game{margin-top:12px;width:100%;background:#e9e4ff}#share-status{font-size:12px;overflow-wrap:anywhere}.ultimate-button{position:absolute;z-index:3;right:219px;bottom:26px;background:linear-gradient(135deg,#22099e,#5200d4);color:white;width:90px;height:74px;border:2px solid #fff;border-radius:19px;display:flex;flex-direction:column;align-items:center;justify-content:center;overflow:hidden;box-shadow:0 5px 0 #22099e28}.ultimate-button>span{font-size:22px;line-height:1}.ultimate-button b{font-size:10px;z-index:1}.ultimate-button small{font-size:11px;z-index:1}.ultimate-button i{position:absolute;bottom:0;left:0;height:4px;width:0;background:#ffcf76}.ultimate-button.is-ready{box-shadow:0 0 18px #ffbb66,0 0 35px #ff044860;border-color:#ffe5a0;background:linear-gradient(135deg,#ff0448,#5200d4)}.ultimate-button:disabled{opacity:.8;cursor:default}.skills{bottom:27px}.skill-chip>div{width:200px}.reward-note{display:block;font-size:11px;line-height:1.8;color:#796b95;margin-top:16px}#survey-progress{width:100%;margin:0 0 20px;height:8px}#claim-survey{width:100%}.rank-form{margin-top:12px}.name-row input{background:#fff}.book-card img{aspect-ratio:1;object-fit:contain}.speech{transition:none;font-size:15px;max-width:75%}
@media(max-width:540px){.home-actions{justify-content:center}.home-copy .how-button{margin:11px 0 0}.home-best{font-size:12px;padding:5px 11px}.home-best strong{font-size:18px}.home-bubbles{top:46%}.skills{bottom:99px;left:12px}.skill-chip>div{width:185px}.ultimate-button{left:13px;right:auto;bottom:20px;width:97px;height:65px}.blast-button{right:91px}.help-steps h3{font-size:16px}.help-steps>div{padding-left:48px}.speech{font-size:13px}.home-copy{top:6%}.home-description{margin-bottom:11px!important}.home-copy h1.game-title{font-size:clamp(34px,9.5vw,50px)}}

/* Two-level runner: clear home flow and quiet, animated power language. */
.home-screen{display:grid;grid-template-columns:46% 54%;align-items:start}.home-copy{position:relative!important;top:auto!important;left:auto!important;width:auto!important;margin:62px 0 0 13%;padding:0}.home-bubbles{position:relative;top:auto;right:auto;width:82%;margin:65px auto 0;display:grid;gap:12px}.home-bubbles .character-bubble{margin:0!important;max-width:100%;font-size:14px;line-height:1.65;overflow-wrap:anywhere}.home-bubbles .pui-bubble{justify-self:start}.home-bubbles .afu-bubble{justify-self:end}.slide-button{position:absolute;bottom:26px;right:125px;width:74px;height:74px;border-radius:22px;background:#6582ff;color:white;font-size:29px;border:2px solid white;z-index:3;box-shadow:0 5px 0 #22099e25;touch-action:none;user-select:none}.slide-button span{display:block;font-size:12px}.slide-button.is-held{background:#22099e;box-shadow:0 1px 0 #22099e25;transform:translateY(3px)}.bonus-banner{position:absolute;z-index:2;top:19%;left:50%;transform:translateX(-50%);padding:8px 22px;background:#ffffffe8;border:1px solid #ffffff;border-radius:18px;color:#5200d4;font:900 23px Arial,sans-serif;letter-spacing:1px;white-space:nowrap;box-shadow:0 4px 25px #5200d41a}.bonus-banner span{display:block;text-align:center;font:600 12px 'Noto Sans Thai',sans-serif;letter-spacing:0;margin-top:3px}.speech{top:31%}.ultimate-button.is-ready{box-shadow:0 0 17px #a596ed80;border-color:#e4ddff;background:linear-gradient(135deg,#6582ff,#5200d4)}.campaign-subhead{font-size:20px;line-height:1.5}.reward-note{margin-top:10px}.home-best{align-self:flex-start}#power-status{font-size:12px}.skill-chip>div{width:215px}
@media(max-width:800px) and (min-width:541px){.home-copy{margin:52px 0 0 10%}.home-bubbles{margin-top:52px;width:90%}.home-bubbles .character-bubble{font-size:12px}.home-copy h1.game-title{font-size:56px}}
@media(max-width:540px){.stage{min-height:700px;max-height:820px}.home-screen{display:flex;flex-direction:column;align-items:center}.home-copy{position:static!important;flex:none;width:100%!important;margin:22px 0 0!important;padding:0 12px;align-items:center}.home-copy h1.game-title{font-size:clamp(34px,9.5vw,48px)}.home-copy .duo-name{margin-top:6px}.home-copy .home-description{margin:5px 0 12px!important}.home-copy .how-button{margin-top:11px}.home-copy .home-best{margin-top:12px;align-self:center}.home-bubbles{position:static!important;flex:none;width:min(86%,340px);margin:18px auto 0!important;gap:9px}.home-bubbles .character-bubble{font-size:12px;padding:7px 11px;min-height:34px;width:100%;justify-self:stretch;border-radius:15px}.slide-button{width:65px;height:65px;right:91px;bottom:22px}.bonus-banner{top:19%;font-size:20px}.speech{top:28%;font-size:12px}.skill-chip>div{width:195px}.campaign-subhead{font-size:18px}}

/* v6: thumb-friendly controls, compact contextual speech, uncluttered playfield. */
#jump{left:24px;right:auto;bottom:22px;width:84px;height:84px}
#slide{left:auto;right:24px;bottom:22px;width:84px;height:84px}
#ultimate{left:auto;right:122px;bottom:22px;width:92px;height:84px}
#jump span,#slide span{font:700 15px Arial,sans-serif}#ultimate b{font:700 13px Arial,sans-serif}
#skills{left:50%;bottom:24px;transform:translateX(-50%);pointer-events:none}.skill-chip{padding:7px 12px;background:#ffffffdf}.skill-chip>div{width:auto}.skill-chip small{font-size:12px;font-weight:700}
#speech{top:auto;left:auto;transform:translate(-35%,-100%);max-width:240px;padding:7px 11px;border-width:1px;font-size:13px;line-height:1.45;border-radius:13px 13px 13px 2px;box-shadow:0 3px 10px #22099e13;pointer-events:none}
@media(max-width:540px){#jump{left:14px;right:auto;bottom:20px;width:68px;height:68px}#slide{left:auto;right:14px;bottom:20px;width:68px;height:68px}#ultimate{left:auto;right:92px;bottom:20px;width:82px;height:68px}#jump span,#slide span{font-size:14px}#ultimate b{font-size:12px}#speech{max-width:165px;font-size:12px;padding:6px 9px;transform:translate(-40%,-100%)}#skills{bottom:98px;max-width:90%;white-space:nowrap}.skill-chip small{font-size:11px}}

/* v7: fit the visible mobile viewport, keep controls above browser chrome. */
button,button *,a.primary,.stage{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}input,textarea{-webkit-user-select:text;user-select:text}button{touch-action:manipulation}#jump,#slide,#ultimate{touch-action:none}.brand img{width:126px;max-height:48px}#rank-save-status:empty,#survey-availability:empty{display:none}
.danger-edge{position:absolute;inset:0;border:3px solid #ff7d4e99;box-shadow:inset 0 0 38px #ff4d4d42;z-index:2;pointer-events:none;animation:danger-breathe 1.8s ease-in-out infinite}.danger-banner{position:absolute;left:50%;top:28%;transform:translateX(-50%);z-index:3;text-align:center;white-space:nowrap;pointer-events:none;background:#fff5eced;border:1px solid #ff9b74;border-radius:16px;padding:9px 20px;color:#c64121;box-shadow:0 5px 20px #b730191a}.danger-banner strong{display:block;font:900 27px Arial,sans-serif}.danger-banner span{display:block;font-size:14px;margin-top:2px}.danger-banner span:empty{display:none}.danger-banner.compact{top:18%;padding:6px 13px;border-radius:10px}.danger-banner.compact strong{font-size:16px}.danger-banner.escaped{color:#5200d4;background:#fff;border-color:#d5c7fb}.danger-paused .danger-edge{animation-play-state:paused}@keyframes danger-breathe{50%{box-shadow:inset 0 0 48px #ff674e55;border-color:#ff9a67}}
@media(max-width:540px){.brand img{width:103px;max-height:38px}.topbar{padding:8px 12px}.game-shell{margin:0 8px}.stage{height:min(570px,calc(100svh - 164px - env(safe-area-inset-bottom,0px)));min-height:0;max-height:none}.game-footer{height:35px}.bottom-note{margin:7px 0}.home-copy{margin-top:17px!important}.home-copy h1.game-title{font-size:clamp(29px,8.5vw,42px)}.home-copy .duo-name{font-size:16px;margin-top:5px}.home-copy .home-description{font-size:12px!important;margin:3px 0 9px!important}.home-copy .start-button{min-height:44px;padding:8px 20px;font-size:17px}.home-copy .how-button{margin-top:7px}.home-copy .home-best{margin-top:7px;font-size:11px}.home-best strong{font-size:16px}#jump,#slide,#ultimate{bottom:max(22px,env(safe-area-inset-bottom,0px))}.danger-banner{top:28%;padding:8px 15px}.danger-banner strong{font-size:23px}.danger-banner.compact{top:22%;padding:5px 10px}.danger-banner.compact strong{font-size:14px}.bonus-banner{top:24%;font-size:21px}.hud{top:11px}.hud-center #hearts{font-size:18px}.distance{font-size:11px}.season-label{font-size:10px}}
@media(max-width:540px) and (max-height:650px){.stage{height:calc(100svh - 146px - env(safe-area-inset-bottom,0px))}.home-copy{margin-top:11px!important}.home-copy .home-description{display:none}.home-copy h1.game-title{font-size:30px}.home-copy .how-button{font-size:12px}.home-best{padding:3px 9px}.home-copy .duo-name{margin-bottom:7px}.bottom-note{display:none}.hud-card{padding:6px 9px}.score-card strong{font-size:21px}}
@media(prefers-reduced-motion:reduce){.danger-edge{animation:none;box-shadow:inset 0 0 22px #ff4d4d30}}

.home-description strong,.home-description span{display:block}.home-description strong{font-size:1.08em}.home-description span{margin-top:3px;color:#655c85;max-width:440px}

@media(max-width:540px){.danger-banner{top:108px}.danger-banner.compact{top:101px}.bonus-banner{top:105px}}

/* v9: center the label independently of its icon; keep every mobile menu visible. */
#start{position:relative;display:grid;place-items:center;padding:12px 54px;gap:0;min-width:228px;text-align:center}#start .start-label{font:inherit;line-height:1.5;letter-spacing:0}#start .start-arrow{position:absolute;right:20px;top:50%;transform:translateY(-50%);width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
@media(max-width:540px){.topbar{display:grid;grid-template-columns:auto 1fr;gap:5px 10px}.brand{grid-column:1;grid-row:1}.tools{display:flex;grid-column:1/-1;width:100%;flex-wrap:nowrap;justify-content:space-between;gap:5px}.tools #campaign-top:not([hidden]){display:inline-flex}.tools .text-button,.tools #campaign-top{font-size:14px;padding:5px 3px;white-space:nowrap;min-height:40px}.tools #sound{width:38px;height:38px;flex-shrink:0}.home-copy #start{padding:8px 50px;min-width:220px}.stage{height:min(570px,calc(100svh - 203px - env(safe-area-inset-bottom,0px)))} }
\n/* v10 interaction + alignment fixes */
#start{display:grid;place-items:center;text-align:center;line-height:1;}
#start .start-label{display:block;text-align:center;width:100%;}
#start .start-arrow{display:block;flex:none;}
#jump,#slide,#ultimate,.jump-button,.slide-button,.ultimate-button{
 -webkit-user-select:none;user-select:none;-webkit-touch-callout:none;
 touch-action:none;-webkit-user-drag:none;overscroll-behavior:contain;
}
#jump *,#slide *,#ultimate *{-webkit-user-select:none;user-select:none;pointer-events:none;}
canvas,.stage{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;}
@media(max-width:540px){
 .tools #campaign-top:not([hidden]){display:inline-flex!important;align-items:center;justify-content:center;}
 #start{display:grid!important;place-items:center!important;text-align:center!important;}
 #start .start-arrow{width:22px;height:22px;right:20px;top:50%;transform:translateY(-50%);}
}

/* v14: responsive shell, accessible touch targets and focused game mode. */
html{min-width:280px;background:var(--paper)}
body{min-height:100svh;overflow-x:hidden}
.topbar,.game-shell,.bottom-note{width:calc(100% - 32px)}
.topbar{padding-inline:0}
.tools button{min-height:44px}
.game-shell{position:relative}
.stage{height:clamp(520px,calc(100svh - 178px),690px)}
.home-description{max-width:470px}
.result-card,.book-card,.hud-card,.hud-center,.primary,.secondary{backdrop-filter:saturate(1.1)}
.result-actions>*{flex:1}
.close-dialog{z-index:8}

@media(max-width:700px){
 .topbar,.game-shell,.bottom-note{width:calc(100% - 16px)}
 .topbar{display:grid;grid-template-columns:1fr auto;gap:7px 10px;padding:8px 4px}
 .brand{grid-column:1;grid-row:1;justify-self:start}
 .brand img{width:104px;max-height:40px}
 .tools{grid-column:1/-1;display:grid;grid-template-columns:1fr 1fr 1.35fr 42px;gap:5px;width:100%}
 .tools .text-button,.tools #campaign-top{display:grid;place-items:center;min-width:0;min-height:44px;padding:5px 4px;border:1px solid #ded7f4;border-radius:12px;background:#ffffffb8;font-size:11px;line-height:1.25;white-space:normal}
 .tools #sound{width:42px;height:42px}
 .game-shell{margin-inline:8px}
 .bottom-note{margin-inline:8px}
 dialog{width:min(100%,560px);max-height:88svh;margin:auto auto 0;padding:30px 20px calc(22px + env(safe-area-inset-bottom,0px));border-radius:24px 24px 0 0;border-bottom:0}
 .close-dialog{position:sticky;top:0;float:right;margin:-14px -7px 0 10px;width:42px;height:42px;background:#ece8f7f2;backdrop-filter:blur(8px)}
 .campaign-image{float:none;display:block;width:112px;height:112px;margin:12px auto}
 .result-actions{display:grid;grid-template-columns:1fr;margin-top:14px}
 .result-actions button{width:100%;min-height:50px}
}

@media(max-width:540px){
 .stage{height:calc(100svh - 190px);min-height:430px;max-height:680px}
 .home-screen{background:linear-gradient(180deg,#f2f2faf2 0%,#f2f2faaa 42%,#f2f2fa00 68%)}
 .home-copy{margin-top:clamp(12px,3.4svh,24px)!important}
 .home-description{padding-inline:8px}
 .home-description span{max-width:340px;margin-inline:auto}
 .home-copy .how-button{min-height:42px;padding:7px 10px}
 .home-best{min-height:42px;display:inline-flex;align-items:center;justify-content:center}
 .game-footer{height:38px;padding-inline:16px}
 .game-footer .footer-detail{display:none}
 .bottom-note{padding-inline:10px;line-height:1.55}
 #help-dialog{padding-bottom:92px}
 #help-dialog #help-play{position:fixed;left:18px;right:18px;bottom:max(14px,env(safe-area-inset-bottom,0px));width:auto;z-index:10;box-shadow:0 7px 24px #22099e3b,0 5px 0 #22099e}
 #jump,#slide{width:74px;height:74px;border-radius:24px}
 #ultimate{width:86px;height:74px;border-radius:24px}
 #jump{left:max(14px,env(safe-area-inset-left,0px))}
 #slide{right:max(14px,env(safe-area-inset-right,0px))}
 #ultimate{right:calc(max(14px,env(safe-area-inset-right,0px)) + 84px)}
 .hud{left:12px;right:12px;gap:8px}
 .hud-card,.hud-center{box-shadow:0 4px 18px #22099e17}
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]){overflow:hidden;overscroll-behavior:none}
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .topbar,
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .game-footer,
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .bottom-note{display:none}
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .game-shell{width:100%;height:100svh;margin:0;border:0;border-radius:0;box-shadow:none}
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .stage{height:100svh;min-height:100svh;max-height:100svh;border-radius:0}
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .hud{top:max(11px,env(safe-area-inset-top,0px));left:max(12px,env(safe-area-inset-left,0px));right:max(12px,env(safe-area-inset-right,0px))}
}

@media(max-width:540px) and (max-height:650px){
 .stage{height:calc(100svh - 170px);min-height:350px}
 .home-copy .home-description{display:block!important;margin:4px 0 8px!important}
 .home-copy .home-description span{display:none}
 .home-copy .home-description strong{font-size:12px}
 .home-copy .how-button{margin-top:5px}
 .home-copy .home-best{margin-top:4px}
}

@media(max-height:500px) and (orientation:landscape){
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]){overflow:hidden}
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .topbar,
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .game-footer,
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .bottom-note{display:none}
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .game-shell{width:100%;height:100svh;margin:0;border:0;border-radius:0;box-shadow:none}
 body:is([data-mode="playing"],[data-mode="countdown"],[data-mode="paused"]) .stage{height:100svh;min-height:100svh;max-height:100svh}
 body:not([data-mode="playing"]):not([data-mode="countdown"]):not([data-mode="paused"]) .stage{height:calc(100svh - 68px);min-height:320px}
 #jump,#slide,#ultimate{bottom:12px;height:64px}
 #jump,#slide{width:64px}
 #ultimate{width:80px}
}

.reward-lead{margin:0 0 10px!important;color:#6f6489!important}.reward-list{display:grid;gap:8px}.reward-offer{width:100%;display:grid;grid-template-columns:38px minmax(0,1fr) auto;align-items:center;gap:10px;padding:10px 12px;border:1px solid #ddd5f3;border-radius:13px;background:#fff;color:var(--ink);text-align:left;text-decoration:none;min-height:58px}.reward-offer:hover{border-color:#8b72e8;background:#faf8ff}.reward-offer-icon{width:34px;height:34px;display:grid;place-items:center;border-radius:10px;background:#eee9ff;color:var(--purple);font-size:18px}.reward-offer-copy{min-width:0}.reward-offer-copy b,.reward-offer-copy small{display:block}.reward-offer-copy b{font-size:13px;line-height:1.45}.reward-offer-copy small{font-size:10px;line-height:1.45;color:#766c90;margin-top:2px}.reward-offer-action{color:var(--purple);font-size:11px;font-weight:800;white-space:nowrap}.reward-offer.is-used{background:#f0edf6;color:#887f99}.reward-offer.is-used .reward-offer-icon{background:#e3dfea;color:#887f99}.reward-progress{display:grid;gap:8px;margin:10px 0;padding:12px;border-radius:13px;background:#eae3ff}.reward-progress strong{font-size:13px}.reward-progress progress{width:100%}.reward-progress button{min-height:44px;padding:9px}.reward-hub-list{margin:20px 0}.reward-hub-list .reward-offer{min-height:70px;padding:12px 14px}.reward-hub-list .reward-offer-copy b{font-size:15px}.reward-hub-list .reward-offer-copy small{font-size:12px}#reward-dialog{width:min(680px,calc(100% - 28px))}
@media(max-width:540px){.reward-offer{grid-template-columns:34px minmax(0,1fr);padding:9px}.reward-offer-action{grid-column:2}.reward-hub-list .reward-offer{min-height:64px}.revive-offers{padding:10px}.revive-offers .reward-list{gap:6px}}

/* Reward Hub card grid */
#reward-dialog{width:min(900px,calc(100% - 28px))}.reward-list{grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.reward-offer,.reward-hub-list .reward-offer{display:flex;flex-direction:column;align-items:stretch;gap:0;min-height:100%;padding:0;margin:0!important;overflow:hidden;border-radius:16px;background:#fff;box-shadow:0 5px 18px #22099e0b}.reward-offer-media{display:block;aspect-ratio:16/9;overflow:hidden;background:#e9e5f8}.reward-offer-media img{display:block;width:100%;height:100%;object-fit:cover;transition:transform .2s ease}.reward-offer:hover .reward-offer-media img{transform:scale(1.025)}.reward-offer-copy{display:block;padding:13px 14px 7px}.reward-offer-copy b{font-size:15px;line-height:1.45;color:var(--ink)}.reward-offer-copy small{font-size:12px;line-height:1.55;margin-top:5px;color:#706681}.reward-offer-action{display:block;margin-top:auto;padding:8px 14px 14px;font-size:12px;text-align:left}.reward-hub-list{margin:20px 0 4px}.revive-offers .reward-list{margin:12px 0}.revive-offers .reward-offer-copy b{font-size:13px}.revive-offers .reward-offer-copy small{font-size:10px}.revive-offers .reward-offer-action{font-size:10px}.result-card{width:min(760px,100%)}
@media(max-width:700px){.reward-list{grid-template-columns:repeat(2,minmax(0,1fr))}.reward-offer-copy b{font-size:14px}}
@media(max-width:430px){.reward-list{grid-template-columns:1fr}.reward-offer{display:grid;grid-template-columns:112px minmax(0,1fr);grid-template-rows:auto auto}.reward-offer-media{grid-row:1/3;aspect-ratio:auto;height:100%;min-height:112px}.reward-offer-copy{padding:11px 11px 3px}.reward-offer-action{padding:4px 11px 11px;grid-column:2}.reward-hub-list .reward-offer{display:grid;min-height:112px}}
