/* TCG ROTK v279 main CSS bundle */

/* ---- assets/css/v132_mobile_dock_fix.css ---- */
/* ================================================================
   v132 — 모바일 하단 고정 UI(아군 본진 · 핸드 · 전투 버튼) 정리
   - game.css / mobile_preview.css 뒤에 로드되는 최종 패치 파일이므로
     기존 규칙과 동일하거나 더 깊은 선택자로 항상 우선 적용된다.
   - body.ui-mode-mobile 클래스는 "실제 모바일 화면"과 "PC의 모바일
     미리보기" 모드 모두에서 공통으로 붙으므로, 두 경우를 한 번에 다룬다.
   ================================================================ */

:root{
  /* JS(v132_mobile_dock_fix.js)가 실측 후 정확한 값으로 덮어씀. 아래는
     JS 실행 전 첫 렌더링에서 겹침이 보이지 않도록 하는 안전한 기본값. */
  --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));
}

/* ----------------------------------------------------------------
   1) 하단 고정 스택 순서를 [버튼] → [아군 본진] → [핸드] 순으로 재배치
      (아래에서 위로). 아군 본진이 항복/셔플/턴종료 버튼 바로 위에 오도록.
   ---------------------------------------------------------------- */
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;
}

/* 본진/핸드/버튼 높이 합만큼 전투 화면 하단 여백을 확보해
   본진 박스가 전투 1열 카드를 가리지 않도록 한다 (실측값 기반). */
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;
}

/* ----------------------------------------------------------------
   2) 아군/적군 본진 박스 높이를 넉넉하게 키워 확대된 글씨가 잘리지 않게 함
   ---------------------------------------------------------------- */
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;
}

/* ----------------------------------------------------------------
   3) 라이프 · MP · 행동력(AP) · 카드 수 · 턴 수 · 책사 유무 —
      아군·적군 본진 모두 글씨/아이콘 크기 확대 (3칸 × 2줄 그리드 정리)
   ---------------------------------------------------------------- */
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;
}
/* 책사 유무 칩은 항상 노출 (일부 기존 규칙이 skill 칩을 숨기던 것을 되돌림) */
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;
}

/* ----------------------------------------------------------------
   4) 항복 · 셔플 · 턴종료 버튼 글씨 크게
   ---------------------------------------------------------------- */
body.ui-mode-mobile:not(.prebattle) .bottom-hud .hud-actions .btn{
  font-size:16px!important;
  font-weight:950!important;
  letter-spacing:-0.02em!important;
}


/* ---- assets/css/v133_card_manager_fix.css ---- */
/* ================================================================
   v133 — 카드 관리자 수정
   1) 이미지 셔틀(가로/세로 크기·위치) 조정이 미리보기에 반영되지 않던
      문제 수정: .card-art-img / .unit-art-img / .manager-preview img
      가 --img-x/--img-y/--img-scale-x/--img-scale-y 값을 실제로
      쓰도록(object-position + transform) 하는 규칙이 누락되어 있었다.
      (배틀필드 유닛(.battlefield-layout .unit-art-img)과 기타이미지
      미리보기(.other-preview-art)에는 있었지만, 카드 매니저 미리보기를
      포함한 일반 카드 이미지에는 없었음)
   2) "카드 이름" 입력창 폭을 줄이고 바로 옆에 "수정 저장" 버튼 배치
   ================================================================ */

/* ---- 1) 이미지 셔틀 미리보기 반영 ---- */
.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;
}
/* 자동 폴더 매칭 이미지(auto-folder-art)도 동일하게 셔틀 값을 반영 */
.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;
}

/* ---- 2) 카드 이름 + 수정 저장 버튼 한 줄 배치 ---- */
.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;
  }
}

/* v147 카드 이미지 일괄 자동 매칭 */
.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}


/* ---- assets/css/relationship_events.css ---- */
#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}}


/* ---- assets/css/v139_pc_bg_fit_and_mobile_dock_fix.css ---- */
/* ================================================================
   v139 — (1) PC 화면(강제 PC 모드 포함)에서 불필요하게 넓은 배경 영역 제거
          (2) 실제 모바일 화면에서 하단 고정 스택(본진·핸드·항복/셔플/턴종료
              버튼)을 진짜 화면 하단에 고정 + 전장 부드러운 스크롤
   game.css / mobile_preview.css / v132·v133 fix 파일보다 항상 나중에
   로드되는 최종 패치이므로 기존 규칙과 동일하거나 더 깊은 선택자로
   항상 우선 적용된다.
   ================================================================ */

/* ----------------------------------------------------------------
   (1) PC 레이아웃: 지금까지의 여러 버전이 .app/.boardwrap 등을
   100vh(또는 calc(100vh-Npx)) 고정 높이로 강제해 왔다. 평소 데스크톱
   에서는 화면 높이와 얼추 비슷해 티가 안 났지만, 휴대폰에서 "PC 버전"
   으로 전환하면 뷰포트 메타(width=1440, initial-scale=0.28)로 인해
   1vh가 실제보다 훨씬 커져, 실제 콘텐츠(전장·덱·핸드)보다 몇 배나 큰
   빈 배경이 화면 하단에 남는다. 높이를 콘텐츠 기준(auto)으로 바꿔
   이 문제를 근본적으로 해결한다. 화면이 콘텐츠보다 작을 때는
   body 스크롤로 대체한다. */
@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}
}

/* ----------------------------------------------------------------
   (2) 실제 모바일 화면: 하단 고정 스택이 실제로는 position:fixed가
   아니라(본진은 static, 핸드/버튼은 sticky) 일반 문서 흐름에 얹혀
   있어, 페이지 맨 위에서는 본진 바로 아래 핸드가 붙어 보이고 화면
   아래로 완전히 스크롤해야만 "고정"처럼 보였다. 세 요소 모두
   position:fixed로 화면 하단에 항상 고정하고, 전장(board)은 그
   높이만큼 padding-bottom을 확보한 채(v132에서 이미 계산) 자유롭게
   스크롤되도록 한다. */
@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;
  }
  /* 전장(board)이 담긴 영역이 body 스크롤로 부드럽게 넘어가도록 보장 */
  body.ui-mode-mobile:not(.prebattle){
    -webkit-overflow-scrolling:touch!important;
    overscroll-behavior-y:contain!important;
  }
}


/* ---- assets/css/v141_mobile_formation_hand_hq_fix.css ---- */
/* ================================================================
   v141 — (1) 모바일 "2. 전투" 메뉴에 진형 선택을 항상 보이게 노출
          (2) 모바일 핸드 카드에서 이미지가 카드 이름을 가리는 현상 수정
          (3) 본진 박스에서 "전략가 배치" 아래 남는 여백 제거(박스 높이 축소)
   game.css 및 이전 모든 fix 파일보다 나중에 로드되는 최종 패치.
   ================================================================ */

/* ----------------------------------------------------------------
   (1) "2. 전투" 카드 안에 진형 선택 + 덱 선택 셀렉트 두 개를 세로로
   쌓아 넣기 위한 레이아웃. 기존 .battle-menu-card는 [라벨][셀렉트]
   [버튼] 3칸 그리드였는데, 셀렉트 자리에 진형·덱 두 개를 넣는다. */
@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;
  }
}

/* ----------------------------------------------------------------
   (2) 실제 모바일 핸드 카드: 카드 총 높이가 화면 폭에 따라 계산되는
   변수(--v129-hand-card-height 등)와 이름줄·이미지·능력치줄의 높이가
   서로 안 맞아떨어지는 경우, 그림 영역이 자기 grid 행 밖으로 넘쳐
   이름줄 위로 겹쳐 보이는 문제가 있었다. 이름·이미지·능력치 세 구간의
   높이를 고정값으로 명확히 나누어(합이 카드 전체 높이와 항상 일치)
   겹침이 생기지 않게 한다. */
@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;
  }
}

/* ----------------------------------------------------------------
   (3) 본진 박스: 정보(라이프·MP·AP·카드수·턴수·책사유무) 두 줄과
   "전략가 배치" 칸은 실제로 100px 안팎이면 충분한데, 박스 자체 높이가
   168px로 고정돼 있어 전략가 배치 칸 아래로 빈 여백이 남았다.
   박스 높이를 실제 콘텐츠에 맞춰 줄인다. */
@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;
  }
}


/* ---- assets/css/online_platform.css?v=175 ---- */
/* Online platform / role / release management extension */
.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}}

/* v149 Firebase account UI */
.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%}}

/* v152 관리자 전용 카드관리 · 능력치 편집 이미지 등록 상태 */
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}}

/* v153: 실시간 사람 대전 대기 알림 */
.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)}


/* v158: online opponent/game log panel and reliable hand interaction */
.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}


/* ---- assets/css/v173_user_request_fix.css?v=175 ---- */
/* v173 요청사항: 핸드/필드 카드 크기 통일, 모바일 본진 압축, 관리자/로그인/드롭 UI */

/* 로그인 전에는 게임 전체 입력을 잠그고 로그인 창만 허용 */
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}
/* v212: max-width:52%+overflow-x:auto가 버튼들을 잘라 보이게 만들던 문제 수정.
   좁은 화면에서는 줄바꿈으로, 넓은 화면에서는 한 줄로 모든 버튼이 온전히 보이도록 한다. */
.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}

/* v212: 항목5 — 라이프/MP/EN이 최고치에 도달하면 밝은 색으로 강조 표시 */
.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}}

/* 데스크톱 핸드카드 높이를 현재 전투필드 카드(160px)와 동일하게 */
@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}
}

/* v173 최종 우선순위 고정: v132/v141의 더 깊은 선택자를 확실히 덮어쓴다. */
@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;
  }
}


/* ---- assets/css/v174_mobile_hq_dock_fix.css?v=175 ---- */
/* ================================================================
   v174 — 모바일 본진 UI 3건
   1) 아군/적군 본진 이름을 박스 상단 중앙에 정확히 표시
      (기존 .hq-title는 PC용 min-width:210px가 좁은 모바일 박스에서
       그대로 남아있어 중앙 배너가 박스 밖으로 밀려나가고 overflow:hidden에
       잘려 "아군 본진 · 위"의 앞글자가 화면 왼쪽 밖으로 잘려 보이던 문제.
       모바일에서는 title을 절대배치 배너 방식에서 그리드 셀 안 텍스트
       중앙정렬 방식으로 바꿔 원천적으로 잘림이 생기지 않게 한다.)
   2) 책사 배치 박스 높이를 본진 박스 높이와 통일
      (기존엔 책사 박스가 정보칸과 같은 56px짜리 가운데 띠 안에만 있어
       박스 위·아래로 남는 공백이 있었음. 본진 박스를 [제목행]-[정보/책사행]
       -[버튼행](아군만) 3행 그리드로 재구성하고, 책사 박스를 정보+버튼
       두 행을 합친 오른쪽 칼럼 전체에 걸쳐 배치해 사실상 본진 박스
       전체 높이(제목행 제외)와 같아지도록 한다.)
   3) 본진 박스를 화면 하단에 완전히 밀착
      (기존엔 본진 박스가 일반 문서 흐름에 있어 그 아래 핸드 영역과
       세이프에어리어 패딩만큼 화면 하단과 틈이 있었음. 본진 박스를
       화면에 고정하고, 핸드는 그 바로 위에 고정해 본진 박스 아래쪽
       테두리가 화면 맨 아래에 완전히 붙도록 한다.)

   game.css 및 이전 모든 모바일 패치(v132/v133/v139/v141/v173)보다
   나중에 로드되는 최종 패치. 일부 규칙은 game.css의 #allyHq/#enemyHq
   ID 선택자가 class 선택자보다 우선하는 것을 피하기 위해 동일하게
   ID 선택자를 사용한다.
   ================================================================ */

@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;
  }
  /* 아군 본진: 제목 / 정보+책사 / 버튼+책사 3행 — 책사 칸이 2·3행을 모두 차지 */
  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;
  }
  /* 적군 본진: 버튼행이 없어 제목 / 정보+책사 2행 — 책사 칸이 남은 높이 전체를 차지 */
  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;
  }

  /* ---- 정보칸(라이프·MP·행동력·덱·턴·책사유무): 그리드 셀에 맞춰 채움 ---- */
  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;
  }
}


/* ---- assets/css/v175_ui_patch.css?v=185 ---- */
/* ================================================================
   v175 — 항목 23: 본진 체력·MP·행동력·카드수·턴을
   핸드 카드 바로 위(#allyHqQuickBar)에 더 크고 직관적으로 표시.
   기존 .hq-info-overlay(본진 박스 안의 작은 칩)는 그대로 두고,
   핸드 바로 위에 별도의 확대 표시줄을 추가하는 방식이라
   v173/v174에서 이미 안정화된 본진 박스 레이아웃은 건드리지 않는다.
   game.css 및 이전 모든 패치보다 나중에 로드된다.
   ================================================================ */

.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;}
}

/* ================================================================
   v175 — 항목 1: 카드상점 카드 글씨 확대(상단은 이름+등급만, 공방체지매 강조)
   ================================================================ */
.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;}
}

/* ================================================================
   v175 — 항목 18: 사용 가능 카드 표시를 굵은 테두리 대신
   등급표시(.card-title-grade)와 같은 크기의 "가능" 배지로 변경.
   ================================================================ */
#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;}
}

/* ================================================================
   v175 — 항목 10: 카드관리 폼에서 현재 카드 종류와 무관한 입력칸을
   흐리게 비활성화만 하지 않고 아예 숨겨 더 간결하게 정리.
   ================================================================ */
.manager-field.mgr-field-hidden{display:none!important;}

/* 전투 시작 전(준비 화면)에는 본진 요약줄을 숨긴다. */
body.prebattle .hq-quickbar{display:none;}

/* ================================================================
   v175 — 항목 20: 본진 1칸(책사 공간)을 밝은 박스로 표시.
   기존 .hq-advisor-slot(책사 배치칸)에 밝은 강조 배경·테두리를 추가해
   "본진 안의 책사 전용 칸"임을 시각적으로 구분한다.
   ================================================================ */
.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;
}

/* ================================================================
   v175-2 — 카드상점 + 덱편집 공통: 공/방/체·지력/매력·설명·아이콘 확대
   (카드 박스 자체 크기는 그대로 두고 내부 글씨/기호만 키운다)
   ================================================================ */
.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;
}

/* 병력종류(병종/카드유형) 아이콘, 행동력(EN) 아이콘 확대 */
.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;
}

