:root{color-scheme:light;--paper:#f2edde;--ivory:#fffaf0;--ink:#263d34;--muted:#596553;--line:#c4c8b2;--wood:#315b43;--fire:#9f3f28;--people:#354f68;--red:#a53e2d;--gold:#8a5b18;font-family:"PingFang SC","Microsoft YaHei",system-ui,sans-serif;font-synthesis:none}
*{box-sizing:border-box}html,body{margin:0;width:100%;height:100%;overflow:hidden}body{background:#e6e5d6;color:var(--ink);-webkit-tap-highlight-color:transparent}button,select,a{touch-action:manipulation}button,select{font:inherit;color:inherit}button{cursor:pointer}button:disabled{cursor:default}button:focus-visible,a:focus-visible,select:focus-visible{outline:3px solid var(--gold);outline-offset:3px}button{border:1px solid var(--line);border-radius:5px;background:var(--ivory)}button[hidden],[hidden]{display:none!important}.sr-only{position:absolute;width:1px;height:1px;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.battle-app{height:100dvh;max-width:1440px;margin:auto;padding:12px 24px 20px;display:flex;flex-direction:column;gap:12px;background:var(--paper);background-image:radial-gradient(#5361440c .8px,transparent .8px);background-size:5px 5px;overflow:hidden}.battle-app.is-expanded{position:fixed;inset:0;z-index:1000;max-width:none;width:100%;height:100dvh}.battle-app:fullscreen{max-width:none}.topbar{display:flex;align-items:center;justify-content:space-between;min-height:56px;gap:12px}.back-link{color:var(--muted);text-decoration:none;display:flex;align-items:center;min-height:44px;font-size:13px;gap:7px}.brand{display:flex;align-items:center;gap:10px}.seal{background:var(--red);color:var(--ivory);font-family:serif;font-size:30px;width:40px;height:42px;display:grid;place-items:center;transform:rotate(-3deg);border-radius:3px 6px 3px 2px;box-shadow:inset 0 0 0 3px var(--red),inset 0 0 0 4px #fffaf080}.brand h1{font-family:"Songti SC","Noto Serif CJK SC",serif;font-size:26px;letter-spacing:4px;line-height:1.2;margin:0}.brand-en{font-size:8px;letter-spacing:3px;color:var(--muted)}.fullscreen{font-size:12px;min-height:44px;padding:5px 12px;border-color:#b6bea9;background:transparent}.game-layout{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(300px,1fr);gap:24px;flex:1;min-height:0}.battlefield{display:flex;flex-direction:column;min-height:0;border:1px solid #b2bea6;border-radius:9px;background:#e1e6d5;overflow:hidden;box-shadow:0 8px 24px #344d3610}.field-top{display:flex;align-items:center;justify-content:space-between;padding:18px 23px;gap:12px;border-bottom:1px solid #b3bea5;background:#e7eadb}.chapter{font-size:10px;letter-spacing:3px;color:var(--muted)}.field-top h2{font-family:serif;letter-spacing:2px;margin:5px 0 0;font-size:23px}.round-chip{border-left:1px solid #adbba0;padding-left:15px;display:grid;gap:5px;text-align:center}.round-chip span{font-size:10px;color:var(--muted)}.round-chip b{font-size:16px;letter-spacing:2px}.ink-scene{position:relative;flex:1;min-height:0;isolation:isolate;overflow:hidden;background:linear-gradient(#e1e6d5,#d1dcc4 85%)}.landscape{position:absolute;inset:0;width:100%;height:100%;z-index:-2}.field-calligraphy{position:absolute;left:25px;top:35px;display:flex;gap:3px;opacity:.43;z-index:-1}.field-calligraphy span{writing-mode:vertical-rl;font:32px/1.1 "Songti SC",serif;letter-spacing:6px}.field-calligraphy span:nth-child(2){padding-top:30px}.field-calligraphy i{writing-mode:vertical-rl;font:10px/1 sans-serif;letter-spacing:3px;padding-top:6px}.lane-labels{display:grid;grid-template-columns:repeat(3,1fr);position:absolute;top:13px;left:8%;right:8%;font-size:10px;color:#4e6048;text-align:center}.lanes{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));position:absolute;left:8%;right:8%;top:40px;bottom:68px}.lane{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:space-between;padding:16px 5px 8px;border-right:1px dashed #71886a38}.lane:last-child{border:0}.lane::before{content:"";position:absolute;top:0;bottom:0;left:50%;border-left:1px solid #8c9d7e22;z-index:-1}.enemy{position:relative;display:flex;align-items:center;flex-direction:column;min-width:80px;max-width:110px}.monster{position:relative;width:65px;height:61px;border-radius:45% 48% 37% 41%;background:#293b32;box-shadow:0 7px 0 -3px #1c2e26,0 14px 15px -9px #1c2e2666;transform:rotate(-4deg);display:grid;place-items:center}.monster::before,.monster::after{content:"";position:absolute;top:-10px;width:23px;height:28px;background:#293b32;clip-path:polygon(0 0,100% 100%,0 75%)}.monster::before{left:1px;transform:rotate(-16deg)}.monster::after{right:1px;transform:scaleX(-1) rotate(-16deg)}.monster-eyes{display:flex;gap:12px;transform:rotate(4deg);z-index:1}.monster-eyes i{width:13px;height:5px;background:#f6eab8;transform:rotate(20deg);box-shadow:0 1px 4px #fae48c80}.monster-eyes i+i{transform:rotate(-20deg)}.monster-mark{position:absolute;bottom:6px;font:14px serif;color:#c0cab6;opacity:.8}.enemy-name{font-size:10px;margin-top:9px;color:#354e3c;font-weight:600}.hp-track{height:4px;background:#adb89e;width:65px;margin-top:5px;border-radius:3px;overflow:hidden}.hp-track i{display:block;height:100%;background:#a34532;transition:width .25s}.hp-text{font-size:10px;font-variant-numeric:tabular-nums;line-height:1.7;color:#3a4f3d}.hp-text small{font-size:9px;margin-left:5px}.enemy-empty{height:108px;display:grid;place-items:center;color:#53654b;font:22px serif}.army-slot{position:relative;width:91px;min-height:112px;padding:8px 6px 5px;border:1px dashed #778c6c;border-radius:8px;background:#e8eddc55;display:flex;flex-direction:column;align-items:center;justify-content:center;box-shadow:0 8px 0 -4px #637b5530;transition:transform .15s,background .2s}.army-slot:not(:disabled):hover{background:#f2f1dd}.army-slot.empty{color:#53694b}.slot-plus{font:31px/1 serif;font-weight:200}.slot-copy{font-size:10px;margin-top:6px}.army-slot.deploy-target{border:2px dashed var(--gold);background:#f8edc4}.army-slot.occupied{border-style:solid;background:var(--ivory);box-shadow:0 5px 0 #bdc8ab,0 7px 12px #273a2622}.unit-glyph{font-family:"Songti SC","Noto Serif CJK SC",serif;font-size:44px;line-height:1.05;font-weight:800}.wood{color:var(--wood)}.fire{color:var(--fire)}.people{color:var(--people)}.army-slot .unit-role{font-size:9px;letter-spacing:2px;margin-top:3px}.army-slot .hp-track{width:60px;margin-top:6px}.army-slot .hp-track i{background:#47724e}.army-slot .hp-text{font-size:9px}.army-slot .unit-stats{font-size:9px;margin-top:4px;white-space:nowrap}.army-slot.occupied::before{content:"";position:absolute;left:6px;top:-7px;border-left:2px solid currentColor;height:22px}.army-slot.occupied::after{content:"";position:absolute;left:8px;top:-7px;width:21px;height:11px;background:currentColor;clip-path:polygon(0 0,100% 0,75% 50%,100% 100%,0 100%)}.army-slot:disabled{opacity:1}.army-slot.empty:disabled{opacity:.55}.gate{height:53px;position:absolute;bottom:4px;left:9%;right:9%;display:flex;align-items:center;gap:12px;border-top:1px solid #87987480;background:linear-gradient(transparent,#bdcaa875);padding:5px 12px}.gate-icon{display:block;position:relative;width:39px;height:34px;background:#6d805a;clip-path:polygon(0 0,18% 0,18% 13%,40% 13%,40% 0,60% 0,60% 13%,82% 13%,82% 0,100% 0,100% 100%,0 100%)}.gate-icon i{position:absolute;bottom:0;left:13px;width:14px;height:21px;background:#d2dcc3;border-radius:9px 9px 0 0}.gate-copy{flex:1;font-size:10px;color:#354e3c;letter-spacing:2px}.gate-track{margin-top:5px;height:5px;border-radius:3px;background:#9ba987;overflow:hidden}.gate-track i{display:block;height:100%;background:var(--wood);transition:width .25s}.gate strong{font-size:12px;font-variant-numeric:tabular-nums;white-space:nowrap}.field-foot{display:flex;justify-content:space-between;align-items:center;gap:8px;min-height:42px;padding:8px 18px;font-size:11px;color:#495d40;background:#e7eadb;border-top:1px solid #b7c1a9}.field-foot #progress{white-space:nowrap;font-size:10px}.workshop{min-height:0;display:flex;flex-direction:column;padding:8px 0 0;gap:12px}.workshop-head{display:flex;align-items:center;justify-content:space-between}.section-kicker{color:var(--red);font-size:10px;letter-spacing:3px}.workshop-head h2{font:28px/1.2 "Songti SC",serif;margin:7px 0 0;letter-spacing:3px}.icon-button{width:44px;height:44px;border-radius:50%;font:20px serif;background:transparent}.recipes{display:flex;gap:5px}.recipe{display:grid;grid-template-columns:17px 1fr;gap:3px;flex:1;border-bottom:1px solid #bdc4ae;padding-bottom:9px}.recipe>span{grid-row:1/3;font:13px/1.2 serif;align-self:center}.recipe b{font-size:9px;font-weight:500;white-space:nowrap;letter-spacing:.2px}.board-heading{display:flex;justify-content:space-between;align-items:center;gap:4px;font-size:10px;color:var(--muted)}.board-heading b{font-size:9px;font-weight:400;letter-spacing:0;margin-left:4px}.character-board{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));grid-template-rows:repeat(3,minmax(44px,1fr));gap:10px;flex:1;min-height:160px;max-height:350px}.character{position:relative;min-width:44px;min-height:44px;padding:8px 2px 7px;display:flex;flex-direction:column;align-items:center;justify-content:center;background:linear-gradient(115deg,#fffaf0,#f1ebd8);border:1px solid #c2bda7;border-radius:6px;box-shadow:0 4px 0 #d4cdb7,0 6px 8px #594a2a10;transition:transform .15s,box-shadow .15s}.character .unit-glyph{font-size:42px;line-height:1.1}.character .unit-role{font-size:9px;letter-spacing:1px;margin-top:4px}.character .rank{position:absolute;left:5px;top:3px;font-size:8px;letter-spacing:1px;color:#5d6651}.character:not(:disabled):hover{transform:translateY(-2px);box-shadow:0 6px 0 #d4cdb7,0 8px 11px #594a2a20}.character.selected{outline:2px solid var(--gold);outline-offset:1px;background:#fff3ce;transform:translateY(-3px);box-shadow:0 6px 0 #b99c5b}.character.matchable{outline:2px dashed #847030;outline-offset:1px}.character.matchable::after{content:"+";position:absolute;right:3px;top:1px;width:15px;height:15px;color:var(--ivory);background:var(--gold);border-radius:50%;font-size:12px;line-height:15px}.character.blank{border:1px dashed #c9c5b1;box-shadow:none;background:#e7e1ce55;color:#9a9d87;font:16px serif}.character:disabled:not(.blank){opacity:.75}.feedback{margin:0;min-height:32px;color:var(--muted);font-size:11px;line-height:1.5;display:flex;align-items:center}.main-action{display:flex;min-height:48px}.march{display:flex;align-items:center;justify-content:center;width:100%;height:48px;gap:18px;background:var(--red);border-color:var(--red);color:var(--ivory);box-shadow:0 3px 0 #7c2d20;font-size:16px;font-weight:600;letter-spacing:4px}.march i{font-style:normal;font-size:23px}.march:disabled{background:#53644e;border-color:#53644e;box-shadow:0 3px 0 #3a4e36;color:#fffaf0;font-size:12px;letter-spacing:2px}.controls{display:flex;gap:8px;align-items:center;min-height:44px}.controls>button{min-height:44px;min-width:80px;padding:5px 11px;background:transparent;border-color:#b6bea9;font-size:11px}.level-picker{position:relative;min-width:0;flex:1}.level-picker select{appearance:none;width:100%;height:44px;background:transparent;border:1px solid #b6bea9;border-radius:5px;padding:6px 27px 6px 10px;font-size:11px}.level-picker>span:last-child{position:absolute;right:10px;top:11px;pointer-events:none}.result{position:absolute;z-index:20;inset:0;display:flex;align-items:center;justify-content:center;flex-direction:column;text-align:center;background:#f2eddeee;backdrop-filter:blur(5px);padding:18px;gap:8px}.result-seal{display:grid;place-items:center;width:63px;height:68px;background:var(--red);color:var(--ivory);font:44px serif;transform:rotate(-4deg);border-radius:3px}.result p{margin:0;font-size:12px;line-height:1.5;max-width:300px}.result #result-eyebrow{font-size:10px;letter-spacing:4px;margin-top:7px;color:var(--muted)}.result h2{font:27px serif;letter-spacing:2px;margin:3px 0}.result>button{min-height:44px;min-width:150px;padding:8px 20px;margin-top:7px;background:var(--wood);color:var(--ivory);border-color:var(--wood);font-size:12px}.result>button.result-secondary{margin:0;background:transparent;color:var(--ink);border-color:#8a9a7b}.fx-layer{position:absolute;inset:0;pointer-events:none;z-index:8;overflow:hidden}.strike{position:absolute;height:3px;background:#b85a34;transform-origin:0 50%;box-shadow:0 0 8px #e4a454;border-radius:5px;animation:strike .35s ease-out both}.damage{position:absolute;font:bold 19px serif;color:#862f22;text-shadow:0 1px var(--ivory);animation:damage .65s ease-out both}.hit{animation:hit .35s ease}.attacking{animation:attack .4s ease}.fallen{animation:fall .45s ease-out both}.merge-ghost{position:fixed;pointer-events:none;z-index:99;margin:0;transition:transform .32s ease-in,opacity .32s;box-shadow:none!important}.merging{animation:merge .45s ease both}.gate-hit{animation:hit .35s ease}dialog{width:min(480px,calc(100% - 24px));max-height:calc(100dvh - 24px);overflow:auto;border:1px solid #acb79b;background:var(--paper);color:var(--ink);border-radius:12px;padding:22px;box-shadow:0 25px 90px #1b2e3b44}dialog::backdrop{background:#1b2e3b88;backdrop-filter:blur(3px)}.help-heading{display:flex;align-items:center;justify-content:space-between;gap:10px}.help-heading h2{font:25px serif;letter-spacing:2px}.help-heading button{width:44px;height:44px;font-size:25px}dialog p{font-size:13px;line-height:1.8}.unit-guide{display:flex;gap:10px}.unit-guide>div{flex:1;background:var(--ivory);text-align:center;padding:12px 4px;border-radius:7px}.unit-guide b{display:block;font:38px serif}.unit-guide span{font-size:12px}.unit-guide p{font-size:10px;line-height:1.6;margin:4px 0 0}.help-tip{color:var(--muted);border-top:1px solid var(--line);padding-top:12px}
@keyframes strike{from{opacity:0;scale:.2 1}40%{opacity:1}to{opacity:0;scale:1 1}}@keyframes damage{from{opacity:1;translate:0 0}to{opacity:0;translate:0 -24px}}@keyframes hit{20%,60%{translate:-3px 0;filter:brightness(1.4)}40%,80%{translate:3px 0}to{translate:0 0}}@keyframes attack{50%{translate:0 -10px;rotate:-4deg}}@keyframes fall{to{opacity:0;transform:scale(.65) rotate(15deg);filter:blur(3px)}}@keyframes merge{35%{transform:scale(.8);filter:brightness(1.6)}70%{transform:scale(1.08)}}
@media(min-width:1100px) and (min-height:650px){.battle-app{padding:20px 40px 28px;gap:20px}.game-layout{gap:35px}.workshop{gap:15px}.field-calligraphy{top:100px}.monster{width:80px;height:74px}.enemy-name{font-size:12px}.army-slot{width:110px;min-height:132px}.army-slot .unit-glyph{font-size:52px}.army-slot .unit-role{font-size:10px}.army-slot .hp-track{width:78px}.lanes{top:65px;bottom:90px}.gate{height:66px;bottom:7px}.character .unit-glyph{font-size:48px}}
@media(max-width:700px) and (orientation:portrait){.battle-app{padding:5px 12px max(7px,env(safe-area-inset-bottom));gap:7px}.topbar{min-height:44px;gap:6px}.back-link{font-size:11px}.brand{gap:6px}.seal{width:28px;height:31px;font-size:23px}.brand h1{font-size:20px;letter-spacing:2px}.brand-en{font-size:6px;letter-spacing:1px}.fullscreen{font-size:10px;padding:5px 7px}.game-layout{display:flex;flex-direction:column;gap:10px}.battlefield{flex:1;min-height:235px}.field-top{padding:7px 12px;min-height:48px}.chapter{font-size:8px;letter-spacing:2px}.field-top h2{font-size:16px;margin-top:2px}.round-chip{display:flex;align-items:center;gap:8px;padding-left:10px}.round-chip span{font-size:9px}.round-chip b{font-size:12px}.field-foot{min-height:25px;padding:4px 10px;font-size:9px}.field-foot #progress{font-size:8px}.field-calligraphy{left:10px;top:34px}.field-calligraphy span{font-size:23px;letter-spacing:3px}.field-calligraphy i{display:none}.lane-labels{top:7px;font-size:8px}.lanes{left:4%;right:4%;top:22px;bottom:43px}.lane{padding:7px 2px 3px}.enemy{min-width:55px}.monster{width:40px;height:35px}.monster::before,.monster::after{width:14px;height:17px;top:-6px}.monster-eyes{gap:6px}.monster-eyes i{width:8px;height:3px}.monster-mark{font-size:9px;bottom:3px}.enemy-name{font-size:8px;margin-top:5px}.enemy .hp-track{width:47px;height:3px;margin-top:3px}.hp-text{font-size:8px;line-height:1.4}.hp-text small{font-size:8px;margin-left:3px}.enemy-empty{height:60px;font-size:18px}.army-slot{width:68px;min-height:75px;padding:4px 2px 3px;border-radius:6px}.army-slot .unit-glyph{font-size:31px}.army-slot .unit-role{font-size:8px;letter-spacing:1px;margin-top:1px}.army-slot .unit-stats{font-size:8px;margin-top:2px}.army-slot .hp-track{width:46px;height:3px;margin-top:3px}.army-slot .hp-text{font-size:8px}.army-slot.occupied::before{left:5px;top:-4px;height:17px}.army-slot.occupied::after{left:7px;top:-4px;width:16px;height:8px}.slot-plus{font-size:26px}.slot-copy{font-size:9px}.gate{height:37px;bottom:1px;left:7%;right:7%;padding:3px 6px;gap:7px}.gate-icon{width:27px;height:26px}.gate-icon i{left:9px;width:10px;height:16px}.gate-copy{font-size:8px;letter-spacing:1px}.gate-track{margin-top:3px;height:4px}.gate strong{font-size:10px}.workshop{flex:none;padding:0;gap:8px}.workshop-head{display:none}.recipes{gap:7px}.recipe{padding-bottom:5px;gap:2px;grid-template-columns:12px 1fr}.recipe>span{font-size:11px}.recipe b{font-size:8px;letter-spacing:0}.board-heading{font-size:9px;min-height:14px}.board-heading b{font-size:8px}.character-board{flex:none;height:clamp(174px,25vh,240px);min-height:0;gap:7px}.character{padding:3px 1px}.character .unit-glyph{font-size:32px}.character .unit-role{font-size:8px;margin-top:0}.character .rank{font-size:7px;left:4px;top:2px}.feedback{min-height:26px;font-size:10px;line-height:1.3}.main-action{min-height:44px}.march{height:44px;font-size:14px}.controls{min-height:44px;gap:7px}.controls>button,.level-picker select{height:44px;min-height:44px;font-size:10px}.controls>button{min-width:76px}.result{gap:5px;padding:8px}.result-seal{width:40px;height:44px;font-size:30px}.result h2{font-size:21px}.result p{font-size:10px}.result #result-eyebrow{font-size:8px;margin-top:0}.result>button{min-height:44px;padding:5px 14px;margin-top:2px;font-size:10px}.result>button.result-secondary{position:absolute;right:7px;top:7px;min-width:70px;background:var(--paper)}#help-open{display:none}}
@media(max-width:700px) and (orientation:portrait) and (max-height:700px){.battle-app{padding:3px 9px 5px;gap:3px}.game-layout{gap:6px}.battlefield{min-height:220px}.field-top{min-height:39px;padding:4px 9px}.field-top h2{font-size:15px}.chapter{font-size:7px}.field-foot{min-height:22px;font-size:8px}.workshop{gap:5px}.character-board{height:159px;gap:5px}.character .unit-glyph{font-size:29px}.character .unit-role{font-size:7px}.feedback{min-height:24px}.recipes{gap:3px}.recipe b{font-size:7.5px}.recipe{padding-bottom:3px}.board-heading{min-height:12px;font-size:8px}.army-slot{min-height:65px;width:61px}.army-slot .unit-glyph{font-size:27px}.army-slot .unit-role{font-size:7px}.army-slot .unit-stats{font-size:7px}.enemy-name{display:none}.lanes{top:20px;bottom:38px}.gate{height:33px}.lane{padding-top:4px}.enemy .hp-text{font-size:7px}.monster{width:35px;height:32px}.gate-icon{height:23px}.topbar .back-link span{display:none}}
@media(max-width:350px) and (orientation:portrait){.battle-app{padding-inline:7px}.brand h1{font-size:18px}.fullscreen{font-size:9px;padding-inline:6px}.game-layout{gap:5px}.workshop{gap:4px}.character-board{height:148px;gap:5px}.character .unit-glyph{font-size:27px}.character .unit-role{font-size:7px}.battlefield{min-height:213px}.recipes{gap:2px}.recipe{grid-template-columns:10px 1fr}.recipe b{font-size:7px}.field-foot{font-size:7.5px}.feedback{font-size:9px;min-height:24px}.board-heading{font-size:8px}.character .rank{font-size:6px}.brand-en{font-size:6px}.back-link{min-width:22px}.result-seal{display:none}}
@media(orientation:landscape) and (max-height:520px){.battle-app{padding:3px 10px 7px;gap:5px}.topbar{min-height:44px}.brand{gap:7px}.seal{width:27px;height:29px;font-size:22px}.brand h1{font-size:20px;letter-spacing:3px}.brand-en{display:none}.back-link{font-size:10px}.fullscreen{font-size:10px}.game-layout{grid-template-columns:minmax(0,1.25fr) minmax(235px,1fr);gap:12px}.field-top{min-height:40px;padding:4px 11px}.chapter{font-size:7px;letter-spacing:2px}.field-top h2{font-size:15px;margin:2px 0 0}.round-chip{display:flex;align-items:center;gap:8px}.round-chip span{font-size:8px}.round-chip b{font-size:11px}.field-foot{min-height:22px;padding:4px 8px;font-size:8px}.field-foot #progress{font-size:8px}.field-calligraphy{left:10px;top:25px}.field-calligraphy span{font-size:22px;letter-spacing:3px}.field-calligraphy i{display:none}.lane-labels{top:6px;font-size:7px}.lanes{left:4%;right:4%;top:20px;bottom:38px}.lane{padding:5px 2px 2px}.enemy{min-width:55px}.monster{width:37px;height:34px}.monster::before,.monster::after{width:13px;height:15px;top:-5px}.monster-eyes{gap:6px}.monster-eyes i{width:8px;height:3px}.monster-mark{font-size:8px;bottom:3px}.enemy-name{font-size:7px;margin-top:3px}.enemy .hp-track{width:43px;height:3px;margin-top:2px}.hp-text{font-size:7px;line-height:1.3}.hp-text small{font-size:7px}.enemy-empty{height:62px;font-size:17px}.army-slot{width:61px;min-height:68px;padding:3px 2px}.army-slot .unit-glyph{font-size:29px}.army-slot .unit-role{font-size:7px;margin-top:1px}.army-slot .unit-stats{font-size:7px;margin-top:2px}.army-slot .hp-track{width:44px;height:3px;margin-top:3px}.army-slot .hp-text{font-size:7px}.army-slot.occupied::before{height:15px;top:-4px}.army-slot.occupied::after{width:16px;height:8px;top:-4px}.slot-plus{font-size:24px}.slot-copy{font-size:8px}.gate{height:32px;bottom:1px;left:6%;right:6%;gap:6px;padding:2px 5px}.gate-icon{width:25px;height:23px}.gate-icon i{left:8px;width:9px;height:15px}.gate-copy{font-size:7px;letter-spacing:1px}.gate-track{height:4px;margin-top:3px}.gate strong{font-size:9px}.workshop{padding:0;gap:5px;position:relative}.workshop-head{display:none}.recipes{gap:3px}.recipe{grid-template-columns:11px 1fr;gap:1px;padding-bottom:4px}.recipe>span{font-size:10px}.recipe b{font-size:7px;letter-spacing:0}.board-heading{font-size:8px;min-height:12px}.board-heading b{font-size:7px}.character-board{min-height:142px;gap:5px;max-height:180px}.character{padding:2px 1px}.character .unit-glyph{font-size:28px;line-height:1.05}.character .unit-role{font-size:7px;margin-top:0}.character .rank{font-size:6px;left:3px;top:1px}.feedback{font-size:9px;min-height:24px;line-height:1.3}.main-action{min-height:44px;padding-right:100px}.march{height:44px;font-size:12px;gap:10px}.march i{font-size:19px}.march:disabled{font-size:10px;letter-spacing:1px}.controls{position:absolute;right:0;bottom:0;gap:4px;min-height:44px;width:94px}.controls>button{min-height:44px;min-width:44px;width:44px;padding:4px;font-size:9px}.level-picker{min-width:46px}.level-picker select{height:44px;padding:4px 10px 4px 5px;font-size:9px}.level-picker>span:last-child{right:3px;font-size:10px;top:14px}.result{gap:4px;padding:6px}.result-seal{width:32px;height:35px;font-size:24px}.result #result-eyebrow{font-size:8px;margin:0}.result h2{font-size:20px;margin:2px 0}.result p{font-size:9px}.result>button{min-height:44px;font-size:10px;margin-top:0}.result>button.result-secondary{position:absolute;right:5px;top:5px;min-width:60px;font-size:8px;padding-inline:6px}.help-heading h2{font-size:20px}dialog{padding:12px 20px}dialog p{font-size:11px;line-height:1.5}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}.merge-ghost,.strike,.damage{display:none!important}}
.topbar .brand{margin-left:auto;margin-right:auto}.topbar .icon-button{flex:none;width:44px;height:44px;font-size:17px;border:0;background:transparent}
@media(max-width:700px) and (orientation:portrait){.topbar{gap:3px}.topbar #help-open{display:block}.topbar .icon-button{width:44px;height:44px}.back-link span{display:none}.brand{margin-inline:auto}.brand h1{font-size:19px;letter-spacing:1px}.brand-en{letter-spacing:.7px}}
@media(max-width:700px) and (orientation:portrait) and (max-height:700px){.workshop{position:relative}.main-action{padding-right:106px}.controls{position:absolute;bottom:0;right:0;width:100px;gap:4px}.controls>button{min-width:44px;width:44px;padding:3px;font-size:9px}.level-picker{min-width:52px}.level-picker select{padding:4px 12px 4px 5px;font-size:9px}.level-picker>span:last-child{font-size:10px;right:3px;top:14px}}
@media(max-width:350px) and (orientation:portrait){.brand h1{font-size:17px}.seal{width:24px;height:28px;font-size:20px}.topbar .brand{gap:4px}.topbar .fullscreen{padding-inline:4px}.topbar .icon-button{font-size:15px}}
.back-link{min-width:44px;flex-shrink:0;justify-content:center}.march i{display:block;position:relative;flex:none;width:13px;height:13px;border-top:2px solid currentColor;border-right:2px solid currentColor}.march i::before{content:"";position:absolute;right:-2px;top:5px;width:17px;height:2px;background:currentColor;transform:rotate(-45deg)}
@media(max-width:350px) and (orientation:portrait){.back-link{min-width:44px}.army-slot{min-height:54px;width:58px;padding:2px}.army-slot .unit-glyph{font-size:25px}.army-slot .unit-role{font-size:7px}.army-slot .unit-stats{font-size:7px;margin-top:1px}.slot-copy{font-size:8px;margin-top:3px}.slot-plus{font-size:23px}.lanes{top:17px;bottom:37px}.lane{padding-top:3px;padding-bottom:2px}.monster{height:29px;width:33px}.enemy .hp-track{margin-top:2px}.enemy-empty{height:43px}.character-board{height:142px}.field-foot{min-height:21px;padding-block:3px}.character .unit-role{font-size:7px}.recipe b{font-size:8px}}

#sound-toggle{min-height:44px;padding:8px 16px;margin:4px 0 12px}
