.mge-root{--mge-cyan:#72f4ff;--mge-pink:#ff6dba;--mge-yellow:#fff29b;--mge-ink:#111429;--mge-glass:#0e1437d9;color:#f9fbff;background:linear-gradient(145deg,#10142b 5%,#24204e 50%,#10142b 95%);border:1px solid #4c527b;border-radius:20px;box-shadow:0 16px 55px #04051c55;max-width:1180px;margin:20px auto;overflow:hidden;font-family:system-ui,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;isolation:isolate;box-sizing:border-box;line-height:1.35}
.mge-root *{box-sizing:border-box}
.mge-root button{font-family:inherit;cursor:pointer;touch-action:manipulation;line-height:1.2}
.mge-root button:focus-visible{outline:3px solid var(--mge-yellow);outline-offset:3px}
.mge-topline{display:flex;justify-content:space-between;align-items:center;min-height:61px;padding:10px 20px;border-bottom:1px solid #444965;background:linear-gradient(90deg,#111529,#242043)}
.mge-logo{font-weight:900;letter-spacing:1.8px;font-size:clamp(13px,2vw,19px);display:flex;gap:12px;align-items:center;text-shadow:0 2px #0a1029}
.mge-logo b{color:#73f4ff}.mge-logo-icon{font-size:26px;color:#ff83cd;text-shadow:0 0 15px #ff83cd}
.mge-top-actions{display:flex;gap:8px}.mge-top-actions button,.mge-pause{width:36px;height:36px;border:1px solid #606b93;border-radius:9px;background:#292f51;color:#fff;font-size:22px;font-weight:800;padding:0;display:grid;place-items:center}
.mge-top-actions button:hover,.mge-pause:hover{background:#46527e}
.mge-stage-wrap{position:relative;background:#09122c;overflow:hidden}
.mge-canvas{display:block;width:100%;height:auto;aspect-ratio:16/9;touch-action:none;background:#172755;image-rendering:auto}
.mge-hud{position:absolute;z-index:2;top:12px;left:13px;right:13px;display:flex;align-items:center;gap:9px;pointer-events:none;filter:drop-shadow(0 2px 4px #0009)}
.mge-hud-group{display:flex;flex-direction:column;gap:2px;border:1px solid #ffffff29;border-radius:10px;background:#0b1127b8;padding:5px 11px;min-width:85px;backdrop-filter:blur(5px)}
.mge-hud-group span{font-weight:800;color:#b3c6e9;letter-spacing:1.4px;font-size:9px}.mge-hud-group strong{font-weight:950;letter-spacing:1px;font-size:clamp(10px,1.5vw,16px);font-variant-numeric:tabular-nums;color:#fff}
.mge-hud-group:nth-child(4){margin-left:auto}.mge-hud-group:nth-child(4) strong{color:#ff7bb6;letter-spacing:3px}
.mge-pause{pointer-events:auto;width:35px;height:35px;flex:0 0 auto}
.mge-overlay{position:absolute;inset:0;z-index:4;display:flex;justify-content:center;align-items:center;background:radial-gradient(ellipse at 50% 30%,#292763ae,#070d29dc 80%);text-align:center;padding:18px;overflow:auto}
.mge-overlay[hidden]{display:none!important}
.mge-menu{max-width:610px;width:100%;animation:mge-rise .28s ease-out}.mge-eyebrow{font-size:clamp(9px,1.5vw,13px);font-weight:900;letter-spacing:3px;color:#8ff6ff;text-shadow:0 0 12px #1eb8db}
.mge-menu h2{font-family:inherit!important;margin:11px 0!important;font-size:clamp(36px,6vw,75px)!important;line-height:.99!important;font-weight:1000!important;color:#fff!important;letter-spacing:-2px!important;text-shadow:4px 6px 0 #10163c,0 0 34px #6d36a7;transform:rotate(-2deg)}
.mge-menu h2 em{font-style:normal;color:#ffd671;text-shadow:3px 4px 0 #de5586,0 0 25px #ff6ba650}
.mge-menu p{color:#dae3ff;font-size:clamp(13px,1.7vw,20px);margin:17px 0;line-height:1.4}
.mge-menu-actions{display:flex;justify-content:center;flex-wrap:wrap;gap:12px;margin:18px auto}
.mge-root .mge-primary,.mge-root .mge-secondary{border-radius:12px;padding:12px 19px;min-height:46px;text-transform:uppercase;font-weight:950;letter-spacing:.5px;border:2px solid transparent;box-shadow:0 5px 0 #0005;transition:transform .13s,filter .13s;font-size:clamp(12px,1.5vw,16px)}
.mge-root .mge-primary{background:#ffdc68;color:#302443;border-color:#fff3ba}.mge-root .mge-secondary{background:#29355d;color:#f3faff;border-color:#6a8cbd}
.mge-root .mge-primary:hover,.mge-root .mge-secondary:hover{filter:brightness(1.12);transform:translateY(-2px)}
.mge-smallprint{font-size:clamp(9px,1.25vw,12px);font-weight:700;color:#bdc2da;letter-spacing:.5px}
.mge-bottom{display:flex;gap:8px;align-items:center;justify-content:space-between;flex-wrap:wrap;padding:12px 17px;background:#15192e;color:#b4bad4;font-size:11px;letter-spacing:1.1px;font-weight:800}
.mge-bottom button{border:none;color:#fff7c4;background:#343257;border-radius:9px;padding:8px 10px;font-size:11px;font-weight:900;letter-spacing:1px}
.mge-bottom button:hover{background:#514777}
.mge-green-dot{display:inline-block;vertical-align:middle;margin-right:5px;width:8px;height:8px;background:#6cf4a9;border-radius:50%;box-shadow:0 0 10px #55e3a7}
.mge-dialog-host{display:none;position:fixed;inset:0;background:#04071dbd;z-index:999999;align-items:center;justify-content:center;padding:18px}
.mge-dialog-host.is-open{display:flex}
.mge-modal{background:linear-gradient(150deg,#20274d,#12172f);border:1px solid #707dad;color:#fff;max-height:min(90vh,800px);overflow-y:auto;width:min(730px,100%);border-radius:20px;box-shadow:0 16px 80px #000c;padding:20px}
.mge-modal-head{display:flex;align-items:center;justify-content:space-between;gap:15px;margin-bottom:13px}
.mge-modal h3{font-size:25px!important;font-weight:950!important;letter-spacing:.4px;color:#ffe07a!important;margin:0!important}
.mge-modal .mge-close{background:#384268;color:#fff;border:0;border-radius:10px;width:38px;height:38px;font-size:23px;flex:0 0 auto}
.mge-modal p{color:#ccd9f6}.mge-worlds{display:flex;gap:9px;flex-wrap:wrap;margin:12px 0}
.mge-world-btn{padding:9px 10px;border-radius:9px;border:1px solid #59678a;background:#30385c;color:#fff;font-size:13px;font-weight:800}
.mge-world-btn.active{background:#ffda7a;color:#25213b;border-color:#fff1be}
.mge-level-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px;margin-top:16px}
.mge-level-grid button{min-height:61px;border:1px solid #7182ac;border-radius:8px;background:#304b72;color:#fff;font-weight:900;font-size:14px;padding:6px 5px;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:3px;text-align:center}
.mge-stage-num{font-size:14px;color:#fff29b}.mge-stage-name{font-size:10px;line-height:1.15;overflow-wrap:anywhere;font-weight:750;color:#e8efff}
.mge-level-grid button:disabled{background:#222b43;color:#7886aa;border-color:#303b56;cursor:not-allowed}
.mge-level-grid button.is-cleared{background:#226b68;border-color:#66d9c1}.mge-level-grid button.is-current{outline:2px solid #ffe17a;outline-offset:2px}
.mge-modal table{width:100%;border-collapse:collapse;color:#e8efff;font-size:14px}
.mge-modal td,.mge-modal th{padding:10px 7px;border-bottom:1px solid #ffffff1b;text-align:left}
.mge-modal th{color:#9ccef6;font-size:11px;letter-spacing:1px}
.mge-modal input{padding:12px;border:1px solid #8b9abf;border-radius:9px;background:#13192f;color:white;width:min(100%,300px);font-size:16px}
.mge-modal-actions{display:flex;justify-content:center;flex-wrap:wrap;gap:10px;margin:19px auto 5px}
.mge-touch-controls{position:absolute;z-index:3;left:14px;right:14px;bottom:10px;display:none;justify-content:space-between;align-items:end;pointer-events:none;user-select:none}
.mge-pad{display:flex;gap:10px}.mge-pad button{pointer-events:auto;touch-action:none;user-select:none;display:grid;place-items:center;width:clamp(44px,11vw,66px);height:clamp(44px,11vw,66px);border:2px solid #b8d8f4a0;border-radius:19px;background:#1e2b5cc7;box-shadow:0 4px 0 #080f2ab8;color:#fff;font-weight:950;font-size:27px;padding:0;opacity:.93}
.mge-pad button.is-held,.mge-pad button:active{background:#6d50ae}
.mge-pad .mge-jump-touch{background:#ffbf58d9;color:#1c2140;border-color:#fff3a8;font-size:34px}
.mge-pad .mge-dash-touch{background:#5a4fa9dd;color:#fff}
@keyframes mge-rise{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:translateY(0)}}
@media (hover:none),(pointer:coarse){.mge-touch-controls{position:relative;left:auto;right:auto;bottom:auto;display:flex;padding:9px 13px;background:linear-gradient(90deg,#151b36,#24204b);border-top:1px solid #5b64925c;pointer-events:auto}.mge-smallprint{display:none}.mge-pad button{width:clamp(48px,12vw,65px);height:clamp(48px,12vw,65px)}}
@media(max-width:720px){.mge-root{border-radius:10px;margin:8px auto}.mge-topline{min-height:45px;padding:7px 12px}.mge-top-actions button{width:30px;height:30px;font-size:19px}.mge-hud{left:5px;right:5px;top:5px;gap:4px}.mge-hud-group{min-width:0;padding:3px 6px;border-radius:6px}.mge-hud-group span{font-size:7px;letter-spacing:.3px}.mge-hud-group strong{font-size:10px}.mge-hud-group:nth-child(4) strong{letter-spacing:1px}.mge-pause{width:26px;height:26px;font-size:15px;border-radius:6px}.mge-bottom{font-size:9px;padding:9px}.mge-bottom>span:last-child{display:none}.mge-menu h2{letter-spacing:-1px!important}.mge-menu p{margin:10px auto}.mge-menu-actions{margin:10px auto}.mge-root .mge-primary,.mge-root .mge-secondary{min-height:37px;padding:8px 12px}.mge-level-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.mge-modal{padding:14px}.mge-modal h3{font-size:20px!important}}
@media(max-width:420px){.mge-logo{font-size:11px;letter-spacing:.4px;gap:5px}.mge-logo-icon{font-size:18px}.mge-hud-group:nth-child(3){display:none}.mge-menu h2{font-size:30px!important}.mge-eyebrow{font-size:8px;letter-spacing:1.5px}.mge-menu p{font-size:11px}.mge-bottom>span:first-child{font-size:8px}.mge-bottom button{font-size:9px}}
.mge-root:fullscreen{max-width:none;border-radius:0;display:flex;flex-direction:column;justify-content:center;background:#10152e}.mge-root:fullscreen .mge-stage-wrap{width:min(100vw,calc((100vh - 130px)*16/9));margin:auto}.mge-root:fullscreen .mge-bottom{width:100%}