/* ================================================================
   v178 — 항목 1·2: 본진 진영 카드 표시 오류 수정 + 책사 공간 재배치
   ================================================================ */
/* 본진 병력칸 이름 줄바꿈(세로로 글자가 쌓이는) 버그 방지: 항상 한 줄로, 넘치면 말줄임. */
.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;
}

/* 항목 2: 핸드 위쪽 본진박스 안의 상태표시(체력·MP·행동력 등 칩)와 책사 배치칸은 더 이상
   여기서 보여주지 않는다(책사 배치는 본진 진영의 마지막 칸으로 이동했고, 상태표시는
   #allyHqQuickBar가 대신한다). */
#allyHq .hq-info-overlay,
#enemyHq .hq-info-overlay,
#allyHq > .hq-advisor-slot,
#enemyHq > .hq-advisor-slot{
  display:none!important;
}

/* ================================================================
   v178 — 항목 5: 핸드 카드 크기를 전투필드 카드 크기와 동일하게.
   syncHandCardSizeToField()가 매 렌더마다 채워주는 --hand-card-width/height를
   모든 반응형 분기(!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;}
}

/* ================================================================
   v179 — 항목4: 아군/적군 3열을 삭제하고 "무점령지" 공유 구역(4칸) 하나로 병합.
   전용 라벨 없이(요청대로 "표시가 없는 구역") 두 진영 사이에 배치한다.
   ================================================================ */
.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;}
}

/* ================================================================
   v180 — 무점령지 레인이 아래(아군) 레인과 시각적으로 겹치는 문제 방어 조치.
   정확한 원인을 실제 브라우저로 확인할 수 없어, 겹침이 구조적으로 불가능하도록
   레인 자체를 내용에 맞춰 확실히 감싸고(overflow:hidden), 위아래 여백을 넉넉히
   확보하는 방어적 수정이다.
   ================================================================ */
.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;}
}

/* ================================================================
   v185 — 매복 카드 UI + 화면 개편 요청 반영
   (1) 함정(구 매복 함정)/매복 카드 관련: 매복 선택 모달은 부활 모달과
       동일한 .revive-select-box/.revive-candidate-* 클래스를 재사용하므로
       별도 CSS 불필요.
   (2) 제목("TCG 삼국지"/"전투 프로토타입") 삭제는 HTML에서 요소 자체를
       삭제해 처리(별도 CSS 불필요).
   (3) 적군·아군 본진을 소형 박스로 나란히("사진처럼") 배치.
   (4) 모바일 하단 항복·셔플·턴종료 버튼줄 위에 적군·아군 상태줄 추가.
   (5) 전투필드 폭은 기존 그대로 유지, 나머지 화면(로그인·전투메뉴 등)
       폭을 핸드카드 화면(.right-hand-section) 폭 기준에 맞춤.
   실기기 렌더링 확인이 불가능한 환경에서 작성되었으므로, 실제 배치 후
   여백·줄바꿈이 어긋나면 스크린샷과 함께 재조정이 필요할 수 있습니다.
   ================================================================ */

/* ---- (3) 적군·아군 소형 상태 박스를 나란히 배치 ---- */
.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;}
}

/* ---- (4) 모바일 하단 고정 상태줄(버튼 위) ---- */
: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;}
}

/* ---- 모바일 사전 설정 화면: "1.덱메뉴/2.전투" 2분할을 축소해
   전투메뉴만 기본 노출하고, 상점·부스터팩·2인플레이·편집은 ⚙(고급 설정)
   패널 안으로 접어 넣어 화면을 더 간결하게 만든다. ---- */
@media (max-width:850px){
  #mobileAdvancedSetup #mobileDeckMenu{grid-column:1/-1!important;margin-bottom:6px!important;}
}

/* ---- (5) 전투필드 폭은 유지하고, 나머지(로그인 모달 등) 폭을
   핸드카드 화면(.right-hand-section) 기준 폭에 맞춘다. PC 기준. ---- */
@media (min-width:851px){
  #loginModal .modalbox.auth-modalbox{
    width:min(420px, var(--hand-card-width,106px) * 3 + 60px)!important;
    max-width:92vw!important;
  }
}


/* ---- assets/css/v181_user_request_fix.css?v=181 ---- */
/* ================================================================
   v181 — 요청사항 1~5: 전투열 간격, 본진 전투열, 책사 스킬,
   본진 버프 대상, 모바일 하단 배치 보정
   ================================================================ */

/* 1) 고정 그리드 행 수와 실제 DOM 행 수가 달라 생기던 무점령지/아군 2열 겹침 제거.
   전투 보드는 실제 자식 높이대로 흐르는 세로 flex로 배치한다. */
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;
}

/* PC에서는 모든 일반 전투열이 카드 한 장을 완전히 감싸도록 고정한다. */
@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;
  }
}

/* 2) 본진 전투열도 일반 전투열과 같은 카드 크기/실선 슬롯을 사용한다. */
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;
}

/* 5) 모바일: 하단 아군 본진 이미지 박스는 제거하고, 핸드는 화면 맨 아래에 고정한다. */
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;
}


/* ---- assets/css/v182_mobile_base_ratio_fix.css?v=182 ---- */
/* ================================================================
   v182 — 모바일 본진 전투열 5장 기준 카드 비율 유지
   ================================================================
   본진 전투열은 모바일 화면 너비를 5등분하되, 필드 카드와 같은
   가로:세로 비율(1 : 1.767)을 사용한다. 이전 패치의 고정 높이를
   제거하여 화면이 좁아질 때 세로만 늘어나는 현상을 방지한다.
   ================================================================ */

@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;
  }
}

/* 데스크톱에서 실행하는 모바일 미리보기는 창 너비가 850px보다 커도
   430px 플레이 영역을 사용하므로 동일한 5장 비율 규칙을 별도로 적용한다. */
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;
}


/* ---- assets/css/v186_left_unified_layout.css?v=186 ---- */
/* v186 — PC 좌측 통합 전투 UI */

@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;
  }

  /* 오른쪽 패널에 있던 보조 덱 박스는 상태 CARD 값으로 대체한다. */
  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;
  }
}

/* v187 — 화면 비율 안정화 / 전체화면 사용 억제 / 스크롤바 숨김 */
@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;
  }
}

/* v188 — 전투 시작 시 필드 공백/행 붕괴 수정 */
@media (min-width:851px){
  /* v187의 고정 7행 그리드 대신, 실제 표시되는 행 수에 따라 유연하게 배치 */
  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;
  }
}

/* v189 — 핸드/필드 카드 크기 통일 + 전투열 높이 정렬 + 본진진영 스크롤바 제거 */
@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;
  }

  /* 아군 핸드: 6장이 한 화면에 정확히 보이는 3x2 고정 비율 */
  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;
  }
}

/* v190 — 전투열 높이·좌측 버튼 통일·본진상태 가독성·카드선 정리 */
@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;
  }

  /* 1) 핸드 카드/전투필드 카드 공통 크기 */
  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;
  }

  /* 2) 전투필드 전투열 높이 확대 — 카드 하단 잘림 방지 */
  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;
  }

  /* 3) 좌측 버튼 높이/글씨크기 통일 */
  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;
  }

  /* 4) 본진 상태 박스 가독성 향상 */
  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;
  }

  /* 5) 아이템 카드 능력치 표기: 공/방/체 +수치 */
  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;
  }

  /* 6) 카드 테두리 얇게, 사용 가능 상태도 굵기 동일 */
  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}

  /* 7) 본진 진영 내부 스크롤 방지 */
  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;
  }
}

/* v191 — 전투열 카드 위치 재정렬 / 카드 비율 2:3.1 고정 / 좌우 빈 공간 축소 */
@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v191-card-w:78px;
    --v191-card-h:121px; /* 2 : 3.1 비율 */
    --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}

  /* 카드 비율 2:3.1 고정 */
  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;
  }
}

/* v191 — 전투열 카드 위치 재정렬 / 2:3.1 비율 고정 / 좌우 여백 제거 */
@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v191-card-w:80px;
    --v191-card-h:124px; /* 2 : 3.1 비율 */
    --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;
  }
}

/* v192 — 카드 2.5:3.5 비율 / 핸드 이름 표시 / 아이템 표기 / 전투열 여백 재조정 */
@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v192-card-w:84px;
    --v192-card-h:117.6px; /* 2.5 : 3.5 = 5 : 7 */
    --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;
  }

  /* 전투열: 5장 기준, 좌우 여백은 카드 0.5장씩 */
  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;
  }
}


/* ---- assets/css/v193_card_ratio_hand_gap_formation_width.css?v=193 ---- */
/* v193 — 카드 2.8:4.0 비율 / 핸드 카드 무간격 / 전투진영 6장 폭·하단 밀착 */
@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v193-card-w:84px;
    --v193-card-h:120px; /* 2.8 : 4.0 */
    --v193-field-gap:6px;
    --v193-hand-gap:0px;
    --v193-hand-section-h:286px;
    --v193-formation-w:534px; /* 84px × 6 + 6px × 5 */
    --v193-five-card-w:444px;
    --v193-four-card-w:354px;
    --v193-three-card-w:264px;
    --v193-two-card-w:174px;
    --v193-lane-h:124px; /* 카드 120px + 상단 2px + 상·하단 테두리 */
  }

  /* 핸드: 2.8 x 4.0 비율, 가로·세로 카드 사이 여백 제거 */
  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;
  }

  /* 전투 카드도 핸드와 동일한 2.8 x 4.0 비율 */
  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;
  }

  /* 전투진영 박스: 카드 6장 + 카드 사이 간격 5개가 정확히 들어가는 폭 */
  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; /* 2.8 : 4.0 */
    --v193-field-gap:5px;
    --v193-hand-section-h:274.5714px;
    --v193-formation-w:505px; /* 80px × 6 + 5px × 5 */
    --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;
  }
}


/* ---- assets/css/v195_status_cardeffect_square.css?v=196 ---- */
/* v196 — 상태표시 단일 박스 / 카드 연출효과 패널 / 카드 3.3:4.8 / 라운딩 제거 */
@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:414px minmax(720px,1fr)!important; /* 기존 360px 대비 15% 확장 */
  }

  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v193-card-w:84px;
    --v193-card-h:122.1818px; /* 3.3 : 4.8 */
    --v193-field-gap:6px;
    --v193-hand-gap:0px;
    --v193-hand-section-h:302px;
    --v193-formation-w:534px; /* 카드 6장 + 간격 5개 */
    --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;
  }

  /* 핸드: 3.3 x 4.8 비율, 가로·세로 카드 사이 여백 제거 */
  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;
  }

  /* 전투 카드도 핸드와 동일한 3.3 x 4.8 비율 */
  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;
  }

  /* 전투진영 박스: 카드 6장 + 카드 사이 간격 5개가 정확히 들어가는 폭 */
  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;
  }

  /* 카드 모서리 라운딩 제거 + 3.3:4.8 비율 고정 */
  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; /* 3.3 : 4.8 */
    --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;
  }
}


/* ---- assets/css/v197_layout_animation.css?v=197 ---- */
/* v197 — 좌측 폭 5% 확장 / 연출 애니메이션 무대 / 좌측 순서 / 전투필드 여백 제거 */
@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview) .app{
    grid-template-columns:435px minmax(720px,1fr)!important; /* v196 414px에서 약 5% 확장 */
  }

  /* 요청 순서: 효과창 → 적·아군 본진 → 아군 핸드 → 항복·셔플·턴종료 */
  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;}

  /* 설정 / 규칙확인 / PC / 모바일 한 줄, 카드관리 버튼과 동일한 높이 */
  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;
  }
}


/* ---- assets/css/v198_action_effect_card_fill.css?v=198 ---- */
/* v198 — 좌측 폭 복원 / 실제 카드 동작 연출만 표시 / 효과창 50% 확대 / 핸드·전투열 카드 높이 밀착 */
@media (min-width:851px){
  /* v197의 5% 확장을 취소하고 v196 폭으로 복원 */
  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){
    /* 핸드 박스 내부 높이(302 - 제목 28 - 상하 패딩 10)를 두 줄이 정확히 채우도록 조정 */
    --v193-card-h:132px;
    --v193-card-w:90.75px; /* 3.3 : 4.8 */
    --v193-field-gap:6px;
    --v193-hand-gap:0px;
    --v193-hand-section-h:302px;
    --v193-formation-w:574.5px; /* 90.75 × 6 + 6 × 5 */
    --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; /* 카드 132 + 상하 테두리 */
  }

  /* 연출효과창 높이 50% 확대: 186px → 279px */
  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){
    /* 낮은 화면: 292 - 제목 28 - 상하 패딩 10 = 254px → 카드 127px × 2 */
    --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;
  }
}


/* ---- assets/css/v199_user_layout_adjustments.css?v=199 ---- */

/* v199 — 사용자 요청 반영: 전투메뉴 단순화 · 카드관리 이동 · 상대찾기 버튼 배치 */

@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;}


/* ---- assets/css/v200_battle_scroll_layout_fix.css?v=200 ---- */

/* v200 — 전투 화면 스크롤 · 좌측폭 축소 · 카드상점/본진 타이틀 보정 */

@media (min-width:851px){
  /* 좌측 화면 폭 3% 축소 */
  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;
  }
}


/* ---- assets/css/v201_mobile_pc_tuning.css?v=201 ---- */

/* v201 — 카드상점/부스터 동일 높이 · 카드연출창 축소 · 모바일 전투열/상태 보정 */

/* 공통: 카드 상점/부스터팩 모달 높이 동일 */
.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;
}

/* PC: 카드 연출창 10% 축소 + 전투열 카드 하단 가림 보정 */
@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;
  }
}

/* 모바일 실기기 + PC 미리보기 공통 보정 */
@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;
  }
}

/* PC에서 보는 모바일 미리보기 폭 기준 동일 계산 */
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;
}


/* PC에서 모바일 미리보기에도 동일 레이아웃 강제 */
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;}


/* ---- assets/css/v202_mobile_field_width_fix.css?v=202 ---- */

/* v202 — 모바일 전투열 오른쪽 잘림 최종 보정 */

@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;
  }

  /* 모든 전투열은 5장 기준 폭을 공유한다. 4/3/2칸 열도 같은 카드 폭 유지 */
  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;
  }

  /* 핸드도 정확히 5장이 화면 폭 안에 들어가도록 재계산 */
  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;
  }
}

/* PC에서 실행하는 모바일 미리보기에도 같은 폭 계산 적용 */
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;
}


