:root{font-family:ui-rounded,"Arial Rounded MT Bold",system-ui,sans-serif;color:#ecf5df;background:#173e3d;letter-spacing:0;color-scheme:dark}
*{box-sizing:border-box}html,body{margin:0;height:100%;width:100%;overflow:hidden;overscroll-behavior:none}button,select{font:inherit}button{border:0;cursor:pointer;color:inherit;touch-action:manipulation;-webkit-tap-highlight-color:transparent}button:disabled{opacity:.4;cursor:default}button:focus-visible,select:focus-visible{outline:3px solid #f9d365;outline-offset:2px}svg{width:26px;height:26px;pointer-events:none;flex-shrink:0}canvas{display:block;user-select:none;-webkit-user-select:none}button>*{pointer-events:none}[hidden]{display:none!important}
#adventure{height:100dvh;max-width:1000px;margin:auto;display:grid;grid-template-rows:auto minmax(0,1fr) auto;background:#24554b}header{display:flex;align-items:center;gap:9px;padding:calc(env(safe-area-inset-top,0px) + 9px) 12px 9px;min-height:65px;background:#173e3d;border-bottom:2px solid #bca65b}header>canvas{width:42px;height:42px}.brand{flex:1;min-width:0}.brand b{display:block;font-size:14px;line-height:1.4}.brand span{font-size:10px;color:#bed6bd}.purse{display:flex;align-items:center;gap:6px;font-size:17px;font-variant-numeric:tabular-nums}.purse>span{color:#f5ce63}.square{display:grid;place-items:center;width:44px;height:44px;border-radius:6px;background:#ffffff10;flex-shrink:0}
#field{position:relative;min-height:0;overflow:hidden}#world{position:absolute;inset:0;width:100%;height:100%;touch-action:none;outline:0}#toast{position:absolute;left:20px;right:20px;top:16px;margin:auto;max-width:360px;background:#173e3df2;border:1px solid #f0d57b;color:#fff4c7;border-radius:6px;padding:12px 16px;font-size:14px;text-align:center;pointer-events:none;box-shadow:0 4px 14px #153d3b44}#context{position:absolute;left:50%;bottom:20px;transform:translateX(-50%);display:flex;align-items:center;justify-content:center;gap:10px;min-height:54px;min-width:150px;border-radius:7px;background:#ffdc75;color:#294b43;border-bottom:4px solid #b4913f;font-weight:800;box-shadow:0 4px 14px #153d3b44}#campSeals{position:absolute;top:10px;right:10px;display:flex;gap:4px;pointer-events:none}#campSeals>span{display:grid;place-items:center;width:26px;height:27px;border-radius:4px;background:#173e3d99;color:#b7cbb6;border:1px solid #ffffff44}#campSeals>span.found{color:#ffe187;background:#205b4b}
footer{background:#173e3d;border-top:2px solid #bca65b;padding:5px 10px calc(7px + env(safe-area-inset-bottom,0px))}#health{display:flex;justify-content:center;gap:10px;max-width:500px;margin:auto;height:44px}.health-bot{display:flex;align-items:center;gap:4px;flex:1;min-width:0;max-width:125px}.health-bot canvas{width:36px;height:40px;flex-shrink:0}.health-track{height:8px;background:#092d30;border-radius:3px;overflow:hidden;flex:1}.health-track>i{display:block;height:100%;background:#8fe0a5}.health-bot.hurt .health-track>i{background:#f2c86a}.health-bot.critical .health-track>i{background:#ff8e74}nav{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));max-width:540px;margin:auto;gap:6px}nav button{height:54px;display:flex;align-items:center;justify-content:center;gap:5px;background:transparent;border-radius:6px;color:#cbe0d0}nav #utility{background:#f7cd62;border-bottom:4px solid #b2923a;color:#234c41}nav #utility b{font-size:15px}nav button.active{background:#2d5f50}nav svg{width:28px;height:28px}
dialog{padding:0;width:min(520px,calc(100% - 20px));max-height:calc(100dvh - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px) - 32px);border:1px solid #799d86;border-radius:8px;background:#ecf1e4;color:#284b46;overflow:auto;box-shadow:0 15px 80px #0d252e88}dialog::backdrop{background:#102e37bb;backdrop-filter:blur(4px)}.panel-head{position:sticky;top:0;z-index:2;display:flex;align-items:center;gap:8px;padding:12px 14px;background:#ecf1e4;border-bottom:1px solid #b8cdb7}.panel-head h1{font-size:20px;line-height:1.3;flex:1;margin:0}.panel-head .square{background:#d6e2ce}#panelBody{padding:14px}#panelBody h2{font-size:13px;margin:16px 0 8px}#panelBody p{font-size:13px;line-height:1.6}.row{display:flex;gap:8px}.wide{width:100%;min-height:52px;border-radius:6px;background:#1e7765;border-bottom:4px solid #155849;color:#fff5cc;display:flex;align-items:center;justify-content:center;gap:9px;font-weight:800;margin-top:12px}.quiet{background:#d6e4d2;border-bottom-color:#b2c8ae;color:#365949}.slot-row{display:grid;grid-template-columns:repeat(var(--slots,3),minmax(0,1fr));gap:6px}.slot{position:relative;background:#dae6d4;border:2px solid transparent;border-radius:6px;height:78px;padding:0;min-width:0}.slot.selected,.choice.selected{border-color:#167f72;background:#d0efce}.slot canvas{height:100%;width:100%}.slot .star{position:absolute;top:1px;right:5px;color:#a47a1d;font-size:14px}.preview{height:160px;width:100%;background:#dce6d4;margin:10px 0;border-radius:6px}.choices{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px}.choices.shields{grid-template-columns:repeat(3,minmax(0,1fr))}.choice{background:#fffdf2;border:2px solid #bfcfba;border-radius:6px;padding:3px;min-width:0;min-height:78px;display:flex;flex-direction:column;align-items:center;justify-content:center;color:#31564b}.choice canvas{width:58px;height:56px;max-width:100%}.choice small{font-size:10px;line-height:1.5}.choice svg{width:34px;height:34px;margin:6px}.choice:disabled{filter:grayscale(1)}.upgrades{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.upgrade{background:#dae8d4;border:1px solid #b3c9ac;border-radius:6px;min-height:88px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:5px;color:#35534b}.upgrade svg{width:30px;height:30px}.upgrade small{font-size:10px}.upgrade b{font-size:14px}.tiers{display:flex;gap:4px}.tiers i{width:9px;height:9px;border-radius:50%;background:#c2cabb}.tiers i.lit{background:#b98b37;border:1px solid #705c32}label.setting{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:55px;font-size:13px}select{max-width:65%;min-height:42px;background:#fffdf2;color:#284b46;border:1px solid #a4bfa5;border-radius:5px;padding:7px}input[type=checkbox]{width:24px;height:24px;accent-color:#247c63}.build{font-size:10px!important;color:#789781}.atlas{width:100%;height:440px;max-height:57dvh;background:#193d3c;border-radius:6px;touch-action:none}.red{color:#a53f42}.seal-row{display:flex;justify-content:center;gap:18px;font-size:32px;padding:20px;color:#bd8b2e}
@media(max-height:740px){header{min-height:58px;padding-bottom:5px}.preview{height:130px}nav button{height:48px}#health{height:39px}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}}
#panelBody h2{display:flex;align-items:center;gap:7px}#panelBody h2 svg{width:21px;height:21px}.seal-row button{width:54px;height:50px;display:grid;place-items:center;background:#d6e4d2;border-radius:6px;color:#365949}
nav #utility.cooldown{background:#879c84;border-bottom-color:#627d6b;color:#edf0dd}
.upgrade:disabled:has(.tiers i:last-child.lit){opacity:1;background:#ecdfb5;border-color:#b69b55;color:#735a2e}
#campSeals.trial-progress{display:grid;grid-template-columns:repeat(5,8px);gap:5px;background:#173e3da8;padding:7px;border-radius:5px}#campSeals.trial-progress i{width:8px;height:8px;border-radius:50%;background:#83978a;border:1px solid #d4dfbe}#campSeals.trial-progress i.won{background:#ffda73;border-color:#ffe8a6}
.seal-row{gap:8px;padding:14px 0}.seal-row button{flex:1;max-width:64px;min-width:0;height:62px;padding:6px}.seal-row small{font-size:11px;line-height:1.4;font-variant-numeric:tabular-nums}
.seal-row>span{display:grid;place-items:center;gap:4px;min-width:44px;font-size:12px;color:#365949}
.atlas-tools{display:flex;justify-content:flex-end;margin-bottom:8px}.atlas-tools .square{background:#d6e2ce;color:#31574f}
.brand b{display:none}.brand span{font-size:11px}#context{min-width:64px;width:64px;height:60px}#context svg{width:34px;height:34px}#toast{left:50%;right:auto;transform:translateX(-50%);width:64px;height:60px;display:grid;place-items:center;padding:8px}#toast svg{width:34px;height:34px}.choice small,.upgrade small{display:none}.panel-head h1 svg{width:30px;height:30px}.wide svg{width:30px;height:30px}
#toast.warning{width:calc(100% - 40px);height:auto;min-height:60px;padding:12px 16px}
#campSeals.quest-progress{display:flex;align-items:center;gap:5px;max-width:140px;padding:5px;background:#173e3dcc;border:1px solid #f2d48788;border-radius:5px}#questMark{width:30px;height:30px}.quest-dots{display:grid;grid-template-columns:repeat(7,7px);gap:4px}.quest-dots i{width:7px;height:7px;border-radius:50%;background:#728d80;border:1px solid #cde0bc}.quest-dots i.won{background:#ffda73;border-color:#fff0c2}
nav{grid-template-columns:repeat(4,minmax(0,1fr))}.world-board{width:100%;height:auto;aspect-ratio:104/76;background:#d3e6cc;border-radius:6px;touch-action:pan-y}
.health-bot{border:1px solid transparent;border-radius:5px;padding:0 3px}.health-bot.controlled{border-color:#f5d474;background:#f5d47412}.health-bot.offline{opacity:.65}.health-bot.offline .health-track{background:repeating-linear-gradient(135deg,#61776f 0 3px,#294c47 3px 6px)}
.panel-head{flex-wrap:wrap}.panel-head h1{min-width:0}#panelMessage{flex-basis:100%;margin:0;padding:8px;background:#f8d9cf;color:#713740;border-radius:4px;font-size:13px;line-height:1.5}select:disabled{opacity:.6;cursor:default}
.wide.danger{position:relative;overflow:hidden;background:#a73f50;border-bottom-color:#783443;color:#fff4dc;touch-action:none;user-select:none;-webkit-user-select:none}.danger.holding::after{content:"";position:absolute;left:0;bottom:0;height:5px;background:#ffdf88;animation:restart-hold 2s linear forwards}@keyframes restart-hold{from{width:0}to{width:100%}}
nav{grid-template-columns:repeat(5,minmax(0,1fr))}#completion{display:grid;place-items:center;width:36px;height:38px;border:1px solid #e5ca72;border-radius:5px;color:#d7ffcc;background:#276c51;flex-shrink:0}#completion svg{width:29px;height:29px}#atlas.completed{background:#386c51;color:#ffe18b;box-shadow:inset 0 0 0 1px #d8bf6a}
.local-map-tools{display:flex;justify-content:flex-end;gap:7px;margin-bottom:10px}.local-map-tools button{background:#d6e4d2;color:#31574f}.local-atlas{display:block;width:100%;height:min(59dvh,540px);border-radius:6px;background:#183f42;touch-action:none;cursor:grab}.local-atlas.city{height:230px;max-height:52dvh}.local-atlas:active{cursor:grabbing}.map-key{display:flex;align-items:center;justify-content:center;gap:20px;margin-top:12px;color:#326455}.map-key>span{display:grid;place-items:center;width:32px;height:32px}
@keyframes scene-arrival{from{opacity:.2}to{opacity:1}}#field.scene-arrival{animation:scene-arrival .32s ease-out}@media(prefers-reduced-motion:reduce){#field.scene-arrival{animation:none}}

.save-transfer{margin-top:22px;padding-top:16px;border-top:1px solid #839f943f}.save-transfer h2{font-size:18px}.save-transfer p{font-size:14px;line-height:1.5;overflow-wrap:anywhere}.transfer-confirm{padding:12px;border:1px solid #c7a649;border-radius:8px}.transfer-confirm button{margin-top:8px}.transfer-status:empty{display:none}
