:root{font-family:system-ui,-apple-system,'Segoe UI',sans-serif;color:#264854;background:#cddfe8;font-synthesis:none;color-scheme:light}*{box-sizing:border-box}body{margin:0;min-height:100svh;background:radial-gradient(ellipse at 50% 30%,#eff9fc,#bdd5e0)}button,a,input{-webkit-tap-highlight-color:transparent}button{font:inherit;cursor:pointer;color:inherit}button:focus-visible,a:focus-visible{outline:3px solid #8263cd;outline-offset:4px}button:disabled{cursor:default}a{color:inherit;text-decoration:none}.game{max-width:440px;margin:auto;padding:24px 25px max(18px,env(safe-area-inset-bottom));min-height:100svh;position:relative;overflow:hidden;background:linear-gradient(#e6f5fa 0%,#f0f9fa 54%,#fffcf5 100%)}header{display:flex;align-items:center;gap:9px;position:relative;z-index:2}.brand{font-size:20px;letter-spacing:2px;font-weight:900;white-space:nowrap}.brand-mark{color:#ff8f69;font-size:25px;vertical-align:-1px}.edition{font-size:7px;letter-spacing:1px;color:#70909a;margin-left:auto}.icon{flex-shrink:0;border:1px solid #fff;background:#ffffffb0;border-radius:14px;width:42px;height:42px;box-shadow:0 3px 0 #c8dfe780;font-size:20px}.hud{margin-top:24px;background:#ffffffb8;border:1px solid #fff;border-radius:23px;padding:18px 20px 14px;box-shadow:0 9px 24px #538a9710}.level-line,.score-line,.play-stats{display:flex;align-items:center;justify-content:space-between}.eyebrow{font-size:11px;letter-spacing:2px;color:#579397;font-weight:850}.coin{display:flex;align-items:center;gap:7px;font-size:15px;color:#997022;background:#fff6da;padding:5px 10px;border:1px solid #ffe8af;border-radius:20px}.coin i,.reward-coin{font-style:normal;color:#bd8120;border-radius:50%;background:#ffd575;box-shadow:inset 0 0 0 2px #efb844;width:21px;height:21px;text-align:center}.score-line{gap:8px;margin-top:12px}h1{font-size:17px;font-weight:700;margin:0;color:#486570}.score{white-space:nowrap;display:flex;gap:6px;align-items:baseline}.score strong{font-size:32px;line-height:1;letter-spacing:-1px;color:#244651}.score span{font-size:15px;color:#8ba4aa}.score b{font-weight:550}.progress{height:10px;border-radius:20px;background:#e1edf0;margin-top:15px;overflow:hidden;box-shadow:inset 0 2px 2px #7396a013}#progress-fill{height:100%;background:linear-gradient(90deg,#65cabb,#8cdbc2);border-radius:20px;box-shadow:inset 0 2px 0 #ffffff70;transition:width .28s}.play-stats{font-size:10px;color:#7f999f;margin-top:12px;min-height:22px}#combo{font-size:10px;font-weight:850;background:#edf2f6;color:#78929f;border-radius:8px;padding:5px 9px}#combo[data-strength="2"]{background:#dff7ef;color:#269c88}#combo[data-strength="3"]{background:#eee7ff;color:#8658c9}#combo[data-strength="4"]{background:#ffead8;color:#d16a30;box-shadow:0 0 17px #ffb57933}.play-area{position:relative;margin-top:2px}.arena{--pose:-18deg;--landing-pose:-18deg;width:100%;height:300px;position:relative;display:block;border:0;background:none;touch-action:none;user-select:none;perspective:750px}.mat{position:absolute;left:50%;top:137px;transform:translateX(-50%) rotateX(28deg);width:310px;height:143px;border-radius:50%;background:linear-gradient(150deg,#8bd9cc,#4cafaa);border:7px solid #b0e8d9;box-shadow:0 8px 0 #4b9695,0 12px 0 #b4d6cd,0 25px 25px #508f9424,inset 0 0 0 2px #429f9c40;pointer-events:none}.mat-line{position:absolute;inset:10px;border:1px dashed #e3fff480;border-radius:50%}.mat-pattern{position:absolute;bottom:10px;left:0;right:0;text-align:center;letter-spacing:12px;font-size:19px;color:#e3fff47a}.shadow{position:absolute;left:calc(50% - 54px);top:202px;width:108px;height:23px;background:#286e7270;border-radius:50%;filter:blur(7px);transform:rotate(-8deg)}.bone-wrap{position:absolute;width:172px;height:204px;left:calc(50% - 86px);top:30px;transform:rotate(var(--pose));pointer-events:none;will-change:transform}#bone{width:100%;height:100%;object-fit:contain;filter:drop-shadow(7px 10px 3px #29676124)}.throwing .bone-wrap{animation:toss var(--throw-ms,760ms) linear both}.throwing .shadow{animation:ground-shadow var(--throw-ms,760ms) linear both}
@keyframes toss{0%{transform:translate(0,0) rotate(var(--pose)) scale(1)}12%{transform:translate(-5px,7px) rotate(-25deg) scale(1.04,.94)}40%{transform:translate(19px,-71px) rotate(150deg) rotateY(145deg) scale(1.04)}64%{transform:translate(10px,-41px) rotate(290deg) rotateY(300deg)}80%{transform:translate(0,5px) rotate(calc(360deg + var(--landing-pose))) rotateY(360deg) scale(1.08,.93)}90%{transform:translate(-3px,-14px) rotate(calc(360deg + var(--landing-pose))) rotateY(360deg) scale(.98,1.02)}100%{transform:translate(0,0) rotate(calc(360deg + var(--landing-pose))) rotateY(360deg) scale(1)}}
@keyframes ground-shadow{0%,100%{transform:scale(1);opacity:1}40%{transform:translateX(15px) scale(.65);opacity:.35}80%{transform:scale(1.13);opacity:1}90%{transform:scale(.9);opacity:.7}}
.cloud{position:absolute;border-radius:50%;background:#fff8;pointer-events:none}.cloud-a{width:110px;height:22px;top:62px;left:-65px;transform:rotate(-10deg)}.cloud-b{width:110px;height:20px;top:135px;right:-70px;transform:rotate(-12deg)}.spark{position:absolute;pointer-events:none;color:#aacdcf}.spark-a{left:35px;top:93px;font-size:20px}.spark-b{right:25px;top:46px;font-size:27px;color:#e9c681}#float-score{position:absolute;right:28px;top:93px;font-size:32px;line-height:1;color:var(--face-color,#e38a50);font-weight:900;text-shadow:0 3px white,2px 0 white,-2px 0 white;pointer-events:none}.pop{animation:pop .42s cubic-bezier(.2,.8,.3,1.4) both}@keyframes pop{0%{transform:scale(.65);opacity:.3}65%{transform:scale(1.13);opacity:1}100%{transform:scale(1);opacity:1}}.particles{position:absolute;left:50%;top:155px;pointer-events:none;z-index:3}.particles i{position:absolute;width:7px;height:11px;border-radius:3px;animation:particle .85s ease-out both;animation-delay:var(--delay)}@keyframes particle{from{transform:translate(0,0) rotate(0);opacity:1}to{transform:translate(var(--x),var(--y)) rotate(var(--r));opacity:0}}.result{text-align:center;min-height:71px;margin-top:-3px;position:relative}.result h2{font-size:20px;font-weight:850;margin:0 0 7px}.result p{font-size:11px;color:#75919b;margin:0;line-height:1.5}.primary{width:100%;border:1px solid #ffb6a0;border-radius:18px;background:linear-gradient(#ff9b80,#f67d66);color:white;padding:17px 18px;font-size:17px;font-weight:900;letter-spacing:1px;box-shadow:0 5px 0 #d56452,0 9px 17px #f28e7028;text-shadow:0 1px #d6655260;transition:transform .1s,filter .15s}.primary:hover{filter:brightness(1.035)}.primary:active{transform:translateY(3px);box-shadow:0 2px 0 #d56452}.primary:disabled{filter:saturate(.65)}.primary span{float:right;font-size:24px;line-height:22px}.gesture-hint{text-align:center;color:#9aaeb0;font-size:8px;letter-spacing:2px;margin:15px 0 19px}.face-guide{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}.face{position:relative;display:flex;flex-direction:column;align-items:center;border:1px solid #e7eeeb;background:#ffffff9c;border-radius:15px;padding:11px 5px 9px;font-size:10px;color:#75909a;gap:3px;transition:transform .2s,border-color .2s}.face i{font-style:normal;font-size:24px;height:32px}.face b{font-weight:850;color:var(--face-color);font-size:12px}.face.active{border-color:var(--face-color);transform:translateY(-3px);box-shadow:0 5px 12px #55868112}.face.active::after{content:'';position:absolute;top:-4px;width:6px;height:6px;border-radius:50%;background:var(--face-color)}footer{display:flex;justify-content:space-between;gap:10px;margin-top:19px;font-size:8px;color:#90a8aa;letter-spacing:.5px}#save-status{font-size:8px;letter-spacing:0;text-align:right}dialog{border:1px solid white;background:#f8fcfa;color:#264854;border-radius:28px;padding:0;width:min(370px,calc(100% - 36px));max-height:90svh;box-shadow:0 25px 100px #214e5860}dialog::backdrop{background:#244d667a;backdrop-filter:blur(7px)}dialog[open]{animation:card-in .25s ease-out}@keyframes card-in{from{transform:translateY(15px) scale(.96);opacity:0}to{transform:none;opacity:1}}.modal-body{padding:29px;position:relative}.modal-body h2{font-size:24px;font-weight:850}.modal-body label{display:flex;justify-content:space-between;padding:15px 0;color:#64818a;font-size:14px}.modal-body input{accent-color:#37a999;width:21px;height:21px}.modal-body .primary{margin-top:20px;font-size:13px;letter-spacing:.5px}.secondary{border:1px solid #c8dfdd;border-radius:13px;background:white;width:100%;padding:13px;margin-top:16px}.reward{text-align:center;background:radial-gradient(circle at 50% 15%,#fff4d3,transparent 40%)}.reward .eyebrow{display:block;font-size:10px;color:#bc974a}.reward h2{margin:12px 0}.reward p{font-size:12px;color:#8aa1a8;line-height:1.65}.medal{font-size:54px;color:#fff1a5;line-height:84px;width:94px;height:94px;background:linear-gradient(135deg,#ffd170,#eeaa3c);border:5px solid #ffe9ad;border-radius:30px;box-shadow:0 6px 0 #d89d3c,0 14px 30px #dfac3740;margin:7px auto 27px;text-shadow:0 3px #d09a2c;transform:rotate(-8deg)}.reward-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:24px 0 18px}.reward-grid div{background:#f0ecff;border:1px solid #e6dffb;border-radius:18px;padding:16px 10px}.reward-grid div+div{background:#fff3d9;border-color:#ffebbf}.reward-grid i{display:block;font-size:22px;color:#9a7dd1;font-style:normal;margin:0 auto 7px}.reward-grid .reward-coin{color:#bd8120;font-size:20px;width:26px;height:26px}.reward-grid strong{display:block;font-size:28px;color:#755ab0}.reward-grid div+div strong{color:#b48632}.reward-grid span{display:block;font-size:10px;letter-spacing:2px;margin-top:4px;color:#9b91b0}#reward-note{font-size:10px}#celebration{top:105px}#level-list:not([hidden]){display:grid;grid-template-columns:repeat(5,1fr);gap:8px;margin-top:16px}#level-list button{background:#e4f1ed;border:1px solid #c7e1d8;border-radius:10px;padding:10px 0}#level-list button:disabled{opacity:.3}#transition:not([hidden]){position:absolute;inset:0;display:grid;place-items:center;background:#eef9f6ec;z-index:10;color:#428e87;font-weight:900;font-size:29px;animation:level-in .56s both;pointer-events:all}@keyframes level-in{0%{opacity:0;transform:translateX(15px)}25%,70%{opacity:1;transform:none}100%{opacity:0;transform:translateX(-15px)}}.no-motion *,.no-motion *::before,.no-motion *::after{animation:none!important;transition:none!important}.no-motion .particles{display:none}
@media(min-width:700px){.game{margin:22px auto;border:6px solid #ffffffa0;border-radius:36px;min-height:0;box-shadow:0 28px 80px #38658026}}
@media(max-height:760px){.game{padding-top:16px}.hud{margin-top:16px;padding:14px 17px 11px}.arena{height:251px}.bone-wrap{top:14px;width:156px;height:185px;left:calc(50% - 78px)}.mat{top:114px;width:280px;height:125px}.shadow{top:181px}.result{min-height:62px}.gesture-hint{margin:13px 0}.face{padding:8px 4px}.face i{font-size:21px;height:27px}footer{margin-top:15px}.particles{top:135px}}
@media(max-width:370px){.game{padding-left:18px;padding-right:18px}.edition{font-size:6px}.hud{padding-left:16px;padding-right:16px}.result h2{font-size:18px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}.particles{display:none}}
/* Compact portrait layouts keep the action and four-face legend together. */
@media(min-height:761px){.arena{height:270px}.mat{top:122px}.shadow{top:187px}.bone-wrap{top:20px}}
@media(max-height:700px){.game{padding-top:12px;padding-bottom:12px}header .icon{height:36px;width:36px}.hud{margin-top:12px;padding:10px 15px}.score-line{margin-top:7px}.progress{margin-top:10px}.play-stats{margin-top:7px}.arena{height:203px}.bone-wrap{width:138px;height:164px;left:calc(50% - 69px);top:5px}.mat{width:260px;height:107px;top:91px}.shadow{top:150px}.result{min-height:53px}.result h2{font-size:17px}.primary{padding:14px 18px}.gesture-hint{margin:11px 0}.face{padding:6px 4px}.face i{height:23px;font-size:19px}footer{margin-top:11px}.spark-a{top:61px}.spark-b{top:25px}}

/* Phase 2B: four independent shagai on one mat. */
#objective-list{display:flex;flex-wrap:wrap;gap:4px 9px;margin-top:9px;font-size:10px;color:#577b83;min-height:14px}.objective.constraint{color:#b4773d}.play-stats{margin-top:6px}.arena{height:289px;--throw-ms:760ms}.arena .mat{width:328px;height:196px;top:60px}.arena .mat-pattern{bottom:8px}.arena .particles{top:150px}.shagai-slot{position:absolute;width:105px;height:125px;left:calc(50% - 114px);top:32px;pointer-events:none;--drift:-20px;--spin:360deg}.shagai-slot:nth-child(2){left:calc(50% + 13px);top:47px;--drift:24px;--spin:-360deg}.shagai-slot:nth-child(3){left:calc(50% - 100px);top:146px;--drift:-28px;--spin:-360deg}.shagai-slot:nth-child(4){left:calc(50% + 28px);top:135px;--drift:17px;--spin:360deg}.shagai-slot .bone-wrap{width:91px;height:106px;left:7px;top:0;transform:rotate(var(--pose));will-change:auto}.bone{width:100%;height:100%;object-fit:contain;filter:drop-shadow(3px 5px 2px #24576127)}.shagai-slot .shadow{width:52px;height:12px;left:28px;top:84px;filter:blur(4px);background:#286e7250}.face-result{position:absolute;top:98px;left:0;right:0;font-size:10px;color:#416777;font-weight:700;text-align:center;background:#ffffffc9;border:1px solid #ffffffb0;border-radius:12px;padding:3px 1px;margin:0 9px}.throwing .face-result{opacity:0}.throwing .bone-wrap{animation:four-toss var(--throw-ms) linear both;animation-delay:var(--delay);will-change:transform}.throwing .shadow{animation:ground-shadow var(--throw-ms) linear both;animation-delay:var(--delay)}
@keyframes four-toss{0%{transform:translate(0,0) rotate(var(--pose))}12%{transform:translate(0,4px) rotate(var(--pose)) scale(1.04,.94)}40%{transform:translate(var(--drift),-57px) rotate(calc(var(--spin) * .45)) rotateY(160deg)}64%{transform:translate(calc(var(--drift) * .5),-25px) rotate(calc(var(--spin) * .8)) rotateY(285deg)}80%{transform:translate(0,4px) rotate(calc(var(--spin) + var(--landing-pose))) rotateY(360deg) scale(1.08,.93)}90%{transform:translate(0,-9px) rotate(calc(var(--spin) + var(--landing-pose))) rotateY(360deg)}100%{transform:translate(0,0) rotate(calc(var(--spin) + var(--landing-pose))) rotateY(360deg)}}
#float-score{top:7px;right:10px;font-size:25px;color:#9973d0;z-index:4}#special-banner:not([hidden]){position:absolute;left:0;right:0;top:0;z-index:5;font-size:17px;font-weight:950;color:#a97727;text-shadow:0 2px white;background:#fff5d6e8;padding:9px;border:1px solid #f6d991;border-radius:14px;animation:pop .4s both;pointer-events:none}.berkh .mat{box-shadow:0 8px 0 #4b9695,0 12px 0 #b4d6cd,0 0 35px #f5c463a0,inset 0 0 0 3px #f7d680;animation:berkh-glow .95s ease-out}.four-kind .mat{box-shadow:0 8px 0 #4b9695,0 12px 0 #b4d6cd,0 0 25px #b29bea80}#result-name[data-combination="FOUR_BERKH"]{color:#b7812c}#result-name[data-combination="FOUR_KIND"]{color:#8262bc}.result{min-height:66px}.result h2{font-size:19px}.result p{font-size:11px}@keyframes berkh-glow{0%{filter:brightness(1)}35%{filter:brightness(1.2)}100%{filter:brightness(1)}}
@media(max-height:760px){.arena{height:243px}.arena .mat{width:294px;height:164px;top:49px}.shagai-slot{top:18px;left:calc(50% - 102px)}.shagai-slot:nth-child(2){top:28px;left:calc(50% + 6px)}.shagai-slot:nth-child(3){top:117px;left:calc(50% - 91px)}.shagai-slot:nth-child(4){top:107px;left:calc(50% + 19px)}.shagai-slot .bone-wrap{width:78px;height:93px;left:13px}.shagai-slot .shadow{top:72px}.face-result{top:84px}.result{min-height:59px}.result h2{font-size:18px}.arena .particles{top:130px}}
@media(max-height:700px){#objective-list{margin-top:6px;font-size:9px}.arena{height:205px}.arena .mat{width:279px;height:142px;top:43px}.shagai-slot{top:7px}.shagai-slot:nth-child(2){top:16px}.shagai-slot:nth-child(3){top:91px}.shagai-slot:nth-child(4){top:83px}.shagai-slot .bone-wrap{width:68px;height:80px;left:18px}.shagai-slot .shadow{top:61px;width:44px}.face-result{top:71px;font-size:9px;padding:2px 1px}.result{min-height:51px}.result h2{font-size:17px}.result p{font-size:10px}.arena .particles{top:100px}#special-banner:not([hidden]){font-size:13px;padding:5px;top:0}#float-score{top:0;font-size:20px}.gesture-hint{margin:10px 0}}
.berkh #float-score{visibility:hidden}
@media(min-height:761px){.game{padding-top:20px;padding-bottom:14px}.hud{margin-top:18px;padding-top:14px;padding-bottom:10px}.gesture-hint{margin-top:12px;margin-bottom:14px}footer{margin-top:14px}}
/* Phase 2C progression screens */
[hidden]{display:none!important}body[data-view="game"] .edition,body[data-view="map"] .edition{display:none}#nav-back{margin-left:auto}#home-screen{padding-top:29px}.home-intro .eyebrow{font-size:9px;letter-spacing:2px}.home-intro h1{font-size:32px;line-height:1.25;letter-spacing:-1px;color:#244b56;margin:13px 0}.home-intro p{font-size:11px;color:#7b99a2}.home-art{height:215px;position:relative}.home-art img{position:absolute;width:114px;height:145px;top:21px;left:54px;transform:rotate(-23deg);filter:drop-shadow(7px 11px 4px #4b797e25)}.home-art img+img{left:auto;right:45px;top:41px;transform:rotate(22deg)}.home-orbit{position:absolute;inset:55px 10px 20px;border-radius:50%;background:linear-gradient(145deg,#a3e2cf,#67bab7);box-shadow:0 9px #529c9f,0 17px 25px #77a2a32a;border:6px solid #bde9de}.home-spark{position:absolute;right:24px;top:10px;font-size:28px;color:#ecc272}.profile-card{border:1px solid white;border-radius:20px;padding:17px;background:#ffffffc9;margin-bottom:23px;box-shadow:0 7px 18px #9bbbb71a}.profile-top,.profile-bottom{display:flex;justify-content:space-between;align-items:center;gap:8px}.profile-top b{font-size:12px;color:#4f7c8c}.profile-top span{font-weight:800;color:#b27e2e}.profile-bottom{font-size:10px;color:#829ca4;margin-top:10px}.profile-bottom b{color:#c59a3a;font-size:13px}#xp-fill{height:100%;background:linear-gradient(90deg,#9780d4,#c0acef);border-radius:10px;transition:width .25s}.home-save{text-align:center;font-size:9px;color:#87a2a6;margin:18px 0 0}#home-map{margin-top:0}.chest-invite{width:100%;padding:12px;border:1px solid #e9d5a1;border-radius:14px;background:linear-gradient(120deg,#fff7dc,#fce9b6);color:#9f7732;font-size:11px;font-weight:850;margin-top:13px;letter-spacing:.5px}.map-heading{margin:27px 0 12px}.map-heading h1{font-size:29px;margin:8px 0}.map-heading p{font-size:12px;color:#7e9ca1}#level-map{height:min(60svh,530px);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#b3d8d2 transparent;padding:18px 0 30px;position:relative;background:radial-gradient(ellipse at 50% 50%,#bfe9e345,transparent 65%);border-radius:22px}#level-map .map-row{height:102px;display:flex;align-items:center;flex-direction:column;position:relative;transform:translateX(var(--offset));width:110px;margin:0 auto}#level-map .map-row::after{content:'';height:30px;border-left:3px dotted #9bc6bd88;position:absolute;bottom:1px;left:54px;z-index:0}#level-map .map-row:last-child::after{display:none}.level-node{position:relative;z-index:1;border:4px solid #d1f0e5;background:linear-gradient(#83d6c4,#4dafaa);border-radius:50%;width:57px;height:57px;font-size:21px;font-weight:900;color:white;box-shadow:0 5px #438e90}.level-node:disabled{background:#dee8ea;color:#a8b8bf;border-color:#eaf1f2;box-shadow:0 4px #cad9dd;filter:grayscale(.8);font-size:17px}.level-node.recommended{background:linear-gradient(#ffa083,#f78266);border-color:#ffe1bb;box-shadow:0 5px #d56951,0 0 0 5px #ffd19b55}.node-caption{font-size:12px;font-weight:800;color:#bf9948;margin-top:8px;letter-spacing:2px}.milestone-caption{font-size:8px;color:#ad8946;background:#fff8e4;border-radius:6px;padding:1px 4px;position:absolute;left:89px;top:17px;width:73px;white-space:normal}#level-map .map-row:nth-child(5n) .milestone-caption{left:auto;right:89px}.earned-stars{font-size:44px;letter-spacing:5px;color:#efbb54;text-shadow:0 3px #d4983740;margin:18px 0 4px}#best-stars{font-size:10px;color:#b89449;margin:4px}#reward-dialog .medal{display:none}#reward-dialog .reward-grid{margin-top:15px}#reward-dialog .modal-body{padding:25px}#reward-dialog .secondary{font-size:11px;padding:11px;margin-top:13px}#star-goals{font-size:8px;color:#ab975c;margin:8px 0 0}.reward #reward-chest{margin-top:8px}#chest-art{height:135px;width:145px;position:relative;margin:30px auto 20px;filter:drop-shadow(0 9px 9px #91744922)}.chest-box{position:absolute;left:8px;right:8px;bottom:8px;height:77px;background:linear-gradient(135deg,#78c3c2,#39858e);border:6px solid #ebc673;border-radius:7px 7px 15px 15px;box-shadow:inset 0 -8px #28657344}.chest-lid{position:absolute;left:4px;right:4px;top:15px;height:46px;background:linear-gradient(#f6d78e,#cf9f49);border:5px solid #ffe2a6;border-radius:28px 28px 5px 5px;z-index:2;transform-origin:bottom left;transition:transform .3s}.chest-lock{position:absolute;top:65px;left:57px;z-index:3;background:#ffe0a0;color:#b3873d;border:2px solid #f4cd78;border-radius:5px;width:32px;height:32px;line-height:27px;font-size:24px}.opening{animation:chest-wiggle .65s ease-in-out}.opened .chest-lid{transform:translateY(-30px) rotate(-12deg)}.opened .chest-lock{opacity:0}.opened::before{content:'✦';position:absolute;left:39px;top:17px;font-size:65px;color:#f8c971;text-shadow:0 0 30px #ffce67}@keyframes chest-wiggle{20%{transform:rotate(-6deg) scale(1.03)}40%{transform:rotate(6deg)}60%{transform:rotate(-3deg)}100%{transform:none}}#levelup-toast:not([hidden]){position:fixed;z-index:20;bottom:24px;left:50%;transform:translateX(-50%);background:#8269bc;color:white;padding:13px 23px;white-space:nowrap;border-radius:20px;box-shadow:0 8px 30px #42306140;font-size:12px;font-weight:800;pointer-events:none}body:not([data-view="game"]) .game{min-height:min(820px,100svh)}
@media(max-height:700px){#home-screen{padding-top:20px}.home-intro h1{font-size:27px}.home-art{height:150px}.home-art img{width:90px;height:112px;top:0}.home-art img+img{top:16px}.home-orbit{inset:30px 13px 16px}.profile-card{padding:13px;margin-bottom:17px}.home-save{margin-top:12px}#star-goals{margin-top:5px;font-size:7px}.map-heading{margin-top:18px}.earned-stars{font-size:35px}.reward-grid div{padding:10px}.modal-body{padding:22px}#chest-art{margin-top:18px;margin-bottom:10px}}
#chest-art{display:block;border:0;padding:0;background:transparent;color:inherit}#chest-art .chest-lock{pointer-events:none}
@media(max-width:699px){body:not([data-view="game"]) .game{min-height:100svh}}
/* Primary game: pull-back flick prototype. Legacy screens remain independently accessible. */
body[data-view="flick"] .edition{display:none}#home-flick{margin:0 0 10px}#home-map{font-size:11px}.legacy-note{line-height:1.6;color:#8b949b!important;font-size:10px!important}.flick-hud{margin-top:20px;background:#ffffffb8;padding:16px 18px;border:1px solid white;border-radius:20px}.flick-hud .eyebrow{font-size:9px}.flick-hud h1{font-size:18px;margin:7px 0 14px}.flick-counters{display:flex;justify-content:space-between;gap:8px}.flick-counters small{display:block;color:#769795;font-size:8px;letter-spacing:1.2px;margin-bottom:5px}.flick-counters strong{font-size:20px;color:#315c63}.flick-field{position:relative;margin:12px -6px 0}#flick-board{width:100%;aspect-ratio:360/460;display:block;touch-action:none;user-select:none;-webkit-user-select:none;cursor:crosshair;outline-offset:-5px}#flick-board image{pointer-events:none}#flick-board[data-phase="moving"]{cursor:wait}.flick-power-row{display:flex;align-items:center;gap:12px;margin-top:8px;font-size:10px;color:#688f92}.flick-power-row>span{min-width:86px}.flick-power-row b{color:#c77c58}#flick-power-bar{height:7px;border-radius:8px;background:#d7e7e4;flex:1;overflow:hidden}#flick-power-fill{height:100%;background:linear-gradient(90deg,#f2c47a,#ee8c70);border-radius:8px}#flick-feedback{text-align:center;font-size:14px;font-weight:800;color:#437f7d;min-height:20px;margin:14px 0 7px}.flick-tip{text-align:center;font-size:10px;line-height:1.6;color:#87a3a3;margin:0}.flick-actions{display:flex;gap:10px}.flick-actions .secondary{font-size:10px;padding:10px;margin-top:12px}.flick-help{font-size:10px;color:#7c969b;margin-top:16px;line-height:1.6}.flick-help summary{cursor:pointer}.flick-help label{display:flex;justify-content:space-between;align-items:center;margin:9px 0}.flick-help input{accent-color:#dc8d73}.flick-help button{font-size:10px}.flick-field #flick-outcome:not([hidden]){position:absolute;inset:12% 12px auto;background:#fcfef9f5;box-shadow:0 18px 50px #32626135;border:1px solid white;border-radius:24px;padding:24px;text-align:center;z-index:5}#flick-outcome h2{font-size:23px;color:#3e7f78}#flick-stars{color:#daac49;font-size:28px;font-weight:800}#flick-outcome-detail{font-size:12px;color:#789396}#flick-outcome button{font-size:12px}#flick-outcome .primary{margin-top:12px}
@media(max-height:760px){.flick-hud{margin-top:12px;padding:11px 15px}.flick-hud h1{margin:5px 0 9px;font-size:16px}.flick-counters strong{font-size:17px}.flick-field{width:min(100%,290px);margin:8px auto 0}#flick-feedback{margin-top:10px;font-size:12px}.flick-tip{font-size:9px}.flick-help{margin-top:12px}}
@media(min-width:700px){.flick-field{max-width:320px;margin-left:auto;margin-right:auto}}
.flick-selector{display:flex;gap:6px;margin:12px 0}.flick-selector button{flex:1;border:1px solid #bed8d1;border-radius:8px;padding:9px 2px;font-size:10px;color:#3f7068;background:#f8fcf5}.flick-selector button[aria-pressed="true"]{background:#426f69;color:white}.flick-hud #flick-objective{font-size:16px;line-height:1.5}.body-label{paint-order:stroke;stroke:#f6fcf2;stroke-width:3px;stroke-linejoin:round}
#flick-screen[data-phase="lost"] #flick-stars{font-size:16px;line-height:1.6;color:#a86154}
.campaign-score{display:flex;align-items:center;flex-direction:column;gap:5px;margin:14px 0;color:#547a76}.campaign-score strong{font-size:28px}.campaign-score small{font-size:9px;letter-spacing:1px}.node-best{font-size:9px;color:#547a76}#flick-outcome-detail{white-space:pre-line;line-height:1.7}#flick-record{font-weight:800;color:#af8335}.flick-field #flick-outcome:not([hidden]){inset:3% 8px auto;padding:14px;max-height:94%;overflow:auto}

#level-map .map-row{height:116px}.node-best{position:relative;background:#edf7f1;padding:2px 4px;z-index:1;border-radius:4px}
#level-map .map-row{height:116px;min-height:0;width:110px;margin:0 auto;transform:translateX(var(--offset))}
#stage-map{height:min(60svh,530px);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#b3d8d2 transparent;padding:18px 0 30px;position:relative;background:radial-gradient(ellipse at 50% 50%,#bfe9e345,transparent 65%);border-radius:22px}
#stage-map .stage-world-heading{font-size:15px;color:#315e62;margin:18px 4px 6px}#stage-map .stage-world-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px;margin-bottom:11px}#stage-map .stage-node{aspect-ratio:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;border:1px solid #c4ded3;border-radius:11px;background:#f8fcf5;color:#426f69;font-size:10px;font-weight:850;padding:3px}#stage-map .stage-node.recommended{border:2px solid #ed9a78;background:#fff3e5}#stage-map .stage-node:disabled{background:#e6edeb;border-color:#e1e9e5;color:#a1b0aa}#stage-map .stage-node-stars{display:block;min-height:14px;text-align:center;font-size:8px;color:#b28634}#stage-map .stage-node small{display:block;color:#8a9d9b;font-size:7px;font-weight:600}#map-campaign-toggle{width:100%;font-size:10px;margin-bottom:8px}

#flick-objective{white-space:pre-line}

#playtest-report-dialog{width:min(90vw,420px);max-height:85vh;overflow:auto}#playtest-report-description{display:block;width:100%;box-sizing:border-box;font:inherit;margin:12px 0}#playtest-report-dialog button{margin:6px 0}
