/* 셀러린 앱 스타일 v136 — index.html 인라인 6블록 통합 (순서 보존) */
/* ═══ v136 분리 — 원본 style 블록 #0 (L58) ═══ */
/* ════════════════════════════════════════════════════════════
   셀러린 v2 — 디자인 토큰
   ════════════════════════════════════════════════════════════ */
:root {
  --brand:        #4f46e5;
  --brand-soft:   #eef2ff;
  --brand-dk:     #4338ca;
  --brand-accent: #818cf8;

  --bg:           #fafafa;
  --surface:      #ffffff;
  --surface-2:    #f5f5f7;
  --surface-3:    #fafafa;
  --sidebar-bg:   #0a0a0f;
  --sidebar-bg-2: #14141d;
  --border:       #ececf0;
  --border-soft:  #f1f1f5;

  --text:           #0a0a0f;
  --text-2:         #52525b;
  --text-3:         #a1a1aa;
  --text-on-dark:   rgba(255,255,255,.92);
  --text-on-dark-2: rgba(255,255,255,.55);
  --text-on-dark-3: rgba(255,255,255,.35);

  --success:      #10b981;
  --success-soft: #ecfdf5;
  --danger:       #e11d48;
  --danger-soft:  #fff1f2;
  --warning:      #f59e0b;
  --warning-soft: #fffbeb;
  --info:         #0ea5e9;
  --info-soft:    #f0f9ff;

  --shadow-xs: 0 1px 2px rgba(10, 10, 15, .04);
  --shadow-sm: 0 1px 3px rgba(10, 10, 15, .06), 0 1px 2px rgba(10, 10, 15, .04);
  --shadow-md: 0 4px 12px rgba(10, 10, 15, .08), 0 2px 4px rgba(10, 10, 15, .04);
  --shadow-lg: 0 12px 32px rgba(10, 10, 15, .10), 0 4px 8px rgba(10, 10, 15, .04);

  --r-sm: 8px;
  --r:    12px;
  --r-lg: 16px;
  --r-xl: 20px;

  --sidebar-w: 244px;
  --topbar-h:  64px;

  /* ── 다크모드용 추가 토큰 (라이트 기본값) ── */
  --topbar-bg:        rgba(255, 255, 255, .85);
  --dropdown-bg:      #ffffff;
  --grid-line:        #f1f1f5;
  --tip-border:       #c7d2fe;
  --hover-border:     #d4d4d8;
  --donut-track:      #f5f5f7;
  --chart-axis-text:  #a1a1aa;
  --chart-label-text: #52525b;
  --chart-tooltip-bg: #0a0a0f;
  --chart-tooltip-fg: #ffffff;
  --circle-stroke-bg: #ffffff;
  --btn-primary-hover:#1a1a1f;
  --btn-primary-fg:   #ffffff;
  --shadow-color:     10, 10, 15;
  color-scheme:       light;

  /* ── 🆕 안내 배지 토큰 (인디고 톤 — 친근 강조) ── */
  --beta-color:        #4f46e5;   /* 메인 브랜드와 동일 인디고 */
  --beta-color-fg:     #ffffff;
  --beta-soft:         #eef2ff;   /* 옅은 인디고 배경 */
  --beta-border:       #c7d2fe;
  --beta-pulse:        rgba(79, 70, 229, .35);
}

/* ════════════════════════════════════════════════════════════
   🌙 다크모드 토큰 (B-수정안: 사이드바와 자연스럽게 연결되는 톤)
   ════════════════════════════════════════════════════════════ */
[data-theme="dark"] {
  /* 표면 */
  --bg:           #08080c;   /* 사이드바 시작색(#0a0a0f)보다 살짝 짙게 → 사이드바가 떠 보임 */
  --surface:      #16161f;   /* 사이드바 끝색(#14141d)보다 살짝 밝게 → 카드가 떠 보임 */
  --surface-2:    #1c1c26;   /* 탭/트랙 배경 */
  --surface-3:    #14141d;
  --border:       rgba(255, 255, 255, .06);
  --border-soft:  rgba(255, 255, 255, .04);

  /* 텍스트 */
  --text:    #fafafa;
  --text-2:  #a1a1aa;
  --text-3:  #71717a;

  /* 브랜드 소프트 (다크에선 인디고를 더 진하게) */
  --brand-soft: rgba(129, 140, 248, .12);

  /* 의미 색상 소프트 (다크 배경에 맞춰 투명 톤으로) */
  --success-soft: rgba(16, 185, 129, .12);
  --danger-soft:  rgba(225, 29, 72, .14);
  --warning-soft: rgba(245, 158, 11, .12);
  --info-soft:    rgba(14, 165, 233, .12);

  /* 그림자 (다크 배경엔 더 짙은 검정) */
  --shadow-color: 0, 0, 0;
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, .25);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, .35), 0 1px 2px rgba(0, 0, 0, .2);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, .4), 0 2px 4px rgba(0, 0, 0, .25);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, .5), 0 4px 8px rgba(0, 0, 0, .3);

  /* 다크모드 전용 컴포넌트 토큰 */
  --topbar-bg:        rgba(10, 10, 15, .75);
  --dropdown-bg:      #1c1c26;
  --grid-line:        rgba(255, 255, 255, .06);
  --tip-border:       rgba(129, 140, 248, .25);
  --hover-border:     rgba(255, 255, 255, .14);
  --donut-track:      rgba(255, 255, 255, .06);
  --chart-axis-text:  #71717a;
  --chart-label-text: #a1a1aa;
  --chart-tooltip-bg: #fafafa;
  --chart-tooltip-fg: #0a0a0f;
  --circle-stroke-bg: #16161f;

  --btn-primary-hover: #e4e4e7;
  --btn-primary-fg:    #0a0a0f;

  color-scheme:   dark;

  /* ── 🆕 안내 배지 토큰 (다크에서는 살짝 밝게) ── */
  --beta-color:        #818cf8;   /* 다크에서는 밝은 인디고 */
  --beta-color-fg:     #0a0a0f;
  --beta-soft:         #1e1e3a;
  --beta-border:       rgba(129, 140, 248, .25);
  --beta-pulse:        rgba(129, 140, 248, .45);
}

/* 부드러운 테마 전환 */
html, body, .topbar, .kpi, .card, .ad-mapping-card, .sku-table-card, .sku-insight-card, .weeks-tracker, .btn, .badge,
.dropzone{
  transition: background-color .25s ease, border-color .25s ease, color .2s ease;
}

/* ────────────────────────────────────────────────────────────
   🌙 다크모드 SVG 차트 색상 오버라이드
   인라인 속성을 속성 선택자로 덮어쓴다 (CSS 우선순위 활용)
   ──────────────────────────────────────────────────────────── */
[data-theme="dark"] svg line[stroke="#f1f1f5"]   { stroke: var(--grid-line); }
[data-theme="dark"] svg circle[stroke="#f1f1f5"] { stroke: var(--grid-line); }
[data-theme="dark"] svg text[fill="#a1a1aa"]     { fill: var(--chart-axis-text); }
[data-theme="dark"] svg text[fill="#52525b"]     { fill: var(--chart-label-text); }

/* 도넛 차트 트랙 (대시보드) */
[data-theme="dark"] svg circle[stroke="#f5f5f7"] { stroke: var(--donut-track); }

/* 차트 포인트 외곽선용 흰색 — 다크에선 카드 배경색에 맞춰 변경 */
[data-theme="dark"] svg circle[fill="#fff"]     { fill: var(--circle-stroke-bg); }
[data-theme="dark"] svg circle[fill="#ffffff"]  { fill: var(--circle-stroke-bg); }
[data-theme="dark"] svg circle[stroke="#fff"]   { stroke: var(--circle-stroke-bg); }
[data-theme="dark"] svg circle[stroke="#ffffff"]{ stroke: var(--circle-stroke-bg); }

/* 차트 툴팁 박스 (검정 배경, 흰 텍스트) — 다크에선 흰 배경, 검정 텍스트로 반전 */
[data-theme="dark"] svg rect[fill="#0a0a0f"]    { fill: var(--chart-tooltip-bg); }
[data-theme="dark"] svg text[fill="#fff"]:not(.keep-white),
[data-theme="dark"] svg text[fill="#ffffff"]:not(.keep-white) {
  fill: var(--chart-tooltip-fg);
}

/* ────────────────────────────────────────────────────────────
   🌙 다크모드 보강 — SKU 페이지·테이블·인사이트 아이템 가독성
   ──────────────────────────────────────────────────────────── */

/* SKU 테이블 행 hover (라이트 #fafbff → 다크 옅은 인디고 hover) */
[data-theme="dark"] .sku-table tbody tr:hover {
  background: rgba(129, 140, 248, .07);
}

/* SKU 인사이트 아이템 라벨 — Amber/Emerald/Rose 계열 텍스트를 다크 가독 톤으로 */
[data-theme="dark"] .sku-insight-item.warning .sku-insight-item-label { color: #fbbf24; }
[data-theme="dark"] .sku-insight-item.danger  .sku-insight-item-label { color: #fb7185; }
[data-theme="dark"] .sku-insight-item.success .sku-insight-item-label { color: #34d399; }

/* SKU 페이지의 흑자/적자 마커 (3412/3416, 3465/3469) — 색만 다크 적응 */


/* 업로드 페이지의 옅은 amber/emerald 텍스트 (1848/2027/2997 등) — 다크 가독 톤 */


/* 미분류 안내 박스 (#fde68a 보더, #fff 배경) — 다크 적응 */
[data-theme="dark"] .unclassified-item {
  background: rgba(245, 158, 11, .08);
  border-color: rgba(245, 158, 11, .25);
}

/* preview-card 헤더 등 옅은 인디고 보더 (#c7d2fe → 다크 톤) */


/* 미세한 옅은 인디고 hover 배경 (#fafbff) — 다크 적응 */


* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont,
               system-ui, Roboto, 'Helvetica Neue', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

button, input, select, textarea { font-family: inherit; }
a { text-decoration: none; color: inherit; }

/* ════════════════════════════════════════════════════════════
   레이아웃
   ════════════════════════════════════════════════════════════ */
.wrap { display: flex; min-height: 100vh; }

/* ════════════════════════════════════════════════════════════
   사이드바
   ════════════════════════════════════════════════════════════ */
.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: linear-gradient(180deg, var(--sidebar-bg) 0%, var(--sidebar-bg-2) 100%);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  border-right: 1px solid rgba(255, 255, 255, .04);
}

.brand {
  padding: 24px 22px 20px;
  display: flex;
  align-items: center;
  gap: 11px;
  cursor: pointer;
}
.brand-mark {
  width: 32px; height: 32px;
  border-radius: 9px;
  background: #ffffff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(79, 70, 229, .35);
  position: relative;
  overflow: hidden;
}
.brand-mark::after { display: none; }
/* v44.1 — V+Sellerin 정사각형 (OAuth Console 업로드 로고와 100% 일치) */
.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.brand-text { display: flex; flex-direction: column; }
.brand-name {
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.025em;
}


.nav {
  flex: 1;
  padding: 8px 12px 24px;
  overflow-y: auto;
}
.nav-section {
  display: flex;
  align-items: center;
  padding: 16px 10px 6px;
  color: var(--text-on-dark-3);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.nav-section::before {
  content: "";
  width: 3px;
  height: 11px;
  background: var(--brand-accent, #818cf8);
  border-radius: 2px;
  margin-right: 8px;
  opacity: 0.65;
}
/* v86 — 단락별 구분선 (첫 섹션 제외) — 사이트맵 시각 한눈 파악 */
.nav .nav-section ~ .nav-section {
  margin-top: 14px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 9px 11px;
  color: var(--text-on-dark-2);
  font-size: 13.5px;
  font-weight: 500;
  border-radius: 8px;
  cursor: pointer;
  transition: all .15s ease;
  position: relative;
  margin: 1px 0;
}
.nav-item:hover {
  color: var(--text-on-dark);
  background: rgba(255, 255, 255, .05);
}
.nav-item.active {
  color: #fff;
  background: linear-gradient(90deg, rgba(79,70,229,.25) 0%, rgba(79,70,229,.08) 100%);
}
.nav-item.active::before {
  content: '';
  position: absolute;
  left: -12px;
  top: 6px; bottom: 6px;
  width: 3px;
  background: var(--brand-accent);
  border-radius: 0 3px 3px 0;
}
.nav-ico {
  /* 🆕 v63.3 사이드바 이모티콘 모두 숨김 — 문자만 남김 */
  display: none;
}
.nav-badge {
  margin-left: auto;
  font-size: 10px;
  font-weight: 600;
  padding: 1px 6px;
  border-radius: 10px;
  background: var(--brand);
  color: #fff;
  letter-spacing: 0.02em;
}
.nav-badge.alert { background: var(--danger); }

/* 🆕 사이드바 데모 모드 버튼 (<button>을 <a>처럼) */
.nav-item-btn {
  background: transparent;
  border: none;
  width: 100%;
  text-align: left;
  font-family: inherit;
  /* nav-item 기본 속성 상속 */
}
/* 🆕 데모 모드 활성 시 표시되는 ON 배지 */
.nav-badge.demo-nav-badge {
  display: none;  /* 기본 숨김 */
  background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
  color: #422006;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .04em;
  padding: 1px 7px;
}
.nav-badge.demo-nav-badge.is-active { display: inline-flex; }

/* 🆕 v21 [A] — 사이드바 외부 링크 (무료 도구) */
.nav-item-external {
  text-decoration: none;
  color: var(--text-on-dark-2);
  opacity: .88;
}
.nav-item-external:hover {
  opacity: 1;
}
.nav-ext-icon {
  margin-left: auto;
  font-size: 11px;
  color: var(--text-on-dark-3);
  font-weight: 500;
  letter-spacing: 0;
}
.nav-item-external:hover .nav-ext-icon {
  color: var(--brand-accent);
}

.sidebar-bottom {
  padding: 14px 18px;
  border-top: 1px solid rgba(255, 255, 255, .06);
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  position: relative;
  transition: background .18s;
}
.sidebar-bottom:hover {
  background: rgba(255, 255, 255, .04);
}
.user-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  color: #fff;
  font-weight: 700;
  font-size: 12px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}
.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.user-info { flex: 1; min-width: 0; }
.user-name {
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-plan {
  color: var(--text-on-dark-3);
  font-size: 10.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-caret {
  color: var(--text-on-dark-3);
  font-size: 14px;
  flex-shrink: 0;
  transition: transform .18s;
}
.sidebar-bottom.is-open .user-caret {
  transform: rotate(180deg);
}


.user-dropdown {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 12px;
  right: 12px;
  background: var(--dropdown-bg);
  border-radius: var(--r);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .35), 0 4px 8px rgba(0, 0, 0, .2);
  padding: 6px;
  display: none;
  z-index: 100;
  animation: dropdownIn .18s cubic-bezier(.2,.8,.2,1) backwards;
}
.sidebar-bottom.is-open .user-dropdown {
  display: block;
}
@keyframes dropdownIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}
.user-dropdown-header {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 4px;
}
.user-dropdown-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-dropdown-email {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-2);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: background .12s;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  font-family: inherit;
}
.user-dropdown-item:hover {
  background: var(--surface-2);
}
.user-dropdown-item.is-danger {
  color: var(--danger);
}
.user-dropdown-item.is-danger:hover {
  background: var(--danger-soft);
}
.user-dropdown-icon {
  font-size: 14px;
  flex-shrink: 0;
}
/* ⭐ v35 옵션 L.3 — 사용자 드롭다운 구분선 + 약관 섹션 */
.user-dropdown-divider {
  height: 1px;
  background: var(--border);
  margin: 6px 0;
}
.user-dropdown-section-label {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 6px 12px 4px;
}
a.user-dropdown-item {
  text-decoration: none;
}
a.user-dropdown-item .user-dropdown-ext {
  margin-left: auto;
  font-size: 10px;
  color: var(--text-3);
  opacity: .6;
}

/* 로그아웃 진행 중 오버레이 */
.logout-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(10, 10, 15, .6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
}
.logout-overlay.show { display: flex; }
.logout-overlay-content {
  background: var(--surface);
  padding: 24px 32px;
  border-radius: var(--r);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 12px;
}


.rerun-modal {
  display: none;
  position: fixed; inset: 0;
  background: rgba(10, 10, 15, .55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 10000;
  align-items: center; justify-content: center;
  padding: 20px;
}
.rerun-modal.show { display: flex; animation: rerunModalFadeIn .18s ease-out; }
@keyframes rerunModalFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.rerun-modal-content {
  background: var(--surface);
  border-radius: var(--r-xl);
  padding: 32px 28px 24px;
  width: 100%; max-width: 420px;
  box-shadow: var(--shadow-lg);
  text-align: center;
  animation: rerunModalRise .22s cubic-bezier(.2,.8,.2,1);
}
@keyframes rerunModalRise {
  from { transform: translateY(20px) scale(.96); opacity: 0; }
  to   { transform: translateY(0)    scale(1);   opacity: 1; }
}
.rerun-modal-icon {
  font-size: 44px;
  margin-bottom: 10px;
  display: inline-block;
  animation: rerunSpin .6s ease-out;
}
@keyframes rerunSpin {
  from { transform: rotate(-90deg); opacity: 0; }
  to   { transform: rotate(0deg);   opacity: 1; }
}
.rerun-modal-title {
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 8px;
  letter-spacing: -.01em;
}
.rerun-modal-desc {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.55;
  margin-bottom: 22px;
}
.rerun-modal-actions {
  display: flex;
  gap: 8px;
  justify-content: center;
}
.rerun-modal-btn {
  flex: 1;
  padding: 11px 18px;
  border-radius: var(--r);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all .15s ease;
  border: none;
  font-family: inherit;
}
.rerun-modal-btn-ghost {
  background: var(--surface-2);
  color: var(--text-2);
}
.rerun-modal-btn-ghost:hover {
  background: var(--border);
  color: var(--text);
}
.rerun-modal-btn-primary {
  background: var(--brand);
  color: var(--btn-primary-fg);
  animation: rerunBtnPulse 1.6s infinite;
}
.rerun-modal-btn-primary:hover {
  background: var(--brand-dk);
  transform: translateY(-1px);
  animation: none;
}
@keyframes rerunBtnPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(79, 70, 229, .45); }
  50%      { box-shadow: 0 0 0 10px rgba(79, 70, 229, 0); }
}

/* ════════════════════════════════════════════════════════════
   메인 영역
   ════════════════════════════════════════════════════════════ */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-width: 0; 
}
.content { min-width: 0; } 

/* ════════════════════════════════════════════════════════════
   토프바
   ════════════════════════════════════════════════════════════ */
.topbar {
  background: var(--topbar-bg);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
  height: var(--topbar-h);
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 50;
}
.topbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
}
.page-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.025em;
  color: var(--text);
}
.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--success-soft);
  color: var(--success);
  letter-spacing: -0.005em;
}
.trust-badge::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, .15);
}
.trust-badge.preview {
  background: var(--warning-soft);
  color: var(--warning);
}
.trust-badge.preview::before {
  background: var(--warning);
  box-shadow: 0 0 0 3px rgba(245, 158, 11, .15);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ── 🌙 다크모드 토글 버튼 ── */
.theme-toggle {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-2);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  transition: all .2s ease;
  position: relative;
  overflow: hidden;
}
.theme-toggle:hover {
  border-color: var(--hover-border);
  color: var(--text);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}
.theme-toggle:active { transform: translateY(0); }

.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), opacity .25s ease;
}
.theme-toggle .icon-sun  { transform: translateY(0)     rotate(0); opacity: 1; }
.theme-toggle .icon-moon { transform: translateY(120%)  rotate(-90deg); opacity: 0; }

[data-theme="dark"] .theme-toggle .icon-sun  { transform: translateY(-120%) rotate(90deg);  opacity: 0; }
[data-theme="dark"] .theme-toggle .icon-moon { transform: translateY(0)     rotate(0);      opacity: 1; }

/* ════════════════════════════════════════════════════════════
   버튼
   ════════════════════════════════════════════════════════════ */
.btn {
  height: 36px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all .15s ease;
  letter-spacing: -0.005em;
}
.btn-primary {
  background: var(--text);
  color: var(--btn-primary-fg);
  box-shadow: 0 1px 2px rgba(var(--shadow-color),.1), inset 0 1px 0 rgba(255,255,255,.08);
}
.btn-primary:hover {
  background: var(--btn-primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(var(--shadow-color), .15);
}
.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}
.btn-ghost:hover {
  background: var(--surface-2);
  border-color: var(--hover-border);
}
.btn-brand {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 1px 2px rgba(79,70,229,.25), inset 0 1px 0 rgba(255,255,255,.15);
}
.btn-brand:hover {
  background: var(--brand-dk);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79,70,229,.35);
}

/* ════════════════════════════════════════════════════════════
   컨텐츠 영역
   ════════════════════════════════════════════════════════════ */
.content {
  padding: 28px 32px 48px;
  max-width: 1440px;
  margin: 0 auto;
  width: 100%;
}


.page {
  display: none;
  animation: fadeUp .4s cubic-bezier(.2,.8,.2,1) backwards;
}
.page.active {
  display: block;
}

/* ── 환영 헤더 ── */
.hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 24px;
  gap: 24px;
}
.hero-left h1 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: 6px;
}
.hero-left h1 .accent {
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-left p {
  font-size: 13.5px;
  color: var(--text-2);
  font-weight: 500;
}

/* ── 누적 주차 트래커 ── */
.weeks-tracker {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-xs);
}
.weeks-dots {
  display: flex;
  gap: 4px;
}
.week-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--border);
  transition: all .2s;
}
.week-dot.filled {
  background: var(--brand);
  box-shadow: 0 0 0 2px rgba(79,70,229,.15);
}
.week-dot.target {
  background: transparent;
  border: 1.5px dashed var(--brand-accent);
}
.week-dot.locked {
  background: var(--surface-2);
  border: 1.5px solid var(--text-3);
  position: relative;
  box-shadow: none;
}
.week-dot.locked::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 3px; height: 3px;
  background: var(--text-3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}
.weeks-info {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}
.weeks-count {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text);
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: -0.015em;
}
.weeks-msg {
  font-size: 11px;
  color: var(--text-3);
  font-weight: 500;
}

/* ── Plan 게이팅 안내 배너 (M2~M4 — v52) ── */
.plan-gating-banner {
  display: none;
  align-items: center;
  gap: 14px;
  margin: 0 0 18px 0;
  padding: 14px 18px;
  background: var(--warning-soft);
  border: 1px solid var(--warning);
  border-radius: 12px;
}
.plan-gating-banner.is-active { display: flex; }
.plan-gating-banner .pgb-icon {
  font-size: 22px;
  color: var(--warning);
  flex-shrink: 0;
}
.plan-gating-banner .pgb-body { flex: 1; min-width: 0; }
.plan-gating-banner .pgb-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--warning);
  margin-bottom: 3px;
}
.plan-gating-banner .pgb-desc {
  font-size: 11.5px;
  color: var(--text-2);
  line-height: 1.5;
}
.plan-gating-banner .pgb-cta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--brand);
  color: #ffffff;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}
.plan-gating-banner .pgb-cta:hover { background: var(--brand-dk); }