/* ---- assets/css/v203_mobile_hand_window_fix.css?v=203 ---- */

/* v203 — 모바일(특히 PC의 모바일 미리보기) 하단 핸드창 폭/크기 복원 */

/* 실기기 모바일은 기존 5장 맞춤을 유지하되, 핸드 카드 높이가 과도하게 커지지 않게 안전 상한 적용 */
@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;
  }
}

/* PC에서 모바일 미리보기: 하단 도크는 전체 폭이 아니라 모바일 플레이 폭(약 418px)을 사용 */
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;
}


/* ---- assets/css/v204_mobile_gap_status_art.css?v=204 ---- */
/* v205 — 모바일/모바일 미리보기 전투필드·핸드 밀착 + 본진 상태 상단 이미지 UI */

/* 실제 모바일: 핸드는 문서 흐름에 두고, 과거 고정 도크용 예약 여백을 제거한다. */
@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;
  }
}

/* PC에서 보는 모바일 미리보기는 viewport가 850px보다 크므로 별도 규칙이 필요하다.
   핸드를 fixed에서 일반 흐름으로 되돌려 전투필드 바로 아래에 붙인다. */
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}


/* ---- assets/css/v205_effect_title_animation_tuning.css?v=205 ---- */
/* v205 — 효과 제목과 실제 움직임이 더 직접적으로 연결되도록 연출 보강 */
.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}
}


/* ---- assets/css/v208_card_effect_idle_art_server.css?v=208 ---- */
/* v208 — 카드 연출창 기본 이미지 R2/Firestore 서버 저장 UI */
.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;}


/* ---- assets/css/v212_shop_deck_card_widen.css?v=212 ---- */
/* ================================================================
   v213 — 항목7: 카드상점 · 덱편집 카드 폭 확대 및 가로:세로 = 2.5 : 4.375 비율 통일
   (2.5:4.375 = 4:7과 동일 비율 — 배율 70)
   - 카드 이름이 잘리던 원인(고정 max-width:45%+font-size:9px, 말줄임 처리)을
     제거하고 이름이 줄바꿈되며 온전히 보이도록 한다.
   - 카드 상점·덱편집 카드 모두 --collection-card-width/height 변수를
     가로:세로 = 2.5:4.375 비율로 통일해 사용한다(기존 JS 자동측정값보다 우선 적용).
   - 이 파일은 항상 마지막에 로드되어 기존 game.css의 좁은 폭/말줄임 규칙을 덮어쓴다.
   ================================================================ */

: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;
}

/* 이름이 잘리던 규칙(45% 폭 제한 + 9px 축소 + 말줄임)을 모두 해제하고 줄바꿈으로 전체 표시 */
.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;
}
/* 항목7: 덱편집 카드도 카드상점과 동일하게 상단에 이름·등급만 표시하고, 국가/점수/보유수량 등
   부가 메타 텍스트는 상단에서 숨긴다(정보 자체는 카드 하단·바깥 보유수량 표시에 남아 있음). */
.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;
}


/* ---- assets/css/v214_deckeditor_layout.css?v=214 ---- */
/* ================================================================
   v214 — 덱 편집 UI 재배치 (PC 데스크톱, min-width:851px 기준)
   1) 덱 요약 문구("장수/지략가/병사/아이템/스킬/점수")를 "아군 덱 편집" 제목 옆으로 이동
   2) 랜덤 구성 비율 + "비율대로 랜덤 구성" 버튼을 카드 검색창 옆으로 이동,
      덱 이름 입력창·카드 검색창 폭을 줄여 공간 확보
   3) 보유 최대치 재설정 / 덱초기화 / 현재덱삭제 / 저장 버튼을 닫기 버튼 옆으로
      작게 이동 (기존 하단 전용 액션바 제거)
   4) 카드 목록 · 현재 덱 두 패널만 본문에 노출 (요약/비율/액션바는 모두 상단으로 이동)
   5) 덱 편집 창 전체 폭을 약 30% 축소하고, 카드도 동일 비율(70%)로 축소
   6) 카드 목록은 1줄에 5장, 현재 덱은 1줄에 4장 고정 표시
   이 파일은 항상 마지막에 로드되어 game.css/v212의 기존 규칙을 덮어쓴다.
   ================================================================ */

@media(min-width:851px){

  /* ---- 1) 헤드: 제목+요약문구 / 액션버튼 소형화 ---- */
  .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;
  }

  /* ---- 2) 툴바: 덱이름/검색창 폭 축소 + 랜덤구성비율·버튼을 검색창 옆으로 ---- */
  .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;}

  /* ---- 5)+6) 창 30% 축소 + 카드 5열(목록)/4열(현재 덱) 고정 ----
     카드 크기 변수는 #deckBuilderModal 안에서만 재정의되어 카드상점(다른 모달)에는
     영향을 주지 않는다. */
  #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;
  }
}


/* ---- assets/css/v215_battle_ui_layout.css?v=215 ---- */
/* v215 — 전투 메뉴 단순화 / 설정 라벨 확대 / 카드 20% 확대 / 전투열 좌측 밀착 */

/* 모바일에서는 기존 전투 설정 제목을 유지한다. */
.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){
    /* v198 최종 높이 132px의 120%, 비율 2.5 : 3.5 */
    --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);
  }

  /* 왼쪽 UI 폭을 고정해 3장의 핸드 카드가 내부 폭을 정확히 채우게 한다. */
  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;
  }

  /* 1) '전투 메뉴' 제목 줄과 외곽 박스를 제거한다. */
  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;
  }

  /* 관리자 권한이 없거나 hidden 상태이면 기존 접근 제어를 유지한다. */
  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;
  }

  /* 2) 전투진영 / 덱설정 / 덱편집 라벨 및 조작 글씨 확대 */
  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;
  }

  /* 카드 애니메이션 박스: 최신 PC 높이 251px에서 5% 축소 */
  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;
  }

  /* 3) 핸드 카드 20% 확대, 2.5 : 3.5 비율, 핸드 영역을 빈틈없이 채움 */
  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;
  }

  /* 4) 전투열 박스를 왼쪽 게임창에 바로 붙임 */
  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;
  }
  /* 낮은 화면에서 기존 238px 기준으로 동일하게 5% 축소 */
  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;
  }
}


/* ---- assets/css/v216_card_ratio_effect_readability.css?v=216 ---- */
/* v216 — 카드 2.7:4.2 비율 / 본진 하단 보정 / 연출 절제 / 카드 정보 가독성 */

/* 연출 내부의 문자·설명 오버레이는 표시하지 않는다. */
.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}
}

/* 공통: 과도한 반짝임을 줄이고 최대 4개의 입자만 사용한다. */
.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){
    /* v215 가로 113.142857px의 105%, 비율 2.7 : 4.2 */
    --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;
  }

  /* 핸드 카드와 전투필드 카드: 2.7 : 4.2 */
  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;
  }
}


/* ---- assets/css/v217_effect_dropdown_fix.css?v=217 ---- */
/* v217 — 연출효과 드롭다운을 모달 바깥 고정 레이어로 표시 */
.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}
}


/* ---- assets/css/v218_compact_faction_cards.css?v=218 ---- */
/* =====================================================================
   v218 — 1/4 축소 대응 심플 국가별 카드 디자인
   위(청색) · 촉(녹색) · 오(적색) · 기타(보라색)
   핵심 정보 우선순위: 이름 > EN > 등급 > 이미지 > 공격/방어/체력
   ===================================================================== */

: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;
}

/* EN 비용 */
#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;
}

/* 1/4급 소형 카드에서 다시 한 번 간결화 */
@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}
}

/* color-mix 미지원 브라우저용 기본값 */
@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}
}


/* ---- assets/css/v219_field_card_polish.css?v=219 ---- */
/* =====================================================================
   v219 — 전투필드 4건 보정
   1) 전투열(라인) 박스가 화면 오른쪽으로 잘리는 문제 방지
   2) 핸드 · 전투필드 카드 5% 축소
   3) EN 원형 배지: "N EN" → 숫자만
   4) 카드 등급 배지: 등급별 색상 구분
   5) 하단 공격/방어/체력: 문구 제거, 숫자만 표시
   ===================================================================== */

/* ---------- 1) 전투열 우측 잘림 방지 ---------- */
/* v216이 강제한 minmax(760px,1fr) 최소폭이 실제 창 폭보다 넓을 때
   .boardwrap의 overflow-x:hidden(v200)과 맞물려 오른쪽이 통째로
   화면 밖으로 밀려나 보이지 않는 현상이 원인. 최소폭을 카드 축소분에
   맞춰 줄이고, 혹시 남는 초과분은 잘리지 않고 스크롤되도록 안전장치를 둔다. */
@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;
}

/* ---------- 2) 핸드 · 전투필드 카드 5% 축소 ---------- */
/* v216이 정의한 카드 크기 변수(--v216-card-w 등)를 그대로 재정의하면
   핸드·전투열·본진 5칸 등 이를 참조하는 모든 규칙에 자동 반영된다. */
@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;
  }
}

/* ---------- 3) EN 원형 배지: 숫자만 ---------- */
#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;
}

/* ---------- 4) 카드 등급 배지: 등급별 색상 ---------- */
#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}

/* ---------- 5) 하단 공격/방어/체력: 문구 제거, 숫자만 ---------- */
/* v216이 ::before로 "공격"/"방어"/"체력" 글자를 넣던 규칙(더 높은 우선순위로
   v218의 아이콘 시도를 계속 이겨왔음)을 동일 선택자+!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;
}


/* ---- assets/css/v220_en_badge_unify.css?v=220 ---- */
/* =====================================================================
   v220 — 원형 배지 통합 + 이미지 미등록 카드 처리
   1) 카드 우측 상단의 국가 문양 원 → EN(필요 행동력) 숫자로 대체
   2) 기존 좌측 상단 EN 원형 배지는 완전히 제거(중복 표시 정리)
   ※ 이미지가 등록되지 않은 카드를 빈 칸으로 두는 처리와, 이미지 등록 시
     Cloudflare 1일 요청 한도가 급격히 소모되던 문제의 원인 제거는
     assets/js/game.js(cardVisual, getAutoFolderCardImageInfo)에서 처리했다.
   ===================================================================== */

/* ---------- 1) 국가 문양 원 → EN 숫자 ---------- */
#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}
}

/* ---------- 2) 기존 EN 원형 배지 삭제 ---------- */
#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;
}


/* ---- assets/css/v221_affordable_name_highlight.css?v=221 ---- */
/* =====================================================================
   v221 — 사용 가능 카드 표시 방식 변경
   기존: 카드 이름 옆에 "가능" 배지(v218에서 작은 초록 점으로 축소돼 있었음)
   변경: 배지를 완전히 삭제하고, 대신 카드 이름 글자색과 이름이 있는
        상단 박스(제목 영역) 배경색이 초록빛으로 바뀌어 사용 가능 여부를 표시
   ===================================================================== */

#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;
}


/* ---- assets/css/v222_field_layout_fix.css?v=222 ---- */
/* =====================================================================
   v222 — 전투필드 3건 보정
   1) 전투열 "추가효과" 배너가 카드 이름을 가리던 문제 → 배너 전용 공간을
      확보해 카드 내용과 겹치지 않게 이동
   2) 카드 중간 특수능력 표시를 더 간결하게(작은 글씨/여백)
   3) 전투열에서 카드 높이가 슬롯보다 커서 아래쪽이 잘리는 문제 방지
   ===================================================================== */

/* ---------- 3-a) 카드 높이가 슬롯보다 커서 잘리는 문제: box-sizing 정리 ---------- */
/* .unit에 box-sizing:border-box가 빠져 있어 테두리(border)만큼 실제 렌더링
   높이가 슬롯(overflow:hidden)보다 커져 아래쪽 몇 px가 잘리고 있었을 가능성이
   높음 — 슬롯과 동일하게 border-box로 맞춰 테두리가 높이에 포함되게 한다. */
.battlefield-layout .slot,
.battlefield-layout .hq-field-slot,
.battlefield-layout .unit{
  box-sizing:border-box!important;
}

@media (min-width:851px){
  /* ---------- 3-b) 모든 전투열에 기본 여유 높이 추가 ---------- */
  /* 카드·슬롯 자체 크기는 그대로 두고, 라인(칸 전체) 높이만 살짝 늘려
     빠듯했던 여유 공간을 넉넉하게 만든다. */
  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;
  }

  /* ---------- 1) 추가효과 배너: 카드 위 전용 공간으로 이동 ---------- */
  /* 위 3-b 규칙과 선택자 특이도가 같으므로, 더 늘려야 하는 이 규칙을
     파일 안에서 나중에 두어 synergy-active 라인에서 우선 적용되게 한다.
     배너가 뜬 라인만 높이를 한 번 더 늘려 카드를 밀어내지 않고 그 위에
     배너 전용 공간을 확보한다(다른 라인/카드 크기는 영향 없음). */
  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;
}

/* ---------- 2) 특수능력 표시(카드 중간) 간결화 ---------- */
/* v216의 body 접두 선택자가 v218의 숨김 시도를 특이도로 계속 이겨 표시는
   유지되고 있었음(카드 이름과 별개 위치이긴 하나 박스가 크고 눈에 띔) —
   동일 체인에 위치·크기만 훨씬 간결하게 다시 정의(표시 자체는 유지). */
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;
}


/* ---- assets/css/v223_hand_field_badge_fix.css?v=223 ---- */
/* =====================================================================
   v223 — 3건 재보정
   1) "가능" 배지가 계속 보인다는 재보고 → 선택자 특이도를 v216과 동일한
      body 접두 체인까지 끌어올려 어떤 상황에서도 반드시 이기도록 강화
   2) 사용 가능 카드의 이름/이름박스 밝은색 표시도 동일하게 특이도 강화
   3) 전투필드(전투열)에 배치된 유닛은 우측 상단 EN 숫자 원을 표시하지 않음
      (핸드 카드에서는 계속 표시 — 손패에서 낼 때만 필요한 정보이므로)
   ===================================================================== */

/* ---------- 1) '가능' 배지 삭제(강화) ---------- */
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;
}

/* ---------- 2) 사용 가능 카드: 이름/이름박스 밝은색(강화) ---------- */
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;
}

/* ---------- 3) 전투필드 유닛: EN 숫자 원 숨김(핸드 카드는 그대로 표시) ---------- */
.battlefield-layout .unit .uimg::before{
  content:none!important;
  display:none!important;
}


