:root{--bg-dark: #0a101f;--bg-panel: #162033;--bg-card: #1e2c44;--border-gold: #deb35c;--border-gold-dark: #8c6a2a;--border-soft: #354966;--text-main: #f8fafc;--text-sub: #94a3b8;--accent-blue: #3b82f6;--accent-red: #ef4444;--accent-green: #22c55e;--accent-gold: #facc15}*{box-sizing:border-box;margin:0;padding:0}body{font-family:Segoe UI,Hiragino Kaku Gothic ProN,Yu Gothic UI,Meiryo,sans-serif;background:radial-gradient(ellipse at top,#1d2d4a,#090e1a);color:var(--text-main);min-height:100vh;overflow-x:hidden;-webkit-user-select:none;user-select:none}.pixel-img{image-rendering:pixelated;image-rendering:crisp-edges}.title-screen{min-height:100vh;display:flex;align-items:center;justify-content:center;padding:20px}.title-card{width:100%;max-width:640px;background:linear-gradient(180deg,#1d2b45,#0f172a);border:3px solid var(--border-gold);border-radius:16px;padding:34px 30px;text-align:center;box-shadow:0 24px 60px #000000b3,inset 0 0 0 2px #ffe8a824}.title-badge{display:inline-block;font-size:11px;letter-spacing:.18em;color:var(--accent-gold);background:#facc151a;border:1px solid rgba(250,204,21,.45);padding:4px 14px;border-radius:999px;margin-bottom:12px}.title-main{font-size:42px;letter-spacing:.14em;background:linear-gradient(180deg,#fff 20%,#fde68a);-webkit-background-clip:text;-webkit-text-fill-color:transparent;filter:drop-shadow(0 3px 0 #090e1a);margin-bottom:4px}.title-sub{font-size:14px;color:var(--text-sub);letter-spacing:.14em;margin-bottom:22px}.title-heroes{display:flex;justify-content:center;gap:12px;flex-wrap:wrap;margin-bottom:24px}.title-hero-chip{display:flex;flex-direction:column;align-items:center;gap:4px;background:linear-gradient(180deg,#162238,#0f172a);border:1px solid var(--border-soft);border-radius:10px;padding:8px 10px;box-shadow:inset 0 1px #ffffff14}.title-hero-chip img{width:56px;height:56px}.title-hero-chip span{font-size:12px;color:#e2e8f0;font-weight:700}.mode-selector{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-bottom:22px}.mode-btn{background:#141e31;border:2px solid var(--border-soft);border-radius:10px;padding:12px 14px;color:var(--text-main);cursor:pointer;transition:all .15s ease;text-align:left}.mode-btn:hover{border-color:#94a3b8}.mode-btn.active.casual{border-color:var(--accent-green);background:#22c55e26;box-shadow:0 0 16px #22c55e33}.mode-btn.active.classic{border-color:var(--accent-red);background:#ef444426;box-shadow:0 0 16px #ef444433}.mode-title{font-size:16px;font-weight:800;margin-bottom:4px}.mode-desc{font-size:12px;color:var(--text-sub)}.title-actions{display:flex;flex-direction:column;gap:10px}.title-hints{margin-top:18px;font-size:12px;color:var(--text-sub)}.btn-primary,.btn-secondary{border:1px solid rgba(255,255,255,.12);border-radius:8px;padding:9px 12px;font-size:13px;font-weight:700;cursor:pointer;transition:transform .08s ease,filter .12s ease}.btn-primary{background:linear-gradient(180deg,#3b82f6,#1d4ed8);color:#fff;box-shadow:0 3px #172554,inset 0 1px #ffffff40}.btn-primary:hover:not(:disabled){filter:brightness(1.12)}.btn-primary:active:not(:disabled){transform:translateY(2px)}.btn-primary:disabled{opacity:.45;cursor:not-allowed}.btn-secondary{background:linear-gradient(180deg,#334155,#1e293b);color:#e2e8f0;box-shadow:0 3px #0f172a,inset 0 1px #ffffff1f}.btn-secondary:hover{filter:brightness(1.16)}.btn-secondary.danger-toggle.active{background:linear-gradient(180deg,#a21caf,#701a75);border-color:#f0abfc;color:#fdf4ff}.btn-lg{padding:13px 20px;font-size:16px}.game-layout{display:flex;justify-content:center;align-items:flex-start;gap:16px;padding:14px;min-height:100vh}.board-wrapper{position:relative;display:flex;flex-direction:column;border:3px solid var(--border-gold);border-radius:12px;overflow:hidden;box-shadow:0 16px 42px #000000a6,0 0 0 1px var(--border-gold-dark);background:#0b1120;max-width:calc(100vw - 370px)}.map-canvas{display:block;cursor:pointer;width:auto;height:auto;max-width:100%;max-height:calc(100vh - 40px)}.action-menu{position:absolute;min-width:152px;background:linear-gradient(180deg,#1a263df5,#0d1424f7);border:2px solid var(--border-gold);border-radius:10px;padding:8px;display:flex;flex-direction:column;gap:5px;box-shadow:0 12px 30px #000000b8,inset 0 0 0 1px #ffe8a826;z-index:20;animation:popIn .12s ease-out}@keyframes popIn{0%{opacity:0;transform:scale(.92)}to{opacity:1;transform:scale(1)}}.action-menu-title{font-size:11px;color:var(--accent-gold);font-weight:800;border-bottom:1px solid var(--border-soft);padding-bottom:4px;margin-bottom:2px;letter-spacing:.04em}.action-btn{text-align:left;background:linear-gradient(180deg,#24334d,#192438);color:#f8fafc;border:1px solid var(--border-soft);border-radius:6px;padding:7px 10px;font-size:13px;font-weight:700;cursor:pointer;transition:all .1s ease}.action-btn:hover{background:#33486b;border-color:var(--accent-gold);transform:translate(2px)}.action-btn.attack{border-color:#ef4444;background:linear-gradient(180deg,#dc262659,#991b1b59);color:#fee2e2}.action-btn.heal{border-color:#22c55e;background:linear-gradient(180deg,#16a34a59,#15803d59);color:#dcfce7}.action-btn.seize,.action-btn.visit{border-color:#facc15;background:linear-gradient(180deg,#ca8a0459,#854d0e59);color:#fef9c3}.phase-banner{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;align-items:center;justify-content:center;pointer-events:none;z-index:25}.phase-banner-inner{padding:14px 56px;font-size:28px;font-weight:900;letter-spacing:.16em;border-top:3px solid var(--border-gold);border-bottom:3px solid var(--border-gold);text-shadow:0 2px 8px rgba(0,0,0,.85)}.phase-banner-inner.player{background:linear-gradient(90deg,transparent,rgba(29,78,216,.94),transparent)}.phase-banner-inner.enemy{background:linear-gradient(90deg,transparent,rgba(185,28,28,.94),transparent)}.side-panel{width:336px;flex-shrink:0;display:flex;flex-direction:column;gap:9px}.panel-card{background:linear-gradient(180deg,#1b2840,#121b2d);border:2px solid var(--border-soft);border-radius:10px;padding:11px 12px;box-shadow:0 6px 18px #00000059,inset 0 1px #ffffff14}.header-card{border-color:var(--border-gold)}.chapter-row{display:flex;justify-content:space-between;align-items:center;margin-bottom:6px}.chapter-title-text{font-size:14px;color:#fef3c7}.mode-pill{font-size:10px;padding:2px 8px;border-radius:999px;font-weight:800}.mode-pill.casual{background:#22c55e38;color:#86efac;border:1px solid rgba(34,197,94,.4)}.mode-pill.classic{background:#ef444438;color:#fca5a5;border:1px solid rgba(239,68,68,.4)}.turn-row{display:flex;justify-content:space-between;align-items:center;margin-bottom:6px}.phase-badge{font-size:12px;font-weight:800;padding:3px 10px;border-radius:6px}.phase-badge.player{background:linear-gradient(180deg,#2563eb,#1d4ed8)}.phase-badge.enemy{background:linear-gradient(180deg,#dc2626,#991b1b)}.turn-num{font-weight:800;font-size:13px;color:var(--accent-gold);letter-spacing:.06em}.victory-text{font-size:11.5px;color:#cbd5e1}.card-label{font-size:12px;font-weight:800;color:var(--accent-gold);margin-bottom:6px}.terrain-top{display:flex;justify-content:space-between;align-items:center;gap:8px}.terrain-chips{display:flex;gap:6px}.t-chip{font-size:11px;font-weight:700;padding:2px 7px;border-radius:5px;background:#0f172a;border:1px solid var(--border-soft);color:#e2e8f0}.t-chip.heal{color:#86efac;border-color:#4ade8073}.unit-header{display:flex;gap:10px;align-items:center;margin-bottom:10px}.unit-thumb-wrap{width:62px;height:62px;flex-shrink:0;border-radius:10px;padding:4px;display:flex;align-items:center;justify-content:center;background:#0d1526;border:2px solid var(--border-soft)}.unit-thumb-wrap.faction-player{border-color:#3b82f6;box-shadow:inset 0 0 12px #3b82f640}.unit-thumb-wrap.faction-enemy{border-color:#ef4444;box-shadow:inset 0 0 12px #ef444440}.unit-thumb-wrap.acted{filter:grayscale(85%) brightness(.75)}.unit-thumb{width:52px;height:52px}.unit-title{flex:1;min-width:0}.unit-name-row{display:flex;align-items:center;gap:6px}.boss-tag{font-size:10px;background:#dc2626;color:#fef08a;padding:1px 6px;border-radius:4px;font-weight:800}.acted-pill{margin-left:auto;font-size:10px;font-weight:800;padding:1px 6px;border-radius:4px}.acted-pill.ready{background:#22c55e38;color:#86efac;border:1px solid rgba(34,197,94,.45)}.acted-pill.done{background:#64748b4d;color:#cbd5e1;border:1px solid #475569}.unit-sub{font-size:11.5px;color:var(--text-sub);margin-bottom:4px}.meter-block{margin-bottom:4px}.meter-head{display:flex;justify-content:space-between;font-size:11px;color:#cbd5e1;margin-bottom:2px}.meter-track{height:8px;background:#0a101d;border:1px solid #2b3c57;border-radius:999px;overflow:hidden}.meter-track.thin{height:5px}.meter-fill{height:100%;border-radius:999px;transition:width .22s ease}.stat-bars-grid{display:grid;grid-template-columns:1fr 1fr;gap:6px 10px;background:#0e1626;border:1px solid #24344d;padding:8px 9px;border-radius:8px;margin-bottom:8px}.stat-bar-row{display:grid;grid-template-columns:28px 1fr 20px;align-items:center;gap:5px;font-size:11.5px}.stat-bar-label{color:#cbd5e1;font-weight:700}.stat-bar-track{height:7px;background:#1a263b;border-radius:4px;overflow:hidden;border:1px solid rgba(255,255,255,.06)}.stat-bar-fill{height:100%;border-radius:3px;transition:width .2s ease}.stat-bar-val{text-align:right;font-weight:800;color:#f8fafc}.stat-bar-val.capped{color:#fde047;text-shadow:0 0 6px rgba(250,204,21,.55)}.stat-mini-badges{display:flex;align-items:center;justify-content:space-between;gap:4px;font-size:11px;color:var(--accent-gold);font-weight:700;padding-left:2px}.inv-label{font-size:11px;color:var(--text-sub);margin-bottom:4px}.inv-item{display:flex;justify-content:space-between;font-size:12px;padding:3px 7px;border-radius:5px}.inv-item.equipped{background:#3b82f638;border:1px solid rgba(96,165,250,.35);color:#dbeafe;font-weight:700}.inv-uses{color:var(--accent-gold);font-weight:700}.empty-unit{font-size:12px;color:var(--text-sub);text-align:center;padding:14px 4px}.log-list{max-height:92px;overflow-y:auto;display:flex;flex-direction:column;gap:3px}.log-line{font-size:11.5px;line-height:1.35;color:#e2e8f0}.log-line.muted{color:var(--text-sub)}.panel-actions{display:flex;flex-direction:column;gap:7px}.top-actions{display:grid;grid-template-columns:1.15fr 1fr;gap:7px}.sub-actions{display:grid;grid-template-columns:repeat(5,1fr);gap:4px}.sub-actions .btn-secondary{padding:7px 2px;font-size:11px}.dialogue-overlay{position:fixed;top:0;right:0;bottom:0;left:0;background:#020617a6;display:flex;align-items:flex-end;justify-content:center;padding:24px;z-index:40}.dialogue-container{width:100%;max-width:780px}.dialogue-portraits{display:flex;margin-bottom:-8px;padding:0 24px}.dialogue-portraits.side-left{justify-content:flex-start}.dialogue-portraits.side-right{justify-content:flex-end}.portrait-frame{width:96px;height:96px;background:linear-gradient(180deg,#1e293b,#0f172a);border:3px solid var(--border-gold);border-radius:12px;display:flex;align-items:center;justify-content:center;box-shadow:0 8px 20px #00000080}.portrait-img{width:80px;height:80px}.dialogue-box{background:linear-gradient(180deg,#1e293b,#0f172a);border:3px solid var(--border-gold);border-radius:12px;padding:16px 20px;cursor:pointer;box-shadow:0 12px 32px #000000b3}.dialogue-header{display:flex;align-items:center;gap:10px;margin-bottom:10px}.speaker-name{font-size:14px;font-weight:800;padding:3px 12px;border-radius:6px;color:#fff}.speaker-expr{font-size:12px;color:var(--accent-gold)}.btn-skip{margin-left:auto;background:transparent;border:1px solid var(--border-soft);color:var(--text-sub);border-radius:6px;padding:3px 10px;font-size:12px;cursor:pointer}.btn-skip:hover{color:#fff;border-color:#94a3b8}.dialogue-text{font-size:17px;line-height:1.65;min-height:56px;margin-bottom:10px}.dialogue-footer{display:flex;justify-content:space-between;font-size:12px;color:var(--text-sub)}.blink-caret{color:var(--accent-gold)}.modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;background:#020617b8;display:flex;align-items:center;justify-content:center;padding:16px;z-index:50}.forecast-card,.levelup-card,.result-card{width:100%;max-width:500px;background:linear-gradient(180deg,#1e2c45,#0f172a);border:3px solid var(--border-gold);border-radius:14px;padding:20px;box-shadow:0 20px 50px #000000bf}.forecast-title{text-align:center;font-size:16px;font-weight:800;color:var(--accent-gold);margin-bottom:12px}.weapon-switcher{display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin-bottom:12px;background:#111b2e;padding:8px;border-radius:8px}.switcher-label{font-size:12px;color:var(--text-sub)}.weapon-pill{background:#263449;color:#e2e8f0;border:1px solid var(--border-soft);border-radius:6px;padding:4px 10px;font-size:12px;cursor:pointer}.weapon-pill.selected{background:#2563eb;border-color:#93c5fd;font-weight:700}.forecast-grid{display:grid;grid-template-columns:1fr auto 1fr;gap:10px;align-items:center;margin-bottom:16px}.forecast-col{border-radius:10px;padding:12px}.player-col{background:#2563eb2e;border:1px solid #3b82f6}.enemy-col{background:#dc26262e;border:1px solid #ef4444}.fc-name{font-size:16px;font-weight:800;margin-bottom:4px}.fc-weapon{font-size:12px;color:#e2e8f0;margin-bottom:8px;min-height:20px}.tri-up{color:#4ade80;font-weight:800}.tri-down{color:#f87171;font-weight:800}.eff-badge{display:inline-block;margin-left:4px;background:#facc15;color:#141826;font-size:10px;font-weight:900;padding:1px 5px;border-radius:4px}.double-badge{color:var(--accent-gold)}.fc-stat{display:flex;justify-content:space-between;font-size:14px;padding:3px 0;border-bottom:1px solid rgba(255,255,255,.08)}.forecast-vs{font-weight:900;color:var(--accent-gold)}.forecast-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px}.levelup-card{max-width:400px;text-align:center}.levelup-banner{font-size:26px;font-weight:900;color:var(--accent-gold);letter-spacing:.12em;text-shadow:0 0 18px rgba(250,204,21,.55);margin-bottom:8px}.levelup-header{display:flex;justify-content:center;gap:12px;font-size:16px;margin-bottom:14px}.levelup-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-bottom:16px}.lu-row{display:flex;justify-content:space-between;padding:7px 12px;background:#141d2e;border:1px solid var(--border-soft);border-radius:6px;font-size:14px;transition:all .2s ease}.lu-row.gained{background:#facc152e;border-color:var(--accent-gold);color:#fef08a;transform:scale(1.04)}.lu-empty{font-size:13px;color:var(--text-sub);margin-bottom:12px}.result-card{text-align:center}.result-card h2{font-size:28px;color:var(--accent-gold);margin-bottom:10px}.result-card p{font-size:14px;color:#cbd5e1;line-height:1.6;margin-bottom:18px}.result-actions{display:flex;justify-content:center;gap:10px}@media(max-width:1120px){.game-layout{flex-direction:column;align-items:center}.side-panel{width:100%;max-width:768px}}.minibattle-card{width:100%;max-width:540px;background:#0f172a;border:3px solid var(--border-gold);border-radius:14px;overflow:hidden;box-shadow:0 24px 60px #000000d9}.minibattle-card.crit-flash{box-shadow:0 0 40px #facc15,0 24px 60px #000000d9}.minibattle-stage{position:relative;height:200px;overflow:hidden;display:flex;align-items:flex-end;justify-content:space-between;padding:0 56px 26px}.mb-sky{position:absolute;top:0;right:0;bottom:52px;left:0;background:linear-gradient(180deg,#1d4ed8,#60a5fa 65%,#bfdbfe)}.mb-ground{position:absolute;inset:auto 0 0 0;height:58px;background:linear-gradient(180deg,#4d9e38,#2f6b22);border-top:4px solid #84cc55}.mb-unit{position:relative;z-index:2;transition:transform .14s ease-out}.mb-unit.lunge-right{transform:translate(72px) scale(1.08)}.mb-unit.lunge-left{transform:translate(-72px) scale(1.08)}.mb-unit.shake{animation:mbShake .24s ease-in-out}@keyframes mbShake{0%,to{transform:translate(0);filter:brightness(1)}25%{transform:translate(-10px);filter:brightness(2.2)}75%{transform:translate(10px);filter:brightness(2.2)}}.mb-sprite{width:96px;height:96px;filter:drop-shadow(0 6px 4px rgba(0,0,0,.45))}.mb-sprite.flip-x{transform:scaleX(-1)}.mb-center-text{position:absolute;top:18px;left:50%;transform:translate(-50%);z-index:4;background:#0f172adb;border:2px solid var(--border-gold);border-radius:8px;padding:4px 14px;font-size:14px;font-weight:800;color:#fef08a;white-space:nowrap}.minibattle-hud{display:grid;grid-template-columns:1fr 1fr;gap:12px;padding:12px 16px;background:linear-gradient(180deg,#1b2840,#0f172a);border-top:2px solid var(--border-gold)}.mb-hud-side{padding:8px 10px;border-radius:8px}.mb-hud-side.player{background:#2563eb38;border:1px solid #3b82f6}.mb-hud-side.enemy{background:#dc262638;border:1px solid #ef4444}.mb-hud-name{display:flex;justify-content:space-between;font-size:13px;margin-bottom:5px}.prep-screen{min-height:100vh;display:flex;justify-content:center;padding:20px}.prep-container{width:100%;max-width:960px;background:linear-gradient(180deg,#1b2840,#0f172a);border:3px solid var(--border-gold);border-radius:14px;padding:20px;box-shadow:0 20px 50px #000000b3}.prep-header{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;border-bottom:2px solid var(--border-soft);padding-bottom:14px;margin-bottom:14px}.prep-badge{display:inline-block;font-size:11px;font-weight:800;color:#141826;background:var(--accent-gold);padding:2px 10px;border-radius:999px;margin-bottom:4px}.prep-sub{font-size:13px;color:#cbd5e1}.prep-header-right{display:flex;align-items:center;gap:10px}.gold-box{background:#0e1626;border:1px solid var(--border-gold);color:var(--accent-gold);font-weight:800;padding:8px 14px;border-radius:8px}.prep-tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:14px}.prep-tab{background:#141e31;color:#cbd5e1;border:2px solid var(--border-soft);border-radius:8px;padding:8px 14px;font-size:13px;font-weight:700;cursor:pointer}.prep-tab.active{background:#1d4ed8;border-color:#93c5fd;color:#fff}.prep-deploy-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:10px}.prep-unit-card{display:flex;align-items:center;gap:10px;background:#141e31;border:2px solid var(--border-soft);border-radius:10px;padding:10px;cursor:pointer}.prep-unit-card.deployed{border-color:#3b82f6;background:#2563eb29}.prep-unit-card img{width:52px;height:52px}.prep-unit-info{flex:1;font-size:12.5px}.prep-mini-stats{font-size:11px;color:#94a3b8;margin-top:2px}.lord-tag{font-size:10px;background:#facc15;color:#141826;padding:1px 5px;border-radius:4px}.deploy-check{font-size:11px;font-weight:800;padding:4px 8px;border-radius:6px;background:#334155;color:#94a3b8}.deploy-check.on{background:#22c55e;color:#052e16}.prep-items-layout{display:grid;grid-template-columns:160px 1fr 1fr;gap:12px}.prep-shop-layout{display:grid;grid-template-columns:1.4fr 1fr;gap:12px}.prep-char-list{display:flex;flex-direction:column;gap:6px}.prep-char-btn{display:flex;justify-content:space-between;background:#141e31;color:#e2e8f0;border:1px solid var(--border-soft);border-radius:6px;padding:8px 10px;cursor:pointer;font-weight:700}.prep-char-btn.active{background:#2563eb;border-color:#93c5fd}.prep-inv-panel{background:#101829;border:1px solid var(--border-soft);border-radius:10px;padding:12px;display:flex;flex-direction:column;gap:8px}.prep-panel-title{display:flex;justify-content:space-between;align-items:center;font-size:13px;font-weight:800;color:var(--accent-gold);border-bottom:1px solid var(--border-soft);padding-bottom:6px}.prep-item-row{display:flex;justify-content:space-between;align-items:center;gap:8px;background:#1a263d;padding:7px 10px;border-radius:6px;font-size:12.5px}.prep-item-btns{display:flex;gap:5px}.mini-btn{background:#334155;color:#f8fafc;border:1px solid #475569;border-radius:5px;padding:4px 8px;font-size:11.5px;font-weight:700;cursor:pointer}.mini-btn.buy{background:#1d4ed8;border-color:#60a5fa}.mini-btn:disabled{opacity:.4;cursor:not-allowed}.cc-modal-card{max-width:600px!important;max-height:90dvh;overflow-y:auto;-webkit-overflow-scrolling:touch}.cc-subtitle{font-size:12px;color:#cbd5e1;margin-bottom:12px;text-align:center}.cc-options{display:flex;flex-direction:column;gap:12px}.cc-option-card{display:flex;flex-direction:column;gap:10px;text-align:left;background:linear-gradient(180deg,#16233b,#101a2e);border:2px solid var(--border-gold);border-radius:12px;padding:12px 14px;color:#f8fafc;cursor:pointer;transition:background .15s ease,transform .12s ease,box-shadow .15s ease}.cc-option-card:hover{background:linear-gradient(180deg,#1f3356,#162540);box-shadow:0 0 0 2px #facc1559}.cc-option-card:active{transform:scale(.99)}.cc-card-head{display:flex;align-items:center;gap:12px}.cc-sprite-pair{display:flex;align-items:center;gap:5px;flex-shrink:0;background:#0f172ab3;border:1px solid rgba(148,163,184,.25);border-radius:10px;padding:6px 8px}.cc-sprite-before{width:38px;height:38px;opacity:.7}.cc-sprite-arrow{color:#facc15;font-weight:900;font-size:13px}.cc-sprite-after{width:52px;height:52px}.cc-head-info{flex:1;min-width:0;display:flex;flex-direction:column;gap:6px}.cc-name-row{display:flex;flex-wrap:wrap;align-items:center;gap:6px}.cc-name{font-size:17px;font-weight:800;color:var(--accent-gold);line-height:1.2}.cc-trait-chip{display:inline-flex;align-items:center;gap:4px;font-size:11px;font-weight:700;padding:2px 7px;border-radius:999px;background:#334155cc;border:1px solid rgba(148,163,184,.4);color:#e2e8f0}.cc-trait-chip.changed{background:#1e40af73;border-color:#60a5fa;color:#bfdbfe}.cc-trait-chip.crit{background:#991b1b80;border-color:#f87171;color:#fecaca}.cc-weapons-row{display:flex;align-items:center;flex-wrap:wrap;gap:6px}.cc-row-label{font-size:11px;color:#94a3b8;font-weight:700}.cc-weapon-chips{display:flex;flex-wrap:wrap;gap:5px}.cc-weapon-new{box-shadow:0 0 6px #facc1559}.cc-new-tag{font-size:9px;font-weight:900;padding:1px 4px;border-radius:4px;background:#facc15;color:#0f172a;line-height:1.1;margin-left:2px}.cc-caps-row{display:flex;align-items:center;flex-wrap:wrap;gap:6px}.cc-caps-chips{display:flex;flex-wrap:wrap;gap:4px}.cc-cap-chip{display:inline-flex;align-items:baseline;gap:3px;font-size:11px;padding:2px 7px;border-radius:999px;background:#0f172ab3;border:1px solid rgba(56,189,248,.45);color:#e0f2fe}.cc-cap-chip strong{color:#38bdf8;font-weight:800}.cc-cap-chip small{color:#86efac;font-weight:700;font-size:10px}.cc-skills-box{background:#0f172aa6;border:1px solid rgba(192,132,252,.35);border-radius:8px;padding:7px 10px}.cc-section-label{font-size:11px;font-weight:800;color:#d8b4fe;margin-bottom:4px}.cc-skills-list{display:flex;flex-direction:column;gap:4px}.cc-skill-item{display:flex;flex-wrap:wrap;align-items:baseline;gap:6px;font-size:12px}.cc-skill-name{font-weight:800;color:#fde68a;display:inline-flex;align-items:center;gap:3px;flex-shrink:0}.cc-skill-desc{color:#cbd5e1;font-size:11px}.cc-stats-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px 12px;background:#0f172a8c;border:1px solid rgba(148,163,184,.2);border-radius:8px;padding:8px 10px}.cc-stat-row{display:flex;flex-direction:column;gap:3px}.cc-stat-top{display:flex;justify-content:space-between;align-items:baseline;font-size:11px}.cc-stat-label{font-weight:700;color:#cbd5e1}.cc-stat-vals{display:inline-flex;align-items:baseline;gap:3px;font-variant-numeric:tabular-nums}.cc-stat-cur{color:#94a3b8;font-size:11px}.cc-stat-arrow{color:#64748b;font-size:10px}.cc-stat-next{color:#f8fafc;font-weight:800;font-size:12px}.cc-stat-inc{color:#4ade80;font-weight:900;font-size:11px;margin-left:2px}.cc-stat-cap{color:#facc15;font-weight:800;font-size:10px;margin-left:2px}.cc-stat-track{position:relative;height:7px;background:#1e293bf2;border-radius:999px;overflow:hidden;border:1px solid rgba(148,163,184,.2)}.cc-stat-fill-base{position:absolute;top:0;bottom:0;left:0;opacity:.78}.cc-stat-fill-inc{position:absolute;top:0;bottom:0;background:#4ade80;box-shadow:0 0 6px #4ade80d9;animation:ccBarPulse 1.4s ease-in-out infinite}@keyframes ccBarPulse{0%,to{opacity:1}50%{opacity:.55}}.cc-select-cta{text-align:right;font-size:11px;font-weight:800;color:#facc15;opacity:.9}@media(max-width:520px){.cc-card-head{flex-direction:column;align-items:flex-start}.cc-sprite-pair{width:100%;justify-content:center}}@media(max-width:820px){.prep-items-layout,.prep-shop-layout{grid-template-columns:1fr}}.debug-chapter-panel{margin-top:14px;padding:12px;background:#0e1626;border:1px solid var(--border-soft);border-radius:10px;text-align:left}.debug-hint{font-size:11.5px;color:var(--accent-gold);margin-bottom:10px;text-align:center}.debug-chapter-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:6px;max-height:220px;overflow-y:auto}.debug-ch-btn{display:flex;flex-direction:column;align-items:flex-start;gap:2px;background:#172338;border:1px solid var(--border-soft);border-radius:6px;padding:6px 8px;color:#e2e8f0;cursor:pointer;font-size:11.5px}.debug-ch-btn:hover{background:#233657;border-color:var(--accent-gold)}.debug-ch-num{font-weight:800;color:var(--accent-gold);font-size:10.5px}.debug-ch-title{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}.saveload-header{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:10px}.saveload-tabs{display:flex;gap:6px}.saveload-notice{background:#22c55e2e;border:1px solid rgba(34,197,94,.5);color:#bbf7d0;border-radius:6px;padding:6px 10px;font-size:12px;text-align:center;margin-bottom:10px}.saveload-list{display:flex;flex-direction:column;gap:7px;overflow-y:auto;padding-right:4px}.save-slot-row{display:flex;align-items:center;gap:10px;background:#131d30;border:1px solid var(--border-soft);border-radius:8px;padding:8px 10px}.save-slot-row.filled{border-color:#3b5984}.slot-badge{font-size:11px;font-weight:800;color:var(--accent-gold);background:#0a101f;border:1px solid var(--border-gold-dark);border-radius:6px;padding:4px 8px;flex-shrink:0}.slot-info{flex:1;min-width:0}.slot-title{font-size:13px;display:flex;align-items:center;margin-bottom:2px}.slot-meta{display:flex;flex-wrap:wrap;gap:10px;font-size:11.5px;color:var(--text-sub)}.slot-date{margin-left:auto}.slot-empty-text{font-size:12px;color:#64748b}.slot-actions{display:flex;gap:5px;flex-shrink:0}.cam-controls{position:absolute;bottom:10px;right:10px;display:flex;flex-direction:column;align-items:center;gap:2px;z-index:15;background:#0a101fb8;border:1px solid var(--border-gold-dark);border-radius:8px;padding:4px}.cam-mid-row{display:flex;gap:18px}.cam-btn{width:24px;height:22px;background:#1e293b;color:#fef08a;border:1px solid var(--border-soft);border-radius:4px;font-size:11px;cursor:pointer;display:flex;align-items:center;justify-content:center}.cam-btn:hover{background:#334155;border-color:var(--accent-gold)}.skill-chips-row{display:flex;flex-wrap:wrap;gap:5px;margin-top:8px}.skill-chip{display:inline-flex;align-items:center;gap:4px;background:#38bdf829;border:1px solid #38bdf8;color:#bae6fd;font-size:11px;font-weight:700;padding:2px 7px;border-radius:999px}.legendary-name{color:#fde047;font-weight:800;text-shadow:0 0 8px rgba(250,204,21,.35)}.broken-tag{display:inline-block;margin-left:5px;background:#dc2626;color:#fff;font-size:10px;font-weight:800;padding:1px 5px;border-radius:4px}.inv-item.broken{opacity:.72;border-left:2px solid #ef4444;padding-left:5px}.tab-count-badge{display:inline-block;margin-left:6px;background:#ef4444;color:#fff;font-size:11px;font-weight:800;padding:0 6px;border-radius:999px}.prep-card-right{display:flex;flex-direction:column;align-items:flex-end;gap:5px}.prep-status-layout{display:grid;grid-template-columns:160px 1fr;gap:12px}.prep-status-detail{background:#101829;border:1px solid var(--border-soft);border-radius:10px;padding:14px;display:flex;flex-direction:column;gap:12px}.prep-status-header{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;border-bottom:1px solid var(--border-soft);padding-bottom:10px}.prep-status-hero{display:flex;align-items:center;gap:12px}.prep-hero-img{width:64px;height:64px;background:#18233a;border:2px solid var(--border-gold);border-radius:8px}.prep-status-name{display:flex;align-items:center;gap:8px;font-size:17px}.prep-class-pill{font-size:12px;background:#1e3a8a;color:#dbeafe;padding:2px 8px;border-radius:6px}.prep-status-meta{font-size:12px;color:#94a3b8;margin-top:2px}.prep-status-actions{display:flex;gap:8px}.prep-stat-bars{display:grid;grid-template-columns:1fr 1fr;gap:7px 18px;background:#141e31;border:1px solid var(--border-soft);border-radius:8px;padding:10px 12px}.stat-bonus-tag{color:#4ade80;margin-left:2px;font-weight:800}.prep-status-subgrid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.prep-skill-row{display:flex;flex-direction:column;gap:2px;background:#1a263d;border-left:3px solid #38bdf8;padding:7px 10px;border-radius:6px;font-size:12.5px}.prep-skill-row small{color:#cbd5e1;font-size:11.5px}.prep-support-pills{display:flex;flex-wrap:wrap;gap:6px}.prep-right-toggle{display:flex;gap:6px;width:100%}.prep-trade-picker{display:flex;align-items:center;gap:8px;font-size:12px;color:#cbd5e1}.prep-select{flex:1;background:#1a263d;color:#f8fafc;border:1px solid #475569;border-radius:6px;padding:5px 8px;font-size:12.5px}.mini-btn.repair{background:#b45309;border-color:#f59e0b;color:#fef3c7}.mini-btn.repair:hover:not(:disabled){background:#d97706}.owner-pill{display:inline-block;background:#1e3a8a;color:#dbeafe;font-size:11px;font-weight:700;padding:1px 7px;border-radius:5px;margin-right:4px}.avatar-tag{font-size:10px;background:linear-gradient(90deg,#38bdf8,#818cf8);color:#0f172a;font-weight:900;padding:1px 6px;border-radius:4px}.avatar-modal-card{width:100%;max-width:820px;max-height:92vh;overflow-y:auto;background:linear-gradient(180deg,#1b2840,#0f172a);border:3px solid var(--border-gold);border-radius:14px;padding:20px;box-shadow:0 24px 60px #000000d9}.avatar-modal-header{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:8px}.avatar-modal-header h2{font-size:22px;color:var(--accent-gold)}.avatar-lead{font-size:12.5px;color:#cbd5e1;line-height:1.5;margin-bottom:14px}.avatar-body{display:grid;grid-template-columns:270px 1fr;gap:16px;margin-bottom:16px}@media(max-width:720px){.avatar-body{grid-template-columns:1fr}}.avatar-left{display:flex;flex-direction:column;gap:12px}.avatar-preview-box{background:#101829;border:2px solid var(--border-soft);border-radius:10px;padding:14px;text-align:center}.avatar-preview-img{width:96px;height:96px;margin-bottom:6px}.avatar-preview-name{font-size:18px;font-weight:900;color:#fef08a}.avatar-preview-class{font-size:12.5px;color:#93c5fd}.avatar-field label,.avatar-section-label{display:block;font-size:12px;font-weight:800;color:var(--accent-gold);margin-bottom:5px}.avatar-input{width:100%;background:#0e1626;border:2px solid #475569;border-radius:7px;padding:8px 10px;color:#f8fafc;font-size:14px;font-weight:700}.avatar-input:focus{outline:none;border-color:#38bdf8}.hair-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:5px}.hair-chip{display:flex;align-items:center;justify-content:center;gap:4px;background:#141e31;border:1px solid #334155;border-radius:6px;padding:5px 4px;font-size:11px;color:#e2e8f0;cursor:pointer}.hair-chip.active{border-color:#38bdf8;background:#1e3a8a}.hair-dot{width:10px;height:10px;border-radius:50%;border:1px solid rgba(255,255,255,.5)}.avatar-stats-box{background:#101829;border:1px solid var(--border-soft);border-radius:8px;padding:9px 10px}.avatar-stats-title{font-size:11.5px;font-weight:800;color:#38bdf8;margin-bottom:6px}.avatar-stats-grid{display:grid;grid-template-columns:1fr 1fr;gap:4px 8px;font-size:11.5px;color:#e2e8f0}.avatar-class-grid{display:grid;grid-template-columns:1fr 1fr;gap:7px}.avatar-class-btn{display:flex;align-items:center;gap:8px;text-align:left;background:#141e31;border:2px solid var(--border-soft);border-radius:8px;padding:7px 9px;color:#f8fafc;cursor:pointer}.avatar-class-btn img{width:38px;height:38px;flex-shrink:0}.avatar-class-btn strong{display:block;font-size:13px}.avatar-class-btn small{display:block;font-size:10.5px;color:#94a3b8;line-height:1.3}.avatar-class-btn.active{border-color:var(--accent-gold);background:#2563eb47}.avatar-footer{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;border-top:1px solid var(--border-soft);padding-top:12px}.map-canvas.grab{cursor:grab}.map-canvas.grabbing{cursor:grabbing}.batch-move-bar{position:static;order:-1;width:100%;z-index:25;display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;background:linear-gradient(180deg,#0f291e,#0b1b15);border-bottom:2px solid #4ade80;padding:7px 14px;color:#f0fdf4;font-size:12.5px;white-space:nowrap}.batch-move-btns{display:flex;gap:6px}.batch-toggle.active{background:#15803d;border-color:#4ade80;color:#f0fdf4}.ko-badge{display:inline-block;margin-left:6px;background:#facc15;color:#141826;font-size:11px;font-weight:900;padding:1px 6px;border-radius:4px;vertical-align:middle}.fc-support-line{margin-top:6px;font-size:11px;font-weight:700;color:#f472b6;background:#f472b624;border:1px solid rgba(244,114,182,.45);border-radius:5px;padding:2px 6px}.fc-skills{display:flex;flex-wrap:wrap;gap:4px;margin-top:6px}.fc-skill-tag{font-size:10.5px;font-weight:700;color:#bae6fd;background:#38bdf829;border:1px solid rgba(56,189,248,.5);border-radius:999px;padding:1px 6px}.drop-hint-row{margin-top:5px;font-size:11.5px;font-weight:700;color:#fde047;background:#facc151f;border:1px dashed rgba(250,204,21,.45);border-radius:5px;padding:3px 6px}.formation-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(155px,1fr));gap:8px}.formation-slot{display:flex;align-items:center;gap:8px;text-align:left;background:#141e31;border:2px solid var(--border-soft);border-radius:8px;padding:6px 8px;color:#f8fafc;cursor:pointer}.formation-slot:hover{border-color:#60a5fa}.formation-slot.picked{border-color:var(--accent-gold);background:#facc1533}.formation-num{font-size:11px;font-weight:900;color:var(--accent-gold);min-width:20px}.formation-slot img{width:32px;height:32px}.formation-info strong{display:block;font-size:12.5px}.formation-info small{font-size:10.5px;color:#94a3b8}.forecast-card-wide{max-width:560px}.warn-badge{display:inline-block;margin-left:8px;font-size:11px;font-weight:900;padding:2px 7px;border-radius:999px;vertical-align:middle}.warn-badge.danger{background:#dc2626;color:#fff;animation:fcDamagePulse .9s ease-in-out infinite}.warn-badge.crit{background:#ca8a04;color:#fefce8}.fc-timeline{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:5px;background:#101829;border:1px solid var(--border-soft);border-radius:8px;padding:6px 10px;margin-bottom:10px}.fc-tl-arrow{font-size:10px;color:#64748b}.fc-tl-chip{font-size:11px;font-weight:800;padding:2px 7px;border-radius:5px}.fc-tl-chip.player{background:#2563eb47;border:1px solid #60a5fa;color:#dbeafe}.fc-tl-chip.enemy{background:#dc262647;border:1px solid #f87171;color:#fee2e2}.fc-unit-head{display:flex;align-items:center;gap:8px;margin-bottom:6px}.fc-unit-icon{width:38px;height:38px;background:#0f172a8c;border:1px solid rgba(255,255,255,.18);border-radius:6px;flex-shrink:0}.fc-terrain-sub{font-size:10.5px;color:#cbd5e1}.fc-uses{color:#facc15;font-weight:700}.fc-hp-block{margin:6px 0 8px}.fc-hp-numbers{display:flex;justify-content:space-between;align-items:baseline;font-size:13px;margin-bottom:4px}.fc-hp-max{color:#94a3b8;font-weight:600}.fc-hp-track{position:relative;height:11px;background:#0f172a;border:1px solid rgba(255,255,255,.22);border-radius:6px;overflow:hidden}.fc-hp-remain{position:absolute;top:0;left:0;bottom:0;transition:width .2s ease}.fc-hp-damage{position:absolute;top:0;bottom:0;background:linear-gradient(90deg,#f97316,#fef08a);animation:fcDamagePulse .75s ease-in-out infinite}@keyframes fcDamagePulse{0%,to{opacity:.95}50%{opacity:.35}}.battle-status-modal{width:100%;max-width:880px;max-height:92vh;overflow-y:auto;background:linear-gradient(180deg,#1b2840,#0f172a);border:3px solid var(--border-gold);border-radius:14px;padding:18px;box-shadow:0 24px 60px #000000d9}.unit-sub{display:flex;align-items:baseline;gap:8px;flex-wrap:wrap}.unit-lv-big{font-size:16px;font-weight:800;color:#fde047;letter-spacing:.02em;text-shadow:0 1px 4px rgba(0,0,0,.7)}.weapon-type-row{display:flex;align-items:center;flex-wrap:wrap;gap:5px;margin:4px 0}.weapon-type-row.compact{gap:4px;margin:2px 0 4px}.weapon-type-label{font-size:11px;color:#94a3b8;font-weight:600}.weapon-type-chip{display:inline-flex;align-items:center;gap:2px;font-size:11px;font-weight:700;padding:1px 6px;border-radius:999px;border:1px solid rgba(148,163,184,.45);background:#0f172ab8;line-height:1.4}.trade-pick-toggle{display:grid;grid-template-columns:1fr 1fr;gap:4px;margin-bottom:6px;position:sticky;top:0;background:#0f172a;padding-bottom:4px;z-index:2}.prep-char-btn.partner{border-color:#facc15;background:#facc1524}.char-side-badge{font-size:10px;font-weight:800;padding:1px 5px;border-radius:4px;line-height:1.2}.char-side-badge.left{background:#2563eb;color:#fff}.char-side-badge.right{background:#ca8a04;color:#fff}.prep-inv-panel.pick-focus-left{border-color:#38bdf8bf;box-shadow:0 0 0 1px #38bdf859}.prep-inv-panel.pick-focus-right{border-color:#facc15cc;box-shadow:0 0 0 1px #facc1559}.item-notice-card{width:min(440px,92vw);background:linear-gradient(180deg,#1e293b,#0f172a);border:2px solid #facc15;border-radius:14px;box-shadow:0 20px 50px #000000b8,0 0 24px #facc1538;padding:18px 20px;display:flex;flex-direction:column;gap:14px;animation:noticePop .18s ease-out}.item-notice-card.special{border-color:#fde047;box-shadow:0 20px 54px #000000c7,0 0 36px #facc1573}@keyframes noticePop{0%{opacity:0;transform:translateY(8px) scale(.96)}to{opacity:1;transform:translateY(0) scale(1)}}.item-notice-header{font-size:16px;font-weight:800;color:#fde047;letter-spacing:.04em;border-bottom:1px solid rgba(250,204,21,.28);padding-bottom:8px}.item-notice-body{display:flex;flex-direction:column;gap:10px}.item-notice-item{background:#0f172ab8;border:1px solid rgba(148,163,184,.3);border-radius:10px;padding:12px;display:flex;flex-direction:column;gap:6px}.item-notice-name-row{display:flex;align-items:center;gap:8px;font-size:17px;color:#f8fafc}.item-notice-uses{font-size:12px;color:#facc15}.item-notice-stats{font-size:12px;color:#cbd5e1;font-weight:600}.item-notice-desc{font-size:12px;color:#94a3b8;line-height:1.5}.item-notice-dest{font-size:12px;color:#38bdf8;font-weight:700;margin-top:2px}.item-notice-dest.convoy{color:#fbbf24}.item-notice-gold{background:#facc151f;border:1px solid rgba(250,204,21,.45);border-radius:8px;padding:8px 12px;font-size:14px;color:#fef08a}.item-notice-msg{margin:0;font-size:13px;color:#e2e8f0;line-height:1.55}.item-notice-btn{align-self:flex-end;padding:8px 20px;font-size:13px}.battle-trade-modal{width:min(760px,95vw);max-height:88vh;background:linear-gradient(180deg,#1e293b,#0f172a);border:2px solid #38bdf8;border-radius:14px;box-shadow:0 24px 60px #000000c7;padding:18px 20px;display:flex;flex-direction:column;gap:12px;overflow:hidden}.trade-partner-tabs{display:flex;align-items:center;flex-wrap:wrap;gap:6px}.battle-trade-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;min-height:240px;max-height:52vh;overflow-y:auto}.battle-convoy-list{display:flex;flex-direction:column;gap:6px;max-height:40vh;overflow-y:auto}.action-menu-footer{display:flex;flex-direction:column-reverse;gap:4px}.map-canvas{touch-action:none;-webkit-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent}.mobile-cancel-btn{position:absolute;left:12px;bottom:12px;z-index:25;padding:9px 14px;border-radius:10px;border:2px solid #f87171;background:#0f172aeb;color:#fecaca;font-size:13px;font-weight:800;cursor:pointer;box-shadow:0 8px 22px #0009}.mobile-cancel-btn:active{transform:scale(.96)}.mobile-mini-hud,.mobile-drawer-header{display:none}.side-panel-container{display:contents}@media(max-width:960px){body{padding-bottom:env(safe-area-inset-bottom,0px)}.game-layout{position:fixed;top:0;right:0;bottom:0;left:0;flex-direction:column-reverse;align-items:stretch;padding:4px;padding-bottom:calc(4px + env(safe-area-inset-bottom,0px));gap:4px;height:100dvh;width:100vw;overflow:hidden}.board-wrapper{flex:1;min-height:0;width:100%;max-width:100vw;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:4px;background:#0a1020}.mobile-mode-classic .board-wrapper{flex:0 0 auto;width:100%;max-height:46dvh}.mobile-mode-classic .map-canvas{width:100%;height:auto;max-width:100%;max-height:46dvh}.mobile-mode-classic .side-panel-container{display:flex!important;flex-direction:column;flex:1;min-height:0;overflow-y:auto;-webkit-overflow-scrolling:touch}.mobile-mode-classic .mobile-drawer-header{display:none}.batch-move-bar{position:static;transform:none;order:-1;width:100%;justify-content:space-between;gap:6px;padding:5px 8px;border-radius:8px;font-size:12px}.batch-move-desc{display:none}.batch-move-label{white-space:nowrap}.map-canvas{width:auto;height:auto;max-width:100%;max-height:100%}.mobile-mini-hud{display:flex;flex-direction:column;gap:4px;flex-shrink:0;background:linear-gradient(180deg,#16233b,#0f172a);border:1.5px solid var(--border-gold);border-radius:10px;padding:5px 7px}.mobile-hud-top-row{display:flex;align-items:center;justify-content:space-between;gap:6px}.mobile-hud-summary{flex:1;min-width:0;display:flex;align-items:center;gap:5px;background:transparent;border:none;color:#f8fafc;text-align:left;padding:1px 2px;cursor:pointer;overflow:hidden}.mobile-hud-dot{width:8px;height:8px;border-radius:999px;flex-shrink:0;background:#3b82f6}.mobile-hud-dot.enemy{background:#ef4444}.mobile-hud-dot.ally{background:#22c55e}.mobile-hud-turn{font-size:11px;font-weight:900;color:#facc15;background:#facc1529;border:1px solid rgba(250,204,21,.45);border-radius:6px;padding:1px 5px;flex-shrink:0}.mobile-hud-name{font-size:13px;font-weight:800;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mobile-hud-sub{font-size:11px;color:#cbd5e1;white-space:nowrap;flex-shrink:0}.mobile-hud-hp{font-size:11.5px;font-weight:800;color:#4ade80;white-space:nowrap;flex-shrink:0;margin-left:auto}.mobile-compact-stats{display:flex;align-items:center;flex-wrap:wrap;gap:4px 8px;padding:3px 6px;background:#0a101eb8;border-radius:6px;font-size:11px;color:#94a3b8}.mobile-compact-stats strong{color:#f8fafc;margin-left:2px;font-weight:800}.mobile-compact-wpn{margin-left:auto;color:#fde68a;font-weight:700;white-space:nowrap}.mobile-compact-actions{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:4px}.mobile-wide-subbar{display:grid;grid-template-columns:1fr 1fr;gap:6px}.mobile-hud-btn{background:#1e293b;border:1px solid rgba(148,163,184,.45);border-radius:7px;color:#f8fafc;font-size:11px;font-weight:800;padding:5px 4px;cursor:pointer;white-space:nowrap;text-align:center}.mobile-hud-btn:disabled{opacity:.4}.mobile-hud-btn.mode-switch{padding:4px 8px;background:#334155e6;border-color:#facc158c;color:#fde68a;flex-shrink:0}.mobile-hud-btn.active{background:#15803d;border-color:#4ade80}.mobile-hud-btn.danger-on{background:#991b1b;border-color:#f87171}.mobile-hud-btn.endturn{background:linear-gradient(180deg,#2563eb,#1d4ed8);border-color:#60a5fa}.mobile-hud-btn.menu{background:linear-gradient(180deg,#334155,#1e293b);border-color:#94a3b8}.side-panel-container{display:none}.side-panel-container.mobile-open{display:flex!important;flex-direction:column;gap:8px;position:fixed;top:0;right:0;bottom:0;left:0;z-index:100;background:#070b16f7;padding:10px;padding-bottom:calc(18px + env(safe-area-inset-bottom,0px));overflow-y:auto;-webkit-overflow-scrolling:touch}.mobile-drawer-header{display:flex;align-items:center;justify-content:space-between;padding:6px 4px;border-bottom:1px solid rgba(148,163,184,.25);flex-shrink:0}.mobile-drawer-title{font-size:14px;font-weight:800;color:var(--accent-gold)}.side-panel{display:flex!important;flex-direction:column;width:100%;max-width:none;max-height:none;overflow:visible;flex-shrink:0}.action-menu{position:fixed!important;left:50%!important;top:auto!important;right:auto!important;bottom:calc(10px + env(safe-area-inset-bottom,0px))!important;transform:translate(-50%)!important;width:min(94vw,360px);max-height:45dvh;overflow-y:auto;display:grid;grid-template-columns:1fr 1fr;gap:6px;padding:10px;z-index:60;box-shadow:0 12px 36px #000000d9}.action-menu-title{grid-column:1 / -1;margin-bottom:2px}.action-btn{padding:9px 8px;font-size:13px;text-align:center;justify-content:center}.action-menu-footer{grid-column:1 / -1;display:grid;grid-template-columns:1fr 1fr;gap:6px;border-top:1px solid rgba(148,163,184,.25);padding-top:6px;margin-top:2px}.action-btn.wait-btn{background:linear-gradient(180deg,#1e3a5f,#172554);border-color:#60a5fa}.prep-screen{padding:8px}.prep-container{padding:12px;max-height:none}.prep-header{flex-direction:column;align-items:flex-start;gap:10px}.prep-tabs{overflow-x:auto;flex-wrap:nowrap;padding-bottom:4px}.prep-tab{white-space:nowrap;flex-shrink:0}.prep-status-layout,.prep-items-layout,.battle-trade-grid,.prep-status-subgrid{grid-template-columns:1fr}.prep-char-list{display:flex;flex-direction:row;overflow-x:auto;max-height:none;gap:6px;padding-bottom:4px}.prep-char-btn{flex-shrink:0;min-width:108px}.dialogue-container{width:96vw}.dialogue-text{font-size:14px}.forecast-card,.battle-status-modal,.battle-trade-modal{width:96vw;max-height:90dvh;padding:12px}}.exp-toast{position:fixed;left:50%;bottom:24px;transform:translate(-50%);z-index:95;width:min(92vw,370px);display:flex;align-items:center;gap:12px;padding:10px 14px;border-radius:12px;background:linear-gradient(180deg,#0f172af5,#0a101efa);border:2px solid var(--border-gold);box-shadow:0 10px 28px #000000b8,0 0 0 1px #facc1540;color:#f8fafc;cursor:pointer;animation:expToastIn .16s ease-out}.exp-toast.level-up{border-color:#fde047;box-shadow:0 10px 30px #000000bf,0 0 18px #facc158c}@keyframes expToastIn{0%{opacity:0;transform:translate(-50%,10px) scale(.96)}to{opacity:1;transform:translate(-50%) scale(1)}}.exp-toast-avatar{width:42px;height:42px;flex-shrink:0;border-radius:8px;background:#1e293bd9;border:1px solid rgba(148,163,184,.35);display:flex;align-items:center;justify-content:center;overflow:hidden}.exp-toast-avatar img{width:38px;height:38px}.exp-toast-body{flex:1;min-width:0;display:flex;flex-direction:column;gap:6px}.exp-toast-head{display:flex;align-items:baseline;justify-content:space-between;gap:8px}.exp-toast-name{display:flex;align-items:baseline;gap:6px;font-weight:800;font-size:14px;color:#f8fafc;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.exp-toast-lv{font-size:12px;font-weight:800;color:#facc15}.exp-toast-gain{font-size:13px;font-weight:900;color:#4ade80;font-variant-numeric:tabular-nums;flex-shrink:0}.exp-toast-gain.low{color:#94a3b8}.exp-toast-gain.high{color:#fde047;text-shadow:0 0 8px rgba(250,204,21,.55)}.exp-toast-gain.lvup{color:#fde047;text-shadow:0 0 10px rgba(250,204,21,.8)}.exp-toast-bar-row{display:flex;align-items:center;gap:7px}.exp-toast-label{font-size:10px;font-weight:900;letter-spacing:.06em;color:#94a3b8}.exp-toast-track{flex:1;height:10px;background:#1e293b;border-radius:999px;border:1px solid rgba(255,255,255,.14);overflow:hidden}.exp-toast-fill{height:100%;border-radius:999px;background:linear-gradient(90deg,#2563eb,#38bdf8 60%,#7dd3fc);box-shadow:0 0 8px #38bdf899}.exp-toast-fill.lvup{background:linear-gradient(90deg,#f59e0b,#facc15 60%,#fef08a);box-shadow:0 0 10px #facc15d9}.exp-toast-num{width:22px;text-align:right;font-size:13px;font-weight:900;color:#e2e8f0;font-variant-numeric:tabular-nums}@media(max-width:960px){.exp-toast{bottom:18px;padding:9px 12px}}.endturn-confirm-card{max-width:440px!important}.endturn-confirm-msg{font-size:13px;color:#e2e8f0;text-align:center;line-height:1.6;margin-bottom:12px}.endturn-confirm-msg strong{color:#fde047;font-size:15px}.endturn-unacted-box{background:#0f172ab8;border:1px solid rgba(148,163,184,.28);border-radius:10px;padding:9px 10px;margin-bottom:14px}.endturn-unacted-hint{font-size:11px;color:#94a3b8;margin-bottom:7px;text-align:center}.endturn-unacted-list{display:flex;flex-wrap:wrap;justify-content:center;gap:6px;max-height:180px;overflow-y:auto}.endturn-unit-chip{display:inline-flex;align-items:center;gap:5px;padding:4px 9px 4px 5px;border-radius:8px;background:#16233b;border:1px solid rgba(96,165,250,.45);color:#f8fafc;font-size:12px;font-weight:700;cursor:pointer}.endturn-unit-chip:hover{background:#213455;border-color:#facc15}.endturn-unit-chip img{width:24px;height:24px}.endturn-confirm-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px}.action-btn.wait-btn.armed{background:linear-gradient(180deg,#ca8a04,#a16207)!important;border-color:#fde047!important;color:#fefce8!important;box-shadow:0 0 10px #facc158c}.prep-map-panel{display:flex;flex-direction:column;gap:8px}.prep-map-toolbar{display:flex;flex-wrap:wrap;align-items:center;gap:6px}.prep-map-enemy-count{margin-left:auto;font-size:12px;font-weight:800;color:#fca5a5;background:#7f1d1d59;border:1px solid rgba(248,113,113,.4);border-radius:999px;padding:3px 10px}.prep-map-canvas-wrap{display:flex;justify-content:center;background:#0a1020;border:2px solid var(--border-gold);border-radius:10px;overflow:hidden}.prep-map-canvas{display:block;width:auto;height:auto;max-width:min(100%,960px);max-height:62dvh;cursor:grab}.prep-map-canvas:active{cursor:grabbing}.prep-map-inspect{background:#0f172ad9;border:1px solid rgba(148,163,184,.3);border-radius:8px;padding:8px 11px;min-height:38px;display:flex;align-items:center}.prep-inspect-line{display:flex;flex-wrap:wrap;align-items:center;gap:6px 10px;font-size:12px;color:#e2e8f0}.prep-inspect-tag{font-size:11px;font-weight:800;padding:2px 7px;border-radius:999px;background:#334155;color:#f8fafc}.prep-inspect-tag.player{background:#1d4ed8}.prep-inspect-tag.enemy{background:#b91c1c}.prep-inspect-tag.chest{background:#a16207;color:#fef08a}.prep-inspect-tag.village{background:#15803d;color:#dcfce7}.phase-banner-inner.ally{background:linear-gradient(90deg,transparent,rgba(21,128,61,.94),transparent);border-color:#4ade80;color:#dcfce7;text-shadow:0 2px 10px rgba(20,83,45,.9)}.phase-badge.ally{background:linear-gradient(180deg,#16a34a,#15803d);border:1px solid #86efac;color:#f0fdf4}