/* ── M3 광고 슬롯 카드 (v52) ── */
.ad-slots-section {
  margin: 18px 0;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
}
.ad-slots-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.ad-slots-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}
.ad-slots-meta {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--brand);
  background: var(--brand-soft);
  padding: 4px 10px;
  border-radius: 100px;
}
.ad-slots-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.ad-slot {
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}
.ad-slot.is-active {
  border-color: var(--success);
  background: var(--success-soft);
}
.ad-slot.is-locked {
  background: var(--surface-2);
  border-color: var(--border);
  position: relative;
  opacity: 0.85;
}
.ad-slot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}
.ad-slot-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-2);
}
.ad-slot.is-active .ad-slot-num { color: var(--success); }

.ad-slot-status {
  font-size: 12.5px;
  font-weight: 700;
  margin-bottom: 3px;
  color: var(--text);
}
.ad-slot.is-locked .ad-slot-status { color: var(--text-3); }
.ad-slot-desc {
  font-size: 11px;
  color: var(--text-2);
  line-height: 1.4;
}
.ad-slots-note {
  margin-top: 12px;
  padding: 10px 12px;
  background: var(--brand-soft);
  border: 1px solid var(--brand-accent);
  border-radius: 8px;
  font-size: 11.5px;
  color: var(--brand-dk);
  line-height: 1.5;
}
[data-theme="dark"] .ad-slots-note {
  background: rgba(129,140,248,0.10);
  border-color: rgba(129,140,248,0.30);
  color: var(--text);
}
.ad-slots-section.is-pro .ad-slot.is-locked { display: none; }
.ad-slots-section.is-pro .ad-slots-grid { grid-template-columns: 1fr; }
.ad-slots-section.is-pro .ad-slots-note { display: none; }

/* ── M4 SKU 식별 잠금 (블러 + 자물쇠 오버레이) v52 ── */
.sku-gated-wrap { position: relative; }
.sku-gated-wrap .sku-gated-content {
  filter: blur(6px);
  user-select: none;
  pointer-events: none;
}
.sku-gated-wrap .sku-gated-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.86);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
  text-align: center;
  border-radius: inherit;
}
[data-theme="dark"] .sku-gated-wrap .sku-gated-overlay { background: rgba(22, 22, 31, 0.88); }

.sku-gated-overlay .sgo-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}
.sku-gated-overlay .sgo-desc {
  font-size: 11.5px;
  color: var(--text-2);
  max-width: 380px;
  margin-bottom: 10px;
  line-height: 1.5;
}
.sku-gated-overlay .sgo-cta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--brand);
  color: #ffffff;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}
.sku-gated-overlay .sgo-cta:hover { background: var(--brand-dk); }


.free-gate-wrap { position: relative; }
.free-gate-wrap .free-gate-overlay { display: none; }
.free-gate-wrap.is-gated .free-gate-content {
  filter: blur(7px);
  user-select: none;
  pointer-events: none;
}
.free-gate-wrap.is-gated .free-gate-overlay {
  display: flex;
  position: absolute;
  inset: 0;
  z-index: 4;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 90px 20px 20px;
  gap: 7px;
  text-align: center;
  background: linear-gradient(180deg, rgba(255,255,255,0.55) 0%, rgba(255,255,255,0.85) 26%);
  border-radius: 12px;
}
[data-theme="dark"] .free-gate-wrap.is-gated .free-gate-overlay {
  background: linear-gradient(180deg, rgba(22,22,31,0.55) 0%, rgba(22,22,31,0.88) 26%);
}
.free-gate-overlay .fgo-title { font-size: 15.5px; font-weight: 800; color: var(--text); }
.free-gate-overlay .fgo-desc { font-size: 12.5px; font-weight: 500; color: var(--text-2); max-width: 440px; line-height: 1.6; }
.free-gate-overlay .fgo-cta {
  margin-top: 6px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 8px;
  background: var(--brand);
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}
.free-gate-overlay .fgo-cta:hover { background: var(--brand-dk); }
/* 문제 진단 — 무료 잠금 그룹 (개수는 공개, 펼침 클릭 차단) */
.ins-group.gated-locked .ins-group-head { cursor: default; }
.ins-group.gated-locked .ins-group-head:hover { background: transparent; }
.ins-lock-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 100px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}


/* ════════════════════════════════════════════════════════════
   KPI 카드
   ════════════════════════════════════════════════════════════ */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.kpi {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 20px 22px;
  position: relative;
  overflow: hidden;
  transition: all .2s ease;
}
.kpi:hover {
  border-color: var(--hover-border);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}
.kpi-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.kpi-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  letter-spacing: -0.005em;
}


.kpi-value {
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: -0.035em;
  line-height: 1.1;
}
.kpi-value .unit {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-3);
  margin-left: 2px;
  letter-spacing: -0.01em;
}

.kpi-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}


.kpi-period {
  font-size: 11px;
  color: var(--text-3);
  font-weight: 500;
}

.spark {
  position: absolute;
  bottom: 0; right: 0;
  width: 110px; height: 38px;
  opacity: 0.45;
  pointer-events: none;
}
.kpi:hover .spark { opacity: 0.7; }

/* ════════════════════════════════════════════════════════════
   인사이트 알림 스트립
   ════════════════════════════════════════════════════════════ */
.insight-strip {
  background: linear-gradient(135deg, #1a1a2e 0%, #0f0f1c 100%);
  border-radius: 16px;
  padding: 20px 24px;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
  color: #fff;
}
.insight-strip::before {
  content: '';
  position: absolute;
  top: -50%; right: -10%;
  width: 360px; height: 360px;
  background: radial-gradient(circle, rgba(129, 140, 248, .25) 0%, transparent 60%);
  pointer-events: none;
}
.insight-strip::after {
  content: '';
  position: absolute;
  bottom: -30%; left: 25%;
  width: 240px; height: 240px;
  background: radial-gradient(circle, rgba(244, 114, 182, .12) 0%, transparent 60%);
  pointer-events: none;
}
.insight-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  position: relative;
  z-index: 1;
}
.insight-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.005em;
}
.insight-title .pill {
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(129, 140, 248, .25);
  color: #c7d2fe;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.insight-action {
  font-size: 12px;
  color: rgba(255,255,255,.7);
  font-weight: 500;
  cursor: pointer;
  transition: color .15s;
}
.insight-action:hover { color: #fff; }
.insight-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  position: relative;
  z-index: 1;
}
.insight-card {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 11px;
  padding: 13px 15px;
  cursor: pointer;
  transition: all .2s;
}
.insight-card:hover {
  background: rgba(255,255,255,.07);
  border-color: rgba(255,255,255,.12);
  transform: translateY(-1px);
}
.insight-card-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.insight-card-head .ic {
  width: 22px; height: 22px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}
.insight-card-head .ic.warn { background: rgba(245,158,11,.18); color: #fbbf24; }
.insight-card-head .ic.crit { background: rgba(225,29,72,.2); color: #fb7185; }
.insight-card-head .ic.opp  { background: rgba(16,185,129,.18); color: #34d399; }
.insight-tag {
  font-size: 10.5px;
  color: rgba(255,255,255,.5);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.insight-text {
  font-size: 12.5px;
  color: rgba(255,255,255,.92);
  font-weight: 500;
  line-height: 1.55;
  letter-spacing: -0.005em;
}
.insight-text strong {
  color: #fff;
  font-weight: 700;
}
.insight-text .num-up   { color: #fb7185; font-weight: 700; }
.insight-text .num-down { color: #34d399; font-weight: 700; }

/* ════════════════════════════════════════════════════════════
   카드 (공통)
   ════════════════════════════════════════════════════════════ */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 22px 24px;
  box-shadow: var(--shadow-xs);
}
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.card-head .left {
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-title {
  font-size: 14.5px;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text);
}
.card-sub {
  font-size: 12px;
  color: var(--text-3);
  font-weight: 500;
  margin-top: 2px;
}
.tabs {
  display: inline-flex;
  background: var(--surface-2);
  border-radius: 8px;
  padding: 3px;
}
.tab {
  font-size: 11.5px;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: 6px;
  cursor: pointer;
  color: var(--text-2);
  transition: all .15s;
  letter-spacing: -0.005em;
}
.tab.active {
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-xs);
}

/* ════════════════════════════════════════════════════════════
   차트 그리드
   ════════════════════════════════════════════════════════════ */
.chart-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 18px;
  margin-bottom: 24px;
}

.chart-main {
  height: 280px;
  position: relative;
}
.chart-main svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.donut-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  height: 280px;
}


/* ════════════════════════════════════════════════════════════
   하단 그리드
   ════════════════════════════════════════════════════════════ */
.bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.sku-list {
  display: flex;
  flex-direction: column;
}
.sku-section-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-soft);
  margin-bottom: 4px;
}
.sku-section-label.top { color: var(--success); }
.sku-section-label.bottom {
  color: var(--danger);
  padding-top: 14px;
}
.sku-item {
  display: grid;
  grid-template-columns: 28px 1fr auto auto;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--border-soft);
}
.sku-item:last-child { border-bottom: none; }
.sku-rank {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-3);
  font-family: 'JetBrains Mono', monospace;
  text-align: center;
}
.sku-rank.top { color: var(--brand); }
.sku-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.005em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 220px;
}
.sku-meta {
  font-size: 10.5px;
  color: var(--text-3);
  font-weight: 500;
  margin-top: 1px;
}
.sku-bar-wrap {
  width: 70px;
  height: 6px;
  background: var(--surface-2);
  border-radius: 3px;
  overflow: hidden;
}
.sku-bar {
  height: 100%;
  border-radius: 3px;
}
.sku-bar.pos { background: var(--success); }
.sku-bar.neg { background: var(--danger); }
.sku-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-align: right;
  min-width: 80px;
}
.sku-value.pos { color: var(--success); }
.sku-value.neg { color: var(--danger); }

.cost-bars {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.cost-row {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.cost-row-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.cost-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.005em;
}
.cost-name .pct {
  color: var(--text-3);
  font-weight: 500;
  margin-left: 6px;
  font-size: 11px;
}
.cost-amt {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}
.cost-track {
  height: 7px;
  background: var(--surface-2);
  border-radius: 4px;
  overflow: hidden;
}
.cost-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 1s cubic-bezier(.2,.8,.2,1);
}

/* ════════════════════════ 일별 매출 캘린더 (v19 / [7순위]) ════════════════════════ */
.calendar-wrap {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.calendar-month-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.calendar-month-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  padding: 0 2px;
}
.calendar-month-head .month-sum {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-2);
  letter-spacing: -0.01em;
}
.calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-align: center;
  padding: 0 2px;
}
.calendar-weekdays .wd-sun { color: var(--danger); }
.calendar-weekdays .wd-sat { color: var(--brand); }
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}
.calendar-cell {
  position: relative;
  aspect-ratio: 1.15 / 1;
  border-radius: 8px;
  padding: 6px 7px;
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: default;
  transition: transform .12s, box-shadow .12s, border-color .12s;
}
.calendar-cell.cal-empty {
  background: transparent;
  border: 0;
  cursor: default;
}
.calendar-cell.cal-has-data {
  cursor: pointer;
}
.calendar-cell.cal-has-data:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  border-color: var(--hover-border);
  z-index: 2;
}
.calendar-cell .cal-day {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-2);
  letter-spacing: -0.01em;
}
.calendar-cell .cal-amount {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.15;
}

/* 히트맵 5단계 — 순이익 양수 (초록 그라디언트) */
.calendar-cell.heat-0 { background: var(--surface-2); }
.calendar-cell.heat-1 { background: rgba(16, 185, 129, 0.08); border-color: rgba(16, 185, 129, 0.15); }
.calendar-cell.heat-2 { background: rgba(16, 185, 129, 0.18); border-color: rgba(16, 185, 129, 0.30); }
.calendar-cell.heat-3 { background: rgba(16, 185, 129, 0.30); border-color: rgba(16, 185, 129, 0.45); }
.calendar-cell.heat-4 { background: rgba(16, 185, 129, 0.45); border-color: rgba(16, 185, 129, 0.60); }
.calendar-cell.heat-4 .cal-amount,
.calendar-cell.heat-4 .cal-day { color: #064e3b; }

/* 다크모드 히트맵 */
[data-theme="dark"] .calendar-cell.heat-0 { background: var(--surface-2); }
[data-theme="dark"] .calendar-cell.heat-1 { background: rgba(52, 211, 153, 0.10); border-color: rgba(52, 211, 153, 0.20); }
[data-theme="dark"] .calendar-cell.heat-2 { background: rgba(52, 211, 153, 0.22); border-color: rgba(52, 211, 153, 0.35); }
[data-theme="dark"] .calendar-cell.heat-3 { background: rgba(52, 211, 153, 0.36); border-color: rgba(52, 211, 153, 0.50); }
[data-theme="dark"] .calendar-cell.heat-4 { background: rgba(52, 211, 153, 0.55); border-color: rgba(52, 211, 153, 0.70); }
[data-theme="dark"] .calendar-cell.heat-4 .cal-amount,
[data-theme="dark"] .calendar-cell.heat-4 .cal-day { color: #f0fdf4; }

/* 손실 셀 — 빨강 */
.calendar-cell.heat-loss { background: var(--danger-soft); border-color: rgba(225, 29, 72, 0.30); }
.calendar-cell.heat-loss .cal-amount { color: var(--danger); }
[data-theme="dark"] .calendar-cell.heat-loss { background: rgba(251, 113, 133, 0.15); border-color: rgba(251, 113, 133, 0.35); }

/* 캘린더 안내 노트 */
.calendar-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 10.5px;
  color: var(--text-3);
  flex-wrap: wrap;
  gap: 8px;
}
.calendar-legend-scale {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.calendar-legend-scale .legend-box {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  display: inline-block;
}
.calendar-legend-scale .legend-box.lvl-0 { background: var(--surface-2); }
.calendar-legend-scale .legend-box.lvl-1 { background: rgba(16, 185, 129, 0.18); }
.calendar-legend-scale .legend-box.lvl-2 { background: rgba(16, 185, 129, 0.30); }
.calendar-legend-scale .legend-box.lvl-3 { background: rgba(16, 185, 129, 0.45); }
.calendar-legend-scale .legend-box.lvl-loss { background: var(--danger-soft); border: 1px solid rgba(225, 29, 72, 0.30); }
[data-theme="dark"] .calendar-legend-scale .legend-box.lvl-1 { background: rgba(52, 211, 153, 0.22); }
[data-theme="dark"] .calendar-legend-scale .legend-box.lvl-2 { background: rgba(52, 211, 153, 0.36); }
[data-theme="dark"] .calendar-legend-scale .legend-box.lvl-3 { background: rgba(52, 211, 153, 0.55); }
[data-theme="dark"] .calendar-legend-scale .legend-box.lvl-loss { background: rgba(251, 113, 133, 0.15); }

/* 캘린더 toast (셀 클릭 시) */
.cal-toast {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--text);
  color: var(--bg);
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 11.5px;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: var(--shadow-md);
  pointer-events: none;
  z-index: 5;
  animation: cal-toast-in 0.15s;
}
.cal-toast::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: var(--text);
}
@keyframes cal-toast-in {
  from { opacity: 0; transform: translate(-50%, 3px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

.secret-note {
  margin-top: 18px;
  padding: 12px 14px;
  background: var(--brand-soft);
  border-radius: 10px;
  font-size: 11.5px;
  color: var(--brand-dk);
  font-weight: 500;
  line-height: 1.55;
}


.empty-state {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 80px 32px;
  text-align: center;
  box-shadow: var(--shadow-xs);
  position: relative;
  overflow: hidden;
}
.empty-state::before {
  content: '';
  position: absolute;
  top: -100px; left: 50%;
  transform: translateX(-50%);
  width: 480px; height: 200px;
  background: radial-gradient(ellipse at center, var(--brand-soft) 0%, transparent 70%);
  opacity: 0.6;
  pointer-events: none;
}
.empty-icon {
  font-size: 56px;
  line-height: 1;
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
}
.empty-title {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text);
  margin-bottom: 8px;
  position: relative;
  z-index: 1;
}
.empty-desc {
  font-size: 14px;
  color: var(--text-2);
  font-weight: 500;
  line-height: 1.6;
  max-width: 440px;
  margin: 0 auto 20px;
  position: relative;
  z-index: 1;
}
.empty-stage {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: var(--brand-soft);
  color: var(--brand);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.01em;
  position: relative;
  z-index: 1;
}
.empty-stage::before {
  /* ⭐ v164 (P2-3) — 장식 이모지에 빈 대체텍스트: 화면낭독기 노출 차단 */
  content: '🚧' / '';
  font-size: 11px;
}
.empty-actions {
  margin-top: 24px;
  display: flex;
  justify-content: center;
  gap: 10px;
  position: relative;
  z-index: 1;
}

/* ⭐ v4 NEW: 빈 페이지용 점프 버튼 (종합 대시보드로 이동) */
.empty-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  background: var(--text);
  color: var(--btn-primary-fg);
  border: none;
  border-radius: var(--r-sm);
  font-family: 'Pretendard Variable', sans-serif;
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: all .2s ease;
  letter-spacing: -0.01em;
}
.empty-cta:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}
.empty-cta-arrow { font-size: 12px; opacity: .8; }
.empty-cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: var(--surface);
  color: var(--text-2);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-family: 'Pretendard Variable', sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all .2s ease;
}
.empty-cta-secondary:hover {
  border-color: var(--hover-border);
  background: var(--surface-2);
}
/* 재방문 요약 배너 — 대시보드 히어로 아래 (마지막 업로드·누적 주차·전주 대비·이번 주 CTA) */
.revisit-banner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin: 0 0 16px 0;
  padding: 13px 18px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-xs);
}
.revisit-banner[hidden] { display: none; }
/* display:inline-flex 클래스가 hidden 속성을 덮어쓰지 않도록 강제 (세그·CTA 개별 숨김용) */
.revisit-banner [hidden] { display: none !important; }
.revisit-seg {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
  line-height: 1.4;
}
.revisit-seg .rv-num {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 800;
  font-size: 13px;
  color: var(--text);
}
.revisit-seg .rv-up { color: var(--success); }
.revisit-seg .rv-down { color: var(--danger); }
.revisit-divider {
  width: 1px;
  height: 16px;
  background: var(--border);
  flex: none;
}
.revisit-spacer { flex: 1 1 auto; }
.revisit-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--text);
  color: var(--bg);
  border-radius: 100px;
  font-size: 12.5px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: all .2s ease;
  flex: none;
}
.revisit-cta:hover { opacity: .85; transform: translateY(-1px); }
.revisit-done {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: var(--success-soft);
  color: var(--success);
  border: 1px solid var(--success);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 800;
  flex: none;
}
@media (max-width: 768px) {
  .revisit-banner { padding: 12px 14px; gap: 8px 12px; }
  .revisit-divider { display: none; }
  .revisit-spacer { flex-basis: 100%; }
}
/* ════════════════════════════════════════════════════════════
   재방문 주간 브리핑 9카드 (E-1 · v139) — 슬림 배너(v133) 확장판
   - 3×3 그리드 (1024px 이하 2열 · 640px 이하 1열)
   - 숫자는 JetBrains Mono · 색상은 토큰만 사용 (§14)
   ════════════════════════════════════════════════════════════ */
.rvg-wrap {
  margin: 0 0 16px 0;
  padding: 16px 18px 18px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-xs);
}
.rvg-wrap[hidden] { display: none; }
/* display 클래스가 hidden 속성을 덮지 않도록 강제 (v133.1 교훈) */
.rvg-wrap [hidden] { display: none !important; }
.rvg-head {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-bottom: 12px;
}
.rvg-title {
  font-size: 14.5px;
  font-weight: 800;
  color: var(--text);
}
.rvg-sub {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-3);
}
/* 변화 요약 배너 (P8-1 · v150) */
.rvg-summary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  margin-bottom: 12px;
  background: var(--brand-soft);
  border: 1px solid var(--tip-border);
  border-radius: 10px;
}
.rvg-summary[hidden] { display: none; }
.rvg-summary-icon {
  font-size: 13px;
  line-height: 1;
  flex: none;
}
.rvg-summary-text {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
  line-height: 1.5;
}
.rvg-summary-text strong {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 800;
  color: var(--text);
}
.rvg-summary-delta {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 800;
}
.rvg-summary-delta.rvg-up { color: var(--success); }
.rvg-summary-delta.rvg-down { color: var(--danger); }
@media (max-width: 640px) {
  .rvg-summary { padding: 8px 12px; }
  .rvg-summary-text { font-size: 12px; }
}
.rvg-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.rvg-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 14px;
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  min-width: 0;
}
a.rvg-card.rvg-link {
  text-decoration: none;
  cursor: pointer;
  transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}
a.rvg-card.rvg-link:hover {
  border-color: var(--hover-border);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}
.rvg-label {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-2);
  line-height: 1.35;
}
.rvg-value {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 8px;
  min-height: 24px;
}
.rvg-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: 19px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.15;
  word-break: keep-all;
}
.rvg-value-name span {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.rvg-delta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 800;
}
.rvg-delta.rvg-up { color: var(--success); }
.rvg-delta.rvg-down { color: var(--danger); }
.rvg-foot {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: auto;
}
.rvg-note {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-3);
  line-height: 1.4;
}
.rvg-note.rvg-loss { color: var(--danger); }
.rvg-note.rvg-gain { color: var(--success); }
.rvg-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 10.5px;
  font-weight: 800;
  background: var(--warning-soft);
  color: var(--warning);
  border: 1px solid var(--warning);
}
.rvg-badge.rvg-trusted {
  background: var(--success-soft);
  color: var(--success);
  border-color: var(--success);
}
.rvg-cta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 13px;
  background: var(--text);
  color: var(--bg);
  border-radius: 100px;
  font-size: 11.5px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: opacity .2s ease, transform .2s ease;
}
.rvg-cta:hover { opacity: .85; transform: translateY(-1px); }
.rvg-done {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  background: var(--success-soft);
  color: var(--success);
  border: 1px solid var(--success);
  border-radius: 100px;
  font-size: 10.5px;
  font-weight: 800;
}
@media (max-width: 1024px) {
  .rvg-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .rvg-grid { grid-template-columns: minmax(0, 1fr); }
  .rvg-wrap { padding: 14px 14px 16px; }
}
/* ════════════════════════════════════════════════════════════
   접근성·모바일 정비 (v135) — 키보드 포커스 · 넘침 보정 · SKU 카드형
   ════════════════════════════════════════════════════════════ */
/* 키보드 포커스 표시 — 전역 (마우스 클릭에는 표시되지 않음) */
:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}
.dropzone:focus-visible { outline: 2.5px solid var(--brand); outline-offset: 4px; }

/* 처음 시작하기 진행 바 — 모바일 가로 넘침 보정 (배경 확장 음수 여백 축소) */
@media (max-width: 768px) {
  .page[data-page="quickstart"] .qs-progress-sticky::after { left: -16px !important; right: -16px !important; }
}

