/* Unified game surface: mint glass, deep ink and tactile coloured rewards. */
html,body{background:#dce9e3;color:#19484b}.app-shell{max-width:540px;padding: max(12px,env(safe-area-inset-top)) 16px max(12px,env(safe-area-inset-bottom));background:radial-gradient(ellipse at 50% 42%,#ffffff 0,#f1f7f1 48%,#e3eee8 100%);border:0;box-shadow:0 0 90px #163e3d14}.app-header{height:40px;margin-bottom:12px}.app-header img{width:116px;opacity:.9}.app-header .settings{width:40px;height:40px;border:1px solid #fff;border-radius:14px;background:#ffffffa8;box-shadow:0 3px 0 #c6d9ce,0 5px 10px #19484b09}.app-header .settings:active{transform:translateY(2px);box-shadow:0 1px 0 #c6d9ce}.hud{position:relative;display:block;width:100%;height:auto;min-height:0;margin:0;padding:16px 18px 14px;background:linear-gradient(135deg,#fffefa,#f7fbf6);color:#19484b;border:1px solid #fff;border-radius:23px;box-shadow:0 4px 0 #cadcd1,0 10px 24px #19484b0b}.hud-main{display:flex;justify-content:space-between;align-items:center;gap:12px}.level-block{display:grid;grid-template-columns:auto auto;gap:2px 7px;align-items:center;justify-items:start}.case-eyebrow{grid-column:1/-1;font-size:9px;font-weight:700;letter-spacing:1.25px;color:#729386}.hud .level-block #levelNo{font-size:25px;letter-spacing:-.6px;line-height:1.2}.hud #difficulty{background:#e3eee6;color:#4a7868;font-size:10px;padding:3px 7px;border-radius:7px}.hud #difficulty[data-grade="Schwer"]{background:#ffe5b6;color:#9a6524}.hud #difficulty[data-grade="Sehr schwer"]{background:#ffe1dd;color:#b2404c}.life-row{gap:6px;align-items:flex-end}.life-label{font-size:11px;color:#658678;letter-spacing:0}.life-label b{font-size:12px;color:#19484b}.hearts{gap:3px}.hearts span{width:17px;height:17px}.hearts img{filter:none;opacity:1}.hearts .lost{opacity:.17}.progress-capsule{position:relative;inset:auto;display:flex;align-items:center;justify-content:space-between;min-width:0;margin-top:12px;padding:0 0 12px;gap:0;color:#618270}.counter-label{position:static;font-size:11px;letter-spacing:0;font-weight:600;color:#618270}.progress-capsule #count{font-size:12px;font-weight:700;color:#19484b}.progress{height:5px;bottom:0;background:#e2ece4;border-radius:6px;box-shadow:inset 0 1px 2px #19484b0d}.progress #bar{background:linear-gradient(90deg,#499a80,#91c9a5);border-radius:6px;min-width:0;box-shadow:0 0 8px #499a8020}.rank-trail{position:relative;inset:auto;width:100%;display:block;overflow:visible;margin:13px 0 0;padding:0;min-height:56px}.rank-summary{width:100%;display:flex;align-items:center;gap:10px;min-height:56px;text-align:left;border:0;background:none;padding:0 5px;color:#19484b}.rank-emblem{flex-shrink:0;display:block;width:44px;height:52px;filter:drop-shadow(0 3px 2px #19484b21)}.rank-emblem svg{display:block;width:100%;height:100%}.rank-copy{display:flex;flex-direction:column;gap:0}.rank-copy small{font-size:8px;font-weight:700;letter-spacing:1.1px;color:#7d9689}.rank-copy b{font-size:16px;font-weight:700}.rank-next{margin-left:auto;font-size:10px;max-width:145px;line-height:1.4;color:#688779}.rank-next b{color:#19484b}.rank-meter{display:block;margin-top:5px;height:3px;background:#d4e3d8;border-radius:4px;overflow:hidden}.rank-meter i{display:block;height:100%;background:#6caa91;border-radius:4px}.rank-chevron{font-size:23px;color:#8aa799}.stage{background:radial-gradient(ellipse at 50% 52%,#ffffff85,transparent 65%);overflow:hidden}.drag-note{font-size:10px;font-weight:500;letter-spacing:.15px;color:#6f9282;bottom:10px}.controls{position:relative;inset:auto;width:auto;display:flex;flex-direction:row;justify-content:space-around;padding:14px 0 3px;gap:3px;background:none;border:0;box-shadow:none;border-radius:0}.controls button{flex:1;min-width:0;min-height:106px;gap:7px;font-size:12px;letter-spacing:-.1px;color:#315f54}.controls .tool-icon{width:64px;height:60px;border-radius:19px;border:1px solid #ffffffd9;color:#fff7de;box-shadow:inset 0 2px 1px #ffffff66,inset 0 -3px 0 #00000012,0 4px 0 #a27934,0 9px 16px #19484b15;background:linear-gradient(145deg,#f5d08a,#d69c43)}.controls .tool-icon svg{width:32px;height:32px;stroke-width:2.2;filter:drop-shadow(0 2px 0 #0000001a)}.controls .eraser-icon{background:linear-gradient(145deg,#93c5bf,#508f88);box-shadow:inset 0 2px 1px #ffffff66,inset 0 -3px 0 #00000012,0 4px 0 #356b68,0 9px 16px #19484b15}.controls .wand-icon{background:linear-gradient(145deg,#bcace3,#8570b9);box-shadow:inset 0 2px 1px #ffffff66,inset 0 -3px 0 #00000012,0 4px 0 #61538c,0 9px 16px #19484b15}.controls button:active .tool-icon{transform:translateY(3px);box-shadow:inset 0 2px 4px #0000001a,0 1px 0 #356b68}.stock{top:-7px;right:calc(50% - 40px);min-width:25px;height:25px;border-radius:50%;color:#fff;font-size:12px;font-weight:700;background:#19484b;border:2px solid #f2f7ef;box-shadow:0 2px 3px #19484b20}.tool-next{font-size:9px;margin-top:-4px;color:#779085}.controls button[data-empty="true"] .tool-icon{opacity:.55}.badge-gallery{grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.badge-card{border:0;border-radius:18px;padding:14px 3px 12px;background:#e7f0e9;gap:7px}.badge-card>span,.badge-card.locked span{display:block;width:58px;height:66px;background:none;clip-path:none;border-radius:0;filter:drop-shadow(0 4px 3px #19484b20)}.badge-card span svg{width:100%;height:100%}.badge-card.earned{background:linear-gradient(145deg,#fafff7,#e6f0df);box-shadow:inset 0 0 0 1px #fff,0 3px 0 #c9dbcc}.badge-card.locked{opacity:.4;filter:grayscale(.7)}.badge-card b{font-size:12px}.badge-card small{font-size:10px}.rank-medal{width:80px;height:91px;background:none;box-shadow:none;border-radius:0;filter:drop-shadow(0 6px 4px #19484b25)}.rank-medal svg{width:100%;height:100%}.rank-celebration{background:linear-gradient(145deg,#f9f5df,#e5f0e1);border:1px solid #fff;box-shadow:0 4px 0 #c6d6c0;padding:15px}.fact-core{gap:9px;filter:drop-shadow(0 6px 14px #19484b12)}.fact-core img{width:75px;height:70px}.fact-core b{font-size:24px;letter-spacing:.6px;white-space:nowrap;color:#19484b}.fact-core span{font-size:10px;letter-spacing:2px;color:#628875}dialog{background:linear-gradient(145deg,#fffef8,#edf5ec);border:1px solid #fff;box-shadow:0 8px 0 #b7cfc1,0 24px 90px #163e3d33;border-radius:27px}dialog::backdrop{background:#173e4070;backdrop-filter:blur(9px)}.primary{background:linear-gradient(#347969,#215951);border:1px solid #3a7b6e;box-shadow:inset 0 1px 0 #ffffff44,0 4px 0 #123f3e;color:#fffdf4;border-radius:16px;font-size:16px;font-weight:700;min-height:50px}.primary:active{transform:translateY(2px);box-shadow:0 2px 0 #123f3e}.win-stars{color:#d6a64a;text-shadow:0 2px 0 #fff3c9;font-size:32px!important}#winDialog h2{font-size:32px;margin-top:14px}#winDialog .win-icon{width:64px;height:64px;background:linear-gradient(#4d9b80,#226653);border:2px solid #c8e6be;box-shadow:0 4px 0 #174d44,0 0 0 7px #e3efdc;border-radius:22px;margin:8px auto 20px}#winDialog .win-icon img{width:43px;height:41px}body[data-training="true"] .hud{display:block}body[data-training="true"] .hud-main{justify-content:space-between}body[data-training="true"] .rank-trail{display:none}body[data-training="true"] .mission{top:15px}body[data-training="true"] .mission span:last-child{color:#315f54}.training-dock{padding-bottom:12px}
@media(max-width:360px){.app-shell{padding-inline:11px}.hud{padding:13px 14px 12px}.hud .level-block #levelNo{font-size:22px}.hud #difficulty{font-size:9px}.hearts span{width:15px;height:15px}.rank-copy b{font-size:15px}.rank-next{max-width:130px;font-size:9px}.controls button{font-size:11px}.tool-next{font-size:8px}.controls .tool-icon{width:59px;height:55px}}
@media(max-height:680px){.app-header{margin-bottom:7px;height:34px}.hud{padding-block:11px}.hud .level-block #levelNo{font-size:22px}.rank-trail{margin-top:8px;min-height:47px}.rank-summary{min-height:47px}.rank-emblem{width:37px;height:45px}.controls{padding-top:8px}.controls button{min-height:93px}.controls .tool-icon{height:50px;width:56px;border-radius:16px}.drag-note{bottom:4px;font-size:9px}.fact-core b{font-size:21px}}
@media(orientation:landscape) and (max-height:500px){.app-shell{max-width:900px;padding:7px 14px}.app-header{height:32px;margin:0 0 7px}.hud{position:relative;inset:auto;width:100%;padding:9px 14px}.hud-main{gap:20px}.level-block{display:flex;gap:9px}.case-eyebrow{display:none}.hud .level-block #levelNo{font-size:20px}.life-row{flex-direction:row;gap:8px;align-items:center}.hud .hearts span{width:15px;height:15px}.progress-capsule{margin-top:5px;padding-bottom:7px}.rank-trail{position:absolute;top:-40px;left:150px;right:50px;width:auto;margin:0;min-height:34px}.rank-summary{min-height:34px;gap:7px}.rank-emblem{width:28px;height:34px}.rank-copy small{display:none}.rank-copy b{font-size:12px}.rank-next{font-size:9px;max-width:150px}.game{padding-right:0}.stage{margin-right:98px}.controls{position:absolute;right:0;top:77px;bottom:0;width:90px;flex-direction:column;justify-content:space-evenly;padding:4px 0;gap:4px}.controls button{flex:0;min-height:66px;font-size:10px;gap:4px}.controls .tool-icon{width:46px;height:39px;border-radius:12px}.controls .tool-icon svg{width:24px;height:24px}.stock{right:calc(50% - 31px);height:21px;min-width:21px;font-size:10px}.tool-next{font-size:8px}.fact-core b{font-size:20px}body[data-training="true"] .stage{margin-right:0}body[data-training="true"] .training-dock{top:77px;right:0}.badge-gallery{grid-template-columns:repeat(3,1fr)}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}}
@media(max-width:400px){.case-eyebrow{display:none}.level-block{grid-template-columns:1fr;gap:3px}.hud .level-block #levelNo{font-size:23px}.hud #difficulty{grid-column:1;grid-row:2;font-size:9px}.hud-main{gap:8px}.hud .life-label{font-size:10px}.hud .hearts span{width:15px;height:15px}}
@media(orientation:landscape) and (max-height:500px){.level-block{flex-direction:row}.hud .level-block #difficulty{align-self:center}.controls{top:77px}.fact-core span{white-space:nowrap}}
.fact-core span{white-space:nowrap}
/* Short landscape phones keep all three tools inside the safe viewport. */
@media(orientation:landscape) and (max-height:350px){.controls{padding-block:0;gap:3px}.controls button{min-height:56px;font-size:9px;gap:3px}.controls .tool-icon{height:33px;width:43px;border-radius:11px}.controls .tool-icon svg{width:21px;height:21px}.tool-next{font-size:7px}.stock{top:-4px}}
.app-header .settings{min-width:44px;min-height:44px}
.preview-entry{font-size:12px;font-weight:700;margin-left:auto;padding:10px 12px;border-radius:12px;color:#315f54;background:#ffffff95;border:1px solid #fff;min-height:44px;display:flex;align-items:center}.app-header .preview-entry+.settings{margin-left:0}.preview-panel[hidden]{display:none}.preview-link{display:block;padding:12px;text-align:center;margin-bottom:14px}.preview-panel{padding:10px 0 0;flex-shrink:0}.preview-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.preview-exit{font-size:11px;color:#315f54;padding:7px}.preview-panel label{display:block;font-size:11px;color:#668777;margin-bottom:4px}.preview-navigation{display:flex;gap:7px}.preview-navigation button{height:44px;min-width:44px;border-radius:13px;border:1px solid #fff;background:#e0eee5;font-size:25px;font-weight:700;box-shadow:0 2px 0 #bbd4c6}.preview-navigation select{min-width:0;flex:1;border:1px solid #d0e0d4;border-radius:13px;background:#fffdf8;padding:8px;color:#19484b;font:600 14px SourceSans,sans-serif}.preview-panel p{margin:7px 0;font-size:11px;line-height:1.3;color:#56796b}.preview-jumps{display:flex;gap:5px;margin-top:9px}.preview-jumps button{flex:1;min-height:36px;border:1px solid #cddfd2;border-radius:10px;font-size:12px;background:#f6fcf5;color:#315f54}.preview-panel .preview-note{font-size:10px;color:#729082;margin:9px 0 0}body[data-preview="true"] .hud,body[data-preview="true"] .rank-trail,body[data-preview="true"] .controls,body[data-preview="true"] .app-header,body[data-preview="true"] .mission,body[data-preview="true"] .training-dock{display:none!important}body[data-preview="true"] .game{padding:0}body[data-preview="true"] .stage{margin:0}body[data-preview="true"] .app-shell{max-width:700px}body[data-preview="true"] .drag-note{bottom:3px}body[data-preview="true"] .stage::before{content:'VORSCHAU';position:absolute;top:10px;left:50%;transform:translateX(-50%);font-size:10px;letter-spacing:2px;font-weight:700;color:#729082;z-index:2}
@media(orientation:landscape) and (max-height:500px){body[data-preview="true"] .app-shell{flex-direction:row;gap:14px;max-width:100%}body[data-preview="true"] main{flex:1}body[data-preview="true"] .preview-panel{width:255px;display:flex;flex-direction:column;justify-content:center;padding:0}body[data-preview="true"] .preview-jumps{flex-wrap:wrap}body[data-preview="true"] .preview-jumps button{flex:1 0 25px;min-height:32px}.preview-heading .eyebrow{font-size:8px}.preview-exit{font-size:10px}}
.case-brief{display:flex;flex-direction:column;align-items:center;gap:2px;flex-shrink:0;padding:5px 8px 3px;text-align:center}.case-brief[hidden]{display:none}.case-brief strong{font-size:15px;line-height:1.15;color:#315f54;font-weight:700}.case-brief span{font-size:11px;line-height:1.3;color:#6d8b7d}.preview-panel .preview-note{max-width:100%}body[data-preview="true"] .case-brief{padding:7px 8px}.preview-jumps button{min-height:40px}
@media(max-height:680px){.case-brief strong{font-size:13px}.case-brief span{font-size:10px}.case-brief{padding-block:3px}}
@media(orientation:landscape) and (max-height:500px){.case-brief{position:absolute;top:77px;left:0;right:98px;z-index:2;padding:4px}.case-brief strong{font-size:12px}.case-brief span{font-size:9px}body[data-preview="true"] .case-brief{top:3px;right:0;padding:3px;max-width:65%}body[data-preview="true"] .stage::before{display:none}}
.adventure-entry{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:12px 14px;font-size:15px}.adventure-entry span{font-size:11px;color:#739081}.daily-goal{margin-top:16px;padding:14px;border-radius:17px;background:#f5eedb;border:1px solid #e5d9b7}.daily-goal>div:first-child{display:flex;flex-direction:column;gap:3px}.daily-goal b{font-size:14px;color:#315f54}.daily-goal span{font-size:12px;color:#8a723a}.daily-goal small{display:block;font-size:11px;line-height:1.4;color:#7f8265;margin-top:8px}.goal-meter{height:5px;background:#e5ddc4;border-radius:5px;margin-top:10px;overflow:hidden}.goal-meter i{display:block;height:100%;background:#c4a35c;border-radius:5px;transition:width .25s}.daily-goal[data-complete="true"]{background:#e6f0e4;border-color:#bcd5bf}.daily-goal[data-complete="true"] .goal-meter i{background:#4a957c}.win-adventure{background:#e8f1e7;border-radius:15px;padding:12px;margin:12px 0;text-align:left;display:flex;flex-direction:column;gap:4px}.win-adventure strong{font-size:14px;color:#315f54}.win-adventure span{font-size:12px;color:#64816d}.win-adventure small{font-size:11px;line-height:1.4;color:#758c6b}.win-adventure[hidden]{display:none}.journey-intro{font-size:13px}.chapter-map{display:flex;flex-direction:column;gap:12px;margin-top:20px}.chapter-card{display:grid;grid-template-columns:47px 1fr auto;gap:12px;align-items:center;border:1px solid #d2e1d3;background:#f5faf0;border-radius:18px;padding:15px 12px}.chapter-card small{font-size:9px;letter-spacing:.7px;color:#789383}.chapter-card h3{margin:3px 0;font-size:17px;line-height:1.15;color:#315f54}.chapter-card p{font-size:11px;margin:0;line-height:1.4;color:#7b8f7d}.chapter-card b{display:block;font-size:10px;color:#5d826d;margin-top:5px}.chapter-card a{font-size:11px;padding:12px 2px;min-height:44px;display:flex;align-items:center}.chapter-seal{width:43px;height:48px;display:grid;place-items:center;background:#dce9dc;color:#759381;clip-path:polygon(50% 0,94% 24%,94% 76%,50% 100%,6% 76%,6% 24%);font-size:22px;font-weight:700}.chapter-done{background:linear-gradient(135deg,#edf5e2,#f9f2d9);border-color:#cbd5a8}.chapter-done .chapter-seal{background:#39846f;color:#ffefb1}.chapter-current{border-color:#91b8a0;box-shadow:0 3px 0 #d1e2d2}.chapter-future .chapter-seal{opacity:.55}.chapter-dots{display:flex;gap:5px;margin-top:8px}.chapter-dots i{width:12px;height:5px;border-radius:3px;background:#dce6d7}.chapter-dots .earned{background:#54a080}
@media(max-width:360px){.chapter-card{grid-template-columns:35px 1fr auto;padding:12px 9px;gap:8px}.chapter-seal{width:33px;height:40px;font-size:18px}.chapter-card h3{font-size:15px}.chapter-card a{font-size:10px}.adventure-entry{font-size:13px}.adventure-entry span{font-size:10px}}
.win-adventure{position:relative}.win-adventure[data-chapter-done="true"]{background:linear-gradient(135deg,#f4f0d8,#e8f2df);border:1px solid #d7d9ad;padding-right:54px}.win-adventure[data-chapter-done="true"]::after{content:'✓';position:absolute;right:13px;top:15px;width:29px;height:29px;border-radius:50%;background:#39846f;color:#fff0b4;border:2px solid #dfd69d;box-shadow:0 2px 0 #23604f;text-align:center;line-height:25px;font-size:19px;font-weight:700}#winDialog #next{position:sticky;bottom:0;z-index:2}
