/* ==========================================================================
   wb-vue.css —— Vue 化基座补充样式（style.css 未覆盖的部件）
   设计令牌全部取自 style.css，禁止另立色值
   ========================================================================== */

/* ---------- 图标 ---------- */
.wbv-ico { display: inline-flex; align-items: center; justify-content: center; vertical-align: -2px; }
.wbv-ico svg { display: block; }

/* ---------- 页头 ---------- */
.wbv-page-h {
  display: flex; align-items: flex-end; justify-content: space-between;
  margin-bottom: 16px; gap: 12px;
}
.wbv-page-h h2 { font-size: 20px; font-weight: 700; }
.wbv-page-h p  { font-size: 13px; color: var(--text-3); margin-top: 3px; }
.wbv-page-act  { display: flex; gap: var(--gap-sm); align-items: center; flex-shrink: 0; }

/* ---------- 工具条（搜索 + 筛选） ---------- */
.wbv-toolbar {
  display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap;
}
.wbv-search {
  display: flex; align-items: center; gap: 7px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 7px 11px; background: #fff; color: var(--text-3);
  min-width: 240px; transition: .15s;
}
.wbv-search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.wbv-search input { border: none; outline: none; font-size: 13px; flex: 1; color: var(--text); background: transparent; }
.wbv-sel {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 7px 10px; font-size: 13px; color: var(--text-2); background: #fff;
  outline: none; cursor: pointer; transition: .15s;
}
.wbv-sel:focus { border-color: var(--accent); }
.wbv-toolbar-act { margin-left: auto; display: flex; gap: var(--gap-sm); }

/* ---------- 表格 ---------- */
.wbv-tbl-wrap { overflow: hidden; }
.wbv-tbl-wrap table tr.clickable { cursor: pointer; transition: background .12s; }
.wbv-tbl-wrap table tr.clickable:hover td { background: #f8f9fc; }
.wbv-td-main { color: var(--text); font-weight: 500; font-size: 13px; }
.wbv-td-sub  { font-size: 11.5px; color: var(--text-3); margin-top: 1px; }
.wbv-link { color: var(--accent); cursor: pointer; font-size: 12.5px; }
.wbv-link:hover { text-decoration: underline; }

/* ---------- 空状态 ---------- */
.wbv-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 48px 20px; color: var(--text-3); gap: 6px;
}
.wbv-empty-ico { opacity: .45; margin-bottom: 4px; }
.wbv-empty-t { font-size: 13.5px; font-weight: 500; color: var(--text-2); }
.wbv-empty-s { font-size: 12px; }

/* ---------- 分页 ---------- */
.wbv-pager {
  display: flex; align-items: center; justify-content: flex-end;
  gap: 10px; margin-top: 12px; font-size: 12.5px; color: var(--text-3);
}
.wbv-pager .btn:disabled { opacity: .45; cursor: not-allowed; }
.wbv-pager-cur { color: var(--text-2); font-weight: 500; }

/* ---------- 抽屉 ---------- */
.wbv-mask {
  position: fixed; inset: 0; background: rgba(16,24,40,.28);
  z-index: 90; display: flex; justify-content: flex-end;
  animation: wbv-fade .18s ease;
}
@keyframes wbv-fade { from { opacity: 0; } }
.wbv-drawer {
  height: 100vh; background: var(--panel);
  box-shadow: -8px 0 30px rgba(16,24,40,.12);
  display: flex; flex-direction: column;
  animation: wbv-slide .22s ease;
}
@keyframes wbv-slide { from { transform: translateX(40px); opacity: .4; } }
.wbv-drawer-h {
  display: flex; align-items: flex-start; justify-content: space-between;
  padding: 18px 22px 14px; border-bottom: 1px solid var(--border-light);
}
.wbv-drawer-t { font-size: 16px; font-weight: 700; }
.wbv-drawer-s { font-size: 12px; color: var(--text-3); margin-top: 3px; }
.wbv-drawer-x {
  cursor: pointer; color: var(--text-3); font-size: 14px; padding: 4px 8px;
  border-radius: 6px; transition: .15s;
}
.wbv-drawer-x:hover { background: #f2f3f5; color: var(--text); }
.wbv-drawer-b { flex: 1; overflow-y: auto; padding: 6px 22px 22px; }
.wbv-drawer-f {
  border-top: 1px solid var(--border-light); padding: 12px 22px;
  display: flex; gap: var(--gap-sm); justify-content: flex-end;
}
.wbv-drawer-b .card { margin-top: 14px; }
.wbv-drawer-b .section-title:first-child { margin-top: 14px; }

/* ---------- 登录页错误 ---------- */
.wbv-login-err {
  background: var(--red-soft); color: var(--red);
  border-radius: var(--radius-sm); padding: 8px 12px; font-size: 12.5px;
}

/* ---------- 区块标题间距微调 ---------- */
.section-title { display: flex; align-items: center; justify-content: space-between; }
.section-title .more { font-size: 12px; color: var(--accent); cursor: pointer; font-weight: 400; }
.section-title .more:hover { text-decoration: underline; }

/* ---------- 网格辅助 ---------- */
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.grid.main-2-1 { grid-template-columns: 2fr 1fr; }
.grid.main-1-2 { grid-template-columns: 1fr 2fr; }
@media (max-width: 1100px) {
  .grid.cols-3, .grid.cols-4, .grid.stat-grid { grid-template-columns: repeat(2, 1fr); }
  .grid.main-2-1, .grid.main-1-2 { grid-template-columns: 1fr; }
}

/* ---------- 描述列表卡 ---------- */
.wbv-kv-card { padding: 4px 0; }

/* ---------- 筛选 chips 行 ---------- */
.wbv-chips { display: flex; gap: var(--gap-sm); flex-wrap: wrap; margin-bottom: 14px; }
.wbv-chips .chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ---------- 对话布局（配合 style.css .chat-wrap） ---------- */
.chat-wrap .right-panel .card { padding: 14px 16px; }
.chat-wrap .right-panel .flow-title { margin-bottom: var(--gap-sm); }

/* ---------- 列表页统计带 ---------- */
.wbv-strip { display: flex; gap: var(--gap); margin-bottom: 14px; flex-wrap: wrap; }
.wbv-strip .stat { flex: 1; min-width: 150px; padding: 13px 16px; }
.wbv-strip .stat .num { font-size: 21px; }

/* ---------- 抽屉内里程碑 ---------- */
.wbv-drawer-b .milestone-flow { padding: var(--gap) 0; }

/* ---------- 表内操作链接组 ---------- */
.wbv-row-acts { display: flex; gap: 10px; justify-content: flex-end; }

/* ---------- 通用段落文本 ---------- */
.wbv-prose { font-size: 13.5px; color: var(--text-2); line-height: 1.8; }
.wbv-prose h4 { font-size: 14px; color: var(--text); margin: 14px 0 6px; }
.wbv-prose ul { padding-left: 18px; margin: 6px 0; }

/* fullOrig 整体嵌入模式：宿主透明，布局全交给原版 DOM/CSS */
.orig-full-host { display: contents; }