/* SKU 테이블 → 모바일 카드형 전환 (좁은 화면에서 가로 스크롤 대신 카드) */
@media (max-width: 640px) {
  .sku-table thead { display: none; }
  .sku-table, .sku-table tbody { display: block; width: 100%; }
  .sku-table tr.is-drillable {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 3px 14px;
    position: relative;
    padding: 14px 14px 12px;
    margin: 0 0 10px 0;
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: 12px;
  }
  .sku-table tr.is-drillable td {
    display: block;
    border: none !important;
    padding: 3px 0;
    text-align: left !important;
  }
  /* 순위 배지 — 카드 우상단 고정 */
  .sku-table tr.is-drillable td:first-child {
    position: absolute; top: 12px; right: 12px; padding: 0;
  }
  /* 상품/옵션 — 카드 헤더 (전체 폭) */
  .sku-table tr.is-drillable td.sku-product-cell {
    grid-column: 1 / -1;
    padding-right: 40px;
    padding-bottom: 8px;
    margin-bottom: 4px;
    border-bottom: 1px solid var(--border-soft) !important;
  }
  /* 수치 셀 — 위에 작은 라벨 표시 */
  .sku-table tr.is-drillable td:nth-child(3)::before  { content: '매출'; }
  .sku-table tr.is-drillable td:nth-child(4)::before  { content: '물류비'; }
  .sku-table tr.is-drillable td:nth-child(5)::before  { content: '광고비'; }
  .sku-table tr.is-drillable td:nth-child(6)::before  { content: '매입원가'; }
  .sku-table tr.is-drillable td:nth-child(7)::before  { content: '원가상태'; }
  .sku-table tr.is-drillable td:nth-child(8)::before  { content: 'SKU 운영 실마진'; }
  .sku-table tr.is-drillable td:nth-child(9)::before  { content: '운영 마진율'; }
  .sku-table tr.is-drillable td:nth-child(10)::before { content: '판매수량'; }
  .sku-table tr.is-drillable td:nth-child(n+3)::before {
    display: block;
    font-family: 'Pretendard Variable', sans-serif;
    font-size: 10.5px;
    font-weight: 700;
    color: var(--text-3);
    margin-bottom: 1px;
  }
  /* 구분줄·펼침 상세·빈 행 — 전체 폭 블록 */
  .sku-table tr.sku-zero-divider,
  .sku-table tr.sku-drill-row,
  .sku-table tr.sku-table-empty { display: block; }
  .sku-table tr.sku-zero-divider td,
  .sku-table tr.sku-drill-row td { display: block; width: 100%; box-sizing: border-box; }
  .sku-table tr.sku-zero-divider td { border-radius: 10px; margin-bottom: 10px; }
  /* 펼침 상세 — 카드에 이어 붙는 형태 */
  .sku-table tr.is-drillable.is-drilled { border-radius: 12px 12px 0 0; margin-bottom: 0; }
  .sku-table tr.sku-drill-row { margin: 0 0 10px 0; }
  .sku-table tr.sku-drill-row td {
    border: 1.5px solid var(--border) !important;
    border-top: none !important;
    border-radius: 0 0 12px 12px;
    background: var(--surface-2);
  }
}
.empty-stage.released {
  background: var(--success-soft);
  color: var(--success);
}
.empty-stage.released::before { content: '✅'; }
.empty-stage.coming-soon {
  background: var(--warning-soft);
  color: var(--warning);
}
.empty-stage.coming-soon::before { content: '🌱'; }

/* ════════════════════════════════════════════════════════════
   🆕 6단계 NEW — Wing 파일 업로드 페이지
   ════════════════════════════════════════════════════════════ */

/* ── 업로드 페이지 헤더 (대시보드 hero와 다른 톤) ── */
.upload-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 24px;
  gap: 24px;
  flex-wrap: wrap;
}
.upload-hero-left h1 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: 8px;
}
.upload-hero-left p {
  font-size: 13.5px;
  color: var(--text-2);
  font-weight: 500;
  line-height: 1.6;
  max-width: 580px;
}
.upload-hero-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}
.upload-progress-meta {
  font-size: 12px;
  color: var(--text-2);
  font-weight: 600;
  letter-spacing: -0.005em;
}
.upload-progress-bar {
  width: 220px;
  height: 6px;
  background: var(--surface-2);
  border-radius: 999px;
  overflow: hidden;
}
.upload-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand-accent) 100%);
  border-radius: 999px;
  width: 0%;
  transition: width .6s cubic-bezier(.2,.8,.2,1);
}

/* ── 업로드 메인 그리드 (사이드 가이드 패널 제거 후 가로 전체) — v67.5 ── */
.upload-layout {
  display: block;
  margin-bottom: 18px;
}

/* ── 드롭존 (메인 카드) ── */
.dropzone {
  background: var(--surface);
  border: 2px dashed var(--hover-border);
  border-radius: var(--r-lg);
  padding: 56px 32px;
  text-align: center;
  cursor: pointer;
  transition: all .2s cubic-bezier(.2,.8,.2,1);
  position: relative;
  overflow: hidden;
}
.dropzone::before {
  content: '';
  position: absolute;
  top: -80px; left: 50%;
  transform: translateX(-50%);
  width: 480px; height: 200px;
  background: radial-gradient(ellipse at center, var(--brand-soft) 0%, transparent 70%);
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease;
}
.dropzone:hover,
.dropzone.is-hover {
  border-color: var(--brand);
  background: var(--brand-soft);
}
.dropzone:hover::before,
.dropzone.is-hover::before {
  opacity: 0.8;
}
.dropzone.is-hover {
  transform: scale(1.005);
}
.dropzone-icon {
  font-size: 48px;
  line-height: 1;
  margin-bottom: 16px;
  position: relative;
  z-index: 1;
  display: inline-block;
  transition: transform .2s ease;
}
.dropzone:hover .dropzone-icon,
.dropzone.is-hover .dropzone-icon {
  transform: translateY(-3px);
}
.dropzone-title {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text);
  margin-bottom: 6px;
  position: relative;
  z-index: 1;
}
.dropzone-desc {
  font-size: 13px;
  color: var(--text-2);
  font-weight: 500;
  line-height: 1.6;
  max-width: 460px;
  margin: 0 auto 16px;
  position: relative;
  z-index: 1;
}
.dropzone-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--brand);
  padding: 8px 16px;
  background: rgba(255,255,255,.85);
  border: 1px solid var(--border);
  border-radius: 999px;
  position: relative;
  z-index: 1;
  transition: all .15s ease;
}
.dropzone:hover .dropzone-cta,
.dropzone.is-hover .dropzone-cta {
  background: #fff;
  border-color: var(--brand);
  box-shadow: 0 4px 12px rgba(79,70,229,.15);
}
.dropzone-types {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 18px;
  position: relative;
  z-index: 1;
}
.dropzone-type-chip {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 4px 10px;
  background: var(--surface-2);
  color: var(--text-2);
  border-radius: 6px;
  font-family: 'JetBrains Mono', monospace;
}

/* ── 사이드 가이드 패널 ── */


/* ── 5종 파일 슬롯 섹션 ── */
.slots-section {
  margin-top: 8px;
}
.slots-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  gap: 12px;
}
.slots-section-title {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.slots-section-title-count {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-2);
  padding: 3px 8px;
  background: var(--surface-2);
  border-radius: 999px;
}
.slots-section-actions {
  display: flex;
  gap: 8px;
}


#proceedBtn.is-ready {
  animation: proceedPulse 1.8s cubic-bezier(.4, 0, .2, 1) infinite;
}
#proceedBtn[disabled],
#proceedBtn:not(.is-ready) {
  animation: none !important;
}
@keyframes proceedPulse {
  0%, 100% {
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.35), 0 0 0 0 rgba(79, 70, 229, 0.45);
  }
  50% {
    box-shadow: 0 4px 16px rgba(79, 70, 229, 0.5), 0 0 0 14px rgba(79, 70, 229, 0);
  }
}
[data-theme="dark"] #proceedBtn.is-ready {
  animation: proceedPulseDark 1.8s cubic-bezier(.4, 0, .2, 1) infinite;
}
@keyframes proceedPulseDark {
  0%, 100% { box-shadow: 0 2px 8px rgba(129, 140, 248, 0.4), 0 0 0 0 rgba(129, 140, 248, 0.5); }
  50%      { box-shadow: 0 4px 16px rgba(129, 140, 248, 0.55), 0 0 0 14px rgba(129, 140, 248, 0); }
}


#proceedBtn.topbar-highlight {
  outline: 3px solid var(--brand-accent);
  outline-offset: 4px;
  animation: proceedHighlightFlash 0.6s ease-in-out 3 !important;
}
@keyframes proceedHighlightFlash {
  0%, 100% { outline-color: var(--brand-accent); }
  50%      { outline-color: transparent; }
}


.slots-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));  /* 7종 = 4+3 분배 (시각 균형) */
  gap: 12px;
}
@media (min-width: 1600px) {
  .slots-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); }  /* 와이드 화면만 1행 7열 */
}
@media (max-width: 1280px) {
  .slots-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }  /* 중간 화면 3열 (3+3+1) */
}
@media (max-width: 768px) {
  .slots-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 540px) {
  .slots-grid { grid-template-columns: 1fr; }
}

/* ── 개별 슬롯 카드 ── */
.slot {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: all .2s ease;
  position: relative;
  cursor: pointer;
  min-height: 168px;
}
.slot:hover {
  border-color: var(--hover-border);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}
.slot.is-empty .slot-status-text {
  color: var(--text-3);
}
.slot.is-loaded {
  border-color: var(--success);
  background: linear-gradient(180deg, var(--success-soft) 0%, var(--surface) 35%);
}
.slot.is-loaded:hover {
  border-color: var(--success);
  box-shadow: 0 4px 12px rgba(16, 185, 129, .15);
}
.slot.is-error {
  border-color: var(--danger);
  background: linear-gradient(180deg, var(--danger-soft) 0%, var(--surface) 35%);
}
.slot.is-error:hover {
  border-color: var(--danger);
  box-shadow: 0 4px 12px rgba(225, 29, 72, .15);
}

.slot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.slot-icon {
  width: 32px; height: 32px;
  border-radius: 8px;
  background: var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
  transition: all .2s ease;
}
.slot.is-loaded .slot-icon {
  background: var(--success);
  color: #fff;
}
.slot.is-error .slot-icon {
  background: var(--danger);
  color: #fff;
}
.slot-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 10.5px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-3);
  letter-spacing: 0.01em;
  text-transform: uppercase;
}
.slot-status::before {
  content: '';
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--text-3);
}
.slot.is-loaded .slot-status {
  background: var(--success-soft);
  color: var(--success);
}
.slot.is-loaded .slot-status::before {
  background: var(--success);
  box-shadow: 0 0 0 3px rgba(16,185,129,.15);
}
.slot.is-error .slot-status {
  background: var(--danger-soft);
  color: var(--danger);
}
.slot.is-error .slot-status::before {
  background: var(--danger);
  box-shadow: 0 0 0 3px rgba(225,29,72,.15);
}

.slot-body {
  flex: 1;
}
.slot-type {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-3);
  letter-spacing: 0.02em;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.slot-optional-badge {
  display: inline-flex;
  align-items: center;
  font-family: 'Pretendard Variable', sans-serif;
  font-size: 9.5px;
  font-weight: 700;
  padding: 2px 7px;
  background: var(--info-soft);
  color: var(--info);
  border-radius: 999px;
  letter-spacing: 0.01em;
  border: 1px solid rgba(14, 165, 233, .15);
}
.slot-name {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.015em;
  margin-bottom: 4px;
  line-height: 1.3;
}
.slot-desc {
  font-size: 11.5px;
  color: var(--text-2);
  font-weight: 500;
  line-height: 1.45;
}


.slot-actions {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}
.slot-btn {
  flex: 1;
  height: 28px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text-2);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all .15s ease;
  letter-spacing: -0.005em;
}
.slot-btn:hover {
  background: var(--surface-2);
  border-color: var(--hover-border);
  color: var(--text);
}
.slot-btn.danger:hover {
  background: var(--danger-soft);
  border-color: var(--danger);
  color: var(--danger);
}

/* ── 분류 불가 영역 (초기 숨김) ── */
.unclassified-section {
  margin-top: 18px;
  background: var(--warning-soft);
  border: 1px solid #fde68a;
  border-radius: var(--r);
  padding: 18px 20px;
  display: none;
}
.unclassified-section.is-visible {
  display: block;
  animation: fadeUp .35s cubic-bezier(.2,.8,.2,1);
}
.unclassified-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.unclassified-title {
  font-size: 13.5px;
  font-weight: 800;
  color: #92400e;
  letter-spacing: -0.015em;
}
.unclassified-desc {
  font-size: 12px;
  color: #92400e;
  font-weight: 500;
  margin-top: 2px;
}
.unclassified-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.unclassified-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1px solid #fde68a;
  border-radius: 8px;
  padding: 10px 12px;
}
.unclassified-item-name {
  flex: 1;
  font-size: 12px;
  color: var(--text);
  font-weight: 600;
  word-break: break-all;
}
.unclassified-item-select {
  height: 30px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  font-family: inherit;
}
.unclassified-item-select:focus {
  outline: none;
  border-color: var(--brand);
}
.unclassified-item-remove {
  width: 28px; height: 28px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text-3);
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .15s ease;
}
.unclassified-item-remove:hover {
  background: var(--danger-soft);
  border-color: var(--danger);
  color: var(--danger);
}

/* ── 미리보기 모달 ── */
.preview-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(10, 10, 15, .55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: fadeIn .2s ease;
}
.preview-modal.is-open {
  display: flex;
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.preview-modal-card {
  background: var(--surface);
  border-radius: var(--r-lg);
  width: 100%;
  max-width: 920px;
  max-height: 86vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: previewSlideUp .3s cubic-bezier(.2,.8,.2,1);
}
@keyframes previewSlideUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.preview-head {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.preview-head-left {
  flex: 1;
  min-width: 0;
}
.preview-head-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.preview-head-type {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  color: var(--brand);
  background: var(--brand-soft);
  padding: 3px 9px;
  border-radius: 999px;
  letter-spacing: 0.01em;
}
.preview-head-title {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  word-break: break-all;
}
.preview-head-sub {
  font-size: 12px;
  color: var(--text-2);
  font-weight: 500;
  margin-top: 4px;
  font-family: 'JetBrains Mono', monospace;
}
.preview-close {
  width: 32px; height: 32px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text-2);
  font-size: 16px;
  cursor: pointer;
  flex-shrink: 0;
  transition: all .15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
.preview-close:hover {
  background: var(--surface-2);
  color: var(--text);
}
.preview-body {
  padding: 18px 24px 0;
  overflow: auto;
  flex: 1;
}
.preview-validation {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 10px;
  margin-bottom: 16px;
  font-size: 12.5px;
  font-weight: 600;
}
.preview-validation.ok {
  background: var(--success-soft);
  color: #065f46;
  border: 1px solid #a7f3d0;
}
.preview-validation.warn {
  background: var(--warning-soft);
  color: #92400e;
  border: 1px solid #fde68a;
}
.preview-validation-icon {
  font-size: 14px;
  flex-shrink: 0;
}
/* ⭐ v149 (28차 R5 / P8-3) — 슬롯 카드 클릭 시 상세 오류 복구 안내 */
.preview-error-detail {
  padding: 14px 16px;
  border-radius: 10px;
  margin-bottom: 16px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}
.preview-error-detail-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 10px;
}
.preview-error-detail-body {
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--text-2);
}
.preview-error-detail-body dt {
  font-weight: 700;
  color: var(--text);
  margin-top: 10px;
}
.preview-error-detail-body dt:first-child {
  margin-top: 0;
}
.preview-error-detail-body dd {
  margin: 2px 0 0;
}
.preview-error-detail-body a {
  color: var(--brand);
}
.preview-table-wrap {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: auto;
  max-height: 360px;
  position: relative;
}
.preview-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  font-family: 'JetBrains Mono', monospace;
}
.preview-table thead th {
  background: var(--surface-2);
  color: var(--text);
  font-weight: 700;
  text-align: left;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border-soft);
  position: sticky;
  top: 0;
  white-space: nowrap;
  font-size: 11px;
  letter-spacing: 0.01em;
}
.preview-table thead th:last-child { border-right: none; }
.preview-table tbody td {
  padding: 7px 12px;
  border-bottom: 1px solid var(--border-soft);
  border-right: 1px solid var(--border-soft);
  color: var(--text-2);
  white-space: nowrap;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.preview-table tbody td:last-child { border-right: none; }
.preview-table tbody tr:nth-child(even) td {
  background: rgba(245, 245, 247, .4);
}
.preview-table tbody tr:hover td {
  background: var(--brand-soft);
  color: var(--text);
}
.preview-foot {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  background: var(--surface-3);
}
.preview-foot-info {
  font-size: 12px;
  color: var(--text-2);
  font-weight: 500;
}
.preview-foot-info strong {
  color: var(--text);
  font-weight: 700;
}
.preview-foot-actions {
  display: flex;
  gap: 8px;
}

/* ── 토스트 알림 (오른쪽 하단) ── */
.upload-toast-wrap {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.upload-toast {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: var(--shadow-lg);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
  min-width: 280px;
  max-width: 380px;
  pointer-events: auto;
  animation: toastIn .3s cubic-bezier(.2,.8,.2,1);
}
.upload-toast.is-leaving {
  animation: toastOut .25s cubic-bezier(.4,0,.2,1) forwards;
}
@keyframes toastIn {
  from { opacity: 0; transform: translateX(20px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes toastOut {
  from { opacity: 1; transform: translateX(0); }
  to   { opacity: 0; transform: translateX(20px); }
}
.upload-toast-icon {
  width: 22px; height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
  color: #fff;
}
.upload-toast.success .upload-toast-icon { background: var(--success); }
.upload-toast.error   .upload-toast-icon { background: var(--danger); }
.upload-toast.info    .upload-toast-icon { background: var(--info); }
.upload-toast.warn    .upload-toast-icon { background: var(--warning); }
.upload-toast-text {
  flex: 1;
  line-height: 1.4;
}
.upload-toast-text small {
  display: block;
  font-size: 11px;
  color: var(--text-2);
  font-weight: 500;
  margin-top: 2px;
}


/* ════════════════════════════════════════════════════════════
   🆕 6단계 NEW v2 — 다중 파일 / 기간 트래킹 / 캘린더
   ════════════════════════════════════════════════════════════ */

/* 드롭존 보조 힌트 */
.dropzone-hint {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  padding: 5px 12px;
  background: rgba(255,255,255,.7);
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-3);
  position: relative;
  z-index: 1;
}

/* ── 다중 파일 슬롯 (확장된 슬롯) ── */
.slot-files-summary {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-2);
  margin-bottom: 4px;
  flex-wrap: wrap;
}
.slot-files-summary .slot-file-count {
  background: var(--text);
  color: var(--btn-primary-fg);
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
}
.slot.is-loaded .slot-files-summary .slot-file-count {
  background: var(--success);
}
.slot-files-summary .dot { color: var(--text-3); }

.slot-period-range {
  font-size: 11.5px;
  color: var(--text-2);
  font-weight: 600;
  margin-bottom: 6px;
  font-family: 'JetBrains Mono', monospace;
}
.slot-rows-total {
  font-size: 11px;
  color: var(--text-3);
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
}

/* 슬롯 내 미니 캘린더 스트립 */
.slot-week-strip {
  display: flex;
  gap: 3px;
  margin-top: 8px;
  flex-wrap: wrap;
}
.slot-week-cell {
  flex: 1;
  min-width: 14px;
  height: 6px;
  border-radius: 2px;
  background: var(--border);
  transition: background .2s ease;
}
.slot-week-cell.is-filled {
  background: var(--success);
}
.slot.is-error .slot-week-cell.is-filled {
  background: var(--danger);
}

/* 슬롯 액션바 */
.slot-actions .slot-btn[data-action="add-more"] {
  background: var(--brand-soft);
  color: var(--brand);
  border-color: transparent;
  font-weight: 700;
}
.slot-actions .slot-btn[data-action="add-more"]:hover {
  background: var(--brand);
  color: #fff;
}

/* ── 페이지 하단 종합 캘린더 패널 ── */
.coverage-panel {
  margin-top: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px 22px;
  box-shadow: var(--shadow-xs);
}
.coverage-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 12px;
  flex-wrap: wrap;
}
.coverage-panel-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14.5px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.coverage-panel-meta {
  font-size: 11.5px;
  color: var(--text-2);
  font-weight: 600;
  font-family: 'JetBrains Mono', monospace;
}
.coverage-panel-meta strong {
  color: var(--text);
  font-weight: 700;
}

/* 빈 상태 */
.coverage-empty {
  padding: 24px 16px;
  text-align: center;
  color: var(--text-3);
  font-size: 12.5px;
  font-weight: 500;
  background: var(--surface-2);
  border-radius: 10px;
}

/* 5종 × 주차 그리드 */
.coverage-grid {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 8px 14px;
  align-items: center;
}
.coverage-row-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text);
}
.coverage-row-label-icon {
  width: 22px; height: 22px;
  border-radius: 6px;
  background: var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  flex-shrink: 0;
}
.coverage-row-label-key {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-2);
  letter-spacing: 0.01em;
  word-break: break-all;
  line-height: 1.3;
}

.coverage-row-cells {
  display: flex;
  gap: 4px;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 4px;
}
.coverage-row-cells::-webkit-scrollbar { height: 4px; }
.coverage-row-cells::-webkit-scrollbar-track { background: var(--surface-2); border-radius: 999px; }
.coverage-row-cells::-webkit-scrollbar-thumb { background: var(--border); border-radius: 999px; }

.coverage-cell {
  min-width: 32px;
  height: 30px;
  border-radius: 5px;
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 9.5px;
  font-weight: 700;
  color: var(--text-3);
  font-family: 'JetBrains Mono', monospace;
  cursor: default;
  transition: all .15s ease;
  position: relative;
  letter-spacing: -0.01em;
  padding: 0 4px;
}
.coverage-cell.is-filled {
  background: var(--success);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 1px 3px rgba(16,185,129,.25);
}
.coverage-cell.is-filled:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(16,185,129,.35);
}
.coverage-cell.is-missing {
  background: repeating-linear-gradient(
    45deg,
    var(--surface-2),
    var(--surface-2) 4px,
    #fff 4px,
    #fff 8px
  );
  border-color: var(--border);
}

/* 컬럼 헤더 (주차 라벨) */

.coverage-header-spacer { /* 빈 공간 */ }
.coverage-header-cells {
  display: flex;
  gap: 4px;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 4px;
}
.coverage-header-cells::-webkit-scrollbar { height: 4px; }
.coverage-header-cells::-webkit-scrollbar-track { background: transparent; }
.coverage-header-cell {
  min-width: 32px;
  font-size: 9.5px;
  font-weight: 700;
  color: var(--text-3);
  text-align: center;
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: -0.01em;
  padding: 0 4px;
  line-height: 1.2;
}

/* 범례 */
.coverage-legend {
  display: flex;
  gap: 14px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
  font-size: 11px;
  color: var(--text-2);
  font-weight: 600;
  flex-wrap: wrap;
}
.coverage-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}
.coverage-legend-swatch {
  width: 14px;
  height: 14px;
  border-radius: 3px;
}
.coverage-legend-swatch.filled {
  background: var(--success);
}
.coverage-legend-swatch.missing {
  background: repeating-linear-gradient(
    45deg,
    var(--surface-2),
    var(--surface-2) 3px,
    #fff 3px,
    #fff 6px
  );
  border: 1px solid var(--border);
}