/* ---- assets/css/v224_sample_card_entry_fix.css?v=224 ---- */
/* =====================================================================
   v224 — 샘플 시트형 카드 / EN 테두리 표시 / 필드 잘림 방지 / 등장 방식
   ===================================================================== */

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

/* ---------------------------------------------------------------------
   1~4, 8~9. 샘플 시트 비율과 전투필드 크기
   기존의 세로로 긴 2.7:4.2 카드보다 짧게 만들어 전투열 하단이 잘리지 않는다.
   --------------------------------------------------------------------- */
@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;
}

/* 기존 제목줄 등급은 완전히 제거. v224 등급은 이미지 좌측 상단에 표시한다. */
#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}

/* ---------------------------------------------------------------------
   EN: 사용 가능 박스 제거 + 충족 시 카드 테두리만 밝게
   --------------------------------------------------------------------- */
#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;
}

/* EN 위치: 장수/지략가/병사는 좌하단, 아이템/전술은 우하단 */
#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;
}

/* 전투필드 EN은 이전 요구사항대로 숨긴다. */
.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;
}

/* 자동 글자 맞춤 JS가 계산한 크기를 우선한다. */
.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}
}

/* ---------------------------------------------------------------------
   6~7. 연출 설정의 카드 등장 방식
   --------------------------------------------------------------------- */
.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}
}

/* ---------------------------------------------------------------------
   v224 데스크톱 우선순위 보호
   이전 버전의 body 접두 !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;
  }
}


/* ---- assets/css/v225_card_ui_request.css?v=225 ---- */
/* =====================================================================
   v225 — 핸드/전투필드 카드 UI 요청 반영
   1) 공격·방어·체력 문구 제거, 숫자 확대
   2) 사용 가능 초록 박스 제거, 카드 전체 밝은 외곽선으로 표시
   3) 핸드 카드 사이 1px 간격
   4) 핸드/필드 상단 카드명·종류 표기 통일
   5) 이미지 위 종류 표시 띠 제거
   6) PC 좌측창 5% 확대, 핸드/필드 카드 15% 확대
   ===================================================================== */

/* ---------- 공통: 이미지 위 종류 표시 띠 제거 ---------- */
#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;
}

/* ---------- PC: 좌측창 +5%, 카드 +15% ---------- */
@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    /* v224 실제 표시값(112.86 × 175.56)의 115% */
    --v216-card-w:129.789px;
    --v216-card-h:201.894px;
    --v216-card-gap:6px;
    --v216-hand-w:391.367px;       /* 3장 + 1px 간격 2개 */
    --v216-hand-h:404.788px;       /* 2줄 + 1px 간격 */
    --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]{
    /* 기존 382px의 약 105% */
    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;
}


/* ---- assets/css/v226_card_ui_effect_fix.css?v=226 ---- */
/* =====================================================================
   v226 — 카드 헤더, 전투열, 아이템 수치, 연출 화면 보정
   ===================================================================== */

/* 1) 핸드 카드의 종류/이름 순서를 전투필드와 동일하게 고정한다.
   game.css의 오래된 grid-column 규칙이 핸드 이름을 첫 칸으로 보내던 문제 보정. */
#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;
}

/* 2) PC 전투열 오른쪽 테두리가 잘리지 않도록 표시 여유를 확보한다. */
@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;
  }
}

/* 3) 아이템은 공격/방어/체력 증가값만 0, +2, +3 형식으로 표시한다. */
#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;
}

/* 4) 실제 카드 연출 화면을 관리자 미리보기 프레임과 같은 320 × 170 크기로 표시. */
@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;
  }
}

/* 5) 개별 연출 설정은 프레임 위의 '실제 본진 크기 미리보기' 제목 박스를 표시하지 않는다. */
#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;
}

/* 6) 카드 종류·이름 글씨 확대, 상단 이름표시 칸 5% 확대(24px → 25.2px). */
: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;
  }
}


/* ---- assets/css/v227_layout_perf_manager_fix.css?v=227 ---- */
/* =====================================================================
   v227 — 전투필드 잘림, 초기 로딩, 카드관리 단일 크기 슬라이더 보정
   ===================================================================== */

/* 1) 카드관리: 가로/세로 분리 슬라이더 대신 단일 크기 슬라이더만 표시 */
#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;
}

/* 2) PC 전투필드: 오른쪽 전투열 카드가 잘리지 않도록 슬롯 폭 계산을 유연화 */
@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;
  }
}


/* ---- assets/css/v228_battlefield_loading_rules_fix.css?v=228 ---- */
/* =====================================================================
   v228 — 전투열 실제 폭 복구 + 카드 비율 유지
   원인: 현재 HTML에서는 본진이 board 안으로 이동했지만 예전의 2열
   battlefield-layout(필드 + 우측 레일) 규칙이 남아 보이지 않는 빈 우측 열이
   약 23~25%의 폭을 계속 차지하고 있었다. board를 단일 열 전체 폭으로 복구한다.
   ===================================================================== */
@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;
  }

  /* 삭제된 우측 레일을 위한 빈 grid 열을 제거한다. */
  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;
  }

  /* 전투열은 전체 폭을 쓰되 카드 자체는 기존 2.5:3.89 크기를 유지한다. */
  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;
  }
}


/* ---- assets/css/v229_battlefield_right_clip_fix.css?v=229 ---- */
/* =====================================================================
   v229 — PC 전투필드 우측 전투열/카드 잘림 최종 보정

   원인:
   - .battle-panel이 가운데 정렬 상태인데 .boardwrap에 이전 버전의
     max-width가 남아 있어, 전투 패널의 실제 가로 공간을 전부 사용하지 못함.
   - 고정 카드 폭을 가진 슬롯 그리드가 좁은 화면에서 몇 px 넘치면
     오른쪽 마지막 슬롯/카드가 overflow에 의해 잘릴 수 있었음.
   ===================================================================== */
@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;
  }

  /* 이전 카드 폭 계산에서 남은 max-width와 자동 좌우 여백을 완전히 제거 */
  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;
  }

  /* v216/v225의 행별 고정 formation 폭보다 높은 구체성으로 덮어쓴다. */
  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;
  }
}


/* ---- assets/css/v230_battlefield_full_width_hidden_scroll.css?v=230 ---- */
/* =====================================================================
   v230 — 전투필드 우측 잘림 + 숨김 스크롤 최종 보정

   1) 핸드 카드와 전투필드 카드의 폭/높이를 동일한 v216 변수로 고정한다.
   2) 이전 v229의 1fr 슬롯 축소 규칙을 제거하고 카드가 찌그러지지 않게 한다.
   3) boardwrap/layout/board에 남은 height:100% + overflow:hidden 조합을 해제한다.
   4) battle-panel만 세로 스크롤 컨테이너로 사용하고 스크롤바는 숨긴다.
   ===================================================================== */
@media (min-width:851px){
  /* 이전 낮은 화면용 app 폭(1048px)과 최신 401px + 822px 열의 충돌 제거 */
  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;
  }

  /* 중첩 overflow/고정 높이를 해제하여 전체 보드 높이가 패널 스크롤에 반영되게 한다. */
  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;
  }

  /* 모든 행의 오른쪽 테두리가 board 안쪽에서 끝나도록 고정한다. */
  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;
  }
}


/* ---- assets/css/v231_battlefield_compact_width_scroll.css?v=231 ---- */
/* =====================================================================
   v231 — 전투필드 폭을 5장 기준으로 축소 + 숨김 스크롤 유지

   목적
   1) v230에서 화면 전체로 넓어진 우측 전투영역을 다시 축소한다.
   2) 우측 전투필드는 카드 5장이 딱 들어가는 폭만 확보한다.
   3) 핸드 카드와 전투필드 카드 크기는 동일하게 유지한다.
   4) 세로 스크롤은 유지하되 스크롤바는 계속 숨긴다.
   ===================================================================== */
@media (min-width:851px){
  body.unified-left-layout:not(.ui-mode-mobile-preview){
    --v231-field-gap:2px;
    --v231-left-col-w:401px;
    /* 5장의 동일 카드 + 4개의 2px 간격 + lane padding 16px + board padding 12px + 여유 1px */
    --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;
  }
}


/* ---- assets/css/v232_requested_features.css?v=235 ---- */
/* v232 — 요청 기능 표시 */
/* 아이템 카드는 공/방/체 문구 없이 +값/0만 3칸에 표시 */
#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}

/* 실제 카드 사용 연출은 개별 연출 미리보기의 크기/X/Y를 그대로 적용 */
.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}

/* 개별 연출 설정 미리보기 화면만 기존보다 10% 확대 */
#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}
}

/* v233 — 누락 로드 보완 및 아이템/연출 세부 수정 */
#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;}

/* v234 — 카드 연출 화면을 카드관리 미리보기와 동일한 크롭/표시 방식으로 강제 */
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;
}

/* v234 — 아이템 카드 하단 수치 가독성 및 이미지 꽉 채우기 */
#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;
}

/* v234 — 연출창을 카드관리 미리보기와 더 가깝게, 아이템 카드 가독성/밀착 보강 */
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;
}

/* v234 — 아이템 카드 하단/라벨 제거 및 연출 프리뷰 동기화 보강 */
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;}

/* v235 — 아이템 숫자 검정색 및 체력 3번째 칸 강제 표시 */
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;
}
/* 오래된 item/advisor 규칙이 마지막(체력) 셀을 두 칸 폭으로 보내고 아래로 밀던 문제 수정 */
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;
}


/* ---- assets/css/v236_requested_features.css?v=236 ---- */
/* v236 — 카드상점 이름 확대/중앙 정렬, 카드별 연출 토글 */
#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;}


/* ---- assets/css/v239_balance_skills.css?v=239 ---- */
.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)}


/* ---- assets/css/v240_rank_icons_battle_result.css?v=240 ---- */
/* 삼국지 TCG v240 — 카드 이미지 하단 역할/병과 아이콘 + 전투결과 */
.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}
}


/* ---- assets/css/v241_requested_patch.css?v=241 ---- */
/* v241 — 사용자 요청: 연출창 텍스트 제거/이미지 꽉 채움, 상점·덱 아이콘 정리, 랜덤 비율 글씨 확대, 전술 이펙트 강화 */

/* 1) 실제 애니메이션 화면만 텍스트를 숨기고 이미지가 박스를 가득 채우도록 한다.
   카드 원본/카드관리 이미지 비율·레이아웃 값은 건드리지 않는다. */
.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;
}
/* 이전 버전에서 PC 연출창의 오버레이를 숨기던 규칙을 되돌려 실제 효과는 보이게 한다. */
.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;
}

/* 2) 덱 편집 UI */
.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;
}

/* 3) 덱편집/카드상점 좌하단 병과 아이콘 중복 제거.
   v240 cardVisual 내부 역할/병과 아이콘만 남기며 EN 표시는 유지한다. */
.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;
}

/* 4) 화공 지속 중 카드 하단에 실제 불꽃이 일렁이는 느낌 */
.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)}}


/* ---- assets/css/v242_animation_fill_fix.css?v=242 ---- */
/* v242 — 애니메이션 연출창 텍스트 완전 제거 + 박스 꽉 채우기 */

/* 연출창 내부 텍스트/배지 완전 숨김 */
.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;
}


/* ---- assets/css/v243_advisor_name_effect_gap_fix.css?v=243 ---- */
/* v243 — 책사 이름 잘림 수정 + 연출창 이미지/박스선 여백 완전 제거 */

/* 1) 책사 이름이 아래쪽에서 잘리지 않도록 배지 높이/행간 보정 */
.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;
}

/* 2) 연출 사진과 연출 박스선 사이의 모든 여백 제거 */
.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;
}


/* ---- assets/css/v244_hq_advisor_lane_labels_fix.css?v=244 ---- */
/* v244 — 본진 책사 카드 높이/이름 표시 + 아군 전투열 문구 정리 */

/*
 * 본진 진영의 5번째 칸으로 reparent 된 책사 슬롯은 더 이상 .battle-hq 하위가 아니다.
 * 따라서 본진 책사칸 자체를 기준으로 슬롯/카드/초상화를 열박스 높이에 정확히 맞춘다.
 */
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;
}


/* ---- assets/css/v245_action_buff_animation_rules.css?v=245 ---- */
/* 삼국지 TCG v245 — 버프 아이콘 + 애니메이션 박스 꽉 채움 */

/* 버프 장수 전용 아이콘: 카드 이미지 우측 하단, 기존 좌하단 병과 아이콘/좌상단 EN과 분리 */
.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;}
}

/* 카드 애니메이션 화면: 박스와 이미지 사이 여백 0 */
.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;
}


/* ---- assets/css/v246_buff_target_filter_rules.css?v=246 ---- */
/* 삼국지 TCG v246 — 공격/버프 동시 타깃, 버프 필터, 덱 비율 입력 폭 */

/* 공격 가능 적 카드: 어두운 레이아웃에서도 카드 자체가 확실히 밝아지게 */
.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;}

/* 랜덤 비율 입력: 100도 잘리지 않도록 기존 36px 강제폭보다 넓게 */
.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;}

/* 필터 폴백: 브라우저/레이아웃 CSS가 hidden 표시를 덮어써도 강제로 숨김 */
.v246-filter-hidden{display:none!important;}


/* ---- assets/css/v251_score_badge_deck_ratio.css?v=251 ---- */
/* =====================================================================
   v251 — 카드 점수 배지(EN 원 옆 작은 원) + 스킬 편집 화면 개선 스타일
   ===================================================================== */

/* ---------- 1) 카드 점수 배지: EN 원(우측 상단, right:4px) 왼쪽에 나란히 표시 ---------- */
.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; }
}

/* ---------- 2) 스킬 편집 화면: 상단 툴바(검색·전체 초기화) ---------- */
#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;
}

/* ---------- 3) 탭: 스킬 개수·수정 개수 함께 표시 ---------- */
#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; }

/* ---------- 4) 등급(티어)별 그룹 헤더 ---------- */
.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; }

/* ---------- 5) 스킬 카드: 수정됨 표시 ---------- */
.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; }


/* ---- assets/css/v252_score_badge_below_en.css?v=252 ---- */
/* =====================================================================
   v252 — 카드 점수 배지 위치 조정
   카드 점수는 우측 상단 행동력(EN) 원 바로 아래에 더 작은 원으로 표시한다.
   v251의 점수 계산/마크업은 그대로 사용하고 위치·크기만 덮어쓴다.
   ===================================================================== */
.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;
  }
}


