:root{font-family:'Nunito',sans-serif;color:#fff;background:#092b3c;font-synthesis:none;text-rendering:optimizeLegibility}*{box-sizing:border-box}html,body{margin:0;min-height:100%;overflow:hidden}body{background:radial-gradient(ellipse at 50% 25%,#164b5d 0,#092b3c 70%);display:grid;place-items:center;padding:clamp(10px,2vw,28px);user-select:none}.shell{width:min(1160px,100%);}.topbar{height:58px;display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}.brand{display:flex;align-items:center;gap:10px;color:#fff;text-decoration:none;font:800 13px/1 'Baloo 2',sans-serif;letter-spacing:1.5px}.brand b{color:#ffc94c}.brand-icon{width:40px;height:40px;border-radius:14px;background:#ffcc58;display:grid;place-items:center;overflow:hidden;box-shadow:0 4px 0 #d69031}.brand-icon img{width:38px;height:38px;object-fit:contain;image-rendering:pixelated}.top-actions{display:flex;gap:7px}.top-location{font:900 11px 'Nunito',sans-serif;letter-spacing:2px;color:#a6c3c6}.live-dot{display:inline-block;width:7px;height:7px;border-radius:50%;background:#83d999;margin-right:7px;box-shadow:0 0 10px #83d999}.sound-btn{font:900 11px 'Nunito';letter-spacing:1px;color:#d9eeee;background:#ffffff12;border:1px solid #ffffff2b;border-radius:999px;padding:9px 15px;cursor:pointer}.game-wrap{position:relative;width:100%;aspect-ratio:16/9;max-height:calc(100dvh - 120px);overflow:hidden;border-radius:20px;border:2px solid #b6d5ca;box-shadow:0 14px 40px #00162090,0 0 0 6px #ffffff0a;background:#60c1d0}#game-container{position:absolute;inset:0;overflow:hidden;image-rendering:pixelated}#game-container canvas{display:block;width:100%;height:100%;image-rendering:pixelated;image-rendering:crisp-edges}.hud-banana{width:29px;height:29px;object-fit:contain;image-rendering:pixelated}#assetError{position:absolute;z-index:8;left:8%;right:8%;bottom:12%;padding:14px 18px;border:2px solid #ff9a83;border-radius:12px;background:#401d2a;color:#fff;font-weight:900;text-align:center}.hud{position:absolute;z-index:2;left:0;right:0;top:0;padding:16px 20px;display:flex;align-items:flex-start;justify-content:space-between;pointer-events:none}.hud-pill{display:flex;align-items:center;gap:9px;background:#072e3bbd;border:1px solid #d3f5e18a;border-radius:12px;padding:7px 13px;min-width:98px;box-shadow:0 3px 8px #00303b30}.hud-icon{font-size:20px}.hud-pill small{display:block;font-size:8px;letter-spacing:1.6px;color:#b7d8d4;font-weight:900}.hud-pill strong{display:block;font-size:16px;color:#fff;font-weight:1000;line-height:1.1}.life-pill strong{font-size:13px;letter-spacing:2px;color:#ffb193}.level-pill{margin-top:4px;background:#fff2d8dd;color:#496557;font-size:10px;font-weight:1000;letter-spacing:1.5px;border-radius:99px;padding:8px 14px;box-shadow:0 3px 8px #00303b20}.level-pill span{color:#e49a3f}.level-pill i{font-style:normal;color:#d1a35d}.progress-track{position:absolute;z-index:2;left:0;right:0;bottom:0;height:5px;background:#113d47aa}.progress-track div{height:100%;width:0;background:#ffd45b;box-shadow:0 0 9px #ffd45b;transition:width .15s}.overlay{position:absolute;inset:0;z-index:4;background:linear-gradient(90deg,#092d3c8e 0%,#092d3c2c 45%,#092d3c20 100%);display:grid;align-items:center;padding:5% 8%;transition:opacity .35s,visibility .35s}.overlay.hidden{opacity:0;visibility:hidden;pointer-events:none}.title-card{position:relative;width:min(470px,55%);z-index:2}.eyebrow{color:#ffdb7f;font-size:10px;font-weight:1000;letter-spacing:2px;margin-bottom:10px}.eyebrow span{color:#fff0be;margin:0 5px}h1{font:800 clamp(32px,5.3vw,63px)/.92 'Baloo 2',sans-serif;letter-spacing:1px;margin:0 0 13px;color:#fff;text-shadow:0 3px 0 #31514c,0 5px 14px #002b35a0}h1 span{color:#ffd45b}.title-card p{font-size:clamp(12px,1.5vw,16px);font-weight:800;color:#e5f3e6;margin:0 0 14px}.hero-monkey{font-size:49px;line-height:1;margin:5px 0 14px;filter:drop-shadow(0 5px 3px #143b41);width:max-content;position:relative;animation:bob 2s ease-in-out infinite}.hero-monkey img{display:block;width:86px;height:86px;object-fit:contain;image-rendering:pixelated}.hero-monkey span{position:absolute;top:-8px;right:-15px;color:#ffe28b;font-size:21px}.play-btn{background:#ffd15b;border:0;border-radius:12px;padding:11px 23px;color:#543b22;font:1000 14px 'Nunito';letter-spacing:1px;box-shadow:0 5px 0 #c28736,0 7px 15px #00262c50;cursor:pointer;transition:transform .12s,filter .12s}.play-btn:hover{transform:translateY(-2px);filter:brightness(1.06)}.play-btn:active{transform:translateY(3px);box-shadow:0 2px 0 #c28736}.play-btn span{margin-left:10px}.start-hint{margin-top:14px;color:#deebe0;font-size:8px;font-weight:1000;letter-spacing:1px}.start-hint b{color:#ffd45b;margin:0 5px}.overlay-sticker{position:absolute;border-radius:50%;width:100px;height:100px;display:grid;place-content:center;text-align:center;transform:rotate(9deg);background:#fff1c8;color:#785528;box-shadow:0 5px 0 #c58b49;font-size:27px}.overlay-sticker small{font-size:8px;font-weight:1000;letter-spacing:.8px}.sticker-left{right:16%;top:23%;transform:rotate(-12deg)}.sticker-right{right:8%;bottom:19%;transform:rotate(12deg)}.mobile-controls{display:none;position:absolute;z-index:3;bottom:18px;left:18px;right:18px;justify-content:space-between;align-items:end;pointer-events:none}.move-controls{display:flex;gap:10px}.mobile-controls button{pointer-events:auto;width:58px;height:58px;border-radius:50%;border:2px solid #ffffffaa;background:#0733458c;color:white;font-size:21px;font-weight:1000;box-shadow:0 4px 10px #00232a40;touch-action:none}.mobile-controls button:active{background:#ffcd57;color:#30463f}.mobile-controls .jump-control{width:70px;height:70px;background:#ffd15bd9;color:#543b22;border-color:#fff3ce;font-size:28px;display:grid;place-content:center}.jump-control small{font-size:8px;letter-spacing:1px}.win-card{position:absolute;z-index:5;inset:0;margin:auto;width:min(370px,85%);height:max-content;text-align:center;background:#fff7df;color:#38584e;border:4px solid #ffd15b;border-radius:24px;padding:22px;box-shadow:0 16px 35px #00313d80}.win-card[hidden]{display:none}.win-emoji{font-size:48px}.win-card h2{font:800 36px/1 'Baloo 2';color:#df8f32;margin:8px}.win-card p{margin:7px;font-weight:800}.win-score{font-weight:1000;background:#fff0c4;border-radius:99px;padding:7px;margin:13px}.win-card .play-btn{margin-top:5px}.toast{position:absolute;z-index:3;top:25%;left:50%;transform:translate(-50%,-10px);opacity:0;transition:.3s;background:#fff4cf;color:#69502a;padding:8px 15px;border-radius:30px;font-weight:1000;box-shadow:0 4px 10px #032d3870;pointer-events:none}.toast.show{opacity:1;transform:translate(-50%,0)}.footer{height:35px;display:flex;align-items:end;justify-content:space-between;color:#a7c5c5;font-size:9px;font-weight:1000;letter-spacing:1.4px}.footer b{color:#ffb17c}@keyframes bob{50%{transform:translateY(-6px)}}@media(max-width:650px){body{padding:7px}.topbar{height:42px;margin-bottom:7px}.top-actions{gap:3px}.top-actions .sound-btn{padding:6px 8px;font-size:9px}.brand{font-size:10px}.brand-icon{width:32px;height:32px;font-size:20px;border-radius:11px}.top-location{font-size:8px;letter-spacing:1px}.sound-btn{padding:7px 10px;font-size:10px}.sound-btn span{display:none}.game-wrap{border-radius:13px;max-height:calc(100dvh - 90px)}.hud{padding:9px}.hud-pill{padding:5px 8px;gap:5px;min-width:0;border-radius:9px}.hud-icon{font-size:15px}.hud-pill small{font-size:6px}.hud-pill strong{font-size:12px}.life-pill strong{font-size:10px;letter-spacing:1px}.level-pill{font-size:7px;letter-spacing:.7px;padding:6px 9px}.title-card{width:62%}.eyebrow{font-size:7px;letter-spacing:1px}h1{font-size:clamp(27px,7vw,40px)}.title-card p{font-size:11px}.hero-monkey{font-size:37px;margin:3px 0 9px}.hero-monkey img{width:62px;height:62px}.play-btn{font-size:12px;padding:9px 17px}.start-hint{font-size:6px;margin-top:9px}.overlay-sticker{width:68px;height:68px;font-size:20px}.overlay-sticker small{font-size:6px}.sticker-left{right:12%;top:18%}.sticker-right{right:5%;bottom:16%}.mobile-controls{display:flex}.footer{height:25px;font-size:7px;letter-spacing:.5px}}@media(max-height:480px) and (orientation:landscape){body{padding:4px}.topbar{height:30px;margin-bottom:4px}.game-wrap{max-height:calc(100dvh - 58px);border-radius:10px}.footer{display:none}.mobile-controls{bottom:8px}.mobile-controls button{width:48px;height:48px}.mobile-controls .jump-control{width:58px;height:58px}.overlay-sticker{width:60px;height:60px}.title-card{width:50%}h1{font-size:36px}}
.landing-menu{display:grid;gap:9px;width:min(260px,100%);margin-top:4px}.landing-menu button{height:42px;position:relative;border-radius:999px;font:1000 13px 'Nunito';letter-spacing:.5px;box-shadow:0 4px 0 #583b2b,0 7px 12px #071b3380}.landing-menu .play-btn{height:48px;font-size:15px;background:#ffcd38;border:3px solid #fff0b1;color:#3d2b1d;box-shadow:0 5px 0 #a76020,0 7px 14px #061d4080}.landing-menu .menu-btn{background:linear-gradient(#fff6dd,#f1d7a6);border:2px solid #fff5d8;color:#422f24}.menu-icon{display:inline-block;margin-right:10px;color:#75502a}.start-hint{margin-top:10px}.settings-btn{position:absolute;z-index:6;right:15px;top:15px;width:46px;height:46px;border:3px solid #fbe7ad;border-radius:14px;background:linear-gradient(#26314f,#101a35);color:#fff3c8;font-size:25px;box-shadow:0 4px 0 #060c1c;cursor:pointer}.hero-monkey{position:absolute;left:min(320px,70%);bottom:64px;margin:0;animation:bob 2s ease-in-out infinite}.hero-monkey img{width:104px;height:104px;object-fit:contain;image-rendering:pixelated;filter:drop-shadow(0 3px 0 #34251b)}.hero-monkey span{top:-8px;right:-5px;text-shadow:1px 2px #a46719}.info-panel{position:absolute;z-index:7;left:50%;top:50%;transform:translate(-50%,-50%);width:min(390px,82%);padding:24px 25px 20px;border:4px solid #f5dfac;border-radius:18px;background:linear-gradient(145deg,#202b4a,#10182d);box-shadow:0 9px 0 #080e20,0 18px 35px #051026b0;color:#fff7dc;text-align:center}.info-panel[hidden]{display:none}.info-panel h2{margin:0 0 12px;color:#ffcf49;font:1000 24px 'Baloo 2';text-shadow:0 2px #885127}.info-panel p{font-size:14px;line-height:1.55;font-weight:800;margin:0}.info-close{position:absolute;right:8px;top:7px;border:0;background:none;color:#fff0ca;font-size:26px;cursor:pointer}.overlay{background:linear-gradient(90deg,#101b3ce8 0%,#172443bc 39%,#0c1c3440 63%,#092d3c08 100%);padding:3% 5%}.title-card{width:min(430px,54%)}.eyebrow{margin-bottom:5px}h1{font-size:clamp(32px,5.2vw,58px);line-height:.83;margin-bottom:9px;letter-spacing:0;text-shadow:2px 3px 0 #2c3153,3px 5px 0 #111a35,0 7px 14px #001b3c}.title-card p{font-size:clamp(11px,1.35vw,15px);line-height:1.15;margin-bottom:5px}.game-wrap{border-color:#f6d98a;box-shadow:0 0 0 4px #122340,0 14px 40px #00162090}.game-wrap:has(.overlay.hidden) .settings-btn{display:none}@media(max-width:650px){.overlay{padding:3% 5%}.title-card{width:65%}h1{font-size:clamp(28px,7vw,39px);line-height:.85}.landing-menu{width:min(210px,100%);gap:7px}.landing-menu button{height:35px;font-size:10px}.landing-menu .play-btn{height:40px;font-size:12px}.hero-monkey{left:65%;bottom:45px}.hero-monkey img{width:66px;height:66px}.settings-btn{width:38px;height:38px;right:9px;top:9px;font-size:20px}.info-panel{padding:20px 18px 17px}.info-panel p{font-size:12px}}
/* Más presencia para Milo en el menú */
.hero-monkey img{width:188px;height:188px}
@media(max-width:650px){.hero-monkey img{width:100px;height:100px}}
/* Juego panorámico a pantalla completa en móviles en horizontal */
@media(max-height:500px) and (orientation:landscape){
  html,body{width:100%;height:100%;min-height:100%;overflow:hidden}
  body{display:block;padding:0}
  .shell{position:fixed;inset:0;width:100vw;height:100dvh}
  .game-wrap{position:absolute;inset:0;width:100%;height:100%;max-height:none;aspect-ratio:auto;border:0;border-radius:0;box-shadow:none}
  .topbar{position:absolute;z-index:10;top:4px;left:10px;right:10px;height:30px;margin:0;text-shadow:0 2px 4px #08152f}
  .brand-icon{width:27px;height:27px;border-radius:9px}
  .brand-icon img{width:27px;height:27px}
  .top-actions .sound-btn{padding:5px 8px;font-size:9px;background:#101a35c9}
  .top-location{font-size:8px;letter-spacing:1px}
  .footer{display:none}
  .hud{top:36px;padding:6px 10px}
  .mobile-controls{bottom:9px;left:12px;right:12px}
  .mobile-controls button{width:48px;height:48px}
  .mobile-controls .jump-control{width:58px;height:58px}
  .overlay{padding:4% 5%}
  .title-card{width:min(44%,430px)}
  h1{font-size:clamp(30px,7vh,48px)}
  .landing-menu{width:min(220px,100%);gap:5px}
  .landing-menu button{height:34px;font-size:10px}
  .landing-menu .play-btn{height:39px;font-size:12px}
  .hero-monkey{left:min(340px,55vw);bottom:24px}
  .hero-monkey img{width:clamp(120px,28vh,170px);height:clamp(120px,28vh,170px)}
  .settings-btn{right:10px;top:42px;width:35px;height:35px;font-size:18px}
}
/* Milo grande y con anclaje visual al suelo */
.hero-monkey img{width:270px;height:270px}
@media(max-width:650px){.hero-monkey img{width:150px;height:150px}}
@media(max-height:500px) and (orientation:landscape){.hero-monkey img{width:clamp(190px,42vh,245px);height:clamp(190px,42vh,245px)}}
.fullscreen-btn{min-width:38px;padding-left:10px;padding-right:10px;font-size:18px}
.shell:fullscreen,.shell:-webkit-full-screen,.shell.pseudo-fullscreen{position:fixed;inset:0;z-index:9999;width:100vw;height:100vh;height:100dvh;max-width:none;display:flex;flex-direction:column;padding:env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);background:#092b3c}
.shell:fullscreen .topbar,.shell:-webkit-full-screen .topbar,.shell.pseudo-fullscreen .topbar{flex:0 0 50px;height:50px;margin:0 0 4px}
.shell:fullscreen .game-wrap,.shell:-webkit-full-screen .game-wrap,.shell.pseudo-fullscreen .game-wrap{flex:1 1 auto;width:100%;height:auto;min-height:0;max-height:none;aspect-ratio:auto;border-radius:10px}
.shell:fullscreen .footer,.shell:-webkit-full-screen .footer,.shell.pseudo-fullscreen .footer{flex:0 0 22px;height:22px}
@media(max-width:650px){.fullscreen-btn{min-width:32px;padding:5px 8px;font-size:16px}}
@media(max-height:500px) and (orientation:landscape){.shell:fullscreen .topbar,.shell:-webkit-full-screen .topbar,.shell.pseudo-fullscreen .topbar{flex-basis:32px;height:32px}.shell:fullscreen .footer,.shell:-webkit-full-screen .footer,.shell.pseudo-fullscreen .footer{display:none}.shell:fullscreen .game-wrap,.shell:-webkit-full-screen .game-wrap,.shell.pseudo-fullscreen .game-wrap{border-radius:0}}
html,body,.shell,.shell *{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;-webkit-tap-highlight-color:transparent}
@media (display-mode:standalone){
  html,body{width:100%;height:100%;min-height:100dvh}
  body{padding:env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);place-items:stretch}
  .shell{width:100%;height:100%;max-width:none;display:flex;flex-direction:column}
  .topbar{flex:0 0 50px;margin:0 0 4px}
  .game-wrap{flex:1 1 auto;width:100%;height:auto;min-height:0;max-height:none;aspect-ratio:auto;border-radius:10px}
  .footer{flex:0 0 22px;height:22px}
}
@media (display-mode:standalone) and (orientation:landscape) and (max-height:500px){
  .topbar{flex-basis:32px;height:32px}
  .footer{display:none}
  .game-wrap{border-radius:0}
}
/* Splash de estudio HTML: aparece durante la carga antes de mostrar Phaser. */
.studio-splash{position:fixed;inset:0;z-index:10000;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;background:#000;opacity:1;transition:opacity .85s ease}.studio-splash-hidden{opacity:0;pointer-events:none}.studio-splash-mark{width:112px;height:112px;border-radius:34px;display:grid;place-items:center;background:#ffcf55;border:4px solid #fff0bd;box-shadow:0 8px 0 #b97932,0 18px 38px #00151f80;animation:bob 1.4s ease-in-out infinite}.studio-splash-mark img{width:98px;height:98px;object-fit:contain;image-rendering:pixelated}.studio-splash-title{margin-top:14px;font:900 clamp(19px,4vw,30px)/1 'Baloo 2',sans-serif;letter-spacing:2px;color:#fff3d3;text-shadow:0 4px 0 #233451}.studio-splash-subtitle{font:900 10px 'Nunito',sans-serif;letter-spacing:3px;color:#ffd66a}
@media(max-width:650px){.move-controls button{width:68px;height:68px}}
@media(max-height:480px) and (orientation:landscape){.move-controls button{width:58px;height:58px}}
.settings-panel{position:absolute;inset:0;z-index:12;display:grid;place-items:center;padding:14px;background:#061624b8}.settings-panel[hidden]{display:none}.settings-card{position:relative;width:min(390px,92%);padding:22px 24px 20px;border:3px solid #f4d88b;border-radius:20px;background:linear-gradient(145deg,#202d4b,#10192e);box-shadow:0 10px 30px #06101dcc;color:#fff6db;text-align:center}.settings-card h2{margin:0 0 16px;color:#ffd45b;font:900 25px 'Baloo 2'}.settings-options{display:grid;gap:10px}.settings-option{width:100%;min-height:44px;border:2px solid #c9d5de;border-radius:12px;background:#f6efd9;color:#23344a;font:900 13px 'Nunito';cursor:pointer}.settings-option:hover{background:#fff8e8}.settings-card .info-close{right:8px;top:5px}

/* Responsive viewport layout: preserve Phaser's 16:9 canvas and use the available screen. */
:root:not(.mobile-device) .shell{width:min(1160px,calc(100vw - 24px),calc((100dvh - 120px)*16 / 9))}
:root:not(.mobile-device) .hud{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);gap:10px;align-items:start}
:root:not(.mobile-device) .score-pill{justify-self:start}
:root:not(.mobile-device) .level-pill{justify-self:center;min-width:0;max-width:48vw;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
:root:not(.mobile-device) .life-pill{justify-self:end}
#game-container{display:flex;align-items:center;justify-content:center;min-width:0;min-height:0}
#game-container canvas{display:block;width:auto!important;height:auto!important;max-width:100%;max-height:100%;margin:0!important;flex:none}
.mobile-controls{touch-action:none;overscroll-behavior:contain}
.mobile-controls button{touch-action:none;-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}
.orientation-screen{display:none}
.mobile-portrait{width:100%;height:100%;height:100dvh;overflow:hidden;background:#092b3c}
.mobile-portrait body{width:100%;height:100%;height:100dvh;min-height:0;padding:0;display:block;overflow:hidden;overscroll-behavior:none}
.mobile-portrait .shell{display:none!important}
.mobile-portrait .orientation-screen{position:fixed;z-index:2147483646;inset:0;display:grid;place-items:center;min-height:100vh;min-height:100dvh;padding:max(24px,env(safe-area-inset-top)) max(24px,env(safe-area-inset-right)) max(24px,env(safe-area-inset-bottom)) max(24px,env(safe-area-inset-left));background:radial-gradient(ellipse at 50% 35%,#1c5360,#092b3c 72%);text-align:center}
.orientation-card{width:min(420px,100%);padding:28px 24px;border:2px solid #f3d894;border-radius:24px;background:linear-gradient(145deg,#17334d,#101b36);box-shadow:0 12px 35px #00152080}
.orientation-card{position:relative;overflow:hidden;border-width:3px;box-shadow:0 0 0 4px #0b162b,0 12px 35px #00152080, inset 0 0 0 2px #ffffff12}
.orientation-card::before,.orientation-card::after{position:absolute;color:#ffcf49;font-size:18px;text-shadow:2px 2px #7a4b25;animation:orientationSparkle 1.5s steps(2,end) infinite}
.orientation-card::before{content:'✦';left:18px;top:18px}
.orientation-card::after{content:'✦';right:18px;bottom:16px;animation-delay:.7s}
.orientation-device{position:relative;width:54px;height:82px;margin:0 auto 24px;border:4px solid #ffdb79;border-radius:12px;transform:rotate(0);animation:rotateDevice 1.8s ease-in-out infinite alternate}
.orientation-device::before{content:'';position:absolute;inset:6px 5px 10px;border-radius:4px;background:linear-gradient(145deg,#63c9dc,#3383b5)}
.orientation-device span{position:absolute;z-index:1;right:-22px;bottom:-19px;color:#ffdb79;font:900 28px/1 'Nunito';text-shadow:0 2px 5px #00152c}
.orientation-mascot{position:relative;width:132px;height:112px;margin:0 auto 12px;animation:orientationMilo 2.4s steps(2,end) infinite alternate;transform-origin:bottom center;filter:drop-shadow(0 4px 0 #081326)}
.orientation-mascot img{position:absolute;left:0;bottom:0;width:112px;height:112px;object-fit:contain;image-rendering:pixelated}
.orientation-phone{position:absolute;z-index:1;right:5px;top:31px;width:20px;height:35px;border:3px solid #f7dc94;border-radius:4px;background:#18344e;box-shadow:2px 2px 0 #081326;transform-origin:50% 80%;animation:phoneTurn 2.4s steps(4,end) infinite alternate}
.orientation-phone::after{content:'';position:absolute;inset:3px;background:#62bfce;border:1px solid #17213d}
.orientation-card h1{margin:0;color:#ffdb79;font:900 clamp(19px,5vw,28px)/1.12 'Baloo 2',sans-serif;letter-spacing:.4px;text-shadow:0 3px 0 #26324a,2px 2px 0 #101b36}
@keyframes rotateDevice{to{transform:rotate(90deg)}}
@keyframes phoneTurn{to{transform:rotate(90deg) translateY(-2px)}}
@keyframes orientationMilo{to{transform:translateY(-4px) rotate(-3deg)}}
@keyframes orientationSparkle{50%{opacity:.35;transform:scale(.75)}}

.mobile-device{width:100%;height:100%;height:100dvh;overflow:hidden;overscroll-behavior:none}
.mobile-device body{width:100%;height:100%;height:100dvh;min-height:0;padding:0;display:block;overflow:hidden;overscroll-behavior:none}
.mobile-device .shell{position:fixed;inset:0;width:100%;height:100vh;height:100dvh;max-width:none;display:flex;flex-direction:column;padding:0;background:#092b3c}
.mobile-device .topbar{position:absolute;z-index:10;top:0;left:0;right:0;height:0;margin:0;padding:0;display:block;pointer-events:none}
.mobile-device .topbar .brand,.mobile-device .topbar .top-location{display:none}
.mobile-device .top-actions{position:absolute;top:calc(env(safe-area-inset-top) + 5px);right:max(8px,env(safe-area-inset-right));gap:5px;pointer-events:auto}
.mobile-device .top-actions .sound-btn{width:42px;height:42px;display:grid;place-items:center;padding:0;border:2px solid #ffe08a;border-radius:12px;color:#fff8dc;font-size:20px;font-weight:1000;line-height:1;text-shadow:0 1px 2px #00101c;background:linear-gradient(145deg,#23375b,#0a1c35);box-shadow:0 3px 0 #050d1e,0 0 0 2px #0a192b,0 4px 12px #00131fcc}
.mobile-device .top-actions .sound-btn span{display:none}
.mobile-device .game-wrap{position:relative;flex:1 1 auto;width:100%;height:auto;min-width:0;min-height:0;max-height:none;aspect-ratio:auto;align-self:stretch;overflow:hidden;border:0;border-radius:0;box-shadow:none;background:#102d48}
.mobile-device #game-container{position:absolute;inset:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center;overflow:hidden}
.mobile-device #game-container canvas{display:block;flex:none;width:auto!important;height:auto!important;max-width:100%;max-height:100%;margin:0!important;image-rendering:pixelated}
.mobile-device .hud{top:calc(env(safe-area-inset-top) + 6px);left:0;right:0;display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:clamp(3px,1vw,8px);align-items:start;padding:0 max(8px,env(safe-area-inset-right)) 0 max(8px,env(safe-area-inset-left))}
.mobile-device .hud-pill{min-width:0;max-width:100%;gap:4px;padding:4px 6px;border-radius:8px}
.mobile-device .hud-icon{font-size:13px}
.mobile-device .hud-banana{width:21px;height:21px}
.mobile-device .hud-pill small{font-size:6px;letter-spacing:.7px}
.mobile-device .hud-pill strong{font-size:11px}
.mobile-device .life-pill strong{font-size:13px;letter-spacing:1.5px;white-space:nowrap}
.mobile-device .life-pill{margin-right:0;padding:6px 9px;gap:6px}
.mobile-device .hud-right{margin-right:110px;gap:6px}
.mobile-device .life-pill .hud-icon{font-size:16px}
.mobile-device .life-pill small{display:none}
.mobile-device .level-pill{justify-self:center;min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-top:2px;padding:5px 8px;font-size:clamp(6px,1.2vw,8px);letter-spacing:.3px;text-align:center}
.mobile-device .mobile-controls{position:absolute;z-index:3;bottom:max(8px,env(safe-area-inset-bottom));left:max(10px,env(safe-area-inset-left));right:max(10px,env(safe-area-inset-right));align-items:end}
.mobile-device .move-controls{gap:clamp(7px,1.5vw,12px)}
.mobile-device .mobile-controls button{width:clamp(50px,13vw,64px);height:clamp(50px,13vw,64px);font-size:20px;opacity:.88;backdrop-filter:blur(2px)}
.mobile-device .mobile-controls .jump-control{width:70px;height:70px;font-size:27px;opacity:.94}
.mobile-device .footer{display:none}

@media(max-width:760px){
  :root:not(.mobile-device) .topbar{gap:7px}
  :root:not(.mobile-device) .top-location{max-width:38vw;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  :root:not(.mobile-device) .level-pill{max-width:44vw}
}
@media(max-height:430px){
  .mobile-device .hud{top:calc(env(safe-area-inset-top) + 3px)}
  .mobile-device .mobile-controls button{width:48px;height:48px}
  .mobile-device .mobile-controls .jump-control{width:58px;height:58px}
}
@supports (height:100dvh){
  .mobile-device,.mobile-portrait{height:var(--visible-viewport-height,100dvh)}
  .mobile-device .shell,.mobile-portrait .orientation-screen{height:var(--visible-viewport-height,100dvh);min-height:var(--visible-viewport-height,100dvh)}
}
.action-controls{display:flex;align-items:end;gap:8px}
.mobile-controls .throw-control{width:58px;height:58px;display:grid;place-content:center;gap:1px;background:#073345b8;color:#fff;border-color:#fff0c4}
.throw-control img{width:25px;height:25px;object-fit:contain;image-rendering:pixelated}
.throw-control small{font-size:7px;letter-spacing:.7px;line-height:1}
.mobile-device .mobile-controls .throw-control{width:clamp(50px,12vw,60px);height:clamp(50px,12vw,60px);font-size:inherit}
.mobile-device .mobile-controls .throw-control img{width:24px;height:24px}
@media(max-height:430px){.mobile-device .mobile-controls .throw-control{width:48px;height:48px}.mobile-device .mobile-controls .throw-control img{width:20px;height:20px}}
.top-actions .sound-btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;white-space:nowrap;text-transform:uppercase}
@font-face{font-family:'Press Start 2P';src:url('assets/fonts/press-start-2p-latin.woff2') format('woff2');font-style:normal;font-weight:400;font-display:block}

.memory-overlay{position:fixed;inset:0;z-index:2147483001;display:grid;place-items:center;box-sizing:border-box;padding:max(12px,env(safe-area-inset-top)) max(12px,env(safe-area-inset-right)) max(12px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left));background:#061521dc;backdrop-filter:blur(3px);overscroll-behavior:contain}
.game-wrap:has(.memory-prompt:not([hidden]))::after{content:'';position:absolute;z-index:8;inset:0;background:rgba(5,15,28,.17);pointer-events:none}
.memory-prompt{position:absolute;z-index:9;top:15%;left:50%;transform:translateX(-50%);width:min(540px,calc(100% - 32px));padding:9px 14px 9px;border:4px solid #27334b;border-radius:4px;background:#fff3d2;box-shadow:0 4px 0 #875e3b;text-align:center;pointer-events:auto}
.memory-prompt[hidden]{display:none}
.memory-prompt-message{margin:0 auto 8px;color:#26334d;font:800 clamp(12px,1.4vw,15px)/1.35 'Press Start 2P',monospace}
.memory-prompt-actions{display:flex;justify-content:center;gap:9px}
.memory-prompt-button{min-width:145px;min-height:42px;padding:7px 14px;border:3px solid #27334b;border-radius:3px;color:#27334b;font:800 12px/1.2 'Press Start 2P',monospace;cursor:pointer;touch-action:manipulation}
.memory-prompt-button:hover{filter:brightness(1.06);transform:translateY(-1px)}
.memory-prompt-ignore{background:#e6edf2}
.memory-prompt-open{background:#f6c74f}
@media(max-width:650px){.memory-prompt{top:15%;width:calc(100% - 24px);padding:7px 9px 8px;border-width:3px}.memory-prompt-message{margin-bottom:6px;font-size:9px;line-height:1.4}.memory-prompt-actions{gap:7px}.memory-prompt-button{min-width:100px;min-height:40px;padding:5px 8px;border-width:2px;font-size:8px}}
@media(max-height:500px) and (orientation:landscape){.memory-prompt{top:12%;width:min(500px,calc(100% - 24px));padding:6px 10px 7px;border-width:3px}.memory-prompt-message{margin-bottom:5px;font-size:clamp(9px,1.15vw,12px);line-height:1.3}.memory-prompt-actions{gap:8px}.memory-prompt-button{min-width:100px;min-height:38px;padding:4px 8px;font-size:8px}}
.memory-dialog{position:relative;box-sizing:border-box;width:min(760px,96vw);max-height:96dvh;overflow:auto;padding:20px clamp(16px,3vw,34px) 24px;border:4px solid #ffd15b;border-radius:18px;background:linear-gradient(145deg,#fff8e5,#f4dcae);color:#26334d;box-shadow:0 10px 0 #81512c,0 24px 70px #00121fc9;text-align:center;scrollbar-color:#bb8550 #f5e5c4}
.memory-story-layout{display:grid;grid-template-columns:minmax(0,1.12fr) minmax(0,.88fr);gap:clamp(16px,3vw,32px);align-items:center;text-align:left}
.memory-dialog-header{display:flex;justify-content:center;align-items:center;min-height:34px;margin-bottom:5px}
.memory-dialog-kicker{font:9px 'Press Start 2P',monospace;letter-spacing:.3px;color:#476b68}
.memory-dialog-close{position:absolute;right:12px;top:10px;width:36px;height:36px;border:2px solid #26334d;border-radius:9px;background:#fff4d5;color:#26334d;font:700 25px/1 'Nunito',sans-serif;cursor:pointer}
.memory-dialog h2{margin:8px auto 12px;font:clamp(13px,2.2vw,19px)/1.65 'Press Start 2P',monospace;color:#684528;text-wrap:balance}
.memory-story-image-frame{display:flex;flex-direction:column;gap:8px;box-sizing:border-box;width:100%;margin:0;padding:7px;border:3px solid #8d6240;border-radius:8px;background:#fff2d7;box-shadow:inset 0 0 0 2px #fff9e8}
.memory-story-image-expand{display:block;width:100%;height:clamp(170px,42vh,390px);padding:0;border:0;background:#233754;cursor:zoom-in;overflow:hidden}
.memory-story-image-frame img{display:block;width:100%;height:100%;object-fit:contain;image-rendering:auto}
.memory-story-caption{color:#76573a;font:italic 700 12px/1.4 'Nunito',sans-serif;text-align:center}
.memory-story-copy{min-width:0}
.memory-story-copy h2{display:block;width:100%;box-sizing:border-box;margin:0 0 16px;padding:12px 14px;border:2px solid #8d6240;border-left:7px solid #d99c35;border-radius:7px;background:linear-gradient(100deg,#fff4d8,#f1d9a9);box-shadow:0 3px 0 #bb8450;color:#593c28;text-align:left;font:800 19px/1.25 'Baloo 2',sans-serif;letter-spacing:.2px;text-wrap:balance}
.memory-story-video{display:block;width:min(100%,640px);max-height:34vh;margin:0 auto 14px;border:3px solid #24314d;background:#101827}
.memory-story-video-frame .memory-story-video{flex:1;min-height:0;width:100%;height:auto;max-height:100%;margin:0;object-fit:contain}
.memory-story-body{max-width:680px;margin:8px auto 0;font:700 clamp(14px,2.3vw,19px)/1.55 'Nunito',sans-serif;color:#28334b;text-wrap:pretty}
.memory-story-headline{margin:4px auto 8px;font:800 clamp(16px,2.5vw,22px)/1.35 'Nunito',sans-serif;color:#78452f}
.memory-story-meta{margin-top:13px;color:#617066;font:700 11px 'Nunito',sans-serif;letter-spacing:.5px}
.memory-dialog-letter .memory-story-body{box-sizing:border-box;padding:16px;border:2px dashed #bd965d;background:#fffaf0;text-align:left;white-space:pre-line}
.memory-image-lightbox{position:fixed;inset:0;z-index:2;display:grid;place-items:center;padding:24px;background:#071421f2;cursor:zoom-out}
.memory-image-lightbox img{display:block;max-width:96vw;max-height:92dvh;object-fit:contain}
.memory-image-lightbox-close{position:absolute;top:max(14px,env(safe-area-inset-top));right:max(14px,env(safe-area-inset-right));width:42px;height:42px;border:2px solid #26334b;border-radius:10px;background:#fff4d5;color:#26334b;font:700 27px/1 'Nunito',sans-serif;cursor:pointer}
@media(max-width:650px){.memory-overlay{padding:0}.memory-dialog{width:100vw;height:100dvh;max-height:100dvh;overflow:auto;padding:max(48px,env(safe-area-inset-top)) 16px max(18px,env(safe-area-inset-bottom));border:0;border-radius:0;box-shadow:none;display:flex;flex-direction:column}.memory-dialog-header{flex:none;min-height:32px;margin-bottom:10px}.memory-dialog-close{top:max(10px,env(safe-area-inset-top));right:12px}.memory-story-layout{flex:1;min-height:0;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:14px;align-items:center}.memory-story-image-frame{padding:5px;gap:7px}.memory-story-image-expand{height:min(54vh,390px)}.memory-story-caption{font-size:10px}.memory-story-copy{text-align:left}.memory-dialog h2{font-size:clamp(12px,3.2vw,17px);line-height:1.6}.memory-story-body{font-size:clamp(13px,3.4vw,17px);line-height:1.5}}
@media(max-height:500px) and (orientation:landscape){.memory-dialog{width:min(820px,96vw);max-height:94dvh;padding:10px 20px 13px}.memory-dialog-header{min-height:24px;margin-bottom:0}.memory-dialog-kicker{font-size:7px}.memory-dialog-close{top:6px;right:8px;width:30px;height:30px}.memory-dialog h2{margin:4px auto 7px;font-size:clamp(11px,2.2vh,15px)}.memory-story-image-frame{height:clamp(90px,25vh,145px);margin-bottom:7px}.memory-story-video{max-height:25vh;margin-bottom:7px}.memory-story-body{margin-top:4px;font-size:clamp(12px,2.7vh,15px);line-height:1.4}.memory-story-meta{margin-top:6px;font-size:9px}}
@media(max-height:500px) and (orientation:landscape){.memory-overlay{padding:0}.memory-dialog{display:flex;flex-direction:column;width:100vw;height:100dvh;max-height:100dvh;padding:max(28px,env(safe-area-inset-top)) max(20px,env(safe-area-inset-right)) max(14px,env(safe-area-inset-bottom)) max(20px,env(safe-area-inset-left));overflow:hidden;border:0;border-radius:0;box-shadow:none}.memory-dialog-header{flex:none;min-height:28px;margin:0 0 8px}.memory-dialog-close{top:max(8px,env(safe-area-inset-top));right:max(12px,env(safe-area-inset-right))}.memory-story-layout{display:grid;flex:1;min-height:0;grid-template-columns:minmax(0,1.35fr) minmax(0,.85fr);gap:clamp(14px,2.5vw,30px);align-items:stretch}.memory-story-image-frame{display:flex;height:auto;min-height:0;margin:0;padding:6px;gap:6px}.memory-story-image-expand{flex:1;min-height:0;height:auto}.memory-story-image-frame img{width:100%;height:100%;object-fit:contain}.memory-story-caption{flex:none;font-size:clamp(10px,1.7vh,13px)}.memory-story-copy{align-self:center;max-height:100%;overflow:auto;padding-right:8px}.memory-dialog h2{margin:0 0 12px;font-size:clamp(12px,2.6vh,20px);line-height:1.55}.memory-story-body{margin:0;font-size:clamp(14px,2.5vh,19px);line-height:1.5}}
.memory-dialog .memory-story-copy h2{font-size:19px}

/* Collectible memories archive */
.hud-right{display:flex;align-items:center;justify-self:end;gap:9px;pointer-events:none}
.memory-folder-button{position:relative;z-index:4;pointer-events:auto;touch-action:manipulation;flex:0 0 auto;width:48px;height:48px;display:grid;place-items:center;padding:0;border:0;border-radius:0;background:transparent;box-shadow:none;filter:drop-shadow(0 2px 2px #07152170);cursor:pointer;transition:transform .12s,filter .12s}
.memory-folder-button img{display:block;width:100%;height:100%;object-fit:contain;image-rendering:pixelated}
.memory-folder-button:hover{transform:translateY(-2px) scale(1.06);filter:drop-shadow(0 3px 3px #07152180) brightness(1.08)}
.memory-folder-button:active{transform:translateY(1px) scale(.94);filter:drop-shadow(0 1px 1px #07152180)}
.memory-folder-button:focus-visible{outline:2px solid #ffe08a;outline-offset:2px;border-radius:5px}
.memory-collection-overlay{position:fixed;inset:0;z-index:2147483000;display:grid;place-items:center;padding:max(12px,env(safe-area-inset-top)) max(12px,env(safe-area-inset-right)) max(12px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left));background:#061521c4;backdrop-filter:blur(2px);overscroll-behavior:contain}
.memory-collection-dialog{position:relative;box-sizing:border-box;width:min(850px,96vw);max-height:min(88dvh,700px);display:flex;flex-direction:column;overflow:hidden;padding:18px 20px 20px;border:4px solid #ffd15b;border-radius:16px;background:linear-gradient(145deg,#fff8e5,#f1d7a7);color:#26334d;box-shadow:0 9px 0 #81512c,0 22px 60px #00121fc9}
.memory-collection-header{position:relative;display:flex;align-items:center;justify-content:center;min-height:40px;padding:0 48px}
.memory-collection-header h2{margin:0;color:#684528;text-align:center;font:800 clamp(15px,2vw,21px)/1.3 'Baloo 2',sans-serif;letter-spacing:.5px}
.memory-collection-close{position:absolute;top:0;right:0;width:40px;height:40px;border:2px solid #26334d;border-radius:9px;background:#fff4d5;color:#26334d;font:700 26px/1 'Nunito',sans-serif;cursor:pointer}
.memory-collection-count{flex:none;margin:3px 0 14px;color:#53675b;text-align:center;font:800 12px/1.4 'Nunito',sans-serif}
.memory-collection-list{min-height:0;overflow:auto;display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,220px),1fr));gap:10px;padding:2px 4px 8px;overscroll-behavior:contain}
.memory-collection-card{min-width:0;min-height:86px;display:flex;align-items:center;gap:12px;padding:9px 11px;border:2px solid #9b7045;border-radius:9px;background:#fff1d3;color:#503824;text-align:left;font:inherit;box-shadow:0 3px 0 #c49a65}
button.memory-collection-card{cursor:pointer;transition:transform .12s,filter .12s,box-shadow .12s}
button.memory-collection-card:hover{transform:translateY(-2px);filter:brightness(1.04);box-shadow:0 5px 0 #c49a65}
button.memory-collection-card:active{transform:translateY(2px);box-shadow:0 1px 0 #c49a65}
.memory-collection-card.is-locked{border-style:dashed;background:#e9d8b9;color:#746b5d;box-shadow:0 3px 0 #ad9371}
.memory-collection-thumbnail{flex:0 0 68px;width:68px;height:58px;display:grid;place-items:center;overflow:hidden;border:2px solid #b88751;border-radius:5px;background:#263c57;color:#ffdf86;font:800 30px 'Press Start 2P',monospace}
.memory-collection-thumbnail img{display:block;width:100%;height:100%;object-fit:cover;image-rendering:auto}
.memory-collection-card:not(.is-collected) .memory-collection-thumbnail{border-color:#b4a184;background:repeating-linear-gradient(135deg,#756b58 0 7px,#887a63 7px 14px);color:#f7e7c7}
.memory-collection-copy{min-width:0;display:flex;flex-direction:column;gap:5px}
.memory-collection-copy strong{font:800 14px/1.3 'Baloo 2',sans-serif;overflow-wrap:anywhere}
.memory-collection-copy small{color:#6a755f;font:900 9px/1.35 'Nunito',sans-serif;letter-spacing:.8px;text-transform:uppercase}
@media(max-width:650px){.memory-folder-button{width:48px;height:48px}.memory-collection-overlay{padding:0}.memory-collection-dialog{width:100vw;height:100dvh;max-height:100dvh;padding:max(38px,env(safe-area-inset-top)) max(12px,env(safe-area-inset-right)) max(12px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left));border:0;border-radius:0;box-shadow:none}.memory-collection-header{min-height:38px;padding:0 46px}.memory-collection-close{width:42px;height:42px}.memory-collection-count{margin:2px 0 9px;font-size:11px}.memory-collection-list{grid-template-columns:repeat(auto-fit,minmax(min(100%,210px),1fr));gap:8px}.memory-collection-card{min-height:74px;padding:7px 9px}.memory-collection-thumbnail{flex-basis:58px;width:58px;height:50px}.memory-collection-copy strong{font-size:13px}}
@media(max-height:500px) and (orientation:landscape){.memory-collection-dialog{width:min(900px,96vw);height:94dvh;max-height:94dvh;padding:8px 14px 9px}.memory-collection-header{min-height:30px}.memory-collection-header h2{font-size:16px}.memory-collection-close{width:32px;height:32px;font-size:22px}.memory-collection-count{margin:1px 0 6px;font-size:10px}.memory-collection-list{grid-template-columns:repeat(auto-fit,minmax(min(100%,215px),1fr));gap:7px}.memory-collection-card{min-height:65px;padding:6px 8px}.memory-collection-thumbnail{flex-basis:54px;width:54px;height:46px}.memory-collection-copy strong{font-size:12px}}