/* ── 미리보기 모달 — 다중 파일 탭 ── */
.preview-tabs {
  display: flex;
  gap: 2px;
  padding: 0 24px;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  background: var(--surface-3);
}
.preview-tabs::-webkit-scrollbar { height: 4px; }
.preview-tab {
  flex-shrink: 0;
  padding: 10px 14px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-2);
  border: none;
  background: transparent;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all .15s ease;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  letter-spacing: -0.005em;
  white-space: nowrap;
}
.preview-tab:hover {
  color: var(--text);
  background: var(--surface);
}
.preview-tab.is-active {
  color: var(--brand);
  border-bottom-color: var(--brand);
  background: var(--surface);
}
.preview-tab-period {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: var(--text-3);
  font-weight: 600;
}
.preview-tab.is-active .preview-tab-period {
  color: var(--brand);
}
.preview-tab-remove {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  border: none;
  background: transparent;
  color: var(--text-3);
  font-size: 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 2px;
  transition: all .15s ease;
}
.preview-tab-remove:hover {
  background: var(--danger-soft);
  color: var(--danger);
}

/* 미리보기 모달이 다중 파일 모드일 때 head 영역 위치 조정 */
.preview-modal-card.has-tabs .preview-head {
  padding-bottom: 12px;
}

/* 중복 파일 거부 토스트 (강조) */
.upload-toast.duplicate {
  border-color: var(--danger);
  border-width: 1.5px;
}
.upload-toast.duplicate .upload-toast-icon {
  background: var(--danger);
}


/* 로그인 페이지 컨테이너 — 화면 전체 차지 */
.login-page {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 48px 24px;
  overflow-y: auto;

  /* ⭐ v25+ G.6-C — 미드나잇 + 골드 (Stripe / Vercel Pro 톤) */
  background:
    radial-gradient(ellipse 70% 50% at 70% 20%, rgba(212, 165, 116, .12), transparent 60%),
    radial-gradient(ellipse 60% 40% at 25% 80%, rgba(180, 140, 90, .08), transparent 65%),
    linear-gradient(135deg, #0a1228 0%, #131a2e 50%, #1a2540 100%);
}

/* 로그인 페이지 활성화 시 표시 */
.login-page.active {
  display: flex;
}

/* 화면이 충분히 클 때만 컨테이너를 세로 중앙으로 (margin auto 트릭) */
.login-page.active .login-container {
  margin: auto 0;
}

/* 로그인 페이지가 활성화되면 사이드바·토프바 숨김 */
body.is-login .wrap {
  display: none;
}

/* 노이즈 라이트 효과 (배경 위 점 패턴) */
.login-page::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 1px 1px, rgba(255,255,255,.04) 1px, transparent 0);
  background-size: 24px 24px;
  pointer-events: none;
}

/* 로그인 컨테이너 (로고 + hero + 카드 + 푸터) — ⭐ v25+ G.6-B: 차별화 8가지 제거로 폭 축소 */
.login-container {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 460px; /* ⭐ v25+ G.6-B: 800 → 460 (8가지 제거 후 적정) */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

/* 상단 셀러린 로고 영역 */
.login-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  animation: loginSlideDown .7s cubic-bezier(.2,.8,.2,1) backwards;
}

.login-brand-mark {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .25), 0 0 0 1px rgba(255, 255, 255, .1);
  overflow: hidden;
}
/* v44.1 — V+Sellerin 정사각형 (OAuth Console과 100% 일치) */
.login-brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.login-brand-name {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -.02em;
  color: #ffffff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, .2);
}

.login-brand-tagline {
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, .7);
  text-align: center;
}


.login-hero {
  width: 100%;
  max-width: 520px;
  text-align: center;
  margin: 4px 0 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  animation: loginFadeUp .7s cubic-bezier(.2,.8,.2,1) 0.1s backwards;
}

.login-hero-headline {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: center;
}

.login-hero-line-1 {
  font-size: 18px;
  font-weight: 500;
  color: rgba(255, 255, 255, .55);
  letter-spacing: -.01em;
  line-height: 1.4;
}

.login-hero-line-2 {
  font-size: 22px;
  font-weight: 800;
  color: rgba(255, 255, 255, .98);
  letter-spacing: -.02em;
  line-height: 1.35;
  text-shadow: 0 2px 16px rgba(0, 0, 0, .3);
}

.login-hero-subcopy {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(129, 140, 248, .14);
  border: 1px solid rgba(129, 140, 248, .3);
  color: #c7d2fe;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: -.01em;
}


/* 로그인 카드 (백드롭 블러 + 흰 배경) */
.login-card {
  width: 100%;
  max-width: 440px; /* ⭐ v18.3: login-container 폭 확장에 따라 카드 자체 폭 명시 */
  background: rgba(255, 255, 255, .98);
  border-radius: var(--r-xl);
  padding: 36px 32px;
  box-shadow:
    0 24px 64px rgba(0, 0, 0, .25),
    0 8px 16px rgba(0, 0, 0, .15),
    0 0 0 1px rgba(255, 255, 255, .1);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  animation: loginFadeUp .7s cubic-bezier(.2,.8,.2,1) 0.15s backwards;
}

.login-card-head {
  text-align: center;
  margin-bottom: 28px;
}

.login-card-title {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -.02em;
  color: var(--text);
  margin: 0 0 6px;
}

.login-card-desc {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-2);
  margin: 0;
}


[data-theme="dark"] .login-card .login-card-title { color: #0a0a0f; }
[data-theme="dark"] .login-card .login-card-desc { color: #52525b; }
[data-theme="dark"] .login-card .login-divider-text { color: #a1a1aa; }
[data-theme="dark"] .login-card .login-email-btn { background: #f5f5f7; color: #a1a1aa; border-color: #ececf0; }

/* Google 로그인 버튼 */
.login-google-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 14px 20px;
  background: #ffffff;
  color: #1f1f1f;
  border: 1px solid #dadce0;
  border-radius: var(--r);
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: -.01em;
  cursor: pointer;
  transition: all .2s cubic-bezier(.2,.8,.2,1);
  box-shadow: var(--shadow-xs);
  font-family: inherit;
}

.login-google-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  border-color: #c0c0c0;
}

.login-google-btn:active {
  transform: translateY(0);
}

/* Google "G" 로고 SVG */
.login-google-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* 구분선 (또는) */
.login-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 24px 0;
}

.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.login-divider-text {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-3);
}

/* 이메일 로그인 (비활성 상태) */
.login-email-btn {
  width: 100%;
  padding: 14px 20px;
  background: var(--surface-2);
  color: var(--text-3);
  border: 1px dashed var(--border);
  border-radius: var(--r);
  font-size: 13.5px;
  font-weight: 500;
  cursor: not-allowed;
  font-family: inherit;
  text-align: center;
}

/* ⭐ v151 (2026-08-05) — 이메일/비밀번호 로그인 토글 + 확장 패널 */
.login-email-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 14px;
  padding: 10px 12px;
  background: transparent;
  border: none;
  color: var(--text-2);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: color .2s;
}
.login-email-toggle:hover { color: var(--brand); }
[data-theme="dark"] .login-card .login-email-toggle { color: #52525b; }
[data-theme="dark"] .login-card .login-email-toggle:hover { color: var(--brand); }

.login-email-toggle-icon {
  flex-shrink: 0;
  transition: transform .25s cubic-bezier(.2,.8,.2,1);
}
.login-email-toggle[aria-expanded="true"] .login-email-toggle-icon {
  transform: rotate(180deg);
}

.login-email-panel {
  margin-top: 6px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  animation: loginFadeUp .3s cubic-bezier(.2,.8,.2,1) backwards;
}
[data-theme="dark"] .login-card .login-email-panel { border-top-color: #ececf0; }

.login-email-tabs {
  display: flex;
  gap: 4px;
  background: var(--surface-2);
  border-radius: var(--r-sm);
  padding: 3px;
  margin-bottom: 16px;
}
[data-theme="dark"] .login-card .login-email-tabs { background: #f5f5f7; }

.login-email-tab {
  flex: 1;
  padding: 8px 12px;
  background: transparent;
  border: none;
  border-radius: 6px;
  color: var(--text-3);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all .2s;
}
[data-theme="dark"] .login-card .login-email-tab { color: #a1a1aa; }

.login-email-tab.is-active {
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-xs);
}
[data-theme="dark"] .login-card .login-email-tab.is-active { background: #ffffff; color: #0a0a0f; }

.login-email-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
/* ⭐ v151.1 (2026-08-05) 핫픽스 — display:flex 가 hidden 속성보다 우선 적용되어
   로그인/회원가입 두 폼이 동시에 보이던 문제 수정 (탭 전환 시 실제로 숨김 처리) */
.login-email-form[hidden] {
  display: none;
}

.login-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.login-field-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
}
[data-theme="dark"] .login-card .login-field-label { color: #52525b; }

.login-field-input {
  width: 100%;
  padding: 11px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  transition: border-color .2s, box-shadow .2s;
}
.login-field-input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}
[data-theme="dark"] .login-card .login-field-input {
  background: #ffffff;
  border-color: #ececf0;
  color: #0a0a0f;
}
[data-theme="dark"] .login-card .login-field-input:focus {
  box-shadow: 0 0 0 3px #eef2ff;
}

.login-email-submit {
  width: 100%;
  margin-top: 4px;
  padding: 13px 20px;
  background: var(--brand);
  color: #ffffff;
  border: none;
  border-radius: var(--r);
  font-size: 14px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all .2s cubic-bezier(.2,.8,.2,1);
}
.login-email-submit:hover { background: var(--brand-dk); transform: translateY(-1px); }
.login-email-submit:active { transform: translateY(0); }
.login-email-submit:disabled {
  cursor: wait;
  opacity: .7;
  pointer-events: none;
}

/* 푸터 */
.login-footer {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, .5);
  text-align: center;
  letter-spacing: -.01em;
  animation: loginFadeUp .7s cubic-bezier(.2,.8,.2,1) 0.3s backwards;
}

.login-footer a {
  color: rgba(255, 255, 255, .7);
  text-decoration: none;
  transition: color .2s;
}

.login-footer a:hover {
  color: rgba(255, 255, 255, .95);
}

/* 🆕 v21 [A] — 로그인 푸터 무료 도구 진입 영역 */


.login-footer-meta {
  font-size: 12px;
  color: rgba(255, 255, 255, .5);
}
/* ⭐ v35 옵션 L.3 — 약관·정책 링크 (개인정보처리방침·이용약관·환불정책) */
.login-footer-legal {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 10px;
  font-size: 11.5px;
  color: rgba(255, 255, 255, .42);
  flex-wrap: wrap;
}
.login-footer-legal a {
  color: rgba(255, 255, 255, .62) !important;
  text-decoration: none;
  transition: color .2s;
  font-weight: 500;
}
.login-footer-legal a:hover {
  color: rgba(255, 255, 255, .92) !important;
  text-decoration: underline;
}
.login-footer-legal-sep {
  color: rgba(255, 255, 255, .22);
  font-size: 10.5px;
}
@media (max-width: 480px) {
  
  
  
  .login-footer-legal { gap: 6px; font-size: 11px; }
  .login-footer-legal-sep { display: none; }
}

/* 로그인 전용 애니메이션 */
@keyframes loginSlideDown {
  from { opacity: 0; transform: translateY(-12px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes loginFadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Google 로그인 버튼 비활성 상태 (로그인 진행 중) */
.login-google-btn:disabled,
.login-google-btn.is-loading {
  cursor: wait;
  opacity: .7;
  pointer-events: none;
}

/* 로딩 스피너 */
.login-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid #e5e7eb;
  border-top-color: #4285F4;
  border-radius: 50%;
  animation: spin .7s linear infinite;
}

/* 로그인 에러 메시지 */
.login-error {
  margin-top: 16px;
  padding: 12px 16px;
  background: var(--danger-soft);
  border: 1px solid var(--danger);
  border-radius: var(--r-sm);
  color: var(--danger);
  font-size: 13px;
  font-weight: 500;
  text-align: center;
  display: none;
}

.login-error.show {
  display: block;
  animation: loginFadeUp .3s cubic-bezier(.2,.8,.2,1) backwards;
}

/* ⭐ v153 (2026-08-12) — 이메일 인증 안내(성공 톤) + 재발송 버튼 */
.login-notice {
  margin-top: 16px;
  padding: 12px 16px;
  background: var(--success-soft);
  border: 1px solid var(--success);
  border-radius: var(--r-sm);
  color: var(--success);
  font-size: 13px;
  font-weight: 500;
  text-align: center;
  display: none;
}
.login-notice.show {
  display: block;
  animation: loginFadeUp .3s cubic-bezier(.2,.8,.2,1) backwards;
}
/* 로그인 카드는 다크모드에서도 라이트 고정 — 기존 오버라이드 패턴(라이트 리터럴) 준수 */
[data-theme="dark"] .login-card .login-notice { background: #ecfdf5; border-color: #10b981; color: #059669; }

.login-resend-row {
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text-2);
}
.login-resend-row[hidden] { display: none !important; } /* v151.1 교훈 — hidden 속성 우선 보장 */
.login-resend-btn {
  background: none;
  border: none;
  padding: 2px 4px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--brand);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.login-resend-btn:hover { color: var(--brand-dk); }
.login-resend-btn:disabled { opacity: .5; cursor: default; }
[data-theme="dark"] .login-card .login-resend-row { color: #52525b; }

/* ⭐ v25+ G.6-B: 차별화 8가지 (.feature-strip / .feature-grid / .feature-card 등) CSS 제거 완료 */

/* 로그인 카드 반응형 (모바일) */
@media (max-width: 480px) {
  .login-page { padding: 16px; }
  .login-card { padding: 28px 24px; }
  .login-brand-name { font-size: 24px; }
  .login-card-title { font-size: 19px; }
  /* ⭐ v25+ G.6-A: 로그인 hero 모바일 폰트 축소 */
  .login-hero-line-1 { font-size: 15.5px; }
  .login-hero-line-2 { font-size: 18px; line-height: 1.3; }
  .login-hero-subcopy { font-size: 11.5px; padding: 7px 14px; }
}

/* ════════════════════════════════════════════════════════════
   반응형
   ════════════════════════════════════════════════════════════ */
@media (max-width: 1180px) {
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .insight-list { grid-template-columns: 1fr; }
  .chart-grid { grid-template-columns: 1fr; }
  .bottom-grid { grid-template-columns: 1fr; }
}
}

/* ════════════════════════════════════════════════════════════
   페이드업 애니메이션
   ════════════════════════════════════════════════════════════ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero { animation: fadeUp .5s cubic-bezier(.2,.8,.2,1) backwards; }
.kpi { animation: fadeUp .5s cubic-bezier(.2,.8,.2,1) backwards; }
.kpi:nth-child(1) { animation-delay: 0.05s; }
.kpi:nth-child(2) { animation-delay: 0.10s; }
.kpi:nth-child(3) { animation-delay: 0.15s; }
.kpi:nth-child(4) { animation-delay: 0.20s; }
.insight-strip { animation: fadeUp .55s cubic-bezier(.2,.8,.2,1) 0.25s backwards; }
.chart-grid > * { animation: fadeUp .55s cubic-bezier(.2,.8,.2,1) 0.30s backwards; }
.bottom-grid > * { animation: fadeUp .55s cubic-bezier(.2,.8,.2,1) 0.35s backwards; }

/* ═══════════════════════════════════════════════════════════════════
   7+9단계 NEW — SKU별 분석 페이지 (옵션ID 단위 집계)
═══════════════════════════════════════════════════════════════════ */

/* 빈 상태 (분석 진행 전) */
.sku-empty {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 60px 40px;
  text-align: center;
  box-shadow: var(--shadow-xs);
}

#skuLoading {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 72px 40px;
  text-align: center;
  box-shadow: var(--shadow-xs);
}
.sku-loading-spinner {
  width: 36px;
  height: 36px;
  margin: 0 auto 18px;
  border: 3px solid var(--surface-2);
  border-top-color: var(--brand);
  border-radius: 50%;
  animation: skuLoadingSpin 0.8s linear infinite;
}
.sku-loading-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}
.sku-loading-desc {
  font-size: 12.5px;
  color: var(--text-2);
}
@keyframes skuLoadingSpin {
  to { transform: rotate(360deg); }
}
.sku-empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.7;
}
.sku-empty-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}
.sku-empty-desc {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.7;
  margin-bottom: 24px;
}
.sku-empty-action {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--brand);
  color: #fff;
  padding: 11px 22px;
  border-radius: var(--r-sm);
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(.2,.8,.2,1);
  box-shadow: var(--shadow-sm);
}
.sku-empty-action:hover {
  background: var(--brand-dk);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* SKU 페이지 헤더 영역 */
.sku-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.sku-header-left { flex: 1; min-width: 0; }
.sku-header-title {
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.025em;
  margin-bottom: 6px;
}
.sku-header-meta {
  font-size: 13px;
  color: var(--text-2);
  font-weight: 500;
}
.sku-header-meta .sku-meta-divider {
  display: inline-block;
  margin: 0 8px;
  color: var(--text-3);
}
.sku-trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.sku-trust-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
}
.sku-trust-badge.warning {
  background: var(--warning-soft);
  color: #92400e;
}
.sku-trust-badge.warning::before { background: var(--warning); }
.sku-trust-badge.success {
  background: var(--success-soft);
  color: #065f46;
}
.sku-trust-badge.success::before { background: var(--success); }

/* SKU KPI 그리드 */
.sku-kpi-grid {
  display: grid;
  
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}
.sku-kpi {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  /* 🆕 v87 — 1행 6개 압축에 맞춰 패딩 축소 */
  padding: 14px 13px;
  box-shadow: var(--shadow-xs);
  transition: all 0.2s cubic-bezier(.2,.8,.2,1);
  animation: fadeUp 0.5s cubic-bezier(.2,.8,.2,1) backwards;
}
.sku-kpi:nth-child(1) { animation-delay: 0.05s; }
.sku-kpi:nth-child(2) { animation-delay: 0.10s; }
.sku-kpi:nth-child(3) { animation-delay: 0.15s; }
.sku-kpi:nth-child(4) { animation-delay: 0.20s; }
.sku-kpi:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  border-color: #e0e0e7;
}

.sku-kpi.is-clickable {
  cursor: pointer;
  position: relative;
}
.sku-kpi.is-clickable:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: var(--brand);
}
.sku-kpi.is-clickable:active {
  transform: translateY(0);
}
.sku-kpi-jump-hint {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--brand);
  background: var(--brand-soft);
  padding: 3px 8px;
  border-radius: 999px;
  transition: all 0.15s ease;
  opacity: 0.85;
}
.sku-kpi.is-clickable:hover .sku-kpi-jump-hint {
  opacity: 1;
  background: var(--brand);
  color: var(--btn-primary-fg);
}
.sku-kpi-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  /* 🆕 v87 — 1행 6개 압축에 맞춰 축소 */
  font-size: 11px;
  font-weight: 600;
  color: var(--text-2);
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.sku-kpi-value {
  font-family: 'JetBrains Mono', monospace;
  /* 🆕 v87 — 1행 6개 압축에 맞춰 축소 (26 → 19) */
  font-size: 19px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.sku-kpi-value.profit { color: var(--success); }
.sku-kpi-value.loss { color: var(--danger); }
.sku-kpi-sub {
  margin-top: 8px;
  font-size: 11.5px;
  color: var(--text-3);
  font-weight: 500;
}


/* 광고 매핑 토글 카드 */
.ad-mapping-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px 22px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-xs);
  animation: fadeUp 0.55s cubic-bezier(.2,.8,.2,1) 0.30s backwards;
}
.ad-mapping-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.ad-mapping-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.015em;
}
.ad-mapping-sub {
  font-size: 12px;
  color: var(--text-3);
  font-weight: 500;
  margin-top: 2px;
}

/* 수동 매핑 패널 */
.ad-manual-panel {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-soft);
  display: none;
}
.ad-manual-panel.open { display: block; }
.ad-manual-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.ad-manual-desc {
  font-size: 12px;
  color: var(--text-2);
  margin-bottom: 14px;
  line-height: 1.6;
}
.ad-manual-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}
.ad-manual-table thead th {
  text-align: left;
  padding: 8px 10px;
  background: var(--surface-2);
  font-weight: 700;
  color: var(--text-2);
  font-size: 11.5px;
  letter-spacing: -0.005em;
  border-bottom: 1px solid var(--border);
}
.ad-manual-table tbody td {
  padding: 10px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: middle;
}
.ad-manual-table tbody tr:last-child td { border-bottom: none; }
.ad-manual-campaign-name {
  font-weight: 600;
  color: var(--text);
}
.ad-manual-campaign-cost {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  color: var(--brand);
  font-size: 12.5px;
}
.ad-manual-actions {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  justify-content: flex-end;
}
.ad-manual-btn {
  padding: 8px 16px;
  border-radius: var(--r-sm);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
}
.ad-manual-btn:hover { border-color: var(--text-3); background: var(--surface-2); }
.ad-manual-btn.primary {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}
.ad-manual-btn.primary:hover { background: var(--brand-dk); border-color: var(--brand-dk); }

/* SKU 테이블 */
.sku-table-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 22px 24px;
  box-shadow: var(--shadow-xs);
  animation: fadeUp 0.55s cubic-bezier(.2,.8,.2,1) 0.35s backwards;
}
.sku-table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 12px;
}
.sku-table-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
}
.sku-table-controls {
  display: flex;
  gap: 8px;
  align-items: center;
}
.sku-search {
  padding: 7px 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-size: 12.5px;
  width: 220px;
  font-family: inherit;
  background: var(--surface);
  color: var(--text);
  transition: border-color 0.2s;
}
.sku-search:focus {
  outline: none;
  border-color: var(--brand);
}

.sku-bulk-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--r);
  margin: 12px 0 14px;
  flex-wrap: wrap;
  transition: all 0.2s;
}
.sku-bulk-bar.active {
  background: var(--brand-soft);
  border-color: var(--brand-accent);
}
.sku-bulk-count {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text);
  font-family: 'JetBrains Mono', monospace;
  padding: 4px 10px;
  background: var(--surface);
  border-radius: 999px;
  border: 1px solid var(--border);
}
.sku-bulk-bar.active .sku-bulk-count {
  background: var(--brand);
  color: var(--btn-primary-fg);
  border-color: var(--brand);
}
.sku-bulk-arrow {
  color: var(--text-2);
  font-size: 13px;
  font-weight: 600;
}
.sku-bulk-select {
  padding: 7px 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-size: 12.5px;
  background: var(--surface);
  color: var(--text);
  font-family: inherit;
  min-width: 200px;
  cursor: pointer;
}
.sku-bulk-select:focus {
  outline: none;
  border-color: var(--brand);
}
.sku-bulk-btn {
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-size: 12px;
  font-weight: 700;
  background: var(--surface);
  color: var(--text-2);
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}
.sku-bulk-btn:hover { border-color: var(--text-3); }
.sku-bulk-btn.primary {
  background: var(--brand);
  color: var(--btn-primary-fg);
  border-color: var(--brand);
}
.sku-bulk-btn.primary:hover { background: var(--brand-dk); border-color: var(--brand-dk); }
.sku-bulk-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.sku-bulk-hint {
  margin-left: auto;
  font-size: 11.5px;
  color: var(--text-3);
}
/* 테이블 체크박스 셀 */