/* ---- assets/css/v257_skill_enhancement.css?v=257 ---- */
.sss-effect-panel{display:none!important}
#boosterPackModal .modalbox{max-width:1080px;width:min(96vw,1080px);max-height:90vh;overflow:auto}

/* v256 — 연의 기반 통합 스킬 / 부스터 강화 */
.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 — 관리자 강화 테스트 / 일반 사용자 강화 가능 대상 필터 */
.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}}


/* ---- assets/css/v258_owned_enhancement_shop_filters.css?v=258 ---- */
/* v258 — 강화 카드 보유 표시 / 카드상점 필터 */
.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}}


/* ---- assets/css/v259_economy_collection_admin.css?v=259 ---- */
/* v259 — 강화 차수 탭 / 계정 보유카드 / GP·BP / 관리자 도구 */
.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}}


/* ---- assets/css/v260_ui_refine.css?v=260 ---- */
/* v260 — 계정바/강화탭/덱편집 UI 정리 */

/* 1) 로그아웃 + GP/BP를 한 줄에 유지 */
.online-account-bar,
.left-auth-logged-in{
  flex-wrap:nowrap!important;
  gap:4px!important;
  align-items:center!important;
}
#logoutBtn,#leftLogoutBtn{
  width:auto!important;
  min-width:50px!important;
  max-width:none!important;
  flex:0 0 auto!important;
  padding:4px 7px!important;
  font-size:10px!important;
  line-height:1.15!important;
  white-space:nowrap!important;
}
.left-auth-logged-in #leftAuthStateText{flex:1 1 auto!important;min-width:0!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}
.v259-wallet,.v259-wallet.compact{flex:0 0 auto!important;margin:0 2px 0 0!important;padding:3px 5px!important;gap:4px!important;font-size:9px!important;white-space:nowrap!important}

/* 2) 강화 탭: 카드 이미지 우측 점수 원 바로 아래 */
.collection-card-art>.v258-enhancement-bookmark{
  left:auto!important;
  right:0!important;
  top:44px!important;
  bottom:auto!important;
  min-width:28px!important;
  height:15px!important;
  padding:0 5px!important;
  border-radius:5px 0 0 5px!important;
  font-size:8px!important;
  line-height:15px!important;
  font-weight:950!important;
  letter-spacing:-.35px!important;
  color:#fff!important;
  text-shadow:0 1px 2px rgba(0,0,0,.75)!important;
  box-shadow:0 2px 5px rgba(0,0,0,.52),inset 0 0 0 1px rgba(255,255,255,.18)!important;
  pointer-events:none!important;
}
.collection-card-art>.v258-enhancement-bookmark:after{display:none!important}
/* 1차 = 청동, 2차 = 백은, 3차 = 황금, 4차 이상 = 자수정/백금 */
.collection-card-art>.v258-enhancement-bookmark[data-enhance-count="1"]{
  background:linear-gradient(135deg,#a76532,#6f391c)!important;
  border:1px solid #d89a66!important;
}
.collection-card-art>.v258-enhancement-bookmark[data-enhance-count="2"]{
  background:linear-gradient(135deg,#dce5ed,#7f94a5 68%,#536675)!important;
  border:1px solid #eef6ff!important;
  color:#10202c!important;
  text-shadow:0 1px 0 rgba(255,255,255,.4)!important;
}
.collection-card-art>.v258-enhancement-bookmark[data-enhance-count="3"]{
  background:linear-gradient(135deg,#fff1a5,#d5a426 58%,#89610f)!important;
  border:1px solid #ffe88a!important;
  color:#291b00!important;
  text-shadow:0 1px 0 rgba(255,255,255,.35)!important;
  box-shadow:0 2px 6px rgba(0,0,0,.5),0 0 7px rgba(255,205,73,.35)!important;
}
.collection-card-art>.v258-enhancement-bookmark.v260-enhance-tier-high{
  background:linear-gradient(135deg,#f0eaff,#a987d8 45%,#5b3a87 78%,#d7c5ff)!important;
  border:1px solid #e6d7ff!important;
  box-shadow:0 2px 7px rgba(0,0,0,.5),0 0 8px rgba(185,145,255,.42)!important;
}

/* 카드상점에서는 강화 카드 외형/탭을 절대 표시하지 않는다. */
#cardShopGrid .v258-enhancement-bookmark{display:none!important}
#cardShopGrid .v258-enhanced-card,
#cardShopGrid .shop-card{
  box-shadow:none!important;
}

/* 3) 덱 편집: 필터/입력 폭 컴팩트화 */
#deckBuilderModal .v246-buff-filter-label{width:62px!important;min-width:62px!important;max-width:62px!important}
#deckBuilderModal #deckBuilderBuffFilter{width:62px!important;min-width:62px!important;max-width:62px!important;padding-left:5px!important;padding-right:16px!important}
#deckBuilderModal #deckRatioGeneral,
#deckBuilderModal #deckRatioAdvisor,
#deckBuilderModal #deckRatioItem,
#deckBuilderModal #deckRatioTactic{
  width:44px!important;
  min-width:44px!important;
  max-width:44px!important;
  padding-left:3px!important;
  padding-right:3px!important;
  text-align:center!important;
  box-sizing:border-box!important;
}
#deckBuilderModal #deckBuilderSearch{
  width:92px!important;
  min-width:92px!important;
  max-width:92px!important;
  flex:0 0 92px!important;
  padding-left:6px!important;
  padding-right:6px!important;
}
#deckBuilderModal .deck-builder-search-cluster{flex:0 1 auto!important}
#deckBuilderModal .deck-auto-ratio-inline{gap:4px!important;padding:4px 6px!important}

@media(max-width:850px){
  .collection-card-art>.v258-enhancement-bookmark{right:-1px!important;top:37px!important;min-width:24px!important;height:13px!important;padding:0 4px!important;font-size:7px!important;line-height:13px!important}
  #deckBuilderModal .v246-buff-filter-label,#deckBuilderModal #deckBuilderBuffFilter{width:60px!important;min-width:60px!important;max-width:60px!important}
  #deckBuilderModal #deckRatioGeneral,#deckBuilderModal #deckRatioAdvisor,#deckBuilderModal #deckRatioItem,#deckBuilderModal #deckRatioTactic{width:43px!important;min-width:43px!important;max-width:43px!important}
  #deckBuilderModal #deckBuilderSearch{width:88px!important;min-width:88px!important;max-width:88px!important;flex-basis:88px!important}
}


/* ---- assets/css/v261_enhanced_variants_images.css?v=261 ---- */
/* v261 — 강화 변형 카드/강화 이미지 관리자 */
.v261-variant-chip{position:absolute;left:7px;bottom:7px;z-index:8;display:inline-flex;align-items:center;justify-content:center;min-width:38px;height:20px;padding:0 7px;border-radius:999px;background:rgba(17,24,39,.86);border:1px solid rgba(255,255,255,.32);color:#fff;font-size:10px;font-weight:900;letter-spacing:-.02em;box-shadow:0 2px 7px rgba(0,0,0,.3);pointer-events:none}
.v261-deck-enhanced .v261-variant-chip,.deck-builder-visual-card.v258-enhanced-card .v261-variant-chip{background:linear-gradient(135deg,#6f4b11,#d4af37 55%,#fff1a8);color:#211704;border-color:#ffe69a}
.v261-deck-base .deck-owned-outside small:first-child{color:#cbd5e1}.v261-deck-enhanced .deck-owned-outside small:first-child{color:#f7d774}

.v261-enhancement-image-manager{margin:10px 0 12px;padding:10px;border:1px solid rgba(212,175,55,.42);border-radius:12px;background:rgba(15,23,42,.58)}
.v261-enh-image-title{display:flex;flex-direction:column;gap:2px;margin-bottom:8px}.v261-enh-image-title b{font-size:13px;color:#f6d783}.v261-enh-image-title small{font-size:10px;color:#aeb8ca;line-height:1.45}
.v261-enh-image-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.v261-enh-image-slot{min-width:0;padding:7px;border:1px solid rgba(148,163,184,.25);border-radius:10px;background:rgba(2,6,23,.52)}
.v261-enh-image-preview{position:relative;aspect-ratio:3/4;border-radius:8px;overflow:hidden;background:#111827;border:1px solid rgba(255,255,255,.12);display:flex;align-items:center;justify-content:center}.v261-enh-image-preview img{width:100%;height:100%;object-fit:cover;display:block}.v261-enh-image-preview>span{position:absolute;right:5px;bottom:5px;padding:2px 5px;border-radius:5px;background:rgba(0,0,0,.72);color:#fff;font-size:10px;font-weight:900}.v261-no-image{font-size:10px;color:#64748b}
.v261-enh-image-actions{display:flex;gap:4px;align-items:center;margin-top:6px}.v261-enh-image-actions .manager-upload-label{flex:1;margin:0;padding:5px 6px;font-size:10px;text-align:center}.v261-enh-image-actions .btn{padding:5px 7px;font-size:10px}.v261-enh-image-slot>small{display:block;margin-top:5px;min-height:24px;font-size:9px;line-height:1.3;color:#94a3b8}
@media(max-width:760px){.v261-enh-image-grid{grid-template-columns:1fr}.v261-enh-image-preview{aspect-ratio:16/8}.v261-enh-image-preview img{object-position:center 28%}}


/* ---- assets/css/v262_starter_decks_episode.css?v=262 ---- */
/* v262 — 기본덱 설정 / 가입 스타터덱 / 빠른편집 숫자폭·에피소드 */
.v262-starter-signup-label{display:flex;align-items:center;gap:6px;font-size:12px;color:var(--muted,#b9b3a6)}
.v262-starter-signup-label select{flex:1;min-width:0}
.v262-starter-signup-note{font-size:11px;line-height:1.35;opacity:.82}
.v262-base-deck-box{width:min(1120px,94vw);max-width:1120px}
.v262-base-toolbar{display:flex;align-items:end;gap:8px;flex-wrap:wrap;margin:10px 0 12px}
.v262-base-toolbar label{display:grid;gap:4px;font-size:12px}
.v262-base-toolbar input{width:130px}
.v262-base-summary{margin-left:auto;padding:7px 10px;border:1px solid rgba(166,215,164,.38);border-radius:8px;background:rgba(30,80,38,.22);font-size:12px;white-space:nowrap}
.v262-base-summary.invalid{border-color:rgba(239,116,116,.55);background:rgba(95,26,26,.24)}
.v262-base-main{display:grid;grid-template-columns:1fr 1fr;gap:12px;min-height:460px}
.v262-base-main>section{min-width:0;border:1px solid rgba(255,255,255,.12);border-radius:10px;padding:10px;background:rgba(0,0,0,.16)}
.v262-base-main h3{margin:0 0 8px;font-size:14px}
.v262-base-list{height:430px;overflow:auto;display:flex;flex-direction:column;gap:5px;padding-right:3px}
.v262-base-row{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:7px 8px;border:1px solid rgba(255,255,255,.1);border-radius:7px;background:rgba(255,255,255,.035)}
.v262-base-row>div:first-child{min-width:0;display:grid;gap:2px}.v262-base-row b{font-size:12px}.v262-base-row small{font-size:10px;opacity:.75}
.v262-base-step{display:flex;align-items:center;gap:5px;flex:0 0 auto}.v262-base-step b{min-width:20px;text-align:center}
.quick-stats-table .qs-stat-number{width:5.2ch!important;min-width:5.2ch!important;max-width:5.2ch!important;padding-left:4px!important;padding-right:2px!important}
.quick-stats-table .qs-episode{width:8.5ch!important;min-width:8.5ch!important;padding-left:4px!important;padding-right:3px!important}
.quick-stats-toolbar #quickStatsEpisode{min-width:74px}
@media(max-width:800px){.v262-base-main{grid-template-columns:1fr}.v262-base-list{height:300px}.v262-base-summary{margin-left:0}.v262-base-deck-box{width:96vw}}


/* ---- assets/css/v263_starter_inventory_deck_return.css?v=263 ---- */
/* v263 — 미강화 라벨 제거 / 기본덱 선택 표시 정리 */
.v263-base-owned-meta{justify-content:flex-end!important}
.v261-deck-base .v261-variant-chip{display:none!important}
.v261-deck-base .deck-owned-outside small:first-child:empty{display:none!important}
#battleDeckSelect option[value^="default:"]{font-weight:700}


/* ---- assets/css/v264_policy_decks_results.css?v=264 ---- */
/* v264 — GP/BP + 로그아웃 컴팩트 / 저장덱 명시 조작 */
#leftLogoutBtn,#logoutBtn{
  flex:0 0 4.8em!important;
  width:4.8em!important;
  min-width:4.8em!important;
  max-width:4.8em!important;
  padding-left:.3em!important;
  padding-right:.3em!important;
  white-space:nowrap!important;
}
.left-auth-logged-in .v259-wallet{margin-left:auto!important;margin-right:4px!important}
.v259-wallet[hidden]{display:none!important}
#v264DeckLoadBtn{white-space:nowrap}
#deckBuilderClearSavedBtn:disabled,#v264DeckLoadBtn:disabled{opacity:.45;cursor:not-allowed}
@media(max-width:760px){
  #leftLogoutBtn,#logoutBtn{flex-basis:4.8em!important;width:4.8em!important;min-width:4.8em!important;max-width:4.8em!important}
}


/* ---- assets/css/v265_episode_boosters_nickname.css?v=271 ---- */
/* v265 — 로그인 ID/닉네임 + 에피소드 부스터팩 */
.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 — 공개 부스터 다중 개봉 + 순차 카드 공개 */
.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 — 부스터 개봉 버튼 가시성 강화 */
.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}}


/* ---- assets/css/v272_booster_controls_hardfix.css?v=272 ---- */
/* v272 — booster controls hard fix. Loaded with a new filename to bypass stale caches. */
#boosterPackGrid .v270-booster-purchase,
#boosterPackGrid .v271-booster-purchase{display:none!important}
#boosterPackGrid .v272-booster-controls{
  display:block!important;
  visibility:visible!important;
  opacity:1!important;
  box-sizing:border-box;
  width:100%;
  margin:10px 0 14px;
  padding:12px;
  border:2px solid rgba(224,177,70,.88);
  border-radius:10px;
  background:linear-gradient(180deg,rgba(38,28,13,.98),rgba(19,15,11,.98));
  box-shadow:0 0 0 1px rgba(255,222,137,.10) inset,0 6px 18px rgba(0,0,0,.24);
}
#boosterPackGrid .v272-booster-title{
  display:flex!important;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  margin:0 0 10px;
  color:#ffe29a;
  font-size:14px;
  font-weight:900;
  letter-spacing:.02em;
}
#boosterPackGrid .v272-booster-admin-badge{
  padding:3px 7px;
  border:1px solid rgba(255,217,109,.58);
  border-radius:999px;
  color:#fff0bc;
  font-size:10px;
  white-space:nowrap;
}
#boosterPackGrid .v272-booster-row{
  display:grid!important;
  grid-template-columns:72px minmax(0,1fr);
  align-items:center;
  gap:8px;
  margin-top:7px;
}
#boosterPackGrid .v272-booster-row-label{
  color:#f6ddb0;
  font-size:12px;
  font-weight:900;
  white-space:nowrap;
}
#boosterPackGrid .v272-booster-buttons{
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:6px;
}
#boosterPackGrid .v272-booster-btn{
  display:inline-flex!important;
  visibility:visible!important;
  opacity:1!important;
  min-width:0!important;
  min-height:36px!important;
  align-items:center!important;
  justify-content:center!important;
  padding:7px 6px!important;
  border:1px solid rgba(224,177,70,.72)!important;
  background:rgba(44,34,19,.96)!important;
  color:#ffe7a7!important;
  font-size:11px!important;
  font-weight:900!important;
  line-height:1.15!important;
  white-space:normal!important;
  cursor:pointer!important;
  pointer-events:auto!important;
}
#boosterPackGrid .v272-booster-btn:hover{filter:brightness(1.18)}
#boosterPackGrid .v272-booster-btn.is-gp{background:rgba(58,43,15,.98)!important}
#boosterPackGrid .v272-booster-btn.is-bp{background:rgba(20,39,59,.98)!important;border-color:rgba(114,174,230,.70)!important;color:#d9efff!important}
@media(max-width:760px){
  #boosterPackGrid .v272-booster-controls{padding:10px}
  #boosterPackGrid .v272-booster-row{grid-template-columns:1fr;gap:5px}
  #boosterPackGrid .v272-booster-buttons{grid-template-columns:repeat(2,minmax(0,1fr))}
  #boosterPackGrid .v272-booster-btn{min-height:40px!important;font-size:12px!important}
}


