/* System fonts keep the game fully self-contained. */
:root{--ink:#233c32;--muted:#7b8575;--paper:#f7f5eb;--line:#dedfd1;--green:#2d674c;--lime:#d5ec8b;
/* Shared visual language: a dark pond surround framing warm cover-paper panels. */
--font-ui:'Noto Sans SC','PingFang SC','Microsoft YaHei','Hiragino Sans GB',system-ui,sans-serif;
--night:#141d1c;--night-2:#1d2a28;--night-3:#2a3a36;--night-line:#4f6459;
--cream:#fdf6e1;--cream-2:#f4e8c6;--cream-3:#e6d6a8;--ink-2:#3b5244;--ink-3:#5a6b52;
--leaf:#3c6b45;--leaf-dark:#21402b;--leaf-light:#93b86d;
--gold:#f4c64f;--gold-dark:#9a6c1c;--gold-light:#ffe7a1;
--coral:#ee6b5d;--coral-dark:#8f3434;--plum:#7a5a8c;--sky:#8fc9dc;
--hud-text:#fff3d1;--hud-muted:#c9d4c2;--frame-dark:#0b1211;--focus:#ffcf4a}*{box-sizing:border-box}body{margin:0;background:var(--paper);color:var(--ink);font:14px var(--font-ui)}.shell{max-width:1500px;margin:auto;padding:0 42px}header{height:100px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line)}button,a{-webkit-tap-highlight-color:transparent}button{font:inherit;cursor:pointer;color:inherit}button:focus-visible,a:focus-visible,input:focus-visible{outline:3px solid var(--focus);outline-offset:3px}button:hover{filter:brightness(.94)}.brand{display:flex;align-items:center;gap:14px;text-decoration:none;color:var(--ink);font-size:22px;font-weight:900;letter-spacing:1px}.brand small{display:block;font-size:9px;letter-spacing:2px;margin-top:4px;font-weight:600}.brand-face{display:grid;place-items:center;width:48px;height:44px;border-radius:17px 17px 22px 22px;background:#f4d974;border:2px solid #354c35;font-size:23px;letter-spacing:-3px}.header-right{display:flex;align-items:center;gap:12px}.edition{font-size:11px;letter-spacing:2px;color:var(--muted);margin-right:18px}.header-right button{background:transparent;border:1px solid var(--line);border-radius:24px;padding:9px 16px;font-size:12px}main{display:grid;grid-template-columns:minmax(0,1fr) 252px;gap:28px;padding:35px 0}.game-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:24px}.eyebrow{font-size:9px;font-weight:700;letter-spacing:2.3px;color:#879178}h1{font-size:30px;letter-spacing:-1px;margin:8px 0 0;font-weight:900}.live-tag{font-size:11px;color:#537052;border:1px solid #d8e0c8;border-radius:20px;padding:7px 12px}.live-tag i{display:inline-block;width:6px;height:6px;background:#7eaa57;border-radius:50%;margin-right:7px}.game-frame{border:7px solid #243e35;border-radius:17px;overflow:hidden;box-shadow:0 14px 25px #233c3214;background:#243e35}.hud{height:66px;display:flex;align-items:center;justify-content:space-between;padding:4px 20px 10px;color:#f6f6e6}.hud-label{font-size:9px;letter-spacing:1px;color:#a5b6a1}#hearts{font-size:20px;letter-spacing:3px;color:#f39887}.room-label{text-align:center;display:flex;flex-direction:column;gap:4px}.room-label strong{font-size:12px;font-weight:600;letter-spacing:1px}.room-label span{font-size:10px;color:#b3c1a8}#pause{background:#ffffff0a;border:1px solid #ffffff25;border-radius:9px;color:#e5ebcc;font-size:20px;width:36px;height:36px}.canvas-wrap{position:relative;overflow:hidden;background:#759174}canvas{width:100%;display:block;outline:none;touch-action:none;aspect-ratio:8/5}.game-footer{min-height:39px;display:flex;justify-content:space-between;align-items:center;padding:6px 12px;color:#b3c2a6;font-size:9px}.game-footer b{font-size:13px;color:#e7efcc;margin-right:5px}.key-guide{display:flex;justify-content:center;gap:22px;margin-top:24px;flex-wrap:wrap;font-size:10px;color:#727d6a}.key-guide span{display:flex;align-items:center;gap:3px}kbd{display:inline-block;min-width:19px;height:21px;text-align:center;border:1px solid #d9ddce;border-bottom:2px solid #c9cfbd;border-radius:4px;padding:2px 4px;color:#5a6852;background:#fffef6;font:10px monospace}.footnote{text-align:center;font-size:10px;color:#969e8b;margin-top:18px;letter-spacing:1px}aside{padding-top:6px;display:flex;flex-direction:column;gap:16px}.panel{border:1px solid var(--line);border-radius:13px;padding:19px;background:#fdfcf5}.panel-title{display:flex;justify-content:space-between;align-items:center;margin-bottom:18px}.panel-title h2{font-size:13px;margin:0;font-weight:800}.panel-title>span{font-size:10px;color:#8e9881}.map{width:140px;display:grid;grid-template-columns:repeat(3,1fr);gap:7px;margin:23px auto}.map-cell{height:34px;border-radius:5px;display:grid;place-items:center;background:#eceee3;color:#b7bfaa;border:1px solid #e0e4d6;font-size:15px}.map-cell.visited{background:#cbd6bc;color:#718565}.map-cell.here{background:#41674d;color:#f1f5d7;border:2px solid #c1da92;box-shadow:0 0 0 2px #41674d}.map-cell.reward{color:#a58233}.map-cell.king{color:#a36e5d}.map-legend{display:flex;justify-content:center;gap:15px;font-size:9px;color:#8b947e}.map-legend i{width:6px;height:6px;display:inline-block;border-radius:2px;margin-right:4px}.current{background:#41674d}.treasure{background:#d8b861}.boss{background:#c38972}.map-panel>p{font-size:10px;text-align:center;color:#939b86;margin:17px 0 0}.empty-bag{text-align:center;font-size:35px;color:#b6c1a1;padding:2px 0}.empty-bag p{font-size:10px;line-height:1.9;color:#949b87;margin:6px 0}.inventory{max-height:218px;overflow:auto}.item-row{display:flex;gap:10px;align-items:center;margin-top:12px}.item-icon{width:34px;height:34px;border-radius:9px;background:#ebeedc;display:grid;place-items:center;font-size:20px}.item-row strong{font-size:11px}.item-row small{display:block;font-size:9px;color:#8d967f;margin-top:3px}.stat{display:flex;justify-content:space-between;padding:8px 0;font-size:11px;color:#859078}.stat strong{color:#516449;font-size:12px}.note{padding:16px 20px;background:#e9eddb;border-radius:3px 3px 24px 3px;position:relative;transform:rotate(-1deg)}.note>span{font-size:9px;letter-spacing:2px;color:#8b9776}.note p{font-size:12px;line-height:1.9}.note>div{position:absolute;right:17px;bottom:18px;color:#8a9b68;font-size:24px}footer{border-top:1px solid var(--line);padding:22px 0;display:flex;justify-content:space-between;color:#929b86;font-size:10px;letter-spacing:.5px}footer b{margin:0 10px}.overlay{position:absolute;inset:0;background:#1d342a55;backdrop-filter:blur(3px);display:flex;align-items:center;justify-content:center;padding:22px;z-index:5}.overlay:empty{display:none}.modal{position:relative;width:450px;max-width:100%;background:#fbfaed;border:1px solid #fff9;border-radius:21px;padding:28px;text-align:center;box-shadow:0 20px 60px #142b3050}.modal .mini{font-size:9px;letter-spacing:3px;color:#8c9879}.modal h2{font-size:29px;font-weight:900;margin:8px 0 12px}.modal p{font-size:12px;line-height:1.9;color:#7b896b}.modal .primary{display:block;margin:18px auto 0;background:#365f44;color:#f5f7e5;border:0;border-radius:11px;padding:13px 33px;font-weight:700;min-width:190px;box-shadow:0 4px 0 #244932}.modal .secondary{background:none;border:0;text-decoration:underline;font-size:11px;margin-top:16px;color:#8b967b}.hero-frog{width:120px;height:100px;margin:-5px auto 5px}.toast{position:absolute;left:50%;bottom:20px;transform:translate(-50%,20px);opacity:0;background:#f8f9e8;color:#3d5735;border-radius:9px;padding:10px 20px;pointer-events:none;transition:.2s;font-size:12px;white-space:nowrap;z-index:8}.toast.show{opacity:1;transform:translate(-50%,0)}.choice-list{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;margin-top:18px}.choice{padding:14px 7px;border:1px solid #d8dfc7;background:#f1f3e6;border-radius:12px;min-height:145px}.choice>span{font-size:29px}.choice strong{display:block;font-size:12px;margin:9px 0}.choice small{font-size:10px;line-height:1.7;color:#788667}.bossbar{position:absolute;left:25%;right:25%;top:15px;pointer-events:none;text-align:center;color:#f7eed5;font-size:11px}.bossbar>div{height:7px;margin-top:5px;background:#253d31;border-radius:9px;overflow:hidden}.bossbar i{display:block;background:#dc8d73;height:100%;width:100%;transition:width .1s}.mobile-controls{display:none}.instructions{font-size:12px;line-height:2;color:#627459;text-align:left;padding-left:15px}.instructions b{color:#294d35}.modal .result-number{font-size:45px;color:#52744a;font-weight:900}@media(min-width:1600px){.shell{max-width:1600px}}@media(max-width:1100px){.shell{padding:0 24px}main{gap:18px;grid-template-columns:minmax(0,1fr) 220px}h1{font-size:25px}.key-guide{gap:12px}.edition{display:none}#tip{display:none}.panel{padding:16px}.game-heading{margin-bottom:20px}.modal{padding:20px}.hero-frog{height:75px;width:90px}.modal h2{font-size:24px}}@media(max-width:780px){.shell{padding:0 14px}header{height:77px}.brand{font-size:18px;gap:9px}.brand-face{width:38px;height:36px;font-size:19px}.brand small{font-size:7px}.header-right{gap:5px}.header-right button{padding:7px 10px;font-size:10px}main{display:block;padding-top:22px}h1{font-size:24px}.eyebrow{font-size:7px}.live-tag{font-size:9px}.game-frame{border-width:4px;border-radius:12px}.hud{height:57px;padding:4px 12px 8px}#hearts{font-size:16px;letter-spacing:1px}.room-label strong{font-size:10px}.room-label span{font-size:8px}.game-footer{font-size:8px;padding:5px 8px}aside{display:grid;grid-template-columns:1fr 1fr;margin-top:20px}.stats-panel,.note{display:none}.panel{padding:14px}.map{margin:10px auto;width:115px;gap:5px}.map-cell{height:26px}.map-panel>p{font-size:9px}.key-guide{display:none}.mobile-controls{display:flex;justify-content:space-between;align-items:center;padding:20px 17px 0;touch-action:none;user-select:none}#stick{height:100px;width:100px;border-radius:50%;border:1px solid #c9d2b8;background:#e7ecda;position:relative;touch-action:none}#stick span{position:absolute;width:45px;height:45px;border-radius:50%;background:#65815a;top:27px;left:27px;box-shadow:0 4px 8px #29432a22;pointer-events:none}#stick em{position:absolute;inset:0;display:grid;place-items:center;font-size:9px;color:#f8faeb;pointer-events:none;font-style:normal}.touch-actions{display:flex;align-items:center;gap:16px}.touch-actions button{border:1px solid #a6b68d;border-radius:50%;background:#dce9bd;height:75px;width:75px;font-weight:700;touch-action:none}#touchDash{width:55px;height:55px;background:#f4e5ad;font-size:11px}.modal{padding:16px}.modal h2{font-size:21px;margin:4px 0 7px}.modal p{font-size:10px;margin:6px 0}.modal .primary{padding:10px 20px;margin-top:10px}.hero-frog{width:75px;height:60px}.modal .mini{font-size:7px}.overlay{padding:10px}.choice{padding:8px 4px;min-height:110px}.choice>span{font-size:21px}.choice strong{font-size:10px}.choice small{font-size:9px}.choice-list{margin-top:9px;gap:5px}.instructions{font-size:10px;line-height:1.8;margin:5px 0}.footnote{font-size:8px}footer{font-size:8px;gap:20px}.toast{font-size:10px;padding:7px 10px;bottom:10px}.panel-title{margin-bottom:8px}.inventory{max-height:160px}}@media(prefers-reduced-motion:reduce){*{transition:none!important}.note{transform:none}}
@media(max-width:780px){.overlay{position:fixed;z-index:30;padding:22px;background:#20372c99}.modal{max-height:90dvh;overflow:auto}.live-tag{white-space:nowrap}.game-heading{gap:12px}.hero-frog{width:100px;height:82px}.modal h2{font-size:25px}.modal p{font-size:12px}.choice{min-height:150px}.choice strong{font-size:12px}.choice small{font-size:11px}.instructions{font-size:12px;line-height:1.9}}
.stats-panel{border-color:#c2d0ae;background:#f6f8ec;order:-1}.stats-panel .panel-title{margin-bottom:10px}.stats-panel .panel-title>span{color:#658153;font-size:9px}.stats-panel .stat{gap:10px;align-items:center;padding:7px 0}.stats-panel strong{font-variant-numeric:tabular-nums;text-align:right}.ability-row{margin:5px 0 10px}.ability-row progress{display:block;width:100%;height:5px;appearance:none;border:0;border-radius:9px;overflow:hidden;background:#e0e6d3}.ability-row progress::-webkit-progress-bar{background:#e0e6d3}.ability-row progress::-webkit-progress-value{background:#83a363;border-radius:9px}.ability-row progress::-moz-progress-bar{background:#83a363}.stats-panel [data-ready=true]{color:#347448}.stats-panel [data-low=true]{color:#ba6554}.active-effects{border-top:1px solid #dde5ce;margin-top:10px;padding-top:12px}.active-effects>span{font-size:10px;color:#89967b}.active-effects p{font-size:11px;line-height:1.8;margin:6px 0 0;color:#4c7046}@media(max-width:780px){.stats-panel{display:block;grid-column:1/-1}.stats-grid{display:grid;grid-template-columns:1fr 1fr;column-gap:22px}.stats-panel .stat{font-size:11px}.stats-panel .panel-title h2{font-size:14px}.stats-panel .ability-row{margin:7px 0 12px}.stats-panel .active-effects{padding-top:8px}}

.map{grid-template-columns:repeat(5,1fr);width:100%;gap:4px}.map-cell{height:27px}.map-cell.fog{visibility:hidden}.resources{padding:10px 14px;margin-bottom:9px;border-radius:9px;background:#e8edda;color:#4e6545;font:600 12px system-ui;font-variant-numeric:tabular-nums}.action-guide{display:flex;justify-content:center;gap:8px;margin-top:14px;flex-wrap:wrap}.action-guide button{border:1px solid #cbd6bb;border-radius:8px;background:#eef1df;padding:9px 13px;touch-action:none;font-size:11px}@media(max-width:780px){.resources{font-size:10px;padding:9px 8px}.action-guide{gap:6px}.action-guide button{padding:12px 10px}.map{width:100%}.map-cell{height:23px}}
.modal{max-height:calc(100% - 20px);overflow:auto}