.sku-checkbox {
  width: 16px;
  height: 16px;
  cursor: pointer;
  accent-color: var(--brand);
  vertical-align: middle;
}
.sku-table tr.is-checked {
  background: var(--brand-soft) !important;
}
/* 수동 매핑 패널 칩 UI */
.ad-chips-container {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 5px;
  min-height: 24px;
}
.ad-option-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 4px 3px 9px;
  background: var(--brand-soft);
  color: var(--brand);
  border: 1px solid var(--brand-accent);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
}
.ad-option-chip-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: transparent;
  border: none;
  color: var(--brand);
  cursor: pointer;
  font-size: 13px;
  line-height: 1;
  padding: 0;
}
.ad-option-chip-remove:hover {
  background: var(--brand);
  color: var(--btn-primary-fg);
}
.sku-sort-btn {
  padding: 7px 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-size: 12px;
  font-weight: 600;
  background: var(--surface);
  color: var(--text-2);
  cursor: pointer;
  transition: all 0.2s;
}
.sku-sort-btn:hover { border-color: var(--text-3); }
.sku-sort-btn.active {
  background: var(--text);
  color: var(--btn-primary-fg);
  border-color: var(--text);
}

.sku-table-wrap {
  overflow-x: auto;
  margin: 0 -24px;
  padding: 0 24px;
}
.sku-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.sku-table tr.sku-zero-divider td {
  background: var(--surface-2);
  color: var(--text-2);
  font-size: 12px;
  font-weight: 700;
  padding: 11px 16px;
  border-top: 2px solid var(--border);
  letter-spacing: -0.01em;
}
.sku-table tr.is-zero-master {
  opacity: 0.66;
}
.sku-table tr.is-zero-master:hover {
  opacity: 1;
}
.sku-table thead th {
  text-align: left;
  padding: 10px 12px;
  background: var(--surface-2);
  font-weight: 700;
  color: var(--text-2);
  font-size: 11.5px;
  letter-spacing: -0.005em;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  position: sticky;
  top: 0;
}
.sku-table thead th.num { text-align: right; }
.sku-table tbody td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: middle;
}
.sku-table tbody tr {
  transition: background 0.15s;
}
.sku-table tbody tr:hover { background: #fafbff; }
.sku-table tbody td.num {
  text-align: right;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 12.5px;
}
.sku-table-rank {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 22px;
  padding: 0 8px;
  border-radius: 6px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 800;
  background: var(--surface-2);
  color: var(--text-2);
}
.sku-table-rank.top {
  background: var(--success-soft);
  color: #065f46;
}
.sku-table-rank.bottom {
  background: var(--danger-soft);
  color: #9f1239;
}
.sku-product-cell {
  max-width: 280px;
  min-width: 200px;
}
.sku-product-name {
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 12.5px;
  letter-spacing: -0.005em;
}
.sku-product-option {
  font-size: 11px;
  color: var(--text-3);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sku-option-id {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-3);
  font-weight: 600;
}
.sku-margin-cell {
  font-weight: 800;
  font-size: 13px;
}
.sku-margin-cell.profit { color: var(--success); }
.sku-margin-cell.loss { color: var(--danger); }

/* 알림 배지 (저볼륨, 반품이상 등) */
.sku-alert-badge {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 10.5px;
  font-weight: 700;
  margin-left: 4px;
  vertical-align: middle;
  letter-spacing: -0.005em;
}
.sku-alert-badge.lowvol {
  background: var(--warning-soft);
  color: #92400e;
}
.sku-alert-badge.return {
  background: var(--danger-soft);
  color: #9f1239;
}

/* ⭐ v18.2 NEW — 마진율 배지 (시장 표준: DashPanda·장사왕 패턴 + 셀러린의 강점) */
.margin-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  vertical-align: middle;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.margin-badge-danger {
  background: var(--danger-soft);
  color: var(--danger);
}
.margin-badge-warning {
  background: var(--warning-soft);
  color: #92400e;
}
.margin-badge-success {
  background: var(--success-soft);
  color: var(--success);
}
[data-theme="dark"] .margin-badge-warning { color: var(--warning); }


.sku-channel-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
  vertical-align: middle;
  margin-left: 4px;
  border: 1px solid transparent;
}
.sku-channel-badge.ch-rocket-growth {
  background: var(--brand-soft);
  color: var(--brand);
  border-color: rgba(79, 70, 229, 0.15);
}
.sku-channel-badge.ch-rocket-shipping {
  background: rgba(129, 140, 248, 0.12);
  color: #6366f1;
  border-color: rgba(129, 140, 248, 0.25);
}
.sku-channel-badge.ch-marketplace {
  background: var(--success-soft);
  color: var(--success);
  border-color: rgba(16, 185, 129, 0.18);
}
[data-theme="dark"] .sku-channel-badge.ch-rocket-shipping {
  background: rgba(129, 140, 248, 0.2);
  color: var(--brand-accent);
  border-color: rgba(129, 140, 248, 0.3);
}
[data-theme="dark"] .sku-channel-badge.ch-marketplace {
  color: #34d399;
}


.kpi-channel-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px 0;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  font-size: 12.5px;
  flex-wrap: wrap;
}
.kpi-channel-label {
  font-weight: 700;
  color: var(--text-2);
  letter-spacing: -0.01em;
}
.kpi-channel-chips {
  display: inline-flex;
  gap: 6px;
  flex-wrap: wrap;
}
.kpi-channel-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  background: var(--surface-2);
  color: var(--text-2);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
  letter-spacing: -0.01em;
}
.kpi-channel-chip:hover {
  border-color: var(--hover-border);
  color: var(--text);
}
.kpi-channel-chip.is-active {
  background: var(--brand);
  color: var(--btn-primary-fg);
  border-color: var(--brand);
}

.kpi-channel-scope {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-3);
  letter-spacing: -0.01em;
}
.kpi-channel-toggle.is-filtered .kpi-channel-scope {
  color: var(--brand);
  font-weight: 700;
}

/* ⭐ v24 NEW — 인사이트 채널 필터 (KPI 토글과 시각 일관성) */
.ins-channel-tabs {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 16px 0;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  font-size: 12.5px;
  flex-wrap: wrap;
}
.ins-channel-label {
  font-weight: 700;
  color: var(--text-2);
  letter-spacing: -0.01em;
}
.ins-channel-chips {
  display: inline-flex;
  gap: 6px;
  flex-wrap: wrap;
}
.ins-channel-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  background: var(--surface-2);
  color: var(--text-2);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
  letter-spacing: -0.01em;
}
.ins-channel-chip:hover {
  border-color: var(--hover-border);
  color: var(--text);
}
.ins-channel-chip.is-active {
  background: var(--brand);
  color: var(--btn-primary-fg);
  border-color: var(--brand);
}

.sku-table-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-3);
  font-size: 13px;
}

/* ════════════════════════ 옵션 3계층 드릴다운 (v19 / [9순위]) ════════════════════════ */
.sku-table tbody tr.is-drillable {
  cursor: pointer;
  transition: background-color 0.12s;
}
.sku-table tbody tr.is-drillable:hover {
  background: var(--surface-2);
}
.sku-table tbody tr.is-drilled {
  background: var(--brand-soft);
}
.sku-table tbody tr.is-drilled .sku-product-name::before {
  content: '▼ ';
  color: var(--brand);
  font-size: 10px;
  font-weight: 800;
}
.sku-table tbody tr.is-drillable:not(.is-drilled) .sku-product-name::before {
  content: '▸ ';
  color: var(--text-3);
  font-size: 10px;
  font-weight: 700;
  transition: color 0.12s;
}
.sku-table tbody tr.is-drillable:not(.is-drilled):hover .sku-product-name::before {
  color: var(--brand);
}

/* Expand row */
.sku-drill-row > td {
  padding: 0;
  background: var(--brand-soft);
  border-bottom: 1px solid var(--border);
}
[data-theme="dark"] .sku-drill-row > td { background: rgba(129, 140, 248, 0.08); }

.sku-drill-content {
  padding: 18px 22px;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
  align-items: start;
}
@media (max-width: 900px) {
  .sku-drill-content { grid-template-columns: 1fr; }
}
.sku-drill-block {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
}
.sku-drill-block-title {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--text-2);
  text-transform: uppercase;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.sku-drill-block-title .pill {
  font-size: 9.5px;
  background: var(--brand);
  color: white;
  padding: 2px 6px;
  border-radius: 999px;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 700;
}
[data-theme="dark"] .sku-drill-block-title .pill { color: var(--bg); }

/* CFS 5종 분해 */
.sku-drill-cost-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.sku-drill-cost-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 6px 10px;
  background: var(--surface-2);
  border-radius: 8px;
  font-size: 11.5px;
}
.sku-drill-cost-row .name { color: var(--text-2); font-weight: 600; }
.sku-drill-cost-row .val  {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  color: var(--text);
  font-size: 11.5px;
}

/* 마스터 통합 정보 */

.sku-drill-master-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}
.sku-drill-master-stat {
  background: var(--surface-2);
  border-radius: 8px;
  padding: 8px 12px;
}
.sku-drill-master-stat .lbl {
  font-size: 10.5px;
  color: var(--text-3);
  font-weight: 600;
  display: block;
  margin-bottom: 2px;
}
.sku-drill-master-stat .num {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  font-weight: 800;
  color: var(--text);
}
.sku-drill-options-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 6px;
  max-height: 120px;
  overflow-y: auto;
}
.sku-drill-option-id {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-2);
  padding: 4px 8px;
  background: var(--surface-2);
  border-radius: 6px;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.sku-drill-option-id .me {
  color: var(--brand);
  font-weight: 800;
}
.sku-drill-option-id .rev {
  color: var(--text-3);
  font-size: 10px;
}
.sku-drill-note {
  font-size: 11px;
  color: var(--text-3);
  margin-top: 8px;
  padding: 8px 10px;
  background: var(--surface-2);
  border-radius: 6px;
  line-height: 1.5;
}
.sku-drill-note strong { color: var(--text-2); font-weight: 700; }

/* 빈 상태 → 인사이트 카드 */
.sku-insight-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 18px 20px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-xs);
  animation: fadeUp 0.55s cubic-bezier(.2,.8,.2,1) 0.4s backwards;
}
.sku-insight-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}
.sku-insight-item {
  background: var(--surface-2);
  border-radius: var(--r);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.sku-insight-item.warning {
  background: var(--warning-soft);
}
.sku-insight-item.danger {
  background: var(--danger-soft);
}
.sku-insight-item.success {
  background: var(--success-soft);
}
.sku-insight-item-label {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.sku-insight-item.warning .sku-insight-item-label { color: #92400e; }
.sku-insight-item.danger .sku-insight-item-label { color: #9f1239; }
.sku-insight-item.success .sku-insight-item-label { color: #065f46; }
.sku-insight-item-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}
.sku-insight-item-desc {
  font-size: 11.5px;
  color: var(--text-2);
  font-weight: 500;
  line-height: 1.4;
}
.sku-insight-card-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.015em;
}

/* 반응형 (작은 화면에서 KPI 단계별 축소) */
@media (max-width: 1300px) {
  .sku-kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } 
}
@media (max-width: 1100px) {
  .sku-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } 
  .sku-insight-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .sku-kpi-grid { grid-template-columns: minmax(0, 1fr); } 
  .sku-insight-list { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════════════════════
   💰 10단계 NEW — 상품 원가 관리 페이지 (#/cost)
   ════════════════════════════════════════════════════════════ */
.cost-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 24px;
  flex-wrap: wrap;
}
.cost-header h1 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: 6px;
}
.cost-header p {
  font-size: 13.5px;
  color: var(--text-2);
  font-weight: 500;
}

.cost-force-sync-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-2);
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
  white-space: nowrap;
}
.cost-force-sync-btn:hover {
  border-color: var(--brand-accent);
  color: var(--brand);
  background: var(--brand-soft);
}
.cost-force-sync-btn:active { transform: scale(0.98); }
.cost-force-sync-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.cost-force-sync-btn.spinning .icon {
  animation: spin 0.8s linear infinite;
  display: inline-block;
}
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
.cost-force-sync-hint {
  font-size: 11px;
  color: var(--text-3);
  font-weight: 500;
  margin-top: 5px;
  text-align: right;
}

/* KPI 그리드 (4개) */
.cost-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 20px;
  animation: fadeUp 0.55s cubic-bezier(.2,.8,.2,1) 0.1s backwards;
}
.cost-kpi {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 20px 22px;
  position: relative;
  overflow: hidden;
  transition: all .2s ease;
}
.cost-kpi:hover {
  border-color: var(--hover-border);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}
.cost-kpi-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 12px;
  letter-spacing: -0.005em;
}
.cost-kpi-value {
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: -0.035em;
  line-height: 1.1;
}
.cost-kpi-value.confirmed { color: var(--success); }
.cost-kpi-value.estimated { color: var(--warning); }
.cost-kpi-value.required  { color: var(--danger); }
.cost-kpi-value .unit {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-3);
  margin-left: 2px;
}
.cost-kpi-foot {
  margin-top: 8px;
  font-size: 11.5px;
  color: var(--text-3);
  font-weight: 500;
}

/* 액션 카드 영역 (양식 다운로드 + 일괄 % 적용 등) */
.cost-action-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
  animation: fadeUp 0.55s cubic-bezier(.2,.8,.2,1) 0.15s backwards;
}
.cost-action-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: all .2s ease;
}
.cost-action-card:hover {
  border-color: var(--hover-border);
  box-shadow: var(--shadow-sm);
}
.cost-action-card.featured {
  background: linear-gradient(135deg, var(--brand-soft) 0%, transparent 80%);
  border-color: var(--tip-border);
}
.cost-action-head {
  display: flex;
  align-items: center;
  gap: 10px;
}
.cost-action-icon {
  width: 32px; height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  background: var(--brand-soft);
  color: var(--brand);
  flex-shrink: 0;
}
.cost-action-icon.warn  { background: var(--warning-soft); color: var(--warning); }
.cost-action-icon.info  { background: var(--info-soft); color: var(--info); }
.cost-action-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}
.cost-action-desc {
  font-size: 12.5px;
  color: var(--text-2);
  line-height: 1.55;
  flex: 1;
}
.cost-action-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.cost-action-row .btn { flex-shrink: 0; }
.cost-action-input {
  flex: 1;
  min-width: 90px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  font-family: 'JetBrains Mono', monospace;
  transition: all .15s ease;
}
.cost-action-input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
}
.cost-action-hint {
  font-size: 11.5px;
  color: var(--text-3);
  font-weight: 500;
}

/* 원가 테이블 카드 */
.cost-table-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 22px 24px;
  animation: fadeUp 0.55s cubic-bezier(.2,.8,.2,1) 0.2s backwards;
}
.cost-table-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  gap: 16px;
  flex-wrap: wrap;
}
.cost-table-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.015em;
  display: flex;
  align-items: center;
  gap: 8px;
}
.cost-table-title-count {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  background: var(--surface-2);
  padding: 3px 9px;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
}
.cost-table-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.cost-search {
  height: 34px;
  padding: 0 12px 0 32px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23a1a1aa' stroke-width='1.6'><circle cx='7' cy='7' r='5'/><line x1='10.5' y1='10.5' x2='14' y2='14'/></svg>") no-repeat 10px center;
  background-size: 14px;
  color: var(--text);
  font-size: 12.5px;
  font-weight: 500;
  min-width: 200px;
  transition: all .15s ease;
}
.cost-search:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
}
.cost-filter-btn {
  height: 34px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text-2);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s ease;
  white-space: nowrap;
}
.cost-filter-btn:hover {
  border-color: var(--hover-border);
  color: var(--text);
}
.cost-filter-btn.active {
  background: var(--text);
  color: var(--btn-primary-fg);
  border-color: var(--text);
}

.cost-table-wrap {
  overflow-x: auto;
  margin: 0 -24px;
  padding: 0 24px;
}
.cost-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 900px;
}
.cost-table thead th {
  text-align: left;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-2);
  letter-spacing: -0.005em;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  background: var(--surface);
  position: sticky;
  top: 0;
  z-index: 1;
}
.cost-table thead th.right { text-align: right; }
.cost-table tbody td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--border-soft);
  vertical-align: middle;
}
.cost-table tbody tr {
  transition: background 0.15s;
}
.cost-table tbody tr:hover { background: rgba(79, 70, 229, .04); }
[data-theme="dark"] .cost-table tbody tr:hover { background: rgba(129, 140, 248, .07); }

.cost-table .col-name {
  max-width: 280px;
}
.cost-table .col-name .pname {
  font-weight: 600;
  color: var(--text);
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 280px;
}
.cost-table .col-name .oname {
  font-size: 11.5px;
  color: var(--text-3);
  font-weight: 500;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 280px;
}
.cost-table .col-id {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  color: var(--text-3);
  font-weight: 600;
}

/* 10.5단계 — 옵션ID 통합 안내 배너 */
.cost-merge-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  margin-bottom: 16px;
  background: linear-gradient(90deg, var(--brand-soft) 0%, var(--surface) 60%);
  border: 1px solid var(--tip-border);
  border-radius: var(--r);
  animation: fadeUp 0.55s cubic-bezier(.2,.8,.2,1) 0.05s backwards;
}
.cost-merge-icon { font-size: 16px; }
.cost-merge-text {
  flex: 1;
  font-size: 13px;
  color: var(--text-2);
}
.cost-merge-text strong {
  color: var(--brand);
  font-weight: 800;
  font-family: 'JetBrains Mono', monospace;
  margin-right: 4px;
}
.cost-merge-tag {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-3);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
}


.cost-shipping-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 22px 24px;
  margin-bottom: 18px;
  box-shadow: var(--shadow-sm);
  animation: fadeUp 0.55s cubic-bezier(.2,.8,.2,1) 0.1s backwards;
}
.cost-shipping-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 18px;
}
.cost-shipping-icon { font-size: 28px; line-height: 1; }
.cost-shipping-title-block { flex: 1; }
.cost-shipping-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}
.cost-shipping-subtitle {
  font-size: 13px;
  color: var(--text-2);
  margin-top: 4px;
  line-height: 1.5;
}
.cost-shipping-tag {
  font-size: 11px;
  font-weight: 700;
  color: var(--brand);
  background: var(--brand-soft);
  border: 1px solid var(--tip-border);
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
  font-family: 'JetBrains Mono', monospace;
}
.cost-shipping-body {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 18px;
  align-items: end;
  padding: 14px 16px;
  background: var(--surface-2);
  border-radius: var(--r);
}
.cost-shipping-body .lbl {
  display: block;
  font-size: 12px;
  color: var(--text-2);
  margin-bottom: 6px;
  font-weight: 500;
}
.cost-shipping-stat .val {
  font-family: 'JetBrains Mono', monospace;
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
}
.cost-shipping-stat .val strong {
  color: var(--brand);
  font-size: 22px;
  margin-right: 2px;
}
.cost-shipping-input-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.cost-shipping-input {
  font-family: 'JetBrains Mono', monospace;
  font-size: 16px;
  font-weight: 700;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  width: 110px;
  background: var(--surface);
  color: var(--text);
  transition: all .2s;
}
.cost-shipping-input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}
.cost-shipping-input-row .unit {
  font-size: 13px;
  color: var(--text-2);
  font-weight: 500;
}
.cost-shipping-result .val {
  font-family: 'JetBrains Mono', monospace;
  font-size: 17px;
  font-weight: 800;
  color: var(--brand);
}
.cost-shipping-result .val strong {
  font-size: 22px;
  margin-right: 0;
}
.cost-shipping-hint {
  margin-top: 14px;
  padding: 11px 14px;
  background: var(--brand-soft);
  border-radius: var(--r-sm);
  font-size: 12px;
  line-height: 1.65;
  color: var(--text-2);
}
.cost-shipping-hint code {
  background: var(--surface);
  padding: 1px 6px;
  border-radius: 4px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text);
}
@media (max-width: 768px) {
  .cost-shipping-body { grid-template-columns: 1fr; gap: 14px; }
  .cost-shipping-head { flex-wrap: wrap; }
}

/* 10.5단계 — 옵션ID 통합 배지 (마스터 단위) */
.col-id-text {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  color: var(--text-3);
  font-weight: 600;
}
.opt-count-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: var(--brand-soft);
  color: var(--brand);
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all .15s ease;
  letter-spacing: -0.005em;
}
.opt-count-badge:hover {
  border-color: var(--brand);
  transform: translateY(-1px);
}
.opt-count-badge .opt-count-num {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 800;
}
.opt-count-badge .opt-count-arrow {
  font-size: 9px;
  transition: transform .15s ease;
}
.opt-count-badge.expanded .opt-count-arrow {
  transform: rotate(180deg);
}
.opt-id-list {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-width: 240px;
}
.opt-id-pill {
  display: inline-block;
  padding: 2px 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-2);
}

/* 원가 입력 (인라인 편집) */
.cost-input {
  width: 110px;
  height: 30px;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: var(--text);
  font-size: 12.5px;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  text-align: right;
  transition: all .15s ease;
}
.cost-input:hover {
  background: var(--surface-2);
  border-color: var(--border);
}
.cost-input:focus {
  outline: none;
  background: var(--surface);
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
}
.cost-input.is-empty {
  color: var(--text-3);
  font-weight: 500;
}

/* 원가상태 배지 + 셀렉트 */
.status-cell {
  position: relative;
}
.status-select {
  height: 28px;
  padding: 0 26px 0 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-color: transparent;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none' stroke='currentColor' stroke-width='2'><polyline points='3 5 6 8 9 5'/></svg>");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 10px;
  transition: all .15s ease;
  letter-spacing: -0.005em;
}
.status-select.confirmed {
  background-color: var(--success-soft);
  color: var(--success);
}
.status-select.estimated {
  background-color: var(--warning-soft);
  color: var(--warning);
}
.status-select.required {
  background-color: var(--danger-soft);
  color: var(--danger);
}
.status-select:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
}
.status-select option {
  background: var(--surface);
  color: var(--text);
  font-weight: 600;
}

.note-input {
  width: 100%;
  min-width: 140px;
  max-width: 220px;
  height: 28px;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: var(--text-2);
  font-size: 12px;
  font-weight: 500;
  transition: all .15s ease;
}
.note-input:hover {
  background: var(--surface-2);
  border-color: var(--border);
}
.note-input:focus {
  outline: none;
  background: var(--surface);
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
  color: var(--text);
}
.note-input::placeholder { color: var(--text-3); }

/* 원가관리 빈 상태 (정산데이터 없을 때) */
.cost-empty-state {
  text-align: center;
  padding: 80px 24px;
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--r-lg);
}
.cost-empty-state .icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}
.cost-empty-state .title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.cost-empty-state .desc {
  font-size: 13px;
  color: var(--text-2);
  margin-bottom: 24px;
  line-height: 1.6;
}

