:root{
  --bg:#0b1220; --panel:#121b2e; --panel2:#18243a; --line:#2a3855;
  --text:#eef4ff; --muted:#9fb0ca; --gold:#f4c45e; --danger:#ff6b6b;
  --wei:#3173d8; --shu:#43a85d; --wu:#d84a4a;
}
*{box-sizing:border-box}
html,body{margin:0;background:radial-gradient(circle at 50% 0%,#17243c 0,#0a1020 55%,#070c16 100%);color:var(--text);font-family:system-ui,-apple-system,"Noto Sans KR",sans-serif}
button,input,select,textarea{font:inherit}
button{cursor:pointer}
.app{min-height:100vh;display:grid;grid-template-columns:270px minmax(700px,1fr) 290px;gap:12px;padding:12px}
.panel{background:rgba(18,27,46,.94);border:1px solid var(--line);border-radius:16px;box-shadow:0 12px 40px #0005;overflow:hidden}
.panel h2,.panel h3{margin:0}
.side{padding:14px;display:flex;flex-direction:column;gap:12px}
.brand{padding:4px 0 8px}
.brand h1{font-size:20px;margin:0 0 3px}
.small{font-size:12px;color:var(--muted);line-height:1.5}
.statbox{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.stat{background:#0b1324;border:1px solid #283652;border-radius:12px;padding:10px}
.stat b{display:block;font-size:21px;margin-top:2px}
.gold{color:var(--gold)}
.hpbar{height:10px;background:#222c3d;border-radius:999px;overflow:hidden;margin-top:5px}
.hpfill{height:100%;background:linear-gradient(90deg,#45d36b,#d6dc55);width:100%}
.btnrow{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.btn{border:1px solid #334767;background:#1a2942;color:#fff;border-radius:10px;padding:9px 10px}
.btn:hover{background:#223553}
.btn.primary{background:#2c62ba;border-color:#4f84df}
.btn.warn{background:#7e3e28;border-color:#b76242}
.btn:disabled{opacity:.4;cursor:not-allowed}
.log{height:250px;overflow:auto;background:#080f1d;border:1px solid #22304a;border-radius:12px;padding:8px;font-size:12px;line-height:1.55}
.log div{padding:3px 4px;border-bottom:1px dashed #1f2c42}
.turnbadge{display:inline-flex;align-items:center;gap:6px;background:#0c172a;border:1px solid #334565;border-radius:999px;padding:5px 9px;font-size:12px}

.battle-panel{display:flex;flex-direction:column;min-width:0}
.topbar{height:58px;display:flex;align-items:center;justify-content:space-between;padding:9px 14px;border-bottom:1px solid var(--line);background:#111a2c}
.topbar .title{font-weight:800}
.controls{display:flex;gap:6px;align-items:center;flex-wrap:wrap}
select,input{background:#0d1727;color:#eef4ff;border:1px solid #31415f;border-radius:8px;padding:7px}

.boardwrap{position:relative;flex:1;min-height:740px;overflow:auto;background:
linear-gradient(#0002,#0002),
repeating-linear-gradient(90deg,transparent 0,transparent 79px,#ffffff08 80px),
linear-gradient(180deg,#4a2c2b 0 13%,#3d4a2d 13% 87%,#233d59 87% 100%)}
.board{min-width:680px;max-width:900px;margin:0 auto;padding:10px 16px 14px;display:flex;flex-direction:column;gap:6px}
.basezone{display:grid;grid-template-columns:1fr 1.6fr 1fr;gap:10px;align-items:center;margin:0 auto;width:min(650px,90%)}
.hq{height:80px;border:2px solid #d09943;background:linear-gradient(180deg,#a95f21,#6d341a);border-radius:12px;padding:8px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;box-shadow:0 7px 18px #0006}
.hq.ally{background:linear-gradient(180deg,#2c5aa2,#173b72);border-color:#6aa0ee}
.hq .hptxt{font-weight:900;font-size:20px}
.hq.faction-fortress{
  min-height:112px;height:112px;background-size:cover!important;background-position:center!important;
  overflow:hidden;isolation:isolate;justify-content:flex-end;padding:8px 10px 7px;
}
.hq.faction-fortress::before{
  content:"";position:absolute;inset:0;z-index:-1;background:linear-gradient(180deg,#00000008 0%,#00000030 48%,#000000d8 100%);
}
.hq.faction-fortress::after{
  content:"";position:absolute;inset:0;z-index:-1;box-shadow:inset 0 0 0 1px #ffffff18,inset 0 -35px 45px #0009;pointer-events:none;
}
.hq-title{font-size:11px;font-weight:950;letter-spacing:.08em;text-shadow:0 2px 5px #000;line-height:1.2}
.hq-subtitle{font-size:8px;color:#e8eef7d6;text-shadow:0 1px 4px #000;margin-bottom:1px}
.hq.faction-fortress .hptxt{font-size:18px;text-shadow:0 2px 6px #000}
.hq.faction-fortress.emergency,.hq.faction-fortress.has-base-unit{height:142px}
.hq.faction-fortress .hq-unit-slot{background:#050b13d9;backdrop-filter:blur(2px)}
.advisor{min-height:78px;height:78px;overflow:hidden}
.advisor.has-portrait{padding:4px;background:#0e1827;border-color:#96b36b}
.advisor-card.rich{display:grid;grid-template-columns:46px 1fr;gap:6px;text-align:left;align-items:center;width:100%;height:100%}
.advisor-portrait{width:46px;height:62px;border-radius:7px;overflow:hidden;border:1px solid #d9e99577;background:#16211b}
.advisor-portrait img{width:100%;height:100%;object-fit:cover;display:block}
.advisor-copy{min-width:0;display:flex;flex-direction:column;gap:2px}
.advisor-copy b{font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.hq{position:relative}
.hq.emergency{border-color:#ffb347;box-shadow:0 0 0 2px #ffb34744,0 7px 18px #0006}
.hq.emergency,.hq.has-base-unit{height:116px}
.hq.summon-valid{outline:3px solid #67d87b;box-shadow:0 0 0 5px #67d87b22,0 7px 18px #0006}
.hq-unit-slot{display:none;width:92%;height:38px;margin-top:4px;border:1px dashed #ffffff66;border-radius:7px;background:#07101d99;align-items:center;justify-content:center;overflow:hidden}
.hq.emergency .hq-unit-slot,.hq.has-base-unit .hq-unit-slot{display:flex}
.hq-unit-slot.empty::after{content:"본진 소환 1칸";font-size:9px;color:#d8e5f7aa}
.base-unit{width:100%;height:100%;display:grid;grid-template-columns:30px 1fr auto;align-items:center;gap:5px;padding:3px 5px;border-radius:6px;border:1px solid #8aa5cc;background:#172842;cursor:pointer;position:relative}
.base-unit.wei{border-color:#66a7ff;background:#173a71}.base-unit.shu{border-color:#73df8c;background:#235f31}.base-unit.wu{border-color:#ff8181;background:#6e2424}
.base-unit.selected{outline:2px solid #ffe07d}.base-unit.spent{filter:saturate(.55) brightness(.72)}
.base-unit-art{height:28px;border-radius:4px;overflow:hidden;display:flex;align-items:center;justify-content:center;background:#0004;font-size:18px}.base-unit-art img{width:100%;height:100%;object-fit:cover}
.base-unit-name{min-width:0;font-size:9px;font-weight:900;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.base-unit-stat{font-size:8px;color:#d9e6f8;white-space:nowrap}
.advisor{height:67px;border:2px solid #74aa4e;background:linear-gradient(180deg,#7ec44d,#3b7836);border-radius:12px;padding:5px;display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;font-size:12px;box-shadow:0 5px 14px #0005}
.advisor .mana{font-weight:800;color:#eefdb9}
.advisor{cursor:pointer;position:relative;transition:.15s ease}
.advisor:hover{filter:brightness(1.07)}
.advisor.summon-valid{outline:3px solid #67d87b;box-shadow:0 0 0 5px #67d87b22,0 7px 18px #0006}
.advisor.active{outline:3px solid #ffe07d;box-shadow:0 0 0 5px #ffe07d22,0 7px 18px #0006}
.advisor-card{width:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;line-height:1.15}
.advisor-card b{font-size:12px}
.advisor-card .advisor-meta{font-size:9px;color:#eaf6d6}
.advisor-empty{font-size:10px;color:#e6f5d2aa;line-height:1.35}
.advisor-level{display:inline-flex;align-items:center;gap:4px;background:#101b26aa;border:1px solid #d7ed9a88;border-radius:999px;padding:2px 6px;font-size:9px;font-weight:900}

.lane{position:relative;border:1px solid #ffffff1a;border-radius:14px;padding:6px 8px;background:#0d162654}
.lane .label{position:absolute;left:8px;top:6px;font-size:11px;color:#d7e2f2aa;z-index:2}
.slots{display:grid;gap:8px;justify-content:center;min-height:92px;align-items:center}
.slots.n4{grid-template-columns:repeat(4,110px)}
.slots.n3{grid-template-columns:repeat(3,120px)}
.slots.n2{grid-template-columns:repeat(2,132px)}
.slot{height:84px;border:1px dashed #c7d5ef44;border-radius:10px;background:#07101d44;display:flex;align-items:center;justify-content:center;position:relative}
.slot.empty::after{content:"빈칸";font-size:11px;color:#c3d1e455}
.slot.valid{outline:2px solid #67d87b;box-shadow:0 0 0 4px #67d87b26}
.slot.attackable{outline:2px solid #ff6b6b;box-shadow:0 0 0 4px #ff6b6b22}
.slot.movable{outline:2px solid #f1c859;box-shadow:0 0 0 4px #f1c85922}
.slot .move-cost{position:absolute;left:4px;top:4px;z-index:10;background:#5b430ee8;color:#fff3b4;border:1px solid #f1c859;border-radius:999px;padding:2px 6px;font-size:8px;font-weight:950;pointer-events:none}
.slot.supportable{outline:3px solid #58e2d0;box-shadow:0 0 0 5px #58e2d02e,0 0 20px #58e2d033}
.slot.supportable::before{content:"협력 대상";position:absolute;right:4px;top:4px;z-index:8;background:#0a4b46e8;color:#d9fffa;border:1px solid #72f0df;border-radius:999px;padding:2px 6px;font-size:8px;font-weight:900;pointer-events:none}
.support-charge{position:absolute;right:3px;bottom:3px;z-index:4;background:#073f3bde;color:#d8fff9;border:1px solid #65e6d5;border-radius:5px;padding:2px 4px;font-size:8px;font-weight:900}
.support-guide{margin-top:7px;padding:8px 9px;border:1px solid #3aa99c;background:#0b2c2a;border-radius:9px;color:#cffff8;font-size:11px;line-height:1.45}

.river{height:34px;border:1px solid #8ccdf233;border-radius:12px;background:linear-gradient(90deg,#1c587c77,#3b86a877,#1d628477);display:flex;align-items:center;justify-content:center;font-size:11px;letter-spacing:5px;color:#d8f3ff;margin:2px 0}

.unit{width:100%;height:100%;border-radius:9px;border:2px solid #aaa;background:#1e2d48;display:grid;grid-template-rows:auto 1fr auto;overflow:hidden;position:relative;box-shadow:0 5px 12px #0005}
.unit.wei{border-color:#66a7ff;background:linear-gradient(180deg,#255baf,#173a71)}
.unit.shu{border-color:#73df8c;background:linear-gradient(180deg,#3a944f,#235f31)}
.unit.wu{border-color:#ff8181;background:linear-gradient(180deg,#ae3f3f,#6e2424)}
.unit.selected{outline:3px solid #ffe07d;transform:translateY(-2px)}
.unit.spent{filter:saturate(.55) brightness(.72)}
.uname{font-size:12px;font-weight:800;padding:3px 5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background:#0003}
.uimg{display:flex;align-items:center;justify-content:center;font-size:24px;position:relative}
.grade{position:absolute;right:3px;top:3px;font-size:9px;font-weight:950;background:#111d;padding:2px 5px;border-radius:5px;border:1px solid #ffffff55;z-index:3}
.grade-S,.card-grade.grade-S{background:#8a5b08;color:#fff3bd;border-color:#ffd76a}
.grade-R,.card-grade.grade-R{background:#6d285f;color:#ffd8f7;border-color:#e98ad7}
.grade-U,.card-grade.grade-U{background:#205d72;color:#d9f7ff;border-color:#78d8f5}
.grade-C,.card-grade.grade-C{background:#3e4a59;color:#edf3fa;border-color:#9aa9ba}
.stats{display:grid;grid-template-columns:repeat(3,1fr);font-size:10px;text-align:center;background:#050a12aa;padding:3px}
.buff{position:absolute;left:3px;top:23px;background:#f7c64d;color:#1a1405;font-size:9px;font-weight:800;border-radius:5px;padding:2px 4px}
.typeicon{position:absolute;left:3px;bottom:3px;font-size:11px;background:#0008;border-radius:5px;padding:2px 4px}

.handbox{border-top:1px solid var(--line);background:#0d1628;padding:8px 10px}

.bottom-hud{
  position:sticky;
  bottom:0;
  z-index:25;
  background:linear-gradient(180deg,#101a2d 0%,#0b1322 100%);
  border-top:2px solid #354b70;
  box-shadow:0 -12px 28px #0009;
}
.hud-status{
  display:grid;
  grid-template-columns:72px 90px 92px 72px minmax(135px,1fr) minmax(135px,1fr) 95px auto;
  gap:7px;
  align-items:stretch;
  padding:8px 10px 5px;
}
.hud-block,.hud-hp{
  min-height:52px;
  border:1px solid #2e405f;
  background:#0a1323;
  border-radius:10px;
  padding:6px 8px;
  display:flex;
  flex-direction:column;
  justify-content:center;
}
.hud-block b{
  font-size:19px;
  line-height:1.1;
}
.hud-block.ap{
  border-color:#b88929;
  background:linear-gradient(180deg,#362b14,#18160f);
}
.hud-block.ap b{
  font-size:25px;
  text-shadow:0 0 12px #f4c45e66;
}
.hud-label{
  font-size:10px;
  color:#9fb0ca;
  white-space:nowrap;
}
.hud-hp-line{
  display:grid;
  grid-template-columns:46px 1fr;
  gap:7px;
  align-items:center;
}
.hud-hp-line b{font-size:14px}
.hud-hp .hpbar{margin:0;height:9px}
.hud-hp.enemy .hpfill{
  background:linear-gradient(90deg,#ff8e78,#d64444);
}
.hud-actions{
  display:grid;
  grid-template-columns:repeat(2,minmax(78px,1fr));
  gap:5px;
  min-width:180px;
}
.hud-actions .btn{
  padding:5px 7px;
  font-size:11px;
  min-height:24px;
}
.bottom-hud .handbox{
  border-top:1px solid #263854;
  background:#0b1424;
  padding:6px 10px 8px;
}
.bottom-hud .hand{
  min-height:128px;
}
.bottom-hud .card{
  flex-basis:100px;
  height:126px;
  grid-template-rows:19px 50px 19px 1fr;
}
.boardwrap{
  min-height:0 !important;
}
.battle-panel{
  height:calc(100vh - 24px);
}

.handhead{display:flex;justify-content:space-between;align-items:center;margin-bottom:7px}
.hand{display:flex;gap:7px;overflow-x:auto;padding-bottom:4px;min-height:142px}
.card{flex:0 0 106px;height:138px;border:2px solid #5577a7;border-radius:10px;background:#20385e;display:grid;grid-template-rows:20px 58px 20px 1fr;overflow:hidden;position:relative;box-shadow:0 5px 12px #0005}
.card.wei{border-color:#65a0ff;background:#2558a0}
.card.shu{border-color:#6fd47f;background:#3b8c49}
.card.wu{border-color:#ff7777;background:#a94141}
.card.item{border-color:#e4c16b;background:#6a5426}
.card.tactic{border-color:#be8cff;background:#56388a}
.card.support{border-color:#75e7d4}
.card.advisor-card-hand{border-color:#d7ed79;background:linear-gradient(180deg,#5c6f2b,#26361c)}
.card.selected{outline:3px solid #ffe47b;transform:translateY(-4px)}
.cname{font-size:11px;font-weight:900;padding:2px 4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background:#0004}
.cimg{display:flex;align-items:center;justify-content:center;font-size:30px;background:#ead9c355;color:#101623}
.cstats{font-size:9px;text-align:center;padding:2px;background:#0006}
.ctext{font-size:9px;line-height:1.25;padding:4px;overflow:hidden}
.cost{position:absolute;right:4px;top:23px;background:#0b1527;border-radius:999px;width:22px;height:22px;display:flex;align-items:center;justify-content:center;font-size:11px;font-weight:900;color:#ffd96a;border:1px solid #d1a63f}
.card-grade{position:absolute;left:4px;top:23px;z-index:4;border-radius:999px;padding:2px 6px;font-size:8px;font-weight:950;border:1px solid #ffffff66;box-shadow:0 2px 6px #0007}

.right-section{border:1px solid #293854;border-radius:12px;overflow:hidden}
.right-title{padding:8px 10px;background:#0b1424;font-size:13px;font-weight:800;border-bottom:1px solid #293854}
.details{padding:10px;font-size:12px;line-height:1.55;min-height:170px}
.skilllist{display:grid;gap:7px;padding:8px}
.skill{border:1px solid #3b4e71;background:#14233c;border-radius:9px;padding:8px;color:#fff;text-align:left}
.skill b{display:block;font-size:12px}
.skill span{font-size:10px;color:#aabbd3}
.legend{display:grid;grid-template-columns:1fr 1fr;gap:6px;font-size:11px}
.legend div{padding:6px;border-radius:7px;background:#0b1424}
.dot{display:inline-block;width:9px;height:9px;border-radius:50%;margin-right:5px}
.admin{max-height:300px;overflow:auto;padding:9px}
.admin label{font-size:10px;color:#9fb0ca;display:block;margin-top:5px}
.admin input,.admin select,.admin textarea{width:100%;padding:6px;font-size:11px}
.admin textarea{height:55px;resize:vertical}
.notice{background:#392f17;border:1px solid #6f5a20;color:#f1da93;padding:7px 9px;border-radius:9px;font-size:11px;line-height:1.5}

.modal{position:fixed;inset:0;background:#000a;display:none;align-items:center;justify-content:center;z-index:50}
.modal.show{display:flex}
.modalbox{width:min(680px,94vw);max-height:88vh;overflow:auto;background:#111a2d;border:1px solid #40506d;border-radius:16px;padding:16px}
.rules{font-size:13px;line-height:1.65}
.rules ol{padding-left:22px}
.win{font-size:32px;font-weight:950;text-align:center;margin:16px 0}
@media (max-width:1180px){
  .app{grid-template-columns:220px minmax(650px,1fr)}
  .right{grid-column:1 / -1;display:grid;grid-template-columns:repeat(3,1fr)}
}
@media (max-width:850px){
  .app{display:block;padding:6px}
  .side{margin-bottom:8px}
  .left{display:grid;grid-template-columns:1fr 1fr}
  .left .brand,.left .log{grid-column:1/-1}
  .boardwrap{min-height:720px}
  .right{display:block}
}

@media (max-width:1300px){
  .hud-status{
    grid-template-columns:65px 78px 82px 62px minmax(120px,1fr) minmax(120px,1fr) 85px;
  }
  .hud-actions{
    grid-column:1/-1;
    grid-template-columns:repeat(4,1fr);
  }
}
@media (max-width:850px){
  .battle-panel{height:auto;min-height:100vh}
  .bottom-hud{position:sticky;bottom:0}
  .hud-status{
    grid-template-columns:repeat(4,1fr);
  }
  .hud-hp{
    grid-column:span 2;
  }
  .hud-block.mana{
    grid-column:span 2;
  }
  .hud-actions{
    grid-column:span 2;
    grid-template-columns:repeat(2,1fr);
    min-width:0;
  }
  .bottom-hud .hand{
    min-height:118px;
  }
  .bottom-hud .card{
    flex-basis:92px;
    height:116px;
  }
}

.lane.captured-ally{
  border-color:#6fb0ff;
  box-shadow:inset 0 0 0 1px #6fb0ff55, 0 0 18px #2d70d844;
}
.lane.captured-enemy{
  border-color:#ff7a7a;
  box-shadow:inset 0 0 0 1px #ff7a7a55, 0 0 18px #d84a4a44;
}
.lane .capture-tag{
  position:absolute;
  right:8px;
  top:5px;
  z-index:3;
  font-size:10px;
  font-weight:900;
  border-radius:999px;
  padding:2px 7px;
  background:#09111dcc;
  border:1px solid #ffffff2b;
}
.lane.captured-ally .capture-tag{color:#8dc2ff}
.lane.captured-enemy .capture-tag{color:#ff9a9a}

.game-toast-wrap{
  position:fixed;left:50%;top:72px;transform:translateX(-50%);
  z-index:120;display:flex;flex-direction:column;gap:8px;
  width:min(520px,92vw);pointer-events:none;
}
.game-toast{
  pointer-events:auto;
  border:1px solid #49617f;background:#101c30ee;color:#f6f9ff;
  border-radius:12px;padding:11px 14px;box-shadow:0 12px 34px #0009;
  font-size:13px;line-height:1.45;animation:toastIn .16s ease-out;
}
.game-toast strong{display:block;font-size:13px;margin-bottom:2px}
.game-toast.info{border-color:#4d7cc2;background:#102344f2}
.game-toast.error{border-color:#d45d5d;background:#401b22f2}
.game-toast.success{border-color:#55a96d;background:#173622f2}
.game-toast.warn{border-color:#d2a545;background:#403319f2}
.game-toast.equipment-event{position:relative;overflow:hidden;border-width:2px;box-shadow:0 16px 42px #000a,0 0 18px #ffffff15;animation:equipmentToastIn .42s cubic-bezier(.2,.9,.2,1.05)}
.game-toast.equipment-event::after{content:'';position:absolute;inset:-40% auto auto -30%;width:55%;height:190%;background:linear-gradient(90deg,transparent,#ffffff80,transparent);transform:rotate(18deg);animation:equipmentShine 1.05s ease-out 1}
.game-toast.equipment-destroy{border-color:#ff9867;background:linear-gradient(135deg,#5b1e10f5,#28110af5 60%,#130c09f5)}
.game-toast.equipment-steal{border-color:#74d8ff;background:linear-gradient(135deg,#0f3353f5,#0b1d34f5 60%,#091118f5)}
@keyframes toastIn{from{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}
@keyframes equipmentToastIn{0%{opacity:0;transform:translateY(-18px) scale(.92)}55%{opacity:1;transform:translateY(3px) scale(1.03)}100%{opacity:1;transform:translateY(0) scale(1)}}
@keyframes equipmentShine{from{transform:translateX(-160%) rotate(18deg)}to{transform:translateX(270%) rotate(18deg)}}

.card-art-img,.unit-art-img{width:100%;height:100%;object-fit:cover;display:block}
.cimg,.uimg{overflow:hidden}
.default-art{width:100%;height:100%;display:flex;align-items:center;justify-content:center;position:relative;overflow:hidden;background:radial-gradient(circle at 30% 25%,#ffffff55 0,#ffffff15 16%,transparent 18%),linear-gradient(180deg,#334a73 0,#17253e 100%)}
.default-art::after{content:'';position:absolute;inset:10% 16%;border-radius:16px;background:radial-gradient(circle at 50% 35%,#ffffff3d 0,#ffffff15 22%,transparent 23%),linear-gradient(180deg,#ffffff14,#00000018);border:1px solid #ffffff24;box-shadow:inset 0 0 18px #00000022}
.default-art span{position:relative;z-index:1;font-size:28px;filter:drop-shadow(0 4px 8px #0008)}
.default-art.card span{font-size:34px}
.default-art.card.wei{background:radial-gradient(circle at 25% 20%,#ffffff4d 0,#ffffff12 18%,transparent 20%),linear-gradient(180deg,#3d6ec8 0,#1d3663 100%)}
.default-art.card.shu{background:radial-gradient(circle at 25% 20%,#ffffff4d 0,#ffffff12 18%,transparent 20%),linear-gradient(180deg,#49a866 0,#234b2d 100%)}
.default-art.card.wu{background:radial-gradient(circle at 25% 20%,#ffffff4d 0,#ffffff12 18%,transparent 20%),linear-gradient(180deg,#cf5b5b 0,#5e2424 100%)}
.default-art.card.item,.default-art.unit.item{background:radial-gradient(circle at 25% 20%,#fff4c455 0,#fff0bc18 18%,transparent 20%),linear-gradient(180deg,#9d7a2f 0,#4b3813 100%)}
.default-art.card.tactic,.default-art.unit.tactic{background:radial-gradient(circle at 25% 20%,#f0dcff55 0,#f0dcff18 18%,transparent 20%),linear-gradient(180deg,#7656aa 0,#342155 100%)}
.default-art.card.support,.default-art.unit.support{background:radial-gradient(circle at 25% 20%,#ffffff55 0,#ffffff12 18%,transparent 20%),linear-gradient(180deg,#5f7ab3 0,#24314f 100%)}
.default-art.card.advisor,.default-art.unit.advisor{background:radial-gradient(circle at 25% 20%,#f7ffd855 0,#efff9a18 18%,transparent 20%),linear-gradient(180deg,#71834a 0,#2b371f 100%)}

.card-manager-box{
  width:min(1180px,96vw);height:min(820px,92vh);padding:0;overflow:hidden;
  display:grid;grid-template-rows:58px 1fr;background:#0c1424;
}
.manager-head{
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:10px 14px;border-bottom:1px solid #32425f;background:#121d31;
}
.manager-head h2{font-size:18px;margin:0}
.manager-main{display:grid;grid-template-columns:320px 1fr;min-height:0}
.manager-list-pane{border-right:1px solid #2d3d59;padding:10px;display:flex;flex-direction:column;gap:8px;min-height:0}
.manager-search{display:grid;grid-template-columns:1fr 94px;gap:6px}
.manager-list{overflow:auto;display:flex;flex-direction:column;gap:6px;padding-right:3px}
.manager-card-row{
  border:1px solid #2e405e;background:#101b2e;color:#fff;border-radius:9px;
  display:grid;grid-template-columns:48px 1fr auto;gap:8px;align-items:center;
  padding:6px;text-align:left;cursor:pointer;
}
.manager-card-row:hover,.manager-card-row.active{border-color:#6c95d2;background:#172844}
.manager-thumb{width:48px;height:58px;border-radius:6px;background:#23324b;overflow:hidden;display:flex;align-items:center;justify-content:center;font-size:22px}
.manager-row-name{font-weight:800;font-size:12px}
.manager-row-meta{font-size:10px;color:#9fb1cb;margin-top:2px}
.manager-edit-pane{overflow:auto;padding:14px}
.manager-grid{display:grid;grid-template-columns:220px 1fr;gap:16px}
.manager-preview-wrap{display:flex;flex-direction:column;gap:8px}
.manager-preview{
  height:300px;border:2px solid #4a6388;border-radius:14px;overflow:hidden;
  background:#1d2b43;display:flex;align-items:center;justify-content:center;font-size:62px;
}
.manager-preview img{width:100%;height:100%;object-fit:cover}
.manager-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.manager-field{display:flex;flex-direction:column;gap:4px}
.manager-field.full{grid-column:1/-1}
.manager-field label{font-size:10px;color:#9fb0ca}
.manager-field input,.manager-field select,.manager-field textarea{width:100%;background:#091321;color:#fff;border:1px solid #334763;border-radius:8px;padding:8px}
.manager-field textarea{min-height:84px;resize:vertical}
.manager-actions{display:flex;gap:7px;flex-wrap:wrap;margin-top:12px}
.manager-help{font-size:11px;color:#99abc3;line-height:1.55;background:#0a1322;border:1px solid #283852;border-radius:9px;padding:9px}
@media(max-width:850px){
  .card-manager-box{height:94vh}
  .manager-main{grid-template-columns:1fr;grid-template-rows:210px 1fr}
  .manager-list-pane{border-right:0;border-bottom:1px solid #2d3d59}
  .manager-grid{grid-template-columns:1fr}
  .manager-preview{height:220px}
  .manager-form{grid-template-columns:1fr}
}

:root{
  --ref-bg:#070b0c;--ref-panel:#0b1113;--ref-panel2:#111719;
  --ref-gold:#b9853e;--ref-gold2:#e0b36a;--ref-copper:#74451d;
  --ref-red:#8e251d;--ref-blue:#1f527b;--ref-text:#e7dfcf;--ref-muted:#a69a86;
  --castle-wei:url("../images/castle_wei.jpg");
  --castle-shu:url("../images/castle_shu.jpg");
  --castle-wu:url("../images/castle_wu.jpg");
}
html,body{height:100%;overflow:hidden;background:#050708;color:var(--ref-text);font-family:"Malgun Gothic","Noto Sans KR",system-ui,sans-serif}
body{background:
  radial-gradient(circle at 50% 38%,#34251435 0 18%,transparent 52%),
  repeating-linear-gradient(0deg,#ffffff018 0 1px,transparent 1px 4px),
  linear-gradient(180deg,#080c0d,#040607)}
.app{height:100vh;min-height:720px;display:grid;grid-template-columns:230px minmax(720px,1fr) 350px;gap:4px;padding:4px}
.panel{border-radius:0;border:1px solid #5d3d1e;background:linear-gradient(180deg,#0b1113f7,#070b0df7);box-shadow:inset 0 0 0 1px #16100a,inset 0 0 32px #000b,0 0 0 1px #000;position:relative}
.panel::before,.panel::after{content:"";position:absolute;width:22px;height:22px;pointer-events:none;z-index:40;opacity:.85}
.panel::before{left:3px;top:3px;border-left:2px solid #8f622d;border-top:2px solid #8f622d}
.panel::after{right:3px;bottom:3px;border-right:2px solid #8f622d;border-bottom:2px solid #8f622d}
.side{padding:0;gap:0;min-height:0}
.small{color:#9d927f}

.reference-left{display:flex;flex-direction:column;overflow:hidden}
.reference-brand{height:94px;min-height:94px;padding:13px 15px 8px;border-bottom:1px solid #68441f;background:linear-gradient(180deg,#0a0f10,#070a0b)}
.reference-brand h1{margin:0;font-family:"Malgun Myeongjo","Batang",serif;font-size:31px;line-height:1.05;letter-spacing:-1.7px;color:#d7a65b;text-shadow:0 2px 0 #241608,0 0 15px #b87d3340}
.reference-brand h1::first-letter{font-size:37px}
.brand-sub{font-size:15px;font-weight:800;letter-spacing:.14em;color:#d6a14d;margin-top:8px}
.ornate-title{height:28px;display:flex;align-items:center;justify-content:center;border-bottom:1px solid #6a4624;background:linear-gradient(180deg,#15202a,#0b1116);font-size:13px;font-weight:900;color:#d7dbe1;letter-spacing:.05em;text-shadow:0 1px #000}
.ornate-title.enemy{color:#e47462;background:linear-gradient(180deg,#251411,#130b09)}
.ornate-title.ally{color:#71aee3;background:linear-gradient(180deg,#10202c,#0a1218)}
.left-status-frame{border-bottom:1px solid #69451f;background:linear-gradient(180deg,#0b1721,#071017);padding-bottom:5px}
.left-stat-row,.resource-line{min-height:37px;display:flex;align-items:center;justify-content:space-between;padding:0 15px;border-bottom:1px solid #273139;font-size:13px}
.left-stat-row span,.resource-line span{color:#b7afa1}
.left-stat-row b,.resource-line b{font-size:16px;color:#ede4d4}
.hp-value{color:#d9e7f6!important} .hp-value::first-letter{color:#4f98d0}
.mana-value{color:#d7e9fb!important}
.left-ap-row{display:flex;align-items:center;justify-content:space-between;padding:3px 15px 0;color:#baaa90;font-size:12px}
.left-ap-row b{font-size:21px;color:#e2b45e}
.left-advisor-frame{border-bottom:1px solid #69451f;background:linear-gradient(180deg,#101519,#090d0f)}
.advisor-mirror{height:108px;padding:7px 8px;display:flex;align-items:center;justify-content:center;background:radial-gradient(circle at 35% 20%,#263849 0,transparent 44%),#0b1114}
.advisor-mirror-empty{font-size:11px;color:#7e7669;text-align:center;line-height:1.5}
.advisor-mirror-card{width:100%;height:100%;display:grid;grid-template-columns:76px 1fr;gap:8px;align-items:center}
.advisor-mirror-art{height:92px;border:1px solid #8d6738;background:#13191d;overflow:hidden;box-shadow:inset 0 0 0 1px #000}
.advisor-mirror-art img,.advisor-mirror-art .default-art{width:100%;height:100%;object-fit:cover}
.advisor-mirror-copy b{display:block;color:#e7d0a4;font-size:14px;margin-bottom:4px}
.advisor-mirror-copy span{display:block;color:#b7ac9a;font-size:10px;line-height:1.45}
.advisor-switch{width:calc(100% - 16px);margin:0 8px 5px;min-height:29px;padding:4px}
.compact-skills{padding:0 8px 7px}
.compact-skills .notice{padding:5px 6px;margin-bottom:5px;font-size:9px;line-height:1.35;border-radius:2px;background:#1a1610;border-color:#5d4c2c;color:#cbb98d}
.compact-skill-grid{display:grid;grid-template-columns:1fr 1fr;gap:4px}
.compact-skill-grid .skill,.compact-skill-grid .btn{min-height:35px;padding:4px 5px;border-radius:2px}
.compact-skill-grid .skill b{font-size:10px} .compact-skill-grid .skill span{font-size:8px}
.left-log-frame{flex:1;min-height:130px;display:flex;flex-direction:column;background:#080c0e}
.left-log-frame .log{flex:1;height:auto;margin:6px 7px;border-radius:0;border:1px solid #46341f;background:#050809;padding:5px;font-size:10px;line-height:1.55;color:#aeb7bd}
.log div{border-bottom:0;padding:1px 2px}
.log div:nth-child(4n+1){color:#e4b756} .log div:nth-child(4n+2){color:#79acd5} .log div:nth-child(4n+3){color:#d56a4e}
.left-bottom-actions{min-height:74px;padding:9px 16px;display:grid;grid-template-columns:1fr;gap:6px;border-top:1px solid #5d3c1d;background:#090c0d}
.left-bottom-actions .btn{min-height:27px}

.battle-panel{height:calc(100vh - 8px);min-height:0;display:flex;flex-direction:column;overflow:hidden}
.reference-topbar{height:96px;min-height:96px;padding:8px 10px;display:grid;grid-template-columns:minmax(380px,1.4fr) 150px minmax(300px,1fr);grid-template-rows:1fr 24px;gap:4px 8px;border-bottom:1px solid #6e4a24;background:linear-gradient(180deg,#0f171a,#090e10)}
.top-control-group{display:flex;gap:8px;align-items:center}
.top-field{display:flex;flex-direction:column;gap:3px;font-size:10px;color:#b39e7d}
.top-field select{min-width:126px}
.top-new{height:38px;margin-top:14px;min-width:96px}
.turn-plate{grid-row:1;grid-column:2;align-self:stretch;display:flex;flex-direction:column;align-items:center;justify-content:center;border:1px solid #8e622b;background:linear-gradient(180deg,#121a1d,#080d0f);box-shadow:inset 0 0 16px #000}
.turn-plate>div{font-family:"Malgun Myeongjo",serif;font-size:15px;color:#dcc9a5}
.turn-plate b{font-size:31px;color:#e5c288;margin-right:4px}
.turn-plate .turnbadge{margin-top:1px;border:0;background:transparent;color:#53aee3;font-weight:900;font-size:12px;padding:1px}
.top-options{display:grid;grid-template-columns:1fr 1fr auto;grid-template-rows:1fr 1fr;gap:4px 8px;align-items:center}
.checkline{display:flex;align-items:center;gap:6px;font-size:12px;color:#d0c5b4}
.checkline input{accent-color:#759e4a;width:18px;height:18px}
.top-options #cardManagerBtn{grid-column:3;grid-row:1/3;min-width:88px}
.top-options #rulesTopBtn{display:none}
.faction-pickers{grid-column:1/4;display:flex;justify-content:flex-end;gap:12px;align-items:center;border-top:1px solid #273036;padding-top:3px;font-size:9px;color:#8f8779}
.faction-pickers label{display:flex;gap:4px;align-items:center}
.faction-pickers select{padding:2px 6px;font-size:10px;min-width:70px}
select,input{border-radius:2px;background:#0b1113;border:1px solid #4b5356;color:#e2ded4;padding:7px 9px}
.btn{border-radius:2px;border:1px solid #775329;background:linear-gradient(180deg,#151b1d,#080c0d);color:#e3dac9;box-shadow:inset 0 0 0 1px #000;padding:7px 10px}
.btn:hover{background:linear-gradient(180deg,#232a2b,#0d1112)}
.btn.primary{background:linear-gradient(180deg,#174776,#0b2b4c);border-color:#7d9bb7}
.btn.warn{background:linear-gradient(180deg,#4a2116,#1d0e0a);border-color:#8c542f}

.boardwrap{flex:1;min-height:0!important;overflow:hidden;background:
  radial-gradient(circle at 50% 35%,#5f492f30,transparent 38%),
  repeating-linear-gradient(90deg,transparent 0 119px,#b7843320 120px,#0000 121px),
  repeating-linear-gradient(0deg,#ffffff08 0 1px,transparent 1px 5px),
  linear-gradient(180deg,#2d2118 0 48%,#241b14 48% 52%,#2c2118 52% 100%)}
.board{height:100%;min-width:0;max-width:none;width:100%;margin:0;padding:4px 7px;gap:2px;justify-content:space-between}
.basezone{width:100%;height:142px;display:grid;grid-template-columns:138px minmax(0,1fr);grid-template-rows:69px 69px;gap:4px;margin:0;align-items:stretch}
.basezone>.advisor:first-child{grid-column:1;grid-row:1}
.basezone>.advisor:last-child{grid-column:1;grid-row:2}
.basezone>.hq{grid-column:2;grid-row:1/3}
.advisor{height:auto!important;min-height:0!important;border-radius:0;border:1px solid #72502c;background:linear-gradient(180deg,#15191a,#090c0d);padding:3px;box-shadow:inset 0 0 0 1px #000;overflow:hidden}
.advisor.has-portrait{background:#0b0f11;border-color:#805a32;padding:3px}
.advisor-card.rich{grid-template-columns:48px 1fr;gap:5px}
.advisor-portrait{width:48px;height:60px;border-radius:0;border-color:#72583a}
.advisor-copy b{font-size:9px;color:#e2c693} .advisor-copy .advisor-meta{font-size:8px} .advisor-level{font-size:8px;padding:1px 4px}
.hq.faction-fortress{height:142px!important;min-height:142px!important;border-radius:0;border:1px solid #9a6b31;background-color:#15110d;background-size:cover!important;background-position:center 45%!important;padding:0;justify-content:flex-end;box-shadow:inset 0 0 0 1px #000,0 0 0 1px #211306;overflow:hidden}
.hq.faction-fortress::before{background:linear-gradient(180deg,#00000010 0,#0000 45%,#000b 100%)}
.hq.faction-fortress::after{box-shadow:inset 0 0 40px #0008,inset 0 -42px 35px #000b}
.hq-title{position:absolute;top:0;left:50%;transform:translateX(-50%);min-width:210px;padding:5px 24px 6px;background:linear-gradient(180deg,#4b1c12,#291009);border:1px solid #a66d35;color:#efc99a;font-size:12px;clip-path:polygon(8% 0,92% 0,100% 50%,92% 100%,8% 100%,0 50%);z-index:3}
#allyHq .hq-title{background:linear-gradient(180deg,#17334b,#0c1b29);border-color:#5b7590;color:#bcd7ed}
.hq-subtitle{position:absolute;top:31px;left:12px;font-size:8px;color:#d8c7afaa}
.hq.faction-fortress .hptxt{position:relative;z-index:3;margin:0 auto 5px;padding:3px 12px;background:#080806d6;border:1px solid #6e5438;color:#e6dbcb;font-size:18px}
.hq.faction-fortress .hptxt::before{content:"♥ ";color:#b84930}
.hq-unit-slot{position:absolute;right:8px;bottom:6px;width:125px;height:34px;margin:0;border-radius:0}
.lane{min-height:55px;flex:1;border-radius:0;border:1px solid #6a4d2a55;padding:1px 5px;background:linear-gradient(180deg,#1f171147,#130f0b38);box-shadow:inset 0 0 18px #0004}
.lane .label{left:5px;top:3px;font-size:8px;color:#9e8a6b88}
.slots{min-height:52px;height:100%;gap:4px;align-items:center}
.slots.n4{grid-template-columns:repeat(4,minmax(70px,112px))}
.slots.n3{grid-template-columns:repeat(3,minmax(72px,116px))}
.slots.n2{grid-template-columns:repeat(2,minmax(76px,120px))}
.slot{height:50px;border-radius:0;border:1px solid #76522673;background:linear-gradient(135deg,#21170f80,#0f0b0780);box-shadow:inset 0 0 12px #0007}
.slot.empty::after{content:"✥";font-family:serif;font-size:25px;color:#7250257a;text-shadow:0 1px #000}
.slot.valid,.slot.attackable,.slot.movable,.slot.supportable{box-shadow:inset 0 0 0 1px currentColor,0 0 10px currentColor}
.river{height:17px;min-height:17px;border-radius:0;border:0;border-top:1px solid #6d4d2a;border-bottom:1px solid #4c351d;background:linear-gradient(90deg,#342619,#5e4323,#342619);color:#a88757;font-size:8px;letter-spacing:.55em;margin:0}
.unit{border-radius:0;border-width:1px;grid-template-rows:14px 1fr 14px;box-shadow:0 2px 4px #0008;background:#171717!important}
.unit.wei{border-color:#547ea7} .unit.shu{border-color:#688a53} .unit.wu{border-color:#a34e3b}
.uname{font-size:9px;padding:1px 3px;background:#050505c9;text-align:center}
.uimg{font-size:16px;background:#221d17}
.stats{font-size:8px;padding:1px;background:#050505db}
.grade{font-size:6px;padding:1px 3px;right:1px;top:1px;border-radius:1px}
.typeicon{font-size:8px;left:1px;bottom:1px;padding:1px 2px}
.buff,.support-charge{font-size:6px;padding:1px 2px}

.bottom-hud{height:154px;min-height:154px;position:relative;bottom:auto;display:grid;grid-template-columns:minmax(0,1fr) 145px;background:linear-gradient(180deg,#0f1517,#070b0c);border-top:1px solid #785429;box-shadow:0 -4px 15px #000b}
.bottom-hud .hud-status{grid-column:2;grid-row:1;padding:8px;display:block;background:#090d0f}
.bottom-hud .hud-status>:not(.hud-actions){display:none}
.hud-actions{display:grid;grid-template-columns:1fr;gap:7px;min-width:0;height:100%;align-content:center}
.hud-actions .btn{min-height:28px;padding:5px;font-size:11px}
.bottom-hud .handbox{grid-column:1;grid-row:1;border:0;padding:6px 8px;background:#0b1012;min-width:0}
.handhead{height:18px;margin-bottom:3px;font-size:10px;color:#b6a688}
.handhead .small{font-size:8px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:70%}
.bottom-hud .hand{height:121px;min-height:121px;gap:5px;overflow-x:auto;overflow-y:hidden}
.bottom-hud .card{flex:0 0 96px;height:118px;border-radius:0;border-width:1px;grid-template-rows:17px 52px 17px 1fr;box-shadow:0 2px 5px #000a;background:#181511!important}
.card.wei{border-color:#4f7eaa} .card.shu{border-color:#608955} .card.wu{border-color:#a44d3d} .card.item{border-color:#a37d3a} .card.tactic{border-color:#8b5d9d}
.cname{font-size:9px;text-align:center;padding:2px;background:#050505d0}
.cimg{background:#221d17}
.cstats{font-size:8px;padding:1px} .ctext{font-size:7px;padding:2px;line-height:1.15}
.cost{width:19px;height:19px;right:2px;top:19px;font-size:9px;border-radius:50%;background:#16110b;border-color:#c59b55}
.card-grade{left:2px;top:19px;font-size:6px;padding:1px 4px;border-radius:2px}

.reference-right{display:flex;flex-direction:column;overflow:hidden;padding:0}
.right-resource-frame{height:110px;min-height:110px;border-bottom:1px solid #65411e;background:linear-gradient(180deg,#130d0b,#090b0c)}
.right-resource-frame .resource-line{min-height:38px}
.mana-pips{display:flex;gap:5px}
.mana-pip{width:18px;height:18px;border-radius:50%;border:2px solid #913425;background:radial-gradient(circle at 35% 30%,#ff9c6d 0 16%,#c73524 18% 58%,#4a0f09 60%);box-shadow:0 0 0 1px #d1804b,0 0 6px #b62b1c88 inset}
.roster-section{min-height:0;border-bottom:1px solid #5d3d1d;background:#080c0d;display:flex;flex-direction:column}
.enemy-roster-section{height:37%} .ally-roster-section{height:40%}
.roster-grid{flex:1;display:grid;grid-template-columns:repeat(3,1fr);grid-auto-rows:minmax(0,1fr);gap:4px;padding:4px;overflow:hidden}
.roster-card{position:relative;min-width:0;min-height:0;border:1px solid #6b4e2f;background:#17120e;overflow:hidden;box-shadow:inset 0 0 0 1px #000}
.roster-card.wei{border-color:#426f97} .roster-card.shu{border-color:#557c4d} .roster-card.wu{border-color:#914432}
.roster-art{position:absolute;inset:0 0 22px;overflow:hidden;background:#1d1712}
.roster-art img,.roster-art>.default-art{width:100%;height:100%;object-fit:cover}
.roster-name{position:absolute;left:0;right:0;bottom:11px;height:15px;background:#050505c7;color:#efe5d6;font-size:8px;font-weight:900;text-align:center;line-height:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.roster-stats{position:absolute;left:0;right:0;bottom:0;height:12px;background:#050505e6;display:flex;justify-content:space-around;align-items:center;font-size:7px;color:#e8d6b9}
.roster-cost{position:absolute;left:2px;top:2px;width:17px;height:17px;border-radius:50%;background:#15110b;border:1px solid #b98c4f;color:#f0d5a0;font-size:8px;font-weight:900;display:flex;align-items:center;justify-content:center;z-index:3}
.roster-empty{border:1px solid #3c2f22;background:radial-gradient(circle,#261a1080,#080706);display:flex;align-items:center;justify-content:center;color:#604321;font-size:22px}
.selection-strip{flex:1;min-height:72px;overflow:hidden;background:#090d0f}
.selection-strip .details{min-height:0;height:calc(100% - 28px);padding:5px 7px;font-size:9px;line-height:1.35;overflow:auto;color:#b9b0a2}

.game-toast-wrap{top:102px}
.game-toast{border-radius:2px}
.modalbox{border-radius:2px;border-color:#75512a;background:#0d1214}

@media (max-width:1280px){
  .app{grid-template-columns:205px minmax(650px,1fr) 305px}
  .reference-topbar{grid-template-columns:minmax(315px,1.2fr) 125px minmax(260px,1fr)}
  .top-field select{min-width:105px}
  .reference-brand h1{font-size:27px}
}
@media (max-width:1050px){
  html,body{overflow:auto}
  .app{height:auto;display:grid;grid-template-columns:190px minmax(660px,1fr);min-width:900px}
  .reference-right{grid-column:1/3;height:470px;display:grid;grid-template-columns:220px 1fr 1fr 220px}
  .right-resource-frame,.enemy-roster-section,.ally-roster-section,.selection-strip{height:auto!important;min-height:0}
}

.battle-panel{position:relative}
.reference-topbar{
  position:absolute;top:8px;right:10px;z-index:35;
  width:min(520px,calc(100% - 26px));height:auto;min-height:0;
  padding:7px 10px;display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:auto auto auto;
  gap:6px;border:1px solid #7b5530;background:linear-gradient(180deg,#0e1518f7,#070b0df4);
  box-shadow:inset 0 0 0 1px #000,0 10px 28px #000a;
}
.top-control-group{grid-column:1/3;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) 108px;gap:8px;align-items:end}
.top-field{min-width:0}
.top-field select{width:100%;min-width:0}
.top-new{height:38px;min-width:0;margin-top:0}
.turn-plate{grid-column:1;grid-row:2;min-height:70px}
.top-options{grid-column:2;grid-row:2;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:auto auto;gap:6px;align-content:stretch}
.top-options #cardManagerBtn{grid-column:1;grid-row:2;min-width:0}
.top-options #rulesTopBtn{grid-column:2;grid-row:2;display:block;min-width:0}
.faction-pickers{grid-column:1/3;grid-row:3;justify-content:space-between;padding-top:4px}
.boardwrap{padding-top:122px}
.board{padding:6px 8px 10px;gap:4px}
.basezone{height:172px}
.hq.faction-fortress{height:170px!important;min-height:170px!important}
.hq-title{min-width:225px;font-size:13px}
.hq-subtitle{top:33px;left:14px;font-size:9px}
.hq.faction-fortress .hptxt{display:none}
.hq-unit-slot{right:10px;bottom:8px;width:140px;height:42px;z-index:6}

.hq-info-overlay{position:absolute;left:12px;right:162px;top:44px;display:flex;flex-wrap:wrap;gap:6px;z-index:6;align-items:flex-start}
.hq-stat-chip{display:inline-flex;align-items:center;gap:4px;padding:3px 8px;background:#050608dc;border:1px solid #715332;color:#f1e7d5;font-size:11px;font-weight:800;box-shadow:0 2px 6px #0008}
.hq-stat-chip.hp b{color:#efc7b8}.hq-stat-chip.mp b{color:#d7ecff}.hq-stat-chip.ap b{color:#f0cd7a}.hq-stat-chip.skill b{color:#d5efab}
.hq-advisor-summary{position:absolute;left:12px;right:162px;bottom:10px;min-height:36px;padding:5px 8px;background:linear-gradient(180deg,#050608dc,#030405e6);border:1px solid #6a5032;color:#dfd5c3;font-size:10px;line-height:1.35;z-index:6;display:flex;flex-direction:column;justify-content:center;box-shadow:0 2px 8px #0009}
.hq-advisor-summary b{display:block;font-size:11px;color:#ecd3a6}
#allyHq .hq-advisor-summary b{color:#bad9f4}
#enemyHq .hq-stat-chip{background:#140909dc;border-color:#7c4a36}
#allyHq .hq-stat-chip{background:#071018dc;border-color:#4b667b}
#enemyHq .hq-advisor-summary{background:linear-gradient(180deg,#150a08e6,#090404e6);border-color:#734936}
#allyHq .hq-advisor-summary{background:linear-gradient(180deg,#09111be6,#04080ce6);border-color:#4a647e}

.lane{min-height:76px;padding:3px 8px}
.lane .label{font-size:9px}
.slots{min-height:72px;gap:8px}
.slots.n4{grid-template-columns:repeat(4,minmax(88px,148px))}
.slots.n3{grid-template-columns:repeat(3,minmax(96px,156px))}
.slots.n2{grid-template-columns:repeat(2,minmax(108px,170px))}
.slot{height:68px}
.unit{grid-template-rows:18px 1fr 18px}
.uname{font-size:11px;padding:2px 4px}
.uimg{font-size:20px}
.stats{font-size:10px;padding:2px 3px}
.grade{font-size:7px;padding:1px 4px}
.typeicon{font-size:9px}
.buff,.support-charge{font-size:7px}

.bottom-hud{height:72px;min-height:72px;grid-template-columns:1fr;padding:8px 10px;align-items:center}
.bottom-hud .hud-status{grid-column:1;padding:0;background:transparent}
.bottom-hud .hud-status>:not(.hud-actions){display:none!important}
.hud-actions{grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;height:auto;align-content:stretch}
.hud-actions .btn{min-height:42px;font-size:12px}
.bottom-hud .handbox{display:none!important}

.left-status-frame{display:none}
.left-advisor-frame{flex:0 0 auto}

.reference-right{display:flex;flex-direction:column;overflow:hidden;padding:0}
.right-resource-frame{display:none}
.enemy-roster-section{height:32%;flex:0 0 32%}
.right-deck-section{flex:0 0 118px;display:flex;flex-direction:column;border-bottom:1px solid #5d3d1d;background:#090c0d}
.right-deck-body{flex:1;display:flex;align-items:center;gap:12px;padding:8px 10px}
.deck-stack{position:relative;width:84px;height:108px}
.deck-back,.deck-back::before,.deck-back::after{content:"";position:absolute;inset:0;border:1px solid #826039;background:linear-gradient(180deg,#16202a,#0a1015);box-shadow:inset 0 0 0 1px #000}
.deck-back::before{transform:translate(5px,-5px);opacity:.5}
.deck-back::after{transform:translate(10px,-10px);opacity:.25}
.deck-emblem{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;font-family:"Malgun Myeongjo",serif;font-size:28px;color:#d7bf95;z-index:2;text-shadow:0 2px 8px #000}
.deck-info{display:flex;flex-direction:column;gap:4px;color:#cdbda2;font-size:11px}
.deck-info b{font-size:20px;color:#f0e1c7}
.deck-help{color:#9c917e;line-height:1.35}
.right-hand-section{flex:1;min-height:0;display:flex;flex-direction:column;border-bottom:1px solid #5d3d1d;background:#080c0d}
.right-hand-section .handbox{flex:1;min-height:0;border:0;padding:6px 8px;background:#080c0d;display:flex;flex-direction:column}
.right-hand-section .handhead{height:auto;min-height:28px;margin-bottom:6px;display:flex;justify-content:space-between;align-items:flex-start;gap:8px;font-size:11px;color:#c6b79e}
.right-hand-section .handhead .small{font-size:9px;white-space:normal;max-width:none}
#hand.hand{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;overflow:auto;overflow-x:hidden;padding-bottom:4px;min-height:0;height:100%}
#hand.hand .card{flex:none;width:auto;height:145px;border-radius:0;border-width:1px;grid-template-rows:18px 64px 18px 1fr;box-shadow:0 3px 8px #000a;background:#181511!important}
#hand.hand .cname{font-size:10px}
#hand.hand .cstats{font-size:8px}
#hand.hand .ctext{font-size:8px;line-height:1.2;padding:3px}
.selection-strip{flex:0 0 118px;min-height:118px}
.selection-strip .details{font-size:10px;line-height:1.4}
.title-flex{display:flex;align-items:center;justify-content:space-between;padding:0 10px}
.title-count{font-size:11px;color:#d4c5ad}

@media (max-width:1280px){
  .reference-topbar{width:min(470px,calc(100% - 22px))}
  .slots.n4{grid-template-columns:repeat(4,minmax(80px,132px))}
  .slots.n3{grid-template-columns:repeat(3,minmax(88px,140px))}
  .slots.n2{grid-template-columns:repeat(2,minmax(96px,150px))}
  #hand.hand .card{height:132px}
}
@media (max-width:1050px){
  .reference-topbar{position:relative;top:auto;right:auto;width:auto}
  .boardwrap{padding-top:8px}
  .left-status-frame{display:none}
  .reference-right{grid-column:1/3;height:640px;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:220px 180px 1fr}
  .enemy-roster-section{grid-column:1;grid-row:1/3;height:auto;flex:auto}
  .right-deck-section{grid-column:2;grid-row:1;height:auto}
  .right-hand-section{grid-column:2;grid-row:2/4;height:auto}
  .selection-strip{grid-column:1;grid-row:3;height:auto}
}

.app{grid-template-columns:220px minmax(560px,.82fr) 360px;gap:6px;padding:6px}
.reference-left{overflow:hidden}
.reference-topbar{
  position:relative;top:auto;right:auto;left:auto;z-index:5;
  width:218px;height:auto;min-height:0;margin:8px 0 6px 8px;padding:6px 7px;
  display:grid;grid-template-columns:1fr;grid-template-rows:auto auto auto auto;gap:5px;
  border:1px solid #6f4b27;background:linear-gradient(180deg,#0e1416,#070b0d);box-shadow:inset 0 0 0 1px #000;
}
.top-control-group{grid-column:auto;display:grid;grid-template-columns:1fr 1fr;gap:5px;align-items:end}
.top-field{gap:2px}
.top-field span{font-size:9px;color:#b8a385}
.top-field select{min-width:0;width:100%;padding:5px 6px;font-size:10px}
.top-new{grid-column:1/3;min-width:0;height:28px;font-size:11px;padding:4px 6px}
.turn-plate{grid-column:auto;grid-row:auto;min-height:0;padding:4px 6px;border:1px solid #62462b;background:#0b1012;display:flex;justify-content:center;align-items:center}
.turn-plate>div{display:none}
.turn-plate .turnbadge{margin:0;padding:2px 0;background:transparent;color:#73b9e8;font-size:11px;letter-spacing:.02em}
.top-options{grid-column:auto;grid-row:auto;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:auto auto;gap:4px 6px;align-items:center}
.checkline{gap:4px;font-size:10px}
.checkline input{width:14px;height:14px;padding:0}
.top-options #cardManagerBtn,.top-options #rulesTopBtn{grid-row:2;min-width:0;height:26px;padding:3px 4px;font-size:10px}
.top-options #cardManagerBtn{grid-column:1}.top-options #rulesTopBtn{grid-column:2;display:block}
.faction-pickers{grid-column:auto;display:grid;grid-template-columns:1fr;gap:4px;justify-content:stretch;padding-top:4px;border-top:1px solid #242d32;font-size:9px}
.faction-pickers label{display:flex;justify-content:space-between;gap:6px}
.faction-pickers select{flex:1;min-width:0;font-size:10px;padding:3px 6px}
.boardwrap{padding-top:0;overflow:auto}
.board{width:80%;min-width:540px;max-width:780px;margin:0 auto;padding:4px 0 8px;gap:4px}
.basezone{height:162px}
.hq.faction-fortress{height:162px!important;min-height:162px!important}
.hq-info-overlay{left:10px;right:146px;top:42px;gap:5px}
.hq-stat-chip{padding:3px 6px;font-size:10px}
.hq-advisor-summary{left:10px;right:146px;bottom:8px;min-height:32px;padding:4px 7px;font-size:9px}
.hq-advisor-summary b{font-size:10px}
.enemy-turn-badge{position:absolute;right:10px;bottom:8px;z-index:7;display:flex;align-items:center;justify-content:center;min-width:48px;height:24px;padding:0 8px;background:#07090bdd;border:1px solid #9d6a35;color:#f3d59f;font-size:12px;font-weight:900;box-shadow:0 2px 8px #0009}
#allyHq .enemy-turn-badge{display:none}
.hq-unit-slot{right:10px;bottom:38px;width:122px;height:36px}

.lane{min-height:68px;padding:2px 6px}
.lane .label{font-size:8px}
.slots{min-height:64px;gap:6px}
.slots.n4{grid-template-columns:repeat(4,minmax(72px,120px))}
.slots.n3{grid-template-columns:repeat(3,minmax(80px,128px))}
.slots.n2{grid-template-columns:repeat(2,minmax(90px,136px))}
.slot{height:60px}
.unit{grid-template-rows:16px 1fr 16px}
.uname{font-size:10px;padding:1px 3px}
.uimg{font-size:18px}
.stats{font-size:9px;padding:1px 2px}
.grade{font-size:6px}
.typeicon{font-size:8px}
.buff,.support-charge{font-size:6px}

.bottom-hud{height:66px;min-height:66px;padding:7px 9px}
.hud-actions{grid-template-columns:repeat(4,minmax(0,1fr));gap:7px}
.hud-actions .btn{min-height:38px;font-size:11px}

.enemy-roster-section{height:31%;flex:0 0 31%}
.right-deck-section{flex:0 0 108px}
.right-deck-body{gap:10px;padding:7px 9px}
.deck-stack{width:78px;height:100px}
.deck-info{font-size:10px}
.deck-info b{font-size:18px}
.right-hand-section .handbox{padding:5px 7px}
.right-hand-section .handhead{min-height:24px;margin-bottom:5px;font-size:10px}
.right-hand-section .handhead .small{font-size:8px}
#hand.hand{grid-template-columns:repeat(2,minmax(0,1fr));gap:5px}
#hand.hand .card{height:128px;grid-template-rows:17px 56px 16px 1fr}
#hand.hand .cname{font-size:9px}
#hand.hand .cstats{font-size:7px}
#hand.hand .ctext{font-size:7px;line-height:1.15}
.roster-grid{gap:3px;padding:3px}
.roster-name{font-size:7px}
.roster-stats{font-size:6px}
.selection-strip{flex:0 0 104px;min-height:104px}
.selection-strip .details{font-size:9px}

@media (max-width:1280px){
  .app{grid-template-columns:210px minmax(520px,.78fr) 330px}
  .board{width:82%;min-width:500px;max-width:740px}
  .slots.n4{grid-template-columns:repeat(4,minmax(68px,112px))}
  .slots.n3{grid-template-columns:repeat(3,minmax(76px,120px))}
  .slots.n2{grid-template-columns:repeat(2,minmax(84px,128px))}
  #hand.hand .card{height:120px}
}
@media (max-width:1050px){
  .app{height:auto;grid-template-columns:190px minmax(520px,1fr);min-width:860px}
  .reference-topbar{width:174px;margin:6px 0 6px 6px}
  .top-control-group{grid-template-columns:1fr}
  .top-new{grid-column:1}
  .top-options{grid-template-columns:1fr 1fr}
  .board{width:90%;min-width:460px}
  .reference-right{grid-column:1/3;height:620px;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:200px 160px 1fr}
}

.app{grid-template-columns:210px minmax(560px,.82fr) 370px}
.reference-left{display:flex;flex-direction:column}
.reference-brand{padding:12px 8px 10px}
.reference-brand h1{font-size:26px}
.reference-brand .brand-sub{font-size:12px}
.left-status-frame{display:none}
.left-advisor-frame.compact-settings-holder{display:block;flex:0 0 auto;padding:6px 8px 8px;background:#080c0d;border-top:1px solid #503719;border-bottom:1px solid #503719}
.settings-mini-copy{padding:8px 10px;font-size:10px;line-height:1.45;color:#afa490;background:#101518;border:1px solid #544127}
.left-log-frame{margin-top:6px;min-height:140px}
.left-bottom-actions{padding:8px 12px;grid-template-columns:1fr 1fr;gap:6px}
.left-bottom-actions .btn{min-height:30px}

.reference-topbar{position:relative;width:auto;left:auto;top:auto;right:auto;margin:0 8px 8px;padding:6px;border:1px solid #6e4a24;background:linear-gradient(180deg,#11181b,#090d0f);display:grid;grid-template-columns:1fr;gap:5px;box-shadow:inset 0 0 0 1px #000}
.top-control-group{grid-template-columns:1fr 1fr;gap:5px}
.top-field span{font-size:8px}
.top-field select{padding:4px 6px;font-size:10px}
.top-new{grid-column:1/3;height:28px;font-size:10px;padding:4px 6px}
.turn-plate{min-height:0;padding:4px;border:1px solid #4e3a22;background:#0b1012}
.turn-plate>div{display:none}.turn-plate .turnbadge{font-size:11px}
.top-options{grid-template-columns:1fr 1fr;gap:4px}
.top-options #cardManagerBtn,.top-options #rulesTopBtn{height:26px;padding:3px 4px;font-size:10px}
.checkline{font-size:10px}.checkline input{width:14px;height:14px}
.faction-pickers{display:grid;grid-template-columns:1fr;gap:4px;font-size:9px}
.faction-pickers label{display:flex;justify-content:space-between;gap:6px}
.faction-pickers select{flex:1;min-width:0;padding:3px 6px;font-size:10px}

.board{width:80%;min-width:540px;max-width:780px}
.basezone{height:190px}
.hq.faction-fortress{height:188px!important;min-height:188px!important}
.hq-info-overlay{left:10px;right:158px;top:40px}
.hq-advisor-summary{left:10px;right:158px;bottom:8px;min-height:30px;padding:4px 6px;font-size:9px}
.hq-advisor-console{position:absolute;top:38px;right:8px;bottom:8px;width:142px;display:flex;flex-direction:column;gap:4px;padding:0;z-index:8}
.hq-advisor-console .advisor-mirror.in-castle{height:54px;padding:4px;background:linear-gradient(180deg,#0f1418d9,#090d10d9);border:1px solid #5e4528}
.hq-advisor-console .advisor-mirror-card{grid-template-columns:40px 1fr;gap:5px}
.hq-advisor-console .advisor-mirror-art{height:44px}
.hq-advisor-console .advisor-mirror-copy b{font-size:10px;margin-bottom:1px}
.hq-advisor-console .advisor-mirror-copy span{font-size:8px;line-height:1.25}
.hq-advisor-console .advisor-switch.mini{width:100%;margin:0;min-height:22px;padding:3px 4px;font-size:9px}
.hq-advisor-console .compact-skills.in-castle{padding:0}
.hq-advisor-console .compact-skills .notice{padding:4px 5px;margin:0;font-size:8px;line-height:1.25;background:#16110eda;border:1px solid #5b482c;color:#d3c19e}
.hq-advisor-console .compact-skill-grid{display:grid;grid-template-columns:1fr;gap:3px;margin-top:4px}
.hq-advisor-console .compact-skill-grid .skill,.hq-advisor-console .compact-skill-grid .btn{min-height:26px;padding:3px 4px}
.hq-advisor-console .compact-skill-grid .skill b{font-size:9px}.hq-advisor-console .compact-skill-grid .skill span{font-size:7px;line-height:1.15}
.hq-unit-slot{right:156px;bottom:10px;width:112px;height:34px}

.right-hand-section .handhead{display:none}
#hand.hand{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;padding-right:4px}
#hand.hand .card{position:relative;overflow:visible;height:178px;border:1px solid #7a5a33;background:linear-gradient(180deg,#131517,#0b0d0f)!important;box-shadow:0 3px 10px #000b,inset 0 0 0 1px #000;display:grid;grid-template-rows:18px 92px 1fr}
#hand.hand .card.selected{outline:2px solid #7cbcf7;box-shadow:0 0 0 2px #0e2438,0 0 18px #59a9ff55}
#hand.hand .cname{display:flex;align-items:center;justify-content:center;font-size:10px;font-weight:800;padding:1px 4px;background:linear-gradient(180deg,#3d2a1f,#1c1511);border-bottom:1px solid #7f6039;color:#f2eadf;line-height:1.1}
#hand.hand .cimg{position:relative;background:#1b1713;overflow:hidden;border-bottom:1px solid #3d3024}
#hand.hand .cimg img,#hand.hand .cimg .default-art{width:100%;height:100%;object-fit:cover}
#hand.hand .card-grade{left:4px;top:22px;padding:1px 4px;border-radius:2px;font-size:8px}
#hand.hand .cost{right:4px;top:22px;width:22px;height:22px;font-size:10px}
#hand.hand .cstats{display:grid;grid-template-rows:auto auto;gap:4px;padding:5px 5px 6px;background:linear-gradient(180deg,#131619,#0d1012)}
#hand.hand .card-type-line{display:flex;justify-content:space-between;align-items:center;font-size:8px;color:#d5c7b0}
#hand.hand .card-stat-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:4px}
#hand.hand .card-stat-cell{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:4px 2px;background:#171d22;border:1px solid #374450;min-height:34px}
#hand.hand .card-stat-cell b{font-size:18px;line-height:1;color:#edf3ff}
#hand.hand .card-stat-cell span{font-size:8px;color:#aac3da;letter-spacing:.02em}
#hand.hand .card-stat-cell.subtle{background:#171310;border-color:#5c4a32}
#hand.hand .card-stat-cell.subtle b{font-size:13px;color:#f0dfbf}
#hand.hand .ctext{display:none}
#hand.hand .card-hover-tooltip{position:absolute;left:calc(100% + 8px);top:6px;width:190px;padding:8px 10px;background:#111316f2;border:1px solid #8b673a;color:#ede4d4;font-size:11px;line-height:1.45;box-shadow:0 10px 24px #000c;opacity:0;pointer-events:none;transform:translateX(-4px);transition:opacity .16s ease,transform .16s ease;z-index:40}
#hand.hand .card-hover-tooltip b{display:block;margin-bottom:4px;color:#f2d49e;font-size:12px}
#hand.hand .card:hover .card-hover-tooltip{opacity:1;transform:translateX(0)}
#hand.hand .card:nth-child(2n) .card-hover-tooltip{left:auto;right:calc(100% + 8px)}
#hand.hand .card.advisor-card-hand .card-stat-cell b{font-size:12px}
#hand.hand .card.item .card-stat-grid,#hand.hand .card.tactic .card-stat-grid,#hand.hand .card.advisor-card-hand .card-stat-grid{grid-template-columns:repeat(2,1fr)}
#hand.hand .card.item .card-stat-cell:last-child,#hand.hand .card.tactic .card-stat-cell:last-child,#hand.hand .card.advisor-card-hand .card-stat-cell:last-child{grid-column:1/3}

@media (max-width:1280px){
  .app{grid-template-columns:198px minmax(520px,.8fr) 340px}
  .board{min-width:500px;max-width:730px}
  #hand.hand .card{height:166px}
  .hq-advisor-console{width:134px}
  .hq-info-overlay,.hq-advisor-summary{right:148px}
  .hq-unit-slot{right:148px}
}

.no-anim *{animation:none!important;transition:none!important}

.left-log-frame{min-height:120px;flex:1 1 auto}
.left-menu-dock{flex:0 0 auto;padding:6px 8px 10px;border-top:1px solid #4f3518;background:#090d0f}
#leftMenuMount{margin-top:6px}
#leftMenuMount .reference-topbar{margin:0;width:100%;border:1px solid #6e4a24;background:linear-gradient(180deg,#10171a,#090d0f);box-shadow:inset 0 0 0 1px #000}
#leftMenuMount .top-control-group{grid-template-columns:1fr;gap:4px}
#leftMenuMount .top-new{grid-column:auto;height:26px}
#leftMenuMount .turn-plate{padding:4px 6px}
#leftMenuMount .turn-plate .turnbadge{display:block;text-align:center}
#leftMenuMount .top-options{grid-template-columns:1fr 1fr;gap:4px}
#leftMenuMount .top-options #cardManagerBtn,#leftMenuMount .top-options #rulesTopBtn{grid-column:auto;grid-row:auto}
#leftMenuMount .faction-pickers{grid-template-columns:1fr;gap:4px}
#leftMenuMount .faction-pickers label{justify-content:space-between}
#leftMenuMount .faction-pickers select{flex:1;min-width:0}
.battle-panel>.reference-topbar{display:none!important}
.battle-panel{padding-top:0}
.boardwrap{padding-top:0}

.bottom-hud{display:none!important}

.basezone{display:block!important;position:relative;height:118px!important;min-height:118px!important;width:100%!important;margin:0!important}
.basezone>.hq{display:flex!important;position:relative;width:90%!important;height:116px!important;min-height:116px!important;margin:0 auto!important;grid-column:auto!important;grid-row:auto!important}
.hq.faction-fortress{height:116px!important;min-height:116px!important;background-position:center 43%!important}
.hq-title{min-width:190px;padding:4px 20px 5px;font-size:11px}
.hq-subtitle{top:27px;left:10px;font-size:7px}
.hq-info-overlay{left:9px;right:132px;top:31px;gap:4px}
.hq-stat-chip{padding:2px 5px;font-size:9px}
.hq-advisor-summary{left:9px;right:132px;bottom:7px;min-height:25px;padding:3px 5px;font-size:8px;line-height:1.2}
.hq-advisor-summary b{font-size:9px}
.enemy-turn-badge{right:8px;bottom:7px;height:21px;min-width:43px;font-size:10px}
.hq-unit-slot{right:134px;bottom:6px;width:92px;height:27px}

.hq>.advisor{position:absolute!important;right:7px!important;width:118px!important;height:32px!important;min-height:32px!important;z-index:12;border:1px solid #76532d!important;background:linear-gradient(180deg,#171b1cde,#080b0cde)!important;padding:2px 4px!important}
.hq>.advisor[data-advisor="left"]{top:31px!important}
.hq>.advisor[data-advisor="right"]{top:66px!important}
.hq>.advisor .advisor-empty{font-size:8px!important;line-height:1.15!important}
.hq>.advisor .advisor-card.rich{grid-template-columns:27px 1fr!important;gap:3px!important}
.hq>.advisor .advisor-portrait{width:27px!important;height:27px!important}
.hq>.advisor .advisor-copy b{font-size:8px!important}
.hq>.advisor .advisor-copy .advisor-meta,.hq>.advisor .advisor-level{font-size:6px!important}

.hq-advisor-console{position:absolute!important;left:40%!important;right:130px!important;top:31px!important;bottom:7px!important;width:auto!important;display:flex!important;flex-direction:column!important;gap:3px!important;overflow:hidden!important;z-index:10}
.hq-advisor-console .advisor-mirror.in-castle{display:none!important}
.hq-advisor-console .advisor-switch.mini{width:100%!important;margin:0!important;min-height:18px!important;height:18px!important;padding:1px 3px!important;font-size:7px!important}
.hq-advisor-console .compact-skills.in-castle{padding:0!important;min-height:0!important}
.hq-advisor-console .compact-skills .notice{display:none!important}
.hq-advisor-console .compact-skill-grid{display:grid!important;grid-template-columns:1fr 1fr!important;gap:2px!important;margin:0!important}
.hq-advisor-console .compact-skill-grid .skill,.hq-advisor-console .compact-skill-grid .btn{min-height:27px!important;height:27px!important;padding:2px 3px!important;overflow:hidden!important}
.hq-advisor-console .compact-skill-grid .skill b{font-size:7px!important;line-height:1!important}
.hq-advisor-console .compact-skill-grid .skill span{font-size:5.5px!important;line-height:1!important}
.hq-advisor-console #upgradeAdvisorBtn{font-size:6.5px!important;line-height:1.05!important}

.lane{min-height:86px!important;height:auto!important;padding:2px 6px!important}
.slots{min-height:82px!important;height:82px!important;gap:7px!important}
.slot{height:80px!important}
.unit{grid-template-rows:18px 1fr 18px!important}
.uname{font-size:10px!important;padding:2px 3px!important}
.uimg{font-size:22px!important;min-height:42px!important}
.stats{font-size:9px!important;padding:2px!important}
.grade{font-size:7px!important;padding:1px 3px!important}
.typeicon{font-size:9px!important}

.enemy-roster-section{height:24%!important;flex:0 0 24%!important}
.right-deck-section{flex:0 0 88px!important}
.right-deck-body{padding:5px 8px!important;gap:8px!important}
.deck-stack{width:58px!important;height:70px!important}
.deck-info{font-size:9px!important;gap:2px!important}
.deck-info b{font-size:15px!important}
.deck-help{font-size:8px!important}
.right-hand-section{flex:1 1 auto!important;min-height:330px!important;overflow:visible!important}
.right-hand-section .handbox{padding:5px!important;overflow:visible!important}
#hand.hand{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;grid-template-rows:repeat(2,154px)!important;grid-auto-rows:154px!important;gap:5px!important;height:auto!important;min-height:313px!important;overflow:visible!important;align-content:start!important;padding:0!important}
#hand.hand .card{width:100%!important;height:154px!important;min-width:0!important;min-height:0!important;grid-template-rows:17px 80px 1fr!important;overflow:hidden!important}
#hand.hand .cname{font-size:8px!important;padding:1px 2px!important}
#hand.hand .cimg{min-height:0!important}
#hand.hand .card-grade{left:2px!important;top:19px!important;font-size:6px!important;padding:1px 3px!important}
#hand.hand .cost{right:2px!important;top:19px!important;width:18px!important;height:18px!important;font-size:8px!important}
#hand.hand .cstats{padding:3px!important;gap:2px!important}
#hand.hand .card-type-line{font-size:6px!important}
#hand.hand .card-stat-grid{gap:2px!important}
#hand.hand .card-stat-cell{min-height:26px!important;padding:2px 1px!important}
#hand.hand .card-stat-cell b{font-size:13px!important}
#hand.hand .card-stat-cell span{font-size:6px!important}
#hand.hand .card-stat-cell.subtle b{font-size:8px!important}
#hand.hand .ctext,#hand.hand .card-hover-tooltip{display:none!important}

.card-function-tooltip{position:fixed;z-index:500;display:none;max-width:240px;min-width:150px;padding:8px 10px;background:#0c0f11f5;border:1px solid #a2753d;color:#f0e7d8;font-size:11px;line-height:1.45;box-shadow:0 10px 28px #000d;pointer-events:none;white-space:normal;overflow-wrap:anywhere}
.card-function-tooltip.show{display:block}
.card-function-tooltip::before{content:"카드 기능";display:block;margin-bottom:4px;color:#e6bd7a;font-size:10px;font-weight:900}

.right-action-strip{flex:0 0 112px!important;min-height:112px!important;border-top:1px solid #60401e;background:#080c0e;display:flex;flex-direction:column}
.right-action-strip #details{display:none!important}
.right-action-mount{flex:1;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr;gap:6px;padding:7px}
.right-action-mount .btn{width:100%!important;height:100%!important;min-height:32px!important;padding:6px 5px!important;font-size:11px!important}
.right-action-mount #shuffleBtn{grid-column:1;grid-row:1}
.right-action-mount #cancelBtn{grid-column:2;grid-row:1}
.right-action-mount #endTurnBtn{grid-column:1/3;grid-row:2;font-size:13px!important;font-weight:900!important}

@media(max-width:1280px){
  .basezone{height:112px!important;min-height:112px!important}
  .basezone>.hq,.hq.faction-fortress{height:110px!important;min-height:110px!important}
  .lane{min-height:82px!important}
  .slots{min-height:78px!important;height:78px!important}
  .slot{height:76px!important}
  #hand.hand{grid-template-rows:repeat(2,145px)!important;grid-auto-rows:145px!important;min-height:295px!important}
  #hand.hand .card{height:145px!important;grid-template-rows:16px 74px 1fr!important}
}

.boardwrap{padding-top:0!important;overflow:hidden!important}
.battlefield-layout{
  height:100%;min-height:0;width:100%;display:grid;
  grid-template-columns:minmax(0,1fr) 184px;gap:0;
  padding:5px 0;
}
.battlefield-layout>.board{
  width:100%!important;min-width:0!important;max-width:none!important;height:100%!important;
  margin:0!important;padding:0!important;display:grid!important;
  grid-template-rows:repeat(3,minmax(92px,1fr)) 22px repeat(3,minmax(92px,1fr));
  gap:5px!important;align-content:stretch!important;
}
.battlefield-layout .lane{
  min-height:0!important;height:100%!important;padding:3px 6px!important;overflow:visible;
}
.battlefield-layout .lane .label{font-size:9px!important;top:3px!important;left:6px!important}
.battlefield-layout .slots{
  width:100%;height:100%!important;min-height:0!important;margin:0 auto;gap:7px!important;
  align-items:center!important;justify-content:center!important;
}
.battlefield-layout .slots.n4{grid-template-columns:repeat(4,minmax(72px,1fr))!important;max-width:650px}
.battlefield-layout .slots.n3{grid-template-columns:repeat(3,minmax(78px,1fr))!important;max-width:510px;width:82%}
.battlefield-layout .slots.n2{grid-template-columns:repeat(2,minmax(86px,1fr))!important;max-width:365px;width:58%}
.battlefield-layout .slot{
  width:100%!important;height:calc(100% - 8px)!important;min-height:78px!important;max-height:114px!important;
}
.battlefield-layout .unit{grid-template-rows:20px 1fr 20px!important}
.battlefield-layout .uname{font-size:11px!important;padding:2px 4px!important}
.battlefield-layout .uimg{font-size:24px!important;min-height:0!important}
.battlefield-layout .stats{font-size:10px!important;padding:2px!important}
.battlefield-layout .grade{font-size:8px!important;padding:1px 4px!important}
.battlefield-layout .typeicon{font-size:10px!important;padding:1px 3px!important}
.battlefield-layout .river{height:22px!important;min-height:22px!important;margin:0!important}

.field-side-rail{
  min-width:0;height:100%;display:flex;flex-direction:column;gap:5px;
  border-left:1px solid #72502c;background:linear-gradient(180deg,#11100d99,#080a0b80);
  padding-left:0;
}
.rail-side-group{display:flex;flex-direction:column;gap:5px;flex:0 0 auto}
.rail-spacer{flex:1 1 auto;min-height:28px;border-top:1px solid #4c361f33;border-bottom:1px solid #4c361f33}
.rail-hq-wrap{width:100%;height:154px;min-height:154px}
.field-side-rail .hq.faction-fortress{
  display:flex!important;position:relative!important;width:100%!important;height:154px!important;min-height:154px!important;
  margin:0!important;padding:0!important;border-radius:0!important;background-position:center 44%!important;
}
.field-side-rail .hq-title{
  top:0!important;left:50%!important;min-width:142px!important;max-width:calc(100% - 10px);
  padding:4px 12px 5px!important;font-size:10px!important;white-space:nowrap;
}
.field-side-rail .hq-subtitle{top:28px!important;left:7px!important;font-size:7px!important}
.field-side-rail .hq.faction-fortress .hptxt{display:none!important}
.field-side-rail .hq-info-overlay{
  left:6px!important;right:6px!important;top:34px!important;display:grid!important;grid-template-columns:1fr 1fr;gap:3px!important;
}
.field-side-rail .hq-stat-chip{justify-content:center!important;padding:2px 3px!important;font-size:8px!important;min-width:0}
.field-side-rail .hq-advisor-summary{
  left:6px!important;right:6px!important;bottom:7px!important;min-height:36px!important;max-height:39px!important;
  padding:3px 4px!important;font-size:7px!important;line-height:1.2!important;overflow:hidden!important;
}
.field-side-rail .hq-advisor-summary b{font-size:8px!important}
.field-side-rail .enemy-turn-badge{right:6px!important;bottom:48px!important;height:18px!important;min-width:37px!important;font-size:8px!important}
.field-side-rail .hq-unit-slot{
  left:6px!important;right:auto!important;bottom:48px!important;width:86px!important;height:22px!important;margin:0!important;z-index:8;
}
.field-side-rail .hq-unit-slot.empty::after{font-size:7px!important}
.field-side-rail .base-unit{grid-template-columns:20px 1fr auto!important;gap:2px!important;padding:1px 2px!important}
.field-side-rail .base-unit-art{height:18px!important;font-size:12px!important}
.field-side-rail .base-unit-name{font-size:7px!important}.field-side-rail .base-unit-stat{font-size:6px!important}

.rail-advisor-row{display:grid;grid-template-columns:1fr 1fr;gap:4px;height:69px;min-height:69px}
.field-side-rail .advisor{
  position:relative!important;inset:auto!important;width:auto!important;height:69px!important;min-height:69px!important;
  margin:0!important;padding:3px!important;border:1px solid #72502c!important;border-radius:0!important;
  background:linear-gradient(180deg,#15191a,#090c0d)!important;overflow:hidden!important;
}
.field-side-rail .advisor.has-portrait{padding:2px!important}
.field-side-rail .advisor-card.rich{grid-template-columns:31px 1fr!important;gap:3px!important;height:100%!important}
.field-side-rail .advisor-portrait{width:31px!important;height:57px!important}
.field-side-rail .advisor-copy b{font-size:8px!important}
.field-side-rail .advisor-copy .advisor-meta{font-size:6px!important;line-height:1.1!important}
.field-side-rail .advisor-level{font-size:6px!important;padding:1px 3px!important}
.field-side-rail .advisor-empty{font-size:9px!important;line-height:1.3!important;color:#d2c6b2!important}

.field-side-rail #allyHq .hq-advisor-summary{display:none!important}
.field-side-rail #allyHq .hq-advisor-console{
  display:block!important;position:absolute!important;left:6px!important;right:6px!important;top:auto!important;bottom:6px!important;
  width:auto!important;height:58px!important;overflow:hidden!important;z-index:10!important;
}
.field-side-rail #allyHq .advisor-mirror.in-castle,.field-side-rail #allyHq .compact-skills .notice{display:none!important}
.field-side-rail #allyHq .advisor-switch.mini{height:17px!important;min-height:17px!important;width:100%!important;margin:0 0 2px!important;padding:1px 3px!important;font-size:6px!important}
.field-side-rail #allyHq .compact-skill-grid{display:grid!important;grid-template-columns:repeat(2,1fr)!important;gap:2px!important;margin:0!important}
.field-side-rail #allyHq .compact-skill-grid .skill,.field-side-rail #allyHq .compact-skill-grid .btn{height:18px!important;min-height:18px!important;padding:1px 2px!important}
.field-side-rail #allyHq .compact-skill-grid .skill b{font-size:6px!important;line-height:1!important}
.field-side-rail #allyHq .compact-skill-grid .skill span{display:none!important}
.field-side-rail #allyHq #upgradeAdvisorBtn{font-size:5.5px!important;line-height:1!important}
.field-side-rail #allyHq .hq-unit-slot{bottom:67px!important}

@media(max-width:1280px){
  .battlefield-layout{grid-template-columns:minmax(0,1fr) 164px;gap:0}
  .rail-hq-wrap{height:142px;min-height:142px}
  .field-side-rail .hq.faction-fortress{height:142px!important;min-height:142px!important}
  .rail-advisor-row{height:62px;min-height:62px}
  .field-side-rail .advisor{height:62px!important;min-height:62px!important}
  .field-side-rail .advisor-portrait{height:50px!important;width:28px!important}
  .battlefield-layout .slots{gap:5px!important}
  .battlefield-layout .slots.n4{grid-template-columns:repeat(4,minmax(62px,1fr))!important}
}

.battlefield-layout{
  grid-template-columns:minmax(0,3.15fr) minmax(190px,1fr)!important;
  gap:0!important;
  padding:0!important;
}
.battlefield-layout>.board{
  border-right:0!important;
  padding:0!important;
  gap:4px!important;
}
.field-side-rail{
  margin:0!important;
  padding:0!important;
  gap:4px!important;
  border-left:1px solid #77512b!important;
}

.battlefield-layout>.board{
  grid-template-rows:repeat(3,minmax(104px,1fr)) 24px repeat(3,minmax(104px,1fr))!important;
}
.battlefield-layout .lane{
  padding:4px 5px!important;
}
.battlefield-layout .slots{
  gap:8px!important;
}
.battlefield-layout .slots.n4{max-width:720px!important;width:94%!important}
.battlefield-layout .slots.n3{max-width:590px!important;width:82%!important}
.battlefield-layout .slots.n2{max-width:440px!important;width:62%!important}
.battlefield-layout .slot{
  height:calc(100% - 10px)!important;
  min-height:88px!important;
  max-height:136px!important;
}
.battlefield-layout .river{
  height:24px!important;
  min-height:24px!important;
  font-size:12px!important;
  letter-spacing:7px!important;
}

.rail-resource-strip{
  height:42px;
  min-height:42px;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:4px;
  padding:4px;
  background:linear-gradient(180deg,#111619,#080c0e);
  border-top:1px solid #654621;
  border-bottom:1px solid #654621;
}
.rail-resource-item{
  min-width:0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:5px;
  padding:4px 6px;
  border:1px solid #4b4234;
  background:#090d0fda;
  box-shadow:inset 0 0 0 1px #000;
  font-weight:900;
}
.rail-resource-item span{
  font-size:10px;
  color:#b9ad98;
  white-space:nowrap;
}
.rail-resource-item b{
  font-size:17px;
  line-height:1;
  color:#f0e8dc;
  white-space:nowrap;
}
.rail-resource-item.mana{border-color:#49687c;background:linear-gradient(180deg,#10202b,#081117)}
.rail-resource-item.mana b{color:#a9d9ff;text-shadow:0 0 8px #3d91c766}
.rail-resource-item.ap{border-color:#765b2d;background:linear-gradient(180deg,#302714,#141108)}
.rail-resource-item.ap b{color:#f3c868;text-shadow:0 0 8px #e6ae4466}

.rail-hq-wrap{height:150px!important;min-height:150px!important}
.field-side-rail .hq.faction-fortress{height:150px!important;min-height:150px!important}
.rail-advisor-row{height:74px!important;min-height:74px!important}
.field-side-rail .advisor{height:74px!important;min-height:74px!important}
.field-side-rail .advisor-portrait{width:34px!important;height:62px!important}
.rail-spacer{min-height:16px!important}

.battlefield-layout .lane .label{font-size:12px!important;font-weight:800!important;color:#bba583a6!important}
.battlefield-layout .unit{grid-template-rows:22px 1fr 22px!important}
.battlefield-layout .uname{font-size:13px!important;padding:3px 5px!important}
.battlefield-layout .uimg{font-size:27px!important}
.battlefield-layout .stats{font-size:12px!important;padding:3px!important}
.battlefield-layout .grade{font-size:9px!important}
.battlefield-layout .typeicon{font-size:11px!important}
.battlefield-layout .buff,.battlefield-layout .support-charge{font-size:8px!important}

.field-side-rail .hq-title{font-size:12px!important;min-width:156px!important}
.field-side-rail .hq-subtitle{font-size:9px!important}
.field-side-rail .hq-stat-chip{font-size:10px!important;padding:3px 4px!important}
.field-side-rail .hq-advisor-summary{font-size:9px!important;line-height:1.25!important}
.field-side-rail .hq-advisor-summary b{font-size:10px!important}
.field-side-rail .enemy-turn-badge{font-size:10px!important;height:20px!important}
.field-side-rail .hq-unit-slot.empty::after{font-size:8px!important}
.field-side-rail .base-unit-name{font-size:8px!important}
.field-side-rail .base-unit-stat{font-size:7px!important}

.field-side-rail .advisor-copy b{font-size:10px!important}
.field-side-rail .advisor-copy .advisor-meta{font-size:8px!important;line-height:1.2!important}
.field-side-rail .advisor-level{font-size:8px!important;padding:1px 4px!important}
.field-side-rail .advisor-empty{font-size:11px!important;line-height:1.35!important}
.field-side-rail .advisor .mana{font-size:11px!important}

.reference-left .ornate-title,.reference-right .ornate-title{font-size:14px!important}
.settings-mini-copy{font-size:11px!important}
.left-log-frame .log{font-size:11px!important}
#leftMenuMount .top-field span,.faction-pickers{font-size:10px!important}
#leftMenuMount .top-field select,#leftMenuMount .faction-pickers select{font-size:11px!important}
#leftMenuMount .turn-plate .turnbadge{font-size:12px!important}
#leftMenuMount .checkline{font-size:11px!important}
#leftMenuMount .btn,.left-bottom-actions .btn{font-size:12px!important}

.deck-info{font-size:11px!important}
.deck-info b{font-size:17px!important}
.deck-help{font-size:9px!important}
#hand.hand .cname{font-size:9px!important}
#hand.hand .card-type-line{font-size:7px!important}
#hand.hand .card-stat-cell span{font-size:7px!important}
.right-action-mount .btn{font-size:12px!important}
.right-action-mount #endTurnBtn{font-size:14px!important}

@media(max-width:1280px){
  .battlefield-layout{grid-template-columns:minmax(0,3.05fr) minmax(176px,1fr)!important}
  .rail-resource-strip{height:39px;min-height:39px;padding:3px}
  .rail-resource-item b{font-size:15px}
  .rail-resource-item span{font-size:9px}
  .rail-hq-wrap{height:140px!important;min-height:140px!important}
  .field-side-rail .hq.faction-fortress{height:140px!important;min-height:140px!important}
  .rail-advisor-row{height:68px!important;min-height:68px!important}
  .field-side-rail .advisor{height:68px!important;min-height:68px!important}
  .field-side-rail .advisor-portrait{height:56px!important;width:31px!important}
  .battlefield-layout .uname{font-size:12px!important}
  .battlefield-layout .stats{font-size:11px!important}
}

.app{
  grid-template-columns:210px minmax(560px,1.7fr) minmax(340px,1fr)!important;
  gap:4px!important;padding:4px!important;
}

.battlefield-layout{
  grid-template-columns:minmax(0,1.32fr) minmax(220px,1fr)!important;
  gap:0!important;padding:0!important;
}
.battlefield-layout>.board{min-width:0!important;max-width:none!important;width:100%!important}
.battlefield-layout .slots.n4{width:96%!important;max-width:none!important;grid-template-columns:repeat(4,minmax(0,1fr))!important}
.battlefield-layout .slots.n3{width:84%!important;max-width:none!important;grid-template-columns:repeat(3,minmax(0,1fr))!important}
.battlefield-layout .slots.n2{width:64%!important;max-width:none!important;grid-template-columns:repeat(2,minmax(0,1fr))!important}
.field-side-rail{min-width:220px!important}

.reference-right{min-width:0!important}
#hand.hand{grid-template-columns:repeat(3,minmax(0,1fr))!important}

.manager-search{grid-template-columns:minmax(0,1fr) 92px 104px!important}
.manager-upload-label{
  display:block;padding:7px 9px;border:1px solid #6f532e;background:linear-gradient(180deg,#241b10,#100d09);
  color:#efd39d;font-size:11px;font-weight:900;text-align:center;cursor:pointer;
}
.manager-upload-label:hover{filter:brightness(1.12)}
.manager-help b{color:#f0cf92}

@media (max-width:1280px) and (min-width:851px){
  .app{grid-template-columns:188px minmax(530px,1.7fr) minmax(315px,1fr)!important;gap:3px!important;padding:2px!important;min-width:1038px!important}
  .battlefield-layout{grid-template-columns:minmax(0,1.32fr) minmax(218px,1fr)!important}
  .field-side-rail{min-width:218px!important}
  .reference-brand h1{font-size:25px!important}
  .reference-brand{padding-left:10px!important;padding-right:8px!important}
}

@media (max-width:1050px) and (min-width:851px){
  .app{height:100vh!important;grid-template-columns:188px 530px minmax(315px,1fr)!important;min-width:1038px!important}
  .reference-right{grid-column:auto!important;height:calc(100vh - 4px)!important;display:flex!important;flex-direction:column!important}
  .enemy-roster-section{height:24%!important;flex:0 0 24%!important}
  .right-deck-section{flex:0 0 88px!important}
  .right-hand-section{flex:1 1 auto!important;min-height:330px!important}
}

@media (min-width:851px){
  html,body{width:100%;height:100%;overflow:hidden!important}
  .app{
    width:100vw!important;height:100vh!important;min-height:0!important;
    display:grid!important;
    grid-template-columns:205px minmax(560px,1fr) minmax(330px,370px)!important;
    gap:3px!important;padding:3px!important;
  }
  .panel{border-radius:0!important}
  .reference-left,.battle-panel,.reference-right{height:calc(100vh - 6px)!important;min-height:0!important}

  
  .boardwrap{height:100%!important;min-height:0!important;overflow:hidden!important;padding:0!important}
  .battlefield-layout{
    display:block!important;width:100%!important;height:100%!important;min-height:0!important;padding:0!important;
  }
  .battlefield-layout>.board{
    width:100%!important;height:100%!important;min-width:0!important;max-width:none!important;margin:0!important;
    padding:0!important;gap:4px!important;
    grid-template-columns:minmax(0,1fr)!important;
    grid-template-rows:repeat(3,minmax(0,1fr)) 24px repeat(3,minmax(0,1fr))!important;
  }
  .battlefield-layout .lane{height:100%!important;min-height:0!important;padding:3px 5px!important}
  .battlefield-layout .slots{height:100%!important;min-height:0!important;width:100%!important;max-width:none!important;gap:6px!important}
  .battlefield-layout .slots.n4{width:96%!important;grid-template-columns:repeat(4,minmax(0,1fr))!important}
  .battlefield-layout .slots.n3{width:82%!important;grid-template-columns:repeat(3,minmax(0,1fr))!important}
  .battlefield-layout .slots.n2{width:62%!important;grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .battlefield-layout .slot{height:calc(100% - 8px)!important;min-height:70px!important;max-height:none!important}

  
  .reference-right{
    position:relative!important;display:flex!important;flex-direction:column!important;
    overflow:hidden!important;padding:0!important;background:#080c0d!important;
  }
  .field-side-rail{display:contents!important}
  .rail-spacer{display:none!important}
  .enemy-roster-section{display:none!important}
  .enemy-rail-group{order:1!important;flex:0 0 auto!important;gap:3px!important}
  .right-deck-section{order:2!important;flex:0 0 76px!important;min-height:76px!important}
  .right-hand-section{order:3!important;flex:1 1 auto!important;min-height:190px!important;border-bottom:1px solid #5d3d1d!important;background:#080c0d!important}
  .ally-rail-group{order:4!important;flex:0 0 auto!important;gap:3px!important}
  .right-action-strip{display:none!important}

  
  .rail-hq-wrap{height:clamp(118px,15.5vh,150px)!important;min-height:118px!important}
  .field-side-rail .hq.faction-fortress{
    width:100%!important;height:clamp(118px,15.5vh,150px)!important;min-height:118px!important;
  }
  .rail-advisor-row{height:clamp(56px,7.5vh,72px)!important;min-height:56px!important;gap:3px!important}
  .field-side-rail .advisor{height:100%!important;min-height:0!important}
  .field-side-rail .advisor-portrait{height:calc(100% - 6px)!important;max-height:62px!important}
  .rail-resource-strip{height:38px!important;min-height:38px!important;padding:3px!important;gap:3px!important}
  .rail-resource-item{padding:3px 5px!important}
  .rail-resource-item span{font-size:9px!important}
  .rail-resource-item b{font-size:15px!important}

  
  .right-hand-section>.ornate-title,.right-hand-section .handhead{display:none!important}
  .right-hand-section .handbox{
    width:100%!important;height:100%!important;min-height:0!important;flex:1 1 auto!important;
    padding:4px!important;margin:0!important;border:0!important;overflow:hidden!important;background:#080c0d!important;
  }
  #hand.hand{
    width:100%!important;height:100%!important;min-height:0!important;margin:0!important;padding:0!important;
    display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;
    grid-template-rows:repeat(2,minmax(0,1fr))!important;grid-auto-rows:minmax(0,1fr)!important;
    gap:4px!important;overflow:hidden!important;align-content:stretch!important;
  }
  #hand.hand .card{
    width:100%!important;height:100%!important;min-width:0!important;min-height:0!important;
    border-radius:0!important;grid-template-rows:16px minmax(42px,1fr) auto!important;overflow:hidden!important;
  }
  #hand.hand .cname{font-size:8px!important;padding:1px 2px!important}
  #hand.hand .cimg{min-height:0!important}
  #hand.hand .cstats{padding:2px!important;gap:2px!important}
  #hand.hand .card-stat-grid{gap:2px!important}
  #hand.hand .card-stat-cell{min-height:22px!important;padding:1px!important}
  #hand.hand .card-stat-cell b{font-size:11px!important}
  #hand.hand .card-stat-cell span{font-size:6px!important}
  #hand.hand .card-type-line{font-size:6px!important}
  #hand.hand .ctext,#hand.hand .card-hover-tooltip{display:none!important}

  
  .right-deck-body{
    height:100%!important;min-height:0!important;display:grid!important;
    grid-template-columns:50px minmax(72px,1fr) 112px!important;gap:6px!important;align-items:center!important;padding:5px 6px!important;
  }
  .deck-stack{width:46px!important;height:58px!important}
  .deck-emblem{font-size:20px!important}
  .deck-info{font-size:9px!important;gap:1px!important;min-width:0!important}
  .deck-info b{font-size:16px!important;line-height:1!important}
  .deck-help{display:none!important}
  .deck-action-mount{
    width:100%!important;height:62px!important;min-width:0!important;padding:0!important;
    display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-template-rows:23px 35px!important;
    gap:3px!important;
  }
  .deck-action-mount .btn{min-width:0!important;width:100%!important;height:100%!important;min-height:0!important;padding:2px 3px!important;font-size:8px!important}
  .deck-action-mount #shuffleBtn{grid-column:1!important;grid-row:1!important}
  .deck-action-mount #cancelBtn{grid-column:2!important;grid-row:1!important}
  .deck-action-mount #rulesBtn{display:none!important}
  .deck-action-mount #endTurnBtn{grid-column:1/3!important;grid-row:2!important;font-size:11px!important;font-weight:900!important}

  
  .reference-left{padding:0!important;gap:0!important;overflow:hidden!important}
  .reference-brand{flex:0 0 86px!important}
  .left-advisor-frame{flex:0 0 auto!important}
  .left-log-frame{flex:1 1 auto!important;min-height:150px!important}
  .left-menu-dock{flex:0 0 auto!important}
  .left-bottom-actions{flex:0 0 62px!important;min-height:62px!important;padding:6px 10px!important}
}

@media (min-width:851px) and (max-width:1180px){
  .app{grid-template-columns:188px minmax(520px,1fr) 320px!important;min-width:1028px!important}
  .right-deck-body{grid-template-columns:44px minmax(66px,1fr) 104px!important;gap:4px!important;padding:4px!important}
  .deck-stack{width:42px!important;height:54px!important}
  .field-side-rail .hq-title{font-size:10px!important;min-width:140px!important}
  .field-side-rail .hq-stat-chip{font-size:8px!important}
  .field-side-rail .advisor-copy b{font-size:8px!important}
  .field-side-rail .advisor-copy .advisor-meta{font-size:7px!important}
}

@media (min-width:851px){
  html,body{
    width:100%;
    height:auto!important;
    min-height:100%;
    overflow:auto!important;
  }
  body{
    padding:18px 0!important;
  }
  .app{
    width:min(1015px, calc(100vw - 40px))!important;
    height:auto!important;
    min-height:0!important;
    margin:0 auto!important;
    display:grid!important;
    grid-template-columns:205px minmax(392px, 420px) minmax(330px, 360px)!important;
    gap:8px!important;
    padding:0!important;
    align-items:start!important;
  }
  .reference-left,.battle-panel,.reference-right{
    height:820px!important;
    min-height:820px!important;
  }
  .reference-left,.battle-panel,.reference-right{max-height:none!important}
}

@media (min-width:851px) and (max-width:1180px){
  body{padding:12px 0!important}
  .app{
    width:min(955px, calc(100vw - 24px))!important;
    grid-template-columns:188px minmax(360px, 390px) minmax(300px, 330px)!important;
    gap:6px!important;
  }
  .reference-left,.battle-panel,.reference-right{
    height:780px!important;
    min-height:780px!important;
  }
}

@media (min-width:851px){
  .right-deck-section{flex-basis:70px!important;min-height:70px!important}
  .right-deck-body{display:grid!important;grid-template-columns:.9fr 1fr 1.15fr!important;grid-template-rows:1fr!important;gap:5px!important;padding:6px!important;align-items:stretch!important}
  .right-deck-body .deck-stack{display:none!important}
  .right-deck-body .deck-info{grid-column:1!important;grid-row:1!important;min-width:0!important;height:auto!important;align-items:center!important;justify-content:center!important;text-align:center!important;gap:1px!important;padding:4px!important;border:1px solid #6b5131!important;background:linear-gradient(180deg,#1c1711,#0d0b08)!important}
  .right-deck-body .deck-info b{font-size:19px!important;line-height:1!important}
  .right-deck-body .deck-info>span:not(.deck-help){font-size:10px!important}
  .right-deck-body .deck-action-mount{display:contents!important}
  .right-deck-body #shuffleBtn,.right-deck-body #endTurnBtn{min-width:0!important;width:100%!important;height:auto!important;min-height:0!important;padding:6px 4px!important;font-size:13px!important;font-weight:900!important}
  .right-deck-body #shuffleBtn{grid-column:2!important;grid-row:1!important}
  .right-deck-body #endTurnBtn{grid-column:3!important;grid-row:1!important}

  .ally-rail-group>.rail-resource-strip{display:none!important}
  .field-side-rail .hq-info-overlay{left:9px!important;right:9px!important;top:38px!important;display:flex!important;align-items:center!important;justify-content:flex-start!important;gap:12px!important;flex-wrap:nowrap!important;pointer-events:none!important}
  .field-side-rail .hq-stat-chip{padding:0!important;margin:0!important;border:0!important;background:transparent!important;box-shadow:none!important;font-size:12px!important;font-weight:900!important;color:#fff!important;text-shadow:0 2px 5px #000,0 0 8px #000!important}
  .field-side-rail .hq-stat-chip b{font-size:14px!important;color:#fff!important}
  .field-side-rail .hq-stat-chip.skill{display:none!important}
  .field-side-rail .hq-title{font-size:14px!important;text-shadow:0 2px 6px #000!important}
  .field-side-rail .hq-subtitle{font-size:10px!important;text-shadow:0 2px 5px #000!important}

  #allyHq #allyAdvisorConsole{display:none!important}
  #allyHq #allyAdvisorConsole.skill-menu-open{display:block!important;position:absolute!important;left:7px!important;right:7px!important;top:34px!important;bottom:7px!important;width:auto!important;height:auto!important;z-index:60!important;padding:7px!important;border:1px solid #9b7844!important;background:linear-gradient(180deg,#090d10f2,#07090bf5)!important;box-shadow:0 8px 24px #000d,inset 0 0 0 1px #000!important;overflow:auto!important}
  #allyAdvisorConsole .advisor-mirror,#allyAdvisorConsole .advisor-switch{display:none!important}
  #allyAdvisorConsole .compact-skills{display:block!important;padding:0!important}
  #allyAdvisorConsole .notice{display:block!important;margin:0 0 6px!important;padding:4px 6px!important;border:0!important;background:transparent!important;color:#f0e3ce!important;font-size:11px!important;line-height:1.3!important;text-align:center!important}
  #allyAdvisorConsole .compact-skill-grid{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:5px!important;margin:0!important}
  #allyAdvisorConsole .compact-skill-grid .skill{min-height:48px!important;padding:5px!important;text-align:center!important}
  #allyAdvisorConsole .compact-skill-grid .skill b{font-size:11px!important;line-height:1.15!important}
  #allyAdvisorConsole .compact-skill-grid .skill span{font-size:9px!important;line-height:1.2!important}
  #allyAdvisorConsole #upgradeAdvisorBtn{grid-column:1/-1!important;min-height:30px!important;padding:4px 6px!important;font-size:10px!important;font-weight:900!important}

  #hand.hand .cname{font-size:11px!important;line-height:1.15!important}
  #hand.hand .card-type-line{font-size:9px!important;font-weight:800!important}
  #hand.hand .card-stat-cell{min-height:25px!important;padding:2px!important}
  #hand.hand .card-stat-cell.combat b{font-size:14px!important;white-space:nowrap!important}
  #hand.hand .card-type-badge{position:absolute;left:4px;bottom:4px;z-index:6;padding:2px 5px;border:1px solid #ffffff55;background:#05080dcc;color:#fff4de;font-size:9px;font-weight:900;line-height:1.15;text-shadow:0 1px 3px #000}
  .battlefield-layout .uname{font-size:14px!important}
  .battlefield-layout .stats{font-size:13px!important;font-weight:900!important}
  .battlefield-layout .typeicon{left:4px!important;bottom:4px!important;padding:2px 5px!important;font-size:10px!important;font-weight:900!important;color:#fff!important;border:1px solid #ffffff44!important;background:#05080dcc!important;text-shadow:0 1px 3px #000!important}
  .battlefield-layout .lane .label{font-size:13px!important}
  .field-side-rail .advisor-copy b{font-size:11px!important}
  .field-side-rail .advisor-copy .advisor-meta{font-size:9px!important}
  .field-side-rail .advisor-level{font-size:9px!important}
  .field-side-rail .advisor-empty{font-size:12px!important}
  .field-side-rail .advisor .mana{font-size:12px!important}
}
@media (max-width:850px){
  .card-type-badge{position:absolute;left:4px;bottom:4px;z-index:6;padding:2px 5px;background:#05080dcc;border:1px solid #ffffff55;font-size:9px;font-weight:900}
  #allyHq #allyAdvisorConsole{display:none!important}
  #allyHq #allyAdvisorConsole.skill-menu-open{display:block!important;position:absolute!important;inset:34px 6px 6px!important;z-index:60!important;padding:6px!important;background:#080b0ef2!important;border:1px solid #9b7844!important;overflow:auto!important}
  #allyAdvisorConsole .advisor-mirror,#allyAdvisorConsole .advisor-switch{display:none!important}
  #allyAdvisorConsole .compact-skill-grid{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:4px!important}
  #allyAdvisorConsole #upgradeAdvisorBtn{grid-column:1/-1!important}
}

.formation-control{display:grid;gap:6px;padding:8px;border:1px solid #4d3b27;background:#0b0e10;border-radius:7px}
.formation-control span{font-size:11px;color:#d8c8ae;font-weight:800;text-align:center}
.formation-control select{width:100%;font-size:13px;font-weight:900;text-align:center;background:#17120d;border-color:#7b5b35;color:#f3e2c5}
.formation-note{font-size:9px;line-height:1.35;color:#9f917c;text-align:center}

.lane.turn-active{border-color:#f3d58a!important;box-shadow:0 0 0 2px #f2cc6f55,0 0 22px #f4c45e70,inset 0 0 18px #f4c45e18!important;animation:activeLaneGlow 1.4s ease-in-out infinite alternate}
.lane.turn-active .label{color:#fff4ce!important;text-shadow:0 0 8px #f3c660!important;font-weight:950!important}
@keyframes activeLaneGlow{from{filter:brightness(1)}to{filter:brightness(1.18)}}
body.no-anim .lane.turn-active{animation:none}

.field-side-rail .hq-info-overlay{left:50%!important;right:auto!important;top:50%!important;transform:translate(-50%,-50%)!important;width:calc(100% - 18px)!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:15px!important;flex-wrap:nowrap!important;pointer-events:none!important;text-align:center!important}
.field-side-rail .hq-stat-chip{padding:0!important;margin:0!important;border:0!important;background:transparent!important;box-shadow:none!important;font-size:14px!important;font-weight:950!important;color:#fff!important;text-shadow:0 2px 6px #000,0 0 10px #000!important;white-space:nowrap!important}
.field-side-rail .hq-stat-chip b{font-size:18px!important;line-height:1!important;color:#fff!important}
.field-side-rail .hq-stat-chip.skill{display:none!important}
.field-side-rail .hq.faction-fortress>.hptxt{display:none!important}

#hand.hand .cname{display:flex!important;align-items:center!important;justify-content:flex-start!important;min-height:22px!important;padding:2px 6px!important;font-size:12px!important;font-weight:950!important;text-align:left!important}
#hand.hand .card-grade{left:5px!important;top:25px!important;padding:3px 7px!important;border-radius:5px!important;font-size:11px!important;line-height:1.1!important;box-shadow:0 2px 7px #000b!important}
#hand.hand .cost{right:5px!important;top:25px!important;width:auto!important;min-width:38px!important;height:26px!important;padding:0 6px!important;border-radius:7px!important;font-size:12px!important;font-weight:950!important;line-height:1!important}
#hand.hand .cost::before{content:'AP ';font-size:9px;font-weight:850;margin-right:2px;color:#fff0bd}

#shuffleBtn{font-weight:950!important}

@media(max-width:850px){
  .field-side-rail .hq-info-overlay{gap:9px!important}
  .field-side-rail .hq-stat-chip{font-size:11px!important}
  .field-side-rail .hq-stat-chip b{font-size:14px!important}
  #hand.hand .card-grade{font-size:9px!important;padding:2px 5px!important}
  #hand.hand .cost{min-width:33px!important;height:23px!important;font-size:10px!important}
}

#hand.hand .card-title-area{
  min-height:36px!important;
  height:36px!important;
  padding:3px 4px!important;
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto auto!important;
  grid-template-rows:15px 13px!important;
  column-gap:3px!important;
  row-gap:2px!important;
  align-items:center!important;
  justify-content:stretch!important;
  overflow:hidden!important;
  background:linear-gradient(180deg,#493324,#211812)!important;
  border-bottom:1px solid #8c683e!important;
  color:#f4ecdf!important;
  text-align:left!important;
}
#hand.hand .card-name-text{
  min-width:0!important;
  overflow:hidden!important;
  white-space:nowrap!important;
  text-overflow:ellipsis!important;
  font-size:10px!important;
  line-height:15px!important;
  font-weight:950!important;
}
#hand.hand .card-head-grade,
#hand.hand .card-head-cost{
  position:static!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  height:15px!important;
  padding:0 4px!important;
  border-radius:4px!important;
  border:1px solid #ffffff55!important;
  font-size:7px!important;
  line-height:1!important;
  font-weight:950!important;
  white-space:nowrap!important;
  box-shadow:none!important;
}
#hand.hand .card-head-cost{
  background:#16110b!important;
  border-color:#c59b55!important;
  color:#ffd96a!important;
}
#hand.hand .card-head-ability{
  grid-column:1 / -1!important;
  min-width:0!important;
  overflow:hidden!important;
  white-space:nowrap!important;
  text-overflow:ellipsis!important;
  font-size:7px!important;
  line-height:13px!important;
  font-weight:700!important;
  color:#e1d4bf!important;
}
#hand.hand .card-head-ability b{
  margin-right:3px!important;
  color:#f4c875!important;
  font-size:7px!important;
  font-weight:950!important;
}

#hand.hand .card-grade,
#hand.hand .cost{display:none!important}

#hand.hand .card{
  grid-template-rows:36px minmax(52px,1fr) auto!important;
}

@media (max-width:850px){
  #hand.hand .card-title-area{
    min-height:34px!important;
    height:34px!important;
    grid-template-rows:14px 12px!important;
    padding:3px!important;
  }
  #hand.hand .card-name-text{font-size:9px!important;line-height:14px!important}
  #hand.hand .card-head-grade,#hand.hand .card-head-cost{height:14px!important;font-size:6.5px!important;padding:0 3px!important}
  #hand.hand .card-head-ability,#hand.hand .card-head-ability b{font-size:6.5px!important;line-height:12px!important}
  #hand.hand .card{grid-template-rows:34px minmax(46px,1fr) auto!important}
}

.card-art-img,.unit-art-img,.manager-preview img,.advisor-portrait img,.roster-art img,.base-unit-art img{
  object-fit:cover!important;
  object-position:var(--img-x,50%) var(--img-y,50%)!important;
  transform:scale(var(--img-scale,1));
  transform-origin:var(--img-x,50%) var(--img-y,50%);
  transition:transform .12s ease,object-position .12s ease;
}
.manager-preview,.manager-thumb,.cimg,.uimg,.advisor-portrait,.roster-art,.base-unit-art{overflow:hidden!important}
.image-adjust-panel{display:grid;gap:7px;padding:9px;border:1px solid #5f472d;background:#0a0d0f}
.image-adjust-title{font-size:11px;font-weight:950;color:#efcf95;text-align:center}
.image-adjust-panel label{display:grid;grid-template-columns:58px minmax(0,1fr) 42px;gap:7px;align-items:center;font-size:10px;color:#d5c7b2}
.image-adjust-panel input[type="range"]{width:100%;accent-color:#c69b55}
.image-adjust-panel output{text-align:right;color:#f2d69f;font-weight:900;font-size:10px}
.image-adjust-panel .btn{min-height:27px!important;font-size:10px!important}
.batch-image-preset-panel{display:grid;gap:10px;padding:10px;border:1px solid #5f472d;background:#0a0d0f}
.batch-image-preset-note{font-size:10px;line-height:1.45;color:#d6c8b3}
.batch-image-preset-note.compact{font-size:9px;color:#bba98c}
.batch-image-preset-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:8px}
.batch-image-preset-slot{display:grid;gap:8px;padding:8px;border:1px solid #6c4d2b;background:linear-gradient(180deg,#12100d,#0a0c0e)}
.batch-image-preset-head{display:flex;align-items:center;justify-content:space-between;gap:6px}
.batch-image-preset-head b{font-size:11px;color:#efcf95}
.batch-image-preset-head .btn,.batch-image-preset-slot>.btn{min-height:26px!important;font-size:10px!important}
.batch-image-preset-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
.batch-image-preset-fields label{display:grid;gap:4px;font-size:10px;color:#d5c7b2}
.batch-image-preset-fields input{width:100%;min-width:0;background:#0b0d0f;border:1px solid #745734;color:#f4e1b8;padding:4px 6px}
.batch-image-type-select{display:flex;flex-wrap:wrap;gap:10px 14px;padding:4px 2px}
.batch-image-type-select label{display:flex;align-items:center;gap:5px;font-size:11px;color:#e0d3bf}
.batch-image-type-select input{accent-color:#c69b55}

@media (min-width:851px){
  .battlefield-layout>.board{
    display:grid!important;
    grid-template-columns:minmax(0,1fr)!important;
    grid-template-rows:104px repeat(3,minmax(0,1fr)) 24px repeat(3,minmax(0,1fr)) 104px!important;
    gap:3px!important;
  }
  .hq-battle-row{min-height:0!important;height:100%!important;padding:0 5px!important;display:flex!important;align-items:stretch!important;justify-content:center!important}
  .battle-hq{width:98%!important;height:100%!important;min-height:0!important;max-height:none!important;border-radius:0!important;margin:0!important;display:block!important;position:relative!important;overflow:hidden!important;background-position:center 43%!important}
  .battle-hq .hq-title{top:0!important;font-size:12px!important;min-width:190px!important;padding:3px 18px 4px!important}
  .battle-hq .hq-subtitle{top:25px!important;left:8px!important;font-size:7px!important}
  .battle-hq .hq-info-overlay{position:absolute!important;left:10px!important;right:auto!important;top:37px!important;transform:none!important;width:auto!important;display:flex!important;gap:10px!important;justify-content:flex-start!important;z-index:8!important}
  .battle-hq .hq-stat-chip{font-size:10px!important;text-shadow:0 2px 5px #000!important}
  .battle-hq .hq-stat-chip b{font-size:13px!important}
  .battle-hq .hq-advisor-summary{left:10px!important;right:132px!important;bottom:7px!important;min-height:28px!important;font-size:9px!important;padding:3px 6px!important}
  .battle-hq .hq-advisor-summary b{font-size:10px!important}
  .battle-hq .hq-advisor-slot{position:absolute!important;right:7px!important;top:29px!important;width:118px!important;height:67px!important;min-height:0!important;z-index:10!important;border-radius:4px!important;padding:3px!important;background:linear-gradient(180deg,#11191aee,#080c0dee)!important;border:1px solid #9b7844!important}
  .battle-hq .hq-advisor-slot.has-portrait{padding:3px!important}
  .battle-hq .hq-advisor-slot .advisor-card.rich{grid-template-columns:44px 1fr!important;gap:4px!important;height:100%!important}
  .battle-hq .hq-advisor-slot .advisor-portrait{width:44px!important;height:58px!important}
  .battle-hq .hq-advisor-slot .advisor-copy b{font-size:10px!important}
  .battle-hq .hq-advisor-slot .advisor-meta,.battle-hq .hq-advisor-slot .advisor-level{font-size:8px!important}
  .battle-hq .hq-advisor-slot .advisor-empty{font-size:10px!important;line-height:1.25!important}
  .battle-hq .hq-unit-slot{right:132px!important;bottom:7px!important;width:118px!important;height:30px!important;z-index:9!important}
  .battle-hq.emergency .hq-unit-slot,.battle-hq.has-base-unit .hq-unit-slot{display:flex!important}
  .battle-hq.emergency,.battle-hq.has-base-unit{height:100%!important;min-height:0!important}
  .battle-hq .enemy-turn-badge{z-index:12!important}

  
  .reference-right{display:flex!important;flex-direction:column!important;overflow:hidden!important}
  .right-deck-section{order:1!important;flex:0 0 74px!important;min-height:74px!important}
  .right-hand-section{order:2!important;flex:1 1 auto!important;min-height:0!important;overflow:auto!important;background:#080c0d!important}
  .right-hand-section>.ornate-title{display:flex!important;flex:0 0 30px!important}
  .right-hand-section .handhead{display:none!important}
  .right-hand-section .handbox{height:auto!important;min-height:0!important;overflow:visible!important;padding:5px!important}
  #hand.hand{height:auto!important;min-height:374px!important;grid-template-rows:repeat(2,minmax(185px,1fr))!important;grid-auto-rows:minmax(185px,1fr)!important;overflow:visible!important}
  #hand.hand .card{height:100%!important;min-height:185px!important;grid-template-rows:36px minmax(100px,1fr) auto!important}
  #hand.hand .cimg{min-height:100px!important}
  #hand.hand .card-stat-cell{min-height:27px!important}

  
  #allyHq #allyAdvisorConsole.skill-menu-open{display:block!important;position:absolute!important;left:8px!important;right:132px!important;top:28px!important;bottom:6px!important;z-index:40!important;padding:7px!important;background:#070a0df5!important;border:1px solid #b58b4f!important;overflow:auto!important}
  #allyAdvisorConsole .notice{display:block!important;font-size:13px!important;line-height:1.35!important;padding:4px 5px!important;margin:0 0 5px!important;text-align:left!important;color:#f3e5cc!important}
  #allyAdvisorConsole .compact-skill-grid{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:5px!important}
  #allyAdvisorConsole .compact-skill-grid .skill{min-height:50px!important;padding:5px!important}
  #allyAdvisorConsole .compact-skill-grid .skill b{font-size:14px!important;line-height:1.15!important}
  #allyAdvisorConsole .compact-skill-grid .skill span{display:block!important;font-size:10px!important;line-height:1.2!important;margin-top:3px!important}
  #allyAdvisorConsole #upgradeAdvisorBtn{grid-column:1/-1!important;min-height:30px!important;font-size:11px!important}
  #allyAdvisorConsole .advisor-mirror{display:none!important}

  .reference-left,.battle-panel,.reference-right{height:860px!important;min-height:860px!important}
}

@media (max-width:850px){
  .hq-battle-row{padding:3px 0}
  .battle-hq{height:125px!important;min-height:125px!important;border-radius:0!important}
  .battle-hq .hq-advisor-slot{position:absolute;right:6px;top:34px;width:112px;height:76px;z-index:10;border-radius:4px}
  .battle-hq .hq-info-overlay{left:8px!important;right:124px!important;top:38px!important;transform:none!important;width:auto!important;justify-content:flex-start!important;gap:7px!important;flex-wrap:wrap!important}
  .battle-hq .hq-advisor-summary{left:8px!important;right:124px!important;bottom:7px!important;font-size:8px!important}
  #hand.hand{grid-auto-rows:185px!important}
  #hand.hand .card{min-height:185px!important;grid-template-rows:34px minmax(100px,1fr) auto!important}
  #allyAdvisorConsole .notice{font-size:12px!important}
  #allyAdvisorConsole .compact-skill-grid .skill b{font-size:13px!important}
  #allyAdvisorConsole .compact-skill-grid .skill span{font-size:10px!important}
}

.ap-spend-feedback{position:fixed;left:50%;top:18%;transform:translate(-50%,-10px) scale(.96);z-index:1000;display:flex;align-items:center;gap:10px;padding:10px 16px;border:1px solid #d0a458;background:#090c0ff2;box-shadow:0 12px 35px #000d;color:#f2dfbe;opacity:0;pointer-events:none;transition:.18s ease}
.ap-spend-feedback.show{opacity:1;transform:translate(-50%,0) scale(1)}
.ap-spend-feedback b{font-size:22px;line-height:1;color:#ffd66e;text-shadow:0 0 12px #f2b94d66}
.ap-spend-feedback span{font-size:12px;font-weight:900}
.ap-value-flash{animation:apValueFlash .65s ease!important}
@keyframes apValueFlash{0%{transform:scale(1);filter:brightness(1)}35%{transform:scale(1.35);filter:brightness(1.8);text-shadow:0 0 12px #ffd15a}100%{transform:scale(1);filter:brightness(1)}}
body.no-anim .ap-value-flash{animation:none!important}

@media (min-width:851px){
  body{padding-bottom:24px!important;}
  .app{min-height:1000px!important;}
  .reference-left,.battle-panel,.reference-right{
    height:1000px!important;
    min-height:1000px!important;
  }
  .boardwrap{
    min-height:0!important;
    overflow:hidden!important;
  }
  .battlefield-layout>.board{
    grid-template-rows:112px repeat(3,minmax(0,1fr)) 24px repeat(3,minmax(0,1fr)) 120px!important;
    padding-bottom:6px!important;
  }
  .enemy-hq-row{min-height:112px!important;}
  .ally-hq-row{min-height:120px!important;padding-bottom:4px!important;}
  .ally-hq-row .battle-hq{min-height:116px!important;}
}

.card-function-tooltip{white-space:pre-line!important;max-width:330px!important;line-height:1.45!important}

#leftMenuMount .top-options #cardManagerBtn{
  grid-column:1 / -1!important;
  width:100%!important;
  min-height:34px!important;
  font-size:12px!important;
  font-weight:900!important;
}

.manager-preview{position:relative;cursor:grab;touch-action:none;user-select:none}
.manager-preview.dragging{cursor:grabbing;outline:2px solid #e3b867;box-shadow:0 0 20px #d8a95055}
.manager-preview.drop-ready{outline:2px dashed #9ed1ff;background:#10202a}
.manager-preview::after{content:'이미지를 드래그해 위치 조절';position:absolute;left:7px;right:7px;bottom:7px;z-index:7;padding:4px 6px;background:#05080bbb;border:1px solid #ffffff33;color:#f3e5ce;font-size:9px;font-weight:800;text-align:center;pointer-events:none}
.drag-position-readout{display:flex;align-items:center;justify-content:space-between;min-height:25px;padding:4px 7px;border:1px solid #463925;background:#101315;color:#d5c7b2;font-size:10px}
.drag-position-readout b{color:#f2d69f}

.hq-image-manager{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:8px;padding:8px;border:1px solid #5f472d;background:#0a0d0f}
.hq-image-manager>.image-adjust-title{grid-column:1/-1}
.hq-image-setting{display:grid;gap:5px;min-width:0}
.hq-image-preview{height:66px;background-size:cover;background-position:center;border:1px solid #76552e;position:relative;overflow:hidden}
.hq-image-preview span{position:absolute;left:4px;bottom:4px;padding:2px 5px;background:#05080bbb;color:#fff;font-size:8px;font-weight:900}
.hq-image-preview.custom{box-shadow:inset 0 0 0 1px #e0b15b}
.hq-image-setting .manager-upload-label,.hq-image-setting .btn{font-size:9px!important;min-height:26px!important;padding:4px!important}

.advisor-hand-panel{display:none;height:100%;min-height:0;grid-template-columns:minmax(110px,.82fr) minmax(150px,1.18fr);gap:8px;padding:6px;background:linear-gradient(180deg,#0b1013,#070a0c)}
.right-hand-section.advisor-skill-mode .advisor-hand-panel{display:grid!important}
.right-hand-section.advisor-skill-mode #hand.hand{display:none!important}
.right-hand-section.advisor-skill-mode .ornate-title .title-flex>span:first-child{font-size:0}
.right-hand-section.advisor-skill-mode .ornate-title .title-flex>span:first-child::after{content:'책사 스킬';font-size:12px}
.advisor-hand-card,.advisor-hand-skills{min-width:0;min-height:0;border:1px solid #76552e;background:#0c1012;padding:6px;overflow:auto}
.advisor-hand-preview-card{height:100%;display:grid;grid-template-rows:28px minmax(150px,1fr) 25px auto;border:1px solid #9a7440;background:linear-gradient(180deg,#171b1d,#0c0e10);overflow:hidden}
.advisor-hand-name{display:flex;align-items:center;justify-content:center;gap:6px;font-size:13px;font-weight:950;color:#f4eadb;background:#211912;border-bottom:1px solid #76552e}
.advisor-hand-art{min-height:0;overflow:hidden;position:relative}.advisor-hand-art img,.advisor-hand-art .default-art{width:100%;height:100%;object-fit:cover}
.advisor-hand-meta{display:flex;align-items:center;justify-content:center;font-size:10px;font-weight:900;color:#e6c98f;background:#11171a;border-top:1px solid #46515a}
.advisor-hand-copy{padding:6px;font-size:9px;line-height:1.35;color:#d7cbb7;background:#0b0e10}
.advisor-hand-empty{height:100%;display:grid;place-items:center;color:#bcae98;font-size:11px;text-align:center}
.advisor-hand-skills{display:flex;flex-direction:column;gap:7px}
.advisor-hand-status{padding:7px 8px;border:1px solid #624b2e;background:#17120d;color:#f2e4cd;font-size:12px;line-height:1.35}
.advisor-hand-skill-grid{display:grid;grid-template-columns:1fr;gap:7px}
.advisor-hand-skill-grid .skill{min-height:62px;padding:8px;text-align:left}
.advisor-hand-skill-grid .skill b{display:block;font-size:15px;line-height:1.15;color:#f3d7a3}
.advisor-hand-skill-grid .skill span{display:block;margin-top:4px;font-size:11px;line-height:1.3}
.advisor-hand-upgrade,.advisor-hand-close{min-height:34px!important;font-size:11px!important;font-weight:900!important}

@media (min-width:851px){
  .battlefield-layout .lane{min-height:86px!important;padding-top:3px!important;padding-bottom:3px!important}
  .battlefield-layout .slots{min-height:82px!important;align-items:center!important}
  .battlefield-layout .slot{height:82px!important;min-height:82px!important}
  .battlefield-layout .unit{height:100%!important;grid-template-rows:21px minmax(0,1fr) 20px!important}
  .battlefield-layout .uname{display:flex!important;align-items:center!important;justify-content:center!important;gap:5px!important;font-size:13px!important;white-space:nowrap!important;overflow:hidden!important}
  .field-unit-name{overflow:hidden;text-overflow:ellipsis}
  .field-grade{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:16px;padding:0 4px;border:1px solid #ffffff44;background:#0a0d10cc;color:#ffe9b0;font-size:9px;font-weight:950;line-height:1}
  .battlefield-layout .uimg{min-height:0!important}
  .battlefield-layout .typeicon.icon-only{min-width:23px!important;min-height:23px!important;padding:1px!important;display:grid!important;place-items:center!important;font-size:16px!important;line-height:1!important;text-indent:0!important}
}

#hand.hand .card-title-area{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;grid-template-rows:18px 12px!important;column-gap:4px!important;align-items:center!important}
#hand.hand .card-name-text{grid-column:1!important;grid-row:1!important;justify-self:center!important;max-width:100%!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}
#hand.hand .card-head-grade{grid-column:2!important;grid-row:1!important;position:static!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;min-width:18px!important;height:14px!important;padding:0 3px!important;font-size:8px!important}
#hand.hand .card-head-ability{grid-column:1/-1!important;grid-row:2!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}
#hand.hand .card-head-cost{display:none!important}
#hand.hand .card-image-cost{position:absolute;right:6px;top:6px;z-index:8;width:28px;height:28px;border-radius:50%;display:grid;place-items:center;background:radial-gradient(circle at 35% 30%,#f9dd83,#b57918 68%,#5a3307);border:2px solid #ffe9a5;box-shadow:0 2px 7px #000c,inset 0 0 0 1px #6b3b0a;color:#171005;font-size:15px;font-weight:1000;line-height:1}
#hand.hand .card-type-badge.icon-only{min-width:25px;min-height:25px;display:grid;place-items:center;padding:2px!important;font-size:16px!important;line-height:1!important}
#hand.hand .card-type-line span:last-child{font-size:15px!important;line-height:1!important}

.base-unit-name{display:flex!important;align-items:center!important;gap:5px!important}
.base-unit .typeicon.icon-only{font-size:15px!important;min-width:22px!important;text-align:center!important}

@media (max-width:850px){
  .advisor-hand-panel{grid-template-columns:42% 58%;gap:5px;padding:4px}
  .advisor-hand-preview-card{grid-template-rows:24px minmax(110px,1fr) 22px auto}
  .advisor-hand-name{font-size:11px}.advisor-hand-copy{font-size:8px}
  .advisor-hand-status{font-size:10px;padding:5px}.advisor-hand-skill-grid .skill{min-height:48px;padding:5px}
  .advisor-hand-skill-grid .skill b{font-size:12px}.advisor-hand-skill-grid .skill span{font-size:9px}
  .hq-image-manager{grid-template-columns:1fr}
  .hq-image-manager>.image-adjust-title{grid-column:1}
}

.advisor-hand-panel{display:none!important}
.right-hand-section.advisor-skill-mode #hand.hand{display:grid!important}
.right-hand-section.advisor-skill-mode .ornate-title .title-flex>span:first-child{font-size:inherit!important}
.right-hand-section.advisor-skill-mode .ornate-title .title-flex>span:first-child::after{content:none!important}

#allyHq #allyAdvisorConsole{display:none!important}
#allyHq #allyAdvisorConsole.skill-menu-open{
  display:block!important;
  position:fixed!important;
  left:var(--advisor-pop-left, 50%)!important;
  top:var(--advisor-pop-top, 50%)!important;
  right:auto!important;
  bottom:auto!important;
  width:272px!important;
  height:auto!important;
  max-height:min(340px,calc(100vh - 16px))!important;
  padding:8px!important;
  z-index:1200!important;
  overflow:auto!important;
  border:1px solid #b58b4f!important;
  border-radius:5px!important;
  background:linear-gradient(180deg,#0b0f12f7,#06090bf7)!important;
  box-shadow:0 12px 32px #000e,inset 0 0 0 1px #ffffff0d!important;
}
#allyHq #allyAdvisorConsole.skill-menu-open::before{
  content:'';
  position:absolute;
  left:-7px;
  top:24px;
  width:12px;
  height:12px;
  transform:rotate(45deg);
  background:#0a0e11;
  border-left:1px solid #b58b4f;
  border-bottom:1px solid #b58b4f;
}
#allyHq #allyAdvisorConsole.skill-menu-open .compact-skills{display:block!important;padding:0!important}
#allyHq #allyAdvisorConsole.skill-menu-open .notice{
  display:block!important;margin:0 0 7px!important;padding:6px 7px!important;
  font-size:12px!important;line-height:1.35!important;text-align:left!important;
  color:#f2e4ce!important;background:#16110ed9!important;border:1px solid #604a2e!important;
}
#allyHq #allyAdvisorConsole.skill-menu-open .compact-skill-grid{
  display:grid!important;grid-template-columns:1fr!important;gap:6px!important;margin:0!important;
}
#allyHq #allyAdvisorConsole.skill-menu-open .compact-skill-grid .skill{
  min-height:54px!important;height:auto!important;padding:7px 8px!important;text-align:left!important;
}
#allyHq #allyAdvisorConsole.skill-menu-open .compact-skill-grid .skill b{font-size:14px!important;line-height:1.15!important}
#allyHq #allyAdvisorConsole.skill-menu-open .compact-skill-grid .skill span{display:block!important;margin-top:3px!important;font-size:10px!important;line-height:1.25!important}
#allyHq #allyAdvisorConsole.skill-menu-open #upgradeAdvisorBtn{
  grid-column:1!important;min-height:34px!important;height:auto!important;padding:6px 8px!important;font-size:11px!important;
}
#allyHq #allyAdvisorConsole.skill-menu-open .advisor-mirror{display:none!important}
#allyHq.advisor-menu-open{overflow:visible!important}

@media (max-width:850px){
  #allyHq #allyAdvisorConsole.skill-menu-open{width:min(252px,calc(100vw - 16px))!important;max-height:300px!important}
}

#allyAdvisorConsole{display:none!important}
#allyAdvisorConsole.skill-menu-open{
  display:block!important;
  position:fixed!important;
  left:var(--advisor-pop-left,50%)!important;
  top:var(--advisor-pop-top,50%)!important;
  right:auto!important;
  bottom:auto!important;
  width:272px!important;
  height:auto!important;
  max-height:min(360px,calc(100vh - 16px))!important;
  padding:8px!important;
  z-index:10000!important;
  overflow:auto!important;
  border:1px solid #b58b4f!important;
  border-radius:5px!important;
  background:linear-gradient(180deg,#0b0f12fc,#06090bfc)!important;
  box-shadow:0 14px 38px #000f,inset 0 0 0 1px #ffffff10!important;
}
#allyAdvisorConsole.skill-menu-open::before{
  content:'';position:absolute;left:-7px;top:24px;width:12px;height:12px;
  transform:rotate(45deg);background:#0a0e11;border-left:1px solid #b58b4f;border-bottom:1px solid #b58b4f;
}
#allyAdvisorConsole.skill-menu-open .compact-skills{display:block!important;padding:0!important}
#allyAdvisorConsole.skill-menu-open .notice{display:block!important;margin:0 0 7px!important;padding:6px 7px!important;font-size:12px!important;line-height:1.35!important;text-align:left!important;color:#f2e4ce!important;background:#16110ed9!important;border:1px solid #604a2e!important}
#allyAdvisorConsole.skill-menu-open .compact-skill-grid{display:grid!important;grid-template-columns:1fr!important;gap:6px!important;margin:0!important}
#allyAdvisorConsole.skill-menu-open .compact-skill-grid .skill{min-height:54px!important;height:auto!important;padding:7px 8px!important;text-align:left!important}
#allyAdvisorConsole.skill-menu-open .compact-skill-grid .skill b{font-size:14px!important;line-height:1.15!important}
#allyAdvisorConsole.skill-menu-open .compact-skill-grid .skill span{display:block!important;margin-top:3px!important;font-size:10px!important;line-height:1.25!important}
#allyAdvisorConsole.skill-menu-open #upgradeAdvisorBtn{grid-column:1!important;min-height:34px!important;height:auto!important;padding:6px 8px!important;font-size:11px!important}
#allyAdvisorConsole.skill-menu-open .advisor-mirror{display:none!important}

#allyHq .hq-advisor-summary{display:none!important}

#hand.hand{
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-template-rows:repeat(2,185px)!important;
  grid-auto-rows:185px!important;
  align-items:stretch!important;
  align-content:start!important;
}
#hand.hand .card{
  width:100%!important;
  height:185px!important;
  min-height:185px!important;
  max-height:185px!important;
  box-sizing:border-box!important;
  grid-template-rows:36px 100px 49px!important;
}
#hand.hand .cimg{height:100px!important;min-height:100px!important;max-height:100px!important}
#hand.hand .cstats{min-height:49px!important;max-height:49px!important;overflow:hidden!important}
#hand.hand .ctext{display:none!important}

@media (min-width:851px){
  .battlefield-layout>.board{
    grid-template-rows:112px repeat(3,minmax(103px,1fr)) 24px repeat(3,minmax(103px,1fr)) 120px!important;
    gap:3px!important;
  }
  .battlefield-layout .lane{
    min-height:103px!important;
    height:100%!important;
    padding:2px 5px!important;
    box-sizing:border-box!important;
  }
  .battlefield-layout .slots{
    height:100%!important;
    min-height:0!important;
    align-items:stretch!important;
  }
  .battlefield-layout .slot{
    height:100%!important;
    min-height:98px!important;
    max-height:none!important;
    align-self:stretch!important;
    box-sizing:border-box!important;
  }
  .battlefield-layout .unit{
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    align-self:stretch!important;
    grid-template-rows:22px minmax(0,1fr) 21px!important;
  }
  .battlefield-layout .uimg{height:100%!important;min-height:0!important}
}

@media (max-width:850px){
  #allyAdvisorConsole.skill-menu-open{width:min(252px,calc(100vw - 16px))!important;max-height:320px!important}
  #hand.hand{grid-template-rows:repeat(2,170px)!important;grid-auto-rows:170px!important}
  #hand.hand .card{height:170px!important;min-height:170px!important;max-height:170px!important;grid-template-rows:34px 92px 44px!important}
  #hand.hand .cimg{height:92px!important;min-height:92px!important;max-height:92px!important}
  #hand.hand .cstats{min-height:44px!important;max-height:44px!important}
}

.ally-side-align-spacer,.ally-hand-align-spacer{flex:0 0 0;height:0;transition:flex-basis .18s ease,height .18s ease}
.reference-right{position:relative!important}
.right-hand-section{position:relative;z-index:1}

.formation-modal-box{max-width:360px;width:min(92vw,360px);padding:18px 16px 16px}
.formation-modal-body{display:grid;gap:12px;margin-top:14px}
.formation-modal-field{display:grid;gap:6px;font-size:12px;color:#d6c8af}
.formation-modal-field select{width:100%;padding:10px 12px;font-size:15px}
.formation-modal-note{font-size:11px;line-height:1.5;color:#aeb7c6;background:#0a1322;border:1px solid #2f4262;border-radius:10px;padding:10px}

.hq-info-overlay{gap:8px!important}
.hq-stat-chip{display:inline-flex!important;align-items:center!important;gap:6px!important;padding:5px 10px!important;border-radius:999px!important}
.hq-stat-icon{display:inline-flex;align-items:center;justify-content:center;width:19px;height:19px;border-radius:999px;background:#00000044;font-size:12px;line-height:1;box-shadow:inset 0 0 0 1px #ffffff14}
.hq-stat-chip b,.hq-stat-chip .hq-stat-value{font-size:18px!important;line-height:1!important;font-weight:950!important;letter-spacing:.02em}
.battle-hq .hq-stat-chip{font-size:0!important}
.battle-hq .hq-stat-chip.skill .hq-stat-value{font-size:14px!important}
.battle-hq .hq-stat-chip.skill .hq-stat-icon{font-size:11px}

.battlefield-layout>.board{
  grid-template-rows:minmax(128px,1.08fr) repeat(3,minmax(112px,1fr)) 24px repeat(3,minmax(112px,1fr)) minmax(136px,1.12fr)!important;
  gap:6px!important;
}
.battlefield-layout .lane{padding:4px 6px!important}
.battlefield-layout .slots{height:100%!important;min-height:0!important;align-items:stretch!important}
.battlefield-layout .slot{
  width:100%!important;height:100%!important;min-height:92px!important;max-height:none!important;
}
.battlefield-layout .unit{height:100%!important;min-height:0!important;grid-template-rows:22px 1fr 22px!important}
.battlefield-layout .uimg{height:100%!important;min-height:0!important;font-size:26px!important}
.battlefield-layout .uname{font-size:12px!important}
.battlefield-layout .stats{font-size:11px!important}
.battlefield-layout .typeicon{font-size:11px!important}

@media (max-width:850px){
  .ally-hand-align-spacer{display:none!important}
  .hq-stat-chip b,.hq-stat-chip .hq-stat-value{font-size:15px!important}
}

:root{
  --grade-s:#f6cc58;
  --grade-r:#dc72d5;
  --grade-u:#65cdef;
  --grade-c:#a9b2bd;
}

.card.other,.unit.other,.base-unit.other{background:linear-gradient(180deg,#48433d,#211e1a)!important}
.default-art.card.other,.default-art.unit.other{background:radial-gradient(circle at 25% 20%,#ffffff35 0,#ffffff10 18%,transparent 20%),linear-gradient(180deg,#6a6259 0,#2b2722 100%)!important}

.card.grade-border-S,.unit.grade-border-S,.base-unit.grade-border-S{border-color:var(--grade-s)!important;box-shadow:0 0 0 1px #5b4618,0 0 12px #f6cc5840!important}
.card.grade-border-R,.unit.grade-border-R,.base-unit.grade-border-R{border-color:var(--grade-r)!important;box-shadow:0 0 0 1px #51234c,0 0 10px #dc72d538!important}
.card.grade-border-U,.unit.grade-border-U,.base-unit.grade-border-U{border-color:var(--grade-u)!important;box-shadow:0 0 0 1px #1d5264,0 0 9px #65cdef32!important}
.card.grade-border-C,.unit.grade-border-C,.base-unit.grade-border-C{border-color:var(--grade-c)!important;box-shadow:0 0 0 1px #3c444e!important}
#hand.hand .card.selected{outline:2px solid #fff1a8!important;box-shadow:0 0 0 2px #604d1d,0 0 18px #ffe47b66!important}

#hand.hand .card-head-ability,#hand.hand .card-type-line{display:none!important}
#hand.hand .cname.card-title-area{height:auto!important;min-height:27px!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:5px!important;padding:3px 5px!important}
#hand.hand .card-name-text{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px!important;font-weight:900!important}
#hand.hand .card-head-grade{position:static!important;flex:0 0 auto!important;font-size:8px!important;padding:1px 4px!important}
#hand.hand .cstats{display:flex!important;align-items:center!important;justify-content:center!important;padding:3px!important}
#hand.hand .card-stat-grid{width:100%!important}

#hand.hand{grid-template-rows:repeat(2,198px)!important;grid-auto-rows:198px!important}
#hand.hand .card{
  height:198px!important;min-height:198px!important;max-height:198px!important;
  grid-template-rows:28px 128px 42px!important;
}
#hand.hand .cimg{height:128px!important;min-height:128px!important;max-height:128px!important}
#hand.hand .cimg img,#hand.hand .cimg .default-art{width:100%!important;height:100%!important}
#hand.hand .card-stat-cell{min-height:32px!important;padding:2px 1px!important}
#hand.hand .card-stat-cell b{font-size:13px!important}
#hand.hand .card.item .card-stat-cell b,#hand.hand .card.tactic .card-stat-cell b,#hand.hand .card.advisor-card-hand .card-stat-cell b{font-size:9px!important}
#hand.hand .card-stat-cell span{font-size:6px!important}

@media (min-width:851px){
  .reference-right{display:flex!important;flex-direction:column!important;height:1120px!important;min-height:1120px!important}
  .right-deck-section{flex:0 0 82px!important;min-height:82px!important}
  .right-hand-section{flex:0 0 446px!important;height:446px!important;min-height:446px!important;max-height:446px!important}
  .right-hand-section .handbox{height:100%!important;min-height:0!important;padding:4px!important}
  #hand.hand{height:100%!important;overflow:hidden!important;align-content:start!important;gap:5px!important}
  .ally-side-align-spacer{flex-shrink:0!important}

  
  body{padding-top:12px!important;padding-bottom:12px!important}
  .app{height:auto!important;min-height:0!important;align-items:start!important}
  .reference-left,.battle-panel,.reference-right{height:1120px!important;min-height:1120px!important}
  .boardwrap{height:1120px!important;overflow:auto!important}
  .battlefield-layout>.board{
    height:auto!important;
    grid-template-rows:minmax(136px,auto) repeat(3,146px) 26px repeat(3,146px) minmax(146px,auto)!important;
    gap:6px!important;
  }
  .battlefield-layout .lane{height:146px!important;min-height:146px!important;padding:4px 6px!important}
  .battlefield-layout .slot{height:100%!important;min-height:136px!important}
  .battlefield-layout .unit{grid-template-rows:24px minmax(0,1fr) 23px!important}
  .battlefield-layout .uimg{min-height:0!important;height:100%!important}
}

@media (max-width:850px){
  #hand.hand{grid-template-rows:repeat(2,180px)!important;grid-auto-rows:180px!important}
  #hand.hand .card{height:180px!important;min-height:180px!important;max-height:180px!important;grid-template-rows:27px 112px 41px!important}
  #hand.hand .cimg{height:112px!important;min-height:112px!important;max-height:112px!important}
}

@media (min-width:851px){
  html,body{height:100%!important;overflow:hidden!important;}
  body{padding:0!important;}

  
  .app{
    height:100vh!important;
    min-height:0!important;
    padding:6px!important;
    gap:0!important;
    grid-template-columns:220px minmax(0,1fr) 344px!important;
    align-items:stretch!important;
  }
  .reference-left,.battle-panel,.reference-right{
    height:calc(100vh - 12px)!important;
    min-height:0!important;
    max-height:calc(100vh - 12px)!important;
  }

  
  .battle-panel{
    border-top-right-radius:0!important;
    border-bottom-right-radius:0!important;
    border-right:none!important;
    overflow:hidden!important;
  }
  .reference-right{
    border-top-left-radius:0!important;
    border-bottom-left-radius:0!important;
    border-left:1px solid #5c3a19!important;
    overflow:hidden!important;
    background:#080c0d!important;
  }

  
  .boardwrap{
    flex:1 1 auto!important;
    height:auto!important;
    min-height:0!important;
    overflow:hidden!important;
    padding:0!important;
  }
  .battlefield-layout{height:100%!important;min-height:0!important;}
  .battlefield-layout>.board{
    height:100%!important;
    min-height:0!important;
    grid-template-rows:minmax(114px,1.04fr) repeat(3,minmax(98px,1fr)) 24px repeat(3,minmax(98px,1fr)) minmax(120px,1.06fr)!important;
    gap:5px!important;
  }
  .battlefield-layout .lane{height:auto!important;min-height:0!important;padding:3px 5px!important;}
  .battlefield-layout .slots{height:100%!important;min-height:0!important;gap:5px!important;align-items:stretch!important;}
  .battlefield-layout .slot{height:100%!important;min-height:90px!important;max-height:none!important;}
  .battlefield-layout .unit{height:100%!important;grid-template-rows:22px minmax(0,1fr) 22px!important;}
  .battlefield-layout .uimg{height:100%!important;min-height:0!important;}
  .battlefield-layout .uname{font-size:12px!important;padding:3px 5px!important;}
  .battlefield-layout .stats{font-size:11px!important;padding:3px!important;}
  .battlefield-layout .lane .label{font-size:12px!important;}
  .battle-hq,.hq.faction-fortress{height:100%!important;min-height:0!important;}

  
  .ally-side-align-spacer,.ally-hand-align-spacer{flex:0 0 0!important;height:0!important;}
  .right-deck-section{flex:0 0 92px!important;min-height:92px!important;max-height:92px!important;}
  .right-deck-body{gap:8px!important;padding:6px 8px!important;}
  .right-hand-section{
    flex:1 1 auto!important;
    min-height:0!important;
    height:auto!important;
    max-height:none!important;
    overflow:hidden!important;
  }
  .right-hand-section .handbox{
    flex:1 1 auto!important;
    min-height:0!important;
    height:auto!important;
    padding:5px!important;
    overflow:hidden!important;
  }
  .right-hand-section .handhead{display:flex!important;min-height:24px!important;margin-bottom:4px!important;font-size:10px!important;}
  .right-hand-section .handhead .small{font-size:8px!important;line-height:1.3!important;}
  #hand.hand{
    height:100%!important;
    min-height:0!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    grid-template-rows:repeat(2,minmax(0,1fr))!important;
    grid-auto-rows:minmax(0,1fr)!important;
    gap:5px!important;
    overflow:hidden!important;
    padding:0!important;
  }
  #hand.hand .card{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    grid-template-rows:24px minmax(86px,1fr) 38px!important;
  }
  #hand.hand .cimg{height:auto!important;min-height:0!important;max-height:none!important;}
  #hand.hand .card-name-text{font-size:10px!important;}
  #hand.hand .card-stat-cell{min-height:28px!important;padding:1px!important;}
  #hand.hand .card-stat-cell b{font-size:12px!important;}

  
  .bottom-hud{flex:0 0 auto!important;padding:4px 6px!important;}
  .hud-status{gap:6px!important;}
  .hud-block,.hud-hp,.hud-actions{min-height:0!important;}
}

@media (min-width:851px){
  
  .app{
    grid-template-columns:220px minmax(0,1fr) 310px!important;
    gap:8px!important;
    height:100vh!important;
    padding:6px!important;
  }
  .battle-panel{
    border-top-right-radius:16px!important;
    border-bottom-right-radius:16px!important;
    border-right:1px solid var(--line)!important;
    overflow:hidden!important;
  }
  .reference-right{
    background:transparent!important;
    border:none!important;
    box-shadow:none!important;
    overflow:visible!important;
    padding:0!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
  }
  .right-action-strip{display:none!important;}
  .ally-side-align-spacer{flex:0 0 clamp(248px,31vh,292px)!important;height:auto!important;}
  .ally-hand-align-spacer{display:none!important;}
  .right-deck-section, .right-hand-section{
    border:1px solid #6c4520!important;
    box-shadow:0 8px 24px #0008,inset 0 0 0 1px #000!important;
    background:#080c0d!important;
  }
  .right-deck-section{
    flex:0 0 88px!important;
    min-height:88px!important;
    max-height:88px!important;
    border-bottom:none!important;
  }
  .right-hand-section{
    flex:0 0 398px!important;
    min-height:398px!important;
    max-height:398px!important;
    overflow:hidden!important;
  }
  .right-hand-section>.ornate-title{flex:0 0 30px!important;display:flex!important;}
  .right-hand-section .handbox{
    flex:1 1 auto!important;
    min-height:0!important;
    padding:4px 5px 5px!important;
    overflow:hidden!important;
    background:#080c0d!important;
  }
  .right-hand-section .handhead{display:none!important;}
  #hand.hand{
    height:100%!important;
    min-height:0!important;
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    grid-template-rows:repeat(2,minmax(0,1fr))!important;
    grid-auto-rows:minmax(0,1fr)!important;
    gap:4px!important;
    overflow:hidden!important;
    padding:0!important;
  }
  #hand.hand .card{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    grid-template-rows:22px minmax(78px,1fr) 34px!important;
    border-width:1px!important;
  }
  #hand.hand .cimg{height:auto!important;min-height:0!important;max-height:none!important;}
  #hand.hand .card-name-text{font-size:10px!important;}
  #hand.hand .card-stat-cell{min-height:26px!important;padding:1px!important;}
  #hand.hand .card-stat-cell b{font-size:11px!important;}
  #hand.hand .card-stat-cell span{font-size:6px!important;}

  
  .boardwrap{overflow:hidden!important;padding:0!important;}
  .battlefield-layout{height:100%!important;min-height:0!important;}
  .battlefield-layout>.board{
    height:100%!important;
    min-height:0!important;
    grid-template-rows:minmax(128px,1.05fr) repeat(3,minmax(118px,1fr)) 24px repeat(3,minmax(118px,1fr)) minmax(132px,1.08fr)!important;
    gap:5px!important;
  }
  .battlefield-layout .lane{min-height:118px!important;height:auto!important;padding:4px 6px!important;}
  .battlefield-layout .slots{min-height:0!important;height:100%!important;gap:6px!important;align-items:stretch!important;}
  .battlefield-layout .slot{min-height:108px!important;height:100%!important;max-height:none!important;}
  .battlefield-layout .unit{height:100%!important;grid-template-rows:23px minmax(0,1fr) 23px!important;}
  .battlefield-layout .uimg{height:100%!important;min-height:0!important;}
  .battlefield-layout .uname{font-size:12px!important;padding:3px 5px!important;}
  .battlefield-layout .stats{font-size:11px!important;padding:3px!important;}
  .battlefield-layout .lane .label{font-size:12px!important;}

  
  .formation-modal-box,.formation-modal-body,.formation-modal-field,.formation-modal-note{display:none!important;}
}

@media (min-width:851px){
  
  .boardwrap{
    overflow:auto!important;
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
    overscroll-behavior:contain!important;
    touch-action:pan-y!important;
  }
  .boardwrap::-webkit-scrollbar{width:0!important;height:0!important;display:none!important;background:transparent!important;}

  
  .right-formation-mount{
    display:block!important;
    flex:0 0 auto!important;
    margin-bottom:6px!important;
  }
  .reference-right .compact-settings-holder{
    display:block!important;
    margin:0!important;
    border:1px solid #6c4520!important;
    border-radius:0!important;
    background:#080c0d!important;
    box-shadow:0 8px 24px #0008,inset 0 0 0 1px #000!important;
    padding:8px!important;
  }
  .reference-right .compact-settings-holder .ornate-title{margin-bottom:6px!important;}
  .reference-right .compact-settings-holder .formation-control{display:grid!important;gap:6px!important;font-size:11px!important;}
  .reference-right .compact-settings-holder select{width:100%!important;min-height:30px!important;}
  .reference-right .compact-settings-holder .formation-note{font-size:10px!important;line-height:1.35!important;}

  
  .battlefield-layout>.board{
    min-height:980px!important;
  }
}

@media (max-width:850px){
  .boardwrap{
    overflow:auto!important;
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
  }
  .boardwrap::-webkit-scrollbar{width:0!important;height:0!important;display:none!important;}
}

.right-hq-summary{flex:0 0 auto;display:block;background:#080c0d;border:1px solid #6c4520;box-shadow:0 8px 24px #0008,inset 0 0 0 1px #000;margin-bottom:6px}
.right-hq-line{display:grid;grid-template-columns:repeat(3,1fr);gap:6px;padding:6px}
.right-hq-stat{display:flex;align-items:center;justify-content:center;gap:6px;padding:6px 4px;border:1px solid #6b5131;background:linear-gradient(180deg,#1c1711,#0d0b08);color:#eadfc8;text-align:center}
.right-hq-stat span{font-size:10px;color:#c8b89d;font-weight:700;letter-spacing:.02em}
.right-hq-stat b{font-size:16px;color:#fff3d8;line-height:1;font-weight:950}
.right-hq-stat.hp b{color:#ffe4df}.right-hq-stat.mp b{color:#d8eeff}.right-hq-stat.ap b{color:#fff0b3}

#hand.hand .cname.card-title-area{justify-content:flex-start!important;padding-right:6px!important}
#hand.hand .card-corner-meta{position:absolute;right:5px;bottom:5px;z-index:9;display:flex;flex-direction:column;align-items:flex-end;gap:4px}
#hand.hand .card-image-grade{display:inline-flex;align-items:center;justify-content:center;min-width:22px;height:16px;padding:0 5px;border-radius:999px;border:1px solid #f3d48e;background:linear-gradient(180deg,#3b2a18,#171008);box-shadow:0 2px 6px #000c;color:#fff6e3;font-size:9px;font-weight:1000;line-height:1}
#hand.hand .card-image-grade.grade-S{border-color:var(--grade-s);color:#fff4c8;background:linear-gradient(180deg,#574316,#241906)}
#hand.hand .card-image-grade.grade-R{border-color:var(--grade-r);color:#ffe6fe;background:linear-gradient(180deg,#4a2147,#1e0f1c)}
#hand.hand .card-image-grade.grade-U{border-color:var(--grade-u);color:#e3fbff;background:linear-gradient(180deg,#153849,#091b23)}
#hand.hand .card-image-grade.grade-C{border-color:var(--grade-c);color:#eef2f6;background:linear-gradient(180deg,#29313a,#11161b)}
#hand.hand .card-image-cost{position:static!important;right:auto!important;top:auto!important;z-index:auto!important;width:24px;height:24px;border-radius:50%;display:grid;place-items:center;background:radial-gradient(circle at 35% 30%,#f9dd83,#b57918 68%,#5a3307);border:2px solid #ffe9a5;box-shadow:0 2px 7px #000c,inset 0 0 0 1px #6b3b0a;color:#171005;font-size:13px;font-weight:1000;line-height:1}
#hand.hand .card-head-grade{display:none!important}

.deck-info{justify-content:center!important}
.deck-info .deck-help{font-size:8px!important;line-height:1.2!important}

@media (min-width:851px){
  .right-deck-section{flex:0 0 96px!important;min-height:96px!important;max-height:96px!important}
  .right-deck-body{padding:5px 8px!important}
  .right-hq-stat b{font-size:15px!important}
}

.ap-spend-feedback{
  position:fixed!important;
  left:50%;
  top:18%;
  transform:translate(-50%,-10px) scale(.96);
  z-index:1000;
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px 14px;
  border:1px solid #d0a458;
  background:#090c0ff2;
  box-shadow:0 12px 35px #000d;
  color:#f2dfbe;
  opacity:0;
  pointer-events:none;
  transition:.18s ease;
}
.ap-spend-feedback.show{opacity:1;transform:translate(-50%,0) scale(1)}

.battle-hq .hq-info-overlay,
.battle-hq .hptxt{display:none!important;}

.battle-hq .hq-advisor-slot{
  position:absolute!important;
  right:7px!important;
  top:29px!important;
  bottom:7px!important;
  height:auto!important;
  width:118px!important;
  min-height:0!important;
  padding:0!important;
  overflow:hidden!important;
  display:flex!important;
  align-items:stretch!important;
  justify-content:stretch!important;
  background:linear-gradient(180deg,#11191aee,#080c0dee)!important;
}
.battle-hq .hq-advisor-slot .advisor-empty,
.battle-hq .hq-advisor-slot .advisor-card.rich{
  width:100%!important;
  height:100%!important;
  min-height:0!important;
  margin:0!important;
  border-radius:0!important;
}
.battle-hq .hq-advisor-slot .advisor-empty{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  text-align:center!important;
  padding:4px!important;
  line-height:1.2!important;
}
.battle-hq .hq-advisor-slot .advisor-card.rich{grid-template-columns:46px 1fr!important;gap:4px!important;padding:3px!important;}
.battle-hq .hq-advisor-slot .advisor-portrait{width:46px!important;height:100%!important;max-height:none!important;border-radius:0!important;}
.battle-hq .hq-advisor-slot .advisor-copy{justify-content:center!important;}

.right-hq-line{grid-template-columns:repeat(3,1fr)!important;gap:6px!important;padding:6px!important;}
.right-hq-stat{min-height:42px!important;height:42px!important;}
.right-deck-section{flex:0 0 96px!important;min-height:96px!important;max-height:96px!important;}
.right-deck-body{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:6px!important;padding:6px!important;align-items:stretch!important;}
.right-deck-body .deck-stack{display:none!important;}
.right-deck-body .deck-info,
.right-deck-body #shuffleBtn,
.right-deck-body #endTurnBtn{
  min-width:0!important;
  min-height:42px!important;
  height:42px!important;
  margin:0!important;
  border:1px solid #6b5131!important;
  background:linear-gradient(180deg,#1c1711,#0d0b08)!important;
  box-shadow:none!important;
}
.right-deck-body .deck-info{
  grid-column:1!important;
  grid-row:1!important;
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  justify-content:center!important;
  gap:1px!important;
  padding:4px!important;
  text-align:center!important;
}
.right-deck-body .deck-info b{font-size:18px!important;line-height:1!important;}
.right-deck-body .deck-help{display:none!important;}
.right-deck-body .deck-action-mount{display:contents!important;}
.right-deck-body #shuffleBtn{grid-column:2!important;grid-row:1!important;padding:4px 6px!important;font-size:12px!important;font-weight:900!important;}
.right-deck-body #endTurnBtn{grid-column:3!important;grid-row:1!important;padding:4px 6px!important;font-size:12px!important;font-weight:900!important;}

.battle-hq .hq-subtitle{top:26px!important;}
.battle-hq .hq-advisor-summary{left:10px!important;right:132px!important;bottom:7px!important;min-height:32px!important;}

@media (min-width:851px){
  
  .ally-side-align-spacer{flex:0 0 clamp(208px,26vh,248px)!important;height:auto!important;}
  .right-hq-summary{margin-bottom:4px!important;}
  .right-deck-section{margin-bottom:4px!important;}
  .right-hand-section{flex:0 0 404px!important;min-height:404px!important;max-height:404px!important;}
  .right-hand-section .handbox{padding:3px 4px 4px!important;}
}

.battle-hq .hq-advisor-slot{position:absolute!important;overflow:hidden!important;}
.battle-hq .hq-advisor-slot .advisor-slot-badge{
  position:absolute;
  left:0; right:0; top:0;
  height:18px;
  z-index:12;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:6px;
  padding:2px 5px;
  background:linear-gradient(180deg,#2d2011,#110c07);
  border-bottom:1px solid #a37a43;
  color:#f7e6c8;
  box-shadow:0 1px 4px #000a;
}
.battle-hq .hq-advisor-slot .advisor-slot-badge b{font-size:9px;line-height:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-weight:900;}
.battle-hq .hq-advisor-slot .advisor-slot-badge span{font-size:8px;line-height:1;color:#ffe29d;font-weight:900;flex:0 0 auto;}
.battle-hq .hq-advisor-slot.has-portrait .advisor-card.rich{padding-top:20px!important;}
.battle-hq .hq-advisor-slot.has-portrait .advisor-portrait{height:calc(100% - 0px)!important;}
.battle-hq .hq-advisor-slot.has-portrait .advisor-copy b{display:none!important;}

.battle-hq .hq-advisor-slot:not(.has-portrait) .advisor-empty{padding-top:4px!important;}

@media (min-width:851px){
  .reference-right{padding-bottom:12px!important;box-sizing:border-box!important;}
  .ally-side-align-spacer{flex:0 0 clamp(168px,22vh,210px)!important;height:auto!important;}
  .right-hq-summary{margin-bottom:4px!important;}
  .right-hq-line{padding:5px!important;gap:5px!important;}
  .right-hq-stat{min-height:40px!important;height:40px!important;}
  .right-hq-stat span{font-size:9px!important;}
  .right-hq-stat b{font-size:14px!important;}
  .right-deck-section{flex:0 0 92px!important;min-height:92px!important;max-height:92px!important;margin-bottom:4px!important;}
  .right-deck-body{padding:5px!important;gap:5px!important;}
  .right-hand-section{flex:0 0 390px!important;min-height:390px!important;max-height:390px!important;overflow:hidden!important;}
  .right-hand-section>.ornate-title{flex:0 0 28px!important;}
  .right-hand-section .handbox{padding:3px 4px 10px!important;overflow:hidden!important;}
  #hand.hand{gap:4px!important;padding:0!important;}
  #hand.hand .card{grid-template-rows:20px minmax(72px,1fr) 32px!important;}
  #hand.hand .card-name-text{font-size:9px!important;}
  #hand.hand .card-stat-cell{min-height:24px!important;padding:1px!important;}
  #hand.hand .card-stat-cell b{font-size:10px!important;}
  #hand.hand .card-stat-cell span{font-size:6px!important;}
  #hand.hand .card-corner-meta{right:4px!important;bottom:4px!important;gap:3px!important;}
  #hand.hand .card-image-grade{min-width:20px!important;height:15px!important;font-size:8px!important;padding:0 4px!important;}
  #hand.hand .card-image-cost{width:22px!important;height:22px!important;font-size:12px!important;}
}

#hand.hand .card.utility-card{grid-template-rows:20px minmax(0,1fr)!important;}
#hand.hand .card.utility-card .cimg{height:100%!important;min-height:0!important;max-height:none!important;border-bottom:0!important;}
#hand.hand .card.utility-card .cstats,#hand.hand .card.utility-card .ctext{display:none!important;}
#hand.hand .card .ctext{display:none!important;}
#hand.hand .card.utility-card .card-type-badge{left:4px!important;bottom:4px!important;}

.card-art-img.auto-folder-art,.unit-art-img.auto-folder-art{width:100%!important;height:100%!important;object-fit:cover!important;display:block!important;}

.battle-hq .hq-advisor-slot .advisor-copy b{display:block!important;}
.battle-hq .hq-advisor-slot .advisor-slot-badge span{min-width:34px;text-align:right;}

.battlefield-layout .unit{grid-template-rows:minmax(0,1fr) 23px!important;}
.battlefield-layout .uname{display:none!important;}
.battlefield-layout .uimg{position:relative!important;overflow:hidden!important;}
.battlefield-layout .unit-image-meta{position:absolute;left:4px;right:4px;top:4px;z-index:8;display:flex;align-items:center;justify-content:space-between;gap:4px;padding:2px 4px;background:linear-gradient(180deg,#05080dcc,#05080d80);border-bottom:1px solid #ffffff24;pointer-events:none;}
.battlefield-layout .unit-image-meta .field-unit-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px;font-weight:950;color:#fff7e8;text-shadow:0 1px 4px #000;}
.battlefield-layout .unit-image-meta .field-grade{flex:0 0 auto;min-width:20px;height:16px;font-size:9px;}

.battlefield-layout .unit-art-img{object-fit:cover!important;object-position:var(--img-x,50%) var(--img-y,50%)!important;transform-origin:var(--img-x,50%) var(--img-y,50%)!important;}
.battlefield-layout .unit-art-img.auto-folder-art{object-position:var(--img-x,50%) var(--img-y,50%)!important;}

#hand.hand .card-image-cost{border:1px solid #ffe9a5!important;box-shadow:0 2px 6px #000b!important;}

.reference-right,.right-hand-section,.right-hand-section .handbox,#hand.hand{scrollbar-width:none!important;-ms-overflow-style:none!important;}
.reference-right::-webkit-scrollbar,.right-hand-section::-webkit-scrollbar,.right-hand-section .handbox::-webkit-scrollbar,#hand.hand::-webkit-scrollbar{width:0!important;height:0!important;display:none!important;}
@media (min-width:851px){
  .reference-right{overflow-y:auto!important;overflow-x:hidden!important;overscroll-behavior:contain!important;}
  .right-hand-section{overflow-y:auto!important;overflow-x:hidden!important;}
  .right-hand-section .handbox{overflow-y:auto!important;overflow-x:hidden!important;}
  #hand.hand{overflow-y:auto!important;overflow-x:hidden!important;align-content:start!important;grid-template-rows:repeat(2,minmax(176px,1fr))!important;grid-auto-rows:minmax(176px,1fr)!important;}

  
  .battlefield-layout>.board{height:auto!important;min-height:1220px!important;grid-template-rows:156px repeat(3,142px) 28px repeat(3,142px) 162px!important;gap:6px!important;}
  .battlefield-layout .lane{height:142px!important;min-height:142px!important;padding:4px 6px!important;}
  .battlefield-layout .slot{height:100%!important;min-height:132px!important;max-height:none!important;}
}

.formation-start-btn{width:100%;margin-top:4px;min-height:32px!important;font-weight:900;}
body.prebattle .board,body.prebattle .right-hand-section,body.prebattle .right-deck-body{filter:saturate(.78) brightness(.82);}
body.prebattle .board,body.prebattle .right-hand-section,body.prebattle .right-deck-body{pointer-events:none;}
#allyFormationSelect:disabled{opacity:.6;cursor:not-allowed;}

.deck-title-tools{display:flex;align-items:center;gap:6px;}
.deck-builder-open{border:1px solid #9c7642;background:#17110b;color:#f1d8aa;font-size:9px;font-weight:900;padding:2px 7px;cursor:pointer;}
.deck-builder-open:hover{background:#2a1c0f;}
.deck-builder-box{width:min(1050px,96vw)!important;max-height:92vh!important;padding:0!important;overflow:hidden!important;display:flex;flex-direction:column;}
.deck-builder-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 16px;border-bottom:1px solid #5c4328;background:#0a0d0f;}
.deck-builder-head h2{margin:0 0 3px;font-size:18px;color:#f0d5a3;}
.deck-builder-toolbar{display:grid;grid-template-columns:120px 120px minmax(180px,1fr) 90px;gap:8px;padding:10px 12px;border-bottom:1px solid #40301f;background:#0d1115;align-items:end;}
.deck-builder-toolbar label{display:grid;gap:4px;font-size:9px;color:#cdbb9e;}
.deck-builder-toolbar select,.deck-builder-toolbar input{min-height:32px;padding:5px 7px;background:#111925;color:#e8edf5;border:1px solid #45556e;}
.deck-builder-count{height:32px;display:flex;align-items:center;justify-content:center;border:1px solid #8c6837;background:#17120d;color:#e7d2ac;font-size:12px;}.deck-builder-count b{font-size:18px;color:#ffdd91;margin-right:4px;}
.deck-builder-main{flex:1;min-height:0;display:grid;grid-template-columns:1.15fr .85fr;gap:8px;padding:10px 12px;background:#070a0d;}
.deck-builder-pane{min-height:0;display:flex;flex-direction:column;border:1px solid #49351f;background:#0b0f13;}
.deck-builder-pane-title{flex:0 0 30px;display:flex;align-items:center;padding:0 9px;border-bottom:1px solid #49351f;color:#e6cfaa;font-size:11px;font-weight:900;}
.deck-builder-list{flex:1;min-height:0;overflow:auto;padding:6px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;align-content:start;scrollbar-width:none;}.deck-builder-list::-webkit-scrollbar{display:none;}
.deck-builder-list.selected{grid-template-columns:1fr;}
.deck-builder-card{min-width:0;display:grid;grid-template-columns:38px minmax(0,1fr) auto;align-items:center;gap:6px;padding:4px;border:1px solid #3c4858;background:#10161d;color:#e8edf2;text-align:left;cursor:pointer;}
.deck-builder-card.selected{grid-template-columns:minmax(0,1fr) auto;border-color:#654a2b;background:#14110d;}
.deck-builder-card:hover{border-color:#c59a57;background:#171e26;}
.deck-builder-thumb{width:38px;height:48px;display:block;overflow:hidden;background:#151719;}.deck-builder-thumb img,.deck-builder-thumb .default-art{width:100%;height:100%;object-fit:cover;}
.deck-builder-copy{min-width:0;display:flex;flex-direction:column;gap:2px;}.deck-builder-copy b{font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}.deck-builder-copy small{font-size:8px;color:#9faebe;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.deck-builder-owned{display:flex;align-items:center;gap:5px;font-size:9px;color:#c9b58e;}.deck-builder-owned em{font-style:normal;width:20px;height:20px;display:grid;place-items:center;border:1px solid #806039;color:#ffe1a3;font-size:14px;}
.deck-builder-empty{padding:16px;text-align:center;color:#84909d;font-size:10px;grid-column:1/-1;}
.deck-builder-summary{padding:8px 12px;border-top:1px solid #40301f;color:#bfae94;background:#0b0f13;font-size:10px;text-align:center;}
.deck-builder-actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:8px;padding:10px 12px;border-top:1px solid #49351f;background:#090c0f;}
@media(max-width:850px){.deck-builder-toolbar{grid-template-columns:1fr 1fr}.deck-builder-main{grid-template-columns:1fr}.deck-builder-list{max-height:260px}.deck-builder-actions{grid-template-columns:1fr}.deck-builder-box{max-height:94vh!important;overflow:auto!important;}}

.unit-class-tag{
  position:absolute;right:4px;bottom:4px;z-index:7;
  padding:2px 5px;border:1px solid #ffffff55;background:#05080dcc;
  color:#f1eadf;font-size:8px;font-weight:900;line-height:1.1;
}
.battlefield-layout .unit .typeicon{left:4px!important;right:auto!important;}
.hq-image-manager{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
.hq-image-manager>.image-adjust-title{grid-column:1/-1!important;}
@media(max-width:1050px){.hq-image-manager{grid-template-columns:1fr!important;}.hq-image-manager>.image-adjust-title{grid-column:1!important;}}
.manager-field select:disabled,.manager-field input:disabled{opacity:.45;cursor:not-allowed;}

:root{
  --grade-sss:#fff1a6;--grade-ss:#ff9f43;--grade-s:#f6cc58;--grade-rr:#ee86da;
  --grade-r:#b47cff;--grade-u:#65cdef;--grade-c:#a9b2bd;
}
.grade-SSS,.card-grade.grade-SSS{background:#66520e;color:#fff9cf;border-color:var(--grade-sss)}
.grade-SS,.card-grade.grade-SS{background:#713b0f;color:#fff0d7;border-color:var(--grade-ss)}
.grade-S,.card-grade.grade-S{background:#8a5b08;color:#fff3bd;border-color:var(--grade-s)}
.grade-RR,.card-grade.grade-RR{background:#762c68;color:#ffe0fa;border-color:var(--grade-rr)}
.grade-R,.card-grade.grade-R{background:#4b2a78;color:#efe3ff;border-color:var(--grade-r)}
.grade-U,.card-grade.grade-U{background:#205d72;color:#d9f7ff;border-color:var(--grade-u)}
.grade-C,.card-grade.grade-C{background:#3e4a59;color:#edf3fa;border-color:var(--grade-c)}
.card.grade-border-SSS,.unit.grade-border-SSS,.base-unit.grade-border-SSS{border-color:var(--grade-sss)!important;box-shadow:0 0 0 2px #9e7e17,0 0 18px #fff1a675!important}
.card.grade-border-SS,.unit.grade-border-SS,.base-unit.grade-border-SS{border-color:var(--grade-ss)!important;box-shadow:0 0 0 1px #754313,0 0 15px #ff9f435a!important}
.card.grade-border-S,.unit.grade-border-S,.base-unit.grade-border-S{border-color:var(--grade-s)!important;box-shadow:0 0 0 1px #5b4618,0 0 12px #f6cc5840!important}
.card.grade-border-RR,.unit.grade-border-RR,.base-unit.grade-border-RR{border-color:var(--grade-rr)!important;box-shadow:0 0 0 1px #59224e,0 0 11px #ee86da48!important}
.card.grade-border-R,.unit.grade-border-R,.base-unit.grade-border-R{border-color:var(--grade-r)!important;box-shadow:0 0 0 1px #3f285e,0 0 10px #b47cff44!important}
.card.grade-border-U,.unit.grade-border-U,.base-unit.grade-border-U{border-color:var(--grade-u)!important;box-shadow:0 0 0 1px #1d5264,0 0 9px #65cdef32!important}
.card.grade-border-C,.unit.grade-border-C,.base-unit.grade-border-C{border-color:var(--grade-c)!important;box-shadow:0 0 0 1px #3c444e!important}
#hand.hand .card-image-grade.grade-SSS{border-color:var(--grade-sss);color:#fffbd7;background:linear-gradient(180deg,#776112,#251b04)}
#hand.hand .card-image-grade.grade-SS{border-color:var(--grade-ss);color:#fff0d7;background:linear-gradient(180deg,#704114,#241306)}
#hand.hand .card-image-grade.grade-S{border-color:var(--grade-s);color:#fff4c8;background:linear-gradient(180deg,#574316,#241906)}
#hand.hand .card-image-grade.grade-RR{border-color:var(--grade-rr);color:#ffe5fb;background:linear-gradient(180deg,#5a2250,#20101d)}
#hand.hand .card-image-grade.grade-R{border-color:var(--grade-r);color:#f0e7ff;background:linear-gradient(180deg,#44286b,#171022)}
#hand.hand .card-image-grade.grade-U{border-color:var(--grade-u);color:#e3fbff;background:linear-gradient(180deg,#153849,#091b23)}
#hand.hand .card-image-grade.grade-C{border-color:var(--grade-c);color:#eef2f6;background:linear-gradient(180deg,#29313a,#11161b)}

.advisor:not(.has-portrait){border:4px solid #d8e1ec!important;background:#0b1422d9!important;box-shadow:inset 0 0 0 1px #25344b,0 5px 14px #0007!important}
.advisor:not(.has-portrait) .advisor-empty{font-size:12px!important;font-weight:950!important;color:#f1f5fb!important;letter-spacing:.03em;line-height:1.2!important}
.advisor:not(.has-portrait) .mana{display:none!important}

.unit-class-tag.general-class{background:#19120de8;border-color:#e3bd78;color:#ffe8b6;max-width:70px}

.equip-stat-bonus{font-style:normal;font-size:.78em;font-weight:1000;color:#8ff0a4;margin-left:1px;text-shadow:0 1px 2px #000}
.stats .equip-stat-bonus,.base-unit-stat .equip-stat-bonus{display:inline}

.zoomable-card-name{cursor:zoom-in!important;text-decoration:none;transition:.12s ease}
.zoomable-card-name:hover{text-decoration:underline;text-underline-offset:2px;filter:brightness(1.18)}
.card-image-zoom-modal{align-items:center;justify-content:center;padding:20px;overflow:auto}
.card-image-zoom-box{max-width:none;min-width:320px;background:#0c1422;border:2px solid #8da4c5;border-radius:14px;padding:12px;box-shadow:0 24px 70px #000c}
.card-image-zoom-head{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:10px}
.card-image-zoom-head b{font-size:16px}
.card-image-zoom-scroll{max-width:88vw;max-height:78vh;overflow:auto;border:1px solid #2e405d;background:#050a11;padding:10px;display:grid;place-items:center}
.card-image-zoom-visual{flex:0 0 auto;overflow:hidden;border-radius:10px;background:#101a29;display:flex;align-items:center;justify-content:center}
.card-image-zoom-visual>img,.card-image-zoom-visual>.default-art{width:100%!important;height:100%!important;object-fit:cover!important;display:block!important}
.card-image-zoom-note{margin-top:8px;text-align:center}

.slots.n5{grid-template-columns:repeat(5,minmax(82px,102px));gap:6px}
@media(max-width:850px){.slots.n5{grid-template-columns:repeat(5,94px)}}

.general-class-hand-badge{position:absolute;left:5px;bottom:5px;z-index:9;display:inline-flex;align-items:center;min-height:18px;padding:2px 6px;border:1px solid #e0bd7a;background:#17100bd9;color:#ffe8b4;border-radius:999px;font-size:8px;font-weight:950;box-shadow:0 2px 7px #000b}

#hand.hand .card.item-stat-card{grid-template-rows:20px minmax(0,1fr) auto!important;}
#hand.hand .card.item-stat-card .card-stat-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
#hand.hand .card.item-stat-card .card-stat-cell:last-child{grid-column:auto!important;}
#hand.hand .card.item-stat-card .card-stat-cell b{font-size:13px!important;white-space:nowrap!important;color:#fff2bd;}
#hand.hand .card.item-stat-card .card-stat-cell span{font-size:6px!important;white-space:nowrap!important;color:#d9c794;}
#hand.hand .card.item-stat-card .cstats{display:block!important;}
.equip-stat-bonus{white-space:nowrap;}
.roster-stats .equip-stat-bonus{font-size:.7em;}

@media (min-width:851px){
  .battlefield-layout>.board{min-height:1395px!important;grid-template-rows:156px repeat(3,170px) 28px repeat(3,170px) 162px!important;gap:6px!important;}
  .battlefield-layout .lane{height:170px!important;min-height:170px!important;padding:4px 6px!important;}
  .battlefield-layout .slot{height:100%!important;min-height:160px!important;max-height:none!important;}
}

.unit-class-tag{display:none!important;}
.unit-class-icon{position:absolute;right:5px;bottom:5px;z-index:10;width:24px;height:24px;display:grid;place-items:center;border-radius:50%;border:1px solid #ffffff88;background:#05080de8;font-size:15px;line-height:1;box-shadow:0 2px 7px #000b;}
.unit-class-icon.general-class-icon{border-color:#e3bd78;background:#19120deb;}

.battlefield-layout .unit-image-meta{pointer-events:auto!important;}
.battlefield-layout .unit-image-meta .field-unit-name{pointer-events:auto!important;cursor:zoom-in!important;}
.battlefield-layout .unit-image-meta .field-grade{pointer-events:none!important;}
.field-strategist{cursor:pointer;}
.field-strategist::after{content:'🧠';position:absolute;left:5px;bottom:31px;z-index:10;width:22px;height:22px;display:grid;place-items:center;border:1px solid #86bbff;background:#08182ee8;border-radius:50%;font-size:13px;box-shadow:0 2px 7px #000b;}
.field-strategist-menu{position:fixed;z-index:12000;width:min(280px,calc(100vw - 16px));max-height:calc(100vh - 16px);overflow:auto;display:none;padding:8px;border:1px solid #8aa9d3;border-radius:10px;background:#07101cf5;color:#edf5ff;box-shadow:0 18px 50px #000d;}
.field-strategist-menu.show{display:block;}
.field-strategist-head{display:flex;align-items:flex-end;justify-content:space-between;gap:8px;padding:4px 4px 8px;border-bottom:1px solid #405575;}
.field-strategist-head b{font-size:15px;color:#fff1c0;}.field-strategist-head span{font-size:9px;color:#9fb6d2;}
.field-strategist-actions{display:grid;gap:5px;padding-top:7px;}
.field-strategist-actions button{display:grid;gap:2px;text-align:left;padding:7px 8px;border:1px solid #415a7c;background:#111d2c;color:#eaf2fc;cursor:pointer;}
.field-strategist-actions button:hover:not(:disabled){border-color:#e0b966;background:#1b293a;}
.field-strategist-actions button:disabled{opacity:.55;cursor:not-allowed;}
.field-strategist-actions button b{font-size:11px;color:#ffe2a1;}.field-strategist-actions button span{font-size:8px;line-height:1.35;color:#b9c8da;}
.field-strategist-actions .field-passive{border-style:dashed;}
.ap-gain-feedback{border-color:#75d598!important;}
.ap-gain-feedback b{color:#91f0ad!important;}
@media(max-width:850px){
  .field-strategist-menu{left:8px!important;right:8px!important;top:auto!important;bottom:8px!important;width:auto!important;max-height:62vh;}
  .unit-class-icon{width:22px;height:22px;font-size:13px;}
}

.soldier-class-hand-icon{position:absolute;left:5px;bottom:5px;z-index:9;width:22px;height:22px;display:grid;place-items:center;border-radius:50%;border:1px solid #ffffff88;background:#05080de8;font-size:13px;box-shadow:0 2px 7px #000b;}
.base-soldier-class-icon{position:absolute;right:26px;bottom:3px;z-index:6;width:20px;height:20px;display:grid;place-items:center;border-radius:50%;border:1px solid #ffffff77;background:#05080de8;font-size:12px;}

.manager-preview-wrap input[type=file],
.hq-image-setting input[type=file]{
  position:absolute!important;
  width:1px!important;height:1px!important;
  padding:0!important;margin:-1px!important;border:0!important;
  overflow:hidden!important;clip:rect(0 0 0 0)!important;clip-path:inset(50%)!important;
  white-space:nowrap!important;
}
.manager-preview-wrap .manager-upload-label,
.hq-image-setting .manager-upload-label,
.hq-image-setting .btn{
  width:100%;display:flex;align-items:center;justify-content:center;
  box-sizing:border-box;
}
.hq-image-setting{align-content:start}
.hq-image-preview{border-radius:6px}
.hq-image-manager{align-items:start}

#hand.hand .cname.card-title-area{
  min-height:30px!important;
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto!important;
  align-items:center!important;
  gap:5px!important;
  padding:4px 6px!important;
  justify-content:stretch!important;
}
#hand.hand .card-name-text{
  justify-self:start!important;
  max-width:100%!important;
  font-size:13px!important;
  line-height:1.1!important;
  font-weight:1000!important;
  text-align:left!important;
}
#hand.hand .card-title-grade,
.collection-card-title em{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:25px;
  height:18px;
  padding:0 5px;
  border:0;
  border-radius:4px;
  font-size:9px;
  font-style:normal;
  font-weight:1000;
  line-height:1;
  box-shadow:0 1px 4px #0009;
}
#hand.hand .card-corner-meta,#hand.hand .card-image-grade,#hand.hand .card-image-cost{display:none!important;}

#hand.hand .card-bottom-icons,
.battlefield-layout .unit-bottom-icons,
.collection-card-icons{
  position:absolute;
  right:5px;
  bottom:5px;
  z-index:12;
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:4px;
  color:#fff8e8;
  font-weight:1000;
  line-height:1;
  text-shadow:0 2px 4px #000,0 0 5px #000;
  pointer-events:none;
}
#hand.hand .card-bottom-icons span,
.battlefield-layout .unit-bottom-icons span,
.collection-card-icons span{
  border:0!important;
  background:transparent!important;
  box-shadow:none!important;
  padding:0!important;
  min-width:0!important;
  height:auto!important;
  border-radius:0!important;
  font-size:15px;
  white-space:nowrap;
}
#hand.hand .card-bottom-icons .card-ap-icon,
.battlefield-layout .unit-bottom-icons span:last-child,
.collection-card-icons span:last-child{font-size:13px;color:#ffe58c;letter-spacing:-.04em;}
#hand.hand .card-type-badge{display:none!important;}
#hand.hand .general-class-hand-badge,#hand.hand .soldier-class-hand-icon{left:5px!important;right:auto!important;bottom:5px!important;}
.battlefield-layout .unit-class-icon{left:5px!important;right:auto!important;bottom:5px!important;}
.battlefield-layout .typeicon{display:none!important;}
.battlefield-layout .unit-image-meta .field-unit-name{font-size:13px!important;}
.battlefield-layout .unit-image-meta .field-grade{border:0!important;font-size:9px!important;}
.field-strategist::after{display:none!important;}

.default-card-image-manager{display:grid;gap:7px;padding:9px;border:1px solid #536176;background:#0b1118;}
.default-image-note{font-size:8px;line-height:1.45;color:#aebbc9;}
.default-image-controls{display:grid;grid-template-columns:1fr 1fr;gap:6px;}
.default-image-controls label{display:grid;gap:3px;font-size:8px;color:#cbb998;}
.default-image-controls select{min-height:30px;padding:4px 6px;background:#111925;color:#e9eef5;border:1px solid #485a73;}
.default-image-preview{height:112px;display:grid;place-items:center;overflow:hidden;border:1px dashed #51647d;background:#070b10;color:#7f8c9c;font-size:9px;}
.default-image-preview img{width:100%;height:100%;display:block;object-fit:cover;}
.default-card-image-manager input[type=file]{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;border:0!important;overflow:hidden!important;clip:rect(0 0 0 0)!important;clip-path:inset(50%)!important;white-space:nowrap!important;}

.deck-builder-toolbar{grid-template-columns:115px 115px minmax(150px,1fr) 92px 112px!important;}
.deck-builder-score{height:32px;display:flex;align-items:center;justify-content:center;border:1px solid #4a7a5a;background:#0d1711;color:#cfe8d5;font-size:10px;}
.deck-builder-score b{font-size:17px;color:#99edaa;margin-right:4px;}
.deck-builder-score.over{border-color:#a84b45;background:#21100f;color:#ffb8b3;}
.deck-builder-score.over b{color:#ff766f;}
.deck-builder-list{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:7px!important;padding:8px!important;}
.deck-builder-list.selected{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
.deck-builder-visual-card,.shop-card{
  position:relative;
  min-width:0;
  overflow:hidden;
  display:grid;
  grid-template-rows:30px minmax(118px,1fr) 28px;
  padding:0;
  border:2px solid #4a5665;
  background:#0c1219;
  color:#eaf0f6;
  text-align:left;
}
button.deck-builder-visual-card{cursor:pointer;}
button.deck-builder-visual-card:hover{filter:brightness(1.12);transform:translateY(-1px);}
.deck-builder-visual-card.selected{background:#15110d;}
.collection-card-title{min-width:0;display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:4px;padding:4px 5px;background:linear-gradient(180deg,#302117,#17100b);border-bottom:1px solid #61492e;}
.collection-card-title b{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px;font-weight:1000;color:#fff3dc;}
.collection-card-art{position:relative;min-height:0;display:block;overflow:hidden;background:#101722;}
.collection-card-art>img,.collection-card-art>.default-art{width:100%!important;height:100%!important;display:block!important;object-fit:cover!important;}
.collection-card-foot{min-width:0;display:flex;align-items:center;justify-content:space-between;gap:4px;padding:4px 5px;background:#0b1016;border-top:1px solid #354253;}
.collection-card-foot small{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:7px;color:#9eafc0;}
.collection-card-foot strong{flex:0 0 auto;font-size:10px;color:#ffe0a1;}
.deck-builder-summary .score-over{color:#ff7972;}.deck-builder-summary .score-ok{color:#8fe0a0;}

.card-shop-box{width:min(1180px,97vw)!important;max-height:94vh!important;padding:0!important;overflow:hidden!important;display:flex;flex-direction:column;}
.card-shop-head,.game-settings-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 16px;border-bottom:1px solid #5c4328;background:#0a0d0f;}
.card-shop-head h2,.game-settings-head h2{margin:0 0 3px;font-size:19px;color:#f0d5a3;}
.card-shop-toolbar{display:grid;grid-template-columns:130px 130px minmax(180px,1fr) 90px;gap:8px;padding:10px 12px;border-bottom:1px solid #40301f;background:#0d1115;align-items:end;}
.card-shop-toolbar label{display:grid;gap:4px;font-size:9px;color:#cdbb9e;}
.card-shop-toolbar select,.card-shop-toolbar input{min-height:32px;padding:5px 7px;background:#111925;color:#e8edf5;border:1px solid #45556e;}
.card-shop-count{height:32px;display:flex;align-items:center;justify-content:center;border:1px solid #8c6837;background:#17120d;color:#e7d2ac;font-size:10px;}.card-shop-count b{font-size:17px;color:#ffdd91;margin-right:3px;}
.card-shop-grid{flex:1;min-height:0;overflow:auto;display:grid;grid-template-columns:repeat(6,minmax(120px,1fr));gap:9px;padding:12px;background:#070a0d;align-content:start;scrollbar-width:none;}.card-shop-grid::-webkit-scrollbar{display:none;}
.shop-card{min-height:210px;cursor:zoom-in;}
.shop-card:hover{filter:brightness(1.12);transform:translateY(-2px);}

.game-settings-box{width:min(660px,94vw)!important;padding:0!important;overflow:hidden!important;}
.deck-rule-form{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;padding:16px;background:#0b1016;}
.deck-rule-form label{display:grid;gap:5px;padding:9px;border:1px solid #3f4d60;background:#101823;color:#d3deea;font-size:10px;font-weight:800;}
.deck-rule-form input{min-width:0;height:34px;padding:5px 7px;background:#080d13;color:#fff1c7;border:1px solid #586a80;font-size:15px;font-weight:900;text-align:center;}
.deck-rule-form .deck-limit-field{grid-column:span 2;border-color:#9a7440;background:#17120d;}
.settings-note{padding:10px 16px;border-top:1px solid #3d4857;background:#090d12;color:#9eacba;font-size:9px;line-height:1.5;}
.game-settings-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding:12px 16px;border-top:1px solid #49351f;background:#090c0f;}

.top-options{grid-template-columns:1fr 1fr!important;}
.top-options .checkline{grid-column:span 1;}
.top-options .btn{width:100%;min-width:0;}

@media(max-width:1000px){
  .card-shop-grid{grid-template-columns:repeat(4,minmax(110px,1fr));}
  .deck-builder-list{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
  .deck-builder-list.selected{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
}
@media(max-width:850px){
  #hand.hand .card-name-text{font-size:11px!important;}
  .deck-builder-toolbar{grid-template-columns:1fr 1fr!important;}
  .deck-builder-score,.deck-builder-count{min-width:0;}
  .deck-builder-list,.deck-builder-list.selected{grid-template-columns:repeat(2,minmax(0,1fr))!important;max-height:340px;}
  .card-shop-toolbar{grid-template-columns:1fr 1fr;}
  .card-shop-grid{grid-template-columns:repeat(2,minmax(120px,1fr));}
  .deck-rule-form{grid-template-columns:repeat(2,minmax(0,1fr));}
  .deck-rule-form .deck-limit-field{grid-column:span 2;}
  .default-image-controls{grid-template-columns:1fr;}
}
.game-settings-box{max-height:92vh!important;overflow:auto!important;}
.deck-builder-list{grid-auto-rows:176px!important;}
.deck-builder-visual-card{height:176px!important;min-height:176px!important;}

.battle-hq .hq-advisor-slot.has-portrait{padding:0!important;background:#080d14!important;}
.battle-hq .hq-advisor-slot .advisor-image-only{position:relative!important;width:100%!important;height:100%!important;display:block!important;padding:0!important;overflow:hidden!important;}
.battle-hq .hq-advisor-slot .advisor-image-only .advisor-portrait{width:100%!important;height:100%!important;border:0!important;border-radius:0!important;background:#0a111b!important;overflow:hidden!important;}
.battle-hq .hq-advisor-slot .advisor-image-only .advisor-portrait>img,
.battle-hq .hq-advisor-slot .advisor-image-only .advisor-portrait>.default-art{width:100%!important;height:100%!important;display:block!important;object-fit:cover!important;object-position:center top!important;}
.battle-hq .hq-advisor-slot .advisor-image-only .advisor-slot-badge{height:20px!important;padding:2px 5px!important;background:linear-gradient(180deg,#080b10e8,#080b10c7)!important;border-bottom:1px solid #d5aa62!important;}
.battle-hq .hq-advisor-slot .advisor-image-only .advisor-slot-badge b{font-size:10px!important;}
.battle-hq .hq-advisor-slot .advisor-image-only .advisor-slot-badge span{font-size:9px!important;min-width:auto!important;}

.deck-builder-score{font-size:13px!important;font-weight:900!important;}
.deck-builder-score b{font-size:22px!important;}
.collection-card-foot small{font-size:10px!important;font-weight:850!important;color:#d3deea!important;}
.collection-card-foot strong{font-size:12px!important;}
.deck-builder-summary{font-size:13px!important;}
.deck-builder-summary b{font-size:16px!important;}

@media (min-width:851px){
  
  .app{
    width:min(1168px,calc(100vw - 24px))!important;
    grid-template-columns:220px minmax(0,1fr) 372px!important;
  }
  
  .right-hand-section{flex-basis:429px!important;min-height:429px!important;max-height:429px!important;}
  
  .battlefield-layout>.board{width:100%!important;max-width:none!important;margin-left:0!important;margin-right:0!important;}
  
  .battlefield-layout .slots.n4{width:96%!important;max-width:none!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;}
  .battlefield-layout .slots.n3{width:72%!important;max-width:none!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;}
  .battlefield-layout .slots.n2{width:48%!important;max-width:none!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;}
}

.field-strategist-menu{width:min(310px,calc(100vw - 16px))!important;}
.field-strategist-head b{font-size:16px!important;}
.field-strategist-actions button b{font-size:12px!important;}
.field-strategist-actions button span{font-size:10px!important;}

@media (min-width:851px){
  
  .battlefield-layout>.board{
    grid-template-rows:156px repeat(3,170px) 28px repeat(3,170px)!important;
    min-height:1238px!important;
  }

  
  .reference-right .right-panel-hq-row{
    order:0!important;
    flex:0 0 104px!important;
    width:100%!important;
    height:104px!important;
    min-height:104px!important;
    padding:0!important;
    margin:0 0 4px!important;
    align-items:stretch!important;
    box-sizing:border-box!important;
  }
  .reference-right .right-panel-hq-row .battle-hq{
    width:100%!important;
    height:104px!important;
    min-height:104px!important;
    max-height:104px!important;
    margin:0!important;
    border-left:0!important;
    border-right:0!important;
    box-sizing:border-box!important;
  }

  
  .reference-right{padding-bottom:4px!important;}
  .right-formation-mount,
  .reference-right .right-panel-hq-row,
  .right-hq-summary,
  .right-deck-section{
    margin-bottom:4px!important;
  }
  .right-hand-section{
    margin:0!important;
    border:1px solid #6c4520!important;
    box-sizing:border-box!important;
  }
  .right-hand-section>.ornate-title{
    height:28px!important;
    min-height:28px!important;
    flex:0 0 28px!important;
  }
  .right-hand-section .handbox{
    padding:5px!important;
    margin:0!important;
    box-sizing:border-box!important;
  }

  
  .right-deck-body .deck-info b,
  .right-deck-body #shuffleBtn,
  .right-deck-body #endTurnBtn{
    font-size:13px!important;
    line-height:1!important;
    font-weight:900!important;
    letter-spacing:0!important;
  }
  .right-deck-body .deck-info,
  .right-deck-body #shuffleBtn,
  .right-deck-body #endTurnBtn{
    height:40px!important;
    min-height:40px!important;
    padding:4px 6px!important;
    box-sizing:border-box!important;
  }
}

@media (max-width:850px){
  
  .reference-right .right-panel-hq-row{
    width:100%!important;
    min-height:104px!important;
    padding:0!important;
    margin:0 0 4px!important;
  }
  .reference-right .right-panel-hq-row .battle-hq{
    width:100%!important;
    height:104px!important;
    min-height:104px!important;
  }
}

.formation-control{display:grid;gap:6px;padding:8px;border:1px solid #4d3b27;background:#0b0e10;border-radius:7px}
.formation-control>span{font-size:11px;color:#d8c8ae;font-weight:800;text-align:left}
.formation-inline{display:flex;align-items:center;gap:8px;justify-content:flex-start}
.formation-inline #allyFormationSelect{width:118px!important;min-width:118px!important;max-width:118px!important;flex:0 0 118px!important;font-size:12px!important}
.formation-inline .formation-start-btn{flex:0 0 auto;width:auto!important;min-width:98px!important;margin-top:0!important;padding:0 14px!important;white-space:nowrap}
.reference-right .compact-settings-holder .formation-inline{display:flex!important;align-items:center!important;gap:8px!important}
.reference-right .compact-settings-holder .formation-inline #allyFormationSelect{width:112px!important;min-width:112px!important;max-width:112px!important;flex:0 0 112px!important}
.reference-right .compact-settings-holder .formation-inline .formation-start-btn{width:auto!important;min-width:96px!important;margin-top:0!important}
.formation-note{display:none!important}
.right-hq-summary{display:none!important}

.battle-hq .hq-info-overlay{display:flex!important;position:absolute!important;left:12px!important;right:132px!important;top:44px!important;gap:10px!important;align-items:center!important;justify-content:flex-start!important;flex-wrap:wrap!important;pointer-events:none!important;z-index:8!important}
.battle-hq .hptxt{display:none!important}
.battle-hq .hq-stat-chip{display:inline-flex!important;align-items:center!important;gap:5px!important;padding:0!important;background:transparent!important;border:0!important;border-radius:0!important;box-shadow:none!important;font-size:13px!important;font-weight:950!important;color:#fff7e8!important;text-shadow:0 2px 8px rgba(0,0,0,.95),0 0 12px rgba(0,0,0,.8)!important}
.battle-hq .hq-stat-chip .hq-stat-icon{font-size:12px!important;opacity:.98!important}
.battle-hq .hq-stat-chip b,.battle-hq .hq-stat-chip .hq-stat-value{font-size:16px!important;line-height:1!important;font-weight:950!important;color:inherit!important}
.battle-hq .hq-stat-chip.skill{display:none!important}
#enemyHq .hq-info-overlay{right:136px!important}
#allyHq .hq-info-overlay{right:136px!important}
@media (max-width: 1480px){
  .formation-inline #allyFormationSelect{width:108px!important;min-width:108px!important;max-width:108px!important;flex-basis:108px!important}
  .battle-hq .hq-info-overlay{left:10px!important;right:124px!important;top:40px!important;gap:8px!important}
  .battle-hq .hq-stat-chip{font-size:12px!important}
  .battle-hq .hq-stat-chip b,.battle-hq .hq-stat-chip .hq-stat-value{font-size:14px!important}
}

.reference-right #rightFormationMount{
  order:-10!important;
  flex:0 0 auto!important;
  width:100%!important;
  min-height:0!important;
  margin:0 0 6px!important;
  display:block!important;
}
.reference-right #rightFormationMount .compact-settings-holder{
  display:block!important;
  width:100%!important;
  margin:0!important;
}
.reference-right .right-panel-hq-row{
  flex:0 0 136px!important;
  height:136px!important;
  min-height:136px!important;
  margin:0 0 6px!important;
}
.reference-right .right-panel-hq-row .battle-hq{
  height:136px!important;
  min-height:136px!important;
  max-height:136px!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-info-overlay{
  top:48px!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot{
  top:33px!important;
  height:88px!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-summary{
  bottom:9px!important;
}
@media (max-width:850px){
  .reference-right .right-panel-hq-row{
    flex-basis:124px!important;
    height:124px!important;
    min-height:124px!important;
  }
  .reference-right .right-panel-hq-row .battle-hq{
    height:124px!important;
    min-height:124px!important;
    max-height:124px!important;
  }
  .reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot{
    height:80px!important;
  }
}

.reference-right #allySideAlignSpacer,
.reference-right #allyHandAlignSpacer{
  display:none!important;
  height:0!important;
  flex:0 0 0!important;
}
.reference-right #rightFormationMount{
  order:-10!important;
  flex:0 0 auto!important;
  margin:0 0 6px!important;
}
.reference-right .right-panel-hq-row{
  order:-9!important;
  flex:1 1 auto!important;
  height:auto!important;
  min-height:190px!important;
  max-height:none!important;
  margin:0 0 6px!important;
  align-items:stretch!important;
  overflow:hidden!important;
}
.reference-right .right-panel-hq-row .battle-hq{
  width:100%!important;
  height:100%!important;
  min-height:190px!important;
  max-height:none!important;
  flex:1 1 auto!important;
  margin:0!important;
}
.reference-right .right-deck-section{
  order:-8!important;
  flex:0 0 96px!important;
  min-height:96px!important;
  max-height:96px!important;
  margin:0 0 4px!important;
}
.reference-right .right-hand-section{order:-7!important;}
.reference-right .formation-inline{
  display:grid!important;
  grid-template-columns:minmax(92px,112px) minmax(88px,1fr) minmax(78px,1fr)!important;
  gap:6px!important;
  align-items:stretch!important;
}
.reference-right .formation-inline #allyFormationSelect{
  width:100%!important;
  min-width:0!important;
  max-width:none!important;
  flex:none!important;
}
.reference-right .formation-inline .formation-start-btn,
.reference-right .formation-inline .formation-deck-btn{
  width:100%!important;
  min-width:0!important;
  margin:0!important;
  padding:0 7px!important;
  min-height:32px!important;
  white-space:nowrap!important;
  font-size:11px!important;
  font-weight:900!important;
}
.reference-right .formation-inline .formation-deck-btn{
  border-color:#8b6b3c!important;
  background:linear-gradient(180deg,#2b2419,#17130e)!important;
  color:#f3dfb6!important;
}
.right-deck-section .deck-title-tools,
.right-deck-section .title-count{
  display:none!important;
}
@media (max-width:850px){
  .reference-right .right-panel-hq-row{
    flex:1 1 auto!important;
    height:auto!important;
    min-height:180px!important;
    max-height:none!important;
  }
  .reference-right .right-panel-hq-row .battle-hq{
    height:100%!important;
    min-height:180px!important;
    max-height:none!important;
  }
}

@media (min-width:851px){
  
  .app{
    width:min(1516px,calc(100vw - 24px))!important;
    grid-template-columns:372px minmax(520px,1fr) 372px!important;
  }
  .reference-left,.reference-right{min-width:0!important;width:auto!important;}

  
  .battlefield-layout>.board{
    grid-template-rows:repeat(3,170px) 28px repeat(3,170px)!important;
    min-height:1048px!important;
  }

  
  .reference-left .enemy-hq-host{
    flex:0 0 auto!important;
    min-height:190px!important;
    margin:6px 0!important;
    padding:0!important;
    border:0!important;
    background:#080c0e!important;
    overflow:hidden!important;
  }
  .reference-left .enemy-hq-mount,
  .reference-left .enemy-hq-row{
    width:100%!important;
    height:100%!important;
    min-height:190px!important;
    padding:0!important;
    margin:0!important;
    box-sizing:border-box!important;
    align-items:stretch!important;
  }
  .reference-left .enemy-hq-row .battle-hq{
    width:100%!important;
    height:100%!important;
    min-height:190px!important;
    max-height:none!important;
    margin:0!important;
    border-left:0!important;
    border-right:0!important;
    box-sizing:border-box!important;
  }
}

.battle-log-hidden{display:none!important;}

#castleEnemyAdvisorSummary,.battle-hq .hq-advisor-summary,#phaseBadge{display:none!important;}
.turn-plate{gap:0!important;}

.battle-hq .hq-advisor-slot{
  width:94px!important;
  height:144px!important;
  min-width:94px!important;
  min-height:144px!important;
  max-width:94px!important;
  max-height:144px!important;
  right:12px!important;
  top:50%!important;
  bottom:auto!important;
  transform:translateY(-50%)!important;
  padding:0!important;
  border:1px solid #9b7844!important;
  border-radius:4px!important;
  box-shadow:none!important;
  overflow:hidden!important;
  background:#080d14!important;
  box-sizing:border-box!important;
}
.battle-hq .hq-advisor-slot .advisor-card,
.battle-hq .hq-advisor-slot .advisor-image-only,
.battle-hq .hq-advisor-slot .advisor-portrait{
  display:block!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  overflow:hidden!important;
  background:#080d14!important;
}
.battle-hq .hq-advisor-slot .advisor-portrait>img,
.battle-hq .hq-advisor-slot .advisor-portrait>.default-art,
.battle-hq .hq-advisor-slot .advisor-portrait>svg{
  display:block!important;
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  object-position:center top!important;
}
.battle-hq .hq-advisor-slot .advisor-slot-badge{
  position:absolute!important;
  left:0!important;
  right:0!important;
  top:0!important;
  bottom:auto!important;
  height:22px!important;
  padding:2px 4px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  background:linear-gradient(180deg,#090d12ed,#090d12c9)!important;
  border:0!important;
  border-bottom:1px solid #9b7844!important;
  z-index:5!important;
  box-sizing:border-box!important;
}
.battle-hq .hq-advisor-slot .advisor-slot-badge b{font-size:9px!important;}
.battle-hq .hq-advisor-slot .advisor-slot-badge span{font-size:8px!important;}
.battle-hq .hq-advisor-slot .advisor-empty{
  display:grid!important;
  place-items:center!important;
  width:100%!important;
  height:100%!important;
  padding:8px!important;
  border:0!important;
  font-size:11px!important;
  line-height:1.35!important;
  text-align:center!important;
  color:#c7b18f!important;
  box-sizing:border-box!important;
}

.battle-hq .hq-info-overlay{
  right:118px!important;
  top:46px!important;
}

.reference-topbar{
  grid-template-columns:auto auto minmax(210px,260px) auto!important;
  align-items:center!important;
}
.simplified-top-control{display:flex!important;align-items:center!important;}
.top-card-actions{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:8px!important;
  width:100%!important;
  min-width:220px!important;
  align-items:stretch!important;
}
.top-card-actions .btn{
  width:100%!important;
  min-width:0!important;
  height:34px!important;
  min-height:34px!important;
  padding:5px 8px!important;
  font-size:11px!important;
  font-weight:900!important;
  box-sizing:border-box!important;
}

@media (max-width:850px){
  .battle-hq .hq-advisor-slot{
    width:84px!important;
    height:128px!important;
    min-width:84px!important;
    min-height:128px!important;
    max-width:84px!important;
    max-height:128px!important;
    right:8px!important;
  }
  .battle-hq .hq-info-overlay{right:100px!important;}
  .top-card-actions{min-width:0!important;grid-template-columns:1fr 1fr!important;}
}

#leftMenuMount .reference-topbar{
  width:100%!important;
  margin:0!important;
  padding:6px!important;
  display:grid!important;
  grid-template-columns:1fr 1fr!important;
  grid-template-rows:auto auto auto!important;
  gap:6px!important;
  box-sizing:border-box!important;
}
#leftMenuMount .simplified-top-control{
  grid-column:1!important;
  grid-row:1!important;
  display:flex!important;
}
#leftMenuMount .simplified-top-control .top-new{
  width:100%!important;
  height:30px!important;
  min-height:30px!important;
}
#leftMenuMount .turn-plate{
  grid-column:2!important;
  grid-row:1!important;
  min-height:30px!important;
  padding:2px 6px!important;
}
#leftMenuMount .turn-plate>div{
  display:block!important;
  font-size:12px!important;
  line-height:1!important;
}
#leftMenuMount .turn-plate b{font-size:20px!important;}
#leftMenuMount .top-card-actions{
  grid-column:1/3!important;
  grid-row:2!important;
  width:100%!important;
  min-width:0!important;
}
#leftMenuMount .faction-pickers{
  grid-column:1/3!important;
  grid-row:3!important;
  display:grid!important;
  grid-template-columns:1fr 1fr!important;
  gap:6px!important;
  width:100%!important;
}
#leftMenuMount .faction-pickers label{min-width:0!important;}

.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot{
  width:96px!important;
  height:148px!important;
  min-width:96px!important;
  min-height:148px!important;
  max-width:96px!important;
  max-height:148px!important;
  right:10px!important;
  top:50%!important;
  bottom:auto!important;
  transform:translateY(-50%)!important;
  margin:0!important;
  display:flex!important;
  align-items:stretch!important;
  justify-content:stretch!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-info-overlay,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-summary,
.reference-right .right-panel-hq-row .battle-hq .hq-unit-slot{
  right:118px!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-card,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-image-only,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-portrait,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-empty{
  width:100%!important;
  height:100%!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-empty{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  text-align:center!important;
  padding:8px 7px!important;
  font-size:11px!important;
  line-height:1.3!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-slot-badge{
  height:20px!important;
  padding:2px 5px!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-slot-badge b{
  font-size:10px!important;
}
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-slot-badge span{
  font-size:8px!important;
}
@media (max-width:850px){
  .reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot{
    width:86px!important;
    height:132px!important;
    min-width:86px!important;
    min-height:132px!important;
    max-width:86px!important;
    max-height:132px!important;
    right:8px!important;
  }
  .reference-right .right-panel-hq-row .battle-hq .hq-info-overlay,
  .reference-right .right-panel-hq-row .battle-hq .hq-advisor-summary,
  .reference-right .right-panel-hq-row .battle-hq .hq-unit-slot{
    right:100px!important;
  }
}

@media (min-width:851px){
  
  .battlefield-layout .slots.n4{
    width:76.8%!important;
    max-width:none!important;
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:6px!important;
  }
  .battlefield-layout .slots.n3{
    width:57.6%!important;
    max-width:none!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:6px!important;
  }
  .battlefield-layout .slots.n2{
    width:38.4%!important;
    max-width:none!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:6px!important;
  }

  
  .reference-left .enemy-hq-host,
  .reference-left .enemy-hq-row,
  .reference-left .enemy-hq-row .battle-hq,
  .reference-right .right-panel-hq-row,
  .reference-right .right-panel-hq-row .battle-hq{
    min-height:190px!important;
    box-sizing:border-box!important;
  }
}

.reference-left .enemy-hq-row .battle-hq .hq-advisor-slot,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot{
  width:96px!important;
  height:148px!important;
  min-width:96px!important;
  min-height:148px!important;
  max-width:96px!important;
  max-height:148px!important;
  right:10px!important;
  top:50%!important;
  bottom:auto!important;
  transform:translateY(-50%)!important;
  margin:0!important;
  padding:0!important;
  border:1px solid #9b7844!important;
  border-radius:4px!important;
  box-shadow:none!important;
  overflow:hidden!important;
  background:#080d14!important;
  box-sizing:border-box!important;
}
.reference-left .enemy-hq-row .battle-hq .hq-info-overlay,
.reference-left .enemy-hq-row .battle-hq .hq-unit-slot,
.reference-right .right-panel-hq-row .battle-hq .hq-info-overlay,
.reference-right .right-panel-hq-row .battle-hq .hq-unit-slot{
  right:118px!important;
}
.reference-left .enemy-hq-row .battle-hq .hq-advisor-slot .advisor-card,
.reference-left .enemy-hq-row .battle-hq .hq-advisor-slot .advisor-image-only,
.reference-left .enemy-hq-row .battle-hq .hq-advisor-slot .advisor-portrait,
.reference-left .enemy-hq-row .battle-hq .hq-advisor-slot .advisor-empty,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-card,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-image-only,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-portrait,
.reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot .advisor-empty{
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
}
@media (max-width:850px){
  .reference-left .enemy-hq-row .battle-hq .hq-advisor-slot,
  .reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot{
    width:86px!important;
    height:132px!important;
    min-width:86px!important;
    min-height:132px!important;
    max-width:86px!important;
    max-height:132px!important;
    right:8px!important;
  }
  .reference-left .enemy-hq-row .battle-hq .hq-info-overlay,
  .reference-left .enemy-hq-row .battle-hq .hq-unit-slot,
  .reference-right .right-panel-hq-row .battle-hq .hq-info-overlay,
  .reference-right .right-panel-hq-row .battle-hq .hq-unit-slot{
    right:100px!important;
  }
}

@media (min-width:851px){
  .card-shop-grid{
    grid-template-columns:repeat(auto-fill,118px)!important;
    grid-auto-rows:185px!important;
    justify-content:start!important;
    align-items:start!important;
    gap:9px!important;
  }
  .card-shop-grid .shop-card{
    width:118px!important;
    height:185px!important;
    min-width:118px!important;
    min-height:185px!important;
    max-width:118px!important;
    max-height:185px!important;
    grid-template-rows:22px minmax(0,1fr) 34px!important;
    box-sizing:border-box!important;
  }
  .card-shop-grid .collection-card-title{
    min-height:22px!important;
    padding:2px 4px!important;
  }
  .card-shop-grid .collection-card-title b{font-size:10px!important;}
  .card-shop-grid .collection-card-art{min-height:0!important;}
  .card-shop-grid .collection-card-foot{
    min-height:34px!important;
    padding:3px 4px!important;
  }
  .card-shop-grid .collection-card-foot small{font-size:7px!important;}
  .card-shop-grid .collection-card-foot strong{font-size:10px!important;}
}
@media (max-width:850px){
  .card-shop-grid{
    grid-template-columns:repeat(auto-fill,minmax(104px,1fr))!important;
    grid-auto-rows:170px!important;
    gap:7px!important;
  }
  .card-shop-grid .shop-card{
    width:100%!important;
    height:170px!important;
    min-height:170px!important;
    max-height:170px!important;
    grid-template-rows:21px minmax(0,1fr) 32px!important;
    box-sizing:border-box!important;
  }
}

@media (min-width:851px){
  .battle-panel .boardwrap{
    width:80%!important;
    max-width:80%!important;
    margin-left:auto!important;
    margin-right:auto!important;
  }
  .battle-panel .battlefield-layout{
    width:100%!important;
    max-width:100%!important;
    margin:0 auto!important;
  }
}
.reference-left .enemy-hq-host,
.reference-left .enemy-hq-mount,
.reference-left .enemy-hq-row,
.reference-left .enemy-hq-row .battle-hq{
  width:100%!important;
  max-width:100%!important;
  box-sizing:border-box!important;
}
.hand-pager{
  flex:0 0 28px;
  min-height:28px;
  display:grid;
  grid-template-columns:34px 1fr 34px;
  align-items:center;
  gap:6px;
  margin:0 0 5px;
  padding:2px 4px;
  border:1px solid #5b4024;
  background:#0b0e10;
}
.hand-pager[hidden]{display:none!important;}
.hand-pager .btn{height:24px!important;min-height:24px!important;padding:0!important;font-size:18px!important;line-height:1!important;}
.hand-pager b{text-align:center;font-size:11px;color:#f0d7a7;}
.concealed-unit .stats{position:relative;overflow:hidden;background:linear-gradient(180deg,#1a2026,#0a0d10)!important;}
.concealed-unit .stats::before{content:'';position:absolute;inset:0;background:linear-gradient(110deg,transparent,#dbe8f02e,transparent);pointer-events:none;}
.concealed-unit .stats span{position:relative;color:#eef5fa!important;text-shadow:0 1px 5px #000;}
.smoke-buff{background:#dfe9ef!important;color:#15202a!important;border-color:#fff!important;}
.rules-box{width:min(980px,94vw)!important;max-height:88vh!important;overflow:auto!important;}
.rules-head{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;margin-bottom:12px;padding-bottom:10px;border-bottom:1px solid #76522c;}
.rules-head h2{margin:0 0 4px;}
.rules-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;}
.rules-grid section{padding:11px 13px;border:1px solid #5a4127;background:linear-gradient(180deg,#101417,#090c0e);}
.rules-grid h3{margin:0 0 8px;color:#efca8c;font-size:14px;}
.rules-grid ul{margin:0;padding-left:18px;display:grid;gap:5px;}
.rules-grid li,.rules-grid dd{font-size:11px;line-height:1.5;color:#d6cbb9;}
.rules-grid dl{display:grid;grid-template-columns:82px 1fr;gap:5px 8px;margin:0;}
.rules-grid dt{font-size:11px;font-weight:900;color:#f1d6a6;}
.rules-grid dd{margin:0;}
.formation-start-btn.warn{background:linear-gradient(180deg,#6d241f,#39110f)!important;border-color:#b95d4e!important;color:#fff0e8!important;}
@media (max-width:850px){
  .rules-grid{grid-template-columns:1fr;}
  .rules-box{width:96vw!important;max-height:92vh!important;}
}

#restartBtn,.top-new,.turn-plate,.enemy-turn-badge{display:none!important;}
#leftMenuMount .reference-topbar{
  display:grid!important;
  grid-template-columns:1fr!important;
  grid-template-rows:auto auto!important;
  gap:6px!important;
  padding:6px!important;
}
#leftMenuMount .top-card-actions{
  grid-column:1!important;
  grid-row:1!important;
  display:grid!important;
  grid-template-columns:1fr 1fr!important;
  gap:7px!important;
  width:100%!important;
}
#leftMenuMount .top-card-actions .btn{
  width:100%!important;
  height:36px!important;
  min-height:36px!important;
  padding:6px 8px!important;
  font-size:12px!important;
  font-weight:900!important;
}
#leftMenuMount .faction-pickers{
  grid-column:1!important;
  grid-row:2!important;
  display:grid!important;
  grid-template-columns:1fr 1fr!important;
  gap:7px!important;
  width:100%!important;
}

.reference-left .enemy-hq-host,
.reference-left .enemy-hq-mount,
.reference-left .enemy-hq-row,
.reference-left .enemy-hq-row .battle-hq{
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  margin-left:0!important;
  margin-right:0!important;
  box-sizing:border-box!important;
}

#allyHq .hq-advisor-slot{
  top:calc(50% - 12px)!important;
  transform:translateY(-50%)!important;
}
.ally-hq-turn{
  position:absolute;
  right:10px;
  top:calc(50% + 66px);
  width:96px;
  height:20px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  border:1px solid #8a6a3f;
  background:linear-gradient(180deg,#111820e8,#080c10e8);
  color:#dfceb0;
  font-size:10px;
  font-weight:900;
  box-sizing:border-box;
  z-index:12;
}
.ally-hq-turn b{font-size:13px;color:#ffe09d;line-height:1;}

#hand.hand .card.affordable{
  border-color:#f7d77f!important;
  box-shadow:0 0 0 1px #fff1b9,0 0 13px #ffd56c88,inset 0 0 0 1px #6e501d!important;
}
#hand.hand .card.affordable:not(.selected)::after{
  content:'';
  position:absolute;
  inset:1px;
  border:1px solid #fff2ad66;
  pointer-events:none;
  z-index:15;
}

.reference-right #rightFormationMount{margin-bottom:6px!important;}
.reference-right .right-panel-hq-row{margin-bottom:6px!important;}
.reference-right .right-deck-section{
  margin-bottom:6px!important;
  padding-bottom:0!important;
}
.reference-right .right-deck-body{
  padding-bottom:0!important;
  margin-bottom:0!important;
  align-items:stretch!important;
}
.reference-right .right-hand-section{margin-top:0!important;}
.reference-right #allyHandAlignSpacer{display:none!important;height:0!important;min-height:0!important;}

#hand.hand .card:not(.utility-card){
  grid-template-rows:20px minmax(0,1fr) 34px!important;
  row-gap:0!important;
}
#hand.hand .card .cimg{
  margin:0!important;
  padding:0!important;
  border-bottom:0!important;
}
#hand.hand .card .cstats{
  height:34px!important;
  min-height:34px!important;
  margin:0!important;
  padding:0!important;
  align-self:stretch!important;
}
#hand.hand .card-stat-grid{
  height:34px!important;
  min-height:34px!important;
  gap:2px!important;
  margin:0!important;
}
#hand.hand .card-stat-cell{
  height:34px!important;
  min-height:34px!important;
  padding:1px!important;
  box-sizing:border-box!important;
}

.rules-box{width:min(1040px,95vw)!important;}
.rules-head h2{font-size:24px!important;}
.rules-head .small{font-size:13px!important;line-height:1.55!important;}
.rules-grid{gap:12px!important;}
.rules-grid section{padding:14px 16px!important;}
.rules-grid h3{font-size:17px!important;margin-bottom:10px!important;}
.rules-grid li,.rules-grid dd{
  font-size:14px!important;
  line-height:1.65!important;
}
.rules-grid dt{
  font-size:14px!important;
  line-height:1.55!important;
}
.rules-grid dl{grid-template-columns:104px 1fr!important;gap:7px 10px!important;}
.rules-grid ul{gap:7px!important;padding-left:20px!important;}

@media (max-width:850px){
  #allyHq .hq-advisor-slot{top:calc(50% - 11px)!important;}
  .ally-hq-turn{right:8px;top:calc(50% + 59px);width:86px;height:19px;font-size:9px;}
  .ally-hq-turn b{font-size:12px;}
  .rules-grid li,.rules-grid dd,.rules-grid dt{font-size:13px!important;}
  .rules-grid dl{grid-template-columns:88px 1fr!important;}
}

.top-card-actions,
#leftMenuMount .top-card-actions{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  grid-auto-rows:38px!important;
  gap:7px!important;
  width:100%!important;
  align-items:stretch!important;
}
.top-card-actions #cardShopBtn,
.top-card-actions #cardManagerBtn,
#leftMenuMount .top-card-actions #cardShopBtn,
#leftMenuMount .top-card-actions #cardManagerBtn{
  grid-column:auto!important;
  grid-row:auto!important;
  width:100%!important;
  min-width:0!important;
  max-width:none!important;
  height:38px!important;
  min-height:38px!important;
  padding:6px 8px!important;
  margin:0!important;
  font-size:12px!important;
  line-height:1!important;
  box-sizing:border-box!important;
}

.ally-hq-turn{
  right:10px!important;
  top:calc(50% + 64px)!important;
  bottom:8px!important;
  width:96px!important;
  height:auto!important;
  min-height:34px!important;
  padding:4px 5px!important;
  gap:8px!important;
  font-size:15px!important;
  line-height:1!important;
  border-color:#b28b50!important;
  background:linear-gradient(180deg,#17212ce8,#080d13f2)!important;
  box-shadow:inset 0 0 0 1px #0009,0 3px 10px #0009!important;
}
.ally-hq-turn span{font-size:15px!important;font-weight:950!important;color:#f2dfbd!important;}
.ally-hq-turn b{font-size:22px!important;font-weight:1000!important;color:#ffe28f!important;line-height:1!important;}

.reference-right .right-deck-section{
  flex:0 0 108px!important;
  height:108px!important;
  min-height:108px!important;
  max-height:108px!important;
}
.reference-right .right-deck-section>.ornate-title{
  flex:0 0 30px!important;
  height:30px!important;
  min-height:30px!important;
}
.reference-right .right-deck-body{
  flex:0 0 78px!important;
  height:78px!important;
  min-height:78px!important;
  max-height:78px!important;
  padding:6px!important;
  gap:6px!important;
  box-sizing:border-box!important;
}
.reference-right .right-deck-body .deck-info,
.reference-right .right-deck-body #shuffleBtn,
.reference-right .right-deck-body #endTurnBtn{
  height:100%!important;
  min-height:0!important;
  box-sizing:border-box!important;
}
.reference-right .right-hand-section>.ornate-title{
  height:30px!important;
  min-height:30px!important;
  flex-basis:30px!important;
}

.buff-provider-badge{
  position:absolute!important;
  left:4px!important;
  right:auto!important;
  bottom:24px!important;
  top:auto!important;
  z-index:12!important;
  display:flex!important;
  flex-direction:column!important;
  align-items:flex-start!important;
  gap:1px!important;
  min-width:70px!important;
  padding:4px 6px!important;
  border:1px solid #7ff2dc!important;
  border-radius:4px!important;
  background:linear-gradient(180deg,#0a5c52f2,#06362ff2)!important;
  color:#e8fffa!important;
  box-shadow:0 0 0 1px #001c18,0 0 12px #58e2d077!important;
  text-shadow:0 1px 3px #000!important;
}
.buff-provider-badge b{font-size:10px!important;line-height:1.05!important;color:#ffffff!important;}
.buff-provider-badge small{font-size:8px!important;line-height:1.05!important;color:#bfffee!important;white-space:nowrap!important;}
.hand-buff-provider-badge{
  position:absolute!important;
  left:4px!important;
  top:4px!important;
  z-index:14!important;
  display:flex!important;
  flex-direction:column!important;
  gap:1px!important;
  padding:3px 5px!important;
  border:1px solid #83f3de!important;
  border-radius:4px!important;
  background:linear-gradient(180deg,#0b655af2,#063a33f2)!important;
  color:#effffb!important;
  box-shadow:0 0 10px #58e2d066!important;
  text-shadow:0 1px 3px #000!important;
}
.hand-buff-provider-badge b{font-size:9px!important;line-height:1!important;}
.hand-buff-provider-badge small{font-size:7px!important;line-height:1!important;color:#c5fff2!important;white-space:nowrap!important;}

.active-buff-badge{
  display:flex!important;
  flex-direction:column!important;
  align-items:flex-start!important;
  gap:1px!important;
  max-width:calc(100% - 8px)!important;
  padding:3px 5px!important;
  border:1px solid #ffe08a!important;
  border-radius:4px!important;
  background:linear-gradient(180deg,#7c5b13f2,#3f2b06f2)!important;
  color:#fff8d8!important;
  box-shadow:0 0 10px #ffd45d66!important;
  text-shadow:0 1px 3px #000!important;
}
.active-buff-badge.negative{
  border-color:#ff948d!important;
  background:linear-gradient(180deg,#742a26f2,#3b1210f2)!important;
  color:#ffe5e2!important;
  box-shadow:0 0 10px #ff706655!important;
}
.active-buff-badge b{font-size:9px!important;line-height:1!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;max-width:100%!important;}
.active-buff-badge small{font-size:7px!important;line-height:1!important;white-space:nowrap!important;}
.popup.buff-popup .popup-body,
.buff-popup .popup-body{font-size:14px!important;line-height:1.55!important;}

@media (max-width:850px){
  .ally-hq-turn{
    right:8px!important;
    top:calc(50% + 58px)!important;
    bottom:6px!important;
    width:86px!important;
    min-height:30px!important;
    font-size:13px!important;
  }
  .ally-hq-turn span{font-size:13px!important;}
  .ally-hq-turn b{font-size:19px!important;}
  .reference-right .right-deck-section{
    flex-basis:100px!important;
    height:100px!important;
    min-height:100px!important;
    max-height:100px!important;
  }
  .reference-right .right-deck-body{
    flex-basis:70px!important;
    height:70px!important;
    min-height:70px!important;
    max-height:70px!important;
  }
}

.hand-buff-provider-badge{
  left:50%!important;
  right:auto!important;
  top:auto!important;
  bottom:5px!important;
  transform:translateX(-50%)!important;
  align-items:center!important;
  min-width:82px!important;
  padding:4px 7px!important;
  text-align:center!important;
}
.hand-buff-provider-badge b{font-size:11px!important;line-height:1.05!important;}
.hand-buff-provider-badge small{font-size:8px!important;line-height:1.05!important;}
.buff-provider-badge{
  left:50%!important;
  right:auto!important;
  top:auto!important;
  bottom:4px!important;
  transform:translateX(-50%)!important;
  align-items:center!important;
  min-width:82px!important;
  text-align:center!important;
}
.buff-provider-badge b{font-size:11px!important;}
.buff-provider-badge small{font-size:8px!important;}
.unit .active-buff-badge{
  position:absolute!important;
  left:50%!important;
  right:auto!important;
  top:auto!important;
  bottom:4px!important;
  transform:translateX(-50%)!important;
  z-index:14!important;
  align-items:center!important;
  min-width:82px!important;
  max-width:calc(100% - 8px)!important;
  text-align:center!important;
}
.unit .active-buff-badge b{font-size:10px!important;}
.unit .active-buff-badge small{font-size:8px!important;}
.unit .active-buff-badge + .buff-provider-badge{bottom:34px!important;}

.hand-title-bar{padding:0 6px!important;}
.hand-title-paged{
  width:100%!important;
  display:grid!important;
  grid-template-columns:28px 1fr auto 28px!important;
  align-items:center!important;
  gap:5px!important;
}
.hand-title-label{text-align:center!important;font-size:13px!important;font-weight:900!important;}
.hand-title-page{font-size:10px!important;color:#ffe0a6!important;white-space:nowrap!important;}
.hand-title-arrow{
  width:26px!important;height:24px!important;min-height:24px!important;padding:0!important;
  border:1px solid #8d6738!important;background:#15100b!important;color:#ffe0a6!important;
  font-size:20px!important;line-height:20px!important;font-weight:950!important;cursor:pointer!important;
}
.hand-title-arrow:disabled{opacity:.3!important;cursor:default!important;}
.hand-title-arrow[hidden],.hand-title-page[hidden]{display:block!important;visibility:hidden!important;}

.lane .lane-synergy-tag{
  position:absolute!important;
  left:50%!important;
  top:5px!important;
  transform:translateX(-50%)!important;
  z-index:9!important;
  max-width:70%!important;
  padding:3px 8px!important;
  border:1px solid #76e9d5!important;
  border-radius:999px!important;
  background:linear-gradient(180deg,#0c5e55ef,#07352fef)!important;
  color:#eafffb!important;
  box-shadow:0 0 12px #61e1cf66!important;
  font-size:9px!important;
  line-height:1.1!important;
  font-weight:950!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  pointer-events:none!important;
}
.lane.synergy-active{box-shadow:inset 0 0 0 1px #65dbc866,0 0 14px #48cbb52c!important;}

.deck-auto-ratio{
  display:grid!important;
  grid-template-columns:auto repeat(4,minmax(105px,1fr)) auto!important;
  align-items:center!important;
  gap:7px!important;
  margin:8px 0!important;
  padding:8px 10px!important;
  border:1px solid #66502f!important;
  background:#0b0f12!important;
  font-size:11px!important;
}
.deck-auto-ratio>b{color:#f0cf91!important;white-space:nowrap!important;}
.deck-auto-ratio label{display:flex!important;align-items:center!important;justify-content:center!important;gap:4px!important;white-space:nowrap!important;}
.deck-auto-ratio input{width:48px!important;height:28px!important;padding:2px 4px!important;text-align:center!important;}
.deck-auto-ratio>span{color:#b8aa91!important;font-size:10px!important;white-space:nowrap!important;}
@media(max-width:850px){
  .deck-auto-ratio{grid-template-columns:repeat(2,1fr)!important;}
  .deck-auto-ratio>b,.deck-auto-ratio>span{grid-column:1/-1!important;text-align:center!important;}
}

.unit.fog-hidden{border-color:#46505c!important;box-shadow:0 3px 12px #000d,inset 0 0 22px #000!important;filter:saturate(.2)!important;}
.unit.fog-hidden .fog-uimg{background:#090d12!important;}
.enemy-shadow-art{display:block;width:100%;height:100%;object-fit:cover;filter:brightness(.8) contrast(1.15);}
.unit.fog-hidden .field-unit-name{color:#c1c8cf!important;letter-spacing:.04em;}
.unit.fog-hidden .stats span{color:#aab3bc!important;background:#10151a!important;}
.slot.trap-known{box-shadow:inset 0 0 0 2px #d88d42aa,0 0 14px #ff9c3f33!important;}
.trap-marker{position:absolute;left:5px;top:5px;z-index:28;padding:2px 6px;border:1px solid #ffbd73;border-radius:999px;background:#32180de8;color:#ffe3b8;font-size:8px;font-weight:950;pointer-events:none;box-shadow:0 0 10px #ff933f66;}
.slot.temporary-slot{border:2px dashed #66e5d5!important;background:repeating-linear-gradient(135deg,#0d3b3744 0 8px,#07191544 8px 16px)!important;box-shadow:inset 0 0 15px #5ee6d33b!important;}
.slot.temporary-slot::after{content:'임시 전투칸';position:absolute;right:4px;bottom:4px;z-index:5;padding:2px 4px;background:#062c28df;border:1px solid #62dbc9;color:#dffffa;font-size:7px;font-weight:900;pointer-events:none;}
.chain-overlay{position:absolute;inset:12% 3% 18%;z-index:32;display:grid;place-items:center;font-size:46px;line-height:1;color:#d4d8de;text-shadow:0 2px 8px #000,0 0 15px #a7b2c2;transform:rotate(-12deg);pointer-events:none;opacity:.95;}
.unit.chain-locked{position:relative;overflow:hidden;filter:grayscale(.44) brightness(.74)!important;box-shadow:inset 0 0 0 2px #a3acb8,inset 0 0 18px #e8edf633,0 0 16px #8690a077!important;}
.unit.chain-locked::before,.unit.chain-locked::after{content:'';position:absolute;inset:-10% -18%;z-index:31;pointer-events:none;opacity:.9;background-repeat:no-repeat;}
.unit.chain-locked::before{transform:rotate(-10deg);background:
  repeating-linear-gradient(135deg,transparent 0 13%,rgba(225,231,238,.0) 13% 14.5%,rgba(220,226,233,.92) 14.5% 17.5%,rgba(118,126,139,.96) 17.5% 20%,rgba(220,226,233,.92) 20% 23%,rgba(0,0,0,0) 23% 32%),
  linear-gradient(135deg,transparent 0 8%,rgba(255,255,255,.16) 8% 9%,transparent 9% 100%);}
.unit.chain-locked::after{transform:rotate(8deg);background:
  repeating-linear-gradient(45deg,transparent 0 15%,rgba(232,236,241,.0) 15% 16%,rgba(220,226,233,.9) 16% 19%,rgba(116,124,138,.95) 19% 21.5%,rgba(220,226,233,.9) 21.5% 24%,rgba(0,0,0,0) 24% 34%),
  linear-gradient(45deg,transparent 0 12%,rgba(255,255,255,.14) 12% 13%,transparent 13% 100%);}
.unit.chain-locked .uimg::before{content:'';position:absolute;inset:0;z-index:30;pointer-events:none;background:radial-gradient(circle at 50% 50%,rgba(255,255,255,.10),rgba(0,0,0,.16) 68%,rgba(0,0,0,.28));}
.unit.chain-locked .field-unit-name,.unit.chain-locked .field-grade,.unit.chain-locked .stats span{position:relative;z-index:33!important;}
.unit-scout-badge{position:absolute;right:4px;top:26px;z-index:20;padding:2px 5px;border:1px solid #7edcff;border-radius:999px;background:#083248e8;color:#dcf8ff;font-size:8px;font-weight:950;box-shadow:0 0 9px #55c8ff66;}

.unit-buff-box,.unit-skill-box{
  position:absolute;
  top:3px;
  z-index:20;
  padding:1px 4px;
  border-radius:3px;
  font-size:7px;
  font-weight:950;
  line-height:1.5;
  white-space:nowrap;
  pointer-events:none;
  text-shadow:0 1px 2px #000;
  box-shadow:0 1px 4px #0008;
}
.unit-buff-box{left:3px;border:1px solid #7ff2dc;background:#073f3bd9;color:#ccfff6;}
.unit-skill-box{right:3px;border:1px solid #b79bff;background:#241a45d9;color:#ecdfff;}
.battlefield-layout .unit-scout-badge{top:18px!important;}
@media (max-width:850px){
  .unit-buff-box,.unit-skill-box{font-size:6px;padding:1px 3px;}
}
.fx-tactic.trap{background:radial-gradient(circle,#ffe5bacc 0 12%,#b95d2588 38%,transparent 72%);box-shadow:0 0 30px #ff843d;}
.fx-tactic.battleprep{background:radial-gradient(circle,#d6fff5cc 0 12%,#2ca58b88 38%,transparent 72%);box-shadow:0 0 30px #58e4c8;}
.fx-tactic.wind{background:radial-gradient(circle,#f5fbffcc 0 10%,#72c8e388 36%,transparent 74%);box-shadow:0 0 34px #8de6ff;animation:fxWindBurst 1.05s ease-out forwards;}
@keyframes fxWindBurst{0%{opacity:0;transform:translate(-70%,-50%) scale(.4) rotate(-35deg)}25%{opacity:1;transform:translate(-50%,-50%) scale(1.15) rotate(10deg)}70%{opacity:1;transform:translate(-25%,-50%) scale(1) rotate(35deg)}100%{opacity:0;transform:translate(10%,-50%) scale(1.5) rotate(80deg)}}

.battlefield-layout .slots.n5{width:100%!important;max-width:none!important;grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:5px!important;}
.battlefield-layout .slots.n6{width:100%!important;max-width:none!important;grid-template-columns:repeat(6,minmax(0,1fr))!important;gap:4px!important;}
@media(max-width:850px){.battlefield-layout .slots.n5,.battlefield-layout .slots.n6{width:max-content!important;grid-template-columns:repeat(5,82px)!important;}.battlefield-layout .slots.n6{grid-template-columns:repeat(6,76px)!important;}}

.battle-hq,.hq{isolation:isolate;}
.battle-hq.low-energy::after,.hq.low-energy::after{content:'';position:absolute;inset:0;z-index:65;pointer-events:none;background:rgba(175,28,28,.16);box-shadow:inset 0 0 34px rgba(255,72,72,.28);animation:hqLowEnergyPulse 1.25s ease-in-out infinite alternate;}
@keyframes hqLowEnergyPulse{from{opacity:.48}to{opacity:.9}}

.hand-buff-provider-badge{left:6px!important;right:auto!important;top:28px!important;bottom:auto!important;transform:none!important;min-width:74px!important;max-width:calc(100% - 12px)!important;padding:3px 6px!important;z-index:24!important;}

.event-image-layout{display:grid;grid-template-columns:1fr;gap:5px;margin:7px 0 2px;padding:7px;border:1px solid #34475d;background:#090f18;}
.event-image-layout label{display:grid;grid-template-columns:62px 1fr;align-items:center;gap:6px;font-size:9px;color:#c9d7e7;}
.event-image-layout input[type=range]{width:100%;}
.event-image-layout output{font-size:9px;color:#f0d6a3;text-align:center;}
.event-image-preview img{transform:scale(var(--scene-preview-scale,1));transform-origin:center;}

:root{--battle-control-height:42px;}
.reference-right .right-deck-body .deck-info,.reference-right .right-deck-body #shuffleBtn,.reference-right .right-deck-body #endTurnBtn,.formation-inline select,.formation-inline .formation-start-btn,.formation-inline .formation-deck-btn,.left-menu-dock button{height:var(--battle-control-height)!important;min-height:var(--battle-control-height)!important;max-height:var(--battle-control-height)!important;box-sizing:border-box!important;}
.reference-right .right-deck-body{min-height:calc(var(--battle-control-height) + 12px)!important;}

#hand.hand .card.instant-tactic-card{cursor:grab;}
#hand.hand .card.instant-tactic-card:active{cursor:grabbing;}
#hand.hand .card.instant-tactic-card.dragging-tactic{opacity:.48;transform:scale(.96);}
.battlefield-layout>.board.tactic-drop-ready{
  position:relative;
  outline:3px solid #c79cff!important;
  outline-offset:-4px;
  box-shadow:inset 0 0 34px #8e5eff55,0 0 20px #8e5eff55!important;
}
.battlefield-layout>.board.tactic-drop-ready::after{
  content:'스킬카드를 놓아 즉시 발동';
  position:absolute;
  inset:10px;
  z-index:90;
  display:grid;
  place-items:center;
  border:2px dashed #e1cfff;
  background:#25153dcc;
  color:#f5edff;
  font-size:18px;
  font-weight:950;
  letter-spacing:.04em;
  text-shadow:0 2px 6px #000;
  pointer-events:none;
}

.batch-image-preset-grid{grid-template-columns:1fr!important;gap:6px!important;}
.batch-image-preset-slot{
  display:grid!important;
  grid-template-columns:160px minmax(220px,1fr) 138px!important;
  gap:8px!important;
  align-items:center!important;
  padding:8px 10px!important;
}
.batch-image-preset-head{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:6px!important;}
.batch-image-preset-head b{white-space:nowrap!important;}
.batch-image-preset-fields{grid-template-columns:repeat(3,minmax(72px,1fr))!important;gap:8px!important;align-items:end!important;}
.batch-image-preset-fields label{gap:3px!important;}
.batch-image-preset-slot>.btn{width:100%!important;}
.batch-image-type-select{justify-content:flex-start!important;}

.event-image-manager{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:10px!important;
  margin-top:8px!important;
  padding:10px!important;
  border:1px solid #5f472d!important;
  background:#0a0d0f!important;
  align-items:start!important;
}
.event-image-manager>.image-adjust-title,
.event-image-manager>.event-image-note{grid-column:1/-1!important;}
.event-image-setting{display:grid!important;gap:6px!important;min-width:0!important;padding:8px!important;border:1px solid #6b4f31!important;background:linear-gradient(180deg,#12100d,#0a0c0e)!important;}
.event-image-head{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:6px!important;flex-wrap:wrap!important;}
.event-image-head span{font-size:9px!important;color:#cdb999!important;}
.event-image-preview{height:132px!important;}

.hq-image-manager{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:10px!important;
  margin-top:8px!important;
  padding:10px!important;
  border:1px solid #5f472d!important;
  background:#0a0d0f!important;
  align-items:start!important;
}
.hq-image-manager>.image-adjust-title{grid-column:1/-1!important;}
.hq-image-setting{padding:8px!important;border:1px solid #6b4f31!important;background:linear-gradient(180deg,#12100d,#0a0c0e)!important;}
.hq-image-preview{height:88px!important;}

@media(max-width:1200px){
  .batch-image-preset-slot{grid-template-columns:1fr!important;}
  .batch-image-preset-head,.batch-image-preset-fields{width:100%!important;}
}
@media(max-width:1050px){
  .event-image-manager,.hq-image-manager{grid-template-columns:1fr!important;}
}

.manager-head-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap;}
.manager-head-actions .btn{min-width:92px;}
.other-image-box{width:min(92vw,760px)!important;max-width:760px!important;padding:14px!important;}
.other-image-head{display:flex;align-items:flex-start;justify-content:space-between;gap:10px;margin-bottom:12px;}
.other-image-head h2{margin:0;}
.other-image-head .small{margin-top:4px;}
#otherImageModal .default-card-image-manager{display:grid!important;gap:8px!important;padding:10px!important;border:1px solid #536176!important;background:#0b1118!important;}
#otherImageModal .default-image-preview{height:180px!important;}

.batch-image-preset-panel{gap:8px!important;}
.batch-image-preset-grid{grid-template-columns:1fr!important;gap:6px!important;}
.batch-image-preset-slot{grid-template-columns:118px minmax(240px,1fr) 132px!important;gap:6px!important;padding:7px 9px!important;align-items:center!important;}
.batch-image-preset-head{gap:6px!important;}
.batch-image-preset-head .btn,.batch-image-preset-slot>.btn{min-height:24px!important;font-size:9px!important;}
.batch-image-preset-fields{grid-template-columns:repeat(3,minmax(68px,1fr))!important;gap:6px!important;}
.batch-image-preset-fields label{font-size:9px!important;}
.batch-image-preset-fields input{padding:3px 5px!important;}
.batch-image-preset-note{font-size:9px!important;}

.event-image-manager{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:10px!important;align-items:start!important;}
.event-image-manager>.image-adjust-title,.event-image-manager>.event-image-note{grid-column:1/-1!important;}
.event-image-setting{display:grid!important;gap:6px!important;}
.event-image-preview{height:126px!important;}
.hq-image-manager{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:10px!important;align-items:start!important;}
.hq-image-manager>.image-adjust-title{grid-column:1/-1!important;}
.hq-image-preview{height:88px!important;}

@media(max-width:1200px){.batch-image-preset-slot{grid-template-columns:1fr!important;}}
@media(max-width:1050px){.event-image-manager,.hq-image-manager{grid-template-columns:1fr!important;}}
@media(max-width:760px){.other-image-head{flex-direction:column;align-items:stretch;}.manager-head-actions{width:100%;justify-content:flex-end;}}

.manager-inline-image-zone{display:grid;gap:10px;margin-top:10px;min-width:0;}
.manager-inline-image-zone .batch-image-preset-panel,
.manager-inline-image-zone .event-image-manager,
.manager-inline-image-zone .hq-image-manager{margin-top:0!important;}
.manager-inline-image-zone .batch-image-preset-panel{order:1;}
.manager-inline-image-zone .event-image-manager{order:2;}
.manager-inline-image-zone .hq-image-manager{order:3;}
.manager-preview-wrap{align-self:start;}
.manager-grid>div:last-child{min-width:0;}
@media(max-width:1050px){.manager-inline-image-zone{margin-top:8px;}}

.manager-inline-image-zone .batch-image-preset-panel{display:grid;gap:6px!important;padding:8px 10px!important;}
.manager-inline-image-zone .batch-image-preset-panel .image-adjust-title{font-size:12px!important;margin-bottom:2px!important;}
.manager-inline-image-zone .batch-image-preset-grid.compact{display:grid!important;grid-template-columns:1fr!important;gap:6px!important;}
.manager-inline-image-zone .batch-image-preset-row{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:wrap!important;padding:6px 8px!important;border:1px solid #6c4d2b;background:linear-gradient(180deg,#12100d,#0a0c0e)!important;}
.manager-inline-image-zone .batch-image-preset-row-label{font-size:11px;font-weight:900;color:#efcf95;min-width:42px;}
.manager-inline-image-zone .batch-check{display:inline-flex;align-items:center;gap:4px;font-size:10px;color:#e0d3bf;white-space:nowrap;}
.manager-inline-image-zone .batch-check input{accent-color:#c69b55;}
.manager-inline-image-zone .batch-mini-field{display:inline-flex;align-items:center;gap:4px;font-size:10px;color:#d5c7b2;white-space:nowrap;}
.manager-inline-image-zone .batch-mini-field input{width:54px!important;min-width:54px!important;max-width:54px!important;padding:3px 4px!important;text-align:center!important;background:#0b0d0f;border:1px solid #745734;color:#f4e1b8;}
.manager-inline-image-zone .batch-image-preset-row .btn{min-height:24px!important;font-size:9px!important;padding:4px 8px!important;white-space:nowrap;}
@media(max-width:1200px){.manager-inline-image-zone .batch-image-preset-row{gap:6px!important;}}

.other-image-box{width:min(94vw,1080px)!important;max-width:1080px!important;max-height:92vh;overflow:auto;}
.other-image-content{display:grid;gap:14px;min-width:0;}
.other-image-content .hq-image-manager{margin-top:0!important;}
.batch-settings-box{width:min(96vw,1240px)!important;max-width:1240px!important;max-height:94vh;overflow:auto;padding:14px!important;}
.batch-settings-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;padding-bottom:10px;border-bottom:1px solid #5f472d;}
.batch-settings-head h2{margin:0 0 4px;}
.batch-current-card{margin:10px 0;padding:8px 10px;border:1px solid #7a5a34;background:linear-gradient(180deg,#18130d,#0d0f11);color:#f1d49b;font-size:12px;font-weight:800;}
.batch-current-card.empty{color:#b7aa95;}
.batch-settings-content{display:grid;gap:14px;}
.batch-settings-section{display:grid;gap:10px;padding:10px;border:1px solid #4f4131;background:#080a0c;min-width:0;}
.batch-section-head>div{display:flex;align-items:baseline;gap:10px;flex-wrap:wrap;}
.batch-section-head b{font-size:14px;color:#f1d49b;}
.batch-section-head span{font-size:10px;color:#b6aa97;}
.batch-settings-section .batch-image-preset-panel{margin:0!important;}
.batch-settings-section .batch-image-preset-grid.compact{display:grid!important;grid-template-columns:1fr!important;gap:7px!important;}
.batch-settings-section .batch-image-preset-row{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:wrap!important;padding:7px 8px!important;border:1px solid #6c4d2b;background:linear-gradient(180deg,#12100d,#0a0c0e)!important;}
.batch-settings-section .batch-image-preset-row-label{font-size:11px;font-weight:900;color:#efcf95;min-width:42px;}
.batch-settings-section .batch-check{display:inline-flex;align-items:center;gap:4px;font-size:10px;color:#e0d3bf;white-space:nowrap;}
.batch-settings-section .batch-check input{accent-color:#c69b55;}
.batch-settings-section .batch-mini-field{display:inline-flex;align-items:center;gap:4px;font-size:10px;color:#d5c7b2;white-space:nowrap;}
.batch-settings-section .batch-mini-field input{width:58px!important;min-width:58px!important;max-width:58px!important;padding:4px!important;text-align:center!important;background:#0b0d0f;border:1px solid #745734;color:#f4e1b8;}
.batch-settings-section .event-image-manager{margin:0!important;}
.batch-scene-actions{display:flex;justify-content:flex-end;padding-top:2px;}
@media(max-width:760px){
  .batch-settings-head{flex-direction:column;align-items:stretch;}
  .batch-settings-head>.btn{align-self:flex-end;}
  .batch-settings-section{padding:8px;}
}

#otherImageModal,#batchSettingsModal{z-index:90!important;}
#otherImageModal.show,#batchSettingsModal.show{display:flex!important;pointer-events:auto!important;}
#otherImageModal .modalbox,#batchSettingsModal .modalbox{position:relative;z-index:1;}
#openOtherImagesBtn,#openBatchSettingsBtn{position:relative;z-index:2;pointer-events:auto!important;cursor:pointer;}

.scene-stage-preview-panel{display:grid;gap:8px;padding:10px;border:1px solid #5f472d;background:linear-gradient(180deg,#12100d,#0a0c0e);margin-bottom:10px;}
.scene-stage-preview-wrap{display:flex;justify-content:center;align-items:center;padding:4px 0 8px;}
.scene-stage-preview.hq{width:var(--stage-hq-width,320px)!important;max-width:100%;height:var(--stage-hq-height,170px)!important;min-height:var(--stage-hq-height,170px)!important;position:relative;overflow:hidden;}
.scene-stage-preview .hq-unit-slot{display:flex!important;right:10px;bottom:8px;width:140px;height:42px;z-index:6;color:#d4dbeb;font-size:10px;}
.scene-stage-preview .hq-unit-slot span{padding:0 6px;text-align:center;}
.scene-stage-preview .hq-title{z-index:6;}
.scene-stage-preview .hq-subtitle{z-index:6;}
.event-image-preview-actions{display:flex;gap:6px;flex-wrap:wrap;margin:-1px 0 6px;}
.event-image-preview-actions .btn{flex:1 1 120px;min-height:28px!important;font-size:10px!important;padding:5px 8px!important;}
.hq-card-scene.preview-static .scene-energy,.hq-card-scene.preview-static::before,.hq-card-scene.preview-static::after{opacity:.2!important;animation:none!important;}
.hq-card-scene.preview-static img{animation:none!important;transform:scale(var(--scene-scale,1))!important;opacity:1!important;filter:saturate(1.05) contrast(1.03)!important;}
@media(max-width:760px){.scene-stage-preview.hq{max-width:100%;}.event-image-preview-actions .btn{flex:1 1 100%;}}

.scene-stage-preview .hq-card-scene{inset:0!important;}
.scene-stage-preview .hq-card-scene img{object-position:var(--scene-x,50%) var(--scene-y,50%)!important;transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;}

.batch-scene-preset-actions{display:flex;align-items:center;justify-content:flex-end;gap:6px;flex-wrap:wrap;padding-top:4px;border-top:1px solid #3f3121;}
.batch-scene-preset-actions>span{margin-right:auto;font-size:10px;color:#cdbb9e;}
.batch-scene-preset-actions .btn{min-height:28px!important;font-size:10px!important;padding:5px 9px!important;}
@media(max-width:760px){.batch-scene-preset-actions>span{flex:1 1 100%;}.batch-scene-preset-actions .btn{flex:1 1 30%;}}

.hq-battlefield-grid{display:grid!important;grid-template-columns:repeat(5,minmax(54px,1fr));gap:6px;width:min(100%,620px)!important;min-height:100px!important;padding:8px!important;background:rgba(10,15,22,.82);border:1px solid rgba(223,183,102,.55);border-radius:12px;overflow:visible!important}
.hq-battlefield-grid.inactive{opacity:.28;pointer-events:none}.hq-battlefield-grid.active{opacity:1;box-shadow:0 0 22px rgba(255,177,54,.24)}
.hq-field-slot{position:relative;min-height:88px;border:1px dashed rgba(238,203,126,.42);border-radius:8px;display:flex;align-items:stretch;justify-content:center;background:rgba(255,255,255,.035);overflow:hidden}.hq-field-slot.empty>span{margin:auto;font-weight:900;color:#bda66f}.hq-field-slot.empty:hover{background:rgba(255,190,75,.14);border-color:#ffd16e}.hq-field-slot .base-unit{width:100%;height:100%;padding:3px;display:grid;grid-template-rows:1fr auto;cursor:pointer}.hq-field-slot .base-unit-art{min-height:58px}.hq-field-slot .base-unit-mini{font-size:9px;line-height:1.2;display:grid;gap:2px;background:rgba(0,0,0,.62);padding:3px}.hq-field-slot .base-unit-mini span{white-space:nowrap;font-size:8px}.hq.emergency .hq-battlefield-grid{animation:hqFieldPulse 1.1s ease-out 1}@keyframes hqFieldPulse{0%{transform:scale(.94);filter:brightness(1.7)}100%{transform:scale(1);filter:brightness(1)}}

.slot.temporary-slot{background:linear-gradient(145deg,rgba(44,120,164,.55),rgba(33,71,113,.72))!important;border:2px solid #78d9ff!important;box-shadow:inset 0 0 14px rgba(105,217,255,.25),0 0 10px rgba(105,217,255,.22)!important}.slot.temporary-slot::after{content:'전투준비';position:absolute;right:3px;bottom:2px;font-size:8px;font-weight:900;color:#bfeeff;background:rgba(0,24,43,.72);padding:1px 4px;border-radius:4px}

.deck-builder-toolbar{flex-wrap:wrap}.deck-builder-list{grid-template-columns:repeat(auto-fill,minmax(190px,1fr))!important;align-content:start}.deck-builder-visual-card{min-height:330px!important;padding:8px!important;display:grid!important;grid-template-rows:auto 178px auto auto auto!important;gap:6px;background:linear-gradient(180deg,rgba(24,28,35,.98),rgba(9,12,17,.98));border-radius:10px}.deck-builder-visual-card .collection-card-art{height:178px!important}.collection-five-stats{display:block;text-align:center;font-size:13px;font-weight:900;letter-spacing:.04em;padding:5px;border-radius:6px;background:rgba(231,197,124,.1);color:#ffe0a0}.collection-extra{display:block;min-height:34px;font-size:10px;line-height:1.35;color:#d8d0c1;overflow:hidden}.deck-card-controls{display:flex;align-items:center;gap:5px;flex-wrap:wrap}.deck-card-controls button{border:1px solid #755f39;background:#1b2027;color:#f5deb0;border-radius:6px;padding:5px 7px;font-size:10px;cursor:pointer}.deck-card-controls button:disabled{opacity:.35;cursor:not-allowed}.deck-add-card{margin-left:auto!important;background:#6f4a13!important}.deck-builder-owned button{width:24px;height:24px;padding:0}.deck-builder-owned em{width:28px!important;height:24px!important}.deck-builder-list.selected .deck-builder-visual-card{min-height:310px!important}
.card-image-zoom-box{width:min(820px,96vw)!important}.card-image-zoom-scroll{max-height:82vh;overflow:auto}.card-image-zoom-visual{max-width:none!important}.card-zoom-layout{display:grid;grid-template-columns:minmax(250px,42%) 1fr;gap:22px;padding:16px}.card-zoom-art{min-height:430px;border-radius:12px;overflow:hidden;background:#0d1118}.card-zoom-art img,.card-zoom-art .card-art-img{width:100%;height:100%;object-fit:cover}.card-zoom-info{display:flex;flex-direction:column;gap:12px;color:#efe7d6}.card-zoom-info h3{font-size:26px;margin:0}.card-zoom-info h3 em{font-style:normal;font-size:16px}.card-zoom-info p{margin:0;color:#cdbf9e}.card-zoom-stats{font-size:19px;font-weight:900;letter-spacing:.06em;padding:12px;background:rgba(230,188,96,.12);border:1px solid rgba(230,188,96,.28);border-radius:9px}.card-zoom-skill{display:grid;gap:7px;padding:13px;background:rgba(79,116,165,.13);border-radius:9px}.card-zoom-skill span,.card-zoom-description{font-size:14px;line-height:1.6}.zoomable-card-name.cimg,.zoomable-card-name.uimg,.zoomable-card-name.base-unit-art{cursor:zoom-in}
@media(max-width:760px){.hq-battlefield-grid{grid-template-columns:repeat(5,minmax(42px,1fr));gap:3px;padding:4px!important}.hq-field-slot{min-height:72px}.card-zoom-layout{grid-template-columns:1fr}.card-zoom-art{min-height:340px}.deck-builder-list{grid-template-columns:repeat(2,minmax(145px,1fr))!important}.deck-builder-visual-card{min-height:300px!important;grid-template-rows:auto 145px auto auto auto!important}.deck-builder-visual-card .collection-card-art{height:145px!important}}

.deck-builder-box{width:min(1260px,98vw)!important;}
.deck-builder-toolbar{
  display:grid!important;
  grid-template-columns:92px 98px 94px 78px 88px minmax(150px,1fr) 88px 116px!important;
  gap:6px!important;
  align-items:end!important;
  flex-wrap:nowrap!important;
}
.deck-builder-toolbar>*{min-width:0!important;}
.deck-builder-toolbar label{min-width:0!important;}
.deck-builder-toolbar select,.deck-builder-toolbar input{width:100%!important;min-width:0!important;padding-left:6px!important;padding-right:6px!important;}
.deck-builder-count,.deck-builder-score{
  min-width:0!important;
  height:32px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:4px!important;
  padding:0 5px!important;
  white-space:nowrap!important;
}
.deck-builder-count>span,.deck-builder-score>span{font-size:9px;font-weight:800;color:#cdbb9e;}
.deck-builder-count b,.deck-builder-score b{margin:0!important;font-size:18px!important;line-height:1!important;}
.deck-builder-count small,.deck-builder-score small{font-size:10px;color:#b9c1ca;}
.deck-builder-main{grid-template-columns:minmax(0,1.35fr) minmax(0,.85fr)!important;}
.deck-builder-list{
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-auto-rows:max-content!important;
  align-items:start!important;
  align-content:start!important;
  gap:8px!important;
  padding:8px!important;
}
.deck-builder-list.selected{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
.deck-builder-visual-card{
  width:100%!important;
  height:auto!important;
  min-height:310px!important;
  max-height:none!important;
  align-self:start!important;
  box-sizing:border-box!important;
  grid-template-rows:auto 154px auto minmax(34px,auto) auto auto!important;
  overflow:hidden!important;
  cursor:pointer!important;
}
.deck-builder-visual-card .collection-card-art{height:154px!important;min-height:154px!important;}
.deck-builder-visual-card .collection-five-stats{font-size:12px!important;padding:5px 3px!important;}
.deck-builder-visual-card .collection-extra{min-height:34px!important;max-height:44px!important;line-height:1.35!important;}
.deck-builder-visual-card .collection-card-foot{min-height:36px!important;padding:4px 5px!important;align-items:center!important;}
.deck-builder-visual-card .collection-card-foot small{white-space:normal!important;line-height:1.25!important;font-size:8px!important;}
.deck-builder-visual-card.selected:hover{border-color:#d6a55f!important;background:#21170e!important;}
.deck-card-controls{margin-top:auto!important;}

.card-shop-grid{
  grid-template-columns:repeat(auto-fill,minmax(160px,1fr))!important;
  grid-auto-rows:auto!important;
  align-items:start!important;
  gap:10px!important;
}
.card-shop-grid .shop-card{
  width:100%!important;
  height:270px!important;
  min-width:0!important;
  min-height:270px!important;
  max-width:none!important;
  max-height:none!important;
  grid-template-rows:46px minmax(0,1fr) 31px 36px!important;
  box-sizing:border-box!important;
}
.card-shop-grid .shop-card-title{min-height:46px!important;padding:4px 5px!important;}
.shop-card-heading{min-width:0;display:flex;align-items:baseline;gap:5px;flex-wrap:wrap;line-height:1.1;}
.shop-card-heading b{flex:0 1 auto;max-width:100%;font-size:11px!important;}
.shop-card-heading small{min-width:0;font-size:7px;color:#ceb98f;white-space:normal;line-height:1.25;}
.card-shop-grid .shop-card-title>em{align-self:start;}
.card-shop-grid .collection-card-art{height:auto!important;min-height:0!important;}
.card-shop-grid .collection-five-stats{font-size:12px!important;padding:5px 3px!important;}
.card-shop-grid .collection-extra{min-height:36px!important;max-height:36px!important;padding:4px 5px!important;font-size:9px!important;line-height:1.35!important;}
.card-shop-grid .collection-card-foot{display:none!important;}

@media(max-width:1050px){
  .deck-builder-toolbar{grid-template-columns:86px 90px 86px 72px 82px minmax(130px,1fr) 82px 106px!important;gap:4px!important;}
  .deck-builder-toolbar select,.deck-builder-toolbar input{font-size:10px!important;}
  .deck-builder-list.selected{grid-template-columns:1fr!important;}
}
@media(max-width:850px){
  .deck-builder-toolbar{grid-template-columns:repeat(4,minmax(0,1fr))!important;}
  .deck-builder-main{grid-template-columns:1fr!important;}
  .deck-builder-list{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
  .deck-builder-list.selected{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
  .deck-builder-visual-card{min-height:290px!important;grid-template-rows:auto 138px auto minmax(34px,auto) auto auto!important;}
  .deck-builder-visual-card .collection-card-art{height:138px!important;min-height:138px!important;}
  .card-shop-grid{grid-template-columns:repeat(2,minmax(130px,1fr))!important;}
}

.deck-builder-visual-card{grid-template-rows:auto 154px auto auto auto auto!important;}
.deck-builder-visual-card>.collection-card-title{grid-row:1;}
.deck-builder-visual-card>.collection-card-art{grid-row:2;}
.deck-builder-visual-card>.collection-five-stats{grid-row:3;}
.deck-builder-visual-card>.collection-extra{grid-row:4;}
.deck-builder-visual-card>.collection-card-foot{grid-row:5;}
.deck-builder-visual-card>.deck-card-controls{grid-row:6;}
.card-shop-grid .shop-card{grid-template-rows:46px minmax(0,1fr) auto auto!important;}
.card-shop-grid .shop-card>.collection-card-title{grid-row:1;}
.card-shop-grid .shop-card>.collection-card-art{grid-row:2;}
.card-shop-grid .shop-card>.collection-five-stats{grid-row:3;min-height:31px;box-sizing:border-box;}
.card-shop-grid .shop-card>.collection-extra{grid-row:4;min-height:36px!important;box-sizing:border-box;}
@media(max-width:850px){
  .deck-builder-visual-card{grid-template-rows:auto 138px auto auto auto auto!important;}
}

.collection-card-title{
  min-height:50px!important;
  padding:5px 6px!important;
  align-items:start!important;
}
.collection-card-heading{
  min-width:0;
  display:flex;
  align-items:baseline;
  align-content:flex-start;
  column-gap:6px;
  row-gap:2px;
  flex-wrap:wrap;
  line-height:1.18;
}
.collection-card-heading .collection-card-name{
  flex:0 1 auto;
  max-width:100%;
  font-size:13px!important;
  line-height:1.2!important;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.collection-card-heading small{
  min-width:0;
  font-size:9px!important;
  font-weight:800;
  color:#d8c39b;
  white-space:normal;
  line-height:1.25;
}
.collection-card-name.zoomable-card-name{cursor:zoom-in;text-decoration:underline dotted rgba(255,225,166,.45);text-underline-offset:3px;}

.deck-builder-visual-card{
  min-height:326px!important;
  grid-template-rows:50px 160px auto minmax(48px,auto) auto!important;
}
.deck-builder-visual-card>.collection-card-title{grid-row:1!important;}
.deck-builder-visual-card>.collection-card-art{grid-row:2!important;height:160px!important;min-height:160px!important;}
.deck-builder-visual-card>.collection-five-stats{grid-row:3!important;}
.deck-builder-visual-card>.collection-extra{grid-row:4!important;}
.deck-builder-visual-card>.deck-card-controls{grid-row:5!important;}
.deck-builder-visual-card>.collection-card-foot{display:none!important;}
.deck-builder-visual-card .collection-five-stats{
  min-height:36px!important;
  display:flex!important;
  align-items:center;
  justify-content:center;
  padding:6px 5px!important;
  font-size:11px!important;
  line-height:1.35!important;
  white-space:normal!important;
}
.deck-builder-visual-card .collection-extra{
  min-height:48px!important;
  max-height:66px!important;
  padding:7px 7px!important;
  font-size:12px!important;
  font-weight:750!important;
  line-height:1.42!important;
  overflow:auto!important;
}
.deck-card-controls{min-height:30px!important;}
.deck-builder-list.selected .deck-builder-visual-card{min-height:326px!important;}

.card-shop-box{width:min(1260px,98vw)!important;}
.card-shop-toolbar{
  display:grid!important;
  grid-template-columns:110px 100px 82px 92px minmax(170px,1fr) 86px!important;
  gap:6px!important;
  align-items:end!important;
}
.card-shop-toolbar>*{min-width:0!important;}
.card-shop-toolbar label{min-width:0!important;}
.card-shop-toolbar select,.card-shop-toolbar input{width:100%!important;min-width:0!important;}
.card-shop-count{
  min-width:0!important;
  height:32px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:4px!important;
  padding:0 6px!important;
  white-space:nowrap!important;
}
.card-shop-count span,.card-shop-count small{font-size:9px;color:#cdbb9e;}
.card-shop-count b{font-size:18px!important;line-height:1!important;}
.card-shop-grid{
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-auto-rows:max-content!important;
  align-items:start!important;
  align-content:start!important;
  gap:8px!important;
  padding:8px!important;
}
.card-shop-grid .shop-card{
  width:100%!important;
  height:auto!important;
  min-height:292px!important;
  display:grid!important;
  grid-template-rows:50px 160px auto minmax(48px,auto)!important;
  overflow:hidden!important;
  cursor:default!important;
  box-sizing:border-box!important;
}
.card-shop-grid .shop-card>.collection-card-title{grid-row:1!important;}
.card-shop-grid .shop-card>.collection-card-art{grid-row:2!important;height:160px!important;min-height:160px!important;}
.card-shop-grid .shop-card>.collection-five-stats{grid-row:3!important;}
.card-shop-grid .shop-card>.collection-extra{grid-row:4!important;}
.card-shop-grid .collection-five-stats{
  min-height:36px!important;
  display:flex!important;
  align-items:center;
  justify-content:center;
  padding:6px 5px!important;
  font-size:11px!important;
  line-height:1.35!important;
  white-space:normal!important;
}
.card-shop-grid .collection-extra{
  min-height:48px!important;
  max-height:66px!important;
  padding:7px 7px!important;
  font-size:12px!important;
  font-weight:750!important;
  line-height:1.42!important;
  overflow:auto!important;
}

.card .cimg,.base-unit-art{cursor:pointer!important;}
.card .card-name-text.zoomable-card-name,.field-unit-name.zoomable-card-name,.base-unit-name-click.zoomable-card-name,.advisor-name-click.zoomable-card-name,.advisor-hand-name-click.zoomable-card-name{cursor:zoom-in!important;}

@media(max-width:1050px){
  .card-shop-toolbar{grid-template-columns:100px 92px 76px 84px minmax(140px,1fr) 78px!important;gap:4px!important;}
  .card-shop-toolbar select,.card-shop-toolbar input{font-size:10px!important;}
}
@media(max-width:850px){
  .card-shop-toolbar{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
  .card-shop-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
  .deck-builder-visual-card{grid-template-rows:50px 142px auto minmax(48px,auto) auto!important;}
  .deck-builder-visual-card>.collection-card-art{height:142px!important;min-height:142px!important;}
  .card-shop-grid .shop-card{grid-template-rows:50px 142px auto minmax(48px,auto)!important;}
  .card-shop-grid .shop-card>.collection-card-art{height:142px!important;min-height:142px!important;}
}
@media(max-width:560px){
  .card-shop-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
  .deck-builder-list,.deck-builder-list.selected,.card-shop-grid{grid-template-columns:1fr!important;}
}

.auto-point-rule-form{grid-template-columns:minmax(220px,360px)!important;justify-content:center!important;}
.deck-builder-list,.deck-builder-list.selected,.card-shop-grid{
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-auto-rows:max-content!important;
  align-items:start!important;
  align-content:start!important;
  gap:7px!important;
  padding:7px!important;
}
.deck-builder-visual-card,.card-shop-grid .shop-card{
  position:relative!important;
  width:100%!important;
  height:214px!important;
  min-height:214px!important;
  max-height:214px!important;
  padding:0!important;
  display:grid!important;
  grid-template-rows:22px 118px 34px 40px!important;
  gap:0!important;
  overflow:hidden!important;
  box-sizing:border-box!important;
  border-radius:4px!important;
  background:linear-gradient(180deg,#151719,#0b0d0f)!important;
  cursor:default!important;
}
.deck-builder-visual-card>.collection-card-title,.card-shop-grid .shop-card>.collection-card-title{
  grid-row:1!important;
  min-height:22px!important;
  height:22px!important;
  padding:2px 4px!important;
  align-items:center!important;
  background:linear-gradient(180deg,#3d2a1f,#1c1511)!important;
  border-bottom:1px solid #7f6039!important;
}
.collection-card-heading{display:flex!important;align-items:center!important;gap:4px!important;flex-wrap:nowrap!important;overflow:hidden!important;}
.collection-card-heading .collection-card-name{font-size:10px!important;line-height:1!important;max-width:48%!important;}
.collection-card-heading small{font-size:7px!important;line-height:1!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;}
.collection-card-title>em{font-size:8px!important;padding:1px 3px!important;align-self:center!important;}
.deck-builder-visual-card>.collection-card-art,.card-shop-grid .shop-card>.collection-card-art{
  grid-row:2!important;
  height:118px!important;
  min-height:118px!important;
  max-height:118px!important;
  margin:0!important;
  padding:0!important;
  overflow:hidden!important;
  background:#15120f!important;
}
.collection-card-art .card-art-img,.collection-card-art .configured-default-art,.collection-card-art .auto-folder-art{
  width:100%!important;height:100%!important;object-fit:cover!important;
  object-position:var(--img-x,50%) var(--img-y,50%)!important;
  transform:scale(var(--img-scale,1))!important;
  transform-origin:var(--img-x,50%) var(--img-y,50%)!important;
}
.collection-card-icons{right:4px!important;bottom:4px!important;gap:3px!important;}
.collection-card-icons span{font-size:8px!important;padding:2px 4px!important;}
.deck-builder-visual-card>.collection-five-stats,.card-shop-grid .shop-card>.collection-five-stats{
  grid-row:3!important;
  height:34px!important;
  min-height:34px!important;
  max-height:34px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:2px 3px!important;
  margin:0!important;
  border-radius:0!important;
  font-size:9px!important;
  font-weight:950!important;
  line-height:1.15!important;
  letter-spacing:0!important;
  white-space:normal!important;
  overflow:hidden!important;
  background:linear-gradient(180deg,#131619,#0d1012)!important;
  border-top:1px solid #374450!important;
  border-bottom:1px solid #374450!important;
}
.collection-five-stats.item-bonus-stats{color:#fff0ae!important;}
.deck-builder-visual-card>.collection-extra,.card-shop-grid .shop-card>.collection-extra{
  grid-row:4!important;
  height:40px!important;
  min-height:40px!important;
  max-height:40px!important;
  padding:5px 6px!important;
  margin:0!important;
  font-size:10px!important;
  font-weight:800!important;
  line-height:1.32!important;
  display:-webkit-box!important;
  -webkit-line-clamp:2!important;
  -webkit-box-orient:vertical!important;
  overflow:hidden!important;
  background:#101318!important;
  color:#ded5c6!important;
}
.deck-builder-visual-card.selected{border-color:#c99b55!important;box-shadow:inset 0 0 0 1px #6f4a20!important;}
.deck-builder-visual-card[data-deck-card]::after,.deck-builder-visual-card[data-selected-card]::after{
  content:'더블클릭';position:absolute;left:4px;top:26px;z-index:8;padding:2px 4px;border-radius:3px;
  background:rgba(0,0,0,.65);border:1px solid rgba(255,221,151,.45);color:#f7dfa8;font-size:7px;font-weight:900;pointer-events:none;
}
.deck-owned-compact{position:absolute;left:4px;bottom:43px;z-index:9;display:flex;align-items:center;gap:2px;height:20px;padding:1px 3px;border:1px solid #80643c;background:rgba(5,8,11,.86);border-radius:4px;}
.deck-owned-compact small{font-size:7px;color:#d9c79f;}
.deck-owned-compact button{width:17px!important;height:17px!important;min-height:17px!important;padding:0!important;border:1px solid #80643c!important;background:#1b2027!important;color:#ffe1a3!important;font-size:11px!important;line-height:1!important;border-radius:3px!important;}
.deck-owned-compact em{min-width:15px;text-align:center;font-size:9px;font-style:normal;font-weight:950;color:#fff;}
.deck-builder-visual-card>.deck-card-controls,.deck-builder-visual-card>.collection-card-foot{display:none!important;}
.card-shop-grid .shop-card{cursor:default!important;}
.collection-card-name.zoomable-card-name{cursor:zoom-in!important;}
@media(max-width:850px){
  .deck-builder-list,.deck-builder-list.selected,.card-shop-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
  .deck-builder-visual-card,.card-shop-grid .shop-card{height:205px!important;min-height:205px!important;max-height:205px!important;grid-template-rows:22px 109px 34px 40px!important;}
  .deck-builder-visual-card>.collection-card-art,.card-shop-grid .shop-card>.collection-card-art{height:109px!important;min-height:109px!important;max-height:109px!important;}
}
@media(max-width:560px){.deck-builder-list,.deck-builder-list.selected,.card-shop-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;}.collection-card-heading small{display:none!important;}}

.deck-builder-list,.deck-builder-list.selected,.card-shop-grid{
  grid-template-columns:repeat(3,var(--collection-card-width,118px))!important;
  justify-content:start!important;
  justify-items:start!important;
}
.deck-builder-visual-card,.card-shop-grid .shop-card{
  width:var(--collection-card-width,118px)!important;
  min-width:var(--collection-card-width,118px)!important;
  max-width:var(--collection-card-width,118px)!important;
  height:var(--collection-card-height,232px)!important;
  min-height:var(--collection-card-height,232px)!important;
  max-height:var(--collection-card-height,232px)!important;
  grid-template-rows:var(--collection-card-title-height,22px) var(--collection-card-art-height,136px) var(--collection-card-stats-height,34px) var(--collection-card-desc-height,40px)!important;
}
.deck-builder-visual-card>.collection-card-title,.card-shop-grid .shop-card>.collection-card-title{
  height:var(--collection-card-title-height,22px)!important;
  min-height:var(--collection-card-title-height,22px)!important;
}
.deck-builder-visual-card>.collection-card-art,.card-shop-grid .shop-card>.collection-card-art{
  height:var(--collection-card-art-height,136px)!important;
  min-height:var(--collection-card-art-height,136px)!important;
  max-height:var(--collection-card-art-height,136px)!important;
}
.deck-builder-visual-card>.collection-five-stats,.card-shop-grid .shop-card>.collection-five-stats{
  height:var(--collection-card-stats-height,34px)!important;
  min-height:var(--collection-card-stats-height,34px)!important;
  max-height:var(--collection-card-stats-height,34px)!important;
  font-size:8px!important;
}
.deck-builder-visual-card>.collection-extra,.card-shop-grid .shop-card>.collection-extra{
  height:var(--collection-card-desc-height,40px)!important;
  min-height:var(--collection-card-desc-height,40px)!important;
  max-height:var(--collection-card-desc-height,40px)!important;
  font-size:9px!important;
}
.collection-card-heading .collection-card-name{max-width:45%!important;font-size:9px!important;}
.collection-card-heading small{font-size:6.5px!important;}
.collection-card-title>em{font-size:7px!important;}
@media(max-width:850px){
  .deck-builder-list,.deck-builder-list.selected,.card-shop-grid{grid-template-columns:repeat(2,var(--collection-card-width,112px))!important;}
  .deck-builder-visual-card,.card-shop-grid .shop-card{
    width:var(--collection-card-width,112px)!important;min-width:var(--collection-card-width,112px)!important;max-width:var(--collection-card-width,112px)!important;
    height:var(--collection-card-height,220px)!important;min-height:var(--collection-card-height,220px)!important;max-height:var(--collection-card-height,220px)!important;
    grid-template-rows:var(--collection-card-title-height,20px) var(--collection-card-art-height,128px) var(--collection-card-stats-height,32px) var(--collection-card-desc-height,40px)!important;
  }
}

.deck-builder-box{width:min(1580px,99vw)!important;}
.deck-builder-main{
  grid-template-columns:minmax(690px,5fr) minmax(550px,4fr)!important;
  gap:10px!important;
}
.deck-builder-list{
  grid-template-columns:repeat(5,var(--collection-card-width,130px))!important;
  gap:8px!important;
  justify-content:start!important;
  justify-items:start!important;
  overflow:auto!important;
}
.deck-builder-list.selected{
  grid-template-columns:repeat(4,var(--collection-card-width,130px))!important;
}
.card-shop-box{width:min(1040px,98vw)!important;}
.card-shop-grid{
  grid-template-columns:repeat(5,var(--collection-card-width,130px))!important;
  gap:8px!important;
  justify-content:start!important;
  justify-items:start!important;
}
.deck-card-entry,.shop-card-entry{
  width:var(--collection-card-width,130px)!important;
  min-width:var(--collection-card-width,130px)!important;
  max-width:var(--collection-card-width,130px)!important;
  display:grid!important;
  grid-template-rows:auto 24px!important;
  gap:4px!important;
  align-content:start!important;
}
.deck-card-entry .deck-builder-visual-card,.shop-card-entry .shop-card{
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
}
.deck-owned-compact{display:none!important;}
.deck-owned-outside,.shop-owned-outside{
  height:24px!important;
  min-height:24px!important;
  box-sizing:border-box!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:4px!important;
  padding:2px 4px!important;
  border:1px solid #80643c!important;
  border-radius:4px!important;
  background:#0b0f14!important;
  color:#e6d2aa!important;
  font-size:8px!important;
  font-weight:900!important;
}
.deck-owned-outside small{font-size:8px!important;color:#d9c79f!important;}
.deck-owned-outside button{
  width:19px!important;height:19px!important;min-height:19px!important;padding:0!important;
  border:1px solid #80643c!important;background:#1b2027!important;color:#ffe1a3!important;
  font-size:12px!important;line-height:1!important;border-radius:3px!important;cursor:pointer!important;
}
.deck-owned-outside em{min-width:18px!important;text-align:center!important;font-size:10px!important;font-style:normal!important;color:#fff!important;}
.deck-builder-visual-card>.collection-five-stats,.card-shop-grid .shop-card>.collection-five-stats{
  white-space:nowrap!important;
  flex-wrap:nowrap!important;
  font-size:7.6px!important;
  letter-spacing:-.035em!important;
  padding-left:1px!important;
  padding-right:1px!important;
}

.deck-builder-list.selected .deck-builder-visual-card,.card-shop-grid .shop-card{
  height:calc(var(--collection-card-height,232px) + 18px)!important;
  min-height:calc(var(--collection-card-height,232px) + 18px)!important;
  max-height:calc(var(--collection-card-height,232px) + 18px)!important;
  grid-template-rows:var(--collection-card-title-height,22px) var(--collection-card-art-height,136px) var(--collection-card-stats-height,34px) calc(var(--collection-card-desc-height,40px) + 18px)!important;
}
.deck-builder-list.selected .collection-extra,.card-shop-grid .collection-extra{
  height:calc(var(--collection-card-desc-height,40px) + 18px)!important;
  min-height:calc(var(--collection-card-desc-height,40px) + 18px)!important;
  max-height:calc(var(--collection-card-desc-height,40px) + 18px)!important;
  display:block!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  -webkit-line-clamp:unset!important;
  scrollbar-width:thin!important;
  scrollbar-color:#80643c #101318!important;
}
.deck-builder-list.selected .collection-extra::-webkit-scrollbar,.card-shop-grid .collection-extra::-webkit-scrollbar{width:4px!important;}
.deck-builder-list.selected .collection-extra::-webkit-scrollbar-thumb,.card-shop-grid .collection-extra::-webkit-scrollbar-thumb{background:#80643c!important;border-radius:4px!important;}

.ally-hq-defense-lane[hidden],.ally-hq-defense-lane.inactive{display:none!important;}
.ally-hq-defense-lane.active{
  display:block!important;
  border:3px solid #ffe27a!important;
  background:linear-gradient(180deg,rgba(76,57,19,.82),rgba(17,23,32,.94))!important;
  box-shadow:0 0 0 2px rgba(255,176,43,.46),0 0 30px rgba(255,205,80,.62),inset 0 0 24px rgba(255,211,96,.24)!important;
  animation:allyBaseLaneGlow 1.3s ease-in-out infinite alternate!important;
}
.ally-hq-defense-lane.active .label{
  color:#fff6c8!important;
  font-weight:1000!important;
  text-shadow:0 0 8px #ffcf55,0 0 14px #ff9d2d!important;
  z-index:5!important;
}
.ally-hq-defense-lane .hq-battlefield-grid{
  width:100%!important;
  max-width:none!important;
  height:100%!important;
  min-height:0!important;
  padding:7px 8px 5px!important;
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  gap:7px!important;
  border:0!important;
  border-radius:8px!important;
  background:rgba(6,10,17,.64)!important;
  box-shadow:inset 0 0 18px rgba(255,210,94,.13)!important;
}
.ally-hq-defense-lane .hq-field-slot{
  height:100%!important;
  min-height:120px!important;
  border:2px dashed rgba(255,231,151,.68)!important;
  background:linear-gradient(145deg,rgba(58,43,18,.62),rgba(7,14,24,.8))!important;
  box-shadow:inset 0 0 13px rgba(255,210,100,.12)!important;
}
.ally-hq-defense-lane .hq-field-slot.valid,.ally-hq-defense-lane .hq-field-slot.empty:hover{
  border-style:solid!important;
  border-color:#fff09a!important;
  box-shadow:0 0 18px rgba(255,225,103,.62),inset 0 0 18px rgba(255,218,91,.25)!important;
}
@keyframes allyBaseLaneGlow{
  from{filter:brightness(1);}
  to{filter:brightness(1.13);}
}

@media(max-width:1280px){
  .deck-builder-box{width:min(1240px,99vw)!important;}
  .deck-builder-main{grid-template-columns:minmax(520px,4fr) minmax(410px,3fr)!important;}
  .deck-builder-list{grid-template-columns:repeat(4,var(--collection-card-width,130px))!important;}
  .deck-builder-list.selected{grid-template-columns:repeat(3,var(--collection-card-width,130px))!important;}
  .card-shop-grid{grid-template-columns:repeat(4,var(--collection-card-width,130px))!important;}
}
@media(max-width:980px){
  .deck-builder-main{grid-template-columns:1fr!important;overflow:auto!important;}
  .deck-builder-list{grid-template-columns:repeat(3,var(--collection-card-width,130px))!important;max-height:430px!important;}
  .deck-builder-list.selected{grid-template-columns:repeat(3,var(--collection-card-width,130px))!important;max-height:430px!important;}
  .card-shop-grid{grid-template-columns:repeat(3,var(--collection-card-width,130px))!important;}
}
@media(max-width:650px){
  .deck-builder-list,.deck-builder-list.selected,.card-shop-grid{grid-template-columns:repeat(2,var(--collection-card-width,123px))!important;}
  .ally-hq-defense-lane .hq-battlefield-grid{gap:3px!important;padding:5px 4px!important;}
  .ally-hq-defense-lane .hq-field-slot{min-height:88px!important;}
}

:root{--collection-card-width:130px;}
.deck-builder-list.selected>.deck-builder-visual-card{
  width:var(--collection-card-width,130px)!important;
  min-width:var(--collection-card-width,130px)!important;
  max-width:var(--collection-card-width,130px)!important;
}
.deck-builder-list.selected>.deck-builder-visual-card>.collection-extra,
.card-shop-grid .shop-card>.collection-extra{
  height:calc(var(--collection-card-desc-height,40px) + 18px)!important;
  min-height:calc(var(--collection-card-desc-height,40px) + 18px)!important;
  max-height:calc(var(--collection-card-desc-height,40px) + 18px)!important;
  display:block!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  -webkit-line-clamp:unset!important;
  scrollbar-width:thin!important;
  scrollbar-color:#80643c #101318!important;
}

.deck-builder-box{width:min(1840px,99.5vw)!important;}
.deck-builder-main{grid-template-columns:minmax(830px,6fr) minmax(700px,5fr)!important;gap:10px!important;}
.deck-builder-list{grid-template-columns:repeat(6,var(--collection-card-width,130px))!important;}
.deck-builder-list.selected{grid-template-columns:repeat(5,var(--collection-card-width,130px))!important;}
.card-shop-box{width:min(1160px,99vw)!important;}
.card-shop-grid{grid-template-columns:repeat(7,var(--collection-card-width,130px))!important;}
.deck-builder-visual-card[data-deck-card]::after,.deck-builder-visual-card[data-selected-card]::after{content:none!important;display:none!important;}
.deck-builder-toolbar{grid-template-columns:88px minmax(135px,1.2fr) minmax(130px,1.2fr) 66px 88px 88px 82px minmax(150px,1.3fr) 78px 88px!important;align-items:end!important;}
.deck-builder-toolbar>.deck-new-btn{height:34px!important;align-self:end!important;padding:5px 7px!important;white-space:nowrap!important;}
#deckBuilderName{height:34px!important;box-sizing:border-box!important;}
@media(max-width:1560px){
  .deck-builder-box{width:min(1500px,99.5vw)!important;}
  .deck-builder-main{grid-template-columns:minmax(690px,5fr) minmax(550px,4fr)!important;}
  .deck-builder-list{grid-template-columns:repeat(5,var(--collection-card-width,130px))!important;}
  .deck-builder-list.selected{grid-template-columns:repeat(4,var(--collection-card-width,130px))!important;}
  .card-shop-grid{grid-template-columns:repeat(6,var(--collection-card-width,130px))!important;}
}
@media(max-width:1280px){
  .deck-builder-list{grid-template-columns:repeat(4,var(--collection-card-width,130px))!important;}
  .deck-builder-list.selected{grid-template-columns:repeat(3,var(--collection-card-width,130px))!important;}
  .card-shop-grid{grid-template-columns:repeat(5,var(--collection-card-width,130px))!important;}
  .deck-builder-toolbar{grid-template-columns:repeat(5,minmax(105px,1fr))!important;}
}
@media(max-width:980px){
  .deck-builder-list,.deck-builder-list.selected{grid-template-columns:repeat(3,var(--collection-card-width,130px))!important;}
  .card-shop-grid{grid-template-columns:repeat(3,var(--collection-card-width,130px))!important;}
}
@media(max-width:650px){
  .deck-builder-list,.deck-builder-list.selected,.card-shop-grid{grid-template-columns:repeat(2,var(--collection-card-width,123px))!important;}
}

@media(min-width:1561px){
  
  .deck-builder-box{
    width:min(1570px,99.5vw)!important;
  }
  .deck-builder-main{
    grid-template-columns:836px 698px!important;
    justify-content:start!important;
  }
  .deck-builder-list{
    grid-template-columns:repeat(6,var(--collection-card-width,130px))!important;
  }
  .deck-builder-list.selected{
    grid-template-columns:repeat(5,var(--collection-card-width,130px))!important;
  }

  
  .card-shop-box{
    width:min(974px,99vw)!important;
  }
  .card-shop-grid{
    grid-template-columns:repeat(7,var(--collection-card-width,130px))!important;
    justify-content:start!important;
  }
}

@media(min-width:1561px){
  .deck-builder-box{
    width:min(calc(
      var(--collection-card-width,130px) + var(--collection-card-width,130px) +
      var(--collection-card-width,130px) + var(--collection-card-width,130px) +
      var(--collection-card-width,130px) + var(--collection-card-width,130px) +
      var(--collection-card-width,130px) + var(--collection-card-width,130px) +
      var(--collection-card-width,130px) + var(--collection-card-width,130px) +
      var(--collection-card-width,130px) + 140px
    ),99.5vw)!important;
  }
  .deck-builder-main{
    grid-template-columns:
      calc(
        var(--collection-card-width,130px) + var(--collection-card-width,130px) +
        var(--collection-card-width,130px) + var(--collection-card-width,130px) +
        var(--collection-card-width,130px) + var(--collection-card-width,130px) + 56px
      )
      calc(
        var(--collection-card-width,130px) + var(--collection-card-width,130px) +
        var(--collection-card-width,130px) + var(--collection-card-width,130px) +
        var(--collection-card-width,130px) + 48px
      )!important;
  }
  .deck-builder-list.selected{gap:8px!important;}
  .card-shop-box{
    width:min(calc(
      var(--collection-card-width,130px) + var(--collection-card-width,130px) +
      var(--collection-card-width,130px) + var(--collection-card-width,130px) +
      var(--collection-card-width,130px) + var(--collection-card-width,130px) +
      var(--collection-card-width,130px) + 64px
    ),99vw)!important;
  }
}

.event-image-effect-line{margin-top:8px}
.event-image-effect-line label{display:flex;flex-direction:column;gap:6px;color:#d7e4f5;font-size:12px;font-weight:700}
.sss-effect-panel{margin-top:8px;padding:14px;border:1px solid #2d4465;border-radius:14px;background:#0a1524}
.sss-effect-panel.disabled{opacity:.55}
.sss-effect-head{display:flex;flex-direction:column;gap:4px;margin-bottom:12px;color:#d7e6fb}
.sss-effect-head span{font-size:12px;color:#9fb5d3}
.sss-effect-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:12px}
.sss-trigger-box{padding:12px;border:1px solid #233650;border-radius:12px;background:#09111d;display:flex;flex-direction:column;gap:10px}
.sss-trigger-title label{display:flex;align-items:center;gap:8px;font-weight:800;color:#f7fbff}
.sss-trigger-fields{display:grid;grid-template-columns:1.2fr .8fr;gap:10px}
.sss-trigger-fields label,.sss-effect-stat{display:flex;flex-direction:column;gap:6px;font-size:12px;color:#cfe0f8}
.sss-effect-stat-list{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.sss-effect-stat label{font-weight:700}
.sss-effect-stat input[type="number"],.sss-trigger-fields input,.sss-trigger-fields select{width:100%}
.sss-effect-summary{padding:8px 10px;border-radius:10px;background:#102038;color:#f0f6ff;font-size:12px;line-height:1.45;border:1px solid #ffffff18}
@media (max-width:900px){.sss-effect-stat-list,.sss-trigger-fields{grid-template-columns:1fr}}

.manager-scene-lock{margin-top:9px;padding:8px 10px;border:1px solid #385274;border-radius:10px;background:#0d1a2a;color:#e5f0ff;display:flex;align-items:center;gap:8px;font-size:12px;font-weight:800}
.manager-scene-lock small{margin-left:auto;color:#9eb2cc;font-size:10px;font-weight:600}
.manager-scene-lock input{accent-color:#efb84b}

#hand.hand .card .hand-buff-provider-badge{
  left:50%!important;right:auto!important;top:60%!important;bottom:auto!important;
  transform:translate(-50%,-50%)!important;min-width:78px!important;max-width:calc(100% - 12px)!important;
  z-index:28!important;text-align:center!important;
}
#enemyHq .hq-stat-chip.deck{display:inline-flex!important;color:#ffe3a2!important}

.left-menu-dock .top-card-actions,
.left-bottom-actions{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:6px!important;
}
.left-menu-dock .top-card-actions .btn,
.left-bottom-actions .btn{
  width:100%!important;
  height:var(--battle-control-height,34px)!important;
  min-height:var(--battle-control-height,34px)!important;
  max-height:var(--battle-control-height,34px)!important;
  padding:4px 6px!important;
  font-size:12px!important;
  font-weight:900!important;
  box-sizing:border-box!important;
}

.reference-right .formation-control{padding:6px!important;gap:5px!important;}
.reference-right .formation-inline{
  display:grid!important;
  grid-template-columns:72px minmax(112px,1fr) 58px!important;
  gap:6px!important;
  align-items:center!important;
}
.reference-right .formation-inline #allyFormationSelect{
  width:72px!important;min-width:72px!important;max-width:72px!important;flex-basis:72px!important;
  padding:3px 2px!important;font-size:11px!important;
}
.reference-right .formation-inline #battleDeckSelect{
  width:100%!important;min-width:0!important;max-width:none!important;
  padding:3px 5px!important;font-size:11px!important;text-overflow:ellipsis!important;
}
.reference-right .formation-inline .formation-deck-btn{
  width:58px!important;min-width:58px!important;max-width:58px!important;
  padding:3px 4px!important;font-size:11px!important;white-space:nowrap!important;
}

.reference-right .right-deck-body{
  display:flex!important;
  grid-template-columns:none!important;
  align-items:stretch!important;
  padding:6px!important;
  gap:6px!important;
}
.reference-right .right-deck-body .deck-stack{display:none!important;}
.reference-right .right-action-mount{
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  grid-template-rows:var(--battle-control-height,34px)!important;
  gap:6px!important;
  padding:0!important;
  width:100%!important;
  flex:1 1 auto!important;
  align-items:stretch!important;
}
.reference-right .right-action-mount .deck-info,
.reference-right .right-action-mount #shuffleBtn,
.reference-right .right-action-mount #endTurnBtn,
.reference-right .right-action-mount #battleControlBtn{
  grid-column:auto!important;
  grid-row:auto!important;
  width:100%!important;
  min-width:0!important;
  height:var(--battle-control-height,34px)!important;
  min-height:var(--battle-control-height,34px)!important;
  max-height:var(--battle-control-height,34px)!important;
  margin:0!important;
  padding:3px 4px!important;
  box-sizing:border-box!important;
  font-size:11px!important;
  font-weight:900!important;
  line-height:1.05!important;
  white-space:nowrap!important;
}
.reference-right .right-action-mount .deck-info{
  display:flex!important;
  flex-direction:column!important;
  justify-content:center!important;
  align-items:center!important;
  border:1px solid #6b5131!important;
  border-radius:6px!important;
  background:linear-gradient(180deg,#1c1711,#0d0b08)!important;
  color:#f3dfb7!important;
}
.reference-right .right-action-mount .deck-info b{font-size:13px!important;line-height:1!important;}
.reference-right .right-action-mount .deck-help{display:block!important;font-size:8px!important;line-height:1!important;color:#a99a82!important;}
body.prebattle .reference-right .right-deck-body{
  pointer-events:auto!important;
  filter:saturate(.88) brightness(.9)!important;
}
body.prebattle #shuffleBtn,body.prebattle #endTurnBtn{pointer-events:none!important;opacity:.55!important;}

.revive-select-box{width:min(780px,94vw)!important;max-height:82vh!important;display:flex!important;flex-direction:column!important;gap:12px!important;}
.revive-select-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;}
.revive-select-head h2{margin:0 0 4px;}
.revive-candidate-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;overflow:auto;padding:2px 2px 8px;}
.revive-candidate-card{display:grid;grid-template-columns:72px minmax(0,1fr);gap:9px;align-items:center;padding:8px;border:1px solid #3a506e;border-radius:10px;background:linear-gradient(145deg,#0e1a2a,#080d15);color:#eef5ff;text-align:left;cursor:pointer;}
.revive-candidate-card:hover{border-color:#ffe287;box-shadow:0 0 14px rgba(255,221,102,.34);transform:translateY(-1px);}
.revive-candidate-art{height:92px;overflow:hidden;border-radius:7px;background:#070b10;}
.revive-candidate-art .cimg{height:100%!important;min-height:100%!important;}
.revive-candidate-info{display:flex;flex-direction:column;gap:6px;min-width:0;}
.revive-candidate-info b{font-size:14px;color:#fff0bf;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.revive-candidate-info small{font-size:10px;line-height:1.4;color:#b9c9dd;}
.slot.revive-target{border:2px solid #fff09a!important;background:linear-gradient(145deg,rgba(255,228,112,.28),rgba(28,48,78,.64))!important;box-shadow:0 0 18px rgba(255,232,122,.82),inset 0 0 16px rgba(255,228,102,.22)!important;animation:reviveTargetPulse .85s ease-in-out infinite alternate!important;cursor:pointer!important;}
@keyframes reviveTargetPulse{from{filter:brightness(1)}to{filter:brightness(1.28)}}
@media(max-width:760px){.revive-candidate-list{grid-template-columns:1fr!important}.reference-right .formation-inline{grid-template-columns:66px minmax(96px,1fr) 56px!important}.reference-right .formation-inline #allyFormationSelect{width:66px!important;min-width:66px!important;max-width:66px!important}}

#cardShopBtn,#cardManagerBtn,#settingsBtn,#rulesBtn{
  height:var(--battle-control-height,42px)!important;
  min-height:var(--battle-control-height,42px)!important;
  max-height:var(--battle-control-height,42px)!important;
  padding:4px 6px!important;
  box-sizing:border-box!important;
  font-size:12px!important;
  font-weight:900!important;
}
.reference-right .compact-settings-holder .formation-inline #allyFormationSelect{
  width:72px!important;min-width:72px!important;max-width:72px!important;flex:0 0 72px!important;
}
.reference-right .compact-settings-holder .formation-inline #battleDeckSelect{
  width:100%!important;min-width:0!important;max-width:none!important;flex:1 1 auto!important;
}
#leftMenuMount .top-card-actions{grid-auto-rows:var(--battle-control-height,42px)!important;}
#leftMenuMount .top-card-actions #cardShopBtn,
#leftMenuMount .top-card-actions #cardManagerBtn{
  height:var(--battle-control-height,42px)!important;
  min-height:var(--battle-control-height,42px)!important;
  max-height:var(--battle-control-height,42px)!important;
  padding:4px 6px!important;
}

.reference-right .right-action-mount #battleControlBtn{grid-column:1!important;grid-row:1!important;}
.reference-right .right-action-mount .deck-info{grid-column:2!important;grid-row:1!important;}
.reference-right .right-action-mount #shuffleBtn{grid-column:3!important;grid-row:1!important;}
.reference-right .right-action-mount #endTurnBtn{grid-column:4!important;grid-row:1!important;}

#batchSettingsModal [hidden]{display:none!important}
.batch-shuttle-panel{display:grid;gap:12px;padding:12px;border:1px solid #3e5f80;border-radius:12px;background:linear-gradient(180deg,#0e1b2b,#08111d);margin-bottom:12px}
.batch-card-image-shuttle{display:grid;grid-template-columns:140px repeat(3,minmax(170px,1fr));gap:10px;align-items:center;padding:10px;border:1px solid #29425f;border-radius:10px;background:#0a1524}
.batch-card-image-shuttle label,.batch-scene-shuttle-card label{display:grid;grid-template-columns:auto 1fr auto;gap:7px;align-items:center;color:#dbe9fb;font-size:12px}
.batch-card-image-shuttle input[type="range"],.batch-scene-shuttle-card input[type="range"]{min-width:0;width:100%}
.batch-card-image-shuttle output,.batch-scene-shuttle-card output{min-width:42px;text-align:right;color:#9ed8ff;font-weight:800}
.batch-scene-shuttle-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.batch-scene-shuttle-card{display:grid;gap:8px;padding:11px;border:1px solid #36516f;border-radius:11px;background:linear-gradient(180deg,#101d2e,#09131f)}
.batch-scene-shuttle-card>b{color:#fff4d6;font-size:13px}
.batch-scene-shuttle-card select{grid-column:2/4;min-width:0}
.batch-image-preset-row{grid-template-columns:auto repeat(4,auto) repeat(3,72px) minmax(220px,1fr) auto auto auto!important;align-items:center!important}
.batch-preset-scene-summary{min-width:220px;padding:7px 9px;border-radius:8px;background:#0b1726;border:1px solid #29445f;color:#cfe4ff;font-size:11px;line-height:1.35}
.batch-mini-field input[readonly]{background:#07101b!important;color:#8fcfff!important;border-color:#29445f!important;cursor:default}
#batchSettingsModal[data-settings-mode="batch"] .batch-current-card{display:none!important}
#batchSettingsModal[data-settings-mode="individual"] .batch-settings-box{max-width:min(1280px,98vw)!important}
#batchSettingsModal[data-settings-mode="individual"] .event-image-manager{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:14px!important}
#batchSettingsModal[data-settings-mode="individual"] .event-image-setting{padding:12px!important;border-radius:12px!important;border-color:#4b6686!important;background:linear-gradient(180deg,#111d2c,#090f18)!important}
.event-image-preview.event-hq-live-preview{display:flex!important;justify-content:center!important;align-items:center!important;width:100%!important;height:auto!important;min-height:calc(var(--stage-hq-height,170px) + 12px)!important;padding:6px!important;border:0!important;background:#04080e!important;overflow:visible!important}
.event-hq-preview-frame{position:relative!important;width:var(--stage-hq-width,320px)!important;height:var(--stage-hq-height,170px)!important;min-height:var(--stage-hq-height,170px)!important;max-width:100%!important;overflow:hidden!important;border:2px solid #ffffff38!important;box-shadow:0 12px 28px #000a,0 0 20px #6ebeff25!important}
.event-hq-preview-frame .hq-card-scene{inset:0!important}
.event-hq-preview-frame>.hq-title,.event-hq-preview-frame>.hq-subtitle{z-index:90!important;pointer-events:none}
.event-image-preview-actions{justify-content:center!important}
.event-image-preview-actions .btn{min-width:180px!important}
.event-image-manager>.image-adjust-title,.event-image-manager>.event-image-note{grid-column:1/-1!important}
@media(max-width:1100px){
  .batch-card-image-shuttle{grid-template-columns:1fr!important}
  .batch-scene-shuttle-grid,#batchSettingsModal[data-settings-mode="individual"] .event-image-manager{grid-template-columns:1fr!important}
  .batch-image-preset-row{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .batch-preset-scene-summary{grid-column:1/-1!important}
}

.batch-scene-shuttle-card .batch-scene-preview{margin-top:4px;min-height:var(--stage-hq-height,170px)}
.batch-scene-shuttle-card .batch-scene-preview-actions{justify-content:flex-end;padding-top:2px}
.batch-scene-shuttle-card .batch-scene-preview-actions .btn{min-height:30px!important;font-size:11px!important}
.batch-scene-shuttle-card .event-hq-preview-frame{width:min(100%,var(--stage-hq-width,320px));margin:0 auto}

.batch-settings-head-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap}
.batch-settings-head-actions .btn{min-width:92px}
.batch-target-selector{display:flex;align-items:center;gap:12px;flex-wrap:wrap;padding:10px 12px;border:1px solid #365574;border-radius:10px;background:#0a1625;color:#dbe9fb}
.batch-target-selector>b{color:#fff1cf;margin-right:4px}
.batch-target-selector label{display:inline-flex;align-items:center;gap:6px;font-size:12px;font-weight:800;white-space:nowrap}
.batch-target-selector input{accent-color:#58aee8}
.individual-card-picker{display:grid!important;grid-template-columns:minmax(220px,.8fr) minmax(300px,1.2fr) minmax(220px,1fr);gap:10px;align-items:end}
.individual-card-picker label{display:grid;gap:5px;color:#d6e5f7;font-size:11px;font-weight:800}
.individual-card-picker input,.individual-card-picker select{width:100%;min-height:36px}
#individualCardMeta{display:flex;align-items:center;min-height:36px;padding:7px 10px;border:1px solid #385675;border-radius:8px;background:#0a1625;color:#f0d49a;font-size:12px;font-weight:800}
@media(max-width:900px){.individual-card-picker{grid-template-columns:1fr!important}.batch-settings-head-actions{width:100%}.batch-settings-head-actions .btn{flex:1}}

.event-hq-preview-frame .scene-static-image-layer{position:absolute;inset:0;z-index:4;overflow:hidden;background:#02050a;pointer-events:none}
.event-hq-preview-frame .scene-static-image{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;max-width:none;max-height:none;animation:none!important;transition:none!important;filter:none!important;opacity:1!important}
.event-hq-preview-frame .scene-static-guide{position:absolute;left:8px;right:8px;bottom:6px;z-index:6;padding:4px 7px;border:1px solid #ffffff38;background:#05080dd9;color:#f4ead7;font-size:10px;font-weight:900;letter-spacing:.02em;text-align:center;text-shadow:0 1px 4px #000}
.event-hq-preview-frame .scene-static-empty{position:absolute;inset:0;display:grid;place-items:center;color:#aebbc9;font-size:12px;font-weight:800;background:linear-gradient(135deg,#0c1724,#05090f)}
.event-hq-preview-frame>.hq-title,.event-hq-preview-frame>.hq-subtitle{z-index:7!important}

.event-hq-preview-frame .scene-static-image{
  object-position:var(--preview-x,50%) var(--preview-y,50%)!important;
  transform-origin:var(--preview-x,50%) var(--preview-y,50%)!important;
  transform:scale(var(--preview-scale,1))!important;
  will-change:transform,object-position;
}

#hand.hand .card.opening-hand-card{
  perspective:1100px!important;
  transform:none!important;
  overflow:visible!important;
  isolation:isolate;
}
#hand.hand .card.opening-hand-card.selected{outline:none!important;transform:none!important}
#hand.hand .opening-hand-flipper{
  position:absolute;
  inset:0;
  z-index:2;
  width:100%;
  height:100%;
  transform-style:preserve-3d;
  transform:rotateY(0deg);
  transition:transform .72s cubic-bezier(.2,.72,.18,1);
  transition-delay:calc(var(--opening-card-index,0) * 90ms);
  will-change:transform;
}
#hand.hand .opening-card-face{
  position:absolute;
  inset:-1px;
  border-radius:inherit;
  overflow:hidden;
  backface-visibility:hidden;
  -webkit-backface-visibility:hidden;
  box-sizing:border-box;
}
#hand.hand .opening-card-front-face{
  display:grid;
  grid-template-rows:inherit;
  transform:rotateY(180deg);
  background:inherit;
  border:1px solid transparent;
}
#hand.hand .opening-card-back-face{
  display:grid;
  place-items:center;
  border:2px solid #b98a49;
  background:
    radial-gradient(circle at 50% 48%,rgba(210,166,89,.22) 0 13%,transparent 14% 100%),
    repeating-radial-gradient(circle at 50% 50%,transparent 0 16px,rgba(212,169,94,.12) 17px 18px),
    linear-gradient(145deg,#111b25,#05090d 68%,#171007);
  box-shadow:inset 0 0 0 3px #0b0d10,inset 0 0 0 5px #7b5428,inset 0 0 28px #000,0 7px 18px #000a;
}
#hand.hand .opening-card-back-face::before,
#hand.hand .opening-card-back-face::after{
  content:"";
  position:absolute;
  width:42px;
  height:42px;
  border-color:#a7793e;
  opacity:.75;
}
#hand.hand .opening-card-back-face::before{left:9px;top:9px;border-left:2px solid;border-top:2px solid}
#hand.hand .opening-card-back-face::after{right:9px;bottom:9px;border-right:2px solid;border-bottom:2px solid}
#hand.hand .opening-card-back-frame{
  position:relative;
  z-index:2;
  width:68%;
  aspect-ratio:1/1;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:4px;
  border:1px solid #c6944d;
  outline:1px solid #3f2b17;
  outline-offset:4px;
  transform:rotate(45deg);
  background:radial-gradient(circle,#2c261c,#101318 72%);
  box-shadow:0 0 24px rgba(208,151,62,.22),inset 0 0 18px #000b;
}
#hand.hand .opening-card-back-frame>*{transform:rotate(-45deg)}
#hand.hand .opening-card-back-frame b{font-family:"Malgun Myeongjo","Batang",serif;font-size:19px;letter-spacing:.08em;color:#e3bc78;text-shadow:0 2px 5px #000}
#hand.hand .opening-card-back-frame span{font-size:6px;font-weight:900;letter-spacing:.12em;color:#9f8d70;white-space:nowrap}
#hand.hand .opening-card-back-frame small{font-family:"Malgun Myeongjo","Batang",serif;font-size:24px;line-height:1;color:#a12e24;text-shadow:0 0 10px #d0432e55}
body.prebattle #hand.hand .card.opening-hand-card{
  border-color:#7b5b34!important;
  background:#0c1116!important;
  box-shadow:0 4px 12px #000b!important;
}
body.hand-reveal-active #hand.hand .opening-hand-flipper{transform:rotateY(180deg)}
body.hand-reveal-active #hand.hand,
body.hand-reveal-active #shuffleBtn,
body.hand-reveal-active #endTurnBtn{pointer-events:none!important}
body.hand-reveal-active #shuffleBtn,
body.hand-reveal-active #endTurnBtn{opacity:.5!important}
@media(max-width:850px){
  #hand.hand .opening-card-back-frame b{font-size:17px}
  #hand.hand .opening-card-back-frame small{font-size:21px}
}
@media(prefers-reduced-motion:reduce){
  #hand.hand .opening-hand-flipper{transition-duration:.01ms!important;transition-delay:0ms!important}
}

#hand.hand .card.actionable-card:not(.opening-hand-card){
  border-color:#72e6a2!important;
  box-shadow:0 0 0 2px rgba(52,180,112,.42),0 0 16px rgba(69,224,139,.32)!important;
}
#hand.hand .card.actionable-card:not(.opening-hand-card)::before{
  content:'행동 가능';position:absolute;z-index:12;left:6px;top:6px;padding:2px 6px;border-radius:999px;
  background:rgba(11,92,55,.94);border:1px solid #9af4bd;color:#edfff4;font-size:9px;font-weight:900;letter-spacing:.03em;
}
#hand.hand .card.selected-vivid:not(.opening-hand-card){
  filter:saturate(1.25) brightness(1.18) contrast(1.08)!important;
  outline:3px solid #fff0a6!important;
  box-shadow:0 0 0 3px #8b6c16,0 0 28px rgba(255,223,103,.75)!important;
  transform:translateY(-9px) scale(1.025)!important;
  z-index:20!important;
}
#hand.hand .card.free-advisor-deploy:not(.opening-hand-card)::after{
  content:'전장 배치 AP 0';position:absolute;z-index:13;right:6px;top:6px;padding:2px 5px;border-radius:4px;
  background:#173b6d;border:1px solid #8fc5ff;color:#eaf5ff;font-size:9px;font-weight:900;
}
.ally-advisor.replace-valid{box-shadow:0 0 0 3px #f0b64b,0 0 24px rgba(240,182,75,.65)!important;}
.ally-advisor.replace-valid::after{content:'교체 가능';position:absolute;right:4px;top:4px;z-index:8;padding:2px 5px;border-radius:4px;background:#7d4c08;color:#fff1c3;font-size:9px;font-weight:900;}
.faction-formation-status{display:inline-flex;align-items:center;min-height:24px;padding:3px 8px;margin-left:6px;border:1px solid #5f6671;border-radius:999px;background:#15191f;color:#9ca5b2;font-size:10px;font-weight:800;white-space:nowrap;}
.faction-formation-status.active{border-color:#d2aa4e;background:linear-gradient(180deg,#4c3712,#251b0b);color:#ffe5a0;box-shadow:0 0 12px rgba(227,177,70,.3);}
.deck-faction-rule-note{margin:8px 12px 0;padding:7px 10px;border:1px solid #4b6681;border-radius:7px;background:#111d28;color:#bdd7ef;font-size:10px;line-height:1.45;}
.deck-builder-toolbar{grid-template-columns:110px minmax(145px,1.25fr) 72px 120px 88px 88px 82px minmax(145px,1.2fr) 78px 88px!important;}
.deck-builder-toolbar .deck-faction-filter select{border-color:#c59642!important;color:#ffe0a4!important;background:#251b0d!important;}
@media(max-width:1100px){.deck-builder-toolbar{grid-template-columns:repeat(5,minmax(105px,1fr))!important;}}
@media(max-width:720px){.deck-builder-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))!important;}.faction-formation-status{display:none;}}

.enemy-hq-defense-lane[hidden],.enemy-hq-defense-lane.inactive{display:none!important;}
.enemy-hq-defense-lane.active{
  display:block!important;
  border:3px solid #ff9b82!important;
  background:linear-gradient(180deg,rgba(79,29,23,.84),rgba(17,23,32,.94))!important;
  box-shadow:0 0 0 2px rgba(255,92,62,.38),0 0 30px rgba(255,112,84,.48),inset 0 0 24px rgba(255,132,96,.18)!important;
  animation:enemyBaseLaneGlow 1.3s ease-in-out infinite alternate!important;
}
.enemy-hq-defense-lane.active .label{
  color:#ffe2d9!important;
  font-weight:1000!important;
  text-shadow:0 0 8px #ff8b71,0 0 14px #d93d2d!important;
  z-index:5!important;
}
.enemy-hq-defense-lane .hq-battlefield-grid{
  width:100%!important;
  max-width:none!important;
  height:100%!important;
  min-height:0!important;
  padding:7px 8px 5px!important;
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  gap:7px!important;
  border:0!important;
  border-radius:8px!important;
  background:rgba(17,7,7,.66)!important;
  box-shadow:inset 0 0 18px rgba(255,112,84,.12)!important;
}
.enemy-hq-defense-lane .hq-field-slot{
  height:100%!important;
  min-height:120px!important;
  border:2px dashed rgba(255,177,157,.62)!important;
  background:linear-gradient(145deg,rgba(69,25,20,.64),rgba(11,13,19,.82))!important;
  box-shadow:inset 0 0 13px rgba(255,105,76,.1)!important;
}
@keyframes enemyBaseLaneGlow{
  from{filter:brightness(1);}
  to{filter:brightness(1.13);}
}
@media(max-width:760px){
  .enemy-hq-defense-lane .hq-battlefield-grid{gap:3px!important;padding:5px 4px!important;}
  .enemy-hq-defense-lane .hq-field-slot{min-height:88px!important;}
}

.battlefield-layout .unit .active-buff-badge,
.battlefield-layout .unit .smoke-buff{
  position:absolute!important;
  left:50%!important;
  right:auto!important;
  top:68%!important;
  bottom:auto!important;
  transform:translate(-50%,-50%)!important;
  z-index:22!important;
  min-width:72px!important;
  max-width:calc(100% - 16px)!important;
  padding:3px 5px!important;
  align-items:center!important;
  text-align:center!important;
  pointer-events:none!important;
}

.battlefield-layout .unit .active-buff-badge + .buff-provider-badge,
.battlefield-layout .unit .smoke-buff + .buff-provider-badge{
  left:50%!important;
  right:auto!important;
  top:33%!important;
  bottom:auto!important;
  transform:translate(-50%,-50%)!important;
}

.battlefield-layout .unit.support-buff-caster{
  outline:3px solid #7ff2dc!important;
  outline-offset:2px!important;
  filter:brightness(1.12) saturate(1.18)!important;
  box-shadow:0 0 0 2px #062f29,0 0 18px #58e2d0cc!important;
}
.slot.buff-cancel-source::after{
  content:'버프 선택 중';
  position:absolute;
  left:50%;top:4px;
  transform:translateX(-50%);
  z-index:35;
  padding:2px 5px;
  border:1px solid #a9fff0;
  border-radius:999px;
  background:#063c35ee;
  color:#effffb;
  font-size:8px;
  font-weight:950;
  white-space:nowrap;
  pointer-events:none;
}
.field-strategist-actions .buff-start-action{
  border-color:#47cdb7!important;
  background:linear-gradient(180deg,#0b5f54,#073d36)!important;
}
.field-strategist-actions .buff-cancel-action{
  border-color:#ffb26d!important;
  background:linear-gradient(180deg,#78411c,#4a2410)!important;
  color:#fff1df!important;
}

#otherImageModal .default-card-image-manager{grid-template-columns:1fr!important;align-items:start!important;}
#otherImageModal .default-card-image-manager>.image-adjust-title,
#otherImageModal .default-card-image-manager>.default-image-note,
#otherImageModal .default-card-image-manager>.default-image-controls,
#otherImageModal .default-card-image-manager>.default-image-preview-dual,
#otherImageModal .default-card-image-manager>#saveDefaultImageLayoutBtn,
#otherImageModal .default-card-image-manager>.manager-upload-label,
#otherImageModal .default-card-image-manager>input[type=file],
#otherImageModal .default-card-image-manager>#removeDefaultCardImageBtn{grid-column:1!important;}
.default-image-preview-dual,.hq-image-preview-dual,.batch-base-preview-dual{display:grid;grid-template-columns:1fr 1fr;gap:12px;}
.default-image-preview-dual .default-image-preview{height:230px!important;border:2px solid #4a6388!important;border-radius:12px!important;background:#111a27!important;}
@media(max-width:900px){
  .default-image-preview-dual,.hq-image-preview-dual,.batch-base-preview-dual{grid-template-columns:1fr;}
}
.other-adjustable-preview{position:relative!important;overflow:hidden!important;cursor:grab!important;touch-action:none!important;user-select:none!important;display:grid!important;place-items:center!important;}
.other-adjustable-preview.dragging{cursor:grabbing!important;outline:2px solid #e3b867!important;box-shadow:0 0 20px #d8a95055!important;}
.other-adjustable-preview.has-image::after,.hq-image-preview.custom::after{content:'이미지를 드래그해 위치 조절';position:absolute;left:7px;right:7px;bottom:7px;z-index:8;padding:4px 6px;background:#05080bbb;border:1px solid #ffffff33;color:#f3e5ce;font-size:9px;font-weight:800;text-align:center;pointer-events:none;}
.other-preview-art{width:100%!important;height:100%!important;display:block!important;object-fit:cover!important;object-position:var(--img-x,50%) var(--img-y,50%)!important;transform:scale(var(--img-scale,1));transform-origin:var(--img-x,50%) var(--img-y,50%);transition:transform .12s ease,object-position .12s ease;}
.other-image-adjust-panel{display:grid;gap:8px;padding:10px;border:1px solid #5f472d;background:#0a0d0f;min-width:0;}
.other-image-adjust-panel label{display:grid;grid-template-columns:46px minmax(0,1fr) 44px;gap:7px;align-items:center;font-size:10px;color:#d5c7b2;}
.other-image-adjust-panel input[type=range]{width:100%;accent-color:#c69b55;}
.other-image-adjust-panel output{text-align:right;color:#f2d69f;font-weight:900;font-size:10px;}
.other-image-adjust-actions{display:flex;gap:6px;flex-wrap:wrap;}
.other-image-adjust-actions .btn{flex:1;min-width:82px;}
#otherImageModal .hq-image-setting{display:grid!important;gap:7px!important;min-width:0!important;}
#otherImageModal .hq-image-preview{height:180px!important;background-size:cover!important;background-position:center!important;}
#otherImageModal .hq-image-preview .other-preview-art{position:absolute;inset:0;z-index:1;}
#otherImageModal .hq-image-preview span{z-index:7!important;}
#otherImageModal .other-image-adjust-panel.compact{padding:7px;gap:6px;}
#otherImageModal .other-image-adjust-panel.compact .image-adjust-title{display:none;}
.drag-position-readout{font-size:10px;color:#d5c7b2;padding:4px 0;}
.drag-position-readout b{color:#f2d69f;}
@media(max-width:900px){
  #otherImageModal .default-card-image-manager{grid-template-columns:1fr!important;}
  #otherImageModal .default-card-image-manager>*{grid-column:1!important;grid-row:auto!important;}
  #otherImageModal .default-card-image-manager>.default-image-preview{height:260px!important;}
}

.mobile-game-header,.mobile-ally-hq-mount,.mobile-hand-mount{display:none}
.responsive-anchor{display:none!important}

@media (max-width:850px){
  :root{--mobile-action-height:58px;--mobile-hand-height:174px}
  html,body{height:auto!important;min-height:100%!important;overflow-x:hidden!important;overflow-y:auto!important;overscroll-behavior-y:contain;background:#050708!important}
  body{padding:0 0 calc(env(safe-area-inset-bottom,0px) + 6px)!important;touch-action:pan-y;}
  body::before{content:'';position:fixed;inset:0;pointer-events:none;z-index:-1;background:radial-gradient(circle at 50% 4%,#432b1538,transparent 38%),linear-gradient(180deg,#080b0c,#030506)}

  .mobile-game-header{display:block;position:sticky;top:0;z-index:96;width:100%;border-bottom:1px solid #8a5b28;background:linear-gradient(180deg,#11191cfa,#070b0df7);box-shadow:0 8px 22px #000c,inset 0 -1px #000;padding-top:env(safe-area-inset-top,0px)}
  .mobile-brand-row{height:44px;display:flex;align-items:center;justify-content:space-between;padding:6px 10px;border-bottom:1px solid #3f2b17}
  .mobile-brand-row>div{display:flex;align-items:baseline;gap:8px;min-width:0}
  .mobile-brand-row b{font-family:"Malgun Myeongjo","Batang",serif;color:#e0b36a;font-size:19px;letter-spacing:-.04em;text-shadow:0 2px #241608}
  .mobile-brand-row span{color:#9f9789;font-size:10px;font-weight:800}
  .mobile-icon-btn{width:34px;height:32px;display:grid;place-items:center;border:1px solid #604621;background:#17130e;color:#e6c27d;border-radius:8px;font-size:17px;padding:0}

  .mobile-prebattle-menu{display:grid;gap:8px;padding:9px}
  .mobile-menu-card{display:grid;grid-template-columns:76px minmax(0,1fr);gap:7px;align-items:center;padding:8px;border:1px solid #5f482b;background:linear-gradient(145deg,#14191b,#0a0e10);box-shadow:inset 0 0 0 1px #000;border-radius:10px}
  .mobile-menu-label{align-self:stretch;display:flex;flex-direction:column;justify-content:center;padding-right:7px;border-right:1px solid #43341f}
  .mobile-menu-label span{color:#efd399;font-size:13px;font-weight:950}
  .mobile-menu-label small{margin-top:2px;color:#8f887b;font-size:8px;line-height:1.25}
  .mobile-menu-actions{display:grid;grid-template-columns:1fr 1fr;gap:7px}
  .mobile-menu-card .btn{min-height:42px;padding:7px;font-size:13px;font-weight:900;border-radius:8px}
  .battle-menu-card{grid-template-columns:76px minmax(0,1fr) 94px}
  .battle-menu-card select{min-width:0;width:100%;height:42px;padding:5px 8px;border-color:#71552e;background:#0b1114;color:#f1e6d2;font-size:12px;font-weight:800}
  .battle-menu-card #mobileBattleStartBtn{height:42px;background:linear-gradient(180deg,#376fc0,#1b477f);border-color:#68a2f1;color:#fff}
  .mobile-advanced-setup{display:grid;grid-template-columns:1fr 1fr;gap:7px;padding:9px;border:1px solid #4a3a24;background:#080c0e;border-radius:9px}
  .mobile-advanced-setup[hidden]{display:none!important}
  .mobile-advanced-setup label{display:grid;gap:4px;color:#bdb2a0;font-size:9px;font-weight:800}
  .mobile-advanced-setup label:last-of-type{grid-column:1/-1}
  .mobile-advanced-setup select{width:100%;min-width:0;height:36px;padding:5px 7px;font-size:11px}
  .mobile-advanced-actions{grid-column:1/-1;display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
  .mobile-advanced-actions .btn{min-height:36px;padding:5px;font-size:10px}

  .mobile-combat-summary{display:none;height:42px;grid-template-columns:repeat(5,1fr);border-top:1px solid #2e2519;border-bottom:1px solid #5f431f;background:#080c0e}
  .mobile-combat-summary>div{display:flex;align-items:center;justify-content:center;gap:4px;border-right:1px solid #2d3132;font-size:9px;color:#9f9a90}
  .mobile-combat-summary>div:last-child{border-right:0}
  .mobile-combat-summary b{font-size:13px;color:#f0d99f}
  .mobile-jump-nav{display:none;grid-template-columns:repeat(4,1fr);height:36px;background:#0c1113;border-bottom:1px solid #392c1b}
  .mobile-jump-nav button{border:0;border-right:1px solid #2f3537;background:transparent;color:#bfb6a8;font-size:10px;font-weight:900;padding:0}
  .mobile-jump-nav button:last-child{border-right:0}
  .mobile-jump-nav button:active{background:#2b2115;color:#f3d595}

  body.prebattle .mobile-combat-summary,body.prebattle .mobile-jump-nav{display:none!important}
  body:not(.prebattle) .mobile-prebattle-menu{display:none!important}
  body:not(.prebattle) .mobile-combat-summary{display:grid!important}
  body:not(.prebattle) .mobile-jump-nav{display:grid!important}
  body.prebattle .app{display:none!important}

  .app{display:block!important;width:100%!important;height:auto!important;min-height:0!important;min-width:0!important;padding:0!important;margin:0!important;overflow:visible!important}
  .app>.reference-left,.app>.reference-right{display:none!important}
  .battle-panel{display:flex!important;flex-direction:column!important;width:100%!important;height:auto!important;min-height:0!important;min-width:0!important;margin:0!important;border:0!important;border-radius:0!important;overflow:visible!important;background:#050708!important;box-shadow:none!important}
  .battle-panel::before,.battle-panel::after{display:none!important}
  .battle-panel>.reference-topbar{display:none!important}

  .boardwrap{order:1!important;display:block!important;position:relative!important;flex:none!important;width:100%!important;height:auto!important;min-height:0!important;overflow:visible!important;padding:8px 5px 5px!important;background:linear-gradient(#0003,#0003),linear-gradient(180deg,#4a2928 0 18%,#34402a 18% 82%,#223b50 82% 100%)!important}
  .battlefield-layout{display:block!important;width:100%!important;height:auto!important;min-height:0!important;margin:0!important;padding:0!important}
  .battlefield-layout>.board,.board{display:flex!important;flex-direction:column!important;gap:5px!important;width:100%!important;max-width:none!important;min-width:0!important;height:auto!important;min-height:0!important;margin:0!important;padding:0!important;overflow:visible!important}

  .enemy-hq-row,.mobile-ally-hq-mount .ally-hq-row{display:block!important;width:100%!important;height:auto!important;min-height:0!important;margin:0!important;padding:0!important}
  .enemy-hq-row .battle-hq,.mobile-ally-hq-mount .battle-hq{display:flex!important;width:100%!important;max-width:none!important;height:132px!important;min-height:132px!important;max-height:132px!important;margin:0!important;border-width:1px!important;border-radius:10px!important;background-position:center 42%!important}
  .enemy-hq-row .hq-title,.mobile-ally-hq-mount .hq-title{min-width:0!important;max-width:64%!important;font-size:12px!important;padding:3px 8px!important}
  .enemy-hq-row .hq-info-overlay,.mobile-ally-hq-mount .hq-info-overlay{left:7px!important;right:7px!important;top:36px!important;display:flex!important;gap:3px!important;flex-wrap:wrap!important;max-width:58%!important}
  .enemy-hq-row .hq-stat-chip,.mobile-ally-hq-mount .hq-stat-chip{font-size:8px!important;padding:2px 4px!important}
  .enemy-hq-row .hq-advisor-slot,.mobile-ally-hq-mount .hq-advisor-slot{right:6px!important;top:37px!important;width:38%!important;height:54px!important;min-height:54px!important}
  .mobile-ally-hq-mount{display:block!important;order:2!important;width:100%!important;padding:5px!important;background:linear-gradient(180deg,#182a3a,#071018)!important;border-top:1px solid #6b4b25!important}
  .mobile-ally-hq-mount .ally-hq-turn{right:7px!important;bottom:5px!important}
  .mobile-ally-hq-mount .hq-advisor-console{z-index:150!important}

  .battlefield-layout .lane{display:block!important;width:100%!important;height:auto!important;min-height:88px!important;margin:0!important;padding:17px 4px 4px!important;border-radius:8px!important;overflow:visible!important}
  .battlefield-layout .lane .label{left:7px!important;top:3px!important;font-size:9px!important;line-height:12px!important}
  .battlefield-layout .slots,.battlefield-layout .slots.n4,.battlefield-layout .slots.n3,.battlefield-layout .slots.n2{display:grid!important;width:100%!important;max-width:none!important;height:68px!important;min-height:68px!important;gap:3px!important;margin:0!important;align-items:stretch!important}
  .battlefield-layout .slots.n4{grid-template-columns:repeat(4,minmax(0,1fr))!important}
  .battlefield-layout .slots.n3{grid-template-columns:repeat(3,minmax(0,1fr))!important;padding-inline:9%!important}
  .battlefield-layout .slots.n2{grid-template-columns:repeat(2,minmax(0,1fr))!important;padding-inline:20%!important}
  .battlefield-layout .slot{width:100%!important;height:68px!important;min-height:68px!important;max-height:68px!important;border-radius:7px!important}
  .battlefield-layout .unit{height:100%!important;min-height:0!important;border-width:1px!important;border-radius:7px!important;grid-template-rows:16px minmax(0,1fr) 17px!important}
  .battlefield-layout .uname{height:16px!important;padding:1px 3px!important;font-size:8px!important;line-height:14px!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
  .battlefield-layout .uimg{height:100%!important;min-height:0!important;font-size:17px!important}
  .battlefield-layout .stats{height:17px!important;padding:1px!important;font-size:8px!important;line-height:14px!important}
  .battlefield-layout .typeicon{left:2px!important;bottom:18px!important;min-width:16px!important;min-height:16px!important;padding:1px 2px!important;font-size:8px!important}
  .battlefield-layout .active-buff-badge,.battlefield-layout .smoke-buff{min-width:42px!important;max-width:calc(100% - 6px)!important;padding:1px 2px!important;font-size:6px!important;line-height:1.1!important}
  .battlefield-layout .lane .capture-tag{right:5px!important;top:2px!important;font-size:7px!important;padding:1px 4px!important}
  .river{height:24px!important;min-height:24px!important;margin:0!important;border-radius:7px!important;font-size:9px!important;letter-spacing:4px!important}
  .hq-defense-lane.active{min-height:92px!important;padding-top:17px!important}
  .hq-defense-lane .hq-battlefield-grid,.enemy-hq-defense-lane .hq-battlefield-grid{height:68px!important;min-height:68px!important;grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:2px!important;padding:2px!important}
  .hq-defense-lane .hq-field-slot,.enemy-hq-defense-lane .hq-field-slot{height:64px!important;min-height:64px!important;max-height:64px!important}

  .mobile-hand-mount{display:block!important;order:3!important;position:sticky!important;bottom:calc(var(--mobile-action-height) + env(safe-area-inset-bottom,0px))!important;z-index:78!important;width:100%!important;height:var(--mobile-hand-height)!important;min-height:var(--mobile-hand-height)!important;max-height:var(--mobile-hand-height)!important;padding:0!important;background:#070b0df8!important;border-top:1px solid #8a5b28!important;box-shadow:0 -7px 20px #000c!important;backdrop-filter:blur(8px)}
  .mobile-hand-mount .right-hand-section{display:flex!important;flex-direction:column!important;width:100%!important;height:100%!important;min-height:0!important;max-height:none!important;margin:0!important;padding:0!important;border:0!important;background:transparent!important;overflow:hidden!important}
  .mobile-hand-mount .right-hand-section>.ornate-title{display:flex!important;flex:0 0 27px!important;height:27px!important;min-height:27px!important}
  .mobile-hand-mount .right-hand-section .handbox{display:block!important;flex:1!important;height:auto!important;min-height:0!important;padding:4px 5px 5px!important;overflow:hidden!important;background:transparent!important}
  .mobile-hand-mount .right-hand-section .handhead{display:none!important}
  .mobile-hand-mount #hand.hand{display:flex!important;grid-template-columns:none!important;width:100%!important;height:137px!important;min-height:137px!important;gap:5px!important;padding:1px 2px 8px!important;overflow-x:auto!important;overflow-y:hidden!important;scroll-snap-type:x proximity;-webkit-overflow-scrolling:touch;overscroll-behavior-x:contain}
  .mobile-hand-mount #hand.hand .card{flex:0 0 86px!important;width:86px!important;height:126px!important;min-height:126px!important;max-height:126px!important;display:grid!important;grid-template-rows:17px 67px minmax(0,1fr)!important;scroll-snap-align:start;border-radius:7px!important;overflow:hidden!important;transform:none}
  .mobile-hand-mount #hand.hand .card.selected,.mobile-hand-mount #hand.hand .card.selected-vivid{transform:translateY(-3px) scale(1.02)!important;z-index:8!important}
  .mobile-hand-mount #hand.hand .cname{font-size:8px!important;padding:1px 2px!important}
  .mobile-hand-mount #hand.hand .cimg{height:67px!important;min-height:67px!important}
  .mobile-hand-mount #hand.hand .cstats{padding:2px!important;gap:2px!important}
  .mobile-hand-mount #hand.hand .card-stat-grid{gap:2px!important}
  .mobile-hand-mount #hand.hand .card-stat-cell{min-height:27px!important;padding:1px!important}
  .mobile-hand-mount #hand.hand .card-stat-cell b{font-size:9px!important}
  .mobile-hand-mount #hand.hand .card-bottom-icons{gap:2px!important;padding:1px 2px!important;font-size:7px!important}
  .mobile-hand-mount #hand.hand .opening-hand-flipper{height:100%!important}
  .mobile-hand-mount #hand.hand .opening-card-face{border-radius:6px!important}
  .mobile-hand-mount .hand-title-arrow{min-width:30px!important;height:24px!important}

  .bottom-hud{display:block!important;order:4!important;position:sticky!important;bottom:0!important;z-index:82!important;width:100%!important;height:var(--mobile-action-height)!important;min-height:var(--mobile-action-height)!important;max-height:var(--mobile-action-height)!important;margin:0!important;padding:5px 6px calc(5px + env(safe-area-inset-bottom,0px))!important;border-top:1px solid #8a5b28!important;background:#070b0dfb!important;box-shadow:0 -5px 18px #000c!important}
  .bottom-hud .hud-status{display:block!important;width:100%!important;height:100%!important;padding:0!important;background:transparent!important}
  .bottom-hud .hud-status>:not(.hud-actions){display:none!important}
  .bottom-hud .hud-actions{display:grid!important;grid-template-columns:72px 1fr 1fr!important;gap:6px!important;width:100%!important;height:100%!important;min-width:0!important;margin:0!important}
  .bottom-hud .hud-actions .btn{display:block!important;width:100%!important;height:44px!important;min-height:44px!important;padding:5px 4px!important;border-radius:8px!important;font-size:11px!important;font-weight:950!important}
  .bottom-hud #battleControlBtn{order:1!important}
  .bottom-hud #shuffleBtn{order:2!important}
  .bottom-hud #endTurnBtn{order:3!important}

  .field-strategist-menu{position:fixed!important;left:8px!important;right:8px!important;top:auto!important;bottom:calc(var(--mobile-hand-height) + var(--mobile-action-height) + 8px + env(safe-area-inset-bottom,0px))!important;width:auto!important;max-height:42vh!important;overflow-y:auto!important;z-index:180!important}
  #allyAdvisorConsole.skill-menu-open{position:fixed!important;left:8px!important;right:8px!important;top:auto!important;bottom:calc(var(--mobile-hand-height) + var(--mobile-action-height) + 8px + env(safe-area-inset-bottom,0px))!important;width:auto!important;max-height:48vh!important;overflow-y:auto!important;z-index:181!important}
  .card-function-tooltip{display:none!important}
  .game-toast-wrap{top:calc(88px + env(safe-area-inset-top,0px))!important;width:calc(100vw - 18px)!important}

  .modal{align-items:flex-end!important;padding:0!important}
  .modalbox{width:100%!important;max-width:none!important;max-height:92dvh!important;border-radius:14px 14px 0 0!important;margin:0!important;padding-bottom:env(safe-area-inset-bottom,0px)!important}
  .deck-builder-box,.card-shop-box,.card-manager-box{height:92dvh!important;max-height:92dvh!important}
  .deck-builder-head,.manager-head,.card-shop-head{padding:10px!important;gap:7px!important}
  .deck-builder-main{grid-template-columns:1fr!important;grid-template-rows:minmax(170px,1fr) minmax(150px,.8fr)!important;min-height:0!important}
  .deck-builder-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))!important;padding:8px!important}
  .deck-builder-actions{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:6px!important;padding:8px!important}
  .deck-builder-actions .btn{min-width:0!important;font-size:10px!important;padding:7px 4px!important}
  .card-shop-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}

  @media (orientation:landscape){
    :root{--mobile-hand-height:146px;--mobile-action-height:52px}
    .mobile-brand-row{height:38px}
    .mobile-combat-summary{height:34px}
    .mobile-jump-nav{height:30px}
    .battlefield-layout .lane{min-height:79px!important}
    .battlefield-layout .slots,.battlefield-layout .slots.n4,.battlefield-layout .slots.n3,.battlefield-layout .slots.n2{height:60px!important;min-height:60px!important}
    .battlefield-layout .slot{height:60px!important;min-height:60px!important;max-height:60px!important}
    .mobile-hand-mount #hand.hand{height:109px!important;min-height:109px!important}
    .mobile-hand-mount #hand.hand .card{height:100px!important;min-height:100px!important;max-height:100px!important;grid-template-rows:15px 50px 1fr!important}
    .mobile-hand-mount #hand.hand .cimg{height:50px!important;min-height:50px!important}
    .bottom-hud .hud-actions .btn{height:39px!important;min-height:39px!important}
  }
}
@media (max-width:850px){
  #enemyHq,#board,#allyHq,#hand{scroll-margin-top:126px}
}
@media (max-width:850px){
  .battlefield-layout .hq-defense-lane[hidden],
  .battlefield-layout .hq-defense-lane.inactive{display:none!important}
  .battlefield-layout .hq-defense-lane.active{display:block!important}
  #enemyBaseSlot,#allyBaseSlot{
    width:100%!important;max-width:100%!important;min-width:0!important;
    overflow:hidden!important;grid-template-columns:repeat(5,minmax(0,1fr))!important;
  }
  #enemyBaseSlot>.hq-field-slot,#allyBaseSlot>.hq-field-slot{width:auto!important;min-width:0!important;max-width:100%!important}
}
@media (max-width:850px){
  .modal{z-index:500!important}
}
@media (max-width:850px){
  body:not(.prebattle) .mobile-game-header{position:fixed!important;top:0!important;left:0!important;right:0!important}
  body:not(.prebattle) .app{padding-top:123px!important}
}
@media (max-width:850px) and (orientation:landscape){
  body:not(.prebattle) .app{padding-top:102px!important}
}

.ui-mode-switch{
  display:grid;
  grid-template-columns:54px minmax(0,1fr) minmax(0,1fr);
  align-items:center;
  gap:4px;
  padding:4px;
  border:1px solid #4d3922;
  border-radius:7px;
  background:linear-gradient(180deg,#111719,#080c0e);
}
.ui-mode-switch>span{
  color:#a99b86;
  font-size:9px;
  font-weight:900;
  text-align:center;
  white-space:nowrap;
}
.ui-mode-switch .btn{
  width:100%!important;
  min-width:0!important;
  height:30px!important;
  min-height:30px!important;
  max-height:30px!important;
  padding:3px 4px!important;
  border-radius:5px!important;
  font-size:10px!important;
  font-weight:900!important;
}
.ui-mode-switch .btn.active{
  border-color:#e5b85d!important;
  background:linear-gradient(180deg,#6f4d20,#38230f)!important;
  color:#fff0c1!important;
  box-shadow:inset 0 0 0 1px #f4d08355,0 0 8px #d5963338!important;
}
.desktop-ui-mode-switch{margin:0 6px 6px}
.mobile-ui-mode-switch{grid-column:1/-1}

@media (min-width:851px){
  .reference-right .right-deck-section{
    flex:0 0 72px!important;
    min-height:72px!important;
    max-height:72px!important;
    height:72px!important;
    margin-bottom:4px!important;
  }
  .reference-right .right-deck-section>.ornate-title{
    flex:0 0 24px!important;
    height:24px!important;
    min-height:24px!important;
    max-height:24px!important;
    padding:2px 7px!important;
    margin:0!important;
    line-height:20px!important;
  }
  .reference-right .right-deck-body{
    flex:0 0 48px!important;
    width:100%!important;
    height:48px!important;
    min-height:48px!important;
    max-height:48px!important;
    padding:5px 6px!important;
    gap:5px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  .reference-right .right-action-mount{
    grid-template-rows:38px!important;
    height:38px!important;
    min-height:38px!important;
    max-height:38px!important;
    gap:5px!important;
  }
  .reference-right .right-action-mount .deck-info,
  .reference-right .right-action-mount #battleControlBtn,
  .reference-right .right-action-mount #shuffleBtn,
  .reference-right .right-action-mount #endTurnBtn{
    height:38px!important;
    min-height:38px!important;
    max-height:38px!important;
    padding:3px 4px!important;
  }
}

@media (max-width:850px){
  :root{--mobile-action-height:58px;--mobile-hand-height:216px}
  .mobile-jump-nav,
  body:not(.prebattle) .mobile-jump-nav{display:none!important}
  body:not(.prebattle) .app{padding-top:86px!important;padding-bottom:calc(var(--mobile-action-height) + env(safe-area-inset-bottom,0px) + 8px)!important}
  body:not(.prebattle){padding-bottom:calc(var(--mobile-action-height) + env(safe-area-inset-bottom,0px) + 8px)!important}

  .enemy-hq-row .battle-hq,.mobile-ally-hq-mount .battle-hq{
    height:150px!important;min-height:150px!important;max-height:150px!important;
  }
  .battlefield-layout .lane{
    min-height:130px!important;
    padding:18px 4px 5px!important;
  }
  .battlefield-layout .slots,
  .battlefield-layout .slots.n4,
  .battlefield-layout .slots.n3,
  .battlefield-layout .slots.n2{
    height:106px!important;min-height:106px!important;gap:4px!important;
  }
  .battlefield-layout .slots.n3{padding-inline:7%!important}
  .battlefield-layout .slots.n2{padding-inline:17%!important}
  .battlefield-layout .slot{
    height:106px!important;min-height:106px!important;max-height:106px!important;
  }
  .battlefield-layout .unit{
    grid-template-rows:19px minmax(0,1fr) 21px!important;
  }
  .battlefield-layout .uname{
    height:19px!important;font-size:9px!important;line-height:17px!important;padding:1px 3px!important;
  }
  .battlefield-layout .uimg{font-size:22px!important}
  .battlefield-layout .stats{
    height:21px!important;font-size:9px!important;line-height:18px!important;padding:1px 2px!important;
  }
  .battlefield-layout .typeicon{
    bottom:22px!important;min-width:18px!important;min-height:18px!important;font-size:9px!important;
  }
  .hq-defense-lane.active{min-height:119px!important}
  .hq-defense-lane .hq-battlefield-grid,.enemy-hq-defense-lane .hq-battlefield-grid{
    height:94px!important;min-height:94px!important;gap:3px!important;
  }
  .hq-defense-lane .hq-field-slot,.enemy-hq-defense-lane .hq-field-slot{
    height:90px!important;min-height:90px!important;max-height:90px!important;
  }

  .mobile-hand-mount{
    display:block!important;
    order:3!important;
    position:relative!important;
    bottom:auto!important;
    z-index:20!important;
    height:var(--mobile-hand-height)!important;
    min-height:var(--mobile-hand-height)!important;
    max-height:var(--mobile-hand-height)!important;
    padding:0!important;
    box-shadow:none!important;
  }
  .mobile-hand-mount .right-hand-section>.ornate-title{
    flex:0 0 30px!important;height:30px!important;min-height:30px!important;
  }
  .mobile-hand-mount .right-hand-section .handbox{
    padding:5px 6px 8px!important;
  }
  .mobile-hand-mount #hand.hand{
    height:178px!important;min-height:178px!important;gap:7px!important;padding:2px 3px 10px!important;
  }
  .mobile-hand-mount #hand.hand .card{
    flex:0 0 112px!important;
    width:112px!important;
    height:164px!important;
    min-height:164px!important;
    max-height:164px!important;
    grid-template-rows:19px 88px minmax(0,1fr)!important;
  }
  .mobile-hand-mount #hand.hand .cname{font-size:9px!important;padding:2px 3px!important}
  .mobile-hand-mount #hand.hand .cimg{height:88px!important;min-height:88px!important}
  .mobile-hand-mount #hand.hand .card-stat-cell{min-height:30px!important}
  .mobile-hand-mount #hand.hand .card-stat-cell b{font-size:10px!important}
  .mobile-hand-mount #hand.hand .card-bottom-icons{font-size:8px!important}

  .bottom-hud{
    position:fixed!important;
    left:0!important;right:0!important;bottom:0!important;
    z-index:92!important;
  }
  #enemyHq,#board,#allyHq,#hand{scroll-margin-top:92px!important}

  .mobile-ui-mode-switch{margin-top:1px}
  .desktop-ui-mode-switch{display:none!important}
}

@media (max-width:850px) and (orientation:landscape){
  :root{--mobile-action-height:54px;--mobile-hand-height:196px}
  body:not(.prebattle) .app{padding-top:72px!important}
  .battlefield-layout .lane{min-height:112px!important}
  .battlefield-layout .slots,.battlefield-layout .slots.n4,.battlefield-layout .slots.n3,.battlefield-layout .slots.n2{
    height:90px!important;min-height:90px!important;
  }
  .battlefield-layout .slot{height:90px!important;min-height:90px!important;max-height:90px!important}
  .mobile-hand-mount #hand.hand{height:158px!important;min-height:158px!important}
  .mobile-hand-mount #hand.hand .card{
    height:146px!important;min-height:146px!important;max-height:146px!important;grid-template-rows:18px 76px minmax(0,1fr)!important;
  }
  .mobile-hand-mount #hand.hand .cimg{height:76px!important;min-height:76px!important}
}

@media (max-width:850px){
  
  body.prebattle .mobile-game-header{
    position:relative!important;
    min-height:100dvh;
    display:flex!important;
    flex-direction:column;
    background:
      radial-gradient(circle at 50% 8%,#70451e38,transparent 34%),
      linear-gradient(180deg,#11191c,#050809 74%);
  }
  body.prebattle .mobile-prebattle-menu{
    display:grid!important;
    align-content:start;
    gap:12px;
    width:100%;
    padding:14px 10px calc(18px + env(safe-area-inset-bottom,0px));
  }
  body.prebattle .mobile-menu-card{
    grid-template-columns:92px minmax(0,1fr);
    gap:9px;
    padding:10px;
    border-radius:12px;
  }
  body.prebattle .battle-menu-card{
    grid-template-columns:92px minmax(0,1fr);
  }
  body.prebattle .battle-menu-card .mobile-menu-label{
    grid-row:1 / span 2;
  }
  body.prebattle .battle-menu-card #mobileBattleDeckSelect,
  body.prebattle .battle-menu-card #mobileBattleStartBtn{
    grid-column:2;
    width:100%;
    min-width:0;
  }
  body.prebattle .mobile-menu-card .btn,
  body.prebattle .battle-menu-card select{
    min-height:46px!important;
    height:46px!important;
    font-size:13px!important;
  }
  .mobile-prebattle-guide{
    margin:0;
    padding:10px 12px;
    border:1px solid #4b3a25;
    border-radius:10px;
    background:#080c0ecc;
    color:#bdb2a0;
    font-size:10px;
    line-height:1.5;
    text-align:center;
  }
  body:not(.prebattle) .mobile-prebattle-guide{display:none!important}

  
  body.mobile-battle-active,
  body:not(.prebattle){
    overflow-y:auto!important;
    touch-action:pan-y!important;
    scroll-behavior:smooth;
  }
  body:not(.prebattle) .mobile-game-header{
    position:sticky!important;
    top:0!important;
    left:auto!important;
    right:auto!important;
    width:100%!important;
  }
  body:not(.prebattle) .app{
    display:block!important;
    padding-top:0!important;
    padding-bottom:calc(var(--mobile-action-height) + env(safe-area-inset-bottom,0px) + 12px)!important;
  }
  body:not(.prebattle) .battle-panel{
    display:flex!important;
    flex-direction:column!important;
    overflow:visible!important;
  }
  body:not(.prebattle) .boardwrap{
    order:1!important;
    position:relative!important;
    overflow:visible!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount{
    order:2!important;
    position:relative!important;
  }
  body:not(.prebattle) .mobile-hand-mount{
    order:3!important;
    position:relative!important;
    inset:auto!important;
    overflow:visible!important;
    margin:0!important;
    height:auto!important;
    min-height:216px!important;
    max-height:none!important;
    scroll-margin-top:90px!important;
  }
  body:not(.prebattle) .mobile-hand-mount .right-hand-section{
    height:auto!important;
    min-height:216px!important;
    max-height:none!important;
    overflow:visible!important;
  }
  body:not(.prebattle) .mobile-hand-mount .handbox{
    min-height:184px!important;
    overflow:visible!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand{
    overflow-x:auto!important;
    overflow-y:hidden!important;
    overscroll-behavior-x:contain;
    -webkit-overflow-scrolling:touch;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card,
  body:not(.prebattle) .battlefield-layout .slot,
  body:not(.prebattle) .battlefield-layout .unit{
    pointer-events:auto!important;
    touch-action:manipulation!important;
  }
  body:not(.prebattle) .bottom-hud{
    position:fixed!important;
    left:0!important;
    right:0!important;
    bottom:0!important;
  }
  .mobile-jump-nav{display:none!important}
}

@media (max-width:850px) and (orientation:landscape){
  body:not(.prebattle) .app{padding-top:0!important}
  body:not(.prebattle) .mobile-hand-mount{
    min-height:196px!important;
  }
  body:not(.prebattle) .mobile-hand-mount .right-hand-section{
    min-height:196px!important;
  }
}

#hand.hand .card.wei{--card-accent:#78adff;--card-panel:#295ca3;--card-panel-strong:#1b4073;--card-panel-soft:rgba(137,182,255,.18);--card-panel-border:rgba(164,203,255,.42)}
#hand.hand .card.shu{--card-accent:#83d08d;--card-panel:#2f7a3e;--card-panel-strong:#225930;--card-panel-soft:rgba(137,224,153,.16);--card-panel-border:rgba(167,234,176,.38)}
#hand.hand .card.wu{--card-accent:#ff9898;--card-panel:#9b3939;--card-panel-strong:#6f2727;--card-panel-soft:rgba(255,162,162,.16);--card-panel-border:rgba(255,202,202,.38)}
#hand.hand .card.other,
#hand.hand .card.item,
#hand.hand .card.tactic,
#hand.hand .card.support,
#hand.hand .card.advisor-card-hand{--card-accent:#c0c6cd;--card-panel:#5f6874;--card-panel-strong:#434a53;--card-panel-soft:rgba(215,220,228,.15);--card-panel-border:rgba(230,234,240,.32)}

#hand.hand .card{
  background:linear-gradient(180deg,var(--card-panel-strong,#273341),#11171d 68%)!important;
  border-color:var(--card-accent,#8fa0b5)!important;
}
#hand.hand .card .cname{
  background:linear-gradient(180deg,color-mix(in srgb,var(--card-panel,#425468) 90%,#ffffff 10%),var(--card-panel-strong,#243342))!important;
  border-bottom:1px solid var(--card-panel-border,#506174)!important;
  color:#f6fbff!important;
}
#hand.hand .card .cstats{
  background:linear-gradient(180deg,color-mix(in srgb,var(--card-panel-strong,#243342) 78%,#ffffff 6%),#11171d)!important;
  padding:0!important;
}
#hand.hand .card-stat-grid{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:0!important;
  width:100%!important;
  border-top:1px solid rgba(255,255,255,.08)!important;
}
#hand.hand .card-stat-cell{
  min-height:34px!important;
  padding:2px 0!important;
  border:0!important;
  border-right:1px solid rgba(255,255,255,.18)!important;
  background:var(--card-panel-soft,rgba(255,255,255,.08))!important;
}
#hand.hand .card-stat-cell:last-child{border-right:0!important}
#hand.hand .card-stat-cell b{
  font-size:15px!important;
  font-weight:900!important;
  color:#edf4ff!important;
  letter-spacing:.01em!important;
}
#hand.hand .card-stat-cell span,
#hand.hand .equip-stat-bonus{display:none!important}
#hand.hand .card.item-stat-card .card-stat-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}
#hand.hand .card.item-stat-card .card-stat-cell:last-child{grid-column:auto!important}
#hand.hand .card.item-stat-card .card-stat-cell b{color:#f8fbff!important;font-size:14px!important}

.unit.wei,.base-unit.wei{background:linear-gradient(180deg,#2d5f9f,#173552)!important}
.unit.shu,.base-unit.shu{background:linear-gradient(180deg,#367946,#1e4728)!important}
.unit.wu,.base-unit.wu{background:linear-gradient(180deg,#9f4040,#5f2525)!important}
.unit.other,.base-unit.other{background:linear-gradient(180deg,#666d77,#383d44)!important}
.unit .stats,.base-unit-mini span,.base-unit-stat{
  background:rgba(9,12,15,.62)!important;
  border-top:1px solid rgba(255,255,255,.1)!important;
}

html.ui-mode-mobile-preview,
body.ui-mode-mobile-preview{
  --mobile-action-height:58px;
  --mobile-hand-height:216px;
  overflow-x:hidden!important;
  overflow-y:auto!important;
  background:#050708!important;
}
body.ui-mode-mobile-preview .mobile-game-header,
body.ui-mode-mobile-preview .mobile-ally-hq-mount,
body.ui-mode-mobile-preview .mobile-hand-mount{display:block!important}
body.ui-mode-mobile-preview .desktop-ui-mode-switch{display:none!important}
body.ui-mode-mobile-preview .app{display:block!important;width:100%!important;height:auto!important;min-height:0!important;padding:0!important;margin:0!important;overflow:visible!important}
body.ui-mode-mobile-preview .app>.reference-left,
body.ui-mode-mobile-preview .app>.reference-right{display:none!important}
body.ui-mode-mobile-preview .battle-panel{display:flex!important;flex-direction:column!important;width:100%!important;height:auto!important;border:0!important;border-radius:0!important;overflow:visible!important;background:#050708!important;box-shadow:none!important}
body.ui-mode-mobile-preview .battle-panel>.reference-topbar{display:none!important}
body.ui-mode-mobile-preview.prebattle .app{display:none!important}
body.ui-mode-mobile-preview.prebattle .mobile-game-header{
  position:relative!important;
  min-height:100vh;
  display:flex!important;
  flex-direction:column;
  background:radial-gradient(circle at 50% 8%,#70451e38,transparent 34%),linear-gradient(180deg,#11191c,#050809 74%)!important;
}
body.ui-mode-mobile-preview.prebattle .mobile-prebattle-menu{display:grid!important;align-content:start;gap:12px;width:100%;padding:14px 10px 18px!important}
body.ui-mode-mobile-preview.prebattle .mobile-combat-summary{display:none!important}
body.ui-mode-mobile-preview.prebattle .mobile-menu-card{display:grid!important;grid-template-columns:92px minmax(0,1fr);gap:9px;align-items:center;padding:10px;border:1px solid #5f482b;background:linear-gradient(145deg,#14191b,#0a0e10);border-radius:12px}
body.ui-mode-mobile-preview.prebattle .mobile-menu-label{align-self:stretch;display:flex;flex-direction:column;justify-content:center;padding-right:8px;border-right:1px solid #43341f}
body.ui-mode-mobile-preview.prebattle .mobile-menu-label span{color:#efd399;font-size:13px;font-weight:950}
body.ui-mode-mobile-preview.prebattle .mobile-menu-label small{margin-top:2px;color:#8f887b;font-size:8px;line-height:1.25}
body.ui-mode-mobile-preview.prebattle .mobile-menu-actions{display:grid;grid-template-columns:1fr 1fr;gap:7px}
body.ui-mode-mobile-preview.prebattle .mobile-menu-card .btn,
body.ui-mode-mobile-preview.prebattle .battle-menu-card select{min-height:46px!important;height:46px!important;font-size:13px!important}
body.ui-mode-mobile-preview.prebattle .battle-menu-card{grid-template-columns:92px minmax(0,1fr)!important}
body.ui-mode-mobile-preview.prebattle .battle-menu-card .mobile-menu-label{grid-row:1 / span 2}
body.ui-mode-mobile-preview.prebattle .battle-menu-card #mobileBattleDeckSelect,
body.ui-mode-mobile-preview.prebattle .battle-menu-card #mobileBattleStartBtn{grid-column:2;width:100%;min-width:0}
body.ui-mode-mobile-preview.prebattle .mobile-prebattle-guide{display:block!important;margin:0;padding:10px 12px;border:1px solid #4b3a25;border-radius:10px;background:#080c0ecc;color:#bdb2a0;font-size:10px;line-height:1.5;text-align:center}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-prebattle-menu{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-game-header{position:sticky!important;top:0!important;left:auto!important;right:auto!important;width:100%!important;border-bottom:1px solid #8a5b28;background:linear-gradient(180deg,#11191cfa,#070b0df7)!important;box-shadow:0 8px 22px #000c,inset 0 -1px #000}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-combat-summary{display:grid!important;height:42px;grid-template-columns:repeat(5,1fr);border-top:1px solid #2e2519;border-bottom:1px solid #5f431f;background:#080c0e}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-combat-summary>div{display:flex;align-items:center;justify-content:center;gap:4px;border-right:1px solid #2d3132;font-size:9px;color:#9f9a90}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-combat-summary>div:last-child{border-right:0}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-combat-summary b{font-size:13px;color:#f0d99f}
body.ui-mode-mobile-preview:not(.prebattle) .app{display:block!important;padding-bottom:calc(var(--mobile-action-height) + 12px)!important}
body.ui-mode-mobile-preview .boardwrap{order:1!important;display:block!important;position:relative!important;flex:none!important;width:100%!important;height:auto!important;overflow:visible!important;padding:8px 5px 5px!important;background:linear-gradient(#0003,#0003),linear-gradient(180deg,#4a2928 0 18%,#34402a 18% 82%,#223b50 82% 100%)!important}
body.ui-mode-mobile-preview .battlefield-layout{display:block!important;width:100%!important;height:auto!important;padding:0!important}
body.ui-mode-mobile-preview .battlefield-layout>.board,
body.ui-mode-mobile-preview .board{display:flex!important;flex-direction:column!important;gap:5px!important;width:100%!important;height:auto!important;margin:0!important;padding:0!important;overflow:visible!important}
body.ui-mode-mobile-preview .enemy-hq-row,
body.ui-mode-mobile-preview .mobile-ally-hq-mount .ally-hq-row{display:block!important;width:100%!important;margin:0!important;padding:0!important}
body.ui-mode-mobile-preview .enemy-hq-row .battle-hq,
body.ui-mode-mobile-preview .mobile-ally-hq-mount .battle-hq{display:flex!important;width:100%!important;height:150px!important;min-height:150px!important;max-height:150px!important;border-radius:10px!important}
body.ui-mode-mobile-preview .battlefield-layout .lane{display:block!important;width:100%!important;min-height:130px!important;margin:0!important;padding:18px 4px 5px!important;border-radius:8px!important;overflow:visible!important}
body.ui-mode-mobile-preview .battlefield-layout .lane .label{left:7px!important;top:3px!important;font-size:9px!important;line-height:12px!important}
body.ui-mode-mobile-preview .battlefield-layout .slots,
body.ui-mode-mobile-preview .battlefield-layout .slots.n4,
body.ui-mode-mobile-preview .battlefield-layout .slots.n3,
body.ui-mode-mobile-preview .battlefield-layout .slots.n2{display:grid!important;width:100%!important;height:106px!important;min-height:106px!important;gap:4px!important;margin:0!important;align-items:stretch!important}
body.ui-mode-mobile-preview .battlefield-layout .slots.n4{grid-template-columns:repeat(4,minmax(0,1fr))!important}
body.ui-mode-mobile-preview .battlefield-layout .slots.n3{grid-template-columns:repeat(3,minmax(0,1fr))!important;padding-inline:7%!important}
body.ui-mode-mobile-preview .battlefield-layout .slots.n2{grid-template-columns:repeat(2,minmax(0,1fr))!important;padding-inline:17%!important}
body.ui-mode-mobile-preview .battlefield-layout .slot{width:100%!important;height:106px!important;min-height:106px!important;max-height:106px!important;border-radius:7px!important}
body.ui-mode-mobile-preview .battlefield-layout .unit{height:100%!important;border-width:1px!important;border-radius:7px!important;grid-template-rows:19px minmax(0,1fr) 21px!important}
body.ui-mode-mobile-preview .battlefield-layout .uname{height:19px!important;padding:1px 3px!important;font-size:9px!important;line-height:17px!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
body.ui-mode-mobile-preview .battlefield-layout .uimg{height:100%!important;font-size:22px!important}
body.ui-mode-mobile-preview .battlefield-layout .stats{height:21px!important;padding:1px 2px!important;font-size:9px!important;line-height:18px!important}
body.ui-mode-mobile-preview .mobile-ally-hq-mount{display:block!important;order:2!important;width:100%!important;padding:5px!important;background:linear-gradient(180deg,#182a3a,#071018)!important;border-top:1px solid #6b4b25!important}
body.ui-mode-mobile-preview .mobile-hand-mount{display:block!important;order:3!important;position:relative!important;inset:auto!important;overflow:visible!important;margin:0!important;min-height:216px!important;max-height:none!important;padding:0!important}
body.ui-mode-mobile-preview .mobile-hand-mount .right-hand-section{height:auto!important;min-height:216px!important;max-height:none!important;overflow:visible!important}
body.ui-mode-mobile-preview .mobile-hand-mount .right-hand-section>.ornate-title{flex:0 0 30px!important;height:30px!important;min-height:30px!important}
body.ui-mode-mobile-preview .mobile-hand-mount .handbox{min-height:184px!important;padding:5px 6px 8px!important;overflow:visible!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand{height:178px!important;min-height:178px!important;overflow-x:auto!important;overflow-y:hidden!important;gap:7px!important;padding:2px 3px 10px!important;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .card{flex:0 0 112px!important;width:112px!important;height:164px!important;min-height:164px!important;max-height:164px!important;grid-template-rows:19px 88px minmax(0,1fr)!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .cname{font-size:9px!important;padding:2px 3px!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .cimg{height:88px!important;min-height:88px!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .card-stat-cell{min-height:30px!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .card-stat-cell b{font-size:10px!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .card,
body.ui-mode-mobile-preview .battlefield-layout .slot,
body.ui-mode-mobile-preview .battlefield-layout .unit{pointer-events:auto!important;touch-action:manipulation!important}
body.ui-mode-mobile-preview .bottom-hud{position:fixed!important;left:calc(50vw - 215px)!important;right:auto!important;bottom:0!important;width:430px!important;max-width:430px!important;z-index:92!important}
body.ui-mode-mobile-preview #enemyHq,
body.ui-mode-mobile-preview #board,
body.ui-mode-mobile-preview #allyHq,
body.ui-mode-mobile-preview #hand{scroll-margin-top:92px!important}

.unit .stats{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:0!important}
.unit .stats span{display:flex!important;align-items:center!important;justify-content:center!important;font-weight:900!important;border-right:1px solid rgba(255,255,255,.16)!important}
.unit .stats span:last-child{border-right:0!important}
.base-unit-stat,.base-unit-mini span{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:0!important;text-align:center!important}

.mobile-brand-actions{display:flex;align-items:center;gap:6px}
.mobile-pc-switch{display:none}

html.mobile-modal-open,body.mobile-modal-open{overflow:hidden!important;overscroll-behavior:none!important}
body.mobile-modal-open .modal.show{overscroll-behavior:contain;touch-action:pan-y}

@media (max-width:850px){
  .mobile-brand-actions{display:flex!important}
  .mobile-pc-switch{display:grid!important;place-items:center;width:42px;height:32px;padding:0;border:1px solid #604621;border-radius:8px;background:#17130e;color:#e6c27d;font-size:11px;font-weight:950}
  .mobile-pc-switch.active{border-color:#d2a257;background:#3b2a17;color:#fff0c8}

  body.prebattle .mobile-menu-actions{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}
  body.prebattle .mobile-menu-actions .btn{height:52px!important;min-height:52px!important;font-size:15px!important}
  body.prebattle .battle-menu-card #mobileBattleDeckSelect,
  body.prebattle .battle-menu-card #mobileBattleStartBtn{height:52px!important;min-height:52px!important;font-size:14px!important}
  body.prebattle .battle-menu-card #mobileBattleStartBtn{font-size:15px!important}

  .modal.show{display:flex!important;align-items:stretch!important;justify-content:stretch!important;padding:0!important;background:#000d!important}
  .modal.show>.modalbox{width:100%!important;height:100dvh!important;max-width:none!important;max-height:100dvh!important;margin:0!important;border:0!important;border-radius:0!important;padding-bottom:env(safe-area-inset-bottom,0px)!important;overscroll-behavior:contain!important}

  .card-manager-box{display:grid!important;grid-template-rows:auto minmax(0,1fr)!important;overflow:hidden!important}
  .manager-head{position:relative!important;z-index:3!important;display:grid!important;grid-template-columns:minmax(0,1fr)!important;align-items:stretch!important;padding:9px!important;gap:8px!important}
  .manager-head h2{font-size:16px!important}
  .manager-head .small{font-size:9px!important;line-height:1.4!important}
  .manager-head-actions{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;width:100%!important;gap:6px!important}
  .manager-head-actions .btn{width:100%!important;min-width:0!important;min-height:42px!important;padding:6px 3px!important;font-size:10px!important}
  .manager-main{display:grid!important;grid-template-columns:1fr!important;grid-template-rows:190px minmax(0,1fr)!important;min-height:0!important;overflow:hidden!important}
  .manager-list-pane{min-height:0!important;padding:7px!important;gap:6px!important;border-right:0!important;border-bottom:1px solid #2d3d59!important;overflow:hidden!important}
  .manager-search{grid-template-columns:minmax(0,1fr) 92px!important;gap:5px!important}
  .manager-search #managerTypeFilter{grid-column:1/-1!important;height:38px!important}
  .manager-search input,.manager-search select{height:38px!important;min-width:0!important;padding:5px 7px!important;font-size:11px!important}
  .manager-list{display:grid!important;grid-auto-flow:column!important;grid-auto-columns:minmax(168px,72vw)!important;overflow-x:auto!important;overflow-y:hidden!important;gap:6px!important;padding:0 0 4px!important;scroll-snap-type:x proximity!important;-webkit-overflow-scrolling:touch}
  .manager-card-row{grid-template-columns:42px minmax(0,1fr) auto!important;min-height:66px!important;padding:5px!important;border-radius:8px!important;scroll-snap-align:start!important}
  .manager-thumb{width:42px!important;height:52px!important}
  .manager-row-name{font-size:11px!important}.manager-row-meta{font-size:8px!important}
  .manager-edit-pane{min-height:0!important;padding:9px!important;overflow-y:auto!important;overflow-x:hidden!important;-webkit-overflow-scrolling:touch}
  .manager-grid{grid-template-columns:1fr!important;gap:10px!important}
  .manager-preview-wrap{gap:6px!important;padding-bottom:8px!important;border-bottom:1px solid #2a3b52!important}
  .manager-preview{height:190px!important;min-height:190px!important;border-radius:10px!important}
  .manager-upload-label,.manager-preview-wrap>.btn{min-height:42px!important;display:flex!important;align-items:center!important;justify-content:center!important;font-size:11px!important}
  .image-adjust-panel{padding:8px!important}
  .manager-form{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px!important}
  .manager-field.full,.sss-effect-panel{grid-column:1/-1!important}
  .manager-field label{font-size:9px!important}
  .manager-field input,.manager-field select,.manager-field textarea{min-height:40px!important;padding:7px!important;font-size:12px!important}
  .manager-field textarea{min-height:96px!important}
  .manager-actions{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:6px!important;position:sticky!important;bottom:0!important;z-index:4!important;padding:8px 0 calc(8px + env(safe-area-inset-bottom,0px))!important;background:linear-gradient(180deg,transparent,#0c1424 18%)!important}
  .manager-actions .btn{min-height:44px!important;font-size:11px!important}
  .sss-effect-stat-list,.sss-trigger-fields{grid-template-columns:1fr!important}

  .deck-builder-box,.card-shop-box{display:flex!important;flex-direction:column!important;overflow:hidden!important}
  .deck-builder-head,.card-shop-head{flex:0 0 auto!important;position:sticky!important;top:0!important;z-index:4!important;padding:9px!important;background:#11191d!important}
  .deck-builder-head h2,.card-shop-head h2{font-size:16px!important}
  .deck-builder-head .small,.card-shop-head .small{font-size:9px!important}
  .deck-builder-head .btn,.card-shop-head .btn{min-width:64px!important;min-height:42px!important;font-size:11px!important}
  .deck-builder-toolbar,.card-shop-toolbar{flex:0 0 auto!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:6px!important;padding:8px!important;overflow:visible!important}
  .deck-builder-toolbar label,.card-shop-toolbar label{min-width:0!important;font-size:9px!important}
  .deck-builder-toolbar input,.deck-builder-toolbar select,.card-shop-toolbar input,.card-shop-toolbar select{width:100%!important;min-width:0!important;height:42px!important;font-size:11px!important}
  .deck-builder-toolbar>input,.card-shop-toolbar>input{grid-column:1/-1!important}
  .deck-builder-count,.deck-builder-score,.card-shop-count{min-height:42px!important}
  .deck-builder-main{flex:1 1 auto!important;grid-template-rows:minmax(190px,1fr) minmax(170px,.9fr)!important;overflow:hidden!important}
  .deck-builder-pane{min-height:0!important;overflow:hidden!important}
  .deck-builder-pane-title{height:30px!important;min-height:30px!important;font-size:11px!important}
  .deck-builder-list{grid-template-columns:repeat(2,minmax(0,1fr))!important;align-content:start!important;max-height:none!important;min-height:0!important;overflow-y:auto!important;overflow-x:hidden!important;padding:7px!important;gap:7px!important;-webkit-overflow-scrolling:touch}
  .deck-builder-list.selected{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .deck-auto-ratio{grid-template-columns:repeat(2,minmax(0,1fr))!important;padding:7px!important;gap:5px!important}
  .deck-auto-ratio>b,.deck-auto-ratio>span{grid-column:1/-1!important}
  .deck-builder-summary{font-size:9px!important;padding:6px 8px!important}
  .deck-builder-actions{flex:0 0 auto!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;padding:7px!important;gap:6px!important;background:#0b1012!important}
  .deck-builder-actions .btn{min-height:44px!important;font-size:10px!important;padding:5px 3px!important}

  .card-shop-grid{flex:1 1 auto!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;align-content:start!important;overflow-y:auto!important;overflow-x:hidden!important;padding:8px!important;gap:8px!important;-webkit-overflow-scrolling:touch}
  .shop-card-entry,.shop-card{min-width:0!important;width:100%!important}
}

html.ui-mode-mobile-preview{height:auto!important;min-height:100%!important;overflow-x:hidden!important;overflow-y:auto!important;background:#020304!important}
body.ui-mode-mobile-preview{width:430px!important;max-width:430px!important;min-height:100vh!important;height:auto!important;margin:0 auto!important;overflow-x:hidden!important;overflow-y:auto!important;box-shadow:0 0 34px #000!important}
body.ui-mode-mobile-preview .mobile-game-header{width:430px!important;max-width:430px!important;margin:0 auto!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-game-header{left:50%!important;right:auto!important;transform:translateX(-50%)!important}
body.ui-mode-mobile-preview .bottom-hud{left:50%!important;right:auto!important;width:430px!important;max-width:430px!important;transform:translateX(-50%)!important}
body.ui-mode-mobile-preview .modal{left:50%!important;right:auto!important;width:430px!important;max-width:430px!important;transform:translateX(-50%)!important}

.mobile-brand-actions{display:flex!important;align-items:center!important;gap:6px!important}
.mobile-ui-switch-btn{display:grid!important;place-items:center;width:42px;height:32px;padding:0;border:1px solid #604621;border-radius:8px;background:#17130e;color:#e6c27d;font-size:11px;font-weight:950;line-height:1}
.mobile-ui-switch-btn.active{border-color:#d2a257;background:#3b2a17;color:#fff0c8}
.mobile-mobile-switch{letter-spacing:-.02em}

#hand.hand .card,
.mobile-hand-mount #hand.hand .card{box-sizing:border-box!important;overflow:hidden!important;align-content:stretch!important}
#hand.hand .card-title-area,
.mobile-hand-mount #hand.hand .card-title-area{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;align-items:start!important;column-gap:4px!important;padding:3px 5px!important;min-height:24px!important;height:auto!important}
#hand.hand .card-name-text,
.mobile-hand-mount #hand.hand .card-name-text{display:block!important;min-width:0!important;line-height:1.15!important;word-break:keep-all!important;overflow:hidden!important;text-overflow:ellipsis!important}
#hand.hand .card-title-grade,
.mobile-hand-mount #hand.hand .card-title-grade{display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;gap:1px!important;min-width:28px!important;padding:2px 4px!important;line-height:1!important}
#hand.hand .card-ready-label,
.mobile-hand-mount #hand.hand .card-ready-label{display:block!important;font-size:7px!important;font-weight:900!important;line-height:1!important;color:#fff6cb!important;letter-spacing:-.02em}
#hand.hand .cimg,
.mobile-hand-mount #hand.hand .cimg{position:relative!important;width:100%!important;overflow:hidden!important;display:block!important;background:#18202a!important}
#hand.hand .cimg img,
#hand.hand .cimg .default-art,
.mobile-hand-mount #hand.hand .cimg img,
.mobile-hand-mount #hand.hand .cimg .default-art{width:100%!important;height:100%!important;display:block!important;object-fit:cover!important;object-position:var(--img-x,50%) var(--img-y,50%)!important}
#hand.hand .cstats,
.mobile-hand-mount #hand.hand .cstats{display:block!important;width:100%!important;padding:0!important;overflow:hidden!important}
#hand.hand .card-stat-grid,
.mobile-hand-mount #hand.hand .card-stat-grid{width:100%!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:0!important}
#hand.hand .card-stat-cell,
.mobile-hand-mount #hand.hand .card-stat-cell{box-sizing:border-box!important;min-width:0!important;border-right:1px solid rgba(255,255,255,.16)!important}
#hand.hand .card-stat-cell:last-child,
.mobile-hand-mount #hand.hand .card-stat-cell:last-child{border-right:0!important}

.battlefield-layout .slot,
.battlefield-layout .unit,
.hq-field-slot,
.hq-field-slot .base-unit{box-sizing:border-box!important;min-width:0!important;max-width:100%!important;overflow:hidden!important}
.battlefield-layout .slot{padding:0!important}
.battlefield-layout .unit{display:grid!important;grid-template-rows:minmax(0,1fr) 22px!important;align-content:stretch!important}
.battlefield-layout .uimg{position:relative!important;display:block!important;width:100%!important;height:100%!important;min-height:0!important;overflow:hidden!important;background:#10161d!important}
.battlefield-layout .uimg img,
.battlefield-layout .uimg .default-art,
.hq-field-slot .base-unit-art img,
.hq-field-slot .base-unit-art .default-art{width:100%!important;height:100%!important;display:block!important;object-fit:cover!important;object-position:var(--img-x,50%) var(--img-y,50%)!important}
.battlefield-layout .unit-image-meta{left:0!important;right:0!important;top:0!important;border-radius:0!important;padding:2px 4px!important}
.battlefield-layout .stats{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:0!important;min-width:0!important}
.battlefield-layout .stats span{min-width:0!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
.hq-field-slot .base-unit{grid-template-rows:minmax(0,1fr) auto!important;padding:2px!important}
.hq-field-slot .base-unit-art{height:auto!important;min-height:0!important}
.hq-field-slot .base-unit-mini{min-width:0!important;overflow:hidden!important}
.hq-field-slot .base-unit-mini b,
.hq-field-slot .base-unit-mini span{display:block!important;min-width:0!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}

@media (max-width:850px){
  .mobile-combat-summary{height:50px!important}
  .mobile-combat-summary>div{font-size:9px!important;padding:0 2px!important}
  .mobile-combat-summary b{font-size:15px!important}
  .battle-hq .hq-advisor-slot{width:42%!important;min-width:112px!important;height:62px!important;min-height:62px!important;top:38px!important;right:6px!important}
  .battle-hq .hq-info-overlay{right:calc(42% + 12px)!important;max-width:none!important}
  .battle-hq .hq-advisor-summary{right:calc(42% + 12px)!important}
  .mobile-hand-mount #hand.hand .card{grid-template-rows:24px 92px 1fr!important}
  .mobile-hand-mount #hand.hand .cstats{min-height:46px!important}
  .mobile-hand-mount #hand.hand .card-stat-cell{min-height:32px!important}
  .battlefield-layout .slots,
  .battlefield-layout .slots.n4,
  .battlefield-layout .slots.n3,
  .battlefield-layout .slots.n2{align-items:stretch!important}
  .battlefield-layout .slot{height:106px!important;min-height:106px!important;max-height:106px!important}
  .battlefield-layout .unit{height:100%!important;grid-template-rows:minmax(0,1fr) 21px!important;border-radius:7px!important}
  .battlefield-layout .uimg{font-size:20px!important}
  .battlefield-layout .unit-image-meta .field-unit-name{font-size:8px!important}
  .battlefield-layout .unit-image-meta .field-grade{font-size:8px!important;min-width:18px!important;height:14px!important}
  .hq-defense-lane .hq-battlefield-grid,.enemy-hq-defense-lane .hq-battlefield-grid{height:96px!important;min-height:96px!important}
  .hq-defense-lane .hq-field-slot,.enemy-hq-defense-lane .hq-field-slot{height:92px!important;min-height:92px!important;max-height:92px!important}
}
body.ui-mode-mobile-preview .mobile-combat-summary{height:50px!important}
body.ui-mode-mobile-preview .mobile-combat-summary b{font-size:15px!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .card{grid-template-rows:24px 92px 1fr!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .cstats{min-height:46px!important}
body.ui-mode-mobile-preview .battlefield-layout .unit{grid-template-rows:minmax(0,1fr) 21px!important}
body.ui-mode-mobile-preview .battlefield-layout .unit-image-meta .field-unit-name{font-size:8px!important}
body.ui-mode-mobile-preview .battlefield-layout .unit-image-meta .field-grade{font-size:8px!important;min-width:18px!important;height:14px!important}
body.ui-mode-mobile-preview .hq-defense-lane .hq-field-slot,
body.ui-mode-mobile-preview .enemy-hq-defense-lane .hq-field-slot{height:92px!important;min-height:92px!important;max-height:92px!important}

#hand.hand .card-ready-label{display:none!important}

#hand.hand .card.actionable-card:not(.opening-hand-card)::before{
  content:'가능'!important;
  left:auto!important;
  right:5px!important;
  top:27px!important;
  min-width:28px!important;
  padding:2px 4px!important;
  border-radius:4px!important;
  text-align:center!important;
  font-size:8px!important;
  line-height:1.05!important;
  letter-spacing:0!important;
}

.battle-hq .hq-advisor-slot{
  right:58px!important;
  top:36px!important;
  width:112px!important;
  height:62px!important;
  min-height:62px!important;
  max-height:62px!important;
}
.hq-turn-box{
  position:absolute;
  right:6px;
  top:36px;
  z-index:13;
  width:46px;
  height:62px;
  min-height:62px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:3px;
  border:1px solid #8a6a3f;
  border-radius:5px;
  background:linear-gradient(180deg,#111820e8,#080c10e8);
  color:#dfceb0;
  box-sizing:border-box;
  font-size:10px;
  font-weight:900;
}
.hq-turn-box b{font-size:18px!important;color:#ffe09d!important;line-height:1!important}
.hq-turn-box span{font-size:9px!important;color:#dfceb0!important;line-height:1!important}
.ally-hq-turn{right:6px!important;top:36px!important;bottom:auto!important;width:46px!important;height:62px!important}

@media (max-width:850px){
  :root{
    --mobile-action-height:58px;
    --mobile-hand-float-height:174px;
    --mobile-hq-float-height:104px;
    --mobile-bottom-dock-height:calc(var(--mobile-action-height) + var(--mobile-hand-float-height) + var(--mobile-hq-float-height));
  }
  
  .battlefield-layout .slots.n4,
  .battlefield-layout .slots.n3,
  .battlefield-layout .slots.n2{
    display:flex!important;
    align-items:stretch!important;
    justify-content:center!important;
    width:100%!important;
    padding-inline:0!important;
    gap:4px!important;
  }
  .battlefield-layout .slots.n4>.slot,
  .battlefield-layout .slots.n3>.slot,
  .battlefield-layout .slots.n2>.slot{
    flex:0 0 calc((100% - 12px)/4)!important;
    width:calc((100% - 12px)/4)!important;
    min-width:0!important;
    max-width:calc((100% - 12px)/4)!important;
  }
  
  body:not(.prebattle),
  body.mobile-battle-active{
    padding-bottom:calc(var(--mobile-bottom-dock-height) + env(safe-area-inset-bottom,0px) + 8px)!important;
  }
  body:not(.prebattle) .app{
    padding-bottom:calc(var(--mobile-bottom-dock-height) + env(safe-area-inset-bottom,0px) + 8px)!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount{
    display:block!important;
    position:fixed!important;
    left:0!important;
    right:0!important;
    bottom:calc(var(--mobile-action-height) + var(--mobile-hand-float-height) + env(safe-area-inset-bottom,0px))!important;
    z-index:88!important;
    width:100%!important;
    height:var(--mobile-hq-float-height)!important;
    min-height:var(--mobile-hq-float-height)!important;
    max-height:var(--mobile-hq-float-height)!important;
    margin:0!important;
    padding:4px!important;
    overflow:hidden!important;
    border-top:1px solid #8a5b28!important;
    background:linear-gradient(180deg,#182a3af7,#071018fa)!important;
    box-shadow:0 -8px 18px #000b!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount .ally-hq-row{
    display:block!important;
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    margin:0!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount .hq-title{font-size:10px!important;padding:2px 6px!important}
  body:not(.prebattle) .mobile-ally-hq-mount .hq-subtitle,
  body:not(.prebattle) .mobile-ally-hq-mount .hptxt{display:none!important}
  body:not(.prebattle) .mobile-ally-hq-mount .hq-info-overlay{
    left:6px!important;
    right:180px!important;
    top:30px!important;
    max-width:none!important;
    gap:2px!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount .hq-stat-chip{padding:2px 3px!important;font-size:7px!important}
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{
    right:55px!important;
    top:29px!important;
    width:116px!important;
    height:62px!important;
    min-height:62px!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount .hq-turn-box{
    right:5px!important;
    top:29px!important;
    width:44px!important;
    height:62px!important;
    min-height:62px!important;
  }
  body:not(.prebattle) .mobile-hand-mount{
    display:block!important;
    position:fixed!important;
    left:0!important;
    right:0!important;
    bottom:calc(var(--mobile-action-height) + env(safe-area-inset-bottom,0px))!important;
    z-index:89!important;
    width:100%!important;
    height:var(--mobile-hand-float-height)!important;
    min-height:var(--mobile-hand-float-height)!important;
    max-height:var(--mobile-hand-float-height)!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
    background:#080c0ef8!important;
    border-top:1px solid #6d522e!important;
    box-shadow:0 -5px 14px #000a!important;
  }
  body:not(.prebattle) .mobile-hand-mount .right-hand-section{
    display:flex!important;
    flex-direction:column!important;
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .mobile-hand-mount .right-hand-section>.ornate-title{
    flex:0 0 27px!important;
    height:27px!important;
    min-height:27px!important;
  }
  body:not(.prebattle) .mobile-hand-mount .handbox{
    flex:1 1 auto!important;
    min-height:0!important;
    height:auto!important;
    padding:3px 5px 5px!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .mobile-hand-mount .handhead{display:none!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand{
    width:100%!important;
    height:142px!important;
    min-height:142px!important;
    max-height:142px!important;
    padding:1px 2px 4px!important;
    gap:6px!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    flex:0 0 104px!important;
    width:104px!important;
    height:136px!important;
    min-height:136px!important;
    max-height:136px!important;
    grid-template-rows:23px 74px 39px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .cimg{
    height:74px!important;
    min-height:74px!important;
    max-height:74px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .cstats{
    height:39px!important;
    min-height:39px!important;
    max-height:39px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-cell{
    min-height:39px!important;
    height:39px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card.actionable-card:not(.opening-hand-card)::before{
    right:4px!important;
    top:25px!important;
    min-width:25px!important;
    font-size:7px!important;
  }
  body:not(.prebattle) .bottom-hud{
    bottom:0!important;
    height:var(--mobile-action-height)!important;
    min-height:var(--mobile-action-height)!important;
    padding-bottom:env(safe-area-inset-bottom,0px)!important;
    z-index:92!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle){
  --mobile-action-height:58px;
  --mobile-hand-float-height:174px;
  --mobile-hq-float-height:104px;
  --mobile-bottom-dock-height:calc(var(--mobile-action-height) + var(--mobile-hand-float-height) + var(--mobile-hq-float-height));
  padding-bottom:calc(var(--mobile-bottom-dock-height) + 8px)!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .app{padding-bottom:calc(var(--mobile-bottom-dock-height) + 8px)!important}
body.ui-mode-mobile-preview .battlefield-layout .slots.n4,
body.ui-mode-mobile-preview .battlefield-layout .slots.n3,
body.ui-mode-mobile-preview .battlefield-layout .slots.n2{display:flex!important;align-items:stretch!important;justify-content:center!important;padding-inline:0!important;gap:4px!important}
body.ui-mode-mobile-preview .battlefield-layout .slots.n4>.slot,
body.ui-mode-mobile-preview .battlefield-layout .slots.n3>.slot,
body.ui-mode-mobile-preview .battlefield-layout .slots.n2>.slot{flex:0 0 calc((100% - 12px)/4)!important;width:calc((100% - 12px)/4)!important;max-width:calc((100% - 12px)/4)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{position:fixed!important;left:calc(50vw - 215px)!important;right:auto!important;bottom:calc(var(--mobile-action-height) + var(--mobile-hand-float-height))!important;width:430px!important;height:var(--mobile-hq-float-height)!important;min-height:var(--mobile-hq-float-height)!important;max-height:var(--mobile-hq-float-height)!important;z-index:88!important;padding:4px!important;overflow:hidden!important;background:linear-gradient(180deg,#182a3af7,#071018fa)!important;border-top:1px solid #8a5b28!important;box-shadow:0 -8px 18px #000b!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .ally-hq-row,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq{height:100%!important;min-height:0!important;max-height:none!important;margin:0!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-subtitle,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hptxt{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-info-overlay{left:6px!important;right:180px!important;top:30px!important;max-width:none!important;gap:2px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{right:55px!important;top:29px!important;width:116px!important;height:62px!important;min-height:62px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-turn-box{right:5px!important;top:29px!important;width:44px!important;height:62px!important;min-height:62px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount{position:fixed!important;left:calc(50vw - 215px)!important;right:auto!important;bottom:var(--mobile-action-height)!important;width:430px!important;height:var(--mobile-hand-float-height)!important;min-height:var(--mobile-hand-float-height)!important;max-height:var(--mobile-hand-float-height)!important;z-index:89!important;overflow:hidden!important;background:#080c0ef8!important;border-top:1px solid #6d522e!important;box-shadow:0 -5px 14px #000a!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .right-hand-section{height:100%!important;min-height:0!important;overflow:hidden!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .right-hand-section>.ornate-title{height:27px!important;min-height:27px!important;flex:0 0 27px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .handbox{min-height:0!important;padding:3px 5px 5px!important;overflow:hidden!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .handhead{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{height:142px!important;min-height:142px!important;max-height:142px!important;padding:1px 2px 4px!important;gap:6px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{flex:0 0 104px!important;width:104px!important;height:136px!important;min-height:136px!important;max-height:136px!important;grid-template-rows:23px 74px 39px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .cimg{height:74px!important;min-height:74px!important;max-height:74px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .cstats{height:39px!important;min-height:39px!important;max-height:39px!important}

.mobile-mobile-switch{width:54px!important;font-size:10px!important}

.hq-defense-lane[hidden],
.hq-defense-lane.inactive:not(.active),
.hq-battlefield-grid[hidden],
.hq-battlefield-grid.inactive:not(.active){
  display:none!important;
  visibility:hidden!important;
  height:0!important;
  min-height:0!important;
  max-height:0!important;
  margin:0!important;
  padding:0!important;
  overflow:hidden!important;
}
.hq-defense-lane.active{visibility:visible!important}

.battle-hq .hq-advisor-slot{
  box-sizing:border-box!important;
  right:56px!important;
  width:112px!important;
  max-width:112px!important;
  overflow:hidden!important;
}
.battle-hq .hq-turn-box{
  box-sizing:border-box!important;
  right:6px!important;
  width:44px!important;
  max-width:44px!important;
  overflow:hidden!important;
}
.battle-hq .hq-advisor-slot + .hq-turn-box{margin-left:6px!important}
.mobile-hq-turn-inline{display:none}

@media (max-width:850px){
  :root{
    --mobile-action-height:58px;
    --mobile-field-card-width:calc((100vw - 22px)/4);
    --mobile-field-card-height:106px;
    --mobile-hand-float-height:136px;
    --mobile-hq-float-height:132px;
    --mobile-bottom-dock-height:calc(var(--mobile-action-height) + var(--mobile-hand-float-height) + var(--mobile-hq-float-height));
  }

  
  .battle-hq .hq-turn-box{display:none!important}
  .mobile-hq-turn-inline{
    display:inline-flex!important;
    align-items:center!important;
    gap:1px!important;
    margin-left:3px!important;
    padding-left:4px!important;
    border-left:1px solid rgba(255,255,255,.22)!important;
    color:#ffe1a0!important;
    font-size:8px!important;
    line-height:1!important;
    white-space:nowrap!important;
  }
  .mobile-hq-turn-inline b{font-size:9px!important;color:#fff3c7!important}

  
  body:not(.prebattle) .enemy-hq-row{
    display:block!important;
    position:relative!important;
    inset:auto!important;
    z-index:2!important;
    width:100%!important;
    height:var(--mobile-hq-float-height)!important;
    min-height:var(--mobile-hq-float-height)!important;
    max-height:var(--mobile-hq-float-height)!important;
    margin:0!important;
    padding:4px!important;
    background:linear-gradient(180deg,#301b1bf5,#130909fa)!important;
    border-bottom:1px solid #8a5b28!important;
    box-shadow:none!important;
  }

  
  body:not(.prebattle) .enemy-hq-row .battle-hq,
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq{
    display:block!important;
    position:relative!important;
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
    border:1px solid #8b6a3c!important;
    border-radius:9px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-title,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-title{
    top:4px!important;
    left:5px!important;
    max-width:calc(100% - 150px)!important;
    padding:2px 6px!important;
    font-size:10px!important;
    line-height:16px!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-subtitle,
  body:not(.prebattle) .enemy-hq-row .hptxt,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-subtitle,
  body:not(.prebattle) .mobile-ally-hq-mount .hptxt{display:none!important}
  body:not(.prebattle) .enemy-hq-row .hq-info-overlay,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-info-overlay{
    position:absolute!important;
    left:6px!important;
    right:146px!important;
    top:31px!important;
    width:auto!important;
    max-width:none!important;
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:3px!important;
    transform:none!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-stat-chip,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-stat-chip{
    min-width:0!important;
    max-width:100%!important;
    height:25px!important;
    padding:2px 4px!important;
    gap:2px!important;
    font-size:7px!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-stat-chip b,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-stat-chip b{font-size:9px!important;white-space:nowrap!important}
  body:not(.prebattle) .enemy-hq-row .hq-stat-chip.skill,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-stat-chip.skill{display:none!important}

  
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{
    display:block!important;
    position:absolute!important;
    right:7px!important;
    top:31px!important;
    width:132px!important;
    min-width:132px!important;
    max-width:132px!important;
    height:91px!important;
    min-height:91px!important;
    max-height:91px!important;
    margin:0!important;
    padding:3px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
    border-radius:6px!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot .advisor-card,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot .advisor-card{
    width:100%!important;
    height:100%!important;
    min-width:0!important;
    min-height:0!important;
    overflow:hidden!important;
  }

  
  body:not(.prebattle) .mobile-ally-hq-mount{
    position:fixed!important;
    left:0!important;
    right:0!important;
    bottom:calc(var(--mobile-action-height) + var(--mobile-hand-float-height) + env(safe-area-inset-bottom,0px))!important;
    z-index:88!important;
    width:100%!important;
    height:var(--mobile-hq-float-height)!important;
    min-height:var(--mobile-hq-float-height)!important;
    max-height:var(--mobile-hq-float-height)!important;
    padding:4px!important;
    overflow:hidden!important;
  }

  
  body:not(.prebattle) .mobile-hand-mount{
    height:var(--mobile-hand-float-height)!important;
    min-height:var(--mobile-hand-float-height)!important;
    max-height:var(--mobile-hand-float-height)!important;
  }
  body:not(.prebattle) .mobile-hand-mount .right-hand-section>.ornate-title{
    flex:0 0 26px!important;
    height:26px!important;
    min-height:26px!important;
  }
  body:not(.prebattle) .mobile-hand-mount .handbox{padding:2px 5px 3px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand{
    height:107px!important;
    min-height:107px!important;
    max-height:107px!important;
    gap:4px!important;
    padding:0 0 1px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    position:relative!important;
    flex:0 0 var(--mobile-field-card-width)!important;
    width:var(--mobile-field-card-width)!important;
    min-width:var(--mobile-field-card-width)!important;
    max-width:var(--mobile-field-card-width)!important;
    height:var(--mobile-field-card-height)!important;
    min-height:var(--mobile-field-card-height)!important;
    max-height:var(--mobile-field-card-height)!important;
    display:grid!important;
    grid-template-rows:20px 64px 22px!important;
    row-gap:0!important;
    transform:none!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-title-area{
    position:relative!important;
    inset:auto!important;
    z-index:3!important;
    width:100%!important;
    height:20px!important;
    min-height:20px!important;
    max-height:20px!important;
    padding:2px 3px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-name-text{
    font-size:8px!important;
    line-height:16px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .cimg{
    position:relative!important;
    inset:auto!important;
    z-index:1!important;
    width:100%!important;
    height:64px!important;
    min-height:64px!important;
    max-height:64px!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .cimg img,
  body:not(.prebattle) .mobile-hand-mount #hand.hand .cimg .default-art{
    width:100%!important;
    height:100%!important;
    display:block!important;
    object-fit:cover!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .cstats,
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-grid,
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-cell{
    height:22px!important;
    min-height:22px!important;
    max-height:22px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-cell b{font-size:9px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card.actionable-card:not(.opening-hand-card)::before{
    top:22px!important;
    right:3px!important;
    min-width:22px!important;
    padding:1px 3px!important;
    font-size:7px!important;
  }

  body:not(.prebattle),
  body:not(.prebattle) .app{
    padding-bottom:calc(var(--mobile-bottom-dock-height) + env(safe-area-inset-bottom,0px) + 8px)!important;
  }
}

@media (max-width:850px) and (orientation:landscape){
  :root{
    --mobile-field-card-height:90px;
    --mobile-hand-float-height:116px;
    --mobile-hq-float-height:116px;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand{height:91px!important;min-height:91px!important;max-height:91px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card{grid-template-rows:18px 54px 18px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-title-area{height:18px!important;min-height:18px!important;max-height:18px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand .cimg{height:54px!important;min-height:54px!important;max-height:54px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand .cstats,
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-grid,
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-cell{height:18px!important;min-height:18px!important;max-height:18px!important}
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{height:76px!important;min-height:76px!important;max-height:76px!important}
}

body.ui-mode-mobile-preview:not(.prebattle){
  --mobile-action-height:58px;
  --mobile-field-card-width:102px;
  --mobile-field-card-height:106px;
  --mobile-hand-float-height:136px;
  --mobile-hq-float-height:132px;
  --mobile-bottom-dock-height:326px;
  padding-bottom:334px!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .app{padding-bottom:334px!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row{position:relative!important;inset:auto!important;height:132px!important;min-height:132px!important;max-height:132px!important;padding:4px!important;background:linear-gradient(180deg,#301b1bf5,#130909fa)!important;border-bottom:1px solid #8a5b28!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq{height:100%!important;min-height:0!important;max-height:none!important;border:1px solid #8b6a3c!important;border-radius:9px!important;overflow:hidden!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-turn-box,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-turn-box{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hq-turn-inline{display:inline-flex!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-subtitle,
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hptxt,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-subtitle,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hptxt{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-info-overlay,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-info-overlay{left:6px!important;right:146px!important;top:31px!important;width:auto!important;max-width:none!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:3px!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{right:7px!important;top:31px!important;width:132px!important;min-width:132px!important;max-width:132px!important;height:91px!important;min-height:91px!important;max-height:91px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{height:132px!important;min-height:132px!important;max-height:132px!important;bottom:194px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount{height:136px!important;min-height:136px!important;max-height:136px!important;bottom:58px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{height:107px!important;min-height:107px!important;max-height:107px!important;gap:4px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{flex:0 0 102px!important;width:102px!important;min-width:102px!important;max-width:102px!important;height:106px!important;min-height:106px!important;max-height:106px!important;grid-template-rows:20px 64px 22px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card-title-area{position:relative!important;inset:auto!important;height:20px!important;min-height:20px!important;max-height:20px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .cimg{height:64px!important;min-height:64px!important;max-height:64px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .cstats,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-grid,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-cell{height:22px!important;min-height:22px!important;max-height:22px!important}

@media (max-width:850px){
  :root{--mobile-field-card-width:calc((100vw - 32px)/4)}
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{
    transform:none!important;
    translate:none!important;
    inset:31px 7px auto auto!important;
  }
}
body.ui-mode-mobile-preview:not(.prebattle){--mobile-field-card-width:99.5px}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{
  transform:none!important;
  translate:none!important;
  inset:31px 7px auto auto!important;
}

:root{
  --faction-wei-border:#45b9ff;
  --faction-shu-border:#51d775;
  --faction-wu-border:#ff6666;
  --faction-other-border:#aeb6c0;
}

.battlefield-layout .unit.wei,
.hq-field-slot .base-unit.wei,
#hand.hand .card.wei{
  border-color:var(--faction-wei-border)!important;
  box-shadow:inset 0 0 0 1px #164f86,0 0 0 1px #8bdbff,0 2px 8px #0009!important;
}
.battlefield-layout .unit.shu,
.hq-field-slot .base-unit.shu,
#hand.hand .card.shu{
  border-color:var(--faction-shu-border)!important;
  box-shadow:inset 0 0 0 1px #1e6a35,0 0 0 1px #a0f0af,0 2px 8px #0009!important;
}
.battlefield-layout .unit.wu,
.hq-field-slot .base-unit.wu,
#hand.hand .card.wu{
  border-color:var(--faction-wu-border)!important;
  box-shadow:inset 0 0 0 1px #7f2424,0 0 0 1px #ffaaaa,0 2px 8px #0009!important;
}
.battlefield-layout .unit.other,
.hq-field-slot .base-unit.other,
#hand.hand .card.other,
#hand.hand .card.item,
#hand.hand .card.tactic{
  border-color:var(--faction-other-border)!important;
  box-shadow:inset 0 0 0 1px #4a515a,0 0 0 1px #e0e4e9,0 2px 8px #0009!important;
}

@media (max-width:850px){
  :root{
    --mobile-field-card-width:calc((100vw - 32px)/4);
    --mobile-field-card-height:106px;
    --mobile-hq-float-height:138px;
    --mobile-hand-float-height:136px;
    --mobile-bottom-dock-height:calc(var(--mobile-action-height) + var(--mobile-hand-float-height) + var(--mobile-hq-float-height));
  }

  
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4,
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3,
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{
    display:grid!important;
    width:100%!important;
    height:var(--mobile-field-card-height)!important;
    min-height:var(--mobile-field-card-height)!important;
    max-height:var(--mobile-field-card-height)!important;
    gap:4px!important;
    padding-inline:0!important;
    justify-content:center!important;
    align-items:stretch!important;
  }
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4{grid-template-columns:repeat(4,var(--mobile-field-card-width))!important}
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3{grid-template-columns:repeat(3,var(--mobile-field-card-width))!important}
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{grid-template-columns:repeat(2,var(--mobile-field-card-width))!important}
  .battlefield-layout .lane:not(.hq-defense-lane) .slot{
    width:var(--mobile-field-card-width)!important;
    min-width:var(--mobile-field-card-width)!important;
    max-width:var(--mobile-field-card-width)!important;
    height:var(--mobile-field-card-height)!important;
    min-height:var(--mobile-field-card-height)!important;
    max-height:var(--mobile-field-card-height)!important;
  }

  
  body:not(.prebattle) .mobile-hand-mount #hand.hand{
    display:flex!important;
    width:100%!important;
    overflow:hidden!important;
    justify-content:flex-start!important;
    align-items:stretch!important;
    gap:4px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    flex:0 0 var(--mobile-field-card-width)!important;
    width:var(--mobile-field-card-width)!important;
    min-width:var(--mobile-field-card-width)!important;
    max-width:var(--mobile-field-card-width)!important;
    height:var(--mobile-field-card-height)!important;
    min-height:var(--mobile-field-card-height)!important;
    max-height:var(--mobile-field-card-height)!important;
  }

  
  body:not(.prebattle) .mobile-hand-mount .hand-title-paged{
    display:grid!important;
    grid-template-columns:32px minmax(0,1fr) 32px!important;
    align-items:center!important;
    width:100%!important;
    gap:3px!important;
  }
  body:not(.prebattle) .mobile-hand-mount #handPrevBtn{grid-column:1!important;grid-row:1!important}
  body:not(.prebattle) .mobile-hand-mount .hand-title-label{grid-column:2!important;grid-row:1!important;text-align:center!important}
  body:not(.prebattle) .mobile-hand-mount #handNextBtn{grid-column:3!important;grid-row:1!important}
  body:not(.prebattle) .mobile-hand-mount .hand-title-page{display:none!important}
  body:not(.prebattle) .mobile-hand-mount .hand-title-arrow{
    display:grid!important;
    place-items:center!important;
    width:30px!important;
    min-width:30px!important;
    height:23px!important;
    padding:0!important;
    border:1px solid #8e6b38!important;
    border-radius:5px!important;
    background:#17110b!important;
    color:#ffe2a7!important;
    font-size:20px!important;
    line-height:1!important;
  }
  body:not(.prebattle) .mobile-hand-mount .hand-title-arrow[hidden]{visibility:hidden!important}

  
  body:not(.prebattle) .enemy-hq-row,
  body:not(.prebattle) .mobile-ally-hq-mount{
    box-sizing:border-box!important;
    width:100%!important;
    height:var(--mobile-hq-float-height)!important;
    min-height:var(--mobile-hq-float-height)!important;
    max-height:var(--mobile-hq-float-height)!important;
    padding:4px!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .enemy-hq-row .battle-hq,
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq{
    box-sizing:border-box!important;
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
    border-radius:9px!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-title,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-title{
    max-width:calc(100% - var(--mobile-field-card-width) - 18px)!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-info-overlay,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-info-overlay{
    right:calc(var(--mobile-field-card-width) + 14px)!important;
  }

  
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{
    inset:27px 6px auto auto!important;
    width:var(--mobile-field-card-width)!important;
    min-width:var(--mobile-field-card-width)!important;
    max-width:var(--mobile-field-card-width)!important;
    height:var(--mobile-field-card-height)!important;
    min-height:var(--mobile-field-card-height)!important;
    max-height:var(--mobile-field-card-height)!important;
    padding:2px!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot .advisor-card,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot .advisor-card,
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot .advisor-image-only,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot .advisor-image-only,
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot .advisor-portrait,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot .advisor-portrait{
    width:100%!important;
    height:100%!important;
    min-width:0!important;
    min-height:0!important;
    max-width:none!important;
    max-height:none!important;
    overflow:hidden!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle){
  --mobile-field-card-width:99.5px;
  --mobile-field-card-height:106px;
  --mobile-hq-float-height:138px;
  --mobile-hand-float-height:136px;
  --mobile-bottom-dock-height:332px;
}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4{grid-template-columns:repeat(4,var(--mobile-field-card-width))!important;justify-content:center!important;padding-inline:0!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3{grid-template-columns:repeat(3,var(--mobile-field-card-width))!important;justify-content:center!important;padding-inline:0!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{grid-template-columns:repeat(2,var(--mobile-field-card-width))!important;justify-content:center!important;padding-inline:0!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slot{width:var(--mobile-field-card-width)!important;min-width:var(--mobile-field-card-width)!important;max-width:var(--mobile-field-card-width)!important;height:var(--mobile-field-card-height)!important;min-height:var(--mobile-field-card-height)!important;max-height:var(--mobile-field-card-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{overflow:hidden!important;justify-content:flex-start!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{flex:0 0 var(--mobile-field-card-width)!important;width:var(--mobile-field-card-width)!important;min-width:var(--mobile-field-card-width)!important;max-width:var(--mobile-field-card-width)!important;height:var(--mobile-field-card-height)!important;min-height:var(--mobile-field-card-height)!important;max-height:var(--mobile-field-card-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .hand-title-paged{display:grid!important;grid-template-columns:32px minmax(0,1fr) 32px!important;align-items:center!important;width:100%!important;gap:3px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #handPrevBtn{grid-column:1!important;grid-row:1!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .hand-title-label{grid-column:2!important;grid-row:1!important;text-align:center!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #handNextBtn{grid-column:3!important;grid-row:1!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .hand-title-page{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{height:var(--mobile-hq-float-height)!important;min-height:var(--mobile-hq-float-height)!important;max-height:var(--mobile-hq-float-height)!important;padding:4px!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{inset:27px 6px auto auto!important;width:var(--mobile-field-card-width)!important;min-width:var(--mobile-field-card-width)!important;max-width:var(--mobile-field-card-width)!important;height:var(--mobile-field-card-height)!important;min-height:var(--mobile-field-card-height)!important;max-height:var(--mobile-field-card-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-info-overlay,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-info-overlay{right:calc(var(--mobile-field-card-width) + 14px)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{bottom:194px!important}

:root{
  --tcg-card-head:24px;
  --tcg-card-stat:28px;
  --tcg-card-radius:8px;
}

#hand.hand .card,
.battlefield-layout .unit{
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-rows:var(--tcg-card-head) minmax(0,1fr) var(--tcg-card-stat)!important;
  align-content:stretch!important;
  overflow:hidden!important;
  border-width:2px!important;
  border-style:solid!important;
  border-radius:var(--tcg-card-radius)!important;
  background:#11171d!important;
}
#hand.hand .card .card-title-area,
.battlefield-layout .unit .card-title-area{
  position:relative!important;
  inset:auto!important;
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto!important;
  align-items:center!important;
  gap:4px!important;
  width:100%!important;
  height:var(--tcg-card-head)!important;
  min-height:var(--tcg-card-head)!important;
  max-height:var(--tcg-card-head)!important;
  padding:3px 5px!important;
  border-bottom:1px solid rgba(255,255,255,.16)!important;
  background:linear-gradient(180deg,#2b3440,#141a21)!important;
  color:#f5f7fa!important;
}
#hand.hand .card .card-name-text,
.battlefield-layout .unit .field-unit-name{
  min-width:0!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  white-space:nowrap!important;
  font-size:11px!important;
  font-weight:950!important;
  line-height:1!important;
  color:#f7f8fa!important;
  text-shadow:0 1px 2px #000!important;
}
#hand.hand .card .card-title-grade,
.battlefield-layout .unit .field-grade{
  position:static!important;
  flex:0 0 auto!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-width:24px!important;
  height:16px!important;
  padding:0 4px!important;
  border-radius:3px!important;
  font-size:8px!important;
  font-weight:1000!important;
  line-height:1!important;
}
#hand.hand .card .cimg,
.battlefield-layout .unit .uimg{
  position:relative!important;
  inset:auto!important;
  box-sizing:border-box!important;
  display:block!important;
  width:100%!important;
  height:100%!important;
  min-height:0!important;
  max-height:none!important;
  overflow:hidden!important;
  background:#0d1218!important;
  border:0!important;
}
#hand.hand .card .cimg img,
#hand.hand .card .cimg .default-art,
.battlefield-layout .unit .uimg img,
.battlefield-layout .unit .uimg .default-art{
  width:100%!important;
  height:100%!important;
  min-width:100%!important;
  min-height:100%!important;
  display:block!important;
  object-fit:cover!important;
  object-position:var(--img-x,50%) var(--img-y,50%)!important;
}
#hand.hand .card .cstats,
.battlefield-layout .unit .stats{
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:0!important;
  width:100%!important;
  height:var(--tcg-card-stat)!important;
  min-height:var(--tcg-card-stat)!important;
  max-height:var(--tcg-card-stat)!important;
  padding:0!important;
  border-top:1px solid rgba(255,255,255,.12)!important;
  background:#131a21!important;
}
#hand.hand .card .card-stat-grid{
  display:contents!important;
}
#hand.hand .card .card-stat-cell,
.battlefield-layout .unit .stats span{
  box-sizing:border-box!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-width:0!important;
  height:100%!important;
  padding:0 2px!important;
  border:0!important;
  border-right:1px solid rgba(255,255,255,.18)!important;
  background:rgba(255,255,255,.03)!important;
  color:#eef3f8!important;
  font-size:11px!important;
  font-weight:950!important;
  line-height:1!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}
#hand.hand .card .card-stat-cell:last-child,
.battlefield-layout .unit .stats span:last-child{border-right:0!important}

#hand.hand .card.wei .card-title-area,
.battlefield-layout .unit.wei .card-title-area{background:linear-gradient(180deg,#3376bd,#173d69)!important}
#hand.hand .card.shu .card-title-area,
.battlefield-layout .unit.shu .card-title-area{background:linear-gradient(180deg,#419552,#225832)!important}
#hand.hand .card.wu .card-title-area,
.battlefield-layout .unit.wu .card-title-area{background:linear-gradient(180deg,#b94e4e,#682929)!important}
#hand.hand .card.other .card-title-area,
#hand.hand .card.item .card-title-area,
#hand.hand .card.tactic .card-title-area,
.battlefield-layout .unit.other .card-title-area{background:linear-gradient(180deg,#68717c,#3c434b)!important}

.battlefield-layout .unit-image-meta{display:none!important}

@media (max-width:850px){
  :root{
    --mobile-play-width:min(calc(100vw - 12px),430px);
    --mobile-card-gap:4px;
    --mobile-card-width:calc((var(--mobile-play-width) - 20px)/4);
    --mobile-card-height:calc(var(--mobile-card-width) * 1.30);
    --tcg-card-head:21px;
    --tcg-card-stat:22px;
  }

  
  body:not(.prebattle) .boardwrap,
  body:not(.prebattle) .battlefield-layout,
  body:not(.prebattle) .battlefield-layout>.board,
  body:not(.prebattle) .enemy-hq-row,
  body:not(.prebattle) .mobile-ally-hq-mount,
  body:not(.prebattle) .mobile-hand-mount .right-hand-section{
    box-sizing:border-box!important;
    width:var(--mobile-play-width)!important;
    min-width:var(--mobile-play-width)!important;
    max-width:var(--mobile-play-width)!important;
    margin-left:auto!important;
    margin-right:auto!important;
  }
  body:not(.prebattle) .boardwrap{padding:4px!important;overflow:visible!important}
  body:not(.prebattle) .battlefield-layout>.board{padding:0!important;gap:4px!important}

  
  .battlefield-layout .lane:not(.hq-defense-lane)>.label{display:none!important}

  
  .battlefield-layout .lane:not(.hq-defense-lane){
    box-sizing:border-box!important;
    width:100%!important;
    min-width:100%!important;
    max-width:100%!important;
    height:calc(var(--mobile-card-height) + 8px)!important;
    min-height:calc(var(--mobile-card-height) + 8px)!important;
    max-height:calc(var(--mobile-card-height) + 8px)!important;
    margin:0!important;
    padding:4px!important;
    overflow:hidden!important;
    border-radius:8px!important;
  }
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4,
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3,
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{
    box-sizing:border-box!important;
    display:grid!important;
    width:100%!important;
    min-width:100%!important;
    max-width:100%!important;
    height:var(--mobile-card-height)!important;
    min-height:var(--mobile-card-height)!important;
    max-height:var(--mobile-card-height)!important;
    margin:0!important;
    padding:0!important;
    gap:var(--mobile-card-gap)!important;
    align-items:stretch!important;
    justify-content:center!important;
  }
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4{grid-template-columns:repeat(4,var(--mobile-card-width))!important}
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3{grid-template-columns:repeat(3,var(--mobile-card-width))!important}
  .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{grid-template-columns:repeat(2,var(--mobile-card-width))!important}
  .battlefield-layout .lane:not(.hq-defense-lane) .slot,
  .battlefield-layout .lane:not(.hq-defense-lane) .unit{
    box-sizing:border-box!important;
    width:var(--mobile-card-width)!important;
    min-width:var(--mobile-card-width)!important;
    max-width:var(--mobile-card-width)!important;
    height:var(--mobile-card-height)!important;
    min-height:var(--mobile-card-height)!important;
    max-height:var(--mobile-card-height)!important;
    margin:0!important;
  }

  
  body:not(.prebattle) .mobile-hand-mount{width:100%!important;padding:0!important}
  body:not(.prebattle) .mobile-hand-mount .right-hand-section{padding:0!important}
  body:not(.prebattle) .mobile-hand-mount .handbox{box-sizing:border-box!important;width:100%!important;padding:4px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand{
    box-sizing:border-box!important;
    width:100%!important;
    min-width:100%!important;
    max-width:100%!important;
    height:var(--mobile-card-height)!important;
    min-height:var(--mobile-card-height)!important;
    max-height:var(--mobile-card-height)!important;
    padding:0!important;
    gap:var(--mobile-card-gap)!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    flex:0 0 var(--mobile-card-width)!important;
    width:var(--mobile-card-width)!important;
    min-width:var(--mobile-card-width)!important;
    max-width:var(--mobile-card-width)!important;
    height:var(--mobile-card-height)!important;
    min-height:var(--mobile-card-height)!important;
    max-height:var(--mobile-card-height)!important;
  }

  #hand.hand .card .card-name-text,
  .battlefield-layout .unit .field-unit-name{font-size:9px!important}
  #hand.hand .card .card-title-grade,
  .battlefield-layout .unit .field-grade{min-width:20px!important;height:14px!important;font-size:7px!important;padding:0 3px!important}
  #hand.hand .card .card-stat-cell,
  .battlefield-layout .unit .stats span{font-size:9px!important}
}

body.ui-mode-mobile-preview:not(.prebattle){--mobile-play-width:418px;--mobile-card-gap:4px;--mobile-card-width:calc((var(--mobile-play-width) - 20px)/4);--mobile-card-height:calc(var(--mobile-card-width) * 1.30);--tcg-card-head:21px;--tcg-card-stat:22px}
body.ui-mode-mobile-preview:not(.prebattle) .boardwrap,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board,
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .right-hand-section{box-sizing:border-box!important;width:var(--mobile-play-width)!important;min-width:var(--mobile-play-width)!important;max-width:var(--mobile-play-width)!important;margin-left:auto!important;margin-right:auto!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane)>.label{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane){box-sizing:border-box!important;width:100%!important;height:calc(var(--mobile-card-height) + 8px)!important;min-height:calc(var(--mobile-card-height) + 8px)!important;max-height:calc(var(--mobile-card-height) + 8px)!important;margin:0!important;padding:4px!important;overflow:hidden!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{display:grid!important;width:100%!important;height:var(--mobile-card-height)!important;min-height:var(--mobile-card-height)!important;max-height:var(--mobile-card-height)!important;margin:0!important;padding:0!important;gap:var(--mobile-card-gap)!important;align-items:stretch!important;justify-content:center!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4{grid-template-columns:repeat(4,var(--mobile-card-width))!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3{grid-template-columns:repeat(3,var(--mobile-card-width))!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{grid-template-columns:repeat(2,var(--mobile-card-width))!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slot,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .unit,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{width:var(--mobile-card-width)!important;min-width:var(--mobile-card-width)!important;max-width:var(--mobile-card-width)!important;height:var(--mobile-card-height)!important;min-height:var(--mobile-card-height)!important;max-height:var(--mobile-card-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{width:100%!important;height:var(--mobile-card-height)!important;min-height:var(--mobile-card-height)!important;max-height:var(--mobile-card-height)!important;padding:0!important;gap:var(--mobile-card-gap)!important;overflow:hidden!important}

.mobile-hq-actions{display:none}
.mobile-hq-turn-chip{display:none}

@media (min-width:851px){
  .battle-hq .hq-turn-box{
    display:flex!important;
    position:absolute!important;
    top:5px!important;
    right:7px!important;
    bottom:auto!important;
    width:58px!important;
    height:22px!important;
    min-height:22px!important;
    padding:2px 5px!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:center!important;
    gap:4px!important;
    border-radius:5px!important;
    z-index:24!important;
  }
  .battle-hq .hq-turn-box span{font-size:9px!important}
  .battle-hq .hq-turn-box b{font-size:13px!important}
  .battle-hq .hq-title{padding-right:72px!important}
  .battle-hq .hq-advisor-slot{
    top:32px!important;
    right:7px!important;
    bottom:auto!important;
  }
  .mobile-hq-turn-chip{display:none!important}
}

.manager-preview{
  width:100%!important;
  height:auto!important;
  min-height:0!important;
  aspect-ratio:500 / 700!important;
  align-self:start!important;
  touch-action:none!important;
  background:#111820!important;
}
.manager-preview>img,
.manager-preview>.card-art-img,
.manager-preview>.default-art{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  object-position:var(--img-x,50%) var(--img-y,50%)!important;
}
.image-adjust-panel .drag-position-readout{
  display:flex!important;
  justify-content:space-between!important;
  gap:8px!important;
  font-size:9px!important;
  color:#baa98f!important;
}
.image-adjust-panel .drag-position-readout b{color:#f0d29a!important;white-space:nowrap!important}

@media (max-width:850px){
  :root{
    --v120-hand-height:calc(var(--mobile-card-height,132px) + 34px);
    --v120-hq-height:178px;
    --v120-bottom-total:calc(var(--v120-hand-height) + var(--v120-hq-height));
  }

  
  body:not(.prebattle) .enemy-hq-row,
  body:not(.prebattle) .mobile-ally-hq-mount{
    box-sizing:border-box!important;
    width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;
    min-width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;
    max-width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;
    height:var(--v120-hq-height)!important;
    min-height:var(--v120-hq-height)!important;
    max-height:var(--v120-hq-height)!important;
    margin-left:auto!important;
    margin-right:auto!important;
    padding:4px!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .enemy-hq-row{
    position:relative!important;
    inset:auto!important;
    z-index:20!important;
    background:linear-gradient(180deg,#281719,#120b0d)!important;
    border-bottom:1px solid #6f3d33!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount{
    position:fixed!important;
    left:50%!important;
    right:auto!important;
    bottom:var(--v120-hand-height)!important;
    transform:translateX(-50%)!important;
    z-index:92!important;
    background:linear-gradient(180deg,#182a3af8,#071018fa)!important;
    border-top:1px solid #8a5b28!important;
    box-shadow:0 -7px 18px #000b!important;
  }
  body:not(.prebattle) .enemy-hq-row .battle-hq,
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq{
    box-sizing:border-box!important;
    position:relative!important;
    display:block!important;
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
    padding:0!important;
    border-radius:9px!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-title,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-title{
    box-sizing:border-box!important;
    height:24px!important;
    min-height:24px!important;
    max-height:24px!important;
    padding:3px 7px!important;
    padding-right:7px!important;
    font-size:10px!important;
    line-height:17px!important;
    max-width:100%!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-subtitle,
  body:not(.prebattle) .enemy-hq-row .hptxt,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-subtitle,
  body:not(.prebattle) .mobile-ally-hq-mount .hptxt,
  body:not(.prebattle) .enemy-hq-row .hq-turn-box,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-turn-box,
  body:not(.prebattle) .enemy-hq-row .desktop-hq-skill-chip,
  body:not(.prebattle) .mobile-ally-hq-mount .desktop-hq-skill-chip{
    display:none!important;
  }

  
  body:not(.prebattle) .enemy-hq-row .hq-info-overlay,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-info-overlay{
    box-sizing:border-box!important;
    position:absolute!important;
    left:5px!important;
    right:5px!important;
    top:27px!important;
    width:auto!important;
    max-width:none!important;
    height:25px!important;
    min-height:25px!important;
    display:grid!important;
    grid-template-columns:1.25fr 1fr .8fr .8fr .7fr!important;
    gap:3px!important;
    padding:0!important;
    transform:none!important;
    z-index:22!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-stat-chip,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-stat-chip{
    box-sizing:border-box!important;
    min-width:0!important;
    height:25px!important;
    min-height:25px!important;
    padding:2px 3px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:2px!important;
    border-radius:5px!important;
    font-size:8px!important;
    white-space:nowrap!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-stat-icon,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-stat-icon{font-size:9px!important;flex:0 0 auto!important}
  body:not(.prebattle) .enemy-hq-row .hq-stat-value,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-stat-value{font-size:9px!important;min-width:0!important;overflow:hidden!important;text-overflow:ellipsis!important}
  body:not(.prebattle) .mobile-hq-turn-chip{display:flex!important}

  
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{
    box-sizing:border-box!important;
    position:absolute!important;
    top:56px!important;
    right:6px!important;
    bottom:auto!important;
    left:auto!important;
    width:var(--mobile-card-width,100px)!important;
    min-width:var(--mobile-card-width,100px)!important;
    max-width:var(--mobile-card-width,100px)!important;
    height:84px!important;
    min-height:84px!important;
    max-height:84px!important;
    padding:2px!important;
    overflow:hidden!important;
    border-radius:7px!important;
    z-index:23!important;
  }
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot .advisor-card,
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot .advisor-image-only,
  body:not(.prebattle) .enemy-hq-row .hq-advisor-slot .advisor-portrait,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot .advisor-card,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot .advisor-image-only,
  body:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot .advisor-portrait{
    width:100%!important;
    height:100%!important;
    min-width:0!important;
    min-height:0!important;
    max-width:none!important;
    max-height:none!important;
    overflow:hidden!important;
  }

  
  body:not(.prebattle) .mobile-ally-hq-mount .mobile-hq-actions{
    box-sizing:border-box!important;
    position:absolute!important;
    left:6px!important;
    right:6px!important;
    bottom:5px!important;
    height:31px!important;
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:5px!important;
    z-index:30!important;
  }
  body:not(.prebattle) .mobile-ally-hq-mount .mobile-hq-actions .btn{
    box-sizing:border-box!important;
    width:100%!important;
    min-width:0!important;
    height:31px!important;
    min-height:31px!important;
    max-height:31px!important;
    padding:3px 4px!important;
    border-radius:6px!important;
    font-size:10px!important;
    font-weight:950!important;
    line-height:1!important;
  }

  
  body:not(.prebattle) .bottom-hud{display:none!important}
  body:not(.prebattle) .mobile-hand-mount{
    position:fixed!important;
    left:50%!important;
    right:auto!important;
    bottom:0!important;
    transform:translateX(-50%)!important;
    width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;
    min-width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;
    max-width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;
    height:var(--v120-hand-height)!important;
    min-height:var(--v120-hand-height)!important;
    max-height:var(--v120-hand-height)!important;
    z-index:93!important;
    overflow:hidden!important;
    background:#080c0efa!important;
    border-top:1px solid #70552d!important;
    box-shadow:0 -5px 15px #000b!important;
  }
  body:not(.prebattle) .mobile-hand-mount .right-hand-section{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .mobile-hand-mount .right-hand-section>.ornate-title{
    height:28px!important;
    min-height:28px!important;
    max-height:28px!important;
    flex:0 0 28px!important;
  }
  body:not(.prebattle) .mobile-hand-mount .handbox{
    height:calc(100% - 28px)!important;
    min-height:0!important;
    padding:3px 4px!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .mobile-hand-mount .handhead{display:none!important}
  body:not(.prebattle) .app,
  body:not(.prebattle){
    padding-bottom:calc(var(--v120-bottom-total) + 10px)!important;
  }

  
  #cardManagerModal .card-manager-box{
    height:96dvh!important;
    max-height:96dvh!important;
  }
  #cardManagerModal .manager-main{
    grid-template-rows:154px minmax(0,1fr)!important;
  }
  #cardManagerModal .manager-list-pane{min-height:0!important;overflow:hidden!important}
  #cardManagerModal .manager-edit-pane{min-height:0!important;overflow-y:auto!important;-webkit-overflow-scrolling:touch!important}
  #cardManagerModal .manager-grid{grid-template-columns:1fr!important;gap:10px!important}
  #cardManagerModal .manager-preview-wrap{width:100%!important;max-width:340px!important;margin:0 auto!important}
  #cardManagerModal .manager-preview{
    width:100%!important;
    height:auto!important;
    min-height:0!important;
    aspect-ratio:500 / 700!important;
    touch-action:none!important;
  }
  #cardManagerModal .image-adjust-panel label{
    grid-template-columns:64px minmax(0,1fr) 42px!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle){
  --v120-hand-height:calc(var(--mobile-card-height,136px) + 34px);
  --v120-hq-height:178px;
  --v120-bottom-total:calc(var(--v120-hand-height) + var(--v120-hq-height));
}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{height:var(--v120-hq-height)!important;min-height:var(--v120-hq-height)!important;max-height:var(--v120-hq-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-info-overlay,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-info-overlay{left:5px!important;right:5px!important;top:27px!important;width:auto!important;height:25px!important;display:grid!important;grid-template-columns:1.25fr 1fr .8fr .8fr .7fr!important;gap:3px!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .desktop-hq-skill-chip,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .desktop-hq-skill-chip,
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-turn-box,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-turn-box{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hq-turn-chip{display:flex!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot{top:56px!important;right:6px!important;width:var(--mobile-card-width,100px)!important;min-width:var(--mobile-card-width,100px)!important;max-width:var(--mobile-card-width,100px)!important;height:84px!important;min-height:84px!important;max-height:84px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{position:fixed!important;left:50%!important;right:auto!important;bottom:var(--v120-hand-height)!important;transform:translateX(-50%)!important;z-index:92!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount{position:fixed!important;left:50%!important;right:auto!important;bottom:0!important;transform:translateX(-50%)!important;height:var(--v120-hand-height)!important;min-height:var(--v120-hand-height)!important;max-height:var(--v120-hand-height)!important;z-index:93!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .mobile-hq-actions{position:absolute!important;left:6px!important;right:6px!important;bottom:5px!important;height:31px!important;display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:5px!important;z-index:30!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .mobile-hq-actions .btn{height:31px!important;min-height:31px!important;padding:3px 4px!important;font-size:10px!important}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud{display:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .app,
body.ui-mode-mobile-preview:not(.prebattle){padding-bottom:calc(var(--v120-bottom-total) + 10px)!important}

.card-art-img,.unit-art-img,.manager-preview img,.advisor-portrait img,.roster-art img,.base-unit-art img{
  transform:scale(var(--img-scale-x,var(--img-scale,1)),var(--img-scale-y,var(--img-scale,1)))!important;
  transform-origin:var(--img-x,50%) var(--img-y,50%)!important;
}
.collection-card-art .card-art-img,.collection-card-art .configured-default-art,.collection-card-art .auto-folder-art,
.other-preview-art{transform:scale(var(--img-scale-x,var(--img-scale,1)),var(--img-scale-y,var(--img-scale,1)))!important;transform-origin:var(--img-x,50%) var(--img-y,50%)!important;}
.image-adjust-panel select{width:100%;min-height:28px;background:#151b22;color:#f7e8c9;border:1px solid #5d4324}
.image-adjust-subtitle{grid-column:1/-1;font-size:11px;font-weight:900;color:#f0c980;padding:2px 0 0}
.image-adjust-subtitle small{font-size:9px;color:#d8c6aa;font-weight:700}
.image-adjust-title small{font-size:9px;font-weight:700;color:#9fb0ca}
.manager-preview-dual{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.manager-inline-preview-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;padding:10px;border:1px solid #2d3d59;border-radius:10px;background:#0a1322}
.manager-preview-dual-col{display:flex;flex-direction:column;gap:6px;min-width:0}
.manager-preview-dual-label{font-size:11px;font-weight:900;color:#9fc2e6;text-align:center}
.manager-inline-preview-grid .manager-preview{height:190px}
.manager-preview-dual .manager-preview{height:210px}
.manager-preview-dual .manager-preview#managerPreviewMobile{border-color:#5ca9d9}
.manager-preview.mobile-preview{outline:2px solid #5ca9d955;outline-offset:2px}
.manager-preview.layout-linked{cursor:default;opacity:.55}
.manager-preview.layout-linked::after{content:'PC 값과 연동됨'}
.image-adjust-panel.compact{padding:7px;gap:5px}
.image-adjust-panel.compact label{grid-template-columns:52px minmax(0,1fr) 38px;font-size:9px}
@media(max-width:850px){
  .manager-preview-dual{grid-template-columns:1fr}
  .manager-inline-preview-grid{grid-template-columns:1fr}
  .manager-preview-dual .manager-preview{height:190px}
}

@media (min-width:851px){
  .right-panel-hq-row .battle-hq,.enemy-hq-row .battle-hq{min-height:112px!important;height:112px!important;padding-bottom:0!important}
  .right-panel-hq-row .battle-hq .hq-advisor-slot,.enemy-hq-row .battle-hq .hq-advisor-slot{top:30px!important;bottom:6px!important;height:auto!important;min-height:0!important}
  .right-panel-hq-row .battle-hq .hq-advisor-summary,.enemy-hq-row .battle-hq .hq-advisor-summary{bottom:6px!important}
  .right-panel-hq-row .battle-hq .hq-turn-box,.enemy-hq-row .battle-hq .hq-turn-box{top:8px!important;bottom:auto!important}
}

@media (max-width:850px){
  :root{--mobile-hand-card-w:86px;--mobile-hand-card-h:126px}
  .enemy-hq-row,.mobile-ally-hq-mount{width:100%!important;padding:5px!important;box-sizing:border-box!important}
  .enemy-hq-row .battle-hq,.mobile-ally-hq-mount .battle-hq{display:block!important;width:100%!important;height:138px!important;min-height:138px!important;max-height:138px!important;border-radius:10px!important;position:relative!important;overflow:hidden!important}
  .enemy-hq-row .battle-hq .hq-info-overlay,.mobile-ally-hq-mount .battle-hq .hq-info-overlay{left:8px!important;right:calc(var(--mobile-hand-card-w) + 14px)!important;top:34px!important;display:flex!important;gap:7px!important;flex-wrap:nowrap!important;align-items:center!important;justify-content:flex-start!important}
  .enemy-hq-row .battle-hq .hq-stat-chip,.mobile-ally-hq-mount .battle-hq .hq-stat-chip{font-size:11px!important}
  .enemy-hq-row .battle-hq .hq-stat-chip b,.mobile-ally-hq-mount .battle-hq .hq-stat-chip b{font-size:12px!important}
  .enemy-hq-row .battle-hq .hq-advisor-slot,.mobile-ally-hq-mount .battle-hq .hq-advisor-slot{position:absolute!important;right:8px!important;top:8px!important;width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-width:var(--mobile-hand-card-w)!important;min-height:var(--mobile-hand-card-h)!important;max-width:var(--mobile-hand-card-w)!important;max-height:var(--mobile-hand-card-h)!important;border-radius:8px!important;padding:0!important;overflow:hidden!important}
  .enemy-hq-row .battle-hq .hq-advisor-slot .advisor-image-only .advisor-slot-badge,.mobile-ally-hq-mount .battle-hq .hq-advisor-slot .advisor-image-only .advisor-slot-badge{height:18px!important;padding:2px 4px!important}
  .enemy-hq-row .battle-hq .hq-advisor-summary,.mobile-ally-hq-mount .battle-hq .hq-advisor-summary{left:8px!important;right:calc(var(--mobile-hand-card-w) + 14px)!important;bottom:6px!important;min-height:24px!important;font-size:8px!important;padding:3px 5px!important}
  .enemy-hq-row .battle-hq .hq-turn-box,.mobile-ally-hq-mount .battle-hq .hq-turn-box{display:none!important}
  .enemy-hq-row .battle-hq .desktop-hq-skill-chip,.mobile-ally-hq-mount .battle-hq .desktop-hq-skill-chip{display:none!important}
  .mobile-hq-actions{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:4px!important;padding:4px 6px 0!important}
  .mobile-hq-actions .btn{min-height:30px!important;font-size:11px!important;padding:0 4px!important}
}

body.ui-mode-mobile-preview{--mobile-hand-card-w:86px;--mobile-hand-card-h:126px}
body.ui-mode-mobile-preview .enemy-hq-row,
body.ui-mode-mobile-preview .mobile-ally-hq-mount{width:100%!important;padding:5px!important;box-sizing:border-box!important}
body.ui-mode-mobile-preview .enemy-hq-row .battle-hq,
body.ui-mode-mobile-preview .mobile-ally-hq-mount .battle-hq{display:block!important;width:100%!important;height:138px!important;min-height:138px!important;max-height:138px!important;border-radius:10px!important;position:relative!important;overflow:hidden!important}
body.ui-mode-mobile-preview .enemy-hq-row .battle-hq .hq-info-overlay,
body.ui-mode-mobile-preview .mobile-ally-hq-mount .battle-hq .hq-info-overlay{left:8px!important;right:calc(var(--mobile-hand-card-w) + 14px)!important;top:34px!important;display:flex!important;gap:7px!important;flex-wrap:nowrap!important;align-items:center!important;justify-content:flex-start!important}
body.ui-mode-mobile-preview .enemy-hq-row .battle-hq .hq-advisor-slot,
body.ui-mode-mobile-preview .mobile-ally-hq-mount .battle-hq .hq-advisor-slot{position:absolute!important;right:8px!important;top:8px!important;width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-width:var(--mobile-hand-card-w)!important;min-height:var(--mobile-hand-card-h)!important;max-width:var(--mobile-hand-card-w)!important;max-height:var(--mobile-hand-card-h)!important;border-radius:8px!important;padding:0!important;overflow:hidden!important}
body.ui-mode-mobile-preview .enemy-hq-row .battle-hq .hq-advisor-summary,
body.ui-mode-mobile-preview .mobile-ally-hq-mount .battle-hq .hq-advisor-summary{left:8px!important;right:calc(var(--mobile-hand-card-w) + 14px)!important;bottom:6px!important;min-height:24px!important;font-size:8px!important;padding:3px 5px!important}
body.ui-mode-mobile-preview .enemy-hq-row .battle-hq .hq-turn-box,
body.ui-mode-mobile-preview .mobile-ally-hq-mount .battle-hq .hq-turn-box,
body.ui-mode-mobile-preview .enemy-hq-row .battle-hq .desktop-hq-skill-chip,
body.ui-mode-mobile-preview .mobile-ally-hq-mount .battle-hq .desktop-hq-skill-chip{display:none!important}

@media (max-width:850px){
  .mobile-hand-mount #hand.hand .card{flex:0 0 var(--mobile-hand-card-w)!important;width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-height:var(--mobile-hand-card-h)!important;max-height:var(--mobile-hand-card-h)!important}
}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .card{flex:0 0 var(--mobile-hand-card-w)!important;width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-height:var(--mobile-hand-card-h)!important;max-height:var(--mobile-hand-card-h)!important}

.image-layout-link-toggle{grid-column:1/-1!important;display:flex!important;align-items:center!important;gap:7px!important;min-height:28px!important;padding:5px 7px!important;border:1px solid #5b4328!important;background:#10161d!important;color:#ead7b4!important;font-size:10px!important;font-weight:800!important}
.image-layout-link-toggle input{width:auto!important;min-width:16px!important;height:16px!important;margin:0!important}
.responsive-image-adjust select{width:100%;min-height:28px;background:#151b22;color:#f7e8c9;border:1px solid #5d4324}
.responsive-image-adjust .image-adjust-subtitle{grid-column:1/-1;margin-top:3px;padding-top:6px;border-top:1px solid #3d3325}
.batch-base-image-preview{grid-column:1/-1;width:min(100%,360px)!important;aspect-ratio:500/700!important;min-height:0!important;margin:3px auto 8px!important;touch-action:none!important;overflow:hidden!important}
.default-image-preview.mobile-preview,.hq-image-preview.mobile-preview,.batch-base-image-preview.mobile-preview{outline:2px solid #5ca9d9;outline-offset:2px}
.other-image-adjust-panel label,.batch-card-image-shuttle label{grid-template-columns:82px minmax(0,1fr) 48px!important}
.other-image-adjust-panel .image-layout-link-toggle,.batch-card-image-shuttle .image-layout-link-toggle{grid-template-columns:auto 1fr!important}

@media (min-width:851px){
  :root{--v122-pc-advisor-w:96px;--v122-pc-advisor-h:148px;--v122-pc-hq-top:29px;--v122-pc-hq-h:178px}
  .reference-left .enemy-hq-host,
  .reference-left .enemy-hq-row,
  .reference-right .right-panel-hq-row{height:var(--v122-pc-hq-h)!important;min-height:var(--v122-pc-hq-h)!important;max-height:var(--v122-pc-hq-h)!important;padding-bottom:0!important;margin-bottom:6px!important;overflow:hidden!important}
  .reference-left .enemy-hq-row .battle-hq,
  .reference-right .right-panel-hq-row .battle-hq{height:var(--v122-pc-hq-h)!important;min-height:var(--v122-pc-hq-h)!important;max-height:var(--v122-pc-hq-h)!important;padding-bottom:0!important;overflow:hidden!important}
  .reference-left .enemy-hq-row .battle-hq .hq-advisor-slot,
  .reference-right .right-panel-hq-row .battle-hq .hq-advisor-slot{top:var(--v122-pc-hq-top)!important;right:10px!important;bottom:1px!important;transform:none!important;width:var(--v122-pc-advisor-w)!important;min-width:var(--v122-pc-advisor-w)!important;max-width:var(--v122-pc-advisor-w)!important;height:var(--v122-pc-advisor-h)!important;min-height:var(--v122-pc-advisor-h)!important;max-height:var(--v122-pc-advisor-h)!important;margin:0!important}
  #allyHq .hq-advisor-slot,#enemyHq .hq-advisor-slot{top:var(--v122-pc-hq-top)!important;right:10px!important;bottom:1px!important;left:auto!important;transform:none!important;width:var(--v122-pc-advisor-w)!important;min-width:var(--v122-pc-advisor-w)!important;max-width:var(--v122-pc-advisor-w)!important;height:var(--v122-pc-advisor-h)!important;min-height:var(--v122-pc-advisor-h)!important;max-height:var(--v122-pc-advisor-h)!important;margin:0!important}
}

@media (max-width:850px){
  :root{--mobile-hand-card-w:var(--mobile-card-width,100px);--mobile-hand-card-h:var(--mobile-card-height,130px);--v122-hq-pad:5px;--v122-mobile-hq-h:calc(var(--mobile-hand-card-h) + 16px);--v120-hq-height:var(--v122-mobile-hq-h);--v120-bottom-total:calc(var(--v120-hand-height) + var(--v122-mobile-hq-h))}
  body:not(.prebattle) .enemy-hq-row,
  body:not(.prebattle) .mobile-ally-hq-mount{box-sizing:border-box!important;width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;min-width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;max-width:var(--mobile-play-width,min(calc(100vw - 12px),430px))!important;height:var(--v122-mobile-hq-h)!important;min-height:var(--v122-mobile-hq-h)!important;max-height:var(--v122-mobile-hq-h)!important;padding:var(--v122-hq-pad)!important;margin:0 auto!important;overflow:hidden!important}
  body:not(.prebattle) .enemy-hq-row .battle-hq,
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq{box-sizing:border-box!important;width:100%!important;height:calc(var(--v122-mobile-hq-h) - (var(--v122-hq-pad) * 2))!important;min-height:calc(var(--v122-mobile-hq-h) - (var(--v122-hq-pad) * 2))!important;max-height:calc(var(--v122-mobile-hq-h) - (var(--v122-hq-pad) * 2))!important;margin:0!important;padding:0!important;overflow:hidden!important}
  body:not(.prebattle) .enemy-hq-row .battle-hq .hq-advisor-slot,
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-advisor-slot{position:absolute!important;top:3px!important;right:3px!important;bottom:3px!important;left:auto!important;transform:none!important;width:var(--mobile-hand-card-w)!important;min-width:var(--mobile-hand-card-w)!important;max-width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-height:var(--mobile-hand-card-h)!important;max-height:var(--mobile-hand-card-h)!important;margin:0!important;padding:0!important;overflow:hidden!important}
  body:not(.prebattle) #allyHq .hq-advisor-slot,body:not(.prebattle) #enemyHq .hq-advisor-slot{position:absolute!important;top:3px!important;right:3px!important;bottom:3px!important;left:auto!important;transform:none!important;width:var(--mobile-hand-card-w)!important;min-width:var(--mobile-hand-card-w)!important;max-width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-height:var(--mobile-hand-card-h)!important;max-height:var(--mobile-hand-card-h)!important;margin:0!important;padding:0!important;overflow:hidden!important}
  body:not(.prebattle) .enemy-hq-row .battle-hq .hq-info-overlay,
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-info-overlay{left:7px!important;right:calc(var(--mobile-hand-card-w) + 11px)!important;top:31px!important;width:auto!important;max-width:none!important;height:auto!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:4px!important;align-items:center!important;justify-items:stretch!important;overflow:visible!important}
  body:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip,
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip{box-sizing:border-box!important;width:100%!important;min-width:0!important;height:24px!important;min-height:24px!important;padding:2px 4px!important;display:flex!important;font-size:9px!important;overflow:hidden!important}
  body:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip b,
  body:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip b{font-size:10px!important}
  body:not(.prebattle) .mobile-ally-hq-mount{bottom:var(--v120-hand-height)!important}
  body:not(.prebattle) .mobile-ally-hq-mount .mobile-hq-actions{left:7px!important;right:calc(var(--mobile-hand-card-w) + 11px)!important;bottom:5px!important;height:29px!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:3px!important;padding:0!important}
  body:not(.prebattle) .mobile-ally-hq-mount .mobile-hq-actions .btn{height:29px!important;min-height:29px!important;max-height:29px!important;font-size:9px!important;padding:2px!important}
  body:not(.prebattle) .app,body:not(.prebattle){padding-bottom:calc(var(--v120-hand-height) + var(--v122-mobile-hq-h) + 10px)!important}

  body:not(.prebattle) .mobile-hand-mount #hand.hand .card{flex:0 0 var(--mobile-hand-card-w)!important;width:var(--mobile-hand-card-w)!important;min-width:var(--mobile-hand-card-w)!important;max-width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-height:var(--mobile-hand-card-h)!important;max-height:var(--mobile-hand-card-h)!important}
  #otherImageModal .other-image-box,#batchSettingsModal .batch-settings-box{width:96vw!important;max-width:96vw!important;height:94dvh!important;max-height:94dvh!important}
  .responsive-image-adjust label{grid-template-columns:72px minmax(0,1fr) 44px!important}
}

body.ui-mode-mobile-preview:not(.prebattle){--mobile-hand-card-w:var(--mobile-card-width,100px);--mobile-hand-card-h:var(--mobile-card-height,130px);--v122-hq-pad:5px;--v122-mobile-hq-h:calc(var(--mobile-hand-card-h) + 16px);--v120-hq-height:var(--v122-mobile-hq-h);--v120-bottom-total:calc(var(--v120-hand-height) + var(--v122-mobile-hq-h))}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{width:var(--mobile-play-width,418px)!important;min-width:var(--mobile-play-width,418px)!important;max-width:var(--mobile-play-width,418px)!important;height:var(--v122-mobile-hq-h)!important;min-height:var(--v122-mobile-hq-h)!important;max-height:var(--v122-mobile-hq-h)!important;padding:var(--v122-hq-pad)!important;margin-left:auto!important;margin-right:auto!important;overflow:hidden!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq{height:calc(var(--v122-mobile-hq-h) - (var(--v122-hq-pad) * 2))!important;min-height:calc(var(--v122-mobile-hq-h) - (var(--v122-hq-pad) * 2))!important;max-height:calc(var(--v122-mobile-hq-h) - (var(--v122-hq-pad) * 2))!important;margin:0!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq .hq-advisor-slot,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-advisor-slot{top:3px!important;right:3px!important;bottom:3px!important;left:auto!important;transform:none!important;width:var(--mobile-hand-card-w)!important;min-width:var(--mobile-hand-card-w)!important;max-width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-height:var(--mobile-hand-card-h)!important;max-height:var(--mobile-hand-card-h)!important}
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq .hq-info-overlay,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-info-overlay{left:7px!important;right:calc(var(--mobile-hand-card-w) + 11px)!important;top:31px!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:4px!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{bottom:var(--v120-hand-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .app,body.ui-mode-mobile-preview:not(.prebattle){padding-bottom:calc(var(--v120-hand-height) + var(--v122-mobile-hq-h) + 10px)!important}

body.ui-mode-mobile-preview:not(.prebattle) #allyHq .hq-advisor-slot,
body.ui-mode-mobile-preview:not(.prebattle) #enemyHq .hq-advisor-slot{position:absolute!important;top:3px!important;right:3px!important;bottom:3px!important;left:auto!important;transform:none!important;width:var(--mobile-hand-card-w)!important;min-width:var(--mobile-hand-card-w)!important;max-width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-height:var(--mobile-hand-card-h)!important;max-height:var(--mobile-hand-card-h)!important;margin:0!important;padding:0!important;overflow:hidden!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{flex:0 0 var(--mobile-hand-card-w)!important;width:var(--mobile-hand-card-w)!important;min-width:var(--mobile-hand-card-w)!important;max-width:var(--mobile-hand-card-w)!important;height:var(--mobile-hand-card-h)!important;min-height:var(--mobile-hand-card-h)!important;max-height:var(--mobile-hand-card-h)!important}

.batch-card-image-shuttle{
  grid-template-columns:1fr!important;
}
.batch-card-image-shuttle>.batch-base-preview-dual{
  grid-column:1/-1!important;
}
.batch-card-image-shuttle>.image-adjust-subtitle,
.batch-card-image-shuttle>.image-layout-link-toggle,
.batch-card-image-shuttle>.batch-base-control-row{
  grid-column:1/-1!important;
}
.batch-base-control-row{
  display:grid!important;
  grid-template-columns:repeat(4,minmax(150px,1fr))!important;
  gap:10px!important;
  width:100%!important;
  min-width:0!important;
  overflow-x:auto!important;
  padding:2px 0 6px!important;
}
.batch-base-control-row>label{
  display:grid!important;
  grid-template-columns:68px minmax(80px,1fr) 42px!important;
  gap:6px!important;
  align-items:center!important;
  min-width:150px!important;
  margin:0!important;
}
.batch-base-control-row input[type="range"]{width:100%!important;min-width:80px!important}
.batch-base-control-row output{min-width:42px!important;text-align:right!important}
.manager-preview-dual-col .batch-base-control-row{grid-template-columns:repeat(2,minmax(110px,1fr))!important}

.mobile-combat-summary{grid-template-columns:repeat(4,1fr)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-combat-summary{grid-template-columns:repeat(4,1fr)!important}

#allyHq .hptxt,#enemyHq .hptxt,#allyHq .hq-turn-box,#enemyHq .hq-turn-box{display:none!important}
#allyHq .hq-info-overlay,#enemyHq .hq-info-overlay{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-template-rows:repeat(2,minmax(22px,auto))!important;
  gap:4px!important;
  align-items:stretch!important;
  justify-items:stretch!important;
  overflow:visible!important;
}
#allyHq .hq-stat-chip,#enemyHq .hq-stat-chip{
  box-sizing:border-box!important;
  width:100%!important;
  min-width:0!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:3px!important;
  white-space:nowrap!important;
  overflow:hidden!important;
}
#allyHq .mobile-hq-turn-chip,#enemyHq .mobile-hq-turn-chip,
#allyHq .desktop-hq-skill-chip,#enemyHq .desktop-hq-skill-chip{display:flex!important}

@media (min-width:851px){
  #allyHq .hq-info-overlay,#enemyHq .hq-info-overlay{
    left:8px!important;
    right:116px!important;
    top:31px!important;
    height:auto!important;
  }
  #allyHq .hq-stat-chip,#enemyHq .hq-stat-chip{
    min-height:25px!important;
    padding:3px 5px!important;
    font-size:10px!important;
  }
  #allyHq .hq-stat-chip b,#enemyHq .hq-stat-chip b{font-size:11px!important}
}

@media (max-width:850px){
  body:not(.prebattle) #allyHq .hq-info-overlay,
  body:not(.prebattle) #enemyHq .hq-info-overlay{
    left:7px!important;
    right:calc(var(--mobile-hand-card-w) + 11px)!important;
    top:29px!important;
    height:50px!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    grid-template-rows:repeat(2,23px)!important;
    gap:4px!important;
  }
  body:not(.prebattle) #allyHq .hq-stat-chip,
  body:not(.prebattle) #enemyHq .hq-stat-chip{
    height:23px!important;
    min-height:23px!important;
    padding:2px 3px!important;
    font-size:8px!important;
  }
  body:not(.prebattle) #allyHq .hq-stat-chip b,
  body:not(.prebattle) #enemyHq .hq-stat-chip b{font-size:9px!important}
  body:not(.prebattle) .mobile-ally-hq-mount .mobile-hq-actions{
    left:7px!important;
    right:calc(var(--mobile-hand-card-w) + 11px)!important;
    bottom:5px!important;
    height:29px!important;
    z-index:35!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle) #allyHq .hq-info-overlay,
body.ui-mode-mobile-preview:not(.prebattle) #enemyHq .hq-info-overlay{
  left:7px!important;
  right:calc(var(--mobile-hand-card-w) + 11px)!important;
  top:29px!important;
  height:50px!important;
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-template-rows:repeat(2,23px)!important;
  gap:4px!important;
}
body.ui-mode-mobile-preview:not(.prebattle) #allyHq .hq-stat-chip,
body.ui-mode-mobile-preview:not(.prebattle) #enemyHq .hq-stat-chip{
  height:23px!important;
  min-height:23px!important;
  padding:2px 3px!important;
  font-size:8px!important;
}
body.ui-mode-mobile-preview:not(.prebattle) #allyHq .hq-stat-chip b,
body.ui-mode-mobile-preview:not(.prebattle) #enemyHq .hq-stat-chip b{font-size:9px!important}
body.ui-mode-mobile-preview:not(.prebattle) #allyHq .mobile-hq-turn-chip,
body.ui-mode-mobile-preview:not(.prebattle) #enemyHq .mobile-hq-turn-chip,
body.ui-mode-mobile-preview:not(.prebattle) #allyHq .desktop-hq-skill-chip,
body.ui-mode-mobile-preview:not(.prebattle) #enemyHq .desktop-hq-skill-chip{display:flex!important}

@media (max-width:700px){
  .batch-base-control-row{grid-template-columns:repeat(4,150px)!important}
}

@media (max-width:850px){
  html body:not(.prebattle) .battle-panel > #mobileAllyHqMount,
  html body:not(.prebattle) .battle-panel > #mobileHandMount{
    left:calc((100vw - var(--mobile-play-width,min(calc(100vw - 12px),430px)))/2)!important;
    right:auto!important;
    transform:none!important;
    margin-left:0!important;
    margin-right:0!important;
  }
}
html body.ui-mode-mobile-preview:not(.prebattle) .battle-panel > #mobileAllyHqMount,
html body.ui-mode-mobile-preview:not(.prebattle) .battle-panel > #mobileHandMount{
  left:calc((100vw - var(--mobile-play-width,min(calc(100vw - 12px),430px)))/2)!important;
  right:auto!important;
  transform:none!important;
  margin-left:0!important;
  margin-right:0!important;
}

.unified-card-image-controls{
  grid-template-columns:minmax(240px,360px)!important;
  justify-content:center!important;
  width:100%!important;
}
.unified-card-image-controls .manager-preview-dual-col{width:100%!important;max-width:360px!important;margin:0 auto!important}
.manager-inline-preview-grid.unified-card-image-controls .manager-preview,
.default-image-preview-dual.unified-card-image-controls .default-image-preview,
.batch-base-preview-dual.unified-card-image-controls .batch-base-image-preview{
  box-sizing:border-box!important;
  width:min(100%,320px)!important;
  height:auto!important;
  min-height:0!important;
  aspect-ratio:21/25!important;
  margin-left:auto!important;
  margin-right:auto!important;
  touch-action:none!important;
  overflow:hidden!important;
}
.unified-card-image-controls .image-adjust-panel,
.unified-card-image-controls .other-image-adjust-panel,
.unified-card-image-controls .batch-base-control-row{width:100%!important;box-sizing:border-box!important}

@media (max-width:850px){
  :root{
    --mobile-play-width:min(calc(100vw - 12px),430px);
    --mobile-card-gap:4px;
    --mobile-card-width:calc((var(--mobile-play-width) - 20px)/4);
    --v129-hand-card-height:calc(var(--mobile-card-width) * 1.632);
    --v129-field-card-height:calc(var(--mobile-card-width) * 1.767);
    --mobile-card-height:var(--v129-field-card-height);
    --mobile-hand-card-w:var(--mobile-card-width);
    --mobile-hand-card-h:var(--v129-hand-card-height);
    --v120-hand-height:calc(var(--v129-hand-card-height) + 34px);
    --v122-mobile-hq-h:calc(var(--v129-hand-card-height) + 16px);
    --v120-hq-height:var(--v122-mobile-hq-h);
    --v120-bottom-total:calc(var(--v120-hand-height) + var(--v122-mobile-hq-h));
  }
  body:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane){
    height:calc(var(--v129-field-card-height) + 8px)!important;
    min-height:calc(var(--v129-field-card-height) + 8px)!important;
    max-height:calc(var(--v129-field-card-height) + 8px)!important;
  }
  body:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4,
  body:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3,
  body:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{
    height:var(--v129-field-card-height)!important;
    min-height:var(--v129-field-card-height)!important;
    max-height:var(--v129-field-card-height)!important;
  }
  body:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slot,
  body:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .unit{
    width:var(--mobile-card-width)!important;
    min-width:var(--mobile-card-width)!important;
    max-width:var(--mobile-card-width)!important;
    height:var(--v129-field-card-height)!important;
    min-height:var(--v129-field-card-height)!important;
    max-height:var(--v129-field-card-height)!important;
  }
  body:not(.prebattle) .battlefield-layout .unit{
    grid-template-rows:calc(var(--mobile-card-width) * .2684) minmax(0,1fr) calc(var(--mobile-card-width) * .3131)!important;
  }
  body:not(.prebattle) .battlefield-layout .unit .card-title-area,
  body:not(.prebattle) .battlefield-layout .unit .stats{height:100%!important;min-height:0!important;max-height:none!important}

  body:not(.prebattle) .mobile-hand-mount{
    height:var(--v120-hand-height)!important;
    min-height:var(--v120-hand-height)!important;
    max-height:var(--v120-hand-height)!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand{
    height:var(--v129-hand-card-height)!important;
    min-height:var(--v129-hand-card-height)!important;
    max-height:var(--v129-hand-card-height)!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    flex:0 0 var(--mobile-card-width)!important;
    width:var(--mobile-card-width)!important;
    min-width:var(--mobile-card-width)!important;
    max-width:var(--mobile-card-width)!important;
    height:var(--v129-hand-card-height)!important;
    min-height:var(--v129-hand-card-height)!important;
    max-height:var(--v129-hand-card-height)!important;
    grid-template-rows:calc(var(--mobile-card-width) * .1705) minmax(0,1fr) calc(var(--mobile-card-width) * .2898)!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-title-area,
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card .cstats,
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-stat-grid,
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-stat-cell{
    height:100%!important;min-height:0!important;max-height:none!important;
  }
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-name-text,
  body:not(.prebattle) .battlefield-layout .unit .field-unit-name{font-size:8px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-title-grade,
  body:not(.prebattle) .battlefield-layout .unit .field-grade{height:13px!important;min-width:18px!important;font-size:7px!important;padding:0 3px!important}
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card-stat-cell,
  body:not(.prebattle) .battlefield-layout .unit .stats span{font-size:9px!important}

  body:not(.prebattle) .mobile-ally-hq-mount{bottom:var(--v120-hand-height)!important}
  body:not(.prebattle),body:not(.prebattle) .app{padding-bottom:calc(var(--v120-hand-height) + var(--v122-mobile-hq-h) + 10px)!important}
}

body.ui-mode-mobile-preview:not(.prebattle){
  --mobile-play-width:418px;
  --mobile-card-gap:4px;
  --mobile-card-width:calc((var(--mobile-play-width) - 20px)/4);
  --v129-hand-card-height:calc(var(--mobile-card-width) * 1.632);
  --v129-field-card-height:calc(var(--mobile-card-width) * 1.767);
  --mobile-card-height:var(--v129-field-card-height);
  --mobile-hand-card-w:var(--mobile-card-width);
  --mobile-hand-card-h:var(--v129-hand-card-height);
  --v120-hand-height:calc(var(--v129-hand-card-height) + 34px);
  --v122-mobile-hq-h:calc(var(--v129-hand-card-height) + 16px);
  --v120-hq-height:var(--v122-mobile-hq-h);
  --v120-bottom-total:calc(var(--v120-hand-height) + var(--v122-mobile-hq-h));
}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane){height:calc(var(--v129-field-card-height) + 8px)!important;min-height:calc(var(--v129-field-card-height) + 8px)!important;max-height:calc(var(--v129-field-card-height) + 8px)!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n4,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n3,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slots.n2{height:var(--v129-field-card-height)!important;min-height:var(--v129-field-card-height)!important;max-height:var(--v129-field-card-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .slot,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .lane:not(.hq-defense-lane) .unit{width:var(--mobile-card-width)!important;min-width:var(--mobile-card-width)!important;max-width:var(--mobile-card-width)!important;height:var(--v129-field-card-height)!important;min-height:var(--v129-field-card-height)!important;max-height:var(--v129-field-card-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .unit{grid-template-rows:calc(var(--mobile-card-width) * .2684) minmax(0,1fr) calc(var(--mobile-card-width) * .3131)!important}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .unit .card-title-area,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .unit .stats{height:100%!important;min-height:0!important;max-height:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount{height:var(--v120-hand-height)!important;min-height:var(--v120-hand-height)!important;max-height:var(--v120-hand-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{height:var(--v129-hand-card-height)!important;min-height:var(--v129-hand-card-height)!important;max-height:var(--v129-hand-card-height)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{flex:0 0 var(--mobile-card-width)!important;width:var(--mobile-card-width)!important;min-width:var(--mobile-card-width)!important;max-width:var(--mobile-card-width)!important;height:var(--v129-hand-card-height)!important;min-height:var(--v129-hand-card-height)!important;max-height:var(--v129-hand-card-height)!important;grid-template-rows:calc(var(--mobile-card-width) * .1705) minmax(0,1fr) calc(var(--mobile-card-width) * .2898)!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-title-area,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .cstats,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-stat-grid,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-stat-cell{height:100%!important;min-height:0!important;max-height:none!important}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{bottom:var(--v120-hand-height)!important}
body.ui-mode-mobile-preview:not(.prebattle),body.ui-mode-mobile-preview:not(.prebattle) .app{padding-bottom:calc(var(--v120-hand-height) + var(--v122-mobile-hq-h) + 10px)!important}

@media (max-width:850px){
  body:not(.prebattle) .mobile-hand-mount #hand.hand .card .cimg{
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
  }
}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .cimg{
  height:100%!important;
  min-height:0!important;
  max-height:none!important;
}

#otherImageModal .default-image-preview-dual.unified-card-image-controls #defaultCardImagePreviewPc{
  width:min(100%,320px)!important;
  height:auto!important;
  min-height:0!important;
  aspect-ratio:21/25!important;
}

@media (max-width:850px){
  body:not(.prebattle) .battlefield-layout>.board{
    padding-bottom:calc(var(--mobile-hq-float-height) + 10px)!important;
    box-sizing:border-box!important;
  }
}

@media (max-width:850px){
  body:not(.prebattle) .mobile-ally-hq-mount{
    position:sticky!important;
    left:auto!important;
    right:auto!important;
    bottom:calc(var(--mobile-action-height) + var(--mobile-hand-float-height) + env(safe-area-inset-bottom,0px))!important;
    margin-top:6px!important;
    z-index:77!important;
    flex:0 0 var(--mobile-hq-float-height)!important;
  }
  body:not(.prebattle) .battlefield-layout>.board{
    padding-bottom:0!important;
  }
}

.battlefield-layout .unit .buff-provider-badge{
  display:none!important;
}
.battlefield-layout .unit .unit-buff-box,
.battlefield-layout .unit .unit-skill-box{
  top:2px!important;
  min-width:18px!important;
  height:11px!important;
  padding:0 2px!important;
  border-width:1px!important;
  border-radius:2px!important;
  font-size:6px!important;
  font-weight:900!important;
  line-height:9px!important;
  letter-spacing:-.04em!important;
  box-sizing:border-box!important;
  box-shadow:none!important;
  text-shadow:0 1px 1px #000!important;
  opacity:.92!important;
}
.battlefield-layout .unit .unit-buff-box{left:2px!important;right:auto!important;}
.battlefield-layout .unit .unit-skill-box{right:2px!important;left:auto!important;}

.field-primary-action-grid{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:5px!important;
}
.field-primary-action-grid.two{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
.field-strategist-actions .field-primary-action-grid button{
  min-width:0!important;
  padding:7px 4px!important;
  text-align:center!important;
  align-content:center!important;
}
.field-strategist-actions .field-primary-action-grid button b{
  font-size:12px!important;
  line-height:1.1!important;
}
.field-strategist-actions .field-primary-action-grid button span{
  font-size:8px!important;
  line-height:1.2!important;
  white-space:normal!important;
}
.field-strategist-actions .field-primary-action-grid .buff-start-action{
  border-color:#52cfb5!important;
  background:#0b3a35!important;
}
.field-strategist-actions .field-primary-action-grid .buff-cancel-action{
  border-color:#ffd36e!important;
  background:#49340e!important;
}
@media(max-width:850px){
  .battlefield-layout .unit .unit-buff-box,
  .battlefield-layout .unit .unit-skill-box{
    min-width:17px!important;
    height:10px!important;
    font-size:5.5px!important;
    line-height:8px!important;
  }
  .field-strategist-actions .field-primary-action-grid button{padding:8px 3px!important;}
}

body[data-online-room]:not(.hand-reveal-active) .right-deck-body,
body[data-online-room]:not(.hand-reveal-active) .right-deck-body .deck-action-mount,
body[data-online-room]:not(.hand-reveal-active) .right-deck-body #shuffleBtn,
body[data-online-room]:not(.hand-reveal-active) .right-deck-body #endTurnBtn{
  pointer-events:auto!important;
}
body[data-online-room] .right-deck-body #shuffleBtn,
body[data-online-room] .right-deck-body #endTurnBtn{
  position:relative!important;
  z-index:120!important;
  touch-action:manipulation!important;
}

body[data-online-room] #shuffleBtn,
body[data-online-room] #endTurnBtn,
body[data-online-room] #battleControlBtn{
  pointer-events:auto!important;
  position:relative!important;
  z-index:10020!important;
  touch-action:manipulation!important;
  user-select:none!important;
}
body[data-online-room] #rightActionMount,
body[data-online-room] #mobileHqActions,
body[data-online-room] .hud-actions,
body[data-online-room] .bottom-hud{
  pointer-events:auto!important;
  position:relative!important;
  z-index:10010!important;
}
body[data-online-room].prebattle #shuffleBtn:not(:disabled),
body[data-online-room].prebattle #endTurnBtn:not(:disabled){
  pointer-events:auto!important;
  opacity:1!important;
  filter:none!important;
}
body[data-online-room] #shuffleBtn:disabled,
body[data-online-room] #endTurnBtn:disabled{
  pointer-events:none!important;
}

body[data-online-room].hand-reveal-active .board,
body[data-online-room].hand-reveal-active .right-hand-section{
  pointer-events:none;
}
body[data-online-room]:not(.hand-reveal-active) .board,
body[data-online-room]:not(.hand-reveal-active) .right-hand-section,
body[data-online-room]:not(.hand-reveal-active) #hand.hand,
body[data-online-room]:not(.hand-reveal-active) #hand.hand .card{
  pointer-events:auto!important;
}

#battleFxLayer{position:fixed;inset:0;pointer-events:none;z-index:9999;overflow:hidden}
.fx-target-flash{position:fixed;border:2px solid #ffe29a;border-radius:10px;box-shadow:0 0 20px #ffd36a, inset 0 0 14px #fff3;animation:fxTargetFlash .42s ease-out forwards;pointer-events:none}
@keyframes fxTargetFlash{0%{opacity:0;transform:scale(.92)}35%{opacity:1;transform:scale(1.05)}100%{opacity:0;transform:scale(1.1)}}

.fx-melee-clash{position:fixed;width:76px;height:76px;transform:translate(-50%,-50%);pointer-events:none;filter:drop-shadow(0 0 8px #ffd16a)}
.fx-melee-clash .blade{position:absolute;left:30px;top:4px;width:13px;height:64px;border-radius:8px 8px 3px 3px;background:linear-gradient(90deg,#6e7682,#fff,#aeb7c5);border:1px solid #fff;transform-origin:50% 83%;box-shadow:0 0 7px #fff8}
.fx-melee-clash .blade::after{content:'';position:absolute;left:-8px;bottom:8px;width:27px;height:5px;border-radius:4px;background:#b88934;border:1px solid #f6d485}
.fx-melee-clash .blade.a{transform:rotate(-56deg);animation:bladeA .48s cubic-bezier(.2,.8,.2,1) forwards}
.fx-melee-clash .blade.b{transform:rotate(56deg);animation:bladeB .48s cubic-bezier(.2,.8,.2,1) forwards}
.fx-melee-clash .spark{position:absolute;left:34px;top:34px;width:8px;height:8px;border-radius:50%;background:#fff4bb;box-shadow:0 0 5px 2px #fff,0 0 18px 8px #f5b742;animation:sparkPop .42s ease-out forwards}
@keyframes bladeA{0%{opacity:0;transform:rotate(-105deg) scale(.75)}45%{opacity:1;transform:rotate(-38deg) scale(1.05)}100%{opacity:0;transform:rotate(-55deg) scale(.95)}}
@keyframes bladeB{0%{opacity:0;transform:rotate(105deg) scale(.75)}45%{opacity:1;transform:rotate(38deg) scale(1.05)}100%{opacity:0;transform:rotate(55deg) scale(.95)}}
@keyframes sparkPop{0%{opacity:0;transform:scale(.2)}42%{opacity:1;transform:scale(1.4)}100%{opacity:0;transform:scale(2.8)}}

.fx-arrow{position:fixed;left:0;top:0;width:38px;height:5px;border-radius:4px;background:linear-gradient(90deg,#5a3b1d,#e7c17d 70%,#f7e2a8);transform-origin:19px 2.5px;pointer-events:none;filter:drop-shadow(0 0 5px #ffc86a);will-change:transform,opacity}
.fx-arrow::before{content:'';position:absolute;right:-8px;top:-4px;border-left:10px solid #e7e3d4;border-top:6px solid transparent;border-bottom:6px solid transparent}
.fx-arrow::after{content:'';position:absolute;left:-8px;top:-4px;width:12px;height:13px;background:linear-gradient(135deg,transparent 45%,#c46a4d 46% 58%,transparent 59%),linear-gradient(45deg,transparent 45%,#c46a4d 46% 58%,transparent 59%)}
.fx-arrow.fly{animation:arrowFly var(--fx-duration,.42s) cubic-bezier(.12,.68,.2,1) forwards}
@keyframes arrowFly{0%{opacity:0;transform:translate(var(--sx),var(--sy)) rotate(var(--angle)) scale(.72)}12%{opacity:1}88%{opacity:1}100%{opacity:0;transform:translate(var(--tx),var(--ty)) rotate(var(--angle)) scale(1.05)}}

body.no-anim #battleFxLayer{display:none!important}

.fx-equipment-burst{position:fixed;left:50%;top:18%;transform:translateX(-50%);min-width:210px;padding:16px 24px;border-radius:18px;border:2px solid #fff8;background:linear-gradient(135deg,#101826f2,#0a0f18f7);box-shadow:0 20px 44px #000b,0 0 24px #ffffff14;display:flex;align-items:center;justify-content:center;gap:12px;z-index:10000;animation:equipmentBurstIn 1.05s ease-out forwards}
.fx-equipment-burst .ring{position:absolute;inset:-6px;border-radius:22px;border:2px solid #ffffff40;animation:equipmentRing 1s ease-out forwards}
.fx-equipment-burst .glyph{position:relative;font-size:28px;filter:drop-shadow(0 0 8px #fff8)}
.fx-equipment-burst .label{position:relative;font-size:18px;font-weight:900;color:#fff;text-shadow:0 2px 8px #000}
.fx-equipment-burst.destroy{border-color:#ffaf86;background:linear-gradient(135deg,#512012f5,#261109f7 65%,#150c08f7)}
.fx-equipment-burst.steal{border-color:#83ddff;background:linear-gradient(135deg,#163f62f5,#0d223af7 65%,#0a1117f7)}
@keyframes equipmentBurstIn{0%{opacity:0;transform:translateX(-50%) translateY(-20px) scale(.8)}20%{opacity:1;transform:translateX(-50%) translateY(0) scale(1.05)}70%{opacity:1;transform:translateX(-50%) translateY(0) scale(1)}100%{opacity:0;transform:translateX(-50%) translateY(-8px) scale(.98)}}
@keyframes equipmentRing{0%{opacity:.75;transform:scale(.85)}100%{opacity:0;transform:scale(1.16)}}

.fx-tactic{
  position:fixed;
  width:78px;
  height:78px;
  transform:translate(-50%,-50%);
  display:grid;
  place-items:center;
  border-radius:50%;
  pointer-events:none;
  z-index:10001;
  animation:fxTacticBurst 1s ease-out forwards;
}
.fx-tactic span{font-size:44px;filter:drop-shadow(0 0 10px #fff);}
.fx-tactic.lightning{background:radial-gradient(circle,#ecf7ffcc 0 12%,#8bd7ff77 30%,transparent 68%);box-shadow:0 0 26px #9fe4ff;}
.fx-tactic.firestorm{background:radial-gradient(circle,#fff0a8cc 0 10%,#ff782c88 34%,transparent 70%);box-shadow:0 0 30px #ff6a2f;}
.fx-tactic.hqdamage{background:radial-gradient(circle,#ffe7aacc,#e43b2d88 38%,transparent 72%);}
.fx-tactic.defdown{background:radial-gradient(circle,#c8d6e5aa,#55697c77 40%,transparent 72%);}
.fx-tactic.draw{background:radial-gradient(circle,#d9c2ffbb,#7454b877 40%,transparent 72%);}
.fx-tactic.clone{background:radial-gradient(circle,#e9f6ffbb,#78b9d477 40%,transparent 72%);}
.fx-tactic.supply,.fx-tactic.hqheal{background:radial-gradient(circle,#efffcbbb,#66cf7a77 40%,transparent 72%);}
@keyframes fxTacticBurst{
  0%{opacity:0;transform:translate(-50%,-50%) scale(.35) rotate(-12deg)}
  22%{opacity:1;transform:translate(-50%,-50%) scale(1.18) rotate(4deg)}
  70%{opacity:1;transform:translate(-50%,-50%) scale(.98) rotate(0)}
  100%{opacity:0;transform:translate(-50%,-50%) scale(1.45)}
}
.fx-item-equip{
  position:fixed;
  width:92px;
  height:92px;
  transform:translate(-50%,-50%);
  border-radius:50%;
  border:2px solid #ffe2a0;
  background:radial-gradient(circle,#fff4c9cc 0 12%,#d49b4077 36%,transparent 70%);
  box-shadow:0 0 28px #ffd36f;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:3px;
  animation:fxItemEquip 1.15s ease-out forwards;
  z-index:10001;
}
.fx-item-equip.linked{border-color:#b9ecff;box-shadow:0 0 32px #82dbff;background:radial-gradient(circle,#f3fdffdd 0 12%,#62bddd77 38%,transparent 72%);}
.fx-item-equip .icon{font-size:34px;filter:drop-shadow(0 0 8px #fff);}
.fx-item-equip .label{padding:2px 5px;background:#090c10dc;border:1px solid #ffffff66;color:#fff4d6;font-size:9px;font-weight:900;white-space:nowrap;}
@keyframes fxItemEquip{
  0%{opacity:0;transform:translate(-50%,-50%) scale(.25) rotate(-25deg)}
  25%{opacity:1;transform:translate(-50%,-50%) scale(1.15) rotate(5deg)}
  72%{opacity:1;transform:translate(-50%,-50%) scale(1)}
  100%{opacity:0;transform:translate(-50%,-50%) scale(1.3)}
}

.fx-lightning-field{
  position:fixed;pointer-events:none;border:1px solid #b9ebff99;
  background:linear-gradient(180deg,#d9f5ff3d,#77cfff17 45%,#ffffff16);
  box-shadow:inset 0 0 55px #bdefff66,0 0 42px #77d8ff55;
  animation:lightningFieldFlash .9s steps(2,end) forwards;
}
@keyframes lightningFieldFlash{0%{opacity:0}8%{opacity:1}18%{opacity:.12}28%{opacity:.95}42%{opacity:.18}58%{opacity:.75}100%{opacity:0}}
.fx-lightning-strike{
  position:fixed;width:90px;transform:translateX(-50%);pointer-events:none;z-index:10004;
  filter:drop-shadow(0 0 8px #d9f7ff) drop-shadow(0 0 20px #5cc8ff);
}
.fx-lightning-strike .bolt{position:absolute;display:block;background:linear-gradient(90deg,#ffffff,#aeeaff 45%,#fff);clip-path:polygon(45% 0,70% 0,56% 38%,83% 34%,35% 100%,45% 58%,18% 62%);}
.fx-lightning-strike .bolt.main{left:31px;top:0;width:28px;height:calc(100% - 10px);animation:lightningBolt .62s steps(2,end) forwards;}
.fx-lightning-strike .bolt.branch{width:16px;height:42%;bottom:12px;opacity:.8;}
.fx-lightning-strike .bolt.branch.a{left:20px;transform:rotate(-22deg);}
.fx-lightning-strike .bolt.branch.b{right:18px;transform:rotate(24deg);}
.fx-lightning-strike .impact{position:absolute;left:50%;bottom:-13px;width:86px;height:34px;transform:translateX(-50%);border-radius:50%;background:radial-gradient(ellipse,#fff 0 8%,#a9eaffaa 20%,#55bfff55 45%,transparent 72%);box-shadow:0 0 28px #9ee9ff;animation:lightningImpact .75s ease-out forwards;}
@keyframes lightningBolt{0%{opacity:0;transform:scaleY(.15)}18%{opacity:1;transform:scaleY(1)}28%{opacity:.12}42%{opacity:1}58%{opacity:.2}72%{opacity:.9}100%{opacity:0}}
@keyframes lightningImpact{0%{opacity:0;transform:translateX(-50%) scale(.2)}25%{opacity:1;transform:translateX(-50%) scale(1.2)}100%{opacity:0;transform:translateX(-50%) scale(1.7)}}
.fx-tactic.morale{width:120px;height:120px;border:2px solid #ffe296;background:radial-gradient(circle,#fff4bdcc 0 10%,#e2a83588 35%,transparent 72%);box-shadow:0 0 40px #ffd66f;}
.fx-tactic.morale::before,.fx-tactic.morale::after{content:'';position:absolute;inset:10px;border:2px solid #ffe8a5;border-radius:50%;animation:moraleWave .95s ease-out forwards;}
.fx-tactic.morale::after{animation-delay:.18s;}
@keyframes moraleWave{0%{opacity:1;transform:scale(.3)}100%{opacity:0;transform:scale(1.65)}}
.fx-tactic.discord{background:radial-gradient(circle,#ead7ffcc 0 12%,#7b3faf88 38%,transparent 72%);box-shadow:0 0 30px #b670ff;}

.event-image-manager{margin-top:12px;padding:10px;border:1px solid #705739;background:#0a1019cc;display:grid;gap:9px}
.event-image-note{font-size:10px;line-height:1.45;color:#c9d4e2}
.event-image-setting{padding:8px;border:1px solid #4b6078;background:#101a27;transition:opacity .18s ease,filter .18s ease}
.event-image-setting.disabled{opacity:.42;filter:grayscale(.75)}
.event-image-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:6px;font-size:11px;color:#f0d6a3}
.event-image-head span{font-size:9px;color:#9fb0c4}
.event-image-preview{position:relative;height:82px;overflow:hidden;border:1px solid #35475c;background:linear-gradient(135deg,#111b27,#05080d);display:flex;align-items:center;justify-content:center;color:#7f91a8;font-size:10px;margin-bottom:6px}
.event-image-preview img{width:100%;height:100%;object-fit:cover;object-position:center}
.event-image-preview .event-image-source{position:absolute;right:4px;bottom:4px;padding:2px 5px;background:#02050bd9;border:1px solid #ffffff2b;color:#dce8f5;font-size:8px}
.event-image-preview.dedicated{border-color:#c79a4f;box-shadow:inset 0 0 18px #eab75b17}

.hq-card-scene{position:absolute;inset:0;z-index:80;overflow:hidden;pointer-events:none;background:#02050a;isolation:isolate}
.hq-card-scene img{position:absolute;inset:-4%;width:108%;height:108%;object-fit:cover;object-position:center;filter:saturate(1.08) contrast(1.05);will-change:transform,opacity,filter}
.hq-card-scene .scene-shade{position:absolute;inset:0;z-index:2;background:linear-gradient(180deg,#0000 35%,#02050ad9 100%);box-shadow:inset 0 0 30px #000}
.hq-card-scene .scene-energy{position:absolute;inset:0;z-index:3}
.hq-card-scene .scene-label{position:absolute;left:8px;right:8px;bottom:6px;z-index:5;padding:4px 7px;background:#05080dd9;border:1px solid #ffffff38;color:#f4ead7;font-size:10px;font-weight:900;letter-spacing:.04em;text-align:center;text-shadow:0 1px 4px #000}
.hq-card-scene.leaving{animation:hqSceneLeave .28s ease-in forwards}
@keyframes hqSceneLeave{to{opacity:0;filter:blur(2px)}}

.hq-card-scene.summon img{animation:hqSummonImage 1.05s cubic-bezier(.13,.78,.2,1) forwards}
.hq-card-scene.summon .scene-energy{background:linear-gradient(90deg,transparent 8%,#9ddcff00 28%,#dff8ffb8 49%,#fff 50%,#dff8ffb8 51%,#9ddcff00 72%,transparent 92%);mix-blend-mode:screen;animation:hqSummonBeam 1.05s ease-out forwards}
.hq-card-scene.summon::before,.hq-card-scene.summon::after{content:'';position:absolute;z-index:4;left:50%;top:50%;width:18px;height:18px;border:2px solid #d9f6ff;border-radius:50%;box-shadow:0 0 18px #8bdfff;transform:translate(-50%,-50%);animation:hqSummonRing 1s ease-out forwards}
.hq-card-scene.summon::after{animation-delay:.13s}
@keyframes hqSummonImage{0%{opacity:0;transform:translateY(18%) scale(calc(var(--scene-scale,1) * 1.18));filter:brightness(2.1) blur(7px)}38%{opacity:1;transform:translateY(5%) scale(calc(var(--scene-scale,1) * .96));filter:brightness(1.35) blur(0)}100%{opacity:1;transform:translateY(0) scale(var(--scene-scale,1));filter:brightness(1)}}
@keyframes hqSummonBeam{0%{opacity:0;transform:scaleX(.12)}28%{opacity:1;transform:scaleX(.65)}100%{opacity:0;transform:scaleX(1.4)}}
@keyframes hqSummonRing{0%{opacity:.95;transform:translate(-50%,-50%) scale(.25)}100%{opacity:0;transform:translate(-50%,-50%) scale(9)}}

.hq-card-scene.battle img{animation:hqBattleImage .82s cubic-bezier(.36,.07,.19,.97) forwards}
.hq-card-scene.battle .scene-energy{background:linear-gradient(118deg,transparent 42%,#fff8 48%,#ffb34d 50%,#ff3b20b8 52%,transparent 58%);mix-blend-mode:screen;animation:hqBattleSlash .76s ease-out forwards}
.hq-card-scene.battle::before,.hq-card-scene.battle::after{content:'';position:absolute;z-index:4;left:50%;top:48%;width:120%;height:3px;background:linear-gradient(90deg,transparent,#fff,#ff993b,transparent);box-shadow:0 0 14px #ff743b;transform:translate(-50%,-50%) rotate(24deg) scaleX(0);animation:hqBattleCut .72s ease-out forwards}
.hq-card-scene.battle::after{transform:translate(-50%,-50%) rotate(-20deg) scaleX(0);animation-delay:.08s}
@keyframes hqBattleImage{0%{opacity:0;transform:translate(0,0) scale(calc(var(--scene-scale,1) * 1.04))}12%{opacity:1}20%,40%,60%{transform:translate(-3px,0) rotate(-.7deg) scale(var(--scene-scale,1))}30%,50%,70%{transform:translate(4px,0) rotate(.7deg) scale(var(--scene-scale,1))}100%{transform:translate(0,0) rotate(0) scale(var(--scene-scale,1));filter:saturate(1.2) contrast(1.12)}}
@keyframes hqBattleSlash{0%{opacity:0;transform:translateX(-70%)}28%{opacity:1}100%{opacity:0;transform:translateX(70%)}}
@keyframes hqBattleCut{0%{opacity:0;transform:translate(-50%,-50%) rotate(24deg) scaleX(0)}35%{opacity:1;transform:translate(-50%,-50%) rotate(24deg) scaleX(1)}100%{opacity:0;transform:translate(-50%,-50%) rotate(24deg) scaleX(1.25)}}
.hq-card-scene.battle::after{animation-name:hqBattleCutReverse}
@keyframes hqBattleCutReverse{0%{opacity:0;transform:translate(-50%,-50%) rotate(-20deg) scaleX(0)}35%{opacity:1;transform:translate(-50%,-50%) rotate(-20deg) scaleX(1)}100%{opacity:0;transform:translate(-50%,-50%) rotate(-20deg) scaleX(1.25)}}

.hq-card-scene.tactic img{animation:hqTacticImage 1.25s ease-out forwards}
.hq-card-scene.tactic .scene-energy{background:radial-gradient(circle at center,#fff 0 2%,#b58cffb8 8%,#572fd78f 22%,transparent 52%);mix-blend-mode:screen;animation:hqTacticPulse 1.2s ease-out forwards}
.hq-card-scene.tactic::before,.hq-card-scene.tactic::after{content:'✦ ᚱ ✧ ᛟ ✦ ᚨ ✧';position:absolute;z-index:4;left:50%;top:48%;width:112px;height:112px;border:2px solid #d9c6ff;border-radius:50%;display:flex;align-items:center;justify-content:center;color:#f2eaff;font-size:13px;letter-spacing:5px;text-shadow:0 0 8px #b688ff;box-shadow:0 0 18px #8e5eff,inset 0 0 18px #6a3acf;transform:translate(-50%,-50%) scale(.2);animation:hqMagicCircle 1.2s ease-out forwards}
.hq-card-scene.tactic::after{width:74px;height:74px;animation-direction:reverse;animation-duration:1s}
@keyframes hqTacticImage{0%{opacity:0;transform:translateY(0) scale(calc(var(--scene-scale,1) * 1.10));filter:hue-rotate(35deg) brightness(1.8) blur(5px)}30%{opacity:1;filter:hue-rotate(15deg) brightness(1.3) blur(0)}100%{transform:translateY(0) scale(var(--scene-scale,1));filter:hue-rotate(0) brightness(1.05)}}
@keyframes hqTacticPulse{0%{opacity:0;transform:scale(.25)}35%{opacity:1}100%{opacity:0;transform:scale(1.8)}}
@keyframes hqMagicCircle{0%{opacity:0;transform:translate(-50%,-50%) scale(.2) rotate(-100deg)}28%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(1.45) rotate(130deg)}}

body.no-anim .hq-card-scene:not(.stage-preview){display:none!important}

.hq-card-scene img{inset:0!important;width:100%!important;height:100%!important;object-position:var(--scene-x,50%) var(--scene-y,50%)!important;transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;}
.hq-card-scene.summon img,.hq-card-scene.battle img,.hq-card-scene.tactic img{animation-duration:1.25s!important;animation-fill-mode:forwards!important;}
.hq-card-scene.holding img{animation:none!important;transform:scale(var(--scene-scale,1))!important;opacity:1!important;filter:saturate(1.05) contrast(1.03)!important;transition:transform .18s ease!important;}
.hq-card-scene.holding .scene-energy,.hq-card-scene.holding::before,.hq-card-scene.holding::after{animation-play-state:paused!important;opacity:.32!important;}
.hq-card-scene.leaving{animation:hqSceneLeave .32s ease-in forwards!important;}
@keyframes hqSceneLeave{to{opacity:0;filter:brightness(.72)}}

.battlefield-card-scene{position:fixed!important;inset:auto!important;z-index:140;border-radius:16px;box-shadow:0 18px 40px #000a,0 0 0 1px #ffffff22;backdrop-filter:blur(2px)}
.hq-card-scene .scene-effect-caption{position:absolute;left:10px;right:10px;top:10px;z-index:6;display:flex;flex-direction:column;gap:4px;align-items:center;text-align:center}
.hq-card-scene .scene-effect-caption:empty{display:none}
.hq-card-scene .scene-title-big{padding:4px 10px;border-radius:999px;background:#09111ddb;border:1px solid #ffffff40;color:#fff6dd;font-size:18px;font-weight:900;letter-spacing:.06em;text-shadow:0 2px 6px #000}
.hq-card-scene .scene-title-small{padding:4px 10px;border-radius:999px;background:#03070cd4;border:1px solid #ffffff24;color:#eef6ff;font-size:11px;font-weight:700;line-height:1.3;text-shadow:0 1px 4px #000}
.hq-card-scene.death img{animation:hqDeathImage 1.06s ease-out forwards}
.hq-card-scene.death .scene-energy{background:radial-gradient(circle at center,#ffccd633 0 8%,#7d001199 28%,#15020ab8 62%,transparent 80%);mix-blend-mode:screen;animation:hqDeathPulse 1s ease-out forwards}
.hq-card-scene.death::before,.hq-card-scene.death::after{content:'';position:absolute;z-index:4;left:50%;top:50%;width:120%;height:120%;border:2px solid #ff9bb355;border-radius:50%;transform:translate(-50%,-50%) scale(.2);animation:hqDeathRing 1s ease-out forwards}
.hq-card-scene.death::after{animation-delay:.08s}
@keyframes hqDeathImage{0%{transform:scale(1.2);opacity:0;filter:brightness(1.8)}30%{opacity:1}100%{transform:scale(var(--scene-scale,1));opacity:1;filter:saturate(1.02) contrast(1.04)}}
@keyframes hqDeathPulse{0%{opacity:0;transform:scale(.5)}25%{opacity:1}100%{opacity:.2;transform:scale(1.08)}}
@keyframes hqDeathRing{0%{opacity:0;transform:translate(-50%,-50%) scale(.2)}30%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(1.18)}}
.hq-card-scene.fx-beam .scene-energy{background:linear-gradient(90deg,transparent 8%,#9ddcff00 28%,#dff8ffb8 49%,#fff 50%,#dff8ffb8 51%,#9ddcff00 72%,transparent 92%)!important}
.hq-card-scene.fx-flare .scene-energy{background:radial-gradient(circle at center,#fff6 0 8%,#ffe6a7d0 18%,#ff7a21a8 34%,transparent 62%)!important}
.hq-card-scene.fx-lightning .scene-energy{background:linear-gradient(120deg,transparent 34%,#d4ebff00 42%,#f9ffff 48%,#7fc6ff 50%,#f9ffff 52%,transparent 60%),radial-gradient(circle at center,#a9d7ff99 0 15%,transparent 55%)!important}
.hq-card-scene.fx-fire .scene-energy{background:radial-gradient(circle at center,#ffefbb77 0 10%,#ffb34dc9 20%,#ff4b2ba8 38%,transparent 68%)!important}
.hq-card-scene.fx-ice .scene-energy{background:radial-gradient(circle at center,#f8ffff77 0 12%,#b7f0ffd0 24%,#65bde9b0 38%,transparent 68%)!important}
.hq-card-scene.fx-smoke .scene-energy{background:radial-gradient(circle at center,#ffffff33 0 12%,#c9d1dc66 25%,#5a64757a 46%,transparent 72%)!important}
.hq-card-scene.fx-petals .scene-energy{background:radial-gradient(circle at center,#ffd5ef55 0 8%,#ff9ad2a8 22%,transparent 58%)!important}
.hq-card-scene.fx-shadow .scene-energy{background:radial-gradient(circle at center,#7b5cff66 0 12%,#2a154eaa 28%,#05030bbd 56%,transparent 78%)!important}
.hq-card-scene.fx-holy .scene-energy{background:radial-gradient(circle at center,#fffbe6aa 0 10%,#fff2b0d0 26%,#ffd56fb0 42%,transparent 72%)!important}
.hq-card-scene.fx-shock .scene-energy{background:linear-gradient(135deg,transparent 30%,#ffffff 50%,transparent 70%),radial-gradient(circle at center,#a7d8ff88 0 14%,transparent 50%)!important}
.hq-card-scene.fx-runes .scene-energy{background:radial-gradient(circle at center,#f1e6ff88 0 10%,#c69cffb8 20%,#5631c8a8 36%,transparent 66%)!important}
.hq-card-scene.fx-blood .scene-energy{background:radial-gradient(circle at center,#ff9bb355 0 12%,#c61134ba 30%,#3f000ab4 54%,transparent 76%)!important}

.battlefield-center-scene{position:fixed!important;inset:auto!important;z-index:160!important;border-radius:22px!important;border:2px solid #ffffff55!important;box-shadow:0 28px 70px #000d,0 0 36px #9fdcff55!important}
.battlefield-center-scene .scene-title-big{font-size:26px!important;padding:7px 18px!important}
.battlefield-center-scene .scene-title-small{font-size:13px!important;max-width:92%;line-height:1.45!important}
.hq-card-scene .scene-particles{position:absolute;inset:0;z-index:4;overflow:hidden;pointer-events:none}
.hq-card-scene .scene-particles i{position:absolute;display:block;opacity:0}

.hq-card-scene.fx-beam .scene-particles i{left:calc(12% * var(--n,1));bottom:-15%;width:3px;height:70%;background:linear-gradient(transparent,#efffff,transparent);animation:sceneBeamRise 1.2s ease-out forwards}
.hq-card-scene.fx-beam .scene-particles i:nth-child(1){--n:1}.hq-card-scene.fx-beam .scene-particles i:nth-child(2){--n:2;animation-delay:.06s}.hq-card-scene.fx-beam .scene-particles i:nth-child(3){--n:3;animation-delay:.12s}.hq-card-scene.fx-beam .scene-particles i:nth-child(4){--n:4;animation-delay:.18s}.hq-card-scene.fx-beam .scene-particles i:nth-child(5){--n:5;animation-delay:.24s}.hq-card-scene.fx-beam .scene-particles i:nth-child(6){--n:6;animation-delay:.3s}.hq-card-scene.fx-beam .scene-particles i:nth-child(7){--n:7;animation-delay:.36s}.hq-card-scene.fx-beam .scene-particles i:nth-child(8){--n:8;animation-delay:.42s}
.hq-card-scene.fx-flare .scene-particles i{left:50%;top:50%;width:6px;height:6px;border-radius:50%;background:#fff4b4;box-shadow:0 0 10px #ffbf45;animation:sceneFlareBurst 1s ease-out forwards}.hq-card-scene.fx-flare .scene-particles i:nth-child(2){--a:45deg}.hq-card-scene.fx-flare .scene-particles i:nth-child(3){--a:90deg}.hq-card-scene.fx-flare .scene-particles i:nth-child(4){--a:135deg}.hq-card-scene.fx-flare .scene-particles i:nth-child(5){--a:180deg}.hq-card-scene.fx-flare .scene-particles i:nth-child(6){--a:225deg}.hq-card-scene.fx-flare .scene-particles i:nth-child(7){--a:270deg}.hq-card-scene.fx-flare .scene-particles i:nth-child(8){--a:315deg}
.hq-card-scene.fx-lightning .scene-particles i{top:-20%;width:5px;height:78%;background:linear-gradient(170deg,transparent 0 20%,#eaffff 21% 27%,transparent 28% 40%,#7ac8ff 41% 50%,transparent 51%);filter:drop-shadow(0 0 7px #6bc5ff);animation:sceneLightningDrop .8s steps(2) forwards}.hq-card-scene.fx-lightning .scene-particles i:nth-child(odd){left:24%;transform:rotate(8deg)}.hq-card-scene.fx-lightning .scene-particles i:nth-child(even){right:24%;transform:rotate(-9deg);animation-delay:.12s}
.hq-card-scene.fx-fire .scene-particles i{bottom:-18%;width:18px;height:28px;border-radius:60% 40% 70% 30%;background:radial-gradient(circle at 50% 70%,#fff2a3,#ff8a25 42%,#e32016 70%,transparent 72%);animation:sceneFireRise 1.25s ease-out forwards}.hq-card-scene.fx-fire .scene-particles i:nth-child(1){left:10%}.hq-card-scene.fx-fire .scene-particles i:nth-child(2){left:22%;animation-delay:.12s}.hq-card-scene.fx-fire .scene-particles i:nth-child(3){left:34%;animation-delay:.04s}.hq-card-scene.fx-fire .scene-particles i:nth-child(4){left:46%;animation-delay:.18s}.hq-card-scene.fx-fire .scene-particles i:nth-child(5){left:58%;animation-delay:.08s}.hq-card-scene.fx-fire .scene-particles i:nth-child(6){left:70%;animation-delay:.22s}.hq-card-scene.fx-fire .scene-particles i:nth-child(7){left:82%;animation-delay:.14s}.hq-card-scene.fx-fire .scene-particles i:nth-child(8){left:90%;animation-delay:.26s}
.hq-card-scene.fx-ice .scene-particles i{left:50%;top:50%;width:4px;height:48%;background:linear-gradient(#efffff,#72d9ff,transparent);transform-origin:50% 100%;animation:sceneIceGrow 1.1s ease-out forwards}.hq-card-scene.fx-ice .scene-particles i:nth-child(2){--r:45deg}.hq-card-scene.fx-ice .scene-particles i:nth-child(3){--r:90deg}.hq-card-scene.fx-ice .scene-particles i:nth-child(4){--r:135deg}.hq-card-scene.fx-ice .scene-particles i:nth-child(5){--r:180deg}.hq-card-scene.fx-ice .scene-particles i:nth-child(6){--r:225deg}.hq-card-scene.fx-ice .scene-particles i:nth-child(7){--r:270deg}.hq-card-scene.fx-ice .scene-particles i:nth-child(8){--r:315deg}
.hq-card-scene.fx-smoke .scene-particles i{bottom:-10%;width:55px;height:55px;border-radius:50%;background:radial-gradient(circle,#e7edf288,#6c748077 55%,transparent 72%);filter:blur(4px);animation:sceneSmokeDrift 1.55s ease-out forwards}.hq-card-scene.fx-smoke .scene-particles i:nth-child(odd){left:12%}.hq-card-scene.fx-smoke .scene-particles i:nth-child(even){right:12%;animation-delay:.18s}
.hq-card-scene.fx-petals .scene-particles i{top:-12%;width:10px;height:16px;border-radius:80% 20% 80% 20%;background:#ff9fd1;box-shadow:0 0 6px #ffd8ed;animation:scenePetalFall 1.5s ease-in forwards}.hq-card-scene.fx-petals .scene-particles i:nth-child(1){left:8%}.hq-card-scene.fx-petals .scene-particles i:nth-child(2){left:20%;animation-delay:.15s}.hq-card-scene.fx-petals .scene-particles i:nth-child(3){left:34%;animation-delay:.3s}.hq-card-scene.fx-petals .scene-particles i:nth-child(4){left:48%;animation-delay:.08s}.hq-card-scene.fx-petals .scene-particles i:nth-child(5){left:60%;animation-delay:.22s}.hq-card-scene.fx-petals .scene-particles i:nth-child(6){left:72%;animation-delay:.36s}.hq-card-scene.fx-petals .scene-particles i:nth-child(7){left:84%;animation-delay:.12s}.hq-card-scene.fx-petals .scene-particles i:nth-child(8){left:92%;animation-delay:.28s}
.hq-card-scene.fx-shadow .scene-particles i{left:50%;top:50%;width:74%;height:74%;border:3px solid #7d4cff77;border-radius:50%;box-shadow:inset 0 0 25px #19092f,0 0 18px #7d4cff;animation:sceneShadowVortex 1.3s ease-out forwards}.hq-card-scene.fx-shadow .scene-particles i:nth-child(n+3){width:48%;height:48%;animation-direction:reverse;animation-delay:.12s}
.hq-card-scene.fx-holy .scene-particles i{left:50%;top:-8%;width:5px;height:110%;background:linear-gradient(transparent,#fffbe8,#ffd775,transparent);transform-origin:50% 50%;animation:sceneHolyRay 1.25s ease-out forwards}.hq-card-scene.fx-holy .scene-particles i:nth-child(2){--r:22deg}.hq-card-scene.fx-holy .scene-particles i:nth-child(3){--r:-22deg}.hq-card-scene.fx-holy .scene-particles i:nth-child(4){--r:42deg}.hq-card-scene.fx-holy .scene-particles i:nth-child(5){--r:-42deg}.hq-card-scene.fx-holy .scene-particles i:nth-child(6){--r:62deg}.hq-card-scene.fx-holy .scene-particles i:nth-child(7){--r:-62deg}.hq-card-scene.fx-holy .scene-particles i:nth-child(8){--r:90deg}
.hq-card-scene.fx-shock .scene-particles i{left:50%;top:50%;width:22px;height:22px;border:3px solid #d8f4ff;border-radius:50%;transform:translate(-50%,-50%);animation:sceneShockWave 1.05s ease-out forwards}.hq-card-scene.fx-shock .scene-particles i:nth-child(2){animation-delay:.1s}.hq-card-scene.fx-shock .scene-particles i:nth-child(3){animation-delay:.2s}.hq-card-scene.fx-shock .scene-particles i:nth-child(4){animation-delay:.3s}
.hq-card-scene.fx-runes .scene-particles i{left:50%;top:50%;width:72%;height:72%;border:2px dashed #e8d6ff;border-radius:50%;box-shadow:0 0 18px #985fff,inset 0 0 18px #5c28a0;transform:translate(-50%,-50%);animation:sceneRuneSpin 1.5s linear forwards}.hq-card-scene.fx-runes .scene-particles i:nth-child(n+2){width:48%;height:48%;animation-direction:reverse}
.hq-card-scene.fx-blood .scene-particles i{top:-12%;width:9px;height:18px;border-radius:50% 50% 65% 65%;background:linear-gradient(#ff7b91,#a1001c);box-shadow:0 0 8px #e4002b;animation:sceneBloodDrop 1.1s ease-in forwards}.hq-card-scene.fx-blood .scene-particles i:nth-child(1){left:12%}.hq-card-scene.fx-blood .scene-particles i:nth-child(2){left:26%;animation-delay:.08s}.hq-card-scene.fx-blood .scene-particles i:nth-child(3){left:40%;animation-delay:.16s}.hq-card-scene.fx-blood .scene-particles i:nth-child(4){left:54%;animation-delay:.24s}.hq-card-scene.fx-blood .scene-particles i:nth-child(5){left:68%;animation-delay:.12s}.hq-card-scene.fx-blood .scene-particles i:nth-child(6){left:82%;animation-delay:.2s}.hq-card-scene.fx-blood .scene-particles i:nth-child(7){left:90%;animation-delay:.28s}.hq-card-scene.fx-blood .scene-particles i:nth-child(8){left:6%;animation-delay:.32s}

.fx-stat-change{position:fixed;z-index:190;transform:translate(-50%,-50%);display:flex;flex-direction:column;align-items:center;gap:3px;pointer-events:none;animation:statChangeFloat 1.2s ease-out forwards;text-align:center;text-shadow:0 2px 6px #000}
.fx-stat-change b{padding:5px 10px;border-radius:999px;font-size:16px;font-weight:950;white-space:nowrap;border:1px solid #ffffff66;box-shadow:0 5px 18px #0008}
.fx-stat-change small{padding:2px 7px;border-radius:999px;background:#05080dd9;color:#fff;font-size:10px;font-weight:800;white-space:nowrap}
.fx-stat-change.positive b{background:#0b8b4fe8;color:#eafff3}.fx-stat-change.negative b{background:#a51b35e8;color:#fff0f3}
.unit.stat-change-pulse{animation:unitStatPulse .9s ease-out!important;z-index:20!important}
@keyframes sceneBeamRise{0%{opacity:0;transform:translateY(25%)}35%{opacity:1}100%{opacity:0;transform:translateY(-25%)}}
@keyframes sceneFlareBurst{0%{opacity:0;transform:translate(-50%,-50%) rotate(var(--a,0deg)) translateX(0) scale(.2)}25%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) rotate(var(--a,0deg)) translateX(155px) scale(1.2)}}
@keyframes sceneLightningDrop{0%{opacity:0;transform:translateY(-30%) rotate(8deg)}35%{opacity:1}70%{opacity:.35}100%{opacity:0;transform:translateY(35%) rotate(-5deg)}}
@keyframes sceneFireRise{0%{opacity:0;transform:translateY(0) scale(.4)}35%{opacity:1}100%{opacity:0;transform:translateY(-210px) scale(1.6) rotate(18deg)}}
@keyframes sceneIceGrow{0%{opacity:0;transform:translate(-50%,-100%) rotate(var(--r,0deg)) scaleY(.05)}45%{opacity:1}100%{opacity:0;transform:translate(-50%,-100%) rotate(var(--r,0deg)) scaleY(1)}}
@keyframes sceneSmokeDrift{0%{opacity:0;transform:translateY(30px) scale(.5)}45%{opacity:.9}100%{opacity:0;transform:translate(70px,-130px) scale(1.8)}}
@keyframes scenePetalFall{0%{opacity:0;transform:translateY(-15px) rotate(0)}25%{opacity:1}100%{opacity:0;transform:translate(55px,260px) rotate(520deg)}}
@keyframes sceneShadowVortex{0%{opacity:0;transform:translate(-50%,-50%) scale(.2) rotate(0)}40%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(1.35) rotate(300deg)}}
@keyframes sceneHolyRay{0%{opacity:0;transform:rotate(var(--r,0deg)) scaleY(.1)}35%{opacity:1}100%{opacity:0;transform:rotate(var(--r,0deg)) scaleY(1)}}
@keyframes sceneShockWave{0%{opacity:0;transform:translate(-50%,-50%) scale(.15)}35%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(14)}}
@keyframes sceneRuneSpin{0%{opacity:0;transform:translate(-50%,-50%) scale(.2) rotate(0)}35%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(1.1) rotate(420deg)}}
@keyframes sceneBloodDrop{0%{opacity:0;transform:translateY(-15px) scale(.5)}30%{opacity:1}100%{opacity:0;transform:translateY(260px) scale(1.2)}}
@keyframes statChangeFloat{0%{opacity:0;transform:translate(-50%,-20%) scale(.65)}20%{opacity:1;transform:translate(-50%,-55%) scale(1.08)}75%{opacity:1}100%{opacity:0;transform:translate(-50%,-145%) scale(.96)}}
@keyframes unitStatPulse{0%{filter:brightness(1)}25%{filter:brightness(1.7) saturate(1.5);transform:scale(1.04)}100%{filter:brightness(1);transform:scale(1)}}

.hq-card-scene.fx-warcry .scene-energy{background:radial-gradient(ellipse at center,#fff4bd66 0 8%,#f1a532a8 22%,#8b3b12a0 42%,transparent 72%)!important}
.hq-card-scene.fx-warcry .scene-particles i{left:50%;top:50%;width:20px;height:20px;border:4px solid #ffe7a6;border-radius:50%;box-shadow:0 0 16px #ff9b35;transform:translate(-50%,-50%);animation:sceneWarcryRing 1.2s cubic-bezier(.15,.72,.25,1) forwards}
.hq-card-scene.fx-warcry .scene-particles i:nth-child(2){animation-delay:.09s}.hq-card-scene.fx-warcry .scene-particles i:nth-child(3){animation-delay:.18s}.hq-card-scene.fx-warcry .scene-particles i:nth-child(n+4){display:none}
.hq-card-scene.fx-dragon .scene-energy{background:conic-gradient(from 0deg at 50% 50%,transparent,#8fffd488,#36cfa1aa,#b9fff0aa,transparent 72%)!important;mix-blend-mode:screen}
.hq-card-scene.fx-dragon .scene-particles i{left:50%;top:50%;width:12px;height:12px;border-radius:55% 45% 70% 30%;background:#b9fff0;box-shadow:0 0 13px #35e1b0;animation:sceneDragonSpiral 1.45s ease-out forwards}
.hq-card-scene.fx-dragon .scene-particles i:nth-child(2){--a:45deg;animation-delay:.05s}.hq-card-scene.fx-dragon .scene-particles i:nth-child(3){--a:90deg;animation-delay:.1s}.hq-card-scene.fx-dragon .scene-particles i:nth-child(4){--a:135deg;animation-delay:.15s}.hq-card-scene.fx-dragon .scene-particles i:nth-child(5){--a:180deg;animation-delay:.2s}.hq-card-scene.fx-dragon .scene-particles i:nth-child(6){--a:225deg;animation-delay:.25s}.hq-card-scene.fx-dragon .scene-particles i:nth-child(7){--a:270deg;animation-delay:.3s}.hq-card-scene.fx-dragon .scene-particles i:nth-child(8){--a:315deg;animation-delay:.35s}
.hq-card-scene.fx-ascend .scene-energy{background:linear-gradient(180deg,transparent 12%,#d8e8ff33 40%,#f5fbff99 76%,transparent 100%)!important}
.hq-card-scene.fx-ascend .scene-particles i{bottom:-18%;width:18px;height:28px;border-radius:50%;background:radial-gradient(circle at 45% 38%,#fff,#bed6ff 42%,#6d87b8aa 68%,transparent 72%);filter:blur(.3px);animation:sceneSoulAscend 1.6s ease-out forwards}
.hq-card-scene.fx-ascend .scene-particles i:nth-child(1){left:10%}.hq-card-scene.fx-ascend .scene-particles i:nth-child(2){left:22%;animation-delay:.1s}.hq-card-scene.fx-ascend .scene-particles i:nth-child(3){left:35%;animation-delay:.2s}.hq-card-scene.fx-ascend .scene-particles i:nth-child(4){left:48%;animation-delay:.04s}.hq-card-scene.fx-ascend .scene-particles i:nth-child(5){left:60%;animation-delay:.14s}.hq-card-scene.fx-ascend .scene-particles i:nth-child(6){left:72%;animation-delay:.24s}.hq-card-scene.fx-ascend .scene-particles i:nth-child(7){left:84%;animation-delay:.08s}.hq-card-scene.fx-ascend .scene-particles i:nth-child(8){left:92%;animation-delay:.18s}
@keyframes sceneWarcryRing{0%{opacity:0;transform:translate(-50%,-50%) scale(.15)}28%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(18,9)}}
@keyframes sceneDragonSpiral{0%{opacity:0;transform:translate(-50%,-50%) rotate(var(--a,0deg)) translateX(18px) scale(.3)}28%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) rotate(calc(var(--a,0deg) + 620deg)) translateX(170px) scale(1.45)}}
@keyframes sceneSoulAscend{0%{opacity:0;transform:translateY(20px) scale(.55)}25%{opacity:1}70%{opacity:.8}100%{opacity:0;transform:translate(35px,-300px) scale(1.5)}}

.hq-card-scene{--fx-speed:1.35s}
.hq-card-scene .scene-energy{opacity:.96!important}
.hq-card-scene .scene-particles{filter:saturate(1.35) brightness(1.12)}

.hq-card-scene.fx-beam img{animation:fxBeamPortrait 1.35s cubic-bezier(.12,.75,.18,1) forwards!important}
.hq-card-scene.fx-beam::before{content:'';position:absolute;z-index:3;left:34%;right:34%;top:-20%;bottom:-20%;background:linear-gradient(90deg,transparent,#eaffff66,#fff,#eaffff66,transparent);filter:blur(5px);mix-blend-mode:screen;animation:fxBeamColumn 1.25s ease-out forwards}
@keyframes fxBeamPortrait{0%{opacity:0;transform:scale(.72) translateY(24%);filter:brightness(2.5) blur(7px)}42%{opacity:1;filter:brightness(1.65) blur(0)}100%{transform:scale(var(--scene-scale,1));filter:saturate(1.15) contrast(1.08)}}
@keyframes fxBeamColumn{0%{opacity:0;transform:scaleX(.15)}30%{opacity:1;transform:scaleX(1.25)}100%{opacity:0;transform:scaleX(2)}}

.hq-card-scene.fx-flare img{animation:fxFlarePortrait 1.2s ease-out forwards!important}
.hq-card-scene.fx-flare::before,.hq-card-scene.fx-flare::after{content:'';position:absolute;z-index:4;inset:-45%;background:conic-gradient(from 0deg,transparent 0 5%,#fff 6% 8%,transparent 9% 18%,#ffc76b 19% 22%,transparent 23% 34%,#fff 35% 37%,transparent 38% 100%);animation:fxFlareSpin 1.1s ease-out forwards}
.hq-card-scene.fx-flare::after{animation-direction:reverse;filter:blur(4px)}
@keyframes fxFlarePortrait{0%{opacity:0;transform:scale(1.65);filter:brightness(4)}28%{opacity:1;transform:scale(.92);filter:brightness(2.1)}100%{transform:scale(var(--scene-scale,1));filter:contrast(1.08)}}
@keyframes fxFlareSpin{0%{opacity:0;transform:rotate(0) scale(.1)}30%{opacity:1}100%{opacity:0;transform:rotate(230deg) scale(1.1)}}

.hq-card-scene.fx-lightning{animation:fxLightningScreen 1.25s steps(2) forwards}
.hq-card-scene.fx-lightning img{animation:fxLightningPortrait 1.2s steps(2) forwards!important}
.hq-card-scene.fx-lightning::before{content:'';position:absolute;z-index:5;left:46%;top:-20%;width:12%;height:130%;background:linear-gradient(165deg,transparent 0 18%,#fff 19% 27%,transparent 28% 38%,#80d8ff 39% 52%,transparent 53% 100%);filter:drop-shadow(0 0 14px #56bdff);animation:fxBoltStrike 1s steps(2) forwards}
@keyframes fxLightningScreen{0%,18%,42%,65%{filter:brightness(.55)}10%,28%,52%{filter:brightness(2.5)}100%{filter:none}}
@keyframes fxLightningPortrait{0%{opacity:0;transform:scale(1.12)}18%{opacity:1;filter:brightness(3) contrast(1.5)}100%{transform:scale(var(--scene-scale,1));filter:contrast(1.12)}}
@keyframes fxBoltStrike{0%,15%,36%{opacity:0}16%,37%,55%{opacity:1}100%{opacity:0}}

.hq-card-scene.fx-fire{background:#260300!important;animation:fxFireScreen 1.65s ease-out forwards}
.hq-card-scene.fx-fire img{animation:fxBurnPortrait 1.6s ease-out forwards!important}
.hq-card-scene.fx-fire::before{content:'';position:absolute;z-index:4;inset:18% -5% -25%;background:repeating-radial-gradient(ellipse at 50% 100%,#fff2a7 0 4%,#ff9a22 5% 12%,#e32310 13% 21%,transparent 22% 31%);filter:blur(3px) saturate(1.8);mix-blend-mode:screen;animation:fxFireWall .72s ease-in-out infinite alternate}
.hq-card-scene.fx-fire::after{content:'';position:absolute;z-index:5;inset:0;background:linear-gradient(0deg,#ff2d00a8,transparent 55%),radial-gradient(circle at 50% 70%,transparent 10%,#ff6a0033 45%,#210000aa 100%);animation:fxHeatWave .22s linear infinite alternate}
@keyframes fxFireScreen{0%{box-shadow:inset 0 0 0 #000}45%{box-shadow:inset 0 -55px 80px #ff3100cc}100%{box-shadow:inset 0 -30px 50px #6c0800aa}}
@keyframes fxBurnPortrait{0%{opacity:0;transform:scale(.88) translateY(18%);filter:brightness(.25) sepia(1)}25%{opacity:1;filter:brightness(1.8) sepia(.6) saturate(2.5)}70%{transform:scale(calc(var(--scene-scale,1) * 1.05));filter:contrast(1.3) saturate(1.8)}100%{transform:scale(var(--scene-scale,1));filter:contrast(1.1) saturate(1.2)}}
@keyframes fxFireWall{from{transform:translateY(12%) scaleY(.82)}to{transform:translateY(-8%) scaleY(1.18)}}
@keyframes fxHeatWave{from{transform:translateX(-2px) skewX(-1deg)}to{transform:translateX(2px) skewX(1deg)}}

.hq-card-scene.fx-ice{background:#031a2a!important;animation:fxFreezeScreen 1.55s ease-out forwards}
.hq-card-scene.fx-ice img{animation:fxFreezePortrait 1.5s ease-out forwards!important}
.hq-card-scene.fx-ice::before{content:'';position:absolute;inset:-2%;z-index:5;background:linear-gradient(135deg,#eaffff99 0 2%,transparent 3% 18%,#b8ecff88 19% 21%,transparent 22% 42%,#fff9 43% 45%,transparent 46%),radial-gradient(circle at 50% 50%,transparent 0 18%,#bceeff55 45%,#dff9ffcc 100%);clip-path:polygon(0 0,100% 0,100% 100%,0 100%);animation:fxIceSheet 1.35s ease-out forwards}
.hq-card-scene.fx-ice::after{content:'❄';position:absolute;z-index:6;inset:0;display:grid;place-items:center;color:#efffff;font-size:84px;text-shadow:0 0 25px #8be4ff;animation:fxIceBurst 1.4s ease-out forwards}
@keyframes fxFreezeScreen{0%{filter:brightness(.4) saturate(.3)}38%{filter:brightness(1.7) saturate(.65) hue-rotate(155deg)}100%{filter:brightness(1.05) saturate(.75) hue-rotate(165deg)}}
@keyframes fxFreezePortrait{0%{opacity:0;transform:scale(1.18);filter:blur(8px) brightness(2)}45%{opacity:1;filter:contrast(1.3) saturate(.2) hue-rotate(165deg)}100%{transform:scale(var(--scene-scale,1));filter:contrast(1.2) saturate(.45) hue-rotate(165deg)}}
@keyframes fxIceSheet{0%{opacity:0;transform:scale(.1)}45%{opacity:1}100%{opacity:.62;transform:scale(1.15)}}
@keyframes fxIceBurst{0%{opacity:0;transform:scale(.1) rotate(-40deg)}45%{opacity:1}100%{opacity:0;transform:scale(2.4) rotate(35deg)}}

.hq-card-scene.fx-smoke img{animation:fxSmokePortrait 1.6s ease-out forwards!important}
.hq-card-scene.fx-smoke::before,.hq-card-scene.fx-smoke::after{content:'';position:absolute;z-index:5;width:95%;height:95%;border-radius:50%;background:radial-gradient(circle,#d9e0e5cc 0 12%,#737b8499 40%,transparent 72%);filter:blur(15px);animation:fxSmokeCloud 1.7s ease-out forwards}
.hq-card-scene.fx-smoke::before{left:-35%;bottom:-35%}.hq-card-scene.fx-smoke::after{right:-35%;top:-30%;animation-delay:.18s}
@keyframes fxSmokePortrait{0%{opacity:0;filter:blur(18px)}45%{opacity:.65;filter:blur(5px)}100%{opacity:1;transform:scale(var(--scene-scale,1));filter:contrast(1.02)}}
@keyframes fxSmokeCloud{0%{opacity:0;transform:scale(.4)}55%{opacity:.95}100%{opacity:0;transform:translate(45%, -35%) scale(1.75)}}

.hq-card-scene.fx-petals img{animation:fxPetalPortrait 1.5s ease-out forwards!important}
.hq-card-scene.fx-petals::before{content:'✦  ❀  ✿  ❁  ✦  ❀  ✿';position:absolute;z-index:5;inset:-20%;color:#ffb2dc;font-size:28px;letter-spacing:22px;text-shadow:0 0 10px #ff78c0;animation:fxPetalStorm 1.6s cubic-bezier(.2,.7,.2,1) forwards}
@keyframes fxPetalPortrait{0%{opacity:0;transform:translateX(-25%) rotate(-5deg) scale(.9)}45%{opacity:1;transform:translateX(3%) rotate(1deg) scale(1.05)}100%{transform:scale(var(--scene-scale,1))}}
@keyframes fxPetalStorm{0%{opacity:0;transform:translate(-20%,-30%) rotate(-30deg) scale(.5)}35%{opacity:1}100%{opacity:0;transform:translate(30%,55%) rotate(210deg) scale(1.25)}}

.hq-card-scene.fx-shadow{animation:fxShadowScreen 1.55s ease-out forwards}
.hq-card-scene.fx-shadow img{animation:fxShadowPortrait 1.5s ease-out forwards!important}
.hq-card-scene.fx-shadow::before{content:'';position:absolute;z-index:5;left:50%;top:50%;width:150%;height:150%;border-radius:50%;background:repeating-conic-gradient(#0000 0 14deg,#6d3ac988 15deg 24deg,#05010c 25deg 40deg);mix-blend-mode:screen;animation:fxShadowSpiral 1.5s ease-in forwards}
@keyframes fxShadowScreen{0%{background:#000}55%{background:#090217}100%{background:#02030a}}
@keyframes fxShadowPortrait{0%{opacity:0;transform:scale(.4) rotate(-14deg);filter:brightness(.1)}55%{opacity:1;transform:scale(1.12) rotate(2deg);filter:brightness(1.4) saturate(.7)}100%{transform:scale(var(--scene-scale,1));filter:contrast(1.1)}}
@keyframes fxShadowSpiral{0%{opacity:0;transform:translate(-50%,-50%) scale(.05) rotate(0)}55%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(1.1) rotate(520deg)}}

.hq-card-scene.fx-holy img{animation:fxHolyPortrait 1.5s ease-out forwards!important}
.hq-card-scene.fx-holy::before{content:'';position:absolute;z-index:5;inset:-25%;background:repeating-conic-gradient(from 0deg,#fff0 0 8deg,#fff8d5cc 9deg 13deg,#fff0 14deg 28deg);mix-blend-mode:screen;animation:fxHolyBurst 1.45s ease-out forwards}
.hq-card-scene.fx-holy::after{content:'✦';position:absolute;z-index:6;inset:0;display:grid;place-items:center;font-size:88px;color:#fff9cf;text-shadow:0 0 30px #ffd45c;animation:fxHolySymbol 1.4s ease-out forwards}
@keyframes fxHolyPortrait{0%{opacity:0;transform:translateY(30%) scale(.8);filter:brightness(3)}45%{opacity:1;transform:translateY(-4%) scale(1.08);filter:brightness(1.7)}100%{transform:scale(var(--scene-scale,1));filter:brightness(1.08)}}
@keyframes fxHolyBurst{0%{opacity:0;transform:rotate(-40deg) scale(.2)}40%{opacity:1}100%{opacity:0;transform:rotate(60deg) scale(1.1)}}
@keyframes fxHolySymbol{0%{opacity:0;transform:scale(.1)}45%{opacity:1}100%{opacity:0;transform:scale(2.2)}}

.hq-card-scene.fx-shock{animation:fxImpactShake 1.1s ease-out forwards}
.hq-card-scene.fx-shock img{animation:fxImpactPortrait 1.2s ease-out forwards!important}
.hq-card-scene.fx-shock::before,.hq-card-scene.fx-shock::after{content:'';position:absolute;z-index:5;left:50%;top:58%;width:30px;height:14px;border:5px solid #d8f6ff;border-radius:50%;box-shadow:0 0 24px #71d6ff;animation:fxImpactRing 1.1s ease-out forwards}
.hq-card-scene.fx-shock::after{animation-delay:.16s}
@keyframes fxImpactShake{0%,100%{transform:translate(0)}18%{transform:translate(-9px,4px)}32%{transform:translate(8px,-3px)}46%{transform:translate(-5px,2px)}60%{transform:translate(3px,-1px)}}
@keyframes fxImpactPortrait{0%{opacity:0;transform:scale(1.5) translateY(-15%)}32%{opacity:1;transform:scale(.88) translateY(8%)}100%{transform:scale(var(--scene-scale,1))}}
@keyframes fxImpactRing{0%{opacity:0;transform:translate(-50%,-50%) scale(.1)}30%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(15,8)}}

.hq-card-scene.fx-runes img{animation:fxRunePortrait 1.55s ease-out forwards!important}
.hq-card-scene.fx-runes::before,.hq-card-scene.fx-runes::after{content:'ᚱ ᛟ ᚨ ᚾ ᛇ ᛉ';position:absolute;z-index:5;left:50%;top:50%;width:74%;height:74%;border:3px solid #d8baff;border-radius:50%;display:flex;align-items:center;justify-content:center;color:#f0e4ff;font-size:20px;letter-spacing:14px;text-shadow:0 0 12px #a05cff;box-shadow:0 0 28px #8f51ff,inset 0 0 28px #54228d;animation:fxRuneCircle 1.6s linear forwards}
.hq-card-scene.fx-runes::after{width:48%;height:48%;animation-direction:reverse}
@keyframes fxRunePortrait{0%{opacity:0;transform:scale(.65);filter:hue-rotate(90deg) brightness(2)}50%{opacity:1;transform:scale(1.08)}100%{transform:scale(var(--scene-scale,1));filter:contrast(1.08)}}
@keyframes fxRuneCircle{0%{opacity:0;transform:translate(-50%,-50%) scale(.2) rotate(0)}35%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(1.15) rotate(540deg)}}

.hq-card-scene.fx-blood{background:#170005!important}
.hq-card-scene.fx-blood img{animation:fxBloodPortrait 1.5s ease-out forwards!important}
.hq-card-scene.fx-blood::before{content:'';position:absolute;z-index:5;inset:-10%;background:radial-gradient(circle at 20% 30%,#ff334499 0 3%,transparent 4%),radial-gradient(circle at 70% 22%,#a8001eaa 0 5%,transparent 6%),radial-gradient(circle at 85% 65%,#ff254099 0 4%,transparent 5%),radial-gradient(circle at 35% 78%,#8d001baa 0 6%,transparent 7%);animation:fxBloodSplash 1.3s ease-out forwards}
@keyframes fxBloodPortrait{0%{opacity:0;transform:scale(1.25);filter:grayscale(1) brightness(.25)}42%{opacity:1;filter:sepia(.8) saturate(3) hue-rotate(320deg)}100%{transform:scale(var(--scene-scale,1));filter:contrast(1.2) saturate(1.25)}}
@keyframes fxBloodSplash{0%{opacity:0;transform:scale(.2) rotate(-25deg)}40%{opacity:1}100%{opacity:0;transform:scale(1.6) rotate(20deg)}}

.hq-card-scene.fx-warcry{animation:fxWarcryShake 1.4s ease-out forwards}
.hq-card-scene.fx-warcry img{animation:fxWarcryPortrait 1.35s ease-out forwards!important}
.hq-card-scene.fx-warcry::before{content:'喝!';position:absolute;z-index:6;right:8%;top:12%;color:#fff0b0;font-size:58px;font-weight:1000;text-shadow:0 0 20px #ff7b22;animation:fxWarcryText 1.2s ease-out forwards}
@keyframes fxWarcryShake{0%,100%{transform:translate(0)}25%{transform:translate(-6px)}38%{transform:translate(6px)}51%{transform:translate(-4px)}64%{transform:translate(3px)}}
@keyframes fxWarcryPortrait{0%{opacity:0;transform:translateX(-35%) scale(1.25)}38%{opacity:1;transform:translateX(4%) scale(1.1)}100%{transform:scale(var(--scene-scale,1))}}
@keyframes fxWarcryText{0%{opacity:0;transform:scale(.1) rotate(-15deg)}40%{opacity:1;transform:scale(1.25) rotate(5deg)}100%{opacity:0;transform:scale(1.8) rotate(8deg)}}

.hq-card-scene.fx-dragon img{animation:fxDragonPortrait 1.7s ease-out forwards!important}
.hq-card-scene.fx-dragon::before{content:'龍';position:absolute;z-index:6;left:50%;top:50%;color:#d9fff2;font-size:108px;font-weight:1000;text-shadow:0 0 30px #1cffb2;animation:fxDragonGlyph 1.6s ease-out forwards}
.hq-card-scene.fx-dragon::after{content:'';position:absolute;z-index:5;left:50%;top:50%;width:140%;height:80%;border:10px solid #73ffd2;border-left-color:transparent;border-bottom-color:transparent;border-radius:50%;filter:drop-shadow(0 0 15px #24d9a6);animation:fxDragonArc 1.55s ease-out forwards}
@keyframes fxDragonPortrait{0%{opacity:0;transform:scale(.4) rotate(-12deg);filter:hue-rotate(80deg) brightness(2)}55%{opacity:1;transform:scale(1.12) rotate(1deg)}100%{transform:scale(var(--scene-scale,1));filter:contrast(1.08)}}
@keyframes fxDragonGlyph{0%{opacity:0;transform:translate(-50%,-50%) scale(.1) rotate(-30deg)}45%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(2) rotate(25deg)}}
@keyframes fxDragonArc{0%{opacity:0;transform:translate(-50%,-50%) scale(.15) rotate(-80deg)}45%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(1.15) rotate(380deg)}}

.hq-card-scene.fx-ascend img{animation:fxAscendPortrait 1.65s ease-out forwards!important}
.hq-card-scene.fx-ascend::before{content:'';position:absolute;z-index:5;left:15%;right:15%;bottom:-20%;height:120%;background:linear-gradient(0deg,#dcecffcc,transparent 72%);clip-path:polygon(0 100%,20% 0,38% 100%,50% 8%,65% 100%,82% 0,100% 100%);filter:blur(5px);animation:fxAscendRays 1.6s ease-out forwards}
@keyframes fxAscendPortrait{0%{opacity:0;transform:translateY(35%) scale(.85);filter:brightness(2)}40%{opacity:1}100%{transform:translateY(-8%) scale(var(--scene-scale,1));filter:brightness(1.2)}}
@keyframes fxAscendRays{0%{opacity:0;transform:translateY(30%)}40%{opacity:1}100%{opacity:0;transform:translateY(-20%) scaleY(1.35)}}

.hq-card-scene.fx-requiem{background:#02030a!important;animation:fxRequiemScreen 1.7s ease-out forwards}
.hq-card-scene.fx-requiem img{animation:fxRequiemPortrait 1.65s cubic-bezier(.2,.62,.24,1) forwards!important}
.hq-card-scene.fx-requiem::before{content:'✧  ✦  ◇  ✧  ✦';position:absolute;z-index:6;inset:0;display:grid;place-items:center;color:#e9f1ff;font-size:30px;letter-spacing:20px;text-shadow:0 0 16px #8ba8ff;animation:fxSoulFragments 1.6s ease-out forwards}
.hq-card-scene.fx-requiem::after{content:'';position:absolute;z-index:5;left:50%;top:50%;width:8px;height:8px;border:3px solid #e4edff;border-radius:50%;box-shadow:0 0 24px #91aaff;animation:fxSoulCollapse 1.55s ease-in-out forwards}
@keyframes fxRequiemScreen{0%{filter:brightness(1)}55%{filter:grayscale(1) brightness(.5)}100%{filter:grayscale(.8) brightness(.8)}}
@keyframes fxRequiemPortrait{0%{opacity:1;transform:scale(var(--scene-scale,1));filter:grayscale(0)}35%{opacity:1;transform:scale(1.04);filter:grayscale(.6) brightness(1.4)}100%{opacity:0;transform:translateY(-28%) scale(.55);filter:grayscale(1) blur(9px)}}
@keyframes fxSoulFragments{0%{opacity:0;transform:translateY(25%) scale(.5)}40%{opacity:1}100%{opacity:0;transform:translateY(-80%) scale(1.8) rotate(35deg)}}
@keyframes fxSoulCollapse{0%{opacity:0;transform:translate(-50%,-50%) scale(18)}55%{opacity:1}100%{opacity:0;transform:translate(-50%,-50%) scale(.05)}}

:root{
  
  --dock-action-h:58px;
  --dock-hq-h:176px;
  --dock-hand-h:174px;
  --dock-total-h:calc(var(--dock-action-h) + var(--dock-hq-h) + var(--dock-hand-h));
}

body.ui-mode-mobile:not(.prebattle) .bottom-hud{
  bottom:0!important;
}
body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount{
  bottom:var(--dock-action-h)!important;
  height:var(--dock-hq-h)!important;
  min-height:var(--dock-hq-h)!important;
  max-height:var(--dock-hq-h)!important;
  padding:6px 6px 8px!important;
  overflow:visible!important;
}
body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount{
  bottom:calc(var(--dock-action-h) + var(--dock-hq-h))!important;
}

body.ui-mode-mobile:not(.prebattle) .app,
body.ui-mode-mobile:not(.prebattle){
  padding-bottom:calc(var(--dock-total-h) + env(safe-area-inset-bottom,0px) + 10px)!important;
}

body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .ally-hq-row,
body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq,
body.ui-mode-mobile:not(.prebattle) .enemy-hq-row,
body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq{
  height:168px!important;
  min-height:168px!important;
  max-height:168px!important;
  overflow:visible!important;
}

body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-info-overlay,
body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-info-overlay{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-template-rows:repeat(2,minmax(0,1fr))!important;
  gap:5px 7px!important;
  align-content:center!important;
}
body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip,
body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:4px!important;
  width:auto!important;
  height:auto!important;
  min-height:24px!important;
  padding:4px 6px!important;
  font-size:12px!important;
  border-radius:6px!important;
}
body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip .hq-stat-icon,
body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip .hq-stat-icon{
  font-size:15px!important;
  line-height:1!important;
  flex:none!important;
}
body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip .hq-stat-value,
body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip b,
body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip .hq-stat-value,
body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip b{
  font-size:16px!important;
  font-weight:900!important;
  line-height:1.1!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}

body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip.skill,
body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip.skill{
  display:flex!important;
}

body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-actions .btn{
  font-size:16px!important;
  font-weight:950!important;
  letter-spacing:-0.02em!important;
}

.card-art-img,
.unit-art-img,
.manager-preview img{
  object-position:var(--img-x,50%) var(--img-y,50%)!important;
  transform:scale(var(--img-scale-x,var(--img-scale,1)),var(--img-scale-y,var(--img-scale,1)))!important;
  transform-origin:var(--img-x,50%) var(--img-y,50%)!important;
  transition:transform .12s ease,object-position .12s ease;
}

.card-art-img.auto-folder-art,
.unit-art-img.auto-folder-art{
  object-position:var(--img-x,50%) var(--img-y,50%)!important;
  transform:scale(var(--img-scale-x,var(--img-scale,1)),var(--img-scale-y,var(--img-scale,1)))!important;
  transform-origin:var(--img-x,50%) var(--img-y,50%)!important;
}

.manager-name-save-field .manager-name-save-inline{
  display:flex;
  align-items:center;
  gap:8px;
}
.manager-name-save-inline #mgrName{
  flex:1 1 auto;
  min-width:0;
  max-width:220px;
}
.manager-name-save-inline #managerSaveBtn{
  flex:0 0 auto;
  white-space:nowrap;
  padding:8px 16px;
}
@media (max-width:520px){
  .manager-name-save-inline{
    flex-wrap:wrap;
  }
  .manager-name-save-inline #mgrName{
    max-width:none;
    flex:1 1 140px;
  }
}

.manager-bulk-image-box{margin:10px 0;padding:12px;border:1px dashed rgba(255,255,255,.28);border-radius:10px;background:rgba(0,0,0,.18);display:grid;gap:6px;text-align:left}
.manager-bulk-image-box.drop-ready{border-color:#e5bd62;background:rgba(229,189,98,.12);box-shadow:0 0 0 2px rgba(229,189,98,.12) inset}
.manager-bulk-image-box>strong{font-size:14px}.manager-bulk-image-box>span{font-size:12px}.manager-bulk-image-box>small{font-size:11px;line-height:1.45;opacity:.82}
.manager-bulk-image-actions{display:flex;flex-wrap:wrap;gap:6px;margin-top:4px}.manager-bulk-image-actions input{position:absolute;width:1px;height:1px;opacity:0;pointer-events:none}
.manager-bulk-image-status{max-height:150px;overflow:auto;white-space:pre-line;padding:8px;border-radius:7px;background:rgba(0,0,0,.24);font-size:11px;line-height:1.5}
.manager-bulk-image-status.success{color:#bce9c2}.manager-bulk-image-status.warning{color:#ffe09a}.manager-bulk-image-status.error{color:#ffb3b3}

#relationshipEventModal .modalbox{width:min(1120px,96vw);max-height:92vh;overflow:auto}.rel-event-layout{display:grid;grid-template-columns:minmax(280px,.8fr) minmax(480px,1.35fr);gap:14px}.rel-panel{border:1px solid #735737;background:linear-gradient(180deg,#17130f,#0b0d10);padding:12px}.rel-panel-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:10px}.rel-panel-head h3{margin:0}.rel-event-list{display:grid;gap:8px;max-height:620px;overflow:auto}.rel-event-card{border:1px solid #8b6a42;background:#10151b;padding:10px;display:grid;gap:7px}.rel-event-card.disabled{opacity:.55}.rel-event-card-head,.rel-card-actions{display:flex;align-items:center;justify-content:space-between;gap:8px}.rel-condition{color:#f0d3a4;font-size:12px}.rel-effect-summary{font-size:11px;color:#c8d6e6;line-height:1.5}.rel-card-actions{justify-content:flex-end}.rel-card-actions .danger{border-color:#8f4141;color:#ffb6b6}.rel-editor{display:grid;gap:12px}.rel-editor>label{display:grid;gap:5px}.rel-section{border:1px solid #394a5c;padding:10px;background:#090e14}.rel-section-title{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.rel-rows{display:grid;gap:7px}.rel-row{display:grid;gap:7px;align-items:end}.rel-required-row{grid-template-columns:1fr auto}.rel-effect-row{grid-template-columns:minmax(140px,1fr) repeat(3,78px) auto}.rel-effect-row label{display:grid;gap:3px;font-size:10px}.rel-row select,.rel-row input,#relEventName{width:100%;min-height:34px;background:#080c11;color:#f1e7d6;border:1px solid #526476;padding:6px}.rel-editor-actions{display:flex;justify-content:flex-end;gap:8px}.rel-empty{padding:28px 8px;text-align:center;color:#9eabba;border:1px dashed #536170}.manager-head-actions #openRelationshipEventsBtn{border-color:#b77b38;color:#ffe0ac}@media(max-width:850px){.rel-event-layout{grid-template-columns:1fr}.rel-effect-row{grid-template-columns:1fr repeat(3,1fr)}.rel-effect-row .rel-remove{grid-column:1/-1}}
.rel-visual-grid{display:grid;grid-template-columns:1.3fr .7fr .7fr;gap:8px}.rel-visual-grid label{display:grid;gap:4px;font-size:11px}.rel-visual-grid input,.rel-visual-grid select{width:100%;min-height:36px;background:#080c11;color:#f1e7d6;border:1px solid #526476;padding:6px}.rel-image-tools{display:flex;align-items:center;gap:10px;margin-top:8px}.rel-image-preview{margin-top:8px;aspect-ratio:16/6;max-height:210px;border:1px dashed #607488;background:#05080c;display:flex;align-items:center;justify-content:center;overflow:hidden;color:#8493a3}.rel-image-preview img{width:100%;height:100%;object-fit:contain}.rel-card-thumb{height:86px;overflow:hidden;border:1px solid #4c5b69;background:#05080c}.rel-card-thumb img{width:100%;height:100%;object-fit:cover}.rel-visual-summary{font-size:10px;color:#e1bd78}.rel-event-presentation{position:fixed;inset:0;z-index:99999;display:flex;align-items:center;justify-content:center;pointer-events:none;opacity:0;visibility:hidden;transition:opacity .22s ease}.rel-event-presentation.show{opacity:1;visibility:visible}.rel-event-backdrop{position:absolute;inset:0;background:rgba(0,0,0,.68);backdrop-filter:blur(3px)}.rel-event-stage{position:relative;width:min(900px,92vw);padding:18px;text-align:center;transform:scale(.78);opacity:0}.rel-event-presentation.show .rel-event-stage{animation:relStageIn .55s cubic-bezier(.2,.9,.2,1) forwards}.rel-event-main-image{display:block;width:100%;max-height:55vh;object-fit:contain;border:2px solid rgba(255,229,157,.8);box-shadow:0 0 38px rgba(255,201,74,.5);background:#07090c}.rel-event-title{margin-top:12px;font-size:clamp(28px,5vw,62px);font-weight:900;letter-spacing:.08em;color:#fff3c2;text-shadow:0 3px 12px #000}.rel-event-side{font-size:clamp(14px,2vw,22px);color:#fff}.rel-event-effect-text{margin:8px auto 0;max-width:900px;font-size:clamp(12px,1.7vw,18px);color:#dce9f7}.effect-gold .rel-event-stage:before,.effect-flame .rel-event-stage:before,.effect-lightning .rel-event-stage:before,.effect-aura .rel-event-stage:before{content:"";position:absolute;inset:-45px;z-index:-1;border-radius:28px}.effect-gold .rel-event-stage:before{background:radial-gradient(circle,rgba(255,225,94,.8),rgba(255,145,0,.2) 42%,transparent 70%);animation:relPulse .75s infinite alternate}.effect-flame .rel-event-stage:before{background:radial-gradient(ellipse at bottom,rgba(255,72,0,.82),rgba(255,170,0,.22) 45%,transparent 72%);filter:blur(8px);animation:relFlame .5s infinite alternate}.effect-lightning .rel-event-stage:before{background:conic-gradient(from 35deg,transparent,#9fd6ff,transparent 12%,transparent 45%,#fff 48%,transparent 51%,transparent);filter:blur(5px);animation:relSpin 1.1s linear infinite}.effect-aura .rel-event-stage:before{background:radial-gradient(circle,rgba(197,111,255,.65),rgba(75,147,255,.25) 50%,transparent 72%);animation:relPulse 1.2s infinite alternate}.effect-none .rel-event-stage:before{display:none}@keyframes relStageIn{to{transform:scale(1);opacity:1}}@keyframes relPulse{from{transform:scale(.95);opacity:.55}to{transform:scale(1.04);opacity:1}}@keyframes relFlame{from{transform:translateY(5px) scale(.96)}to{transform:translateY(-6px) scale(1.04)}}@keyframes relSpin{to{transform:rotate(360deg)}}
@media(max-width:850px){.rel-visual-grid{grid-template-columns:1fr}.rel-event-stage{width:96vw;padding:8px}.rel-event-main-image{max-height:48vh}.rel-event-title{margin-top:7px}}

@media (min-width:851px){
  html,body{overflow:auto!important}
  .app{height:auto!important;min-height:0!important;align-items:start!important}
  .reference-left,.battle-panel,.reference-right{height:auto!important;min-height:0!important;max-height:none!important}
  .boardwrap{flex:0 0 auto!important;height:auto!important;min-height:0!important;max-height:none!important;overflow:visible!important}
  .battlefield-layout{height:auto!important;min-height:0!important}
  .battlefield-layout>.board{height:auto!important;min-height:0!important}
}

@media (max-width:850px){
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount{
    position:fixed!important;
    left:0!important;right:0!important;width:100%!important;
    bottom:var(--dock-action-h)!important;
    z-index:88!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount{
    position:fixed!important;
    left:0!important;right:0!important;width:100%!important;
    bottom:calc(var(--dock-action-h) + var(--dock-hq-h))!important;
    z-index:89!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud{
    position:fixed!important;
    left:0!important;right:0!important;width:100%!important;
    bottom:0!important;
    z-index:92!important;
  }
  
  body.ui-mode-mobile:not(.prebattle){
    -webkit-overflow-scrolling:touch!important;
    overscroll-behavior-y:contain!important;
  }
}

@media (max-width:850px){
  .battle-menu-card .battle-menu-selects{
    display:flex!important;
    flex-direction:column!important;
    gap:5px!important;
    min-width:0!important;
  }
  .battle-menu-card .battle-menu-selects select{
    width:100%!important;
  }
}

@media (max-width:850px){
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    height:142px!important;min-height:142px!important;max-height:142px!important;
    display:grid!important;
    grid-template-rows:20px minmax(0,1fr) 32px!important;
    overflow:hidden!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .cname,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-title-area{
    height:20px!important;min-height:20px!important;max-height:20px!important;
    display:flex!important;align-items:center!important;
    overflow:hidden!important;white-space:nowrap!important;
    position:relative!important;z-index:2!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-name-text{
    overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .cimg{
    height:100%!important;min-height:0!important;max-height:none!important;
    overflow:hidden!important;position:relative!important;z-index:1!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .cstats,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-stat-grid{
    height:32px!important;min-height:32px!important;max-height:32px!important;
    overflow:hidden!important;
  }
}

@media (max-width:850px){
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq{
    height:112px!important;min-height:112px!important;max-height:112px!important;
    overflow:visible!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .hq-advisor-slot{
    top:34px!important;height:58px!important;min-height:58px!important;
  }
}

.online-account-bar{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.online-user-chip{padding:7px 10px;border:1px solid rgba(232,196,108,.42);border-radius:8px;background:rgba(20,16,12,.82);font-size:12px}.online-role-admin{color:#ffd66b}.online-role-user{color:#b7d8ff}.match-mode-grid,.booster-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:12px}.match-card,.booster-card,.online-panel{border:1px solid rgba(232,196,108,.35);background:rgba(19,15,12,.88);border-radius:12px;padding:14px}.match-card h3,.booster-card h3{margin:0 0 8px}.match-status{margin-top:10px;padding:10px;border-radius:8px;background:rgba(0,0,0,.26);min-height:42px}.admin-only[hidden],.user-only[hidden]{display:none!important}.release-badge{display:inline-flex;padding:2px 7px;border-radius:999px;font-size:10px;font-weight:700;margin-left:4px}.release-released{background:#285d3b;color:#d7ffe2}.release-upcoming{background:#644f1f;color:#fff0af}.release-test{background:#493568;color:#eadcff}.online-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.online-form-grid label{display:grid;gap:5px;font-size:12px}.online-form-grid input,.online-form-grid select,.online-form-grid textarea{width:100%;box-sizing:border-box}.online-form-grid .full{grid-column:1/-1}.online-notice{font-size:12px;line-height:1.5;color:#d5c9b4}.booster-card .pack-art{font-size:44px;text-align:center;padding:12px}.mobile-online-actions{display:flex;gap:6px;flex-wrap:wrap;margin-top:8px}.opponent-human{outline:2px solid rgba(110,190,255,.55)}
@media(max-width:700px){.online-form-grid{grid-template-columns:1fr}.online-account-bar{font-size:11px}.match-mode-grid,.booster-grid{grid-template-columns:1fr}}
.visibility-badge{display:inline-flex;align-items:center;margin-left:5px;padding:2px 7px;border-radius:999px;font-size:11px;font-weight:700}
.visibility-public{background:#dff6e7;color:#176b37;border:1px solid #82c99b}
.visibility-private{background:#ececef;color:#555;border:1px solid #aaa}
.checkbox-line{display:flex!important;align-items:center;gap:8px;padding:10px;border:1px solid rgba(255,255,255,.15);border-radius:8px}
.checkbox-line input{width:auto!important;margin:0}
.wide-online-modal{width:min(1180px,96vw);max-width:none}.online-toolbar{display:grid;grid-template-columns:repeat(5,minmax(130px,1fr));gap:10px;margin:12px 0}.online-toolbar label{display:flex;flex-direction:column;gap:5px;font-size:12px}.online-table-wrap{max-height:62vh;overflow:auto;border:1px solid rgba(255,255,255,.14);border-radius:10px}.online-admin-table{width:100%;border-collapse:collapse;font-size:12px}.online-admin-table th,.online-admin-table td{padding:7px;border-bottom:1px solid rgba(255,255,255,.1);text-align:center;white-space:nowrap}.online-admin-table th{position:sticky;top:0;background:#171b25;z-index:2}.online-admin-table input,.online-admin-table select{min-width:58px;max-width:100px;padding:5px}.online-admin-table .name-cell{min-width:120px;text-align:left}.online-footer-actions{display:flex;justify-content:space-between;align-items:center;margin-top:12px}@media(max-width:760px){.online-toolbar{grid-template-columns:1fr 1fr}.wide-online-modal{width:98vw}.online-admin-table{min-width:900px}}

.auth-modalbox{width:min(720px,94vw);max-width:720px}
.auth-sections{display:grid;gap:14px;margin-top:12px}
.auth-section{padding:15px;border:1px solid rgba(232,196,108,.32);border-radius:12px;background:rgba(10,12,18,.44)}
.auth-section h3{margin:0 0 12px;font-size:16px;color:#f1d792}
.auth-reset-section{background:rgba(18,24,36,.55)}
.auth-actions{display:flex;gap:8px;justify-content:flex-end}
.auth-actions .btn{min-width:150px}
@media(max-width:700px){.auth-actions{justify-content:stretch}.auth-actions .btn{width:100%}}

html:not(.is-card-admin) #cardManagerBtn,
html:not(.is-card-admin) #mobileCardManagerBtn,
html:not(.is-card-admin) .admin-only{display:none!important}
.quick-stats-toolbar{grid-template-columns:repeat(4,minmax(120px,1fr)) minmax(220px,auto)}
.quick-stats-image-summary{align-self:end;min-height:34px;display:flex;align-items:center;justify-content:center;padding:0 10px;border:1px solid rgba(255,255,255,.14);border-radius:7px;background:rgba(0,0,0,.22);font-size:11px;white-space:nowrap}
.quick-stats-image-summary .registered-count{color:#8fe0a1}.quick-stats-image-summary .missing-count{color:#ffadad}
.quick-stats-table th:first-child,.quick-stats-table td:first-child{width:34px;min-width:34px;padding:3px}
.quick-stats-table th:nth-child(2),.quick-stats-table td:nth-child(2){width:56px;min-width:56px;padding-left:4px;padding-right:4px}
.qs-image-thumb{width:22px;height:30px;margin:auto;border:1px solid rgba(255,255,255,.28);border-radius:3px;overflow:hidden;background:rgba(255,255,255,.05);display:grid;place-items:center}
.qs-image-thumb img{width:100%;height:100%;object-fit:cover;display:block}
.qs-image-empty{font-size:13px;line-height:1;color:#ff9f9f;opacity:.8}
.qs-image-status{display:inline-flex;align-items:center;gap:3px;font-size:9px;padding:2px 5px;border-radius:999px;font-weight:700}
.qs-image-status i{display:block;width:5px;height:5px;border-radius:50%}
.qs-image-status.registered{color:#c9f7d2;background:rgba(45,130,67,.26);border:1px solid rgba(94,195,116,.42)}
.qs-image-status.registered i{background:#63db7c;box-shadow:0 0 5px rgba(99,219,124,.7)}
.qs-image-status.missing{color:#ffd0d0;background:rgba(150,55,55,.24);border:1px solid rgba(226,103,103,.4)}
.qs-image-status.missing i{background:#ef7272}
.quick-stats-table tr.qs-image-missing td:first-child,.quick-stats-table tr.qs-image-missing td:nth-child(2){background:rgba(121,32,32,.10)}
@media(max-width:760px){.quick-stats-toolbar{grid-template-columns:1fr 1fr}.quick-stats-image-summary{grid-column:1/-1}.quick-stats-table{min-width:980px}}

.match-waiting-notice{
  width:calc(100% - 12px);margin:2px 6px 7px;padding:8px 10px;
  border:1px solid rgba(255,190,61,.78);border-radius:8px;
  background:linear-gradient(180deg,rgba(69,45,8,.96),rgba(34,23,7,.96));
  color:#ffe7a2;font-weight:800;font-size:12px;line-height:1.35;text-align:left;
  cursor:pointer;box-shadow:0 0 0 1px rgba(255,205,89,.08) inset,0 3px 12px rgba(0,0,0,.25)
}
.match-waiting-notice:hover{filter:brightness(1.12);border-color:#ffd46d}
.match-waiting-notice[hidden]{display:none!important}
.match-waiting-dot{display:inline-block;width:8px;height:8px;margin-right:7px;border-radius:50%;background:#ffbf34;box-shadow:0 0 0 0 rgba(255,191,52,.65);animation:matchWaitingPulse 1.45s infinite;vertical-align:1px}
.match-waiting-notice strong{color:#fff3c8}
@keyframes matchWaitingPulse{0%{box-shadow:0 0 0 0 rgba(255,191,52,.62)}70%{box-shadow:0 0 0 7px rgba(255,191,52,0)}100%{box-shadow:0 0 0 0 rgba(255,191,52,0)}}
.mobile-advanced-setup .match-waiting-notice{grid-column:1/-1;width:100%;margin:3px 0 0}
body.ui-mode-mobile-preview #mobileMatchWaitingNotice{display:block}
.mobile-header-match-notice{width:calc(100% - 16px);margin:4px 8px 6px;position:relative;z-index:2}
.auth-remember{display:flex!important;align-items:center;gap:8px}.auth-remember input{width:auto!important}.online-opponent-banner{position:fixed;top:10px;left:50%;transform:translateX(-50%);z-index:9998;padding:8px 16px;border-radius:999px;background:rgba(12,20,32,.92);color:#fff;font-weight:700;box-shadow:0 4px 18px rgba(0,0,0,.3)}

.online-match-info-panel{margin-top:10px;padding:10px;border:1px solid rgba(205,170,93,.55);border-radius:10px;background:rgba(12,18,29,.92);color:#f5ead0;font-size:12px;line-height:1.45}
.online-match-info-title{font-weight:800;color:#ffd976;margin-bottom:5px}
.online-match-opponent{padding:6px 8px;border-radius:7px;background:rgba(255,255,255,.06);font-weight:700}
.online-match-log-title{margin-top:8px;color:#d6bd83;font-weight:700}
.online-match-game-log{margin-top:4px;max-height:130px;overflow:auto;padding:6px 8px;border-radius:7px;background:rgba(0,0,0,.25)}
.online-match-game-log>div{padding:3px 0;border-bottom:1px solid rgba(255,255,255,.07);word-break:break-word}
.online-match-game-log>div:first-child{color:#fff2ba}
#hand .card{pointer-events:auto!important;touch-action:manipulation;cursor:pointer;position:relative;z-index:2}
#hand .card.opening-hand-card{cursor:wait}
#hand .card.selected{z-index:6}
@media(max-width:900px){.mobile-online-match-info{display:block;margin:10px 0 0}.online-match-game-log{max-height:110px}}

.faction-auto-display{display:flex;gap:12px;align-items:center;flex-wrap:wrap}.faction-auto-display span{padding:6px 10px;border:1px solid rgba(255,255,255,.18);border-radius:8px;background:rgba(0,0,0,.2)}.faction-auto-display b{margin-left:4px}

html.login-required,body.login-required{overflow:hidden!important}
body.login-required .app,
body.login-required .mobile-game-header,
body.login-required .bottom-hud,
body.login-required #mobileMenuDrawer{pointer-events:none!important;user-select:none!important;filter:blur(1.5px) brightness(.42)!important}
body.login-required .modal:not(#loginModal){display:none!important}
body.login-required #loginModal{display:flex!important;opacity:1!important;visibility:visible!important;pointer-events:auto!important;z-index:50000!important}
body.login-required #loginModal [data-close-online="loginModal"]{display:none!important}
body.login-required #loginModal .modalbox{pointer-events:auto!important;filter:none!important}

.card-manager-box .manager-head{gap:8px!important;align-items:flex-start!important}
.card-manager-box .manager-head>div:first-child{min-width:0!important}
.card-manager-box .manager-head h2{font-size:16px!important;line-height:1.2!important;white-space:nowrap!important}
.card-manager-box .manager-head .small{font-size:10px!important;line-height:1.3!important}

.card-manager-box .manager-head-actions{display:flex!important;flex-wrap:wrap!important;gap:4px!important;align-items:center!important;justify-content:flex-end!important;overflow:visible!important;max-width:none!important;flex:1 1 auto!important;min-width:0!important}
.card-manager-box .manager-head-actions .btn{min-height:26px!important;height:26px!important;padding:3px 7px!important;font-size:10px!important;line-height:1!important;white-space:nowrap!important;flex:0 0 auto!important;border-radius:6px!important}
.manager-direct-image-drop-zone{width:100%;min-height:92px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;padding:12px;border:1.5px dashed rgba(79,182,255,.8);border-radius:10px;background:rgba(22,56,85,.42);text-align:center;cursor:pointer;transition:.15s ease}
.manager-direct-image-drop-zone:hover,.manager-direct-image-drop-zone:focus,.manager-direct-image-drop-zone.drop-ready{outline:none;border-color:#7ff0bd;background:rgba(23,104,85,.42);transform:translateY(-1px)}
.manager-direct-image-drop-zone strong{font-size:13px;color:#e9fbff}
.manager-direct-image-drop-zone span{font-size:10px;color:#b9d7e8;line-height:1.35}
.manager-direct-image-drop-zone small{font-size:9px;color:#8fa9b8}

.stat-maxed{color:#fff3b0!important;text-shadow:0 0 6px #ffe37acc,0 0 14px #ffcf4d80!important;font-weight:900!important}

.qs-image-thumb{cursor:pointer;position:relative;outline:none;transition:.15s ease}
.qs-image-thumb:hover,.qs-image-thumb:focus,.qs-image-thumb.drop-ready{box-shadow:0 0 0 2px #65e6bd,0 0 14px rgba(101,230,189,.35)!important;transform:scale(1.04)}
.qs-image-thumb.uploading{pointer-events:none;opacity:.55}
.qs-image-thumb.uploading:after{content:'저장 중';position:absolute;inset:0;display:grid;place-items:center;background:rgba(4,15,25,.75);font-size:8px;color:#fff}
.qs-image-thumb.just-registered{animation:qsImageRegisteredFlash 1.4s ease-out}
.qs-image-thumb.just-registered:after{content:'✓ 등록됨';position:absolute;inset:0;display:grid;place-items:center;background:rgba(20,90,60,.75);font-size:8px;color:#d6ffe9;font-weight:900;animation:qsImageRegisteredLabel 1.4s ease-out forwards}
@keyframes qsImageRegisteredFlash{0%{box-shadow:0 0 0 3px #65e6bd,0 0 18px rgba(101,230,189,.6)}100%{box-shadow:0 0 0 0 rgba(101,230,189,0)}}
@keyframes qsImageRegisteredLabel{0%{opacity:1}70%{opacity:1}100%{opacity:0}}

@media (min-width:851px){
  #hand.hand{grid-auto-rows:160px!important;grid-template-rows:repeat(2,160px)!important;align-content:start!important}
  #hand.hand .card{height:160px!important;min-height:160px!important;max-height:160px!important;grid-template-rows:24px minmax(0,1fr) 28px!important}
}

@media (max-width:850px){
  :root{
    --v173-mobile-hq-height:118px;
    --v173-mobile-hq-content-height:56px;
    --v173-mobile-hand-height:calc(var(--v129-field-card-height, 154px) + 32px);
  }
  body.ui-mode-mobile #hand.hand .card,
  body.ui-mode-mobile .mobile-hand-mount #hand .card{
    width:var(--mobile-card-width)!important;
    min-width:var(--mobile-card-width)!important;
    max-width:var(--mobile-card-width)!important;
    height:var(--v129-field-card-height)!important;
    min-height:var(--v129-field-card-height)!important;
    max-height:var(--v129-field-card-height)!important;
    grid-template-rows:calc(var(--mobile-card-width) * .2684) minmax(0,1fr) calc(var(--mobile-card-width) * .3131)!important;
  }
  body.ui-mode-mobile #hand.hand{
    grid-auto-rows:var(--v129-field-card-height)!important;
    grid-template-rows:var(--v129-field-card-height)!important;
    min-height:var(--v129-field-card-height)!important;
  }
  
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount{
    position:relative!important;inset:auto!important;left:auto!important;right:auto!important;top:auto!important;bottom:auto!important;transform:none!important;z-index:auto!important;width:100%!important;margin:4px 0!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount{height:var(--v173-mobile-hq-height)!important;min-height:var(--v173-mobile-hq-height)!important;max-height:var(--v173-mobile-hq-height)!important;padding:0!important}
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount{height:var(--v173-mobile-hand-height)!important;min-height:var(--v173-mobile-hand-height)!important;max-height:var(--v173-mobile-hand-height)!important;padding:0 4px!important;overflow:hidden!important}
  body.ui-mode-mobile:not(.prebattle) .bottom-hud{display:none!important}
  body.ui-mode-mobile:not(.prebattle),body.ui-mode-mobile:not(.prebattle) .app{padding-bottom:max(8px,env(safe-area-inset-bottom))!important}

  
  body.ui-mode-mobile .enemy-hq-row,
  body.ui-mode-mobile .ally-hq-row,
  body.ui-mode-mobile .battle-hq{
    height:var(--v173-mobile-hq-height)!important;
    min-height:var(--v173-mobile-hq-height)!important;
    max-height:var(--v173-mobile-hq-height)!important;
  }
  body.ui-mode-mobile .battle-hq{padding:0!important;overflow:hidden!important}
  body.ui-mode-mobile .battle-hq .hq-title{height:22px!important;min-height:22px!important;padding:3px 6px!important;font-size:10px!important;line-height:16px!important}
  body.ui-mode-mobile .battle-hq .hq-info-overlay{
    position:absolute!important;left:5px!important;right:calc(var(--mobile-card-width) + 10px)!important;top:25px!important;bottom:auto!important;height:var(--v173-mobile-hq-content-height)!important;min-height:var(--v173-mobile-hq-content-height)!important;display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;grid-template-rows:repeat(2,minmax(0,1fr))!important;gap:2px!important;padding:2px!important;border-radius:6px!important;
  }
  body.ui-mode-mobile .battle-hq .hq-stat-chip{min-height:0!important;height:auto!important;padding:1px 2px!important;font-size:8px!important;line-height:1!important}
  body.ui-mode-mobile .battle-hq .hq-stat-value{font-size:8px!important;line-height:1!important}
  body.ui-mode-mobile .battle-hq .hq-stat-icon{font-size:8px!important}
  body.ui-mode-mobile .battle-hq .hq-advisor-slot{
    position:absolute!important;right:5px!important;top:25px!important;bottom:auto!important;width:var(--mobile-card-width)!important;height:var(--v173-mobile-hq-content-height)!important;min-height:var(--v173-mobile-hq-content-height)!important;max-height:var(--v173-mobile-hq-content-height)!important;padding:0!important;border-radius:6px!important;overflow:hidden!important;
  }
  body.ui-mode-mobile .hq-advisor-slot .advisor-card,
  body.ui-mode-mobile .hq-advisor-slot .advisor-portrait{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;min-height:0!important;border-radius:5px!important;overflow:hidden!important}
  body.ui-mode-mobile .hq-advisor-slot .advisor-portrait img{width:100%!important;height:100%!important;object-fit:cover!important}
  body.ui-mode-mobile .hq-advisor-slot .advisor-slot-badge{position:absolute!important;left:0!important;right:0!important;bottom:0!important;height:17px!important;min-height:17px!important;padding:2px 3px!important;background:linear-gradient(transparent,rgba(2,8,16,.96))!important;display:flex!important;align-items:flex-end!important;justify-content:center!important;z-index:3!important}
  body.ui-mode-mobile .hq-advisor-slot .advisor-slot-badge b{display:block!important;width:100%!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important;text-align:center!important;font-size:8px!important;line-height:12px!important}
  body.ui-mode-mobile .hq-advisor-slot .advisor-slot-badge span{display:none!important}
  body.ui-mode-mobile .hq-advisor-slot .advisor-empty{font-size:8px!important;line-height:1.2!important;text-align:center!important;padding:4px!important}
  body.ui-mode-mobile .battle-hq .mobile-hq-actions{position:absolute!important;left:5px!important;right:5px!important;bottom:4px!important;top:auto!important;height:27px!important;min-height:27px!important;display:flex!important;align-items:stretch!important;gap:3px!important;z-index:8!important}
  body.ui-mode-mobile .battle-hq .mobile-hq-actions .btn,
  body.ui-mode-mobile .battle-hq .mobile-hq-actions button{min-height:27px!important;height:27px!important;padding:2px 5px!important;font-size:9px!important;line-height:1!important;white-space:nowrap!important}
  body.ui-mode-mobile .battle-hq .hq-turn-box{display:none!important}
}

@media (max-width:850px){
  :root{
    --v129-hand-card-height:var(--v129-field-card-height)!important;
    --mobile-hand-card-h:var(--v129-field-card-height)!important;
    --v120-hand-height:calc(var(--v129-field-card-height) + 32px)!important;
    --v122-mobile-hq-h:118px!important;
    --v120-hq-height:118px!important;
    --v120-bottom-total:calc(var(--v129-field-card-height) + 150px)!important;
  }

  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{
    height:var(--v129-field-card-height)!important;
    min-height:var(--v129-field-card-height)!important;
    max-height:var(--v129-field-card-height)!important;
    grid-auto-rows:var(--v129-field-card-height)!important;
    grid-template-rows:var(--v129-field-card-height)!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    flex:0 0 var(--mobile-card-width)!important;
    width:var(--mobile-card-width)!important;
    min-width:var(--mobile-card-width)!important;
    max-width:var(--mobile-card-width)!important;
    height:var(--v129-field-card-height)!important;
    min-height:var(--v129-field-card-height)!important;
    max-height:var(--v129-field-card-height)!important;
    display:grid!important;
    grid-template-rows:calc(var(--mobile-card-width) * .2684) minmax(0,1fr) calc(var(--mobile-card-width) * .3131)!important;
    overflow:hidden!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .cname,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-title-area,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .cname,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-title-area{
    height:100%!important;min-height:0!important;max-height:none!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .cstats,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-stat-grid,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .cstats,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card .card-stat-grid{
    height:100%!important;min-height:0!important;max-height:none!important;
  }

  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .ally-hq-row,
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .ally-hq-row,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq{
    height:118px!important;min-height:118px!important;max-height:118px!important;overflow:hidden!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-info-overlay,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-info-overlay,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-info-overlay,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq .hq-info-overlay{
    left:5px!important;right:calc(var(--mobile-card-width) + 10px)!important;top:25px!important;bottom:auto!important;
    height:56px!important;min-height:56px!important;max-height:56px!important;
    display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;grid-template-rows:repeat(2,minmax(0,1fr))!important;
    gap:2px!important;padding:2px!important;align-content:stretch!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip{
    width:auto!important;height:auto!important;min-height:0!important;padding:1px 2px!important;gap:2px!important;font-size:8px!important;border-radius:4px!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip .hq-stat-icon,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip .hq-stat-icon,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip .hq-stat-icon,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip .hq-stat-icon{
    font-size:8px!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip .hq-stat-value,
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip b,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip .hq-stat-value,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip b,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip .hq-stat-value,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-stat-chip b,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip .hq-stat-value,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .battle-hq .hq-stat-chip b{
    font-size:8px!important;line-height:1!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .hq-advisor-slot,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount .hq-advisor-slot,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row .hq-advisor-slot{
    inset:25px 5px auto auto!important;
    width:var(--mobile-card-width)!important;min-width:var(--mobile-card-width)!important;max-width:var(--mobile-card-width)!important;
    height:56px!important;min-height:56px!important;max-height:56px!important;padding:0!important;overflow:hidden!important;
  }
}

@media (max-width:850px){

  
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq{
    display:grid!important;
    grid-template-columns:1fr var(--mobile-card-width)!important;
    column-gap:5px!important;
    padding:3px!important;
    box-sizing:border-box!important;
    position:relative!important;
    overflow:hidden!important;
  }
  
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq{
    grid-template-rows:22px 1fr 28px!important;
    grid-template-areas:"title title" "stats advisor" "actions advisor"!important;
    row-gap:2px!important;
  }
  
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq{
    grid-template-rows:22px 1fr!important;
    grid-template-areas:"title title" "stats advisor"!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-title,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-title{
    grid-area:title!important;
    position:static!important;
    inset:auto!important;
    left:auto!important;top:auto!important;transform:none!important;
    width:100%!important;min-width:0!important;max-width:none!important;
    box-sizing:border-box!important;
    height:100%!important;min-height:0!important;max-height:none!important;
    margin:0!important;padding:0 4px!important;
    display:flex!important;align-items:center!important;justify-content:center!important;
    text-align:center!important;
    white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;
    clip-path:none!important;
    font-size:11px!important;line-height:1.1!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .hq-info-overlay,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row .battle-hq .hq-info-overlay{
    grid-area:stats!important;
    position:static!important;
    inset:auto!important;
    left:auto!important;right:auto!important;top:auto!important;bottom:auto!important;
    width:100%!important;height:100%!important;
    min-width:0!important;max-width:none!important;min-height:0!important;max-height:none!important;
    margin:0!important;padding:2px!important;box-sizing:border-box!important;
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    grid-template-rows:repeat(2,minmax(0,1fr))!important;
    gap:2px!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) #allyHq .hq-advisor-slot,
  body.ui-mode-mobile:not(.prebattle) #enemyHq .hq-advisor-slot{
    grid-area:advisor!important;
    position:static!important;
    inset:auto!important;
    left:auto!important;right:auto!important;top:auto!important;bottom:auto!important;
    transform:none!important;
    width:100%!important;height:100%!important;
    min-width:0!important;max-width:none!important;min-height:0!important;max-height:none!important;
    margin:0!important;padding:0!important;box-sizing:border-box!important;
    border-radius:6px!important;overflow:hidden!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .mobile-hq-actions{
    grid-area:actions!important;
    position:static!important;
    inset:auto!important;
    left:auto!important;right:auto!important;top:auto!important;bottom:auto!important;
    width:100%!important;height:100%!important;
    min-width:0!important;max-width:none!important;min-height:0!important;max-height:none!important;
    margin:0!important;padding:0!important;box-sizing:border-box!important;
    display:flex!important;align-items:stretch!important;justify-content:stretch!important;gap:3px!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .mobile-hq-actions .btn,
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount .battle-hq .mobile-hq-actions button{
    flex:1 1 0!important;
    width:auto!important;
    height:auto!important;min-height:0!important;max-height:none!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount{
    position:fixed!important;
    left:0!important;right:0!important;top:auto!important;bottom:0!important;
    width:100%!important;margin:0!important;
    padding:0 4px env(safe-area-inset-bottom,0px)!important;
    box-sizing:border-box!important;
    z-index:60!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount{
    position:fixed!important;
    left:0!important;right:0!important;top:auto!important;
    bottom:calc(var(--v173-mobile-hq-height, 118px) + env(safe-area-inset-bottom,0px))!important;
    width:100%!important;margin:0!important;
    z-index:59!important;
  }
  
  body.ui-mode-mobile:not(.prebattle) .app,
  body.ui-mode-mobile:not(.prebattle){
    padding-bottom:calc(var(--v173-mobile-hq-height, 118px) + var(--v173-mobile-hand-height, 186px) + env(safe-area-inset-bottom,0px) + 6px)!important;
  }
}

.hq-quickbar{
  display:flex;
  align-items:stretch;
  justify-content:space-between;
  gap:6px;
  margin:0 0 6px 0;
  padding:6px 8px;
  border-radius:10px;
  background:linear-gradient(180deg,#151b2be6,#0b0f18e6);
  border:1px solid #ffffff26;
  box-shadow:0 2px 10px #000a;
}
.hq-quick-stat{
  flex:1 1 0;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:5px;
  min-width:0;
}
.hq-quick-icon{font-size:15px;line-height:1;opacity:.9;}
.hq-quick-stat b{
  font-size:16px;
  font-weight:800;
  letter-spacing:.2px;
  color:#fff;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.hq-quick-stat.hp b{color:#ff8a8a;}
.hq-quick-stat.mp b{color:#8ad6ff;}
.hq-quick-stat.ap b{color:#ffe28a;}
.hq-quick-stat.deck b{color:#c9b8ff;}
.hq-quick-stat.turn b{color:#9dffb0;}

@media (max-width:850px){
  body.ui-mode-mobile:not(.prebattle) .hq-quickbar{
    padding:5px 6px;
    margin:0 0 4px 0;
    border-radius:8px;
    gap:3px;
  }
  body.ui-mode-mobile:not(.prebattle) .hq-quick-icon{font-size:13px;}
  body.ui-mode-mobile:not(.prebattle) .hq-quick-stat b{font-size:14px;}
}

.card-shop-grid .collection-card-heading small{display:none!important;} 
.card-shop-grid .collection-card-heading .collection-card-name{font-size:13px!important;font-weight:1000!important;}
.card-shop-grid .collection-card-title em{font-size:12px!important;min-width:24px!important;height:20px!important;}
.card-shop-grid .collection-five-stats{font-size:15px!important;font-weight:950!important;padding:6px 3px!important;}
@media (max-width:850px){
  .card-shop-grid .collection-card-heading .collection-card-name{font-size:11px!important;}
  .card-shop-grid .collection-five-stats{font-size:12px!important;}
}

#hand.hand .card.affordable{
  border-color:#f7d77f!important;
  box-shadow:none!important; 
}
#hand.hand .card.affordable:not(.selected)::after{content:none!important;}
#hand.hand .card-ready-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:25px;
  height:18px;
  padding:0 5px;
  margin-left:2px;
  border-radius:3px;
  border:1px solid #6fe3a0;
  background:#0d2e1cd9;
  color:#c9ffd9;
  font-size:9px;
  font-weight:950;
  line-height:1;
  white-space:nowrap;
  text-shadow:0 1px 2px #000;
}
@media (max-width:850px){
  #hand.hand .card-ready-badge{min-width:20px;height:14px;font-size:7px;padding:0 3px;}
}

.manager-field.mgr-field-hidden{display:none!important;}

body.prebattle .hq-quickbar{display:none;}

.battle-hq .hq-advisor-slot{
  background:linear-gradient(180deg,#3a3018e6,#241d0ce6)!important;
  border:1px solid #f3d67f!important;
  box-shadow:0 0 10px #f3d67f4d,inset 0 0 0 1px #ffe9a355!important;
}
.battle-hq .hq-advisor-slot.active{
  background:linear-gradient(180deg,#4a3d1fe6,#2c230ee6)!important;
  box-shadow:0 0 14px #ffe08a66,inset 0 0 0 1px #ffe9a377!important;
}

.card-shop-grid .collection-five-stats,
.deck-builder-visual-card .collection-five-stats{
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  justify-content:center!important;
  gap:2px!important;
  font-size:15px!important;
  padding:5px 3px!important;
}
.collection-stat-core{
  font-size:15px!important;
  font-weight:1000!important;
  color:#ffe6ad!important;
  letter-spacing:.02em;
}
.collection-stat-mind{
  font-size:13px!important;
  font-weight:900!important;
  color:#8fe0ff!important; 
  letter-spacing:.02em;
}
@media (max-width:850px){
  .card-shop-grid .collection-five-stats,
  .deck-builder-visual-card .collection-five-stats{font-size:12px!important;}
  .collection-stat-core{font-size:12px!important;}
  .collection-stat-mind{font-size:11px!important;}
}

.card-shop-grid .collection-extra,
.deck-builder-visual-card .collection-extra{
  font-size:11px!important;
  line-height:1.3!important;
  font-weight:600!important;
  color:#f0e6d0!important;
}

.card-shop-grid .collection-card-icons,
.deck-builder-visual-card .collection-card-icons{
  gap:4px!important;
}
.card-shop-grid .collection-type-icon,
.card-shop-grid .collection-soldier-icon,
.card-shop-grid .collection-en-icon,
.deck-builder-visual-card .collection-type-icon,
.deck-builder-visual-card .collection-soldier-icon,
.deck-builder-visual-card .collection-en-icon{
  font-size:15px!important;
  font-weight:900!important;
  text-shadow:0 1px 3px #000;
}
.collection-soldier-icon{
  padding:0 2px;
}

.hq-field-slot .base-unit-mini,
.hq-field-slot .base-unit-mini b,
.hq-field-slot .base-unit-mini span,
.hq-field-slot .base-unit-name-click{
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  writing-mode:horizontal-tb!important;
  min-width:0!important;
}
.hq-field-slot{min-width:0!important;}
.hq-battlefield-grid{grid-template-columns:repeat(5,minmax(0,1fr))!important;}

.hq-advisor-field-slot{
  border-style:solid!important;
  border-color:#f3d67f!important;
  background:linear-gradient(180deg,#3a3018e6,#241d0ce6)!important;
  box-shadow:0 0 10px #f3d67f4d,inset 0 0 0 1px #ffe9a355!important;
  padding:0!important;
}
.hq-advisor-field-slot .hq-advisor-slot,
.hq-advisor-field-slot .advisor{
  position:static!important;
  width:100%!important;
  height:100%!important;
  inset:auto!important;
  margin:0!important;
}

#allyHq .hq-info-overlay,
#enemyHq .hq-info-overlay,
#allyHq > .hq-advisor-slot,
#enemyHq > .hq-advisor-slot{
  display:none!important;
}

#hand.hand .card{
  width:var(--hand-card-width,106px)!important;
  min-width:var(--hand-card-width,106px)!important;
  max-width:var(--hand-card-width,106px)!important;
  height:var(--hand-card-height,138px)!important;
  min-height:var(--hand-card-height,138px)!important;
  max-height:var(--hand-card-height,138px)!important;
}

#hand.hand{
  display:flex!important;
  flex-wrap:wrap!important;
  grid-template-columns:none!important;
  align-content:flex-start!important;
  justify-content:flex-start!important;
}
.right-hand-section{
  width:auto!important;
  min-width:calc(var(--hand-card-width,106px) * 2 + 30px)!important;
}
@media (max-width:850px){
  .right-hand-section{min-width:0!important;}
}

.lane.neutral-lane{
  background:repeating-linear-gradient(135deg,#1c222a 0 10px,#161b21 10px 20px)!important;
  border:1px dashed #6b7688aa!important;
}
.lane.neutral-lane .slots.n4{grid-template-columns:repeat(4,minmax(0,1fr))!important;}
@media (max-width:850px){
  .battlefield-layout .lane.neutral-lane{padding-top:6px!important;}
}

.battlefield-layout .lane{
  overflow:hidden!important;
  isolation:isolate;
}
.lane.neutral-lane{
  margin:4px 0!important;
  min-height:86px!important;
}
.lane.neutral-lane .slots{
  min-height:78px!important;
}
@media (max-width:850px){
  .battlefield-layout .lane.neutral-lane{min-height:92px!important;margin:5px 0!important;}
  .battlefield-layout .lane.neutral-lane .slots{min-height:84px!important;}
}

.battle-status-pair{
  display:flex;
  gap:8px;
  margin:0 0 6px 0;
}
.battle-status-pair .hq-quickbar{
  flex:1 1 0;
  min-width:0;
  margin:0;
  display:flex;
  flex-direction:column;
  gap:4px;
}
.hq-quickbar-title{
  font-size:10px;
  font-weight:900;
  color:#d8c497;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  padding:0 2px;
}
.hq-quickbar-stats{
  display:flex;
  align-items:stretch;
  justify-content:space-between;
  gap:4px;
}
.enemy-quickbar{border-color:#7a3a3aa0!important;background:linear-gradient(180deg,#2b1417e6,#150a0be6)!important;}
.enemy-quickbar .hq-quickbar-title{color:#f0a5a5;}
.ally-quickbar{border-color:#3a5a7aa0!important;background:linear-gradient(180deg,#141f2be6,#0a0f18e6)!important;}
.ally-quickbar .hq-quickbar-title{color:#a5c8f0;}
body.prebattle .battle-status-pair{display:none;}
@media (max-width:850px){
  .battle-status-pair{gap:5px;}
  .hq-quickbar-title{font-size:9px;}
  body.ui-mode-mobile:not(.prebattle) .battle-status-pair .hq-quick-stat b{font-size:12px;}
}

:root{--mobile-status-row-height:0px;}
#mobileBottomStatusRow{display:none;}
@media (max-width:850px){
  body.ui-mode-mobile{--mobile-status-row-height:30px;}
  body.ui-mode-mobile:not(.prebattle) #mobileBottomStatusRow{
    display:flex!important;
    gap:6px!important;
    order:1!important;
    width:100%!important;
    height:var(--mobile-status-row-height)!important;
    min-height:var(--mobile-status-row-height)!important;
    max-height:var(--mobile-status-row-height)!important;
    padding:2px 2px 4px!important;
    margin:0!important;
    border-bottom:1px solid #2c2216!important;
    background:transparent!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud{
    display:flex!important;
    flex-direction:column!important;
    height:calc(var(--mobile-action-height) + var(--mobile-status-row-height))!important;
    min-height:calc(var(--mobile-action-height) + var(--mobile-status-row-height))!important;
    max-height:calc(var(--mobile-action-height) + var(--mobile-status-row-height))!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-status{
    flex:0 0 var(--mobile-action-height)!important;
    height:var(--mobile-action-height)!important;
    order:2!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount{
    bottom:calc(var(--mobile-action-height) + var(--mobile-status-row-height) + env(safe-area-inset-bottom,0px))!important;
  }
  .mini-quickbar{
    flex:1 1 0;
    min-width:0;
    display:flex;
    align-items:center;
    gap:5px;
    padding:2px 5px;
    border-radius:6px;
    background:#0000002e;
  }
  .mini-quickbar.enemy{background:#3a15171f;}
  .mini-quickbar.ally{background:#15233a1f;}
  .mini-quickbar-label{font-size:9px;font-weight:950;color:#cbb98a;flex:0 0 auto;}
  .mini-quick-stat{display:flex;align-items:center;gap:2px;font-size:8px;color:#cfcfcf;white-space:nowrap;}
  .mini-quick-stat b{font-size:9px;font-weight:800;color:#fff;}
}

@media (max-width:850px){
  #mobileAdvancedSetup #mobileDeckMenu{grid-column:1/-1!important;margin-bottom:6px!important;}
}

@media (min-width:851px){
  #loginModal .modalbox.auth-modalbox{
    width:min(420px, var(--hand-card-width,106px) * 3 + 60px)!important;
    max-width:92vw!important;
  }
}

body:not(.prebattle) .boardwrap{
  overflow-x:hidden!important;
  overflow-y:auto!important;
}
body:not(.prebattle) .battlefield-layout>.board{
  display:flex!important;
  flex-direction:column!important;
  justify-content:flex-start!important;
  align-content:initial!important;
  height:auto!important;
  min-height:100%!important;
  gap:5px!important;
}
body:not(.prebattle) .battlefield-layout>.board>.lane,
body:not(.prebattle) .battlefield-layout>.board>.hq-battle-row{
  position:relative!important;
  flex:0 0 auto!important;
}
body:not(.prebattle) .battlefield-layout>.board>.neutral-lane{
  position:relative!important;
  z-index:1!important;
  margin:5px 0!important;
  clear:both!important;
}
body:not(.prebattle) .battlefield-layout>.board>.lane[data-row="a2"]{
  position:relative!important;
  z-index:1!important;
}

@media (min-width:851px){
  body:not(.prebattle) .battlefield-layout>.board>.lane:not(.hq-defense-lane){
    box-sizing:border-box!important;
    height:calc(var(--hand-card-height,138px) + 10px)!important;
    min-height:calc(var(--hand-card-height,138px) + 10px)!important;
    max-height:none!important;
    overflow:hidden!important;
  }
  body:not(.prebattle) .battlefield-layout>.board>.lane:not(.hq-defense-lane)>.slots{
    height:var(--hand-card-height,138px)!important;
    min-height:var(--hand-card-height,138px)!important;
    max-height:var(--hand-card-height,138px)!important;
  }
  body:not(.prebattle) .battlefield-layout>.board>.lane:not(.hq-defense-lane)>.slots>.slot,
  body:not(.prebattle) .battlefield-layout>.board>.lane:not(.hq-defense-lane)>.slots>.slot>.unit{
    height:var(--hand-card-height,138px)!important;
    min-height:var(--hand-card-height,138px)!important;
    max-height:var(--hand-card-height,138px)!important;
  }
}

body:not(.prebattle) .hq-defense-lane.active{
  box-sizing:border-box!important;
  display:block!important;
  height:calc(var(--hand-card-height,138px) + 10px)!important;
  min-height:calc(var(--hand-card-height,138px) + 10px)!important;
  max-height:none!important;
  padding:4px 6px!important;
  overflow:hidden!important;
}
body:not(.prebattle) .hq-defense-lane .hq-battlefield-grid{
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:repeat(5,var(--hand-card-width,106px))!important;
  grid-template-rows:var(--hand-card-height,138px)!important;
  grid-auto-rows:var(--hand-card-height,138px)!important;
  width:max-content!important;
  max-width:100%!important;
  height:var(--hand-card-height,138px)!important;
  min-height:var(--hand-card-height,138px)!important;
  max-height:var(--hand-card-height,138px)!important;
  gap:7px!important;
  margin:0 auto!important;
  padding:0 3px 2px!important;
  align-items:stretch!important;
  justify-content:start!important;
  overflow-x:auto!important;
  overflow-y:hidden!important;
  scrollbar-width:thin;
}
body:not(.prebattle) .hq-defense-lane .hq-field-slot{
  box-sizing:border-box!important;
  width:var(--hand-card-width,106px)!important;
  min-width:var(--hand-card-width,106px)!important;
  max-width:var(--hand-card-width,106px)!important;
  height:var(--hand-card-height,138px)!important;
  min-height:var(--hand-card-height,138px)!important;
  max-height:var(--hand-card-height,138px)!important;
  padding:0!important;
  border:1px solid #765b36!important;
  border-style:solid!important;
  border-radius:7px!important;
  background:linear-gradient(180deg,#17120de6,#0d0a08e8)!important;
  overflow:hidden!important;
}
body:not(.prebattle) .hq-defense-lane .hq-field-slot.empty::after{
  content:none!important;
}
body:not(.prebattle) .hq-defense-lane .hq-field-slot.empty>span{
  color:#bda57b80!important;
  font-size:10px!important;
  font-weight:800!important;
}
body:not(.prebattle) .hq-defense-lane .hq-field-slot>.unit{
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  height:100%!important;
  min-height:100%!important;
  max-height:100%!important;
  border-radius:6px!important;
}

body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot{
  border-color:#a899ff!important;
  background:linear-gradient(180deg,#292242f0,#12182ce8)!important;
  box-shadow:inset 0 0 0 1px #c4baff44,0 0 10px #7767d933!important;
}
body:not(.prebattle) .hq-advisor-field-slot .hq-advisor-slot,
body:not(.prebattle) .hq-advisor-field-slot .advisor{
  box-sizing:border-box!important;
  position:static!important;
  inset:auto!important;
  display:flex!important;
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  height:100%!important;
  min-height:100%!important;
  max-height:100%!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:6px!important;
  background:transparent!important;
  box-shadow:none!important;
  overflow:hidden!important;
}
body:not(.prebattle) .hq-advisor-field-slot .advisor-card,
body:not(.prebattle) .hq-advisor-field-slot .advisor-image-only,
body:not(.prebattle) .hq-advisor-field-slot .advisor-portrait{
  box-sizing:border-box!important;
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  height:100%!important;
  min-height:100%!important;
  max-height:100%!important;
}
body:not(.prebattle) .hq-advisor-field-slot .advisor-empty{
  width:100%!important;
  height:100%!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#e4ddff!important;
  font-weight:900!important;
  letter-spacing:.04em!important;
}

body:not(.prebattle) .hq-field-slot.supportable{
  outline:3px solid #58e2d0!important;
  box-shadow:0 0 0 5px #58e2d02e,0 0 20px #58e2d033!important;
}
body:not(.prebattle) .hq-field-slot.buff-cancel-source,
body:not(.prebattle) .hq-field-slot .support-buff-caster{
  outline:3px solid #ffd867!important;
  box-shadow:0 0 0 4px #ffd86730,0 0 18px #ffd86744!important;
}

body.ui-mode-mobile:not(.prebattle) .mobile-ally-hq-mount,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-ally-hq-mount{
  display:none!important;
  visibility:hidden!important;
  position:static!important;
  width:0!important;
  min-width:0!important;
  max-width:0!important;
  height:0!important;
  min-height:0!important;
  max-height:0!important;
  margin:0!important;
  padding:0!important;
  overflow:hidden!important;
}

@media (max-width:850px){
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount{
    display:block!important;
    position:fixed!important;
    left:0!important;
    right:0!important;
    bottom:0!important;
    transform:none!important;
    width:100%!important;
    max-width:none!important;
    z-index:96!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud{
    display:block!important;
    position:fixed!important;
    left:0!important;
    right:0!important;
    bottom:var(--v120-hand-height,var(--mobile-hand-float-height,174px))!important;
    width:100%!important;
    height:46px!important;
    min-height:46px!important;
    max-height:46px!important;
    padding:4px 6px!important;
    z-index:95!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-status{
    display:block!important;
    height:100%!important;
    padding:0!important;
    background:transparent!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-status>:not(.hud-actions){display:none!important;}
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-actions{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:5px!important;
    width:100%!important;
    height:100%!important;
    min-width:0!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-actions .btn{
    min-height:36px!important;
    height:36px!important;
    padding:3px 5px!important;
    font-size:10px!important;
  }
  body.ui-mode-mobile:not(.prebattle),
  body.ui-mode-mobile:not(.prebattle) .app{
    padding-bottom:calc(var(--v120-hand-height,var(--mobile-hand-float-height,174px)) + 54px + env(safe-area-inset-bottom,0px))!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount{
  display:block!important;
  position:fixed!important;
  left:50%!important;
  right:auto!important;
  bottom:0!important;
  transform:translateX(-50%)!important;
  width:var(--mobile-play-width,430px)!important;
  max-width:var(--mobile-play-width,430px)!important;
  z-index:96!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud{
  display:block!important;
  position:fixed!important;
  left:50%!important;
  right:auto!important;
  bottom:var(--v120-hand-height,var(--mobile-hand-float-height,174px))!important;
  transform:translateX(-50%)!important;
  width:var(--mobile-play-width,430px)!important;
  height:46px!important;
  min-height:46px!important;
  max-height:46px!important;
  padding:4px 6px!important;
  z-index:95!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-status{
  display:block!important;
  height:100%!important;
  padding:0!important;
  background:transparent!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-status>:not(.hud-actions){display:none!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-actions{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:5px!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-actions .btn{
  min-height:36px!important;
  height:36px!important;
  padding:3px 5px!important;
  font-size:10px!important;
}
body.ui-mode-mobile-preview:not(.prebattle),
body.ui-mode-mobile-preview:not(.prebattle) .app{
  padding-bottom:calc(var(--v120-hand-height,var(--mobile-hand-float-height,174px)) + 54px)!important;
}

@media (max-width:850px){
  body.ui-mode-mobile:not(.prebattle),
  body.ui-mode-mobile-preview:not(.prebattle){
    --v182-hq-card-ratio:1.767;
    --v182-hq-grid-gap:4px;
  }

  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane.active,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane.active{
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    padding:4px 5px!important;
    overflow:hidden!important;
  }

  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane .hq-battlefield-grid,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-battlefield-grid{
    display:grid!important;
    grid-template-columns:repeat(5,minmax(0,1fr))!important;
    grid-template-rows:auto!important;
    grid-auto-rows:auto!important;
    width:min(100%,430px)!important;
    max-width:100%!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    gap:var(--v182-hq-grid-gap)!important;
    margin:0 auto!important;
    padding:0!important;
    align-items:start!important;
    justify-content:center!important;
    overflow:visible!important;
  }

  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane .hq-field-slot,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-field-slot{
    box-sizing:border-box!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    aspect-ratio:1 / var(--v182-hq-card-ratio)!important;
    align-self:start!important;
  }

  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane .hq-field-slot>.unit,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-field-slot>.unit{
    box-sizing:border-box!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
    grid-template-rows:15.2% minmax(0,1fr) 17.7%!important;
  }

  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .hq-advisor-slot,
  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .hq-advisor-slot,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
  }

  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-card,
  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-image-only,
  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-portrait,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-card,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-image-only,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-portrait{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle){
  --v182-hq-card-ratio:1.767;
  --v182-hq-grid-gap:4px;
}
body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane.active{
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  padding:4px 5px!important;
  overflow:hidden!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-battlefield-grid{
  display:grid!important;
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  grid-template-rows:auto!important;
  grid-auto-rows:auto!important;
  width:min(100%,430px)!important;
  max-width:100%!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  gap:var(--v182-hq-grid-gap)!important;
  margin:0 auto!important;
  padding:0!important;
  align-items:start!important;
  justify-content:center!important;
  overflow:visible!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-field-slot{
  box-sizing:border-box!important;
  width:100%!important;
  min-width:0!important;
  max-width:none!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  aspect-ratio:1 / var(--v182-hq-card-ratio)!important;
  align-self:start!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane .hq-field-slot>.unit{
  box-sizing:border-box!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  height:100%!important;
  min-height:0!important;
  max-height:100%!important;
  grid-template-rows:15.2% minmax(0,1fr) 17.7%!important;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    width:100%!important;
    height:100vh!important;
    min-height:720px!important;
    grid-template-columns:360px minmax(720px,1fr)!important;
    gap:4px!important;
    padding:4px!important;
    overflow:hidden!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left{
    grid-column:1!important;
    display:flex!important;
    flex-direction:column!important;
    height:calc(100vh - 8px)!important;
    min-height:0!important;
    padding:0!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    scrollbar-width:thin;
    background:linear-gradient(180deg,#070b0e,#0b1013 52%,#06090b)!important;
    border:1px solid #6f4d25!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    grid-column:2!important;
    width:auto!important;
    min-width:0!important;
    height:calc(100vh - 8px)!important;
    min-height:0!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-right{
    display:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel{order:1}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-menu-dock{order:2}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-setup-host{order:3}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host{order:4}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host{order:5}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-section{order:6}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{order:7}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-bottom-actions{order:8}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .desktop-ui-mode-switch{order:9}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #desktopOnlineMatchInfo{order:10}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #desktopMatchWaitingNotice{order:11}

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-status-frame,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-log-frame{
    display:none!important;
  }

  
  body.login-required.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    pointer-events:auto!important;
    user-select:auto!important;
    filter:none!important;
  }
  body.login-required.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel,
  body.login-required.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left>:not(.left-auth-panel){
    pointer-events:none!important;
    user-select:none!important;
    filter:brightness(.44) saturate(.65)!important;
  }
  body.login-required.unified-left-layout:not(.ui-mode-mobile-preview) #loginModal{
    display:none!important;
    opacity:0!important;
    visibility:hidden!important;
    pointer-events:none!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel{
    flex:0 0 auto!important;
    padding:0 7px 7px!important;
    background:linear-gradient(180deg,#111920,#080d10)!important;
    border-bottom:1px solid #67451f!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel .ornate-title{
    margin:0 -7px 6px!important;
    min-height:27px!important;
    font-size:13px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-fields{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) minmax(0,.72fr)!important;
    gap:5px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel input[type="email"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel input[type="password"]{
    width:100%!important;
    min-width:0!important;
    height:30px!important;
    padding:4px 7px!important;
    border:1px solid #705432!important;
    border-radius:3px!important;
    background:#05090c!important;
    color:#f2eadc!important;
    font-size:11px!important;
    outline:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel input:focus{
    border-color:#c3924b!important;
    box-shadow:0 0 0 2px #c3924b22!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-remember{
    display:flex!important;
    align-items:center!important;
    gap:5px!important;
    margin:5px 0!important;
    color:#cfc1a8!important;
    font-size:10px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr 1fr!important;
    gap:4px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-out[hidden]{display:none!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-actions .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-subpanel .btn{
    min-height:29px!important;
    padding:4px 5px!important;
    font-size:10px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-actions .btn.active{
    border-color:#d4a454!important;
    color:#ffe8bb!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-subpanel{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:5px!important;
    margin-top:6px!important;
    padding-top:6px!important;
    border-top:1px solid #4c351d!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-subpanel[hidden]{display:none!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-in{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    min-height:36px!important;
    color:#bfe8c7!important;
    font-size:11px!important;
    font-weight:800!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-in[hidden]{display:none!important}

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-menu-dock{
    flex:0 0 auto!important;
    padding:0 7px 7px!important;
    border:0!important;
    border-bottom:1px solid #5b3e20!important;
    background:#080d10!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-menu-dock>.ornate-title{
    margin:0 -7px 6px!important;
    min-height:27px!important;
    font-size:13px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-topbar{
    position:static!important;
    inset:auto!important;
    display:block!important;
    width:100%!important;
    height:auto!important;
    min-height:0!important;
    padding:0!important;
    margin:0!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .top-options{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:5px!important;
    width:100%!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .top-options .btn{
    width:100%!important;
    min-width:0!important;
    min-height:31px!important;
    padding:4px!important;
    font-size:10px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .online-account-bar{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .faction-pickers{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:5px!important;
    margin-top:5px!important;
    font-size:9px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .faction-pickers span{
    min-width:0!important;
    padding:4px 5px!important;
    text-align:center!important;
    border:1px solid #46351f!important;
    background:#0b1013!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-setup-host{
    flex:0 0 auto!important;
    min-height:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-setup-host .compact-settings-holder{
    display:block!important;
    width:100%!important;
    margin:0!important;
    padding:0 7px 7px!important;
    border:0!important;
    border-bottom:1px solid #5b3e20!important;
    background:#080d10!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-setup-host .ornate-title{
    margin:0 -7px 6px!important;
    min-height:27px!important;
    font-size:13px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-control>span{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline{
    display:grid!important;
    grid-template-columns:67px minmax(0,1fr) 65px!important;
    gap:5px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline select,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline .btn{
    min-width:0!important;
    width:100%!important;
    height:31px!important;
    padding:3px 5px!important;
    font-size:9px!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host{
    display:grid!important;
    grid-template-columns:1.2fr .8fr 1fr!important;
    gap:5px!important;
    flex:0 0 auto!important;
    padding:6px 7px!important;
    border-bottom:1px solid #5b3e20!important;
    background:#0b1013!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host .btn{
    width:100%!important;
    min-width:0!important;
    min-height:32px!important;
    padding:4px!important;
    font-size:10px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host .deck-info{display:none!important}

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host{
    flex:0 0 auto!important;
    padding:6px 7px!important;
    border-bottom:1px solid #5b3e20!important;
    background:#080d10!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .battle-status-pair{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:5px!important;
    width:100%!important;
    margin:0!important;
    padding:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar{
    position:relative!important;
    display:block!important;
    min-width:0!important;
    min-height:98px!important;
    padding:0 5px 20px!important;
    border:1px solid #72502b!important;
    border-radius:4px!important;
    overflow:hidden!important;
    cursor:pointer!important;
    box-shadow:inset 0 0 14px #0009!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .enemy-quickbar{
    background:linear-gradient(180deg,#3c1718,#13090a)!important;
    border-color:#a25656!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .ally-quickbar{
    background:linear-gradient(180deg,#172a42,#08101b)!important;
    border-color:#547fb1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar:focus,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar:hover{
    outline:none!important;
    filter:brightness(1.12)!important;
    box-shadow:inset 0 0 14px #0008,0 0 0 2px #d6ab6533!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar-title{
    height:25px!important;
    margin:0 -5px 5px!important;
    padding:5px 6px!important;
    overflow:hidden!important;
    white-space:nowrap!important;
    text-overflow:ellipsis!important;
    font-size:10px!important;
    line-height:15px!important;
    text-align:center!important;
    color:#f4e6cf!important;
    border-bottom:1px solid #ffffff22!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar-stats{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:3px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat{
    position:relative!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:0!important;
    min-height:29px!important;
    padding:11px 2px 2px!important;
    border:1px solid #ffffff1c!important;
    background:#05080ba6!important;
    font-size:9px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat::before{
    content:attr(data-stat-label)!important;
    position:absolute!important;
    top:2px!important;
    left:0!important;
    right:0!important;
    color:#aeb8c2!important;
    font-size:6px!important;
    font-weight:900!important;
    letter-spacing:.05em!important;
    text-align:center!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat:nth-child(4),
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat:nth-child(5){
    grid-column:span 1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-icon{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat b{
    min-width:0!important;
    max-width:100%!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
    color:#fff!important;
    font-size:9px!important;
    line-height:1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-quickbar-hint{
    position:absolute!important;
    left:5px!important;
    right:5px!important;
    bottom:4px!important;
    color:#cfc3af!important;
    font-size:7px!important;
    text-align:center!important;
    opacity:.85!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-section{
    flex:0 0 auto!important;
    padding:5px 7px 7px!important;
    border-bottom:1px solid #5b3e20!important;
    background:#070b0e!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-section[hidden]{display:none!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-head{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    margin-bottom:5px!important;
    color:#e9d8b8!important;
    font-size:10px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-head .btn{
    min-height:25px!important;
    padding:2px 8px!important;
    font-size:9px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-host .enemy-hq-row{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-host .ally-hq-row{
    display:block!important;
    width:100%!important;
    height:auto!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-host .battle-hq{
    width:100%!important;
    height:184px!important;
    min-height:184px!important;
    max-height:184px!important;
    margin:0!important;
    border-radius:5px!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{
    flex:0 0 auto!important;
    min-height:344px!important;
    padding:0!important;
    border-bottom:1px solid #5b3e20!important;
    background:#070b0e!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    display:flex!important;
    flex-direction:column!important;
    width:100%!important;
    height:344px!important;
    min-height:344px!important;
    max-height:344px!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
    border:0!important;
    background:#080c0d!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section>.ornate-title{
    display:flex!important;
    flex:0 0 28px!important;
    height:28px!important;
    min-height:28px!important;
    font-size:12px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox{
    display:flex!important;
    flex:1 1 auto!important;
    min-height:0!important;
    height:auto!important;
    padding:5px!important;
    overflow:hidden!important;
    border:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handhead{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    grid-template-rows:repeat(2,150px)!important;
    grid-auto-rows:150px!important;
    gap:4px!important;
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    padding:0 2px 2px 0!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    align-content:start!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:100%!important;
    height:150px!important;
    min-width:0!important;
    min-height:150px!important;
    max-height:150px!important;
    margin:0!important;
    grid-template-rows:24px minmax(70px,1fr) auto!important;
    border-radius:4px!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card-title-area{
    min-height:24px!important;
    padding:3px 4px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card-name-text{
    font-size:9px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card-title-grade{
    min-width:25px!important;
    padding:1px 3px!important;
    font-size:7px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card-stat-cell{
    min-height:26px!important;
    padding:2px 1px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card-stat-cell b{
    font-size:10px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card-stat-cell span{
    font-size:6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card-hover-tooltip{
    display:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-bottom-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:5px!important;
    flex:0 0 auto!important;
    padding:6px 7px!important;
    border-top:0!important;
    background:#080d10!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-bottom-actions .btn{
    width:100%!important;
    min-height:30px!important;
    font-size:10px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .desktop-ui-mode-switch{
    flex:0 0 auto!important;
    margin:0!important;
    padding:5px 7px!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .right-deck-section,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .right-action-strip{
    display:none!important;
  }
}

@media (min-width:851px) and (max-height:850px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{grid-template-columns:342px minmax(680px,1fr)!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel{padding-bottom:5px!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:304px!important;
    min-height:304px!important;
    max-height:304px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-rows:repeat(2,130px)!important;
    grid-auto-rows:130px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    height:130px!important;
    min-height:130px!important;
    max-height:130px!important;
  }
}

@media (min-width:851px){
  html,
  body,
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    overflow:hidden!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    width:min(1088px,calc(100vw - 16px))!important;
    max-width:1088px!important;
    height:min(920px,calc(100vh - 16px))!important;
    min-height:720px!important;
    margin:8px 0 8px 8px!important;
    padding:0!important;
    gap:8px!important;
    grid-template-columns:308px minmax(0,772px)!important;
    justify-content:start!important;
    align-items:stretch!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left{
    overflow-x:hidden!important;
    overflow-y:auto!important;
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left::-webkit-scrollbar,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox::-webkit-scrollbar,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand::-webkit-scrollbar{
    width:0!important;
    height:0!important;
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    width:100%!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    width:100%!important;
    max-width:100%!important;
    height:100%!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout{
    width:100%!important;
    max-width:none!important;
    height:100%!important;
    min-height:0!important;
    margin:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    height:100%!important;
    min-height:0!important;
    margin:0!important;
    padding:4px 6px 6px!important;
    gap:6px!important;
    grid-template-rows:122px 96px 96px 126px 96px 96px 122px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battle-row{
    min-height:0!important;
    height:100%!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane{
    padding:3px 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots{
    min-height:0!important;
    height:100%!important;
    gap:5px!important;
    align-items:stretch!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot{
    min-height:86px!important;
    height:100%!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{
    min-height:330px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:330px!important;
    min-height:330px!important;
    max-height:330px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-rows:repeat(2,143px)!important;
    grid-auto-rows:143px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    height:143px!important;
    min-height:143px!important;
    max-height:143px!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    width:min(1048px,calc(100vw - 12px))!important;
    max-width:1048px!important;
    height:min(860px,calc(100vh - 12px))!important;
    margin:6px 0 6px 6px!important;
    gap:6px!important;
    grid-template-columns:296px minmax(0,746px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    padding:4px 5px 5px!important;
    gap:5px!important;
    grid-template-rows:114px 90px 90px 116px 90px 90px 114px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot{
    min-height:80px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:300px!important;
    min-height:300px!important;
    max-height:300px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-rows:repeat(2,128px)!important;
    grid-auto-rows:128px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    height:128px!important;
    min-height:128px!important;
    max-height:128px!important;
  }
}

@media (min-width:851px){
  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    display:flex!important;
    flex-direction:column!important;
    justify-content:flex-start!important;
    align-items:stretch!important;
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    padding:4px 6px 6px!important;
    gap:5px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .enemy-hq-row{
    flex:0 0 84px!important;
    min-height:84px!important;
    height:84px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    flex:0 0 72px!important;
    min-height:72px!important;
    height:72px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"]{
    flex:1 1 0!important;
    min-height:84px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane{
    flex:0 0 110px!important;
    min-height:110px!important;
    height:110px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battle-row{
    width:100%!important;
    min-height:0!important;
    box-sizing:border-box!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane{
    padding:3px 6px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    gap:5px!important;
    align-items:stretch!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot{
    height:100%!important;
    min-height:74px!important;
    max-height:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .unit{
    height:100%!important;
    min-height:0!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .enemy-hq-row{
    flex-basis:78px!important;
    min-height:78px!important;
    height:78px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    flex-basis:66px!important;
    min-height:66px!important;
    height:66px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane{
    flex-basis:96px!important;
    min-height:96px!important;
    height:96px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"]{
    min-height:76px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot{
    min-height:68px!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v189-card-w:92px;
    --v189-card-h:124px;
    --v189-card-gap:6px;
    --v189-hand-title-h:28px;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{
    min-height:calc(var(--v189-hand-title-h) + (var(--v189-card-h) * 2) + var(--v189-card-gap) + 14px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:calc(var(--v189-hand-title-h) + (var(--v189-card-h) * 2) + var(--v189-card-gap) + 14px)!important;
    min-height:calc(var(--v189-hand-title-h) + (var(--v189-card-h) * 2) + var(--v189-card-gap) + 14px)!important;
    max-height:calc(var(--v189-hand-title-h) + (var(--v189-card-h) * 2) + var(--v189-card-gap) + 14px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section>.ornate-title{
    flex:0 0 var(--v189-hand-title-h)!important;
    height:var(--v189-hand-title-h)!important;
    min-height:var(--v189-hand-title-h)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox{
    padding:6px!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v189-card-w))!important;
    grid-template-rows:repeat(2,var(--v189-card-h))!important;
    grid-auto-rows:var(--v189-card-h)!important;
    justify-content:center!important;
    align-content:start!important;
    gap:var(--v189-card-gap)!important;
    width:100%!important;
    height:100%!important;
    padding:0!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v189-card-w)!important;
    min-width:var(--v189-card-w)!important;
    max-width:var(--v189-card-w)!important;
    height:var(--v189-card-h)!important;
    min-height:var(--v189-card-h)!important;
    max-height:var(--v189-card-h)!important;
    margin:0!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    display:flex!important;
    flex-direction:column!important;
    justify-content:flex-start!important;
    align-items:stretch!important;
    gap:6px!important;
    padding:4px 6px 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .enemy-hq-row{
    flex:0 0 84px!important;
    min-height:84px!important;
    height:84px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    flex:1 1 0!important;
    min-height:92px!important;
    height:auto!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battle-row{
    width:100%!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane{
    padding:3px 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane .label{
    font-size:12px!important;
    font-weight:800!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    justify-content:center!important;
    align-items:stretch!important;
    align-content:center!important;
    gap:var(--v189-card-gap)!important;
    width:100%!important;
    min-height:0!important;
    overflow:hidden!important;
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots::-webkit-scrollbar,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid::-webkit-scrollbar{
    width:0!important;
    height:0!important;
    display:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,var(--v189-card-w))!important;
    width:max-content!important;
    max-width:100%!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,var(--v189-card-w))!important;
    width:max-content!important;
    max-width:100%!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,var(--v189-card-w))!important;
    width:max-content!important;
    max-width:100%!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,var(--v189-card-w))!important;
    width:max-content!important;
    max-width:100%!important;
    margin:0 auto!important;
    padding:0!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v189-card-w)!important;
    min-width:var(--v189-card-w)!important;
    max-width:var(--v189-card-w)!important;
    height:var(--v189-card-h)!important;
    min-height:var(--v189-card-h)!important;
    max-height:var(--v189-card-h)!important;
    margin:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .unit{
    height:100%!important;
    min-height:0!important;
    grid-template-rows:22px minmax(0,1fr) 22px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .uimg{
    height:100%!important;
    min-height:0!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .enemy-hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .ally-hq-defense-lane{
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .enemy-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .ally-hq-defense-lane .hq-battlefield-grid{
    height:var(--v189-card-h)!important;
    min-height:var(--v189-card-h)!important;
    max-height:var(--v189-card-h)!important;
    border:0!important;
    border-radius:6px!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-defense-lane .hq-field-slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .enemy-hq-defense-lane .hq-field-slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .ally-hq-defense-lane .hq-field-slot{
    border-width:1px!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v189-card-w:88px;
    --v189-card-h:118px;
    --v189-card-gap:5px;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .enemy-hq-row{
    flex-basis:78px!important;
    min-height:78px!important;
    height:78px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    min-height:86px!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v190-card-w:88px;
    --v190-card-h:116px;
    --v190-card-gap:6px;
    --v190-button-h:32px;
    --v190-button-fs:10px;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{
    min-height:calc(28px + (var(--v190-card-h) * 2) + var(--v190-card-gap) + 16px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:calc(28px + (var(--v190-card-h) * 2) + var(--v190-card-gap) + 16px)!important;
    min-height:calc(28px + (var(--v190-card-h) * 2) + var(--v190-card-gap) + 16px)!important;
    max-height:calc(28px + (var(--v190-card-h) * 2) + var(--v190-card-gap) + 16px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v190-card-w))!important;
    grid-template-rows:repeat(2,var(--v190-card-h))!important;
    grid-auto-rows:var(--v190-card-h)!important;
    gap:var(--v190-card-gap)!important;
    justify-content:center!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v190-card-w)!important;
    min-width:var(--v190-card-w)!important;
    max-width:var(--v190-card-w)!important;
    height:var(--v190-card-h)!important;
    min-height:var(--v190-card-h)!important;
    max-height:var(--v190-card-h)!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    gap:5px!important;
    padding:4px 6px 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .enemy-hq-row{
    flex:0 0 84px!important;
    min-height:84px!important;
    height:84px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    flex:1 1 0!important;
    min-height:126px!important;
    height:auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane{
    padding:18px 6px 5px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane .label{
    top:3px!important;
    left:8px!important;
    font-size:12px!important;
    line-height:1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    gap:var(--v190-card-gap)!important;
    justify-content:center!important;
    align-items:stretch!important;
    align-content:center!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{grid-template-columns:repeat(4,var(--v190-card-w))!important;width:max-content!important;margin:0 auto!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{grid-template-columns:repeat(3,var(--v190-card-w))!important;width:max-content!important;margin:0 auto!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{grid-template-columns:repeat(2,var(--v190-card-w))!important;width:max-content!important;margin:0 auto!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{grid-template-columns:repeat(5,var(--v190-card-w))!important;width:max-content!important;max-width:100%!important;margin:0 auto!important;padding:0!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v190-card-w)!important;
    min-width:var(--v190-card-w)!important;
    max-width:var(--v190-card-w)!important;
    height:var(--v190-card-h)!important;
    min-height:var(--v190-card-h)!important;
    max-height:var(--v190-card-h)!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .unit{
    height:100%!important;
    min-height:0!important;
    grid-template-rows:24px minmax(0,1fr) 28px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .uimg{
    height:100%!important;
    min-height:0!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .top-options .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline select,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-bottom-actions .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-login-host .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .auth-actions .btn{
    height:var(--v190-button-h)!important;
    min-height:var(--v190-button-h)!important;
    max-height:var(--v190-button-h)!important;
    padding:4px 8px!important;
    font-size:var(--v190-button-fs)!important;
    line-height:1.1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .top-options .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-bottom-actions .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host .btn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline .btn{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    text-align:center!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar{
    min-height:112px!important;
    padding:0 6px 23px!important;
    border-radius:5px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar-title{
    height:28px!important;
    margin:0 -6px 6px!important;
    padding:6px 6px!important;
    font-size:11px!important;
    font-weight:900!important;
    line-height:16px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar-stats{
    gap:4px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat{
    min-height:34px!important;
    padding:13px 2px 3px!important;
    font-size:10px!important;
    border-radius:3px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat::before{
    top:2px!important;
    font-size:7px!important;
    color:#cad4de!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat b{
    font-size:12px!important;
    font-weight:1000!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-quickbar-hint{
    font-size:8px!important;
    bottom:5px!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-grid{
    grid-template-columns:1fr!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell{
    border-right:0!important;
    border-bottom:1px solid rgba(255,255,255,.12)!important;
    justify-content:flex-start!important;
    padding:0 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell:last-child{
    border-bottom:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell b{
    font-size:11px!important;
    color:#fff2bd!important;
    letter-spacing:.01em!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-field-slot .base-unit{
    border-width:1px!important;
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.06),0 2px 7px rgba(0,0,0,.55)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card.grade-border-SSS,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .unit.grade-border-SSS,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .base-unit.grade-border-SSS,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card.grade-border-SS,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .unit.grade-border-SS,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .base-unit.grade-border-SS,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card.grade-border-S,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .unit.grade-border-S,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .base-unit.grade-border-S,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card.grade-border-RR,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .unit.grade-border-RR,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .base-unit.grade-border-RR,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card.grade-border-R,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .unit.grade-border-R,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .base-unit.grade-border-R,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card.grade-border-U,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .unit.grade-border-U,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .base-unit.grade-border-U,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card.grade-border-C,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .unit.grade-border-C,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .base-unit.grade-border-C{
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.05),0 2px 7px rgba(0,0,0,.55)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.affordable,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.actionable-card:not(.opening-hand-card){
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.14),0 0 10px rgba(255,255,255,.08),0 2px 7px rgba(0,0,0,.55)!important;
    transform:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.affordable{
    border-color:var(--card-accent,#d6e5f8)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.actionable-card:not(.opening-hand-card){
    border-color:color-mix(in srgb,var(--card-accent,#9de3aa) 78%, white 22%)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.affordable:not(.selected)::after{
    inset:1px!important;
    border-width:1px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.valid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.supportable,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.movable,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.attackable{
    outline:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.valid{box-shadow:inset 0 0 0 1px #9fd9ff,0 0 8px rgba(159,217,255,.30)!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.supportable{box-shadow:inset 0 0 0 1px #a8efc2,0 0 8px rgba(168,239,194,.28)!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.movable{box-shadow:inset 0 0 0 1px #f6d88a,0 0 8px rgba(246,216,138,.28)!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.attackable{box-shadow:inset 0 0 0 1px #ffaaa0,0 0 8px rgba(255,170,160,.30)!important}

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .enemy-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .ally-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-defense-lane .hq-battlefield-grid{
    height:var(--v190-card-h)!important;
    min-height:var(--v190-card-h)!important;
    max-height:var(--v190-card-h)!important;
    overflow:hidden!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v190-card-w:84px;
    --v190-card-h:110px;
    --v190-card-gap:5px;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    min-height:120px!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v191-card-w:78px;
    --v191-card-h:121px; 
    --v191-card-gap:6px;
    --v191-lane-label-h:16px;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{
    min-height:calc(28px + (var(--v191-card-h) * 2) + var(--v191-card-gap) + 16px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:calc(28px + (var(--v191-card-h) * 2) + var(--v191-card-gap) + 16px)!important;
    min-height:calc(28px + (var(--v191-card-h) * 2) + var(--v191-card-gap) + 16px)!important;
    max-height:calc(28px + (var(--v191-card-h) * 2) + var(--v191-card-gap) + 16px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v191-card-w))!important;
    grid-template-rows:repeat(2,var(--v191-card-h))!important;
    grid-auto-rows:var(--v191-card-h)!important;
    gap:var(--v191-card-gap)!important;
    justify-content:center!important;
    align-content:start!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v191-card-w)!important;
    min-width:var(--v191-card-w)!important;
    max-width:var(--v191-card-w)!important;
    height:var(--v191-card-h)!important;
    min-height:var(--v191-card-h)!important;
    max-height:var(--v191-card-h)!important;
    aspect-ratio:2 / 3.1!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    justify-content:flex-start!important;
    gap:4px!important;
    padding:4px 4px 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .enemy-hq-row{
    flex:0 0 82px!important;
    min-height:82px!important;
    height:82px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    flex:1 1 0!important;
    min-height:137px!important;
    height:auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battle-row{
    width:100%!important;
    box-sizing:border-box!important;
    min-height:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane{
    padding:16px 3px 3px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane .label{
    top:2px!important;
    left:6px!important;
    font-size:12px!important;
    line-height:1!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    display:flex!important;
    width:100%!important;
    height:auto!important;
    min-height:var(--v191-card-h)!important;
    max-height:none!important;
    justify-content:space-between!important;
    align-items:flex-start!important;
    align-content:flex-start!important;
    gap:var(--v191-card-gap)!important;
    padding:0!important;
    margin:0!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4>.slot{flex:0 0 var(--v191-card-w)!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3>.slot{flex:0 0 var(--v191-card-w)!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2>.slot{flex:0 0 var(--v191-card-w)!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid>.hq-field-slot{flex:0 0 var(--v191-card-w)!important}

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v191-card-w)!important;
    min-width:var(--v191-card-w)!important;
    max-width:var(--v191-card-w)!important;
    height:var(--v191-card-h)!important;
    min-height:var(--v191-card-h)!important;
    max-height:var(--v191-card-h)!important;
    aspect-ratio:2 / 3.1!important;
    margin:0!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot .base-unit{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .unit{
    grid-template-rows:22px minmax(0,1fr) 25px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .uimg{
    height:100%!important;
    min-height:0!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .enemy-hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .ally-hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-defense-lane{
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .enemy-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .ally-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-defense-lane .hq-battlefield-grid{
    min-height:var(--v191-card-h)!important;
    height:var(--v191-card-h)!important;
    max-height:var(--v191-card-h)!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v191-card-w:75px;
    --v191-card-h:116px;
    --v191-card-gap:5px;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    min-height:132px!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v191-card-w:80px;
    --v191-card-h:124px; 
    --v191-card-gap:6px;
    --v191-lane-pad-x:4px;
    --v191-lane-pad-top:18px;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{
    min-height:calc(28px + (var(--v191-card-h) * 2) + var(--v191-card-gap) + 16px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:calc(28px + (var(--v191-card-h) * 2) + var(--v191-card-gap) + 16px)!important;
    min-height:calc(28px + (var(--v191-card-h) * 2) + var(--v191-card-gap) + 16px)!important;
    max-height:calc(28px + (var(--v191-card-h) * 2) + var(--v191-card-gap) + 16px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v191-card-w))!important;
    grid-template-rows:repeat(2,var(--v191-card-h))!important;
    grid-auto-rows:var(--v191-card-h)!important;
    gap:var(--v191-card-gap)!important;
    justify-content:space-between!important;
    align-content:start!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v191-card-w)!important;
    min-width:var(--v191-card-w)!important;
    max-width:var(--v191-card-w)!important;
    height:var(--v191-card-h)!important;
    min-height:var(--v191-card-h)!important;
    max-height:var(--v191-card-h)!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    gap:4px!important;
    padding:4px 4px 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    flex:0 0 auto!important;
    min-height:calc(var(--v191-card-h) + var(--v191-lane-pad-top) + 8px)!important;
    height:auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .enemy-hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .ally-hq-defense-lane{
    padding:var(--v191-lane-pad-top) var(--v191-lane-pad-x) 4px!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane .label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-defense-lane .label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .enemy-hq-defense-lane .label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .ally-hq-defense-lane .label{
    top:2px!important;
    left:6px!important;
    font-size:12px!important;
    line-height:1!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    width:100%!important;
    max-width:none!important;
    min-height:var(--v191-card-h)!important;
    height:var(--v191-card-h)!important;
    padding:0!important;
    margin:0!important;
    justify-content:space-between!important;
    align-items:stretch!important;
    align-content:stretch!important;
    gap:var(--v191-card-gap)!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    display:grid!important;
    grid-template-columns:repeat(4,var(--v191-card-w))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    display:grid!important;
    grid-template-columns:repeat(3,var(--v191-card-w))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    display:grid!important;
    grid-template-columns:repeat(2,var(--v191-card-w))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    display:grid!important;
    grid-template-columns:repeat(5,var(--v191-card-w))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v191-card-w)!important;
    min-width:var(--v191-card-w)!important;
    max-width:var(--v191-card-w)!important;
    height:var(--v191-card-h)!important;
    min-height:var(--v191-card-h)!important;
    max-height:var(--v191-card-h)!important;
    aspect-ratio:2 / 3.1!important;
    margin:0!important;
    justify-self:stretch!important;
    align-self:stretch!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .base-unit{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .enemy-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .ally-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-defense-lane .hq-battlefield-grid{
    height:var(--v191-card-h)!important;
    min-height:var(--v191-card-h)!important;
    max-height:var(--v191-card-h)!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v191-card-w:76px;
    --v191-card-h:118px;
    --v191-card-gap:5px;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v192-card-w:84px;
    --v192-card-h:117.6px; 
    --v192-card-gap:6px;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{
    min-height:calc(28px + (var(--v192-card-h) * 2) + var(--v192-card-gap) + 18px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:calc(28px + (var(--v192-card-h) * 2) + var(--v192-card-gap) + 18px)!important;
    min-height:calc(28px + (var(--v192-card-h) * 2) + var(--v192-card-gap) + 18px)!important;
    max-height:calc(28px + (var(--v192-card-h) * 2) + var(--v192-card-gap) + 18px)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v192-card-w))!important;
    grid-template-rows:repeat(2,var(--v192-card-h))!important;
    grid-auto-rows:var(--v192-card-h)!important;
    gap:var(--v192-card-gap)!important;
    justify-content:space-between!important;
    align-content:start!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v192-card-w)!important;
    min-width:var(--v192-card-w)!important;
    max-width:var(--v192-card-w)!important;
    height:var(--v192-card-h)!important;
    min-height:var(--v192-card-h)!important;
    max-height:var(--v192-card-h)!important;
    aspect-ratio:2.5 / 3.5!important;
    grid-template-rows:30px minmax(0,1fr) 28px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-title-area{
    grid-template-columns:minmax(0,1fr) auto auto!important;
    height:30px!important;
    min-height:30px!important;
    max-height:30px!important;
    padding:2px 4px!important;
    align-items:start!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-name-text{
    white-space:normal!important;
    overflow:hidden!important;
    text-overflow:clip!important;
    display:-webkit-box!important;
    -webkit-line-clamp:2!important;
    -webkit-box-orient:vertical!important;
    line-height:1.03!important;
    font-size:10px!important;
    word-break:keep-all!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-ready-badge,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-title-grade{
    align-self:center!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-grid{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .item-bonus-summary-cell{
    grid-column:1 / -1!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:center!important;
    gap:2px!important;
    padding:2px 3px!important;
    border-right:0!important;
    background:rgba(255,255,255,.03)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .item-bonus-summary-cell b{
    font-size:12px!important;
    line-height:1!important;
    color:#fff2bd!important;
    letter-spacing:.02em!important;
    white-space:nowrap!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .item-bonus-summary-cell span{
    display:block!important;
    font-size:8px!important;
    line-height:1!important;
    color:#d8dfe8!important;
    white-space:nowrap!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    gap:4px!important;
    padding:4px 4px 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    min-height:calc(var(--v192-card-h) + 4px)!important;
    height:auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .enemy-hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .ally-hq-defense-lane{
    padding:2px 0 2px!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .lane .label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-defense-lane .label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .enemy-hq-defense-lane .label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .ally-hq-defense-lane .label{
    top:1px!important;
    left:6px!important;
    font-size:11px!important;
    line-height:1!important;
    padding:0!important;
    margin:0!important;
    pointer-events:none!important;
    opacity:.92!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v192-card-w)!important;
    min-width:var(--v192-card-w)!important;
    max-width:var(--v192-card-w)!important;
    height:var(--v192-card-h)!important;
    min-height:var(--v192-card-h)!important;
    max-height:var(--v192-card-h)!important;
    aspect-ratio:2.5 / 3.5!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    padding:0!important;
    margin:0 auto!important;
    max-width:none!important;
    height:var(--v192-card-h)!important;
    min-height:var(--v192-card-h)!important;
    gap:var(--v192-card-gap)!important;
    align-items:stretch!important;
    align-content:stretch!important;
    justify-content:center!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    width:calc((var(--v192-card-w) * 6) + (var(--v192-card-gap) * 4))!important;
    grid-template-columns:repeat(5,var(--v192-card-w))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    width:calc((var(--v192-card-w) * 5) + (var(--v192-card-gap) * 3))!important;
    grid-template-columns:repeat(4,var(--v192-card-w))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    width:calc((var(--v192-card-w) * 4) + (var(--v192-card-gap) * 2))!important;
    grid-template-columns:repeat(3,var(--v192-card-w))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    width:calc((var(--v192-card-w) * 3) + (var(--v192-card-gap) * 1))!important;
    grid-template-columns:repeat(2,var(--v192-card-w))!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .enemy-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .ally-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-defense-lane .hq-battlefield-grid{
    height:var(--v192-card-h)!important;
    min-height:var(--v192-card-h)!important;
    max-height:var(--v192-card-h)!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v192-card-w:80px;
    --v192-card-h:112px;
    --v192-card-gap:5px;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v193-card-w:84px;
    --v193-card-h:120px; 
    --v193-field-gap:6px;
    --v193-hand-gap:0px;
    --v193-hand-section-h:286px;
    --v193-formation-w:534px; 
    --v193-five-card-w:444px;
    --v193-four-card-w:354px;
    --v193-three-card-w:264px;
    --v193-two-card-w:174px;
    --v193-lane-h:124px; 
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{
    min-height:var(--v193-hand-section-h)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:var(--v193-hand-section-h)!important;
    min-height:var(--v193-hand-section-h)!important;
    max-height:var(--v193-hand-section-h)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v193-card-w))!important;
    grid-template-rows:repeat(2,var(--v193-card-h))!important;
    grid-auto-rows:var(--v193-card-h)!important;
    column-gap:0!important;
    row-gap:0!important;
    gap:0!important;
    justify-content:center!important;
    align-content:start!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v193-card-w)!important;
    min-width:var(--v193-card-w)!important;
    max-width:var(--v193-card-w)!important;
    height:var(--v193-card-h)!important;
    min-height:var(--v193-card-h)!important;
    max-height:var(--v193-card-h)!important;
    margin:0!important;
    aspect-ratio:2.8 / 4!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v193-card-w)!important;
    min-width:var(--v193-card-w)!important;
    max-width:var(--v193-card-w)!important;
    height:var(--v193-card-h)!important;
    min-height:var(--v193-card-h)!important;
    max-height:var(--v193-card-h)!important;
    margin:0!important;
    aspect-ratio:2.8 / 4!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    align-items:center!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    width:var(--v193-formation-w)!important;
    min-width:var(--v193-formation-w)!important;
    max-width:var(--v193-formation-w)!important;
    height:var(--v193-lane-h)!important;
    min-height:var(--v193-lane-h)!important;
    max-height:var(--v193-lane-h)!important;
    flex:0 0 var(--v193-lane-h)!important;
    align-self:center!important;
    padding:2px 0 0!important;
    margin-left:auto!important;
    margin-right:auto!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    height:var(--v193-card-h)!important;
    min-height:var(--v193-card-h)!important;
    max-height:var(--v193-card-h)!important;
    padding:0!important;
    gap:var(--v193-field-gap)!important;
    align-items:stretch!important;
    align-content:stretch!important;
    justify-content:center!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    display:grid!important;
    grid-template-columns:repeat(5,var(--v193-card-w))!important;
    width:var(--v193-five-card-w)!important;
    min-width:var(--v193-five-card-w)!important;
    max-width:var(--v193-five-card-w)!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    display:grid!important;
    grid-template-columns:repeat(4,var(--v193-card-w))!important;
    width:var(--v193-four-card-w)!important;
    min-width:var(--v193-four-card-w)!important;
    max-width:var(--v193-four-card-w)!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    display:grid!important;
    grid-template-columns:repeat(3,var(--v193-card-w))!important;
    width:var(--v193-three-card-w)!important;
    min-width:var(--v193-three-card-w)!important;
    max-width:var(--v193-three-card-w)!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    display:grid!important;
    grid-template-columns:repeat(2,var(--v193-card-w))!important;
    width:var(--v193-two-card-w)!important;
    min-width:var(--v193-two-card-w)!important;
    max-width:var(--v193-two-card-w)!important;
    margin:0 auto!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .enemy-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .ally-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-defense-lane .hq-battlefield-grid{
    height:var(--v193-card-h)!important;
    min-height:var(--v193-card-h)!important;
    max-height:var(--v193-card-h)!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v193-card-w:80px;
    --v193-card-h:114.2857px; 
    --v193-field-gap:5px;
    --v193-hand-section-h:274.5714px;
    --v193-formation-w:505px; 
    --v193-five-card-w:420px;
    --v193-four-card-w:335px;
    --v193-three-card-w:250px;
    --v193-two-card-w:165px;
    --v193-lane-h:118.2857px;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:414px minmax(720px,1fr)!important; 
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v193-card-w:84px;
    --v193-card-h:122.1818px; 
    --v193-field-gap:6px;
    --v193-hand-gap:0px;
    --v193-hand-section-h:302px;
    --v193-formation-w:534px; 
    --v193-five-card-w:444px;
    --v193-four-card-w:354px;
    --v193-three-card-w:264px;
    --v193-two-card-w:174px;
    --v193-lane-h:126.1818px;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{min-height:var(--v193-hand-section-h)!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:var(--v193-hand-section-h)!important;min-height:var(--v193-hand-section-h)!important;max-height:var(--v193-hand-section-h)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v193-card-w))!important;grid-template-rows:repeat(2,var(--v193-card-h))!important;grid-auto-rows:var(--v193-card-h)!important;
    column-gap:0!important;row-gap:0!important;gap:0!important;justify-content:center!important;align-content:start!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v193-card-w)!important;min-width:var(--v193-card-w)!important;max-width:var(--v193-card-w)!important;
    height:var(--v193-card-h)!important;min-height:var(--v193-card-h)!important;max-height:var(--v193-card-h)!important;
    margin:0!important;aspect-ratio:3.3 / 4.8!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v193-card-w)!important;min-width:var(--v193-card-w)!important;max-width:var(--v193-card-w)!important;
    height:var(--v193-card-h)!important;min-height:var(--v193-card-h)!important;max-height:var(--v193-card-h)!important;
    margin:0!important;aspect-ratio:3.3 / 4.8!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{align-items:center!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    width:var(--v193-formation-w)!important;min-width:var(--v193-formation-w)!important;max-width:var(--v193-formation-w)!important;
    height:var(--v193-lane-h)!important;min-height:var(--v193-lane-h)!important;max-height:var(--v193-lane-h)!important;
    flex:0 0 var(--v193-lane-h)!important;align-self:center!important;padding:2px 0 0!important;margin-left:auto!important;margin-right:auto!important;overflow:hidden!important;box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    height:var(--v193-card-h)!important;min-height:var(--v193-card-h)!important;max-height:var(--v193-card-h)!important;
    padding:0!important;gap:var(--v193-field-gap)!important;align-items:stretch!important;align-content:stretch!important;justify-content:center!important;overflow:hidden!important;box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    display:grid!important;grid-template-columns:repeat(5,var(--v193-card-w))!important;
    width:var(--v193-five-card-w)!important;min-width:var(--v193-five-card-w)!important;max-width:var(--v193-five-card-w)!important;margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    display:grid!important;grid-template-columns:repeat(4,var(--v193-card-w))!important;
    width:var(--v193-four-card-w)!important;min-width:var(--v193-four-card-w)!important;max-width:var(--v193-four-card-w)!important;margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    display:grid!important;grid-template-columns:repeat(3,var(--v193-card-w))!important;
    width:var(--v193-three-card-w)!important;min-width:var(--v193-three-card-w)!important;max-width:var(--v193-three-card-w)!important;margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    display:grid!important;grid-template-columns:repeat(2,var(--v193-card-w))!important;
    width:var(--v193-two-card-w)!important;min-width:var(--v193-two-card-w)!important;max-width:var(--v193-two-card-w)!important;margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .enemy-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .ally-hq-defense-lane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-defense-lane .hq-battlefield-grid{
    height:var(--v193-card-h)!important;min-height:var(--v193-card-h)!important;max-height:var(--v193-card-h)!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-section{order:4!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host{order:5!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host{order:6!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-section{order:7!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{order:8!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-bottom-actions{order:9!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .desktop-ui-mode-switch{order:10!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #desktopOnlineMatchInfo{order:11!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #desktopMatchWaitingNotice{order:12!important;}

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host{
    padding:6px 7px!important;
    background:#080d10!important;
    border-bottom:1px solid #5b3e20!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .battle-status-pair{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:0!important;
    margin:0!important;
    padding:0!important;
    width:100%!important;
    border:1px solid #7a532c!important;
    background:linear-gradient(180deg,#0e1418,#080b0f)!important;
    box-shadow:0 8px 24px #0008,inset 0 0 0 1px #000!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar{
    min-width:0!important;
    min-height:78px!important;
    padding:0!important;
    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;
    cursor:default!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .enemy-quickbar{
    background:linear-gradient(180deg,#351517,#12090a)!important;
    border-right:1px solid #7a532c!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .ally-quickbar{
    background:linear-gradient(180deg,#122946,#08111c)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar:hover,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar:focus{filter:none!important;outline:none!important;box-shadow:none!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar-title{
    display:flex!important;align-items:center!important;gap:4px!important;height:28px!important;margin:0!important;padding:0 8px!important;
    border-bottom:1px solid #ffffff22!important;font-size:12px!important;font-weight:900!important;line-height:1!important;color:#e8edf2!important;
    text-align:left!important;letter-spacing:-.01em!important;white-space:nowrap!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .enemy-quickbar .hq-quickbar-title{color:#ffdbde!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .ally-quickbar .hq-quickbar-title{color:#dbeaff!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar-stats{
    display:flex!important;align-items:center!important;gap:8px!important;padding:8px 8px 9px!important;flex-wrap:wrap!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat{
    position:relative!important;display:inline-flex!important;align-items:center!important;justify-content:flex-start!important;gap:3px!important;
    min-width:0!important;min-height:0!important;padding:0!important;border:0!important;background:transparent!important;font-size:12px!important;color:#f6f7fb!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat::before{display:none!important;content:none!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-icon{display:inline-flex!important;align-items:center!important;justify-content:center!important;width:auto!important;min-width:10px!important;font-size:13px!important;line-height:1!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quick-stat b{color:#fff!important;font-size:12px!important;font-weight:900!important;line-height:1!important;white-space:nowrap!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .enemy-quickbar .hq-quick-stat.turn{display:none!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host .hq-quickbar-hint{display:none!important;}

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-section{
    padding:0 7px 7px!important;background:#080d10!important;border-bottom:1px solid #5b3e20!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-head{
    display:flex!important;align-items:center!important;justify-content:space-between!important;gap:8px!important;
    padding:6px 8px!important;border:1px solid #6e4926!important;border-bottom:0!important;background:linear-gradient(180deg,#1d1710,#0b0a09)!important;
    color:#f1e3c8!important;font-size:12px!important;font-weight:900!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-head small{color:#bba88b!important;font-size:9px!important;font-weight:700!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:186px!important;min-height:186px!important;max-height:186px!important;overflow:hidden!important;
    padding:8px!important;border:1px solid #6e4926!important;background:linear-gradient(180deg,#0d1318,#090d10)!important;
    box-shadow:inset 0 0 0 1px #000!important;color:#d8e0ea!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-card{display:grid!important;grid-template-columns:1fr!important;gap:6px!important;height:100%!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-title{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:8px!important;color:#fff3da!important;min-height:18px!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-title b{font-size:13px!important;line-height:1.2!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-type{flex:0 0 auto!important;padding:2px 6px!important;border:1px solid #7a5b33!important;background:#15110c!important;color:#f6dfb4!important;font-size:9px!important;font-weight:900!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-note{color:#8fbaff!important;font-size:9px!important;font-weight:800!important;line-height:1.2!important;min-height:12px!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-effect-empty{display:flex!important;align-items:center!important;justify-content:center!important;height:100%!important;text-align:center!important;color:#9daaba!important;font-size:10px!important;line-height:1.6!important;padding:0 8px!important;}

  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-grid{
    display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-template-rows:repeat(2,1fr)!important;gap:6px!important;flex:1 1 auto!important;min-height:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-item{
    display:grid!important;grid-template-columns:58px minmax(0,1fr)!important;gap:6px!important;align-items:center!important;
    min-height:0!important;padding:5px!important;border:1px solid #284157!important;background:linear-gradient(180deg,#0f1c29,#0a121b)!important;overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-thumb{
    width:58px!important;height:48px!important;border:1px solid #4c647e!important;background:#0b1016!important;overflow:hidden!important;display:flex!important;align-items:center!important;justify-content:center!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-thumb img{width:100%!important;height:100%!important;object-fit:cover!important;display:block!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-thumb.no-image{background:linear-gradient(180deg,#1a2736,#101821)!important;color:#9db8d5!important;font-size:11px!important;font-weight:900!important;letter-spacing:-.02em!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-meta{min-width:0!important;display:grid!important;gap:4px!important;align-content:center!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-kind{color:#ffe7bf!important;font-size:10px!important;font-weight:900!important;line-height:1!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-effect{color:#d5e4f3!important;font-size:10px!important;font-weight:700!important;line-height:1.25!important;word-break:keep-all!important;display:-webkit-box!important;-webkit-line-clamp:2!important;-webkit-box-orient:vertical!important;overflow:hidden!important;}

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{padding:0!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    padding:0!important;display:flex!important;justify-content:center!important;align-items:stretch!important;overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout{
    width:var(--v193-formation-w)!important;min-width:var(--v193-formation-w)!important;max-width:var(--v193-formation-w)!important;
    margin:0 auto!important;padding:0!important;display:block!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    width:var(--v193-formation-w)!important;min-width:var(--v193-formation-w)!important;max-width:var(--v193-formation-w)!important;
    margin:0 auto!important;padding:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .river{
    width:var(--v193-formation-w)!important;min-width:var(--v193-formation-w)!important;max-width:var(--v193-formation-w)!important;margin:0 auto!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .cimg,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .cstats,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-title-area,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .base-unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .default-art,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .art,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .grade,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .buff,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .typeicon{border-radius:0!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{aspect-ratio:3.3 / 4.8!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{aspect-ratio:3.3 / 4.8!important;}
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{grid-template-columns:414px minmax(680px,1fr)!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v193-card-w:80px;
    --v193-card-h:116.3636px; 
    --v193-field-gap:5px;
    --v193-hand-section-h:292px;
    --v193-formation-w:505px;
    --v193-five-card-w:420px;
    --v193-four-card-w:335px;
    --v193-three-card-w:250px;
    --v193-two-card-w:165px;
    --v193-lane-h:120.3636px;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{height:176px!important;min-height:176px!important;max-height:176px!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-item{grid-template-columns:52px minmax(0,1fr)!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-scene-thumb{width:52px!important;height:42px!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .river{
    width:var(--v193-formation-w)!important;min-width:var(--v193-formation-w)!important;max-width:var(--v193-formation-w)!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:435px minmax(720px,1fr)!important; 
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel{order:1!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-menu-dock{order:2!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-setup-host{order:3!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-section{order:4!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host{order:5!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{order:6!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host{order:7!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hq-utility-section{order:8!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-utility-action-row{order:9!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #desktopOnlineMatchInfo{order:10!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #desktopMatchWaitingNotice{order:11!important;}

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-utility-action-row{
    display:grid!important;
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:5px!important;
    width:100%!important;
    padding:7px!important;
    border-top:1px solid #5b3e20!important;
    border-bottom:1px solid #5b3e20!important;
    background:#080d10!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-utility-action-row .btn{
    width:100%!important;
    min-width:0!important;
    height:42px!important;
    min-height:42px!important;
    max-height:42px!important;
    box-sizing:border-box!important;
    padding:0 3px!important;
    font-size:10px!important;
    line-height:1!important;
    white-space:nowrap!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-utility-action-row #settingsBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-utility-action-row #rulesBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-utility-action-row .btn[data-ui-mode]{
    height:42px!important;
    min-height:42px!important;
    max-height:42px!important;
    box-sizing:border-box!important;
    padding:4px 3px!important;
    font-size:10px!important;
    line-height:1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-bottom-actions,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .desktop-ui-mode-switch{
    display:none!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:186px!important;
    min-height:186px!important;
    max-height:186px!important;
    padding:6px!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-card{
    display:grid!important;
    grid-template-rows:20px minmax(0,1fr) 25px!important;
    gap:4px!important;
    height:100%!important;
    min-height:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-title{
    min-height:20px!important;
    height:20px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage{
    position:relative!important;
    min-height:0!important;
    overflow:hidden!important;
    isolation:isolate!important;
    border:1px solid #314e68!important;
    background:radial-gradient(circle at 50% 42%,#162a3c,#070c11 72%)!important;
    box-shadow:inset 0 0 18px #000!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene{
    position:absolute!important;
    inset:0!important;
    left:0!important;
    top:0!important;
    right:0!important;
    bottom:0!important;
    width:100%!important;
    height:100%!important;
    min-width:0!important;
    min-height:0!important;
    max-width:none!important;
    max-height:none!important;
    margin:0!important;
    z-index:1!important;
    border-radius:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene .scene-label{
    left:5px!important;
    right:5px!important;
    bottom:4px!important;
    padding:3px 5px!important;
    font-size:9px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene .scene-effect-caption{
    top:5px!important;
    left:5px!important;
    right:5px!important;
    gap:2px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene .scene-title-big{
    padding:2px 7px!important;
    font-size:11px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene .scene-title-small{
    padding:2px 6px!important;
    font-size:8px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage-badge{
    position:absolute!important;
    top:5px!important;
    left:5px!important;
    z-index:20!important;
    display:flex!important;
    align-items:center!important;
    gap:5px!important;
    padding:3px 6px!important;
    border:1px solid #ffffff3a!important;
    background:#03070cd9!important;
    color:#fff4da!important;
    font-size:9px!important;
    font-weight:900!important;
    pointer-events:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage-badge span{
    color:#9ed0ff!important;
    font-weight:800!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-scene-tabs{
    display:grid!important;
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:4px!important;
    min-height:25px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-scene-tab{
    height:25px!important;
    min-height:25px!important;
    padding:2px 3px!important;
    border:1px solid #35485b!important;
    border-radius:0!important;
    background:#0b141d!important;
    color:#aebdca!important;
    font-size:9px!important;
    font-weight:900!important;
    cursor:pointer!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-scene-tab.active{
    border-color:#c58b43!important;
    background:linear-gradient(180deg,#3b2814,#171008)!important;
    color:#ffe7bd!important;
    box-shadow:inset 0 0 0 1px #000!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-effect-empty{
    height:100%!important;
    border:1px solid #314e68!important;
    background:radial-gradient(circle at 50% 42%,#162a3c,#070c11 72%)!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    align-items:center!important;
    padding:0!important;
    background:transparent!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    flex:0 0 auto!important;
    width:var(--v193-formation-w)!important;
    min-width:var(--v193-formation-w)!important;
    max-width:var(--v193-formation-w)!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    margin:0 auto!important;
    padding:0!important;
    overflow:visible!important;
    background:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    width:var(--v193-formation-w)!important;
    min-width:var(--v193-formation-w)!important;
    max-width:var(--v193-formation-w)!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
    padding:0!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    display:flex!important;
    flex-direction:column!important;
    justify-content:flex-start!important;
    align-items:stretch!important;
    gap:0!important;
    background:transparent!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane{
    margin:0!important;
    border-radius:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .bottom-hud{
    width:100%!important;
    align-self:stretch!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:435px minmax(680px,1fr)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:176px!important;
    min-height:176px!important;
    max-height:176px!important;
  }
}

@media (min-width:851px){
  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:414px minmax(720px,1fr)!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview){
    
    --v193-card-h:132px;
    --v193-card-w:90.75px; 
    --v193-field-gap:6px;
    --v193-hand-gap:0px;
    --v193-hand-section-h:302px;
    --v193-formation-w:574.5px; 
    --v193-five-card-w:477.75px;
    --v193-four-card-w:381px;
    --v193-three-card-w:284.25px;
    --v193-two-card-w:187.5px;
    --v193-lane-h:134px; 
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:279px!important;
    min-height:279px!important;
    max-height:279px!important;
    padding:6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-card.action-view-mode{
    display:grid!important;
    grid-template-rows:24px minmax(0,1fr)!important;
    gap:5px!important;
    height:100%!important;
    min-height:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-title{
    min-height:24px!important;
    height:24px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage{
    min-height:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-scene-tabs{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-effect-empty{
    height:100%!important;
    border:1px solid #314e68!important;
    background:radial-gradient(circle at 50% 42%,#111d27,#070c11 72%)!important;
    color:#7f93a5!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:var(--v193-hand-section-h)!important;
    min-height:var(--v193-hand-section-h)!important;
    max-height:var(--v193-hand-section-h)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox{
    padding:5px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v193-card-w))!important;
    grid-template-rows:repeat(2,var(--v193-card-h))!important;
    grid-auto-rows:var(--v193-card-h)!important;
    gap:0!important;
    padding:0!important;
    justify-content:center!important;
    align-content:stretch!important;
    overflow-x:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v193-card-w)!important;
    min-width:var(--v193-card-w)!important;
    max-width:var(--v193-card-w)!important;
    height:var(--v193-card-h)!important;
    min-height:var(--v193-card-h)!important;
    max-height:var(--v193-card-h)!important;
    margin:0!important;
    aspect-ratio:3.3 / 4.8!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v193-card-w)!important;
    min-width:var(--v193-card-w)!important;
    max-width:var(--v193-card-w)!important;
    height:var(--v193-card-h)!important;
    min-height:var(--v193-card-h)!important;
    max-height:var(--v193-card-h)!important;
    margin:0!important;
    aspect-ratio:3.3 / 4.8!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    width:var(--v193-formation-w)!important;
    min-width:var(--v193-formation-w)!important;
    max-width:var(--v193-formation-w)!important;
    height:var(--v193-lane-h)!important;
    min-height:var(--v193-lane-h)!important;
    max-height:var(--v193-lane-h)!important;
    flex:0 0 var(--v193-lane-h)!important;
    padding:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    height:var(--v193-card-h)!important;
    min-height:var(--v193-card-h)!important;
    max-height:var(--v193-card-h)!important;
    padding:0!important;
    align-items:stretch!important;
    align-content:stretch!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,var(--v193-card-w))!important;
    width:var(--v193-five-card-w)!important;
    min-width:var(--v193-five-card-w)!important;
    max-width:var(--v193-five-card-w)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,var(--v193-card-w))!important;
    width:var(--v193-four-card-w)!important;
    min-width:var(--v193-four-card-w)!important;
    max-width:var(--v193-four-card-w)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,var(--v193-card-w))!important;
    width:var(--v193-three-card-w)!important;
    min-width:var(--v193-three-card-w)!important;
    max-width:var(--v193-three-card-w)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,var(--v193-card-w))!important;
    width:var(--v193-two-card-w)!important;
    min-width:var(--v193-two-card-w)!important;
    max-width:var(--v193-two-card-w)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .river,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    width:var(--v193-formation-w)!important;
    min-width:var(--v193-formation-w)!important;
    max-width:var(--v193-formation-w)!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:414px minmax(680px,1fr)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    
    --v193-card-h:127px;
    --v193-card-w:87.3125px;
    --v193-field-gap:5px;
    --v193-hand-section-h:292px;
    --v193-formation-w:548.875px;
    --v193-five-card-w:456.5625px;
    --v193-four-card-w:364.25px;
    --v193-three-card-w:271.9375px;
    --v193-two-card-w:179.625px;
    --v193-lane-h:129px;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:264px!important;
    min-height:264px!important;
    max-height:264px!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .online-account-bar,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .faction-pickers{
    display:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions #matchmakingBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions #cardManagerBtn{
    display:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-in{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) repeat(2,minmax(72px,auto))!important;
    gap:6px!important;
    align-items:center!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-in #leftAuthStateText{
    min-width:0!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-in #cardManagerBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-in #leftLogoutBtn{
    width:100%!important;
    min-width:72px!important;
    height:31px!important;
    min-height:31px!important;
    max-height:31px!important;
    padding:4px 8px!important;
    font-size:10px!important;
    font-weight:900!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-in #cardManagerBtn{
    border-color:#7c5cff!important;
    background:linear-gradient(180deg,#4932a8,#281568)!important;
    color:#f5efff!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host .deck-info{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host #matchmakingBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host #battleControlBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host #shuffleBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host #endTurnBtn{
    order:initial!important;
    width:100%!important;
    min-width:0!important;
    min-height:32px!important;
    height:32px!important;
    max-height:32px!important;
    padding:4px 6px!important;
    font-size:10px!important;
    font-weight:900!important;
  }
}

#matchmakingBtn{white-space:nowrap!important;}

#mobileMatchmakingBtn{white-space:nowrap!important;}

@media (min-width:851px){
  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:349px minmax(720px,1fr)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .boardwrap{
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left::-webkit-scrollbar,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel::-webkit-scrollbar,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .boardwrap::-webkit-scrollbar{
    width:0!important;
    height:0!important;
    display:none!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left > section,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left > div{
    box-sizing:border-box!important;
    width:100%!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-menu-dock,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-panel,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-setup-host .compact-settings-holder,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-section,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-bottom-actions,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .desktop-ui-mode-switch,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #desktopOnlineMatchInfo{
    width:100%!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    overflow-y:auto!important;
    overflow-x:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .boardwrap{
    flex:0 0 auto!important;
    min-height:0!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    padding-bottom:12px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout>.board{
    padding-bottom:12px!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout>.board > #allyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #allyBaseDefenseLane{
    margin-bottom:10px!important;
    padding-bottom:6px!important;
  }

  
  .card-shop-box,
  #boosterPackModal .modalbox{
    height:min(92vh, 860px)!important;
    max-height:min(92vh, 860px)!important;
    display:flex!important;
    flex-direction:column!important;
    overflow:hidden!important;
  }
  #boosterPackGrid,
  .card-shop-grid{
    flex:1 1 auto!important;
    overflow:auto!important;
  }

  
  #allyHqQuickBar .hq-quickbar-title{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:8px!important;
  }
  #allyHqQuickBar .hq-quick-stat.turn{
    display:none!important;
  }
  #allyHqQuickBar .hq-quickbar-turn-inline{
    flex:0 0 auto!important;
    display:inline-flex!important;
    align-items:center!important;
    gap:4px!important;
    padding:1px 6px!important;
    border:1px solid rgba(255,255,255,.2)!important;
    border-radius:999px!important;
    background:rgba(0,0,0,.28)!important;
    color:#f4e6cf!important;
    font-size:9px!important;
    font-weight:900!important;
    line-height:1.2!important;
    white-space:nowrap!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-head{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-section{
    padding-top:6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body .card-effect-empty{
    display:none!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:402px minmax(680px,1fr)!important;
  }
}

.card-shop-box,
#boosterPackModal .modalbox{
  height:min(92vh,860px)!important;
  max-height:min(92vh,860px)!important;
}
.top-card-actions .btn,
#mobileDeckMenu .mobile-menu-actions .btn{
  min-height:31px!important;
  height:31px!important;
  max-height:31px!important;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:251px!important;
    min-height:251px!important;
    max-height:251px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane:not(.hq-defense-lane),
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .hq-defense-lane.active{
    height:auto!important;
    min-height:calc(var(--v193-card-h,132px) + 14px)!important;
    padding-top:3px!important;
    padding-bottom:5px!important;
    overflow:visible!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    overflow:visible!important;
  }
}
@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:238px!important;
    min-height:238px!important;
    max-height:238px!important;
  }
}

@media (max-width:850px){
  :root{
    --v201-mobile-gap:2px;
    --v201-mobile-side:8px;
    --v201-mobile-card-w:calc((100vw - (var(--v201-mobile-side) * 2) - (var(--v201-mobile-gap) * 4)) / 5);
    --v201-mobile-card-h:calc(var(--v201-mobile-card-w) * 48 / 33);
    --v201-mobile-hand-height:calc(var(--v201-mobile-card-h) + 28px);
    --v201-mobile-status-h:68px;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-combat-summary,
  body.ui-mode-mobile:not(.prebattle) #enemyHqMount,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-mount,
  body.ui-mode-mobile:not(.prebattle) .enemy-hq-row,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-combat-summary,
  body.ui-mode-mobile-preview:not(.prebattle) #enemyHqMount,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-mount,
  body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row{
    display:none!important;
  }

  body.ui-mode-mobile:not(.prebattle) .battlefield-layout>.board,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board{
    gap:4px!important;
  }
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout>.board>.lane:not(.hq-defense-lane),
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board>.lane:not(.hq-defense-lane),
  body.ui-mode-mobile:not(.prebattle) .hq-defense-lane.active,
  body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane.active{
    box-sizing:border-box!important;
    min-height:calc(var(--v201-mobile-card-h) + 10px)!important;
    height:auto!important;
    padding:3px 4px 5px!important;
    overflow:visible!important;
  }

  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .hq-battlefield-grid,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-battlefield-grid{
    width:100%!important;
    max-width:100%!important;
    margin:0 auto!important;
    gap:var(--v201-mobile-gap)!important;
    padding:0!important;
    justify-content:space-between!important;
    align-items:stretch!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots.n5,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n5,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .hq-battlefield-grid,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,var(--v201-mobile-card-w))!important;
  }
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots.n4,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n4{grid-template-columns:repeat(4,var(--v201-mobile-card-w))!important;}
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots.n3,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n3{grid-template-columns:repeat(3,var(--v201-mobile-card-w))!important;}
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots.n2,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n2{grid-template-columns:repeat(2,var(--v201-mobile-card-w))!important;}

  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slot,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slot,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .hq-field-slot,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-field-slot,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    width:var(--v201-mobile-card-w)!important;
    min-width:var(--v201-mobile-card-w)!important;
    max-width:var(--v201-mobile-card-w)!important;
    height:var(--v201-mobile-card-h)!important;
    min-height:var(--v201-mobile-card-h)!important;
    max-height:var(--v201-mobile-card-h)!important;
    aspect-ratio:33 / 48!important;
    overflow:visible!important;
  }
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slot>.unit,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slot>.unit,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .hq-field-slot>.unit,
  body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-field-slot>.unit{
    overflow:visible!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount{
    height:var(--v201-mobile-hand-height)!important;
    min-height:var(--v201-mobile-hand-height)!important;
    max-height:var(--v201-mobile-hand-height)!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand,
  body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{
    height:var(--v201-mobile-card-h)!important;
    min-height:var(--v201-mobile-card-h)!important;
    max-height:var(--v201-mobile-card-h)!important;
    gap:var(--v201-mobile-gap)!important;
    padding:0 var(--v201-mobile-side)!important;
    justify-content:flex-start!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) .bottom-hud,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud{
    display:grid!important;
    grid-template-rows:26px 34px!important;
    gap:4px!important;
    height:var(--v201-mobile-status-h)!important;
    min-height:var(--v201-mobile-status-h)!important;
    max-height:var(--v201-mobile-status-h)!important;
    padding:4px 6px!important;
    bottom:var(--v201-mobile-hand-height)!important;
    overflow:hidden!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .mobile-bottom-status-row,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mobile-bottom-status-row{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:4px!important;
    width:100%!important;
    height:26px!important;
    min-height:26px!important;
    max-height:26px!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .mini-quickbar,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mini-quickbar{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:3px!important;
    min-width:0!important;
    padding:2px 4px!important;
    border:1px solid rgba(255,255,255,.12)!important;
    border-radius:6px!important;
    background:rgba(0,0,0,.34)!important;
    overflow:hidden!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .mini-quickbar-label,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mini-quickbar-label{font-size:8px!important;}
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .mini-quick-stat,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mini-quick-stat{font-size:7px!important;gap:1px!important;}
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .mini-quick-stat b,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mini-quick-stat b{font-size:8px!important;}
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-status,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-status{
    display:block!important;
    height:34px!important;
    padding:0!important;
    background:transparent!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-status>:not(.hud-actions),
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-status>:not(.hud-actions){display:none!important;}
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-actions,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-actions{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:4px!important;
    width:100%!important;
    height:34px!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-actions .btn,
  body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-actions .btn{
    min-height:30px!important;
    height:30px!important;
    max-height:30px!important;
    padding:2px 4px!important;
    font-size:9px!important;
  }
  body.ui-mode-mobile:not(.prebattle),
  body.ui-mode-mobile:not(.prebattle) .app,
  body.ui-mode-mobile-preview:not(.prebattle),
  body.ui-mode-mobile-preview:not(.prebattle) .app{
    padding-bottom:calc(var(--v201-mobile-hand-height) + var(--v201-mobile-status-h) + 8px + env(safe-area-inset-bottom,0px))!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle){
  --v201-mobile-gap:2px;
  --v201-mobile-side:8px;
  --v201-mobile-card-w:calc((var(--mobile-play-width,430px) - (var(--v201-mobile-side) * 2) - (var(--v201-mobile-gap) * 4)) / 5);
  --v201-mobile-card-h:calc(var(--v201-mobile-card-w) * 48 / 33);
  --v201-mobile-hand-height:calc(var(--v201-mobile-card-h) + 28px);
  --v201-mobile-status-h:68px;
}

body.ui-mode-mobile-preview:not(.prebattle) .mobile-combat-summary,
body.ui-mode-mobile-preview:not(.prebattle) #enemyHqMount,
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-mount,
body.ui-mode-mobile-preview:not(.prebattle) .enemy-hq-row{display:none!important;}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board{gap:4px!important;}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board>.lane:not(.hq-defense-lane),
body.ui-mode-mobile-preview:not(.prebattle) .hq-defense-lane.active{box-sizing:border-box!important;min-height:calc(var(--v201-mobile-card-h) + 10px)!important;height:auto!important;padding:3px 4px 5px!important;overflow:visible!important;}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-battlefield-grid{width:100%!important;max-width:100%!important;margin:0 auto!important;gap:var(--v201-mobile-gap)!important;padding:0!important;justify-content:space-between!important;align-items:stretch!important;overflow:visible!important;box-sizing:border-box!important;}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n5,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-battlefield-grid{grid-template-columns:repeat(5,var(--v201-mobile-card-w))!important;}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n4{grid-template-columns:repeat(4,var(--v201-mobile-card-w))!important;}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n3{grid-template-columns:repeat(3,var(--v201-mobile-card-w))!important;}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n2{grid-template-columns:repeat(2,var(--v201-mobile-card-w))!important;}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slot,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-field-slot,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{width:var(--v201-mobile-card-w)!important;min-width:var(--v201-mobile-card-w)!important;max-width:var(--v201-mobile-card-w)!important;height:var(--v201-mobile-card-h)!important;min-height:var(--v201-mobile-card-h)!important;max-height:var(--v201-mobile-card-h)!important;aspect-ratio:33 / 48!important;overflow:visible!important;}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount{height:var(--v201-mobile-hand-height)!important;min-height:var(--v201-mobile-hand-height)!important;max-height:var(--v201-mobile-hand-height)!important;}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{height:var(--v201-mobile-card-h)!important;min-height:var(--v201-mobile-card-h)!important;max-height:var(--v201-mobile-card-h)!important;gap:var(--v201-mobile-gap)!important;padding:0 var(--v201-mobile-side)!important;justify-content:flex-start!important;overflow:hidden!important;box-sizing:border-box!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud{display:grid!important;grid-template-rows:26px 34px!important;gap:4px!important;height:var(--v201-mobile-status-h)!important;min-height:var(--v201-mobile-status-h)!important;max-height:var(--v201-mobile-status-h)!important;padding:4px 6px!important;bottom:var(--v201-mobile-hand-height)!important;overflow:hidden!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mobile-bottom-status-row{display:grid!important;grid-template-columns:1fr 1fr!important;gap:4px!important;width:100%!important;height:26px!important;min-height:26px!important;max-height:26px!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mini-quickbar{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:3px!important;min-width:0!important;padding:2px 4px!important;border:1px solid rgba(255,255,255,.12)!important;border-radius:6px!important;background:rgba(0,0,0,.34)!important;overflow:hidden!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mini-quickbar-label{font-size:8px!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mini-quick-stat{font-size:7px!important;gap:1px!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .mini-quick-stat b{font-size:8px!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-status{display:block!important;height:34px!important;padding:0!important;background:transparent!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-status>:not(.hud-actions){display:none!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-actions{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:4px!important;width:100%!important;height:34px!important;}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud .hud-actions .btn{min-height:30px!important;height:30px!important;max-height:30px!important;padding:2px 4px!important;font-size:9px!important;}
body.ui-mode-mobile-preview:not(.prebattle),
body.ui-mode-mobile-preview:not(.prebattle) .app{padding-bottom:calc(var(--v201-mobile-hand-height) + var(--v201-mobile-status-h) + 8px)!important;}

@media (max-width:850px){
  body.ui-mode-mobile:not(.prebattle),
  body.ui-mode-mobile:not(.prebattle) .app,
  body.ui-mode-mobile:not(.prebattle) .battle-panel,
  body.ui-mode-mobile:not(.prebattle) .boardwrap,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout>.board{
    box-sizing:border-box!important;
    min-width:0!important;
    max-width:100%!important;
    overflow-x:hidden!important;
  }

  body.ui-mode-mobile:not(.prebattle) .boardwrap,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout>.board{
    width:100%!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:2px!important;
    padding-right:2px!important;
  }

  body.ui-mode-mobile:not(.prebattle) .battlefield-layout>.board>.lane,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout>.board>.hq-defense-lane{
    box-sizing:border-box!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:3px!important;
    padding-right:3px!important;
    overflow:hidden!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots.n5,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots.n4,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots.n3,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slots.n2,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .hq-battlefield-grid{
    box-sizing:border-box!important;
    display:grid!important;
    grid-template-columns:repeat(5,minmax(0,1fr))!important;
    grid-auto-columns:minmax(0,1fr)!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    gap:2px!important;
    margin:0!important;
    padding:0!important;
    justify-content:stretch!important;
    overflow:hidden!important;
  }

  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slot,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .hq-field-slot{
    box-sizing:border-box!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    aspect-ratio:33 / 48!important;
    margin:0!important;
  }
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .slot>.unit,
  body.ui-mode-mobile:not(.prebattle) .battlefield-layout .hq-field-slot>.unit{
    box-sizing:border-box!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
    margin:0!important;
  }

  
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount .right-hand-section,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount .handbox,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand{
    box-sizing:border-box!important;
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand{
    display:flex!important;
    gap:2px!important;
    padding-left:3px!important;
    padding-right:3px!important;
    overflow:hidden!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    box-sizing:border-box!important;
    flex:0 0 calc((100% - 8px) / 5)!important;
    width:calc((100% - 8px) / 5)!important;
    min-width:0!important;
    max-width:calc((100% - 8px) / 5)!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    aspect-ratio:33 / 48!important;
    margin:0!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle),
body.ui-mode-mobile-preview:not(.prebattle) .app,
body.ui-mode-mobile-preview:not(.prebattle) .battle-panel,
body.ui-mode-mobile-preview:not(.prebattle) .boardwrap,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board{
  box-sizing:border-box!important;
  min-width:0!important;
  max-width:100%!important;
  overflow-x:hidden!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .boardwrap,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board{
  width:100%!important;
  margin-left:0!important;
  margin-right:0!important;
  padding-left:2px!important;
  padding-right:2px!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board>.lane,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout>.board>.hq-defense-lane{
  box-sizing:border-box!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  margin-left:0!important;
  margin-right:0!important;
  padding-left:3px!important;
  padding-right:3px!important;
  overflow:hidden!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n5,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n4,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n3,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slots.n2,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-battlefield-grid{
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  grid-auto-columns:minmax(0,1fr)!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  gap:2px!important;
  margin:0!important;
  padding:0!important;
  justify-content:stretch!important;
  overflow:hidden!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slot,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-field-slot{
  box-sizing:border-box!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  aspect-ratio:33 / 48!important;
  margin:0!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .slot>.unit,
body.ui-mode-mobile-preview:not(.prebattle) .battlefield-layout .hq-field-slot>.unit{
  box-sizing:border-box!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  height:100%!important;
  min-height:0!important;
  max-height:100%!important;
  margin:0!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .right-hand-section,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .handbox,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{
  box-sizing:border-box!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{
  display:flex!important;
  gap:2px!important;
  padding-left:3px!important;
  padding-right:3px!important;
  overflow:hidden!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{
  box-sizing:border-box!important;
  flex:0 0 calc((100% - 8px) / 5)!important;
  width:calc((100% - 8px) / 5)!important;
  min-width:0!important;
  max-width:calc((100% - 8px) / 5)!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  aspect-ratio:33 / 48!important;
  margin:0!important;
}

@media (max-width:850px){
  body.ui-mode-mobile:not(.prebattle){
    --v203-mobile-hand-card-w:min(calc((100vw - 14px) / 5), 82px);
    --v203-mobile-hand-card-h:calc(var(--v203-mobile-hand-card-w) * 48 / 33);
    --v203-mobile-hand-dock-h:calc(var(--v203-mobile-hand-card-h) + 30px);
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount{
    width:100%!important;
    left:0!important;
    right:0!important;
    transform:none!important;
    height:var(--v203-mobile-hand-dock-h)!important;
    min-height:var(--v203-mobile-hand-dock-h)!important;
    max-height:var(--v203-mobile-hand-dock-h)!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount .right-hand-section,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount .handbox,
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand{
    width:100%!important;
    max-width:100%!important;
    box-sizing:border-box!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand{
    height:var(--v203-mobile-hand-card-h)!important;
    min-height:var(--v203-mobile-hand-card-h)!important;
    max-height:var(--v203-mobile-hand-card-h)!important;
    padding-left:3px!important;
    padding-right:3px!important;
  }
  body.ui-mode-mobile:not(.prebattle) .mobile-hand-mount #hand.hand .card{
    flex:0 0 var(--v203-mobile-hand-card-w)!important;
    width:var(--v203-mobile-hand-card-w)!important;
    min-width:var(--v203-mobile-hand-card-w)!important;
    max-width:var(--v203-mobile-hand-card-w)!important;
    height:var(--v203-mobile-hand-card-h)!important;
    min-height:var(--v203-mobile-hand-card-h)!important;
    max-height:var(--v203-mobile-hand-card-h)!important;
  }
  body.ui-mode-mobile:not(.prebattle) .bottom-hud{
    bottom:var(--v203-mobile-hand-dock-h)!important;
  }
  body.ui-mode-mobile:not(.prebattle),
  body.ui-mode-mobile:not(.prebattle) .app{
    padding-bottom:calc(var(--v203-mobile-hand-dock-h) + var(--v201-mobile-status-h,68px) + 8px + env(safe-area-inset-bottom,0px))!important;
  }
}

body.ui-mode-mobile-preview:not(.prebattle){
  --v203-preview-hand-card-w:calc((var(--mobile-play-width,418px) - 14px) / 5);
  --v203-preview-hand-card-h:calc(var(--v203-preview-hand-card-w) * 48 / 33);
  --v203-preview-hand-dock-h:calc(var(--v203-preview-hand-card-h) + 30px);
}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount{
  left:50%!important;
  right:auto!important;
  transform:translateX(-50%)!important;
  width:var(--mobile-play-width,418px)!important;
  min-width:var(--mobile-play-width,418px)!important;
  max-width:var(--mobile-play-width,418px)!important;
  height:var(--v203-preview-hand-dock-h)!important;
  min-height:var(--v203-preview-hand-dock-h)!important;
  max-height:var(--v203-preview-hand-dock-h)!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .right-hand-section,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount .handbox,
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{
  width:var(--mobile-play-width,418px)!important;
  min-width:var(--mobile-play-width,418px)!important;
  max-width:var(--mobile-play-width,418px)!important;
  box-sizing:border-box!important;
  margin-left:auto!important;
  margin-right:auto!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand{
  height:var(--v203-preview-hand-card-h)!important;
  min-height:var(--v203-preview-hand-card-h)!important;
  max-height:var(--v203-preview-hand-card-h)!important;
  padding-left:3px!important;
  padding-right:3px!important;
  overflow:hidden!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .mobile-hand-mount #hand.hand .card{
  flex:0 0 var(--v203-preview-hand-card-w)!important;
  width:var(--v203-preview-hand-card-w)!important;
  min-width:var(--v203-preview-hand-card-w)!important;
  max-width:var(--v203-preview-hand-card-w)!important;
  height:var(--v203-preview-hand-card-h)!important;
  min-height:var(--v203-preview-hand-card-h)!important;
  max-height:var(--v203-preview-hand-card-h)!important;
}
body.ui-mode-mobile-preview:not(.prebattle) .bottom-hud{
  left:50%!important;
  right:auto!important;
  transform:translateX(-50%)!important;
  width:var(--mobile-play-width,418px)!important;
  min-width:var(--mobile-play-width,418px)!important;
  max-width:var(--mobile-play-width,418px)!important;
  bottom:var(--v203-preview-hand-dock-h)!important;
}
body.ui-mode-mobile-preview:not(.prebattle),
body.ui-mode-mobile-preview:not(.prebattle) .app{
  padding-bottom:calc(var(--v203-preview-hand-dock-h) + var(--v201-mobile-status-h,68px) + 8px)!important;
}

@media (max-width:850px){
  body.ui-mode-mobile,
  body.ui-mode-mobile .app{
    margin-bottom:0!important;
    padding-bottom:calc(var(--mobile-action-height,58px) + 4px + env(safe-area-inset-bottom,0px))!important;
  }
  body.ui-mode-mobile .battle-panel,
  body.ui-mode-mobile .boardwrap,
  body.ui-mode-mobile .battlefield-layout,
  body.ui-mode-mobile .battlefield-layout>.board,
  body.ui-mode-mobile .mobile-ally-hq-mount,
  body.ui-mode-mobile .mobile-hand-mount{
    margin-top:0!important;
    margin-bottom:0!important;
    padding-bottom:0!important;
  }
  body.ui-mode-mobile .battle-panel{
    gap:0!important;
    row-gap:0!important;
  }
  body.ui-mode-mobile .boardwrap{
    padding-bottom:2px!important;
  }
  body.ui-mode-mobile .mobile-ally-hq-mount{
    margin:0!important;
  }
  body.ui-mode-mobile .mobile-hand-mount{
    position:relative!important;
    inset:auto!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    bottom:auto!important;
    transform:none!important;
    width:100%!important;
    margin:0!important;
    scroll-margin-top:0!important;
  }
}

body.ui-mode-mobile-preview,
body.ui-mode-mobile-preview .app{
  margin-bottom:0!important;
  padding-bottom:calc(var(--mobile-action-height,58px) + 4px)!important;
}
body.ui-mode-mobile-preview .battle-panel,
body.ui-mode-mobile-preview .boardwrap,
body.ui-mode-mobile-preview .battlefield-layout,
body.ui-mode-mobile-preview .battlefield-layout>.board,
body.ui-mode-mobile-preview .mobile-ally-hq-mount,
body.ui-mode-mobile-preview .mobile-hand-mount{
  margin-top:0!important;
  margin-bottom:0!important;
  padding-bottom:0!important;
}
body.ui-mode-mobile-preview .battle-panel{
  gap:0!important;
  row-gap:0!important;
}
body.ui-mode-mobile-preview .boardwrap{
  padding-bottom:2px!important;
}
body.ui-mode-mobile-preview .mobile-ally-hq-mount{
  margin:0 auto!important;
}
body.ui-mode-mobile-preview .mobile-hand-mount{
  position:relative!important;
  inset:auto!important;
  left:auto!important;
  right:auto!important;
  top:auto!important;
  bottom:auto!important;
  transform:none!important;
  width:var(--mobile-play-width,418px)!important;
  min-width:var(--mobile-play-width,418px)!important;
  max-width:var(--mobile-play-width,418px)!important;
  margin:0 auto!important;
  z-index:20!important;
  box-shadow:none!important;
  scroll-margin-top:0!important;
}
body.ui-mode-mobile-preview .bottom-hud{
  bottom:0!important;
}

.status-top-art-section{
  margin-top:18px;
  border-top:1px solid rgba(255,255,255,.08);
  padding-top:18px;
}
.status-top-art-preview-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
  gap:14px;
  margin-top:12px;
}
.status-top-art-preview-box{
  background:#081523;
  border:1px solid rgba(255,210,120,.28);
  border-radius:14px;
  padding:10px;
}
.status-top-art-preview-title{font-weight:800;margin-bottom:8px;color:#f6d08a}
.status-top-art-preview{
  position:relative;
  min-height:112px;
  border-radius:12px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,.08);
  background:linear-gradient(180deg,#451114,#0d1a2b 72%);
}
.status-top-art-preview.mobile{min-height:78px;background:linear-gradient(180deg,#182433,#0f1624 72%)}
.status-top-art-preview .mock-title,
.status-top-art-preview .mock-stats,
.status-top-art-preview .mock-mini-label,
.status-top-art-preview .mock-mini-stats{position:relative;z-index:2}
.status-top-art-preview .mock-title{padding:56px 12px 4px;font-size:15px;font-weight:800}
.status-top-art-preview .mock-stats{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px;padding:0 12px 12px;font-size:12px;color:#fff}
.status-top-art-preview.mobile .mock-mini-label{padding:28px 8px 2px;font-size:11px;font-weight:800}
.status-top-art-preview.mobile .mock-mini-stats{display:flex;gap:7px;padding:0 8px 8px;font-size:9px}
.status-top-art-preview .status-top-art-layer,
.hq-quickbar .status-top-art-layer,
.mini-quickbar .status-top-art-layer{
  position:absolute;
  background-repeat:no-repeat;
  pointer-events:none;
  z-index:1;
}
.status-top-art-preview .status-top-art-layer{left:10px;right:10px;top:8px;height:44px;opacity:.98;filter:drop-shadow(0 3px 8px rgba(0,0,0,.28));}
.status-top-art-preview.mobile .status-top-art-layer{left:6px;right:6px;top:4px;height:22px}
.hq-quickbar{position:relative;overflow:hidden}
.hq-quickbar.has-status-top-art{padding-top:54px!important}
.hq-quickbar .status-top-art-layer{left:8px;right:8px;top:6px;height:42px;opacity:.98;filter:drop-shadow(0 3px 7px rgba(0,0,0,.32));}
.mini-quickbar{position:relative;overflow:hidden}
.mini-quickbar.has-status-top-art{padding-top:11px!important}
.mini-quickbar .status-top-art-layer{left:3px;right:3px;top:2px;height:10px;opacity:.95;filter:drop-shadow(0 2px 5px rgba(0,0,0,.28));}
.status-top-art-controls{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:12px;margin-top:12px}
.status-top-art-controls .other-image-adjust-panel{height:100%}
.status-top-art-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}
.status-top-art-help{font-size:12px;opacity:.8;margin-top:6px}

.hq-card-scene .scene-energy,
.hq-card-scene .scene-particles{will-change:transform,opacity,filter}

.hq-card-scene.fx-beam .scene-energy{animation:v205BeamColumn 1.35s cubic-bezier(.12,.76,.2,1) forwards!important;transform-origin:50% 100%}
.hq-card-scene.fx-flare .scene-energy{animation:v205FlareBurst 1.1s ease-out forwards!important}
.hq-card-scene.fx-lightning .scene-energy{animation:v205LightningFlash 1.05s steps(2,end) forwards!important}
.hq-card-scene.fx-fire .scene-energy{animation:v205FireLift 1.45s ease-out forwards!important;transform-origin:50% 100%}
.hq-card-scene.fx-ice .scene-energy{animation:v205FreezeSpread 1.45s ease-out forwards!important;transform-origin:50% 50%}
.hq-card-scene.fx-smoke .scene-energy{animation:v205SmokeDrift 1.7s ease-out forwards!important;filter:blur(5px)}
.hq-card-scene.fx-petals .scene-energy{animation:v205PetalBreeze 1.55s ease-in-out forwards!important}
.hq-card-scene.fx-shadow .scene-energy{animation:v205ShadowVortex 1.55s cubic-bezier(.3,.05,.2,1) forwards!important}
.hq-card-scene.fx-holy .scene-energy{animation:v205HolyDescend 1.45s ease-out forwards!important;transform-origin:50% 0}
.hq-card-scene.fx-shock .scene-energy{animation:v205ShockImpact 1.05s cubic-bezier(.16,.7,.2,1) forwards!important}
.hq-card-scene.fx-runes .scene-energy{animation:v205RuneSpin 1.65s linear forwards!important}
.hq-card-scene.fx-blood .scene-energy{animation:v205BloodPulse 1.45s ease-out forwards!important}
.hq-card-scene.fx-warcry .scene-energy{animation:v205WarcryWave 1.25s ease-out forwards!important}
.hq-card-scene.fx-dragon .scene-energy{animation:v205DragonCoil 1.7s cubic-bezier(.18,.72,.22,1) forwards!important}
.hq-card-scene.fx-ascend .scene-energy{animation:v205AscendLift 1.65s ease-out forwards!important;transform-origin:50% 100%}
.hq-card-scene.fx-requiem .scene-energy{animation:v205RequiemCollapse 1.75s cubic-bezier(.34,.02,.18,1) forwards!important}

.hq-card-scene.fx-lightning{animation:v205LightningStage 1.05s steps(2,end) forwards!important}
.hq-card-scene.fx-shock{animation:v205ShockStage 1.05s ease-out forwards!important}
.hq-card-scene.fx-warcry{animation:v205WarcryStage 1.25s ease-out forwards!important}
.hq-card-scene.fx-ice{box-shadow:inset 0 0 34px rgba(170,239,255,.8)!important}
.hq-card-scene.fx-fire{box-shadow:inset 0 -28px 45px rgba(255,55,0,.55)!important}
.hq-card-scene.fx-holy{box-shadow:inset 0 0 42px rgba(255,232,144,.5)!important}
.hq-card-scene.fx-shadow,.hq-card-scene.fx-requiem{box-shadow:inset 0 0 48px rgba(0,0,0,.92)!important}

@keyframes v205BeamColumn{0%{opacity:0;transform:scaleX(.18) scaleY(.05);filter:brightness(3)}28%{opacity:1;transform:scaleX(.42) scaleY(1.18);filter:brightness(2.2)}70%{opacity:.95;transform:scaleX(.72) scaleY(1)}100%{opacity:0;transform:scaleX(1.05) scaleY(.96);filter:brightness(1)}}
@keyframes v205FlareBurst{0%{opacity:0;transform:scale(.08) rotate(-25deg);filter:brightness(4)}38%{opacity:1;transform:scale(1.2) rotate(8deg);filter:brightness(2.4)}100%{opacity:0;transform:scale(2.2) rotate(22deg);filter:brightness(1)}}
@keyframes v205LightningFlash{0%,16%,36%{opacity:0;transform:skewX(-12deg) scaleY(.25)}8%,25%,48%{opacity:1;transform:skewX(8deg) scaleY(1.25);filter:brightness(3.5)}100%{opacity:0;transform:skewX(0) scaleY(1)}}
@keyframes v205FireLift{0%{opacity:.15;transform:translateY(45%) scale(.65);filter:saturate(1.2)}55%{opacity:1;transform:translateY(-4%) scale(1.15);filter:saturate(2.2) brightness(1.5)}100%{opacity:0;transform:translateY(-45%) scale(.9);filter:saturate(1)}}
@keyframes v205FreezeSpread{0%{opacity:0;transform:scale(.06) rotate(12deg);filter:blur(6px) brightness(2.5)}48%{opacity:1;transform:scale(1.05) rotate(0);filter:blur(0) brightness(1.7)}100%{opacity:.2;transform:scale(1.28);filter:blur(1px) brightness(1)}}
@keyframes v205SmokeDrift{0%{opacity:0;transform:translate(-18%,28%) scale(.55)}50%{opacity:.95;transform:translate(4%,-2%) scale(1.25)}100%{opacity:0;transform:translate(22%,-24%) scale(1.55)}}
@keyframes v205PetalBreeze{0%{opacity:0;transform:translate(18%,-25%) rotate(-10deg) scale(.7)}48%{opacity:1;transform:translate(-5%,5%) rotate(8deg) scale(1.05)}100%{opacity:0;transform:translate(-24%,34%) rotate(24deg) scale(1.18)}}
@keyframes v205ShadowVortex{0%{opacity:0;transform:scale(1.6) rotate(-120deg);filter:brightness(2)}60%{opacity:1;transform:scale(.78) rotate(35deg);filter:brightness(.7)}100%{opacity:0;transform:scale(.08) rotate(180deg);filter:brightness(.25)}}
@keyframes v205HolyDescend{0%{opacity:0;transform:translateY(-55%) scaleX(.25);filter:brightness(3)}42%{opacity:1;transform:translateY(0) scaleX(.85);filter:brightness(2)}100%{opacity:0;transform:translateY(18%) scaleX(1.15);filter:brightness(1)}}
@keyframes v205ShockImpact{0%{opacity:0;transform:scale(.05)}28%{opacity:1;transform:scale(.35);filter:brightness(3)}100%{opacity:0;transform:scale(2.4);filter:brightness(1)}}
@keyframes v205RuneSpin{0%{opacity:0;transform:scale(.35) rotate(-160deg);filter:brightness(2.2)}45%{opacity:1;transform:scale(1.05) rotate(8deg)}100%{opacity:0;transform:scale(1.18) rotate(150deg);filter:brightness(.8)}}
@keyframes v205BloodPulse{0%{opacity:0;transform:scale(.45);filter:brightness(2.4)}30%{opacity:1;transform:scale(1.18)}52%{transform:scale(.92)}72%{transform:scale(1.08)}100%{opacity:0;transform:scale(1.3);filter:brightness(.7)}}
@keyframes v205WarcryWave{0%{opacity:0;transform:scaleX(.05) scaleY(.55)}36%{opacity:1;transform:scaleX(1.3) scaleY(1.05);filter:brightness(2)}100%{opacity:0;transform:scaleX(2.5) scaleY(.7);filter:brightness(1)}}
@keyframes v205DragonCoil{0%{opacity:0;transform:translate(-28%,25%) scale(.35) rotate(-35deg)}52%{opacity:1;transform:translate(5%,-5%) scale(1.12) rotate(8deg);filter:brightness(1.8)}100%{opacity:0;transform:translate(30%,-28%) scale(1.38) rotate(28deg)}}
@keyframes v205AscendLift{0%{opacity:0;transform:translateY(50%) scale(.55);filter:brightness(2.5)}48%{opacity:1;transform:translateY(-5%) scale(1.05)}100%{opacity:0;transform:translateY(-62%) scale(.82);filter:brightness(1)}}
@keyframes v205RequiemCollapse{0%{opacity:0;transform:scale(1.7) rotate(-18deg);filter:blur(5px) brightness(2)}55%{opacity:1;transform:scale(.72) rotate(8deg);filter:blur(0) brightness(.85)}100%{opacity:0;transform:scale(.02) rotate(42deg);filter:blur(8px) brightness(.2)}}
@keyframes v205LightningStage{0%,18%,38%{filter:brightness(.65)}8%,28%,48%{filter:brightness(2.6)}100%{filter:brightness(1)}}
@keyframes v205ShockStage{0%,100%{transform:translate(0)}22%{transform:translate(-6px,2px)}32%{transform:translate(7px,-2px)}44%{transform:translate(-4px,1px)}58%{transform:translate(3px,-1px)}}
@keyframes v205WarcryStage{0%,100%{transform:scale(1)}28%{transform:scale(1.035)}38%{transform:scale(.985)}50%{transform:scale(1.02)}72%{transform:scale(1)}}

@media (prefers-reduced-motion:reduce){
  .hq-card-scene,.hq-card-scene *{animation-duration:.001ms!important;animation-iteration-count:1!important}
}

.left-card-effect-body.card-effect-idle-art-host,
.card-effect-idle-preview{
  position:relative!important;
  overflow:hidden!important;
  isolation:isolate;
}
.left-card-effect-body>.card-effect-idle-art-layer,
.card-effect-idle-preview>.card-effect-idle-art-layer{
  position:absolute!important;
  inset:0!important;
  z-index:50!important;
  display:block;
  overflow:hidden;
  pointer-events:none;
  background:transparent;
}
.left-card-effect-body>.card-effect-idle-art-layer[hidden],
.card-effect-idle-preview>.card-effect-idle-art-layer[hidden]{display:none!important;}
.card-effect-idle-art-image{
  position:absolute!important;
  display:block!important;
  max-width:none!important;
  max-height:none!important;
  min-width:0!important;
  min-height:0!important;
  object-fit:fill!important;
  object-position:center!important;
  transform:translate(-50%,-50%)!important;
  transform-origin:center center!important;
  user-select:none!important;
  -webkit-user-drag:none!important;
}
.left-card-effect-body.show-card-effect-idle-art>.card-effect-empty{visibility:hidden!important;}

.card-effect-idle-art-settings{
  padding:14px 16px 16px;
  border-top:1px solid #4a3926;
  background:linear-gradient(180deg,#0d141d,#080c12);
}
.card-effect-idle-settings-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:12px;
  margin-bottom:11px;
}
.card-effect-idle-settings-head b{color:#f3d39d;font-size:14px;}
.card-effect-idle-settings-head span{max-width:360px;color:#9eacba;font-size:10px;line-height:1.4;text-align:right;}
.card-effect-idle-preview-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}
.card-effect-idle-preview-box{
  min-width:0;
  padding:9px;
  border:1px solid #33485f;
  background:#09121d;
}
.card-effect-idle-preview-title{margin-bottom:7px;color:#d9e8f8;font-size:10px;font-weight:900;}
.card-effect-idle-preview{
  height:126px;
  border:1px solid #314e68;
  background:radial-gradient(circle at 50% 42%,#162a3c,#070c11 72%);
  box-shadow:inset 0 0 18px #000;
  cursor:copy;
}
.card-effect-idle-preview.mobile{height:92px;}
.card-effect-idle-preview.is-dragover{outline:2px solid #efc46f;outline-offset:-3px;}
.card-effect-idle-preview-guide{
  position:absolute;
  left:50%;
  top:50%;
  z-index:2;
  width:calc(100% - 20px);
  transform:translate(-50%,-50%);
  color:#9daaba;
  font-size:9px;
  font-weight:800;
  line-height:1.45;
  text-align:center;
}
.card-effect-idle-preview.has-card-effect-idle-art .card-effect-idle-preview-guide{display:none;}
.card-effect-idle-status{
  margin-top:9px;
  padding:8px 10px;
  border:1px solid #384758;
  background:#080e15;
  color:#a9b5c2;
  font-size:10px;
  font-weight:800;
}
.card-effect-idle-status.registered{border-color:#3f7958;background:#0b1912;color:#a9e7bd;}
.card-effect-idle-controls{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  margin-top:10px;
}
.card-effect-idle-adjust-panel{
  display:grid;
  gap:7px;
  min-width:0;
  padding:10px;
  border:1px solid #35485b;
  background:#0b141e;
}
.card-effect-idle-adjust-panel>b{color:#fff0ca;font-size:11px;}
.card-effect-idle-adjust-panel label{
  display:grid;
  grid-template-columns:66px minmax(0,1fr) 42px;
  align-items:center;
  gap:6px;
  min-width:0;
  color:#cbd9e6;
  font-size:9px;
  font-weight:800;
}
.card-effect-idle-adjust-panel label.is-disabled{opacity:.43;}
.card-effect-idle-adjust-panel input[type="range"]{min-width:0;width:100%;}
.card-effect-idle-adjust-panel output{color:#9ed0ff;text-align:right;font-size:9px;font-weight:900;}
.card-effect-idle-adjust-panel .card-effect-idle-link-toggle{
  grid-template-columns:auto 1fr;
  grid-column:1/-1;
  color:#f0d5a3;
}
.card-effect-idle-actions{
  display:flex;
  flex-wrap:wrap;
  gap:7px;
  margin-top:11px;
}
.card-effect-idle-help{margin-top:8px;color:#8f9dad;font-size:9px;line-height:1.5;}

#statusTopArtSection,
.hq-quickbar>.status-top-art-layer,
.mini-quickbar>.status-top-art-layer{display:none!important;}
.hq-quickbar.has-status-top-art,
.mini-quickbar.has-status-top-art{padding-top:initial!important;}

@media(max-width:700px){
  .card-effect-idle-settings-head{display:grid;align-items:start;}
  .card-effect-idle-settings-head span{text-align:left;}
  .card-effect-idle-preview-grid,
  .card-effect-idle-controls{grid-template-columns:1fr;}
  .card-effect-idle-preview{height:110px;}
  .card-effect-idle-preview.mobile{height:86px;}
}

.card-effect-idle-status.server-synced{border-color:#4f9c68!important;box-shadow:inset 0 0 0 1px rgba(79,156,104,.18);}
.card-effect-idle-actions .btn:disabled{opacity:.55;cursor:wait;}

:root{
  --collection-card-width:175px !important;
  --collection-card-height:306.25px !important;
  --collection-card-title-height:48px !important;
  --collection-card-art-height:174.25px !important;
  --collection-card-stats-height:34px !important;
  --collection-card-desc-height:50px !important;
}

.collection-card-heading .collection-card-name,
.collection-card-title b,
.collection-card-title .collection-card-name{
  max-width:100% !important;
  width:100% !important;
  font-size:13px !important;
  line-height:1.18 !important;
  white-space:normal !important;
  overflow:visible !important;
  text-overflow:unset !important;
  display:block !important;
}
.collection-card-title{
  min-height:var(--collection-card-title-height) !important;
  align-items:center !important;
}
.collection-card-heading{
  width:100% !important;
}

.collection-card-heading small{
  display:none !important;
}
.collection-card-title>em{
  font-size:11px !important;
}

@media(min-width:851px){
  .deck-builder-list,.deck-builder-list.selected,.card-shop-grid{
    grid-template-columns:repeat(auto-fill,var(--collection-card-width)) !important;
    justify-content:start !important;
  }
}

@media(max-width:850px){
  :root{
    --collection-card-width:150px !important;
    --collection-card-height:262.5px !important;
    --collection-card-title-height:42px !important;
    --collection-card-art-height:148px !important;
    --collection-card-stats-height:30px !important;
    --collection-card-desc-height:42.5px !important;
  }
  .deck-builder-list,.deck-builder-list.selected,.card-shop-grid{
    grid-template-columns:repeat(auto-fill,var(--collection-card-width)) !important;
    justify-content:start !important;
  }
}

@media(max-width:560px){
  :root{
    --collection-card-width:144px !important;
    --collection-card-height:252px !important;
    --collection-card-title-height:40px !important;
    --collection-card-art-height:142px !important;
    --collection-card-stats-height:28px !important;
    --collection-card-desc-height:42px !important;
  }
  .collection-card-heading small{display:none !important;}
}

.deck-builder-visual-card,.card-shop-grid .shop-card{
  width:var(--collection-card-width) !important;
  min-width:var(--collection-card-width) !important;
  max-width:var(--collection-card-width) !important;
  height:var(--collection-card-height) !important;
  min-height:var(--collection-card-height) !important;
  max-height:var(--collection-card-height) !important;
  grid-template-rows:var(--collection-card-title-height) var(--collection-card-art-height) var(--collection-card-stats-height) var(--collection-card-desc-height) !important;
}
.deck-builder-visual-card>.collection-card-title,.card-shop-grid .shop-card>.collection-card-title{
  height:var(--collection-card-title-height) !important;
  min-height:var(--collection-card-title-height) !important;
}
.deck-builder-visual-card>.collection-card-art,.card-shop-grid .shop-card>.collection-card-art{
  height:var(--collection-card-art-height) !important;
  min-height:var(--collection-card-art-height) !important;
  max-height:var(--collection-card-art-height) !important;
}
.deck-builder-visual-card>.collection-five-stats,.card-shop-grid .shop-card>.collection-five-stats{
  height:var(--collection-card-stats-height) !important;
  min-height:var(--collection-card-stats-height) !important;
  max-height:var(--collection-card-stats-height) !important;
  font-size:11px !important;
}
.deck-builder-visual-card>.collection-extra,.card-shop-grid .shop-card>.collection-extra{
  height:var(--collection-card-desc-height) !important;
  min-height:var(--collection-card-desc-height) !important;
  max-height:var(--collection-card-desc-height) !important;
  font-size:10.5px !important;
}

@media(min-width:851px){

  
  .deck-builder-head{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:10px!important;
    flex-wrap:wrap!important;
  }
  .deck-builder-head-title{
    display:flex!important;
    align-items:baseline!important;
    flex-wrap:wrap!important;
    gap:6px 14px!important;
    min-width:0!important;
  }
  .deck-builder-head-title h2{margin:0!important;font-size:16px!important;white-space:nowrap!important;}
  .deck-builder-head-title .deck-builder-summary{
    padding:0!important;
    border:0!important;
    background:none!important;
    color:#cdbb9e!important;
    font-size:11px!important;
    text-align:left!important;
    white-space:normal!important;
  }
  .deck-builder-head-title .deck-builder-summary b{font-size:12px!important;}
  .deck-builder-head-actions{
    display:flex!important;
    align-items:center!important;
    gap:6px!important;
    flex-wrap:wrap!important;
  }
  .btn.small{
    font-size:10px!important;
    padding:4px 9px!important;
    min-height:0!important;
    border-radius:6px!important;
  }

  
  .deck-builder-toolbar{
    display:flex!important;
    flex-wrap:wrap!important;
    align-items:end!important;
    gap:8px!important;
  }
  .deck-builder-toolbar>label{flex:0 0 auto!important;min-width:0!important;}
  #deckBuilderName{width:110px!important;min-width:0!important;flex:0 0 110px!important;}
  .deck-builder-search-cluster{
    display:flex!important;
    align-items:end!important;
    gap:8px!important;
    flex:1 1 320px!important;
    flex-wrap:wrap!important;
  }
  #deckBuilderSearch{width:110px!important;min-width:0!important;flex:0 0 110px!important;}
  .deck-auto-ratio-inline{
    display:flex!important;
    align-items:end!important;
    gap:6px!important;
    flex-wrap:wrap!important;
    padding:4px 8px!important;
    border:1px solid #40301f!important;
    background:#0d1115!important;
    border-radius:4px!important;
  }
  .deck-auto-ratio-inline label{
    display:grid!important;
    gap:2px!important;
    font-size:8px!important;
    color:#cdbb9e!important;
  }
  .deck-auto-ratio-inline input[type=number]{
    width:36px!important;
    min-height:24px!important;
    padding:2px 4px!important;
    background:#111925!important;
    color:#e8edf5!important;
    border:1px solid #45556e!important;
  }
  .deck-auto-ratio-inline .btn{white-space:nowrap!important;align-self:end!important;}

  
  #deckBuilderModal{
    --collection-card-width:122.5px;
    --collection-card-height:214.375px;
    --collection-card-title-height:33.6px;
    --collection-card-art-height:121.975px;
    --collection-card-stats-height:23.8px;
    --collection-card-desc-height:35px;
  }
  .deck-builder-box{width:min(1230px,96vw)!important;}
  .deck-builder-main{
    grid-template-columns:662px 528px!important;
    gap:8px!important;
  }
  .deck-builder-list{
    grid-template-columns:repeat(5,var(--collection-card-width))!important;
    gap:6px!important;
    justify-content:start!important;
  }
  .deck-builder-list.selected{
    grid-template-columns:repeat(4,var(--collection-card-width))!important;
    gap:6px!important;
  }
}

.v215-setup-labels .v215-desktop-setup-label{display:none;}
.v215-setup-labels .v215-mobile-setup-title{display:inline;}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    
    --v215-card-h:158.4px;
    --v215-card-w:113.142857px;
    --v215-field-gap:6px;
    --v215-hand-section-h:355px;
    --v215-formation-w:708.857142px;
    --v215-five-card-w:589.714285px;
    --v215-four-card-w:470.571428px;
    --v215-three-card-w:351.428571px;
    --v215-two-card-w:232.285714px;
    --v215-lane-h:162px;
    --hand-card-width:var(--v215-card-w);
    --hand-card-height:var(--v215-card-h);
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    grid-template-columns:352px minmax(720px,1fr)!important;
    column-gap:0!important;
    gap:0!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-menu-dock{
    padding:0 5px 5px!important;
    border:0!important;
    border-bottom:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-menu-dock>.ornate-title{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .reference-topbar{
    margin:0!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:5px!important;
    width:100%!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions #cardShopBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions #boosterPackBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions #cardManagerBtn{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:100%!important;
    min-width:0!important;
    height:36px!important;
    min-height:36px!important;
    max-height:36px!important;
    padding:4px 5px!important;
    font-size:11px!important;
    font-weight:900!important;
    line-height:1.1!important;
    white-space:nowrap!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions #cardManagerBtn{
    border-color:#7c5cff!important;
    background:linear-gradient(180deg,#4932a8,#281568)!important;
    color:#f5efff!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-auth-logged-in{
    grid-template-columns:minmax(0,1fr) minmax(72px,auto)!important;
  }

  
  html:not(.is-card-admin) body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions #cardManagerBtn,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions #cardManagerBtn[hidden]{
    display:none!important;
  }
  html:not(.is-card-admin) body.unified-left-layout:not(.ui-mode-mobile-preview) #leftMenuMount .top-card-actions{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .v215-setup-labels{
    display:grid!important;
    grid-template-columns:82px minmax(0,1fr) 76px!important;
    align-items:center!important;
    gap:5px!important;
    height:34px!important;
    min-height:34px!important;
    padding:0 7px!important;
    margin:0 -7px 6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .v215-setup-labels .v215-mobile-setup-title{
    display:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .v215-setup-labels .v215-desktop-setup-label{
    display:block!important;
    min-width:0!important;
    color:#f3d39d!important;
    font-size:15px!important;
    font-weight:950!important;
    line-height:1!important;
    text-align:center!important;
    letter-spacing:-.04em!important;
    white-space:nowrap!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline{
    grid-template-columns:82px minmax(0,1fr) 76px!important;
    gap:5px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline select,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .formation-inline .btn{
    height:35px!important;
    min-height:35px!important;
    max-height:35px!important;
    padding:3px 5px!important;
    font-size:12px!important;
    font-weight:900!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:238.45px!important;
    min-height:238.45px!important;
    max-height:238.45px!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:var(--v215-hand-section-h)!important;
    min-height:var(--v215-hand-section-h)!important;
    max-height:var(--v215-hand-section-h)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox{
    padding:5px!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    display:grid!important;
    grid-template-columns:repeat(3,var(--v215-card-w))!important;
    grid-template-rows:repeat(2,var(--v215-card-h))!important;
    grid-auto-rows:var(--v215-card-h)!important;
    width:100%!important;
    height:316.8px!important;
    min-height:316.8px!important;
    max-height:316.8px!important;
    gap:0!important;
    padding:0!important;
    margin:0!important;
    justify-content:start!important;
    align-content:start!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v215-card-w)!important;
    min-width:var(--v215-card-w)!important;
    max-width:var(--v215-card-w)!important;
    height:var(--v215-card-h)!important;
    min-height:var(--v215-card-h)!important;
    max-height:var(--v215-card-h)!important;
    margin:0!important;
    aspect-ratio:2.5 / 3.5!important;
    border-radius:0!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v215-card-w)!important;
    min-width:var(--v215-card-w)!important;
    max-width:var(--v215-card-w)!important;
    height:var(--v215-card-h)!important;
    min-height:var(--v215-card-h)!important;
    max-height:var(--v215-card-h)!important;
    margin:0!important;
    padding:0!important;
    aspect-ratio:2.5 / 3.5!important;
    border-radius:0!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    width:100%!important;
    height:100%!important;
    min-width:0!important;
    min-height:0!important;
    max-width:none!important;
    max-height:none!important;
    border-radius:0!important;
    overflow:hidden!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    width:var(--v215-formation-w)!important;
    min-width:var(--v215-formation-w)!important;
    max-width:var(--v215-formation-w)!important;
    height:var(--v215-lane-h)!important;
    min-height:var(--v215-lane-h)!important;
    max-height:var(--v215-lane-h)!important;
    flex:0 0 var(--v215-lane-h)!important;
    padding:1px 0 0!important;
    margin-left:0!important;
    margin-right:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    height:var(--v215-card-h)!important;
    min-height:var(--v215-card-h)!important;
    max-height:var(--v215-card-h)!important;
    padding:0!important;
    gap:var(--v215-field-gap)!important;
    align-items:stretch!important;
    align-content:stretch!important;
    justify-content:center!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    display:grid!important;
    grid-template-columns:repeat(5,var(--v215-card-w))!important;
    width:var(--v215-five-card-w)!important;
    min-width:var(--v215-five-card-w)!important;
    max-width:var(--v215-five-card-w)!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    display:grid!important;
    grid-template-columns:repeat(4,var(--v215-card-w))!important;
    width:var(--v215-four-card-w)!important;
    min-width:var(--v215-four-card-w)!important;
    max-width:var(--v215-four-card-w)!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    display:grid!important;
    grid-template-columns:repeat(3,var(--v215-card-w))!important;
    width:var(--v215-three-card-w)!important;
    min-width:var(--v215-three-card-w)!important;
    max-width:var(--v215-three-card-w)!important;
    margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    display:grid!important;
    grid-template-columns:repeat(2,var(--v215-card-w))!important;
    width:var(--v215-two-card-w)!important;
    min-width:var(--v215-two-card-w)!important;
    max-width:var(--v215-two-card-w)!important;
    margin:0 auto!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    margin-left:0!important;
    margin-right:auto!important;
    padding-left:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.river{
    width:var(--v215-formation-w)!important;
    min-width:var(--v215-formation-w)!important;
    max-width:var(--v215-formation-w)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    align-items:flex-start!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    grid-template-columns:352px minmax(720px,1fr)!important;
  }
  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    height:226.1px!important;
    min-height:226.1px!important;
    max-height:226.1px!important;
  }
}

.hq-card-scene .scene-label,
.hq-card-scene .scene-effect-caption,
.left-card-effect-stage-badge{display:none!important}

.left-card-effect-stage .hq-card-scene.left-effect-preview-scene:not(.fx-none) img{
  inset:0!important;
  margin:auto!important;
  width:auto!important;
  height:auto!important;
  min-width:0!important;
  min-height:0!important;
  max-width:100%!important;
  max-height:100%!important;
  object-fit:contain!important;
  object-position:center!important;
  transform-origin:center!important;
  animation:v216NaturalPreview 1.35s ease-out forwards!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene.holding img{
  animation:none!important;
  transform:translate(0,0) scale(1)!important;
}

.left-card-effect-stage .hq-card-scene.left-effect-preview-scene.fx-none img{
  inset:0!important;
  margin:auto!important;
  width:auto!important;
  height:auto!important;
  min-width:0!important;
  min-height:0!important;
  max-width:100%!important;
  max-height:100%!important;
  object-fit:contain!important;
  object-position:center!important;
  animation:none!important;
  transform:translate(0,0) scale(1)!important;
  filter:none!important;
}
@keyframes v216NaturalPreview{
  0%{opacity:0;transform:translateY(8px) scale(.98);filter:brightness(.82)}
  34%{opacity:1;transform:translateY(0) scale(1);filter:brightness(1.08)}
  100%{opacity:1;transform:translateY(0) scale(1);filter:none}
}

.hq-card-scene .scene-particles{filter:none!important;opacity:.62!important}
.hq-card-scene .scene-particles i:nth-child(n+5){display:none!important}

.hq-card-scene.fx-none{background:#070b10!important;animation:none!important;filter:none!important}
.hq-card-scene.fx-none img{
  animation:none!important;
  opacity:1!important;
  transform:scale(var(--scene-scale,1))!important;
  filter:none!important;
}
.hq-card-scene.fx-none .scene-shade,
.hq-card-scene.fx-none .scene-energy,
.hq-card-scene.fx-none .scene-particles,
.hq-card-scene.fx-none::before,
.hq-card-scene.fx-none::after{display:none!important;content:none!important}

.hq-card-scene.summon::before,
.hq-card-scene.summon::after,
.hq-card-scene.tactic::before,
.hq-card-scene.tactic::after,
.hq-card-scene.death::before,
.hq-card-scene.death::after{display:none!important;content:none!important}

.hq-card-scene.fx-ice::after,
.hq-card-scene.fx-petals::before,
.hq-card-scene.fx-holy::after,
.hq-card-scene.fx-runes::before,
.hq-card-scene.fx-runes::after,
.hq-card-scene.fx-warcry::before,
.hq-card-scene.fx-dragon::before,
.hq-card-scene.fx-requiem::before{content:none!important;display:none!important}

.hq-card-scene.fx-fire .scene-particles{display:none!important}
.hq-card-scene.fx-fire::before{
  content:''!important;
  display:block!important;
  position:absolute!important;
  z-index:4!important;
  left:-8%!important;
  right:-8%!important;
  top:auto!important;
  bottom:-32%!important;
  height:82%!important;
  background:
    radial-gradient(ellipse at 10% 100%,#fff0a3 0 4%,#ff9b24 5% 11%,#d9340d 12% 22%,transparent 23%),
    radial-gradient(ellipse at 30% 100%,#fff0a3 0 5%,#ff8a1d 6% 13%,#c9230b 14% 25%,transparent 26%),
    radial-gradient(ellipse at 52% 100%,#fff4b3 0 5%,#ff9b24 6% 14%,#e12c0c 15% 26%,transparent 27%),
    radial-gradient(ellipse at 74% 100%,#fff0a3 0 4%,#ff7e18 5% 12%,#c62009 13% 24%,transparent 25%),
    radial-gradient(ellipse at 92% 100%,#fff0a3 0 4%,#ff9b24 5% 11%,#d9340d 12% 22%,transparent 23%);
  filter:blur(2px) saturate(1.35)!important;
  mix-blend-mode:screen!important;
  transform-origin:50% 100%!important;
  animation:v216FireRise 1.55s cubic-bezier(.2,.72,.2,1) forwards!important;
}
.hq-card-scene.fx-fire::after{
  content:''!important;
  display:block!important;
  position:absolute!important;
  z-index:3!important;
  inset:0!important;
  background:linear-gradient(0deg,#d92b008f 0%,#ff6b002e 44%,transparent 72%)!important;
  animation:v216FireGlow 1.55s ease-out forwards!important;
}
@keyframes v216FireRise{
  0%{opacity:0;transform:translateY(36%) scaleY(.45)}
  28%{opacity:.94}
  72%{opacity:.82;transform:translateY(-12%) scaleY(1.18)}
  100%{opacity:0;transform:translateY(-34%) scaleY(1.4)}
}
@keyframes v216FireGlow{0%{opacity:0}28%{opacity:.82}78%{opacity:.48}100%{opacity:0}}

.hq-card-scene.fx-warcry{animation:v216WarcryPush 1.35s ease-out forwards!important}
.hq-card-scene.fx-warcry::before{
  content:''!important;
  display:block!important;
  position:absolute!important;
  z-index:5!important;
  inset:42% -18% -18%!important;
  background:
    linear-gradient(168deg,transparent 0 22%,#e8c17b66 23% 26%,transparent 27% 42%,#b77b3d55 43% 47%,transparent 48%),
    linear-gradient(12deg,transparent 0 28%,#f2d29a55 29% 32%,transparent 33% 58%,#98602d55 59% 63%,transparent 64%);
  filter:blur(2px)!important;
  transform-origin:50% 100%!important;
  animation:v216WarDust 1.3s ease-out forwards!important;
}
.hq-card-scene.fx-warcry::after{
  content:''!important;
  display:block!important;
  position:absolute!important;
  z-index:4!important;
  inset:0!important;
  background:linear-gradient(90deg,#100a0699,transparent 25% 75%,#100a0699),linear-gradient(0deg,#a3642638,transparent 58%)!important;
  animation:v216WarVignette 1.35s ease-out forwards!important;
}
.hq-card-scene.fx-warcry .scene-particles i{
  display:block!important;
  top:auto!important;
  bottom:5%!important;
  width:15px!important;
  height:5px!important;
  border:0!important;
  border-radius:45%!important;
  background:#d4ad72!important;
  box-shadow:none!important;
  animation:v216DustDrift 1.25s ease-out forwards!important;
}
.hq-card-scene.fx-warcry .scene-particles i:nth-child(1){left:12%!important}
.hq-card-scene.fx-warcry .scene-particles i:nth-child(2){left:36%!important;animation-delay:.08s!important}
.hq-card-scene.fx-warcry .scene-particles i:nth-child(3){left:62%!important;animation-delay:.16s!important}
.hq-card-scene.fx-warcry .scene-particles i:nth-child(4){left:84%!important;animation-delay:.23s!important}
@keyframes v216WarcryPush{0%{transform:translateX(-2%);filter:brightness(.72)}28%{transform:translateX(1.2%);filter:brightness(1.15)}100%{transform:none;filter:none}}
@keyframes v216WarDust{0%{opacity:0;transform:translateY(28%) scale(.75)}35%{opacity:.8}100%{opacity:0;transform:translateY(-38%) scale(1.35)}}
@keyframes v216WarVignette{0%{opacity:0}30%{opacity:.8}100%{opacity:0}}
@keyframes v216DustDrift{0%{opacity:0;transform:translate(0,20px) scale(.4)}30%{opacity:.72}100%{opacity:0;transform:translate(26px,-115px) scale(1.5)}}

.hq-card-scene.fx-petals .scene-energy{background:linear-gradient(180deg,#e7c98a1f,transparent 40%,#8e5a2629)!important}
.hq-card-scene.fx-petals .scene-particles{display:block!important;opacity:.85!important}
.hq-card-scene.fx-petals .scene-particles i{
  display:block!important;
  top:-18%!important;
  width:10px!important;
  height:17px!important;
  border:0!important;
  border-radius:80% 18% 75% 22%!important;
  background:linear-gradient(145deg,#e7b65b,#9b4f1d 72%)!important;
  box-shadow:0 1px 2px #1d0d0680!important;
  animation:v216LeafFall 1.85s cubic-bezier(.22,.58,.35,1) forwards!important;
}
.hq-card-scene.fx-petals .scene-particles i:nth-child(1){left:12%!important;--leaf-x:42px;--leaf-r:210deg}
.hq-card-scene.fx-petals .scene-particles i:nth-child(2){left:35%!important;--leaf-x:-28px;--leaf-r:-170deg;animation-delay:.18s!important}
.hq-card-scene.fx-petals .scene-particles i:nth-child(3){left:62%!important;--leaf-x:34px;--leaf-r:190deg;animation-delay:.08s!important}
.hq-card-scene.fx-petals .scene-particles i:nth-child(4){left:84%!important;--leaf-x:-38px;--leaf-r:-225deg;animation-delay:.28s!important}
@keyframes v216LeafFall{
  0%{opacity:0;transform:translate(0,-12px) rotate(0) scale(.7)}
  18%{opacity:.95}
  62%{opacity:.9;transform:translate(calc(var(--leaf-x) * .5),58vh) rotate(calc(var(--leaf-r) * .55)) scale(1)}
  100%{opacity:0;transform:translate(var(--leaf-x),118vh) rotate(var(--leaf-r)) scale(.92)}
}

.hq-card-scene.fx-shock::before,
.hq-card-scene.fx-shock::after{
  content:''!important;
  display:block!important;
  position:absolute!important;
  z-index:5!important;
  left:50%!important;
  top:auto!important;
  bottom:13%!important;
  width:22%!important;
  height:5px!important;
  border:0!important;
  border-radius:0!important;
  background:linear-gradient(90deg,transparent,#d8f4ff,#7dcfe8,#d8f4ff,transparent)!important;
  box-shadow:0 0 13px #7fdcff!important;
  animation:v216GroundShock 1.05s ease-out forwards!important;
}
.hq-card-scene.fx-shock::after{animation-delay:.12s!important}
.hq-card-scene.fx-shock .scene-particles{display:none!important}
@keyframes v216GroundShock{0%{opacity:0;transform:translateX(-50%) scaleX(.15)}28%{opacity:.95}100%{opacity:0;transform:translateX(-50%) scaleX(5.2)}}

.hq-card-scene.fx-runes .scene-particles,
.hq-card-scene.fx-requiem::after{display:none!important;content:none!important}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    
    --v216-card-w:118.8px;
    --v216-card-h:184.8px;
    --v216-card-gap:6px;
    --v216-hand-h:369.6px;
    --v216-hand-w:356.4px;
    --v216-hand-section-h:408px;
    --v216-formation-w:742.8px;
    --v216-five-card-w:618px;
    --v216-four-card-w:493.2px;
    --v216-three-card-w:368.4px;
    --v216-two-card-w:243.6px;
    --v216-lane-h:198px;
    --hand-card-width:var(--v216-card-w);
    --hand-card-height:var(--v216-card-h);
    --tcg-card-head:31px;
    --tcg-card-stat:38px;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    grid-template-columns:382px minmax(760px,1fr)!important;
    column-gap:0!important;
    gap:0!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:var(--v216-hand-section-h)!important;
    min-height:var(--v216-hand-section-h)!important;
    max-height:var(--v216-hand-section-h)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox{padding:5px!important;overflow:hidden!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    display:grid!important;
    grid-template-columns:repeat(3,var(--v216-card-w))!important;
    grid-template-rows:repeat(2,var(--v216-card-h))!important;
    grid-auto-rows:var(--v216-card-h)!important;
    width:var(--v216-hand-w)!important;
    min-width:var(--v216-hand-w)!important;
    max-width:var(--v216-hand-w)!important;
    height:var(--v216-hand-h)!important;
    min-height:var(--v216-hand-h)!important;
    max-height:var(--v216-hand-h)!important;
    gap:0!important;
    padding:0!important;
    margin:0!important;
    justify-content:start!important;
    align-content:start!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    box-sizing:border-box!important;
    width:var(--v216-card-w)!important;
    min-width:var(--v216-card-w)!important;
    max-width:var(--v216-card-w)!important;
    height:var(--v216-card-h)!important;
    min-height:var(--v216-card-h)!important;
    max-height:var(--v216-card-h)!important;
    margin:0!important;
    padding:0!important;
    aspect-ratio:2.7 / 4.2!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    width:100%!important;height:100%!important;min-height:0!important;max-height:none!important;overflow:hidden!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-title-area,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .card-title-area{
    padding:4px 5px!important;gap:3px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-name-text,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .field-unit-name{
    font-size:14px!important;font-weight:1000!important;letter-spacing:-.04em!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-title-grade,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .field-grade{
    min-width:25px!important;height:20px!important;font-size:10px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span{
    position:relative!important;
    display:grid!important;
    grid-template-rows:12px 1fr!important;
    place-items:center!important;
    padding:2px 1px!important;
    font-size:17px!important;
    font-weight:1000!important;
    color:#fff!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell b{font-size:17px!important;line-height:1!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell::before,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span::before{
    display:block!important;font-size:9px!important;font-weight:1000!important;line-height:1!important;color:#e5c78d!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell:nth-child(1)::before,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span:nth-child(1)::before{content:'공격'}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell:nth-child(2)::before,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span:nth-child(2)::before{content:'방어'}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell:nth-child(3)::before,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span:nth-child(3)::before{content:'체력'}

  body.unified-left-layout:not(.ui-mode-mobile-preview) .general-class-hand-badge,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .soldier-class-hand-icon,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit-class-icon{
    position:absolute!important;
    left:4px!important;
    right:auto!important;
    bottom:5px!important;
    z-index:12!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:auto!important;
    min-width:0!important;
    max-width:62px!important;
    height:21px!important;
    padding:2px 6px!important;
    border:1px solid #d8b676aa!important;
    border-radius:4px!important;
    background:#080b10e8!important;
    color:#ffe6b0!important;
    font-size:10px!important;
    font-weight:1000!important;
    line-height:1!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .card-ability-label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .unit-ability-label{
    position:absolute!important;
    z-index:13!important;
    left:5px!important;
    right:5px!important;
    top:5px!important;
    display:block!important;
    padding:3px 5px!important;
    border:1px solid #9eb8d066!important;
    border-radius:3px!important;
    background:#06101bdd!important;
    color:#eff8ff!important;
    font-size:10px!important;
    font-weight:950!important;
    line-height:1.15!important;
    text-align:center!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    text-shadow:0 1px 2px #000!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    box-sizing:border-box!important;
    width:var(--v216-formation-w)!important;
    min-width:var(--v216-formation-w)!important;
    max-width:var(--v216-formation-w)!important;
    height:var(--v216-lane-h)!important;
    min-height:var(--v216-lane-h)!important;
    max-height:var(--v216-lane-h)!important;
    flex:0 0 var(--v216-lane-h)!important;
    padding:2px 0 4px!important;
    margin:0!important;
    overflow:visible!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    box-sizing:border-box!important;
    height:var(--v216-card-h)!important;
    min-height:var(--v216-card-h)!important;
    max-height:var(--v216-card-h)!important;
    padding:0!important;
    gap:var(--v216-card-gap)!important;
    align-items:stretch!important;
    align-content:stretch!important;
    justify-content:center!important;
    overflow:visible!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,var(--v216-card-w))!important;
    width:var(--v216-five-card-w)!important;min-width:var(--v216-five-card-w)!important;max-width:var(--v216-five-card-w)!important;margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,var(--v216-card-w))!important;
    width:var(--v216-four-card-w)!important;min-width:var(--v216-four-card-w)!important;max-width:var(--v216-four-card-w)!important;margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,var(--v216-card-w))!important;
    width:var(--v216-three-card-w)!important;min-width:var(--v216-three-card-w)!important;max-width:var(--v216-three-card-w)!important;margin:0 auto!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,var(--v216-card-w))!important;
    width:var(--v216-two-card-w)!important;min-width:var(--v216-two-card-w)!important;max-width:var(--v216-two-card-w)!important;margin:0 auto!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #allyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .enemy-hq-defense-lane{
    padding-bottom:6px!important;
    overflow:visible!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #enemyBaseDefenseLane .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #allyBaseDefenseLane .hq-battlefield-grid{
    overflow:visible!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.river{
    width:var(--v216-formation-w)!important;
    min-width:var(--v216-formation-w)!important;
    max-width:var(--v216-formation-w)!important;
    overflow:visible!important;
  }
}

@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{grid-template-columns:382px minmax(760px,1fr)!important}
}

@media (min-width:851px){
  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .unit-ability-label{
    top:auto!important;
    bottom:31px!important;
    left:5px!important;
    right:5px!important;
    font-size:11px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-ability-label{
    font-size:11px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .general-class-hand-badge,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .soldier-class-hand-icon,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit-class-icon{
    font-size:11px!important;
  }
}

.scene-effect-native-select{
  cursor:pointer!important;
  position:relative!important;
  z-index:2!important;
}
.scene-effect-dropdown-menu{
  position:fixed;
  display:none;
  box-sizing:border-box;
  min-width:220px;
  padding:6px;
  overflow-y:auto;
  overscroll-behavior:contain;
  border:1px solid #8eb7df;
  border-radius:9px;
  background:linear-gradient(180deg,#13243a 0%,#08111e 100%);
  box-shadow:0 18px 45px #000d,0 0 0 1px #ffffff12 inset;
  z-index:2147483000;
  scrollbar-width:thin;
  scrollbar-color:#577ca2 #08111e;
}
.scene-effect-dropdown-menu.open{display:block}
.scene-effect-dropdown-option{
  display:flex;
  align-items:center;
  width:100%;
  min-height:36px;
  margin:0 0 3px;
  padding:8px 10px;
  border:1px solid transparent;
  border-radius:6px;
  background:transparent;
  color:#eaf4ff;
  font-size:12px;
  font-weight:800;
  line-height:1.25;
  text-align:left;
  cursor:pointer;
}
.scene-effect-dropdown-option:last-child{margin-bottom:0}
.scene-effect-dropdown-option:hover,
.scene-effect-dropdown-option:focus-visible{
  border-color:#75b9ef;
  background:#1b3a59;
  outline:none;
}
.scene-effect-dropdown-option[aria-selected="true"]{
  border-color:#e7bd6b;
  background:linear-gradient(90deg,#59401d,#24364a);
  color:#fff3ce;
}
.scene-effect-dropdown-option:disabled{opacity:.42;cursor:not-allowed}
.scene-effect-dropdown-backdrop{
  position:fixed;
  inset:0;
  display:none;
  z-index:2147482999;
  background:transparent;
}
.scene-effect-dropdown-backdrop.open{display:block}
@media(max-width:760px){
  .scene-effect-dropdown-menu{
    min-width:0;
    border-radius:10px;
  }
  .scene-effect-dropdown-option{min-height:42px;font-size:13px}
}

:root{
  --v218-gold:#d8b85d;
  --v218-gold-soft:#f1d98d;
  --v218-ink:#070a0e;
  --v218-stat-h:30px;
}

#hand.hand .card.wei,.battlefield-layout .unit.wei,.faction-wei{
  --v218-main:#174f91;--v218-deep:#071d39;--v218-soft:#5f9bdd;--v218-glyph:'魏';
}
#hand.hand .card.shu,.battlefield-layout .unit.shu,.faction-shu{
  --v218-main:#216b3b;--v218-deep:#082715;--v218-soft:#6daf79;--v218-glyph:'蜀';
}
#hand.hand .card.wu,.battlefield-layout .unit.wu,.faction-wu{
  --v218-main:#8f241f;--v218-deep:#360806;--v218-soft:#d45a50;--v218-glyph:'吳';
}
#hand.hand .card.other,.battlefield-layout .unit.other,.faction-other,
#hand.hand .card.item,#hand.hand .card.tactic{
  --v218-main:#5c2d79;--v218-deep:#1d092c;--v218-soft:#9b67bb;--v218-glyph:'群';
}

#hand.hand .card,
.battlefield-layout .unit{
  border:2px solid var(--v218-gold)!important;
  border-radius:9px!important;
  background:var(--v218-deep,#111)!important;
  box-shadow:0 3px 9px #000b,inset 0 0 0 1px rgba(255,255,255,.13)!important;
  isolation:isolate!important;
}

#hand.hand .card .card-title-area,
.battlefield-layout .unit .card-title-area{
  grid-template-columns:minmax(0,1fr) auto!important;
  padding:2px 5px 2px 7px!important;
  border-bottom:1px solid var(--v218-gold)!important;
  background:linear-gradient(180deg,var(--v218-main,#394552),var(--v218-deep,#131921))!important;
  box-shadow:inset 0 -1px rgba(0,0,0,.35)!important;
}

#hand.hand .card .card-name-text,
.battlefield-layout .unit .field-unit-name{
  color:#fff!important;
  font-family:"Malgun Gothic","Apple SD Gothic Neo",sans-serif!important;
  font-size:12px!important;
  font-weight:1000!important;
  letter-spacing:-.055em!important;
  text-align:center!important;
  text-shadow:0 1px 2px #000!important;
}

#hand.hand .card .card-title-grade,
.battlefield-layout .unit .field-grade{
  min-width:25px!important;
  height:17px!important;
  padding:0 4px!important;
  border:1px solid var(--v218-gold-soft)!important;
  border-radius:4px!important;
  background:#15100be8!important;
  color:#ffe992!important;
  font-size:9px!important;
  font-weight:1000!important;
  box-shadow:none!important;
  text-shadow:0 1px #000!important;
}

#hand.hand .card .cimg,
.battlefield-layout .unit .uimg{
  background:linear-gradient(180deg,var(--v218-deep,#0d1218),#05070a)!important;
}

#hand.hand .card .cimg::after,
.battlefield-layout .unit .uimg::after,
.collection-card-art::after{
  content:"";
  position:absolute;
  inset:0;
  z-index:3;
  pointer-events:none;
  background:linear-gradient(180deg,rgba(0,0,0,.04) 52%,rgba(0,0,0,.62) 100%),linear-gradient(90deg,rgba(0,0,0,.20),transparent 18%,transparent 82%,rgba(0,0,0,.20));
}

#hand.hand .card .cimg::before,
.battlefield-layout .unit .uimg::before,
.faction-wei .collection-card-art::before,
.faction-shu .collection-card-art::before,
.faction-wu .collection-card-art::before,
.faction-other .collection-card-art::before{
  content:var(--v218-glyph,'群');
  position:absolute;
  right:4px;
  top:4px;
  z-index:8;
  display:grid;
  place-items:center;
  width:20px;
  height:20px;
  border:1px solid var(--v218-gold-soft);
  border-radius:50%;
  background:color-mix(in srgb,var(--v218-deep,#111) 88%,transparent);
  color:#fff4c3;
  font-family:"Malgun Myeongjo","Batang",serif;
  font-size:12px;
  font-weight:1000;
  line-height:1;
  text-shadow:0 1px 2px #000;
  box-shadow:0 1px 4px #000b;
  pointer-events:none;
}

#hand.hand .card .card-bottom-icons,
.battlefield-layout .unit .unit-bottom-icons{
  inset:0!important;
  right:auto!important;
  bottom:auto!important;
  display:block!important;
  width:100%!important;
  height:100%!important;
  z-index:10!important;
}

#hand.hand .card .card-bottom-icons>span:first-child,
.battlefield-layout .unit .unit-bottom-icons>span:first-child{
  position:absolute!important;
  left:4px!important;
  bottom:4px!important;
  display:grid!important;
  place-items:center!important;
  width:20px!important;
  height:20px!important;
  border:1px solid var(--v218-gold-soft)!important;
  border-radius:5px!important;
  background:rgba(5,7,10,.86)!important;
  color:#fff!important;
  font-size:12px!important;
  text-shadow:none!important;
}

#hand.hand .card .card-ap-icon,
.battlefield-layout .unit .unit-bottom-icons>span:last-child{
  position:absolute!important;
  left:4px!important;
  top:4px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-width:29px!important;
  height:24px!important;
  padding:0 4px!important;
  border:2px solid var(--v218-gold-soft)!important;
  border-radius:999px!important;
  background:var(--v218-deep,#111)!important;
  color:#fff!important;
  font-size:0!important;
  font-weight:1000!important;
  text-shadow:none!important;
  box-shadow:0 2px 5px #000b!important;
}
#hand.hand .card .card-ap-icon::before,
.battlefield-layout .unit .unit-bottom-icons>span:last-child::before{
  content:attr(data-en) ' EN';
  font-size:10px;
  line-height:1;
  white-space:nowrap;
}

#hand.hand .card .card-bottom-icons>span:not(:first-child):not(.card-ap-icon),
.battlefield-layout .unit .unit-bottom-icons>span:not(:first-child):not(:last-child),
#hand.hand .card .card-ability-label,
#hand.hand .card .hand-buff-provider-badge,
#hand.hand .card .general-class-hand-badge,
#hand.hand .card .soldier-class-hand-icon,
.battlefield-layout .unit .unit-ability-label,
.battlefield-layout .unit .unit-class-icon,
.battlefield-layout .unit .unit-buff-box,
.battlefield-layout .unit .unit-skill-box,
.battlefield-layout .unit .unit-scout-badge{
  display:none!important;
}

#hand.hand .card .cstats,
.battlefield-layout .unit .stats{
  border-top:1px solid var(--v218-gold)!important;
  background:var(--v218-deep,#10161d)!important;
}
#hand.hand .card .card-stat-cell,
.battlefield-layout .unit .stats span{
  position:relative!important;
  gap:2px!important;
  border-right:1px solid color-mix(in srgb,var(--v218-gold) 70%,transparent)!important;
  background:linear-gradient(180deg,color-mix(in srgb,var(--v218-main,#333) 82%,#000),var(--v218-deep,#111))!important;
  color:#fff!important;
  font-size:13px!important;
  font-weight:1000!important;
  text-shadow:0 1px 2px #000!important;
}
#hand.hand .card .card-stat-cell b{font-size:14px!important;line-height:1!important}
#hand.hand .card .card-stat-cell::before,
.battlefield-layout .unit .stats span::before{
  color:#ffe48b;
  font-size:9px;
  font-weight:1000;
  line-height:1;
}
#hand.hand .card .card-stat-cell:nth-child(1)::before,
.battlefield-layout .unit .stats span:nth-child(1)::before{content:'⚔'}
#hand.hand .card .card-stat-cell:nth-child(2)::before,
.battlefield-layout .unit .stats span:nth-child(2)::before{content:'◆'}
#hand.hand .card .card-stat-cell:nth-child(3)::before,
.battlefield-layout .unit .stats span:nth-child(3)::before{content:'♥';color:#ff7777}

#hand.hand .card .card-ready-badge{
  position:absolute!important;
  left:4px!important;
  top:50%!important;
  width:7px!important;
  min-width:7px!important;
  height:7px!important;
  padding:0!important;
  border:1px solid #d7ffd7!important;
  border-radius:50%!important;
  background:#40d861!important;
  color:transparent!important;
  overflow:hidden!important;
  box-shadow:0 0 6px #4cff72!important;
}

#hand.hand .card.item,
#hand.hand .card.tactic{
  --v218-main:#5c2d79;--v218-deep:#1d092c;--v218-soft:#9b67bb;--v218-glyph:'策';
}
#hand.hand .card.utility-card .cimg::before{content:'策'}

.deck-builder-visual-card,
.card-shop-grid .shop-card{
  border:2px solid var(--v218-gold)!important;
  border-radius:8px!important;
  background:var(--v218-deep,#101216)!important;
  box-shadow:0 3px 8px #0009,inset 0 0 0 1px rgba(255,255,255,.10)!important;
}
.deck-builder-visual-card>.collection-card-title,
.card-shop-grid .shop-card>.collection-card-title{
  background:linear-gradient(180deg,var(--v218-main,#3c2d25),var(--v218-deep,#17110e))!important;
  border-bottom:1px solid var(--v218-gold)!important;
}
.collection-card-title .collection-card-name,
.collection-card-title>b{
  color:#fff!important;
  font-size:11px!important;
  font-weight:1000!important;
  letter-spacing:-.045em!important;
  text-shadow:0 1px 2px #000!important;
}
.collection-card-title>em{
  border:1px solid var(--v218-gold-soft)!important;
  background:#15100be8!important;
  color:#ffe992!important;
  border-radius:4px!important;
  font-size:8px!important;
}
.deck-builder-visual-card>.collection-card-art,
.card-shop-grid .shop-card>.collection-card-art{
  background:var(--v218-deep,#101216)!important;
}
.collection-card-icons{
  inset:0!important;
  right:auto!important;
  bottom:auto!important;
  display:block!important;
  width:100%!important;
  height:100%!important;
  z-index:10!important;
}
.collection-card-icons .collection-type-icon,
.collection-card-icons>span:first-child{
  position:absolute!important;
  left:4px!important;
  bottom:4px!important;
  display:grid!important;
  place-items:center!important;
  width:19px!important;
  height:19px!important;
  border:1px solid var(--v218-gold-soft)!important;
  border-radius:5px!important;
  background:rgba(5,7,10,.86)!important;
  color:#fff!important;
  font-size:11px!important;
}
.collection-card-icons .collection-en-icon,
.collection-card-icons>span:last-child{
  position:absolute!important;
  left:4px!important;
  top:4px!important;
  min-width:27px!important;
  height:22px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:0 4px!important;
  border:2px solid var(--v218-gold-soft)!important;
  border-radius:999px!important;
  background:var(--v218-deep,#111)!important;
  color:#fff!important;
  font-size:0!important;
  text-shadow:none!important;
}
.collection-card-icons .collection-en-icon::before,
.collection-card-icons>span:last-child::before{content:attr(data-en) ' EN';font-size:9px;line-height:1;white-space:nowrap}
.collection-card-icons>span:not(:first-child):not(:last-child){display:none!important}
.deck-builder-visual-card>.collection-five-stats,
.card-shop-grid .shop-card>.collection-five-stats{
  border-top:1px solid var(--v218-gold)!important;
  border-bottom:0!important;
  background:linear-gradient(180deg,var(--v218-main,#303640),var(--v218-deep,#121820))!important;
  color:#fff!important;
  font-size:11px!important;
  font-weight:1000!important;
  letter-spacing:.02em!important;
  text-shadow:0 1px 2px #000!important;
}
.collection-stat-core{font-size:12px!important;color:#fff!important}
.collection-stat-mind{font-size:8px!important;color:#ffeaa0!important}
.deck-builder-visual-card>.collection-extra,
.card-shop-grid .shop-card>.collection-extra{
  background:#090c10!important;
  color:#d9dee6!important;
  border-top:1px solid rgba(255,255,255,.10)!important;
}

@media (max-width:850px){
  #hand.hand .card .card-name-text,
  .battlefield-layout .unit .field-unit-name{font-size:9px!important}
  #hand.hand .card .card-title-grade,
  .battlefield-layout .unit .field-grade{min-width:20px!important;height:14px!important;font-size:7px!important;padding:0 2px!important}
  #hand.hand .card .cimg::before,
  .battlefield-layout .unit .uimg::before{width:16px;height:16px;font-size:9px;right:3px;top:3px}
  #hand.hand .card .card-ap-icon,
  .battlefield-layout .unit .unit-bottom-icons>span:last-child{left:3px!important;top:3px!important;min-width:24px!important;height:19px!important;border-width:1px!important}
  #hand.hand .card .card-ap-icon::before,
  .battlefield-layout .unit .unit-bottom-icons>span:last-child::before{font-size:8px!important}
  #hand.hand .card .card-bottom-icons>span:first-child,
  .battlefield-layout .unit .unit-bottom-icons>span:first-child{left:3px!important;bottom:3px!important;width:16px!important;height:16px!important;font-size:9px!important}
  #hand.hand .card .card-stat-cell,
  .battlefield-layout .unit .stats span{font-size:9px!important;padding:0!important}
  #hand.hand .card .card-stat-cell b{font-size:10px!important}
  #hand.hand .card .card-stat-cell::before,
  .battlefield-layout .unit .stats span::before{font-size:7px!important}
}

@supports not (background:color-mix(in srgb,#000 50%,#fff)){
  #hand.hand .card .cimg::before,.battlefield-layout .unit .uimg::before,
  .faction-wei .collection-card-art::before,.faction-shu .collection-card-art::before,
  .faction-wu .collection-card-art::before,.faction-other .collection-card-art::before{background:rgba(8,10,14,.88)}
  #hand.hand .card .card-stat-cell,.battlefield-layout .unit .stats span{background:var(--v218-deep,#111)!important}
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    grid-template-columns:382px minmax(716px,1fr)!important;
  }
}
@media (min-width:851px) and (max-height:900px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    grid-template-columns:382px minmax(716px,1fr)!important;
  }
}
body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel,
body.unified-left-layout:not(.ui-mode-mobile-preview) .boardwrap{
  overflow-x:auto!important;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v216-card-w:112.86px;
    --v216-card-h:175.56px;
    --v216-hand-h:351.12px;
    --v216-hand-w:338.58px;
    --v216-hand-section-h:389.12px;
    --v216-formation-w:705.66px;
    --v216-five-card-w:588.3px;
    --v216-four-card-w:469.44px;
    --v216-three-card-w:350.58px;
    --v216-two-card-w:231.72px;
    --v216-lane-h:188.1px;
  }
}

#hand.hand .card .card-ap-icon::before,
.battlefield-layout .unit .unit-bottom-icons>span:last-child::before,
.collection-card-icons .collection-en-icon::before,
.collection-card-icons>span:last-child::before{
  content:attr(data-en)!important;
}

#hand.hand .card .card-title-grade.grade-SSS,
.battlefield-layout .unit .field-grade.grade-SSS,
.collection-card-title>em.grade-SSS{border-color:var(--grade-sss)!important;color:var(--grade-sss)!important}
#hand.hand .card .card-title-grade.grade-SS,
.battlefield-layout .unit .field-grade.grade-SS,
.collection-card-title>em.grade-SS{border-color:var(--grade-ss)!important;color:var(--grade-ss)!important}
#hand.hand .card .card-title-grade.grade-S,
.battlefield-layout .unit .field-grade.grade-S,
.collection-card-title>em.grade-S{border-color:var(--grade-s)!important;color:var(--grade-s)!important}
#hand.hand .card .card-title-grade.grade-RR,
.battlefield-layout .unit .field-grade.grade-RR,
.collection-card-title>em.grade-RR{border-color:var(--grade-rr)!important;color:var(--grade-rr)!important}
#hand.hand .card .card-title-grade.grade-R,
.battlefield-layout .unit .field-grade.grade-R,
.collection-card-title>em.grade-R{border-color:var(--grade-r)!important;color:var(--grade-r)!important}
#hand.hand .card .card-title-grade.grade-U,
.battlefield-layout .unit .field-grade.grade-U,
.collection-card-title>em.grade-U{border-color:var(--grade-u)!important;color:var(--grade-u)!important}
#hand.hand .card .card-title-grade.grade-C,
.battlefield-layout .unit .field-grade.grade-C,
.collection-card-title>em.grade-C{border-color:var(--grade-c)!important;color:var(--grade-c)!important}

body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell::before,
body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span::before,
#hand.hand .card .card-stat-cell::before,
.battlefield-layout .unit .stats span::before{
  content:none!important;
  display:none!important;
}
body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell,
body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span{
  grid-template-rows:1fr!important;
}

#hand.hand .card .cimg::before,
.battlefield-layout .unit .uimg::before,
.faction-wei .collection-card-art::before,
.faction-shu .collection-card-art::before,
.faction-wu .collection-card-art::before,
.faction-other .collection-card-art::before,
.collection-card-art::before{
  content:attr(data-en)!important;
  font-family:"Malgun Gothic","Apple SD Gothic Neo",sans-serif!important;
  font-size:11px!important;
  font-weight:1000!important;
}
#hand.hand .card.utility-card .cimg::before{content:attr(data-en)!important}
@media (max-width:850px){
  #hand.hand .card .cimg::before,
  .battlefield-layout .unit .uimg::before{font-size:9px!important}
}

#hand.hand .card .card-ap-icon,
.battlefield-layout .unit .unit-bottom-icons>span:last-child,
.collection-card-icons .collection-en-icon,
.collection-card-icons>span:last-child{
  display:none!important;
}

#hand.hand .card .card-ready-badge{display:none!important}

#hand.hand .card.affordable .card-title-area{
  background:linear-gradient(180deg,#2f8f52,#0d3a20)!important;
  border-bottom-color:#8ff0ae!important;
}
#hand.hand .card.affordable .card-name-text{
  color:#eeffee!important;
  text-shadow:0 0 6px #4cff72,0 1px 2px #000!important;
}

.battlefield-layout .slot,
.battlefield-layout .hq-field-slot,
.battlefield-layout .unit{
  box-sizing:border-box!important;
}

@media (min-width:851px){
  
  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row]{
    height:calc(var(--v216-lane-h, 198px) + 6px)!important;
    min-height:calc(var(--v216-lane-h, 198px) + 6px)!important;
    max-height:calc(var(--v216-lane-h, 198px) + 6px)!important;
    flex:0 0 calc(var(--v216-lane-h, 198px) + 6px)!important;
  }

  
  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane.synergy-active{
    height:calc(var(--v216-lane-h, 198px) + 15px)!important;
    min-height:calc(var(--v216-lane-h, 198px) + 15px)!important;
    max-height:calc(var(--v216-lane-h, 198px) + 15px)!important;
    flex:0 0 calc(var(--v216-lane-h, 198px) + 15px)!important;
    padding-top:17px!important;
  }
}
.lane .lane-synergy-tag{
  top:1px!important;
  padding:1px 7px!important;
  font-size:8px!important;
  line-height:1.3!important;
  max-width:70%!important;
}

body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .unit-ability-label{
  display:block!important;
  position:absolute!important;
  top:auto!important;
  bottom:29px!important;
  left:4px!important;
  right:4px!important;
  z-index:13!important;
  padding:1px 4px!important;
  border:1px solid #9eb8d055!important;
  border-radius:3px!important;
  background:#06101bb8!important;
  color:#eff8ff!important;
  font-size:8px!important;
  font-weight:850!important;
  line-height:1.25!important;
  text-align:center!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  text-shadow:0 1px 2px #000!important;
}

body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-ready-badge,
#hand.hand .card .card-ready-badge{
  display:none!important;
  content:none!important;
}

body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.affordable .card-title-area,
#hand.hand .card.affordable .card-title-area{
  background:linear-gradient(180deg,#2f8f52,#0d3a20)!important;
  border-bottom-color:#8ff0ae!important;
}
body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.affordable .card-name-text,
#hand.hand .card.affordable .card-name-text{
  color:#eeffee!important;
  text-shadow:0 0 6px #4cff72,0 1px 2px #000!important;
}

.battlefield-layout .unit .uimg::before{
  content:none!important;
  display:none!important;
}

:root{
  --v224-card-ratio:2.5 / 3.5;
  --v224-gold:#c8a45c;
  --v224-gold-bright:#ffe7a0;
  --v224-black:#07090c;
  --v224-paper:#d8ccb2;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v216-card-w:102px;
    --v216-card-h:143px;
    --v216-hand-h:286px;
    --v216-hand-w:306px;
    --v216-hand-section-h:324px;
    --v216-formation-w:651px;
    --v216-five-card-w:534px;
    --v216-four-card-w:426px;
    --v216-three-card-w:318px;
    --v216-two-card-w:210px;
    --v216-lane-h:151px;
    --hand-card-width:var(--v216-card-w);
    --hand-card-height:var(--v216-card-h);
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:var(--v216-hand-section-h)!important;
    min-height:var(--v216-hand-section-h)!important;
    max-height:var(--v216-hand-section-h)!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-rows:repeat(2,var(--v216-card-h))!important;
    grid-auto-rows:var(--v216-card-h)!important;
    height:var(--v216-hand-h)!important;
    min-height:var(--v216-hand-h)!important;
    max-height:var(--v216-hand-h)!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane[data-row],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-defense-lane{
    height:var(--v216-lane-h)!important;
    min-height:var(--v216-lane-h)!important;
    max-height:var(--v216-lane-h)!important;
    flex-basis:var(--v216-lane-h)!important;
    padding:3px 0 5px!important;
    overflow:visible!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane.synergy-active{
    height:calc(var(--v216-lane-h) + 14px)!important;
    min-height:calc(var(--v216-lane-h) + 14px)!important;
    max-height:calc(var(--v216-lane-h) + 14px)!important;
    flex-basis:calc(var(--v216-lane-h) + 14px)!important;
    padding-top:17px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .hq-battlefield-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .hq-field-slot{
    height:var(--v216-card-h)!important;
    min-height:var(--v216-card-h)!important;
    max-height:var(--v216-card-h)!important;
  }
}

#hand.hand .card,
.battlefield-layout .unit{
  box-sizing:border-box!important;
  aspect-ratio:var(--v224-card-ratio)!important;
  display:grid!important;
  grid-template-rows:22px minmax(0,1fr) 25px!important;
  border:2px solid var(--v224-gold)!important;
  border-radius:5px!important;
  background:var(--v218-deep,#10151b)!important;
  overflow:hidden!important;
  box-shadow:0 3px 9px #000c,inset 0 0 0 1px #f6dda42b!important;
}

#hand.hand .card.utility-card{
  grid-template-rows:22px minmax(0,1fr) 36px!important;
}

.battlefield-layout .slot,
.battlefield-layout .hq-field-slot,
.battlefield-layout .slot>.unit,
.battlefield-layout .hq-field-slot>.unit{
  box-sizing:border-box!important;
  min-height:0!important;
  max-height:none!important;
}
.battlefield-layout .slot>.unit,
.battlefield-layout .hq-field-slot>.unit{
  width:100%!important;
  height:100%!important;
}

#hand.hand .card .card-title-area,
.battlefield-layout .unit .card-title-area{
  position:relative!important;
  display:grid!important;
  grid-template-columns:31px minmax(0,1fr)!important;
  align-items:center!important;
  gap:2px!important;
  min-height:22px!important;
  height:22px!important;
  padding:0 4px 0 0!important;
  border-bottom:1px solid var(--v224-gold)!important;
  background:linear-gradient(180deg,var(--v218-main,#394552),var(--v218-deep,#131921))!important;
  overflow:hidden!important;
}

#hand.hand .card .card-kind-ribbon,
.battlefield-layout .unit .card-kind-ribbon{
  align-self:stretch;
  display:flex;
  align-items:center;
  justify-content:center;
  min-width:31px;
  padding:0 3px;
  color:#f8f3e7;
  background:color-mix(in srgb,var(--v218-main,#38506c) 76%,#0a0d12);
  border-right:1px solid #d7bd7a88;
  clip-path:polygon(0 0,100% 0,86% 100%,0 100%);
  font-size:7.5px;
  font-weight:950;
  line-height:1;
  white-space:nowrap;
  text-shadow:0 1px 2px #000;
}

#hand.hand .card .card-name-text,
.battlefield-layout .unit .field-unit-name{
  display:block!important;
  min-width:0!important;
  width:100%!important;
  padding:0 2px!important;
  color:#fff!important;
  font-family:"Malgun Gothic","Apple SD Gothic Neo",sans-serif!important;
  font-size:11px!important;
  font-weight:950!important;
  line-height:1!important;
  letter-spacing:-.055em!important;
  text-align:center!important;
  white-space:nowrap!important;
  overflow:visible!important;
  text-overflow:clip!important;
  text-shadow:0 1px 2px #000!important;
  transform-origin:center!important;
}

#hand.hand .card .card-title-area>.card-title-grade,
.battlefield-layout .unit .card-title-area>.field-grade{
  display:none!important;
}

#hand.hand .card .cimg,
.battlefield-layout .unit .uimg{
  position:relative!important;
  min-height:0!important;
  overflow:hidden!important;
  border:0!important;
  background:linear-gradient(180deg,var(--v218-deep,#10151b),#050608)!important;
}

#hand.hand .card .card-image-grade,
.battlefield-layout .unit .card-image-grade{
  position:absolute!important;
  z-index:15!important;
  left:4px!important;
  top:4px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-width:22px!important;
  height:17px!important;
  padding:0 4px!important;
  border:0!important;
  border-radius:2px!important;
  background:#071018d6!important;
  color:#fff0a5!important;
  font-size:9px!important;
  font-weight:1000!important;
  line-height:1!important;
  text-shadow:0 1px 2px #000,0 0 4px currentColor!important;
  box-shadow:none!important;
}

#hand.hand .card .card-kind-strip,
.battlefield-layout .unit .card-kind-strip{
  position:absolute!important;
  z-index:14!important;
  left:50%!important;
  bottom:3px!important;
  transform:translateX(-50%)!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-width:48px!important;
  max-width:70%!important;
  height:14px!important;
  padding:0 7px!important;
  border:1px solid #d2b56d99!important;
  border-radius:2px!important;
  background:#07090cda!important;
  color:#f5e4bd!important;
  font-size:7.5px!important;
  font-weight:950!important;
  line-height:1!important;
  white-space:nowrap!important;
  text-shadow:0 1px 2px #000!important;
}

#hand.hand .card .card-bottom-icons>span:first-child,
.battlefield-layout .unit .unit-bottom-icons>span:first-child{
  display:none!important;
}

#hand.hand .card .card-image-grade.grade-SSS,
.battlefield-layout .unit .card-image-grade.grade-SSS{color:var(--grade-sss,#ffd861)!important}
#hand.hand .card .card-image-grade.grade-SS,
.battlefield-layout .unit .card-image-grade.grade-SS{color:var(--grade-ss,#d9a0ff)!important}
#hand.hand .card .card-image-grade.grade-S,
.battlefield-layout .unit .card-image-grade.grade-S{color:var(--grade-s,#ffdf7a)!important}
#hand.hand .card .card-image-grade.grade-RR,
.battlefield-layout .unit .card-image-grade.grade-RR{color:var(--grade-rr,#a9e8ff)!important}
#hand.hand .card .card-image-grade.grade-R,
.battlefield-layout .unit .card-image-grade.grade-R{color:var(--grade-r,#a9d4ff)!important}
#hand.hand .card .card-image-grade.grade-U,
.battlefield-layout .unit .card-image-grade.grade-U{color:var(--grade-u,#cfdae8)!important}
#hand.hand .card .card-image-grade.grade-C,
.battlefield-layout .unit .card-image-grade.grade-C{color:var(--grade-c,#d0d0d0)!important}

#hand.hand .card .card-ready-badge{
  display:none!important;
  content:none!important;
}
#hand.hand .card.affordable .card-title-area{
  background:linear-gradient(180deg,var(--v218-main,#394552),var(--v218-deep,#131921))!important;
  border-bottom-color:var(--v224-gold)!important;
}
#hand.hand .card.affordable .card-name-text{
  color:#fff!important;
  text-shadow:0 1px 2px #000!important;
}
#hand.hand .card.affordable{
  border-color:var(--v224-gold-bright)!important;
  box-shadow:0 0 0 1px #fff3ba,0 0 12px 3px #ffd96b99,inset 0 0 10px #fff2a52b!important;
  filter:brightness(1.09) saturate(1.06)!important;
}
#hand.hand .card.affordable.selected{
  outline-color:#fff6c7!important;
  box-shadow:0 0 0 2px #fff6c7,0 0 16px 5px #ffd96baa!important;
}

#hand.hand .card .card-ap-icon{
  left:4px!important;
  right:auto!important;
  top:auto!important;
  bottom:3px!important;
  z-index:16!important;
  min-width:25px!important;
  height:20px!important;
  padding:0 4px!important;
  border:1px solid #f0d58a!important;
  border-radius:3px 8px 3px 3px!important;
  background:#07111bdd!important;
}
#hand.hand .card.utility-card .card-ap-icon{
  left:auto!important;
  right:4px!important;
  border-radius:8px 3px 3px 3px!important;
}
#hand.hand .card .card-ap-icon::before{
  content:'EN ' attr(data-en)!important;
  font-size:8px!important;
  font-style:italic!important;
  white-space:nowrap!important;
}

.battlefield-layout .unit .unit-ap-icon,
.battlefield-layout .unit .uimg::before{
  display:none!important;
  content:none!important;
}

#hand.hand .card .cstats,
.battlefield-layout .unit .stats{
  height:25px!important;
  min-height:25px!important;
  padding:0!important;
  border-top:1px solid var(--v224-gold)!important;
  background:var(--v224-paper)!important;
  color:#111!important;
}
#hand.hand .card .card-stat-grid,
.battlefield-layout .unit .stats{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:0!important;
  height:100%!important;
}
#hand.hand .card .card-stat-cell,
.battlefield-layout .unit .stats span{
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;
  justify-content:center!important;
  gap:2px!important;
  min-width:0!important;
  height:100%!important;
  padding:0 2px!important;
  border-right:1px solid #4b3922aa!important;
  background:linear-gradient(180deg,#e6dcc5,#bcae91)!important;
  color:#15120d!important;
  font-size:8px!important;
  font-weight:900!important;
  line-height:1!important;
  text-shadow:none!important;
  white-space:nowrap!important;
}
#hand.hand .card .card-stat-cell:last-child,
.battlefield-layout .unit .stats span:last-child{border-right:0!important}
#hand.hand .card .card-stat-cell b{
  font-size:13px!important;
  color:#111!important;
  line-height:1!important;
}
#hand.hand .card .card-stat-cell::before,
.battlefield-layout .unit .stats span::before{
  display:inline!important;
  color:#19150e!important;
  font-size:7px!important;
  font-weight:950!important;
  line-height:1!important;
}
#hand.hand .card .card-stat-cell:nth-child(1)::before,
.battlefield-layout .unit .stats span:nth-child(1)::before{content:'공격'!important}
#hand.hand .card .card-stat-cell:nth-child(2)::before,
.battlefield-layout .unit .stats span:nth-child(2)::before{content:'방어'!important}
#hand.hand .card .card-stat-cell:nth-child(3)::before,
.battlefield-layout .unit .stats span:nth-child(3)::before{content:'체력'!important}

#hand.hand .card .card-effect-text{
  box-sizing:border-box!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:100%!important;
  height:36px!important;
  min-height:36px!important;
  padding:3px 5px!important;
  border-top:1px solid var(--v224-gold)!important;
  background:linear-gradient(180deg,#13171b,#07090c)!important;
  color:#f2eee5!important;
  font-size:8.5px!important;
  font-weight:750!important;
  line-height:1.18!important;
  text-align:center!important;
  word-break:keep-all!important;
  overflow:visible!important;
}
#hand.hand .card .card-effect-text>span{
  display:block!important;
  width:100%!important;
  max-height:100%!important;
  overflow:visible!important;
}

#hand.hand .card .card-ability-label,
#hand.hand .card .hand-buff-provider-badge,
#hand.hand .card .general-class-hand-badge,
#hand.hand .card .soldier-class-hand-icon,
.battlefield-layout .unit .unit-ability-label,
.battlefield-layout .unit .unit-class-icon,
.battlefield-layout .unit .unit-buff-box,
.battlefield-layout .unit .unit-skill-box,
.battlefield-layout .unit .unit-scout-badge{
  display:none!important;
}

.card-name-text[data-v224-fit],
.field-unit-name[data-v224-fit]{font-size:var(--v224-fit-size,11px)!important}
.card-effect-text[data-v224-fit]{font-size:var(--v224-effect-fit-size,8.5px)!important}

@media (max-width:850px){
  #hand.hand .card,
  .battlefield-layout .unit{
    aspect-ratio:var(--v224-card-ratio)!important;
    grid-template-rows:18px minmax(0,1fr) 21px!important;
  }
  #hand.hand .card.utility-card{grid-template-rows:18px minmax(0,1fr) 31px!important}
  #hand.hand .card .card-title-area,
  .battlefield-layout .unit .card-title-area{height:18px!important;min-height:18px!important;grid-template-columns:26px minmax(0,1fr)!important}
  #hand.hand .card .card-kind-ribbon,
  .battlefield-layout .unit .card-kind-ribbon{min-width:26px!important;font-size:6px!important}
  #hand.hand .card .card-name-text,
  .battlefield-layout .unit .field-unit-name{font-size:8px!important}
  #hand.hand .card .card-image-grade,
  .battlefield-layout .unit .card-image-grade{min-width:18px!important;height:14px!important;font-size:7px!important;left:3px!important;top:3px!important}
  #hand.hand .card .card-kind-strip,
  .battlefield-layout .unit .card-kind-strip{height:12px!important;min-width:38px!important;font-size:6px!important;bottom:2px!important}
  #hand.hand .card .cstats,
  .battlefield-layout .unit .stats{height:21px!important;min-height:21px!important}
  #hand.hand .card .card-stat-cell,
  .battlefield-layout .unit .stats span{font-size:6px!important;padding:0 1px!important}
  #hand.hand .card .card-stat-cell b{font-size:9px!important}
  #hand.hand .card .card-stat-cell::before,
  .battlefield-layout .unit .stats span::before{font-size:5.5px!important}
  #hand.hand .card .card-effect-text{height:31px!important;min-height:31px!important;padding:2px 3px!important;font-size:6.5px!important}
  #hand.hand .card .card-ap-icon{min-width:21px!important;height:16px!important;bottom:2px!important}
  #hand.hand .card .card-ap-icon::before{font-size:6.5px!important}
}

.event-image-effect-line label,
.batch-scene-shuttle-card>label{
  min-width:0!important;
}
.event-image-effect-line select[id$="SceneEntry"],
.batch-scene-shuttle-card select[id$="Entry"]{
  border-color:#a9874d!important;
  background:#11161d!important;
  color:#f1dfb8!important;
}

.hq-card-scene.entry-steady:not(.holding):not(.leaving) .scene-entry-motion{
  animation:v224EntrySteady .85s ease-out both!important;
}
@keyframes v224EntrySteady{
  0%{opacity:0;filter:brightness(.75) blur(2px);transform:translate3d(0,8px,0)}
  100%{opacity:1;filter:none;transform:translate3d(0,0,0)}
}

.hq-card-scene.entry-impact:not(.holding):not(.leaving) .scene-entry-motion{
  animation:v224EntryImpact .78s cubic-bezier(.2,.72,.24,1) both!important;
}
@keyframes v224EntryImpact{
  0%{opacity:0;filter:brightness(.65);transform:translate3d(0,0,0)}
  22%{opacity:1;filter:brightness(1.35);transform:translate3d(-8px,1px,0) rotate(-.7deg)}
  37%{transform:translate3d(7px,-1px,0) rotate(.6deg)}
  52%{transform:translate3d(-5px,0,0) rotate(-.4deg)}
  68%{transform:translate3d(3px,0,0) rotate(.2deg)}
  100%{opacity:1;filter:none;transform:translate3d(0,0,0) rotate(0)}
}

.hq-card-scene.entry-unfold:not(.holding):not(.leaving) .scene-entry-motion{
  animation:v224EntryUnfold .92s cubic-bezier(.2,.76,.2,1) both!important;
}
@keyframes v224EntryUnfold{
  0%{opacity:.15;clip-path:inset(0 49% 0 49%);filter:brightness(1.7) blur(2px);transform:none}
  55%{opacity:1;clip-path:inset(0 8% 0 8%);filter:brightness(1.15);transform:none}
  100%{opacity:1;clip-path:inset(0 0 0 0);filter:none;transform:none}
}

.hq-card-scene.entry-suck:not(.holding):not(.leaving) .scene-entry-motion{
  animation:v224EntrySuck 1s cubic-bezier(.14,.72,.18,1) both!important;
}
@keyframes v224EntrySuck{
  0%{opacity:0;filter:blur(18px) brightness(2.2);transform:translate3d(34px,-20px,0) skewX(-8deg)}
  38%{opacity:.8;filter:blur(7px) brightness(1.55);transform:translate3d(-10px,7px,0) skewX(3deg)}
  68%{opacity:1;filter:blur(2px) brightness(1.18);transform:translate3d(3px,-2px,0) skewX(0)}
  100%{opacity:1;filter:none;transform:translate3d(0,0,0)}
}

.hq-card-scene.entry-emerge:not(.holding):not(.leaving) .scene-entry-motion{
  animation:v224EntryEmerge .95s cubic-bezier(.18,.78,.2,1) both!important;
}
@keyframes v224EntryEmerge{
  0%{opacity:0;clip-path:circle(0 at 50% 50%);filter:brightness(2) blur(4px);transform:none}
  52%{opacity:1;clip-path:circle(48% at 50% 50%);filter:brightness(1.25) blur(1px);transform:none}
  100%{opacity:1;clip-path:circle(75% at 50% 50%);filter:none;transform:none}
}

.hq-card-scene .scene-entry-motion{
  position:absolute;
  inset:0;
  z-index:0;
  display:block;
  overflow:hidden;
  transform-origin:center;
  will-change:transform,opacity,filter,clip-path;
}

.hq-card-scene .scene-shade,
.hq-card-scene .scene-energy,
.hq-card-scene .scene-particles,
.hq-card-scene .scene-effect-caption,
.hq-card-scene .scene-label{
  z-index:1;
}

.hq-card-scene.holding .scene-entry-motion,
.hq-card-scene.leaving .scene-entry-motion{
  clip-path:none!important;
  opacity:1!important;
  filter:none!important;
  transform:none!important;
}
.hq-card-scene.holding img{
  clip-path:none!important;
  opacity:1!important;
  filter:none!important;
  transform:scale(var(--scene-scale,1))!important;
}

@media (prefers-reduced-motion:reduce){
  .hq-card-scene[class*="entry-"] .scene-entry-motion{animation:none!important;clip-path:none!important;opacity:1!important;filter:none!important;transform:none!important}
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    box-sizing:border-box!important;
    aspect-ratio:2.5 / 3.5!important;
    display:grid!important;
    grid-template-rows:22px minmax(0,1fr) 25px!important;
    border:2px solid var(--v224-gold)!important;
    border-radius:5px!important;
    background:var(--v218-deep,#10151b)!important;
    overflow:hidden!important;
    box-shadow:0 3px 9px #000c,inset 0 0 0 1px #f6dda42b!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card.utility-card{
    grid-template-rows:22px minmax(0,1fr) 36px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-title-area,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .card-title-area{
    position:relative!important;
    display:grid!important;
    grid-template-columns:31px minmax(0,1fr)!important;
    align-items:center!important;
    gap:2px!important;
    min-height:22px!important;
    height:22px!important;
    padding:0 4px 0 0!important;
    border-bottom:1px solid var(--v224-gold)!important;
    background:linear-gradient(180deg,var(--v218-main,#394552),var(--v218-deep,#131921))!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-name-text,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .field-unit-name{
    display:block!important;
    min-width:0!important;
    width:100%!important;
    padding:0 2px!important;
    color:#fff!important;
    font-size:11px!important;
    font-weight:950!important;
    line-height:1!important;
    letter-spacing:-.055em!important;
    text-align:center!important;
    white-space:nowrap!important;
    overflow:visible!important;
    text-overflow:clip!important;
    transform-origin:center!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-name-text[data-v224-fit],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .field-unit-name[data-v224-fit]{
    font-size:var(--v224-fit-size,11px)!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-image-grade,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .card-image-grade.field-grade{
    position:absolute!important;
    z-index:15!important;
    left:4px!important;
    right:auto!important;
    top:4px!important;
    bottom:auto!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:22px!important;
    width:auto!important;
    height:17px!important;
    padding:0 4px!important;
    border:0!important;
    border-radius:2px!important;
    background:#071018d6!important;
    font-size:9px!important;
    font-weight:1000!important;
    line-height:1!important;
    box-shadow:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .cstats,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats{
    display:block!important;
    height:25px!important;
    min-height:25px!important;
    padding:0!important;
    border-top:1px solid var(--v224-gold)!important;
    background:var(--v224-paper)!important;
    color:#111!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-grid,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    grid-template-rows:1fr!important;
    gap:0!important;
    height:100%!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span{
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:center!important;
    gap:2px!important;
    min-width:0!important;
    height:100%!important;
    padding:0 2px!important;
    border-right:1px solid #4b3922aa!important;
    background:linear-gradient(180deg,#e6dcc5,#bcae91)!important;
    color:#15120d!important;
    font-size:8px!important;
    font-weight:900!important;
    line-height:1!important;
    white-space:nowrap!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell b{
    font-size:13px!important;
    color:#111!important;
    line-height:1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell::before,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span::before{
    display:inline!important;
    color:#19150e!important;
    font-size:7px!important;
    font-weight:950!important;
    line-height:1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell:nth-child(1)::before,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span:nth-child(1)::before{content:'공격'!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell:nth-child(2)::before,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span:nth-child(2)::before{content:'방어'!important}
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell:nth-child(3)::before,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span:nth-child(3)::before{content:'체력'!important}

  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-effect-text{
    display:flex!important;
    height:36px!important;
    min-height:36px!important;
    padding:3px 5px!important;
    font-size:var(--v224-effect-fit-size,8.5px)!important;
    line-height:1.18!important;
    overflow:visible!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-ready-badge{
    display:none!important;
    content:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.affordable .card-title-area{
    background:linear-gradient(180deg,var(--v218-main,#394552),var(--v218-deep,#131921))!important;
    border-bottom-color:var(--v224-gold)!important;
    box-shadow:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.affordable .card-name-text{
    color:#fff!important;
    text-shadow:0 1px 2px #000!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.affordable{
    border-color:var(--v224-gold-bright)!important;
    box-shadow:0 0 0 1px #fff3ba,0 0 12px 3px #ffd96b99,inset 0 0 10px #fff2a52b!important;
    filter:brightness(1.09) saturate(1.06)!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-ability-label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .hand-buff-provider-badge,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .general-class-hand-badge,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .soldier-class-hand-icon,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .unit-ability-label,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .unit-class-icon,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .unit-buff-box,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .unit-skill-box,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .unit-scout-badge{
    display:none!important;
  }
}

#hand.hand .card .card-kind-strip,
.mobile-hand-mount #hand.hand .card .card-kind-strip,
.battlefield-layout .unit .card-kind-strip{
  display:none!important;
  content:none!important;
}

body #hand.hand .card .card-stat-cell::before,
body .mobile-hand-mount #hand.hand .card .card-stat-cell::before,
body .battlefield-layout .unit .stats span::before{
  display:none!important;
  content:none!important;
}
body #hand.hand .card .card-stat-cell,
body .mobile-hand-mount #hand.hand .card .card-stat-cell,
body .battlefield-layout .unit .stats span{
  grid-template-rows:1fr!important;
}

#hand.hand .card .card-ready-badge,
#hand.hand .card .card-ready-label,
.mobile-hand-mount #hand.hand .card .card-ready-badge,
.mobile-hand-mount #hand.hand .card .card-ready-label{
  display:none!important;
  content:none!important;
}
#hand.hand .card.actionable-card:not(.opening-hand-card)::before,
.mobile-hand-mount #hand.hand .card.actionable-card:not(.opening-hand-card)::before{
  display:none!important;
  content:none!important;
}

#hand.hand .card.affordable .card-title-area,
#hand.hand .card.actionable-card .card-title-area,
.mobile-hand-mount #hand.hand .card.affordable .card-title-area,
.mobile-hand-mount #hand.hand .card.actionable-card .card-title-area{
  background:linear-gradient(180deg,var(--v218-main,#394552),var(--v218-deep,#131921))!important;
  border-bottom-color:var(--v224-gold,#d8bb72)!important;
  box-shadow:none!important;
}
#hand.hand .card.affordable .card-name-text,
#hand.hand .card.actionable-card .card-name-text,
.mobile-hand-mount #hand.hand .card.affordable .card-name-text,
.mobile-hand-mount #hand.hand .card.actionable-card .card-name-text{
  color:#fff!important;
  text-shadow:0 1px 2px #000!important;
}
#hand.hand .card.affordable,
#hand.hand .card.actionable-card,
.mobile-hand-mount #hand.hand .card.affordable,
.mobile-hand-mount #hand.hand .card.actionable-card{
  border-color:#fff2a0!important;
  box-shadow:0 0 0 2px #fff8cf,0 0 16px 5px #ffe36fad,inset 0 0 12px #fff4b83d!important;
  filter:brightness(1.12) saturate(1.08)!important;
}

#hand.hand .card .card-title-area,
.mobile-hand-mount #hand.hand .card .card-title-area,
.battlefield-layout .unit .card-title-area{
  display:grid!important;
  grid-template-columns:34px minmax(0,1fr)!important;
  align-items:center!important;
  gap:2px!important;
  height:24px!important;
  min-height:24px!important;
  max-height:24px!important;
  padding:0 4px 0 0!important;
  overflow:hidden!important;
}
#hand.hand .card .card-kind-ribbon,
.mobile-hand-mount #hand.hand .card .card-kind-ribbon,
.battlefield-layout .unit .card-kind-ribbon{
  align-self:stretch!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-width:34px!important;
  padding:0 3px!important;
  font-size:8px!important;
  font-weight:950!important;
  line-height:1!important;
  white-space:nowrap!important;
}
#hand.hand .card .card-name-text,
.mobile-hand-mount #hand.hand .card .card-name-text,
.battlefield-layout .unit .field-unit-name{
  display:block!important;
  width:100%!important;
  min-width:0!important;
  padding:0 2px!important;
  font-size:12px!important;
  font-weight:950!important;
  line-height:1!important;
  letter-spacing:-.05em!important;
  text-align:center!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    
    --v216-card-w:129.789px;
    --v216-card-h:201.894px;
    --v216-card-gap:6px;
    --v216-hand-w:391.367px;       
    --v216-hand-h:404.788px;       
    --v216-hand-section-h:444px;
    --v216-formation-w:811.509px;
    --v216-five-card-w:672.945px;
    --v216-four-card-w:537.156px;
    --v216-three-card-w:401.367px;
    --v216-two-card-w:265.578px;
    --v216-lane-h:216.315px;
    --hand-card-width:var(--v216-card-w);
    --hand-card-height:var(--v216-card-h);
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    
    grid-template-columns:401px minmax(822px,1fr)!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:var(--v216-hand-section-h)!important;
    min-height:var(--v216-hand-section-h)!important;
    max-height:var(--v216-hand-section-h)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox{
    padding:0!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v216-card-w))!important;
    grid-template-rows:repeat(2,var(--v216-card-h))!important;
    grid-auto-rows:var(--v216-card-h)!important;
    width:var(--v216-hand-w)!important;
    min-width:var(--v216-hand-w)!important;
    max-width:var(--v216-hand-w)!important;
    height:var(--v216-hand-h)!important;
    min-height:var(--v216-hand-h)!important;
    max-height:var(--v216-hand-h)!important;
    gap:1px!important;
    padding:0!important;
    margin:0!important;
    justify-content:start!important;
    align-content:start!important;
    overflow:hidden!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v216-card-w)!important;
    min-width:var(--v216-card-w)!important;
    max-width:var(--v216-card-w)!important;
    height:var(--v216-card-h)!important;
    min-height:var(--v216-card-h)!important;
    max-height:var(--v216-card-h)!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    grid-template-rows:24px minmax(0,1fr) 31px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card.utility-card{
    grid-template-rows:24px minmax(0,1fr) 42px!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .cstats,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats{
    height:31px!important;
    min-height:31px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .stats span{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:0 2px!important;
    font-size:19px!important;
    font-weight:1000!important;
    line-height:1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-stat-cell b{
    font-size:19px!important;
    font-weight:1000!important;
    line-height:1!important;
  }
}

@media (max-width:850px){
  .mobile-hand-mount #hand.hand{gap:1px!important}
  .mobile-hand-mount #hand.hand .card-stat-cell b,
  .battlefield-layout .unit .stats span{
    font-size:12px!important;
    font-weight:1000!important;
  }
}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand{gap:1px!important}
body.ui-mode-mobile-preview .mobile-hand-mount #hand.hand .card-stat-cell b,
body.ui-mode-mobile-preview .battlefield-layout .unit .stats span{
  font-size:12px!important;
  font-weight:1000!important;
}

#hand.hand .card .card-title-area>.card-kind-ribbon,
.mobile-hand-mount #hand.hand .card .card-title-area>.card-kind-ribbon{
  grid-column:1!important;
  grid-row:1!important;
  order:0!important;
}
#hand.hand .card .card-title-area>.card-name-text,
.mobile-hand-mount #hand.hand .card .card-title-area>.card-name-text{
  grid-column:2!important;
  grid-row:1!important;
  order:1!important;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    grid-template-columns:401px minmax(838px,1fr)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    box-sizing:border-box!important;
    padding-right:10px!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    box-sizing:border-box!important;
    margin-left:auto!important;
    margin-right:auto!important;
    overflow:visible!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.river{
    box-sizing:border-box!important;
  }
}

#hand.hand .card.item-stat-card{
  grid-template-rows:var(--v226-card-head,25.2px) minmax(0,1fr) 31px!important;
}
#hand.hand .card.item-stat-card .cstats{
  display:block!important;
  min-height:31px!important;
  height:31px!important;
  max-height:31px!important;
}
#hand.hand .card.item-stat-card .card-stat-grid{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  height:100%!important;
}
#hand.hand .card.item-stat-card .item-bonus-cell b{
  display:block!important;
  font-size:19px!important;
  font-weight:1000!important;
  line-height:1!important;
  letter-spacing:0!important;
  white-space:nowrap!important;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-body{
    box-sizing:border-box!important;
    height:212px!important;
    min-height:212px!important;
    max-height:212px!important;
    padding:6px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-card.action-view-mode{
    grid-template-columns:320px!important;
    grid-template-rows:24px 170px!important;
    justify-content:center!important;
    align-content:start!important;
    gap:5px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage{
    box-sizing:border-box!important;
    width:320px!important;
    min-width:320px!important;
    max-width:320px!important;
    height:170px!important;
    min-height:170px!important;
    max-height:170px!important;
    justify-self:center!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage>.hq-card-scene.left-effect-preview-scene{
    width:320px!important;
    min-width:320px!important;
    max-width:320px!important;
    height:170px!important;
    min-height:170px!important;
    max-height:170px!important;
  }
}

#batchSettingsModal[data-settings-mode="individual"] .event-image-setting .event-hq-preview-frame>.hq-title,
#batchSettingsModal[data-settings-mode="individual"] .event-image-setting .event-hq-preview-frame>.hq-subtitle{
  display:none!important;
}

:root{--v226-card-head:25.2px}
#hand.hand .card .card-title-area,
.mobile-hand-mount #hand.hand .card .card-title-area,
.battlefield-layout .unit .card-title-area{
  grid-template-columns:36px minmax(0,1fr)!important;
  height:var(--v226-card-head)!important;
  min-height:var(--v226-card-head)!important;
  max-height:var(--v226-card-head)!important;
}
#hand.hand .card .card-kind-ribbon,
.mobile-hand-mount #hand.hand .card .card-kind-ribbon,
.battlefield-layout .unit .card-kind-ribbon{
  min-width:36px!important;
  font-size:9px!important;
}
#hand.hand .card .card-name-text,
.mobile-hand-mount #hand.hand .card .card-name-text,
.battlefield-layout .unit .field-unit-name{
  font-size:13px!important;
  letter-spacing:-.045em!important;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    grid-template-rows:var(--v226-card-head) minmax(0,1fr) 31px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card.utility-card:not(.item-stat-card){
    grid-template-rows:var(--v226-card-head) minmax(0,1fr) 42px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-kind-ribbon,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .card-kind-ribbon{
    font-size:9px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-name-text,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .field-unit-name{
    font-size:13px!important;
  }
}

@media (max-width:850px){
  .mobile-hand-mount #hand.hand .card .card-title-area,
  .battlefield-layout .unit .card-title-area{
    grid-template-columns:32px minmax(0,1fr)!important;
  }
  .mobile-hand-mount #hand.hand .card .card-kind-ribbon,
  .battlefield-layout .unit .card-kind-ribbon{
    min-width:32px!important;
    font-size:8px!important;
  }
  .mobile-hand-mount #hand.hand .card .card-name-text,
  .battlefield-layout .unit .field-unit-name{
    font-size:10px!important;
  }
  .mobile-hand-mount #hand.hand .card.item-stat-card .item-bonus-cell b{
    font-size:12px!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-title-area,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .card-title-area{
    grid-template-columns:36px minmax(0,1fr)!important;
    height:var(--v226-card-head)!important;
    min-height:var(--v226-card-head)!important;
    max-height:var(--v226-card-head)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-kind-ribbon,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .card-kind-ribbon{
    grid-column:1!important;
    grid-row:1!important;
    min-width:36px!important;
    font-size:9px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card .card-name-text,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit .field-unit-name{
    grid-column:2!important;
    grid-row:1!important;
    font-size:13px!important;
    letter-spacing:-.045em!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .cstats{
    display:block!important;
    height:31px!important;
    min-height:31px!important;
    max-height:31px!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .item-bonus-cell b{
    display:block!important;
    font-size:19px!important;
    font-weight:1000!important;
    line-height:1!important;
  }
}

@media (max-width:850px){
  body #hand.hand .card .card-title-area,
  body .mobile-hand-mount #hand.hand .card .card-title-area,
  body .battlefield-layout .unit .card-title-area{
    height:var(--v226-card-head)!important;
    min-height:var(--v226-card-head)!important;
    max-height:var(--v226-card-head)!important;
  }
  body .mobile-hand-mount #hand.hand .card .card-kind-ribbon{
    grid-column:1!important;
    grid-row:1!important;
  }
  body .mobile-hand-mount #hand.hand .card .card-name-text{
    grid-column:2!important;
    grid-row:1!important;
  }
}

#cardManagerModal .manager-unified-scale-label{
  grid-template-columns:74px minmax(0,1fr) 42px!important;
}
#cardManagerModal .manager-hidden-scale-axis{
  display:none!important;
}
#cardManagerModal .manager-preview-dual-label small{
  font-size:10px;
  color:#c6b28d;
  font-weight:700;
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v227-field-gap:4px;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    padding-right:0!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    padding-right:8px!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    width:100%!important;
    min-width:0!important;
    padding-right:4px!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.river{
    width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    box-sizing:border-box!important;
    justify-content:stretch!important;
    gap:var(--v227-field-gap)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    width:100%!important;
    min-width:0!important;
    padding-left:6px!important;
    padding-right:6px!important;
    overflow-x:hidden!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout{
    display:grid!important;
    grid-template-columns:minmax(0,1fr)!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    padding:0!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    grid-column:1/-1!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    padding-left:4px!important;
    padding-right:4px!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-battle-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-defense-lane{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    display:grid!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    padding:0!important;
    margin:0!important;
    gap:var(--v216-card-gap,6px)!important;
    justify-content:space-evenly!important;
    justify-items:center!important;
    align-items:stretch!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,minmax(0,var(--v216-card-w,129.789px)))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,minmax(0,var(--v216-card-w,129.789px)))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,minmax(0,var(--v216-card-w,129.789px)))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,minmax(0,var(--v216-card-w,129.789px)))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v216-card-w,129.789px)!important;
    min-width:var(--v216-card-w,129.789px)!important;
    max-width:var(--v216-card-w,129.789px)!important;
    height:var(--v216-card-h,201.894px)!important;
    min-height:var(--v216-card-h,201.894px)!important;
    max-height:var(--v216-card-h,201.894px)!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.base-unit{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
    box-sizing:border-box!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    box-sizing:border-box!important;
    overflow-x:hidden!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    flex:1 1 auto!important;
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:6px!important;
    padding-right:6px!important;
    box-sizing:border-box!important;
    overflow-x:hidden!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    align-self:stretch!important;
    box-sizing:border-box!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    padding-left:4px!important;
    padding-right:4px!important;
    align-items:stretch!important;
    overflow-x:visible!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-battle-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-defense-lane{
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.enemy-hq-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.ally-hq-row{
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>#enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane[data-row="neutral"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>#allyBaseDefenseLane{
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    --v229-field-gap:var(--v216-card-gap,6px);
    width:100%!important;
    min-width:0!important;
    margin-left:auto!important;
    margin-right:auto!important;
    padding:0!important;
    gap:var(--v229-field-gap)!important;
    justify-content:center!important;
    justify-items:stretch!important;
    align-items:stretch!important;
    box-sizing:border-box!important;
    overflow-x:visible!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    width:100%!important;
    min-width:0!important;
    max-width:calc((var(--v216-card-w,129.789px) * 5) + (var(--v229-field-gap) * 4))!important;
    grid-template-columns:repeat(5,minmax(0,1fr))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    width:100%!important;
    min-width:0!important;
    max-width:calc((var(--v216-card-w,129.789px) * 4) + (var(--v229-field-gap) * 3))!important;
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    width:100%!important;
    min-width:0!important;
    max-width:calc((var(--v216-card-w,129.789px) * 3) + (var(--v229-field-gap) * 2))!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    width:100%!important;
    min-width:0!important;
    max-width:calc((var(--v216-card-w,129.789px) * 2) + var(--v229-field-gap))!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.base-unit{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    box-sizing:border-box!important;
  }
}

@media (min-width:851px){
  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    display:grid!important;
    grid-template-columns:401px minmax(0,1fr)!important;
    column-gap:0!important;
    gap:0!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:100vh!important;
    min-height:720px!important;
    margin:0!important;
    padding:4px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:calc(100vh - 8px)!important;
    min-height:0!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    overscroll-behavior-y:contain!important;
    touch-action:pan-y!important;
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel::-webkit-scrollbar{
    width:0!important;
    height:0!important;
    display:none!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    position:relative!important;
    flex:0 0 auto!important;
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:auto!important;
    min-height:100%!important;
    max-height:none!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout{
    display:block!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    justify-content:flex-start!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
    padding:8px 6px 20px!important;
    gap:6px!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-battle-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.enemy-hq-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.ally-hq-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>#enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>#allyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane[data-row]{
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane{
    overflow:visible!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    flex:0 0 var(--v216-card-w,129.789px)!important;
    width:var(--v216-card-w,129.789px)!important;
    min-width:var(--v216-card-w,129.789px)!important;
    max-width:var(--v216-card-w,129.789px)!important;
    height:var(--v216-card-h,201.894px)!important;
    min-height:var(--v216-card-h,201.894px)!important;
    max-height:var(--v216-card-h,201.894px)!important;
    aspect-ratio:2.7 / 4.2!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    --v230-field-gap:2px;
    display:grid!important;
    height:var(--v216-card-h,201.894px)!important;
    min-height:var(--v216-card-h,201.894px)!important;
    max-height:var(--v216-card-h,201.894px)!important;
    padding:0!important;
    gap:var(--v230-field-gap)!important;
    justify-content:center!important;
    justify-items:center!important;
    align-items:stretch!important;
    align-content:stretch!important;
    margin-left:auto!important;
    margin-right:auto!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,var(--v216-card-w,129.789px))!important;
    width:calc((var(--v216-card-w,129.789px) * 5) + (var(--v230-field-gap) * 4))!important;
    min-width:calc((var(--v216-card-w,129.789px) * 5) + (var(--v230-field-gap) * 4))!important;
    max-width:calc((var(--v216-card-w,129.789px) * 5) + (var(--v230-field-gap) * 4))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,var(--v216-card-w,129.789px))!important;
    width:calc((var(--v216-card-w,129.789px) * 4) + (var(--v230-field-gap) * 3))!important;
    min-width:calc((var(--v216-card-w,129.789px) * 4) + (var(--v230-field-gap) * 3))!important;
    max-width:calc((var(--v216-card-w,129.789px) * 4) + (var(--v230-field-gap) * 3))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,var(--v216-card-w,129.789px))!important;
    width:calc((var(--v216-card-w,129.789px) * 3) + (var(--v230-field-gap) * 2))!important;
    min-width:calc((var(--v216-card-w,129.789px) * 3) + (var(--v230-field-gap) * 2))!important;
    max-width:calc((var(--v216-card-w,129.789px) * 3) + (var(--v230-field-gap) * 2))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,var(--v216-card-w,129.789px))!important;
    width:calc((var(--v216-card-w,129.789px) * 2) + var(--v230-field-gap))!important;
    min-width:calc((var(--v216-card-w,129.789px) * 2) + var(--v230-field-gap))!important;
    max-width:calc((var(--v216-card-w,129.789px) * 2) + var(--v230-field-gap))!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.base-unit{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
    box-sizing:border-box!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v231-field-gap:2px;
    --v231-left-col-w:401px;
    
    --v231-battle-col-w:685px;
    --v231-app-w:1094px;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    display:grid!important;
    grid-template-columns:var(--v231-left-col-w) var(--v231-battle-col-w)!important;
    column-gap:0!important;
    gap:0!important;
    width:var(--v231-app-w)!important;
    min-width:var(--v231-app-w)!important;
    max-width:var(--v231-app-w)!important;
    height:100vh!important;
    min-height:720px!important;
    margin:0!important;
    padding:4px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    width:var(--v231-battle-col-w)!important;
    min-width:var(--v231-battle-col-w)!important;
    max-width:var(--v231-battle-col-w)!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    height:calc(100vh - 8px)!important;
    min-height:0!important;
    overflow-x:hidden!important;
    overflow-y:auto!important;
    overscroll-behavior-y:contain!important;
    touch-action:pan-y!important;
    scrollbar-width:none!important;
    -ms-overflow-style:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel::-webkit-scrollbar{
    width:0!important;
    height:0!important;
    display:none!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap{
    position:relative!important;
    flex:0 0 auto!important;
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:auto!important;
    min-height:100%!important;
    max-height:none!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout{
    display:block!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    justify-content:flex-start!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    margin:0!important;
    padding:8px 6px 20px!important;
    gap:6px!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-battle-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.hq-defense-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.enemy-hq-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.ally-hq-row,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>#enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>#allyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane[data-row]{
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
    overflow:visible!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    flex:0 0 var(--v216-card-w,129.789px)!important;
    width:var(--v216-card-w,129.789px)!important;
    min-width:var(--v216-card-w,129.789px)!important;
    max-width:var(--v216-card-w,129.789px)!important;
    height:var(--v216-card-h,201.894px)!important;
    min-height:var(--v216-card-h,201.894px)!important;
    max-height:var(--v216-card-h,201.894px)!important;
    aspect-ratio:2.7 / 4.2!important;
    box-sizing:border-box!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    display:grid!important;
    height:var(--v216-card-h,201.894px)!important;
    min-height:var(--v216-card-h,201.894px)!important;
    max-height:var(--v216-card-h,201.894px)!important;
    padding:0!important;
    gap:var(--v231-field-gap)!important;
    justify-content:center!important;
    justify-items:center!important;
    align-items:stretch!important;
    align-content:stretch!important;
    margin-left:auto!important;
    margin-right:auto!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,var(--v216-card-w,129.789px))!important;
    width:calc((var(--v216-card-w,129.789px) * 5) + (var(--v231-field-gap) * 4))!important;
    min-width:calc((var(--v216-card-w,129.789px) * 5) + (var(--v231-field-gap) * 4))!important;
    max-width:calc((var(--v216-card-w,129.789px) * 5) + (var(--v231-field-gap) * 4))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,var(--v216-card-w,129.789px))!important;
    width:calc((var(--v216-card-w,129.789px) * 4) + (var(--v231-field-gap) * 3))!important;
    min-width:calc((var(--v216-card-w,129.789px) * 4) + (var(--v231-field-gap) * 3))!important;
    max-width:calc((var(--v216-card-w,129.789px) * 4) + (var(--v231-field-gap) * 3))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,var(--v216-card-w,129.789px))!important;
    width:calc((var(--v216-card-w,129.789px) * 3) + (var(--v231-field-gap) * 2))!important;
    min-width:calc((var(--v216-card-w,129.789px) * 3) + (var(--v231-field-gap) * 2))!important;
    max-width:calc((var(--v216-card-w,129.789px) * 3) + (var(--v231-field-gap) * 2))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,var(--v216-card-w,129.789px))!important;
    width:calc((var(--v216-card-w,129.789px) * 2) + var(--v231-field-gap))!important;
    min-width:calc((var(--v216-card-w,129.789px) * 2) + var(--v231-field-gap))!important;
    max-width:calc((var(--v216-card-w,129.789px) * 2) + var(--v231-field-gap))!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.base-unit{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
    box-sizing:border-box!important;
  }
}

#hand.hand .card.item-stat-card .card-stat-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}
#hand.hand .card.item-stat-card .item-bonus-cell::before,#hand.hand .card.item-stat-card .item-bonus-cell::after{content:none!important;display:none!important}
#hand.hand .card.item-stat-card .item-bonus-cell b{font-size:15px!important;line-height:1!important;white-space:nowrap!important}

.unit,.advisor-card,.base-unit{position:relative!important}
.equipped-item-rail{position:absolute;left:3px;top:34px;z-index:75;display:flex;flex-direction:column;gap:4px;pointer-events:auto}
.advisor-card>.equipped-item-rail{top:7px;left:5px}
.base-unit>.equipped-item-rail{top:5px;left:5px}
.equipped-item-icon{display:grid;place-items:center;width:25px;height:25px;padding:0;border:1px solid rgba(255,255,255,.78);border-radius:50%;background:rgba(5,10,17,.9);box-shadow:0 2px 7px rgba(0,0,0,.7),inset 0 0 8px rgba(255,255,255,.08);color:#fff;font-size:15px;line-height:1;cursor:pointer;transition:transform .15s ease,filter .15s ease}
.equipped-item-icon svg{width:16px;height:16px;display:block;fill:currentColor}
.equipment-popover-icon svg{width:17px;height:17px;display:block;fill:currentColor}
.equipped-item-icon:hover,.equipped-item-icon:focus-visible{transform:scale(1.12);filter:brightness(1.22);outline:2px solid rgba(255,224,143,.9);outline-offset:1px}
.equipped-weapon{background:linear-gradient(145deg,rgba(94,25,20,.96),rgba(26,7,7,.96))}
.equipped-armor{background:linear-gradient(145deg,rgba(25,60,105,.96),rgba(8,20,42,.96))}
.equipped-mount{background:linear-gradient(145deg,rgba(86,58,21,.96),rgba(29,18,6,.96))}
.equipment-info-popover{position:fixed;z-index:10050;width:260px;max-width:calc(100vw - 16px);padding:9px;border:1px solid #d8b36b;border-radius:10px;background:linear-gradient(180deg,#172233,#090e16);box-shadow:0 14px 36px rgba(0,0,0,.72);color:#f6f2e8;font-size:12px}
.equipment-info-popover[hidden]{display:none!important}
.equipment-popover-title{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:1px 2px 7px;border-bottom:1px solid rgba(255,255,255,.14)}
.equipment-popover-title b{font-size:13px;color:#ffe7ad}
.equipment-popover-title button{width:24px;height:24px;border:0;border-radius:50%;background:#ffffff17;color:#fff;cursor:pointer}
.equipment-popover-row{display:grid;grid-template-columns:30px 1fr;gap:8px;align-items:center;padding:8px 6px;border-radius:7px}
.equipment-popover-row.active{background:rgba(255,211,117,.13);outline:1px solid rgba(255,211,117,.28)}
.equipment-popover-icon{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#05080e;border:1px solid #ffffff42;font-size:16px}
.equipment-popover-row b{display:block;color:#fff;font-size:12px}
.equipment-popover-row small{display:block;margin-top:2px;color:#becce0;font-size:10px}

.left-card-effect-stage .hq-card-scene.left-effect-preview-scene img{position:absolute!important;inset:0!important;margin:0!important;width:100%!important;height:100%!important;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;object-fit:cover!important;object-position:var(--scene-x,50%) var(--scene-y,50%)!important;transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene.fx-none img,.left-card-effect-stage .hq-card-scene.left-effect-preview-scene.holding img{animation:none!important;transform:scale(var(--scene-scale,1))!important;opacity:1!important;filter:none!important}

#batchSettingsModal[data-settings-mode="individual"] .event-hq-preview-frame{width:var(--individual-stage-hq-width,352px)!important;height:var(--individual-stage-hq-height,187px)!important;min-height:var(--individual-stage-hq-height,187px)!important}
#batchSettingsModal[data-settings-mode="individual"] .event-image-preview.event-hq-live-preview{min-height:calc(var(--individual-stage-hq-height,187px) + 12px)!important}

@media(max-width:850px){
 .equipped-item-rail{left:2px;top:29px;gap:3px}.equipped-item-icon{width:22px;height:22px;font-size:13px}
 .equipment-info-popover{width:238px}
}

#hand.hand .card.item-stat-card{grid-template-rows:20px minmax(0,1fr) auto!important;}
#hand.hand .card.item-stat-card .cimg{height:100%!important;min-height:0!important;max-height:none!important;padding:0!important;margin:0!important;border-bottom:1px solid #3d3024!important;background:#16110c!important;}
#hand.hand .card.item-stat-card .cimg img,#hand.hand .card.item-stat-card .cimg .default-art{display:block!important;width:100%!important;height:100%!important;object-fit:cover!important;}
#hand.hand .card.item-stat-card .cstats{display:block!important;padding:3px!important;}
#hand.hand .card.item-stat-card .card-stat-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:2px!important;}
#hand.hand .card.item-stat-card .card-stat-cell{display:flex!important;align-items:center!important;justify-content:center!important;min-height:30px!important;padding:3px 1px!important;}
#hand.hand .card.item-stat-card .card-stat-cell::before,#hand.hand .card.item-stat-card .card-stat-cell::after,#hand.hand .card.item-stat-card .card-stat-cell:nth-child(1)::before,#hand.hand .card.item-stat-card .card-stat-cell:nth-child(2)::before,#hand.hand .card.item-stat-card .card-stat-cell:nth-child(3)::before{content:none!important;display:none!important;}
#hand.hand .card.item-stat-card .item-bonus-cell b{font-size:14px!important;line-height:1!important;white-space:nowrap!important;color:#fff0bf!important;}
#hand.hand .card.item-stat-card .item-bonus-cell span{display:none!important;}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene img,.battlefield-card-scene img,.battle-hq .hq-card-scene img{position:absolute!important;inset:0!important;margin:0!important;width:100%!important;height:100%!important;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;object-fit:cover!important;object-position:var(--scene-x,50%) var(--scene-y,50%)!important;transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;}
.hq-card-scene.preview-static img,.left-card-effect-stage .hq-card-scene.left-effect-preview-scene.fx-none img,.left-card-effect-stage .hq-card-scene.left-effect-preview-scene.holding img{animation:none!important;transform:scale(var(--scene-scale,1))!important;opacity:1!important;filter:none!important;}

body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion{
  inset:0!important;
  clip-path:none!important;
  opacity:1!important;
  filter:none!important;
  transform:none!important;
}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene img,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion>img{
  position:absolute!important;
  inset:0!important;
  margin:0!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  max-width:none!important;
  max-height:none!important;
  object-fit:cover!important;
  object-position:var(--scene-x,50%) var(--scene-y,50%)!important;
  transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;
  animation:none!important;
  filter:none!important;
  opacity:1!important;
  transform:scale(var(--scene-scale,1))!important;
}

#hand.hand .card.item-stat-card .cstats{
  display:block!important;
  padding:3px!important;
  background:linear-gradient(180deg,#15110c,#0d0906)!important;
}
#hand.hand .card.item-stat-card .card-stat-cell{
  background:linear-gradient(180deg,rgba(52,35,18,.94),rgba(22,13,7,.96))!important;
  border:1px solid rgba(183,139,76,.55)!important;
  border-radius:4px!important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.06)!important;
}
#hand.hand .card.item-stat-card .card-stat-cell::before,
#hand.hand .card.item-stat-card .card-stat-cell::after,
#hand.hand .card.item-stat-card .card-stat-cell:nth-child(1)::before,
#hand.hand .card.item-stat-card .card-stat-cell:nth-child(2)::before,
#hand.hand .card.item-stat-card .card-stat-cell:nth-child(3)::before{
  content:none!important;
  display:none!important;
}
#hand.hand .card.item-stat-card .item-bonus-cell b{
  color:#f4d38c!important;
  text-shadow:0 1px 2px rgba(0,0,0,.9)!important;
  font-weight:900!important;
}
#hand.hand .card.item-stat-card .cimg{
  padding:0!important;
  overflow:hidden!important;
}
#hand.hand .card.item-stat-card .cimg img,
#hand.hand .card.item-stat-card .cimg .default-art{
  display:block!important;
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  transform:scale(1.035)!important;
  transform-origin:center center!important;
}

body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage{
  width:var(--individual-stage-hq-width,352px)!important;
  min-width:var(--individual-stage-hq-width,352px)!important;
  max-width:var(--individual-stage-hq-width,352px)!important;
  height:var(--individual-stage-hq-height,187px)!important;
  min-height:var(--individual-stage-hq-height,187px)!important;
  max-height:var(--individual-stage-hq-height,187px)!important;
  background:#02050a!important;
}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage>.hq-card-scene.left-effect-preview-scene{
  width:100%!important;min-width:0!important;max-width:none!important;
  height:100%!important;min-height:0!important;max-height:none!important;
  background:#02050a!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene img{
  object-fit:contain!important;
  background:#02050a!important;
}
#hand.hand .card.item-stat-card{
  overflow:hidden!important;
  gap:0!important;
  padding:0!important;
  box-sizing:border-box!important;
}
#hand.hand .card.item-stat-card .cimg{
  padding:0!important;
  margin:0!important;
  background:#15110c!important;
}
#hand.hand .card.item-stat-card .cimg img,#hand.hand .card.item-stat-card .cimg .default-art{
  display:block!important;
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
}
#hand.hand .card.item-stat-card .cstats{
  display:block!important;
  padding:4px!important;
  background:linear-gradient(180deg,#1d1710,#120d08)!important;
}
#hand.hand .card.item-stat-card .card-stat-grid{gap:2px!important;}
#hand.hand .card.item-stat-card .card-stat-cell{
  min-height:28px!important;
  padding:3px 1px!important;
  background:linear-gradient(180deg,#2c2114,#171108)!important;
  border:1px solid #7b5a28!important;
}
#hand.hand .card.item-stat-card .card-stat-cell b{
  color:#f2d48e!important;
  text-shadow:0 1px 2px rgba(0,0,0,.85)!important;
}

body #hand.hand .card.item-stat-card{grid-template-rows:20px minmax(0,1fr) 32px!important;align-items:stretch!important;}
body #hand.hand .card.item-stat-card .cimg{align-self:stretch!important;justify-self:stretch!important;height:auto!important;min-height:0!important;max-height:none!important;padding:0!important;margin:0!important;border-bottom:1px solid #3d3024!important;background:#16110c!important;overflow:hidden!important;}
body #hand.hand .card.item-stat-card .cstats{display:block!important;align-self:stretch!important;min-height:32px!important;max-height:32px!important;height:32px!important;padding:2px!important;margin:0!important;background:linear-gradient(180deg,#2f2545,#221a31)!important;overflow:hidden!important;}
body #hand.hand .card.item-stat-card .card-stat-grid{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:2px!important;height:100%!important;align-items:stretch!important;}
body #hand.hand .card.item-stat-card .card-stat-cell,body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell{display:flex!important;align-items:center!important;justify-content:center!important;min-height:0!important;height:100%!important;padding:0 1px!important;}
body #hand.hand .card.item-stat-card .card-stat-cell::before,body #hand.hand .card.item-stat-card .card-stat-cell::after,body #hand.hand .card.item-stat-card .card-stat-cell:nth-child(1)::before,body #hand.hand .card.item-stat-card .card-stat-cell:nth-child(2)::before,body #hand.hand .card.item-stat-card .card-stat-cell:nth-child(3)::before,body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell::before,body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell::after,body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell:nth-child(1)::before,body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell:nth-child(2)::before,body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .card-stat-cell:nth-child(3)::before{content:none!important;display:none!important;}
body #hand.hand .card.item-stat-card .item-bonus-cell b,body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .item-bonus-cell b{display:block!important;font-size:13px!important;line-height:1!important;white-space:nowrap!important;color:#e8d496!important;text-shadow:none!important;}
body #hand.hand .card.item-stat-card .item-bonus-cell span{display:none!important;}
body #hand.hand .card.item-stat-card .card-image-grade{top:3px!important;left:3px!important;}

body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage{background:#04080e!important;}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene{background:#04080e!important;}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion{position:absolute!important;inset:0!important;overflow:hidden!important;transform:none!important;clip-path:none!important;opacity:1!important;filter:none!important;}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene img{position:absolute!important;inset:0!important;margin:0!important;width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;object-fit:cover!important;object-position:var(--scene-x,50%) var(--scene-y,50%)!important;transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;animation:none!important;filter:none!important;opacity:1!important;transform:scale(var(--scene-scale,1))!important;}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-shade,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-energy,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-particles{display:none!important;}

body #hand.hand .card.item-stat-card .item-bonus-cell b,
body.unified-left-layout:not(.ui-mode-mobile-preview) #hand.hand .card.item-stat-card .item-bonus-cell b,
body.ui-mode-mobile #hand.hand .card.item-stat-card .item-bonus-cell b,
body.ui-mode-mobile-preview #hand.hand .card.item-stat-card .item-bonus-cell b{
  color:#111!important;
  text-shadow:none!important;
  font-weight:950!important;
}

body #hand.hand .card .card-stat-grid{
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-auto-flow:column!important;
}
body #hand.hand .card .card-stat-cell,
body #hand.hand .card .card-stat-cell:last-child,
body #hand.hand .card.item .card-stat-cell:last-child,
body #hand.hand .card.item-stat-card .card-stat-cell:last-child,
body #hand.hand .card.advisor-card-hand .card-stat-cell:last-child{
  grid-column:auto!important;
  grid-row:auto!important;
  min-width:0!important;
  overflow:visible!important;
}
body #hand.hand .card:not(.utility-card) .cstats{overflow:visible!important;}
body #hand.hand .card:not(.utility-card) .card-stat-grid{overflow:visible!important;}
body #hand.hand .card:not(.utility-card) .card-stat-cell b{
  display:block!important;
  min-width:0!important;
  overflow:visible!important;
}

#cardShopGrid .shop-card .collection-card-title,
#cardShopGrid .shop-card .collection-card-name{
  width:100%!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  text-align:center!important;
}
#cardShopGrid .shop-card .collection-card-title b,
#cardShopGrid .shop-card .collection-card-name{
  font-size:clamp(15px,1.05vw,20px)!important;
  line-height:1.15!important;
  font-weight:950!important;
  letter-spacing:-.02em!important;
  text-align:center!important;
}
.individual-animation-toggle{
  display:inline-flex!important;align-items:center;gap:7px;padding:8px 11px;
  border:1px solid rgba(196,151,75,.55);border-radius:8px;background:rgba(30,22,13,.72);
  font-weight:800;white-space:nowrap;
}
.individual-animation-toggle input,#mgrCardAnimationEnabled{accent-color:#d29a42;}

.v239-advisor-skill-wrap{display:contents}
.poison-status-badge{position:absolute;right:4px;bottom:24px;z-index:9;padding:2px 5px;border-radius:999px;background:rgba(75,20,105,.9);color:#fff;font-size:10px;font-weight:800;box-shadow:0 1px 4px rgba(0,0,0,.45)}

.v240-art-shell{position:relative;display:block;width:100%;height:100%;min-width:0;min-height:0;overflow:hidden;line-height:0}
.v240-art-shell>.card-art-img,.v240-art-shell>.unit-art-img,.v240-art-shell>.configured-default-art,.v240-art-shell>.auto-folder-art,.v240-art-shell>.default-art{width:100%!important;height:100%!important;display:block!important;object-fit:cover!important}
.v240-role-icons{position:absolute;left:5px;bottom:5px;z-index:9;display:inline-flex;align-items:center;gap:2px;min-height:20px;padding:2px 5px;border-radius:7px;background:rgba(5,8,12,.80);border:1px solid rgba(255,226,157,.78);box-shadow:0 1px 4px rgba(0,0,0,.65);font-size:14px;line-height:1;pointer-events:none;white-space:nowrap}
.v240-role-glyph{display:inline-flex;align-items:center;justify-content:center;min-width:15px;height:16px;line-height:16px;filter:drop-shadow(0 1px 1px rgba(0,0,0,.8))}
.card .v240-role-icons{left:4px;bottom:4px;font-size:13px;min-height:18px;padding:2px 4px}
.uimg .v240-role-icons,.base-unit-art .v240-role-icons{left:3px;bottom:3px;font-size:11px;min-height:16px;padding:1px 3px;border-radius:5px}
.collection-card-art .v240-role-icons{left:5px;bottom:5px;font-size:13px}
.manager-preview .v240-art-shell,.card-zoom-art .v240-art-shell,.advisor-portrait .v240-art-shell,.roster-art .v240-art-shell,.base-unit-art .v240-art-shell{width:100%!important;height:100%!important}
.card-zoom-art .v240-art-shell{min-height:430px}
#endText{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;text-align:center}
#endText>b{font-size:32px;line-height:1.1}
#endText>span{font-size:14px;font-weight:700;opacity:.9}
#endText[data-result="win"]>b{color:#ffe39a}
#endText[data-result="lose"]>b{color:#ffb0a8}
#endText[data-result="draw"]>b{color:#d5d8df}
@media(max-width:760px){
  .v240-role-icons{left:3px;bottom:3px;font-size:11px;min-height:16px;padding:1px 3px;gap:1px}
  .card-zoom-art .v240-art-shell{min-height:340px}
}

.left-card-effect-card.action-view-mode .left-card-effect-title,
.left-card-effect-stage-badge,
.left-card-effect-stage .hq-card-scene .scene-label,
.left-card-effect-stage .hq-card-scene .scene-effect-caption,
.battlefield-card-scene .scene-label,
.battlefield-card-scene .scene-effect-caption,
.battle-hq .hq-card-scene:not(.stage-preview) .scene-label,
.battle-hq .hq-card-scene:not(.stage-preview) .scene-effect-caption{
  display:none!important;
}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-card.action-view-mode,
.left-card-effect-card.action-view-mode{
  grid-template-rows:minmax(0,1fr)!important;
  gap:0!important;
}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage,
.left-card-effect-stage{
  padding:0!important;
  overflow:hidden!important;
  background:#04080e!important;
}
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage>.hq-card-scene.left-effect-preview-scene,
.left-card-effect-stage>.hq-card-scene.left-effect-preview-scene{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  max-width:none!important;
  max-height:none!important;
  margin:0!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion,
.battlefield-card-scene .scene-entry-motion,
.battle-hq .hq-card-scene:not(.stage-preview) .scene-entry-motion{
  position:absolute!important;
  inset:0!important;
  overflow:hidden!important;
  clip-path:none!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene img,
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion>img,
.battlefield-card-scene img,
.battlefield-card-scene .scene-entry-motion>img,
.battle-hq .hq-card-scene:not(.stage-preview) img,
.battle-hq .hq-card-scene:not(.stage-preview) .scene-entry-motion>img{
  position:absolute!important;
  inset:0!important;
  margin:0!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  max-width:none!important;
  max-height:none!important;
  object-fit:cover!important;
  object-position:var(--scene-x,50%) var(--scene-y,50%)!important;
  transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;
}

.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-shade,
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-energy,
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-particles{
  display:block!important;
}

.deck-builder-name-input{min-width:170px!important}
.deck-auto-ratio-inline,
.deck-auto-ratio-inline label,
.deck-auto-ratio-inline button{
  font-size:14px!important;
}
.deck-auto-ratio-inline label{
  font-weight:900!important;
  color:#f7e6b5!important;
}
.deck-auto-ratio-inline input{
  font-size:15px!important;
  font-weight:900!important;
  min-height:31px!important;
}

.deck-builder-visual-card .collection-card-icons .collection-type-icon,
.deck-builder-visual-card .collection-card-icons .collection-soldier-icon,
.card-shop-grid .collection-card-icons .collection-type-icon,
.card-shop-grid .collection-card-icons .collection-soldier-icon{
  display:none!important;
}

.unit.v241-burning .uimg{
  box-shadow:0 0 0 1px #ffcc7730,0 0 22px #ff7b2d66!important;
}
.unit.v241-burning .uimg::before{
  content:'';
  position:absolute;
  left:3%;right:3%;bottom:-1px;height:31%;
  pointer-events:none;z-index:12;
  background:
    radial-gradient(ellipse at 12% 100%,#fff7c7 0 7%,#ffc14d 11%,#ff6e20 25%,transparent 45%),
    radial-gradient(ellipse at 35% 100%,#fff3ac 0 8%,#ffa936 14%,#ff4d14 33%,transparent 51%),
    radial-gradient(ellipse at 60% 100%,#fff8c7 0 7%,#ffc54b 13%,#ff6c1d 29%,transparent 49%),
    radial-gradient(ellipse at 82% 100%,#ffeaa0 0 7%,#ff9a2a 14%,#ff4718 32%,transparent 50%),
    radial-gradient(ellipse at 96% 100%,#fff2aa 0 6%,#ffb23a 13%,#ff5b18 30%,transparent 48%);
  filter:drop-shadow(0 0 9px #ff8a2a);
  animation:v241FireLick .72s ease-in-out infinite alternate;
}
.unit.v241-burning .uimg::after{
  content:'';
  position:absolute;
  left:7%;right:7%;bottom:14%;height:34%;
  pointer-events:none;z-index:11;
  background:linear-gradient(180deg,transparent,#ffb34a55 52%,#ff541c2d 100%);
  filter:blur(7px);
  animation:v241HeatWave .2s linear infinite alternate;
}
@keyframes v241FireLick{from{transform:translateY(7%) scaleY(.84) skewX(-1deg)}to{transform:translateY(-7%) scaleY(1.18) skewX(1deg)}}
@keyframes v241HeatWave{from{transform:skewX(-1.4deg) translateX(-1px)}to{transform:skewX(1.4deg) translateX(1px)}}

.v241-electric-arc{
  position:fixed;width:104px;height:104px;pointer-events:none;z-index:10003;
  transform:translate(-50%,-50%);
}
.v241-electric-arc::before,.v241-electric-arc::after{
  content:'';position:absolute;inset:7px;border-radius:50%;
  border:2px solid rgba(210,248,255,.92);
  box-shadow:0 0 10px #fff,0 0 24px #70d8ff,inset 0 0 16px #b5edff;
  clip-path:polygon(50% 0,60% 19%,80% 8%,72% 37%,100% 48%,75% 61%,91% 86%,61% 76%,50% 100%,39% 75%,10% 88%,25% 60%,0 50%,26% 39%,14% 12%,40% 22%);
  animation:v241ElectricArc .72s steps(2,end) forwards;
}
.v241-electric-arc::after{inset:20px;opacity:.8;animation-delay:.07s;transform:rotate(25deg)}
@keyframes v241ElectricArc{0%{opacity:0;transform:scale(.25) rotate(-20deg)}18%{opacity:1}55%{opacity:.92}100%{opacity:0;transform:scale(1.35) rotate(28deg)}}

.v241-fire-burst{
  position:fixed;width:132px;height:132px;pointer-events:none;z-index:10003;
  transform:translate(-50%,-50%);
}
.v241-fire-burst::before,.v241-fire-burst::after{
  content:'';position:absolute;left:50%;bottom:4px;width:112px;height:112px;transform:translateX(-50%);
  background:radial-gradient(circle at 50% 88%,#fff7c8 0 8%,#ffc54b 16%,#ff6a1e 35%,rgba(142,15,0,.45) 56%,transparent 74%);
  filter:drop-shadow(0 0 12px #ff6a1d);
  clip-path:polygon(50% 0,60% 13%,69% 28%,82% 15%,76% 43%,95% 37%,84% 60%,100% 73%,76% 70%,84% 98%,61% 82%,50% 100%,38% 82%,15% 98%,24% 70%,0 73%,17% 59%,6% 38%,24% 43%,17% 15%,31% 28%,39% 13%);
  animation:v241FireBurst .86s ease-out forwards;
}
.v241-fire-burst::after{width:62px;height:84px;bottom:18px;opacity:.86;animation-delay:.06s}
@keyframes v241FireBurst{0%{opacity:0;transform:translateX(-50%) scale(.3) translateY(14px)}22%{opacity:1}100%{opacity:0;transform:translateX(-50%) scale(1.35) translateY(-22px)}}

.v241-gust{
  position:fixed;width:164px;height:96px;pointer-events:none;z-index:10003;
  transform:translate(-50%,-50%);
}
.v241-gust::before,.v241-gust::after{
  content:'';position:absolute;inset:0;border-radius:50%;
  border-top:4px solid rgba(222,250,255,.98);
  border-bottom:4px solid rgba(105,190,231,.76);
  border-left:5px solid transparent;border-right:5px solid transparent;
  filter:drop-shadow(0 0 8px #86ddff);
  animation:v241GustSpin .84s ease-out forwards;
}
.v241-gust::after{inset:17px 12px 20px 18px;opacity:.82;animation-delay:.05s}
@keyframes v241GustSpin{0%{opacity:0;transform:rotate(-55deg) scale(.2)}22%{opacity:1}100%{opacity:0;transform:rotate(205deg) scale(1.2)}}
.unit.v241-wind-hit{animation:v241WindHit .56s ease-out}
@keyframes v241WindHit{0%{transform:translateX(0)}18%{transform:translateX(-8px) rotate(-1.2deg)}40%{transform:translateX(10px) rotate(1.5deg)}68%{transform:translateX(-4px)}100%{transform:translateX(0)}}

.left-card-effect-title,
.left-card-effect-title *,
.left-card-effect-stage-badge,
.left-card-effect-stage .scene-label,
.left-card-effect-stage .scene-effect-caption{
  display:none!important;
  visibility:hidden!important;
  opacity:0!important;
  max-height:0!important;
  overflow:hidden!important;
}

.left-card-effect-body{
  padding:0!important;
}
.left-card-effect-card.action-view-mode,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-card.action-view-mode{
  display:grid!important;
  grid-template-rows:minmax(0,1fr)!important;
  gap:0!important;
  height:100%!important;
  min-height:0!important;
  padding:0!important;
  margin:0!important;
}
.left-card-effect-stage,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage{
  position:relative!important;
  width:100%!important;
  height:100%!important;
  min-height:0!important;
  margin:0!important;
  padding:0!important;
  overflow:hidden!important;
  background:#04080e!important;
  line-height:0!important;
}

.left-card-effect-stage > .hq-card-scene.left-effect-preview-scene,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage > .hq-card-scene.left-effect-preview-scene{
  position:absolute!important;
  inset:-2px!important;
  width:calc(100% + 4px)!important;
  height:calc(100% + 4px)!important;
  min-width:0!important;
  min-height:0!important;
  max-width:none!important;
  max-height:none!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  overflow:hidden!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion{
  position:absolute!important;
  inset:0!important;
  margin:0!important;
  padding:0!important;
  overflow:hidden!important;
  clip-path:none!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene img,
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion > img{
  position:absolute!important;
  inset:0!important;
  margin:0!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  max-width:none!important;
  max-height:none!important;
  object-fit:cover!important;
  object-position:var(--scene-x,50%) var(--scene-y,50%)!important;
  transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;
}

.battle-hq .hq-advisor-slot .advisor-slot-badge,
body.ui-mode-mobile .hq-advisor-slot .advisor-slot-badge,
body.ui-mode-mobile-preview .hq-advisor-slot .advisor-slot-badge{
  box-sizing:border-box!important;
  min-height:22px!important;
  height:22px!important;
  padding:2px 5px 4px!important;
  display:flex!important;
  align-items:flex-end!important;
  justify-content:center!important;
  gap:4px!important;
  overflow:hidden!important;
}
.battle-hq .hq-advisor-slot .advisor-slot-badge b,
body.ui-mode-mobile .hq-advisor-slot .advisor-slot-badge b,
body.ui-mode-mobile-preview .hq-advisor-slot .advisor-slot-badge b{
  display:block!important;
  width:100%!important;
  line-height:1.18!important;
  padding-bottom:1px!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  text-align:center!important;
  font-size:10px!important;
}
.battle-hq .hq-advisor-slot .advisor-slot-badge span,
body.ui-mode-mobile .hq-advisor-slot .advisor-slot-badge span,
body.ui-mode-mobile-preview .hq-advisor-slot .advisor-slot-badge span{
  line-height:1.1!important;
}

.left-card-effect-section,
.left-card-effect-body,
.left-card-effect-card.action-view-mode,
.left-card-effect-stage{
  padding:0!important;
}
.left-card-effect-stage,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage{
  margin:0!important;
  border:0!important;
  outline:0!important;
  overflow:hidden!important;
  background:#000!important;
}
.left-card-effect-stage > .hq-card-scene.left-effect-preview-scene,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage > .hq-card-scene.left-effect-preview-scene{
  position:absolute!important;
  inset:-4px!important;
  width:calc(100% + 8px)!important;
  height:calc(100% + 8px)!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  outline:0!important;
  box-shadow:none!important;
  overflow:hidden!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion{
  position:absolute!important;
  inset:-2px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  overflow:hidden!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene img,
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion > img{
  position:absolute!important;
  inset:-4px!important;
  width:calc(100% + 8px)!important;
  height:calc(100% + 8px)!important;
  margin:0!important;
  min-width:0!important;
  min-height:0!important;
  max-width:none!important;
  max-height:none!important;
  object-fit:cover!important;
  object-position:var(--scene-x,50%) var(--scene-y,50%)!important;
  transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;
}

.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-shade,
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-energy,
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-particles{
  position:absolute!important;
  inset:0!important;
  margin:0!important;
}

body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot{
  position:relative!important;
  align-self:stretch!important;
  padding:0!important;
  overflow:hidden!important;
}
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot > .hq-advisor-slot,
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot > .advisor{
  position:relative!important;
  inset:auto!important;
  display:block!important;
  box-sizing:border-box!important;
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  height:100%!important;
  min-height:100%!important;
  max-height:100%!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:inherit!important;
  overflow:hidden!important;
  background:transparent!important;
}
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-card,
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-image-only{
  position:relative!important;
  display:block!important;
  box-sizing:border-box!important;
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  height:100%!important;
  min-height:100%!important;
  max-height:100%!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  overflow:hidden!important;
}

body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-portrait{
  position:absolute!important;
  inset:0!important;
  display:block!important;
  box-sizing:border-box!important;
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  height:100%!important;
  min-height:100%!important;
  max-height:100%!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  overflow:hidden!important;
}
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-portrait > img,
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-portrait > .default-art,
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-portrait > svg,
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-portrait .v240-art-shell,
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-portrait .v240-art-shell > img{
  display:block!important;
  box-sizing:border-box!important;
  width:100%!important;
  min-width:100%!important;
  max-width:100%!important;
  height:100%!important;
  min-height:100%!important;
  max-height:100%!important;
  margin:0!important;
  padding:0!important;
  object-fit:cover!important;
  object-position:center top!important;
}

body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-slot-badge{
  position:absolute!important;
  left:0!important;
  right:0!important;
  top:auto!important;
  bottom:0!important;
  z-index:20!important;
  box-sizing:border-box!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:100%!important;
  height:24px!important;
  min-height:24px!important;
  max-height:24px!important;
  margin:0!important;
  padding:3px 5px 4px!important;
  overflow:hidden!important;
  background:linear-gradient(180deg,rgba(4,7,11,.18),rgba(4,7,11,.96))!important;
  border:0!important;
  border-top:1px solid rgba(213,170,98,.8)!important;
}
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-slot-badge b{
  display:block!important;
  width:100%!important;
  min-width:0!important;
  margin:0!important;
  padding:0!important;
  color:#fff3d5!important;
  font-size:10px!important;
  font-weight:900!important;
  line-height:16px!important;
  text-align:center!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}
body:not(.prebattle) .hq-defense-lane .hq-advisor-field-slot .advisor-slot-badge span{
  display:none!important;
}

.v245-art-shell{
  position:relative!important;
  display:block!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  overflow:hidden!important;
  line-height:0!important;
}
.v245-art-shell>.v240-art-shell,
.v245-art-shell>img,
.v245-art-shell>.configured-default-art,
.v245-art-shell>.auto-folder-art,
.v245-art-shell>.default-art{
  width:100%!important;
  height:100%!important;
  display:block!important;
}
.v245-action-icon-rail{
  position:absolute!important;
  right:4px!important;
  bottom:4px!important;
  z-index:34!important;
  display:inline-flex!important;
  flex-direction:row!important;
  align-items:center!important;
  justify-content:flex-end!important;
  gap:3px!important;
  pointer-events:none!important;
  line-height:1!important;
}
.v245-buff-skill-icon{
  display:grid!important;
  place-items:center!important;
  width:20px!important;
  height:20px!important;
  min-width:20px!important;
  padding:0!important;
  border:1px solid rgba(127,242,220,.95)!important;
  border-radius:6px!important;
  background:rgba(5,66,59,.92)!important;
  color:#d9fff8!important;
  box-shadow:0 1px 4px rgba(0,0,0,.8)!important;
  font-size:14px!important;
  font-weight:1000!important;
  text-shadow:0 1px 2px #000!important;
}

.battlefield-layout .unit .unit-buff-box,
#hand.hand .card .hand-buff-provider-badge{display:none!important;}

.battlefield-layout .unit .v245-action-icon-rail{right:3px!important;bottom:3px!important;gap:2px!important;}
.battlefield-layout .unit .v245-buff-skill-icon{width:16px!important;height:16px!important;min-width:16px!important;font-size:11px!important;border-radius:4px!important;}
.base-unit-art .v245-action-icon-rail{right:3px!important;bottom:3px!important;}
.base-unit-art .v245-buff-skill-icon{width:17px!important;height:17px!important;min-width:17px!important;font-size:11px!important;}
@media(max-width:850px){
  .v245-action-icon-rail{right:3px!important;bottom:3px!important;}
  .v245-buff-skill-icon{width:17px!important;height:17px!important;min-width:17px!important;font-size:11px!important;border-radius:4px!important;}
}

.left-card-effect-body,
.left-card-effect-card.action-view-mode,
.left-card-effect-stage{
  padding:0!important;
  margin:0!important;
  gap:0!important;
}
.left-card-effect-stage,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage{
  position:relative!important;
  width:100%!important;
  height:100%!important;
  min-height:0!important;
  overflow:hidden!important;
  border:0!important;
  outline:0!important;
  background:#000!important;
  line-height:0!important;
}
.left-card-effect-stage>.hq-card-scene.left-effect-preview-scene,
body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-stage>.hq-card-scene.left-effect-preview-scene{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  max-width:none!important;
  max-height:none!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  outline:0!important;
  box-shadow:none!important;
  overflow:hidden!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  overflow:hidden!important;
}
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene img,
.left-card-effect-stage .hq-card-scene.left-effect-preview-scene .scene-entry-motion>img{
  position:absolute!important;
  inset:0!important;
  display:block!important;
  width:100%!important;
  height:100%!important;
  min-width:100%!important;
  min-height:100%!important;
  max-width:none!important;
  max-height:none!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  object-fit:cover!important;
  object-position:var(--scene-x,50%) var(--scene-y,50%)!important;
  transform-origin:var(--scene-x,50%) var(--scene-y,50%)!important;
}

.slot.attackable.v246-bright-attack-target,
body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.attackable.v246-bright-attack-target{
  outline:3px solid #ff5f67!important;
  outline-offset:2px!important;
  box-shadow:0 0 0 3px rgba(255,75,86,.42),0 0 24px rgba(255,68,82,.9),inset 0 0 18px rgba(255,88,96,.28)!important;
  background:rgba(126,16,26,.24)!important;
}
.slot.attackable.v246-bright-attack-target .unit{
  filter:brightness(1.3) saturate(1.24)!important;
  box-shadow:0 0 18px rgba(255,92,99,.9),0 6px 14px rgba(0,0,0,.55)!important;
}

.slot.supportable.v246-bright-buff-target,
body.unified-left-layout:not(.ui-mode-mobile-preview) .slot.supportable.v246-bright-buff-target,
.hq-field-slot.supportable.v246-bright-buff-target{
  outline:3px solid #62ffe1!important;
  outline-offset:2px!important;
  box-shadow:0 0 0 3px rgba(75,255,221,.42),0 0 25px rgba(73,255,219,.88),inset 0 0 18px rgba(88,255,222,.25)!important;
  background:rgba(17,122,105,.2)!important;
}
.slot.supportable.v246-bright-buff-target .unit,
.hq-field-slot.supportable.v246-bright-buff-target .unit{
  filter:brightness(1.32) saturate(1.18)!important;
  box-shadow:0 0 19px rgba(86,255,226,.88),0 6px 14px rgba(0,0,0,.5)!important;
}
.slot.supportable.v246-bright-buff-target::before,
.hq-field-slot.supportable.v246-bright-buff-target::before{
  content:'버프 가능'!important;
  background:rgba(0,92,78,.96)!important;
  border-color:#7affea!important;
  color:#edfffb!important;
  box-shadow:0 0 10px rgba(87,255,226,.55)!important;
}

#deckBuilderBuffFilter,#cardShopBuffFilter{min-width:92px!important;}
.deck-builder-toolbar .v246-buff-filter-label,
.card-shop-toolbar .v246-buff-filter-label{white-space:nowrap!important;}

.deck-auto-ratio-inline input[type=number],
#deckRatioGeneral,#deckRatioAdvisor,#deckRatioItem,#deckRatioTactic{
  width:58px!important;
  min-width:58px!important;
  max-width:68px!important;
  padding-left:7px!important;
  padding-right:7px!important;
  box-sizing:border-box!important;
  text-align:center!important;
  font-variant-numeric:tabular-nums!important;
}
#deckBuilderAutoBtn{min-width:58px!important;}

@media(max-width:850px){
  .deck-auto-ratio-inline input[type=number],
  #deckRatioGeneral,#deckRatioAdvisor,#deckRatioItem,#deckRatioTactic{width:60px!important;min-width:60px!important;}
  #deckBuilderBuffFilter,#cardShopBuffFilter{min-width:0!important;width:100%!important;}
}

#allyAdvisorConsole .v246-advisor-buff-skill{
  border-color:#62ffe1!important;
  box-shadow:inset 0 0 12px rgba(70,255,220,.12),0 0 8px rgba(70,255,220,.18)!important;
}
#allyAdvisorConsole .v246-advisor-buff-skill:not(:disabled) b{color:#bffff3!important;}

.v246-filter-hidden{display:none!important;}

.collection-card-art{ position:relative; }
.collection-score-badge{
  position:absolute;
  right:27px;
  top:4px;
  z-index:9;
  display:grid;
  place-items:center;
  width:20px;
  height:20px;
  border-radius:50%;
  border:1px solid var(--v218-gold-soft,#c6a25a);
  background:color-mix(in srgb, var(--v218-deep,#111) 88%, transparent);
  color:#9be27a;
  font-family:"Malgun Gothic","Apple SD Gothic Neo",sans-serif;
  font-size:11px;
  font-weight:1000;
  line-height:1;
  text-shadow:0 1px 2px #000;
  pointer-events:none;
}
@media (max-width:850px){
  .collection-score-badge{ right:24px; top:3px; width:16px; height:16px; font-size:9px; }
}

#skillEditorModal .manager-head-actions{ display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.skill-editor-search{
  padding:6px 10px;
  border-radius:8px;
  border:1px solid rgba(255,255,255,.22);
  background:rgba(0,0,0,.25);
  color:inherit;
  font-size:13px;
  min-width:180px;
}
.skill-editor-summary{
  padding:4px 16px 0;
  font-size:12px;
  opacity:.75;
}

#skillEditorModal .skill-editor-tabs button{ display:flex; flex-direction:column; align-items:center; gap:2px; line-height:1.2; }
#skillEditorModal .skill-editor-tabs button small{ font-size:10px; opacity:.75; font-weight:400; }
#skillEditorModal .skill-editor-tabs button.active small{ opacity:.9; }

.skill-tier-group{ display:flex; flex-direction:column; gap:8px; margin-bottom:4px; }
.skill-tier-group-head{
  display:flex;
  align-items:center;
  gap:8px;
  padding:6px 2px 2px;
  border-bottom:1px solid rgba(255,255,255,.1);
}
.skill-tier-group-head small{ opacity:.65; font-size:11px; }

.skill-edit-card{ position:relative; transition:border-color .15s; }
.skill-edit-card.modified{ border-color:#c6a25a; background:rgba(198,162,90,.08); }
.skill-modified-dot{
  font-size:10px;
  padding:1px 6px;
  border-radius:999px;
  background:rgba(198,162,90,.25);
  border:1px solid #c6a25a;
  color:#f2d9a0;
  margin-left:2px;
}
.skill-edit-noparam{ opacity:.6; font-size:12px; }
.skill-editor-empty{ padding:24px 12px; text-align:center; opacity:.7; font-size:13px; }

.collection-score-badge{
  right:6px;
  top:27px;
  width:15px;
  height:15px;
  border-width:1px;
  font-size:8px;
  line-height:1;
}

@media (max-width:850px){
  .collection-score-badge{
    right:5px;
    top:23px;
    width:12px;
    height:12px;
    font-size:7px;
  }
}

.sss-effect-panel{display:none!important}
#boosterPackModal .modalbox{max-width:1080px;width:min(96vw,1080px);max-height:90vh;overflow:auto}

.v256-unified-skill-field{border:1px solid rgba(198,162,90,.34);background:rgba(198,162,90,.06);padding:10px;border-radius:10px}
.v256-unified-skill-field label small{opacity:.65;margin-left:6px;font-weight:400}
.v256-skill-info{font-size:12px;line-height:1.55;margin-top:7px;padding:8px 10px;border-radius:8px;background:rgba(0,0,0,.18)}
.v256-skill-info span{opacity:.72}
.v256-booster-tabs{display:flex;gap:8px;padding:10px 14px 0}
.v256-booster-tabs .active{box-shadow:0 0 0 1px rgba(255,255,255,.15) inset}
.v256-enhancement-panel{display:none;padding:12px 14px 16px}
.v256-enhancement-panel.active{display:block}
.v256-enhance-toolbar{display:flex;gap:8px;margin-bottom:10px}
.v256-enhance-toolbar input{flex:1;min-width:160px}
.v256-enhance-toolbar input,.v256-enhance-toolbar select{padding:8px 10px;border-radius:8px;border:1px solid rgba(255,255,255,.18);background:rgba(0,0,0,.22);color:inherit}
.v256-enhance-layout{display:grid;grid-template-columns:minmax(250px,38%) 1fr;gap:12px;min-height:430px}
.v256-enhance-card-list{overflow:auto;max-height:62vh;border:1px solid rgba(255,255,255,.12);border-radius:10px;padding:6px;background:rgba(0,0,0,.12)}
.v256-enhance-card-row{width:100%;display:grid;grid-template-columns:1fr auto;grid-template-areas:"name grade" "name owned";align-items:center;gap:2px 8px;text-align:left;padding:9px 10px;margin:0 0 5px;border-radius:9px;border:1px solid rgba(255,255,255,.1);background:rgba(255,255,255,.035);color:inherit;cursor:pointer}
.v256-enhance-card-row:hover,.v256-enhance-card-row.selected{border-color:#c6a25a;background:rgba(198,162,90,.13)}
.v256-enhance-card-row>span:first-child{grid-area:name;display:flex;flex-direction:column;gap:3px}
.v256-enhance-card-row small{font-size:10.5px;opacity:.65}
.v256-enhance-card-row .v256-grade{grid-area:grade;font-weight:900;color:#f0c96c;text-align:right}
.v256-enhance-card-row .v256-owned{grid-area:owned;font-size:10.5px;opacity:.75;text-align:right}
.v256-enhance-detail{border:1px solid rgba(255,255,255,.13);border-radius:10px;padding:12px;display:flex;flex-direction:column;gap:10px;background:rgba(0,0,0,.12)}
.v256-enhance-detail-inner{flex:1}
.v256-detail-title{display:flex;justify-content:space-between;align-items:center;padding-bottom:9px;border-bottom:1px solid rgba(255,255,255,.12);font-size:17px}
.v256-detail-title span{font-weight:900;color:#f0c96c}
.v256-detail-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:10px}
.v256-detail-grid>div{display:flex;flex-direction:column;gap:4px;padding:9px;border-radius:8px;background:rgba(255,255,255,.04)}
.v256-detail-grid .full{grid-column:1/-1}
.v256-detail-grid small{opacity:.65}
.v256-detail-grid b{font-size:12.5px;line-height:1.55}
.v256-detail-grid em{font-style:normal;color:#80d99a}
.v256-rule-box{margin-top:10px;padding:10px;border:1px solid rgba(198,162,90,.35);border-radius:9px;display:flex;flex-wrap:wrap;gap:7px 12px;align-items:center;background:rgba(198,162,90,.07);font-size:12px}
.v256-rule-box b{font-size:15px;color:#f0c96c}
.v256-rule-box strong{color:#82e49b}
.v256-rule-box small{flex-basis:100%;opacity:.72}
.v256-rule-box.max{border-color:rgba(255,215,80,.4)}
.v256-material{margin-top:9px;font-size:12px;opacity:.88}
.v256-enhance-result{border-radius:10px;padding:11px;border:1px solid rgba(255,255,255,.13);background:rgba(0,0,0,.16);font-size:12px}
.v256-enhance-result:empty{display:none}
.v256-enhance-result.success{border-color:rgba(80,220,120,.45);background:rgba(80,220,120,.08)}
.v256-enhance-result.fail{border-color:rgba(240,95,95,.42);background:rgba(240,95,95,.07)}
.v256-result-head{font-size:18px;font-weight:900;margin-bottom:7px}
.v256-enhance-result.success .v256-result-head{color:#82e49b}
.v256-enhance-result.fail .v256-result-head{color:#ff9a9a}
.v256-result-line{display:flex;justify-content:space-between;padding:4px 0;border-bottom:1px dashed rgba(255,255,255,.08)}
.v256-result-line span{opacity:.7}
.v256-result-skill{padding:7px 0;display:grid;grid-template-columns:60px 1fr;gap:5px}
.v256-result-skill>span{opacity:.7}
.v256-result-skill small{grid-column:2;opacity:.72}
.v256-arrow{color:#f0c96c;padding:0 4px}
.v256-result-material{text-align:right;margin-top:6px;opacity:.7}
.v256-empty{padding:25px 10px;text-align:center;opacity:.65;line-height:1.6}
@media(max-width:760px){
  .v256-enhance-layout{grid-template-columns:1fr;min-height:0}
  .v256-enhance-card-list{max-height:34vh}
  .v256-enhance-detail{min-height:360px}
  .v256-detail-grid{grid-template-columns:1fr}
  .v256-detail-grid .full{grid-column:auto}
  .v256-enhance-toolbar{flex-direction:column}
}

.v257-enhance-role-note{flex-basis:100%;font-size:11px;line-height:1.5;padding:7px 9px;border-radius:8px;border:1px solid rgba(198,162,90,.28);background:rgba(198,162,90,.07);opacity:.9}
.v257-enhance-role-note b{color:#f0c96c}
#v257EnhanceResetBtn{border-color:rgba(255,180,90,.34)}
html:not(.is-card-admin) #v257EnhanceResetBtn{display:none!important}
@media(max-width:760px){.v257-enhance-role-note{flex-basis:auto}}

.shop-card,.deck-builder-visual-card,.v258-owned-card{position:relative!important}
.v258-enhancement-bookmark{
  position:absolute;z-index:18;left:7px;top:-1px;
  display:flex;align-items:center;justify-content:center;
  min-width:49px;height:23px;padding:0 7px 4px;
  box-sizing:border-box;border-radius:0 0 7px 7px;
  background:linear-gradient(180deg,#f7d77a,#9f6d18 82%);
  color:#201300;font-size:9px;font-weight:950;letter-spacing:-.2px;
  text-shadow:0 1px 0 rgba(255,255,255,.35);
  box-shadow:0 2px 6px rgba(0,0,0,.48),0 0 0 1px rgba(255,230,140,.35) inset;
  pointer-events:none;white-space:nowrap;
}
.v258-enhancement-bookmark:after{content:"";position:absolute;left:50%;bottom:-6px;transform:translateX(-50%);border-left:8px solid transparent;border-right:8px solid transparent;border-top:7px solid #9f6d18}
.v258-enhancement-bookmark.is-test{background:linear-gradient(180deg,#b9d6ff,#48658d 82%);color:#081321}.v258-enhancement-bookmark.is-test:after{border-top-color:#48658d}
.v258-enhanced-card{
  border-color:#e5bc4f!important;
  box-shadow:0 0 0 2px rgba(229,188,79,.48) inset,0 0 10px rgba(229,188,79,.32)!important;
}
.v258-normal-card{box-shadow:none}

.card-shop-toolbar{
  grid-template-columns:108px 96px 78px 82px 58px 82px minmax(150px,1fr) 78px!important;
}
.card-shop-toolbar .card-shop-point-filter{width:58px!important;min-width:58px!important}
.card-shop-toolbar .card-shop-point-filter select{width:52px!important;min-width:52px!important;padding-left:5px!important;padding-right:16px!important;text-align:center!important}
.card-shop-toolbar .card-shop-ownership-filter{width:82px!important;min-width:82px!important}
.shop-owned-outside{white-space:nowrap!important;font-size:10px!important}

.v258-owned-panel{display:none;padding:12px 14px 16px}.v258-owned-panel.active{display:block}
.v258-owned-toolbar{display:grid;grid-template-columns:105px minmax(170px,1fr) 88px;gap:8px;align-items:end;margin-bottom:8px}
.v258-owned-toolbar label{display:grid;gap:4px;font-size:11px}.v258-owned-toolbar select,.v258-owned-toolbar input{width:100%;min-width:0;padding:8px 9px;border-radius:8px;border:1px solid rgba(255,255,255,.18);background:rgba(0,0,0,.22);color:inherit;box-sizing:border-box}
.v258-owned-count{height:34px;border:1px solid rgba(255,255,255,.14);border-radius:8px;display:flex;align-items:center;justify-content:center;gap:5px;font-size:11px}.v258-owned-count b{font-size:17px;color:#f0c96c}
.v258-owned-guide{padding:8px 10px;margin-bottom:9px;border-radius:8px;background:rgba(198,162,90,.07);border:1px solid rgba(198,162,90,.22);font-size:11px;line-height:1.5;opacity:.88}
.v258-owned-grid{display:grid;grid-template-columns:repeat(6,minmax(120px,1fr));gap:9px;align-items:start;max-height:62vh;overflow:auto;padding:4px}
.v258-owned-entry{display:grid;gap:5px;min-width:0}
.v258-owned-card{display:grid;grid-template-rows:46px 145px auto minmax(42px,auto);overflow:hidden;min-height:270px;border:1px solid rgba(255,255,255,.16);border-radius:10px;background:rgba(12,12,14,.92);box-sizing:border-box}
.v258-owned-card>.collection-card-title{grid-row:1}.v258-owned-card>.collection-card-art{grid-row:2;height:145px!important;min-height:145px!important}.v258-owned-card>.collection-five-stats{grid-row:3}.v258-owned-card>.collection-extra{grid-row:4;min-height:42px!important}
.v258-owned-meta{display:flex;align-items:center;justify-content:space-between;gap:5px;padding:4px 6px;border-radius:7px;background:rgba(0,0,0,.28);font-size:10px}.v258-owned-meta b{color:#e7d4a5}.v258-owned-entry:has(.v258-enhanced-card) .v258-owned-meta b{color:#f0c96c}

@media(max-width:1100px){.card-shop-toolbar{grid-template-columns:100px 90px 74px 78px 58px 78px minmax(130px,1fr) 74px!important}.v258-owned-grid{grid-template-columns:repeat(4,minmax(120px,1fr))}}
@media(max-width:760px){.card-shop-toolbar{grid-template-columns:repeat(3,minmax(0,1fr))!important}.card-shop-toolbar .card-shop-point-filter,.card-shop-toolbar .card-shop-ownership-filter{width:auto!important;min-width:0!important}.card-shop-toolbar .card-shop-point-filter select{width:100%!important;min-width:0!important}.v258-owned-toolbar{grid-template-columns:1fr 1fr}.v258-owned-count{grid-column:1/-1}.v258-owned-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.v258-enhancement-bookmark{left:5px;min-width:45px;font-size:8px}}
@media(max-width:430px){.card-shop-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))!important}.v258-owned-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}.v258-owned-card{min-height:235px;grid-template-rows:42px 118px auto minmax(38px,auto)}.v258-owned-card>.collection-card-art{height:118px!important;min-height:118px!important}}

.v258-enhancement-bookmark{
  left:auto!important;right:4px!important;top:44px!important;bottom:auto!important;
  min-width:28px!important;width:auto!important;height:14px!important;padding:0 4px!important;
  border-radius:4px!important;font-size:7px!important;line-height:14px!important;letter-spacing:-.2px!important;
  background:linear-gradient(180deg,#f7d77a,#9f6d18)!important;color:#201300!important;
  box-shadow:0 1px 4px rgba(0,0,0,.55),0 0 0 1px rgba(255,230,140,.32) inset!important;
}
.v258-enhancement-bookmark:after{display:none!important}
.v258-enhancement-bookmark.is-test{background:linear-gradient(180deg,#b9d6ff,#48658d)!important;color:#081321!important}
@media(max-width:850px){.v258-enhancement-bookmark{right:3px!important;top:37px!important;min-width:24px!important;height:12px!important;padding:0 3px!important;font-size:6px!important;line-height:12px!important}}

.v259-wallet{display:inline-flex;align-items:center;gap:5px;margin-left:auto;margin-right:5px;padding:4px 6px;border:1px solid rgba(221,183,91,.35);border-radius:7px;background:rgba(0,0,0,.22);font-size:9px;white-space:nowrap}
.v259-wallet span{display:inline-flex;gap:2px}.v259-wallet b{color:#f1cc71;font-size:10px}.v259-wallet.compact{margin:0 6px}
.left-auth-logged-in{display:flex;align-items:center;gap:5px;flex-wrap:wrap}.left-auth-logged-in[hidden]{display:none!important}

.v259-deck-ownership-filter{min-width:88px}
.deck-builder-toolbar{grid-template-columns:repeat(6,minmax(98px,1fr))!important}

.card-shop-head{display:flex;align-items:center}.v259-my-cards-btn{margin-left:auto}.v259-my-cards-btn+#closeCardShopBtn{margin-left:6px}
.v259-my-cards-box{width:min(1320px,96vw)!important;max-height:90vh!important}
.v259-my-cards-toolbar{display:grid;grid-template-columns:120px minmax(180px,1fr) 120px;gap:8px;align-items:end;padding:10px 12px}
.v259-my-cards-toolbar label{display:grid;gap:4px;font-size:11px}.v259-my-cards-toolbar input,.v259-my-cards-toolbar select{width:100%;box-sizing:border-box;padding:7px 8px;border-radius:7px;border:1px solid rgba(255,255,255,.16);background:rgba(0,0,0,.25);color:inherit}
.v259-my-cards-toolbar>div{height:34px;display:flex;align-items:center;justify-content:center;gap:5px;border:1px solid rgba(255,255,255,.13);border-radius:7px}.v259-my-cards-toolbar b{color:#f0c96c}
.v259-my-cards-grid{display:grid;grid-template-columns:repeat(6,minmax(125px,1fr));gap:9px;max-height:68vh;overflow:auto;padding:8px 12px 16px}
.v259-my-card-entry{display:grid;gap:5px;min-width:0}.v259-my-card{position:relative;display:grid;grid-template-rows:46px 145px auto minmax(42px,auto);overflow:hidden;min-height:270px;border:1px solid rgba(255,255,255,.16);border-radius:10px;background:rgba(12,12,14,.92)}
.v259-my-card>.collection-card-title{grid-row:1}.v259-my-card>.collection-card-art{grid-row:2;height:145px!important;min-height:145px!important}.v259-my-card>.collection-five-stats{grid-row:3}.v259-my-card>.collection-extra{grid-row:4;min-height:42px!important}
.v259-my-card-count{display:flex;align-items:center;justify-content:space-between;gap:5px;padding:5px 6px;border-radius:7px;background:rgba(0,0,0,.3);font-size:10px}.v259-my-card-count b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.v259-my-card-count span{white-space:nowrap;color:#e8cf94}

.v259-booster-costs{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin:9px 0 6px}.v259-booster-card small{display:block;line-height:1.45;opacity:.78;font-size:9px}

.v259-admin-box{width:min(940px,95vw)!important;max-height:90vh!important}.v259-admin-grid{display:grid;grid-template-columns:minmax(230px,1fr) auto;gap:10px;padding:12px}.v259-admin-grid>label{display:grid;gap:4px}.v259-admin-grid select,.v259-admin-grid input{width:100%;box-sizing:border-box;padding:8px;border-radius:7px;border:1px solid rgba(255,255,255,.16);background:rgba(0,0,0,.25);color:inherit}.v259-admin-target-info{grid-column:1/-1;padding:8px 10px;border-radius:7px;background:rgba(198,162,90,.08);border:1px solid rgba(198,162,90,.22)}.v259-admin-grid fieldset{min-width:0;border:1px solid rgba(255,255,255,.15);border-radius:9px;padding:10px;display:grid;grid-template-columns:1fr 120px;gap:8px}.v259-admin-grid fieldset legend{padding:0 6px;color:#f0c96c;font-weight:900}.v259-admin-grid fieldset label{display:grid;gap:4px}.v259-admin-actions{grid-column:1/-1;display:flex;gap:7px}.v259-admin-actions .btn{flex:1}

@media(max-width:1100px){.deck-builder-toolbar{grid-template-columns:repeat(4,minmax(95px,1fr))!important}.v259-my-cards-grid{grid-template-columns:repeat(4,minmax(120px,1fr))}}
@media(max-width:760px){.v259-wallet{margin-left:0}.deck-builder-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))!important}.v259-my-cards-toolbar{grid-template-columns:1fr 1fr}.v259-my-cards-toolbar>div{grid-column:1/-1}.v259-my-cards-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.v259-admin-grid{grid-template-columns:1fr}.v259-admin-target-info,.v259-admin-grid fieldset{grid-column:1}.v259-admin-grid fieldset{grid-template-columns:1fr}.v259-admin-actions{grid-column:1}.v259-booster-costs{grid-template-columns:1fr}}

.left-auth-logged-in #leftAuthStateText{flex:0 0 auto!important}
.v265-login-id{border:0;background:transparent;color:#f0cf7b;padding:2px 3px;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-decoration:underline;text-underline-offset:2px;cursor:pointer;font:inherit}
.v265-login-id:hover{color:#ffe5a2}.online-user-chip.v265-clickable-user{cursor:pointer;text-decoration:underline;text-underline-offset:2px}
.v265-booster-card{overflow:hidden}.v265-pack-cover{width:100%;aspect-ratio:16/9;border-radius:9px;overflow:hidden;background:rgba(0,0,0,.35);border:1px solid rgba(232,196,108,.24);display:flex;align-items:center;justify-content:center;margin-bottom:9px}
.v265-pack-cover img{width:100%;height:100%;object-fit:cover;display:block}.v265-pack-cover-empty{display:grid;place-content:center;text-align:center;background:radial-gradient(circle at 50% 35%,rgba(182,132,43,.35),rgba(14,10,8,.92))}.v265-pack-cover-empty b{font-size:26px;color:#f0cf7b}.v265-pack-cover-empty span{font-size:10px;opacity:.76;letter-spacing:.12em}
.v265-pack-head{display:flex;gap:7px;align-items:flex-start;justify-content:space-between}.v265-pack-head h3{min-width:0}.v265-visibility{flex:0 0 auto;padding:3px 7px;border-radius:999px;font-size:9px;font-weight:900}.v265-visibility.public{background:#285d3b;color:#d7ffe2}.v265-visibility.private{background:#5e3030;color:#ffd7d7}.v265-pack-factions{font-size:10px;opacity:.82;line-height:1.5}.v265-booster-card.is-private{outline:1px dashed rgba(255,130,130,.32)}
.v265-pack-admin-box{width:min(1180px,96vw)!important;max-height:92vh!important;overflow:auto}.v265-pack-admin-toolbar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding:10px 12px;border-bottom:1px solid rgba(255,255,255,.1)}.v265-pack-admin-toolbar span{font-size:10px;opacity:.8}.v265-overflow-note{margin:10px 12px 0;padding:8px 10px;border:1px solid rgba(232,196,108,.24);border-radius:8px;background:rgba(232,196,108,.07);font-size:10px;line-height:1.5}.v265-overflow-note b{color:#f1cc71}
.v265-pack-admin-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;padding:12px}.v265-pack-admin-card{min-width:0;border:1px solid rgba(232,196,108,.28);border-radius:11px;background:rgba(18,14,11,.9);padding:10px;display:grid;gap:8px}.v265-cover-editor{display:grid;gap:5px;cursor:pointer;font-size:10px;text-align:center;color:#f0cf7b}.v265-cover-editor .v265-pack-cover{margin:0}.v265-pack-admin-fields{display:grid;grid-template-columns:1fr 95px;gap:7px}.v265-pack-admin-fields label{display:grid;gap:4px;font-size:10px}.v265-pack-admin-fields input,.v265-pack-admin-fields select{width:100%;box-sizing:border-box;padding:7px;border-radius:7px;border:1px solid rgba(255,255,255,.16);background:rgba(0,0,0,.25);color:inherit}.v265-pack-admin-meta{display:flex;gap:7px;align-items:center;flex-wrap:wrap;font-size:10px}.v265-pack-admin-meta b{color:#f0cf7b}.v265-pack-admin-card details{font-size:10px}.v265-pack-admin-card summary{cursor:pointer;color:#dfc78c}.v265-pack-card-list{display:grid;grid-template-columns:1fr 1fr;gap:3px 8px;max-height:170px;overflow:auto;padding:7px 2px}.v265-pack-card-list span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.v265-pack-admin-actions{display:flex;justify-content:flex-end}.v265-pack-admin-actions .btn{min-width:88px}
@media(max-width:980px){.v265-pack-admin-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:680px){.v265-login-id{max-width:120px}.v265-pack-admin-grid{grid-template-columns:1fr}.v265-pack-admin-fields{grid-template-columns:1fr}.v265-pack-card-list{grid-template-columns:1fr}}

.v270-booster-purchase{display:grid;gap:8px;margin:10px 0 7px}
.v270-booster-currency{display:grid;gap:5px;padding:7px;border:1px solid rgba(232,196,108,.16);border-radius:8px;background:rgba(255,255,255,.025)}
.v270-booster-currency>b{font-size:10px;color:#ead7a5}
.v270-booster-counts{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px}
.v270-booster-counts .btn{min-width:0;padding:7px 5px;font-size:9px;white-space:nowrap}
.v270-booster-result-box{width:min(780px,94vw);max-width:780px}
.v270-booster-reveal-stage{min-height:460px;display:flex;align-items:center;justify-content:center;padding:16px 4px}
.v270-booster-reveal-card{width:min(310px,76vw);aspect-ratio:5/7;border:1px solid rgba(232,196,108,.42);border-radius:14px;overflow:hidden;background:linear-gradient(180deg,#211b12,#0c0b0a);box-shadow:0 18px 50px rgba(0,0,0,.48);display:flex;flex-direction:column;animation:v270CardReveal .28s ease-out}
@keyframes v270CardReveal{from{opacity:0;transform:translateY(12px) scale(.96)}to{opacity:1;transform:none}}
.v270-booster-reveal-image{flex:1;min-height:0;background:#090909;overflow:hidden}
.v270-booster-reveal-image img{display:block;width:100%;height:100%;object-fit:cover}
.v270-booster-reveal-image.is-empty{background:transparent}
.v270-booster-reveal-info{padding:12px 14px 14px;text-align:center;border-top:1px solid rgba(255,255,255,.08)}
.v270-booster-reveal-info h3{margin:4px 0 3px;font-size:22px}
.v270-booster-reveal-info p{margin:0;font-size:11px;opacity:.72}
.v270-booster-grade{display:inline-flex;padding:3px 8px;border-radius:999px;background:rgba(255,255,255,.08);font-size:11px;font-weight:900}
.v270-booster-result-actions{display:flex;justify-content:center;margin:0 0 10px}
.v270-booster-result-actions .btn{min-width:150px}
.v270-booster-result-strip{display:flex;gap:5px;overflow:auto;padding:7px 2px 2px}
.v270-booster-mini{flex:0 0 auto;min-width:86px;max-width:120px;padding:6px 7px;border:1px solid rgba(255,255,255,.08);border-radius:7px;opacity:.32;display:grid;gap:2px}
.v270-booster-mini.revealed{opacity:1;border-color:rgba(232,196,108,.35)}
.v270-booster-mini span,.v270-booster-mini em{font-size:8px;opacity:.7;font-style:normal}.v270-booster-mini b{font-size:9px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.v270-card-art-empty{background:none!important;background-image:none!important;box-shadow:none!important;visibility:hidden!important}
@media(max-width:760px){.v270-booster-counts{grid-template-columns:repeat(2,minmax(0,1fr))}.v270-booster-reveal-stage{min-height:390px}.v270-booster-reveal-card{width:min(280px,80vw)}}
.v270-booster-mini:not(.revealed) b,.v270-booster-mini:not(.revealed) em{visibility:hidden}
.v270-booster-mini:not(.revealed)::after{content:'미공개';font-size:8px;opacity:.55}

.v271-booster-purchase{display:grid!important;visibility:visible!important;opacity:1!important;overflow:visible!important;margin-top:12px!important;padding-top:10px;border-top:1px solid rgba(240,207,123,.22)}
.v271-booster-action-title{display:block;font-size:12px;font-weight:900;color:#f5d77f;letter-spacing:.02em;margin-bottom:1px}
.v271-booster-purchase .v270-booster-currency{display:grid!important;visibility:visible!important;opacity:1!important}
.v271-booster-purchase .v270-booster-counts{display:grid!important;visibility:visible!important;opacity:1!important}
.v271-booster-purchase .v270-booster-counts .btn{display:inline-flex!important;align-items:center;justify-content:center!important;min-height:34px!important;font-size:10px!important;font-weight:800!important;visibility:visible!important;opacity:1!important;pointer-events:auto!important}
@media(max-width:760px){.v271-booster-purchase .v270-booster-counts .btn{min-height:38px!important;font-size:11px!important}}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v280-card-w:107.485714px; 
    --v280-card-h:150.48px;    
    --v280-field-gap:6px;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    grid-template-columns:repeat(3,var(--v280-card-w))!important;
    grid-template-rows:repeat(2,var(--v280-card-h))!important;
    grid-auto-rows:var(--v280-card-h)!important;
    column-gap:calc((100% - (var(--v280-card-w) * 3)) / 2)!important;
    row-gap:6px!important;
    width:100%!important;
    height:calc((var(--v280-card-h) * 2) + 6px)!important;
    min-height:calc((var(--v280-card-h) * 2) + 6px)!important;
    max-height:calc((var(--v280-card-h) * 2) + 6px)!important;
    justify-content:start!important;
    align-content:start!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card{
    width:var(--v280-card-w)!important;min-width:var(--v280-card-w)!important;max-width:var(--v280-card-w)!important;
    height:var(--v280-card-h)!important;min-height:var(--v280-card-h)!important;max-height:var(--v280-card-h)!important;
    aspect-ratio:2.5 / 3.5!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    width:var(--v280-card-w)!important;min-width:var(--v280-card-w)!important;max-width:var(--v280-card-w)!important;
    height:var(--v280-card-h)!important;min-height:var(--v280-card-h)!important;max-height:var(--v280-card-h)!important;
    aspect-ratio:2.5 / 3.5!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    height:var(--v280-card-h)!important;min-height:var(--v280-card-h)!important;max-height:var(--v280-card-h)!important;
    gap:var(--v280-field-gap)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,var(--v280-card-w))!important;
    width:calc((var(--v280-card-w) * 5) + (var(--v280-field-gap) * 4))!important;
    min-width:calc((var(--v280-card-w) * 5) + (var(--v280-field-gap) * 4))!important;
    max-width:calc((var(--v280-card-w) * 5) + (var(--v280-field-gap) * 4))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,var(--v280-card-w))!important;
    width:calc((var(--v280-card-w) * 4) + (var(--v280-field-gap) * 3))!important;
    min-width:calc((var(--v280-card-w) * 4) + (var(--v280-field-gap) * 3))!important;
    max-width:calc((var(--v280-card-w) * 4) + (var(--v280-field-gap) * 3))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,var(--v280-card-w))!important;
    width:calc((var(--v280-card-w) * 3) + (var(--v280-field-gap) * 2))!important;
    min-width:calc((var(--v280-card-w) * 3) + (var(--v280-field-gap) * 2))!important;
    max-width:calc((var(--v280-card-w) * 3) + (var(--v280-field-gap) * 2))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,var(--v280-card-w))!important;
    width:calc((var(--v280-card-w) * 2) + var(--v280-field-gap))!important;
    min-width:calc((var(--v280-card-w) * 2) + var(--v280-field-gap))!important;
    max-width:calc((var(--v280-card-w) * 2) + var(--v280-field-gap))!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    width:100%!important;height:100%!important;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    height:154px!important;min-height:154px!important;max-height:154px!important;flex-basis:154px!important;
  }
}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    
    --v281-card-w:107.485714px;
    --v281-card-h:150.48px;
    --v281-hand-gap:1px;
    --v281-field-gap:2px;
    --v281-hand-w:324.457142px; 
    --v281-hand-h:301.96px;     
    --v281-left-col-w:334.09px; 
    --v281-five-w:545.42857px;
    --v281-four-w:435.942856px;
    --v281-three-w:326.457142px;
    --v281-two-w:216.971428px;
    --v281-lane-h:154.48px;     
    --v281-battle-col-w:574.43px; 
    --v281-app-w:916.52px;       

    
    --v216-card-w:var(--v281-card-w);
    --v216-card-h:var(--v281-card-h);
    --hand-card-width:var(--v281-card-w);
    --hand-card-height:var(--v281-card-h);
    --v231-field-gap:var(--v281-field-gap);
    --v231-left-col-w:var(--v281-left-col-w);
    --v231-battle-col-w:var(--v281-battle-col-w);
    --v231-app-w:var(--v281-app-w);
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .app,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app[style]{
    grid-template-columns:var(--v281-left-col-w) var(--v281-battle-col-w)!important;
    width:var(--v281-app-w)!important;
    min-width:var(--v281-app-w)!important;
    max-width:var(--v281-app-w)!important;
    gap:0!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .reference-left{
    width:var(--v281-left-col-w)!important;
    min-width:var(--v281-left-col-w)!important;
    max-width:var(--v281-left-col-w)!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel{
    width:var(--v281-battle-col-w)!important;
    min-width:var(--v281-battle-col-w)!important;
    max-width:var(--v281-battle-col-w)!important;
    padding-right:0!important;
    box-sizing:border-box!important;
    overflow-x:hidden!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .right-hand-section{
    height:calc(var(--v281-hand-h) + 40px)!important;
    min-height:calc(var(--v281-hand-h) + 40px)!important;
    max-height:calc(var(--v281-hand-h) + 40px)!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host .handbox{
    width:100%!important;
    padding:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand{
    display:grid!important;
    grid-template-columns:repeat(3,var(--v281-card-w))!important;
    grid-template-rows:repeat(2,var(--v281-card-h))!important;
    grid-auto-rows:var(--v281-card-h)!important;
    width:var(--v281-hand-w)!important;
    min-width:var(--v281-hand-w)!important;
    max-width:var(--v281-hand-w)!important;
    height:var(--v281-hand-h)!important;
    min-height:var(--v281-hand-h)!important;
    max-height:var(--v281-hand-h)!important;
    column-gap:var(--v281-hand-gap)!important;
    row-gap:var(--v281-hand-gap)!important;
    gap:var(--v281-hand-gap)!important;
    margin:0 auto!important;
    padding:0!important;
    justify-content:start!important;
    align-content:start!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host #hand.hand .card,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    flex:0 0 var(--v281-card-w)!important;
    width:var(--v281-card-w)!important;
    min-width:var(--v281-card-w)!important;
    max-width:var(--v281-card-w)!important;
    height:var(--v281-card-h)!important;
    min-height:var(--v281-card-h)!important;
    max-height:var(--v281-card-h)!important;
    aspect-ratio:2.5 / 3.5!important;
    margin:0!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot{
    padding:0!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit{
    position:relative!important;
    inset:auto!important;
    transform:none;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slot>.unit.selected,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-field-slot>.unit.selected{
    transform:translateY(-2px)!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .boardwrap,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout{
    width:100%!important;min-width:0!important;max-width:none!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    padding:8px 6px 20px!important;
    gap:6px!important;
    align-items:stretch!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #enemyBaseDefenseLane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="e2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .neutral-lane,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a2"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > .lane[data-row="a1"],
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board > #allyBaseDefenseLane{
    align-self:stretch!important;
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    height:var(--v281-lane-h)!important;
    min-height:var(--v281-lane-h)!important;
    max-height:var(--v281-lane-h)!important;
    flex:0 0 var(--v281-lane-h)!important;
    flex-basis:var(--v281-lane-h)!important;
    padding:2px 8px 0!important;
    margin-left:0!important;
    margin-right:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    display:grid!important;
    height:var(--v281-card-h)!important;
    min-height:var(--v281-card-h)!important;
    max-height:var(--v281-card-h)!important;
    padding:0!important;
    gap:var(--v281-field-gap)!important;
    margin:0 auto!important;
    justify-content:center!important;
    justify-items:center!important;
    align-items:stretch!important;
    align-content:stretch!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n5,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .hq-battlefield-grid{
    grid-template-columns:repeat(5,var(--v281-card-w))!important;
    width:var(--v281-five-w)!important;min-width:var(--v281-five-w)!important;max-width:var(--v281-five-w)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n4{
    grid-template-columns:repeat(4,var(--v281-card-w))!important;
    width:var(--v281-four-w)!important;min-width:var(--v281-four-w)!important;max-width:var(--v281-four-w)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n3{
    grid-template-columns:repeat(3,var(--v281-card-w))!important;
    width:var(--v281-three-w)!important;min-width:var(--v281-three-w)!important;max-width:var(--v281-three-w)!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout .slots.n2{
    grid-template-columns:repeat(2,var(--v281-card-w))!important;
    width:var(--v281-two-w)!important;min-width:var(--v281-two-w)!important;max-width:var(--v281-two-w)!important;
  }

  
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit.action-ready{
    filter:brightness(1.12) saturate(1.08)!important;
    opacity:1!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit.action-disabled,
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit.spent{
    filter:brightness(.56) saturate(.48)!important;
    opacity:.86!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battlefield-layout .unit.action-ready.selected{
    filter:brightness(1.18) saturate(1.12)!important;
  }
}

@media (min-width:901px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane.neutral-lane{
    height:var(--v281-lane-h)!important;
    min-height:var(--v281-lane-h)!important;
    max-height:var(--v281-lane-h)!important;
    flex:0 0 var(--v281-lane-h)!important;
    margin:0!important;
    padding:2px 8px 0!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  body.unified-left-layout:not(.ui-mode-mobile-preview) .battle-panel .battlefield-layout>.board>.lane.neutral-lane>.slots{
    height:var(--v281-card-h)!important;
    min-height:var(--v281-card-h)!important;
    max-height:var(--v281-card-h)!important;
    margin:0 auto!important;
    padding:0!important;
  }
}
.v282-passive-line{display:inline-flex;gap:4px;align-items:center;flex-wrap:wrap}
.v282-passive-chip{display:inline-flex;align-items:center;padding:2px 6px;border:1px solid rgba(229,187,82,.55);border-radius:999px;font-size:10px;line-height:1.2;background:rgba(26,20,9,.78)}

.manager-passive-editor{
  border:1px solid rgba(199,160,74,.45);
  background:linear-gradient(180deg,rgba(53,42,20,.5),rgba(18,17,15,.55));
  padding:10px 12px;
  border-radius:6px;
}
.manager-passive-editor>label{font-weight:800;color:#f0d58d;margin-bottom:8px;display:block}
.manager-passive-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.manager-passive-slot{display:flex;flex-direction:column;gap:5px;font-size:12px;color:#e9dcb6}
.manager-passive-slot small{font-weight:400;opacity:.75;margin-left:4px}
.manager-passive-slot select{width:100%;min-height:34px}
.manager-passive-help{margin-top:8px;line-height:1.45;color:#cfc7b3}
.manager-passive-help b{color:#ffe38e}
.manager-passive-editor.is-disabled{opacity:.68;background:rgba(20,20,20,.38)}
.manager-passive-editor.is-disabled select{cursor:not-allowed}
@media(max-width:760px){.manager-passive-grid{grid-template-columns:1fr}}
.manager-passive-slot[hidden]{display:none!important}

.modal:not(.show){content-visibility:hidden;}
#managerCardList,#cardShopGrid,#deckBuilderCatalog,#v258OwnedCardsGrid,#v259MyCardsGrid,#v265PackAdminGrid{contain:layout style paint;}
.manager-card-row,.shop-card-entry,.deck-builder-card,.v258-owned-entry,.v259-my-card-entry,.v265-pack-admin-card{content-visibility:auto;contain-intrinsic-size:auto 180px;}
#managerCardList img,#cardShopGrid img,#deckBuilderCatalog img,#v258OwnedCardsGrid img,#v259MyCardsGrid img{content-visibility:auto;}
.v285-shop-more,.v285-deck-more,.v285-packbuilder-more,.v285-quickstats-more{text-align:center;}

@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-card-effect-section{order:3!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-battle-status-host{order:4!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-setup-host{order:5!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-hand-host{order:6!important;}
  body.unified-left-layout:not(.ui-mode-mobile-preview) .left-combat-controls-host{order:7!important;}
}
.card-shop-toolbar{grid-template-columns:100px 104px 90px 74px 78px 58px 78px minmax(130px,1fr) 74px!important;}
.card-shop-toolbar .card-shop-pack-filter{min-width:104px!important;}
.card-shop-toolbar .card-shop-pack-filter select{width:100%!important;}
@media(max-width:1100px){.card-shop-toolbar{grid-template-columns:92px 100px 84px 70px 74px 56px 76px minmax(120px,1fr) 70px!important;}}
@media(max-width:760px){.card-shop-toolbar{grid-template-columns:repeat(3,minmax(0,1fr))!important}.card-shop-toolbar .card-shop-pack-filter{min-width:0!important;}}
@media(max-width:430px){.card-shop-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))!important;}}
.slot.v286-bright-heal-target{outline:3px solid #8eff9b!important;box-shadow:0 0 0 2px rgba(142,255,155,.35),0 0 22px rgba(142,255,155,.8)!important;background:rgba(142,255,155,.16)!important;}
.slot.v286-bright-heal-target>.unit{filter:brightness(1.32) saturate(1.18)!important;}
.slot.v286-bright-heal-target::before{content:'회복 가능';position:absolute;z-index:12;top:4px;left:50%;transform:translateX(-50%);padding:2px 6px;border-radius:999px;background:rgba(10,60,24,.9);color:#dfffe5;font-size:9px;font-weight:900;white-space:nowrap;pointer-events:none;}
.rules-box{scroll-behavior:smooth;}
.rules-toc{position:sticky;top:0;z-index:20;margin:8px 0 12px;padding:10px;border:1px solid rgba(255,255,255,.12);border-radius:10px;background:rgba(12,16,24,.96);backdrop-filter:blur(8px);}
.rules-toc>b{display:block;margin-bottom:7px;font-size:12px;}
.rules-toc-links{display:flex;flex-wrap:wrap;gap:6px;}
.rules-toc-link{border:1px solid rgba(255,255,255,.14);border-radius:999px;background:rgba(255,255,255,.06);color:inherit;padding:5px 9px;font-size:10px;font-weight:800;cursor:pointer;}
.rules-toc-link:hover,.rules-toc-link:focus{background:rgba(255,255,255,.14);outline:none;}
.rules-grid>section{scroll-margin-top:116px;}
.rules-skill-catalog-section{grid-column:1/-1;}
.rules-skill-group,.rules-runtime-skills{margin-top:12px;padding-top:8px;border-top:1px solid rgba(255,255,255,.08);}
.rules-skill-group h4,.rules-runtime-skills h4{margin:0 0 8px;font-size:13px;}
.rules-skill-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;margin:0;}
.rules-skill-entry{padding:8px 9px;border:1px solid rgba(255,255,255,.08);border-radius:8px;background:rgba(255,255,255,.035);}
.rules-skill-entry dt{font-size:11px;font-weight:900;margin:0 0 3px;}
.rules-skill-entry dd{margin:0;font-size:10px;line-height:1.45;opacity:.88;}
.rules-skill-tier{display:inline-flex;margin-left:5px;padding:1px 5px;border-radius:999px;background:rgba(255,255,255,.09);font-size:8px;vertical-align:middle;}
@media(max-width:760px){.rules-skill-list{grid-template-columns:1fr}.rules-toc{top:0}.rules-grid>section{scroll-margin-top:154px;}}
