/* A full-screen game shell: scenes, HUD, map and tactile controls. */
html,body,#app{min-height:100%;overflow-x:hidden}
body{background:#342267}
.layout{max-width:none;min-height:100dvh;align-items:center;justify-content:center;padding:0;background:radial-gradient(circle at 50% 15%,#8061db 0,#3d297a 45%,#241d4f 100%)}
.layout:before,.layout:after{content:"✦";position:fixed;color:#ffffff30;font-size:9rem;top:7%;left:12%;transform:rotate(-20deg);pointer-events:none}.layout:after{content:"♫";top:auto;bottom:4%;left:auto;right:12%;font-size:12rem;transform:rotate(14deg)}
.desktop-side{display:none!important}.phone{width:100%;max-width:480px;height:100dvh;min-height:0;position:relative;overflow:hidden;background:#f8f3e9;border:0;border-radius:0;box-shadow:0 24px 85px #0d0b2e99}
.screen{height:100%;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:18px 18px 98px;scrollbar-width:none}.screen::-webkit-scrollbar{display:none}
.bottom-nav{position:absolute;left:0;bottom:0;transform:none;max-width:none;width:100%;height:73px;padding:8px 10px calc(9px + env(safe-area-inset-bottom));border:0;border-radius:25px 25px 0 0;background:#fffdfbf4;box-shadow:0 -9px 25px #321f5933;z-index:22}
.nav-btn{min-width:64px;gap:2px;min-height:50px;font-weight:900}.nav-btn svg{width:23px;height:23px;stroke-width:2}.nav-btn.active:before{top:-8px;width:29px;height:4px;border-radius:8px;background:#7543e8}.nav-btn.active{color:#7543e8}.nav-btn:hover{color:#7543e8}
.game-hud{height:48px;display:flex;align-items:center;justify-content:space-between;position:relative;z-index:3;margin:0 2px 11px}.game-logo{font-size:1.35rem;font-weight:900;letter-spacing:-.07em;color:#29232e;display:flex;align-items:center;gap:5px}.game-logo .brandmark{transform:scale(.75)}.hud-avatar{width:41px;height:41px;border-radius:15px;background:linear-gradient(145deg,#ffb56c,#fb704d);box-shadow:0 4px 0 #c65f3d;border:2px solid white;color:#fff;font-weight:900;font-size:1.2rem}.sound-toggle{width:41px;height:41px;border-radius:15px;padding:0;display:grid;place-items:center;font-size:1.4rem;background:#fff;box-shadow:0 4px 0 #e4d5c5}.sound-toggle span{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.home-scene{position:relative;height:clamp(470px,calc(100dvh - 218px),610px);border-radius:34px;overflow:hidden;background:radial-gradient(circle at 10% 23%,#b97aff 0,transparent 34%),radial-gradient(circle at 100% 53%,#24d1ec 0,transparent 48%),linear-gradient(158deg,#6d42de 0,#6535d4 52%,#2a9ddb 100%);box-shadow:inset 0 3px 0 #ffffff52,0 16px 28px #60439d5c}
.home-scene:before{content:"";position:absolute;inset:16px;border:1px solid #ffffff40;border-radius:26px;pointer-events:none}.home-scene:after{content:"";position:absolute;width:260px;height:260px;border:32px solid #ffffff13;left:-95px;top:45px;border-radius:50%;pointer-events:none}
.scene-stars{position:absolute;inset:0;pointer-events:none}.scene-stars i{font-style:normal;position:absolute;color:#ffdf68;text-shadow:0 8px 12px #472ba65e;animation:float-tag 4s ease-in-out infinite}.scene-stars i:nth-child(1){top:98px;left:20px;font-size:2rem}.scene-stars i:nth-child(2){top:26px;left:43%;font-size:2.5rem;animation-delay:-1.3s}.scene-stars i:nth-child(3){top:115px;right:27px;font-size:2.7rem;font-weight:900;color:#ffb05b;animation-delay:-2s}.scene-stars i:nth-child(4){top:235px;left:26px;font-size:1.2rem;color:white;animation-delay:-2.6s}
.scene-heading{position:absolute;top:23px;right:25px;z-index:2;color:#fff;max-width:70%;text-shadow:0 3px 7px #41218188}.daily-label{display:inline-block;padding:5px 10px;border-radius:11px;background:#ffdc5a;color:#52319c;box-shadow:0 4px 0 #d7a43f;font-weight:900;font-size:.72rem;letter-spacing:.02em;text-shadow:none}.scene-heading h1{font-size:clamp(1.9rem,8vw,2.75rem);line-height:1.03;letter-spacing:-.07em;margin:14px 0 6px;color:#fff;transform:rotate(-2deg)}.scene-heading h1 em{font-style:normal;color:#ffe563}.scene-heading p{font-size:.74rem;font-weight:800;margin:0;color:#f7eaff}
.scene-mascot{position:absolute;left:-12px;top:63px;width:59%;height:52%;object-fit:contain;object-position:center top;filter:drop-shadow(0 16px 10px #34208088);animation:mascot-bob 4s ease-in-out infinite;z-index:1}.scene-vinyl{position:absolute;left:11px;top:31%;width:57px;height:57px;border-radius:50%;background:repeating-radial-gradient(circle,#222031 0 3px,#373244 4px 6px);box-shadow:0 9px 12px #2b187c66;display:grid;place-items:center;color:#ffbf4c;transform:rotate(-20deg);animation:spin-soft 14s linear infinite}
.mission-panel{position:absolute;z-index:3;bottom:12px;left:12px;right:12px;background:#fffaf6;border:3px solid #fff;box-shadow:0 9px 0 #34248848,0 16px 25px #25166766;border-radius:26px;padding:14px 14px 16px;color:#28242c}.mission-top{display:flex;justify-content:space-between;align-items:center;font-weight:900;font-size:.84rem;color:#5936c5;margin-bottom:9px}.mission-difficulty{background:#e8dafa;padding:4px 8px;border-radius:100px;font-size:.7rem;color:#6e46c4}.mission-route{display:flex;align-items:center;gap:5px;direction:rtl}.mission-point{flex:1;min-width:0;min-height:70px;border-radius:16px;background:#e9f9ff;display:flex;align-items:center;gap:7px;padding:7px;border:1px solid #8bddec}.mission-point.goal{background:#fff0dc;border-color:#ffc676}.point-icon{flex:none;width:35px;height:35px;display:grid;place-items:center;border-radius:11px;background:#4cbbdf;color:#fff;font-size:1.15rem;font-weight:900;box-shadow:0 3px 0 #198ba8}.point-icon.tv{background:#ff9857;box-shadow:0 3px 0 #c56c36}.mission-point small{display:block;font-size:.59rem;color:#777277;white-space:nowrap}.mission-point strong{display:block;font-size:.88rem;color:#28242c;white-space:nowrap}.route-mystery{width:31px;display:grid;justify-items:center;gap:2px;color:#7446dd;flex:none}.route-mystery i{height:6px;border-left:2px dashed #8a6dea}.route-mystery b{width:27px;height:27px;display:grid;place-items:center;background:#7b4ce6;color:white;border-radius:50%;font-size:1.15rem;box-shadow:0 4px 0 #4b2da7;animation:mystery-pulse 2s ease-in-out infinite}.mission-start{width:100%;min-height:53px;margin-top:12px;border:0;border-radius:16px;background:linear-gradient(180deg,#ffad5b,#ff783d);box-shadow:0 5px 0 #c85530;color:#fff;font-weight:900;font-size:1.13rem;display:flex;align-items:center;justify-content:center;gap:13px;transition:transform .15s,box-shadow .15s}.mission-start span{font-size:1.5rem;line-height:0}.mission-start:active{transform:translateY(4px);box-shadow:0 1px 0 #c85530}
.home-shortcuts{display:flex;justify-content:space-between;gap:8px;margin:16px 2px 0}.home-shortcuts button{flex:1;min-height:62px;border:0;border-radius:18px;background:#fff;box-shadow:0 5px 0 #ded0ba;color:#594191;display:flex;align-items:center;justify-content:center;gap:5px;flex-direction:column;transition:transform .15s}.home-shortcuts button:active{transform:translateY(4px)}.home-shortcuts span{font-size:1.25rem;line-height:1}.home-shortcuts b{font-size:.7rem}
#play{background:radial-gradient(circle at 100% 25%,#e2d1ff,transparent 38%),radial-gradient(circle at 0 78%,#d5f5ff,transparent 40%),#f8f3e9}.toprow{margin:0 0 16px}.toprow .subtitle{font-size:.87rem;color:#5b3bc0;font-weight:900}.toprow .pill{font-size:.74rem;background:#fff;box-shadow:0 4px 0 #ded0bf}.progress-track{height:10px;border:2px solid #fff;box-shadow:0 3px 0 #d8c7b7;margin-bottom:15px;background:#e7dbee}.progress-track span{background:linear-gradient(90deg,#ffca5b,#ff8551);border-radius:10px;transition:width .35s cubic-bezier(.2,1.3,.4,1)}
.play-header .eyebrow{font-size:.7rem;color:#8b65d5}.play-header h1{font-size:1.75rem;line-height:1.1;margin:4px 0 4px}.play-header p{font-size:.8rem;margin-bottom:13px}.target-card{display:flex;gap:11px;align-items:center;background:linear-gradient(105deg,#7e56e7,#5832c8);border-radius:19px;padding:12px;color:#fff;box-shadow:0 7px 0 #42259a,0 13px 20px #5b3b9947;margin:0 2px 22px;position:relative;overflow:hidden}.target-card:after{content:"◎";position:absolute;left:45px;top:-40px;font-size:9rem;color:#ffffff12}.target-symbol{width:48px;height:48px;border-radius:14px;background:#ffbd56;display:grid;place-items:center;color:#5b379e;font-size:2rem;font-weight:900;box-shadow:0 4px 0 #dd8c39}.target-card small{display:block;color:#e6d7ff;font-size:.68rem}.target-card strong{font-size:1.15rem}.target-lock{margin-right:auto;font-size:1.2rem;color:#ffdd74}.board-label{display:flex;align-items:center;justify-content:space-between;font-weight:900;color:#5c4a83;font-size:.9rem;margin:0 4px 9px}.board-label span{font-size:.63rem;color:#9c8fa4;font-weight:600}
.path{border:2px solid #ffffff;background:#ffffffad;border-radius:25px;padding:13px 12px 16px;box-shadow:0 12px 25px #68539226;min-height:165px}.path-node{min-height:64px;border-radius:16px;box-shadow:0 4px 0 #d9cdd6}.path-node.start{background:#dbf7ff;border-color:#8bd5e6}.path-node:not(.start){background:#f4eaff;border-color:#d6bff6}.path-node .node-symbol{width:43px;height:43px}.path-relation{height:39px;color:#7f61b0;border-right:3px dotted #a783e8;font-weight:800}.path-relation:before{background:#8d67df;box-shadow:0 0 0 4px #c5b0eb}.path-empty{height:59px;width:100%;background:#fff2dc;border:2px dashed #ffad67;color:#a65e2f;margin-top:13px;font-size:.9rem;animation:empty-glow 2.4s ease-in-out infinite}.path-empty:hover{background:#ffe6bf}
.play-actions{background:linear-gradient(transparent,#f8f3e9 26%);bottom:20px;margin-top:12px;position:sticky;padding-top:20px}.add-btn{font-size:1rem;min-height:53px}.hint-btn{min-height:53px;border:2px solid #ffbf68;background:#fff6e8;color:#a65b27;box-shadow:0 4px 0 #e0b17b}.undo-btn{padding:12px 0 3px}.play-meta{font-size:.7rem;margin-top:4px}
.phone:has(#play:not([hidden])) .bottom-nav,.phone:has(#result:not([hidden])) .bottom-nav{display:none}#play,#result{padding-bottom:26px}
#result{background:radial-gradient(circle at 50% 10%,#f5d8ff,transparent 52%),#f8f3e9}.result-hero{background:linear-gradient(180deg,#ffe6b4 0 43%,#fffdfa 43%);border:3px solid white;box-shadow:0 8px 0 #e9d7bc,0 18px 24px #8e7c6540}.winner-mascot{height:270px}.result-hero h1{font-size:2.25rem}.score{font-size:3.5rem}.summary-card{margin:19px 0 14px}.result-actions{position:sticky;bottom:8px;z-index:3;background:#f8f3e9ed;padding:8px 0 11px;border-radius:18px}.result-actions .main-wide{background:linear-gradient(#ffab59,#ff7d43)}
#levels{background:radial-gradient(circle at 50% 0,#dcd0ff,transparent 40%),#f8f3e9}.map-heading{text-align:center;position:relative;z-index:1;margin:0 0 15px}.map-heading span{font-size:.7rem;color:#7b55c3;font-weight:900}.map-heading h1{font-size:2rem;line-height:1.05;letter-spacing:-.07em;margin:6px 0;color:#35265b}.map-heading p{margin:4px 0;font-size:.75rem;color:#857a8b;font-weight:800}.level-map{position:relative;background:radial-gradient(circle at 80% 20%,#e8cbff,transparent 31%),radial-gradient(circle at 14% 70%,#c0efff,transparent 33%),linear-gradient(#f6eafa,#e7f8fa);border-radius:32px;padding:22px 15px 26px;min-height:545px;overflow:hidden;box-shadow:inset 0 0 0 2px white,0 10px 20px #74649627;display:flex;flex-direction:column;gap:19px}.level-map:before,.level-map:after{content:"✦";position:absolute;color:#b89fea;font-size:5rem;left:-13px;top:15px}.level-map:after{content:"♫";left:auto;right:-15px;top:auto;bottom:20px;color:#96dbed}.map-trail{position:absolute;top:50px;bottom:42px;left:50%;border-left:5px dotted #b698e8;opacity:.8}.map-stage{width:90%;z-index:1;border:3px solid white;border-radius:55px;background:linear-gradient(105deg,#fff,#fcf7ff);min-height:101px;display:flex;align-items:center;gap:11px;text-align:right;padding:11px;box-shadow:0 7px 0 #b9a7d8,0 13px 16px #654aa72e;position:relative;transition:transform .18s,box-shadow .18s;color:#34264e}.map-stage:active{transform:translateY(5px)!important;box-shadow:0 2px 0 #b9a7d8}.stage-one{align-self:flex-start;transform:rotate(2deg)}.stage-two{align-self:flex-end;transform:rotate(-2deg)}.stage-three{align-self:flex-start;transform:rotate(1.5deg)}.map-orb{width:65px;height:65px;flex:none;border-radius:50%;display:grid;place-items:center;background:linear-gradient(#ffbd62,#ff784d);color:#fff;font-size:2rem;font-weight:900;border:3px solid #fff;box-shadow:0 5px 0 #cc7546}.stage-two .map-orb{background:linear-gradient(#6fdcf1,#3b9de3);box-shadow:0 5px 0 #358cba}.stage-three .map-orb{background:linear-gradient(#bd85f5,#7945db);box-shadow:0 5px 0 #5e33a7}.map-copy{min-width:0}.map-copy small{display:block;color:#a07cbd;font-size:.63rem;font-weight:900}.map-copy b{display:block;line-height:1.1;font-size:.97rem}.map-copy em{font-style:normal;color:#8b8294;font-size:.67rem;display:block;white-space:nowrap}.map-stars{position:absolute;left:16px;top:9px;color:#ffb638;font-size:.75rem;letter-spacing:1px}.map-coming{z-index:1;align-self:center;background:#ffffffa8;border:2px dashed #c8b8d5;border-radius:20px;padding:9px 22px;display:flex;align-items:center;gap:7px;color:#85718c;font-size:.75rem}.map-coming span{font-size:1rem}.map-coming small{color:#a69aaa}
#rank{background:radial-gradient(circle at 50% 0,#e5d5ff,transparent 45%),#f8f3e9}.rank-title{text-align:center;margin:-2px 0 12px}.rank-title span{font-size:.72rem;color:#8659cd;font-weight:900}.rank-title h1{font-size:2.3rem;color:#342354;margin:2px 0;line-height:1}.rank-head{min-height:72px;padding:12px 17px}.rank-head strong{font-size:1rem}.rank-head small{font-size:.68rem}.podium{margin-top:13px}.rank-row{min-height:58px}
@keyframes mystery-pulse{0%,100%{transform:scale(1)}50%{transform:scale(1.14)}}@keyframes empty-glow{0%,100%{box-shadow:0 0 0 0 #ffad6766}50%{box-shadow:0 0 0 5px #ffad671b}}
@media(min-width:820px){.layout{padding:18px}.phone{height:min(900px,96dvh);border:7px solid #fffaf7;border-radius:38px;min-height:650px}.screen{height:100%;min-height:0}.bottom-nav{left:0;transform:none}.overlay{position:absolute;border-radius:31px}.play-actions{bottom:18px}.home-scene{height:clamp(470px,calc(96dvh - 230px),610px)}}
@media(max-width:819px){.layout{background:#f8f3e9}.layout:before,.layout:after{display:none}.phone{max-width:none}.home-scene{height:clamp(420px,calc(100dvh - 260px),610px)}}
@media(max-width:380px){.scene-heading h1{font-size:1.85rem}.mission-panel{padding:11px}.mission-point{padding:5px}.mission-point strong{font-size:.8rem}.home-shortcuts b{font-size:.64rem}}
@media(prefers-reduced-motion:reduce){.scene-mascot,.scene-stars i,.route-mystery b,.path-empty{animation:none!important}}
#play:not([hidden]){display:flex;flex-direction:column}
#play .path{flex:1 0 auto;min-height:220px;position:relative;background:radial-gradient(circle at 14% 83%,#e3d5f888,transparent 30%),radial-gradient(circle at 89% 69%,#ccefff77,transparent 33%),#ffffffad}
#play .path:after{content:"✦";position:absolute;left:22px;bottom:0;color:#956ce422;font-size:6rem;pointer-events:none}
#play .path-node,#play .path-empty{position:relative;z-index:1}
#play .play-actions{margin-top:12px;flex:none}
#play .play-meta{flex:none}
.map-stars{color:#c7b9cb}.map-stage.completed .map-stars{color:#ffb638}
.sheet{box-shadow:0 -20px 0 #4c2ba255,0 -25px 60px #1d154c88}.filter-row{margin-bottom:13px}.filter-chip{box-shadow:0 3px 0 #e2d5e5}.filter-chip.active{box-shadow:0 3px 0 #5532a9}.search-result{box-shadow:0 4px 0 #e8dbe7;border-radius:17px;min-height:62px;margin-bottom:3px}.search-result:active{transform:translateY(3px);box-shadow:0 1px 0 #e8dbe7}