/* 토스트 (10단계 전용 — 짧은 알림) */
.cost-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  background: var(--text);
  color: var(--btn-primary-fg);
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  z-index: 9999;
  opacity: 0;
  transition: all .3s cubic-bezier(.2,.8,.2,1);
  pointer-events: none;
  max-width: 90vw;
}
.cost-toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}
.cost-toast.success { background: var(--success); color: #fff; }
.cost-toast.danger  { background: var(--danger);  color: #fff; }
.cost-toast.warning { background: var(--warning); color: #1a1a1f; }

@media (max-width: 1100px) {
  .cost-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cost-action-grid { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .cost-kpi-grid { grid-template-columns: 1fr; }
  .cost-search { min-width: 0; flex: 1; }
}

/* ════════════════════════════════════════════════════════════
   11단계 NEW — 인사이트 알림 페이지
   마스터 단위 + 매입원가 반영 + 8종 인사이트
   ════════════════════════════════════════════════════════════ */

/* 페이지 hero */
.ins-hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.ins-hero-left h1 {
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 8px 0;
  letter-spacing: -0.02em;
}
.ins-hero-left p {
  font-size: 13.5px;
  color: var(--text-2);
  margin: 0;
  line-height: 1.6;
  max-width: 720px;
}
.ins-hero-right {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.ins-trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  font-family: 'Pretendard Variable', sans-serif;
  border: 1px solid;
}
.ins-trust-badge.trusted {
  background: var(--success-soft);
  color: var(--success);
  border-color: var(--success);
}
.ins-trust-badge.partial {
  background: var(--warning-soft);
  color: var(--warning);
  border-color: var(--warning);
}
.ins-trust-badge .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
}

/* KPI 요약 4개 */
.ins-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}
.ins-summary {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: all .2s cubic-bezier(.2,.8,.2,1);
}
.ins-summary:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
  border-color: var(--hover-border);
}
.ins-summary-label {
  font-size: 12px;
  color: var(--text-2);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}
.ins-summary-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 26px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.ins-summary-value.danger { color: var(--danger); }
.ins-summary-value.warning { color: var(--warning); }
.ins-summary-value.success { color: var(--success); }
.ins-summary-sub {
  font-size: 11.5px;
  color: var(--text-3);
  font-weight: 500;
}


/* ════════════════════════════════════════════════════════════
   🆕 P1 핫픽스 (2026-05-17) — 다크모드 인디고 박스 가독성 보강
   외부 셀러 + 직원 보고 — 다크 인디고 배경 위 인디고 텍스트 콘트라스트 정비
   대상 5곳: ins-secret-banner / secret-note / cost-principles (3 sub-area)
   ════════════════════════════════════════════════════════════ */


[data-theme="dark"] .secret-note {
  background: rgba(129,140,248,0.14);
  color: var(--text);
}
[data-theme="dark"] .secret-note strong {
  color: var(--brand-accent);
}


/* 카테고리 탭 */
.ins-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 18px;
  flex-wrap: wrap;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 6px;
}
.ins-tab {
  padding: 8px 14px;
  border-radius: var(--r-sm);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
  cursor: pointer;
  transition: all .15s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: none;
  font-family: 'Pretendard Variable', sans-serif;
}
.ins-tab:hover { background: var(--surface-2); color: var(--text); }
.ins-tab.active {
  background: var(--text);
  color: var(--btn-primary-fg);
}
.ins-tab .count {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
  background: var(--surface-2);
  color: var(--text-2);
}
.ins-tab.active .count {
  background: rgba(255,255,255,.18);
  color: var(--btn-primary-fg);
}
[data-theme="dark"] .ins-tab.active .count { background: rgba(0,0,0,.18); }

/* 인사이트 그룹 카드 */
.ins-group {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  margin-bottom: 14px;
  overflow: hidden;
  transition: all .2s cubic-bezier(.2,.8,.2,1);
}
.ins-group:hover {
  box-shadow: var(--shadow-sm);
  border-color: var(--hover-border);
}
.ins-group-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 22px;
  cursor: pointer;
  user-select: none;
}
.ins-group-head:hover { background: var(--surface-2); }


.ins-group-body { flex: 1; min-width: 0; }
.ins-group-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.ins-group-count {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  background: var(--surface-2);
  color: var(--text-2);
}
.ins-group-desc {
  font-size: 12.5px;
  color: var(--text-2);
  line-height: 1.5;
}
.ins-group-toggle {
  width: 28px; height: 28px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  transition: transform .2s ease;
  flex-shrink: 0;
  font-size: 14px;
}
.ins-group.open .ins-group-toggle { transform: rotate(180deg); }

/* 인사이트 그룹 상세 (펼침) */
.ins-group-detail {
  display: none;
  border-top: 1px solid var(--border-soft);
}
.ins-group.open .ins-group-detail { display: block; }
.ins-group-action-tip {
  padding: 14px 22px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border-soft);
  font-size: 12.5px;
  color: var(--text-2);
  line-height: 1.6;
}
.ins-group-action-tip strong { color: var(--text); font-weight: 700; }
.ins-group-action-tip .lab {
  display: inline-block;
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 5px;
  background: var(--brand);
  color: var(--btn-primary-fg);
  margin-right: 8px;
  letter-spacing: 0.04em;
}

/* 인사이트 상세 항목 (마스터 리스트) */
.ins-item-list {
  max-height: 480px;
  overflow-y: auto;
}
.ins-item {
  display: grid;
  grid-template-columns: 1fr auto auto auto;
  gap: 16px;
  padding: 12px 22px;
  border-bottom: 1px solid var(--border-soft);
  align-items: center;
  transition: background .15s ease;
}
.ins-item:last-child { border-bottom: none; }
.ins-item:hover { background: var(--surface-2); }
.ins-item-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ins-item-name .opt {
  display: block;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-3);
  margin-top: 2px;
}
.ins-item-name .opt-merged {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-left: 6px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 8px;
  background: var(--brand-soft);
  color: var(--brand);
  vertical-align: middle;
}
.ins-item-metric {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  font-weight: 700;
  text-align: right;
  white-space: nowrap;
}
.ins-item-metric.danger  { color: var(--danger);  }
.ins-item-metric.warning { color: var(--warning); }
.ins-item-metric.success { color: var(--success); }
.ins-item-metric .lbl {
  display: block;
  font-family: 'Pretendard Variable', sans-serif;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-3);
  margin-top: 2px;
  text-align: right;
}
.ins-item-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  white-space: nowrap;
}
.ins-item-status.confirmed { background: var(--success-soft); color: var(--success); }
.ins-item-status.estimated { background: var(--warning-soft); color: var(--warning); }
.ins-item-status.required  { background: var(--danger-soft);  color: var(--danger);  }

/* 빈 상태 */
.ins-empty-group {
  padding: 24px 22px;
  text-align: center;
  color: var(--text-3);
  font-size: 12.5px;
}

/* 기준 데이터 없을 때 */
.ins-no-data {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 60px 24px;
  text-align: center;
}
.ins-no-data .ico {
  font-size: 40px;
  margin-bottom: 14px;
  opacity: 0.6;
}
.ins-no-data .title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.ins-no-data .desc {
  font-size: 13px;
  color: var(--text-2);
  margin-bottom: 20px;
  line-height: 1.6;
}
.ins-no-data .btn-go {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: var(--text);
  color: var(--btn-primary-fg);
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: all .2s ease;
}
.ins-no-data .btn-go:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* 페이지 진입 애니 */
.page[data-page="insight"].active .ins-summary,
.page[data-page="insight"].active .ins-tabs,
.page[data-page="insight"].active .ins-group {
  animation: fadeUp .5s cubic-bezier(.2,.8,.2,1) backwards;
}

.page[data-page="insight"].active .ins-summary:nth-child(1) { animation-delay: .08s; }
.page[data-page="insight"].active .ins-summary:nth-child(2) { animation-delay: .11s; }
.page[data-page="insight"].active .ins-summary:nth-child(3) { animation-delay: .14s; }
.page[data-page="insight"].active .ins-summary:nth-child(4) { animation-delay: .17s; }
.page[data-page="insight"].active .ins-tabs { animation-delay: .2s; }
.page[data-page="insight"].active .ins-group:nth-child(1) { animation-delay: .23s; }
.page[data-page="insight"].active .ins-group:nth-child(2) { animation-delay: .26s; }
.page[data-page="insight"].active .ins-group:nth-child(3) { animation-delay: .29s; }
.page[data-page="insight"].active .ins-group:nth-child(4) { animation-delay: .32s; }

/* 반응형 */
@media (max-width: 1100px) {
  .ins-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ins-item { grid-template-columns: 1fr auto; }
  .ins-item-status { display: none; }
  .ins-item-metric:nth-child(2) { display: none; }
}
@media (max-width: 700px) {
  .ins-summary-grid { grid-template-columns: 1fr; }
  .ins-hero { flex-direction: column; align-items: flex-start; }
}

/* ════════════════════════════════════════════════════════════
   🆕 브랜드 배지, 피드백 버튼, 워터마크, 푸터
   친근 한글 톤 + 인디고 컬러 (셀러린 메인 브랜드와 일관)
   ════════════════════════════════════════════════════════════ */

/* ── 사이드바 브랜드 옆 안내 배지 ── */
.brand-beta-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 6px;
  padding: 2px 7px;
  background: var(--beta-color);
  color: var(--beta-color-fg);
  border-radius: 999px;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .02em;
  font-family: 'Pretendard Variable', sans-serif;
  vertical-align: middle;
  position: relative;
  box-shadow: 0 0 0 0 var(--beta-pulse);
  animation: betaPulse 2.4s cubic-bezier(.4, 0, .6, 1) infinite;
}
.brand-beta-tag::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--beta-color-fg);
  display: inline-block;
}
@keyframes betaPulse {
  0%, 100% { box-shadow: 0 0 0 0 var(--beta-pulse); }
  50%      { box-shadow: 0 0 0 6px transparent; }
}

/* brand-sub를 안내문으로 활용 */


/* ── 토프바 피드백 버튼 ── */
.btn-beta-feedback {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--beta-color);
  color: var(--beta-color-fg);
  border: 1px solid var(--beta-color);
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -.01em;
  font-family: inherit;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, background .2s;
  text-decoration: none;
  position: relative;
}
.btn-beta-feedback:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px var(--beta-pulse);
  background: var(--brand-dk);
}
.btn-beta-feedback:active {
  transform: translateY(0);
}
.btn-beta-feedback .ico {
  font-size: 14px;
}
.btn-beta-feedback .lbl {
  font-family: 'Pretendard Variable', sans-serif;
}

/* ── 우하단 떠있는 워터마크 (절제된 톤) ── */
.beta-floating-watermark {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  background: var(--surface);
  color: var(--beta-color);
  border: 1px solid var(--beta-border);
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: -.01em;
  box-shadow: var(--shadow-md);
  cursor: default;
  user-select: none;
  pointer-events: none;
  font-family: 'Pretendard Variable', sans-serif;
  opacity: .85;
  transition: opacity .2s, transform .2s;
}
.beta-floating-watermark::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--beta-color);
  box-shadow: 0 0 0 0 var(--beta-pulse);
  animation: betaDotPulse 2s ease-in-out infinite;
}
@keyframes betaDotPulse {
  0%, 100% { box-shadow: 0 0 0 0 var(--beta-pulse); opacity: 1; }
  50%      { box-shadow: 0 0 0 4px transparent; opacity: .7; }
}

/* ── 본문 푸터 (스크롤 끝에서 보임) ── */
.beta-footer {
  margin-top: 48px;
  padding: 28px 32px 24px;
  border-top: 1px solid var(--border);
  background: var(--beta-soft);
  border-radius: var(--r);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-family: 'Pretendard Variable', sans-serif;
}
.beta-footer-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  min-width: 280px;
}
.beta-footer-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--beta-color);
  color: var(--beta-color-fg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
  box-shadow: 0 2px 8px var(--beta-pulse);
}
.beta-footer-text { line-height: 1.5; }
.beta-footer-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 2px;
  letter-spacing: -.01em;
}
.beta-footer-title strong {
  color: var(--beta-color);
  font-weight: 800;
}
.beta-footer-desc {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-2);
  letter-spacing: -.01em;
}
.beta-footer-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: var(--beta-color);
  color: var(--beta-color-fg);
  border-radius: var(--r-sm);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: transform .15s, box-shadow .15s;
  letter-spacing: -.01em;
  white-space: nowrap;
}
.beta-footer-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px var(--beta-pulse);
}
.beta-footer-meta {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-3);
  font-family: 'JetBrains Mono', monospace;
}

/* 반응형 — 좁은 화면 */
@media (max-width: 700px) {
  .beta-floating-watermark { right: 12px; bottom: 12px; padding: 6px 11px; font-size: 10.5px; }
  .beta-footer { flex-direction: column; align-items: flex-start; padding: 22px; }
  .beta-footer-cta { width: 100%; justify-content: center; }
  .btn-beta-feedback .lbl { display: none; }  /* 좁은 화면에서 텍스트 생략 */
  .btn-beta-feedback { padding: 8px 10px; }
}
@media (max-width: 1200px) {
  .btn-beta-feedback .lbl-full { display: none; }  /* 좁은 화면에선 짧은 라벨 */
}

/* ── 준비 중 단계 빈 상태 — 기존 dash-empty와 자연스럽게 어우러지게 ── */
.dash-empty.is-beta-pending {
  position: relative;
}
.dash-empty.is-beta-pending::after {
  /* ⭐ v164 (P2-2 금칙어 정비) — 준비 중 배지로 교체 */
  content: '🚧 준비 중' / '준비 중';
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 3px 8px;
  background: var(--beta-soft);
  color: var(--beta-color);
  border: 1px solid var(--beta-border);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .01em;
}

/* ════════════════════════════════════════════════════════════
   🆕 데모 모드 — 환영 모달 + 데모 배지 + 인사이트 카드 빈 상태
   §15-4 셀러린의 강점: 셀러가 빈 화면 대신 데모로 체험
   ════════════════════════════════════════════════════════════ */

/* ── 환영 모달 (첫 진입 시) ── */
.welcome-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 15, .55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: welcomeFadeIn .3s ease;
}
.welcome-overlay.is-open { display: flex; }
@keyframes welcomeFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
.welcome-modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  max-width: 540px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  animation: welcomeSlideUp .4s cubic-bezier(.2,.8,.2,1);
}
@keyframes welcomeSlideUp {
  from { opacity: 0; transform: translateY(24px) scale(.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.welcome-header {
  padding: 28px 32px 18px;
  background: linear-gradient(135deg, var(--brand-soft) 0%, transparent 100%);
  border-bottom: 1px solid var(--border-soft);
  position: relative;
  overflow: hidden;
}
.welcome-header::before {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 180px;
  height: 180px;
  background: radial-gradient(circle, var(--brand-soft) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  opacity: .5;
}
.welcome-mark {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 11px;
  background: var(--surface);
  border: 1px solid var(--brand-soft);
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--brand);
  margin-bottom: 14px;
  position: relative;
}
.welcome-title {
  font-family: 'Pretendard Variable', sans-serif;
  font-size: 24px;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 8px 0;
  letter-spacing: -.02em;
  position: relative;
}
.welcome-subtitle {
  font-size: 14px;
  color: var(--text-2);
  margin: 0;
  line-height: 1.55;
  position: relative;
}
.welcome-body {
  padding: 22px 32px 28px;
}
.welcome-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.welcome-option {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: var(--surface-2);
  border: 1.5px solid var(--border);
  border-radius: var(--r);
  cursor: pointer;
  transition: all .2s cubic-bezier(.2,.8,.2,1);
  text-align: left;
  width: 100%;
  font-family: inherit;
}
.welcome-option:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}
.welcome-option.is-primary {
  border-color: var(--brand);
  background: linear-gradient(135deg, var(--brand-soft) 0%, var(--surface) 100%);
}

.welcome-option-text {
  flex: 1;
  min-width: 0;
}
.welcome-option-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
  letter-spacing: -.01em;
}
.welcome-option-desc {
  font-size: 12.5px;
  color: var(--text-2);
  line-height: 1.45;
}
.welcome-option-arrow {
  flex-shrink: 0;
  color: var(--text-3);
  font-size: 18px;
  transition: transform .2s, color .2s;
}
.welcome-option:hover .welcome-option-arrow {
  color: var(--brand);
  transform: translateX(3px);
}
.welcome-footer {
  padding: 14px 32px 22px;
  border-top: 1px solid var(--border-soft);
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 11.5px;
  color: var(--text-3);
}
/* 🆕 v21 [A] — 환영 모달 footer 무료 도구 링크 */
.welcome-footer-tools {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.welcome-footer-link {
  color: var(--brand);
  text-decoration: none;
  font-weight: 600;
  font-size: 11.5px;
}
.welcome-footer-link:hover { text-decoration: underline; }

/* ── 데모 모드 활성 배지 (사이드바 + 토프바) ── */
.demo-mode-badge {
  display: none;  /* 기본 숨김, JS에서 표시 */
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  border: 1px solid #fcd34d;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  color: #92400e;
  letter-spacing: -.005em;
  white-space: nowrap;
}
[data-theme="dark"] .demo-mode-badge {
  background: linear-gradient(135deg, #422006 0%, #2d1604 100%);
  border-color: #78350f;
  color: #fcd34d;
}
.demo-mode-badge.is-active { display: inline-flex; }
.demo-mode-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  background: currentColor;
  border-radius: 50%;
  flex-shrink: 0;
  animation: demoPulse 2s ease-in-out infinite;
}
@keyframes demoPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .5; transform: scale(.85); }
}

/* 사이드바 데모 배지 (브랜드 영역 옆) */
.brand-text .demo-mode-badge {
  margin-top: 6px;
  font-size: 10px;
  padding: 3px 8px;
}

/* 토프바 "데모 종료" 버튼 */
.btn-demo-exit {
  display: none;  /* 기본 숨김 */
  align-items: center;
  gap: 6px;
  padding: 7px 13px;
  background: var(--surface);
  border: 1.5px solid #fcd34d;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: #92400e;
  cursor: pointer;
  transition: all .2s cubic-bezier(.2,.8,.2,1);
  font-family: inherit;
}
[data-theme="dark"] .btn-demo-exit {
  border-color: #78350f;
  color: #fcd34d;
}
.btn-demo-exit:hover {
  background: #fef3c7;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}
[data-theme="dark"] .btn-demo-exit:hover {
  background: #422006;
}
.btn-demo-exit.is-active { display: inline-flex; }


/* 반투명 말풍선 — 본문 중앙 상단 고정 */
.demo-tour-bubble {
  position: fixed;
  top: 88px;                 /* 토프바(64px) 아래 */
  left: calc(50% + 122px);   /* 사이드바(244px) 보정한 본문 중앙 */
  transform: translateX(-50%) translateY(-8px);
  width: min(720px, calc(100vw - 200px));
  z-index: 9200;
  background: color-mix(in srgb, var(--surface) 50%, transparent);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border: 1.5px solid var(--brand);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  padding: 36px 40px 28px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .28s cubic-bezier(.2,.8,.2,1), transform .28s cubic-bezier(.2,.8,.2,1);
}
.demo-tour-bubble.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
/* 말풍선 꼬리 (위쪽 화살표) */
.demo-tour-bubble::before {
  content: "";
  position: absolute;
  top: -9px;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 16px;
  height: 16px;
  background: color-mix(in srgb, var(--surface) 50%, transparent);
  border-left: 1.5px solid var(--brand);
  border-top: 1.5px solid var(--brand);
  border-radius: 3px 0 0 0;
}
/* 🆕 v91 — 데모 화면 게이팅 안내 (투어 말풍선과 동일 위치·스타일) */
.demo-gate-notice {
  position: fixed;
  top: 88px;                 /* 투어 말풍선과 동일 */
  left: calc(50% + 122px);   /* 투어 말풍선과 동일 */
  transform: translateX(-50%) translateY(-8px);
  width: min(560px, calc(100vw - 200px));
  z-index: 9300;             /* 투어 말풍선(9200) 위 */
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border: 2px solid var(--warning);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg), 0 0 0 4px color-mix(in srgb, var(--warning) 18%, transparent);
  padding: 16px 22px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .28s cubic-bezier(.2,.8,.2,1), transform .28s cubic-bezier(.2,.8,.2,1);
}
.demo-gate-notice.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.demo-gate-notice::before {
  content: "";
  position: absolute;
  top: -9px;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 16px;
  height: 16px;
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  border-left: 2px solid var(--warning);
  border-top: 2px solid var(--warning);
  border-radius: 3px 0 0 0;
}
.demo-gate-notice-title {
  font-size: 14.5px;
  font-weight: 800;
  color: var(--warning);
  margin-bottom: 4px;
}
.demo-gate-notice-desc {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-2);
  line-height: 1.55;
}
/* 우상단 ✕ (다음으로) */
.demo-tour-x {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 16px;
  line-height: 1;
  color: var(--text-2);
  cursor: pointer;
  transition: all .18s cubic-bezier(.2,.8,.2,1);
  font-family: inherit;
}
.demo-tour-x:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--btn-primary-fg);
  transform: scale(1.08);
}
.demo-tour-step-count {
  font-family: 'JetBrains Mono', monospace;
  font-size: 14px;
  font-weight: 700;
  color: var(--brand);
  letter-spacing: .04em;
  margin-bottom: 8px;
}
.demo-tour-title {
  font-size: 23px;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 12px;
  padding-right: 38px;   /* ✕ 자리 확보 */
}
.demo-tour-desc {
  font-size: 17px;
  font-weight: 500;
  line-height: 1.7;
  color: var(--text-2);
  margin: 0 0 18px;
}
.demo-tour-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}
.demo-tour-hint {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-3);
}
.demo-tour-close-all {
  padding: 9px 18px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-2);
  cursor: pointer;
  transition: all .18s cubic-bezier(.2,.8,.2,1);
  font-family: inherit;
}
.demo-tour-close-all:hover {
  border-color: var(--hover-border);
  color: var(--text);
  background: var(--surface);
}
/* 🆕 v91.2 — 투어 액션 영역 + 다음 버튼 (순차 둘러보기: 상품별 수익 → 문제 진단 → 내 수익 보기) */
.demo-tour-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.demo-tour-next {
  padding: 9px 20px;
  background: var(--brand);
  border: 1px solid var(--brand);
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--btn-primary-fg);
  cursor: pointer;
  transition: all .18s cubic-bezier(.2,.8,.2,1);
  font-family: inherit;
}
.demo-tour-next:hover {
  background: var(--brand-dk);
  border-color: var(--brand-dk);
  transform: translateY(-1px);
}
.demo-tour-next[hidden] { display: none; }

.nav-item.tour-active {
  /* 🐛 fix 2026-07-01 — 다크 사이드바에서 밝은 brand-soft 배경 + 밝은 글자 → 글자 묻힘.
     .active 와 동일한 인디고 반투명 배경 + 흰 글자로 교체해 가독성 확보. */
  background: linear-gradient(90deg, rgba(79,70,229,.38) 0%, rgba(79,70,229,.14) 100%) !important;
  color: #fff !important;
  font-weight: 700;
  box-shadow: inset 3px 0 0 var(--brand);
  animation: tourNavPulse 1.6s ease-in-out infinite;
}
.nav-item.tour-active .nav-badge { filter: none; }
@keyframes tourNavPulse {
  0%, 100% { box-shadow: inset 3px 0 0 var(--brand); }
  50%      { box-shadow: inset 3px 0 0 var(--brand), 0 0 0 3px color-mix(in srgb, var(--brand) 22%, transparent); }
}
/* 모바일 — 사이드바 접힘 시 본문 중앙 정렬 */
@media (max-width: 900px) {
  .demo-tour-bubble {
    left: 50%;
    width: min(640px, calc(100vw - 28px));
  }
  .demo-gate-notice {
    left: 50%;
    width: min(560px, calc(100vw - 28px));
  }
}