/* ---- assets/css/v274_booster_shop_patch.css?v=274 ---- */
/* v273 — compact booster layout / pack detail / public-shop indicator */
#boosterPackGrid .booster-card.v273-compact-pack{
  display:grid!important;
  grid-template-columns:minmax(120px,30%) minmax(0,1fr)!important;
  column-gap:16px!important;
  row-gap:8px!important;
  align-items:start!important;
  overflow:visible!important;
}
#boosterPackGrid .booster-card.v273-compact-pack > .v265-pack-cover,
#boosterPackGrid .booster-card.v273-compact-pack > .pack-art{
  grid-column:1!important;
  grid-row:1 / span 30!important;
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  align-self:start!important;
  position:relative!important;
}
#boosterPackGrid .booster-card.v273-compact-pack > :not(.v265-pack-cover):not(.pack-art){grid-column:2!important;min-width:0}
#boosterPackGrid .v273-pack-cover{cursor:pointer!important;position:relative!important;outline:none}
#boosterPackGrid .v273-pack-cover:hover{border-color:rgba(245,211,124,.82)!important;filter:brightness(1.05)}
.v273-cover-hint{position:absolute;left:6px;right:6px;bottom:6px;z-index:2;display:block;padding:5px 7px;border-radius:6px;background:rgba(4,4,4,.78);color:#f8e6b5;font-size:9px;font-style:normal;text-align:center;line-height:1.2;pointer-events:none}
.v273-pack-composition{display:grid;gap:7px;padding:10px;border:1px solid rgba(232,196,108,.20);border-radius:9px;background:rgba(255,255,255,.025)}
.v273-composition-title{display:flex;align-items:center;justify-content:space-between;gap:8px}.v273-composition-title b{font-size:12px;color:#f2d27f}.v273-composition-title span{font-size:9px;opacity:.7}
.v273-grade-summary,.v273-detail-grade-summary{display:flex;gap:5px;flex-wrap:wrap}.v273-grade-chip{display:inline-flex;gap:4px;align-items:center;padding:3px 7px;border:1px solid rgba(255,255,255,.12);border-radius:999px;background:rgba(0,0,0,.18);font-size:9px}.v273-grade-chip b{color:#f3d27e}
.v273-composition-list,.v273-detail-composition{display:grid;gap:4px}.v273-composition-row{display:grid;grid-template-columns:34px minmax(0,1fr);gap:7px;align-items:start;font-size:9px;line-height:1.45}.v273-composition-row>b{color:#f0cf7b}.v273-composition-row>span{opacity:.86;overflow-wrap:anywhere}.v273-composition-empty{font-size:10px;opacity:.65}
.v273-view-pack-btn{justify-self:start!important;min-height:30px!important;padding:5px 10px!important;font-size:10px!important}
#boosterPackGrid .v272-booster-controls{margin:0!important}

.v273-pack-detail-box{width:min(1180px,96vw)!important;max-width:1180px!important;max-height:92vh!important;overflow:auto!important}
.v273-pack-detail-hero{display:grid;grid-template-columns:minmax(150px,30%) minmax(0,1fr);gap:16px;align-items:start;padding:12px 0 16px;border-bottom:1px solid rgba(232,196,108,.18)}
.v273-detail-cover-wrap .v265-pack-cover{width:100%;margin:0;position:relative;cursor:default}.v273-detail-cover-wrap .v273-cover-hint{display:none}
.v273-detail-summary{display:grid;gap:10px;min-width:0}.v273-detail-composition{padding:9px;border:1px solid rgba(255,255,255,.09);border-radius:8px;background:rgba(255,255,255,.02)}
.v273-detail-booster-controls{display:grid;gap:8px;padding:10px;border:1px solid rgba(224,177,70,.48);border-radius:9px;background:rgba(37,28,14,.72)}
.v273-detail-booster-title{font-size:12px;font-weight:900;color:#f4d47f}.v273-detail-booster-row{display:grid;grid-template-columns:72px minmax(0,1fr);gap:8px;align-items:center}.v273-detail-booster-row>b{font-size:10px;color:#ead7a5}.v273-detail-booster-row>div{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px}.v273-detail-booster-row .btn{min-width:0!important;padding:7px 5px!important;font-size:9px!important;white-space:normal!important}
.v273-pack-detail-section{padding-top:14px}.v273-pack-detail-section>h3{margin:0 0 10px;color:#f1d17b;font-size:14px}
.v273-pack-detail-cards{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px}.v273-pack-card-tile{position:relative;min-width:0}.v273-pack-card-tile .shop-card{width:100%;box-sizing:border-box}.v273-pack-card-rank{position:absolute;left:5px;top:5px;z-index:7;min-width:22px;padding:3px 5px;border-radius:999px;background:rgba(0,0,0,.76);border:1px solid rgba(239,204,111,.42);font-size:9px;text-align:center;color:#f5dc9a}.v273-pack-card-caption{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:4px;align-items:center;margin-top:4px;font-size:9px}.v273-pack-card-caption>b{color:#f2d17b}.v273-pack-card-caption>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.v273-pack-card-caption>em{font-style:normal;opacity:.65}

/* 관리자 에피소드 부스터 편집: 표지 자체 클릭은 사용자용 상세 화면. 업로드는 문구 클릭. */
#v265PackAdminGrid .v273-admin-cover-preview{cursor:pointer!important;position:relative!important}
#v265PackAdminGrid .v265-cover-editor>span{position:relative;z-index:3;display:inline-block;padding:4px 7px;border:1px solid rgba(232,196,108,.25);border-radius:6px;cursor:pointer}

/* 일반 사용자는 실제 공개+발매 완료 카드만 표시한다는 안내를 상점 헤더에 추가할 수 있도록 여백 확보 */
html:not(.is-card-admin) #cardShopModal .card-shop-head::after{content:'일반 유저: 공개 카드만 표시';display:inline-flex;align-items:center;margin-left:8px;padding:3px 7px;border:1px solid rgba(232,196,108,.24);border-radius:999px;color:#d9c58f;font-size:9px;white-space:nowrap}
html.is-card-admin #cardShopModal .card-shop-head::after{content:'관리자: 전체 카드 표시';display:inline-flex;align-items:center;margin-left:8px;padding:3px 7px;border:1px solid rgba(232,196,108,.24);border-radius:999px;color:#f0d47d;font-size:9px;white-space:nowrap}

@media(max-width:900px){
  .v273-pack-detail-cards{grid-template-columns:repeat(4,minmax(0,1fr))}
}
@media(max-width:760px){
  #boosterPackGrid .booster-card.v273-compact-pack{grid-template-columns:minmax(92px,30%) minmax(0,1fr)!important;column-gap:10px!important}
  .v273-composition-row{grid-template-columns:28px minmax(0,1fr);font-size:8px}.v273-cover-hint{font-size:8px;padding:4px}
  .v273-pack-detail-hero{grid-template-columns:minmax(100px,30%) minmax(0,1fr);gap:10px}.v273-detail-booster-row{grid-template-columns:1fr}.v273-detail-booster-row>div{grid-template-columns:repeat(2,minmax(0,1fr))}.v273-pack-detail-cards{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media(max-width:520px){
  #boosterPackGrid .booster-card.v273-compact-pack{grid-template-columns:minmax(82px,30%) minmax(0,1fr)!important;column-gap:8px!important;padding:10px!important}
  .v273-pack-composition{padding:7px}.v273-composition-list{max-height:110px;overflow:auto}.v273-pack-detail-cards{grid-template-columns:repeat(2,minmax(0,1fr))}
  html:not(.is-card-admin) #cardShopModal .card-shop-head::after,html.is-card-admin #cardShopModal .card-shop-head::after{display:none}
}
/* 오른쪽 정보 흐름: 팩 제목 → 기본 정보 → 구성 → 개봉 버튼 → 확률 */
#boosterPackGrid .booster-card.v273-compact-pack > .v265-pack-head{order:1}
#boosterPackGrid .booster-card.v273-compact-pack > p{order:2}
#boosterPackGrid .booster-card.v273-compact-pack > .v265-pack-factions{order:3}
#boosterPackGrid .booster-card.v273-compact-pack > .v273-pack-composition{order:4}
#boosterPackGrid .booster-card.v273-compact-pack > .v272-booster-controls{order:5}
#boosterPackGrid .booster-card.v273-compact-pack > small{order:6}

/* ================================================================
   v274 — 부스터 구성/결과 카드는 카드 상점과 동일한 DOM·크기·내용 사용
   .card-shop-grid + .shop-card-entry + .shop-card 규칙을 그대로 상속한다.
   ================================================================ */
#v273PackDetailCards.v274-booster-card-grid,
#v274BoosterResultGrid.v274-booster-results-grid{
  flex:none!important;
  min-height:0!important;
  max-height:none!important;
  overflow:visible!important;
  box-sizing:border-box!important;
}
.v274-booster-result-box{
  width:min(1180px,96vw)!important;
  max-width:1180px!important;
  max-height:92vh!important;
  overflow:auto!important;
}
.v274-booster-result-box #v270BoosterResultProgress{
  color:#d9c58f!important;
}
/* 결과는 획득 배열 순서를 그대로 DOM 순서로 출력한다. 별도 다음/한장 공개 UI 없음. */
#v274BoosterResultGrid .shop-card-entry,
#v273PackDetailCards .shop-card-entry{
  order:initial!important;
}


/* ---- assets/css/v267_game_modes_scenario.css?v=267 ---- */
/* v267 — 게임 모드 선택 / 시나리오 진행 */
.v267-mode-box{width:min(900px,94vw);max-width:900px}
.v267-mode-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin-top:14px}
.v267-mode-card{display:flex;flex-direction:column;gap:12px;padding:18px;border:1px solid rgba(214,176,103,.38);border-radius:12px;background:rgba(17,20,27,.92);min-height:280px}
.v267-mode-card.scenario{background:linear-gradient(145deg,rgba(37,22,19,.96),rgba(17,20,27,.96))}
.v267-mode-card h3{margin:0;font-size:20px}.v267-mode-card p{margin:0;color:#c9c2b4;line-height:1.5}
.v267-mode-card label{display:grid;gap:6px;font-weight:800}.v267-mode-card select{width:100%}
.v267-mode-card .btn{margin-top:auto;width:100%}
.v267-mode-desc{padding:10px 12px;border-radius:8px;background:rgba(255,255,255,.055);color:#d8d2c6;font-size:13px;line-height:1.55}
.v267-scenario-progress{display:grid;gap:5px;padding:13px 14px;border:1px solid rgba(230,181,86,.42);border-radius:9px;background:rgba(126,72,24,.16)}
.v267-scenario-progress b{font-size:19px;color:#f0c66e}.v267-scenario-progress span{font-size:13px;color:#ddd2bd}
.v267-mode-note{margin-top:14px;padding:10px 12px;border-radius:8px;background:rgba(112,126,158,.12);font-size:12px;color:#bbbfc9}
@media(max-width:720px){.v267-mode-grid{grid-template-columns:1fr}.v267-mode-card{min-height:0;padding:14px}.v267-mode-box{max-height:90vh;overflow:auto}}


/* ---- assets/css/v269_conquest_campaign.css?v=270 ---- */
/* v269 — 정복 지도 시각 강화 + 주요 거점 성채 + 스토리 이미지 */
#v267GameModeModal .v267-mode-grid{grid-template-columns:repeat(auto-fit,minmax(240px,1fr));}
#v267GameModeModal .v267-mode-box{width:min(1200px,96vw);max-width:1200px;}
.v267-mode-card.conquest{background:linear-gradient(145deg,rgba(19,28,22,.96),rgba(17,20,27,.96));}
.v268-locked-faction{padding:10px 12px;border:1px solid rgba(214,176,103,.38);border-radius:8px;background:rgba(255,255,255,.04);font-weight:800;}
.v268-gate-badge{color:#ffb347;}

.v268-path-box{width:min(1120px,97vw);max-width:1120px;}

/* 지도(SVG) — 밝은 고서 지도 스타일 */
.v268-map-wrap{margin-top:10px;border:1px solid rgba(230,181,86,.5);border-radius:12px;overflow:hidden;background:#2c2114;box-shadow:0 6px 22px rgba(0,0,0,.4),inset 0 0 40px rgba(0,0,0,.35);}
.v268-map-svg{display:block;width:100%;height:auto;max-height:66vh;}
.v268-map-frame-outer{fill:none;stroke:#e6b556;stroke-width:3;}
.v268-map-frame-inner{fill:none;stroke:rgba(230,181,86,.45);stroke-width:1;}
.v268-map-region-label{fill:#3a2c18;font-size:18px;font-weight:900;letter-spacing:3px;opacity:.52;text-anchor:middle;pointer-events:none;text-transform:uppercase;}
.v268-map-river{fill:none;stroke:#5fa0c9;stroke-width:4;opacity:.55;stroke-linecap:round;}
.v268-map-river2{opacity:.5;}
.v268-map-route-full{fill:none;stroke:#8a7a5c;stroke-width:2;stroke-dasharray:6 6;opacity:.6;}
.v268-map-route-done{fill:none;stroke:#e6b556;stroke-width:4;opacity:.95;filter:drop-shadow(0 0 4px rgba(230,181,86,.6));}
.v268-map-compass{pointer-events:none;}
.v268-map-compass circle{fill:rgba(255,255,255,.05);stroke:#e6b556;stroke-width:1.5;opacity:.7;}
.v268-map-compass-needle{fill:#e6b556;opacity:.85;}
.v268-map-compass-n{fill:#e6b556;font-size:13px;font-weight:900;text-anchor:middle;opacity:.85;}
.v268-map-node{cursor:pointer;}
.v268-map-node circle{stroke-width:3;transition:r .12s ease,filter .12s ease,stroke-width .12s ease;}
.v268-map-node:hover circle{filter:brightness(1.35);}
.v268-map-node:hover .v268-map-label{fill:#fff3d6;}
.v268-map-label-halo{font-size:15px;font-weight:900;stroke:#241a0e;stroke-width:4;paint-order:stroke;text-anchor:middle;pointer-events:none;}
.v268-map-label{font-size:15px;font-weight:900;fill:#f0e8d6;text-anchor:middle;pointer-events:none;}
.v268-map-order{font-size:11px;font-weight:900;fill:#241a0e;text-anchor:middle;pointer-events:none;}
.v268-map-check{font-size:15px;font-weight:900;fill:#0e2312;text-anchor:middle;pointer-events:none;}
.v268-map-gate-icon{font-size:17px;fill:#ffcf6e;text-anchor:middle;pointer-events:none;filter:drop-shadow(0 0 3px rgba(255,180,50,.7));}
/* 경로 미포함 성: 흐린 점 */
.v268-map-off .v268-map-node-circle{fill:url(#v268NodeDim);stroke:#4a3c26;}
.v268-map-off .v268-map-label,.v268-map-off .v268-map-label-halo{font-size:12px;opacity:.74;}
/* 아직 잠긴 목표: 회청색 */
.v268-map-locked .v268-map-node-circle{fill:url(#v268NodeGrey);stroke:#2c3742;}
/* 다음 목표: 금색 + 맥동 링 */
.v268-map-current .v268-map-node-circle{fill:url(#v268NodeGold);stroke:#fff3d6;}
.v268-map-ring{fill:none;stroke:#e6b556;stroke-width:2;opacity:.6;animation:v268PulseRing 1.6s ease-out infinite;}
@keyframes v268PulseRing{0%{opacity:.72;stroke-width:3;}100%{opacity:0;stroke-width:1;}}
.v268-map-current .v268-map-node-circle{animation:v268PulseGlow 1.6s ease-in-out infinite;}
@keyframes v268PulseGlow{0%,100%{filter:drop-shadow(0 0 2px rgba(230,181,86,.6));}50%{filter:drop-shadow(0 0 10px rgba(255,210,120,.95));}}
.v268-map-current .v268-map-label{fill:#ffe3a0;font-weight:900;}
/* 함락 완료: 초록 + 체크 */
.v268-map-done .v268-map-node-circle{fill:url(#v268NodeGreen);stroke:#c8f0cc;}
.v268-map-done .v268-map-label{fill:#c8f0cc;}
/* 최고 관문: 두꺼운 금테 */
.v268-map-gate .v268-map-node-circle{stroke-width:3.5;stroke:#ffcf6e;}
/* 선택된 노드 강조 */
.v268-map-selected .v268-map-node-circle{stroke:#fff;stroke-width:4;}
.v268-map-legend{display:flex;flex-wrap:wrap;gap:14px;margin-top:9px;padding:8px 12px;border-radius:8px;background:rgba(255,255,255,.03);border:1px solid rgba(255,255,255,.07);font-size:11px;color:#c9c2b4;align-items:center;}
.v268-legend-dot{display:inline-block;width:11px;height:11px;border-radius:50%;margin-right:5px;vertical-align:-1px;}
.v268-legend-current{background:#e6b556;box-shadow:0 0 5px rgba(230,181,86,.7);}
.v268-legend-done{background:#4c8f5a;}
.v268-legend-locked{background:#4a5866;}
.v268-legend-off{background:#6b5c3e;}
.v268-legend-star{color:#ffcf6e;font-weight:900;}
.v268-map-info{margin-top:9px;padding:11px 13px;border-radius:8px;border:1px solid rgba(230,181,86,.28);background:rgba(255,255,255,.03);font-size:12px;line-height:1.65;color:#d8d2c6;min-height:20px;}
.v268-map-info b{color:#f0e8d6;}
.v268-map-action-btn{margin-top:9px;width:100%;font-weight:900;}

.v268-path-list{display:grid;gap:6px;max-height:22vh;overflow:auto;margin-top:10px;}
.v268-path-row{display:grid;grid-template-columns:32px 1.1fr 1fr 1.3fr auto auto;gap:10px;align-items:center;padding:9px 11px;border:1px solid rgba(255,255,255,.08);border-radius:8px;font-size:12px;background:rgba(255,255,255,.02);}
.v268-path-step{font-weight:900;color:#e6b556;text-align:center;}
.v268-path-name{font-weight:800;color:#f0e8d6;}
.v268-path-gen{color:#c9c2b4;}
.v268-path-tag{color:#9aa3b5;font-size:11px;}
.v268-path-reward{color:#f0c66e;white-space:nowrap;}
.v268-path-status{font-weight:800;text-align:right;white-space:nowrap;}
.v268-path-row.v268-done{opacity:.6;border-color:rgba(120,200,120,.4);}
.v268-path-row.v268-done .v268-path-status{color:#8fd18f;}
.v268-path-row.v268-current{border-color:#e6b556;background:rgba(230,181,86,.14);}
.v268-path-row.v268-current .v268-path-status{color:#f0c66e;}
.v268-path-row.v268-locked{opacity:.42;}
.v268-path-row.v268-locked .v268-path-status{color:#9aa3b5;}

@media(max-width:720px){
  .v268-path-row{grid-template-columns:1fr;gap:3px;}
  .v268-path-status{text-align:left;}
}


/* v269 — 주요 거점/스토리 이미지 시각 강화 */
.v269-map-major .v268-map-node-circle{stroke-width:4;filter:drop-shadow(0 2px 5px rgba(0,0,0,.55));}
.v269-map-castle{pointer-events:none;filter:drop-shadow(0 2px 2px rgba(0,0,0,.65));}
.v269-map-castle use{fill:#f1cf83;stroke:#2b1b0e;stroke-width:.8;paint-order:stroke;}
.v268-map-done.v269-map-major .v269-map-castle use{fill:#bfe7c4;}
.v268-map-locked.v269-map-major .v269-map-castle use{fill:#aeb8c2;}
.v268-map-off.v269-map-major .v269-map-castle use{fill:#b7a77f;opacity:.8;}
.v269-map-story-mark{pointer-events:none;filter:drop-shadow(0 1px 2px rgba(0,0,0,.7));}
.v269-map-story-mark rect{fill:#f2d58e;stroke:#2a1d0f;stroke-width:1;}
.v269-map-story-mark circle,.v269-map-story-mark path{fill:#6d4f27;stroke:none;}
.v269-legend-castle{color:#f1cf83;font-weight:900;}
.v269-legend-story{color:#f2d58e;font-weight:800;}

.v269-map-detail{display:grid;grid-template-columns:minmax(260px,.9fr) minmax(300px,1.1fr);gap:14px;align-items:stretch;}
.v269-map-detail-copy{display:flex;flex-direction:column;gap:5px;min-width:0;}
.v269-city-title{font-size:16px;line-height:1.35;}
.v269-city-title b{color:#fff0c9;}
.v269-city-castle{font-size:18px;filter:drop-shadow(0 1px 2px rgba(0,0,0,.5));}
.v269-city-tag{color:#b9c1cc;}
.v269-story-panel{min-width:0;border-left:1px solid rgba(230,181,86,.18);padding-left:14px;display:flex;flex-direction:column;gap:8px;justify-content:center;}
.v269-story-image{position:relative;width:100%;height:234px;padding:0;border:1px solid rgba(230,181,86,.38);border-radius:10px;overflow:hidden;background:#17120c;cursor:zoom-in;box-shadow:0 5px 16px rgba(0,0,0,.28);}
.v269-story-image img{display:block;transition:filter .22s ease;}
.v269-story-image:hover img{filter:brightness(1.08);}
.v269-story-image.v269-story-draggable{cursor:grab;}
.v269-story-image.v269-story-draggable:active{cursor:grabbing;}
.v269-story-image.v269-story-conquered img{filter:grayscale(1);}
.v269-story-image.v269-story-conquered:hover img{filter:grayscale(1) brightness(1.08);}
.v269-story-conquered-badge{position:absolute;left:7px;bottom:7px;z-index:2;padding:3px 8px;border-radius:999px;background:rgba(0,0,0,.72);border:1px solid rgba(232,196,108,.4);color:#e7dcc0;font-size:10px;font-weight:800;letter-spacing:.03em;pointer-events:none;}
.v269-story-lightbox-card img.v269-conquered-photo{filter:grayscale(1);}
.v269-story-layout-editor{display:grid;gap:6px;padding:9px 0 2px;border-top:1px dashed rgba(230,181,86,.22);margin-top:2px;}
.v269-story-layout-title{font-size:11px;font-weight:900;color:#f0cf7b;}
.v269-story-layout-row{display:grid;grid-template-columns:64px 1fr 42px;gap:8px;align-items:center;font-size:10px;color:#d8d2c6;}
.v269-story-layout-row input[type="range"]{width:100%;}
.v269-story-layout-actions{display:flex;gap:7px;padding-top:2px;}
.v269-story-layout-actions .btn{padding:6px 10px;font-size:10px;}
.v269-story-layout-hint{font-size:9px;opacity:.65;}
.v269-story-empty{min-height:82px;border:1px dashed rgba(230,181,86,.3);border-radius:10px;display:flex;align-items:center;justify-content:center;text-align:center;padding:12px;color:#9e978b;background:rgba(0,0,0,.12);}
.v269-story-admin{display:flex;gap:7px;align-items:center;flex-wrap:wrap;padding-top:2px;}
.v269-story-admin .btn{padding:7px 10px;font-size:11px;}
.v269-story-admin span{font-size:10px;color:#8f98a7;}
.v269-story-lightbox{position:fixed;inset:0;z-index:10050;display:none;align-items:center;justify-content:center;padding:28px;background:rgba(5,5,7,.88);backdrop-filter:blur(5px);}
.v269-story-lightbox.show{display:flex;}
.v269-story-lightbox-card{max-width:min(1100px,92vw);max-height:88vh;border:1px solid rgba(230,181,86,.5);border-radius:14px;overflow:hidden;background:#15110c;box-shadow:0 18px 70px rgba(0,0,0,.65);}
.v269-story-lightbox-card img{display:block;max-width:92vw;max-height:82vh;object-fit:contain;background:#090806;}
.v269-story-lightbox-title{padding:10px 14px;text-align:center;font-weight:900;color:#f1d69e;}
.v269-story-lightbox-close{position:fixed;right:24px;top:18px;width:42px;height:42px;border:1px solid rgba(255,255,255,.24);border-radius:50%;background:rgba(0,0,0,.45);color:white;font-size:30px;line-height:36px;cursor:pointer;}

@media(max-width:820px){
  .v268-map-label,.v268-map-label-halo{font-size:13px;}
  .v268-map-off .v268-map-label,.v268-map-off .v268-map-label-halo{font-size:11px;}
  .v269-map-detail{grid-template-columns:1fr;}
  .v269-story-panel{border-left:0;border-top:1px solid rgba(230,181,86,.18);padding-left:0;padding-top:10px;}
  .v269-story-image{height:281px;}
}


/* ---- assets/css/v275_card_zoom_layer_fix.css?v=275 ---- */
/* v275 — 카드 확대 모달이 부스터 상세/결과 모달 뒤로 밀리는 문제 수정 */
#v273BoosterDetailModal,
#v270BoosterResultModal{
  z-index:14000!important;
}

#cardImageZoomModal.card-image-zoom-modal{
  z-index:2147483000!important;
  isolation:isolate;
}
#cardImageZoomModal.card-image-zoom-modal.show{
  display:flex!important;
}
#cardImageZoomModal .card-image-zoom-box{
  position:relative!important;
  z-index:2!important;
}

/* 확대 중에는 뒤쪽 부스터 카드 툴팁이 위로 겹치지 않도록 한다. */
#cardImageZoomModal.show ~ .card-function-tooltip,
body.v275-card-zoom-open .card-function-tooltip{
  display:none!important;
}


/* ---- assets/css/v276_booster_pack_flip.css?v=277 ---- */
/* ================================================================
   v276 — 부스터팩 첫 화면 단순화 + 순차 카드 플립 공개
   1) 부스터 첫 화면: 팩 표지/팩명/에피소드만 표시
   2) 개봉 결과: 카드 뒷면 -> 앞면을 획득 순서대로 자동 플립
   ================================================================ */

/* ---------- 부스터팩 첫 화면 ---------- */
#boosterPackGrid.v276-booster-picker{
  display:grid!important;
  grid-template-columns:repeat(auto-fill,minmax(180px,1fr))!important;
  gap:14px!important;
  align-items:start!important;
}
#boosterPackGrid .booster-card.v276-simple-pack{
  display:grid!important;
  grid-template-columns:1fr!important;
  grid-template-rows:auto auto auto!important;
  gap:7px!important;
  align-items:start!important;
  padding:10px!important;
  min-width:0!important;
  cursor:pointer!important;
  overflow:hidden!important;
  border:1px solid rgba(232,196,108,.25)!important;
  border-radius:11px!important;
  background:rgba(18,14,11,.9)!important;
  transition:transform .16s ease,border-color .16s ease,box-shadow .16s ease!important;
}
#boosterPackGrid .booster-card.v276-simple-pack:hover,
#boosterPackGrid .booster-card.v276-simple-pack:focus-visible{
  transform:translateY(-2px)!important;
  border-color:rgba(245,211,124,.72)!important;
  box-shadow:0 10px 24px rgba(0,0,0,.28)!important;
  outline:none!important;
}
#boosterPackGrid .booster-card.v276-simple-pack > *{
  display:none!important;
  grid-column:1!important;
}
#boosterPackGrid .booster-card.v276-simple-pack > .v265-pack-cover,
#boosterPackGrid .booster-card.v276-simple-pack > .pack-art{
  display:flex!important;
  grid-row:1!important;
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  aspect-ratio:16/9!important;
  position:relative!important;
}
#boosterPackGrid .booster-card.v276-simple-pack > .v265-pack-head{
  display:block!important;
  grid-row:2!important;
  margin:0!important;
}
#boosterPackGrid .booster-card.v276-simple-pack > .v265-pack-head h3{
  display:block!important;
  margin:0!important;
  font-size:13px!important;
  line-height:1.35!important;
  color:#f2d27f!important;
  text-align:center!important;
}
#boosterPackGrid .booster-card.v276-simple-pack > .v265-pack-head .v265-visibility{
  display:none!important;
}
#boosterPackGrid .booster-card.v276-simple-pack > p{
  display:block!important;
  grid-row:3!important;
  margin:0!important;
  padding:0!important;
  font-size:10px!important;
  line-height:1.35!important;
  text-align:center!important;
  color:#d8c79d!important;
}
#boosterPackGrid .booster-card.v276-simple-pack .v273-cover-hint{
  display:none!important;
}

/* ---------- 개봉 결과: 순차 플립 ---------- */

/* 결과 DOM이 래핑되기 전 카드 앞면이 순간 노출되지 않도록 숨긴다. */
#v274BoosterResultGrid > .shop-card-entry{visibility:hidden!important;}
#v274BoosterResultGrid.v276-flip-grid{
  perspective:1200px!important;
  align-items:start!important;
}
#v274BoosterResultGrid .v276-flip-card{
  position:relative!important;
  width:var(--collection-card-width,175px)!important;
  min-width:var(--collection-card-width,175px)!important;
  max-width:var(--collection-card-width,175px)!important;
  height:calc(var(--collection-card-height,306.25px) + 28px)!important;
  min-height:calc(var(--collection-card-height,306.25px) + 28px)!important;
  perspective:1000px!important;
  transform:translateZ(0);
}
#v274BoosterResultGrid .v276-flip-inner{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  transform-style:preserve-3d!important;
  transform:rotateY(180deg)!important;
  transition:transform .62s cubic-bezier(.2,.72,.16,1)!important;
}
#v274BoosterResultGrid .v276-flip-card.is-revealed .v276-flip-inner{
  transform:rotateY(0deg)!important;
}
#v274BoosterResultGrid .v276-card-back,
#v274BoosterResultGrid .v276-card-front{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  backface-visibility:hidden!important;
  -webkit-backface-visibility:hidden!important;
  overflow:hidden!important;
}
#v274BoosterResultGrid .v276-card-front{
  transform:rotateY(0deg)!important;
}
#v274BoosterResultGrid .v276-card-back{
  transform:rotateY(180deg)!important;
}
#v274BoosterResultGrid .v276-card-front > .shop-card-entry{
  margin:0!important;
}
#v274BoosterResultGrid .v276-card-back{
  display:grid!important;
  place-items:center!important;
  box-sizing:border-box!important;
  padding:10px!important;
  border:1px solid rgba(232,196,108,.58)!important;
  border-radius:9px!important;
  background:
    radial-gradient(circle at 50% 42%,rgba(213,169,73,.25),transparent 34%),
    repeating-linear-gradient(45deg,rgba(235,202,119,.055) 0 7px,transparent 7px 14px),
    linear-gradient(160deg,#24190e 0%,#0e0b09 52%,#191008 100%)!important;
  box-shadow:inset 0 0 0 4px rgba(0,0,0,.42),inset 0 0 0 6px rgba(230,193,102,.18),0 12px 30px rgba(0,0,0,.34)!important;
}
#v274BoosterResultGrid .v276-card-back::before{
  content:'三國志'!important;
  display:grid!important;
  place-items:center!important;
  width:76%!important;
  aspect-ratio:1!important;
  border:1px solid rgba(238,207,125,.38)!important;
  border-radius:50%!important;
  color:#f0cf7b!important;
  font-size:26px!important;
  font-weight:900!important;
  letter-spacing:.1em!important;
  text-indent:.1em!important;
  text-shadow:0 2px 8px rgba(0,0,0,.65)!important;
  box-shadow:inset 0 0 28px rgba(218,167,62,.1)!important;
}
#v274BoosterResultGrid .v276-card-back::after{
  content:'TCG BOOSTER'!important;
  position:absolute!important;
  left:0!important;
  right:0!important;
  bottom:18px!important;
  text-align:center!important;
  color:rgba(244,221,164,.72)!important;
  font-size:9px!important;
  font-weight:800!important;
  letter-spacing:.18em!important;
}
#v274BoosterResultGrid .v276-flip-card.is-revealed{
  animation:v276RevealPop .42s ease-out both;
}
@keyframes v276RevealPop{
  0%{filter:brightness(.82)}
  55%{filter:brightness(1.18)}
  100%{filter:none}
}

@media(max-width:760px){
  #boosterPackGrid.v276-booster-picker{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:9px!important}
  #boosterPackGrid .booster-card.v276-simple-pack{padding:8px!important}
  #boosterPackGrid .booster-card.v276-simple-pack > .v265-pack-head h3{font-size:11px!important}
  #v274BoosterResultGrid .v276-card-back::before{font-size:21px!important}
}
@media(max-width:420px){
  #boosterPackGrid.v276-booster-picker{grid-template-columns:1fr 1fr!important;gap:7px!important}
  #boosterPackGrid .booster-card.v276-simple-pack > .v265-pack-head h3{font-size:10px!important}
  #boosterPackGrid .booster-card.v276-simple-pack > p{font-size:9px!important}
}

@media(prefers-reduced-motion:reduce){
  #v274BoosterResultGrid .v276-flip-inner{transition-duration:.01ms!important}
  #v274BoosterResultGrid .v276-flip-card.is-revealed{animation:none!important}
}


/* ---- assets/css/v277_booster_list_editor.css?v=277 ---- */
/* v277 — 관리자 부스터팩 LIST 편집 모드 */
#v277BoosterEditModeBtn{margin-left:auto}
#boosterPackModal.v277-editing #boosterPackGrid .booster-card.v276-simple-pack{border-color:rgba(105,184,255,.55)!important;box-shadow:inset 0 0 0 1px rgba(105,184,255,.12)!important}
#boosterPackGrid .booster-card.v276-simple-pack > .v277-pack-edit-btn{display:none!important;grid-row:4!important;margin-top:2px!important;justify-content:center!important;width:100%!important;position:relative!important;z-index:3!important}
#boosterPackGrid.v277-admin-list-edit .booster-card.v276-simple-pack > .v277-pack-edit-btn{display:flex!important}
#boosterPackGrid.v277-admin-list-edit .booster-card.v276-simple-pack{grid-template-rows:auto auto auto auto!important}
#boosterPackGrid.v277-admin-list-edit .booster-card.v276-simple-pack > .v265-pack-cover,#boosterPackGrid.v277-admin-list-edit .booster-card.v276-simple-pack > .pack-art{pointer-events:none!important}

.v277-editor-box{width:min(1240px,96vw)!important;max-height:92vh!important;overflow:auto!important}
.v277-editor-layout{display:grid;grid-template-columns:310px minmax(0,1fr);gap:14px;padding:14px}
.v277-editor-side,.v277-editor-main{border:1px solid rgba(232,196,108,.18);border-radius:11px;background:rgba(255,255,255,.025);padding:12px;min-width:0}
.v277-editor-side{display:grid;align-content:start;gap:9px}.v277-editor-side h3,.v277-editor-main h3{margin:0 0 3px;color:#f0cf7b;font-size:13px}
.v277-editor-side>label{display:grid;gap:4px;font-size:10px}.v277-editor-side input,.v277-editor-side select,.v277-card-filters input,.v277-card-filters select{width:100%;box-sizing:border-box;padding:8px;border-radius:7px;border:1px solid rgba(255,255,255,.16);background:rgba(0,0,0,.28);color:inherit}
.v277-editor-cover{width:100%;aspect-ratio:16/9;border:1px solid rgba(232,196,108,.3);border-radius:9px;overflow:hidden;background:#0e0b09}.v277-editor-cover img{width:100%;height:100%;object-fit:cover;display:block}.v277-cover-empty{height:100%;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))}.v277-cover-empty b{font-size:28px;color:#f0cf7b}.v277-cover-empty span{font-size:10px;opacity:.7}
.v277-rate-group{display:grid;gap:5px;padding:8px;border:1px solid rgba(255,255,255,.09);border-radius:8px}.v277-rate-group>b{font-size:11px;color:#f2d783}.v277-rate-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px}.v277-rate-field{display:grid;grid-template-columns:33px 1fr 14px;align-items:center;gap:4px;font-size:9px}.v277-rate-field input{padding:6px!important;text-align:right}.v277-rate-field em{font-style:normal;opacity:.65}.v277-rate-remain{font-size:9px;opacity:.75}.v277-rate-remain.is-invalid{color:#ff8b8b;opacity:1;font-weight:800}.v277-rate-note{font-size:9px;line-height:1.45;opacity:.68}
.v277-card-config-head{display:flex;gap:12px;align-items:end;justify-content:space-between;margin-bottom:8px}.v277-card-filters{display:grid;grid-template-columns:minmax(160px,1fr) 100px 90px;gap:6px;min-width:min(520px,65%)}.v277-card-bulk{display:flex;gap:6px;margin-bottom:8px}.v277-card-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;max-height:610px;overflow:auto;padding-right:3px}.v277-card-row{display:grid;grid-template-columns:20px 40px 34px minmax(0,1fr);gap:5px;align-items:center;padding:7px;border:1px solid rgba(255,255,255,.08);border-radius:7px;background:rgba(0,0,0,.16);font-size:9px;cursor:pointer}.v277-card-row:hover{border-color:rgba(232,196,108,.35)}.v277-card-row input{margin:0}.v277-card-row .v277-grade{font-weight:900;color:#f0cf7b}.v277-card-row .v277-faction{opacity:.72}.v277-card-row b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.v277-card-row small{grid-column:4;font-size:8px;opacity:.45;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.v277-editor-actions{display:flex;justify-content:flex-end;gap:7px;padding:0 14px 14px}.v277-editor-actions .btn{min-width:110px}
.v277-editing .v276-simple-pack{cursor:pointer!important}
@media(max-width:900px){.v277-editor-layout{grid-template-columns:1fr}.v277-editor-side{grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}.v277-editor-side h3,.v277-editor-cover,.v277-rate-note{grid-column:1/-1}.v277-card-list{grid-template-columns:1fr}.v277-card-filters{min-width:0;width:100%;grid-template-columns:1fr 90px 80px}.v277-card-config-head{align-items:stretch;flex-direction:column}}
@media(max-width:600px){.v277-editor-side{grid-template-columns:1fr}.v277-editor-cover,.v277-editor-side h3,.v277-rate-note{grid-column:auto}.v277-card-filters{grid-template-columns:1fr 1fr}.v277-card-filters input{grid-column:1/-1}.v277-editor-layout{padding:8px}.v277-editor-side,.v277-editor-main{padding:9px}}


/* ---- assets/css/v278_booster_cover_zoom.css?v=278 ---- */
/* ================================================================
   v278 — 부스터팩 표지 2.5:3.5 비율 통일 + 구성/개봉 글씨 확대
          + 관리자 LIST 편집 모드 표지 확대·위치 조정 UI
   ================================================================ */

/* ---------- 표지 비율: 목록 첫 화면 + 상세화면 + 관리자 편집 미리보기 공통 ---------- */
.v265-pack-cover,
#boosterPackGrid .booster-card.v276-simple-pack > .v265-pack-cover,
#boosterPackGrid .booster-card.v276-simple-pack > .pack-art,
.v273-detail-cover-wrap .v265-pack-cover,
.v277-editor-cover{
  aspect-ratio:2.5/3.5 !important;
}
.v277-editor-cover{position:relative;}
.v277-editor-cover.v278-dragging{cursor:grabbing !important;}

/* ---------- 카드 구성 텍스트 확대 ---------- */
.v273-pack-detail-section>h3{font-size:18px !important;}
.v273-composition-title b{font-size:15px !important;}
.v273-composition-title span{font-size:11px !important;}
.v273-grade-summary .v273-grade-chip,
.v273-detail-grade-summary .v273-grade-chip{font-size:12px !important;padding:4px 9px !important;}
.v273-composition-row,
.v273-detail-composition .v273-composition-row{font-size:12px !important;line-height:1.55 !important;}
.v273-pack-card-caption{font-size:11px !important;}
.v273-pack-card-caption>b{font-size:12px !important;}
.v273-view-pack-btn{font-size:12px !important;padding:7px 12px !important;}

/* ---------- 개봉 버튼 텍스트 확대 ---------- */
.v273-detail-booster-title{font-size:15px !important;}
.v273-detail-booster-row>b{font-size:13px !important;}
.v273-detail-booster-row .btn{font-size:13px !important;padding:9px 6px !important;}

@media(max-width:640px){
  .v273-pack-detail-section>h3{font-size:16px !important;}
  .v273-detail-booster-row .btn{font-size:12px !important;}
}

/* ---------- 관리자 표지 확대/위치 편집 컨트롤 ---------- */
.v278-cover-layout-box{display:grid;gap:6px;margin-top:8px;padding:9px 0 2px;border-top:1px dashed rgba(232,196,108,.28);}
.v278-cover-layout-title{font-size:11px;font-weight:900;color:#f0cf7b;}
.v278-cover-layout-row{display:grid;grid-template-columns:56px 1fr 42px;gap:8px;align-items:center;font-size:10px;color:#d8d2c6;}
.v278-cover-layout-row input[type="range"]{width:100%;}
.v278-cover-layout-actions{display:flex;gap:7px;padding-top:2px;}
.v278-cover-layout-actions .btn{padding:6px 10px;font-size:10px;}
.v278-cover-layout-hint{font-size:9px;opacity:.65;}