/* ── 인사이트 카드 빈 상태 (데이터 없을 때) ── */
.insight-card.insight-card-empty {
  background: var(--surface);
  border: 1px dashed var(--border);
  color: var(--text-2);
}
.insight-card.insight-card-empty .ic {
  background: var(--surface-2);
  color: var(--text-2);
}
.insight-card.insight-card-empty .insight-tag {
  background: var(--surface-2);
  color: var(--text-2);
  border-color: var(--border-soft);
}
.insight-card.insight-card-empty .insight-text {
  color: var(--text-2);
}
.insight-card.insight-card-empty strong { color: var(--text); }

/* 그리팅 strong 강조 (사용자 이름) */
#dashGreeting strong {
  color: var(--brand);
  font-weight: 800;
}

/* 환영 모달 모바일 대응 */
@media (max-width: 640px) {
  .welcome-modal { max-width: 100%; }
  .welcome-header { padding: 22px 24px 14px; }
  .welcome-title { font-size: 20px; }
  .welcome-body { padding: 18px 24px 22px; }
  .welcome-footer { padding: 12px 24px 18px; gap: 6px; }
  .welcome-footer-tools { gap: 8px; }
  
  .welcome-option { padding: 14px 14px; gap: 12px; }
  
}

/* 페이지 헤더 */


/* 카드 그리드 */


/* 5종 파일 카드 */


/* 카드 좌측 (콘텐츠) */


/* 카드 정보 표 */


/* 단계별 안내 */


/* 카드 우측 (스크린샷 자리) */


/* 안내 박스 (페이지 하단) */


/* ═════════════════════════════════════════════════════════════
   가이드 v2 (옵션 A — 4탭 구조)
   탭 1: 정산 4종 통합 / 탭 2: 광고 보고서 / 탭 3·4: placeholder
═════════════════════════════════════════════════════════════ */

/* hl: 형광펜 효과 */
.g2-hl {
  background: linear-gradient(transparent 55%, var(--highlight, #fef08a) 55%);
  padding: 0 2px;
  font-weight: 700;
}
[data-theme="dark"] .g2-hl {
  background: linear-gradient(transparent 55%, rgba(251, 191, 36, 0.45) 55%);
}

/* g2 hero */
.g2-hero {
  background: linear-gradient(135deg, var(--brand-soft) 0%, var(--surface-2) 100%);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 28px 32px;
  margin-bottom: 22px;
  position: relative;
  overflow: hidden;
}
.g2-hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--brand);
  color: var(--btn-primary-fg, #fff);
  font-size: 11.5px;
  font-weight: 800;
  margin-bottom: 10px;
  letter-spacing: 0.3px;
}
.g2-hero h1 {
  font-size: 24px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.4px;
  margin: 0 0 8px 0;
}
.g2-hero p {
  font-size: 13.5px;
  color: var(--text-2);
  line-height: 1.6;
  margin: 0;
}

/* g2 탭 인터페이스 */
.g2-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 18px;
  padding: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 14px;
}
@media (max-width: 720px) {
  .g2-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.g2-tab {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--text-2);
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
  font-family: inherit;
  text-align: left;
  width: 100%;
  position: relative;
}
.g2-tab:hover {
  background: var(--surface);
  color: var(--text);
}
.g2-tab.active {
  background: var(--surface);
  border-color: var(--brand);
  color: var(--text);
  box-shadow: 0 2px 8px rgba(79, 70, 229, 0.12);
}
[data-theme="dark"] .g2-tab.active {
  box-shadow: 0 2px 8px rgba(129, 140, 248, 0.18);
}
.g2-tab-num {
  flex-shrink: 0;
  font-family: "JetBrains Mono", monospace;
  font-size: 14px;
  font-weight: 800;
  color: var(--text-3);
  min-width: 22px;
}
.g2-tab.active .g2-tab-num { color: var(--brand); }
.g2-tab-label {
  flex: 1;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}


/* g2 panel */
.g2-panel { display: none; }
.g2-panel.active { display: block; animation: g2-fade .25s ease-out; }
@keyframes g2-fade {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ─────────────────────────────────────────────
   .gc-* — 카드 단위 디자인 (시안 v2)
───────────────────────────────────────────── */
.gc-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
}
.gc-card:hover {
  border-color: var(--hover-border);
  box-shadow: 0 4px 20px rgba(0,0,0,0.04);
}
[data-theme="dark"] .gc-card:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.gc-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 28px 32px;
  border-bottom: 1px solid var(--border);
}
.gc-num {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-accent, #818cf8) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "JetBrains Mono", monospace;
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.5px;
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}
.gc-title-block { flex: 1; min-width: 0; }
.gc-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 10px;
  letter-spacing: 0.3px;
}


.gc-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.4px;
  margin-bottom: 6px;
}


/* 별도 시스템 경고 배너 (탭 2에서만) */


/* 4종 파일 매핑 박스 (탭 1에서만) */


/* v63 가이드 재작성 — 어떻게/왜 2섹션 구조용 CSS */
.gc-section {
  padding: 22px 32px 26px;
  border-top: 1px solid var(--border);
}
.gc-section:first-of-type { border-top: none; }
/* 🆕 v67 가이드 탭 — 확인 완료 버튼 (각 탭 하단) */
.gc-confirm-wrap {
  display: flex;
  justify-content: flex-end;
  padding: 18px 32px 24px;
  border-top: 1px solid var(--border);
}
.gc-confirm-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  background: var(--brand);
  color: #fff;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: all .15s ease;
  border: none;
  font-family: inherit;
  box-shadow: 0 2px 8px rgba(79, 70, 229, .25);
}
.gc-confirm-btn:hover {
  background: var(--brand-dk);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, .35);
}
.gc-confirm-btn-arrow { font-size: 16px; }
.gc-section-title {
  font-size: 14px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: 0.2px;
  margin-bottom: 14px;
}
.gc-step-list {
  list-style: none;
  counter-reset: gc-step;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.gc-step-list > li {
  position: relative;
  padding: 10px 12px 10px 38px;
  background: var(--surface-2);
  border-radius: 10px;
  font-size: 13.5px;
  color: var(--text-2);
  line-height: 1.55;
  counter-increment: gc-step;
}
.gc-step-list > li::before {
  content: counter(gc-step);
  position: absolute;
  left: 10px;
  top: 10px;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--brand);
  color: #fff;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  font-weight: 800;
  border-radius: 50%;
}
.gc-step-list strong { color: var(--brand-dk); font-weight: 700; }
.gc-tip {
  display: inline-block;
  margin-left: 6px;
  font-size: 12px;
  color: var(--text-3);
  font-weight: 500;
}
.gc-file-list {
  list-style: disc;
  padding-left: 20px;
  margin: 10px 0 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12.5px;
  color: var(--text-2);
}
.gc-file-list code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  font-weight: 700;
  padding: 2px 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
}
.gc-step-list code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  font-weight: 700;
  padding: 2px 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
}
.gc-why-text {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--text-2);
}

/* 메타 정보 */


/* 단계 */
.gc-steps {
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.gc-steps-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-2);
  margin-bottom: 24px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.gc-step-row {
  display: grid;
  grid-template-columns: 275px minmax(0, 1fr);
  gap: 22px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  align-items: center;
  transition: border-color .15s, transform .15s;
}
.gc-step-row:hover {
  border-color: var(--brand);
  transform: translateX(2px);
}
@media (max-width: 720px) {
  .gc-step-row { grid-template-columns: 1fr; }
  .gc-step-thumb { max-width: 100%; }
}
.gc-step-arrow {
  display: flex;
  justify-content: center;
  padding: 5px 0;
  color: var(--text-3);
  font-size: 20px;
  line-height: 1;
}
.gc-step-thumb {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  display: block;
  max-width: 275px;
}
.gc-step-thumb svg { width: 100%; height: 100%; display: block; }
.gc-step-info {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.gc-step-num {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.gc-step-num-badge {
  width: 25px;
  height: 25px;
  border-radius: 7px;
  background: var(--brand);
  color: var(--btn-primary-fg, #fff);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  font-weight: 800;
}
.gc-step-headline {
  font-size: 16.5px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.35;
  letter-spacing: -0.3px;
}
.gc-step-detail {
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--text-2);
}


/* placeholder 카드 */


/* 페이지 진입 애니메이션 */
.page[data-page="guide"].active .g2-hero,
.page[data-page="guide"].active .g2-tabs,
.page[data-page="guide"].active .g2-panel.active {
  animation: g2-page-fade .35s ease-out;
}
@keyframes g2-page-fade {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ═════════════════════════════════════════════════════════════
   가이드 v2 — 다크모드 가독성 핫픽스 v1
   (g2/gc 컴포넌트 한정 — 다른 페이지 영향 X)
═════════════════════════════════════════════════════════════ */
[data-theme="dark"] .g2-hero p { color: #d4d4d8; }
[data-theme="dark"] .g2-hero h1 { color: #fafafa; }

[data-theme="dark"] .g2-tab { color: #d4d4d8; }
[data-theme="dark"] .g2-tab:hover { color: #fafafa; }
[data-theme="dark"] .g2-tab-num { color: #a1a1aa; }
[data-theme="dark"] .g2-tab.active { color: #fafafa; }
[data-theme="dark"] .g2-tab.active .g2-tab-num { color: var(--brand); }
[data-theme="dark"] .g2-tab-label { color: inherit; }


[data-theme="dark"] .gc-title { color: #fafafa; }

[data-theme="dark"] .gc-tag { color: #c7d2fe; background: rgba(129, 140, 248, 0.18); }


[data-theme="dark"] .gc-steps-title { color: #d4d4d8; }
[data-theme="dark"] .gc-step-num { color: #a1a1aa; }
[data-theme="dark"] .gc-step-headline { color: #fafafa; }
[data-theme="dark"] .gc-step-detail { color: #d4d4d8; }
[data-theme="dark"] .gc-step-arrow { color: #71717a; }


/* SVG 안 보조 텍스트 — 카드 컨테이너 안에서만 명도 강화 */
[data-theme="dark"] .gc-step-thumb svg text[fill="var(--text-2)"] { fill: #d4d4d8; }
[data-theme="dark"] .gc-step-thumb svg text[fill="var(--text-3)"] { fill: #a1a1aa; }

/* 업로드 페이지 상단 배너 (가이드 안내) */
.upload-guide-banner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 22px;
  background: linear-gradient(135deg, var(--brand-soft) 0%, var(--beta-soft) 100%);
  border: 1px solid var(--beta-border);
  border-radius: var(--r);
  margin-bottom: 22px;
  text-decoration: none;
  transition: transform .15s, box-shadow .15s;
}
.upload-guide-banner:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px var(--beta-pulse);
}

.upload-guide-banner-text {
  flex: 1;
  min-width: 0;
}
.upload-guide-banner-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 2px;
  letter-spacing: -.01em;
}
.upload-guide-banner-desc {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-2);
  letter-spacing: -.01em;
}
.upload-guide-banner-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--surface);
  color: var(--brand);
  border: 1px solid var(--brand);
  border-radius: var(--r-sm);
  font-size: 12.5px;
  font-weight: 700;
  flex-shrink: 0;
  letter-spacing: -.01em;
  font-family: 'Pretendard Variable', sans-serif;
  transition: background .15s, color .15s;
}
.upload-guide-banner:hover .upload-guide-banner-cta {
  background: var(--brand);
  color: #ffffff;
}

/* 페이지 진입 페이드업 */


/* 반응형 — 좁은 화면 */

@media (max-width: 700px) {
  
  
  
  
  
  
  .upload-guide-banner { flex-direction: column; align-items: flex-start; }
  .upload-guide-banner-cta { width: 100%; justify-content: center; }
}

/* 🆕 v45 [A3] — 가이드 4종 다운로드 인터랙티브 체크리스트 (실 셀러 헤맴 #1.3 판매수수료 누락 해소) */


/* 🆕 v21 [A] — 데이터 가이드 하단 무료 도구 진입 박스 */


.channel-donut-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 8px 4px;
}
.channel-donut {
  width: 200px;
  height: 200px;
  display: block;
  flex-shrink: 0;
}

.channel-legend {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}
.channel-legend-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px 14px;
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  border-radius: var(--r);
  transition: border-color .15s, background .15s;
  min-width: 0;
  overflow: hidden;
}
.channel-legend-row:hover {
  border-color: var(--hover-border);
}
.channel-legend-marker {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex-shrink: 0;
  margin-top: 4px;
}
.channel-legend-info { flex: 1; min-width: 0; overflow: hidden; }
.channel-legend-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -.01em;
  margin-bottom: 8px;
  font-family: 'Pretendard Variable', sans-serif;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  word-break: keep-all;
}
.channel-legend-name .ch-tag {
  font-size: 9.5px;
  font-weight: 600;
  padding: 2px 6px;
  background: var(--beta-soft);
  color: var(--beta-color);
  border: 1px solid var(--beta-border);
  border-radius: 999px;
  letter-spacing: .01em;
  white-space: nowrap;
}
.channel-legend-stats {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}
.channel-stat {
  display: grid;
  grid-template-columns: 36px 1fr;
  align-items: baseline;
  gap: 8px;
  font-family: 'Pretendard Variable', sans-serif;
  font-size: 11.5px;
  min-width: 0;
}
.channel-stat .lbl {
  font-weight: 600;
  color: var(--text-3);
  letter-spacing: -.01em;
  font-size: 10.5px;
}
.channel-stat .val {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -.02em;
  min-width: 0;
  /* 핵심 숫자는 한 단어처럼 처리되어 줄바꿈 안 됨 (숫자 자체가 잘리는 일 없음) */
  /* em(비율)은 inline-block + 자연 줄바꿈 허용 → 폭 부족 시 다음 줄로 자연스럽게 내려감 */
  word-break: keep-all;
  line-height: 1.4;
}
.channel-stat .val em {
  font-style: normal;
  font-weight: 600;
  color: var(--text-3);
  font-size: 10px;
  margin-left: 3px;
  /* 비율은 별도 inline 요소로 — 폭 부족 시 다음 줄 자연 이동 */
  display: inline-block;
  white-space: nowrap;
}
/* SKU 표시 — "96개 마스터 · 213개 옵션" */
.channel-stat .val .sku-chunk {
  display: inline-block;
  white-space: nowrap;     /* 한 청크는 안 깨짐 (숫자+단위 묶음) */
}
.channel-stat .val .sku-sep {
  display: inline-block;
  margin: 0 4px;
  color: var(--text-3);
  font-weight: 500;
}

/* 안내문 (도넛 하단) */
.channel-beta-note {
  margin-top: 16px;
  padding: 10px 14px;
  background: var(--beta-soft);
  border: 1px solid var(--beta-border);
  border-radius: var(--r-sm);
  font-size: 11.5px;
  font-weight: 500;
  color: var(--beta-color);
  letter-spacing: -.01em;
  line-height: 1.55;
  font-family: 'Pretendard Variable', sans-serif;
}
.channel-beta-note strong {
  font-weight: 700;
}
.channel-beta-note a {
  color: var(--beta-color);
  text-decoration: underline;
  font-weight: 700;
}
.channel-beta-note a:hover {
  color: var(--brand-dk);
}

/* 채널 카드 자체에 padding 보정 — 기존 donut-wrap 280px 고정 제약 회피 */
#dashChannelCard .donut-wrap {
  height: auto;
  display: block;
  padding: 0;
}

/* 반응형 */
@media (max-width: 720px) {
  .channel-legend {
    grid-template-columns: 1fr;
  }
  .channel-donut {
    width: 180px;
    height: 180px;
  }
}

/* ════════════════════════════════════════════════════════════
   🆕 글로벌 업로드/분석 진행 토스트
   우하단 떠있음 + 워터마크 위에 위치
   sellerinToast.show(title, desc, progress) / hide() / success(msg) / error(msg)
   ════════════════════════════════════════════════════════════ */

.upload-toast {
  position: fixed;
  right: 18px;
  bottom: 60px;          /* 워터마크 위에 */
  z-index: 60;            /* 워터마크(50)보다 위 */
  min-width: 280px;
  max-width: 360px;
  padding: 14px 18px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  box-shadow: var(--shadow-lg);
  font-family: 'Pretendard Variable', sans-serif;
  opacity: 0;
  transform: translateY(8px) scale(.96);
  pointer-events: none;
  visibility: hidden;
  transition: opacity .25s cubic-bezier(.2,.8,.2,1),
              transform .25s cubic-bezier(.2,.8,.2,1),
              visibility 0s linear .25s;
}
.upload-toast.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
  visibility: visible;
  transition: opacity .25s cubic-bezier(.2,.8,.2,1),
              transform .25s cubic-bezier(.2,.8,.2,1),
              visibility 0s linear 0s;
}

/* 토스트 상태별 색상 */
.upload-toast.is-success {
  border-color: var(--success);
}
.upload-toast.is-error {
  border-color: var(--danger);
}
/* v59.4 (2026-05-20) A.5 — info 상태 추가 (K.B 데이터 복구 안내 토스트 무한 회전 차단).
   스피너 SVG 숨기고 ℹ️ 아이콘 표시. */
.upload-toast.is-info {
  border-color: var(--brand);
}
.upload-toast.is-info .upload-toast-spinner svg {
  display: none;
}
.upload-toast.is-info .upload-toast-spinner::before {
  content: 'ℹ️';
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  font-size: 18px;
}
.upload-toast.is-info .upload-toast-progress {
  display: none;
}

.upload-toast-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.upload-toast-spinner {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}
.upload-toast-spinner svg {
  width: 100%;
  height: 100%;
  animation: toastSpin .8s linear infinite;
}
@keyframes toastSpin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.upload-toast.is-success .upload-toast-spinner svg {
  animation: none;
}
.upload-toast.is-success .upload-toast-spinner::before {
  content: '✓';
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--success);
  color: #ffffff;
  font-size: 16px;
  font-weight: 800;
  border-radius: 50%;
}
.upload-toast.is-success .upload-toast-spinner svg { display: none; }

.upload-toast.is-error .upload-toast-spinner svg {
  animation: none;
}
.upload-toast.is-error .upload-toast-spinner::before {
  content: '!';
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--danger);
  color: #ffffff;
  font-size: 16px;
  font-weight: 800;
  border-radius: 50%;
}
.upload-toast.is-error .upload-toast-spinner svg { display: none; }

.upload-toast-text {
  flex: 1;
  min-width: 0;
}
.upload-toast-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -.01em;
  margin-bottom: 2px;
  line-height: 1.3;
}
.upload-toast-desc {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-2);
  letter-spacing: -.01em;
  line-height: 1.4;
}

.upload-toast-progress {
  width: 100%;
  height: 4px;
  background: var(--surface-2);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}
.upload-toast-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand-accent) 100%);
  border-radius: 999px;
  width: 0%;
  transition: width .3s cubic-bezier(.2,.8,.2,1);
}
/* 무한 진행 (퍼센트를 모를 때) */
.upload-toast-progress.is-indeterminate .upload-toast-progress-bar {
  width: 40% !important;
  animation: toastIndeterminate 1.4s cubic-bezier(.4, 0, .2, 1) infinite;
}
@keyframes toastIndeterminate {
  from { transform: translateX(-100%); }
  to   { transform: translateX(250%); }
}

.upload-toast.is-success .upload-toast-progress-bar {
  background: var(--success);
  width: 100% !important;
}
.upload-toast.is-error .upload-toast-progress-bar {
  background: var(--danger);
  width: 100% !important;
}

/* 좁은 화면 */
@media (max-width: 700px) {
  .upload-toast {
    right: 12px;
    left: 12px;
    bottom: 54px;
    min-width: 0;
    max-width: none;
  }
}


@media (max-width: 767px) {
  .main, .content, .page { min-width: 0; max-width: 100%; }
  .content { padding: 20px 16px; }
  .hero, .sku-header, .ins-hero { flex-wrap: wrap; }
  .hero h1, .hero p, .sku-header-title, .sku-header-meta, .ins-hero h1, .ins-hero p { min-width: 0; overflow-wrap: anywhere; }
  /* grid 1fr = minmax(auto,1fr) → min-content 블로우아웃 방지 위해 minmax(0,1fr) 필수 */
  .kpi-grid { grid-template-columns: minmax(0, 1fr); }
  .sku-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .trust-stages { flex-wrap: wrap; }
  .trust-stages > * { min-width: 0; }
  .kpi-channel-toggle { flex-wrap: wrap; }
  /* 넓은 표·차트는 화면 전체를 밀지 않고 카드 내부에서 가로 스크롤 */
  .sku-table-wrap, .chart-card, .card { max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  /* 터치 영역 44px 확보 (메뉴·로그인·CTA) */
  .nav-item { min-height: 44px; align-items: center; }
  .btn, .btn-primary, .btn-brand, .btn-ghost, .sku-sort-btn, .tab, .kpi-channel-chip { min-height: 44px; }
  .login-footer a, .login-footer-links a { display: inline-block; padding: 12px 6px; }
  .login-email-btn, .login-google-btn { min-height: 48px; }
}


.sb-toggle-btn { display: none; }
@media (max-width: 767px) {
  .sidebar {
    transform: translateX(-100%);
    transition: transform .28s cubic-bezier(.2,.8,.2,1);
    z-index: 9400;
    width: min(280px, 84vw);
  }
  .sidebar.sb-open {
    transform: translateX(0);
    box-shadow: 24px 0 48px rgba(10,10,15,.35);
  }
  .main { margin-left: 0; width: 100%; }
  .sb-toggle-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    margin-right: 4px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    color: var(--text);
    font-size: 18px;
    cursor: pointer;
    flex: none;
  }
  .sb-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9390;
    background: rgba(10,10,15,.45);
  }
  .sb-backdrop.is-open { display: block; }
  
  .sku-table-header, .sku-table-controls { flex-wrap: wrap; }
  /* 토프바 2줄 허용 — 배지·버튼이 뷰포트를 밀지 않도록 (505px 넘침 원인) */
  .topbar { flex-wrap: wrap; height: auto; min-height: var(--topbar-h); padding: 8px 12px; row-gap: 4px; }
  .topbar-right { flex-wrap: wrap; justify-content: flex-end; row-gap: 4px; }
  .sku-search { min-width: 0; max-width: 100%; }
  .free-gate-wrap, .free-gate-content { max-width: 100%; }
  
  .topbar { height: auto; min-height: var(--topbar-h); flex-wrap: wrap; padding: 8px 14px; gap: 6px 10px; }
  .topbar-right { flex-wrap: wrap; min-width: 0; }
  .topbar-left { min-width: 0; }
}

/* ═══ v136 분리 — 원본 style 블록 #1 (L7679) ═══ */
.inapp-guard-mask {
  position: fixed;
  inset: 0;
  z-index: 9999999;
  background: rgba(10, 10, 15, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  font-family: 'Pretendard Variable', -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', sans-serif;
  animation: inappGuardFadeIn 0.3s ease;
}
@keyframes inappGuardFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.inapp-guard-card {
  background: #ffffff;
  border-radius: 20px;
  padding: 32px 26px 26px;
  max-width: 380px;
  width: 100%;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  text-align: center;
  animation: inappGuardSlideUp 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}
@keyframes inappGuardSlideUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}


.inapp-guard-title {
  font-size: 18px;
  font-weight: 800;
  color: #0a0a0f;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
  line-height: 1.4;
}
.inapp-guard-desc {
  font-size: 14px;
  font-weight: 500;
  color: #52525b;
  line-height: 1.6;
  margin-bottom: 22px;
}
.inapp-guard-desc strong {
  color: #4f46e5;
  font-weight: 700;
}
.inapp-guard-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px 18px;
  background: #0a0a0f;
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-family: 'Pretendard Variable', sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 10px;
}
.inapp-guard-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}
.inapp-guard-btn-secondary {
  background: #f5f5f7;
  color: #52525b;
  font-weight: 600;
}
.inapp-guard-btn-secondary:hover {
  background: #ececf0;
}
.inapp-guard-ios-hint {
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  border-radius: 10px;
  padding: 14px 16px;
  margin-top: 14px;
  text-align: left;
  font-size: 13px;
  font-weight: 500;
  color: #4338ca;
  line-height: 1.5;
}
.inapp-guard-ios-hint strong {
  color: #4f46e5;
  font-weight: 700;
}
.inapp-guard-ios-hint .step {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 6px;
}
.inapp-guard-ios-hint .step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  background: #4f46e5;
  color: #ffffff;
  border-radius: 50%;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
}
.inapp-guard-trust {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid #ececf0;
  font-size: 12px;
  font-weight: 500;
  color: #a1a1aa;
  line-height: 1.5;
}
.inapp-guard-trust strong {
  color: #52525b;
  font-weight: 600;
}
.inapp-guard-toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  background: #10b981;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 999px;
  font-family: 'Pretendard Variable', sans-serif;
  font-size: 13px;
  font-weight: 700;
  z-index: 10000000;
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.4);
  animation: inappGuardToastIn 0.3s ease, inappGuardToastOut 0.3s ease 2.4s forwards;
}
@keyframes inappGuardToastIn {
  from { opacity: 0; transform: translate(-50%, 10px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}
@keyframes inappGuardToastOut {
  to { opacity: 0; transform: translate(-50%, 10px); }
}

/* ═══ v136 분리 — 원본 style 블록 #2 (L8210) ═══ */
    
    #printReportHeader { display: none; }
    @media print {
      @page { margin: 12mm; }
      html, html[data-theme="dark"] {
        --bg:#ffffff; --surface:#ffffff; --surface-2:#f5f5f7;
        --border:#ececf0; --border-soft:#f1f1f5; --hover-border:#d4d4d8;
        --text:#0a0a0f; --text-2:#52525b; --text-3:#a1a1aa;
        --brand:#4f46e5; --brand-soft:#eef2ff; --brand-dk:#4338ca; --brand-accent:#818cf8;
        --success:#10b981; --success-soft:#ecfdf5;
        --danger:#e11d48; --danger-soft:#fff1f2;
        --warning:#f59e0b; --warning-soft:#fffbeb;
        --grid-line:#f1f1f5;
      }
      body { background:#ffffff !important; }
      .sidebar, .topbar, .demo-tour-bubble, .demo-gate-notice, .rerun-modal,
      .welcome-overlay, .upload-toast-wrap, .sku-kpi-jump-hint { display: none !important; }
      .main { margin-left: 0 !important; }
      .content { padding: 12px 0 0 0 !important; }
      #printReportHeader {
        display: block !important;
        padding: 0 0 14px 0;
        margin-bottom: 18px;
        border-bottom: 2px solid #4f46e5;
      }
      #printReportHeader .prh-brand { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; color: #0a0a0f; }
      #printReportHeader .prh-brand span { color: #4f46e5; }
      #printReportHeader .prh-title { font-size: 13px; font-weight: 700; color: #52525b; margin-top: 4px; }
      #printReportHeader .prh-meta { font-size: 11px; color: #a1a1aa; margin-top: 2px; font-family: 'JetBrains Mono', monospace; }
      #printReportHeader .prh-disclaimer { font-size: 10px; color: #a1a1aa; margin-top: 6px; }
      * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
    }
    

/* ═══ v136 분리 — 원본 style 블록 #3 (L9981) ═══ */
        .page[data-page="quickstart"] .qs-hero { padding: 32px 36px 28px; background: linear-gradient(135deg, var(--brand) 0%, var(--brand-dk) 100%); border-radius: 18px; color: #fff; margin-bottom: 24px; box-shadow: 0 12px 32px rgba(79, 70, 229, .25); position: relative; overflow: hidden; }
        .page[data-page="quickstart"] .qs-hero::before { content: ''; position: absolute; top: -40px; right: -40px; width: 200px; height: 200px; background: rgba(255,255,255,.08); border-radius: 50%; }
        
        /* 🆕 v67 hero 마케팅 슬로건 */
        .page[data-page="quickstart"] .qs-hero-marketing { display: inline-block; padding: 8px 16px; background: rgba(255,255,255,.18); border-radius: 100px; font-size: 13px; font-weight: 800; letter-spacing: -0.3px; margin-bottom: 14px; }
        /* 🆕 v67.2 hero 처음부터 다시 시작 버튼 */
        .page[data-page="quickstart"] .qs-reset-btn { position: absolute; top: 22px; right: 28px; padding: 7px 14px; background: rgba(255,255,255,.16); color: #fff; border: 1px solid rgba(255,255,255,.3); border-radius: 100px; font-size: 12px; font-weight: 700; cursor: pointer; font-family: inherit; transition: all .15s ease; }
        .page[data-page="quickstart"] .qs-reset-btn:hover { background: rgba(255,255,255,.28); border-color: rgba(255,255,255,.5); }
        .page[data-page="quickstart"] .qs-hero-title { font-size: 30px; font-weight: 800; margin: 0 0 10px 0; letter-spacing: -0.5px; }
        .page[data-page="quickstart"] .qs-hero-desc { font-size: 14px; line-height: 1.6; margin: 0; opacity: 0.92; font-weight: 600; }
        /* 🆕 v67 잠금 상태 스텝 — 시각적으로 흐릿하게 (cursor 변화 + opacity) */
        .page[data-page="quickstart"] .qs-step.is-locked .qs-step-card { opacity: 0.55; }
        .page[data-page="quickstart"] .qs-step.is-locked .qs-cta-primary { background: var(--text-3); cursor: not-allowed; box-shadow: none; }
        .page[data-page="quickstart"] .qs-step.is-locked .qs-cta-primary:hover { background: var(--text-3); transform: none; box-shadow: none; }
        /* v45 [N3] — 진행바 sticky 래퍼 (스크롤 시 토프바 아래 고정) */
        .page[data-page="quickstart"] .qs-progress-sticky {
          position: sticky;
          top: 64px;
          z-index: 5;
          background: var(--bg);
          padding: 22px 0 18px;
          margin: 0 0 12px 0;
        }
        [data-theme="dark"] .page[data-page="quickstart"] .qs-progress-sticky { background: var(--bg); }
        .page[data-page="quickstart"] .qs-progress-sticky::after {
          content: '';
          position: absolute;
          left: -32px;
          right: -32px;
          bottom: 0;
          height: 14px;
          background: linear-gradient(180deg, var(--bg) 0%, transparent 100%);
          pointer-events: none;
        }
        .page[data-page="quickstart"] .qs-progress-bar { position: relative; height: 12px; background: var(--surface-2); border-radius: 100px; overflow: visible; }
        .page[data-page="quickstart"] .qs-progress-fill { height: 100%; background: linear-gradient(90deg, var(--success) 0%, var(--brand) 100%); border-radius: 100px; transition: width .4s ease; }
        .page[data-page="quickstart"] .qs-progress-label { position: absolute; right: 0; top: -22px; font-size: 11px; font-weight: 700; color: var(--text-3); letter-spacing: 0.3px; }
        .page[data-page="quickstart"] .qs-wizard { display: flex; flex-direction: column; gap: 0; }
        .page[data-page="quickstart"] .qs-step { display: grid; grid-template-columns: 56px 1fr; grid-template-rows: auto 1fr; gap: 0; position: relative; }
        .page[data-page="quickstart"] .qs-step-num { grid-row: 1; grid-column: 1; display: flex; align-items: flex-start; justify-content: center; padding-top: 14px; }
        .page[data-page="quickstart"] .qs-step-num span { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--surface); border: 2.5px solid var(--border); color: var(--text-3); font-family: 'JetBrains Mono', monospace; font-size: 16px; font-weight: 800; transition: all .25s ease; }
        .page[data-page="quickstart"] .qs-step.done .qs-step-num span { background: var(--success); border-color: var(--success); color: #fff; }
        .page[data-page="quickstart"] .qs-step-line { grid-row: 2; grid-column: 1; width: 2.5px; background: var(--border); margin: 0 auto; margin-top: 2px; min-height: 30px; }
        .page[data-page="quickstart"] .qs-step.done .qs-step-line { background: var(--success); }
        .page[data-page="quickstart"] .qs-step-card { grid-row: 1 / span 2; grid-column: 2; background: var(--surface); border: 1.5px solid var(--border); border-radius: 16px; padding: 24px 28px; margin-bottom: 16px; transition: all .25s ease; box-shadow: var(--shadow-xs); position: relative; overflow: hidden; }
        .page[data-page="quickstart"] .qs-step.done .qs-step-card { border-color: var(--success); background: var(--success-soft); }
        /* v45 [N2] — 완료 단계 좌측 액센트 바 (직원분 발견: "바탕 변화 인지 어려움" 해소) */
        .page[data-page="quickstart"] .qs-step.done .qs-step-card::after {
          content: '';
          position: absolute;
          left: 0;
          top: 0;
          bottom: 0;
          width: 4px;
          background: var(--success);
        }
        /* v45 [N2] — 완료 단계의 ghost 버튼 자체가 초록 배경 + 흰 글씨로 시각 강화 */
        .page[data-page="quickstart"] .qs-step.done .qs-cta-ghost {
          background: var(--success);
          color: #ffffff;
          border-color: var(--success);
          font-weight: 800;
        }
        .page[data-page="quickstart"] .qs-step.done .qs-cta-ghost:hover {
          background: var(--success);
          color: #ffffff;
          border-color: var(--success);
          filter: brightness(0.93);
        }
        .page[data-page="quickstart"] .qs-step-card:hover { border-color: var(--hover-border); transform: translateY(-1px); box-shadow: var(--shadow-sm); }
        .page[data-page="quickstart"] .qs-step-header { display: flex; gap: 16px; align-items: center; margin-bottom: 12px; }
        
        
        .page[data-page="quickstart"] .qs-step-titles { flex: 1; }
        .page[data-page="quickstart"] .qs-step-eyebrow { font-size: 11px; font-weight: 800; color: var(--brand); letter-spacing: 1px; margin-bottom: 4px; font-family: 'JetBrains Mono', monospace; }
        .page[data-page="quickstart"] .qs-step-title { font-size: 18px; font-weight: 800; color: var(--text); letter-spacing: -0.3px; line-height: 1.3; }
        .page[data-page="quickstart"] .qs-step-desc { font-size: 13.5px; line-height: 1.65; color: var(--text-2); margin-bottom: 14px; }
        .page[data-page="quickstart"] .qs-step-checklist { list-style: none; padding: 0; margin: 0 0 18px 0; display: flex; flex-direction: column; gap: 8px; }
        .page[data-page="quickstart"] .qs-step-checklist li { display: flex; gap: 10px; align-items: center; padding: 8px 12px; background: var(--surface-2); border-radius: 8px; font-size: 12.5px; color: var(--text-2); }
        
        .page[data-page="quickstart"] .qs-step-actions { display: flex; gap: 10px; flex-wrap: wrap; }
        .page[data-page="quickstart"] .qs-cta { display: inline-flex; align-items: center; gap: 8px; padding: 11px 18px; border-radius: 10px; font-size: 13.5px; font-weight: 700; text-decoration: none; cursor: pointer; transition: all .15s ease; border: none; font-family: inherit; }
        .page[data-page="quickstart"] .qs-cta-primary { background: var(--brand); color: #fff; box-shadow: 0 2px 8px rgba(79, 70, 229, .25); }
        .page[data-page="quickstart"] .qs-cta-primary:hover { background: var(--brand-dk); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(79, 70, 229, .35); }
        .page[data-page="quickstart"] .qs-cta-ghost { background: var(--surface); color: var(--text-2); border: 1.5px solid var(--border); }
        .page[data-page="quickstart"] .qs-cta-ghost:hover { border-color: var(--brand); color: var(--brand); }
        .page[data-page="quickstart"] .qs-cta-arrow { font-size: 16px; }
        .page[data-page="quickstart"] .qs-help { margin-top: 24px; padding: 22px 26px; background: var(--surface-2); border-radius: 14px; border: 1px dashed var(--border); }
        .page[data-page="quickstart"] .qs-help-title { font-size: 14px; font-weight: 800; color: var(--text); margin-bottom: 12px; }
        .page[data-page="quickstart"] .qs-help-actions { display: flex; gap: 10px; flex-wrap: wrap; }
        /* ⭐ v149 (28차 R5 / P8-2) — 단계별 소요시간·오류 해결·고객센터 */
        .page[data-page="quickstart"] .qs-step-eta { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; color: var(--text-3); background: var(--surface-2); padding: 3px 10px; border-radius: 100px; white-space: nowrap; flex-shrink: 0; }
        .page[data-page="quickstart"] .qs-step-help { margin: 2px 0 14px; }
        .page[data-page="quickstart"] .qs-step-help summary { cursor: pointer; font-size: 12.5px; font-weight: 700; color: var(--brand); list-style: none; display: flex; align-items: center; gap: 6px; padding: 2px 0; }
        .page[data-page="quickstart"] .qs-step-help summary::-webkit-details-marker { display: none; }
        .page[data-page="quickstart"] .qs-step-help summary::before { content: '▸'; font-size: 10px; display: inline-block; transition: transform .15s ease; }
        .page[data-page="quickstart"] .qs-step-help[open] summary::before { transform: rotate(90deg); }
        .page[data-page="quickstart"] .qs-step-help-body { margin-top: 10px; padding: 12px 14px; background: var(--surface-2); border-radius: 10px; font-size: 12.5px; line-height: 1.7; color: var(--text-2); }
        .page[data-page="quickstart"] .qs-step-help-body dt { font-weight: 700; color: var(--text); margin-top: 10px; }
        .page[data-page="quickstart"] .qs-step-help-body dt:first-child { margin-top: 0; }
        .page[data-page="quickstart"] .qs-step-help-body dd { margin: 2px 0 0; }
        .page[data-page="quickstart"] .qs-step-help-body a { color: var(--brand); }
        .page[data-page="quickstart"] .qs-step-cs-link { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; color: var(--text-3); text-decoration: none; margin-left: 4px; }
        .page[data-page="quickstart"] .qs-step-cs-link:hover { color: var(--brand); }
        @media (max-width: 720px) {
          .page[data-page="quickstart"] .qs-step { grid-template-columns: 44px 1fr; }
          .page[data-page="quickstart"] .qs-step-card { padding: 18px 20px; }
          .page[data-page="quickstart"] .qs-step-num span { width: 32px; height: 32px; font-size: 13px; }
        }

        
        .page[data-page="quickstart"] .qs-step.is-current .qs-step-num span {
          width: 52px; height: 52px; font-size: 20px;
          background: var(--brand); border-color: var(--brand); color: #fff;
          animation: qsStepNumPulse 1.8s infinite;
          transform: scale(1.05);
        }
        .page[data-page="quickstart"] .qs-step.is-current .qs-step-card {
          border-color: var(--brand); border-width: 2px;
          box-shadow: 0 8px 24px rgba(79, 70, 229, .18);
          transform: translateY(-1px);
        }
        .page[data-page="quickstart"] .qs-step.is-current .qs-step-card::before {
          content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
          background: var(--brand); border-radius: 16px 0 0 16px;
        }
        .page[data-page="quickstart"] .qs-step.is-current .qs-step-eyebrow::after {
          /* ⭐ v164 (P2-3) — 손가락 이모지 제거·대체텍스트 정리: 현재 단계는 텍스트로 전달 */
          content: ' · 지금 이 단계' / ' 지금 이 단계'; color: var(--brand); font-weight: 800;
        }
        
        @keyframes qsStepNumPulse {
          0%, 100% { box-shadow: 0 2px 8px rgba(79, 70, 229, .4), 0 0 0 0 rgba(79, 70, 229, .5); }
          50%      { box-shadow: 0 4px 16px rgba(79, 70, 229, .55), 0 0 0 10px rgba(79, 70, 229, 0); }
        }
        [data-theme="dark"] .page[data-page="quickstart"] .qs-step.is-current .qs-step-num span {
          animation: qsStepNumPulseDark 1.8s infinite;
        }
        @keyframes qsStepNumPulseDark {
          0%, 100% { box-shadow: 0 2px 8px rgba(129, 140, 248, .4), 0 0 0 0 rgba(129, 140, 248, .5); }
          50%      { box-shadow: 0 4px 16px rgba(129, 140, 248, .55), 0 0 0 10px rgba(129, 140, 248, 0); }
        }
        /* done 단계가 is-current보다 우선 (모두 완료 후엔 펄스 안 함) */
        .page[data-page="quickstart"] .qs-step.done.is-current .qs-step-num span { animation: none; transform: none; background: var(--success); border-color: var(--success); }
        .page[data-page="quickstart"] .qs-step.done.is-current .qs-step-card::before { display: none; }
        .page[data-page="quickstart"] .qs-step.done.is-current .qs-step-eyebrow::after { content: ''; }
        @media (max-width: 768px) {
          .page[data-page="quickstart"] .qs-step.is-current .qs-step-num span { width: 40px; height: 40px; font-size: 15px; }
          .page[data-page="quickstart"] .qs-hero-title { font-size: 24px; }
        }
      

/* ═══ v136 분리 — 원본 style 블록 #4 (L21274) ═══ */
  /* 12단계 대시보드 빈 상태 */
  .dash-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    text-align: center;
    color: var(--text-3);
    min-height: 220px;
  }
  .dash-empty-icon {
    font-size: 36px;
    opacity: 0.4;
    margin-bottom: 12px;
  }
  .dash-empty-msg {
    font-size: 13.5px;
    font-weight: 600;
    color: var(--text-2);
    line-height: 1.55;
  }
  .dash-empty-sub {
    margin-top: 8px;
    font-size: 11.5px;
    color: var(--text-3);
    line-height: 1.5;
  }

  /* KPI 카드 갱신 후 스파크라인 색상 (CSS Variables 적용) */
  .kpi .spark-area-brand   { fill: var(--brand);   opacity: .18; }
  .kpi .spark-line-brand   { stroke: var(--brand); }
  .kpi .spark-area-success { fill: var(--success); opacity: .18; }
  .kpi .spark-line-success { stroke: var(--success); }
  .kpi .spark-area-danger  { fill: var(--danger);  opacity: .18; }
  .kpi .spark-line-danger  { stroke: var(--danger); }
  .kpi .spark-area-warning { fill: var(--warning); opacity: .18; }
  .kpi .spark-line-warning { stroke: var(--warning); }

  /* 주차별 추이 차트 */
  .weekly-svg {
    width: 100%;
    height: 280px;
    display: block;
  }
  .weekly-svg .grid-line {
    stroke: var(--grid-line);
    stroke-width: 1;
  }
  .weekly-svg .y-label {
    fill: var(--text-3);
    font-size: 10px;
    font-family: 'JetBrains Mono', monospace;
  }
  .weekly-svg .x-label {
    fill: var(--text-2);
    font-size: 11px;
    font-weight: 500;
  }
  .weekly-svg .x-label-sub {
    fill: var(--text-3);
    font-size: 10px;
    font-weight: 500;
    font-family: 'JetBrains Mono', monospace;
  }
  .weekly-svg .area-margin { fill: var(--success); opacity: .18; }
  .weekly-svg .line-margin { stroke: var(--success); stroke-width: 2.5; fill: none; stroke-linecap: round; stroke-linejoin: round; }
  .weekly-svg .area-revenue { fill: var(--brand); opacity: .18; }
  .weekly-svg .line-revenue { stroke: var(--brand); stroke-width: 2.5; fill: none; stroke-linecap: round; stroke-linejoin: round; }
  .weekly-svg .area-cost { fill: var(--danger); opacity: .15; }
  .weekly-svg .line-cost { stroke: var(--danger); stroke-width: 2.5; fill: none; stroke-linecap: round; stroke-linejoin: round; }
  .weekly-svg .point { stroke-width: 2; }
  .weekly-svg .latest-label-bg { fill: var(--text); }
  .weekly-svg .latest-label-text {
    fill: var(--surface);
    font-size: 10.5px;
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
  }

  /* TOP/BOTTOM 리스트의 마스터 단위 표시 보강 */
  .sku-meta .opt-merge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    margin-left: 6px;
    padding: 1px 6px;
    border-radius: 999px;
    background: var(--brand-soft);
    color: var(--brand-dk);
    font-size: 10.5px;
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
  }
  [data-theme="dark"] .sku-meta .opt-merge {
    background: var(--brand-soft);
    color: var(--brand);
  }

  /* 페이지 진입 페이드업 (대시보드 카드) */
  @keyframes dash-fade-up {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
  }
  #dashKpiGrid > .kpi,
  #dashCostBars > .cost-row {
    animation: dash-fade-up .35s cubic-bezier(.2,.8,.2,1) both;
  }

/* ═══ v136 분리 — 원본 style 블록 #5 (L24579) ═══ */
  .mobile-pc-modal-overlay{
    display:none;position:fixed;inset:0;z-index:9600;
    background:rgba(10,10,15,.55);backdrop-filter:blur(3px);-webkit-backdrop-filter:blur(3px);
    align-items:center;justify-content:center;padding:24px;
  }
  .mobile-pc-modal-overlay.is-open{display:flex;animation:mpmFade .2s ease}
  @keyframes mpmFade{from{opacity:0}to{opacity:1}}
  .mobile-pc-modal{
    width:100%;max-width:340px;
    background:var(--surface);border:1px solid var(--border);border-radius:var(--r-xl, 20px);
    box-shadow:var(--shadow-lg, 0 12px 32px rgba(10,10,15,.10));
    padding:24px 22px;text-align:center;color:var(--text);
    animation:mpmPop .25s cubic-bezier(.2,.9,.3,1.2);
  }
  @keyframes mpmPop{from{opacity:0;transform:scale(.94) translateY(8px)}to{opacity:1;transform:none}}
  .mobile-pc-modal .mpm-icon{font-size:34px;line-height:1;margin-bottom:10px}
  .mobile-pc-modal .mpm-title{font-size:16px;font-weight:800;letter-spacing:-0.02em;margin:0 0 8px}
  .mobile-pc-modal .mpm-desc{font-size:13px;line-height:1.6;color:var(--text-2);margin:0 0 6px}
  .mobile-pc-modal .mpm-sub{font-size:12px;line-height:1.55;color:var(--text-3);margin:0 0 16px}
  .mobile-pc-modal .mpm-btn{
    display:block;width:100%;padding:12px 16px;border:none;cursor:pointer;
    border-radius:12px;font-size:13.5px;font-weight:700;font-family:inherit;letter-spacing:-0.01em;
    background:var(--brand);color:#fff; /* v117.1 (2026-07-28) — 메인 브랜드 인디고로 변경 */
  }
  .mobile-pc-modal .mpm-btn:active{opacity:.85}
  @media (min-width:768px){ .mobile-pc-modal-overlay{display:none !important} }

/* ═══ v137 R1 접근성 ═══ */
/* v137 R1 접근성 — 본문 바로가기 */
.skip-link{position:absolute;left:-9999px;top:0;z-index:12000;background:var(--brand);color:#ffffff;font-weight:700;font-size:14px;padding:10px 18px;border-radius:0 0 10px 0;text-decoration:none}
.skip-link:focus{left:0}
