﻿/* ================= 组件增强层：为销售工作台补充的界面组件 ================= */

/* ---------- 页头 ---------- */
.page-head { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.ph-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.ph-main h2 { font-size: 18px; font-weight: 600; letter-spacing: -.2px; display: flex; align-items: center; gap: 9px; line-height: 1.3; }
.ph-main p { font-size: 12.5px; color: var(--muted); line-height: 1.5; max-width: 640px; }
.ph-actions { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ph-actions .btn { padding: 7px 14px; font-size: 13px; border-radius: 8px; }

/* ---------- 指标卡（新版） ---------- */
.stat-grid { display: grid; gap: 12px; margin-bottom: 14px; grid-template-columns: repeat(auto-fit, minmax(158px, 1fr)); }
.stat-grid.c2 { grid-template-columns: repeat(2, 1fr); }
.stat-grid.c3 { grid-template-columns: repeat(3, 1fr); }
/* 抽屉里一排放四个：字号收一点，「1分39秒」这种才不会被折成两行 */
.stat-grid.compact .stat-value { font-size: 19px; }
.stat-grid.compact .stat-sub { font-size: 11px; }
.stat-grid.c4 { grid-template-columns: repeat(4, 1fr); }
.stat-grid.c5 { grid-template-columns: repeat(5, 1fr); }
.stat-grid.c6 { grid-template-columns: repeat(6, 1fr); }
/* 7 张卡在 auto-fit 下会「6+1」，第 7 张孤零零挂第二行左边，右边一大片空白。
   窄屏退回 4 列两行，仍然齐整 */
.stat-grid.c7 { grid-template-columns: repeat(7, 1fr); }
/* 7 列时每张只有 ~105px：说明文字有的 1 行有的 2 行，卡片底部不齐。
   统一预留两行高度，整排看起来是齐的 */
.stat-grid.c7 .stat { padding: 13px 13px; }
.stat-grid.c7 .stat-sub { min-height: 32px; align-items: flex-start; }
@media (max-width: 1180px) { .stat-grid.c7 { grid-template-columns: repeat(4, 1fr); } }

.stat {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px 16px; box-shadow: var(--shadow); position: relative; overflow: hidden;
  transition: box-shadow .18s, transform .18s;
}
.stat[data-nav] { cursor: pointer; }
.stat[data-nav]:hover { box-shadow: 0 4px 14px rgba(16, 24, 40, .08); transform: translateY(-1px); }
.stat-label { font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.stat-ico { margin-left: auto; opacity: .5; font-size: 13px; }
.stat-value { font-size: 23px; font-weight: 600; margin-top: 6px; letter-spacing: -.5px; font-variant-numeric: tabular-nums; }
.stat-value small { font-size: 12px; font-weight: 400; color: var(--muted); margin-left: 4px; }
.stat-sub { font-size: 11.5px; color: var(--muted); margin-top: 4px; display: flex; align-items: center; gap: 6px; }
.stat-sub .up { color: #dc2626; }
.stat-sub .down { color: #16a34a; }
.stat.tone-primary { border-left: 3px solid var(--primary); }
.stat.tone-warn { border-left: 3px solid var(--warn); }
.stat.tone-danger { border-left: 3px solid var(--danger); }
.stat.tone-ok { border-left: 3px solid var(--success); }
.stat.tone-teal { border-left: 3px solid #0f9d8a; }
.stat.tone-purple { border-left: 3px solid #7c3aed; }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); margin-bottom: 14px; overflow-x: auto; }
.tab {
  padding: 9px 14px; font-size: 13.5px; color: var(--text-2); border-bottom: 2px solid transparent;
  white-space: nowrap; display: flex; align-items: center; gap: 6px;
}
.tab:hover { color: var(--primary); }
.tab.on { color: var(--primary); border-bottom-color: var(--primary); font-weight: 500; }
.tab-num {
  font-size: 11px; font-weight: 500; background: #f1f2f5; color: var(--text-2);
  border-radius: 9px; padding: 0 6px; min-width: 18px; text-align: center;
}
.tab.on .tab-num { background: var(--primary-soft); color: var(--primary); }

/* ---------- 分段控件 ---------- */
.segmented { display: inline-flex; background: #f1f2f5; border-radius: 8px; padding: 2px; gap: 2px; }
.seg { padding: 5px 12px; font-size: 12.5px; border-radius: 6px; color: var(--text-2); }
.seg.on { background: #fff; color: var(--text); font-weight: 500; box-shadow: 0 1px 3px rgba(16, 24, 40, .1); }

/* ---------- 快捷筛选胶囊 ---------- */
.chips { display: flex; gap: 7px; flex-wrap: wrap; margin-bottom: 12px; }
.chip {
  padding: 5px 11px; border-radius: 16px; font-size: 12.5px; color: var(--text-2);
  background: #fff; border: 1px solid var(--border-strong); display: flex; align-items: center; gap: 5px;
  transition: all .15s;
}
.chip:hover { border-color: var(--primary); color: var(--primary); }
.chip.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.chip b { font-size: 11px; font-weight: 500; background: rgba(0, 0, 0, .06); border-radius: 8px; padding: 0 5px; }
.chip.on b { background: rgba(255, 255, 255, .22); }
.chip.warn { color: #b45309; border-color: #f2d9b0; background: #fffaf1; }
.chip.warn.on { background: #d97706; border-color: #d97706; color: #fff; }
.chip.danger { color: #b91c1c; border-color: #f3c9cb; background: #fff7f7; }
.chip.danger.on { background: #dc2626; border-color: #dc2626; color: #fff; }

/* ---------- 高级筛选面板 ---------- */
.filter-panel {
  display: none; background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px 16px 12px; margin-bottom: 12px; box-shadow: var(--shadow);
}
.filter-panel.open { display: block; }
.fp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(178px, 1fr)); gap: 10px 12px; }
.fp-item label { display: block; font-size: 11.5px; color: var(--muted); margin-bottom: 4px; }
.fp-item input, .fp-item select { padding: 6px 9px; font-size: 12.5px; }
.fp-item.wide { grid-column: span 2; }
.fp-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--border); }
.fp-more { font-size: 12px; color: var(--primary); cursor: pointer; }

/* ---------- 已选条件条（筛完能一眼看到选中了什么，点 × 单独去掉） ---------- */
.fv-quick { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
/* 拜访的高级筛选有 7 项，按默认 178px 会在末行剩一个孤零零的「排序」 */
#fv-adv .fp-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
/* 客户跟进看板 15 项，排 5 列 × 3 行刚好填满，不留半行 */
#adv-holder #filter-panel .fp-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
/* 跟进待办 14 项：7 列正好两行填满，不留半行空白；窄屏再退回自适应 */
#td-holder #filter-panel .fp-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); }
@media (max-width: 1180px) { #td-holder #filter-panel .fp-grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); } }
.toolbar-inline .sb-split { width: 1px; height: 16px; background: var(--border); margin: 0 2px; flex: 0 0 auto; }
.fv-tags { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 0 0 10px; }
.fv-tags:empty { display: none; }
.fv-tag {
  display: inline-flex; align-items: center; gap: 5px; height: 25px; padding: 0 9px;
  border: 1px solid var(--border); border-radius: 20px; background: #fff;
  font-size: 12px; color: var(--text-2); line-height: 1;
}
.fv-tag b { font-weight: 500; color: var(--text); }
.fv-tag i { font-style: normal; cursor: pointer; color: var(--muted); font-size: 13px; }
.fv-tag i:hover { color: var(--danger); }
.fv-tag.clear { border-color: transparent; background: none; color: var(--primary); padding: 0 2px; cursor: pointer; }

/* ---------- 工具栏（新版） ---------- */
.tb-search {
  position: relative; flex: 1; min-width: 200px; max-width: 340px;
}
.tb-search svg { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.tb-search input { padding-left: 31px; padding-top: 7px; padding-bottom: 7px; font-size: 13px; }
.tb-right { margin-left: auto; display: flex; gap: 8px; align-items: center; }

/* ---------- 批量操作条 ---------- */
.bulk-bar {
  display: none; align-items: center; gap: 8px; background: #0f172a; color: #fff;
  padding: 9px 14px; border-radius: 8px; margin-bottom: 10px; box-shadow: var(--shadow-lg);
  position: sticky; top: 0; z-index: 5;
}
.bulk-bar.on { display: flex; }
.bulk-count { font-size: 12.5px; color: #cbd5e1; margin-right: 4px; }
.bulk-count b { color: #fff; font-size: 14px; }
.bulk-bar .btn { background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .18); color: #fff; }
.bulk-bar .btn:hover { background: rgba(255, 255, 255, .2); color: #fff; border-color: rgba(255, 255, 255, .3); }
.bulk-bar .btn-primary { background: var(--primary); border-color: var(--primary); }
.bulk-bar .btn-ghost { margin-left: auto; }

/* ---------- 表格增强 ---------- */
.table-wrap.rounded { border-radius: var(--radius); }
table.compact thead th { padding: 8px 10px; }
table.compact tbody td { padding: 8px 10px; }
tr.selected { background: #f0f6ff !important; }
td .row-main { display: flex; align-items: center; gap: 8px; }
.avatar-xs {
  width: 30px; height: 30px; border-radius: 8px; background: #eef2f9; color: #334155;
  display: grid; place-items: center; font-size: 12px; font-weight: 500; flex: none;
}
.avatar-xs.round { border-radius: 50%; }
.hl { color: var(--danger); font-weight: 500; }
.muted { color: var(--muted); }

/* ---------- 成员单元格（系统设置 · 账号列表） ----------
   12 列挤在一屏会把「销售一部」压成一列一个字，所以合并成 8 列并禁止关键列换行 */
.user-table td { vertical-align: middle; }
.user-table th:nth-child(2), .user-table td:nth-child(2),
.user-table th:nth-child(3), .user-table td:nth-child(3),
.user-table th:nth-child(4), .user-table td:nth-child(4) { white-space: nowrap; }
.u-cell { display: flex; align-items: center; gap: 9px; }
.u-avatar {
  width: 30px; height: 30px; border-radius: 9px; flex: none;
  background: #eef4ff; color: var(--primary);
  display: grid; place-items: center; font-size: 13px; font-weight: 600;
}
.u-name { font-weight: 500; line-height: 1.35; }
.u-sub { font-size: 12px; color: var(--muted); line-height: 1.35; }

/* 等级胶囊：比纯字母更清楚，也不会被误认成名字的一部分 */
.tag.lv-tag { padding: 0 6px; height: 18px; line-height: 18px; font-size: 11px; font-weight: 500; }
.small { font-size: 12px; }
.nowrap { white-space: nowrap; }
.mini-tag {
  display: inline-block; padding: 0 6px; border-radius: 4px; font-size: 11px;
  background: #f2f4f8; color: #5b636e; margin-right: 4px; line-height: 18px;
}
.intent-bar { display: inline-flex; gap: 2px; align-items: center; }
.intent-bar i { width: 4px; height: 11px; border-radius: 1px; background: #e5e7eb; }
.intent-bar i.on { background: #dc2626; }
.intent-bar i.on.mid { background: #d97706; }
.intent-bar i.on.low { background: #94a3b8; }

/* ---------- 抽屉 ---------- */
.drawer-mask {
  position: fixed; inset: 0; background: rgba(15, 23, 42, .32); z-index: 120;
  display: flex; justify-content: flex-end; animation: fadeIn .16s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideLeft { from { transform: translateX(30px); opacity: .6; } to { transform: none; opacity: 1; } }
.drawer {
  width: min(var(--dw, 520px), 100vw); background: #fff; height: 100%; display: flex; flex-direction: column;
  box-shadow: -8px 0 40px rgba(16, 24, 40, .16); animation: slideLeft .2s ease;
}
.drawer-head {
  padding: 16px 20px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 10px;
}
.drawer-head h3 { font-size: 15px; font-weight: 600; flex: 1; }
.drawer-head .x, .modal-head .x { font-size: 22px; color: var(--muted); line-height: 1; padding: 0 4px; }
.drawer-head .x:hover, .modal-head .x:hover { color: var(--text); }
.drawer-body { flex: 1; min-height: 0; overflow-y: auto; padding: 18px 20px; }
.drawer-foot {
  padding: 12px 20px; border-top: 1px solid var(--border); display: flex; gap: 8px; justify-content: flex-end;
  background: #fff;
}

/* ---------- 环形/进度 ---------- */
.ring-wrap { display: flex; flex-direction: column; align-items: center; }
.ring-label { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.meter { background: #f1f3f6; border-radius: 4px; overflow: hidden; height: 6px; min-width: 30px; }
.meter i { display: block; height: 100%; border-radius: 4px; transition: width .3s; }

/* ---------- 时间轴 ---------- */
.timeline { position: relative; padding-left: 4px; }
.tl-item { position: relative; padding: 0 0 16px 20px; border-left: 1px solid #e8ebf0; }
.tl-item:last-child { border-left-color: transparent; padding-bottom: 0; }
.tl-dot {
  position: absolute; left: -5px; top: 4px; width: 9px; height: 9px; border-radius: 50%;
  background: #fff; border: 2px solid var(--primary);
}
.tl-item.ok .tl-dot { border-color: var(--success); }
.tl-item.warn .tl-dot { border-color: var(--warn); }
.tl-item.danger .tl-dot { border-color: var(--danger); }
.tl-head { display: flex; align-items: baseline; gap: 8px; }
.tl-head b { font-size: 13px; font-weight: 500; }
.tl-head span { font-size: 11.5px; color: var(--muted); margin-left: auto; }
.tl-desc { font-size: 12.5px; color: var(--text-2); margin-top: 3px; line-height: 1.65; }
/* 流程节点：完成日期 + 节点上传的通知文件（可下载） */
.tl-date { display: inline-block; margin-top: 4px; font-size: 11.5px; color: #15803d; }
.tl-files { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 4px; }
.tl-file { font-size: 12px; color: var(--primary); text-decoration: none; }
.tl-file:hover { text-decoration: underline; }

/* ---------- KV ---------- */
.kv-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px 18px; }
.kv { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.kv.wide { grid-column: span 2; }
.kv > span { font-size: 11.5px; color: var(--muted); }
.kv > b { font-size: 13px; font-weight: 500; word-break: break-all; }

/* ---------- 横向条形图 ---------- */
.hbar-list { display: flex; flex-direction: column; gap: 9px; }
.hbar-row { display: grid; grid-template-columns: 78px 1fr 52px; align-items: center; gap: 10px; }
.hbar-label { font-size: 12.5px; color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hbar-track { height: 8px; background: #f1f3f6; border-radius: 4px; overflow: hidden; }
.hbar-track i { display: block; height: 100%; border-radius: 4px; }
.hbar-val { font-size: 12px; text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- 漏斗 ---------- */
.funnel-list { display: flex; flex-direction: column; gap: 10px; }
.funnel-head { display: flex; justify-content: space-between; font-size: 12.5px; margin-bottom: 4px; color: var(--text-2); }
.funnel-head b { font-weight: 600; color: var(--text); font-size: 13.5px; }
.funnel-rate { font-style: normal; font-size: 11px; color: var(--muted); margin-left: 6px; }
.funnel-track { height: 20px; background: #f4f6f9; border-radius: 5px; overflow: hidden; }
.funnel-track i { display: block; height: 100%; border-radius: 5px; }

/* ---------- 环形图 ---------- */
.donut-wrap { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.donut-legend { min-width: 150px; flex: 1; }
.donut-legend-row { display: flex; align-items: center; gap: 7px; font-size: 12.5px; padding: 3px 0; }
.donut-legend-row i { width: 8px; height: 8px; border-radius: 2px; flex: none; }
.donut-legend-row span { color: var(--text-2); flex: 1; }
.donut-legend-row b { font-weight: 500; font-variant-numeric: tabular-nums; }
.donut-legend-row em { font-style: normal; font-size: 11px; color: var(--muted); width: 34px; text-align: right; }

/* ---------- 工作台布局 ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.grid-2-1 { display: grid; grid-template-columns: 2fr 1fr; gap: 14px; }
.grid-1-2 { display: grid; grid-template-columns: 1fr 2fr; gap: 14px; }
.section-title {
  font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 8px; margin-bottom: 10px;
}
.section-title .more { margin-left: auto; font-size: 12px; font-weight: 400; color: var(--primary); cursor: pointer; }
.section-title .count { font-size: 11.5px; color: var(--muted); font-weight: 400; }

/* 今日行动条 */
.action-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px; }
.action-item {
  background: #fff; border: 1px solid var(--border); border-left: 3px solid var(--primary);
  border-radius: var(--radius); padding: 12px 14px; cursor: pointer; transition: all .15s;
}
.action-item:hover { box-shadow: 0 4px 14px rgba(16, 24, 40, .08); }
.action-item.danger { border-left-color: var(--danger); }
.action-item.warn { border-left-color: var(--warn); }
.action-item.ok { border-left-color: var(--success); }
.action-item .ai-label { font-size: 12px; color: var(--muted); }
.action-item .ai-value { font-size: 20px; font-weight: 600; margin-top: 3px; }
.action-item .ai-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
/* 可点击：右上角提示去处，悬停/聚焦显现；选中态留一个描边 */
.action-item { position: relative; }
.action-item .ai-go {
  position: absolute; top: 12px; right: 12px; font-size: 11px; color: var(--primary); font-weight: 400;
  opacity: 0; transform: translateX(-3px); transition: opacity .16s, transform .16s; white-space: nowrap;
}
.action-item:hover .ai-go, .action-item:focus-visible .ai-go { opacity: 1; transform: none; }
.action-item.active { box-shadow: 0 0 0 2px rgba(30, 72, 184, .12), 0 2px 10px rgba(16, 24, 40, .06); }
.action-item:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; }
@keyframes flashRing { 0% { box-shadow: 0 0 0 0 rgba(30, 72, 184, .3); } 100% { box-shadow: 0 0 0 12px rgba(30, 72, 184, 0); } }
.flash { animation: flashRing .8s ease-out 2; }

/* 待办条目 */
.todo-row {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px;
  border: 1px solid var(--border); margin-bottom: 7px; background: #fff; transition: all .15s;
}
.todo-row:hover { border-color: var(--primary); box-shadow: 0 2px 8px rgba(37, 99, 235, .08); }
.todo-row.overdue { border-left: 3px solid var(--danger); }
.todo-row.today { border-left: 3px solid var(--warn); }
.todo-row .tr-main { flex: 1; min-width: 0; }
.todo-row .tr-title { font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.todo-row .tr-sub { font-size: 12px; color: var(--muted); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.todo-row .tr-time { font-size: 11.5px; color: var(--muted); white-space: nowrap; }

/* 分组标题 */
.group-head {
  display: flex; align-items: center; gap: 8px; padding: 8px 2px; font-size: 12.5px;
  color: var(--text-2); font-weight: 500;
}
.group-head .badge-dot { width: 7px; height: 7px; border-radius: 50%; }
.group-head .g-count { font-size: 11.5px; color: var(--muted); font-weight: 400; }

/* ---------- 看板 ---------- */
.kanban { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 8px; align-items: flex-start; }
.kcol { background: #f7f8fa; border: 1px solid var(--border); border-radius: 10px; width: 268px; flex: none; }
.kcol-head { padding: 11px 13px; border-bottom: 1px solid var(--border); }
.kcol-title { font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 7px; }
.kcol-title .dotc { width: 7px; height: 7px; border-radius: 50%; }
.kcol-title .cnt { margin-left: auto; font-size: 11.5px; color: var(--muted); font-weight: 400; }
.kcol-sum { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.kcol-body { padding: 8px; min-height: 90px; display: flex; flex-direction: column; gap: 8px; }
.kcard {
  background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 11px 12px;
  cursor: pointer; transition: all .15s; box-shadow: var(--shadow);
}
.kcard:hover { border-color: var(--primary); box-shadow: 0 4px 12px rgba(37, 99, 235, .1); }
.kcard-top { display: flex; align-items: flex-start; gap: 6px; }
.kcard-title { font-size: 13px; font-weight: 500; line-height: 1.45; flex: 1; }
.kcard-amount { font-size: 15px; font-weight: 600; margin-top: 7px; letter-spacing: -.3px; }
.kcard-meta { display: flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 11.5px; color: var(--muted); flex-wrap: wrap; }
.kcard-stall { margin-top: 7px; font-size: 11.5px; color: #b45309; background: #fffaf1; border-radius: 5px; padding: 3px 7px; }
.kcard-stall.danger { color: #b91c1c; background: #fff5f5; }

/* ---------- 客户卡片 ---------- */
.cust-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px; }
.cust-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 15px;
  transition: all .15s; cursor: pointer;
}
.cust-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(37, 99, 235, .09); }
.cc-head { display: flex; align-items: flex-start; gap: 9px; }
.cc-name { font-size: 14px; font-weight: 600; }
.cc-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.cc-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 11px; padding-top: 10px; border-top: 1px dashed var(--border); }
.cc-stat { text-align: center; }
.cc-stat b { display: block; font-size: 13.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cc-stat span { font-size: 11px; color: var(--muted); }

/* ---------- 通话 ---------- */
.call-row {
  display: grid; grid-template-columns: 34px 1fr auto; gap: 11px; align-items: center;
  padding: 11px 13px; border-bottom: 1px solid #f0f1f4;
}
.call-row:last-child { border-bottom: none; }
.call-ico {
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  background: #eaf1ff; color: #1e48b8; font-size: 13px;
}
.call-ico.no { background: #f4f5f7; color: #868e9c; }
.call-ico.ok { background: #e9f7ee; color: #15803d; }
.call-dur { font-size: 13px; font-weight: 500; font-variant-numeric: tabular-nums; }
.call-sub { font-size: 11.5px; color: var(--muted); margin-top: 1px; }
.waveform { display: flex; align-items: center; gap: 2px; height: 16px; }
.waveform i { width: 2px; background: #c7d2fe; border-radius: 1px; }

/* ---------- 知识库 ---------- */
.kb-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; }
.kb-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 15px 16px;
  cursor: pointer; transition: all .15s; display: flex; flex-direction: column;
}
.kb-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(37, 99, 235, .09); }
.kb-card h4 { font-size: 14px; font-weight: 600; line-height: 1.5; margin-bottom: 6px; }
.kb-excerpt { font-size: 12.5px; color: var(--text-2); line-height: 1.7; flex: 1;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.kb-meta { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: 11.5px; color: var(--muted); }
.kb-body { font-size: 13.5px; line-height: 1.95; color: var(--text-2); white-space: pre-wrap; word-break: break-word; }

/* ---------- 审批链 ---------- */
.appr-chain { display: flex; flex-direction: column; gap: 0; }
.appr-step { display: flex; gap: 12px; position: relative; padding-bottom: 16px; }
.appr-step:last-child { padding-bottom: 0; }
.appr-step::before {
  content: ""; position: absolute; left: 13px; top: 28px; bottom: 0; width: 1px; background: var(--border);
}
.appr-step:last-child::before { display: none; }
.appr-avatar {
  width: 27px; height: 27px; border-radius: 50%; background: #f1f3f6; color: #5b636e;
  display: grid; place-items: center; font-size: 11px; flex: none; z-index: 1;
}
.appr-avatar.ok { background: #e9f7ee; color: #15803d; }
.appr-avatar.no { background: #fdeced; color: #b91c1c; }
.appr-avatar.cur { background: var(--primary); color: #fff; }
.appr-body { flex: 1; }
.appr-name { font-size: 12.5px; font-weight: 500; }
.appr-desc { font-size: 11.5px; color: var(--muted); margin-top: 2px; }

/* ---------- 空态/加载 ---------- */
.empty { text-align: center; padding: 46px 20px; color: var(--muted); }
.empty .big { font-size: 30px; opacity: .35; margin-bottom: 8px; }
.empty p { font-size: 13px; }
.empty .tip { font-size: 12px; margin-top: 5px; color: #a8aeb8; }
.loading-box { display: flex; align-items: center; justify-content: center; gap: 9px; padding: 50px; color: var(--muted); font-size: 13px; }

/* ---------- 详情页布局 ---------- */
.detail-grid { display: grid; grid-template-columns: 1fr 320px; gap: 14px; align-items: start; }
.detail-side { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 0; }
.breadcrumb { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); margin-bottom: 10px; }
.breadcrumb a { color: var(--primary); cursor: pointer; }
.detail-hero {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; margin-bottom: 14px;
}
.dh-top { display: flex; align-items: flex-start; gap: 13px; flex-wrap: wrap; }
.dh-name { font-size: 18px; font-weight: 600; }
.dh-sub { font-size: 12.5px; color: var(--muted); margin-top: 3px; display: flex; gap: 10px; flex-wrap: wrap; }
.dh-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.dh-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 9px; }

/* ---------- 表单网格 ---------- */
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 14px; }
.form-grid .full { grid-column: span 2; }
.form-grid.three { grid-template-columns: repeat(3, 1fr); }
.form-section { font-size: 12.5px; font-weight: 600; color: var(--text-2); margin: 4px 0 10px; padding-bottom: 6px; border-bottom: 1px solid var(--border); }
.form-grid .field { margin-bottom: 0; }

/* 业绩拆分行 */
.perf-row { display: grid; grid-template-columns: 1fr 100px 80px 76px 28px; gap: 8px; align-items: center; margin-bottom: 8px; }
.perf-row input, .perf-row select { padding: 6px 8px; font-size: 12.5px; }
.perf-sum { font-size: 12px; color: var(--text-2); }
.perf-sum.bad { color: var(--danger); }

/* ---------- 手机端 ---------- */
.only-m { display: none; }
@media (max-width: 980px) {
  .grid-2, .grid-3, .grid-2-1, .grid-1-2 { grid-template-columns: 1fr; }
  .detail-grid { grid-template-columns: 1fr; }
  .detail-side { position: static; }
  .stat-grid.c4, .stat-grid.c5, .stat-grid.c6 { grid-template-columns: repeat(2, 1fr); }
  .action-strip { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .only-m { display: inline-flex; }
  .hide-m { display: none !important; }
  .page-head { margin-bottom: 10px; }
  .ph-main h2 { font-size: 16px; }
  .ph-main p { display: none; }
  .stat-grid { gap: 8px; }
  .stat-grid.c3 { grid-template-columns: repeat(2, 1fr); }
  .stat { padding: 11px 12px; }
  .stat-value { font-size: 19px; }
  .stat-sub { font-size: 11px; }
  .form-grid, .form-grid.three { grid-template-columns: 1fr; }
  .form-grid .full { grid-column: span 1; }
  .kv-grid { grid-template-columns: 1fr; }
  .kv.wide { grid-column: span 1; }
  .cust-grid, .kb-grid { grid-template-columns: 1fr; }
  .fp-grid { grid-template-columns: repeat(2, 1fr); }
  .fp-item.wide { grid-column: span 2; }
  .perf-row { grid-template-columns: 1fr 1fr; }
  .drawer { width: 100vw; }
  .kanban { gap: 8px; }
  .kcol { width: 84vw; }
  .toolbar { gap: 6px; }
  .tb-search { max-width: none; flex: 1 1 100%; }
  .tb-right { margin-left: 0; flex-wrap: wrap; }
  .bulk-bar { flex-wrap: wrap; }
  /* 表格转卡片 */
  .table-wrap.card-mode table thead { display: none; }
  .table-wrap.card-mode tbody tr {
    display: block; border: 1px solid var(--border); border-radius: 9px; margin-bottom: 9px; padding: 10px 12px;
    background: #fff; position: relative;
  }
  .table-wrap.card-mode tbody td {
    display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; border: none;
    font-size: 12.5px; text-align: right;
  }
  .table-wrap.card-mode tbody td::before {
    content: attr(data-label); color: var(--muted); font-size: 12px; text-align: left; flex: none;
  }
  .table-wrap.card-mode tbody td:has(.row-main) { display: block;
    padding: 0 26px 9px 0; text-align: left; border-bottom: 1px dashed var(--border); margin-bottom: 4px;
  }
  .table-wrap.card-mode tbody td:has(.row-main)::before { display: none; }
  .table-wrap.card-mode tbody td.check-col { position: absolute; right: 10px; top: 12px; width: auto; padding: 0; }
  .table-wrap.card-mode tbody td.check-col::before { display: none; }
}

/* ---------------- 知识库阅读页 ---------------- */
.crumbs { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); margin-bottom: 12px; }
.crumbs a { color: var(--text-2); }
.crumbs a:hover { color: var(--primary); }
.crumbs i { font-style: normal; color: #c8ccd4; }

/* 长文阅读：总宽收在 1180（1920 屏不再拉成一整条 90 字宽的长行），侧栏跟随滚动，
   否则长文滚到下半屏时右栏早已见底，整块空白看着像没加载完。 */
.kb-read { display: grid; grid-template-columns: minmax(0, 1fr) 292px; gap: 14px; align-items: start;
  max-width: 1180px; margin: 0 auto; }
.kb-article { padding: 26px 30px 22px; }
.kb-head { border-bottom: 1px solid var(--border); padding-bottom: 16px; }
.kb-badges { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.kb-head h1 { font-size: 21px; line-height: 1.45; font-weight: 600; letter-spacing: -.2px; }
.kb-head .kb-meta { margin-top: 12px; }
.avatar-sm { width: 22px; height: 22px; font-size: 11px; }

.kb-article .kb-body { white-space: normal; margin-top: 18px; font-size: 14px; line-height: 1.95; color: #2b3445; }
.kb-article .kb-body p { margin: 0 0 11px; }
.kb-article .kb-h3 { font-size: 14.5px; font-weight: 600; color: var(--text); margin: 20px 0 9px; }
.kb-article .kb-li { padding-left: 4px; margin-bottom: 6px; }
.kb-article .kb-body blockquote {
  margin: 12px 0; padding: 12px 15px; background: #f6f8fc; border-left: 3px solid var(--primary);
  border-radius: 0 7px 7px 0; color: #3b4759; font-size: 13.5px; line-height: 1.85;
}
.kb-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 18px; }
.kb-tags .chip { cursor: default; font-size: 11.5px; }
.kb-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--border); }
.kb-actions .btn:first-child { min-width: 92px; }

.kb-side { display: flex; flex-direction: column; gap: 12px;
  position: sticky; top: 12px; align-self: start; }
/* 本文目录：长文右栏的导航，滚到哪节高亮哪条 */
.kb-toc-card .card-head { display: flex; align-items: center; justify-content: space-between; }
.kb-toc { display: flex; flex-direction: column; gap: 2px; padding: 6px 8px 10px;
  max-height: calc(100vh - 320px); overflow-y: auto; }
.kb-toc-i { display: block; width: 100%; text-align: left; background: none; border: 0; cursor: pointer;
  font: inherit; font-size: 12.5px; line-height: 1.5; color: var(--text-2); padding: 6px 9px;
  border-radius: 6px; border-left: 2px solid transparent; }
.kb-toc-i:hover { background: #f5f8ff; color: var(--text); }
.kb-toc-i.on { color: var(--primary); background: #eef4ff; border-left-color: var(--primary); font-weight: 500; }
.kb-author { display: flex; gap: 10px; align-items: center; padding: 14px 16px; }
.kb-author b { font-size: 13px; font-weight: 500; }
.kb-author p { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.kb-related { padding: 6px 8px 8px; }
.kb-rel-item { display: block; padding: 9px 8px; border-radius: 7px; }
.kb-rel-item:hover { background: #f5f8ff; }
.kb-rel-item b { display: block; font-size: 12.5px; font-weight: 500; line-height: 1.55; color: var(--text); }
.kb-rel-item span { font-size: 11px; color: var(--muted); }
.empty-mini { padding: 20px 16px; font-size: 12px; color: var(--muted); text-align: center; }

/* 知识库分享面板：文章码 + 销售微信码 + 复制链接 */
.kb-share { padding: 6px 0 4px; }
.kb-share-qr { display: flex; gap: 18px; justify-content: center; text-align: center; }
.kb-share-item { flex: 1; max-width: 170px; min-width: 0; }
.kb-share-box { display: flex; align-items: center; justify-content: center;
  width: 150px; height: 150px; margin: 0 auto; border: 1px solid var(--border);
  border-radius: 9px; background: #fff; overflow: hidden; }
.kb-share-item img.kb-share-box { object-fit: cover; }
.kb-share-box svg { width: 100%; height: auto; }
.kb-share-item p { font-size: 12px; color: var(--muted); margin: 8px 0 0; }
.kb-share-url { display: flex; gap: 8px; margin-top: 16px; }
.kb-share-url input { flex: 1; min-width: 0; font-size: 12px; color: var(--text-2); }

.btn-danger-ghost { color: #b91c1c; border-color: #f0cdcd; background: #fff; }
.btn-danger-ghost:hover { background: #fff5f5; border-color: #e5a3a3; }

/* 通用块间距 */
.stack-12 > * + * { margin-top: 12px; }
.row-gap { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.mt-12 { margin-top: 12px; }
.muted { color: var(--muted); }
.tiny { font-size: 11.5px; }

@media (max-width: 900px) {
  .kb-read { grid-template-columns: 1fr; }
  .kb-article { padding: 18px 16px 16px; }
  .kb-head h1 { font-size: 18px; }
}

/* ---------------- 表单字段（全站通用） ---------------- */
.fi { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.fi > span { font-size: 11.5px; color: var(--muted); }
.fi > input, .fi > select, .fi > textarea { width: 100%; }
.form-grid .span2 { grid-column: span 2; }
.form-tip { font-size: 11.5px; color: var(--muted); line-height: 1.7; background: #f7f9fc; border-radius: 6px; padding: 9px 11px; margin-top: 10px; }
.form-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border); }

/* 数字输入带单位 */
.input-unit { display: flex; align-items: center; gap: 6px; }
.input-unit input { flex: 1; }
.input-unit i { font-style: normal; font-size: 11.5px; color: var(--muted); flex: none; }
.input-unit.dual { gap: 4px; }
.input-unit.dual input { width: 58px; flex: none; }
.input-unit.sm input { width: 68px; padding: 5px 8px; font-size: 12.5px; }

/* ---------------- 统计行 / 列表行 ---------------- */
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
.stat-row.c5 { grid-template-columns: repeat(5, 1fr); }
.stat-row.c2 { grid-template-columns: repeat(2, 1fr); }

.list-body { padding: 4px 6px 8px; }
.list-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 10px; border-bottom: 1px solid #f1f3f7; }
.list-row:last-child { border-bottom: none; }
.list-row:hover { background: #f8fafd; }
.lr-main { min-width: 0; }
.lr-main b { display: block; font-size: 13px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lr-main span { font-size: 11.5px; color: var(--muted); }
.lr-side { text-align: right; flex: none; }
.lr-side b { display: block; font-size: 13px; }
.lr-side span { font-size: 11px; color: var(--muted); }

.text-danger { color: var(--danger) !important; }
.op-cell { white-space: nowrap; }
.op-cell .link { margin-right: 8px; font-size: 12px; }
.op-cell .link:last-child { margin-right: 0; }
.op-cell .link.danger { color: var(--danger); }
.tree-mark { color: #c3c9d4; margin-right: 4px; }
.sortable th[data-sort] { cursor: pointer; user-select: none; }
.sortable th[data-sort]:hover { color: var(--primary); }
.sortable th.sorted { color: var(--primary); }
/* 订单列表 10 列挤在 1020px 内容区，操作列被压到 51px 导致「详情」拆成两行单字（竖排）。
   固定操作列宽度并整列禁止折行，余下列自适应 */
.tbl-orders th:last-child, .tbl-orders td:last-child { width: 86px; white-space: nowrap; }
/* 数字与标签一律不许折行：宁可让能换行的「客户 / 业务组合」变窄，
   也不要出现「成本 ¥4,200 ·」换行把 65% 掉到第三行、或者「合同 / 缺凭证」竖着堆两行 */
.tbl-orders td.num, .tbl-orders td.num b, .tbl-orders td.num .cell-sub { white-space: nowrap; }
.tbl-orders td:nth-child(6), .tbl-orders td:nth-child(8) { white-space: nowrap; }
/* 客户名、业务组合是长文本重灾区：单行省略号，杜绝「常州精工模具有 / 限公司」这种孤字断行 */
.tbl-orders td:nth-child(2), .tbl-orders td:nth-child(3) { max-width: 0; }
.tbl-orders td:nth-child(2) > a,
.tbl-orders td:nth-child(2) > span,
.tbl-orders td:nth-child(3) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tbl-orders td:nth-child(2) .cell-sub,
.tbl-orders td:nth-child(3) .cell-sub { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 合计行必须继承表头/数据行的内边距，否则文字贴左、数字贴右，和上面几列对不齐
   （曾经只写了背景和边框，padding 为 0，订单详情「合计」整行错位） */
table tfoot td { background: #f8fafd; font-weight: 500; border-top: 1px solid var(--border); padding: 11px 12px; }
table.compact tfoot td { padding: 8px 10px; }
table tfoot td:first-child { border-radius: 0 0 0 8px; }
table tfoot td:last-child { border-radius: 0 0 8px 0; }

/* ---------------- 报表页 ---------------- */
/* 工作汇报 · 周期标题条 */
.rp-title { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.rp-title-main { display: flex; flex-direction: column; gap: 2px; }
.rp-title-main h3 { margin: 0; font-size: 17px; font-weight: 600; letter-spacing: .2px; }
.rp-title > .tag { margin-left: auto; }

/* 跟进页 · 待跟进日期筛选条 */
.due-bar-wrap {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 9px 12px; margin-bottom: 12px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 10px;
}
.db-label { font-size: 12.5px; color: var(--muted); font-weight: 500; }
.db-hint { margin-left: auto; font-size: 12px; color: var(--muted); }
@media (max-width: 640px) {
  .db-hint { margin-left: 0; width: 100%; }
}

/* 待跟进计划筛选条 */
.due-bar { flex-wrap: wrap; row-gap: 6px; }
.due-date {
  width: auto; padding: 4px 8px; font-size: 12.5px; line-height: 1.4;
  border: 1px solid var(--line); border-radius: 7px;
  background: var(--surface); color: var(--text);
}
.due-date:focus { outline: none; border-color: var(--pri); }
.due-range { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
/* 放在 source-bar 里时不要被通用 input 撑满整行 */
.source-bar .due-date { width: 132px; flex: 0 0 auto; }
@media (max-width: 640px) {
  .due-bar .sb-label { width: 100%; }
  .due-date { flex: 1 1 auto; min-width: 0; }
}

.rp-filter { margin-bottom: 12px; }
.rp-filter:empty { display: none; }
.rp-seg { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rp-month { width: auto; padding: 6px 10px; font-size: 12.5px; }

/* 时间维度筛选条 */
.range-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.range-bar input[type='date'] { width: auto; padding: 5px 8px; font-size: 12.5px; }
.rb-sep { font-size: 12px; color: var(--muted); }
.rp-donut { display: flex; justify-content: center; padding: 4px 0 10px; }
.rp-legend { display: flex; flex-direction: column; gap: 7px; margin-top: 4px; }
.rp-lg { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }
.rp-lg i { width: 8px; height: 8px; border-radius: 2px; flex: none; }
.rp-lg span { color: var(--text-2); }
.rp-lg b { margin-left: auto; }
.rp-lg em { font-style: normal; color: var(--muted); width: 40px; text-align: right; font-size: 11.5px; }
.rp-results { display: flex; flex-direction: column; gap: 11px; }
.rp-res-row { display: flex; align-items: center; gap: 10px; }
.rp-res-name { width: 78px; flex: none; font-size: 12.5px; color: var(--text-2); }
.rp-res-row .meter { flex: 1; }
.rp-res-row b { font-size: 12.5px; width: 34px; text-align: right; }
.rp-res-row em { font-style: normal; font-size: 11.5px; color: var(--muted); width: 34px; text-align: right; }

/* ---------------- 设置页 ---------------- */
.settings-layout { display: grid; grid-template-columns: 178px minmax(0, 1fr); gap: 14px; align-items: start; }
.set-nav { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 6px; box-shadow: var(--shadow); position: sticky; top: 12px; }
.set-nav-item {
  display: block; width: 100%; text-align: left; padding: 9px 12px; border: none; background: none;
  border-radius: 7px; font-size: 13px; color: var(--text-2); cursor: pointer; transition: background .15s, color .15s;
}
.set-nav-item:hover { background: #f5f8ff; color: var(--primary); }
.set-nav-item.on { background: #eef4ff; color: var(--primary); font-weight: 500; }
.set-body { min-width: 0; }
.set-body .card + .card { margin-top: 12px; }
.card-foot { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; border-top: 1px solid var(--border); }
.pager-foot { gap: 10px; }

/* 开关 */
.switch { display: inline-flex; cursor: pointer; }
.switch input { display: none; }
.switch i { width: 34px; height: 19px; border-radius: 10px; background: #dfe3ea; position: relative; transition: background .18s; }
.switch i::after {
  content: ''; position: absolute; top: 2px; left: 2px; width: 15px; height: 15px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .18); transition: transform .18s;
}
.switch input:checked + i { background: var(--primary); }
.switch input:checked + i::after { transform: translateX(15px); }

/* 审批流展示 */
.flow-row { display: flex; align-items: flex-start; gap: 14px; padding: 13px 14px; border-bottom: 1px solid #f1f3f7; }
.flow-row:last-child { border-bottom: none; }
.flow-main { flex: 1; min-width: 0; }
.flow-main > b { font-size: 13.5px; font-weight: 500; }
.flow-main > span { font-size: 11.5px; color: var(--muted); margin-left: 8px; }
.flow-steps { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 9px; }
.flow-step { display: inline-flex; align-items: center; gap: 5px; background: #f4f7fd; border: 1px solid #e3ebf8; border-radius: 20px; padding: 3px 10px 3px 4px; font-size: 11.5px; color: var(--text-2); }
.flow-step i { width: 17px; height: 17px; border-radius: 50%; background: var(--primary); color: #fff; font-style: normal; font-size: 10px; display: inline-flex; align-items: center; justify-content: center; }
.flow-step em { font-style: normal; color: var(--muted); font-size: 11px; }
.flow-step u { text-decoration: none; background: #fdf3e3; color: #b45309; border-radius: 4px; padding: 0 4px; font-size: 10px; }
.flow-arrow { color: #c3c9d4; font-size: 11px; }

/* 审批流编辑 */
.flow-editor { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 12px; }
.fe-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.fe-head b { font-size: 12.5px; }
.fe-row { display: grid; grid-template-columns: 22px 1fr 82px 1.4fr 26px; gap: 8px; align-items: center; margin-bottom: 8px; }
.fe-idx { width: 22px; height: 22px; border-radius: 50%; background: #eef4ff; color: var(--primary); font-size: 11px; display: inline-flex; align-items: center; justify-content: center; }
.fe-row input[name=step_name] { padding: 6px 9px; font-size: 12.5px; }
.fe-row select { padding: 6px 6px; font-size: 12px; }
.approver-pick { display: flex; flex-wrap: wrap; gap: 4px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 4px 6px; max-height: 62px; overflow-y: auto; }
.pick { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; background: #f4f7fd; border-radius: 4px; padding: 2px 6px; cursor: pointer; }
.pick input { display: none; }
.pick:has(input:checked) { background: #e3edff; color: var(--primary); font-weight: 500; }

/* 申诉与系统信息 */
.dispute-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-bottom: 1px solid #f1f3f7; }
.dr-main { flex: 1; min-width: 0; }
.dr-main b { font-size: 13px; font-weight: 500; }
.dr-main span { display: block; font-size: 11px; color: var(--muted); margin-top: 2px; }
.dr-main p { font-size: 12px; color: var(--text-2); margin-top: 5px; }
.dr-actions { display: flex; gap: 8px; flex: none; }
.sys-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.sys-item { background: #f8fafd; border: 1px solid #eef1f6; border-radius: 8px; padding: 11px 13px; }
.sys-item span { display: block; font-size: 11.5px; color: var(--muted); }
.sys-item b { display: block; font-size: 15px; margin-top: 3px; }
.sys-item em { font-style: normal; font-size: 11px; color: var(--muted); }

@media (max-width: 1100px) {
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .settings-layout { grid-template-columns: 1fr; }
  .set-nav { display: flex; gap: 4px; overflow-x: auto; position: static; padding: 8px; }
  .set-nav-item { width: auto; white-space: nowrap; }
  .sys-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .stat-row { grid-template-columns: 1fr 1fr; gap: 8px; }
  .form-grid .span2, .form-grid .full { grid-column: span 1; }
  .fe-row { grid-template-columns: 22px 1fr 26px; row-gap: 6px; }
  .fe-row select, .fe-row .approver-pick { grid-column: 2 / 4; }
  .flow-row { flex-direction: column; }
  .dispute-row { flex-direction: column; align-items: flex-start; }
  .rp-res-name { width: 66px; }
  .sys-grid { grid-template-columns: 1fr 1fr; }
}

/* ---------------- 线索详情：商机 / 通话 ---------------- */
.opp-mini { display: flex; flex-direction: column; gap: 8px; }
.opp-mini > b { font-size: 13px; font-weight: 500; }
.opp-mini-row { display: flex; align-items: center; justify-content: space-between; font-size: 12px; color: var(--text-2); }
.opp-mini-row > span { color: var(--muted); }

.call-mini { display: flex; align-items: center; gap: 10px; padding: 8px 14px; border-bottom: 1px solid #f2f4f8; }
.call-mini:last-child { border-bottom: none; }
.cm-ico {
  width: 26px; height: 26px; border-radius: 50%; flex: none; display: inline-flex; align-items: center;
  justify-content: center; font-size: 13px;
}
.cm-ico.ok { background: #e7f6ef; color: #14804a; }
.cm-ico.miss { background: #fdeeee; color: #c0392b; }
.cm-main { flex: 1; min-width: 0; }
.cm-title { font-size: 12.5px; display: flex; align-items: center; gap: 6px; }
.cm-sub { font-size: 11px; color: var(--muted); margin-top: 2px; }

/* ---------- 定义列表（dt/dd） ---------- */
dl.kv-dl { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 11px 14px; margin: 0; align-items: baseline; }
dl.kv-dl dt { font-size: 12px; color: var(--muted); }
dl.kv-dl dd { margin: 0; font-size: 13px; color: var(--text); word-break: break-word; }
dl.kv-dl.cols-2 { grid-template-columns: 64px minmax(0, 1fr) 64px minmax(0, 1fr); gap: 13px 22px; }
@media (max-width: 720px) { dl.kv-dl.cols-2 { grid-template-columns: 64px minmax(0, 1fr); } }

/* ---------------- 订单：多业务组合选择 ---------------- */
.type-picker { display: flex; flex-direction: column; gap: 12px; }
.type-group { display: flex; flex-direction: column; gap: 6px; }
.type-group-h {
  display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; color: var(--text-2);
}
.type-group-h::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.type-group-h .tg-count { font-weight: 400; color: var(--muted); }
.type-group-body { display: flex; flex-wrap: wrap; gap: 8px; }
.type-chip {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 118px;
  padding: 8px 12px; border: 1px solid var(--border); border-radius: 8px; background: #fff;
  cursor: pointer; text-align: left; transition: .15s;
}
.type-chip:hover { border-color: #bcd0f7; background: #fafcff; }
.type-chip.on { border-color: var(--primary); background: #eff5ff; box-shadow: 0 0 0 2px rgba(37,99,235,.08); }
.type-chip .tc-name { font-size: 13px; font-weight: 500; color: var(--text); }
.type-chip .tc-cost { font-size: 11px; color: var(--muted); }
.type-chip.on .tc-cost { color: #3b6fd4; }

.calc-box {
  margin-top: 14px; background: #f7f9fc; border: 1px solid var(--border);
  border-radius: 10px; padding: 12px 14px;
}
.calc-row { display: flex; align-items: center; justify-content: space-between; font-size: 13px; color: var(--text-2); padding: 5px 0; }
.calc-row b { font-weight: 500; color: var(--text); font-size: 14px; }
.calc-row.big { border-top: 1px dashed var(--border); margin-top: 4px; padding-top: 9px; }
.calc-row.big b { font-size: 18px; color: var(--primary); }
.calc-tip { font-size: 12px; margin-top: 6px; }
.alloc-wrap { display: block; }
.alloc-title { font-size: 12px; color: var(--muted); margin: 6px 0 5px; }
.alloc-rows { display: flex; flex-direction: column; gap: 6px; }
.alloc-row { display: flex; align-items: center; gap: 8px; }
.alloc-row .ar-name { font-size: 12.5px; min-width: 78px; }
.alloc-row .ar-cost { font-size: 11.5px; color: var(--muted); flex: 1; }
.alloc-row .ar-amt { width: 130px; padding: 5px 8px; font-size: 12.5px; }

/* ---------------- 新线索弹窗提醒 ---------------- */
.lead-alert { width: 560px; max-width: calc(100vw - 28px); }
.la-row { display: flex; align-items: center; gap: 8px; padding: 11px 0; border-bottom: 1px solid var(--border); }
.la-row:last-child { border-bottom: none; }
.la-main { flex: 1; min-width: 0; }
.la-name { font-size: 13.5px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.la-sub { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.nav-badge.red { background: var(--danger); }
tr.row-danger td { background: #fff9f9; }

/* ---------------- 通话分析：时长 / 风控 ---------------- */
.risk-row { display: flex; gap: 10px; padding: 12px 16px; border-bottom: 1px solid #f3f5f8; }
.risk-row:last-child { border-bottom: none; }
.risk-flag { width: 4px; border-radius: 3px; flex: none; }
.risk-flag.l3 { background: #dc2626; }
.risk-flag.l2 { background: #d97706; }
.risk-flag.l1 { background: #94a3b8; }
.risk-body { flex: 1; min-width: 0; }
.risk-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.risk-snippet { font-size: 12.5px; color: var(--text-2); background: #fafbfc; border-left: 2px solid var(--border); padding: 6px 9px; margin-top: 6px; border-radius: 0 6px 6px 0; }
.slot-table td { font-variant-numeric: tabular-nums; }

.risk-acts { display: flex; align-items: center; gap: 6px; flex: none; padding-left: 10px; }
.risk-acts .btn { white-space: nowrap; }

/* ---------------- 提醒清单 / 续费服务 ---------------- */
.alert-list { display: flex; flex-direction: column; }
.alert-row { padding: 10px 14px; border-bottom: 1px solid #f3f5f8; }
.alert-row:last-child { border-bottom: none; }
.alert-row:hover { background: #fafbfc; }
tr.row-active td { background: #eef5ff; }

/* ---------------- 业务类型自定义字段 ---------------- */
.ftype-card { border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; margin-bottom: 10px; background: #fff; }
.ftype-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ftype-name { font-size: 13.5px; font-weight: 500; }
.ftype-meta { font-size: 12px; color: var(--muted); margin-top: 5px; line-height: 1.7; }
.field-row { display: grid; grid-template-columns: 1.2fr 1fr 1fr .8fr 28px; gap: 6px; margin-bottom: 6px; }
.field-row input, .field-row select { padding: 5px 8px; font-size: 12.5px; }
.field-del { border: none; background: transparent; color: var(--muted); cursor: pointer; font-size: 16px; line-height: 1; }
.field-del:hover { color: var(--danger); }

/* ---------------- 子账号权限勾选 ---------------- */
.perm-group { margin-bottom: 12px; }
.perm-group-title { font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.perm-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px 10px; }
.perm-item { display: flex; align-items: center; gap: 6px; font-size: 12.5px; padding: 5px 8px; border: 1px solid var(--border); border-radius: 7px; cursor: pointer; }
.perm-item.on { border-color: var(--primary); background: var(--primary-soft); color: var(--primary); }
.perm-item input { margin: 0; }

/* ---------------- 平台运营 ---------------- */
.tenant-card { border: 1px solid var(--border); border-radius: 10px; padding: 14px; background: #fff; }
.tenant-card .t-name { font-size: 14px; font-weight: 500; }
.tenant-card .t-meta { font-size: 12px; color: var(--muted); margin-top: 4px; line-height: 1.8; }
.plan-badge { font-size: 11px; padding: 1px 7px; border-radius: 20px; background: var(--primary-soft); color: var(--primary); }
.plan-badge.pro { background: #eef7f3; color: #0f766e; }
.plan-badge.enterprise { background: #fdf3e7; color: #b45309; }
.plan-badge.trial { background: #f4f5f7; color: var(--muted); }
.plan-badge.purple { background: #f0edff; color: #5b46d6; }
.plan-badge.green { background: #eef7f3; color: #0f766e; }
.plan-badge.gold { background: #fdf3e7; color: #b45309; }
.plan-badge.gray { background: #f4f5f7; color: var(--muted); }

@media (max-width: 720px) {
  .perm-grid { grid-template-columns: repeat(2, 1fr); }
  .field-row { grid-template-columns: 1fr 1fr 24px; }
}

/* ---------------- 成交分析：组合筛选面板 ---------------- */
.filter-block { margin-bottom: 12px; }
.filter-block:last-child { margin-bottom: 0; }
.fb-title { font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.chip-wrap { display: flex; flex-wrap: wrap; gap: 6px; }
.fchip { border: 1px solid var(--border); background: #fff; border-radius: 20px; padding: 3px 11px; font-size: 12px; color: var(--text-2); cursor: pointer; }
.fchip:hover { border-color: var(--primary); color: var(--primary); }
.fchip.on { background: var(--primary-soft); border-color: var(--primary); color: var(--primary); font-weight: 500; }
.fin { border: 1px solid var(--border); border-radius: 7px; padding: 5px 9px; font-size: 12.5px; outline: none; }
.fin:focus { border-color: var(--primary); }

/* ---------------- 下单：多业务计量与自定义字段 ---------------- */
.alloc-row-wrap { border-bottom: 1px dashed #eef1f5; padding-bottom: 8px; }
.alloc-row-wrap:last-child { border-bottom: none; }
.alloc-extra { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px 10px; margin: 4px 0 0 0; }
.alloc-extra label { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--muted); }
.alloc-extra input, .alloc-extra select { flex: 1; padding: 4px 7px; font-size: 12px; min-width: 0; }
@media (max-width: 720px) { .alloc-extra { grid-template-columns: 1fr 1fr; } }

/* ================= V1.3 新增页面样式 ================= */

/* ---------- 通用小工具 ---------- */
.sec-t { font-size: 12px; color: var(--muted); margin: 12px 0 7px; font-weight: 500; }
.num-list { margin: 0; padding-left: 18px; font-size: 12.5px; color: var(--text-2); line-height: 1.9; }
.dot-list { margin: 0; padding-left: 0; list-style: none; font-size: 12.5px; color: var(--text-2); line-height: 1.85; }
.dot-list li { position: relative; padding-left: 13px; }
.dot-list li::before { content: ''; position: absolute; left: 2px; top: 8px; width: 4px; height: 4px; border-radius: 50%; background: var(--border-strong); }
/* 风险/预警类清单：圆点换成红，扫一眼能分出来。
   注意别再写 <ul class="dot">：.dot 在 app.css 里是 6×6 的圆点图标，会把整个列表缩成一个点 */
.dot-list.warn li, .dot-list.warn li::before { color: var(--danger); }
.dot-list.warn li::before { background: var(--danger); }
.meter-mini { height: 5px; border-radius: 3px; background: #eef0f4; overflow: hidden; margin-top: 5px; }
.meter-mini i { display: block; height: 100%; border-radius: 3px; background: var(--primary); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.two-col-12 { display: grid; grid-template-columns: 1.25fr 1fr; gap: 14px; }
.two-col-11 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.score-pill { display: inline-block; min-width: 30px; text-align: center; padding: 1px 7px; border-radius: 20px; font-size: 12px; font-weight: 600; }
.score-pill.good { background: var(--success-soft); color: var(--success); }
.score-pill.mid { background: var(--warn-soft); color: var(--warn); }
.score-pill.bad { background: var(--danger-soft); color: var(--danger); }
.toolbar-inline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }

/* ---------- 培训考核 ---------- */
.task-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(330px, 1fr)); gap: 12px; }
.task-card { border: 1px solid var(--border); border-radius: 11px; padding: 13px 15px; background: #fff; cursor: pointer; transition: .15s; }
.task-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(37, 99, 235, .08); transform: translateY(-1px); }
.tc-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.tc-title { font-size: 14px; font-weight: 500; line-height: 1.5; }
.tc-meta { font-size: 11.5px; color: var(--muted); margin-top: 5px; display: flex; flex-wrap: wrap; gap: 4px 10px; }
.tc-score { text-align: right; font-size: 11px; color: var(--muted); white-space: nowrap; }
.tc-score b { display: block; font-size: 20px; font-weight: 600; color: var(--primary); line-height: 1.2; }
.tc-score.pass b { color: var(--success); }
.tc-score.fail b { color: var(--danger); }
.tc-foot { margin-top: 10px; padding-top: 9px; border-top: 1px dashed var(--border); display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11.5px; color: var(--muted); }

/* ---- 学习计划（计划包）---- */
.progress { height: 6px; border-radius: 3px; background: #eef1f6; overflow: hidden; }
.progress > i { display: block; height: 100%; background: linear-gradient(90deg, #2563eb, #22b573); border-radius: 3px; }
.progress > .bar { display: block; height: 100%; background: linear-gradient(90deg, #2563eb, #22b573); border-radius: 3px; }
.plan-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.plan-card { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: #fff; cursor: pointer; transition: .15s; }
.plan-card:hover { border-color: var(--primary); box-shadow: 0 6px 18px rgba(37, 99, 235, .1); transform: translateY(-2px); }
.pc-cover { position: relative; padding: 18px 16px 16px; color: #fff; min-height: 88px; display: flex; flex-direction: column; justify-content: flex-end; }
.pc-flag { position: absolute; top: 10px; right: 10px; font-size: 10.5px; padding: 2px 8px; border-radius: 99px; background: rgba(255,255,255,.22); }
.pc-title { font-size: 15px; font-weight: 600; line-height: 1.4; }
.pc-body { padding: 12px 14px 13px; }
.pc-meta { display: flex; align-items: center; gap: 8px; }
.pc-body .progress { margin-top: 8px; }
.plan-detail-head { padding: 18px 18px 15px; color: #fff; border-radius: 11px; margin-bottom: 14px; }
.pdh-title { font-size: 17px; font-weight: 600; }
.pdh-intro { font-size: 12px; opacity: .92; margin-top: 6px; line-height: 1.6; }
.pdh-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 11.5px; opacity: .95; margin-top: 10px; }
.pdh-meta .tag { color: #fff; background: rgba(255,255,255,.22); }
.plan-detail-head .progress { margin-top: 12px; }
.plan-detail-head .progress.light { background: rgba(255,255,255,.25); }
.plan-detail-head .progress.light .bar { background: #fff; }
.plan-detail-head .tiny { margin-top: 6px; opacity: .9; }
.node-list { display: flex; flex-direction: column; gap: 10px; }
.node-item { display: flex; gap: 12px; align-items: flex-start; padding: 11px 13px; border: 1px solid var(--border); border-radius: 10px; background: #fff; }
.node-item.locked { opacity: .55; background: #fafbfc; }
.node-item.done { border-color: #d3eadc; background: #f6fcf8; }
.ni-num { flex: 0 0 auto; width: 26px; height: 26px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-size: 12.5px; font-weight: 600; display: flex; align-items: center; justify-content: center; margin-top: 1px; }
.node-item.done .ni-num { background: var(--success); color: #fff; }
.node-item.locked .ni-num { background: #eef1f6; color: var(--muted); }
.ni-title { font-size: 13.5px; font-weight: 500; line-height: 1.5; }
.ni-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; margin-top: 4px; font-size: 11.5px; color: var(--muted); }
.board-nodes { display: flex; flex-wrap: wrap; gap: 6px; }
.plan-node-pick { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.pnode-row { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border: 1px solid var(--border); border-radius: 8px; background: #fafbfc; }
.pnode-idx { flex: 0 0 auto; width: 20px; height: 20px; border-radius: 5px; background: var(--primary); color: #fff; font-size: 11px; display: inline-flex; align-items: center; justify-content: center; font-weight: 600; }
.pnode-name { flex: 0 0 40%; }


.exam-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 15px; background: var(--primary-soft); border: 1px solid #dbe6ff; border-radius: 9px; margin-bottom: 14px; }
.exam-head b { font-size: 13.5px; }
.exam-timer { font-family: ui-monospace, Menlo, monospace; font-size: 15px; font-weight: 600; color: var(--primary); }
.exam-body .q-item { border-bottom: 1px solid #f1f3f6; padding: 14px 0; }
.exam-body .q-item:last-child { border-bottom: none; }
.q-stem { font-size: 13.5px; line-height: 1.7; margin-bottom: 9px; display: flex; gap: 7px; }
.q-no { flex: 0 0 auto; width: 20px; height: 20px; border-radius: 5px; background: var(--primary-soft); color: var(--primary); font-size: 11.5px; display: inline-flex; align-items: center; justify-content: center; font-weight: 600; margin-top: 1px; }
.q-opts { display: flex; flex-direction: column; gap: 6px; padding-left: 27px; }
.q-opt { display: flex; align-items: flex-start; gap: 7px; font-size: 12.5px; color: var(--text-2); padding: 6px 10px; border: 1px solid var(--border); border-radius: 7px; cursor: pointer; }
.q-opt:hover { border-color: var(--primary); background: #fafcff; }
.q-opt:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); color: var(--primary); }
.q-opt input { margin: 2px 0 0; }
.q-preview { border: 1px solid var(--border); border-radius: 9px; padding: 11px 13px; margin-bottom: 9px; background: #fcfdfe; }
.qp-stem { font-size: 13px; line-height: 1.65; margin-bottom: 6px; }
.qp-ans { font-size: 12px; color: var(--success); }
.q-blank { border-bottom: 1px solid var(--border-strong); display: inline-block; min-width: 70px; }

.score-hero { display: flex; align-items: center; gap: 18px; padding: 16px 18px; border-radius: 11px; background: linear-gradient(120deg, #f4f8ff, #eef4ff); border: 1px solid #dbe6ff; margin-bottom: 14px; }
.sh-num { font-size: 40px; font-weight: 700; line-height: 1; color: var(--primary); }
.sh-sub { font-size: 12.5px; color: var(--text-2); line-height: 1.8; }
.dim-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.dim-item { font-size: 11.5px; color: var(--muted); }
.dim-item b { float: right; color: var(--text); font-size: 12px; }

.gen-box { border: 1px dashed var(--border-strong); border-radius: 9px; padding: 12px 14px; background: #fcfdff; }
.gen-row { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-bottom: 8px; }
/* 微信绑定方式二选一：企业微信 / 个人微信 */
.wx-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.wx-opt { text-align: left; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px;
  background: #fff; cursor: pointer; transition: .15s; }
.wx-opt b { display: block; font-size: 13.5px; color: var(--text); }
.wx-opt span { display: block; font-size: 11.5px; color: var(--muted); margin-top: 3px; line-height: 1.5; }
.wx-opt:hover { border-color: #c7d2fe; }
.wx-opt.on { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 5%, #fff);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--primary) 14%, transparent); }
.wx-pane.hide { display: none; }
.wrong-list { display: flex; flex-direction: column; gap: 8px; }
.wrong-item { border: 1px solid var(--danger-soft); background: #fffafa; border-radius: 8px; padding: 9px 12px; font-size: 12.5px; line-height: 1.7; }

/* ---------- AI 主管 ---------- */
.ab-hero { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 20px; align-items: center; padding: 18px 20px; border-radius: 12px; background: linear-gradient(125deg, #f2f6ff 0%, #f7f9ff 45%, #eef7f3 100%); border: 1px solid #e2eaf8; margin-bottom: 14px; }
.ab-score { text-align: center; min-width: 0; }
.ab-score b { display: block; font-size: 46px; font-weight: 700; line-height: 1; color: var(--primary); }
.ab-score span { font-size: 12px; color: var(--muted); }
.ab-score-note { font-size: 11.5px; color: var(--text-2); margin-top: 7px; line-height: 1.7; word-break: break-word; }
.ab-dims { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 9px 16px; }
.ab-dim { font-size: 11.5px; color: var(--muted); }
.abd-top { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; }
.abd-top b { font-size: 13px; color: var(--text); }
.abd-top b i { font-size: 10.5px; color: var(--muted); font-style: normal; font-weight: 400; }
.period-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.plan-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.plan-body { font-size: 12.5px; }
.plan-list { margin: 0; padding-left: 0; list-style: none; counter-reset: p; }
.plan-list li { display: flex; gap: 9px; padding: 8px 0; border-bottom: 1px dashed #f0f2f5; line-height: 1.75; color: var(--text-2); }
.plan-list li:last-child { border-bottom: none; }
.plan-list .pn { flex: 0 0 19px; height: 19px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-size: 11px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; margin-top: 2px; }
.issue-list { display: flex; flex-direction: column; gap: 9px; }
.issue-list > div { border: 1px solid var(--border); border-radius: 9px; padding: 10px 13px; }
.ii-head { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; flex-wrap: wrap; }
.ii-detail { font-size: 12px; color: var(--text-2); line-height: 1.75; margin-top: 5px; }
.ii-sug { font-size: 12px; color: var(--text-2); line-height: 1.75; margin-top: 6px; padding: 7px 10px; background: #f8fafc; border-radius: 7px; }
.ii-label { display: inline-block; font-size: 10.5px; color: var(--primary); background: var(--primary-soft); padding: 1px 6px; border-radius: 4px; margin-right: 6px; }
.learn-item { padding: 10px 0; border-bottom: 1px dashed #f0f2f5; }
.learn-item:last-child { border-bottom: none; }
.li-topic { font-size: 13px; font-weight: 500; }
.li-reason { font-size: 12px; color: var(--muted); line-height: 1.7; margin: 4px 0; }
.li-action { font-size: 12px; color: var(--primary); }

/* ---------- 工作汇报 ---------- */
.report-list { display: flex; flex-direction: column; gap: 10px; }
.report-card { border: 1px solid var(--border); border-radius: 10px; padding: 13px 15px; background: #fff; cursor: pointer; transition: .15s; }
.report-card:hover { border-color: var(--primary); background: #fbfcff; }
.rc-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.rc-body { font-size: 12.5px; color: var(--text-2); line-height: 1.8; margin: 7px 0; white-space: pre-line; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.rc-foot { font-size: 11.5px; color: var(--muted); display: flex; gap: 12px; flex-wrap: wrap; }
.report-content { font-size: 13px; line-height: 1.9; color: var(--text-2); white-space: pre-wrap; }
.rp-text { font-size: 13px; line-height: 1.9; letter-spacing: .2px; }
/* 汇报正文：按板块分行，行距与内边距放宽，避免整段挤成一片 */
.report-text {
  font-size: 13px; line-height: 2.1; letter-spacing: .2px; color: var(--text-2);
  padding: 14px 16px; min-height: 220px; background: #fcfdff;
  border-radius: var(--radius-sm); white-space: pre-wrap;
}
.tl-time { font-size: 11px; color: var(--muted); }
.tl-text { font-size: 12.5px; color: var(--text-2); line-height: 1.7; margin-top: 2px; }

/* ---------- 外出拜访 ---------- */
.visit-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 12px; }
.visit-card { border: 1px solid var(--border); border-radius: 11px; padding: 13px 15px; background: #fff; cursor: pointer; transition: .15s; }
.visit-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(37, 99, 235, .08); }
.vc-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.vc-title { font-size: 13.5px; font-weight: 500; }
.vc-sub { font-size: 11.5px; color: var(--muted); margin-top: 4px; }
.vc-score { text-align: right; white-space: nowrap; }
.vc-score b { font-size: 21px; color: var(--primary); font-weight: 600; }
.vc-score span { font-size: 10.5px; color: var(--muted); margin-left: 2px; }
.vc-body { font-size: 12px; color: var(--text-2); line-height: 1.75; margin: 8px 0; }
.vc-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 11px; color: var(--muted); padding-top: 8px; border-top: 1px dashed var(--border); }
.kv-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px 14px; font-size: 12.5px; }
.kv-grid > div span { color: var(--muted); }
.kv-grid > div b { font-weight: 500; }

/* 客户档案：分组标题 + 缺项提示 */
.pf-sub { font-size: 11px; font-weight: 600; color: var(--muted); letter-spacing: .3px; margin: 12px 0 7px; padding-left: 7px; border-left: 3px solid var(--primary); line-height: 1; }
.pf-sub:first-child { margin-top: 0; }
.pf-gap { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 11.5px; line-height: 1.7;
  margin-top: 12px; padding: 8px 10px; border-radius: 7px; background: #fff7ed; border: 1px solid #fde3c0; color: #92400e; }
.pf-gap.ok { background: #f0fdf4; border-color: #bbf7d0; color: #15803d; }
.pf-gap .btn-text { margin-left: auto; color: #b45309; font-weight: 600; white-space: nowrap; }

/* ---------- 团队看板 ---------- */
.board-hero { display: grid; grid-template-columns: 160px 1fr; gap: 18px; align-items: center; padding: 16px 18px; border-radius: 12px; background: linear-gradient(120deg, #f5f8ff, #f2f9f5); border: 1px solid #e4ecf7; margin-bottom: 14px; }
.bh-left { display: flex; justify-content: center; }
.bh-right { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px 14px; }
.bh-kpi { background: rgba(255, 255, 255, .72); border: 1px solid #e8eef8; border-radius: 8px; padding: 8px 11px; }
.bh-kpi span { display: block; font-size: 11px; color: var(--muted); }
.bh-kpi b { font-size: 16px; font-weight: 600; }
.bh-kpi i { font-size: 10.5px; color: var(--muted); font-style: normal; margin-left: 3px; }
.team-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.team-table th { text-align: left; font-weight: 500; font-size: 11.5px; color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--border); background: #fafbfc; white-space: nowrap; }
.team-table td { padding: 8px 10px; border-bottom: 1px solid #f4f6f8; white-space: nowrap; }
.team-table tfoot td { background: #fafbfc; border-top: 1px solid var(--border); font-weight: 500; }
.team-table .num { text-align: right; }

/* ---------- 线索分区：盲打 / 分类 ---------- */
.blind-card { border: 1px solid var(--border); border-radius: 12px; padding: 18px; background: #fcfdff; text-align: center; }
.bc-idx { font-size: 11.5px; color: var(--muted); }
.bc-name { font-size: 17px; font-weight: 600; margin: 9px 0 3px; }
.bc-sub { font-size: 12px; color: var(--muted); }
.bc-phone { font-family: ui-monospace, Menlo, monospace; font-size: 25px; letter-spacing: 1px; color: var(--primary); margin: 14px 0; font-weight: 600; }
.bc-actions { display: flex; gap: 9px; justify-content: center; margin-bottom: 10px; }
.bc-tip { font-size: 11.5px; color: var(--muted); line-height: 1.7; margin-bottom: 12px; }
.bc-results { display: flex; flex-direction: column; gap: 7px; }
.cat-row { display: flex; align-items: center; gap: 9px; padding: 7px 0; border-bottom: 1px solid #f4f6f8; }
.cat-row input { flex: 1; border: 1px solid var(--border); border-radius: 7px; padding: 5px 9px; font-size: 12.5px; }

@media (max-width: 900px) {
  .two-col, .two-col-11, .two-col-12 { grid-template-columns: 1fr; }
  .ab-hero, .board-hero { grid-template-columns: 1fr; }
  .ab-dims { grid-template-columns: repeat(2, 1fr); }
  .bh-right { grid-template-columns: repeat(2, 1fr); }
  .kv-grid { grid-template-columns: 1fr; }
}

/* AI 主管评分区（V1.3 调整） */
.ab-main { min-width: 0; }
.ab-hero-note { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.ab-hero-note b { font-size: 13.5px; font-weight: 600; color: var(--text); }
.ab-hero .ring-label { margin-top: 4px; }

/* 工具条内的紧凑筛选控件 */
.toolbar-inline .fin { width: auto; min-width: 118px; }
.toolbar-inline input[type="date"], .toolbar-inline input[type="month"] { width: 148px; }

/* 金额区间分布：三段式行 */
.rank-row.bucket-row { grid-template-columns: 96px 1fr 92px; }

/* 团队排行条 */
.rank-list { display: flex; flex-direction: column; gap: 9px; padding: 4px 0 2px; }
.rank-row { display: grid; grid-template-columns: 18px 62px 1fr 84px; align-items: center; gap: 8px; }
.rk-idx { width: 18px; height: 18px; border-radius: 5px; background: #f2f4f7; color: var(--muted);
  font-size: 10.5px; display: flex; align-items: center; justify-content: center; }
.rk-idx.top { background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.rk-name { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rk-track { height: 8px; border-radius: 5px; background: #f1f3f7; overflow: hidden; }
.rk-track i { display: block; height: 100%; border-radius: 5px; }
.rk-val { font-size: 12px; text-align: right; color: var(--text-2); font-variant-numeric: tabular-nums; }

/* AI 主管：指标条更宽松，避免挤成一行 */
.ab-hero { grid-template-columns: 168px minmax(0, 1fr); column-gap: 22px; }
.ab-dims { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 22px; }
.ab-dim .meter-mini { margin-top: 7px; }
@media (max-width: 1180px) { .ab-dims { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* AI 主管：维度得分卡片 */
.ab-dim { background: rgba(255,255,255,.7); border: 1px solid #e8eef8; border-radius: 9px; padding: 9px 11px; }
.abd-top b.dim-score { font-size: 15px; font-weight: 600; }
.abd-top b.dim-score.good { color: var(--success); }
.abd-top b.dim-score.mid { color: var(--warning); }
.abd-top b.dim-score.bad { color: var(--danger); }
.dim-bar { height: 5px; border-radius: 3px; background: #eef1f6; overflow: hidden; margin: 7px 0 5px; }
.dim-bar i { display: block; height: 100%; border-radius: 3px; }
.dim-bar i.good { background: var(--success); }
.dim-bar i.mid { background: var(--warning); }
.dim-bar i.bad { background: var(--danger); }
.dim-pct { font-size: 10.5px; color: var(--muted); }

/* AI 主管：核查指标卡
 * 三列铺开，卡内固定四层（指标名 / 数值 / 进度 / 脚注），
 * 避免指标一多就被 auto-fit 挤成一条窄缝、文字贴着边框。 */
.ab-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 14px 0; }
.ab-m {
  display: flex; flex-direction: column; min-height: 120px;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 13px 16px 12px; box-shadow: var(--shadow);
}
.abm-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 18px; }
.abm-name { font-size: 12.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.abm-tag { flex: 0 0 auto; font-size: 11px; line-height: 18px; padding: 0 7px; border-radius: 9px; white-space: nowrap; }
.abm-tag.ok { background: rgba(22, 163, 74, .1); color: var(--success); }
.abm-tag.miss { background: rgba(220, 38, 38, .09); color: var(--danger); }
.abm-val { font-size: 24px; font-weight: 600; letter-spacing: -.4px; margin-top: 7px; font-variant-numeric: tabular-nums; }
.abm-val small { font-size: 12px; font-weight: 400; color: var(--muted); margin-left: 4px; letter-spacing: 0; }
.abm-bar { height: 5px; border-radius: 3px; background: #eef1f6; overflow: hidden; margin: 10px 0 0; }
.abm-bar i { display: block; height: 100%; border-radius: 3px; }
.abm-bar i.ok { background: var(--success); }
.abm-bar i.miss { background: var(--warning); }
.abm-bar i.danger { background: var(--danger); }
.abm-foot {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  margin-top: auto; padding-top: 9px; font-size: 11.5px; color: var(--muted);
}
.abm-foot > span:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.abm-foot .abm-goal { flex: 0 0 auto; color: var(--text-2); }
@media (max-width: 1180px) { .ab-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  .ab-metrics { grid-template-columns: 1fr; gap: 8px; }
  .ab-m { min-height: 0; padding: 11px 13px 10px; }
  .abm-val { font-size: 21px; }
}

/* 工作汇报时间线：只补 time/text，沿用通用时间轴样式 */
.tl-list { padding-left: 0; }

/* ==================== V1.5 卡片正文留白 ====================
 * 约定：.card 只负责边框和背景，正文一律走 .card-body（16px 内边距）
 * 历史页面里有不少卡片把文本块直接塞进 .card，这里做一层兜底，
 * 避免出现「文字紧贴边框」的排版问题。 */
.card-body { padding: 16px; }
.card-body.tight { padding: 0; }
.card > :is(p, ul, ol, .sec-t, .hint, .form-tip, .learn-item, .issue-list, .plan-tabs,
  .plan-body, .dot-list, .alert, .timeline, .kv-list, .empty-mini, .learn-actions) {
  margin-left: 16px;
  margin-right: 16px;
}
.card > :is(p, ul, ol, .sec-t, .hint, .form-tip, .learn-item, .issue-list, .plan-tabs,
  .plan-body, .dot-list, .alert, .timeline, .kv-list, .empty-mini, .learn-actions):first-child {
  margin-top: 14px;
}
.card > :is(p, ul, ol, .sec-t, .hint, .form-tip, .learn-item, .issue-list, .plan-tabs,
  .plan-body, .dot-list, .alert, .timeline, .kv-list, .empty-mini, .learn-actions):last-child {
  margin-bottom: 14px;
}
.card > .issue-list { padding: 2px 0 4px; }
.card > .learn-item { padding: 12px 0; }
.learn-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.empty-mini { padding: 12px 0; font-size: 12.5px; color: var(--muted); }

/* AI 主管：目标达成标签 */
.stat-sub .tgt { display: inline-flex; align-items: center; gap: 3px; font-size: 11px;
  padding: 1px 6px; border-radius: 4px; background: #f4f6f9; color: var(--muted); }
.stat-sub .tgt.ok { background: #eaf7ee; color: #15803d; }
.stat-sub .tgt.miss { background: #fdeceb; color: #b91c1c; }
.stat-value small { font-size: 12px; font-weight: 400; color: var(--muted); margin-left: 4px; }

/* AI 主管：核查指标设置表 */
.rule-table { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.rt-row { display: grid; grid-template-columns: 82px minmax(132px, 1fr) 158px 52px minmax(200px, 1.9fr) 56px;
  align-items: center; gap: 10px; padding: 10px 14px; border-top: 1px solid #f1f3f7; font-size: 12.5px; }
.rt-row:nth-child(odd) { background: #fcfdff; }
.rt-head { border-top: none; background: #f7f9fc !important; font-size: 11.5px; color: var(--muted); font-weight: 500; }
.rt-dim { padding: 9px 14px 5px; font-size: 11.5px; font-weight: 600; color: var(--primary);
  background: #f4f8ff; border-top: 1px solid #e8eefb; letter-spacing: .3px; }
.rt-dim:first-of-type { border-top: none; }
.rt-dim-tag { font-size: 11px; color: var(--muted); }
.rt-name { font-weight: 500; color: var(--text); }
.rt-unit { color: var(--muted); font-size: 12px; }
.rt-hint { font-size: 11.5px; color: var(--muted); line-height: 1.6; }
.rt-row .rt-input { width: 92px; text-align: right; padding: 5px 8px; font-size: 12.5px; }
.rt-on { text-align: center; }

/* 分层目标：作用对象选择 + 目标来源标记 */
.rt-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.rt-bar-label { font-size: 12px; color: var(--muted); flex: 0 0 auto; }
.rt-scope { width: auto; min-width: 268px; max-width: 420px; height: 32px; padding: 4px 10px; font-size: 12.5px; }
.rt-scope-fixed { font-size: 13px; color: var(--text); }
.rt-badge { font-size: 11.5px; padding: 3px 9px; border-radius: 20px; background: #eaf3ff; color: #1f6fd0; }
.rt-badge.soft { background: #f2f5fa; color: var(--muted); }
.rt-target { display: flex; align-items: center; gap: 6px; }
.rt-num { font-size: 14px; font-weight: 600; color: var(--text); }
.rt-src {
  font-style: normal; font-size: 10.5px; line-height: 1; padding: 3px 5px; border-radius: 4px;
  background: #f1f4f9; color: var(--muted); white-space: nowrap;
}
.rt-src.s-dept { background: #eef4ff; color: #2b6cd4; }
.rt-src.s-user { background: #fff3e6; color: #b4620c; }
.rt-row.is-custom { background: #f9fbff; }
.rt-state { font-size: 11.5px; color: var(--text-2); }
.rt-state.off { color: var(--muted); }
.rt-foot {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  position: sticky; bottom: 0; z-index: 3;
  margin-top: 14px; padding: 12px 0 6px;
  background: #fff;
  border-top: 1px solid var(--border);
}

/* 窄屏：6 列的表格必然溢出，改成「名称 + 输入 + 开关」一行、说明独占一行的卡片式 */
@media (max-width: 900px) {
  .rt-row.rt-head { display: none; }
  .rt-row {
    display: flex; flex-wrap: wrap; align-items: center;
    gap: 8px 10px; padding: 11px 14px;
  }
  .rt-dim-tag { display: none; }
  .rt-name { flex: 0 1 auto; min-width: 0; margin-right: auto; font-size: 13px; }
  .rt-row > span:nth-child(3) { flex: 0 0 96px; }
  .rt-row .rt-input { width: 100%; }
  .rt-row .rt-src { display: none; }
  /* 窄屏下吸底按钮会压住表格行，改成跟随文档流 */
  .rt-foot { position: static; margin-top: 12px; padding-bottom: 0; border-top: none; }
  .rt-unit { flex: 0 0 auto; min-width: 22px; }
  .rt-on { flex: 0 0 auto; }
  .rt-hint { flex: 1 1 100%; order: 9; }
}

/* 来源 / 线索分类二级筛选条 */
.source-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 0 2px; }
.source-bar .sb-label { font-size: 12px; color: var(--muted); flex: 0 0 auto; }
.source-bar .sb-split { width: 1px; height: 16px; background: var(--border); margin: 0 2px; }
.fchip.sm { height: 25px; font-size: 11.5px; padding: 0 10px; }

/* 数据分类管理 */
.cat-add { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.cat-add .fin { flex: 1 1 140px; }
.cat-row { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid #f4f5f7; }
.cat-row input { flex: 1; }

/* 批量添加客户：两步式引导 */
.imp-wrap { display: flex; flex-direction: column; gap: 16px; }
.imp-step { display: flex; gap: 14px; padding: 16px; border: 1px solid var(--border); border-radius: 11px; background: #fff; }
.imp-no { flex: 0 0 26px; height: 26px; border-radius: 50%; background: var(--primary-soft); color: var(--primary);
  font-size: 13px; font-weight: 600; display: flex; align-items: center; justify-content: center; }
.imp-main { flex: 1; min-width: 0; }
.imp-title { font-size: 13.5px; font-weight: 600; color: var(--text); }
.imp-desc { font-size: 12.5px; color: var(--text-2); line-height: 1.75; margin-top: 5px; }
.imp-actions { display: flex; align-items: center; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.imp-tips { margin: 10px 0 0; padding: 10px 14px 10px 28px; background: #f8fafd; border-radius: 9px; border: 1px solid #edf1f7; }
.imp-tips li { font-size: 12px; color: var(--text-2); line-height: 1.9; }
.imp-tips li b { color: var(--text); font-weight: 600; }
.imp-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; margin-top: 10px; }
.imp-grid .fi span { font-size: 12px; color: var(--muted); }
.imp-sum { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 14px; }
.imp-sum .is-item { border-radius: 9px; padding: 10px 12px; background: #f7f9fc; border: 1px solid var(--border); }
.imp-sum .is-item b { display: block; font-size: 19px; font-weight: 600; }
.imp-sum .is-item span { font-size: 11.5px; color: var(--muted); }
.imp-sum .is-item.ok { background: #f1faf3; border-color: #d6efdd; }
.imp-sum .is-item.ok b { color: #15803d; }
.imp-sum .is-item.warn { background: #fffaf0; border-color: #f6e6c3; }
.imp-sum .is-item.warn b { color: #b45309; }
.imp-sum .is-item.bad { background: #fdf2f2; border-color: #f5d9d9; }
.imp-sum .is-item.bad b { color: #b91c1c; }
.imp-err { margin-top: 12px; }
.imp-err-list { max-height: 190px; overflow: auto; font-size: 12px; color: var(--text-2);
  border: 1px solid var(--border); border-radius: 8px; padding: 6px 10px; }
.imp-err-list > div { padding: 4px 0; border-bottom: 1px dashed #f1f3f7; }
.imp-err-list > div:last-child { border-bottom: none; }
.imp-err-list .line { display: inline-block; min-width: 74px; color: var(--muted); }

/* ---------- 显示设置（菜单 / 指标卡 / 列表字段） ---------- */
.disp-intro { font-size: 12px; color: var(--text-2); background: #f5f8ff; border: 1px solid #e6eefb;
  border-radius: 8px; padding: 8px 12px; margin-bottom: 14px; }
.disp-sec { margin-bottom: 6px; }
.disp-sec + .disp-sec { margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--border); }
.disp-sec h4 { font-size: 13px; font-weight: 600; margin: 0 0 4px; color: var(--text); }
.disp-tip { font-size: 11.5px; color: var(--muted); line-height: 1.75; margin-bottom: 9px; }
.disp-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 8px; }
.disp-item { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 7px;
  font-size: 12.5px; color: var(--text-2); cursor: pointer; min-width: 0; }
.disp-item:hover { background: #f5f8ff; }
.disp-item input { flex: 0 0 auto; width: 14px; height: 14px; margin: 0; accent-color: var(--primary); cursor: pointer; }
.disp-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.disp-item.lock { opacity: .62; cursor: default; }
.disp-item.lock:hover { background: transparent; }
.disp-item.lock input { opacity: 1; accent-color: #94a3b8; }
.disp-lock { margin-left: auto; font-style: normal; font-size: 10px; color: var(--muted);
  background: #f1f5f9; border-radius: 4px; padding: 0 5px; line-height: 16px; }

@media (max-width: 760px) {
  .disp-grid { grid-template-columns: 1fr; }
}



/* ---------- 多层级管理身份 ---------- */
.dept-pick { max-height: 210px; overflow: auto; border: 1px solid var(--border); border-radius: 10px; padding: 8px 10px; background: #fbfcfe; }
.dept-pick .perm-grid { gap: 6px 10px; }
.dept-pick .perm-item { font-size: 12.5px; }
.mgmt-scope-row { display: flex; align-items: center; gap: 10px; padding: 8px 2px; border-bottom: 1px dashed var(--border); font-size: 12.5px; }
.mgmt-scope-row:last-child { border-bottom: 0; }
.msr-name { flex: 0 0 120px; font-weight: 600; color: var(--text); }
.msr-depts { flex: 1; color: var(--text-2); min-width: 0; word-break: break-word; }
.msr-count { flex: 0 0 auto; }
.mgmt-hero { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.idt-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; padding: 2px 8px;
  border-radius: 999px; background: var(--primary-soft); color: var(--primary); font-weight: 600; }

@media (max-width: 760px) {
  .mgmt-scope-row { flex-wrap: wrap; gap: 4px 8px; }
  .msr-name { flex: 0 0 100%; }
  .dept-pick { max-height: 180px; }
}

/* ---------- 线索分配 / 留资对接 / 跟进高级筛选 ---------- */
.dp-item { display: flex; align-items: center; gap: 7px; padding: 6px 4px; font-size: 12.5px; border-bottom: 1px dashed var(--border); cursor: pointer; }
.dp-item:last-child { border-bottom: 0; }
.dp-item input { margin: 0; }
.dp-item span { font-weight: 500; }
.dp-item em { margin-left: auto; font-style: normal; font-size: 11.5px; color: var(--muted); }

.ib-row { border: 1px solid var(--border); border-radius: 11px; padding: 11px 13px; margin-bottom: 10px; background: #fbfcfe; }
.ib-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 7px; }
.ib-head b { font-size: 13.5px; }
.ib-url { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.ib-url code { flex: 1 1 280px; min-width: 0; font-size: 11.5px; background: #fff; border: 1px solid var(--border);
  border-radius: 7px; padding: 6px 9px; color: var(--text-2); word-break: break-all; }

.adv-chips { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: -4px 0 10px; }
.adv-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; padding: 3px 4px 3px 9px;
  border-radius: 999px; background: var(--primary-soft); color: var(--primary); }
.adv-chip button { border: 0; background: transparent; color: inherit; cursor: pointer; font-size: 13px; line-height: 1; padding: 0 4px; }

@media (max-width: 760px) {
  .ib-url code { flex: 1 1 100%; }
  .dept-pick { max-height: 180px; }
}

/* 权限区标题行：标题与说明一行，按钮单独一行，避免窄弹窗挤压 */
.perm-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.perm-head .ph-t { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; min-width: 0; }
.perm-head .ph-t b { font-size: 13px; }
.perm-head .ph-a { display: flex; gap: 6px; flex: 0 0 auto; }

/* ==================== AI 主管 · 实战教练 ==================== */
/* 人设条：让使用者知道「对面是谁、凭什么给建议」 */
.ab-persona { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 12px;
  background: linear-gradient(120deg, #f7f9ff 0%, #f4fbf8 100%); border: 1px solid #e5ecf8; margin-bottom: 14px; }
.abp-ava { flex: none; width: 38px; height: 38px; border-radius: 11px; background: linear-gradient(135deg, #2563eb, #0f9d8a);
  color: #fff; font-size: 13px; font-weight: 700; display: grid; place-items: center; letter-spacing: .5px; }
.abp-main { min-width: 0; flex: 1; }
.abp-name { font-size: 13.5px; font-weight: 600; color: var(--text); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.abp-style { font-size: 11px; font-weight: 400; color: var(--muted); }
.abp-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.abp-tag { font-size: 11px; padding: 2px 8px; border-radius: 999px; background: #fff; border: 1px solid #e2e9f5; color: var(--text-2); }
.abp-learn { font-size: 11px; color: var(--muted); margin-top: 6px; line-height: 1.6; }

/* 分时段行动：一条一个卡片式条目，话术与步骤都在里面 */
.plan-list li { align-items: flex-start; }
.plan-list .pi { flex: 1; min-width: 0; }
.pi-t { font-size: 13px; color: var(--text); line-height: 1.7; font-weight: 500; }
.pi-why { font-size: 12px; color: var(--muted); line-height: 1.75; margin-top: 4px; }
.pi-script { margin-top: 7px; padding: 8px 11px; border-radius: 8px; background: #f4f8ff; border-left: 2px solid #93b4fb;
  font-size: 12px; color: var(--text-2); line-height: 1.8; }
.pii-label { display: inline-block; font-size: 10.5px; color: var(--primary); background: var(--primary-soft);
  padding: 1px 6px; border-radius: 4px; margin-right: 6px; vertical-align: 1px; }
.pi-sop { margin: 7px 0 0; padding-left: 0; list-style: none; counter-reset: s; }
.pi-sop li { display: block; border-bottom: none; font-size: 12px; color: var(--text-2); line-height: 1.8;
  padding: 2px 0 2px 16px; position: relative; }
.pi-sop li::before { counter-increment: s; content: counter(s) "·"; position: absolute; left: 0; color: var(--muted); }
.pi-kpi { font-size: 11.5px; color: #0f766e; margin-top: 6px; }

/* 客户攻坚卡片 */
.coach { border: 1px solid var(--border); border-radius: 10px; margin-bottom: 9px; overflow: hidden; background: #fff; }
.coach[open] { box-shadow: 0 1px 2px rgba(16,24,40,.04); }
.coach > summary { list-style: none; cursor: pointer; padding: 10px 13px; display: flex; align-items: center;
  gap: 8px; background: #fcfdfe; }
.coach > summary::-webkit-details-marker { display: none; }
.coach-h { font-size: 12.8px; color: var(--text); line-height: 1.6; flex: 1; min-width: 0; }
.coach-caret { color: var(--muted); font-size: 11px; transition: transform .15s; }
.coach[open] .coach-caret { transform: rotate(180deg); }
.coach-tag { flex: none; font-size: 10.5px; padding: 2px 7px; border-radius: 5px; background: var(--primary-soft); color: var(--primary); }
.coach-tag.t-客户停滞 { background: #fdeaea; color: #b42318; }
.coach-tag.t-异议处理 { background: #fdf3e7; color: #b45309; }
.coach-tag.t-机会推进 { background: #eef4ff; color: #1d4ed8; }
.coach-tag.t-跟进记录 { background: #f2f4f7; color: #475467; }
.coach-tag.t-录音复盘 { background: #f4f0ff; color: #6941c6; }
.coach-tag.t-触达质量 { background: #eafaf3; color: #0f766e; }
.coach-body { padding: 4px 14px 14px; }
.coach-meta { font-size: 11.5px; color: var(--muted); margin: 6px 0 2px; }
.coach-sec { margin-top: 12px; }
.cs-t { font-size: 12px; font-weight: 600; color: var(--text); margin-bottom: 5px; display: flex; align-items: center; gap: 6px; }
.cs-p { font-size: 12px; color: var(--text-2); line-height: 1.8; }
.coach .dot-list { margin: 0; padding-left: 16px; }
.coach .dot-list li { font-size: 12px; color: var(--text-2); line-height: 1.8; }

/* 话术框：像聊天记录一样，一眼看清谁说什么 */
.script-box { border: 1px solid #e8eef8; border-radius: 9px; background: #fbfcff; padding: 9px 11px; }
.sc-line { display: flex; gap: 8px; padding: 4px 0; font-size: 12.2px; line-height: 1.8; }
.sc-who { flex: none; width: 40px; text-align: center; font-size: 10.5px; border-radius: 4px; height: 19px; line-height: 19px;
  background: var(--primary-soft); color: var(--primary); margin-top: 2px; }
.sc-who.cus { background: #f2f4f7; color: #475467; }
.sc-who.old { background: #fdeaea; color: #b42318; }
.sc-who.new { background: #eafaf3; color: #0f766e; }
.sc-say { flex: 1; min-width: 0; color: var(--text-2); }
.sc-qs { margin-top: 8px; padding-top: 8px; border-top: 1px dashed #e8eef8; }
.sc-qs ul { margin: 4px 0 0; padding-left: 18px; }
.sc-qs li { font-size: 11.8px; color: var(--text-2); line-height: 1.8; }

.think-list { margin: 0; padding-left: 18px; }
.think-list li { font-size: 12px; color: var(--text-2); line-height: 1.85; margin-bottom: 3px; }

.sop-list { display: flex; flex-direction: column; gap: 6px; }
.sop-row { display: flex; gap: 9px; padding: 7px 9px; background: #fafbfd; border-radius: 8px; }
.sop-step { flex: none; font-size: 10.5px; color: var(--primary); background: #fff; border: 1px solid #e2e9f5;
  border-radius: 5px; padding: 1px 6px; height: 20px; line-height: 18px; }
.sop-do { font-size: 12px; color: var(--text-2); line-height: 1.75; }
.sop-done { font-size: 11px; color: var(--muted); margin-top: 2px; }

.tl-chips { display: flex; gap: 7px; flex-wrap: wrap; }
.tl-chip { font-size: 11.5px; color: var(--text-2); background: #f5f7fa; border-radius: 7px; padding: 5px 9px; line-height: 1.6;
  max-width: 100%; }
.tl-chip b { color: var(--primary); margin-right: 5px; font-weight: 600; }

/* 问题诊断里的「直接这么说」与动作清单 */
.ii-when { font-size: 10.5px; color: #b42318; background: #fdeaea; padding: 1px 6px; border-radius: 4px; }
.ii-sug.ii-say { background: #f4f8ff; }
.ii-steps { margin: 7px 0 0; padding-left: 18px; }
.ii-steps li { font-size: 12px; color: var(--text-2); line-height: 1.8; }

.kb-ref { margin: 0; padding-left: 0; list-style: none; }
.kb-ref li { font-size: 12.5px; line-height: 1.7; padding: 6px 0; border-bottom: 1px dashed #f0f2f5; }
.kb-ref li:last-child { border-bottom: none; }
.kb-ref .tag { margin-left: 6px; }

@media (max-width: 760px) {
  .ab-persona { padding: 10px 12px; }
  .coach > summary { padding: 9px 10px; }
  .coach-body { padding: 2px 10px 12px; }
  .sc-who { width: 34px; }
}

/* =====================================================================
   沟通纪要（对标飞书妙记）：目录 + 正文 + 导出面板
   ===================================================================== */
.mn-hero { padding-bottom: 14px; border-bottom: 1px solid var(--border); margin-bottom: 16px; }
.mn-hero h2 { font-size: 19px; font-weight: 700; color: var(--text); margin: 0 0 10px; line-height: 1.4; }
.mn-hero-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.mn-chip { font-size: 11.5px; color: var(--text-2); background: #f3f5f9; border: 1px solid #e8ecf3;
  border-radius: 20px; padding: 2px 9px; white-space: nowrap; }
.mn-chip.ok { color: var(--success); background: var(--success-soft); border-color: #cdebd8; }
.mn-chip.warn { color: var(--warn); background: var(--warn-soft); border-color: #f3e2c2; }
.mn-chip.bad { color: var(--danger); background: var(--danger-soft); border-color: #f6d3d5; }
.mn-hero-tip { font-size: 11.5px; color: var(--muted); margin-top: 8px; }

.mn { display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 18px; align-items: start; }
.mn-nav { position: sticky; top: 0; align-self: start; }
.mn-nav-t { font-size: 11px; color: var(--muted); letter-spacing: .5px; margin-bottom: 6px; }
.mn-nav-g { font-size: 10.5px; color: var(--muted); margin: 10px 0 3px; padding-left: 8px; }
.mn-nav a { display: block; font-size: 12px; color: var(--text-2); padding: 5px 8px; border-radius: 6px;
  cursor: pointer; line-height: 1.4; border-left: 2px solid transparent; }
.mn-nav a:hover { background: #f4f6fa; color: var(--text); }
.mn-nav a.on { background: var(--primary-soft); color: var(--primary); border-left-color: var(--primary); font-weight: 500; }
.mn-nav-hint { font-size: 10.5px; color: #b3b9c4; margin-top: 10px; padding-left: 8px; }

.mn-main { min-width: 0; }
.mn-sec { scroll-margin-top: 8px; padding: 0 0 18px; margin-bottom: 6px; border-bottom: 1px dashed #eef1f6; }
.mn-sec:last-of-type { border-bottom: none; }
.mn-sec h3 { display: flex; align-items: baseline; gap: 7px; font-size: 14px; font-weight: 600;
  color: var(--text); margin: 0 0 10px; }
.mn-sec h3 i { font-style: normal; font-size: 12px; color: #fff; background: var(--primary);
  width: 18px; height: 18px; border-radius: 5px; display: inline-flex; align-items: center;
  justify-content: center; flex: none; transform: translateY(-1px); }
.mn-sec-g { margin-left: auto; font-size: 10.5px; font-weight: 400; color: var(--muted); }
.mn-p { font-size: 12.8px; line-height: 1.85; color: var(--text-2); margin: 0 0 8px; }
.mn-p.mut, .mut { color: var(--muted); }
.mn-lb { font-size: 11.5px; color: var(--muted); font-weight: 500; margin: 10px 0 4px; }
.mn-kv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 18px;
  border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.mn-kv > div { display: flex; gap: 8px; padding: 7px 11px; font-size: 12.3px; border-bottom: 1px solid #f2f4f8; }
.mn-kv > div:nth-child(odd) { background: #fafbfd; }
.mn-kv span { color: var(--muted); flex: none; width: 68px; }
.mn-kv b { font-weight: 500; color: var(--text); min-width: 0; word-break: break-all; }
.mn-ul, .mn-ol { margin: 4px 0 8px; padding-left: 16px; }
.mn-ul { list-style: none; padding-left: 4px; }
.mn-ul li { position: relative; padding-left: 12px; font-size: 12.5px; line-height: 1.8; color: var(--text-2); }
.mn-ul li::before { content: ''; position: absolute; left: 2px; top: 9px; width: 4px; height: 4px;
  border-radius: 50%; background: #c3cad6; }
.mn-ul.sm li { font-size: 12px; color: #5b6478; }
.mn-ol li { font-size: 12.5px; line-height: 1.8; color: var(--text-2); margin-bottom: 3px; }
.mn-tb-wrap { overflow-x: auto; margin: 6px 0 10px; }
.mn-tb { width: 100%; border-collapse: collapse; font-size: 12px; }
.mn-tb th, .mn-tb td { border: 1px solid #e9edf4; padding: 6px 9px; text-align: left;
  vertical-align: top; line-height: 1.7; }
.mn-tb th { background: #f5f8fc; color: #47506a; font-weight: 600; white-space: nowrap; }
.mn-tb tbody tr:nth-child(even) { background: #fcfdff; }
.mn-quote { margin: 6px 0; padding: 8px 12px; border-left: 3px solid #ccd6e8; background: #f8fafc;
  color: #44506a; font-size: 12.3px; line-height: 1.8; }
.mn-chips { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; margin: 8px 0 4px; }
.mn-chips-lb { font-size: 11px; color: var(--muted); margin-right: 2px; }
.mn-chips span { font-size: 11px; color: var(--primary); background: var(--primary-soft);
  border-radius: 10px; padding: 2px 8px; }
.mn-co { border-left: 3px solid var(--primary); background: #f2f7ff; padding: 9px 12px;
  border-radius: 0 6px 6px 0; margin: 8px 0; }
.mn-co.ok { border-color: var(--success); background: #f1faf4; }
.mn-co.warn { border-color: var(--warn); background: #fff8ec; }
.mn-co.danger { border-color: var(--danger); background: #fdf1f1; }
.mn-co-t { font-size: 12.3px; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.mn-co-b { font-size: 12.3px; color: var(--text-2); line-height: 1.8; }
.mn-script { border: 1px solid #dbe6f6; background: #f8fbff; border-radius: 8px; padding: 9px 12px; margin: 8px 0; }
.mn-sc-t { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--primary);
  font-weight: 600; margin-bottom: 6px; }
.mn-sc-t .btn-text { margin-left: auto; font-weight: 400; font-size: 11.5px; }
.mn-sc-l { display: flex; gap: 7px; font-size: 12.5px; line-height: 1.85; color: var(--text); margin: 3px 0; }
.mn-sc-w { flex: none; font-size: 10.5px; color: #fff; background: var(--primary); border-radius: 3px;
  padding: 0 5px; height: 17px; line-height: 17px; margin-top: 4px; }
.mn-sc-w.cus { background: #0f766e; }
.mn-sc-n { font-size: 11px; color: var(--muted); margin-top: 5px; }
.mn-stats { display: flex; gap: 8px; margin: 8px 0 10px; }
.mn-stats > div { flex: 1; border: 1px solid var(--border); border-radius: 8px; padding: 8px 6px; text-align: center; }
.mn-stats b { display: block; font-size: 15px; color: var(--text); }
.mn-stats span { font-size: 10.5px; color: var(--muted); }
.mn-score { display: flex; gap: 18px; align-items: center; border: 1px solid var(--border);
  border-radius: 8px; padding: 12px 14px; margin: 6px 0 10px; }
.mn-score-v { text-align: center; flex: none; }
.mn-score-v b { font-size: 30px; color: var(--primary); line-height: 1; }
.mn-score-v span { font-size: 11px; color: var(--muted); }
.mn-score-v em { display: block; font-style: normal; font-size: 10.5px; color: var(--muted); margin-top: 2px; }
.mn-score-d { flex: 1; display: grid; gap: 5px; }
.mn-score-d > div { display: grid; grid-template-columns: 62px 1fr 30px; gap: 8px; align-items: center; }
.mn-score-d span { font-size: 11.5px; color: var(--text-2); }
.mn-score-d b { font-size: 11.5px; color: var(--text); text-align: right; }
.mn-bar { height: 5px; background: #eef1f6; border-radius: 3px; overflow: hidden; }
.mn-bar i { display: block; height: 100%; border-radius: 3px; }
.mn-steps { display: grid; gap: 8px; margin: 6px 0 10px; }
.mn-step { display: flex; gap: 9px; }
.mn-step-n { flex: none; width: 18px; height: 18px; border-radius: 50%; background: var(--primary-soft);
  color: var(--primary); font-size: 11px; display: flex; align-items: center; justify-content: center; margin-top: 2px; }
.mn-step-h { font-size: 12.5px; color: var(--text-2); line-height: 1.75; }
.mn-step-h b { color: var(--primary); margin-right: 6px; font-weight: 600; }
.mn-step-f { font-size: 11px; color: var(--muted); margin-top: 2px; }
.mn-chap { border: 1px solid #e9edf5; border-radius: 8px; padding: 10px 12px; margin: 8px 0; }
.mn-chap-h { display: flex; align-items: baseline; gap: 8px; margin-bottom: 5px; }
.mn-chap-h b { font-size: 12.8px; font-weight: 600; color: var(--text); }
.mn-time { flex: none; font-size: 10.5px; color: var(--primary); background: var(--primary-soft);
  border-radius: 3px; padding: 1px 6px; font-variant-numeric: tabular-nums; }
.mn-chap-s { font-size: 12.3px; color: var(--text-2); line-height: 1.8; }
.mn-marks { display: grid; gap: 2px; border-top: 1px solid #f1f4f9; }
.mn-mark { display: flex; gap: 8px; align-items: baseline; padding: 6px 0; border-bottom: 1px solid #f5f7fa; }
.mn-mark-tag { flex: none; font-size: 10.5px; color: var(--danger); background: var(--danger-soft);
  border-radius: 3px; padding: 0 6px; }
.mn-mark-x { font-size: 12.3px; color: var(--text-2); line-height: 1.75; }
.mn-mark-x b { color: var(--text); font-weight: 500; margin-right: 4px; }
.mn-note { font-size: 11.5px; color: var(--muted); margin: 2px 0 8px; line-height: 1.7; }
.mn-tr { border-top: 1px solid #f1f4f9; }
.mn-tr-l { display: flex; gap: 8px; padding: 5px 0; border-bottom: 1px solid #f7f9fc; align-items: flex-start; }
.mn-tr-w { flex: none; font-size: 11px; font-weight: 600; width: 64px; line-height: 1.7; }
.mn-tr-w.me { color: var(--primary); }
.mn-tr-w.cus { color: #0f766e; }
.mn-tr-x { font-size: 12.3px; color: var(--text-2); line-height: 1.8; min-width: 0; }
.mn-end { margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--border);
  font-size: 11px; color: var(--muted); text-align: center; line-height: 1.8; }

/* 导出面板 */
.ex-fmt { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.ex-fmt-b { text-align: left; border: 1px solid var(--border); background: #fff; border-radius: 9px;
  padding: 10px 12px; cursor: pointer; transition: .15s; }
.ex-fmt-b b { display: block; font-size: 13.5px; color: var(--text); margin-bottom: 3px; }
.ex-fmt-b span { font-size: 11.5px; color: var(--muted); line-height: 1.5; }
.ex-fmt-b.on { border-color: var(--primary); background: var(--primary-soft); }
.ex-fmt-b.on b { color: var(--primary); }
.ex-head { display: flex; align-items: center; gap: 10px; font-size: 12.5px; margin-bottom: 8px; }
.ex-head .spacer { flex: 1; }
.ex-list { max-height: 320px; overflow-y: auto; border: 1px solid var(--border); border-radius: 8px; }
.ex-group { border-bottom: 1px solid #f1f4f8; }
.ex-group:last-child { border-bottom: none; }
.ex-group-h { display: flex; align-items: center; gap: 8px; padding: 7px 11px; background: #f7f9fc;
  font-size: 11.5px; color: var(--muted); }
.ex-group-h .btn-text { margin-left: auto; font-size: 11px; }
.ex-item { display: flex; align-items: center; gap: 9px; padding: 7px 11px 7px 18px;
  font-size: 12.5px; color: var(--text-2); cursor: pointer; border-top: 1px solid #f8fafc; }
.ex-item:hover { background: #fafbfe; }
.ex-item input { accent-color: var(--primary); width: 14px; height: 14px; }
.ex-item-t { flex: 1; }
.ex-fix { font-size: 10.5px; color: var(--muted); background: #f1f3f7; border-radius: 3px; padding: 0 6px; }
.ex-tip { font-size: 11.5px; color: var(--muted); margin-top: 10px; line-height: 1.7; }

@media (max-width: 820px) {
  .mn { grid-template-columns: 1fr; }
  .mn-nav { display: none; }
  .mn-kv { grid-template-columns: 1fr; }
  .ex-fmt { grid-template-columns: 1fr; }
}

/* ==================== 客户 AI 销售助手 ==================== */
.btn-ai {
  border-color: #c7b6ff;
  color: #6941c6;
  background: linear-gradient(180deg, #fbf9ff, #f4efff);
}
.btn-ai:hover { border-color: #a78bfa; color: #5b21b6; background: #f4efff; }

.sa-top { display: flex; gap: 16px; align-items: center; padding: 14px 16px; border: 1px solid var(--border); border-radius: 12px; background: #fbfcff; margin-bottom: 12px; }
.sa-score { flex: none; width: 88px; height: 88px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; background: #fff; border: 6px solid var(--c); }
.sa-score b { font-size: 26px; line-height: 1; color: var(--c); }
.sa-score span { font-size: 10.5px; color: var(--muted); margin-top: 4px; }
.sa-meta { flex: 1; min-width: 0; }
.sa-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 9px; }
.sa-kpis { display: flex; flex-wrap: wrap; gap: 18px; }
.sa-kpis > div { display: flex; flex-direction: column; }
.sa-kpis em { font-style: normal; font-size: 11px; color: var(--muted); }
.sa-kpis b { font-size: 15px; font-weight: 600; margin-top: 2px; }

/* 档案完备清单：与客户档案同一份字段定义，缺哪项一眼看到 */
.sa-prof { display: flex; flex-wrap: wrap; gap: 6px; }
.sa-pf { font-size: 11.5px; padding: 4px 9px; border-radius: 6px; border: 1px solid var(--border); background: #fff; color: var(--text-2); white-space: nowrap; }
.sa-pf.on { border-color: #bbf7d0; background: #f0fdf4; color: #15803d; }
.sa-pf.off { border-color: #fecaca; background: #fef2f2; color: #b91c1c; }
.sa-pf.crit { border-style: dashed; }
.sa-prof-foot { font-size: 11.5px; color: var(--muted); margin-top: 10px; line-height: 1.7; }

.sa-headline { padding: 10px 14px; border-radius: 9px; background: #fff7ed; border: 1px solid #fde3c0; color: #92400e; font-size: 13px; line-height: 1.7; }
.sa-summary { font-size: 13px; color: var(--text-2); line-height: 1.8; margin: 10px 0 12px; }
.sa-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.sa-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
@media (max-width: 900px) { .sa-grid { grid-template-columns: 1fr; } }

.sa-dim { margin-bottom: 12px; }
.sa-dim:last-child { margin-bottom: 0; }
.sa-dim-top { display: flex; justify-content: space-between; font-size: 12.5px; margin-bottom: 5px; }
.sa-dim-top b { font-weight: 600; }
.sa-dim-note { font-size: 11.5px; color: var(--muted); margin-top: 5px; line-height: 1.6; }

.sa-list { margin: 0; padding-left: 16px; }
.sa-list li { font-size: 12.5px; line-height: 1.85; color: var(--text-2); }
.sa-list.warn li { color: #b45309; }
.sa-list li.ok { color: #0f766e; }
.sa-next { font-size: 13.5px; line-height: 1.8; color: var(--text); padding: 10px 12px; background: #f0f7ff; border-left: 3px solid #93b4fb; border-radius: 7px; }

.sa-scripts { padding: 8px 12px; }
.sa-script { border: 1px solid var(--border); border-radius: 10px; margin-bottom: 8px; overflow: hidden; background: #fff; }
.sa-script > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: #fafbfe; }
.sa-script > summary::-webkit-details-marker { display: none; }
.sa-scene { flex: 1; font-size: 12.8px; color: var(--text); }
.sa-caret { font-size: 11px; color: var(--muted); transition: transform .15s; }
.sa-script[open] .sa-caret { transform: rotate(180deg); }
.sa-script-body { padding: 12px; }
.sa-goal { font-size: 12px; color: var(--primary); background: var(--primary-soft); padding: 6px 10px; border-radius: 6px; margin-bottom: 10px; }
.sa-bubble { margin-bottom: 8px; max-width: 92%; }
.sa-bubble.me { margin-left: auto; }
.sa-who { font-size: 10.5px; color: var(--muted); margin-bottom: 3px; }
.sa-bubble.me .sa-who { text-align: right; }
.sa-say { font-size: 13px; line-height: 1.75; padding: 9px 12px; border-radius: 10px; background: #f4f6fa; color: var(--text); }
.sa-bubble.me .sa-say { background: #eef4ff; border: 1px solid #dbe7ff; }
.sa-bubble.them .sa-say { background: #f7f7f8; }
.sa-tips { margin: 10px 0; font-size: 11.5px; color: var(--muted); line-height: 1.7; }

.sa-think { margin: 0; padding-left: 18px; }
.sa-think li { font-size: 12.5px; line-height: 1.85; color: var(--text-2); margin-bottom: 6px; }

.sa-plan { display: flex; flex-direction: column; gap: 10px; }
.sa-step { border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px; background: #fff; }
.sa-step-h { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.sa-step-h b { font-size: 12.8px; }
.sa-when { margin-left: auto; font-size: 11px; color: var(--primary); background: var(--primary-soft); padding: 1px 7px; border-radius: 5px; }
.sa-step-do { font-size: 12.5px; line-height: 1.8; color: var(--text-2); }
.sa-step-done { font-size: 11.5px; color: #0f766e; margin-top: 6px; }

/* ==================== AI 角色扮演演练 ==================== */
.rp-wrap { display: grid; grid-template-columns: 320px 1fr; gap: 14px; align-items: start; }
@media (max-width: 980px) { .rp-wrap { grid-template-columns: 1fr; } }
.rp-side .card { margin-bottom: 12px; }
.rp-scene-item { padding: 9px 10px; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 7px; cursor: pointer; }
.rp-scene-item:hover { border-color: #c7d7fb; background: #fafbff; }
.rp-scene-item.on { border-color: var(--primary); background: var(--primary-soft); }
.rp-scene-item b { font-size: 12.5px; display: block; }
.rp-scene-item span { font-size: 11px; color: var(--muted); }

.rp-chat { display: flex; flex-direction: column; height: 460px; }
.rp-msgs { flex: 1; overflow-y: auto; padding: 14px 16px; background: #fafbfc; border-bottom: 1px solid var(--border); }
.rp-msg { margin-bottom: 12px; max-width: 82%; }
.rp-msg.me { margin-left: auto; }
.rp-msg .rp-name { font-size: 10.5px; color: var(--muted); margin-bottom: 3px; }
.rp-msg.me .rp-name { text-align: right; }
.rp-msg .rp-text { font-size: 13px; line-height: 1.75; padding: 9px 12px; border-radius: 10px; background: #fff; border: 1px solid var(--border); white-space: pre-wrap; }
.rp-msg.me .rp-text { background: #eef4ff; border-color: #dbe7ff; }
.rp-input { display: flex; gap: 8px; padding: 10px 12px; align-items: flex-end; }
.rp-input textarea { flex: 1; min-height: 62px; resize: vertical; }
.rp-hint { font-size: 11.5px; color: var(--muted); padding: 0 12px 10px; }
.rp-eval-top { display: flex; gap: 16px; align-items: center; padding: 14px; border: 1px solid var(--border); border-radius: 12px; background: #fbfcff; margin-bottom: 12px; }
.rp-big { font-size: 34px; font-weight: 700; line-height: 1; }
.rp-dim { margin-bottom: 10px; }
.rp-dim-top { display: flex; justify-content: space-between; font-size: 12.5px; margin-bottom: 4px; }
.rp-turn { border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px; margin-bottom: 9px; background: #fff; }
.rp-turn-h { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.rp-turn-say { font-size: 12.5px; line-height: 1.75; padding: 8px 10px; background: #f7f8fa; border-radius: 7px; }
.rp-turn-fix { font-size: 12.5px; line-height: 1.75; padding: 8px 10px; background: #f0fdf7; border-radius: 7px; margin-top: 7px; color: #065f46; }
.rp-turn-note { font-size: 11.5px; color: #b45309; margin-top: 6px; line-height: 1.7; }
.rp-sec-title { font-size: 12.5px; font-weight: 600; margin: 14px 0 8px; }
.rp-chip { display: inline-block; font-size: 11px; padding: 2px 7px; border-radius: 5px; background: #f2f4f7; color: #475467; margin: 0 4px 4px 0; }

/* --- V2.7 演练：人设组合 / 受虐难度 / AAR 复盘 --- */
.rp-src { display: flex; gap: 6px; margin-bottom: 9px; }
.rp-src-btn { flex: 1; padding: 6px 4px; font-size: 12px; border: 1px solid var(--border); background: #fff;
  border-radius: 7px; cursor: pointer; color: var(--text-2); }
.rp-src-btn.on { background: var(--primary-soft); border-color: var(--primary); color: var(--primary); font-weight: 600; }
.rp-list { max-height: 250px; overflow-y: auto; padding-right: 2px; }
.rp-mini { font-size: 11px; color: var(--muted); margin-left: auto; }
.rp-tip { font-size: 11.5px; color: var(--muted); line-height: 1.7; margin-top: 8px;
  background: #fafbfc; border-radius: 7px; padding: 7px 9px; }
.rp-real-tip { font-size: 11.5px; color: #0f766e; background: #f0fdf7; border: 1px solid #d1fae5;
  border-radius: 7px; padding: 7px 9px; margin-top: 8px; line-height: 1.65; }
.rp-diffs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.rp-diff { padding: 7px 2px; font-size: 12px; border: 1px solid var(--border); background: #fff;
  border-radius: 7px; cursor: pointer; color: var(--text-2); }
.rp-diff.on { background: var(--primary-soft); border-color: var(--primary); color: var(--primary); font-weight: 600; }
.rp-diff[data-diff="abuse"].on { background: #fef2f2; border-color: #dc2626; color: #b91c1c; }
.rp-persona-bar { display: flex; flex-wrap: wrap; gap: 0; padding: 0 16px 10px; }
.rp-guide { display: flex; flex-direction: column; gap: 9px; margin-top: 6px; }
.rp-guide-i { font-size: 12.5px; line-height: 1.75; color: var(--text-2); padding-left: 10px;
  border-left: 2px solid var(--primary-soft); }
.rp-guide-i b { color: var(--text); margin-right: 6px; }
.rp-w { font-style: normal; font-size: 10.5px; color: var(--muted); margin-left: 4px; }
.rp-dim-ev { font-size: 11px; color: var(--muted); line-height: 1.7; margin-top: 3px; }

.rp-aar { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; margin-top: 12px; }
.rp-aar-row { display: flex; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--border); font-size: 12.5px; line-height: 1.8; }
.rp-aar-row:last-child { border-bottom: 0; }
.rp-aar-row:nth-child(odd) { background: #fbfcfe; }
.rp-aar-k { flex: none; width: 96px; font-weight: 600; color: var(--text-2); font-size: 12px; }
.rp-aar-facts { display: flex; flex-direction: column; gap: 5px; }
.rp-fact { display: flex; gap: 8px; align-items: flex-start; }
.rp-fact-at { flex: none; font-size: 10.5px; color: var(--muted); width: 84px; padding-top: 2px; }
.rp-fact-q { color: var(--text); }
.rp-root { color: #b45309; font-weight: 500; }
.rp-ssl { display: flex; gap: 8px; margin-bottom: 4px; }
.rp-ssl > b { flex: none; width: 34px; font-size: 11.5px; color: var(--primary); }
.rp-ssl ul { margin: 0; padding-left: 16px; }
.rp-ssl li { margin-bottom: 2px; }

.rp-script { border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; background: #fff; }
.rp-script-h { display: flex; align-items: baseline; gap: 8px; margin-bottom: 7px; }
.rp-script-h b { font-size: 13px; }
.rp-script-h span { font-size: 11px; color: var(--muted); }
.rp-say { display: flex; gap: 8px; font-size: 12.5px; line-height: 1.8; padding: 7px 10px;
  background: #f0fdf7; border-radius: 7px; margin-bottom: 6px; color: #065f46; }
.rp-say i { font-style: normal; flex: none; width: 15px; height: 15px; border-radius: 50%;
  background: #d1fae5; color: #047857; font-size: 10px; display: flex; align-items: center;
  justify-content: center; margin-top: 3px; }
.rp-why { font-size: 11.5px; color: var(--muted); line-height: 1.7; }

.rp-sop { display: flex; gap: 11px; padding: 11px 0; border-bottom: 1px dashed var(--border); }
.rp-sop:last-child { border-bottom: 0; }
.rp-sop-no { flex: none; width: 22px; height: 22px; border-radius: 50%; background: #eef2f7; color: var(--text-2);
  font-size: 11.5px; display: flex; align-items: center; justify-content: center; font-weight: 600; }
.rp-sop-no.ok { background: #d1fae5; color: #047857; }
.rp-sop-name { font-size: 12.5px; font-weight: 600; }
.rp-sop-std { font-size: 11.5px; color: var(--text-2); line-height: 1.75; margin-top: 3px; }
.rp-sop-note { font-size: 11.5px; color: #0f766e; line-height: 1.75; margin-top: 3px; }

/* ==================== 结构化跟进表单（AI 回填） ==================== */
.ff-ai { border: 1px solid #dbe7ff; background: linear-gradient(180deg, #f6f9ff, #fbfcff);
  border-radius: 10px; padding: 11px 13px; margin-bottom: 14px; }
.ff-ai-h { display: flex; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.ff-ai-h b { font-size: 12.5px; color: var(--primary); }
.ff-ai-h span { font-size: 11.5px; color: var(--muted); }
.ff-ai-row { display: flex; gap: 7px; align-items: center; }
.ff-ai-row select { flex: 1; min-width: 0; }
.ff-ai-tip { font-size: 11.5px; color: var(--muted); line-height: 1.7; margin-top: 7px; }
#ff-text { width: 100%; box-sizing: border-box; font-size: 12.5px; line-height: 1.7; padding: 8px 10px;
  border: 1px solid #d0d5dd; border-radius: 6px; resize: vertical; font-family: inherit; background: #fff; }
#ff-text:focus { outline: none; border-color: var(--primary); }

.ff-sec { border-bottom: 1px dashed var(--border); padding-bottom: 12px; margin-bottom: 12px; }
.ff-sec:last-of-type { border-bottom: 0; padding-bottom: 0; margin-bottom: 4px; }
.ff-sec-h { font-size: 12.5px; font-weight: 600; margin-bottom: 9px; display: flex; align-items: baseline; gap: 8px; }
.ff-sec-h em { font-style: normal; font-size: 11px; font-weight: 400; color: var(--muted); }
.ff-sec .form-grid { margin-bottom: 0; }
.ff-sec textarea { font-size: 12.5px; line-height: 1.7; }

.ff-tags { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.ff-tags:empty { display: none; }
.ff-tag-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ff-tag-k { font-size: 11px; color: var(--muted); width: 52px; flex: none; }
.ff-tag { font-size: 11.5px; padding: 2px 8px; border-radius: 5px; background: #f2f4f7; color: #475467; }
.ff-tag.red { background: #fef2f2; color: #b91c1c; }
.ff-tag.green { background: #f0fdf7; color: #047857; }
.ff-tag.blue { background: #eff6ff; color: #1d4ed8; }
.ff-follow-x { margin-top: 6px; display: flex; flex-direction: column; gap: 3px; }
.ff-follow-x > div { font-size: 12px; color: var(--text-2); line-height: 1.7; }
.ff-follow-x i { font-style: normal; display: inline-block; min-width: 30px; color: var(--muted); margin-right: 6px; }

/* ---------- 写跟进 · 快捷放弃 ---------- */
.ff-abandon { border: 1px solid #fee2e2; background: #fffafa; border-radius: 8px; padding: 10px 12px; }
.ff-abandon-toggle { display: flex; align-items: center; gap: 8px; cursor: pointer; font-size: 13px; color: #b91c1c; font-weight: 500; }
.ff-abandon-toggle input { width: 16px; height: 16px; accent-color: #dc2626; }
.ff-abandon-toggle span { color: #7f1d1d; font-weight: 500; }
.ff-abandon .field { margin-top: 10px; }


/* ---------- 跟进记录 · 微信截图识别那一条 ----------
   原文不在这里铺，只留摘要 / 痛点 / 我方三行（相同句子只出现一次），
   原文与截图分别走「查看沟通记录」浮窗与「管理原始截图」。 */
.ff-shot { padding: 10px 12px; margin-bottom: 8px; border: 1px solid #eef1f5; border-left: 3px solid #bfdbfe;
  border-radius: 8px; background: #fcfdff; }
.ff-shot-h { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ff-shot-who { font-size: 13px; font-weight: 500; }
.ff-shot-time { margin-left: auto; font-size: 11.5px; color: var(--muted); }
.ff-shot-x { margin-top: 7px; display: flex; flex-direction: column; gap: 4px; }
.ff-shot-x > div { display: flex; gap: 8px; font-size: 12.5px; color: var(--text-2); line-height: 1.65; }
.ff-shot-x i { font-style: normal; flex: none; min-width: 30px; white-space: nowrap; color: var(--muted); }
.ff-shot-x span { min-width: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.ff-shot-f { margin-top: 8px; padding-top: 7px; border-top: 1px dashed #e6eaf0;
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap; font-size: 12px; }
.ff-shot-next { color: var(--muted); }
@media (max-width: 760px) {
  .ff-shot-f { gap: 10px; }
  .ff-shot-next { flex-basis: 100%; }
}

/* 查看沟通记录浮窗里的「识别原文」折叠区 */
.ccv-raw { margin-top: 12px; border-top: 1px solid var(--border); padding-top: 8px; }
.ccv-raw > summary { cursor: pointer; font-size: 12px; color: var(--muted); user-select: none; }
.ccv-raw > summary:hover { color: var(--text-2); }
.ccv-raw-body { margin-top: 8px; padding: 10px 12px; background: #f7f8fa; border-radius: 6px;
  font-size: 12px; color: var(--text-2); line-height: 1.75; max-height: 220px; overflow: auto;
  white-space: normal; word-break: break-word; }


/* ---------- 个人中心 · 通知 / 下载中心 ---------- */
.me-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 14px; align-items: start; }
@media (max-width: 1080px) { .me-grid { grid-template-columns: 1fr; } }
.me-col { min-width: 0; }

.steps { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.step { display: flex; gap: 10px; align-items: flex-start; }
.step > b { width: 20px; height: 20px; border-radius: 50%; background: var(--primary-soft); color: var(--primary);
  font-size: 11.5px; font-weight: 600; display: flex; align-items: center; justify-content: center; flex: none; margin-top: 1px; }
.step > div > span { font-size: 13px; font-weight: 500; }
.step p { font-size: 12.5px; color: var(--text-2); line-height: 1.65; margin-top: 3px; }
.step code { background: #f1f4f9; border-radius: 4px; padding: 1px 5px; font-size: 12px; }

.code-big { font-size: 28px; font-weight: 700; letter-spacing: 6px; color: var(--primary); margin: 6px 0 4px; }

.pref-list { display: flex; flex-direction: column; }
.pref-item { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 9px 0; border-bottom: 1px solid var(--border); }
.pref-item:last-child { border-bottom: 0; }
.pref-name { font-size: 13px; font-weight: 500; }
.pref-desc { font-size: 11.5px; color: var(--muted); margin-top: 2px; }

.progress-line { height: 6px; border-radius: 3px; background: #eef1f6; overflow: hidden; margin-bottom: 12px; }
.progress-line > i { display: block; height: 100%; background: linear-gradient(90deg, #2563eb, #22b573); border-radius: 3px; }

.me-table { display: flex; flex-direction: column; max-height: 320px; overflow: auto; }
.me-thead, .me-tr { display: grid; grid-template-columns: 1.2fr 1fr 64px 52px; gap: 8px; align-items: center;
  font-size: 12.5px; padding: 7px 2px; }
.me-thead { font-size: 11.5px; color: var(--muted); border-bottom: 1px solid var(--border); position: sticky; top: 0; background: #fff; }
.me-tr { border-bottom: 1px solid var(--border); }
.me-tr:last-child { border-bottom: 0; }
.me-td-name { font-weight: 500; }

.me-list { display: flex; flex-direction: column; max-height: 420px; overflow: auto; }
.me-row { display: flex; gap: 12px; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--border); }
.me-row:last-child { border-bottom: 0; }
.me-row-title { font-size: 13px; font-weight: 500; }
.me-row-sub { font-size: 12px; color: var(--text-2); margin-top: 2px; line-height: 1.6; }
.me-row-err { font-size: 11.5px; color: var(--danger); margin-top: 3px; }
.me-row-side { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex: none; }

/* 下载中心 */
.dl-hero { display: grid; grid-template-columns: 372px minmax(0, 1fr); gap: 26px; align-items: start; }
@media (max-width: 980px) { .dl-hero { grid-template-columns: 1fr; } }
/* 两个二维码并排，避免竖着摞成一条长柱、左栏比右栏高一倍 */
.dl-qr-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.dl-qr-row > .qr-box:only-child { grid-column: span 2; }
.qr-icon { width: 52px; height: 52px; border-radius: 12px; display: block; margin: 0 auto 8px; }
.qr-holder { min-height: 150px; display: flex; align-items: center; justify-content: center; }
.qr-cap { font-size: 12px; color: var(--muted); margin-top: 6px; }
.qr-box { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 12px; text-align: center; }
.qr-box canvas { display: block; margin: 0 auto; image-rendering: pixelated; }
.dl-url { display: flex; gap: 8px; align-items: center; margin-top: 10px; }
.dl-url input { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; }
.dl-steps { display: flex; flex-direction: column; gap: 12px; margin-top: 16px; }
.dl-step { display: flex; gap: 12px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; background: #fcfdff; }
.dl-step > b { flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 12px; }
.dl-step h4 { font-size: 13px; font-weight: 600; }
.dl-step p { font-size: 12.5px; color: var(--text-2); line-height: 1.7; margin-top: 3px; }
.dl-note { font-size: 12px; color: var(--muted); line-height: 1.7; }


/* ---------- 投流平台对接 ---------- */
.ap-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(390px, 1fr)); gap: 14px; }
.ap-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.ap-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px 12px; border-bottom: 1px solid var(--border); }
.ap-dot { width: 8px; height: 8px; border-radius: 4px; flex: none; box-shadow: 0 0 0 3px rgba(37,99,235,.10); }
.ap-name { font-size: 14px; font-weight: 600; }
.ap-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.ap-body { padding: 12px 16px 4px; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; }
.ap-kv span { display: block; font-size: 11px; color: var(--muted); }
.ap-kv b { font-size: 12.5px; font-weight: 500; }
.ap-field { padding: 4px 16px 10px; }
.ap-label { font-size: 11px; color: var(--muted); margin-bottom: 5px; }
.ap-url { display: flex; gap: 6px; }
.ap-url input { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 11.5px; }
.ap-err { margin: 0 16px 10px; padding: 7px 10px; border-radius: 7px; background: #fdecec; color: #c0392b;
  font-size: 11.5px; line-height: 1.6; }
.ap-foot { display: flex; gap: 6px; align-items: center; padding: 10px 16px; border-top: 1px solid var(--border);
  background: #fbfcfe; margin-top: auto; }

.plat-pick { display: flex; gap: 8px; flex-wrap: wrap; }
.plat-opt { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 8px;
  border: 1px solid var(--border); background: #fff; font-size: 12.5px; cursor: pointer; color: var(--text-2); }
.plat-opt.on { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); font-weight: 500; }
.plat-dot { width: 7px; height: 7px; border-radius: 4px; display: inline-block; }

.pick-users { display: flex; flex-wrap: wrap; gap: 8px; }
.pu { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border: 1px solid var(--border);
  border-radius: 16px; font-size: 12.5px; cursor: pointer; background: #fff; white-space: nowrap; }
.pu > span, .pu > label { white-space: nowrap; }
.pu.on { border-color: var(--primary); background: var(--primary-soft); color: var(--primary); }
.pu input { margin: 0; }

/* ---------- 通知通道 ---------- */
.ch-card { border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; margin-bottom: 12px; background: #fcfdff; }
.ch-card:last-child { margin-bottom: 0; }
.ch-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 12px; }
.ch-name { font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.ch-desc { font-size: 12px; color: var(--muted); line-height: 1.65; margin-top: 4px; }

/* ---------- 安装包卡片 ---------- */
.apk-card { border: 1px solid rgba(37,99,235,.22); background: linear-gradient(180deg,#f7faff,#fff);
  border-radius: 12px; padding: 16px; margin-bottom: 16px; }
.apk-card-main { display: flex; gap: 14px; align-items: center; }
.apk-icon { width: 56px; height: 56px; border-radius: 13px; flex: none;
  box-shadow: 0 6px 16px rgba(11,18,32,.18); }
.apk-title { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.apk-meta { font-size: 12.5px; color: var(--text-2); margin-top: 4px; }
.apk-hash { font-size: 11px; color: var(--muted); margin-top: 3px; font-family: ui-monospace, Menlo, Consolas, monospace; }
.dl-step code { background: #f1f4f9; border-radius: 4px; padding: 1px 5px; font-size: 12px; }

/* ================= 录音转写（ASR） ================= */
.asr-sec { margin-top: 18px; }
/* 智能转写：本月节省卡（设置页） */
.asr-save { margin-top: 10px; padding: 10px 12px; border-radius: 8px; background: var(--success-soft, #ecfdf5); color: #166534; font-size: 12px; line-height: 1.75; }
.asr-save b { font-weight: 600; }
/* 智能转写：时间轴（通话/拜访详情） */
.asr-tl { max-height: 420px; overflow-y: auto; padding-right: 4px; display: flex; flex-direction: column; gap: 6px; }
.asr-tl-item { display: flex; gap: 10px; padding: 8px 10px; border-radius: 8px; background: var(--surface-2, #f8fafc); border: 1px solid transparent; }
.asr-tl-item.is-cold { background: #fffbeb; border-color: #fde68a; }
.asr-tl-item.is-gap { background: #f1f5f9; color: var(--muted); font-size: 12px; padding: 7px 10px; }
.asr-tl-time { flex: 0 0 44px; font-size: 11.5px; color: var(--muted); font-variant-numeric: tabular-nums; padding-top: 2px; }
.asr-tl-body { flex: 1; min-width: 0; white-space: pre-wrap; word-break: break-word; font-size: 12.5px; line-height: 1.7; }
.asr-tl-tag { display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 999px; font-size: 10.5px; line-height: 16px; vertical-align: 1px; background: #e0e7ff; color: #3730a3; }
.asr-tl-tag.warn { background: #fef3c7; color: #92400e; }
.asr-tl-tag.gray { background: #e5e7eb; color: #4b5563; }
.asr-tl-play { border: 0; background: none; color: var(--primary); font-size: 11.5px; cursor: pointer; padding: 0 0 0 6px; }
.asr-tl-body b { font-weight: 600; }
.asr-tl-body .tl-me { color: var(--primary); }
.asr-tl-body .tl-cus { color: #0f766e; }
.asr-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.asr-title { font-size: 13px; font-weight: 600; color: var(--text); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.asr-badge { font-size: 11px; font-weight: 400; color: var(--muted); background: #f2f4f7;
  border-radius: 20px; padding: 2px 9px; white-space: nowrap; }
.asr-badge-run { color: var(--primary); background: var(--primary-soft); }
.asr-badge-bad { color: var(--danger); background: var(--danger-soft); }
.asr-tools { display: flex; gap: 10px; }
.asr-empty, .asr-fail { border: 1px dashed var(--border-strong); border-radius: var(--radius);
  padding: 18px; text-align: center; color: var(--muted); font-size: 12.5px; background: #fbfcfd; }
.asr-empty p, .asr-fail p { margin-bottom: 8px; }
.asr-fail { border-color: #f3c9c9; background: var(--danger-soft); color: #9b2c2c; }
.asr-pending { display: flex; align-items: center; gap: 12px; border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 16px; background: var(--primary-soft); }
.asr-pending p { font-size: 12.5px; color: var(--text-2); line-height: 1.6; }
.asr-dots { display: flex; gap: 4px; flex: none; }
.asr-dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--primary); opacity: .35;
  animation: asrBlink 1.2s infinite; }
.asr-dots i:nth-child(2) { animation-delay: .2s; }
.asr-dots i:nth-child(3) { animation-delay: .4s; }
@keyframes asrBlink { 0%, 60%, 100% { opacity: .25; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-2px); } }

.asr-spk-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  background: #f7f9fc; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 8px 12px; margin-bottom: 10px; }
.asr-spk-label { font-size: 12px; color: var(--muted); white-space: nowrap; }
.asr-spk-item { font-size: 12px; color: var(--text-2); display: flex; align-items: center; gap: 5px; white-space: nowrap; }
.asr-spk-item select { font-size: 12px; padding: 2px 4px; border: 1px solid var(--border-strong);
  border-radius: 5px; background: #fff; }

.asr-flow { max-height: 420px; overflow-y: auto; padding-right: 4px; }.asr-msg { border-left: 3px solid var(--border-strong); padding: 6px 0 6px 11px; margin-bottom: 10px; }
.asr-msg.asr-sales { border-left-color: var(--primary); }
.asr-msg.asr-customer { border-left-color: var(--success); }
.asr-msg.asr-other { border-left-color: #b9bec7; }
.asr-msg-top { display: flex; align-items: center; gap: 8px; margin-bottom: 3px; }
.asr-who { font-size: 11.5px; font-weight: 600; color: var(--text-2); }
.asr-msg.asr-sales .asr-who { color: var(--primary); }
.asr-msg.asr-customer .asr-who { color: var(--success); }
.asr-ts { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums;
  padding: 0 4px; border-radius: 4px; background: transparent; }
.asr-ts:hover { background: var(--primary-soft); color: var(--primary); }
.asr-text { font-size: 13px; line-height: 1.75; color: var(--text); word-break: break-word; }

/* ---------- 语音转写设置 ---------- */
.asr-buy { border: 1px solid rgba(37,99,235,.25); background: linear-gradient(180deg,#f6f9ff,#fff);
  border-radius: 12px; padding: 14px 16px; margin-bottom: 16px; }
.asr-buy-title { font-size: 13.5px; font-weight: 600; color: var(--primary); margin-bottom: 6px; }
.asr-buy-body { font-size: 12.5px; color: var(--text-2); line-height: 1.8; }
.asr-buy-body b { color: var(--danger); }
.asr-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
@media (max-width: 720px) { .asr-grid2 { grid-template-columns: 1fr; } }
.asr-engines { display: flex; flex-direction: column; gap: 8px; }
.asr-engine { display: flex; align-items: center; gap: 10px; border: 1px solid var(--border);
  border-radius: var(--radius); padding: 10px 12px; cursor: pointer; transition: all .12s; }
.asr-engine:hover { border-color: var(--border-strong); background: #fafbfd; }
.asr-engine.on { border-color: var(--primary); background: var(--primary-soft); }
.asr-engine input { accent-color: var(--primary); flex: none; }
.asr-engine-main { flex: 1; min-width: 0; }
.asr-engine-name { font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.asr-engine-note { font-size: 11.5px; color: var(--muted); margin-top: 2px; line-height: 1.5; }
.asr-engine-side { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; flex: none; }
.asr-price { font-size: 11.5px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.asr-switch { display: flex; align-items: flex-start; gap: 10px; padding: 9px 0; cursor: pointer; }
.asr-switch + .asr-switch { border-top: 1px solid var(--border); }
.asr-switch input { margin-top: 3px; accent-color: var(--primary); flex: none; }
.asr-switch b { font-size: 13px; font-weight: 500; display: block; }
.asr-switch span { font-size: 11.5px; color: var(--muted); }
/* 风控行：AI 给出的整改建议（2026-11 第 12 条） */
.risk-advice { font-size: 12px; color: var(--text-2); background: #f7f9ff; border-left: 2px solid var(--primary);
  padding: 6px 9px; margin-top: 5px; border-radius: 0 6px 6px 0; line-height: 1.6; }

/* ==================== 客户资料存储（2026-11） ==================== */
.cf-cats { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.cf-cats .fchip { display: inline-flex; align-items: center; gap: 5px; }
/* 分类上的小图标：重命名 / 删除。默认淡显，鼠标移到分类上才明显，避免误点 */
.cf-cat-x { font-size: 11px; opacity: .5; padding: 0 1px; line-height: 1; }
.cf-cats .fchip:hover .cf-cat-x { opacity: 1; }
.cf-cat-x:hover { color: var(--danger); }
.cf-list { display: flex; flex-direction: column; }
.cf-row { display: flex; align-items: center; gap: 10px; padding: 9px 2px; border-bottom: 1px solid #f5f6f8; }
.cf-row:last-child { border-bottom: 0; }
.cf-row:hover { background: #fafbfd; }
.cf-thumb { width: 34px; height: 34px; border-radius: 6px; object-fit: cover; flex: none;
  border: 1px solid var(--border); background: #fff; }
.cf-badge { width: 34px; height: 34px; border-radius: 6px; flex: none; display: flex;
  align-items: center; justify-content: center; font-size: 10px; font-weight: 600; text-transform: uppercase; }
.cf-main { flex: 1; min-width: 0; }
.cf-name { font-size: 12.8px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cf-sub { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 2px;
  font-size: 11.5px; color: var(--muted); }
.cf-acts { display: flex; align-items: center; gap: 10px; flex: none; }
.cf-acts .btn-text.danger { color: var(--danger); }

/* =====================================================================
   销冠物料（AI 知识库 · 物料页）
   卡片要一眼分清「图 / 视频 / 文档」：图片铺满、视频给首帧 + 播放键、
   文档给扩展名色块。操作按钮常显，因为销售的真实动作是「找到就下载」，
   不该先 hover 再找按钮。
   ===================================================================== */
.kbseg { display: inline-flex; gap: 2px; padding: 3px; background: #eef1f6; border-radius: 9px; margin-bottom: 14px; }
.kbseg button { border: 0; background: transparent; padding: 7px 16px; font-size: 13px; color: var(--text-2);
  border-radius: 7px; cursor: pointer; font-weight: 500; display: inline-flex; align-items: center; gap: 6px; }
.kbseg button:hover { color: var(--primary); }
.kbseg button.on { background: #fff; color: var(--primary); box-shadow: 0 1px 3px rgba(19, 32, 56, .1); }
.kbseg button b { font-size: 11px; background: var(--primary-soft, #e8f0ff); color: var(--primary);
  padding: 1px 6px; border-radius: 9px; font-weight: 600; }

.kbm-cats { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.kbm-cats .fchip { display: inline-flex; align-items: center; gap: 3px; height: 26px; font-size: 12px; }
.kbm-cats .fchip i { font-style: normal; font-size: 10.5px; opacity: .55; margin-left: 3px; }
.kbm-cx { font-size: 9px; opacity: 0; padding: 0; line-height: 1; transition: opacity .12s; }
.kbm-cats .fchip:hover .kbm-cx { opacity: .55; }
.kbm-cx:hover { opacity: 1 !important; color: var(--danger); }

.kbm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(224px, 1fr)); gap: 13px; }
.kbm-card { background: #fff; border: 1px solid var(--border); border-radius: 11px; overflow: hidden;
  display: flex; flex-direction: column; transition: box-shadow .16s, border-color .16s, transform .16s; }
.kbm-card:hover { border-color: #c9d6ee; box-shadow: 0 6px 18px rgba(19, 32, 56, .09); transform: translateY(-1px); }

.kbm-thumb { position: relative; aspect-ratio: 4 / 3; background: #f5f7fa; cursor: pointer; overflow: hidden; }
.kbm-img { width: 100%; height: 100%; object-fit: cover; object-position: top center; display: block; }
.kbm-video { width: 100%; height: 100%; object-fit: cover; object-position: top center; display: block; background: #0f172a; }
.kbm-play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  color: #fff; background: linear-gradient(180deg, rgba(15,23,42,.06), rgba(15,23,42,.34)); pointer-events: none; }
.kbm-play svg { filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .45)); }
.kbm-ico { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center;
  justify-content: center; gap: 5px; background: #f6f8fc;
  /* 老内核不认 color-mix 时保留上面的浅灰底，扩展名仍有颜色，不影响识别 */
  background: linear-gradient(160deg, color-mix(in srgb, var(--tone) 12%, #fff), color-mix(in srgb, var(--tone) 4%, #fff)); }
.kbm-ext { font-size: 20px; font-weight: 700; letter-spacing: .5px; color: var(--tone); }
.kbm-kindt { font-size: 11px; color: #8a94a6; }

.kbm-tools { position: absolute; top: 6px; right: 6px; display: flex; gap: 5px; opacity: 0; transition: opacity .14s; }
.kbm-card:hover .kbm-tools { opacity: 1; }
.kbm-tools button { border: 0; background: rgba(15, 23, 42, .72); color: #fff; font-size: 11.5px;
  padding: 3px 8px; border-radius: 5px; cursor: pointer; backdrop-filter: blur(2px); }
.kbm-tools button:hover { background: rgba(15, 23, 42, .9); }

.kbm-body { padding: 9px 11px 10px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.kbm-title { font-size: 13px; font-weight: 600; line-height: 1.45; color: var(--text);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.kbm-remark { font-size: 11.5px; color: var(--muted); line-height: 1.5;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kbm-meta { display: flex; align-items: center; gap: 7px; font-size: 11px; color: var(--muted); margin-top: 2px; }
.kbm-foot { display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--muted);
  margin-top: auto; padding-top: 5px; border-top: 1px dashed #f0f2f6; }
.kbm-foot .btn-text { margin-left: auto; font-size: 12px; }

.kbm-preview { background: #0f172a; border-radius: 9px; padding: 6px; display: flex;
  align-items: center; justify-content: center; min-height: 160px; }
.kbm-preview img { max-width: 100%; max-height: 68vh; border-radius: 5px; display: block; }

/* 上传：拖拽区 + 已选文件清单 */
.kbm-drop { border: 1.5px dashed var(--border-strong); border-radius: 10px; padding: 26px 18px;
  text-align: center; cursor: pointer; background: #fbfcfe; margin-top: 14px; transition: .14s; }
.kbm-drop:hover, .kbm-drop.on { border-color: var(--primary); background: #f3f7ff; }
.kbm-drop b { display: block; font-size: 13.5px; color: var(--text); margin-bottom: 5px; }
.kbm-drop span { font-size: 11.5px; color: var(--muted); }
.kbm-pick { display: flex; align-items: center; gap: 9px; padding: 8px 2px; border-bottom: 1px solid #f4f6f9; }
.kbm-pick:last-child { border-bottom: 0; }
.kbm-pick-ext { width: 38px; height: 38px; border-radius: 7px; background: #eef2f8; color: #55617a;
  font-size: 9.5px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex: none; }
.kbm-pick-main { flex: 1; min-width: 0; }
.kbm-pick-main span { font-size: 11px; color: var(--muted); display: block; margin-top: 1px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kbm-pick-title { width: 100%; border: 1px solid transparent; background: transparent; padding: 2px 4px;
  font-size: 12.5px; border-radius: 5px; color: var(--text); }
.kbm-pick-title:hover { border-color: var(--border); }
.kbm-pick-title:focus { border-color: var(--primary); background: #fff; outline: none; }

/* ================= 交易协同：订单流水线 ================= */
.tp-bar { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px 10px; margin-bottom: 14px; box-shadow: var(--shadow); }
.tp-track { display: flex; align-items: flex-start; overflow-x: auto; padding-bottom: 4px; }
.tp-node { flex: 1; min-width: 92px; text-align: center; position: relative; cursor: pointer; padding: 0 2px; }
.tp-node::before, .tp-node::after { content: ''; position: absolute; top: 13px; height: 2px; background: #e8ecf3; }
.tp-node::before { left: 0; right: 50%; }
.tp-node::after { left: 50%; right: 0; }
.tp-node:first-child::before, .tp-node:last-child::after { display: none; }
.tp-node.done::before, .tp-node.done::after { background: #0d9488; }
.tp-node.doing::before { background: #0d9488; }
.tp-dot { width: 26px; height: 26px; line-height: 23px; border-radius: 50%; margin: 0 auto 6px; font-size: 11.5px;
  background: #fff; border: 2px solid #dde3ec; color: #98a2b3; position: relative; z-index: 1; font-weight: 600; }
.tp-node.done .tp-dot { background: #0d9488; border-color: #0d9488; color: #fff; }
.tp-node.doing .tp-dot { background: #fff; border-color: #2563eb; color: #2563eb; box-shadow: 0 0 0 4px #eef4ff; }
.tp-node.late .tp-dot { border-color: #dc2626; color: #dc2626; box-shadow: 0 0 0 4px #fef2f2; }
.tp-nm { font-size: 11.5px; color: #5b6576; line-height: 1.35; }
.tp-node.doing .tp-nm { color: #1d4ed8; font-weight: 600; }
.tp-ow { font-size: 10.5px; color: #98a2b3; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.tp-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 14px; align-items: start; }
.tp-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.tp-sec-h { display: flex; align-items: center; gap: 8px; padding: 11px 16px; border-bottom: 1px solid var(--border);
  font-size: 13px; font-weight: 600; color: #1f2937; }
.tp-sec-h .r { margin-left: auto; font-weight: 400; font-size: 12px; color: var(--muted); }

.tp-row { display: flex; gap: 10px; padding: 11px 16px; border-bottom: 1px solid #f3f5f9; align-items: flex-start; }
.tp-row:last-child { border-bottom: 0; }
.tp-row.on { background: #f7faff; }
.tp-idx { width: 22px; height: 22px; border-radius: 50%; flex: none; display: flex; align-items: center; justify-content: center;
  font-size: 11px; background: #eef1f6; color: #6b7280; margin-top: 1px; font-weight: 600; }
.tp-row.done .tp-idx { background: #e6f7f3; color: #0d9488; }
.tp-row.doing .tp-idx { background: #2563eb; color: #fff; }
.tp-row.late .tp-idx { background: #dc2626; color: #fff; }
.tp-row-main { flex: 1; min-width: 0; }
.tp-row-t { font-size: 13px; font-weight: 600; color: #1f2937; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.tp-row-s { font-size: 12px; color: var(--muted); margin-top: 3px; line-height: 1.55; }
.tp-row-a { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 7px; }
.tp-req { display: inline-block; font-size: 11px; padding: 1px 7px; border-radius: 5px; background: #fff7e6; color: #b45309; }

/* 节点材料清单（细分业务官方流程） */
.tp-mats { margin-top: 6px; border: 1px dashed #dbe2ec; border-radius: 8px; padding: 8px 10px; background: #fafbfe; }
.tp-mats-h { font-size: 11px; font-weight: 600; color: #475569; margin-bottom: 5px; }
.tp-mat { display: flex; align-items: center; gap: 6px; font-size: 12px; padding: 3px 0; color: #334155; flex-wrap: wrap; }
.tp-mat .dot { width: 14px; text-align: center; color: #94a3b8; }
.tp-mat.d .dot { color: #0d9488; }
.tp-mat.w .dot { color: #94a3b8; }
.tp-mat .nm em { font-style: normal; font-size: 10px; color: #b45309; margin-left: 2px; }
.tp-mat .nt { color: #94a3b8; font-size: 11px; }
.tp-mat button { margin-left: 4px; font-size: 11px; padding: 0 6px; border-radius: 4px; border: 1px solid #dbe2ec; background: #fff; color: #475569; cursor: pointer; }
.tp-mat button:hover { border-color: #2563eb; color: #2563eb; }
.tp-mat.w .nm, .tp-mat.d .nm { color: #94a3b8; }
.tp-mat.w .nm { text-decoration: line-through; }

.tp-files { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 16px; }
.tp-file { display: flex; align-items: center; gap: 8px; border: 1px solid var(--border); border-radius: 8px;
  padding: 7px 10px; font-size: 12px; background: #fcfdff; max-width: 260px; }
.tp-file b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tp-file .x { margin-left: 4px; color: #c0c6d0; cursor: pointer; }
.tp-file .x:hover { color: #dc2626; }

.tp-ev { display: flex; gap: 9px; padding: 9px 16px; border-bottom: 1px solid #f5f7fa; }
.tp-ev:last-child { border-bottom: 0; }
.tp-ava { width: 24px; height: 24px; border-radius: 50%; flex: none; background: #eef2f8; color: #4b5563;
  font-size: 11px; display: flex; align-items: center; justify-content: center; font-weight: 600; }
.tp-ava.sys { background: #f1f5f9; color: #94a3b8; }
.tp-ev-b { flex: 1; min-width: 0; font-size: 12.5px; line-height: 1.6; color: #374151; word-break: break-word; }
.tp-ev-b .who { font-weight: 600; color: #111827; }
.tp-ev-b .t { font-size: 11px; color: #9aa4b2; margin-left: 6px; }
.tp-ev-sys { font-size: 12px; color: #6b7280; }
.tp-box { padding: 10px 14px; border-top: 1px solid var(--border); background: #fbfcfe; }
.tp-box textarea { width: 100%; border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; font-size: 12.5px;
  resize: vertical; min-height: 54px; font-family: inherit; }
.tp-box .row { display: flex; gap: 8px; align-items: center; margin-top: 8px; }
.tp-box .row .r { margin-left: auto; }

/* 进度小条（列表里用） */
.tp-mini { display: flex; align-items: center; gap: 7px; min-width: 120px; }
.tp-mini .track { flex: 1; height: 5px; background: #eef1f6; border-radius: 3px; overflow: hidden; }
.tp-mini .fill { height: 100%; background: #0d9488; border-radius: 3px; }
.tp-mini .fill.late { background: #dc2626; }
.tp-mini span { font-size: 11px; color: var(--muted); white-space: nowrap; }

/* 岗位多选（账号管理 → 订单协同派活依据） */
.post-pick { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.post-chip { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; line-height: 1;
  padding: 6px 11px; border: 1px solid var(--border); border-radius: 20px; cursor: pointer;
  background: #fff; color: #4b5563; user-select: none; transition: .12s; }
.post-chip:hover { border-color: #c7d2fe; color: var(--primary); }
.post-chip.on { border-color: var(--primary); background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.post-chip input { display: none; }
.post-tags { display: flex; flex-wrap: wrap; gap: 3px; }
.post-tags .pt { font-size: 11px; padding: 1px 6px; border-radius: 4px; background: #eef2f8; color: #4b5563; white-space: nowrap; }
.post-tags .pt.main { background: #e0f2f1; color: #0d9488; font-weight: 600; }
.post-tags .none { font-size: 11px; color: #b0b8c4; }

/* 账号列表：部门 + 岗位两行（岗位不单独占列，避免把操作列挤出可视区） */
.dept-cell .dn { font-size: 12.5px; color: #374151; }
.dept-cell .post-tags { margin-top: 3px; }

/* 1280~1440 的笔记本：账号表 8 列会把「操作」挤出可视区（按钮点不到），
   所以窄屏下压缩内边距、让操作按钮换行显示，保证 5 个按钮全部可点。 */
@media (max-width: 1440px) {
  .user-table thead th, .user-table tbody td { padding-left: 8px; padding-right: 8px; }
  .user-table th:last-child { width: 168px !important; }
  .user-table .op-cell { white-space: normal; line-height: 2; }
  .user-table .op-cell .link { margin-right: 7px; }
  .user-table td:nth-child(3) { white-space: normal; }
}
.user-table .last-login { margin-top: 3px; white-space: nowrap; font-size: 11px; }
.user-table td.num { white-space: nowrap; }
@media (max-width: 1440px) {
  /* 部门名不允许断在字中间（会出现「华东销售中 / 心」），岗位标签另起一行 */
  .user-table .dept-cell .dn { white-space: nowrap; }
  .user-table .tag { font-size: 11px; padding: 1px 6px; }
}

/* 系统日志：企业名可能很长（「XX科技（演示企业）」），单行截断避免把统计卡顶成两行 */
.stat-value .sys-tenant { display: inline-block; max-width: 100%; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; font-size: 20px; }

/* =====================================================================
   微信 / 企微沟通记录（截图识别后的时间线）
   设计取向：一眼看出「谁说的、什么时候说的、是文字还是图片」。
   我方气泡用微信绿，客户用白底描边，不做花哨 IM 皮肤——销售看的是内容，
   不是皮肤。时间放气泡外侧，永远可见，不用 hover 才找得到。
   ===================================================================== */
.ct-note { display: flex; gap: 8px; align-items: flex-start; padding: 9px 12px; border-radius: 9px;
  font-size: 12.3px; line-height: 1.6; margin-bottom: 11px; }
.ct-note b { flex: none; font-weight: 600; }
.ct-note.danger { background: var(--danger-soft); color: #8d1b1b; border: 1px solid #f6cccc; }
.ct-note.info { background: var(--info-soft, #eef4ff); color: #1e40af; border: 1px solid #cfe0f8; }

/* 上传区：整块可点 + 可拖入，销售不用先找按钮 */
.ct-drop { display: flex; align-items: center; gap: 12px; padding: 14px 16px; margin-bottom: 12px;
  border: 1.5px dashed #c3cede; border-radius: 11px; background: #fbfcfe; cursor: pointer;
  transition: border-color .15s, background .15s; }
.ct-drop:hover, .ct-drop.over { border-color: var(--primary); background: #f3f7ff; }
.ct-drop-ico { width: 34px; height: 34px; border-radius: 9px; flex: none; display: flex;
  align-items: center; justify-content: center; font-size: 19px; color: var(--primary);
  background: #e8f0ff; font-weight: 300; }
.ct-drop-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ct-drop-main b { font-size: 13px; font-weight: 600; color: var(--text); }
.ct-drop-main span { font-size: 11.8px; color: var(--muted); line-height: 1.5; }

/* 多业务员对接：一条会话一个 tab */
.ct-tabs { display: flex; gap: 7px; margin-bottom: 11px; overflow-x: auto; padding-bottom: 2px; }
.ct-tab { display: flex; flex-direction: column; gap: 1px; text-align: left; padding: 7px 12px;
  border: 1px solid var(--border); border-radius: 9px; background: #fff; flex: none; max-width: 260px; }
.ct-tab:hover { border-color: #bfd2ee; }
.ct-tab.on { border-color: var(--primary); background: var(--primary-soft, #eff4ff); }
.ct-tab .ctt-name { font-size: 12.5px; font-weight: 500; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ct-tab.on .ctt-name { color: var(--primary); }
.ct-tab .ctt-sub { font-size: 11px; color: var(--muted); }

.ct-head { display: flex; align-items: flex-end; gap: 10px; padding-bottom: 9px;
  border-bottom: 1px solid var(--border); margin-bottom: 4px; }
.ct-h-main { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ct-h-main b { font-size: 13.5px; font-weight: 600; }
.ct-h-sub { margin-left: auto; font-size: 11.5px; color: var(--muted); white-space: nowrap; }

.ct-sum { margin: 9px 0 2px; padding: 9px 12px; background: #f7f9fc; border-radius: 9px;
  font-size: 12.3px; line-height: 1.7; color: var(--text-2); }
.ct-sum b { display: block; font-size: 11px; color: var(--primary); margin-bottom: 3px;
  letter-spacing: .4px; font-weight: 600; }

/* 时间线：复刻微信对话框 —— 灰底、左右分列、不显示头像、气泡带小尖角 */
.ct-scroll { max-height: 48vh; min-height: 240px; overflow-y: auto; padding: 14px 14px 12px;
  background: #ededed; border-radius: 10px; }
.ct-day, .ct-t { text-align: center; margin: 12px 0 10px; }
.ct-day:first-child, .ct-t:first-child { margin-top: 2px; }
.ct-day span, .ct-t span { display: inline-block; padding: 2px 9px; border-radius: 4px;
  background: rgba(17, 24, 39, .055); color: #8a8f99; font-size: 11px; }
.ct-msg { display: flex; margin-bottom: 12px; }
.ct-msg.me { justify-content: flex-end; }
/* 同一个人连着说，气泡之间收紧；换人就自然拉开 */
.ct-msg.them + .ct-msg.them, .ct-msg.me + .ct-msg.me { margin-top: -6px; }
.ct-mid { max-width: 70%; min-width: 0; display: flex; flex-direction: column; }
.ct-msg.me .ct-mid { align-items: flex-end; }
.ct-who { font-size: 11px; color: #8a8f99; margin: 0 0 3px 2px; }
.ct-bubble { position: relative; padding: 9px 12px; border-radius: 6px; font-size: 13.5px;
  line-height: 1.62; background: #fff; color: #1a1a1a; word-break: break-word; white-space: pre-wrap; }
/* 小尖角：用 clip-path 画三角，比 border 三角稳（border 三角会被气泡背景压掉） */
.ct-msg.them .ct-bubble::before { content: ''; position: absolute; left: -6px; top: 11px;
  width: 6px; height: 12px; background: #fff; clip-path: polygon(100% 0, 100% 100%, 0 50%); }
.ct-msg.me .ct-bubble { background: #95ec69; color: #111a10; }
.ct-msg.me .ct-bubble::before { content: ''; position: absolute; right: -6px; top: 11px;
  width: 6px; height: 12px; background: #95ec69; clip-path: polygon(0 0, 0 100%, 100% 50%); }
.ct-bubble.plain { background: #f7f8fa; color: #6b7280; font-size: 12.5px; }
.ct-msg.them .ct-bubble.plain::before { background: #f7f8fa; }
.ct-msg.me .ct-bubble.plain { background: #d6f3c2; color: #3f5c34; }
.ct-msg.me .ct-bubble.plain::before { background: #d6f3c2; }
.ct-holder { font-size: 12.5px; }
.ct-empty { padding: 6px 0 2px; }

/* 截图管理：默认收起，展开后一行一张，右对齐操作 */
.ct-shots { margin-top: 12px; border-top: 1px solid var(--border); padding-top: 9px; }
.ct-shots > summary { cursor: pointer; font-size: 12.3px; color: var(--text-2); display: flex;
  align-items: center; gap: 7px; list-style: none; }
.ct-shots > summary::-webkit-details-marker { display: none; }
.ct-shots > summary::before { content: '▸'; font-size: 10px; color: var(--muted); }
.ct-shots[open] > summary::before { content: '▾'; }
.ct-shots > summary b { font-weight: 600; color: var(--text); }
.cts-tip { font-size: 11px; color: var(--muted); margin-left: auto; }
.cts-list { margin-top: 8px; }
.cts-row { display: flex; align-items: center; gap: 10px; padding: 8px 2px; border-bottom: 1px solid #f5f6f8; }
.cts-row:last-child { border-bottom: 0; }
.cts-thumb { width: 40px; height: 40px; border-radius: 6px; object-fit: cover; object-position: center 22%;
  flex: none; border: 1px solid var(--border); background: #fff; }
.cts-thumb.gone { display: flex; align-items: center; justify-content: center; font-size: 9.5px;
  color: var(--muted); background: #f4f5f7; border-style: dashed; text-align: center; line-height: 1.2; }
.cts-main { flex: 1; min-width: 0; }
.cts-t { font-size: 12.5px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.cts-sub { display: flex; gap: 9px; flex-wrap: wrap; font-size: 11.3px; color: var(--muted); margin-top: 2px; }
.ct-warn { color: var(--warn); }
.cts-err { font-size: 11.3px; color: var(--danger); margin-top: 3px; }
.cts-acts { display: flex; align-items: center; gap: 9px; flex: none; }
.cts-acts .btn-text.danger { color: var(--danger); }
.ct-prog { margin-right: auto; font-size: 12px; color: var(--primary); }

/* 客户详情里的轻量卡片：只露最近几条，深度阅读进面板 */
.ccc-thread { padding: 9px 0; border-bottom: 1px dashed var(--border); }
.ccc-thread:last-of-type { border-bottom: 0; }
.ccc-th { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.ccc-th b { font-size: 12.8px; font-weight: 600; }
.ccc-msgs { display: flex; flex-direction: column; gap: 4px; }
.ccc-m { display: flex; }
.ccc-m.me { justify-content: flex-end; }
.ccc-b { display: inline-block; max-width: 84%; padding: 4px 9px; border-radius: 7px; font-size: 12.2px;
  line-height: 1.55; background: #f4f5f7; color: var(--text-2); word-break: break-word; }
.ccc-m.me .ccc-b { background: #e6f7d9; color: #2c4225; }
.ccc-more { font-size: 11.3px; color: var(--muted); margin-top: 5px; cursor: pointer; }
.ccc-more:hover { color: var(--primary); }
.ccc-foot { display: flex; align-items: center; gap: 12px; padding-top: 9px; margin-top: 8px;
  border-top: 1px solid var(--border); font-size: 11.5px; color: var(--muted); }
.ccc-foot .btn-text { margin-left: auto; }

/* 客户列表操作列：5 个动作挤一行在 1280 笔记本上会断成「聊天记 / 录」，
   固定两行——第一行拨号 / 写跟进 / AI 助手（高频动作），第二行详情 / 聊天记录 */
.cust-ops { white-space: normal; line-height: 1.95; width: 146px; padding-top: 6px; padding-bottom: 6px; }
.cust-ops .ops-row { display: flex; align-items: center; gap: 8px; flex-wrap: nowrap; }
.cust-ops .ops-row + .ops-row { gap: 10px; }
/* 按钮自己不许折行（中文会在任意字间断行，出现「聊天记 / 录」） */
.cust-ops .btn-text { margin-right: 0; white-space: nowrap; }
/* 窄屏（1080 全窗口 / 1024）下浏览器会把客户名压成三字一行的竖排，
   给名称列一个下限，超出就整体横向滚动（.table-wrap 已 overflow-x:auto） */
.cust-table thead th:first-child,
.cust-table tbody td:first-child { min-width: 210px; }
.cust-table .cell-sub { line-height: 1.55; }
/* 「下次回访」是「12-01 15:06」+「刚刚」两行，列宽不够时日期会拆成两行变三行，
   表头也被压成两行。整列禁止折行，让能换行的客户名列自己让位 */
.cust-table thead th:nth-child(10), .cust-table tbody td:nth-child(10) { white-space: nowrap; }
.cust-table thead th { white-space: nowrap; }

/* 成交回访表在左栏（约 660px）塞 6 列：「2026-09-01」被拆成 2026-09- / 01、
   「销售二部」被拆成 销售二 / 部。日期、部门、状态一律不折行，让客户名列自己换行 */
.visit-table thead th { white-space: nowrap; }
.visit-table tbody td:nth-child(2),
.visit-table tbody td:nth-child(3),
.visit-table tbody td:nth-child(4) { white-space: nowrap; }

/* 线索表「分区」列只有 67px，业务类型「代理记账」会被拆成「代理记 / 账」，整列不折行 */
.cell-ch, .cell-ch .cell-sub { white-space: nowrap; }
/* 「首触」会显示「1260 分钟」这种长值，折行后整格变成两行、列宽被撑破，同样不折行 */
.cell-first { white-space: nowrap; }

/* AI 助手：客户微信原话（截图识别）
   把 AI 的判断依据摊开给销售看，异议/风险才有说服力 */
.sa-chat-note { font-size: 11.5px; color: var(--muted); margin-bottom: 10px; line-height: 1.7; }
.sa-chat-list { display: flex; flex-direction: column; gap: 8px; }
.sa-cm { display: flex; flex-direction: column; max-width: 78%; }
.sa-cm.them { align-self: flex-start; }
.sa-cm.me { align-self: flex-end; align-items: flex-end; }
.sa-cm-b { font-size: 12.5px; line-height: 1.72; padding: 7px 11px; border-radius: 10px;
  background: #f1f5f9; color: var(--text); word-break: break-word; }
.sa-cm.me .sa-cm-b { background: #e8f7e4; }
.sa-cm-t { font-size: 10.5px; color: var(--muted); margin-top: 3px; }

/* ==================================================================
 * AI 销售助手 · 相似客户成交案例（2026-11-18）
 * 自动调取本租户已成交的相似客户，提炼成交全过程，帮助快速开单。
 * ================================================================== */
.sa-case-note { display: flex; align-items: flex-start; gap: 7px; font-size: 11.5px; line-height: 1.7; color: var(--muted); padding: 8px 11px; background: #f6f8fb; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 12px; }
.sa-case-note i { font-style: normal; color: #b45309; }
.sa-case-playbook { border: 1px solid #fde3c0; background: #fffbf2; border-radius: 10px; padding: 12px 14px; margin-bottom: 14px; }
.sa-case-playbook h4 { margin: 0 0 8px; font-size: 12.5px; color: #92400e; }
.sa-case-playbook ol { margin: 0; padding-left: 18px; }
.sa-case-playbook li { font-size: 12.5px; line-height: 1.85; color: #7c4a12; }
.sa-case-list { display: flex; flex-direction: column; gap: 12px; }
.sa-case { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: #fff; }
.sa-case-head { display: flex; align-items: center; gap: 8px; padding: 10px 14px; background: #fafbfe; border-bottom: 1px solid var(--border); }
.sa-case-title { font-size: 13px; font-weight: 600; color: var(--text); min-width: 0; }
.sa-case-tags { display: flex; flex-wrap: wrap; gap: 5px; }
.sa-case-body { padding: 12px 14px; }
.sa-case-meta { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 10px; }
.sa-case-meta > div { display: flex; flex-direction: column; }
.sa-case-meta em { font-style: normal; font-size: 10.5px; color: var(--muted); }
.sa-case-meta b { font-size: 12.8px; font-weight: 600; margin-top: 1px; }
.sa-case-flow { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
.sa-case-stage { display: flex; align-items: flex-start; gap: 8px; font-size: 12px; line-height: 1.7; color: var(--text-2); }
.sa-case-stage-label { flex: none; font-size: 11px; color: var(--primary); background: var(--primary-soft); padding: 1px 8px; border-radius: 5px; margin-top: 3px; white-space: nowrap; }
.sa-case-stage-body { min-width: 0; flex: 1; }
.sa-case-moves { font-size: 11.5px; color: var(--muted); line-height: 1.75; margin-top: 1px; }
.sa-case-moves b { color: var(--text-2); font-weight: 600; }
.sa-case-summary { font-size: 12.5px; line-height: 1.8; color: var(--text-2); padding: 9px 11px; background: #f7f9fc; border-radius: 8px; }

/* 订单列表：流程进度条（一眼看出这单走到第几段、卡在谁手上） */
.fl-bar { height: 4px; border-radius: 2px; background: #eef1f5; overflow: hidden; margin: 5px 0 4px; }
.fl-bar i { display: block; height: 100%; background: #0d9488; border-radius: 2px; }

/* ==================================================================
 * 业务侧「订单管理」（2026-11-13）
 * 与订单中心的区别：这里看的是单子交出去之后「到哪一步、卡在谁、文件在哪」
 * ================================================================== */
/* 业务大类页签：横向可滚，数量多也不换行挤压 */
.om-cats { display: flex; gap: 8px; overflow-x: auto; padding: 2px 0 10px; scrollbar-width: thin; }
.om-cats::-webkit-scrollbar { height: 5px; }
.om-cats::-webkit-scrollbar-thumb { background: #d8dce3; border-radius: 3px; }
.om-cat {
  flex: 0 0 auto; border: 1px solid var(--border); background: #fff; color: var(--text-2);
  border-radius: 8px; padding: 7px 13px; font-size: 13px; cursor: pointer; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 7px; transition: .15s;
}
.om-cat span { font-size: 11.5px; color: var(--muted); background: #f2f4f7; border-radius: 9px; padding: 1px 7px; }
.om-cat:hover { border-color: var(--border-strong); color: var(--text); }
.om-cat.on { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); font-weight: 600; }
.om-cat.on span { background: #fff; color: var(--primary); }

.om-filter { padding: 12px 14px; margin-bottom: 12px; }
.om-frow { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.om-frow input[type="search"] { flex: 1 1 220px; min-width: 180px; max-width: 320px; padding: 7px 10px; font-size: 13px; }
.om-frow input[type="date"] { width: 138px; padding: 7px 8px; font-size: 12.5px; }
.om-dash { color: var(--muted); font-size: 12px; }
.om-hint { margin-top: 9px; font-size: 12px; color: var(--muted); line-height: 1.6; }

.om-states { margin-bottom: 10px; flex-wrap: wrap; }
.om-table td { vertical-align: middle; }
.om-table tbody tr { cursor: pointer; }
.om-table tbody tr:hover td { background: #f8fafd; }
.om-prog { height: 5px; border-radius: 3px; background: #eef1f5; overflow: hidden; width: 84px; }
.om-prog i { display: block; height: 100%; background: #0d9488; border-radius: 3px; }
.om-over { color: var(--danger); font-weight: 500; }
.cell-sub.om-over { color: var(--danger); }

/* 详情抽屉 */
.om-detail { font-size: 13px; }
.om-sum { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px 16px; padding: 12px 14px;
  background: #f8fafd; border-radius: 10px; margin-bottom: 16px; }
.om-sum > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.om-sum label { font-size: 11.5px; color: var(--muted); }
.om-sum b { font-size: 13.5px; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.om-h4 { font-size: 13.5px; margin: 18px 0 9px; padding-left: 9px; border-left: 3px solid var(--primary); line-height: 1.2; }

.om-flow { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.om-step { display: flex; gap: 11px; padding: 10px 13px; border-bottom: 1px solid #f0f2f5; }
.om-step:last-child { border-bottom: none; }
.om-step-dot { flex: 0 0 22px; height: 22px; border-radius: 50%; background: #eef1f5; color: #6b7280;
  font-size: 11.5px; display: flex; align-items: center; justify-content: center; font-weight: 600; }
.om-step.done .om-step-dot { background: var(--success-soft); color: #15803d; }
.om-step.doing .om-step-dot { background: var(--primary-soft); color: var(--primary); }
.om-step.rejected .om-step-dot { background: var(--danger-soft); color: var(--danger); }
.om-step-body { min-width: 0; flex: 1; }
.om-step-name { font-size: 13px; font-weight: 500; color: var(--text); display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.om-step.done .om-step-name { color: var(--text-2); }
.om-step-meta { font-size: 11.5px; color: var(--muted); margin-top: 3px; line-height: 1.5; }
.om-step-note { font-size: 12px; color: var(--text-2); margin-top: 4px; background: #fafbfd; padding: 5px 8px; border-radius: 6px; }
.om-need { font-size: 10.5px; color: #a15c07; background: var(--warn-soft); border-radius: 4px; padding: 1px 6px; font-weight: 500; }

.om-fgroup { border: 1px solid var(--border); border-radius: 10px; margin-bottom: 9px; overflow: hidden; }
.om-fg-head { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px;
  background: #f8fafd; font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.om-fg-head span { color: var(--muted); font-weight: 400; font-size: 11.5px; }
.om-file { display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 12px; border-top: 1px solid #f2f4f7; }
.om-file-main { min-width: 0; flex: 1; }
.om-file-main a { color: var(--primary); text-decoration: none; font-size: 13px; }
.om-file-main a:hover { text-decoration: underline; }
.om-file-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.om-events { border-left: 2px solid #eef1f5; padding-left: 13px; }
.om-ev { font-size: 12.5px; color: var(--text-2); padding: 4px 0; line-height: 1.55; }
.om-ev-t { color: var(--muted); font-size: 11.5px; margin-right: 8px; }
.om-pick { border: 1px dashed var(--border-strong); border-radius: 8px; padding: 16px; text-align: center;
  color: var(--muted); font-size: 13px; cursor: pointer; }
.om-pick:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.om-actions { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--border); display: flex; gap: 8px; }

@media (max-width: 1080px) {
  .om-sum { grid-template-columns: repeat(2, 1fr); }
}
.om-nowrap { white-space: nowrap; }

/* ==================================================================
 * 部门工作台（2026-11-13）
 * 七个部门共用一套骨架，只换标题与数据，避免每个部门长成另一个系统
 * ================================================================== */
.dk-badge { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px;
  border-radius: 6px; font-size: 12px; font-weight: 600; margin-right: 8px; vertical-align: 1px;
  background: var(--primary-soft); color: var(--primary); }
.dk-badge.finance { background: var(--warn-soft); color: #a15c07; }
.dk-badge.legal { background: #f3eeff; color: #6d28d9; }
.dk-badge.hr { background: var(--success-soft); color: #15803d; }
.dk-badge.field { background: #f1f2f5; color: #5b636e; }
.dk-badge.gm { background: var(--danger-soft); color: #b91c1c; }
.dk-badge.delivery { background: #e7f7f2; color: #0f766e; }

.dk-sections { display: grid; grid-template-columns: 1fr; gap: 16px; }.dk-sec .card-head { padding: 13px 16px; border-bottom: 1px solid var(--border); }
.dk-sec .card-head h3 { font-size: 14px; display: flex; align-items: center; gap: 8px; }
.dk-count { font-size: 11.5px; font-weight: 500; color: var(--muted); background: #f2f4f7;
  border-radius: 9px; padding: 1px 7px; }
.dk-table th { font-size: 12px; }
.dk-table td { font-size: 12.8px; }
.dk-table tbody tr[data-url] { cursor: pointer; }
.dk-table tbody tr[data-url]:hover td { background: #f8fafd; }
.dk-first { font-weight: 500; }
.dk-act-col { width: 84px; text-align: right; white-space: nowrap; }
.dk-act-col .btn { padding: 3px 10px; font-size: 12px; }
.dk-table tbody tr[data-url]:hover .dk-act-col .btn { border-color: var(--primary); color: var(--primary); }
.dk-table tr.t-red .dk-first .cell-main { color: var(--danger); }
.dk-table tr.t-amber .dk-first .cell-main { color: #a15c07; }
.dk-empty { padding: 4px 16px 16px; }
.dk-sec > .dk-empty .empty, .dk-sec .dk-empty .empty { padding: 26px 12px; }
.dk-sec .empty { padding: 30px 16px; }
.dk-sec .empty .big { font-size: 24px; margin-bottom: 6px; }
.dk-sec .empty p { font-size: 13px; }
.dk-sec .empty .tip { font-size: 12px; margin-top: 4px; }

/* ===== 人事页签式工作台（2026-11-13）===== */
.dk-tabs-wrap { display: flex; flex-direction: column; gap: 16px; }
.dk-tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); padding-bottom: 0; }
.dk-tab { position: relative; padding: 10px 18px; font-size: 13.5px; font-weight: 500; color: var(--muted);
  cursor: pointer; border-radius: 8px 8px 0 0; display: flex; align-items: center; gap: 7px;
  white-space: nowrap; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.dk-tab:hover { color: var(--text); background: #f8fafd; }
.dk-tab.on { color: var(--primary); font-weight: 600; border-bottom-color: var(--primary); }
.dk-tab-badge { font-size: 11px; font-weight: 600; color: var(--primary); background: var(--primary-soft);
  border-radius: 9px; padding: 0 7px; line-height: 17px; }
.dk-tab.on .dk-tab-badge { background: var(--primary); color: #fff; }
.dk-tab-pane { display: none; }
.dk-tab-pane.on { display: block; }

/* 运营总览：主卡 + 右侧 mini 卡，两端严格对齐 */
.hr-ov { display: grid; grid-template-columns: 1.35fr repeat(7, minmax(0, 1fr)); gap: 8px; align-items: stretch; }
.hr-ov-main { display: contents; }
.hr-ov-main-legacy { flex: 1; display: flex; gap: 0; background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; overflow: hidden; min-width: 0; }
.hr-ov-big { display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; padding: 16px 10px; background: linear-gradient(135deg, var(--primary-soft), #fff);
  border: 1px solid var(--border); border-radius: 12px; min-width: 0; }
.hr-ov-big b { font-size: 30px; font-weight: 700; color: var(--primary); line-height: 1.05; }
.hr-ov-big span { font-size: 12px; color: var(--muted); white-space: nowrap; }
.hr-ov-item { display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; padding: 16px 8px; background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; min-width: 0; }
.hr-ov-item b { font-size: 24px; font-weight: 700; color: var(--text); line-height: 1.05; font-variant-numeric: tabular-nums; }
.hr-ov-item span { font-size: 12px; color: var(--muted); white-space: nowrap; }
.hr-ov-item.warn b { color: #a15c07; }
.hr-ov-item.danger b { color: var(--danger); }
.hr-ov-side { display: contents; }
.hr-ov-mini { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  padding: 16px 8px; background: var(--card); border: 1px solid var(--border); border-radius: 12px; min-width: 0; }
.hr-ov-mini b { font-size: 24px; font-weight: 700; color: var(--text); line-height: 1.05; font-variant-numeric: tabular-nums; }
.hr-ov-mini span { font-size: 12px; color: var(--muted); white-space: nowrap; }
.hr-ov-mini.danger b { color: var(--danger); }
.hr-ov-mini.danger b { color: var(--danger); }

/* 花名册工具栏 */
.hr-toolbar { display: flex; gap: 10px; align-items: center; }
.hr-search { flex: 1; max-width: 320px; }
.hr-filter { max-width: 180px; }

/* 员工档案抽屉 */
.hr-prof-head { display: flex; align-items: center; gap: 12px; padding-bottom: 14px;
  border-bottom: 1px solid var(--border); margin-bottom: 14px; }
.hr-prof-avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--primary-soft);
  color: var(--primary); font-size: 20px; font-weight: 700; display: flex; align-items: center;
  justify-content: center; flex: none; }
.hr-prof-name { font-size: 16px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.hr-prof-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hr-kv-list { display: flex; flex-direction: column; }
.hr-kv { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0;
  border-bottom: 1px dashed var(--border); }
.hr-kv span { color: var(--muted); font-size: 12.5px; }
.hr-kv b { font-weight: 500; font-size: 13px; text-align: right; }

/* 360° 档案关键指标卡 + 子页签 */
.hr-prof-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px; }
.hr-prof-kpi { display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 12px 8px; background: var(--bg); border: 1px solid var(--border); border-radius: 10px; }
.hr-prof-kpi b { font-size: 20px; font-weight: 700; color: var(--text); line-height: 1; }
.hr-prof-kpi span { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.hr-prof-kpi.warn b { color: #a15c07; }
.hr-prof-subtabs { margin-bottom: 0; }
.hr-prof-subtabs .dk-subtab i { font-style: normal; font-size: 10.5px; color: var(--primary);
  background: var(--primary-soft); border-radius: 8px; padding: 0 5px; margin-left: 3px; line-height: 15px; }
.hr-prof-pane { display: none; padding-top: 14px; }
.hr-prof-pane.on { display: block; }
.hr-prof-pane .card { padding: 0; }
.hr-prof-pane .card .card-head { padding: 12px 16px; }
.hr-prof-pane .card .hr-tl,
.hr-prof-pane .card .hr-kv-list,
.hr-prof-pane .card .hr-cl { padding: 6px 16px 14px; }
/* onboarding checklist */
.hr-cl { display: flex; flex-direction: column; gap: 6px; }
.hr-cl-item { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text); }
.hr-cl-item.done { color: var(--muted); }
.hr-cl-dot { width: 16px; height: 16px; border-radius: 50%; border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center; font-size: 11px; color: var(--primary);
  flex: none; background: #fff; }
.hr-cl-item.done .hr-cl-dot { background: var(--primary-soft); border-color: var(--primary); color: var(--primary); }

/* 生命周期时间轴 */
.hr-tl { display: flex; flex-direction: column; padding: 4px 0; }
.hr-tl-item { position: relative; display: flex; align-items: center; gap: 10px; padding: 9px 0 9px 18px; }
.hr-tl-item::before { content: ''; position: absolute; left: 4px; top: 0; bottom: 0; width: 2px;
  background: var(--border); }
.hr-tl-item:first-child::before { top: 12px; }
.hr-tl-item:last-child::before { bottom: calc(100% - 12px); }
.hr-tl-dot { position: absolute; left: 0; top: 14px; width: 10px; height: 10px; border-radius: 50%;
  background: var(--muted); border: 2px solid #fff; box-shadow: 0 0 0 1px var(--border); }
.hr-tl-item.tl-green .hr-tl-dot { background: #16a34a; }
.hr-tl-item.tl-blue .hr-tl-dot { background: var(--primary); }
.hr-tl-item.tl-amber .hr-tl-dot { background: #d97706; }
.hr-tl-item.tl-red .hr-tl-dot { background: var(--danger); }
.hr-tl-date { font-size: 12px; color: var(--muted); min-width: 84px; }
.hr-tl-title { font-size: 13px; font-weight: 500; }

/* 人事经营驾驶舱（2026-11-13） */
.hr-dash { display: flex; flex-direction: column; gap: 16px; }
.hr-dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.hr-dash-grid > .card { min-width: 0; overflow: hidden; }
.hr-ai-box { border: 1px dashed var(--border); border-radius: 10px; padding: 16px; min-height: 40px;
  background: var(--bg); }
.hr-ai-text { font-size: 13.5px; line-height: 1.9; color: var(--text); white-space: pre-wrap;
  word-break: break-word; }
.hr-funnel { display: flex; flex-direction: column; gap: 11px; padding: 14px 16px 4px; }
.hr-funnel-step { display: grid; grid-template-columns: 92px minmax(0, 1fr) 40px; align-items: center; gap: 12px; }
.hr-funnel-label { font-size: 12.5px; color: var(--muted); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-funnel-bar { flex: 1; height: 18px; background: var(--primary-soft); border-radius: 6px; overflow: hidden; }
.hr-funnel-fill { height: 100%; background: linear-gradient(90deg, var(--primary), #6c8cff);
  border-radius: 6px; transition: width .3s; min-width: 2px; }
.hr-funnel-num { text-align: right; font-size: 13px; font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }
.hr-dash-sub { display: flex; gap: 12px; margin-top: 16px; }
.hr-dash-kpi { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 14px 10px; background: var(--bg); border: 1px solid var(--border); border-radius: 10px; }
.hr-dash-kpi b { font-size: 22px; font-weight: 700; color: var(--text); line-height: 1; }
.hr-dash-kpi span { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.hr-dash-kpi.danger b { color: var(--danger); }
.hr-rank { display: flex; flex-direction: column; gap: 9px; padding: 2px 6px 2px 4px; }
.hr-rank-row { display: grid; grid-template-columns: 108px minmax(0, 1fr) 40px; align-items: center; gap: 10px; min-width: 0; }
.hr-rank-name { font-size: 12.5px; color: var(--text); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-rank .hr-bar { min-width: 20px; }
.hr-bar { flex: 1; height: 12px; background: var(--bg); border-radius: 6px; overflow: hidden; }
.hr-bar-fill { height: 100%; background: var(--primary); border-radius: 6px; min-width: 2px; }
.hr-rank-num { text-align: right; font-size: 12.5px; font-weight: 600; color: var(--muted); font-variant-numeric: tabular-nums; }

/* 薪酬成本页签（2026-11-13） */
.hr-pay-kpis { display: flex; gap: 12px; padding: 16px 16px 4px; }
.hr-pay-kpis .hr-dash-kpi { flex: 1; }
.hr-quota-list { display: flex; flex-direction: column; gap: 8px; padding: 4px 16px 16px; }
.hr-quota-row { display: grid; grid-template-columns: minmax(0, 1fr) 64px 76px; align-items: center; gap: 12px; padding: 9px 12px;
  background: var(--bg); border-radius: 8px; }
.hr-quota-dept { font-size: 13px; font-weight: 500; color: var(--text); flex: none; min-width: 0; }
.hr-quota-dept i { font-style: normal; font-size: 11px; }
.hr-quota-num { font-size: 12.5px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.hr-inv-list { display: flex; flex-direction: column; gap: 10px; padding: 4px 16px 16px; }
.hr-inv-item { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px;
  background: #fff7f7; border: 1px solid #f4c7c7; border-radius: 8px; }
.hr-inv-line { font-size: 13px; color: var(--text); }
.hr-inv-line.muted { color: var(--muted); font-size: 12.5px; }
.hr-inv-item .tag { align-self: flex-start; }

/* 人才发展：九宫格 + 梯队 */
@media (max-width: 1420px) {
  .hr-ov { grid-template-columns: 1.2fr repeat(3, minmax(0, 1fr)); }
}
.hr-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: 1fr; gap: 10px; padding: 14px 16px 16px; }
.hr-grid-cell { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 12px 10px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 10px; min-height: 92px; min-width: 0; }
.hr-grid-cell.green { border-color: #b6e0c5; background: #f0faf3; }
.hr-grid-cell.blue { border-color: #c3d7fb; background: #f2f7ff; }
.hr-grid-cell.amber { border-color: #f0d5a8; background: #fff8ec; }
.hr-grid-cell.red { border-color: #f4c7c7; background: #fff7f7; }
.hr-grid-label { font-size: 12.5px; font-weight: 600; color: var(--text); }
.hr-grid-count { font-size: 22px; font-weight: 700; line-height: 1; color: var(--text); }
.hr-grid-members { display: flex; flex-wrap: wrap; gap: 4px; justify-content: center; }
.hr-grid-members span { font-size: 11px; color: var(--muted); background: #fff; border: 1px solid var(--border);
  border-radius: 9px; padding: 1px 7px; }
.hr-grid-list { display: flex; flex-direction: column; gap: 6px; padding: 0 16px 16px; }
.hr-grid-row { display: grid; grid-template-columns: 80px minmax(0, 1fr) 76px 76px 84px; align-items: center; gap: 12px;
  padding: 9px 14px; background: var(--bg); border-radius: 8px; }
.hr-grid-name { font-size: 13px; font-weight: 500; color: var(--text); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-grid-score { font-size: 12.5px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; margin: 0; }
.hr-grid-row .tag { flex: none; justify-self: end; }
.hr-pipe-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 16px; font-size: 12.5px; }
.hr-pipe-chip i { font-style: normal; font-size: 11px; color: var(--primary); }

/* 留存关怀页签（2026-11-13）：离职风险 / 关怀节点 / eNPS */
.hr-risk-list { display: flex; flex-direction: column; gap: 10px; padding: 4px 16px 12px; }
.hr-risk-item { display: flex; flex-direction: column; gap: 8px; padding: 11px 13px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 10px; }
.hr-risk-head { display: flex; align-items: center; gap: 10px; }
.hr-risk-name { font-size: 13.5px; font-weight: 600; color: var(--text); }
.hr-risk-score { font-size: 14px; font-weight: 700; margin-left: auto; flex: none; }
.hr-risk-score.danger { color: var(--danger); }
.hr-risk-score.warn { color: #e6a23c; }
.hr-risk-reasons { display: flex; flex-wrap: wrap; gap: 6px; }
.hr-risk-tag { font-size: 11px; color: var(--muted); background: #fff; border: 1px solid var(--border);
  border-radius: 9px; padding: 2px 8px; }
.hr-risk-mid { display: flex; flex-direction: column; gap: 5px; padding: 0 16px 16px; }
.hr-risk-mid-row { display: grid; grid-template-columns: 96px minmax(0, 1fr) 52px; align-items: center; gap: 10px;
  padding: 6px 10px; background: var(--bg); border-radius: 8px; }
.hr-risk-mid-row .tiny { text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-risk-mid-row .hr-grid-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-risk-mid-row .hr-risk-score { font-size: 12.5px; }
.hr-care-list { display: flex; flex-direction: column; gap: 7px; padding: 4px 16px 16px; }
.hr-care-row { display: grid; grid-template-columns: 52px minmax(0, 1fr) 84px 50px; align-items: center; gap: 10px;
  padding: 8px 12px; background: var(--bg); border-radius: 8px; }
.hr-care-row .hr-grid-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-care-row .hr-grid-name i { font-style: normal; font-size: 11.5px; color: var(--muted); margin-left: 6px; }
.hr-care-row .tiny { text-align: right; white-space: nowrap; }
.hr-care-at { font-size: 12.5px; font-weight: 600; color: var(--text); text-align: right; white-space: nowrap; }
.hr-enps-list { display: flex; flex-direction: column; gap: 8px; padding: 4px 16px 16px; }
.hr-enps-row { display: flex; align-items: center; gap: 12px; padding: 11px 13px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 10px; cursor: pointer;
  transition: border-color .15s; }
.hr-enps-row:hover { border-color: var(--primary); }
.hr-enps-main { flex: 1; min-width: 0; }
.hr-enps-title { font-size: 13.5px; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.hr-enps-nps { font-size: 22px; font-weight: 700; color: var(--text); flex: none; width: 56px; text-align: center; }
.hr-enps-nps.good { color: #22a06b; }
.hr-enps-nps.bad { color: var(--danger); }
.hr-enps-ans { display: flex; align-items: center; gap: 12px; padding: 8px 12px;
  background: var(--bg); border-radius: 8px; }
.hr-enps-ans-name { font-size: 13px; font-weight: 500; color: var(--text); min-width: 56px; }
.hr-enps-ans-score { font-size: 14px; font-weight: 700; color: var(--text); width: 30px; text-align: center; flex: none; }
.hr-enps-ans-score.good { color: #22a06b; }
.hr-enps-ans-score.bad { color: var(--danger); }
.hr-dash-kpi.warn b { color: #e6a23c; }

/* 人才画像 persona（2026-11-13）：性格画像 / 能力雷达 / 人才标签 */
.hr-persona-meta { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 16px 4px; }
.hr-persona-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 10px; }
.hr-persona-chip i { font-style: normal; font-size: 14px; font-weight: 700; color: var(--primary); }
.hr-persona-chip span { font-size: 11.5px; color: var(--muted); }
.hr-radar { display: flex; flex-direction: column; gap: 10px; padding: 4px 16px 16px; }
.hr-radar-row { display: flex; align-items: center; gap: 10px; }
.hr-radar-k { width: 40px; font-size: 12.5px; color: var(--text); flex: none; }
.hr-radar-bar { flex: 1; height: 12px; background: var(--bg); border-radius: 6px; overflow: hidden; }
.hr-radar-fill { height: 100%; background: linear-gradient(90deg, var(--primary), #6c8cff); border-radius: 6px; min-width: 2px; }
.hr-radar-v { width: 28px; text-align: right; font-size: 12.5px; font-weight: 600; color: var(--muted); flex: none; }
.hr-persona-body { padding: 4px 16px 16px; }
.hr-persona-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.hr-tag { font-size: 12px; color: var(--primary); background: var(--primary-soft); border-radius: 9px; padding: 3px 10px; }
.hr-radar-edit { display: flex; flex-direction: column; gap: 8px; padding: 8px 0; }
.hr-radar-edit-row { display: flex; align-items: center; gap: 10px; }
.hr-radar-edit-row span { width: 40px; font-size: 12.5px; color: var(--text); flex: none; }
.hr-radar-edit-row input[type=range] { flex: 1; }
.hr-radar-edit-row b { width: 30px; text-align: right; font-size: 12.5px; font-weight: 600; color: var(--primary); flex: none; }

/* 候选人测评画像：优势/待提升 kv 行 */
.hr-kv-k { color: var(--muted); font-size: 12.5px; flex: none; width: 56px; }
.hr-kv-v { font-size: 13px; color: var(--text); line-height: 1.6; flex: 1; text-align: left; }

/* 团队搭配 */
.hr-team-mates { display: flex; flex-direction: column; gap: 8px; }
.hr-team-mate { padding: 10px 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg); }
.hr-team-mate-h { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-bottom: 4px; }
.hr-team-mate-h b { font-size: 13.5px; }
.hr-team-mate .tiny { line-height: 1.55; }

/* 简历 AI 解析（收简历弹窗） */
.hr-resume-parse { display: flex; gap: 8px; margin-bottom: 4px; }
.hr-resume-parse .btn { flex: 1; }
.hr-resume-ai { border: 1px dashed var(--border); border-radius: 10px; padding: 12px; margin: 10px 0 4px; background: var(--bg); }
.hr-resume-divider { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 11.5px; margin: 10px 0; }
.hr-resume-divider::before, .hr-resume-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.hr-resume-done-h { font-size: 13px; font-weight: 600; color: #22a06b; margin-bottom: 8px; }
.hr-resume-persona { display: flex; flex-direction: column; gap: 5px; font-size: 12.5px; line-height: 1.6; }
.hr-resume-score { font-size: 13px; }
.hr-resume-score b { color: var(--primary); font-size: 16px; }

/* 候选人沟通结构化（沟通弹窗） */
.hr-comm-item { padding: 10px 0; border-bottom: 1px dashed var(--border); }
.hr-comm-item:last-child { border-bottom: none; }
.hr-comm-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.hr-comm-date { font-size: 12px; color: var(--muted); }
.hr-comm-content { font-size: 13px; line-height: 1.7; color: var(--text); white-space: pre-wrap; }
.hr-comm-hl { font-size: 12.5px; margin-top: 6px; padding: 7px 10px; background: #f2f7ff; border-left: 3px solid var(--primary); border-radius: 4px; color: var(--text); }
.hr-comm-hl b { color: var(--primary); margin-right: 6px; }
.hr-comm-ai { font-size: 12.5px; line-height: 1.7; margin-top: 6px; padding: 8px 10px; background: var(--bg); border-radius: 6px; color: var(--text); }
.hr-comm-next { font-size: 12.5px; margin-top: 6px; color: var(--text); }
.hr-comm-next b { color: #22a06b; margin-right: 6px; }
.hr-comm-trans { font-size: 12px; margin-top: 6px; color: var(--muted); }
.hr-comm-trans summary { cursor: pointer; color: var(--primary); }
.hr-comm-trans div { margin-top: 4px; padding: 8px 10px; background: var(--bg); border-radius: 6px; white-space: pre-wrap; line-height: 1.7; max-height: 200px; overflow-y: auto; }
.hr-comm-form { border-top: 1px solid var(--border); padding-top: 12px; }
.hr-comm-form-h { font-size: 13.5px; font-weight: 600; color: var(--text); margin-bottom: 10px; }
.hr-comm-ops { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.hr-comm-ai-box { margin-top: 10px; }
.hr-comm-ai-res { border: 1px solid var(--border); border-radius: 10px; padding: 12px; background: var(--bg); font-size: 12.5px; line-height: 1.7; }
.hr-comm-ai-res .hr-comm-hl { margin-top: 0; }

/* 人才测评调研问卷（2026-11-13） */
.hr-survey-pushees { display: flex; flex-wrap: wrap; gap: 6px; max-height: 160px; overflow-y: auto; padding: 8px; border: 1px solid var(--border); border-radius: 8px; }
.hr-survey-pushee { display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; background: var(--bg); border: 1px solid var(--border); border-radius: 14px; font-size: 12.5px; cursor: pointer; }
.hr-survey-pushee input { margin: 0; }
.hr-survey-pushes { display: flex; flex-direction: column; gap: 6px; }
.hr-survey-push-row { display: grid; grid-template-columns: minmax(0, 1fr) 72px 60px; align-items: center; gap: 10px;
  padding: 8px 12px; background: var(--bg); border-radius: 8px; font-size: 13px; }
.hr-survey-push-row .spacer { display: none; }
.hr-survey-push-row .tag { justify-self: end; }
.hr-survey-qs { display: flex; flex-direction: column; gap: 12px; }
.hr-survey-q { padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; }
.hr-survey-q-prompt { font-size: 13.5px; font-weight: 500; color: var(--text); margin-bottom: 8px; }
.hr-survey-q-opts { display: flex; flex-wrap: wrap; gap: 6px; }
.hr-survey-opt { font-size: 12.5px; padding: 4px 10px; background: var(--bg); border-radius: 6px; color: var(--muted); }

/* 劳动合同存档（2026-11-13） */
.hr-contract-list { display: flex; flex-direction: column; gap: 10px; padding: 4px 16px 16px; }
.hr-contract-item { border: 1px solid var(--border); border-radius: 10px; padding: 12px; }
.hr-contract-head { display: flex; align-items: center; gap: 8px; }
.hr-contract-head b { font-size: 14px; color: var(--text); }
.hr-contract-head .spacer { flex: 1; }
.hr-contract-meta { display: flex; flex-direction: column; gap: 2px; margin-top: 8px; font-size: 12.5px; color: var(--text); }
.hr-contract-ops { display: flex; gap: 8px; margin-top: 10px; align-items: center; }

/* 智能招聘：子页签 + 话术 */
.dk-subtabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 14px; }
.dk-subtab { padding: 8px 14px; font-size: 13px; font-weight: 500; color: var(--muted); cursor: pointer;
  border-bottom: 2px solid transparent; }
.dk-subtab:hover { color: var(--text); }
.dk-subtab.on { color: var(--primary); font-weight: 600; border-bottom-color: var(--primary); }
.hr-reply-item { padding: 10px 0; border-bottom: 1px dashed var(--border); }
.hr-reply-item:last-child { border-bottom: none; }
.hr-reply-title { font-size: 12.5px; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.hr-reply-content { font-size: 13px; line-height: 1.7; color: var(--text); }
.hr-reply-ops { display: flex; gap: 6px; margin-top: 6px; }

@media (max-width: 900px) {
  .hr-ov { flex-direction: column; }
  .hr-ov-side { flex-direction: row; min-width: 0; }
  .hr-prof-grid { grid-template-columns: 1fr; }
  .hr-dash-grid { grid-template-columns: 1fr; }
}

/* 本部门提醒条：横向排列的小卡片，逾期标红，点击跳到对应办理页 */
.dk-remind { padding: 10px 12px 12px; border-left: 3px solid var(--primary); }
.dk-remind-h { display: flex; align-items: center; gap: 8px; padding: 0 2px 8px; }
.dk-remind-t { font-size: 13.5px; font-weight: 600; color: var(--text); }
.dk-remind-list { display: flex; flex-wrap: wrap; gap: 8px; }
.dk-rm { display: flex; align-items: flex-start; gap: 7px; flex: 1 1 330px; max-width: 460px;
  padding: 7px 10px;
  border: 1px solid var(--border); border-radius: 8px; background: var(--card); cursor: pointer;
  transition: border-color .15s, background .15s; }
.dk-rm:hover { border-color: var(--primary); background: var(--primary-soft); }
.dk-rm-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--primary); margin-top: 5px; flex: none; }
.dk-rm.is-late { border-color: #f4c7c7; background: #fff7f7; }
.dk-rm.is-late .dk-rm-dot { background: var(--danger); }
.dk-rm-body { min-width: 0; flex: 1; }
.dk-rm-t { font-size: 12.8px; font-weight: 500; color: var(--text); line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dk-rm-s { font-size: 11.5px; color: var(--muted); margin-top: 2px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (min-width: 1500px) {
  .dk-sections { grid-template-columns: 1fr 1fr; }
  .dk-sec:first-child { grid-column: 1 / -1; }
}

/* AI 辅助输出：模型返回的是纯文本，保留换行但不撑破抽屉 */
.dk-ai-text { font-size: 13.4px; line-height: 1.85; color: var(--text); word-break: break-word; }
.dk-ai-text .hit { color: var(--primary); font-weight: 600; }

/* ==================================================================
 * 人事第二批 UI（2026-11-13）：排版修复 + 新模块
 * ================================================================== */

/* 通用：卡片内表格不要顶到边框 */
.dk-sec > .table-wrap { padding: 0 4px 8px; }
.dk-sec > .table-wrap > table { margin: 0; }

/* 弹窗内表格/列表的左右呼吸感 */
.modal .table-wrap { margin: 0 2px; }

/* ---------- 考勤：上传解析预览 ---------- */
.hr-import-drop { display: flex; align-items: center; gap: 14px; padding: 18px 16px;
  border: 1px dashed var(--border); border-radius: 10px; background: var(--bg); }
.hr-import-drop .ico { width: 42px; height: 42px; border-radius: 10px; background: var(--primary-soft);
  color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 18px; flex: none; }
.hr-import-drop .txt { flex: 1; min-width: 0; }
.hr-import-drop .txt b { display: block; font-size: 13.5px; margin-bottom: 3px; }
.hr-import-drop .txt span { font-size: 12px; color: var(--muted); line-height: 1.6; }
.hr-import-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.hr-import-tag { font-size: 12px; padding: 4px 10px; background: var(--bg); border: 1px solid var(--border);
  border-radius: 14px; color: var(--text); }
.hr-import-tag b { color: var(--primary); font-weight: 600; }
.hr-import-map { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px;
  padding: 10px 12px; background: var(--bg); border-radius: 8px; margin-bottom: 12px; }
.hr-import-map div { font-size: 12px; color: var(--muted); display: flex; gap: 6px; min-width: 0; }
.hr-import-map div b { color: var(--text); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-import-map div i { font-style: normal; color: var(--primary); flex: none; }
.hr-import-warn { font-size: 12px; color: #a15c07; background: #fff8ec; border: 1px solid #f0d5a8;
  border-radius: 8px; padding: 8px 12px; margin-bottom: 10px; line-height: 1.6; }

/* ---------- 薪资：明细 / 提成规则 / 确认 ---------- */
.hr-pay-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 0 16px 12px; }
.hr-pay-toolbar .hr-search, .hr-pay-toolbar .hr-filter { height: 32px; }
.hr-pay-sum { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; padding: 0 16px 12px; }
.hr-pay-sum .cell { background: var(--bg); border-radius: 10px; padding: 11px 12px; min-width: 0; }
.hr-pay-sum .cell b { display: block; font-size: 18px; font-weight: 700; line-height: 1.2; font-variant-numeric: tabular-nums; }
.hr-pay-sum .cell span { font-size: 11.5px; color: var(--muted); }
.hr-pay-sum .cell.good b { color: #22a06b; }
.hr-pay-sum .cell.warn b { color: #e6a23c; }
.hr-pay-sum .cell.danger b { color: var(--danger); }

/* 薪资明细表：项目/金额/说明三列 */
.hr-payslip-items { display: flex; flex-direction: column; gap: 2px; }
.hr-payslip-item { display: grid; grid-template-columns: minmax(0, 1fr) 130px; align-items: center;
  gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--border); font-size: 13px; }
.hr-payslip-item:last-child { border-bottom: 0; }
.hr-payslip-item .k { color: var(--text); min-width: 0; }
.hr-payslip-item .k i { font-style: normal; font-size: 11.5px; color: var(--muted); margin-left: 6px; }
.hr-payslip-item .v { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.hr-payslip-item.add .v { color: #22a06b; }
.hr-payslip-item.sub .v { color: var(--danger); }
.hr-payslip-total { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 12px; padding: 14px 16px; background: var(--primary-soft); border-radius: 10px; }
.hr-payslip-total span { font-size: 13px; color: var(--text); }
.hr-payslip-total b { font-size: 24px; font-weight: 700; color: var(--primary); font-variant-numeric: tabular-nums; }
.hr-payslip-note { font-size: 12px; color: var(--muted); margin-top: 8px; line-height: 1.7; }

/* 提成规则卡片 */
.hr-rule-list { display: flex; flex-direction: column; gap: 8px; }
.hr-rule-card { padding: 12px 14px; background: var(--bg); border: 1px solid var(--border); border-radius: 10px; }
.hr-rule-h { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.hr-rule-h b { font-size: 13.5px; font-weight: 600; }
.hr-rule-h .spacer { flex: 1; }
.hr-rule-meta { font-size: 12px; color: var(--muted); line-height: 1.7; }
.hr-rule-tiers { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.hr-rule-tier { font-size: 11.5px; padding: 2px 8px; background: #fff; border: 1px solid var(--border); border-radius: 9px; }

/* 确认进度条 */
.hr-confirm-bar { display: flex; height: 10px; border-radius: 6px; overflow: hidden; background: var(--bg); margin: 8px 0 6px; }
.hr-confirm-bar i { display: block; height: 100%; }
.hr-confirm-legend { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--muted); }
.hr-confirm-legend span { display: inline-flex; align-items: center; gap: 5px; }
.hr-confirm-legend i { width: 8px; height: 8px; border-radius: 2px; display: inline-block; }

/* ---------- HRBP 专属 ---------- */
.hrbp-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
.hrbp-grid > .card { min-width: 0; }
.hrbp-quick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 14px 16px 16px; }
.hrbp-quick-btn { display: flex; flex-direction: column; gap: 3px; align-items: flex-start;
  padding: 12px 14px; background: var(--bg); border: 1px solid var(--border); border-radius: 10px;
  cursor: pointer; transition: all .15s; min-width: 0; text-align: left; }
.hrbp-quick-btn:hover { border-color: var(--primary); background: var(--primary-soft); }
.hrbp-quick-btn b { font-size: 13px; font-weight: 600; color: var(--text); }
.hrbp-quick-btn span { font-size: 11.5px; color: var(--muted); line-height: 1.5; }
.hrbp-doc-list { display: flex; flex-direction: column; gap: 8px; padding: 0 16px 16px; }
.hrbp-doc-row { display: grid; grid-template-columns: minmax(0, 1fr) 128px 74px; align-items: center;
  gap: 10px; padding: 10px 12px; background: var(--bg); border-radius: 9px; cursor: pointer; }
.hrbp-doc-row:hover { background: var(--primary-soft); }
.hrbp-doc-row b { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hrbp-doc-row .tiny { text-align: right; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hrbp-doc-row .tag { justify-self: end; }
.hrbp-doc-body { padding: 16px; font-size: 13.5px; line-height: 1.9; color: var(--text); white-space: pre-wrap; }
.hrbp-doc-body h1 { font-size: 18px; font-weight: 700; margin: 14px 0 8px; }
.hrbp-doc-body h2 { font-size: 15px; font-weight: 600; margin: 14px 0 6px; }
.hrbp-camp-row { display: grid; grid-template-columns: minmax(0,1fr) 80px 72px; align-items: center; gap: 10px;
  padding: 11px 12px; background: var(--bg); border-radius: 9px; }
.hrbp-camp-row b { font-size: 13px; font-weight: 500; }
.hrbp-flow { display: flex; flex-direction: column; gap: 0; }
.hrbp-flow-row { display: grid; grid-template-columns: 108px 20px minmax(0, 1fr); gap: 8px; padding: 9px 0; position: relative; }
.hrbp-flow-time { font-size: 12px; color: var(--primary); font-weight: 600; text-align: right; }
.hrbp-flow-dot { display: flex; justify-content: center; position: relative; }
.hrbp-flow-dot::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--primary); margin-top: 6px; z-index: 1; }
.hrbp-flow-dot::after { content: ''; position: absolute; top: 6px; bottom: -9px; width: 1px; background: var(--border); }
.hrbp-flow-row:last-child .hrbp-flow-dot::after { display: none; }
.hrbp-flow-main { font-size: 13px; min-width: 0; }
.hrbp-flow-main b { font-weight: 500; }
.hrbp-flow-main span { display: block; font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.hrbp-point { padding: 11px 13px; background: var(--bg); border-radius: 9px; margin-bottom: 8px; }
.hrbp-point-h { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.hrbp-point-h i { width: 20px; height: 20px; border-radius: 50%; background: var(--primary); color: #fff;
  font-size: 11px; font-style: normal; display: flex; align-items: center; justify-content: center; flex: none; }
.hrbp-point-h b { font-size: 13px; font-weight: 600; }
.hrbp-point p { font-size: 12.5px; color: var(--muted); line-height: 1.75; margin: 0 0 4px; }
.hrbp-point p.how { color: var(--text); }
.hrbp-script { padding: 11px 13px; border-left: 3px solid var(--primary); background: var(--bg);
  border-radius: 0 9px 9px 0; margin-bottom: 9px; }
.hrbp-script .stage { font-size: 11.5px; color: var(--primary); font-weight: 600; margin-bottom: 5px; }
.hrbp-script .say { font-size: 13px; line-height: 1.8; color: var(--text); }
.hrbp-script .avoid { font-size: 11.5px; color: var(--danger); margin-top: 5px; line-height: 1.6; }
.hrbp-analysis { font-size: 13px; line-height: 1.95; white-space: pre-wrap; padding: 12px 14px;
  background: var(--bg); border-radius: 9px; }
.hrbp-notice { font-size: 12px; color: #a15c07; background: #fff8ec; border: 1px solid #f0d5a8;
  border-radius: 8px; padding: 9px 12px; margin-bottom: 12px; line-height: 1.6; }
.hrbp-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.hrbp-chip { font-size: 12px; padding: 4px 10px; background: var(--bg); border: 1px solid var(--border); border-radius: 12px; }

/* 表格数字列统一右对齐 + 等宽数字 */
.dk-table td.num, .dk-table th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* 调研模式选择（题库抽题 / AI 出题） */
.hr-smode { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.hr-smode label { display: block; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px;
  cursor: pointer; background: #fff; min-width: 0; transition: all .15s; }
.hr-smode label:hover { border-color: var(--primary); }
.hr-smode label.on { border-color: var(--primary); background: var(--primary-soft); }
.hr-smode input { display: none; }
.hr-smode b { display: block; font-size: 13px; font-weight: 600; margin-bottom: 3px; }
.hr-smode span { display: block; font-size: 11.5px; color: var(--muted); line-height: 1.55; }

@media (max-width: 760px) {
  .hr-smode { grid-template-columns: minmax(0, 1fr); }
  .hrbp-quick { grid-template-columns: minmax(0, 1fr); }
}

/* 员工自助（我的） */
.hr-self-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
.hr-self-kv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 16px; padding: 14px 16px 16px; }
.hr-self-kv .kv { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px;
  padding: 7px 10px; background: var(--bg); border-radius: 8px; min-width: 0; }
.hr-self-kv .kv span { color: var(--muted); flex: none; }
.hr-self-kv .kv b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 1180px) {
  .hrbp-grid, .hr-self-grid { grid-template-columns: minmax(0, 1fr); }
  .hrbp-quick { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hr-pay-sum { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* 招聘弹窗内部卡片：内容不贴边 + 职位卡片两列自适应 */
.rq-card { width: 100%; padding: 14px 16px; margin-bottom: 12px; }
.rq-card > .card-head { margin: -14px -16px 10px; }
.rq-card > .tiny.muted:last-child { padding: 6px 0 2px; }
.hr-pos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); gap: 12px; align-items: start; margin-bottom: 12px; }
.hr-pos-grid > .rq-card { margin-bottom: 0; }
.hr-pos-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.hr-pos-head b { flex: 1; min-width: 0; font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-pos-grid .dk-table th, .hr-pos-grid .dk-table td { padding: 6px 6px; }
.hr-pos-grid .dk-table td .btn-xs { padding: 3px 7px; font-size: 11.5px; }

/* ===== 资产行政（2026-11-13） ===== */
/* 6 个 KPI 一行铺开，窄屏降到 3 列；用 grid 定宽避免 flex 拉伸错位 */
.hr-asset-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.hr-asset-kpis .hr-dash-kpi { flex: none; min-width: 0; padding: 14px 8px; }
.hr-asset-kpis .hr-dash-kpi b { font-size: 21px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.hr-asset-kpis .hr-dash-kpi.warn b { color: #a15c07; }
.hr-asset-name { font-size: 13px; font-weight: 500; color: var(--text); min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-asset-low { color: var(--danger); font-weight: 600; }
/* 库存告急 / 最近流水：两列布局，左名称右标签，中间不出现大片空白 */
.hr-asset-lowlist { display: flex; flex-direction: column; gap: 6px; padding: 4px 16px 16px; }
.hr-asset-lowrow { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px;
  padding: 8px 12px; background: var(--bg); border-radius: 8px; min-width: 0; }
.hr-asset-lowrow .hr-grid-name { min-width: 0; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hr-asset-lowrow .hr-grid-name i { font-style: normal; }
.hr-asset-lowrow .tag { flex: none; white-space: nowrap; }
.hr-asset-ok { padding: 14px 16px 18px; font-size: 12.5px; color: var(--muted); }

/* ===== 人事月报（2026-11-13） ===== */
.hr-rep-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px;
  padding: 14px 16px 4px; }
.hr-rep-kpis .hr-dash-kpi { flex: none; min-width: 0; }
.hr-rep-kpis .hr-dash-kpi.warn b { color: #a15c07; }
/* 部门/司龄条形：名称 + 条 + 数字三列定宽，名称过长省略而不是把条挤没 */
.hr-rep-bar { display: grid; grid-template-columns: 96px minmax(0, 1fr) 44px; align-items: center; gap: 10px;
  padding: 7px 12px; background: var(--bg); border-radius: 8px; min-width: 0; }
.hr-rep-bar .hr-grid-name { font-size: 12.5px; color: var(--text); overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
/* grid 里 flex:1 不生效，进度条必须显式占满列宽，否则条是 0 宽（整行只剩名字和数字） */
.hr-rep-bar .hr-bar { display: block; width: 100%; }
.hr-rep-bar .hr-bar-fill { display: block; height: 100%; }
.hr-rep-bar b { font-size: 12.5px; font-weight: 600; text-align: right; color: var(--muted);
  font-variant-numeric: tabular-nums; }
.hr-rep-risks { display: flex; flex-direction: column; gap: 8px; padding: 4px 16px 16px; }
.hr-rep-risk { display: grid; grid-template-columns: 44px minmax(0, 1fr); align-items: center; gap: 10px;
  padding: 8px 12px; border-radius: 8px; background: var(--bg); font-size: 12.5px; color: var(--text); min-width: 0; }
.hr-rep-risk .tag { justify-self: start; }
.hr-rep-risk span:last-child { min-width: 0; overflow-wrap: break-word; }
.hr-rep-risk.high { background: #fff5f5; border: 1px solid #f6c9c9; }
.hr-rep-risk.mid { background: #fffaf0; border: 1px solid #f3ddb3; }
.hr-rep-risk.ok { background: #f4fbf7; border: 1px solid #c6ead6; }

@media (max-width: 1180px) {
  .hr-asset-kpis, .hr-rep-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hr-rep-bar { grid-template-columns: 80px minmax(0, 1fr) 40px; }
}

/* 页签多于一屏时可横向滚动，不换行、不挤成两行 */
/* 人事工作台页签一行放不下（今日待办 / 招聘 / AI 人事经理 / 员工 / 组织岗位 / 花名册 …共 15+ 个）。
   原来 overflow-x:auto + 隐藏滚动条，后面的页签被裁在屏幕外，使用者以为没有「人才」「薪酬」这些页。
   改成换行：多占一行，但谁的入口都在。 */
.dk-tabs { flex-wrap: wrap; overflow-x: visible; scrollbar-width: none; row-gap: 2px; }

/* 月报历史留存：小圆角 chip，选中的高亮 */
.hr-rep-hist { display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin-top: 14px; padding: 12px 16px; background: var(--bg); border-radius: 10px; }
.hr-rep-chip { display: inline-flex; align-items: baseline; gap: 5px; height: 28px; padding: 0 11px;
  border: 1px solid var(--border); background: var(--card); border-radius: 14px;
  font-size: 12.5px; color: var(--text); cursor: pointer; }
.hr-rep-chip i { font-style: normal; font-size: 11px; color: var(--muted); }
.hr-rep-chip:hover { border-color: var(--primary); color: var(--primary); }
.hr-rep-chip.on { border-color: var(--primary); background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.hr-rep-chip.on i { color: var(--primary); }

/* 假期额度设置：两列排布，每个假期一个「额度 + 已用」小格 */
.hr-train-quota-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.hr-quota-cell { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px;
  background: var(--bg); border-radius: 10px; min-width: 0; }
.hr-quota-cell label { font-size: 12.5px; color: var(--muted); }
.hr-quota-inputs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; min-width: 0; }
.hr-quota-inputs input { min-width: 0; }
@media (max-width: 760px) { .hr-train-quota-grid { grid-template-columns: minmax(0, 1fr); } }

/* ==================================================================
 * 卡片内容内距兜底（2026-11-13）
 * 背景：.card 本身 padding:0，内距全靠子元素各自声明。只要某个子块忘了写
 *       padding（如 .hr-kv-list / .hr-rank），文字就直接贴到卡片边线。
 * 做法：给 .dk-sec 内所有「非表头 / 非表格 / 非空态」的直接子块统一补左右内距，
 *       只设左右，不覆盖各模块自己的上下间距。
 * 影响面：仅部门工作台（.dk-sec）。业务销售板块的 .card 不带该类，不受影响。
 * ================================================================== */
.dk-sec > :not(.card-head):not(.table-wrap):not(.card-foot):not(.dk-empty):not(.dk-subtabs) {
  padding-left: 16px;
  padding-right: 16px;
}

/* 驾驶舱进度行：原来左 4px 右 6px，名字几乎贴着卡片边线 */
.hr-rank { padding: 4px 16px 16px; }
/* 月报键值区：原来完全没有内距 */
.dk-sec > .hr-kv-list { padding: 4px 16px 14px; }
/* 设置页成员表：表头单元格 10px 偏窄，跟业务 CRM 的 12px 对齐 */
.user-table th, .user-table td { padding-left: 12px; padding-right: 12px; }
/* 账号表窄屏只压中间列，首尾列保持呼吸（人眼只感知最左最右是否贴边） */
@media (max-width: 1440px) {
  .user-table thead th:first-child, .user-table tbody td:first-child { padding-left: 14px; }
  .user-table thead th:last-child, .user-table tbody td:last-child { padding-right: 14px; }
}

/* ==================================================================
 * 按钮尺寸补齐（2026-11-13）
 * 背景：代码里大量用 btn-xs，但全局从没定义过它，实际渲染成 13.5px 默认按钮，
 *       表格操作列因此挤成一团、比 btn-sm 还大，看着很不整齐。
 * ================================================================== */
.btn-xs { padding: 3px 8px; font-size: 11.5px; border-radius: 6px; min-height: 24px; gap: 4px; }
/* 选中态（签到「到/假/缺」、筛选 chip 共用） */
.btn-xs.on, .btn-sm.on, .btn.on {
  border-color: var(--primary); background: var(--primary-soft); color: var(--primary); font-weight: 600;
}

/* ===== 培训签到表（2026-11-13） ===== */
.hr-train-sign { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); }
.hr-train-sign-h { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; min-width: 0; }
.hr-train-sign-h b { font-size: 13.5px; }
.hr-train-sign-h .spacer { flex: 1; }
.hr-sign-list { display: flex; flex-direction: column; gap: 6px; max-height: 320px; overflow-y: auto; }
/* 三列定宽：姓名弹性、状态标签不压、按钮组固定，避免长姓名把按钮挤出去 */
.hr-sign-row { display: grid; grid-template-columns: minmax(0, 1fr) 84px 96px;
  align-items: center; gap: 10px; padding: 8px 12px; background: var(--bg); border-radius: 8px; min-width: 0; }
.hr-sign-name { font-size: 13px; color: var(--text); min-width: 0; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; }
.hr-sign-name i { font-style: normal; font-size: 11.5px; color: var(--muted); margin-left: 6px; }
.hr-sign-row .tag { justify-self: start; white-space: nowrap; }
.hr-sign-btns { display: flex; gap: 4px; justify-content: flex-end; }
.hr-sign-btns .btn-xs { width: 28px; padding: 3px 0; }
@media (max-width: 760px) {
  .hr-sign-row { grid-template-columns: minmax(0, 1fr) 76px 90px; gap: 8px; padding: 8px 10px; }
}

/* 汇总条：原来固定 4 列，社保 6 格会被挤成「4+2」两行、第二行右侧一片空。
   改 auto-fit：几格就几列，格数变化不用再改 CSS。 */
.hr-pay-sum { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
@media (max-width: 760px) {
  .hr-pay-sum { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* 社保申报状态提示行（不是进度条，别再塞进 .hr-confirm-bar——那里 height:10px 会把文字压扁） */
.hr-soc-tip { padding: 0 16px 10px; font-size: 12px; color: var(--muted); line-height: 1.6; }

/* ==================================================================
 * 报表中心（2026-11-14）
 * 布局：左侧报表导航 + 右侧内容。内距统一 16px，避免「文字贴卡片边」。
 * 断点：<1180 收成 2 列，<860 收成 1 列，左侧导航改横向滚动。
 * ================================================================== */
.rc-wrap {
  display: grid; grid-template-columns: 172px minmax(0, 1fr);
  gap: 16px; padding: 4px 16px 18px; align-items: start;
}
.rc-nav {
  position: sticky; top: 8px; display: flex; flex-direction: column; gap: 2px;
  padding: 6px; background: var(--bg); border-radius: 10px;
}
.rc-nav a {
  display: block; padding: 8px 10px; font-size: 13px; color: var(--text-2);
  border-radius: 7px; cursor: pointer; white-space: nowrap; border: 1px solid transparent;
}
.rc-nav a:hover { background: #fff; color: var(--text); }
.rc-nav a.on { background: #fff; color: var(--primary); font-weight: 600; border-color: var(--border); box-shadow: var(--shadow); }
.rc-body { min-width: 0; }

/* ---- 顶部 6 个核心指标 ---- */
.rc-kpis {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
  gap: 10px; margin-bottom: 14px;
}
.rc-kpi {
  padding: 12px 14px; background: var(--bg); border-radius: 12px;
  border-left: 3px solid var(--primary); min-width: 0;
}
.rc-kpi.t-green { border-left-color: #22b07d; }
.rc-kpi.t-cyan { border-left-color: #0ea5e9; }
.rc-kpi.t-orange { border-left-color: #f5a623; }
.rc-kpi.t-red { border-left-color: #e5544b; }
.rc-kpi.t-teal { border-left-color: #14b8a6; }
.rc-kpi-l {
  font-size: 12px; color: var(--muted); margin-bottom: 6px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.rc-kpi-v { font-size: 22px; font-weight: 600; color: var(--text); line-height: 1.2; }
.rc-kpi-v i { font-size: 12px; font-weight: 400; font-style: normal; color: var(--muted); margin-left: 3px; }
.rc-kpi-d { margin-top: 6px; font-size: 11.5px; color: var(--muted); display: flex; gap: 5px; align-items: center; }
.rc-kpi-d .up { color: #22b07d; }
.rc-kpi-d .down { color: #e5544b; }
.rc-kpi-d em { font-style: normal; }

/* ---- 9 个分析板块 ---- */
.rc-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.rc-block {
  border: 1px solid var(--border); border-radius: 12px; padding: 14px 18px 16px;
  min-width: 0; background: #fff; display: flex; flex-direction: column;
  /* 窄屏下单行数字（如 7.69%）可能撑出边框，裁掉比露出卡片外好看 */
  overflow: hidden;
}
.rc-block-head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; min-width: 0; }
.rc-block-head h4 { font-size: 13.5px; font-weight: 600; color: var(--text); white-space: nowrap; }
.rc-block-body { min-width: 0; flex: 1; }
.rc-donut { display: flex; justify-content: center; }
.rc-empty { padding: 24px 0; text-align: center; font-size: 12.5px; color: var(--muted); }
.rc-foot { margin-top: 8px; font-size: 11.5px; color: var(--muted); line-height: 1.6; }

/* 排行/进度条行：统一 4 段网格。末两列给足宽度，否则百分比（如 7.69%）
   在窄列里会向左溢出到卡片内边距外，被贴边审计判为 -6px。 */
.rc-ranks { display: flex; flex-direction: column; gap: 9px; }
.rc-rank {
  display: grid; grid-template-columns: minmax(0, 84px) minmax(0, 1fr) 60px 52px;
  align-items: center; gap: 8px; font-size: 12px; min-width: 0;
}
.rc-rank-l { color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rc-rank-track { height: 8px; border-radius: 4px; background: var(--bg); overflow: hidden; min-width: 0; }
.rc-rank-track i { display: block; height: 100%; border-radius: 4px; background: var(--primary); }
.rc-rank b { text-align: right; font-weight: 600; color: var(--text); }
.rc-rank em { font-style: normal; text-align: right; font-size: 11.5px; color: var(--muted); }

/* 籍贯双列表：必须用 minmax(0,1fr)，1fr 的 min-width 是 auto，
   表格的固有最小宽度会把两列一起撑破，文字溢到卡片边框外（曾报 -6px）。 */
.rc-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.rc-mini { width: 100%; border-collapse: collapse; font-size: 12px; table-layout: fixed; }
.rc-mini th {
  text-align: left; font-size: 11.5px; font-weight: 500; color: var(--muted);
  padding: 4px 6px; border-bottom: 1px solid var(--border);
}
.rc-mini td { padding: 5px 6px; border-bottom: 1px dashed var(--border); }
.rc-mini tr:last-child td { border-bottom: none; }
.rc-mini .num { text-align: right; }

/* 部门成本表：跟全局表头一致，不改内距 */
.rc-table { width: 100%; }
.rc-table .num { text-align: right; }

/* 入离职分析：左入职 / 中净增长 / 右离职 */
.rc-io { display: grid; grid-template-columns: minmax(0, 1fr) 128px minmax(0, 1fr); gap: 14px; align-items: center; }
.rc-io-col { min-width: 0; }
.rc-io-h {
  font-size: 12.5px; font-weight: 600; color: var(--text); margin-bottom: 8px;
  display: flex; align-items: baseline; gap: 6px;
}
.rc-io-h em { font-style: normal; font-size: 11px; font-weight: 400; color: var(--muted); }
.rc-io-kv {
  display: flex; align-items: center; justify-content: space-between;
  padding: 5px 0; font-size: 12px; color: var(--text-2); border-bottom: 1px dashed var(--border);
}
.rc-io-kv:last-child { border-bottom: none; }
.rc-io-kv b { font-size: 14px; color: var(--text); }
.rc-io-kv b.up { color: #22b07d; }
.rc-io-kv b.down { color: #e5544b; }
.rc-io-mid { text-align: center; padding: 6px 8px; background: var(--bg); border-radius: 12px; }
.rc-io-net { font-size: 26px; font-weight: 600; line-height: 1.15; }
.rc-io-net i { font-size: 12px; font-style: normal; font-weight: 400; margin-left: 2px; }
.rc-io-net.up { color: #22b07d; }
.rc-io-net.down { color: #e5544b; }
.rc-io-netl { font-size: 11px; color: var(--muted); margin-top: 4px; line-height: 1.5; }
.rc-io-ch { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 10px; font-size: 11.5px; color: var(--muted); }
.rc-io-ch span { white-space: nowrap; }
.rc-io-ch b { color: var(--text-2); font-weight: 600; }

/* 报表说明 */
.rc-notes { list-style: none; display: flex; flex-direction: column; gap: 7px; }
.rc-notes li {
  position: relative; padding-left: 14px; font-size: 12px; line-height: 1.65; color: var(--text-2);
}
.rc-notes li::before {
  content: ''; position: absolute; left: 2px; top: 7px; width: 4px; height: 4px;
  border-radius: 50%; background: var(--muted); opacity: .6;
}

/* 专项报表：小节标题 / 工具栏 / 自定义字段抽屉 */
.card-sub-head {
  display: flex; align-items: center; gap: 8px; margin: 16px 0 8px;
  font-size: 13px; font-weight: 600; color: var(--text);
}
.rc-toolbar { background: var(--bg); border-radius: 12px; padding: 12px 14px; margin-bottom: 12px; }
.rc-tool-row { display: flex; align-items: flex-start; gap: 10px; }
.rc-tool-row + .rc-tool-row { margin-top: 10px; }
.rc-tool-l { flex: none; width: 34px; font-size: 12px; color: var(--muted); padding-top: 6px; }
.rc-chips { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.rc-chip {
  display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px;
  background: #fff; border: 1px solid var(--border); border-radius: 14px;
  font-size: 12px; color: var(--text-2); cursor: pointer; user-select: none;
}
.rc-chip input { margin: 0; }
.rc-chip:has(input:checked) { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.rc-tool-row select.hr-search { padding: 5px 8px; }

/* 月报顶栏 */
.rc-month-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; margin-bottom: 12px; background: var(--bg); border-radius: 10px;
}

@media (max-width: 1180px) {
  .rc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rc-grid .rc-block[style*="span 2"] { grid-column: span 2 !important; }
}
@media (max-width: 860px) {
  .rc-wrap { grid-template-columns: minmax(0, 1fr); padding: 4px 12px 16px; }
  .rc-nav { position: static; flex-direction: row; overflow-x: auto; gap: 4px; }
  .rc-nav a { flex: none; }
  .rc-grid { grid-template-columns: minmax(0, 1fr); }
  .rc-grid .rc-block[style*="span 2"] { grid-column: span 1 !important; }
  .rc-io { grid-template-columns: minmax(0, 1fr); }
  .rc-io-mid { order: -1; }
}

/* ==================================================================
 * 人事底座：组织架构 / 岗位 / 花名册 / 风险日历（2026-11-14）
 * 内距一律自带，不依赖父级；卡片外层用 .dk-sec 的兜底 16px。
 * ================================================================== */

/* 顶栏页签多了要能横向滚动，否则 14 个标签会挤出屏幕 */
.dk-tabs { overflow-x: auto; scrollbar-width: thin; }
.dk-tabs::-webkit-scrollbar { height: 4px; }
.dk-tabs::-webkit-scrollbar-thumb { background: #d5dce6; border-radius: 2px; }
.dk-tab { flex: none; }

/* ---- 指标卡（组织 / 岗位 / 花名册共用）---- */
.hro-kpis {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px; margin-bottom: 12px;
}
.hro-kpi {
  padding: 12px 14px; background: var(--bg); border-radius: 12px;
  border-left: 3px solid var(--primary); min-width: 0;
}
.hro-kpi.t-green { border-left-color: #22b07d; }
.hro-kpi.t-red { border-left-color: #e5544b; }
.hro-kpi.t-orange { border-left-color: #f5a623; }
.hro-kpi.t-cyan { border-left-color: #0ea5e9; }
.hro-kpi-l { font-size: 12px; color: var(--muted); margin-bottom: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hro-kpi-v { font-size: 21px; font-weight: 600; color: var(--text); line-height: 1.2; }
.hro-kpi-v i { font-size: 12px; font-weight: 400; font-style: normal; color: var(--muted); margin-left: 3px; }
.hro-kpi-s { margin-top: 5px; font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---- 组织架构树 ---- */
.hro-tree { display: flex; flex-direction: column; gap: 4px; padding: 2px 0 6px; }
.hro-node {
  display: flex; align-items: center; gap: 8px; min-height: 42px;
  padding: 6px 12px 6px calc(12px + var(--dep, 0) * 22px);
  background: #fff; border: 1px solid var(--border); border-radius: 9px;
  font-size: 13px; cursor: grab; min-width: 0;
}
.hro-node.lv0 { background: var(--bg); border-color: #dfe6ef; }
.hro-node.off { opacity: .55; }
.hro-node.dragging { opacity: .4; }
.hro-node.drag-over { border-color: var(--primary); background: var(--primary-soft, #eef4ff); box-shadow: 0 0 0 2px rgba(37,99,235,.12); }
.hro-grip { color: #c2cbd8; font-size: 11px; letter-spacing: -2px; cursor: grab; flex: none; user-select: none; }
.hro-name { font-weight: 600; color: var(--text); flex: none; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hro-code { font-size: 11.5px; color: var(--muted); flex: none; }
.hro-tag {
  flex: none; padding: 1px 7px; border-radius: 10px; font-size: 11.5px;
  background: var(--bg); color: var(--text-2); border: 1px solid var(--border); white-space: nowrap;
}
.hro-tag.sub { background: #f3f7ff; color: #2f6bd8; border-color: #dbe6fb; }
.hro-tag.quota.over { color: #b4322a; border-color: #f3c7c3; background: #fdf1f0; }
.hro-tag.over { color: #b4322a; background: #fdeceb; border-color: #f6cdc9; font-weight: 600; }
.hro-tag.on { color: #187a53; background: #e9f8f1; border-color: #c2ebd8; }
.hro-tag.off { color: #8a94a3; background: #f2f4f7; }
.hro-leader { font-size: 12px; color: var(--text-2); flex: none; }
.hro-leader i { color: #b9c2cf; font-style: normal; }
.hro-act { margin-left: auto; display: flex; gap: 5px; flex: none; }
.btn-danger-ghost { color: #c0392b; border-color: #f0c8c3; }
.btn-danger-ghost:hover { background: #fdf1f0; }

/* ---- 架构图 ---- */
.hro-chart { padding: 6px 0 10px; }
.hro-chart-scroll { overflow: auto; max-height: 620px; }
.hro-cnode { cursor: pointer; }
.hro-cnode:hover rect { stroke: var(--primary); }

/* ---- 版本列表 ---- */
.hro-ver-tip { font-size: 12.5px; color: var(--text-2); line-height: 1.7; margin-bottom: 10px; }
.hro-ver-row {
  display: flex; align-items: center; gap: 10px; padding: 9px 4px;
  border-bottom: 1px dashed var(--border); font-size: 13px;
}
.hro-ver-row:last-child { border-bottom: none; }
.hro-ver-main { display: flex; align-items: baseline; gap: 8px; min-width: 0; flex-wrap: wrap; }

/* ---- 岗位表 ---- */
.hro-pos-table td, .hro-pos-table th { white-space: nowrap; }
.hro-pos-table td:nth-child(1) { min-width: 150px; }

/* ---- 岗位说明书 ---- */
.hro-jd-head { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.hro-jd-sec { margin-bottom: 16px; }
.hro-jd-sec h4 { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 7px; }
.hro-jd-sec p { font-size: 13px; line-height: 1.75; color: var(--text-2); }
.hro-jd-sec ol, .hro-jd-sec ul { padding-left: 20px; font-size: 13px; line-height: 1.85; color: var(--text-2); }
.hro-holders { display: flex; flex-wrap: wrap; gap: 6px; }
.hro-holder {
  padding: 3px 10px; background: var(--bg); border-radius: 12px;
  font-size: 12.5px; color: var(--text-2);
}
.hro-holder i { font-style: normal; color: var(--muted); font-size: 11.5px; }
.hro-holder em { font-style: normal; color: #b08900; font-size: 11px; }

/* ---- 花名册表 ---- */
.hro-roster-wrap { max-height: 620px; overflow: auto; }
.hro-roster-table td, .hro-roster-table th { white-space: nowrap; }
.hro-roster-table .sticky-col {
  position: sticky; left: 0; background: #fff; z-index: 2;
  box-shadow: 1px 0 0 var(--border);
}
.hro-roster-table thead .sticky-col { background: var(--bg); z-index: 3; }
.hro-roster-table tbody tr:hover .sticky-col { background: #f8fafc; }
.hro-flag {
  display: inline-block; padding: 1px 7px; margin: 1px 3px 1px 0;
  border-radius: 10px; font-size: 11px; color: #b4322a;
  background: #fdeceb; border: 1px solid #f6cdc9; white-space: nowrap;
}

/* ---- 员工档案抽屉 ---- */
.hro-prof-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.hro-prof-avatar {
  width: 46px; height: 46px; border-radius: 12px; flex: none;
  background: var(--primary-soft, #eef4ff); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 19px; font-weight: 600;
}
.hro-prof-name { font-size: 16px; font-weight: 600; color: var(--text); }
.hro-metric-row {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 8px; margin-bottom: 16px;
}
.hro-metric { padding: 10px 12px; background: var(--bg); border-radius: 10px; min-width: 0; }
.hro-metric b { display: block; font-size: 15px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hro-metric span { font-size: 11.5px; color: var(--muted); }
.hro-kv-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2px 16px; }
.hro-kv {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  padding: 6px 0; border-bottom: 1px dashed var(--border); font-size: 12.5px;
}
.hro-kv span { color: var(--muted); flex: none; }
.hro-kv b { color: var(--text); font-weight: 500; text-align: right; word-break: break-all; }
.hro-custom-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }

/* ---- 导入对话框 ---- */
.hro-imp-bar {
  display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 10px 12px;
  background: var(--bg); border-radius: 10px; font-size: 12.5px; color: var(--text-2);
  margin-bottom: 12px;
}
.hro-imp-bar b { color: var(--text); }
.hro-imp-tip {
  font-size: 12px; line-height: 1.75; color: var(--text-2);
  background: #f8fafc; border-left: 3px solid #d5dce6; border-radius: 0 8px 8px 0;
  padding: 9px 12px; margin: 10px 0;
}
.hro-imp-tip code { background: #eef2f7; padding: 1px 5px; border-radius: 4px; font-size: 11.5px; }
.hro-map-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 6px; margin-bottom: 10px; }
.hro-map {
  display: flex; align-items: center; gap: 6px; padding: 6px 10px; min-width: 0;
  background: #fff; border: 1px solid var(--border); border-radius: 8px; font-size: 12px;
}
.hro-map-h { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 110px; }
.hro-map-arrow { color: #c2cbd8; flex: none; }
.hro-map-k { color: var(--primary); font-weight: 600; flex: none; }

/* ---- 字段设置 ---- */
.hro-fdef {
  display: flex; align-items: center; gap: 8px; padding: 8px 10px;
  border-bottom: 1px dashed var(--border); font-size: 13px;
}
.hro-fdef:last-child { border-bottom: none; }

/* ---- 用工风险 ---- */
.hro-risk-ok {
  display: flex; align-items: center; gap: 12px; padding: 18px 16px;
  background: #f2fbf7; border: 1px solid #c9ecdb; border-radius: 12px;
}
.hro-risk-ok-icon {
  width: 34px; height: 34px; border-radius: 50%; flex: none;
  background: #22b07d; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.hro-risk-sum { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.hro-risk-say { font-size: 13.5px; font-weight: 600; color: var(--text); }
.hro-risk-chips { display: flex; gap: 6px; }
.r-chip { padding: 2px 9px; border-radius: 10px; font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.r-chip.r-high { color: #fff; background: #e5544b; }
.r-chip.r-mid { color: #8a5a00; background: #fdf0d5; border: 1px solid #f3dca8; }
.r-chip.r-low { color: #4b5a6b; background: #eef2f7; border: 1px solid #dde4ec; }
.hro-risk-types { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.hro-risk-type {
  padding: 3px 10px; background: var(--bg); border-radius: 12px;
  font-size: 12px; color: var(--text-2);
}
.hro-risk-type b { color: #b4322a; }
.hro-risk-reason { max-width: 260px; font-size: 12.5px; }
.hro-risk-advice { max-width: 320px; font-size: 12px; color: var(--muted); line-height: 1.6; }

/* ---- 人事日历 ---- */
.hro-cal-alert {
  padding: 9px 12px; background: #fdf1f0; border: 1px solid #f6cdc9;
  border-radius: 10px; font-size: 12.5px; color: #a33227; line-height: 1.7; margin-bottom: 12px;
}
.hro-cal { display: flex; flex-direction: column; gap: 12px; padding-bottom: 6px; }
.hro-cal-day { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 12px; align-items: start; }
.hro-cal-date { text-align: right; padding-top: 4px; }
.hro-cal-date b { display: block; font-size: 14px; color: var(--text); }
.hro-cal-date span { font-size: 11.5px; color: var(--muted); }
.hro-cal-date span.soon { color: #d97706; font-weight: 600; }
.hro-cal-date span.past { color: #c0392b; font-weight: 600; }
.hro-cal-evs { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hro-cal-ev {
  display: flex; align-items: center; gap: 8px; padding: 8px 12px; flex-wrap: wrap;
  background: #fff; border: 1px solid var(--border); border-left: 3px solid var(--primary);
  border-radius: 8px; font-size: 12.5px;
}
.hro-cal-ev.t-contract { border-left-color: #0ea5e9; }
.hro-cal-ev.t-idcard { border-left-color: #f5a623; }
.hro-cal-ev.t-regular { border-left-color: #8b5cf6; }
.hro-cal-ev.t-birthday { border-left-color: #ec4899; }
.hro-cal-ev.t-anniversary { border-left-color: #14b8a6; }
.hro-cal-ev.t-social { border-left-color: #e5544b; }
.hro-cal-ev.t-cert { border-left-color: #6366f1; }
.hro-cal-tag {
  padding: 1px 7px; border-radius: 9px; font-size: 11px;
  background: var(--bg); color: var(--text-2); white-space: nowrap;
}
.hro-cal-ev b { color: var(--text); }
.hro-cal-act { margin-left: auto; font-size: 11.5px; color: var(--primary); white-space: nowrap; }

@media (max-width: 860px) {
  .hro-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hro-node { flex-wrap: wrap; gap: 6px; }
  .hro-name { max-width: 130px; }
  .hro-act { margin-left: 0; width: 100%; }
  .hro-cal-day { grid-template-columns: minmax(0, 1fr); }
  .hro-cal-date { text-align: left; display: flex; align-items: baseline; gap: 8px; }
  .hro-cal-date b { display: inline; }
}

/* 架构图：PC 上等比缩放到容器宽，一屏看全；窄屏保持原始尺寸 + 横向滚动，避免字缩成蚂蚁 */
.hro-chart-scroll svg { max-width: none !important; }
@media (max-width: 900px) {
  .hro-chart-scroll svg { width: 720px !important; height: auto !important; max-width: none !important; }
}

/* 提醒列要留够宽度，否则「合同将到期」会被压成两行 */
.hro-roster-table .col-flag { min-width: 108px; }
/* 岗位名后面的编码小字别贴着名字 */
.hro-pos-table td:nth-child(1) .tiny { margin-left: 6px; }

/* ==================================================================
 * 审批引擎 · 申请单（2026-11-14）
 * 只服务 approvals.js：发起面板、动态表单、表单设计器、流程配置。
 * 变量沿用全局，不新造色，避免和既有页面两种画风。
 * ================================================================== */

/* ---------- 选择申请单 ---------- */
.fpick-group { margin-bottom: 18px; }
.fpick-group:last-child { margin-bottom: 0; }
.fpick-group h4 { font-size: 12.5px; font-weight: 600; color: var(--muted); margin: 0 0 9px; letter-spacing: .3px; }
.fpick { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.fpick-item {
  display: flex; flex-direction: column; align-items: flex-start; gap: 3px;
  padding: 13px 14px; border: 1px solid #e2e8f2; border-radius: 12px;
  background: #fff; cursor: pointer; text-align: left; transition: .15s;
  min-width: 0; box-shadow: 0 1px 2px rgba(16,24,40,.04); position: relative;
}
.fpick-cat {
  position: absolute; top: 11px; right: 12px;
  font-size: 10.5px; color: var(--muted); letter-spacing: .3px;
}
.fpick-item:hover { border-color: #9dbcf7; box-shadow: 0 6px 16px rgba(43,108,246,.13); transform: translateY(-1px); }
.fpick-item:active { transform: none; }
.fpick-ic {
  width: 30px; height: 30px; border-radius: 9px; display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 700; margin-bottom: 4px;
}
.fpick-item b { font-size: 13.5px; font-weight: 600; color: var(--text); }
.fpick-item em {
  font-style: normal; font-size: 11.5px; line-height: 1.55; color: var(--muted);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* ---------- 动态表单 ---------- */
.ff-head {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-size: 12.5px; color: var(--sub); line-height: 1.7;
  background: var(--bg); border-radius: 10px; padding: 9px 12px; margin-bottom: 16px;
}
.ff-note { font-size: 12px; color: var(--muted); line-height: 1.7; margin-top: 14px; }
.ff-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 12px; }
.ff-err { font-size: 11.5px; color: var(--danger); min-height: 0; line-height: 1.5; }
.ff-err:empty { display: none; }
.field.has-err input, .field.has-err select, .field.has-err textarea { border-color: var(--danger); background: #fff8f8; }

.ff-files { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ff-files-tip { font-size: 12px; color: var(--muted); }
.ff-file-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; font-size: 12.5px; }
.ff-file-row > span { color: var(--muted); flex: none; }

/* ---------- 列表卡片上的业务类型标 ---------- */
.ftag {
  display: inline-flex; align-items: center; height: 20px; padding: 0 7px;
  border-radius: 6px; background: var(--primary-l, #eef4ff); color: var(--primary);
  font-size: 11px; font-weight: 600; flex: none;
}
.apr-list { display: flex; flex-direction: column; gap: 0; }
.apr-kv { margin-bottom: 12px; }
.apr-kv .kv b { word-break: break-word; }

/* ---------- 表单设计器 ---------- */
.fdef-list { display: flex; flex-direction: column; gap: 8px; }
.fdef-row {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  border: 1px solid var(--line); border-radius: 10px; background: #fff; min-width: 0;
}
.fdef-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.fdef-main b { font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.fdef-main em { font-style: normal; font-size: 11.5px; color: var(--muted); }
.fdef-head {
  display: flex; align-items: center; gap: 10px; margin: 18px 0 10px;
  padding-bottom: 8px; border-bottom: 1px solid var(--line);
}
.fdef-head b { font-size: 13px; font-weight: 600; }
.fdef-head .spacer { flex: 1; }

.fdef-edit-list { display: flex; flex-direction: column; gap: 7px; }
.fdef-edit {
  display: grid; grid-template-columns: minmax(0,1.15fr) minmax(0,.95fr) minmax(0,.85fr) auto auto 26px;
  gap: 7px; align-items: center; padding: 8px 10px; background: var(--bg); border-radius: 9px;
}
.fdef-edit input, .fdef-edit select {
  width: 100%; min-width: 0; padding: 6px 9px; font-size: 12.5px;
  border: 1px solid var(--line); border-radius: 7px; background: #fff; outline: none;
}
.fdef-edit input:focus, .fdef-edit select:focus { border-color: #a9c4fb; }
.fdef-edit input:disabled { background: var(--line-2); color: var(--muted); cursor: not-allowed; }
.fe-chk { display: flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--sub); white-space: nowrap; }
.fe-opts { grid-column: 1 / -1; }

/* ---------- 流程配置 ---------- */
.flow-block { margin-bottom: 20px; }
.flow-block-h {
  display: flex; align-items: center; gap: 8px; margin-bottom: 8px;
  padding-bottom: 7px; border-bottom: 1px solid var(--line);
}
.flow-block-h b { font-size: 13px; font-weight: 600; }
.flow-block-h .spacer { flex: 1; }
.flow-row {
  display: flex; align-items: flex-start; gap: 12px; padding: 11px 12px;
  border: 1px solid var(--line); border-radius: 10px; margin-bottom: 8px; background: #fff;
}
.flow-main { flex: 1; min-width: 0; }
.flow-title { display: flex; align-items: center; gap: 7px; font-size: 13.5px; font-weight: 600; flex-wrap: wrap; }
.flow-steps { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.flow-step {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px 3px 4px;
  background: var(--bg); border-radius: 8px; font-size: 12px; color: var(--text); min-width: 0;
}
.flow-step i {
  font-style: normal; width: 16px; height: 16px; border-radius: 50%; flex: none;
  background: var(--primary); color: #fff; font-size: 10px; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
}
.flow-step em { font-style: normal; font-size: 10.5px; color: var(--muted); }
.flow-step u {
  text-decoration: none; font-size: 10.5px; color: var(--warn, #b8860b);
  background: var(--warn-l, #fff8e1); border-radius: 5px; padding: 1px 5px;
}
.flow-step b { font-size: 11px; font-weight: 500; color: var(--sub); }
.flow-arrow { color: var(--muted); font-size: 11px; }

.step-card {
  border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px;
  margin-bottom: 8px; background: #fff;
}
.step-card-h { display: flex; align-items: center; gap: 8px; }
.step-no {
  width: 20px; height: 20px; border-radius: 50%; background: var(--primary); color: #fff;
  font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex: none;
}
.step-card-h .st-name { flex: 1; min-width: 0; }
.step-card-h input, .step-card-h select,
.step-cond-body input, .step-cond-body select {
  padding: 6px 9px; font-size: 12.5px; border: 1px solid var(--line); border-radius: 7px;
  background: #fff; outline: none; min-width: 0;
}
.step-approvers { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }
.chk-chip {
  display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px;
  border: 1px solid var(--line); border-radius: 999px; font-size: 12px; color: var(--sub);
  cursor: pointer; user-select: none; background: #fff;
}
.chk-chip:has(input:checked) { border-color: var(--primary); background: var(--primary-l, #eef4ff); color: var(--primary); }
.chk-chip input { width: 13px; height: 13px; accent-color: var(--primary); }
.step-cond { margin-top: 9px; border-top: 1px dashed var(--line); padding-top: 9px; }
.step-cond-body { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-top: 7px; }
.step-cond-body input[type=number] { width: 110px; }
.step-cond-body input:not([type]) { width: 130px; }

@media (max-width: 780px) {
  .fdef-edit { grid-template-columns: minmax(0,1fr) minmax(0,1fr) 26px; }
  .fdef-edit .fe-type, .fdef-edit .fe-chk { grid-column: span 1; }
}

/* 表单设计器补丁（2026-11-14） */
.fe-opts-wrap { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; }
.fe-opts-wrap > span { font-size: 11px; color: var(--muted); flex: none; }
.fe-opts-wrap > .fe-opts { flex: 1; min-width: 0; }
/* 只读字段要一眼看出不能改：白底 + 正常光标会让人以为能输 */
#nf-key:disabled, .field input:disabled {
  background: #f2f4f8; color: var(--muted); cursor: not-allowed; border-color: #e6eaf1;
}

/* ==================================================================
 * 考勤规则引擎（2026-11-15）
 * 排班日历是「30 列 × N 行」的密集表格，难点全在格子上：
 * 一个字要能看出是哪个班、灰/红/浅色要能区分休息与节假日，
 * 同时不能贴边 —— 外面套 .table-wrap 给内距，横向滚动只发生在内层。
 * ================================================================== */
.hsa-kpis {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px; margin-bottom: 12px;
}
.hsa-kpi {
  padding: 10px 12px; background: var(--bg); border-radius: 10px;
  border-left: 3px solid var(--primary); min-width: 0;
}
.hsa-kpi.warn { border-left-color: var(--warn); }
.hsa-kpi.danger { border-left-color: var(--danger); }
.hsa-kpi b { display: block; font-size: 19px; line-height: 1.2; }
.hsa-kpi span { font-size: 11.5px; color: var(--muted); }
.hsa-kpi-tip {
  grid-column: 1 / -1; font-size: 11.5px; color: var(--muted);
  background: var(--bg); border-radius: 8px; padding: 7px 10px;
}

/* ---- 排班表格 ---- */
.hsa-cal-wrap { overflow-x: auto; scrollbar-width: thin; }
.hsa-cal-wrap::-webkit-scrollbar { height: 8px; }
.hsa-cal-wrap::-webkit-scrollbar-thumb { background: #d5dce6; border-radius: 4px; }
.hsa-cal { border-collapse: separate; border-spacing: 0; width: 100%; min-width: 900px; }
.hsa-cal th, .hsa-cal td { padding: 0; border-bottom: 1px solid var(--border); }
.hsa-cal thead th {
  position: sticky; top: 0; z-index: 2; background: var(--card);
  font-weight: 500; padding: 6px 2px; text-align: center; font-size: 11px; color: var(--muted);
  border-bottom: 1px solid var(--border-strong);
}
.hsa-th b { display: block; font-size: 11px; color: var(--muted); font-weight: 500; }
.hsa-th i { display: block; font-style: normal; font-size: 12.5px; color: var(--text); font-weight: 600; }
.hsa-th em {
  display: block; font-style: normal; font-size: 9.5px; line-height: 1.3;
  color: var(--danger); margin-top: 1px; white-space: nowrap; overflow: hidden;
}
.hsa-th.we { background: #fafbfd; }
.hsa-th.hol { background: #fdf1f1; }
.hsa-th.adj { background: #fff8ea; }

.hsa-name-th, .hsa-name {
  position: sticky; left: 0; z-index: 3; background: var(--card);
  text-align: left !important; padding: 6px 10px !important; min-width: 96px;
  border-right: 1px solid var(--border);
}
.hsa-name-th { z-index: 4; font-size: 11.5px; color: var(--muted); }
.hsa-name b { display: block; font-size: 12.5px; font-weight: 600; }
.hsa-name i { display: block; font-style: normal; font-size: 10.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 96px; }

.hsa-cell {
  width: 30px; height: 30px; text-align: center; cursor: pointer;
  font-size: 12px; color: var(--text); transition: background .12s;
  position: relative;
}
.hsa-cell:hover { background: var(--primary-soft); box-shadow: inset 0 0 0 1px var(--primary); }
/* 值班角标：30px 的格子里只放一个字，靠右上角定位，不挤班次字 */
.hsa-cell-duty {
  position: absolute; top: 1px; right: 2px; font-style: normal;
  font-size: 9px; line-height: 1; color: #fff; background: #7c5cff;
  border-radius: 3px; padding: 1px 2px; pointer-events: none;
}
.hsa-cell.duty { box-shadow: inset 0 -2px 0 #7c5cff; }
.hsa-cell.off { color: #b6bdc9; background: #fafbfd; }
.hsa-cell.we { background: #fafbfd; }
.hsa-cell.we.off { color: #c9ced7; }
.hsa-cell.hol { background: #fdf1f1; }
.hsa-cell.adj { background: #fff8ea; }
/* 自动兜底（没排班、系统按规则推出来的）用半透明字，一眼能分出「人工排的」和「系统推的」 */
.hsa-cell.auto { color: #98a2b3; font-style: italic; }
.hsa-cell.auto.off { color: #c6ccd6; }
/* 节假日格子：浅灰字压在浅红底上几乎看不见，HR 扫一遍会以为没排班。
   统一压成深红，和「红＝放假」的心智对齐（写在这里是为了盖住上面的 .auto.off） */
.hsa-cell.hol, .hsa-cell.hol.off, .hsa-cell.hol.we, .hsa-cell.hol.auto, .hsa-cell.hol.auto.off { color: #b4433f; }

/* ---- 批量排班选人 ---- */
.hsa-pick {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
  gap: 6px; max-height: 190px; overflow-y: auto; overflow-x: hidden;
  border: 1px solid var(--border); border-radius: 8px; padding: 8px;
}
.hsa-pick-all { grid-column: 1 / -1; font-size: 12px; color: var(--muted); border-bottom: 1px dashed var(--border); padding-bottom: 6px; }
/* 名字不许被挤成两行：以前 140px 一列、弹窗一窄就压成「张 / 伟」上下排，看着像两列数据 */
.hsa-pick-i { display: flex; align-items: center; gap: 5px; font-size: 12.5px; min-width: 0;
  white-space: nowrap; overflow: hidden; }
.hsa-pick-i i { font-style: normal; font-size: 10.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.hsa-row2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
.hsa-chk { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text-2); margin: 4px 0 2px; }

/* ---- 模板七天 ---- */
.hsa-week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; margin: 6px 0 8px; }
.hsa-week-i { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.hsa-week-i span { font-size: 11.5px; color: var(--muted); }
.hsa-week-i select { width: 100%; min-width: 0; }

/* ---- 考核规则分段 ---- */
.hsa-rule-sec { border-top: 1px dashed var(--border); padding-top: 10px; margin-top: 10px; }
.hsa-rule-sec:first-of-type { border-top: none; margin-top: 0; padding-top: 0; }
.hsa-rule-sec h4 { font-size: 13px; margin-bottom: 8px; color: var(--text); }

/* ---- 核算结果表 ---- */
.hsa-rep td.ctr { text-align: center; }
.hsa-rep .warn-cell { color: var(--warn); font-weight: 600; }
.hsa-rep .danger-cell { color: var(--danger); font-weight: 600; }
.danger-text { color: var(--danger); }

/* ---- 逐日明细（抽屉）---- */
.hsa-day-list { display: flex; flex-direction: column; gap: 6px; }
.hsa-day {
  display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 10px;
  padding: 8px 10px; border-radius: 8px; background: var(--bg);
}
.hsa-day.rest { background: #fafbfd; }
.hsa-day-d { text-align: center; }
.hsa-day-d b { display: block; font-size: 15px; line-height: 1.1; }
.hsa-day-d span { font-size: 10.5px; color: var(--muted); }
.hsa-day-m { min-width: 0; }
.hsa-day-s { display: flex; align-items: center; gap: 6px; margin-bottom: 2px; }
.hsa-day-t { line-height: 1.5; word-break: break-all; }

/* ---- 异常分组 ---- */
.hsa-anom-g { margin-bottom: 14px; }
.hsa-anom-h { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font-size: 12.5px; }
.hsa-anom-i { padding: 7px 10px; border-radius: 8px; background: var(--bg); margin-bottom: 5px; }
.hsa-anom-i b { font-size: 12.5px; }

@media (max-width: 1100px) {
  .hsa-row2 { grid-template-columns: minmax(0, 1fr); }
  .hsa-week { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ==================================================================
 * 算薪引擎配置界面（2026-11-14）
 * 薪资方案 / 薪资档案 / 社保规则三个弹层共用
 * ================================================================== */

/* ---- 方案：左列表 + 右薪资项 ---- */
.hsp-split { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 14px; }
.hsp-side { min-width: 0; }
.hsp-side-h {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12.5px; color: var(--text-2); margin-bottom: 8px;
}
.hsp-plan-list { display: flex; flex-direction: column; gap: 4px; max-height: 60vh; overflow: auto; }
.hsp-plan {
  padding: 9px 11px; border-radius: 8px; background: var(--bg); cursor: pointer;
  border: 1px solid transparent; transition: background .12s, border-color .12s;
}
.hsp-plan:hover { background: var(--primary-soft); }
.hsp-plan.on { background: var(--primary-soft); border-color: var(--primary); }
.hsp-plan b { display: block; font-size: 13px; }
.hsp-plan span { display: block; font-size: 11px; color: var(--muted); margin-top: 2px; }

.hsp-main { min-width: 0; }
.hsp-main-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.hsp-main-h .spacer { flex: 1; }
.hsp-note { padding: 6px 2px 10px; line-height: 1.6; }
.hsp-items td:first-child { max-width: 220px; }

/* 加项 / 减项标签：颜色必须区分开，HR 一眼要能看出这项是扣钱的 */
.hsp-tag {
  display: inline-block; padding: 1px 7px; border-radius: 5px;
  font-size: 11px; white-space: nowrap;
}
.hsp-tag.add { background: var(--success-soft); color: #15803d; }
.hsp-tag.sub { background: var(--danger-soft); color: #b91c1c; }

.hsp-hint { margin-top: 10px; padding: 8px 10px; border-radius: 8px; background: var(--bg); line-height: 1.6; }

/* ---- 薪资档案 ---- */
.hss-bar { display: flex; align-items: center; gap: 8px; padding-bottom: 10px; }
.hss-bar .spacer { flex: 1; }
.hss-warn { font-size: 12px; color: var(--warn); }
.hss-sec { border-top: 1px solid var(--border); padding: 12px 0 4px; }
.hss-sec:first-child { border-top: 0; padding-top: 0; }
.hss-sec-h {
  font-size: 12.5px; font-weight: 600; color: var(--text-2);
  margin-bottom: 8px;
}
.hss-err {
  display: inline-block; padding: 0 5px; border-radius: 4px;
  font-size: 11px; background: var(--danger-soft); color: #b91c1c;
}

/* 试算结果：一块深色小面板，数字要能一眼扫到 */
.hss-pv {
  margin-top: 12px; padding: 12px; border-radius: 10px;
  background: var(--bg); border: 1px solid var(--border);
}
.hss-pv-h { font-size: 12.5px; font-weight: 600; margin-bottom: 10px; }
.hss-pv-grid {
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px;
}
.hss-pv-grid > div { text-align: center; min-width: 0; }
.hss-pv-grid span { display: block; font-size: 11px; color: var(--muted); }
.hss-pv-grid b { display: block; font-size: 14px; margin-top: 2px; }
.hss-pv-grid .big b { font-size: 17px; color: var(--primary); }

/* 工资条里的「逐项计算明细」折叠块 */
.hss-fold { margin-top: 14px; }
.hss-fold > summary {
  cursor: pointer; font-size: 12.5px; color: var(--text-2);
  padding: 7px 10px; border-radius: 8px; background: var(--bg);
}
.hss-fold > summary:hover { background: var(--primary-soft); }

@media (max-width: 1100px) {
  .hsp-split { grid-template-columns: 180px minmax(0, 1fr); }
  .hss-pv-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hss-pv-grid .big { grid-column: span 3; }
}

/* ==================================================================
 * 人事 · 电子档案库（2026-11-14）
 * ================================================================== */
.hdc-kpis {
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px; margin-bottom: 12px;
}
.hdc-kpi {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; padding: 14px 8px; background: var(--card);
  border: 1px solid var(--border); border-radius: 12px; min-width: 0;
}
.hdc-kpi b { font-size: 23px; font-weight: 700; line-height: 1.05; font-variant-numeric: tabular-nums; }
.hdc-kpi span { font-size: 12px; color: var(--muted); white-space: nowrap; }
.hdc-kpi.amber b { color: #a15c07; }
.hdc-kpi.red b { color: var(--danger); }

/* 齐备度进度条：不做成仪表盘，表格里一行能扫完更重要 */
.hdc-bar {
  height: 6px; border-radius: 4px; background: var(--border); overflow: hidden;
}
.hdc-bar > i { display: block; height: 100%; border-radius: 4px; background: var(--danger); }
.hdc-bar > i.mid { background: #e0a33a; }
.hdc-bar > i.full { background: #2e9e6b; }

.hdc-miss { color: var(--danger); font-weight: 600; }
.hdc-ok { color: #2e9e6b; font-weight: 600; }
.hdc-miss-txt { color: var(--danger); font-size: 11.5px; margin-top: 2px; }

/* ---- 一人一档抽屉 ---- */
.hdc-head {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 0 0 12px; border-bottom: 1px solid var(--border); margin-bottom: 12px;
}
.hdc-head h4 { margin: 0 0 4px; font-size: 16px; }
.hdc-head-r { text-align: right; flex: none; }
.hdc-head-r b { display: block; font-size: 22px; color: var(--primary); line-height: 1.1; }
.hdc-head-r span { font-size: 11px; color: var(--muted); }

.hdc-sec { margin-bottom: 14px; }
.hdc-sec-h {
  display: flex; align-items: center; gap: 8px; padding: 6px 0 8px;
  border-bottom: 1px dashed var(--border); margin-bottom: 8px;
}
.hdc-sec-h b { font-size: 13px; }
.hdc-sec-h .spacer { flex: 1; }

.hdc-doc {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 9px 11px; border-radius: 10px; background: var(--bg); margin-bottom: 6px;
}
.hdc-doc-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.hdc-doc-main b { font-size: 13px; }
.hdc-doc-act { display: flex; align-items: center; gap: 6px; flex: none; }
.hdc-empty {
  padding: 12px; border-radius: 10px; border: 1px dashed var(--border);
  font-size: 12px; color: var(--muted); text-align: center;
}

@media (max-width: 1280px) {
  .hdc-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* ==================================================================
 * 人事 · 合同管理台账（2026-11-14）
 * ================================================================== */
.hcc-kpis {
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px; margin-bottom: 12px;
}
.hcc-kpi {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; padding: 14px 8px; background: var(--card);
  border: 1px solid var(--border); border-radius: 12px; min-width: 0;
}
.hcc-kpi b { font-size: 23px; font-weight: 700; line-height: 1.05; font-variant-numeric: tabular-nums; }
.hcc-kpi span { font-size: 12px; color: var(--muted); white-space: nowrap; }
.hcc-kpi.amber b { color: #a15c07; }
.hcc-kpi.red b { color: var(--danger); }

/* 表格里的「还剩 N 天」：红/黄只给需要动手的那几行，履行中的保持灰 */
.hcc-red { color: var(--danger); font-weight: 600; }
.hcc-amber { color: #a15c07; font-weight: 600; }
.dk-table td.rt, .dk-table th.rt { text-align: right; }
.hcc-kpi + .card { margin-top: 0; }

/* ---- 详情抽屉 ---- */
.hcd-hd {
  display: flex; align-items: flex-start; gap: 12px;
  padding-bottom: 12px; border-bottom: 1px solid var(--border); margin-bottom: 12px;
}
.hcd-hd h4 { margin: 0 0 4px; font-size: 16px; display: flex; align-items: center; gap: 8px; }
.hcd-hd-r { text-align: right; flex: none; }
.hcd-hd-r b { display: block; font-size: 20px; color: var(--primary); line-height: 1.15; }
.hcd-hd-r span { font-size: 11px; color: var(--muted); }

.hcd-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px; background: var(--border); border-radius: 10px; overflow: hidden;
  margin-bottom: 14px;
}
.hcd-row {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  padding: 9px 12px; background: var(--card); min-width: 0;
}
.hcd-row > span { font-size: 12px; color: var(--muted); flex: none; }
.hcd-row > b { font-size: 13px; font-weight: 600; text-align: right; min-width: 0; word-break: break-all; }

.hcd-sec { margin-bottom: 14px; }
.hcd-sec-h {
  display: flex; align-items: center; gap: 8px; padding: 4px 0 8px;
  border-bottom: 1px dashed var(--border); margin-bottom: 8px;
}
.hcd-sec-h b { font-size: 13px; }
.hcd-sec-h .spacer { flex: 1; }

/* 续签链：当前这份高亮，一眼看出「这是第几份」 */
.hcd-chain {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px;
  border-radius: 9px; background: var(--bg); margin-bottom: 6px;
}
.hcd-chain.on { background: var(--primary-soft); box-shadow: inset 3px 0 0 var(--primary); }
.hcd-chain-i {
  flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--card);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; color: var(--muted);
}
.hcd-chain.on .hcd-chain-i { background: var(--primary); color: #fff; }
.hcd-chain b { font-size: 12.5px; }

.hcd-body {
  margin: 0; padding: 12px 14px; border-radius: 10px; background: var(--bg);
  font-size: 12.5px; line-height: 1.85; color: var(--text-2);
  white-space: pre-wrap; word-break: break-word; max-height: 360px; overflow: auto;
}

.hcd-log {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 7px 0; border-top: 1px dashed var(--border); font-size: 12.5px;
}
.hcd-log:first-child { border-top: none; }
.hcd-log > span { flex: none; width: 96px; }

/* ---- 表单里的小行 ---- */
.hcc-tpl-row, .hcc-file-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.hcc-tpl-row select { max-width: 260px; }

/* ---- 到期提醒清单 ---- */
.hcc-exp-sec { margin-bottom: 14px; }
.hcc-exp-row {
  display: flex; align-items: center; gap: 12px; padding: 9px 11px;
  border-radius: 10px; background: var(--bg); margin-bottom: 6px;
}
.hcc-exp-row > div:first-child { flex: 1; min-width: 0; }
.hcc-exp-r { flex: none; font-size: 12.5px; font-weight: 600; color: var(--muted); width: 92px; text-align: right; }
.hcc-exp-act { flex: none; display: flex; gap: 6px; }

@media (max-width: 1280px) {
  .hcc-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hcd-grid { grid-template-columns: 1fr; }
}

/* 模板正文编辑框：rows=14 在某些高度下会被容器压扁，内容一多就看不到结尾 */
.hsp-main textarea[data-t="body"] { min-height: 300px; }

/* ==================== 在线考试 · PC（2026-11-14） ==================== */
.hex-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.hex-kpi {
  background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
  padding: 14px 16px; display: flex; flex-direction: column; gap: 4px;
}
.hex-kpi b { font-size: 22px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.hex-kpi span { font-size: 12px; color: var(--text-3); }
.hex-kpi.amber b { color: var(--amber, #b26a00); }
.hex-amber { color: var(--amber, #b26a00); font-weight: 600; }
.hex-red { color: var(--red, #d33); font-weight: 600; }

.hex-name { font-weight: 600; line-height: 1.35; }
.hex-ops { display: flex; gap: 6px; flex-wrap: wrap; }
.dk-table.compact th, .dk-table.compact td { padding: 7px 10px; font-size: 12.5px; }

.hex-d-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 10px; }
.hex-d-head > div:first-child { min-width: 0; flex: 1; }
.hex-d-title { font-size: 16px; font-weight: 700; line-height: 1.35; }
.hex-intro {
  background: var(--bg-2, #f7f8fa); border-radius: 8px; padding: 10px 12px;
  font-size: 12.5px; color: var(--text-2); line-height: 1.7; margin-bottom: 12px; white-space: pre-wrap;
}
.hex-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 16px; margin-bottom: 14px; }
.hex-grid > div { display: flex; gap: 8px; font-size: 12.5px; }
.hex-grid span { color: var(--text-3); flex: 0 0 92px; white-space: nowrap; }
.hex-grid b { font-weight: 600; }

.hex-stats {
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px;
  background: var(--bg-2, #f7f8fa); border-radius: 10px; padding: 12px 14px; margin-bottom: 14px;
}
.hex-stats > div { display: flex; flex-direction: column; gap: 2px; }
.hex-stats b { font-size: 18px; font-variant-numeric: tabular-nums; }
.hex-stats span { font-size: 11.5px; color: var(--text-3); }

.hex-sec { margin-bottom: 16px; }
.hex-sec-h {
  display: flex; align-items: baseline; gap: 8px; font-weight: 600; font-size: 13px;
  margin-bottom: 8px; padding-bottom: 6px; border-bottom: 1px solid var(--border);
}
.hex-qlist { margin: 0; padding-left: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; }
.hex-qlist li { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }
.hex-qstem { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.hex-bands { display: flex; flex-direction: column; gap: 7px; }
.hex-bands > div { display: grid; grid-template-columns: 48px minmax(0, 1fr) 34px; align-items: center; gap: 10px; font-size: 12px; }
.hex-bands span { color: var(--text-3); white-space: nowrap; font-variant-numeric: tabular-nums; }
.hex-band-track { height: 14px; background: var(--bg-2, #f1f2f4); border-radius: 4px; overflow: hidden; }
.hex-band-track i { display: block; height: 100%; background: var(--primary, #2f6fed); opacity: .7; }
.hex-bands b { text-align: right; font-variant-numeric: tabular-nums; }
.hex-qidx {
  flex: 0 0 18px; height: 18px; border-radius: 50%; background: var(--bg-2, #f1f2f4);
  color: var(--text-3); font-style: normal; font-size: 11px; line-height: 18px; text-align: center;
}
.hex-notjoin { display: flex; flex-wrap: wrap; gap: 6px; }

.hex-answers { display: flex; flex-direction: column; gap: 12px; }
.hex-ans {
  border: 1px solid var(--border); border-left: 3px solid var(--border); border-radius: 8px;
  padding: 10px 12px; display: flex; flex-direction: column; gap: 7px;
}
.hex-ans.ok { border-left-color: var(--green, #16a34a); }
.hex-ans.no { border-left-color: var(--red, #d33); }
.hex-ans.pend { border-left-color: var(--amber, #f59e0b); }
.hex-ans-h { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; font-size: 13px; }
.hex-ans-h b { font-weight: 600; flex: 1; min-width: 0; line-height: 1.5; }
.hex-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.hex-opts > span {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 14px;
  background: var(--bg-2, #f4f5f7); font-size: 12.5px; border: 1px solid transparent;
}
.hex-opts > span i { font-style: normal; font-weight: 700; color: var(--text-3); }
.hex-opts > span.mine { background: #eef3ff; border-color: #c8d8ff; }
.hex-opts > span.std { border-color: var(--green, #16a34a); }
.hex-opts.small > span { padding: 2px 8px; font-size: 12px; }
.hex-mine, .hex-std { font-size: 12.5px; color: var(--text-2); }
.hex-std { color: var(--green, #15803d); }
.hex-comment { font-size: 12.5px; color: var(--text-2); background: var(--bg-2, #f7f8fa); padding: 6px 10px; border-radius: 6px; }
.hex-grade { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12.5px; }
.hex-grade label { color: var(--text-3); }
.hex-grade input[type="text"] { flex: 1; min-width: 160px; }

.hex-checks { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; font-size: 13px; }
.hex-checks label { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.hex-target {
  display: flex; flex-wrap: wrap; gap: 6px 14px; max-height: 140px; overflow: auto;
  border: 1px solid var(--border); border-radius: 8px; padding: 10px;
}
.hex-target label { font-size: 12.5px; display: inline-flex; align-items: center; gap: 5px; }

.hex-pick { border: 1px solid var(--border); border-radius: 8px; padding: 8px; max-height: 280px; overflow: auto; }
.hex-bank-pick { display: flex; flex-direction: column; gap: 6px; }
.hex-pick-i {
  display: grid; grid-template-columns: 18px minmax(0, 1fr) 68px; align-items: center; gap: 8px;
  padding: 7px 8px; border-radius: 6px; border: 1px solid transparent;
}
.hex-pick-i.on { background: #eef3ff; border-color: #cddbff; }
.hex-pick-t { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 12.5px; }
.hex-pick-t b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hex-pick-s { text-align: right; }
.hex-draw { display: flex; flex-direction: column; gap: 8px; }
.hex-draw-i { display: grid; grid-template-columns: 90px 80px minmax(0, 1fr); align-items: center; gap: 10px; font-size: 12.5px; }

.hex-bank-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.hex-seg { display: inline-flex; gap: 4px; background: var(--bg-2, #f2f3f5); padding: 3px; border-radius: 8px; }
.hex-seg .seg {
  border: 0; background: transparent; padding: 5px 12px; border-radius: 6px;
  font-size: 12.5px; cursor: pointer; color: var(--text-2);
}
.hex-seg .seg.on { background: var(--surface, #fff); color: var(--text-1); font-weight: 600; box-shadow: 0 1px 2px rgba(0,0,0,.06); }
.hex-qbank { display: flex; flex-direction: column; gap: 8px; }
.hex-qb-i { border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.hex-qb-h { display: flex; align-items: center; gap: 8px; font-size: 12.5px; flex-wrap: wrap; }
.hex-qb-h b { font-weight: 600; }
.hex-opt-edit { display: flex; flex-direction: column; gap: 6px; }
.hex-op-row { display: grid; grid-template-columns: 52px minmax(0, 1fr) 56px; gap: 8px; }
.hex-op-k { text-align: center; font-weight: 600; }

@media (max-width: 1280px) {
  .hex-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hex-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hex-grid { grid-template-columns: minmax(0, 1fr); }
}

/* 题库卡片：题干长的时候不许把「编辑/删除」挤到下一行左侧 */
.hex-qb-h b { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hex-qb-h .btn { flex: 0 0 auto; }
.hex-qb-h { flex-wrap: nowrap; }
.hex-qb-h .tiny.muted { flex: 0 0 auto; white-space: nowrap; }

/* ==================================================================
 * 考试页用到的三个语义色别名
 * ------------------------------------------------------------------
 * 之前直接写了 var(--text-3) / var(--bg-2) / var(--primary-l)，
 * 但 app.css 的 :root 里从来没定义过 —— 浏览器按 invalid 处理，
 * 于是「辅助文字」全部继承成正文黑，一屏小字糊成一片。
 * 这里补上别名，不动 app.css（那套变量是所有页面在用的，别去碰）。
 * ================================================================== */
:root {
  --text-3: #868e9c;
  --bg-2: #f6f8fc;
  --primary-l: #eff4ff;
}

/* ==================================================================
 * 人事 · 在线考试 · 考生视角（PC，2026-11-14）
 * ------------------------------------------------------------------
 * 手机上是「一列滚到底」，电脑上要利用横向空间：
 * 左边题面、右边答题卡。14 道题滚一遍很长，没有答题卡就不知道
 * 还剩几道没答，最后交卷全靠运气。
 * ================================================================== */

/* ---- 我的考试 ---- */
.hex-my { display: flex; flex-direction: column; gap: 9px; }
.hex-my-i {
  border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px;
  display: flex; flex-direction: column; gap: 5px;
}
/* 正在考的那场描边：列表里一眼能认出来 */
.hex-my-i.doing { border-color: #f0d9a8; background: #fffdf7; box-shadow: inset 3px 0 0 #d99a2b; }
.hex-my-h { display: flex; align-items: center; gap: 8px; }
.hex-my-h b { font-size: 14px; font-weight: 600; min-width: 0; }
.hex-my-h .tag { flex: none; }
.hex-my-intro {
  max-height: 44px; overflow: hidden; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.hex-my-act { display: flex; align-items: center; gap: 8px; }

/* ---- 开考前的规则卡 ---- */
.hex-mystart { text-align: center; }
.hex-mystart-t { font-size: 15px; font-weight: 600; margin-bottom: 12px; }
.hex-mystart-r { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-bottom: 12px; }
.hex-mystart-r > div {
  background: var(--bg-2, #f6f8fc); border-radius: 9px; padding: 10px 4px;
  display: flex; flex-direction: column; align-items: center; gap: 1px;
}
.hex-mystart-r b { font-size: 18px; font-weight: 700; line-height: 1.1; }
.hex-mystart-r span { font-size: 11px; color: var(--text-3); }
.hex-mystart-intro {
  text-align: left; background: var(--bg-2, #f6f8fc); border-radius: 9px;
  padding: 11px 13px; font-size: 12.5px; line-height: 1.8; color: var(--text-2);
  margin-bottom: 12px; max-height: 30vh; overflow: auto; white-space: pre-wrap;
}

/* ---- 答题层：整块用满弹窗，内部自己滚 ---- */
.modal.hex-exam { max-height: 92vh; }
.modal.hex-exam .modal-body {
  padding: 0; overflow: hidden; flex: 1; min-height: 0; display: flex;
}
.hex-take { display: flex; flex-direction: column; flex: 1; min-width: 0; min-height: 0; }
.hex-take-head {
  display: flex; align-items: center; gap: 10px; padding: 11px 18px;
  border-bottom: 1px solid var(--border); flex: none; background: #fbfcfe;
}
.hex-take-t { font-size: 14px; font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hex-take-prog { font-size: 12.5px; color: var(--text-3); flex: none; }
.hex-take-prog b { color: var(--primary); font-size: 14px; }
/* 倒计时常驻：答题时最怕的就是不知道还剩多久 */
.hex-take-clock {
  flex: none; height: 26px; padding: 0 11px; border-radius: 13px;
  background: var(--primary-l, #eaf1ff); color: var(--primary);
  font-size: 12.5px; font-weight: 600; font-variant-numeric: tabular-nums;
  display: inline-flex; align-items: center;
}
.hex-take-clock.warn { background: #fdeeee; color: #d64545; }

.hex-take-body { display: flex; flex: 1; min-height: 0; }
.hex-take-main { flex: 1; min-width: 0; overflow-y: auto; padding: 16px 18px 26px; }
.hex-take-side {
  width: 208px; flex: none; border-left: 1px solid var(--border);
  padding: 14px; overflow-y: auto; background: #fbfcfe;
}
.hex-take-side-h {
  font-size: 12.5px; font-weight: 600; margin-bottom: 9px;
  display: flex; align-items: baseline; gap: 6px;
}
.hex-cells { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.hex-cell {
  height: 30px; border-radius: 7px; border: 1px solid var(--border); background: #fff;
  font-size: 12.5px; color: var(--text-2); font-variant-numeric: tabular-nums;
}
.hex-cell.on { background: var(--primary-l, #eaf1ff); border-color: #b9cff8; color: var(--primary); font-weight: 600; }
.hex-cell.cur { outline: 2px solid rgba(43, 108, 246, .35); outline-offset: 1px; }
.hex-take-legend {
  display: flex; gap: 12px; margin-top: 12px; font-size: 11px; color: var(--text-3);
}
.hex-take-legend span { display: inline-flex; align-items: center; gap: 5px; }
.hex-take-legend i {
  width: 12px; height: 12px; border-radius: 4px; border: 1px solid var(--border); background: #fff;
}
.hex-take-legend i.on { background: var(--primary-l, #eaf1ff); border-color: #b9cff8; }

/* ---- 一道题 ---- */
.hex-q { border-bottom: 1px dashed var(--border); padding: 14px 0 16px; }
.hex-q:first-child { padding-top: 2px; }
.hex-q:last-child { border-bottom: none; }
.hex-q-h { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 10px; }
.hex-q-n {
  flex: none; width: 22px; height: 22px; border-radius: 50%;
  background: var(--bg-2, #f2f5fa); color: var(--text-3);
  font-size: 11.5px; font-weight: 700; display: inline-flex;
  align-items: center; justify-content: center; margin-top: 1px;
}
.hex-q-h b { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 600; line-height: 1.65; }
.hex-q-h .tag, .hex-q-h .tiny { flex: none; margin-top: 3px; }
.hex-q-opts { display: flex; flex-direction: column; gap: 6px; padding-left: 30px; }
.hex-q-opt {
  display: flex; align-items: flex-start; gap: 8px; padding: 9px 12px;
  border: 1px solid var(--border); border-radius: 9px; cursor: pointer;
  font-size: 13px; line-height: 1.6; background: #fff;
}
.hex-q-opt:hover { border-color: #c8d6ef; }
.hex-q-opt.on { border-color: var(--primary); background: var(--primary-l, #eaf1ff); }
.hex-q-opt input { flex: none; width: 15px; height: 15px; margin: 3px 0 0; accent-color: var(--primary); }
.hex-q-opt i { flex: none; font-style: normal; font-weight: 600; color: var(--text-3); min-width: 12px; }
.hex-q-opt.on i { color: var(--primary); }
.hex-q-opt span { flex: 1; min-width: 0; }
.hex-q-in {
  width: calc(100% - 30px); margin-left: 30px; padding: 9px 12px; border-radius: 9px;
  border: 1px solid var(--border); font-size: 13px; line-height: 1.65; resize: vertical;
}
.hex-q-in:focus { outline: none; border-color: var(--primary); }

/* ---- 成绩单 ---- */
.hex-score {
  display: flex; align-items: center; gap: 14px; padding: 14px 16px;
  border-radius: 11px; border: 1px solid var(--border); margin-bottom: 12px;
}
.hex-score b { font-size: 34px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.hex-score > div { flex: 1; min-width: 0; }
/* 只给「满分/及格」那行小字上灰，不能连标签的颜色一起盖掉 */
.hex-score > div span { font-size: 12px; color: var(--text-3); }
.hex-score.ok { background: #f3fbf6; border-color: #c9ecd9; }
.hex-score.ok b { color: #17845a; }
.hex-score.no { background: #fdf4f4; border-color: #f6d7d7; }
.hex-score.no b { color: #d64545; }
.hex-score.amber { background: #fefaf1; border-color: #f3e2c4; }
.hex-score.amber b { color: #b7791f; }

/* .spacer 在 app.css 里是「按容器各写一份」的，没有全局定义。
   考试页这两处漏了，结果「交卷」和「已答 X / N」全挤在左边。 */
.hex-take-head .spacer, .hex-my-act .spacer { flex: 1; }

/* ==================================================================
 * 员工自助工作台 · PC（2026-11-14）
 * ------------------------------------------------------------------
 * 用户是全体员工，不是 HR。所以这一页的信息密度要低、字要大、
 * 「现在该干什么」要比「一共有多少」更显眼。
 * ================================================================== */

.med-main { margin-top: 14px; }

/* ---- 待办提醒条：只列现在该动手的事，最多 5 条 ---- */
.med-alerts { display: flex; flex-direction: column; gap: 7px; margin-bottom: 12px; }
.med-alert {
  display: flex; align-items: center; gap: 9px; width: 100%;
  padding: 9px 14px; border-radius: 9px; text-align: left;
  font-size: 13px; line-height: 1.5; border: 1px solid transparent;
  background: #f6f8fc; color: var(--text); cursor: pointer;
}
.med-alert:hover { filter: brightness(.985); }
.med-alert .dot { width: 7px; height: 7px; border-radius: 50%; flex: none; background: #8a94a6; }
.med-alert .arr { margin-left: auto; color: var(--text-3); font-size: 15px; }
.med-alert.warn { background: #fefaf1; border-color: #f3e2c4; }
.med-alert.warn .dot { background: #d99a2b; }
.med-alert.danger { background: #fdf4f4; border-color: #f6d7d7; color: #b3341f; }
.med-alert.danger .dot { background: #d64545; }
.med-alert.info { background: #f4f8ff; border-color: #dce7fa; }
.med-alert.info .dot { background: #2b6cf6; }

/* ---- 名片 + 四格数字 ---- */
.med-hero {
  display: grid; grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
  gap: 16px; align-items: stretch;
}
.med-who {
  display: flex; align-items: center; gap: 12px; padding: 16px 18px;
  border: 1px solid var(--border); border-radius: 12px; background: #fbfcfe;
}
.med-av {
  width: 46px; height: 46px; border-radius: 50%; flex: none;
  background: var(--primary, #2b6cf6); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 19px; font-weight: 600;
}
.med-who-t { min-width: 0; }
.med-name {
  font-size: 15.5px; font-weight: 600; display: flex; align-items: center; gap: 7px;
  margin-bottom: 3px;
}
.med-sub { font-size: 12.5px; color: var(--text-2); margin-bottom: 5px; }
.med-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 11.5px; color: var(--text-3); }

.med-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.med-kpi {
  border: 1px solid var(--border); border-radius: 12px; padding: 13px 14px;
  display: flex; flex-direction: column; gap: 2px; min-width: 0;
}
.med-kpi > span { font-size: 11.5px; color: var(--text-3); white-space: nowrap; }
.med-kpi > b {
  font-size: 21px; font-weight: 700; line-height: 1.25;
  font-variant-numeric: tabular-nums; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}
.med-kpi > i {
  font-style: normal; font-size: 11px; color: var(--text-3);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.med-kpi > i.warn { color: #b7791f; }

/* ---- 第二条：完整度 / 学时 / 合同 / 最该做的事 ---- */
.med-strip {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px; margin-top: 10px;
}
.med-strip-i {
  border: 1px solid var(--border); border-radius: 11px; padding: 11px 14px;
  display: flex; flex-direction: column; gap: 3px; min-width: 0;
}
.med-strip-i > span { font-size: 11.5px; color: var(--text-3); }
.med-strip-i > b { font-size: 15px; font-weight: 650; }
.med-strip-i > .med-todo {
  font-size: 12.5px; font-weight: 500; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.link-btn {
  align-self: flex-start; background: none; border: none; padding: 0;
  font-size: 11.5px; color: var(--primary, #2b6cf6); cursor: pointer;
}
.link-btn:hover { text-decoration: underline; }

.med-bar {
  height: 5px; border-radius: 3px; background: #eef1f6; overflow: hidden;
  width: 100%; margin: 2px 0 1px;
}
.med-bar.big { height: 7px; border-radius: 4px; }
.med-bar > i { display: block; height: 100%; background: var(--primary, #2b6cf6); border-radius: inherit; }

/* ---- 通用行 ---- */
.med-bar-row {
  display: flex; align-items: center; gap: 10px; margin-bottom: 12px; flex-wrap: wrap;
}
.med-empty { padding: 26px 0 8px; }
.med-ded { color: #b3341f; }
.med-net { color: var(--text); }
.med-reason {
  max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--text-2);
}

/* ---- 工资条明细抽屉 ---- */
.med-pay-sum {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px;
  margin-bottom: 14px;
}
.med-pay-sum > div {
  background: #f6f8fc; border-radius: 10px; padding: 11px 13px;
  display: flex; flex-direction: column; gap: 2px;
}
.med-pay-sum span { font-size: 11.5px; color: var(--text-3); }
.med-pay-sum b { font-size: 19px; font-weight: 700; font-variant-numeric: tabular-nums; }
.med-pay-sec { margin-bottom: 14px; }
.med-pay-h {
  font-size: 12px; font-weight: 600; color: var(--text-3);
  padding-bottom: 6px; border-bottom: 1px solid var(--border); margin-bottom: 4px;
}
.med-pay-row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 7px 2px; font-size: 13px; border-bottom: 1px dashed #f0f2f6;
}
.med-pay-row:last-child { border-bottom: none; }
.med-pay-row b { font-variant-numeric: tabular-nums; }
.med-dispute {
  padding: 9px 11px; border-radius: 9px; background: #fefaf1;
  border: 1px solid #f3e2c4; margin-bottom: 6px;
}
.med-dispute > div { margin-bottom: 3px; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }

/* ---- 假期额度 ---- */
.med-quota {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px; margin-bottom: 14px;
}
.med-quota-i {
  border: 1px solid var(--border); border-radius: 11px; padding: 11px 13px;
  display: flex; flex-direction: column; gap: 3px;
}
.med-quota-i > span { font-size: 11.5px; color: var(--text-3); }
.med-quota-i > b { font-size: 20px; font-weight: 700; line-height: 1.2; font-variant-numeric: tabular-nums; }
.med-quota-i > b i { font-size: 11.5px; font-style: normal; font-weight: 500; color: var(--text-3); margin-left: 2px; }
.med-quota-i > em { font-style: normal; }

/* ---- 我的合同 ---- */
.med-ct { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 12px; }
.med-ct-i {
  border: 1px solid var(--border); border-radius: 11px; padding: 13px 15px;
  display: flex; flex-direction: column; gap: 7px;
}
.med-ct-i.off { background: #fafbfd; opacity: .78; }
.med-ct-h { display: flex; align-items: center; gap: 7px; }
.med-ct-h b { font-size: 14px; font-weight: 600; }
.med-ct-d { display: flex; align-items: baseline; gap: 8px; font-size: 12.5px; }
.med-ct-d > span { color: var(--text-3); flex: 0 0 34px; }
.med-ct-d > b { font-weight: 500; }
.med-ct-d > em { font-style: normal; font-size: 11.5px; color: var(--text-3); }
.med-ct-d > em.warn { color: #b7791f; }
.med-ct-sign { font-size: 11.5px; color: var(--text-3); }
.med-ct-act { margin-top: 2px; }

/* ---- 我的考试 ---- */
.med-ex { display: flex; flex-direction: column; gap: 9px; margin-bottom: 12px; }
.med-ex-i {
  border: 1px solid var(--border); border-radius: 10px; padding: 11px 14px;
  display: flex; flex-direction: column; gap: 3px;
}
.med-ex-i.doing { border-color: #f0d9a8; background: #fffdf7; box-shadow: inset 3px 0 0 #d99a2b; }
.med-ex-h { display: flex; align-items: center; gap: 8px; }
.med-ex-h b { font-size: 13.5px; font-weight: 600; min-width: 0; }
.med-ex-h .tag { flex: none; }

/* ---- 培训 ---- */
.med-train-h { display: flex; align-items: baseline; gap: 8px; }
.med-train-h > span { font-size: 12px; color: var(--text-3); }
.med-train-h > b { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }

/* ---- 我的资料 ---- */
.med-prof { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 16px; align-items: start; }
.card-flat { border: 1px solid var(--border); border-radius: 12px; padding: 15px 17px; }
.med-prof-h {
  font-size: 13px; font-weight: 600; margin-bottom: 11px;
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
}
.med-prof-h > b { font-size: 15px; color: var(--primary, #2b6cf6); }
.med-prof-act { margin-top: 13px; display: flex; justify-content: flex-end; }
.med-prof-side { min-width: 0; }
.med-miss { display: flex; flex-wrap: wrap; gap: 5px; margin: 7px 0 4px; }
.med-ro {
  padding: 8px 0; border-bottom: 1px dashed #f0f2f6;
  display: flex; flex-direction: column; gap: 2px;
}
.med-ro:last-child { border-bottom: none; }
.med-ro > div { display: flex; align-items: baseline; gap: 8px; font-size: 12.5px; }
.med-ro > div > b { flex: 0 0 auto; color: var(--text-3); font-weight: 500; }
.med-ro > div > span { min-width: 0; word-break: break-all; }
.med-ro > em { font-style: normal; font-size: 11px; color: var(--text-3); }

/* ---- 窄屏：名片与四格改两行，别把数字挤成省略号 ---- */
@media (max-width: 1180px) {
  .med-hero { grid-template-columns: minmax(0, 1fr); }
  .med-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .med-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .med-prof { grid-template-columns: minmax(0, 1fr); }
}

/* 额度没设置 ≠ 额度是 0：显示「未设置」并压暗，避免被读成「公司没有这项假」 */
.med-quota-i.unset { background: #fbfcfe; }
.med-quota-i .med-unset { font-size: 14px; font-weight: 500; color: var(--text-3); }

/* 工资项的算法备注（如「销售岗阶梯提成」）跟在项名后面，不用括号 —— 
   备注名里本身常带括号，套起来会变成「（销售岗阶梯提成（测试））」 */
.med-pay-note { font-style: normal; font-size: 11.5px; color: var(--text-3); }
.med-miss { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin: 6px 0 3px; }
.med-miss > em { font-style: normal; font-size: 11px; color: var(--text-3); flex: 0 0 auto; }

/* ==================================================================
 * 交付中心（2026-11-14）
 * 命名统一 dvc- 前缀，避免和部门工作台、交易协同的类名撞车
 * ================================================================== */

/* 顶部提醒条 */
.dvc-alerts { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.dvc-alert {
  display: flex; align-items: center; gap: 8px; padding: 8px 12px;
  border-radius: var(--radius-sm); font-size: 13px; border: 1px solid transparent;
  background: var(--info-soft); color: #1e40af;
}
.dvc-alert i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
.dvc-alert.amber { background: var(--warn-soft); color: #92400e; }
.dvc-alert.danger { background: var(--danger-soft); color: #991b1b; }
.dvc-alert.warn { background: var(--warn-soft); color: #92400e; }
.dvc-alert.info { background: var(--info-soft); color: #1e40af; }

/* KPI 五格 */
.dvc-kpis { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-bottom: 14px; }
.dvc-kpi {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 13px 15px; box-shadow: var(--shadow); cursor: pointer; transition: .15s; position: relative;
}
.dvc-kpi:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.dvc-kpi-l { font-size: 12.5px; color: var(--muted); }
.dvc-kpi-v { font-size: 24px; font-weight: 600; letter-spacing: -.4px; margin: 3px 0 1px; }
.dvc-kpi-s { font-size: 11.5px; color: var(--muted); }
.dvc-kpi.t-amber .dvc-kpi-v { color: var(--warn); }
.dvc-kpi.t-danger .dvc-kpi-v { color: var(--danger); }
.dvc-kpi.t-purple .dvc-kpi-v { color: #7c3aed; }

/* 主页签 */
.dvc-tabs {
  display: flex; gap: 2px; background: #eceef2; padding: 3px; border-radius: 9px;
  margin-bottom: 14px; width: fit-content;
}
.dvc-tab {
  padding: 6px 16px; border-radius: 7px; font-size: 13.5px; color: var(--text-2);
  background: transparent; transition: .15s;
}
.dvc-tab.on { background: #fff; color: var(--text); box-shadow: var(--shadow); font-weight: 500; }

/* 调度台两栏 */
.dvc-desk { display: grid; grid-template-columns: minmax(0, 1fr) 302px; gap: 14px; align-items: start; }
.dvc-main { min-width: 0; }
.dvc-card { padding: 0; overflow: hidden; }
.dvc-side { display: flex; flex-direction: column; gap: 14px; }
.dvc-card-h {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 13px 16px; border-bottom: 1px solid var(--border);
}
.dvc-card-h h3 { font-size: 14px; font-weight: 500; }
.dvc-card-h > div { display: flex; gap: 8px; }

/* 视图页签 */
.dvc-views { display: flex; flex-wrap: wrap; gap: 2px; padding: 10px 12px 0; border-bottom: 1px solid var(--border); align-items: center; }
.dvc-view {
  padding: 7px 12px 9px; font-size: 13.5px; color: var(--text-2); border-bottom: 2px solid transparent;
  display: inline-flex; align-items: center; gap: 6px;
}
.dvc-view b {
  font-size: 11px; font-weight: 600; padding: 0 6px; border-radius: 9px;
  background: #eef0f4; color: var(--muted); min-width: 18px; text-align: center;
}
.dvc-view.on { color: var(--primary); border-bottom-color: var(--primary); font-weight: 500; }
.dvc-view.on b { background: var(--primary-soft); color: var(--primary); }

/* 筛选条 */
.dvc-filters { display: flex; gap: 8px; align-items: center; padding: 10px 12px; flex-wrap: wrap; }
.dvc-filters .input { height: 32px; }
.dvc-filters #dvc-kw { flex: 1; min-width: 190px; }
.dvc-filters select.input { width: auto; min-width: 118px; }
.dvc-pgbar { margin-left: auto; display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); }
.dvc-pgbar .btn[disabled] { opacity: .45; cursor: default; }
.dvc-chk { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; color: var(--text-2); }
.dvc-chk input { width: 14px; height: 14px; }

/* 批量操作条 */
.dvc-bulkbar {
  display: flex; align-items: center; gap: 10px; padding: 8px 14px;
  background: var(--primary-soft); font-size: 13px; border-top: 1px solid #dbe6ff;
}
.dvc-bulkbar b { color: var(--primary); }

/* 工单表 */
.dvc-table { width: 100%; border-collapse: collapse; font-size: 13.2px; }
.dvc-table th {
  text-align: left; font-weight: 500; color: var(--muted); font-size: 12.5px;
  padding: 9px 12px; border-bottom: 1px solid var(--border); white-space: nowrap; background: #fafbfc;
}
.dvc-table td { padding: 10px 12px; border-bottom: 1px solid #f1f2f5; vertical-align: middle; }
.dvc-table tbody tr { cursor: pointer; }
.dvc-table tbody tr:hover { background: #fafcff; }
.dvc-table .w40 { width: 38px; }
.dvc-table .w120 { width: 118px; }
.dvc-table .w130 { width: 104px; }
.dvc-table input[type=checkbox] { width: 14px; height: 14px; }
.dvc-t1 { font-weight: 500; font-size: 13.4px; }
.dvc-t2 { color: var(--muted); font-size: 12px; margin-top: 2px; }
.dvc-overrow { background: #fffbfb; }
.dvc-overrow:hover { background: #fff6f6; }
.dvc-warn {
  display: inline-flex; width: 15px; height: 15px; border-radius: 50%;
  background: var(--danger); color: #fff; font-size: 11px; align-items: center;
  justify-content: center; vertical-align: 1px;
}
.dvc-red, .dvc-red b { color: var(--danger) !important; }
.dvc-green { color: var(--success); }
.dvc-ops { white-space: nowrap; }
/* 待补信息：业务字段（商标/专利信息）没填齐的橙色角标 */
.dvc-pending {
  display: inline-block; padding: 1px 6px; border-radius: 4px;
  background: #fff7ed; color: #c2570a; border: 1px solid #fed7aa;
  font-size: 11px; line-height: 1.5; vertical-align: 1px; white-space: nowrap;
}

/* 优先级 */
.dvc-pri {
  display: inline-block; padding: 1px 7px; border-radius: 4px; font-size: 11.5px;
  background: #f1f2f5; color: var(--muted);
}
.dvc-pri.urgent { background: var(--warn-soft); color: #b45309; font-weight: 500; }
.dvc-pri.critical { background: var(--danger-soft); color: #b91c1c; font-weight: 600; }

/* 进度条 */
.dvc-pbar { height: 5px; border-radius: 3px; background: #eceef2; overflow: hidden; }
.dvc-pbar i { display: block; height: 100%; background: var(--primary); border-radius: 3px; transition: .3s; }
.dvc-ppct { font-size: 11px; color: var(--muted); margin-top: 3px; }
.dvc-mini-bar { height: 4px; border-radius: 2px; background: #eceef2; overflow: hidden; margin-top: 6px; }
.dvc-mini-bar i { display: block; height: 100%; background: var(--primary); }

/* 负载看板 */
.dvc-load-list { max-height: 560px; overflow-y: auto; }
.dvc-load-i { padding: 11px 15px; border-bottom: 1px solid #f2f3f6; }
.dvc-load-i:last-child { border-bottom: none; }
.dvc-load-i.over { background: #fffafa; }
.dvc-load-h { display: flex; align-items: center; gap: 7px; font-size: 13.4px; }
.dvc-load-h b { font-weight: 500; }
.dvc-load-h em { margin-left: auto; font-style: normal; font-size: 12.5px; color: var(--text-2); }
.dvc-load-i.over .dvc-load-h em { color: var(--danger); font-weight: 600; }
.dvc-load-bar { height: 5px; border-radius: 3px; background: #eceef2; margin: 7px 0 6px; overflow: hidden; }
.dvc-load-bar i { display: block; height: 100%; background: var(--primary); }
.dvc-load-i.over .dvc-load-bar i { background: var(--danger); }
.dvc-load-meta { display: flex; flex-wrap: wrap; gap: 9px; font-size: 11.5px; color: var(--muted); }
.dvc-load-sk { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.dvc-load-sk span {
  font-size: 11px; padding: 1px 6px; border-radius: 4px; background: var(--primary-soft); color: #1e40af;
}

/* 我的工单 */
.dvc-mine { padding: 8px; }
.dvc-mine-i {
  display: block; width: 100%; text-align: left; padding: 10px 11px; border-radius: 8px;
  border: 1px solid var(--border); margin-bottom: 8px; background: #fff;
}
.dvc-mine-i:hover { border-color: var(--primary); background: #fafcff; }
.dvc-mine-t { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 13.3px; }
.dvc-mine-s { font-size: 11.8px; color: var(--muted); margin-top: 3px; }

/* 工单详情抽屉 */
.dvc-wd-top { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.dvc-info {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 14px;
  padding: 13px 14px; background: #fafbfc; border-radius: var(--radius-sm); margin-bottom: 14px;
}
.dvc-info label { display: block; font-size: 11.5px; color: var(--muted); margin-bottom: 2px; }
.dvc-info b { font-size: 13.2px; font-weight: 500; }
.dvc-req { padding: 11px 14px; background: var(--warn-soft); border-radius: var(--radius-sm); margin-bottom: 14px; }
.dvc-req label { font-size: 11.5px; color: #92400e; }
.dvc-req p { font-size: 13px; margin-top: 3px; line-height: 1.7; }
/* 业务字段区（2026-11-26）：商标申请号/类别、专利号/名称等可自定义字段 */
.dvc-fields-sec { padding: 13px 14px; background: #fafbfc; border-radius: var(--radius-sm); }
.dvc-fields { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 14px; }
.dvc-fld { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.dvc-fld label { font-size: 12px; color: var(--muted); }
.dvc-fld label em { font-style: normal; color: #dc2626; }
.dvc-fld .inp { width: 100%; }
.dvc-fields-bar { margin-top: 12px; display: flex; justify-content: flex-end; }
.dvc-ex { padding: 12px 14px; background: var(--danger-soft); border-radius: var(--radius-sm); margin-bottom: 14px; }
.dvc-ex b { color: #991b1b; font-size: 13.4px; }
.dvc-ex p { font-size: 13px; margin: 5px 0 4px; color: #7f1d1d; line-height: 1.7; }

/* 申报信息（第 9 条） */
.dvc-apply-sec { padding: 13px 14px; background: #fbfcfe; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.dvc-apply { display: flex; flex-direction: column; gap: 10px; }
.dvc-apply-item label { font-size: 11.5px; color: var(--muted); display: block; margin-bottom: 3px; }
.dvc-apply-item p { font-size: 13px; line-height: 1.7; margin: 0; }
.dvc-apply-item.ask { padding: 9px 12px; background: var(--warn-soft); border-radius: 7px; }
.dvc-apply-item.ask label { color: #92400e; }
.dvc-apply-item.reply { padding: 9px 12px; background: #f0f9f4; border-radius: 7px; }
.dvc-apply-item.reply label { color: #166534; }
.dvc-apply-bar { margin-top: 12px; display: flex; gap: 8px; justify-content: flex-end; }

.dvc-sec { margin-bottom: 20px; }
.dvc-sec-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.dvc-sec-h h4 { font-size: 13.6px; font-weight: 500; }
.dvc-sec-h h4 em { font-style: normal; color: var(--muted); font-size: 12px; margin-left: 6px; }

/* 节点时间轴 */
.dvc-nodes { display: flex; flex-direction: column; }
.dvc-node { display: flex; gap: 11px; padding-bottom: 14px; position: relative; }
.dvc-node::before {
  content: ""; position: absolute; left: 11px; top: 24px; bottom: 0; width: 1px; background: #e4e7ec;
}
.dvc-node:last-child { padding-bottom: 0; }
.dvc-node:last-child::before { display: none; }
.dvc-node-dot {
  width: 23px; height: 23px; border-radius: 50%; flex: none; z-index: 1;
  display: flex; align-items: center; justify-content: center;
  font-size: 11.5px; background: #f1f2f5; color: var(--muted); border: 1px solid var(--border-strong);
}
.dvc-node.done .dvc-node-dot { background: var(--success); color: #fff; border-color: var(--success); }
.dvc-node.doing .dvc-node-dot { background: var(--primary); color: #fff; border-color: var(--primary); }
.dvc-node-b { flex: 1; min-width: 0; }
.dvc-node-h { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.dvc-node-h b { font-size: 13.3px; font-weight: 500; }
.dvc-node.done .dvc-node-h b { color: var(--muted); }
.dvc-node-d { font-size: 12.4px; color: var(--text-2); margin-top: 3px; line-height: 1.6; }
.dvc-node-note { font-size: 12.3px; color: var(--text-2); margin-top: 5px; padding-left: 8px; border-left: 2px solid var(--border-strong); }
.dvc-mats { margin-top: 7px; padding: 8px 10px; background: #fafbfc; border-radius: 6px; }
.dvc-mat { display: flex; align-items: center; gap: 6px; font-size: 12.4px; padding: 3px 6px; border-radius: 5px; cursor: pointer; }
/* 勾没勾要一眼看得出来：13px 原生复选框在浅灰底上几乎没差别，
   客户现场核对「哪些收到、哪些还差」全靠这一眼 */
.dvc-mat input { width: 14px; height: 14px; accent-color: var(--success); }
.dvc-mat.ok { background: var(--success-soft); }
.dvc-mat.ok span { color: #15803d; text-decoration: none; }
.dvc-mat em { color: var(--danger); font-style: normal; }
.dvc-nfiles { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.dvc-nfiles a { font-size: 12.3px; color: var(--primary); text-decoration: underline; }

/* 材料列表 */
.dvc-files { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.dvc-file {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid #f2f3f6;
}
.dvc-file:last-child { border-bottom: none; }
.dvc-file-n { font-size: 13px; font-weight: 500; flex: 1; min-width: 0; word-break: break-all; }
.dvc-file-m { font-size: 11.6px; color: var(--muted); }
.dvc-none { padding: 18px; text-align: center; color: var(--muted); font-size: 12.8px; }

/* 日志时间轴 */
.dvc-logs { display: flex; flex-direction: column; gap: 0; }
.dvc-log { display: flex; gap: 10px; padding-bottom: 12px; position: relative; }
.dvc-log::before { content: ""; position: absolute; left: 3px; top: 12px; bottom: 0; width: 1px; background: #eceef2; }
.dvc-log:last-child::before { display: none; }
.dvc-log i {
  width: 7px; height: 7px; border-radius: 50%; background: var(--border-strong); flex: none; margin-top: 6px; z-index: 1;
}
.dvc-log-t { font-size: 12.8px; font-weight: 500; }
.dvc-log-n { font-size: 12.4px; color: var(--text-2); margin-top: 2px; line-height: 1.6; }
.dvc-log-m { font-size: 11.4px; color: var(--muted); margin-top: 2px; }

/* 指派推荐 */
.dvc-rec-h { font-size: 12.4px; color: var(--muted); margin-bottom: 8px; }
.dvc-recs { display: flex; flex-direction: column; gap: 7px; margin-bottom: 14px; }
.dvc-recs-all { max-height: 240px; overflow: auto; padding-right: 4px; }
.dvc-rec {
  display: flex; gap: 9px; align-items: flex-start; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer;
}
.dvc-rec.on { border-color: var(--primary); background: var(--primary-soft); }
.dvc-rec.over { background: #fffafa; }
.dvc-rec input { margin-top: 3px; }
.dvc-rec b { font-size: 13.2px; font-weight: 500; }
.dvc-rec-r { font-size: 11.8px; color: var(--muted); margin-top: 1px; }

/* 异常处理二选一 */
.dvc-choices { display: flex; flex-direction: column; gap: 8px; }
.dvc-choice {
  display: flex; gap: 9px; padding: 11px 12px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); cursor: pointer; align-items: flex-start;
}
.dvc-choice.on { border-color: var(--primary); background: var(--primary-soft); }
.dvc-choice b { display: block; font-size: 13.2px; font-weight: 500; }
.dvc-choice span { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; line-height: 1.5; }

/* 报表 */
.dvc-rpt-h { display: flex; align-items: center; gap: 4px; padding: 10px 12px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.dvc-rpt-act { margin-left: auto; }
.dvc-rpt { padding: 0; }
#dvc-rpt { padding: 14px 16px; }
.dvc-rpt-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin-bottom: 14px; }
.dvc-mini { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px 13px; }
.dvc-mini span { display: block; font-size: 11.8px; color: var(--muted); }
.dvc-mini b { font-size: 19px; font-weight: 600; }
.dvc-rpt-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 10px; }
.dvc-exbar { margin-bottom: 14px; }
.dvc-exbar-i { display: grid; grid-template-columns: 120px 1fr 40px; gap: 10px; align-items: center; font-size: 12.6px; margin-bottom: 7px; }
.dvc-rowlink { cursor: pointer; }
.dvc-rowlink:hover { background: #fafcff; }

/* 业务达成统计（2026-11-15）：区间条 + 走势柱 + 人员展开明细 */
.dvc-rng { display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 8px 10px; margin-bottom: 12px; background: #fafbfd;
  border: 1px solid var(--border); border-radius: var(--radius-sm); }
.dvc-rng-tabs { display: flex; gap: 2px; flex-wrap: wrap; }
.dvc-rng-cust { display: flex; align-items: center; gap: 7px; }
.dvc-rng-cust .input { height: 32px; width: 148px; }
.dvc-rng-sep { font-size: 12.4px; color: var(--muted); }

.dvc-sub-h { display: flex; align-items: baseline; gap: 9px; flex-wrap: wrap;
  font-size: 13px; font-weight: 600; margin: 16px 0 9px; padding-left: 9px;
  border-left: 3px solid var(--primary); line-height: 1.5; }
.dvc-sub-h span { font-size: 11.8px; font-weight: 400; color: var(--muted); }

.dvc-trend { display: flex; align-items: flex-end; gap: 4px; overflow-x: auto;
  padding: 4px 2px 2px; border-bottom: 1px solid var(--border); }
.dvc-trend-i { flex: 1 0 22px; min-width: 22px; max-width: 64px; display: flex; flex-direction: column;
  align-items: center; gap: 4px; }
.dvc-trend-b { width: 100%; max-width: 30px; height: 58px; display: flex;
  flex-direction: column-reverse; justify-content: flex-start; border-radius: 3px 3px 0 0; overflow: hidden; }
.dvc-trend-b i { display: block; background: var(--primary); }
.dvc-trend-b u { display: block; background: #c9d7f7; }
.dvc-trend-i span { font-size: 10.4px; color: var(--muted); white-space: nowrap; }

.dvc-pers td { white-space: nowrap; }
.dvc-prow { cursor: pointer; }
.dvc-prow:hover { background: #fafcff; }
.dvc-prow-ar { font-style: normal; color: var(--muted); margin-left: 6px; font-size: 11px;
  display: inline-block; transition: transform .15s; }
.dvc-prow.open .dvc-prow-ar { transform: rotate(90deg); color: var(--primary); }
.dvc-pcats > td { background: #fafbfd; padding: 0 !important; }
.dvc-pcats-in { padding: 10px 14px 12px; }
.dvc-pcats-h { font-size: 12.4px; font-weight: 600; margin-bottom: 8px; color: var(--text-2); }
.dvc-pcats table { background: #fff; border-radius: 6px; }
/* 触屏窄屏：两张表允许横向滚动，不挤成两行 */
.dvc-pers, .dvc-pcats table { min-width: 640px; }

/* 业务目录 */
.dvc-cat-h { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.dvc-cat-tabs { display: flex; gap: 2px; flex-wrap: wrap; }
.dvc-cat-h .input { height: 32px; width: 200px; margin-left: auto; }
.dvc-cat-tip { padding: 10px 16px; font-size: 12.4px; line-height: 1.75; color: var(--muted); background: #fafbfc; border-bottom: 1px solid var(--border); }
.dvc-cat-tip b { color: var(--text-2); font-weight: 600; }
.dvc-cat-list { padding: 6px 10px 12px; }
.dvc-cat-i { padding: 10px 8px; border-bottom: 1px solid #f3f4f7; cursor: pointer; border-radius: 6px; }
.dvc-cat-i:hover { background: #fafcff; }
.dvc-cat-i:last-child { border-bottom: none; }
.dvc-cat-r { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.dvc-cat-r b { font-size: 13.4px; font-weight: 500; }
.dvc-cat-m { font-size: 12.2px; color: var(--muted); margin-top: 3px; }
.dvc-cat-m b { color: var(--text-2); }
.dvc-cat-x { margin-top: 9px; padding: 10px 12px; background: #fafbfc; border-radius: 7px; }
.dvc-cat-n {
  display: inline-flex; align-items: center; gap: 6px; font-size: 12.3px;
  padding: 3px 9px; background: #fff; border: 1px solid var(--border); border-radius: 20px; margin: 0 6px 6px 0;
}
.dvc-cat-n i {
  font-style: normal; width: 16px; height: 16px; border-radius: 50%; background: var(--primary-soft);
  color: var(--primary); font-size: 10.5px; display: inline-flex; align-items: center; justify-content: center;
}
.dvc-cat-n em { font-style: normal; color: var(--muted); font-size: 11px; }
.dvc-cat-mat { font-size: 12px; color: var(--text-2); margin-top: 4px; line-height: 1.7; }

/* 配置 */
.dvc-cfg { display: flex; flex-direction: column; gap: 14px; }
.dvc-tip { padding: 9px 16px; font-size: 12.2px; color: var(--muted); background: #fafbfc; border-top: 1px solid var(--border); }
.dvc-off { opacity: .55; }
.dvc-cfg-form { padding: 14px 16px; display: flex; flex-direction: column; gap: 14px; }
.dvc-cfg-form .field label { font-size: 12.6px; font-weight: 500; display: block; margin-bottom: 5px; }
.dvc-cfg-form .field .input { max-width: 220px; }
.dvc-switches { display: flex; flex-wrap: wrap; gap: 10px 18px; }
.dvc-sw { display: inline-flex; align-items: center; gap: 6px; font-size: 12.8px; color: var(--text-2); }
.dvc-dict { padding: 14px 16px; display: flex; flex-direction: column; gap: 11px; }
.dvc-dict label { display: block; font-size: 11.8px; color: var(--muted); margin-bottom: 4px; }
.dvc-dict > div > div { display: flex; flex-wrap: wrap; gap: 5px; }
.dvc-cfg-foot { padding: 0 16px 14px; display: flex; gap: 8px; }

@media (max-width: 1180px) {
  .dvc-desk { grid-template-columns: minmax(0, 1fr); }
  .dvc-kpis { grid-template-columns: repeat(3, 1fr); }
  .dvc-rpt-2 { grid-template-columns: 1fr; }
  .dvc-info { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .dvc-kpis { grid-template-columns: repeat(2, 1fr); }
  .dvc-info { grid-template-columns: 1fr; }
}

/* 订单详情里的交付节点小标签（只读展示，处理动作在交付中心） */
.od-dn { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.od-dn-i {
  display: inline-flex; align-items: center; gap: 5px; font-size: 12.2px; padding: 3px 9px;
  border-radius: 20px; background: #f4f5f8; color: var(--muted); border: 1px solid transparent;
}
.od-dn-i.on { background: var(--success-soft); color: #15803d; }
.od-dn-i.cur { background: var(--primary-soft); color: #1e40af; border-color: #c7d7fe; }
.od-dn-i i { font-style: normal; font-size: 11px; opacity: .75; }
.od-dn-i.od-dn-od { background: #fef2f2; color: #dc2626; border-color: #fecaca; }
.od-dn-i.od-dn-od i { opacity: 1; font-weight: 600; }
/* 节点明细：完成日期 + 通知文件下载（老板要的「带出每个节点完成日期 + 能下载通知文件」） */
.od-dn-detail { margin-top: 10px; border: 1px solid var(--line); border-radius: 8px; padding: 6px 12px; background: #fafbfc; }
.od-dn-row { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: 12.5px; }
.od-dn-row:last-child { border-bottom: 0; }
.od-dn-nm { color: var(--text); font-weight: 500; }
.od-dn-dt { color: #15803d; font-size: 12px; white-space: nowrap; }
.od-dn-fs { display: inline-flex; flex-wrap: wrap; gap: 4px 10px; }
.od-dn-file { color: var(--primary); text-decoration: none; font-size: 12px; }
.od-dn-file:hover { text-decoration: underline; }
/* 一单多业务：每项业务一块，块之间用虚线分隔，别让人误以为是同一张工单的节点 */
.od-dv-row { padding: 12px 0; border-top: 1px dashed var(--line); }
.od-dv-row:first-child { border-top: 0; }
.od-dv-h { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.od-dv-h b { font-size: 13.5px; color: var(--text); }
.od-dv-row .od-dn { margin-top: 8px; }

/* 办理材料 / 申报信息（订单详情交付进展区） */
.od-apply-hint { font-size: 12.3px; color: var(--muted); background: var(--bg-soft, #f8fafc); border: 1px dashed var(--border); border-radius: 6px; padding: 8px 10px; margin-top: 10px; line-height: 1.6; }
.od-apply-line { font-size: 12.3px; color: var(--muted); margin-top: 8px; line-height: 1.6; }
.ap-files { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.ap-file { display: flex; align-items: center; gap: 10px; justify-content: space-between; padding: 7px 10px; border: 1px solid var(--border); border-radius: 6px; font-size: 12.5px; background: #fafbfd; }
.ap-file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* hidden 属性在 display:flex/grid 上会被忽略，批量条必须显式收起来 */
.dvc-bulkbar[hidden] { display: none !important; }

/* 工单表列宽：窄屏下先保住「谁、什么时候到期、能不能点」，其余按比例让位 */
.dvc-table th, .dvc-table td { white-space: nowrap; }
.dvc-table td.c-biz, .dvc-table td.c-cust { white-space: normal; }
.dvc-table .c-chk { width: 34px; }
.dvc-table .c-biz { min-width: 172px; }
.dvc-table .c-cust { min-width: 118px; max-width: 160px; }
.dvc-table .c-pri { width: 58px; }
.dvc-table .c-st { width: 74px; }
.dvc-table .c-node { width: 84px; }
.dvc-table .c-who { width: 74px; }
.dvc-table .c-due { width: 88px; }
.dvc-table .c-ops { width: 72px; min-width: 72px; }
.dvc-table th, .dvc-table td { padding-left: 10px; padding-right: 10px; }
/* 窄屏下右侧栏收到 286px；必须带 min-width，否则会盖掉上面 1180px 的单列规则 */
@media (min-width: 1181px) {
  .dvc-desk { grid-template-columns: minmax(0, 1fr) 286px; }
}

/* ------------------------------------------------------------------
 * 工单列表：自带纵向滚动，分页条常驻底部
 * 「已完成 69」这种长列表，原来分页器被 20 行表格顶到视口外，
 * 使用者滚半天也不确定能不能翻页 —— 现在列表区自己滚，页码永远在眼前。
 * ------------------------------------------------------------------ */
.dvc-listbox { display: flex; flex-direction: column; min-width: 0; }
.dvc-scroll { max-height: calc(100vh - 330px); min-height: 260px; overflow: auto; }
.dvc-scroll > .table-wrap { overflow: visible; }
.dvc-scroll thead th {
  position: sticky; top: 0; z-index: 2;
  box-shadow: inset 0 -1px 0 var(--border);
}
/* 操作列贴右边：横向滚动时「指派 / 查看」不会先被裁掉 */
.dvc-table .c-ops { position: sticky; right: 0; background: #fff; box-shadow: -6px 0 8px -6px rgba(15, 23, 42, .12); }
.dvc-table thead th.c-ops { background: #fafbfc; }
.dvc-table tbody tr:hover .c-ops { background: #fafcff; }
.dvc-table tbody tr.dvc-overrow .c-ops { background: #fffbfb; }
.dvc-foot {
  display: flex; align-items: center; justify-content: flex-end; gap: 10px;
  min-height: 44px; padding: 6px 14px; border-top: 1px solid var(--border); background: #fff;
  /* 吸在滚动容器（.view）底部：屏幕矮的时候页头会吃掉高度，靠 JS 精算太脆，
     sticky 让分页条无论在什么分辨率下都留在眼前 */
  position: sticky; bottom: 0; z-index: 3;
}
/* 窄屏（笔记本 1366 及以下）把人员负载收到主列表下方，别跟表格抢那 286px */
@media (max-width: 1360px) {
  .dvc-desk { grid-template-columns: minmax(0, 1fr); }
  .dvc-scroll { max-height: none; }
}

/* 材料清单：通用件（企业基础资料）与超量收口项用浅底区分，不抢专属材料的注意力 */
.dvc-mat.base, .dvc-mat.more { width: 100%; box-sizing: border-box; background: #e9eff8;
  border-radius: 4px; padding: 3px 6px; margin-top: 3px; }
.dvc-mat.base span, .dvc-mat.more span { color: #4a5a70; }
/* 已勾的合并件也要变绿：灰底 + 灰字会让人以为「这项还没收」 */
.dvc-mat.base.ok, .dvc-mat.more.ok { background: var(--success-soft); }
.dvc-mat.base.ok span, .dvc-mat.more.ok span { color: #15803d; }
.dvc-mat-i { margin-left: 6px; font-style: normal; font-size: 11px; color: var(--muted);
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 0 6px; }
.dvc-mat.ok .dvc-mat-i { color: #15803d; }
.dvc-cat-mat .muted { color: var(--muted); }

/* 上传进度浮层：不遮页面（上传时还能看别的），但绝不让人以为卡死 */
.dvc-upg { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 2600;
  width: 320px; max-width: calc(100vw - 32px); padding: 13px 15px 12px; background: #fff;
  border-radius: 10px; box-shadow: 0 10px 30px rgba(15, 35, 70, .18); border: 1px solid #e3ecfa; }
.dvc-upg-t { font-size: 13px; color: #22303f; margin-bottom: 8px; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; }
.dvc-upg-bar { height: 6px; border-radius: 99px; background: #e9eff8; overflow: hidden; }
.dvc-upg-bar i { display: block; height: 100%; width: 0; background: var(--primary);
  border-radius: 99px; transition: width .18s ease; }

/* 同单其他业务：客户问「另一项到哪了」时，交付员要能当场答上来 */
.dvc-sib { margin: 0 0 12px; padding: 10px 12px; background: #f4f8ff; border: 1px solid #dbe7fb;
  border-radius: 8px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.dvc-sib > b { font-size: 12.5px; color: #1e3a63; }
.dvc-sib-i { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--text-2);
  background: #fff; border: 1px solid #e2ebfa; border-radius: 999px; padding: 2px 9px; }
.dvc-sib-i em { font-style: normal; font-weight: 600; }
.dvc-sib-i em.blue { color: #1d4ed8; } .dvc-sib-i em.amber { color: #b45309; }
.dvc-sib-i em.green { color: #15803d; } .dvc-sib-i em.gray { color: #64748b; }
.dvc-sib-i em.red { color: #b91c1c; } .dvc-sib-i em.purple { color: #7c3aed; }
.dvc-sib-i i { font-style: normal; color: var(--muted); }

/* ==================================================================
 * 法务工作台（2026-11-14）
 * 前缀统一 lg-，与 dvc-（交付中心）不撞车
 * 设计口径：一张合同要能一口气看完「版本 → 风险 → 节点 → 评审 → 日志」，
 *          所以抽屉里的每一段都做留白分隔，不做卡片套卡片。
 * ================================================================== */

/* 顶部提醒条：没内容时不占高度 */
.lg-alertbar { display: flex; flex-direction: column; gap: 8px; }
.lg-alertbar:empty { display: none; }
.lg-alert { display: flex; align-items: center; gap: 8px; padding: 9px 13px; border-radius: var(--radius-sm);
  font-size: 13px; background: var(--info-soft); color: #1e40af; border: 1px solid #dbe6fb; }
.lg-alert.amber { background: var(--warn-soft); color: #92400e; border-color: #f3e2c0; }
.lg-alert.danger { background: var(--danger-soft); color: #991b1b; border-color: #f6d5d7; }
.lg-alert i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }

/* 页签容器允许多行（八个页签在 1280 宽会挤） */
.lg-tabs { flex-wrap: wrap; width: fit-content; max-width: 100%; }

/* KPI 六格 */
.lg-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; margin-bottom: 14px; }
.lg-kpi {
  text-align: left; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 13px 15px; box-shadow: var(--shadow); transition: .15s; min-width: 0;
}
.lg-kpi:hover { border-color: var(--border-strong); transform: translateY(-1px); box-shadow: var(--shadow-lg); }
.lg-kpi-l { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lg-kpi-v { font-size: 24px; font-weight: 600; letter-spacing: -.4px; margin: 3px 0 1px; line-height: 1.2; }
.lg-kpi-s { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lg-kpi.t-amber .lg-kpi-v { color: var(--warn); }
.lg-kpi.t-danger .lg-kpi-v { color: var(--danger); }
.lg-kpi.t-purple .lg-kpi-v { color: #7c3aed; }

/* 两栏 */
.lg-grid2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; align-items: start; }
.lg-card { padding: 0; overflow: hidden; }
.lg-card-h { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.lg-card-h h3 { font-size: 14px; font-weight: 500; }
.lg-card-h.lg-mt, .lg-card-h + .lg-mt { margin-top: 0; }
.lg-mt { margin-top: 14px; }
.lg-sp { flex: 1; }
.lg-none { padding: 22px 16px; text-align: center; font-size: 13px; color: var(--muted); }
.lg-tip { background: #f6f8fc; border: 1px solid #e7edf7; border-radius: var(--radius-sm);
  padding: 9px 12px; font-size: 12.5px; color: var(--text-2); line-height: 1.65; }
.lg-tip.warn { background: var(--warn-soft); border-color: #f3e2c0; color: #92400e; }
.lg-amber { color: var(--warn); }

/* 看板：待处理风险小列表 */
.lg-risk-mini { display: flex; flex-direction: column; }
.lg-risk-mini-i { display: flex; align-items: center; gap: 10px; padding: 10px 16px; text-align: left;
  border-bottom: 1px solid var(--border); width: 100%; }
.lg-risk-mini-i:last-child { border-bottom: 0; }
.lg-risk-mini-i:hover { background: #fafbfd; }
.lg-risk-mini-i > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.lg-risk-mini-i b { font-size: 13px; font-weight: 500; }
.lg-risk-mini-i span { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lg-risk-mini-i em.tag { flex: none; }
.lg-dot { width: 7px; height: 7px; border-radius: 50%; flex: none; background: #c3cad6; }
.lg-dot.red { background: var(--danger); }
.lg-dot.amber { background: var(--warn); }
.lg-dot.green { background: var(--success); }
.lg-dot.blue { background: var(--primary); }
.lg-dot.gray { background: #c3cad6; }

/* 风险等级分布 */
.lg-dots { padding: 14px 16px; display: flex; flex-direction: column; gap: 9px; }
.lg-dotrow { display: grid; grid-template-columns: 46px minmax(0, 1fr) 32px; align-items: center; gap: 10px; }
.lg-dot-l { font-size: 12.5px; color: var(--text-2); }
.lg-dotrow > b { font-size: 13px; text-align: right; }
.lg-dotbar { height: 8px; border-radius: 99px; background: #eef1f6; overflow: hidden; }
.lg-dotbar > i { display: block; height: 100%; border-radius: 99px; background: #94a3b8; transition: width .3s; }
.lg-dotbar > i.red { background: var(--danger); }
.lg-dotbar > i.amber { background: var(--warn); }
.lg-dotbar > i.blue { background: var(--primary); }
.lg-dotbar > i.gray { background: #94a3b8; }

/* 到期提醒 */
.lg-warnlist { display: flex; flex-direction: column; }
.lg-warn-i { display: flex; align-items: center; gap: 10px; padding: 10px 16px; text-align: left;
  border-bottom: 1px solid var(--border); width: 100%; }
.lg-warn-i:last-child { border-bottom: 0; }
.lg-warn-i:hover { background: #fafbfd; }
.lg-warn-i > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.lg-warn-i b { font-size: 13px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lg-warn-i span { font-size: 12px; color: var(--muted); }
.lg-warn-i em { font-style: normal; font-size: 12px; color: var(--warn); flex: none; }

/* 类型分布 */
.lg-types { display: flex; flex-wrap: wrap; gap: 10px; padding: 14px 16px; }
.lg-type { display: flex; flex-direction: column; align-items: center; gap: 1px; min-width: 92px;
  flex: 1 1 92px; /* 铺满整行，否则右边一大片空白 */
  padding: 10px 12px; background: #f8fafc; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.lg-type b { font-size: 18px; font-weight: 600; }
.lg-type span { font-size: 12px; color: var(--muted); }

/* 台账筛选行 */
.lg-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.lg-filters .input { width: auto; min-width: 132px; height: 32px; }
.lg-filters input.input#lg-kw { min-width: 230px; flex: 1 1 230px; }
.lg-filters .btn { height: 32px; }

/* 台账表：8 列，金额/操作右对齐 */
.lg-table { display: flex; flex-direction: column; }
.lg-tr { display: grid; grid-template-columns: minmax(210px, 2fr) minmax(120px, 1.3fr) 92px 110px 88px 104px 96px 62px;
  align-items: center; gap: 10px; padding: 11px 16px; border-bottom: 1px solid var(--border); font-size: 13px; }
.lg-tr:last-child { border-bottom: 0; }
.lg-tr > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-tr > span > b { font-weight: 500; }
.lg-tr > span > i { display: block; font-style: normal; font-size: 11.5px; color: var(--muted);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-th { background: #f8fafc; font-size: 12px; color: var(--muted); font-weight: 500; padding: 9px 16px; }
.lg-tr[data-cid] { cursor: pointer; }
.lg-tr[data-cid]:hover { background: #fafbfd; }
.ta-r { text-align: right; }

.lg-foot { display: flex; align-items: center; gap: 8px; padding: 11px 16px; border-top: 1px solid var(--border); }

/* 摘要视图（业务角色只看交付相关约定） */
.lg-masked h4 { font-size: 15px; font-weight: 500; margin-bottom: 4px; }
.lg-masked p { margin-bottom: 12px; }

/* 抽屉头 */
.lg-hd { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.lg-hd-t { min-width: 0; }
.lg-hd-t h4 { font-size: 16px; font-weight: 500; line-height: 1.4; }
.lg-hd-tags { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; flex: none; max-width: 55%; }

/* 键值网格 */
.lg-kv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px;
  background: var(--border); border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.lg-kv-i { display: flex; align-items: baseline; gap: 8px; padding: 9px 12px; background: #fff; min-width: 0; }
.lg-kv-i > i { font-style: normal; font-size: 12px; color: var(--muted); flex: none; width: 62px; }
.lg-kv-i > b { font-size: 13px; font-weight: 500; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 抽屉内的分段 */
.lg-sec { margin-top: 20px; }
.lg-sec-h { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.lg-sec-h h4 { font-size: 13.5px; font-weight: 600; }

/* 版本列表 */
.lg-vers { display: flex; flex-direction: column; gap: 6px; }
.lg-ver { display: flex; align-items: center; gap: 10px; padding: 8px 12px; background: #f8fafc;
  border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 12.5px; }
.lg-ver > b { flex: none; font-weight: 600; color: var(--primary); }
.lg-ver-k { flex: none; font-size: 11.5px; color: var(--text-2); background: #fff; border: 1px solid var(--border);
  border-radius: 999px; padding: 0 8px; }
.lg-ver-n { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-cmp { display: flex; align-items: center; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.lg-cmp .input { width: 96px; height: 30px; }

/* 版本比对 */
.lg-cmp-res { display: flex; flex-direction: column; }
.lg-cmp-stat { font-size: 12.5px; color: var(--text-2); background: #f6f8fc; border-radius: var(--radius-sm);
  padding: 8px 12px; margin-bottom: 8px; }
.lg-diff { font-size: 12.5px; line-height: 1.7; padding: 8px 11px; border-radius: 6px; margin-bottom: 6px;
  background: #f8fafc; border-left: 3px solid var(--border-strong); white-space: pre-wrap; }
.lg-diff.add { background: #f2fbf5; border-left-color: var(--success); }
.lg-diff.del { background: #fdf3f3; border-left-color: var(--danger); text-decoration: line-through; color: #8a4a4a; }

/* 风险条目：一条一条读，等级用左侧色带区分 */
.lg-risks { display: flex; flex-direction: column; gap: 10px; }
.lg-risk { border: 1px solid var(--border); border-left: 3px solid var(--border-strong);
  border-radius: var(--radius-sm); padding: 11px 13px; background: #fff; }
.lg-risk.high { border-left-color: var(--danger); }
.lg-risk.mid { border-left-color: var(--warn); }
.lg-risk.low { border-left-color: var(--primary); }
.lg-risk.done { background: #fbfcfd; }
.lg-risk-h { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-bottom: 6px; }
.lg-risk-h > b { font-size: 13.5px; font-weight: 500; }
.lg-risk-d { font-size: 12.5px; color: var(--text-2); line-height: 1.65; }
.lg-risk-q, .lg-risk-a, .lg-risk-r { position: relative; margin-top: 8px; padding: 8px 11px 8px 42px;
  font-size: 12.5px; line-height: 1.7; border-radius: 6px; white-space: pre-wrap; }
.lg-risk-q { background: #f8fafc; color: var(--text-2); }
.lg-risk-a { background: var(--info-soft); color: #1e40af; }
.lg-risk-r { background: #f2fbf5; color: #14532d; }
.lg-risk-q > i, .lg-risk-a > i, .lg-risk-r > i { position: absolute; left: 11px; top: 8px; font-style: normal;
  font-size: 11px; font-weight: 600; opacity: .75; }
.lg-risk-txt { white-space: pre-wrap; }
.lg-risk-r .btn { margin-top: 6px; }
.lg-risk-loose { margin-top: 8px; font-size: 12.5px; }
.lg-risk-loose > summary { cursor: pointer; color: var(--primary); font-size: 12.5px; padding: 2px 0; }
.lg-risk-loose .lg-risk-txt { margin-top: 6px; padding: 8px 11px; background: #f8fafc; border-radius: 6px; }

/* 节点列表（履约节点 / 证据清单共用） */
.lg-nodes { display: flex; flex-direction: column; gap: 6px; }
.lg-node { display: flex; align-items: center; gap: 10px; padding: 9px 12px; background: #f8fafc;
  border: 1px solid var(--border); border-radius: var(--radius-sm); }
.lg-node > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.lg-node b { font-size: 13px; font-weight: 500; }
.lg-node span { font-size: 11.5px; color: var(--muted); }
.lg-node > em { font-style: normal; font-size: 12px; color: var(--muted); flex: none; }
.lg-node .btn { flex: none; }

/* 评审记录 */
.lg-revs { display: flex; flex-direction: column; gap: 8px; }
.lg-rev { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px 12px; }
.lg-rev-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.lg-rev-h > b { font-size: 13px; font-weight: 500; }
.lg-rev-c { margin-top: 7px; padding: 8px 11px; background: #f8fafc; border-radius: 6px;
  font-size: 12.5px; line-height: 1.7; white-space: pre-wrap; }

/* 关联文书 / 模板 / 条款 / 黑名单的紧凑行 */
.lg-doc-i { display: flex; align-items: center; gap: 10px; padding: 9px 16px; border-bottom: 1px solid var(--border); }
.lg-doc-i:last-child { border-bottom: 0; }
.lg-doc-i > span { flex: 1; min-width: 0; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-doc-i > em.tag { flex: none; }
.lg-sec .lg-doc-i { padding-left: 0; padding-right: 0; }

/* AI 日志 */
.lg-logs { display: flex; flex-direction: column; gap: 4px; }
.lg-log { display: flex; align-items: baseline; gap: 8px; font-size: 12px; padding: 6px 10px;
  background: #f8fafc; border-radius: 6px; flex-wrap: wrap; }
.lg-log > b { font-weight: 500; flex: none; }
.lg-log > em { font-style: normal; margin-left: auto; color: var(--muted); flex: none; }

/* 评审队列 */
.lg-queue { display: flex; flex-direction: column; }
.lg-q-i { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 16px; border-bottom: 1px solid var(--border); text-align: left; width: 100%; }
.lg-q-i:last-child { border-bottom: 0; }
.lg-q-i:hover { background: #fafbfd; }
.lg-q-l { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.lg-q-l b { font-size: 13.5px; font-weight: 500; }
.lg-q-l span { font-size: 12px; color: var(--muted); }
.lg-q-r { display: flex; align-items: center; gap: 6px; flex: none; flex-wrap: wrap; justify-content: flex-end; }
/* 整行是按钮，但光看不一定知道能点，给个明确的入口提示 */
.lg-q-go { font-style: normal; font-size: 12px; color: var(--primary); white-space: nowrap; }

/* 文书列表 */
.lg-docs { display: flex; flex-direction: column; }
.lg-doc { padding: 12px 16px; border-bottom: 1px solid var(--border); cursor: pointer; }
.lg-doc:last-child { border-bottom: 0; }
.lg-doc:hover { background: #fafbfd; }
.lg-doc-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.lg-doc-h > b { font-size: 13.5px; font-weight: 500; }
.lg-doc-m { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 4px; font-size: 12px; color: var(--muted); }

/* 分类 chip */
.lg-chip { font-size: 12.5px; color: var(--text-2); background: #f1f3f7; border-radius: 999px;
  padding: 4px 12px; transition: .15s; }
.lg-chip:hover { background: #e7eaf0; }
.lg-chip.on { background: var(--primary); color: #fff; }

/* 纠纷案件 */
.lg-cases { display: flex; flex-direction: column; }
.lg-case { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 16px; border-bottom: 1px solid var(--border); text-align: left; width: 100%; }
.lg-case:last-child { border-bottom: 0; }
.lg-case:hover { background: #fafbfd; }
.lg-case-l { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.lg-case-l b { font-size: 13.5px; font-weight: 500; }
.lg-case-l span { font-size: 12px; color: var(--muted); }
.lg-case-r { display: flex; align-items: center; gap: 6px; flex: none; flex-wrap: wrap; justify-content: flex-end; }
.lg-case-r > b { font-size: 13px; }

/* 智能问答 */
.lg-qa-in { display: flex; gap: 8px; padding: 14px 16px 0; align-items: flex-start; }
.lg-qa-in textarea.input { flex: 1; min-height: 68px; resize: vertical; }
.lg-qa-in .btn { flex: none; height: 34px; }
.lg-ans { padding: 14px 16px; }
.lg-ans-t { font-size: 13px; line-height: 1.8; color: var(--text); }
.lg-cites { margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--border);
  display: flex; flex-direction: column; gap: 3px; font-size: 12px; color: var(--text-2); }
.lg-cites > b { font-size: 12px; color: var(--muted); font-weight: 500; margin-bottom: 2px; }

/* 法规检索结果 */
.lg-lawres { padding: 12px 16px; display: flex; flex-direction: column; gap: 8px; }
.lg-law { padding: 10px 12px; background: #f8fafc; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.lg-law > b { font-size: 13px; font-weight: 500; }
.lg-law > p { margin-top: 5px; font-size: 12.5px; color: var(--text-2); line-height: 1.7; }

/* 知识库 */
.lg-kbs { display: flex; flex-direction: column; }
.lg-kb { padding: 12px 16px; border-bottom: 1px solid var(--border); cursor: pointer; }
.lg-kb:last-child { border-bottom: 0; }
.lg-kb:hover { background: #fafbfd; }
.lg-kb-h { display: flex; align-items: center; gap: 8px; }
.lg-kb-h > b { font-size: 13.5px; font-weight: 500; flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-kb > p { margin-top: 4px; font-size: 12.5px; color: var(--muted); line-height: 1.65; }

/* 两列表单（宽弹窗用） */
.lg-form2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 14px; }
.lg-form2 .field { min-width: 0; }

/* 文书正文：像稿纸一样读 */
.lg-docbody { font-size: 13.5px; line-height: 2; color: var(--text); white-space: pre-wrap;
  padding: 16px 18px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm);
  /* 稿纸要撑起来，否则短文书下面一大片空白，看不出这是「一张纸」 */
  min-height: 52vh; outline: none; }
.lg-docbody:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.lg-docbody.ro { background: #fbfcfd; }

/* 案件进展时间轴 */
.lg-timeline { display: flex; flex-direction: column; gap: 2px; }
.lg-tl { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 12px; padding: 8px 0;
  border-bottom: 1px solid var(--border); }
.lg-tl:last-child { border-bottom: 0; }
.lg-tl > em { font-style: normal; font-size: 12px; color: var(--muted); padding-top: 1px; }
.lg-tl > div { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.lg-tl b { font-size: 13px; font-weight: 500; }
.lg-tl span { font-size: 12.5px; color: var(--text-2); line-height: 1.65; white-space: pre-wrap; }
.lg-tl i { font-style: normal; }

/* AI 拆解等清单项 */
.lg-li { position: relative; padding: 6px 0 6px 16px; font-size: 12.5px; line-height: 1.7; color: var(--text-2); }
.lg-li::before { content: ; position: absolute; left: 2px; top: 13px; width: 5px; height: 5px;
  border-radius: 50%; background: var(--border-strong); }
.lg-li.warn::before { background: var(--danger); }

/* 一致性校验 */
.lg-cons { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px 12px; margin-bottom: 8px; }
.lg-cons.bad { border-color: #f6d5d7; background: #fffafa; }
.lg-cons-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.lg-cons-h > b { font-size: 13px; font-weight: 500; }
.lg-cons-b { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 12.5px; color: var(--text-2); }

/* OCR / 检索服务状态卡 */
.lg-ocr { padding: 13px 14px; background: #f8fafc; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.lg-ocr-h { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.lg-ocr-h > b { font-size: 13px; font-weight: 500; }
.lg-ocr .lg-filters { border-bottom: 0; padding: 10px 0 0; }
.lg-ocr .lg-filters .input { min-width: 110px; }

/* 窄屏：台账退化为两行字段堆叠（1280 以下逐步收窄） */
@media (max-width: 1400px) {
  .lg-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1180px) {
  .lg-grid2 { grid-template-columns: minmax(0, 1fr); }
  .lg-tr { grid-template-columns: minmax(180px, 2fr) minmax(110px, 1.2fr) 88px 100px 84px 62px; }
  .lg-tr > span:nth-child(3), .lg-tr > span:nth-child(7) { display: none; }
}
@media (max-width: 900px) {
  .lg-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lg-form2 { grid-template-columns: minmax(0, 1fr); }
  .lg-kv { grid-template-columns: minmax(0, 1fr); }
}

/* ============================================================
 * 财务工作台（2026-11-14）
 * 顶部模式分页把「通用财务」和「代账财税」分成两套工作区，
 * 共用底座（应收/回款/开票/提成）只在通用分页出现，代账分页专注服务台账与到期。
 * ============================================================ */

/* 模式切换：财务每天进来第一件事是选「今天处理哪摊事」，所以做成大块而不是小页签 */
.fw-modes { display: flex; gap: 10px; margin-bottom: 14px; }
.fw-mode {
  flex: 1; display: flex; align-items: center; gap: 12px; padding: 13px 16px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  cursor: pointer; transition: .15s; text-align: left; min-width: 0;
}
.fw-mode:hover { border-color: var(--border-strong); }
.fw-mode.on { border-color: var(--primary); background: var(--primary-soft); box-shadow: 0 0 0 1px var(--primary) inset; }
.fw-mode .ic {
  width: 38px; height: 38px; border-radius: 9px; display: grid; place-items: center; flex: none;
  background: #eef2f7; color: var(--text-2); font-size: 17px;
}
.fw-mode.on .ic { background: var(--primary); color: #fff; }
.fw-mode .tx { min-width: 0; }
.fw-mode .tx b { display: block; font-size: 14px; color: var(--text); margin-bottom: 2px; }
.fw-mode .tx span { font-size: 12px; color: var(--muted); }
.fw-mode .cnt {
  margin-left: auto; flex: none; font-size: 12px; color: var(--text-2);
  background: #fff; border: 1px solid var(--border); border-radius: 20px; padding: 2px 10px;
}

/* KPI 六格 */
.fw-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.fw-kpi {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px 14px 12px; min-width: 0; position: relative; overflow: hidden;
}
.fw-kpi .lb { font-size: 12.5px; color: var(--muted); margin-bottom: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fw-kpi .vl { font-size: 22px; font-weight: 600; color: var(--text); line-height: 1.15; letter-spacing: -.3px; }
.fw-kpi .vl small { font-size: 13px; font-weight: 400; color: var(--muted); margin-left: 2px; }
.fw-kpi .sub { font-size: 11.5px; color: var(--muted); margin-top: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fw-kpi.danger { border-color: #fbd5d5; background: linear-gradient(180deg, #fff, #fffafa); }
.fw-kpi.danger .vl { color: var(--danger); }
.fw-kpi.amber { border-color: #f7e3c3; background: linear-gradient(180deg, #fff, #fffdf8); }
.fw-kpi.amber .vl { color: var(--warn); }
.fw-kpi.ok .vl { color: var(--success); }

/* 两/三列栅格 */
.fw-grid2 { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 14px; }
.fw-grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.fw-card { padding: 0; overflow: hidden; }
.fw-card > h4 {
  font-size: 13.5px; font-weight: 600; color: var(--text); margin: 0;
  padding: 13px 16px 11px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 8px;
}
.fw-card > h4 .sp { flex: 1; }
.fw-card > h4 .tiny { font-weight: 400; }
.fw-card-b { padding: 14px 16px; }
.fw-card-b.tight { padding: 0; }

/* 列表行：用 grid 固定列宽，避免表格被长客户名挤变形 */
.fw-tr {
  display: grid; align-items: center; gap: 10px; padding: 11px 16px;
  border-bottom: 1px solid #f0f1f4; font-size: 13px; cursor: pointer; transition: background .12s;
}
.fw-tr:hover { background: #fafbfc; }
.fw-tr:last-child { border-bottom: 0; }
.fw-tr.head {
  font-size: 12px; color: var(--muted); background: #fafbfc; cursor: default; font-weight: 500;
  border-bottom: 1px solid var(--border); padding: 9px 16px;
}
.fw-tr.head:hover { background: #fafbfc; }
.fw-tr .nm { font-weight: 500; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fw-tr .sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fw-tr .amt { text-align: right; font-variant-numeric: tabular-nums; font-weight: 500; }
.fw-tr .amt.muted { color: var(--muted); font-weight: 400; }
.fw-tr .amt.red { color: var(--danger); }
.fw-tr .amt.green { color: var(--success); }
.fw-tr .rt { text-align: right; }
.fw-tr .sp { flex: 1; }
.fw-tr .op { display: flex; gap: 6px; justify-content: flex-end; }

/* 左侧预警色带 */
.fw-warn { box-shadow: inset 3px 0 0 transparent; }
.fw-warn.red { box-shadow: inset 3px 0 0 #dc2626; }
.fw-warn.amber { box-shadow: inset 3px 0 0 #d97706; }
.fw-warn.green { box-shadow: inset 3px 0 0 #16a34a; }
.fw-warn.purple { box-shadow: inset 3px 0 0 #7c3aed; }
.fw-warn.gray { box-shadow: inset 3px 0 0 #cbd5e1; }

/* 汇总条：列表底部的合计，跟行同一套列宽 */
.fw-sum {
  display: grid; align-items: center; gap: 10px; padding: 11px 16px;
  background: #f8fafc; border-top: 1px solid var(--border); font-size: 12.5px; font-weight: 600;
}
.fw-sum .amt { text-align: right; font-variant-numeric: tabular-nums; }

/* 筛选条 */
.fw-filter {
  display: flex; gap: 8px; flex-wrap: wrap; align-items: center;
  padding: 12px 16px; border-bottom: 1px solid var(--border); background: #fff;
}
.fw-filter .inp, .fw-filter select { height: 32px; font-size: 13px; }
.fw-filter .grow { flex: 1; min-width: 120px; }
.fw-filter .sp { flex: 1; }

/* 标签小件 */
.fw-tag {
  display: inline-flex; align-items: center; gap: 4px; height: 21px; padding: 0 8px;
  border-radius: 5px; font-size: 11.5px; white-space: nowrap;
  background: #f1f3f6; color: var(--text-2);
}
/* 统计标签行：一组 miniStat 横排，放不下自动换行，绝不互相挤压重叠
   （曾误用 .row，其子元素 flex:1;min-width:0 会把 nowrap 标签压到叠在一起） */
.fw-statline {
  display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-bottom: 10px;
}
.fw-statline .fw-tag { flex: 0 0 auto; }
.fw-tag.red { background: var(--danger-soft); color: var(--danger); }
.fw-tag.amber { background: var(--warn-soft); color: var(--warn); }
.fw-tag.green { background: var(--success-soft); color: var(--success); }
.fw-tag.blue { background: var(--primary-soft); color: var(--primary); }
.fw-tag.purple { background: #f3edff; color: #7c3aed; }
.fw-tag.gray { background: #f1f3f6; color: var(--muted); }

/* 账龄条 */
.fw-aging { display: flex; flex-direction: column; gap: 9px; }
.fw-aging-i { display: grid; grid-template-columns: 82px minmax(0, 1fr) 88px 54px; gap: 10px; align-items: center; font-size: 12.5px; }
.fw-aging-i .bar { height: 8px; background: #eef0f4; border-radius: 5px; overflow: hidden; }
.fw-aging-i .bar i { display: block; height: 100%; border-radius: 5px; background: var(--primary); }
.fw-aging-i .bar i.red { background: #dc2626; }
.fw-aging-i .bar i.amber { background: #d97706; }
.fw-aging-i .bar i.green { background: #16a34a; }
.fw-aging-i .num { text-align: right; font-variant-numeric: tabular-nums; color: var(--text); }
.fw-aging-i .cnt { text-align: right; color: var(--muted); font-size: 11.5px; }

/* 趋势迷你图：纯 CSS 柱状，不引第三方图表库 */
.fw-trend { display: flex; align-items: flex-end; gap: 10px; height: 120px; padding: 6px 2px 0; }
.fw-trend .col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 5px; height: 100%; }
.fw-trend .col .bars { display: flex; gap: 3px; align-items: flex-end; height: 100%; width: 100%; justify-content: center; }
.fw-trend .col .bars i { width: 9px; border-radius: 3px 3px 0 0; background: var(--primary); min-height: 2px; }
.fw-trend .col .bars i.pay { background: #16a34a; }
.fw-trend .col .mm { font-size: 10.5px; color: var(--muted); white-space: nowrap; }
.fw-legend { display: flex; gap: 14px; font-size: 11.5px; color: var(--muted); margin-top: 8px; }
.fw-legend i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 4px; }

/* 表单两列 */
.fw-form2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 14px; }
.fw-form2 .full { grid-column: 1 / -1; }
.fw-f { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.fw-f > label { font-size: 12px; color: var(--text-2); }
.fw-f > label em { color: var(--danger); font-style: normal; margin-left: 2px; }
.fw-f .inp, .fw-f select, .fw-f textarea { font-size: 13px; }
.fw-f textarea { min-height: 64px; resize: vertical; }
.fw-f .hint { font-size: 11.5px; color: var(--muted); }

/* AI 结论卡 */
.fw-ai { border: 1px solid #dfe7ff; background: linear-gradient(180deg, #fbfcff, #fff); border-radius: var(--radius); padding: 14px 16px; }
.fw-ai-h { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.fw-ai-h b { font-size: 13.5px; }
.fw-ai-h .sp { flex: 1; }
.fw-ai-note { font-size: 11.5px; color: var(--muted); margin-top: 10px; padding-top: 9px; border-top: 1px dashed #dbe3f5; line-height: 1.6; }
.fw-ai-f { padding: 10px 0; border-bottom: 1px dashed #e8edf8; }
.fw-ai-f:last-child { border-bottom: 0; }
.fw-ai-f .t { font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.fw-ai-f .d { font-size: 12.5px; color: var(--text-2); line-height: 1.7; }
.fw-ai-f .a { font-size: 12.5px; color: var(--primary); line-height: 1.7; margin-top: 4px; }
.fw-ai-pre { white-space: pre-wrap; font-size: 13px; line-height: 1.85; color: var(--text); }
.fw-ai-lv { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.fw-ai-lv.high { background: #dc2626; }
.fw-ai-lv.mid { background: #d97706; }
.fw-ai-lv.low { background: #16a34a; }

/* 回款匹配候选 */
.fw-cand { display: grid; grid-template-columns: minmax(0, 1fr) 96px 110px; gap: 10px; align-items: center;
  padding: 11px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 8px; }
.fw-cand.hi { border-color: #bfe3c9; background: #f8fdf9; }
.fw-cand .why { font-size: 11.5px; color: var(--muted); margin-top: 3px; }

/* 设置抽屉里的分节 */
.fw-sec { padding: 2px 0 16px; }
.fw-sec + .fw-sec { border-top: 1px solid var(--border); padding-top: 16px; }
.fw-sec > h5 { font-size: 13px; margin: 0 0 10px; color: var(--text); }
.fw-sec .desc { font-size: 12px; color: var(--muted); line-height: 1.7; margin-bottom: 10px; }

/* 套餐卡片 */
.fw-pkg { border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; background: #fff; }
.fw-pkg.off { opacity: .62; }
.fw-pkg .h { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 8px; }
.fw-pkg .h b { font-size: 14px; }
.fw-pkg .price { font-size: 19px; font-weight: 600; color: var(--primary); margin: 6px 0 2px; }
.fw-pkg .price small { font-size: 12px; color: var(--muted); font-weight: 400; }
.fw-pkg .items { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }

/* 外部系统对接（设置页，预留接口，未接入时如实标注） */
.fw-erp-i { border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; margin-bottom: 8px; background: #fafbfc; }
.fw-erp-i:last-child { margin-bottom: 0; }
.fw-erp-i .h { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.fw-erp-i .h b { font-size: 13px; }
.fw-erp-i .ln { font-size: 12px; color: var(--muted); line-height: 1.7; }

/* 第三方财务软件对接页 */
.fw-erp-intro { border: 1px solid var(--border); border-radius: 10px; padding: 12px 16px; margin-bottom: 14px; background: #fafbfc; display: flex; flex-direction: column; gap: 4px; }
.fw-erp-intro b { font-size: 14px; }
.fw-erp-intro span { font-size: 12.5px; line-height: 1.7; }
.fw-erp-prov { border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; background: #fff; }
.fw-erp-prov.on { border-color: var(--primary); background: linear-gradient(180deg, #fff, #fbfdff); }
.fw-erp-prov .h { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; flex-wrap: wrap; }
.fw-erp-prov .h b { font-size: 14px; }
.fw-erp-prov .sc { font-size: 12.5px; color: var(--text); margin-bottom: 6px; }
.fw-erp-prov .ln { font-size: 12px; color: var(--muted); line-height: 1.7; }
.fw-erp-prov .row { display: flex; align-items: center; }

/* 表单分组分隔（代登账号区块标题） */
.fw-sep { grid-column: 1 / -1; margin: 4px 0 -2px; padding-top: 10px; border-top: 1px dashed var(--border); }
.fw-sep span { font-size: 12.5px; font-weight: 600; color: var(--text-2); }

/* 空状态 */
.fw-empty { padding: 34px 16px; text-align: center; color: var(--muted); font-size: 13px; }
.fw-empty .big { font-size: 26px; opacity: .5; margin-bottom: 8px; }

/* 审批步骤 */
.fw-steps { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.fw-step { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.fw-step .dot { width: 18px; height: 18px; border-radius: 50%; background: #eef0f4; display: grid; place-items: center; font-size: 10.5px; color: var(--text-2); }
.fw-step.on .dot { background: var(--primary); color: #fff; }
.fw-step.done .dot { background: var(--success); color: #fff; }
.fw-step .ar { color: #cbd5e1; }

@media (max-width: 1440px) {
  .fw-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1180px) {
  .fw-grid2, .fw-grid3 { grid-template-columns: minmax(0, 1fr); }
  .fw-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .fw-modes { flex-direction: column; }
  .fw-form2 { grid-template-columns: minmax(0, 1fr); }
  .fw-tr { grid-template-columns: minmax(0, 1fr) 90px !important; }
  .fw-tr > *:nth-child(n+3) { display: none; }
}

/* 财务工作台用到的两个通用小件：间距工具类 + 两列键值表（抽屉里高频） */
.row.gap6 { gap: 6px; }
.row.gap8 { gap: 8px; }
.kv2 { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 7px 10px; font-size: 12.5px; align-items: baseline; }
.kv2 > span { color: var(--muted); }
.kv2 > b { font-weight: 500; color: var(--text); word-break: break-all; }

/* ==================================================================
   AI 王牌专家（四个专家：广场 / 工作台 / 报告）—— 前缀 xp-
   与「导出面板」的 .ex-* 区分开，避免样式互相污染
   ================================================================== */
/* 十位专家：宽屏 5×2 排得整齐，中屏 3 列，窄屏 2 列（原来固定 4 列，10 张卡会排成 4+4+2 的豁口） */
.xp-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
/* 1440 笔记本（内容区约 1160px）就是 5×2 正好排满，10 张卡不出现 4+4+2 的豁口 */
@media (max-width: 1352px) { .xp-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 1240px) { .xp-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 980px) { .xp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.xp-card { --ac: #2563eb; display: flex; flex-direction: column; position: relative; overflow: hidden; color: inherit;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 15px 16px 13px;
  box-shadow: var(--shadow); transition: transform .16s, box-shadow .16s, border-color .16s; }
.xp-card::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--ac); }
.xp-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(16,24,40,.09); border-color: var(--ac); }
.xp-card-ico { width: 34px; height: 34px; border-radius: 9px; background: #f4f6fb;
  display: flex; align-items: center; justify-content: center; font-size: 17px; line-height: 1; }
.xp-card-h { display: flex; align-items: flex-start; gap: 8px; margin-top: 10px; }
.xp-card-h b { flex: 1; min-width: 0; font-size: 14px; font-weight: 600; line-height: 1.4; letter-spacing: -.1px; }
.xp-card-c { margin-left: auto; font-size: 11px; color: var(--muted); background: #f1f3f7; border-radius: 20px; padding: 1px 8px; white-space: nowrap; }
.xp-card-d { font-size: 12px; color: var(--muted); line-height: 1.6; margin-top: 6px; min-height: 38px; }
.xp-card-f { margin-top: auto; padding-top: 10px; font-size: 12px; font-weight: 500; color: var(--ac); display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.xp-card-f > span { flex: 1; min-width: 0; }
.xp-share-btn { flex: none; }

/* 专家获客区块 */
.xp-lead-stats { display: flex; gap: 20px; padding: 4px 0 12px; flex-wrap: wrap; }
.xp-lead-stats span { font-size: 13px; color: var(--muted); }
.xp-lead-stats b { color: var(--text); font-size: 16px; margin: 0 2px; }

/* 获客数据看板 */
.xa-summary { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 4px; }
.xa-sum-item { flex: 1; min-width: 120px; background: #f7f9fc; border-radius: 8px; padding: 16px; text-align: center; }
.xa-sum-item b { display: block; font-size: 24px; color: var(--text); }
.xa-sum-item span { font-size: 12px; color: var(--muted); }
.xa-sec { margin: 20px 0 8px; }
.xa-sec h4 { font-size: 13px; font-weight: 600; color: var(--text); margin: 0; }
.xa-funnel { display: flex; flex-direction: column; gap: 8px; }
.xa-funnel-row { display: flex; align-items: center; gap: 12px; }
.xa-funnel-label { width: 76px; font-size: 12px; color: var(--text); flex: none; }
.xa-funnel-bar { flex: 1; height: 20px; background: #eef2f7; border-radius: 4px; overflow: hidden; }
.xa-funnel-fill { height: 100%; background: linear-gradient(90deg, #2563eb, #4f8cff); border-radius: 4px; }
.xa-funnel-num { width: 90px; font-size: 13px; flex: none; }
.xa-funnel-num i { font-size: 11px; margin-left: 6px; font-style: normal; }
.xa-filters { display: flex; gap: 8px; }
.xa-filters select { padding: 4px 8px; font-size: 12px; border: 1px solid var(--line); border-radius: 6px; background: #fff; color: var(--text); }
.xa-pager { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 12px 0 4px; }
.xa-ev { display: inline-block; font-size: 11px; padding: 1px 7px; border-radius: 5px; white-space: nowrap; }
.xa-ev-open { color: #475569; background: #eef2f7; }
.xa-ev-submit { color: #16a34a; background: #e8f7ee; }
.xa-ev-unlock { color: #7c3aed; background: #f3eefe; }
.xa-ev-report { color: #2563eb; background: #eef4ff; }
.xa-ev-apply { color: #d97706; background: #fdf3e3; }
.xa-ev-export { color: #dc2626; background: #fdeaea; }

.xp-row { cursor: pointer; }
.xp-row:hover td { background: #fafbfe; }
.xp-row td.mono { white-space: nowrap; }
.xp-cus { display: block; max-width: 168px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.xp-tag { display: inline-block; font-size: 11px; color: #2563eb; background: #eef4ff; border-radius: 5px; padding: 1px 7px; white-space: nowrap; }
.xp-ai { font-style: normal; font-size: 10px; font-weight: 700; color: #7c3aed; background: #f3eefe; border-radius: 4px; padding: 1px 4px; margin-left: 4px; }
.xp-sum { font-size: 11.5px; color: var(--muted); margin-top: 2px; line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }

/* 工作台：左表单 / 右报告 */
.xp-desk { display: grid; grid-template-columns: 400px minmax(0, 1fr); gap: 14px; align-items: start; }
@media (max-width: 1320px) { .xp-desk { grid-template-columns: 356px minmax(0, 1fr); } }
@media (max-width: 1080px) { .xp-desk { grid-template-columns: minmax(0, 1fr); } }
.xp-form { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.xp-fg { padding: 12px 14px 14px; border-bottom: 1px solid #f1f4f8; }
.xp-fg:last-of-type { border-bottom: none; }
.xp-fg-h { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; font-size: 13px; font-weight: 600; margin-bottom: 10px; }
.xp-fg-h span { font-size: 11.5px; font-weight: 400; color: var(--muted); }
.xp-fgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.xp-fi { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.xp-fi > span { font-size: 12px; color: var(--text-2); }
.xp-fi.wide { grid-column: 1 / -1; }
.xp-fi input, .xp-fi select, .xp-fi textarea { width: 100%; min-width: 0; font-family: inherit; font-size: 12.8px;
  color: var(--text); background: #fff; border: 1px solid var(--border-strong); border-radius: 7px; padding: 7px 9px;
  transition: border-color .15s, box-shadow .15s; }
.xp-fi textarea { resize: vertical; line-height: 1.6; }
.xp-fi input:focus, .xp-fi select:focus, .xp-fi textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.xp-import { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-top: 11px; }
.xp-hint { font-size: 11.5px; color: var(--muted); line-height: 1.6; }

/* 多选下拉（所属行业 / 发展阶段 / 业务类型 / 资金情况 / 商业模式） */
.xp-ms-tip { margin-left: 6px; font-style: normal; font-size: 10.5px; color: var(--muted);
  background: #f1f4f9; border-radius: 20px; padding: 1px 7px; }
.xp-ms { position: relative; min-width: 0; }
.xp-ms-btn { display: flex; align-items: center; gap: 6px; width: 100%; min-width: 0; text-align: left;
  font-family: inherit; font-size: 12.8px; color: var(--text); background: #fff; cursor: pointer;
  border: 1px solid var(--border-strong); border-radius: 7px; padding: 7px 9px;
  transition: border-color .15s, box-shadow .15s; }
.xp-ms-btn:hover { border-color: #c3d3f0; }
.xp-ms-btn em { flex: 1; min-width: 0; font-style: normal; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.xp-ms-btn em.ph { color: #9aa4b2; }
.xp-ms-btn i { flex: none; font-style: normal; font-size: 10px; color: var(--muted); }
.xp-ms.open .xp-ms-btn { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.xp-ms-pop { position: fixed; z-index: 900; background: #fff; border: 1px solid var(--border);
  border-radius: 9px; box-shadow: 0 14px 34px rgba(15,23,42,.16); padding: 5px;
  max-height: 300px; overflow: auto; }
.xp-ms-cl { position: sticky; top: -5px; background: #fff; padding: 3px 8px 6px; font-size: 11px;
  color: var(--muted); border-bottom: 1px solid #f1f4f8; }
.xp-ms-i { display: flex; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 6px;
  font-size: 12.6px; cursor: pointer; }
.xp-ms-i:hover { background: #f4f7fc; }
.xp-ms-i.on { background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.xp-ms-i input { width: 13px; height: 13px; margin: 0; accent-color: var(--primary); }

.xp-chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(152px, 1fr)); gap: 8px; }
.xp-chip { position: relative; display: flex; flex-direction: column; gap: 2px; cursor: pointer;
  background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; transition: .15s; }
.xp-chip input { position: absolute; opacity: 0; pointer-events: none; }
.xp-chip b { font-size: 12.5px; font-weight: 600; }
.xp-chip span { font-size: 11px; color: var(--muted); line-height: 1.5; }
.xp-chip:hover { border-color: #c3d3f0; }
.xp-chip.on { border-color: var(--primary); background: var(--primary-soft); box-shadow: inset 0 0 0 1px var(--primary); }
.xp-chip.on b { color: var(--primary); }
.xp-chips.sm { display: flex; flex-wrap: wrap; gap: 6px; }
.xp-chip.sm { flex-direction: row; padding: 4px 10px; }
.xp-chip.sm b { font-size: 12px; font-weight: 400; }

.xp-files { display: flex; flex-wrap: wrap; gap: 6px; }
.xp-file { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; font-size: 12px;
  background: #f2f5fa; border: 1px solid var(--border); border-radius: 6px; padding: 4px 6px 4px 9px; }
.xp-file.bad { background: var(--danger-soft); border-color: #f5c2c4; }
.xp-file-x { border: none; background: transparent; cursor: pointer; color: var(--muted); font-size: 14px; line-height: 1; padding: 0 2px; }
.xp-file-x:hover { color: var(--danger); }
.xp-submit { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px;
  background: #fafbfd; border-top: 1px solid var(--border); }

/* 后台生成进度条：报告要 30~90 秒，切页回来要能看见它还在跑。
   .xp-out 有 420px 最小高，进度条从上往下排会在下面留一大片空白，
   所以这里让它垂直居中，视觉上是一块「正在生成」的状态卡而不是一条贴在顶上的线。 */
.xp-jobbar { padding: 22px 20px; min-height: 420px; display: flex; flex-direction: column; justify-content: center; }
.xp-jobbar-t { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: #0f172a; margin-bottom: 10px; }
.xp-jobbar-t b { margin-left: auto; font-size: 13px; color: #2563eb; font-weight: 600; }
.xp-jobbar-spin { width: 13px; height: 13px; border: 2px solid #bfdbfe; border-top-color: #2563eb;
  border-radius: 50%; animation: xpjobspin .8s linear infinite; flex: none; }
.xp-jobbar-bar { height: 6px; border-radius: 6px; background: #eef2f7; overflow: hidden; }
.xp-jobbar-bar i { display: block; height: 100%; border-radius: 6px; background: #2563eb; transition: width .4s; }
@keyframes xpjobspin { to { transform: rotate(360deg); } }

.xp-out { background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); min-height: 420px; overflow: hidden; }
/* 工作台表单很长（品牌 26 项）：报告跟着滚，滚到哪都能看见 */
.xp-desk .xp-out { position: sticky; top: 10px; }
@media (max-width: 1080px) { .xp-desk .xp-out { position: static; } }
.xp-rep-h { display: flex; align-items: flex-start; gap: 14px; flex-wrap: wrap; padding: 14px 16px 10px; border-bottom: 1px solid #f1f4f8; }
.xp-rep-t { font-size: 15.5px; font-weight: 600; line-height: 1.4; letter-spacing: -.2px; }
.xp-rep-m { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 11.5px; color: var(--muted); margin-top: 5px; }
.xp-rep-a { margin-left: auto; display: flex; gap: 6px; flex-wrap: wrap; }
.xp-rep-s { padding: 11px 16px; background: #fafbfd; border-bottom: 1px solid #f1f4f8;
  font-size: 12.5px; color: var(--text-2); line-height: 1.75; }
.xp-rep-body { display: grid; grid-template-columns: 172px minmax(0, 1fr); }
@media (max-width: 1080px) {
  .xp-rep-body { grid-template-columns: minmax(0, 1fr); }
  .xp-nav { flex-direction: row !important; overflow-x: auto; border-right: none !important; border-bottom: 1px solid #f1f4f8; }
  .xp-nav-i { white-space: nowrap; }
  .xp-content { max-height: none !important; }
}
.xp-nav { display: flex; flex-direction: column; gap: 1px; padding: 10px 8px;
  background: #fcfdfe; border-right: 1px solid #f1f4f8; }
.xp-nav-i { display: flex; align-items: flex-start; gap: 7px; width: 100%; text-align: left; cursor: pointer;
  border: none; background: transparent; border-radius: 6px; padding: 6px 8px;
  font-family: inherit; font-size: 12.5px; line-height: 1.45; color: var(--text-2); }
.xp-nav-i b { flex: none; width: 15px; text-align: right; font-size: 11px; font-weight: 500; color: var(--muted); }
.xp-nav-i:hover { background: #f2f5fa; color: var(--primary); }
.xp-nav-i.on { background: var(--primary-soft); color: var(--primary); font-weight: 500; }
.xp-nav-i.on b { color: var(--primary); }
/* 移动端导航横排：导航项按内容宽度排列，超出部分由 .xp-nav 横向滚动，不能撑满导致溢出 */
@media (max-width: 1080px) {
  .xp-nav-i { width: auto !important; flex: none; }
  .xp-nav-i b { width: auto; margin-right: 2px; }
}
.xp-content { padding: 14px 16px 18px; min-width: 0; max-height: calc(100vh - 232px); overflow-y: auto; }
.xp-dis { padding: 10px 16px 13px; border-top: 1px solid #f1f4f8; background: #fcfdfe;
  font-size: 11px; color: var(--muted); line-height: 1.7; }

/* 报告内容块 */
.xp-p { font-size: 13px; line-height: 1.85; color: var(--text-2); margin: 0 0 10px; }
.xp-lbl { font-size: 12px; font-weight: 600; color: var(--text); margin: 12px 0 6px;
  padding-left: 8px; border-left: 3px solid var(--primary); line-height: 1.4; }
.xp-ul, .xp-ol { margin: 0 0 10px; padding-left: 20px; font-size: 12.8px; line-height: 1.8; color: var(--text-2); }
.xp-ul li, .xp-ol li { margin: 2px 0; }
.xp-ul.sm { font-size: 12px; line-height: 1.7; margin: 6px 0 0; }
.xp-kv { width: 100%; border-collapse: collapse; margin: 0 0 12px; font-size: 12.5px; }
.xp-kv th { width: 134px; text-align: left; font-weight: 500; color: var(--muted);
  padding: 6px 10px 6px 0; vertical-align: top; border-bottom: 1px solid #f4f6f9; }
.xp-kv td { padding: 6px 0; border-bottom: 1px solid #f4f6f9; color: var(--text-2); line-height: 1.7; }
.xp-tbwrap { margin: 0 0 12px; border: 1px solid var(--border); border-radius: 8px; overflow-x: auto; }
.xp-tb { width: 100%; border-collapse: collapse; font-size: 12.3px; }
.xp-tb th { background: #f7f9fc; text-align: left; font-weight: 600; color: var(--text);
  padding: 7px 10px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.xp-tb td { padding: 7px 10px; border-bottom: 1px solid #f4f6f9; color: var(--text-2); line-height: 1.65; vertical-align: top; }
.xp-tb tr:last-child td { border-bottom: none; }
.xp-tb td.num { color: var(--muted); font-variant-numeric: tabular-nums; }
.xp-q { margin: 0 0 12px; padding: 9px 12px; background: #fafbfd; border-left: 3px solid #cbd5e1;
  border-radius: 0 6px 6px 0; font-size: 12.6px; color: var(--text-2); line-height: 1.8; }
.xp-chipsline { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin: 0 0 12px; font-size: 11.5px; color: var(--muted); }
.xp-chipsline i { font-style: normal; font-size: 11.5px; color: var(--text-2); background: #f1f4f9; border-radius: 20px; padding: 2px 9px; }
.xp-co { border: 1px solid; border-radius: 8px; padding: 10px 12px; margin: 0 0 12px; }
.xp-co-h { font-size: 12.6px; font-weight: 600; margin-bottom: 3px; }
.xp-co-b { font-size: 12.4px; color: var(--text-2); line-height: 1.8; }
.xp-co.info { background: #f0f6ff; border-color: #d6e4ff; }
.xp-co.info .xp-co-h { color: #1d4ed8; }
.xp-co.ok { background: var(--success-soft); border-color: #c7ebd4; }
.xp-co.ok .xp-co-h { color: #157f3b; }
.xp-co.warn { background: var(--warn-soft); border-color: #f2ddb5; }
.xp-co.warn .xp-co-h { color: #a4620a; }
.xp-co.danger { background: var(--danger-soft); border-color: #f6cdd0; }
.xp-co.danger .xp-co-h { color: #b91c1c; }
.xp-stat { display: grid; grid-template-columns: repeat(auto-fit, minmax(102px, 1fr)); gap: 8px; margin: 0 0 12px; }
.xp-stat > div { background: #f7f9fc; border: 1px solid var(--border); border-radius: 8px; padding: 9px 11px; }
.xp-stat b { display: block; font-size: 16px; font-weight: 600; letter-spacing: -.3px; }
.xp-stat span { display: block; font-size: 11px; color: var(--muted); line-height: 1.5; margin-top: 2px; }
.xp-score { border: 1px solid var(--border); border-radius: 9px; background: #fcfdff; padding: 12px 14px; margin-bottom: 12px; }
.xp-score-h { font-size: 12.5px; color: var(--text-2); margin-bottom: 10px; }
.xp-score-h b { font-size: 19px; font-weight: 600; color: var(--primary); margin: 0 2px; }
.xp-dims { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px 18px; }
@media (max-width: 900px) { .xp-dims { grid-template-columns: minmax(0, 1fr); } }
.xp-dim-t { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--text-2); margin-bottom: 4px; }
.xp-dim-t b { font-weight: 600; font-variant-numeric: tabular-nums; }
.xp-bar { height: 6px; background: #eceff4; border-radius: 3px; overflow: hidden; }
.xp-bar i { display: block; height: 100%; border-radius: 3px; }
.xp-chaps { display: flex; flex-direction: column; gap: 10px; margin-bottom: 10px; }
.xp-chap { border: 1px solid var(--border); border-radius: 9px; background: #fff; padding: 10px 12px; }
.xp-chap-h { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 13px; font-weight: 600; }
.xp-chap-sp { font-size: 10.5px; font-weight: 500; color: #7c3aed; background: #f4f0fe; border-radius: 4px; padding: 1px 6px; }
.xp-chap-s { font-size: 12.3px; color: var(--text-2); line-height: 1.75; margin-top: 5px; }
.xp-script { border: 1px solid #e3ebf7; background: #f7faff; border-radius: 8px; padding: 9px 11px; margin: 0 0 12px; }
.xp-script-h { font-size: 12px; font-weight: 600; color: #1d4ed8; margin-bottom: 6px; }
.xp-script-l { display: flex; gap: 7px; padding: 3px 0; font-size: 12.3px; color: var(--text-2); line-height: 1.75; }
.xp-script-l i { flex: none; height: 17px; line-height: 17px; margin-top: 2px; padding: 0 5px; border-radius: 4px;
  font-style: normal; font-size: 10.5px; font-weight: 600; color: #fff; background: #93a3b8; }
.xp-script-n { font-size: 11.5px; color: var(--muted); line-height: 1.6; margin-top: 6px; }

/* 客户选择抽屉 */
.xp-pk { display: flex; flex-direction: column; gap: 10px; }
.xp-pk input[type="search"] { width: 100%; font-family: inherit; font-size: 13px; padding: 8px 11px;
  border: 1px solid var(--border-strong); border-radius: 8px; }
.xp-pk input[type="search"]:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.xp-pk-list { max-height: 52vh; overflow-y: auto; border: 1px solid var(--border); border-radius: 8px; }
.xp-pk-i { padding: 9px 12px; border-bottom: 1px solid #f4f6f9; cursor: pointer; }
.xp-pk-i:last-child { border-bottom: none; }
.xp-pk-i:hover { background: #f7f9fc; }
.xp-pk-n { font-size: 13px; font-weight: 500; }
.xp-pk-m { font-size: 11.5px; color: var(--muted); margin-top: 2px; line-height: 1.5; }

/* ==================================================================
   企服业务库：列表 kbb- / 详情 kbd-
   ================================================================== */
.kbb-wrap { display: grid; grid-template-columns: 196px minmax(0, 1fr); gap: 14px; align-items: start; }
.kbb-side { display: flex; flex-direction: column; gap: 1px; padding: 7px; position: sticky; top: 10px;
  max-height: calc(100vh - 120px); overflow-y: auto;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.kbb-cat { display: flex; align-items: center; gap: 7px; width: 100%; text-align: left; cursor: pointer;
  border: none; background: transparent; border-radius: 7px; padding: 8px 10px;
  font-family: inherit; font-size: 12.8px; line-height: 1.35; color: var(--text-2); }
.kbb-cat .n { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kbb-cat b { flex: none; font-size: 11px; font-weight: 500; color: var(--muted); background: #f1f3f7; border-radius: 20px; padding: 1px 7px; }
.kbb-cat:hover { background: #f7f9fc; color: var(--primary); }
.kbb-cat.on { background: var(--primary-soft); color: var(--primary); font-weight: 500; }
.kbb-cat.on b { background: #fff; color: var(--primary); }
.kbb-dot { flex: none; width: 5px; height: 5px; border-radius: 50%; background: var(--warn); }
.kbb-main { min-width: 0; }
.kbb-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.kbb-search { flex: 1; display: flex; align-items: center; gap: 7px; height: 34px; padding: 0 11px;
  background: #fff; border: 1px solid var(--border-strong); border-radius: 8px; color: var(--muted); }
.kbb-search input { flex: 1; min-width: 0; height: 100%; border: none; outline: none; background: transparent;
  font-family: inherit; font-size: 13px; color: var(--text); }
.kbb-cnt { flex: none; font-size: 12px; color: var(--muted); white-space: nowrap; }
.kbb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(238px, 1fr)); gap: 11px; }
.kbb-card { display: block; color: inherit; background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius); padding: 12px 13px; box-shadow: var(--shadow); transition: .16s; }
.kbb-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(16,24,40,.08); transform: translateY(-1px); }
.kbb-card-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.kbb-tag { font-size: 10.5px; color: #2563eb; background: #eef4ff; border-radius: 4px; padding: 1px 6px; white-space: nowrap; }
.kbb-sub { font-size: 11px; color: var(--muted); max-width: 104px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kbb-badge { margin-left: auto; font-size: 10px; color: var(--muted); background: #f1f3f7; border-radius: 4px; padding: 1px 5px; }
.kbb-badge.warn { color: #a4620a; background: var(--warn-soft); }
.kbb-name { font-size: 13.5px; font-weight: 600; line-height: 1.45; min-height: 39px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.kbb-meta { display: flex; gap: 5px; font-size: 11.5px; color: var(--muted); margin-top: 6px; white-space: nowrap; overflow: hidden; }
.kbb-meta > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.kbb-meta > span:last-child { flex: 1; }
.kbb-meta .dot { flex: none; opacity: .5; }
.kbb-foot { display: flex; align-items: center; gap: 8px; margin-top: 9px; padding-top: 8px;
  border-top: 1px solid #f4f6f9; font-size: 11px; color: var(--muted); }
.kbb-v { margin-left: auto; font-variant-numeric: tabular-nums; }

/* 详情 */
.kbd-top { background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 14px 16px; margin-bottom: 12px; }
.kbd-back { display: inline-block; font-size: 12px; color: var(--muted); margin-bottom: 7px; }
.kbd-back:hover { color: var(--primary); }
.kbd-top h2 { font-size: 18px; font-weight: 600; letter-spacing: -.2px; line-height: 1.35; }
.kbd-sub { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12px; color: var(--muted); margin-top: 7px; }
.kbd-chip { font-size: 11.5px; color: #2563eb; background: #eef4ff; border-radius: 4px; padding: 1px 7px; }
.kbd-acts { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 12px; padding-top: 11px; border-top: 1px solid #f4f6f9; }
.kbd-draft { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 12px;
  background: var(--warn-soft); border: 1px solid #f2ddb5; border-radius: 9px; padding: 9px 13px;
  font-size: 12.3px; color: #8a5406; line-height: 1.7; }
.kbd-draft b { color: #7c4a05; }
.kbd-tabs { display: flex; gap: 2px; overflow-x: auto; padding: 0 8px;
  background: #fff; border: 1px solid var(--border); border-bottom: none;
  border-radius: var(--radius) var(--radius) 0 0; }
.kbd-tab { display: flex; align-items: center; gap: 5px; white-space: nowrap; cursor: pointer;
  border: none; background: transparent; border-bottom: 2px solid transparent;
  padding: 11px 12px; font-family: inherit; font-size: 13px; color: var(--text-2); }
.kbd-tab:hover { color: var(--primary); }
.kbd-tab.on { color: var(--primary); border-bottom-color: var(--primary); font-weight: 500; }
.kbd-tab b { font-size: 10.5px; font-weight: 500; color: var(--muted); background: #f1f3f7; border-radius: 20px; padding: 0 5px; }
.kbd-tab.on b { color: var(--primary); background: var(--primary-soft); }
.kbd-body { background: #fff; border: 1px solid var(--border); border-top: none;
  border-radius: 0 0 var(--radius) var(--radius); box-shadow: var(--shadow); padding: 14px 16px 6px; }
.kbd-sec { margin-bottom: 18px; }
.kbd-sec-h { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
  font-size: 13.5px; font-weight: 600; margin-bottom: 9px; }
.kbd-sec-s { font-size: 11.5px; font-weight: 400; color: var(--muted); }
.kbd-tb { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.kbd-tb th { background: #f7f9fc; text-align: left; font-weight: 600; color: var(--text);
  padding: 7px 9px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.kbd-tb th.c { text-align: center; }
.kbd-tb td { padding: 7px 9px; border-bottom: 1px solid #f4f6f9; color: var(--text-2); line-height: 1.7; vertical-align: top; }
.kbd-tb tr:last-child td { border-bottom: none; }
.kbd-tb td.num { color: var(--muted); text-align: center; font-variant-numeric: tabular-nums; }
.kbd-note { color: var(--muted); font-size: 12px; }
.kbd-must { font-size: 10.5px; color: #b91c1c; background: var(--danger-soft); border-radius: 4px; padding: 1px 6px; white-space: nowrap; }
.kbd-opt { font-size: 10.5px; color: var(--muted); background: #f1f3f7; border-radius: 4px; padding: 1px 6px; white-space: nowrap; }
.kbd-tip { font-size: 11.5px; color: var(--muted); line-height: 1.75; margin-bottom: 10px;
  background: #fafbfd; border: 1px dashed var(--border-strong); border-radius: 8px; padding: 9px 11px; }

.kbd-flow { display: flex; flex-direction: column; }
.kbd-fs { display: flex; gap: 11px; padding-bottom: 14px; position: relative; }
.kbd-fs::before { content: ''; position: absolute; left: 13px; top: 27px; bottom: 0; width: 1px; background: #e6ebf3; }
.kbd-fs:last-child::before { display: none; }
.kbd-fs-n { flex: none; width: 27px; height: 27px; border-radius: 50%; position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 600; color: var(--primary); background: var(--primary-soft); border: 1px solid #d6e4ff; }
.kbd-fs-main { min-width: 0; padding-top: 3px; }
.kbd-fs-h { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; font-size: 13px; }
.kbd-fs-h b { font-weight: 600; }
.kbd-fs-d { font-size: 11px; color: #0f766e; background: #e8f7f4; border-radius: 4px; padding: 0 6px; }
.kbd-fs-p { font-size: 11px; color: var(--text-2); background: #f1f3f7; border-radius: 4px; padding: 0 6px; }
.kbd-fs-f { font-size: 11px; color: #a4620a; background: var(--warn-soft); border-radius: 4px; padding: 0 6px; }
.kbd-fs-desc { font-size: 12.3px; color: var(--text-2); line-height: 1.7; margin-top: 4px; }
.kbd-fs-c { font-size: 11.5px; color: var(--muted); line-height: 1.6; margin-top: 3px; }

.kbd-kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(148px, 1fr)); gap: 8px; }
.kbd-kv > div { background: #f7f9fc; border: 1px solid var(--border); border-radius: 8px; padding: 9px 11px; }
.kbd-kv span { display: block; font-size: 11px; color: var(--muted); margin-bottom: 2px; }
.kbd-kv b { font-size: 13px; font-weight: 600; line-height: 1.5; }
.kbd-price { font-size: 15px; font-weight: 600; color: var(--text);
  background: var(--primary-soft); border: 1px solid #d6e4ff; border-radius: 8px; padding: 9px 13px; margin-bottom: 10px; }
.kbd-sub-h { font-size: 12px; font-weight: 600; margin: 10px 0 5px; }
.kbd-ul { margin: 0; padding-left: 19px; font-size: 12.5px; line-height: 1.8; color: var(--text-2); }
.kbd-ul li { margin: 2px 0; }
.kbd-ul li.ok::marker { color: var(--success); }
.kbd-ul li.no::marker { color: var(--danger); }
.kbd-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 900px) { .kbd-grid2 { grid-template-columns: minmax(0, 1fr); } }

.kbd-sup { display: flex; flex-direction: column; gap: 9px; }
.kbd-sup-i { border: 1px solid var(--border); border-radius: 9px; background: #fcfdff; padding: 10px 12px; }
.kbd-sup-h { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; font-size: 13px; }
.kbd-sup-h b { font-weight: 600; }
.kbd-sup-h span { font-size: 11px; color: #7c3aed; background: #f4f0fe; border-radius: 4px; padding: 0 6px; }
.kbd-sup-m { display: flex; flex-wrap: wrap; gap: 3px 16px; font-size: 11.8px; color: var(--muted); margin-top: 5px; line-height: 1.6; }
.kbd-sup-n { font-size: 11.8px; color: var(--text-2); line-height: 1.7; margin-top: 5px; }

.kbd-cg { border: 1px solid var(--border); border-radius: 8px; background: #fcfdff; padding: 9px 11px; margin-bottom: 10px; }
.kbd-grid2 .kbd-cg { margin-bottom: 0; }
.kbd-cg-h { font-size: 12.5px; font-weight: 600; margin-bottom: 6px; }
.kbd-cg-h.must { color: #a4620a; }
.kbd-cg-h.no { color: #b91c1c; }
.kbd-check { display: grid; grid-template-columns: repeat(auto-fill, minmax(272px, 1fr)); gap: 2px 12px; }
.kbd-chk { display: flex; align-items: flex-start; gap: 8px; cursor: pointer;
  font-size: 12.5px; line-height: 1.7; color: var(--text-2); padding: 5px 8px; border-radius: 6px; }
.kbd-chk:hover { background: #f7f9fc; }
.kbd-chk input { flex: none; margin-top: 3px; accent-color: var(--primary); }
.kbd-chk input:checked + span { color: var(--muted); text-decoration: line-through; }
.kbd-chk-count { margin-left: auto; font-size: 11px; font-weight: 500; color: var(--muted);
  background: #f1f3f7; border-radius: 20px; padding: 1px 9px; }
.kbd-chk-count.all { color: #157f3b; background: var(--success-soft); }

.kbd-ben { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
@media (max-width: 900px) { .kbd-ben { grid-template-columns: minmax(0, 1fr); } }
.kbd-ben-i { display: flex; gap: 10px; border: 1px solid var(--border); border-radius: 9px; background: #fcfdff; padding: 10px 12px; }
.kbd-ben-n { flex: none; font-size: 15px; font-weight: 700; line-height: 1.15; color: #dbe4f3; font-variant-numeric: tabular-nums; }
.kbd-ben-t { font-size: 12.8px; font-weight: 600; margin-bottom: 3px; }
.kbd-ben-d { font-size: 12px; color: var(--text-2); line-height: 1.7; }

.kbd-faq-g { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.kbd-faq-chip { font-size: 11px; color: var(--text-2); background: #f1f3f7; border-radius: 20px; padding: 2px 10px; }
.kbd-faq-group { margin-bottom: 14px; }
.kbd-faq-gh { font-size: 12.5px; font-weight: 600; line-height: 1.4; margin-bottom: 7px;
  padding-left: 8px; border-left: 3px solid var(--primary); }
.kbd-q { background: #fff; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 7px; overflow: hidden; }
.kbd-q.open { background: #fcfdff; border-color: #d6e4ff; }
.kbd-q-h { display: flex; align-items: center; gap: 8px; padding: 9px 11px; cursor: pointer; font-size: 12.8px; }
.kbd-q-h:hover { background: #f7f9fc; }
.kbd-q-n { flex: none; font-size: 10.5px; font-weight: 700; color: #2563eb; background: #eef4ff; border-radius: 4px; padding: 1px 5px; }
.kbd-q-t { flex: 1; min-width: 0; line-height: 1.55; }
.kbd-q-c { flex: none; font-size: 10.5px; color: var(--muted); }
.kbd-q-ar { flex: none; font-size: 10px; color: var(--muted); transition: transform .15s; }
.kbd-q.open .kbd-q-ar { transform: rotate(180deg); }
.kbd-q-b { padding: 2px 11px 12px; border-top: 1px solid #f4f6f9; }
.kbd-angles { display: grid; grid-template-columns: repeat(auto-fill, minmax(252px, 1fr)); gap: 8px; margin: 10px 0; }
.kbd-angle { background: #fff; border: 1px solid var(--border); border-radius: 7px; padding: 8px 10px; }
.kbd-angle-h { font-size: 11px; font-weight: 600; color: #2563eb; margin-bottom: 4px; }
.kbd-angle-t { font-size: 12.2px; color: var(--text-2); line-height: 1.7; }
.kbd-mind { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; margin-bottom: 9px;
  background: #fdf8ee; border: 1px solid #f2e3c4; border-radius: 7px; padding: 8px 10px;
  font-size: 12.2px; color: var(--text-2); line-height: 1.7; }
.kbd-mind b { flex: none; font-size: 11.5px; color: #a4620a; }
.kbd-mind-tag { font-size: 10.5px; color: #fff; background: #d9a441; border-radius: 3px; padding: 0 5px; }
.kbd-script { background: #f7faff; border: 1px solid #e3ebf7; border-radius: 7px; padding: 8px 10px; }
.kbd-script-h { display: flex; align-items: center; gap: 8px; font-size: 11.5px; font-weight: 600; color: #1d4ed8; margin-bottom: 5px; }
.kbd-script-h .btn { margin-left: auto; }
.kbd-script-t { font-size: 12.3px; color: var(--text-2); line-height: 1.8; white-space: pre-wrap; }

.kbd-sop { display: flex; flex-direction: column; }
.kbd-sop-i { display: flex; gap: 11px; }
.kbd-sop-l { flex: none; width: 26px; display: flex; flex-direction: column; align-items: center; }
.kbd-sop-n { flex: none; width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 600; color: #fff; background: var(--primary); }
.kbd-sop-line { flex: 1; width: 1px; background: #e6ebf3; margin: 4px 0; }
.kbd-sop-i:last-child .kbd-sop-line { display: none; }
.kbd-sop-c { flex: 1; min-width: 0; padding-bottom: 14px; }
.kbd-sop-h { font-size: 13px; font-weight: 600; margin-bottom: 4px; }
.kbd-sop-goal { font-size: 12.2px; color: var(--text-2); line-height: 1.7; margin-bottom: 5px; }
.kbd-sop-act { font-size: 12.2px; color: var(--text-2); line-height: 1.75; margin-bottom: 7px; }
.kbd-sop-act b { font-size: 11px; font-weight: 600; color: var(--muted); background: #f1f3f7; border-radius: 4px; padding: 1px 6px; margin-right: 6px; }
.kbd-sop-m { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 11.5px; color: var(--muted); margin-top: 7px; }

.kbd-risk-t { font-size: 11px; color: #b91c1c; background: var(--danger-soft); border-radius: 4px; padding: 1px 6px; white-space: nowrap; }
.kbd-risk-r { color: #a4620a; }

.kbd-rel { margin-top: 14px; }
.kbd-rel-h { font-size: 12.5px; font-weight: 600; margin-bottom: 8px; }
.kbd-rel-l { display: flex; flex-wrap: wrap; gap: 7px; }
.kbd-rel-l a { font-size: 12px; color: var(--text-2); background: #fff; border: 1px solid var(--border); border-radius: 6px; padding: 4px 10px; }
.kbd-rel-l a:hover { color: var(--primary); border-color: var(--primary); }
.kbd-foot { display: flex; flex-direction: column; gap: 3px; margin-top: 14px; padding-top: 11px;
  border-top: 1px solid var(--border); font-size: 11px; color: var(--muted); line-height: 1.7; }

.kbd-vers { display: flex; flex-direction: column; gap: 8px; }
.kbd-ver-i { display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  border: 1px solid var(--border); border-radius: 8px; padding: 9px 11px; }
.kbd-ver-l { display: flex; align-items: baseline; gap: 8px; min-width: 118px; }
.kbd-ver-l b { font-size: 13px; }
.kbd-ver-l span { font-size: 11px; color: var(--muted); }
.kbd-ver-m { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; gap: 3px 12px; font-size: 11.5px; color: var(--muted); }
@media (max-width: 1080px) { .kbb-wrap { grid-template-columns: minmax(0, 1fr); }
  .kbb-side { position: static; max-height: none; flex-direction: row; overflow-x: auto; } }

/* ---------- AI 知识库 → 企服业务库入口条（PRD 八 前端交互结构） ---------- */
.kb-bizentry { display: flex; align-items: center; gap: 12px; padding: 11px 15px; margin-bottom: 13px;
  border: 1px solid var(--border); border-radius: 11px; text-decoration: none; color: inherit;
  background: linear-gradient(96deg, #f4f7ff, #fff 64%); transition: border-color .18s, box-shadow .18s; }
.kb-bizentry:hover { border-color: #c2cff3; box-shadow: 0 4px 14px rgba(37, 67, 196, .08); }
.kbe-ic { flex: 0 0 32px; width: 32px; height: 32px; border-radius: 9px; display: flex; align-items: center;
  justify-content: center; background: #e7edff; color: #2543c4; }
.kbe-m { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.kbe-m b { font-size: 13px; font-weight: 600; }
.kbe-m i { font-style: normal; font-size: 11.5px; color: var(--muted); line-height: 1.5;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kbe-go { flex: 0 0 auto; font-size: 12.5px; font-weight: 600; color: #2543c4; }
@media (max-width: 860px) { .kbe-m i { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; } }

/* ---------- 报告引用业务库条目（PRD 八：报告可引用知识库业务条目，互相跳转） ---------- */
.xp-rep-kb { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin: 0 0 11px; }
.xp-rep-kb-l { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.xp-rep-kbc { font-size: 11.5px; color: var(--text-2); background: #fff; border: 1px solid var(--border);
  border-radius: 6px; padding: 3px 9px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.xp-rep-kbc:hover { color: var(--primary); border-color: var(--primary); }
.xp-rep-kbm { font-size: 11.5px; color: var(--muted); }

/* ---------- 报告历史版本（同客户归档，PRD 3.5） ---------- */
.xp-hist { display: flex; flex-direction: column; gap: 8px; }
.xp-hist-i { display: block; border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px;
  text-decoration: none; color: inherit; background: #fff; }
.xp-hist-i:hover { border-color: var(--primary); }
.xp-hist-i.on { background: #f7f9ff; border-color: #c7d4f5; }
.xp-hist-h { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.xp-hist-h b { font-size: 12.5px; color: var(--text); font-weight: 600; letter-spacing: .2px; }
.xp-hist-h span { background: #f1f4fa; border-radius: 4px; padding: 1px 6px; }
.xp-hist-h i.cur { font-style: normal; font-size: 10.5px; color: #1a7f4b; background: #e9f8ef; border-radius: 4px; padding: 1px 6px; }
.xp-hist-h em { margin-left: auto; font-style: normal; font-size: 11px; }
.xp-hist-t { font-size: 13px; margin-top: 5px; line-height: 1.5; }
.xp-hist-m { font-size: 11.5px; color: var(--muted); margin-top: 3px; }

/* ---------- 十位专家切换条（工作台顶部，避免「只看到一个专家」） ---------- */
/* 11 位专家全都要能看见：宽屏换行铺满，窄屏才允许横滑并露出滚动条。
   原来写死 nowrap + 隐藏滚动条，第 10 位之后的专家被裁在屏幕外，用户以为没有这个专家。 */
.xp-switch { display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  margin: -2px 0 14px; padding-bottom: 2px; }
@media (max-width: 720px) {
  .xp-switch { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px;
    scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
  .xp-switch::-webkit-scrollbar { height: 6px; }
  .xp-switch::-webkit-scrollbar-thumb { background: #cfd6e4; border-radius: 3px; }
  .xp-switch::-webkit-scrollbar-track { background: transparent; }
}
.xp-switch-l { flex: none; font-size: 12px; color: var(--muted); margin-right: 2px; }
.xp-sw { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px;
  border: 1px solid var(--border); border-radius: 8px; background: #fff;
  font-size: 12.5px; color: var(--text-2); text-decoration: none; transition: border-color .16s, color .16s; }
.xp-sw-i { font-size: 13px; line-height: 1; }
.xp-sw b { font-weight: 500; white-space: nowrap; }
.xp-sw:hover { border-color: #c2cff3; color: var(--primary); }
.xp-sw.on { background: #f5f8ff; border-color: var(--ac, #2543c4); color: var(--ac, #2543c4); }
.xp-sw.on b { font-weight: 600; }

/* ---------- 报告页：倒计时条 / 危机提示 ---------- */
.xp-dl { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 12px; padding: 10px 14px;
  border-radius: 8px; border-left: 3px solid #2563eb; background: #f4f8ff; font-size: 12.5px; line-height: 1.65; }
.xp-dl b { flex: none; font-size: 12px; font-weight: 600; color: #1e3a8a; }
.xp-dl span { color: #334155; }
.xp-dl.ok { border-left-color: #16a34a; background: #f0fbf4; }
.xp-dl.ok b { color: #14532d; }
.xp-dl.warn { border-left-color: #d97706; background: #fff9ef; }
.xp-dl.warn b { color: #78350f; }
.xp-dl.danger { border-left-color: #dc2626; background: #fdf1f1; }
.xp-dl.danger b { color: #7f1d1d; }

/* ---------- 报告页：追问改稿 ---------- */
.xp-chat { margin-top: 16px; border: 1px solid var(--border); border-radius: 10px; background: #fff; overflow: hidden; }
.xp-chat-h { display: flex; align-items: baseline; gap: 10px; padding: 11px 14px; background: #fafbfd; border-bottom: 1px solid var(--border); }
.xp-chat-h b { font-size: 13px; font-weight: 600; }
.xp-chat-h span { font-size: 11.5px; color: var(--muted); line-height: 1.5; }
.xp-chat-list { max-height: 340px; overflow-y: auto; padding: 12px 14px; }
.xp-chat-empty { font-size: 12.5px; color: var(--muted); line-height: 1.7; }
.xp-msg { display: flex; margin-bottom: 9px; }
.xp-msg.me { justify-content: flex-end; }
.xp-msg-b { max-width: 86%; padding: 8px 11px; border-radius: 9px; font-size: 12.8px; line-height: 1.72; white-space: normal; }
.xp-msg.me .xp-msg-b { background: #eef4ff; color: #1e3a8a; border: 1px solid #dbe6fb; }
.xp-msg.ai { flex-direction: column; align-items: flex-start; }
.xp-msg.ai .xp-msg-b { background: #f7f8fa; color: #334155; border: 1px solid #ebedf2; }
.xp-msg.ai.loading .xp-msg-b { color: var(--muted); }
.xp-apply { margin-top: 7px; }
.xp-apply-done { margin-top: 7px; margin-left: 10px; font-size: 12px; color: var(--primary); text-decoration: none; }
.xp-chat-in { display: flex; gap: 8px; padding: 10px 14px; border-top: 1px solid var(--border); background: #fff; }
.xp-chat-in input { flex: 1; min-width: 0; height: 34px; padding: 0 11px; border: 1px solid var(--border);
  border-radius: 8px; font-size: 12.5px; outline: none; }
.xp-chat-in input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,67,196,.08); }
.xp-chat-tip { padding: 0 14px 10px; font-size: 11.5px; color: #b45309; line-height: 1.6; }
.xp-chat-tip:empty { display: none; }

/* ---------- 企服业务库：材料逐条白话说明 ---------- */
.kbd-mats { display: flex; flex-direction: column; gap: 8px; }
.kbd-mat { border: 1px solid var(--border); border-radius: 9px; padding: 10px 13px; background: #fff; }
.kbd-mat-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.kbd-mat-h b { font-size: 13.4px; font-weight: 600; }
.kbd-mat-n { width: 19px; height: 19px; border-radius: 5px; background: #eef2f8; color: #64748b;
  font-size: 11px; display: grid; place-items: center; flex: none; }
.kbd-mat-note { font-size: 11.8px; color: var(--muted); }
.kbd-mat-l { display: flex; gap: 9px; margin-top: 6px; font-size: 12.6px; line-height: 1.72; color: var(--text-2); }
.kbd-mat-l i { flex: none; width: 52px; font-style: normal; color: #94a3b8; font-size: 11.8px; line-height: 1.9; }
.kbd-mat-l.trap span { color: #b45309; }
.kbd-mat-l.trap i { color: #d97706; }
/* 官费明细：金额列加粗，说明列允许折行 */
.kbd-fee-tb td { vertical-align: top; }
.kbd-fee-tb .kbd-fee-amt { font-weight: 600; color: var(--text); white-space: normal; }
@media (max-width: 900px) {
  .kbd-mat-l { flex-direction: column; gap: 2px; }
  .kbd-mat-l i { width: auto; }
}

/* ==================================================================
   财务工作台 · 账务内核（凭证 / 账簿 / 报表 / 科目）与日常业务
   ------------------------------------------------------------------
   两张新页面 finBooks.js / finOps.js 共用一套表格、卡片、条栏。
   命名前缀统一 finb-（finance books），避免和既有 fw- 打架。
   ================================================================== */

/* 财务工作台顶部模式页签有 15 个，.dvc-tabs 原本 fit-content 单行，
   装不下就被裁到屏幕外。改成占满宽度、可换行。 */
.fw-tabs { width: 100%; flex-wrap: wrap; row-gap: 3px; }

.finb { display: flex; flex-direction: column; gap: 12px; min-width: 0; }

/* 账务二级条：页签 + 期间选择 */
.finb-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.finb-tabs { display: flex; gap: 2px; background: #eceef2; padding: 3px; border-radius: 9px; flex-wrap: wrap; }
.finb-tab { padding: 6px 15px; border-radius: 7px; font-size: 13.4px; color: var(--text-2); background: transparent; transition: .15s; }
.finb-tab.on { background: #fff; color: var(--text); box-shadow: var(--shadow); font-weight: 500; }
.finb-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }

/* 卡片与筛选行 */
.finb-card { padding: 0; overflow: hidden; }
.finb-card-h { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-bottom: 1px solid var(--border); }
.finb-card-h b { font-size: 13.6px; }
.finb-card-h .muted { margin-left: auto; font-size: 12px; }
.finb-filter { display: flex; align-items: center; gap: 8px; padding: 11px 14px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.finb-filter .spacer { flex: 1; }
.finb-stat { font-size: 12.5px; color: var(--muted); }
.finb-stat b { color: var(--text); font-size: 13px; }

/* 表格：长列表可横滚，操作列贴右不被裁 */
.table-wrap { overflow-x: auto; }
.finb-tb { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; }
.finb-tb th { text-align: left; font-weight: 500; font-size: 12px; color: var(--muted);
  padding: 8px 12px; background: #f7f8fa; border-bottom: 1px solid var(--border); white-space: nowrap; }
.finb-tb td { padding: 9px 12px; border-bottom: 1px solid #f1f2f5; vertical-align: top; }
.finb-tb tbody tr:hover td { background: #fafbfd; }
.finb-tb td.r, .finb-tb th.r { text-align: right; white-space: nowrap; }
.finb-tb .finb-sum { font-size: 12.8px; color: var(--text); }
.finb-tb .finb-ops { white-space: nowrap; }
.finb-tb .finb-ops .btn { margin-right: 4px; }
.finb-tb .num { color: var(--muted); font-size: 12px; }

/* 凭证里逐行科目摘要 */
.finb-lines { display: flex; flex-direction: column; gap: 1px; margin-top: 3px; }
.finb-line { display: flex; gap: 10px; font-size: 11.8px; color: var(--muted); }
.finb-line i { font-style: normal; flex: 1; min-width: 0; }
.finb-line em { font-style: normal; white-space: nowrap; }
.finb-line em.d { color: #2563eb; }
.finb-line em.c { color: #b45309; }

/* 合计条 / 底部 */
.finb-foot { display: flex; align-items: center; gap: 10px; padding: 9px 14px;
  border-top: 1px solid var(--border); background: #fbfcfd; font-size: 12.5px; color: var(--muted); }
.finb-pbar { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.finb-tip { font-size: 12px; line-height: 1.75; color: var(--muted);
  background: #f7f9fc; border: 1px solid var(--border); border-radius: 9px; padding: 9px 12px; }

/* 空态 */
.finb-empty { padding: 34px 16px; text-align: center; color: var(--muted); }
.finb-empty b { display: block; font-size: 14px; color: var(--text); font-weight: 600; margin-bottom: 5px; }
.finb-empty p { font-size: 12.6px; line-height: 1.7; max-width: 430px; margin: 0 auto 12px; }

/* 账簿：科目余额小卡 */
.finb-kv { display: flex; gap: 18px; flex-wrap: wrap; padding: 11px 14px; background: #f8f9fb;
  border-bottom: 1px solid var(--border); }
.finb-kv > div { display: flex; flex-direction: column; gap: 2px; }
.finb-kv span { font-size: 11.5px; color: var(--muted); }
.finb-kv b { font-size: 13.4px; }

/* 资产负债表：左右两栏 */
.finb-reports { display: flex; flex-direction: column; gap: 12px; }
.finb-bs { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0; }
.finb-bs-col { padding: 10px 14px; }
.finb-bs-col + .finb-bs-col { border-left: 1px solid var(--border); }
.finb-bs-h { font-size: 12.4px; font-weight: 600; color: var(--text-2); padding: 4px 0 7px; }
.finb-bs-h.mt { margin-top: 12px; border-top: 1px dashed var(--border); padding-top: 12px; }
.finb-bs-r { display: flex; justify-content: space-between; gap: 10px; padding: 4.5px 0; font-size: 12.8px; }
.finb-bs-r span { color: var(--text-2); min-width: 0; }
.finb-bs-r b { font-weight: 500; white-space: nowrap; font-variant-numeric: tabular-nums; }
.finb-bs-r.total { border-top: 1px solid var(--border); margin-top: 4px; padding-top: 6px; font-weight: 600; }
.finb-bs-r.grand { border-top: 2px solid var(--text-2); margin-top: 6px; padding-top: 7px; font-weight: 700; }

/* 利润表 */
.finb-pl { padding: 8px 14px 14px; }
.finb-pl-r { display: flex; justify-content: space-between; gap: 10px; padding: 5.5px 0;
  font-size: 12.9px; border-bottom: 1px dashed #f0f1f4; }
.finb-pl-r:last-child { border-bottom: 0; }
.finb-pl-r span { color: var(--text-2); }
.finb-pl-r b { font-weight: 500; font-variant-numeric: tabular-nums; }
.finb-pl-r.b { font-weight: 700; border-top: 1px solid var(--border); border-bottom: 0;
  margin-top: 4px; padding-top: 7px; }
.finb-pl-r.b span { color: var(--text); }

/* 科目表 */
.finb-accs { padding: 4px 14px 14px; }
.finb-acc-g { margin-top: 12px; }
.finb-acc-h { display: flex; align-items: center; gap: 8px; font-size: 12.4px; font-weight: 600;
  color: var(--text-2); padding: 5px 0; border-bottom: 1px solid var(--border); }
.finb-acc-h .muted { font-weight: 400; font-size: 11.5px; }
.finb-acc-r { display: flex; align-items: center; gap: 10px; padding: 6px 0;
  border-bottom: 1px dashed #f2f3f6; font-size: 12.8px; }
.finb-acc-r .code { width: 54px; color: var(--muted); font-variant-numeric: tabular-nums; }
.finb-acc-r .name { flex: 1; min-width: 0; }

/* 凭证编辑器（弹窗内） */
.finv { display: flex; flex-direction: column; gap: 10px; }
.finv-head { display: flex; gap: 10px; flex-wrap: wrap; }
.finv-head label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
.finv-head label.grow { flex: 1; min-width: 200px; }
.finv-f { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
.finv-tb { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; }
.finv-tb th { text-align: left; font-weight: 500; font-size: 11.8px; color: var(--muted);
  padding: 6px 8px; background: #f7f8fa; border-bottom: 1px solid var(--border); }
.finv-tb th.r { text-align: right; }
.finv-tb td { padding: 5px 6px; border-bottom: 1px solid #f2f3f6; }
.finv-tb td.num { color: var(--muted); font-size: 12px; }
.finv-tb .input { width: 100%; }
.finv-foot { display: flex; align-items: center; gap: 10px; }
.finv-foot .spacer { flex: 1; }
.finv-sum { font-size: 12.8px; color: var(--muted); }
.finv-sum b { color: var(--text); font-variant-numeric: tabular-nums; }
.finv-sum .bad { color: var(--danger); font-weight: 600; }
.finv-sum .ok { color: var(--success); font-weight: 600; }
.finv-tip { font-size: 11.8px; line-height: 1.7; color: var(--muted);
  background: #f7f9fc; border-radius: 8px; padding: 8px 11px; }

/* 手机 / 窄屏：资产负债表竖排，表格允许横滚 */
@media (max-width: 860px) {
  .finb-bs { grid-template-columns: minmax(0, 1fr); }
  .finb-bs-col + .finb-bs-col { border-left: 0; border-top: 1px solid var(--border); }
  .finb-kv { gap: 12px; }
  .finb-kv > div { min-width: 88px; }
}

/* ---------- 开票闭环：状态小卡 / 行内状态 / 详情抽屉 ---------- */
.fw-inv-stat { display: flex; gap: 0; border-bottom: 1px solid var(--border); background: #fbfcfd; flex-wrap: wrap; }
.fw-inv-stat .s { display: flex; flex-direction: column; gap: 1px; padding: 10px 16px; min-width: 132px; }
.fw-inv-stat .s + .s { border-left: 1px solid var(--border); }
.fw-inv-stat .s b { font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.fw-inv-stat .s span { font-size: 11.5px; color: var(--muted); }
.fw-inv-stat .s.amber b { color: #b45309; }
.fw-inv-stat .s.blue b { color: #2563eb; }
.fw-inv-stat .s.green b { color: var(--success); }
.fw-inv-stat .s.red b { color: var(--danger); }
.fw-inv-stat .s.dark b { color: var(--text); }

.fw-io-link { color: #2563eb; cursor: pointer; font-size: 12.5px; text-decoration: none; }
.fw-io-link:hover { text-decoration: underline; }
.fw-io-miss { color: #b45309; font-size: 12.3px; }
.fw-io-ok { color: var(--success); font-size: 12.3px; }

.fw-kv2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px 16px; }
.fw-kv2 > div { display: flex; flex-direction: column; gap: 2px; }
.fw-kv2 span { font-size: 11.5px; color: var(--muted); }
.fw-kv2 b { font-size: 13px; font-weight: 500; word-break: break-all; }
.fw-h3 { font-size: 12.4px; font-weight: 600; color: var(--text-2); margin-bottom: 8px; }
.fw-files { display: flex; flex-direction: column; gap: 6px; }
.fw-file { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--border);
  border-radius: 8px; background: #fff; text-decoration: none; color: var(--text); }
.fw-file:hover { border-color: #c7d2e5; background: #fafbfd; }
.fw-file .ic { font-size: 14px; flex: none; }
.fw-file .nm { flex: 1; min-width: 0; font-size: 12.8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 900px) {
  .fw-inv-stat .s { min-width: 0; flex: 1; padding: 9px 11px; }
  .fw-kv2 { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- 财务工作台排版修正 ---------- */
/* 全站 input/select 默认 width:100%，塞进横排筛选行会把每个控件顶成一整行，
   一行只剩一个控件，看着像坏了。这里统一收窄成「按内容宽度」。 */
.fw-filter .inp, .fw-filter select,
.finb-filter .inp, .finb-filter .input, .finb-filter select { width: auto; }
.fw-filter select, .finb-filter select { min-width: 132px; max-width: 210px; }
.fw-filter .inp:not(.grow), .finb-filter input.input { min-width: 200px; max-width: 300px; }

/* 页签文字不能被压成两行（「看板」竖排成「看 板」） */
.dvc-tab, .finb-tab { white-space: nowrap; flex: none; }
/* 15 个页签按 16px 内边距会溢出一格，收紧到 12px 就能一行排完（实测 1440 宽） */
.fw-tabs .dvc-tab { padding: 6px 12px; }

/* ==================================================================
   法务工作台 · 扩展四页（知识产权 / 期限时效 / 合规体检 / 外部律师）
   ================================================================== */

/* 12 个页签，一行放不下，允许换行 */
.lg-tabs { width: 100%; flex-wrap: wrap; row-gap: 3px; }

.lg-card { padding: 0; overflow: hidden; }
.lg-card-h { display: flex; align-items: center; gap: 10px; padding: 11px 14px;
  border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.lg-card-h b { font-size: 13.4px; }
.lg-card-h .muted { font-size: 12px; }
.lg-card-h .spacer { flex: 1; }

.lg-check { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--text-2); cursor: pointer; }
.lg-ops { white-space: nowrap; }
.lg-ops .btn { margin-right: 4px; }
.lg-red { color: var(--danger); font-weight: 600; }
.lg-row-bad td { background: #fff7f7; }

.lg-empty { padding: 34px 16px; text-align: center; color: var(--muted); }
.lg-empty b { display: block; font-size: 14px; color: var(--text); font-weight: 600; margin-bottom: 5px; }
.lg-empty p { font-size: 12.6px; line-height: 1.75; max-width: 460px; margin: 0 auto 12px; }

.lg-form2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px 12px; }
.lg-form2 .field.full { grid-column: 1 / -1; }
.lg-form2 .field label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.lg-form2 .tiny { display: block; margin-top: 3px; }

/* 布局提醒 */
.lg-advice { padding: 8px 14px 4px; display: flex; flex-direction: column; gap: 6px; }
.lg-adv { display: flex; gap: 8px; font-size: 12.6px; line-height: 1.72; color: var(--text-2); }
.lg-adv .dot { flex: none; width: 6px; height: 6px; border-radius: 50%; margin-top: 8px; background: #94a3b8; }
.lg-adv.risk .dot { background: var(--danger); }
.lg-adv.watch .dot { background: #f59e0b; }
.lg-advice-foot { display: flex; align-items: center; gap: 10px; padding: 8px 14px 12px; flex-wrap: wrap; }
.lg-advice-foot .muted { font-size: 11.8px; }

/* 合规体检 */
.lg-cmp { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); gap: 12px; align-items: start; }
.lg-score { display: flex; align-items: center; gap: 14px; padding: 14px; }
.lg-score .num { font-size: 44px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.lg-score .num.green { color: var(--success); }
.lg-score .num.amber { color: #d97706; }
.lg-score .num.red { color: var(--danger); }
.lg-score .meta { display: flex; flex-direction: column; gap: 2px; }

.lg-cmp-tabs { display: flex; gap: 2px; background: #eceef2; padding: 3px; border-radius: 8px;
  margin: 0 14px 10px; width: fit-content; flex-wrap: wrap; }
.lg-cmp-tab { padding: 5px 12px; border-radius: 6px; font-size: 12.4px; color: var(--text-2); background: transparent; }
.lg-cmp-tab.on { background: #fff; color: var(--text); box-shadow: var(--shadow); font-weight: 500; }

.lg-finding { margin: 0 14px 10px; border: 1px solid var(--border); border-left-width: 3px;
  border-radius: 8px; padding: 9px 12px; background: #fff; }
.lg-finding.risk { border-left-color: var(--danger); }
.lg-finding.watch { border-left-color: #f59e0b; }
.lg-finding .h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13px; }
.lg-finding .h b { font-weight: 600; }
.lg-finding .badge { font-size: 11px; padding: 1px 6px; border-radius: 4px; background: #fef2f2; color: #b91c1c; }
.lg-finding.watch .badge { background: #fffbeb; color: #b45309; }
.lg-finding .deduct { margin-left: auto; font-size: 11.5px; color: var(--danger); }
.lg-finding .row { display: flex; gap: 9px; margin-top: 5px; font-size: 12.4px; line-height: 1.72; color: var(--text-2); }
.lg-finding .row i { flex: none; width: 66px; font-style: normal; color: #94a3b8; font-size: 11.8px; }

.lg-cmp-foot { display: flex; align-items: center; gap: 10px; padding: 4px 14px 14px; flex-wrap: wrap; }
.lg-cmp-foot .muted { font-size: 11.8px; }

.lg-runs { padding: 6px 0 8px; }
.lg-run { display: flex; align-items: center; gap: 10px; padding: 8px 14px; cursor: pointer;
  border-bottom: 1px dashed #f0f1f4; }
.lg-run:hover { background: #fafbfd; }
.lg-run .l { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.lg-run .l b { font-size: 12.8px; font-weight: 500; }

/* AI 输出排版 */
.lg-h3 { font-size: 12.4px; font-weight: 600; color: var(--text-2); margin: 14px 0 6px; }
.lg-ul { margin: 0 0 4px; padding-left: 18px; font-size: 12.6px; line-height: 1.8; color: var(--text-2); }
.lg-ai-note { font-size: 11.8px; color: #b45309; background: #fffbeb; border: 1px solid #fde68a;
  border-radius: 8px; padding: 7px 10px; line-height: 1.6; }
.lg-ai-sum { font-size: 13px; line-height: 1.75; color: var(--text-2); margin: 8px 0 0; }
.lg-line { padding: 8px 0; border-bottom: 1px dashed #f0f1f4; }
.lg-line b { font-size: 13px; }
.lg-line span { font-size: 11.8px; color: var(--muted); margin-left: 8px; }
.lg-line p { font-size: 12.4px; line-height: 1.72; color: var(--text-2); margin: 4px 0; }

@media (max-width: 1180px) {
  .lg-cmp { grid-template-columns: minmax(0, 1fr); }
  .lg-form2 { grid-template-columns: minmax(0, 1fr); }
}

/* 法务卡片头里的筛选控件：全局 input/select 是 100% 宽，会把一行顶成四行 */
.lg-card-h .input, .lg-card-h select { width: auto; }
.lg-card-h select { min-width: 132px; max-width: 200px; }
.lg-card-h input.input:not([type=checkbox]) { min-width: 180px; max-width: 280px; }
/* 「为什么算问题」五个字被挤成两行，给足宽度并禁止换行 */
.lg-finding .row i { width: 76px; white-space: nowrap; }

/* ==================================================================
   交付中心 · 线下跑办独立栏 + 业务流程编辑器（2026-11-15）
   ================================================================== */

/* 线下跑办表格：地址那一列容易把整行撑爆，给个上限 */
.dvc-ft-tb td { vertical-align: top; }
.dvc-ft-tb td:nth-child(3) { max-width: 220px; }
.dvc-ft-ops { white-space: nowrap; }
.dvc-ft-ops .btn { margin-right: 4px; }
.dvc-row-bad td { background: #fff8f8; }

/* 业务流程行：右侧操作按钮不参与展开点击 */
.dvc-flow-ops { margin-left: auto; display: inline-flex; gap: 6px; flex-wrap: wrap; }
.dvc-flow-i .dvc-cat-r { align-items: center; }
.dvc-flow-nodes { display: flex; flex-wrap: wrap; gap: 0; }
.dvc-cat-n.must { border-color: #fcd9a8; background: #fffaf0; }
.dvc-cat-n.must i { background: #fef3c7; color: #b45309; }

/* 流程编辑器 */
.dvc-flow-edit { display: flex; flex-direction: column; gap: 12px; }
.dvc-fe-tip { font-size: 12.2px; line-height: 1.75; color: #1e40af; background: #f3f7ff;
  border: 1px solid #dbe6ff; border-radius: 9px; padding: 9px 12px; }
.dvc-fe-h { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.dvc-fe-h b { font-size: 13px; }
.dvc-fe-h .muted { font-size: 11.6px; flex: 1; min-width: 0; }

.dvc-stage { border: 1px solid var(--border); border-radius: 10px; padding: 9px 11px; margin-bottom: 8px; background: #fff; }
.dvc-stage-h { display: flex; align-items: center; gap: 7px; }
.dvc-stage-n { flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--primary-soft);
  color: var(--primary); font-size: 11px; display: inline-flex; align-items: center; justify-content: center; }
.dvc-stage-h .input { flex: 1; min-width: 0; }
.dvc-stage-b { display: grid; grid-template-columns: 1fr 96px 1fr 1fr; gap: 8px; margin-top: 8px; }
.dvc-stage-b label { display: flex; flex-direction: column; gap: 3px; font-size: 11.5px; color: var(--muted); }
.dvc-stage-b .input { width: 100%; }
.dvc-stage-d { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.dvc-stage-d .input { width: 100%; }

@media (max-width: 1100px) {
  .dvc-stage-b { grid-template-columns: 1fr 1fr; }
  .dvc-stage-d { grid-template-columns: 1fr; }
}

/* ---------- 企服业务库 · 培训资料（小白视角） ---------- */
.kbt-hero { border: 1px solid #dbe6ff; border-radius: 12px; padding: 14px 16px;
  background: linear-gradient(120deg, #f2f6ff, #fff 70%); }
.kbt-hero-tag { display: inline-block; font-size: 11px; font-weight: 600; color: #2543c4;
  background: #e7edff; border-radius: 20px; padding: 2px 9px; margin-bottom: 8px; }
.kbt-hero-one { font-size: 15.5px; font-weight: 600; line-height: 1.6; margin-bottom: 9px; }
.kbt-hero-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; }
.kbt-hero-list li { position: relative; padding-left: 15px; font-size: 12.8px; line-height: 1.75; color: var(--text-2); }
.kbt-hero-list li::before { content: ''; position: absolute; left: 2px; top: 8px; width: 5px; height: 5px;
  border-radius: 50%; background: #93a7e8; }

.kbt-exp { display: flex; flex-direction: column; gap: 9px; }
.kbt-exp-i { display: flex; gap: 9px; font-size: 12.8px; line-height: 1.85; color: var(--text-2); }
.kbt-exp-i i { flex: none; width: 19px; height: 19px; border-radius: 50%; background: #f1f4fb; color: #4b5b86;
  font-style: normal; font-size: 11px; display: inline-flex; align-items: center; justify-content: center; margin-top: 3px; }

.kbt-fit { display: flex; flex-wrap: wrap; gap: 7px; }
.kbt-fit-i { font-size: 12.2px; color: var(--text-2); background: #f7f9fc; border: 1px solid var(--border);
  border-radius: 20px; padding: 4px 11px; }
.kbt-fit-n { font-size: 11.8px; color: var(--muted); line-height: 1.8; margin-top: 8px; }

/* 上手四件套：周期 / 费用 / 材料 / 流程 —— 培训 v2 新增，小白照着就能开工 */
.kbt-cf { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); gap: 9px; }
.kbt-cf-i { border: 1px solid #e0e9ff; background: #f7faff; border-radius: 10px; padding: 10px 12px; }
.kbt-cf-i i { display: block; font-style: normal; font-size: 11.3px; color: #4b5b86; margin-bottom: 4px; }
.kbt-cf-i b { display: block; font-size: 12.5px; font-weight: 500; line-height: 1.8; color: var(--text); }

.kbt-sub { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; font-size: 12.7px; font-weight: 600;
  line-height: 1.5; margin: 15px 0 9px; padding-left: 9px; border-left: 3px solid var(--primary); }
.kbt-sub i { font-style: normal; font-size: 10.8px; font-weight: 500; color: var(--primary);
  background: var(--primary-soft); border-radius: 20px; padding: 1px 7px; }
.kbt-sub span { font-size: 11.4px; font-weight: 400; color: var(--muted); }

.kbt-mats { margin: 0; padding: 0; list-style: none; counter-reset: kbm; display: flex; flex-direction: column; gap: 6px; }
.kbt-mats li { counter-increment: kbm; position: relative; padding-left: 25px;
  font-size: 12.5px; line-height: 1.8; color: var(--text-2); }
.kbt-mats li::before { content: counter(kbm); position: absolute; left: 0; top: 3px; width: 17px; height: 17px;
  border-radius: 5px; background: #eef2ff; color: #35479b; font-size: 10.5px;
  display: inline-flex; align-items: center; justify-content: center; }

.kbt-steps { display: flex; flex-direction: column; }
.kbt-step { display: flex; gap: 10px; position: relative; padding-bottom: 10px; }
.kbt-step:last-child { padding-bottom: 0; }
.kbt-step::before { content: ''; position: absolute; left: 10px; top: 20px; bottom: 0; width: 1px; background: #e3e9f6; }
.kbt-step:last-child::before { display: none; }
.kbt-step i { flex: none; width: 21px; height: 21px; border-radius: 50%; background: #f2f6ff;
  border: 1px solid #d9e3fb; color: #35479b; font-style: normal; font-size: 10.5px;
  display: inline-flex; align-items: center; justify-content: center; }
.kbt-step span { flex: 1; min-width: 0; font-size: 12.5px; line-height: 1.8; color: var(--text-2); padding-top: 1px; }

.kbt-traps { padding-left: 21px; }
.kbt-traps li { margin: 3px 0; }

.kbt-when { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 7px; }
.kbt-when li { position: relative; padding-left: 22px; font-size: 12.8px; line-height: 1.8; color: var(--text-2); }
.kbt-when li::before { content: '必'; position: absolute; left: 0; top: 3px; width: 15px; height: 15px;
  border-radius: 4px; background: var(--danger-soft); color: #b91c1c; font-size: 9.5px; font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center; }

.kbt-know { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 9px; }
.kbt-know-i { border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px; background: #fff; }
.kbt-know-i b { display: block; font-size: 12.8px; margin-bottom: 5px; }
.kbt-know-i span { font-size: 12.3px; color: var(--text-2); line-height: 1.8; }

.kbt-gloss { display: flex; flex-direction: column; }
.kbt-gloss-i { display: flex; gap: 12px; padding: 7px 0; border-bottom: 1px dashed #eef1f6; font-size: 12.5px; line-height: 1.75; }
.kbt-gloss-i:last-child { border-bottom: none; }
.kbt-gloss-i b { flex: 0 0 132px; font-weight: 600; color: var(--text); }
.kbt-gloss-i span { flex: 1; min-width: 0; color: var(--text-2); }

.kbt-law { display: flex; flex-direction: column; gap: 8px; }
.kbt-law-i { border-left: 2px solid #c7d4f5; padding: 2px 0 2px 11px; font-size: 12.5px; line-height: 1.8; color: var(--text-2); }
.kbt-law-i b { display: block; color: var(--text); font-size: 12.6px; }
.kbt-law-i i { font-style: normal; font-size: 11.5px; color: var(--muted); }

.kbt-quiz { display: flex; flex-direction: column; gap: 7px; }
.kbt-q { border: 1px solid var(--border); border-radius: 9px; padding: 9px 12px; background: #fcfdff; }
.kbt-q summary { font-size: 12.8px; font-weight: 500; cursor: pointer; list-style: none; display: flex; gap: 8px; align-items: baseline; }
.kbt-q summary::-webkit-details-marker { display: none; }
.kbt-q summary::after { content: '答案 ▾'; margin-left: auto; flex: none; font-size: 11px; font-weight: 400; color: var(--muted); }
.kbt-q[open] summary::after { content: '收起 ▴'; }
.kbt-q summary i { flex: none; width: 18px; height: 18px; border-radius: 50%; background: var(--primary-soft);
  color: var(--primary); font-style: normal; font-size: 10.5px; display: inline-flex; align-items: center; justify-content: center; }
.kbt-q > div { font-size: 12.4px; line-height: 1.85; color: var(--text-2); margin-top: 8px; padding-top: 8px;
  border-top: 1px dashed #eef1f6; white-space: pre-wrap; }

/* 范例文件 */
.kbt-files { display: flex; flex-direction: column; gap: 7px; }
.kbt-file { display: flex; align-items: center; gap: 10px; border: 1px solid var(--border);
  border-radius: 9px; padding: 8px 11px; background: #fff; }
.kbt-file-k { flex: none; font-size: 10.5px; color: #2543c4; background: #eef2ff; border-radius: 4px; padding: 1px 7px; }
.kbt-file-m { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.kbt-file-m a { font-size: 12.8px; font-weight: 500; color: var(--text); text-decoration: none; }
.kbt-file-m a:hover { color: var(--primary); text-decoration: underline; }
.kbt-file-m span { font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kbt-file-empty { font-size: 12.3px; color: var(--muted); border: 1px dashed var(--border-strong);
  border-radius: 9px; padding: 16px; text-align: center; background: #fafbfd; }

/* ---------- 企服业务库 · 编辑弹窗 ---------- */
.kbz-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 12px; }
.kbz-tab { border: none; background: transparent; border-bottom: 2px solid transparent; padding: 8px 12px;
  font-family: inherit; font-size: 13px; color: var(--text-2); cursor: pointer; }
.kbz-tab.on { color: var(--primary); border-bottom-color: var(--primary); font-weight: 500; }
.kbz-tip { font-size: 11.8px; line-height: 1.75; color: #1e40af; background: #f3f7ff;
  border: 1px solid #dbe6ff; border-radius: 8px; padding: 8px 11px; margin-bottom: 12px; }
.kbz-f { display: flex; flex-direction: column; gap: 5px; margin-bottom: 12px; }
.kbz-f > span { font-size: 12px; font-weight: 500; color: var(--text-2); display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.kbz-f > span i { font-style: normal; font-size: 11px; font-weight: 400; color: var(--muted); }
.kbz-f .input { width: 100%; }
.kbz-ta { font-family: inherit; font-size: 12.5px; line-height: 1.8; resize: vertical; }
.kbz-two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kbz-sc { border: 1px solid var(--border); border-radius: 10px; padding: 11px 13px; margin-bottom: 10px; background: #fcfdff; }
.kbz-sc-h { display: flex; align-items: center; gap: 9px; margin-bottom: 10px; }
.kbz-sc-h b { flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--primary-soft);
  color: var(--primary); font-size: 11px; display: inline-flex; align-items: center; justify-content: center; }
.kbz-sc-h .input { flex: 1; min-width: 0; font-weight: 600; }
@media (max-width: 720px) { .kbz-two { grid-template-columns: 1fr; } }

/* ---------- 财务 · 从销售订单开票 ---------- */
.fw-op-list { display: flex; flex-direction: column; }
.fw-op-i { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid #f0f1f4; }
.fw-op-i:last-child { border-bottom: none; }
.fw-op-m { flex: 1; min-width: 0; }
.fw-op-t { font-size: 13px; font-weight: 500; }
.fw-op-s { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.fw-op-a { flex: none; text-align: right; }
.fw-op-a b { display: block; font-size: 13px; }
.fw-op-a span { font-size: 11px; color: var(--muted); }

/* ==================================================================
 * 人事考试 · AI 出题（2026-11-15）
 * ------------------------------------------------------------------
 * 出题弹窗分三段：选资料 → 选题型/份数 → 过一遍题目。
 * 用横向卡片而不是下拉，是因为「用哪份资料」直接决定题目质量，
 * 得让人一眼看到每份资料里有多少条东西可用。
 * ================================================================== */
.hex-aigen {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 8px 10px; margin-bottom: 8px; border-radius: 8px;
  background: linear-gradient(90deg, #f4f7ff 0%, #f9fbff 100%);
  border: 1px dashed #cddbff;
}
.hex-aigen .tiny { flex: 1 1 220px; min-width: 0; line-height: 1.5; }

.hexg-sec { border-top: 1px solid var(--border, #eceef2); padding: 14px 0; }
.hexg-sec:first-child { border-top: 0; padding-top: 2px; }
.hexg-h {
  display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 10px;
}
.hexg-h b { font-size: 13.5px; }
.hexg-h .tiny { flex: 1 1 200px; min-width: 0; }

.hexg-src { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.hexg-src-i {
  border: 1px solid var(--border, #e5e7eb); border-radius: 8px; padding: 10px 12px;
  cursor: pointer; display: flex; flex-direction: column; gap: 4px; background: #fff;
  transition: border-color .12s, background .12s;
}
.hexg-src-i:hover { border-color: #c8d8ff; }
.hexg-src-i.on { border-color: var(--primary, #2b6cf6); background: #f5f8ff; box-shadow: 0 0 0 1px var(--primary, #2b6cf6) inset; }
.hexg-src-t { display: flex; align-items: baseline; gap: 8px; }
.hexg-src-t b { font-size: 13px; font-weight: 600; }
.hexg-src-t em { font-style: normal; flex: none; }
.hexg-src-i .tiny { line-height: 1.5; }

.hexg-types { display: flex; flex-wrap: wrap; gap: 8px 10px; }
.hexg-t-i {
  display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px;
  border: 1px solid var(--border, #e5e7eb); border-radius: 8px; padding: 6px 10px; background: #fff;
}
.hexg-t-i input[type="number"] { text-align: right; }

.hexg-prev { display: flex; flex-direction: column; gap: 8px; max-height: 320px; overflow: auto; padding-right: 2px; }
.hexg-q { border: 1px solid var(--border, #eceef2); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; background: #fff; }
.hexg-q-h { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; font-size: 12.5px; }
.hexg-q-h b { flex: 1 1 240px; min-width: 0; font-weight: 600; line-height: 1.55; }
.hexg-q-h .tiny { flex: none; }

@media (max-width: 900px) {
  .hexg-src { grid-template-columns: minmax(0, 1fr); }
}

/* ==================================================================
 * 人事工作台 · AI 王牌人事经理（2026-11-15 按需求文档重做）
 * ------------------------------------------------------------------
 * 三层信息，从上到下：
 *   1) 本公司数据条 + 系统推荐 + 最近生成 —— 先回答「我现在什么情况」；
 *   2) 11 个板块卡片三列排 —— 一屏看得完，HR 每天要用的东西不能埋进折叠；
 *   3) 抽屉里的表单与报告 —— 报告复用专家的 xp-* 块样式，这里只补外框与导航。
 * ================================================================== */

/* ---- 页头：数据条 / 推荐 / 最近 ---- */
.aimgr-lead { padding: 0 16px; }
.aimgr-stat { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.aimgr-stat > div {
  border: 1px solid var(--border); background: #fafbfd; border-radius: 9px; padding: 8px 11px;
}
.aimgr-stat b { display: block; font-size: 17px; font-weight: 650; letter-spacing: -.3px; line-height: 1.2; }
.aimgr-stat span { display: block; font-size: 11.2px; color: var(--muted); margin-top: 2px; }
.aimgr-stat > div.warn b { color: var(--warn, #d97706); }
.aimgr-stat > div.blue b { color: var(--primary); }
.aimgr-stat > div.danger b { color: var(--danger); }

.aimgr-reco { display: flex; flex-wrap: wrap; align-items: stretch; gap: 8px; margin-top: 10px; }
.aimgr-reco-l {
  flex: none; align-self: center; font-size: 11.3px; color: var(--primary);
  background: var(--primary-soft, #eef2ff); border-radius: 20px; padding: 3px 9px;
}
.aimgr-reco-i {
  flex: 0 1 360px; min-width: 220px; text-align: left; cursor: pointer;
  border: 1px solid #dbe4fb; background: #fbfdff; border-radius: 9px; padding: 8px 11px;
  display: flex; flex-direction: column; gap: 2px; transition: border-color .12s, box-shadow .12s;
}
.aimgr-reco-i:hover { border-color: var(--primary); box-shadow: 0 2px 10px rgba(37, 99, 235, .1); }
.aimgr-reco-i b { font-size: 12.5px; font-weight: 600; color: var(--text); }
.aimgr-reco-i span { font-size: 11.4px; color: var(--muted); line-height: 1.6; }

.aimgr-recent { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 10px; }
.aimgr-recent-l { flex: none; font-size: 11.5px; color: var(--muted); }
.aimgr-recent-i {
  display: flex; align-items: baseline; gap: 6px; cursor: pointer; max-width: 100%;
  border: 1px solid var(--border); background: #fff; border-radius: 7px; padding: 4px 9px;
}
.aimgr-recent-i:hover { border-color: var(--primary); }
.aimgr-recent-i b { font-size: 11.8px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aimgr-recent-i span { font-size: 10.8px; color: var(--muted); white-space: nowrap; }

/* ---- 11 个板块卡片 ---- */
.aimgr-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 12px 16px 16px; }
.aimgr-card {
  display: flex; flex-direction: column; gap: 7px; cursor: pointer;
  border: 1px solid var(--border); border-radius: 10px; padding: 13px 14px; background: #fff;
  transition: border-color .12s, box-shadow .12s, transform .12s;
}
.aimgr-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(37, 99, 235, .1); transform: translateY(-1px); }
.aimgr-card-h { display: flex; align-items: center; gap: 8px; }
.aimgr-i {
  flex: none; width: 30px; height: 30px; border-radius: 8px; background: #f2f6ff;
  display: flex; align-items: center; justify-content: center; font-size: 16px;
}
.aimgr-card-h b { flex: 1; min-width: 0; font-size: 13.2px; font-weight: 600; line-height: 1.4; }
.aimgr-no {
  flex: none; font-style: normal; width: 18px; height: 18px; border-radius: 5px;
  background: #f4f6fa; color: var(--muted); font-size: 10.5px;
  display: inline-flex; align-items: center; justify-content: center;
}
.aimgr-card-d { font-size: 12.2px; color: var(--text-2, #4b5563); line-height: 1.7; }
.aimgr-card-o { margin: 0; padding-left: 16px; display: flex; flex-direction: column; gap: 3px; }
.aimgr-card-o li { font-size: 11.6px; color: var(--muted); line-height: 1.65; }
.aimgr-card-f {
  margin-top: auto; padding-top: 8px; border-top: 1px dashed var(--border);
  display: flex; align-items: baseline; gap: 8px;
}
.aimgr-card-f span {
  flex: 1; min-width: 0; font-size: 11.2px; color: var(--primary); line-height: 1.6;
  background: var(--primary-soft, #eef2ff); border-radius: 5px; padding: 2px 7px;
}
.aimgr-card-f em { flex: none; font-style: normal; font-size: 12px; color: var(--primary); white-space: nowrap; }

/* ---- 抽屉表单 ---- */
.aimgr-run-t { font-size: 12.8px; color: var(--text-2, #4b5563); line-height: 1.75; }
.aimgr-run-outs { display: flex; flex-direction: column; gap: 4px; margin: 9px 0 15px; }
.aimgr-run-outs span { position: relative; padding-left: 17px; font-size: 12.3px; color: var(--text-2, #4b5563); line-height: 1.7; }
.aimgr-run-outs span::before {
  content: ''; position: absolute; left: 4px; top: 7px; width: 5px; height: 5px;
  border-radius: 50%; background: var(--primary);
}
.aimgr-run-tip { margin-top: 11px; font-size: 11.6px; color: var(--muted); line-height: 1.7; }

.aimgr-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px 14px; }
.aimgr-form .span2 { grid-column: span 2; }
.aimgr-form .field { margin-bottom: 0; }
.aimgr-form .field > span {
  display: block; font-size: 12.4px; color: var(--text-2, #4b5563);
  margin-bottom: 6px; line-height: 1.5;
}
.aimgr-req { color: var(--danger); font-style: normal; margin-left: 2px; }
.aimgr-hint { font-style: normal; font-size: 11.2px; color: var(--muted); font-weight: 400; }

.aimgr-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.aimgr-chip {
  display: inline-flex; align-items: center; cursor: pointer; white-space: nowrap;
  border: 1px solid var(--border); background: #fff; border-radius: 20px; padding: 4px 11px;
  font-size: 12px; color: var(--text-2, #4b5563); transition: border-color .12s, background .12s;
}
.aimgr-chip.on { border-color: #c7d4f5; background: var(--primary-soft, #eef2ff); color: var(--primary); font-weight: 600; }
.aimgr-chip input { display: none; }

.aimgr-file { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-bottom: 8px; }
.aimgr-file-l { font-size: 11.8px; color: var(--muted); }
.aimgr-file-i {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11.5px; color: #35479b; background: #eef2ff;
  border-radius: 5px; padding: 2px 6px 2px 8px; margin: 0 5px 5px 0;
}
.aimgr-file-x {
  cursor: pointer; font-weight: 400; color: #8b93a7; padding: 0 2px;
  border-radius: 4px; font-style: normal;
}
.aimgr-file-x:hover { color: var(--danger, #d9363e); background: #fdecec; }
/* 转写状态：小字挂在文件名后面，不抢眼但能看出「这段录音处理到哪一步」 */
.aimgr-ftag {
  font-style: normal; font-size: 10.5px; color: #6b7280; background: #f1f3f7;
  border-radius: 4px; padding: 1px 5px;
}
.aimgr-ftag.ok { color: #157347; background: #e8f6ee; }
.aimgr-ftag.warn { color: #a2610a; background: #fff4e5; }
/* 板块专属字段的小标题：一眼看出「这块问的是它自己的事」 */
.aimgr-sec {
  grid-column: span 2; font-size: 11.5px; font-weight: 600; color: var(--primary);
  letter-spacing: .2px; padding-top: 3px; margin-top: 3px;
  border-top: 1px dashed var(--border);
}

/* ---- 报告视图 ---- */
.aimgr-out { margin-top: 16px; border-top: 1px solid var(--border); padding-top: 14px; }
.aimgr-rep-h { display: flex; align-items: flex-start; gap: 12px; }
.aimgr-rep-ht { flex: 1; min-width: 0; }
.aimgr-rep-title { font-size: 15.5px; font-weight: 600; line-height: 1.5; }
.aimgr-rep-meta { display: flex; gap: 10px; flex-wrap: wrap; font-size: 11.5px; color: var(--muted); margin-top: 4px; }
.aimgr-rep-a { flex: none; display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.aimgr-rep-s {
  margin: 10px 0 11px; padding: 9px 12px; border-radius: 8px; background: #f7f9fc;
  font-size: 12.8px; color: var(--text-2, #4b5563); line-height: 1.75;
}
.aimgr-kpi { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; margin-bottom: 13px; }
.aimgr-kpi > div { border: 1px solid #e0e9ff; background: #f7faff; border-radius: 9px; padding: 8px 11px; }
.aimgr-kpi span { display: block; font-size: 11.2px; color: #4b5b86; margin-bottom: 3px; }
.aimgr-kpi b { font-size: 13.5px; font-weight: 600; line-height: 1.4; }

.aimgr-rep-body { display: grid; grid-template-columns: 172px minmax(0, 1fr); gap: 14px; }
.aimgr-rep-nav { display: flex; flex-direction: column; gap: 3px; max-height: 560px; overflow: auto; }
.aimgr-nav-i {
  display: flex; align-items: flex-start; gap: 7px; text-align: left; cursor: pointer;
  padding: 7px 9px; border-radius: 7px; border: 1px solid transparent;
  background: transparent; font-size: 11.9px; color: var(--text-2, #4b5563); line-height: 1.45;
}
.aimgr-nav-i:hover { background: #f6f8fc; }
.aimgr-nav-i i { flex: none; font-style: normal; font-size: 10.5px; color: var(--muted); width: 13px; }
.aimgr-nav-i.on { background: var(--primary-soft, #eef2ff); color: var(--primary); font-weight: 600; border-color: #dbe4fb; }
.aimgr-rep-c { min-width: 0; max-height: 560px; overflow: auto; padding-right: 4px; }

/* ---- 追问 ---- */
.aimgr-chat { margin-top: 15px; border-top: 1px solid var(--border); padding-top: 12px; }
.aimgr-chat-h { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 9px; }
.aimgr-chat-h b { font-size: 13px; }
.aimgr-chat-h span { font-size: 11.5px; color: var(--muted); }
.aimgr-chat-list { display: flex; flex-direction: column; gap: 8px; max-height: 280px; overflow: auto; }
.aimgr-msg { font-size: 12.6px; line-height: 1.75; }
.aimgr-msg > b { display: block; font-size: 11px; font-weight: 500; color: var(--muted); margin-bottom: 2px; }
.aimgr-msg > div { background: #f7f9fc; border-radius: 8px; padding: 8px 11px; }
.aimgr-msg.me > div { background: var(--primary-soft, #eef2ff); }
.aimgr-msg-a { display: flex; align-items: center; gap: 8px; margin-top: 6px; flex-wrap: wrap; }
.aimgr-msg-a span { font-size: 11px; color: var(--muted); }
.aimgr-chat-in { display: flex; gap: 8px; margin-top: 9px; }
.aimgr-chat-in input { flex: 1; min-width: 0; }
.aimgr-dis { margin-top: 14px; padding-top: 10px; border-top: 1px dashed var(--border); font-size: 11.2px; color: var(--muted); line-height: 1.75; }

@media (max-width: 1280px) {
  .aimgr-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .aimgr-grid { grid-template-columns: minmax(0, 1fr); }
  .aimgr-stat { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .aimgr-rep-body { grid-template-columns: minmax(0, 1fr); }
  .aimgr-rep-nav { flex-direction: row; overflow-x: auto; max-height: none; padding-bottom: 4px; }
  .aimgr-nav-i { flex: none; white-space: nowrap; }
}
@media (max-width: 760px) {
  .aimgr-form { grid-template-columns: minmax(0, 1fr); }
  .aimgr-form .span2 { grid-column: auto; }
}

/* AI 王牌人事经理页头：标题不许被右侧的长标签挤到换行 */
#hr-aimgr-pane .card-head h3 { white-space: nowrap; flex: none; }
#hr-aimgr-pane .card-head #hr-aimgr-brief { max-width: 46%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ==================================================================
 * 法务 · AI 王牌法务经理（2026-11-16）
 * ------------------------------------------------------------------
 * 面板外壳、板块卡片、表单、报告视图全部复用人事经理的 aimgr-* 一套，
 * 这里只补法务特有的两样：风险等级标签 + 合同台账选择器。
 * （同一套骨架两处用，改版式只改一处，两端不会长歪）
 * ================================================================== */
#law-aimgr-pane .card-head h3 { white-space: nowrap; flex: none; }
#law-aimgr-pane .card-head #law-aimgr-brief { max-width: 46%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 法务的页头是 6 个数（多一个「合同总额」），人事那套是 5 列 —— 不单独给列数，
   第 6 个会掉到第二行被拉成一整条通栏，看着像排版坏了 */
#law-aimgr-pane .aimgr-stat { grid-template-columns: repeat(6, minmax(0, 1fr)); }
@media (max-width: 1440px) {
  #law-aimgr-pane .aimgr-stat { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  #law-aimgr-pane .aimgr-stat { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* 风险等级：红/黄/蓝三级，与法务台账的 risk_level 同口径 */
.law-risk {
  display: inline-flex; align-items: center; font-style: normal;
  font-size: 11.5px; font-weight: 600; border-radius: 6px; padding: 1px 7px;
  vertical-align: middle; margin-left: 6px;
}
.law-risk.high { color: #b42318; background: #fdecec; }
.law-risk.mid { color: #a2610a; background: #fff4e5; }
.law-risk.low { color: #1d4ed8; background: #eef2ff; }

/* 合同台账选择器：一行一份，勾中变蓝，不做的太花 */
.law-pick { max-height: 320px; overflow: auto; display: flex; flex-direction: column; gap: 6px; }
.law-pick-i {
  display: flex; align-items: flex-start; gap: 9px; cursor: pointer;
  border: 1px solid var(--border); border-radius: 8px; padding: 8px 11px; background: #fff;
}
.law-pick-i:hover { border-color: #c7d4f5; }
.law-pick-i.on { border-color: #c7d4f5; background: #f7faff; }
.law-pick-i input { margin-top: 3px; flex: none; }
.law-pick-i > div { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.law-pick-i b { font-size: 12.8px; font-weight: 600; line-height: 1.5; }
.law-pick-i span { font-size: 11.6px; color: var(--muted); line-height: 1.6; }

/* 生成后收起填表区：.aimgr-form 是 display:grid，[hidden] 的 UA 规则压不住它，
   必须显式补一刀，否则「改条件」点了没反应也看不出来 */
.aimgr-run [hidden], .aimgr-run .aimgr-form[hidden] { display: none !important; }

@media (max-width: 900px) {
  #law-aimgr-pane .card-head h3 { white-space: normal; }
  #law-aimgr-pane .card-head #law-aimgr-brief { max-width: 100%; }
}

/* ==================================================================
 * 人事 · 值班（2026-11-15）
 * ------------------------------------------------------------------
 * 值班和排班共用一张月历，但值班不进考勤、不算钱，
 * 所以列表用独立的紫色标识（#7c5cff）区分于排班的蓝，避免 HR 误以为是排班。
 * ================================================================== */
.hsa-duty { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 12px; }
.hsa-duty-h { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.hsa-duty-h b { font-size: 13px; }
.hsa-duty-h .tiny { flex: 1 1 200px; min-width: 0; }
.hsa-duty-empty {
  font-size: 12.5px; color: var(--muted); background: #f7f8fb;
  border-radius: 8px; padding: 14px 12px; text-align: center; line-height: 1.7;
}
.hsa-duty-i {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 7px 10px; border-radius: 7px; font-size: 12.5px;
  border-left: 3px solid #7c5cff; background: #faf9ff; margin-bottom: 5px;
}
.hsa-duty-i b { flex: none; font-weight: 600; min-width: 74px; }
.hsa-duty-i b i { font-style: normal; font-weight: 400; color: var(--muted); font-size: 11.5px; }
.hsa-duty-i span { flex: none; min-width: 56px; }
.hsa-duty-i em { font-style: normal; flex: none; color: #5b47c9; font-variant-numeric: tabular-nums; }
.hsa-duty-i u { text-decoration: none; flex: 1 1 100px; min-width: 0; color: var(--muted); font-size: 12px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hsa-duty-del {
  margin-left: auto; border: 0; background: transparent; color: var(--muted);
  font-size: 16px; line-height: 1; cursor: pointer; padding: 0 4px; border-radius: 4px;
}
.hsa-duty-del:hover { color: var(--danger); background: #fdecec; }

/* ==================================================================
 * 投流线索 · 线索排班（2026-11-15）
 * ------------------------------------------------------------------
 * 一张「人 × 日期」的周表：格子里的胶囊就是排班时段。
 * 之所以不做成日历，是因为排班是「谁在班」的问题，横向看人比纵向看天快；
 * 而且一个人一天可能早晚两班，胶囊能叠，日历格子叠不下。
 * ================================================================== */
.ls-now {
  display: flex; flex-direction: column; gap: 4px; padding: 10px 12px;
  border-radius: 8px; background: #f6f7fb; border-left: 3px solid var(--muted); margin-bottom: 14px;
}
.ls-now b { font-size: 13px; font-weight: 600; }
.ls-now .tiny { line-height: 1.6; }
.ls-now.on { background: #f1f8f3; border-left-color: var(--primary, #2b6cf6); }
.ls-now.warn { background: #fffaf0; border-left-color: #d9a441; }

.ls-form { border-top: 1px solid var(--border, #eceef2); padding-top: 12px; }
.ls-f { display: flex; flex-direction: column; gap: 6px; margin-bottom: 10px; }
.ls-f > span { font-size: 12.5px; color: var(--text-2); }
.ls-line { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.ls-f2 { display: flex; flex-direction: column; gap: 4px; }
.ls-f2 > span { font-size: 11.5px; color: var(--muted); }
.ls-f2.grow { flex: 1 1 180px; min-width: 140px; }
.ls-f2 input, .ls-f2 select { height: 30px; font-size: 12.5px; padding: 0 8px; }

.ls-pick {
  display: flex; flex-wrap: wrap; gap: 6px; max-height: 132px; overflow: auto;
  border: 1px solid var(--border, #e5e7eb); border-radius: 8px; padding: 8px 10px; background: #fff;
}
.ls-pick-all, .ls-pick-i {
  display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px;
  border: 1px solid var(--border, #e8eaef); border-radius: 7px; padding: 4px 8px; cursor: pointer;
  white-space: nowrap;
}
.ls-pick-all { background: #f6f8fb; }
.ls-pick-i i { font-style: normal; color: var(--muted); font-size: 11px; }
.ls-pick-i:has(input:checked) { border-color: var(--primary, #2b6cf6); background: #f4f8ff; }

.ls-table-wrap { overflow: auto; }
.ls-table { border-collapse: separate; border-spacing: 0; width: 100%; }
.ls-table th, .ls-table td {
  border-bottom: 1px solid var(--border, #eef0f4); padding: 6px 6px; text-align: center;
  font-size: 12px; vertical-align: top;
}
.ls-table th { font-weight: 500; color: var(--text-2); background: #fafbfd; position: sticky; top: 0; }
.ls-table th b { display: block; font-size: 12px; }
.ls-table th i { font-style: normal; font-size: 11px; color: var(--muted); }
.ls-table th.we { background: #f6f7fa; }
.ls-name { text-align: left; white-space: nowrap; min-width: 96px; }
.ls-name b { display: block; font-size: 12.5px; font-weight: 600; }
.ls-name i { display: block; font-style: normal; font-size: 10.5px; color: var(--muted); }
.ls-cell { min-width: 74px; }
.ls-cell.we { background: #fbfbfd; }
.ls-chip {
  display: inline-flex; align-items: center; gap: 3px; margin: 1px;
  background: var(--primary-soft, #e8f0ff); color: var(--primary, #2b6cf6);
  border-radius: 5px; padding: 2px 5px; font-size: 11px; font-variant-numeric: tabular-nums;
  cursor: default; white-space: nowrap;
}
.ls-chip i {
  font-style: normal; cursor: pointer; opacity: .55; padding: 0 1px; border-radius: 3px;
}
.ls-chip i:hover { opacity: 1; background: rgba(0, 0, 0, .08); }

/* ---------- 线索号码保护 / 悬停复制（2026-11-15） ----------
   号码默认脱敏，点「查看」才向后端取完整号码（留痕）；
   姓名/公司/电话这类信息，鼠标移上去才出现复制钮，不占版面。 */
.lp { display: inline-flex; align-items: center; gap: 5px; }
.lp-num { font-variant-numeric: tabular-nums; letter-spacing: .2px; }
.lp-btn { border: 0; background: #eef2f8; color: #2b6cf6; font-size: 11px; line-height: 1;
  padding: 3px 6px; border-radius: 5px; cursor: pointer; }
.lp-btn:hover { background: #dfe8fb; }
.cp-hover { position: relative; display: inline-flex; align-items: center; }
.cp-btn { opacity: 0; margin-left: 4px; border: 0; background: transparent; color: var(--muted);
  cursor: pointer; font-size: 12px; line-height: 1; padding: 2px 3px; border-radius: 4px; transition: opacity .12s; }
.cp-hover:hover .cp-btn { opacity: .85; }
.cp-btn:hover { background: #eef2f8; color: var(--primary); opacity: 1; }
/* 抽屉/详情里的 kv 字段：整项悬停出现复制钮 */
.kv-dl dt .cp-btn, .kv-dl dd .cp-btn { opacity: 0; }
.kv-dl dd:hover .cp-btn, .kv-dl dt:hover .cp-btn { opacity: .85; }

/* 导出额度弹窗 */
.exp-quota { display: flex; align-items: baseline; gap: 10px; padding: 12px 14px; border-radius: 8px;
  background: #f3f7ff; border: 1px solid #e2ebfb; }
.eq-num { font-size: 26px; font-weight: 600; color: var(--primary); }
.eq-unit { font-size: 12px; color: var(--text-2); margin-left: 3px; }
.eq-sub { font-size: 12px; color: var(--muted); margin-left: auto; }
.exp-mode { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.exp-opt { display: flex; gap: 9px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--border);
  border-radius: 8px; cursor: pointer; }
.exp-opt:hover { border-color: #c9d8f5; background: #fbfcff; }
.exp-opt.off { opacity: .55; cursor: not-allowed; }
.exp-opt b { font-size: 13px; font-weight: 500; display: block; }
.exp-opt em { font-style: normal; font-size: 11.5px; color: var(--muted); }
.exp-tip { margin-top: 10px; font-size: 12px; color: var(--muted); line-height: 1.7; }

/* 号码 / 导出管控看板 */
.gb-top { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 6px; }
.gb-kpi { padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; background: #fcfdff; }
.gk-l { font-size: 11.5px; color: var(--muted); }
.gk-v { font-size: 20px; font-weight: 600; margin-top: 2px; }
.gk-v.danger { color: var(--danger); }
.gk-u { font-size: 11.5px; font-weight: 400; color: var(--muted); margin-left: 4px; }
.gb-apply { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid #fde9c8;
  background: #fffdf7; border-radius: 8px; margin-bottom: 8px; }
.ga-main { flex: 1; min-width: 0; font-size: 12.5px; }
.ga-reason { font-size: 12px; color: var(--text-2); margin-top: 3px; }
.ga-acts { display: flex; gap: 6px; }
.gb-recent { font-size: 12px; color: var(--muted); line-height: 1.9; margin-top: 4px; }
@media (max-width: 900px) { .gb-top { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ==================================================================
   交付中心 · 高级筛选 + 我的 AI 看板（2026-11-16）
   ------------------------------------------------------------------
   两块都是新加的，沿用 dvc- 前缀下的 dvcai- / dvc-adv 二级命名，
   避免和已有的 dvc-kpi / dvc-tab 撞车。
   ================================================================== */

/* ---------------- 高级筛选 ---------------- */
.dvc-advn { display: inline-block; margin-left: 5px; min-width: 16px; padding: 0 4px;
  border-radius: 8px; background: var(--primary); color: #fff; font-size: 10.5px;
  font-weight: 600; line-height: 16px; text-align: center; }
.dvc-advbar { display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  padding: 0 12px 10px; }
.dvc-advtag { display: inline-flex; align-items: center; gap: 5px; max-width: 320px;
  padding: 3px 6px 3px 9px; border-radius: 7px; background: var(--primary-soft);
  color: var(--primary-d); font-size: 12px; }
.dvc-advtag span, .dvc-advtag { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dvc-advtag i { font-style: normal; padding: 0 2px; color: var(--primary); opacity: .6; }
.dvc-advtag:hover i { opacity: 1; }

.dvc-adv-tip { font-size: 12px; color: var(--text-2); line-height: 1.75;
  background: #f7f9fd; border: 1px solid #e6ecf7; border-radius: 8px;
  padding: 9px 11px; margin-bottom: 12px; }
.dvc-adv-tip b { color: var(--text); }
.dvc-adv-rows { display: flex; flex-direction: column; gap: 8px; }
.dvc-advrow { display: flex; align-items: center; gap: 7px; }
.dvc-advrow .dvc-advf { width: 132px; flex: none; }
.dvc-advrow .dvc-advo2 { width: 108px; flex: none; }
.dvc-advrow .input { height: 34px; }
.dvc-advx { flex: none; width: 28px; height: 28px; border-radius: 6px; color: var(--muted);
  font-size: 17px; line-height: 1; }
.dvc-advx:hover { background: var(--danger-soft); color: var(--danger); }
.dvc-adv-empty { padding: 16px; text-align: center; font-size: 12.5px; color: var(--muted);
  border: 1px dashed var(--border); border-radius: 8px; }
.dvc-adv2 { display: flex; align-items: center; gap: 6px; }
.dvc-advpick { display: flex; flex-direction: column; gap: 6px; }
.dvc-advlist { display: flex; flex-wrap: wrap; gap: 5px; max-height: 150px; overflow: auto;
  padding: 7px; border: 1px solid var(--border); border-radius: 8px; background: #fcfdff; }
.dvc-advo { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px;
  border: 1px solid var(--border); border-radius: 6px; font-size: 12px; background: #fff; cursor: pointer; }
.dvc-advo.on { border-color: #bcd3fd; background: var(--primary-soft); color: var(--primary-d); font-weight: 500; }
.dvc-advo input { display: none; }
.dvc-adv-add { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.dvc-adv-add select { flex: 1; height: 34px; }
.dvc-adv-sec { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--border); }
.dvc-adv-sec h4 { font-size: 12.5px; font-weight: 600; color: var(--text-2); margin-bottom: 8px; }
.dvc-adv-sec select { width: 100%; max-width: 320px; height: 34px; }
.dvc-adv-saved { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 9px; min-height: 20px; }
.dvc-advsave { display: inline-flex; align-items: center; gap: 3px; font-size: 12.5px; }
.dvc-advsave i { font-style: normal; color: var(--muted); cursor: pointer; padding: 0 2px; }
.dvc-advsave i:hover { color: var(--danger); }
.dvc-adv-as { display: flex; gap: 8px; }
.dvc-adv-as .input { flex: 1; height: 34px; }

/* ---------------- 我的 AI 看板 ---------------- */
.dvcai { display: flex; flex-direction: column; gap: 12px; }
.dvcai-ranges { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.dvcai-rg { padding: 5px 13px; border-radius: 7px; font-size: 12.5px; color: var(--text-2);
  background: #f1f4f9; border: 1px solid transparent; }
.dvcai-rg.on { background: #fff; border-color: var(--border-strong); color: var(--text);
  font-weight: 500; box-shadow: var(--shadow); }
.dvcai-cust { display: inline-flex; align-items: center; gap: 5px; }
.dvcai-cust .input { height: 30px; width: 136px; }
.dvcai-cust i { font-style: normal; font-size: 12px; color: var(--muted); }

.dvcai-top { display: grid; grid-template-columns: 352px minmax(0, 1fr); gap: 12px; align-items: stretch; }
.dvcai-scorecard { display: flex; align-items: center; gap: 14px; padding: 14px 16px; }
.dvcai-score { display: flex; align-items: center; gap: 8px; flex: none; color: var(--primary); }
.dvcai-score.ok { color: #16a34a; }
.dvcai-score.good { color: #2563eb; }
.dvcai-score.warn { color: #d97706; }
.dvcai-score.bad { color: #dc2626; }
.dvcai-score svg { display: block; }
.dvcai-score > div { display: flex; flex-direction: column; }
.dvcai-score b { font-size: 22px; line-height: 1.1; letter-spacing: -.5px; }
.dvcai-score span { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.dvcai-scoreparts { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.dvcai-sp { display: grid; grid-template-columns: minmax(0, 1fr) 44px 20px; align-items: center; gap: 6px; }
.dvcai-sp > span { font-size: 11.5px; color: var(--text-2); white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; letter-spacing: -.2px; }
.dvcai-sp > span i { font-style: normal; font-size: 9.5px; color: var(--muted); margin-left: 2px; }
.dvcai-spbar { height: 5px; border-radius: 3px; background: #eef1f6; overflow: hidden; }
.dvcai-spbar i { display: block; height: 100%; border-radius: 3px; background: var(--primary); }
.dvcai-sp b { font-size: 11.5px; font-weight: 600; text-align: right; color: var(--text-2); }

.dvcai-kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; padding: 0; overflow: hidden; }
.dvcai-kpi { padding: 11px 13px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.dvcai-kpi:nth-child(3n) { border-right: none; }
.dvcai-kpi:nth-last-child(-n+3) { border-bottom: none; }
.dvcai-kpi > span { display: block; font-size: 11.5px; color: var(--muted); }
.dvcai-kpi > b { display: block; font-size: 21px; font-weight: 650; letter-spacing: -.4px; margin: 2px 0 1px; }
.dvcai-kpi > i { display: block; font-style: normal; font-size: 11px; color: var(--muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dvcai-kpi.green > b { color: #16a34a; }
.dvcai-kpi.amber > b { color: #d97706; }
.dvcai-kpi.red > b { color: #dc2626; }

.dvcai-trendcard { padding: 0; overflow: hidden; }
.dvcai-trendbody { padding: 12px 16px 10px; }
.dvcai-trend { display: flex; align-items: flex-end; gap: 3px;
  /* 画一条基线：没有单的日子柱子高度是 0，不留基线会被误读成图表坏了 */
  border-bottom: 1px solid var(--line); padding-bottom: 1px; }
.dvcai-col { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: flex-end;
  align-items: center; gap: 3px; }
.dvcai-col > em { font-style: normal; font-size: 10px; line-height: 1; color: var(--primary); font-weight: 600; }
.dvcai-bars { display: flex; align-items: flex-end; gap: 2px; width: 100%; height: 72px; }
.dvcai-bars i { flex: 1; min-height: 0; border-radius: 2px 2px 0 0; }
.dvcai-bars .c { background: #c7dcfb; }
.dvcai-bars .d { background: var(--primary); }
.dvcai-col > span { font-size: 9.5px; color: var(--muted); white-space: nowrap; }
.dvcai-legend { display: flex; align-items: center; gap: 5px; font-size: 11px; color: var(--muted); margin-top: 6px; }
.dvcai-legend i { width: 9px; height: 9px; border-radius: 2px; display: inline-block; }
.dvcai-legend i.c { background: #c7dcfb; }
.dvcai-legend i.d { background: var(--primary); margin-left: 8px; }

.dvcai-grid { display: grid; grid-template-columns: minmax(0, 1fr) 322px; gap: 12px; align-items: start; }
.dvcai-main, .dvcai-side { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.dvcai-card { padding: 0; overflow: hidden; }

.dvcai-issues { display: flex; flex-direction: column; }
.dvcai-issue { padding: 13px 16px; border-bottom: 1px solid var(--border); border-left: 3px solid transparent; }
.dvcai-issue:last-child { border-bottom: none; }
.dvcai-issue.danger { border-left-color: #dc2626; background: #fffafa; }
.dvcai-issue.warn { border-left-color: #d97706; background: #fffdf8; }
.dvcai-issue.info { border-left-color: #16a34a; }
.dvcai-issue-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.dvcai-issue-h b { font-size: 13.5px; font-weight: 600; }
.dvcai-issue p { font-size: 12.5px; color: var(--text-2); line-height: 1.7; margin-top: 4px; }
.dvcai-why { margin-top: 7px; font-size: 12px; color: #92400e; background: #fff8ec;
  border-radius: 7px; padding: 7px 9px; line-height: 1.65; }
.dvcai-why span { display: inline-block; font-weight: 600; margin-right: 6px; color: #b45309; }
.dvcai-acts { margin: 8px 0 0; padding-left: 18px; font-size: 12.5px; color: var(--text-2); line-height: 1.75; }
.dvcai-acts li { margin-top: 1px; }

.dvcai-todo { display: flex; flex-direction: column; }
.dvcai-todo-i { display: flex; align-items: center; gap: 11px; padding: 10px 16px; text-align: left;
  border-bottom: 1px solid var(--border); width: 100%; }
.dvcai-todo-i:last-child { border-bottom: none; }
.dvcai-todo-i:hover { background: #f8fafd; }
.dvcai-todo-n { flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--primary-soft);
  color: var(--primary-d); font-size: 11.5px; font-weight: 600; display: flex;
  align-items: center; justify-content: center; }
.dvcai-todo-i > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.dvcai-todo-i b { font-size: 12.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dvcai-todo-i span { font-size: 12px; color: var(--primary-d); }
.dvcai-todo-i em { font-style: normal; font-size: 11px; color: var(--muted); }
.dvcai-none { padding: 18px; text-align: center; font-size: 12.5px; color: var(--muted); }

.dvcai-rem { display: flex; flex-direction: column; max-height: 360px; overflow: auto; }
.dvcai-rem-i { display: flex; align-items: center; gap: 9px; padding: 8px 16px; text-align: left;
  border-bottom: 1px solid var(--border); }
.dvcai-rem-i:last-child { border-bottom: none; }
.dvcai-rem-i:hover { background: #f8fafd; }
.dvcai-rem-tag { flex: none; font-size: 11px; padding: 2px 7px; border-radius: 6px; font-weight: 500; }
.dvcai-rem-i.danger .dvcai-rem-tag { background: #fee2e2; color: #b91c1c; }
.dvcai-rem-i.warn .dvcai-rem-tag { background: #fef3c7; color: #92400e; }
.dvcai-rem-i > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.dvcai-rem-i b { font-size: 12.5px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dvcai-rem-i em { font-style: normal; font-size: 10.5px; color: var(--muted); }
.dvcai-rem-tip { flex: none; max-width: 42%; font-size: 11.5px; color: var(--muted); text-align: right; }

.dvcai-clusters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.dvcai-cl { padding: 11px 15px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.dvcai-cl:nth-child(2n) { border-right: none; }
.dvcai-cl b { font-size: 12.5px; font-weight: 600; display: block; }
.dvcai-cl > span { display: block; font-size: 11.5px; color: var(--text-2); margin-top: 3px; line-height: 1.6; }
.dvcai-cl p { font-size: 11.5px; color: var(--primary-d); background: var(--primary-soft);
  border-radius: 6px; padding: 6px 8px; margin: 6px 0 0; line-height: 1.6; }

.dvcai-goals { padding: 10px 16px 13px; display: flex; flex-direction: column; gap: 10px; }
.dvcai-goal { display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; align-items: center; }
.dvcai-goal > span { grid-column: 1 / 2; font-size: 12.5px; color: var(--text-2); }
.dvcai-goal > em { grid-column: 2 / 3; grid-row: 1; font-style: normal; font-size: 11.5px; color: var(--muted); }
.dvcai-goalbar { grid-column: 1 / 3; height: 6px; border-radius: 3px; background: #eef1f6; overflow: hidden; }
.dvcai-goalbar i { display: block; height: 100%; border-radius: 3px; background: var(--primary); }
.dvcai-goal.done .dvcai-goalbar i { background: #16a34a; }
.dvcai-goal.done > span { color: var(--text); font-weight: 500; }

.dvcai-cats { padding: 10px 16px 13px; display: flex; flex-direction: column; gap: 8px; }
.dvcai-cat { display: grid; grid-template-columns: 76px 1fr 28px; gap: 8px; align-items: center; }
.dvcai-cat > span { font-size: 12px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dvcai-catbar { height: 6px; border-radius: 3px; background: #eef1f6; overflow: hidden; }
.dvcai-catbar i { display: block; height: 100%; background: #7ba7f0; border-radius: 3px; }
.dvcai-cat b { font-size: 11.5px; font-weight: 600; text-align: right; }
.dvcai-cat em { grid-column: 3 / 4; font-style: normal; font-size: 10px; text-align: right; }

.dvcai-team { display: flex; flex-direction: column; }
.dvcai-tm { display: flex; align-items: center; gap: 8px; padding: 7px 16px;
  border-bottom: 1px solid var(--border); font-size: 11.5px; }
.dvcai-tm:last-child { border-bottom: none; }
.dvcai-tm b { flex: 1; font-size: 12.5px; font-weight: 500; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; }
.dvcai-tm.bad { background: #fffafa; }

.dvcai-chat { padding: 10px 14px; max-height: 300px; overflow: auto; display: flex;
  flex-direction: column; gap: 8px; }
.dvcai-hint { font-size: 11.5px; color: var(--muted); line-height: 1.8; }
.dvcai-msg { font-size: 12.5px; line-height: 1.75; padding: 8px 10px; border-radius: 9px; max-width: 100%; }
.dvcai-msg.me { background: var(--primary-soft); color: var(--primary-d); align-self: flex-end; }
.dvcai-msg.ai { background: #f5f7fa; color: var(--text-2); }
.dvcai-msg.loading { color: var(--muted); font-size: 12px; }
.dvcai-askbox { display: flex; gap: 7px; padding: 0 14px 14px; }
.dvcai-askbox .input { flex: 1; height: 34px; }

@media (max-width: 1180px) {
  .dvcai-top { grid-template-columns: 1fr; }
  .dvcai-grid { grid-template-columns: 1fr; }
  .dvcai-clusters { grid-template-columns: 1fr; }
  .dvcai-cl { border-right: none; }
}
@media (max-width: 900px) {
  .dvcai-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dvcai-kpi:nth-child(3n) { border-right: 1px solid var(--border); }
  .dvcai-kpi:nth-child(2n) { border-right: none; }
  .dvcai-kpi:nth-last-child(-n+3) { border-bottom: 1px solid var(--border); }
  .dvcai-kpi:nth-last-child(-n+2) { border-bottom: none; }
}

/* ---------------- 交付中心 · 申报指引 ---------------- */
.dvc-gd { display: grid; grid-template-columns: 288px minmax(0, 1fr); gap: 12px; align-items: start; }
.dvc-gd-side { padding: 0; overflow: hidden; display: flex; flex-direction: column;
  max-height: calc(100vh - 210px); }
.dvc-gd-search { padding: 10px 12px; border-bottom: 1px solid var(--border); }
.dvc-gd-search .input { height: 32px; }
.dvc-gd-cats { padding: 8px 10px; display: flex; flex-wrap: wrap; gap: 5px;
  border-bottom: 1px solid var(--border); }
.dvc-gd-cat { font-size: 11.5px; padding: 4px 8px; border-radius: 6px; color: var(--text-2);
  background: #f2f5fa; border: 1px solid transparent; white-space: nowrap; }
.dvc-gd-cat b { font-size: 10.5px; color: var(--muted); margin-left: 3px; font-weight: 500; }
.dvc-gd-cat.on { background: var(--primary-soft); border-color: #bcd3fd; color: var(--primary-d); font-weight: 600; }
.dvc-gd-cat.on b { color: var(--primary); }
.dvc-gd-list { overflow: auto; flex: 1; min-height: 120px; }
.dvc-gd-i { display: flex; flex-direction: column; gap: 1px; width: 100%; text-align: left;
  padding: 8px 12px; border-bottom: 1px solid #f2f4f8; }
.dvc-gd-i:hover { background: #f8fafd; }
.dvc-gd-i.on { background: var(--primary-soft); border-left: 3px solid var(--primary); padding-left: 9px; }
.dvc-gd-i b { font-size: 12.5px; font-weight: 500; line-height: 1.4; }
.dvc-gd-i.on b { color: var(--primary-d); font-weight: 600; }
.dvc-gd-i span { font-size: 10.5px; color: var(--muted); }
.dvc-gd-i em { font-style: normal; font-size: 10.5px; color: var(--muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dvc-gd-none { padding: 22px; text-align: center; font-size: 12px; color: var(--muted); }

.dvc-gd-main { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.dvc-gd-welcome { padding: 22px 24px; }
.dvc-gd-welcome h3 { font-size: 15px; font-weight: 600; margin-bottom: 6px; }
.dvc-gd-welcome > p { font-size: 12.5px; color: var(--text-2); line-height: 1.75; }
.dvc-gd-wgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 14px 0; }
.dvc-gd-wgrid > div { border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; background: #fcfdff; }
.dvc-gd-wgrid b { display: block; font-size: 12.5px; font-weight: 600; margin-bottom: 3px; }
.dvc-gd-wgrid span { font-size: 11.5px; color: var(--muted); line-height: 1.6; }

.dvc-gd-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px 16px; box-shadow: var(--shadow); }
.dvc-gd-title h3 { font-size: 15px; font-weight: 600; }
.dvc-gd-sub { font-size: 12px; color: var(--muted); margin-top: 3px; }
.dvc-gd-headact { display: flex; align-items: center; gap: 8px; flex: none; }
.dvc-gd-aging { font-size: 11.5px; color: #92400e; background: #fef3c7; border-radius: 6px; padding: 3px 8px; }

.dvc-gd-tabs { display: flex; gap: 3px; flex-wrap: wrap; background: #eef1f6;
  border-radius: 9px; padding: 3px; }
.dvc-gd-tab { padding: 6px 12px; border-radius: 7px; font-size: 12.5px; color: var(--text-2);
  display: inline-flex; align-items: center; gap: 4px; }
.dvc-gd-tab b { font-size: 10.5px; font-weight: 600; padding: 0 5px; border-radius: 8px;
  background: #e3e8f0; color: var(--muted); }
.dvc-gd-tab.on { background: #fff; color: var(--text); font-weight: 500; box-shadow: var(--shadow); }
.dvc-gd-tab.on b { background: var(--primary-soft); color: var(--primary); }

.dvc-gd-body { background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 18px; }
.dvc-gd-body:empty { display: none; }

.dvc-gd-sites { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; }
.dvc-gd-site { border: 1px solid var(--border); border-radius: 9px; padding: 11px 13px; background: #fcfdff; }
.dvc-gd-site-h { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.dvc-gd-role { font-size: 10.5px; padding: 1px 6px; border-radius: 5px;
  background: var(--primary-soft); color: var(--primary-d); }
.dvc-gd-site-h b { font-size: 12.5px; font-weight: 600; }
.dvc-gd-url { margin: 5px 0 3px; font-size: 11.5px; word-break: break-all; }
.dvc-gd-url a { color: var(--primary); }
.dvc-gd-site p { font-size: 11.5px; color: var(--muted); line-height: 1.6; }

.dvc-gd-block { margin-top: 16px; }
.dvc-gd-block:first-child { margin-top: 0; }
.dvc-gd-block h4 { font-size: 12.5px; font-weight: 600; color: var(--text-2); margin-bottom: 8px; }
.dvc-gd-path { margin: 0; padding-left: 0; list-style: none; counter-reset: gp;
  display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.dvc-gd-path li { counter-increment: gp; display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--text-2); background: #f2f5fa; border-radius: 7px; padding: 5px 10px; }
.dvc-gd-path li::before { content: counter(gp); width: 16px; height: 16px; border-radius: 50%;
  background: var(--primary); color: #fff; font-size: 10px; display: inline-flex;
  align-items: center; justify-content: center; flex: none; }
.dvc-gd-path li:not(:last-child)::after { content: '›'; color: var(--muted); margin-left: 2px; }
.dvc-gd-tip { margin-top: 8px; font-size: 12px; color: var(--text-2); background: #f7f9fd;
  border: 1px solid #e6ecf7; border-radius: 7px; padding: 8px 10px; line-height: 1.7; }
.dvc-gd-meta { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 14px;
  padding-top: 12px; border-top: 1px dashed var(--border); font-size: 12px; color: var(--muted); }
.dvc-gd-meta b { color: var(--text); font-weight: 500; }
.dvc-gd-warn { margin-top: 10px; font-size: 11px; color: var(--muted); line-height: 1.7; }

.dvc-gd-flow { display: flex; flex-direction: column; gap: 0; }
.dvc-gd-step { display: flex; gap: 11px; padding-bottom: 12px; position: relative; }
.dvc-gd-step:not(:last-child)::before { content: ''; position: absolute; left: 13px; top: 28px;
  bottom: 0; width: 1px; background: var(--border); }
.dvc-gd-step-n { flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--primary-soft);
  color: var(--primary-d); font-size: 11.5px; font-weight: 600; display: flex;
  align-items: center; justify-content: center; z-index: 1; }
.dvc-gd-step-b { flex: 1; min-width: 0; }
.dvc-gd-step-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.dvc-gd-step-h b { font-size: 12.5px; font-weight: 600; }
.dvc-gd-step-h em { font-style: normal; font-size: 11.5px; color: var(--muted); }
.dvc-gd-step-b p { font-size: 12px; color: var(--text-2); line-height: 1.65; margin-top: 3px; }
.dvc-gd-step-m { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 3px; }
.dvc-gd-step-m span { font-size: 10.5px; color: var(--muted); }

.dvc-gd-notices { display: flex; flex-direction: column; gap: 9px; }
.dvc-gd-notice { display: flex; gap: 10px; border: 1px solid var(--border);
  border-radius: 8px; padding: 10px 12px; background: #fcfdff; }
.dvc-gd-notice-n { flex: none; width: 22px; height: 22px; border-radius: 6px; background: #fef3c7;
  color: #92400e; font-size: 11px; font-weight: 600; display: flex; align-items: center; justify-content: center; }
.dvc-gd-notice b { font-size: 12.5px; font-weight: 600; }
.dvc-gd-notice p { font-size: 12px; color: var(--text-2); line-height: 1.7; margin-top: 3px; }
.dvc-gd-why, .dvc-gd-trap { margin-top: 6px; font-size: 11.5px; line-height: 1.65;
  border-radius: 6px; padding: 6px 8px; }
.dvc-gd-why { background: #fff8ec; color: #92400e; }
.dvc-gd-trap { background: #f4f6fa; color: var(--text-2); }
.dvc-gd-why i, .dvc-gd-trap i { font-style: normal; font-weight: 600; margin-right: 6px; }
.dvc-gd-why i { color: #b45309; }
.dvc-gd-trap i { color: var(--text); }

.dvc-gd-dept td { vertical-align: top; }
.dvc-gd-duty { font-size: 12px; color: var(--text-2); line-height: 1.6; max-width: 340px; }
.dvc-gd-hot { font-size: 13.5px; font-weight: 600; color: var(--primary-d); letter-spacing: .3px; }

.dvc-gd-faqbar { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.dvc-gd-faqbar .input { height: 32px; width: 280px; }
.dvc-gd-faqg { border: 1px solid var(--border); border-radius: 8px; margin-bottom: 8px; overflow: hidden; }
.dvc-gd-faqg summary { cursor: pointer; padding: 9px 12px; font-size: 12.5px; font-weight: 600;
  background: #f7f9fd; display: flex; align-items: center; justify-content: space-between; }
.dvc-gd-faqg summary span { font-size: 11px; font-weight: 500; color: var(--muted); }
.dvc-gd-faqs { padding: 4px 0; }
.dvc-gd-faq { padding: 9px 14px; border-top: 1px solid #f2f4f8; }
.dvc-gd-faq b { display: block; font-size: 12.5px; font-weight: 500; line-height: 1.6; }
.dvc-gd-faq b i { font-style: normal; display: inline-block; min-width: 20px; color: var(--muted);
  font-size: 11px; margin-right: 4px; }
.dvc-gd-faq p { font-size: 12px; color: var(--text-2); line-height: 1.7; margin-top: 3px; padding-left: 24px; }
.dvc-gd-faqtag { display: inline-block; margin: 4px 0 0 24px; font-size: 10.5px;
  background: #eef2f9; color: var(--muted); border-radius: 5px; padding: 1px 6px; }

.dvc-gd-risks { display: flex; flex-direction: column; gap: 8px; }
.dvc-gd-risk { display: flex; gap: 10px; border: 1px solid var(--border); border-radius: 8px;
  padding: 10px 12px; background: #fff; }
.dvc-gd-risk-n { flex: none; width: 24px; height: 24px; border-radius: 6px; background: #fee2e2;
  color: #b91c1c; font-size: 11px; font-weight: 600; display: flex; align-items: center; justify-content: center; }
.dvc-gd-risk-b { flex: 1; min-width: 0; }
.dvc-gd-risk-h { margin-bottom: 4px; }
.dvc-gd-risk-b p { font-size: 12px; color: var(--text-2); line-height: 1.65; margin-top: 2px; }
.dvc-gd-risk-b p b { display: inline-block; min-width: 42px; font-weight: 600; color: var(--text); margin-right: 4px; }
.dvc-gd-avoid { background: #f0fdf4; border-radius: 6px; padding: 5px 8px; }
.dvc-gd-avoid b { color: #15803d !important; }

/* 更正弹窗 */
.dvc-ge-sec { margin-bottom: 16px; }
.dvc-ge-sec h4 { font-size: 12.5px; font-weight: 600; color: var(--text-2); margin-bottom: 8px; }
.dvc-ge-row { display: flex; align-items: center; gap: 10px; margin-bottom: 7px; }
.dvc-ge-l { flex: none; width: 152px; font-size: 12px; color: var(--text-2);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dvc-ge-row .input { flex: 1; height: 32px; }
.dvc-ge-sec > .input, .dvc-ge-sec > textarea { width: 100%; }

@media (max-width: 1100px) {
  .dvc-gd { grid-template-columns: 1fr; }
  .dvc-gd-side { max-height: 300px; }
  .dvc-gd-wgrid { grid-template-columns: 1fr; }
}

/* ==================== 友商合作中心（coop） ==================== */
.coop-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.coop-filter { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; flex: 1; }
.coop-filter select, .coop-filter input { height: 34px; padding: 0 10px; border: 1px solid var(--border-strong, #d5dbe3);
  border-radius: 8px; font-size: 13px; background: #fff; color: var(--text, #1f2937); }
.coop-filter input { min-width: 200px; }
.coop-list { display: flex; flex-direction: column; gap: 10px; }
.coop-pager { display: flex; align-items: center; gap: 8px; margin-top: 12px; justify-content: flex-end; color: var(--muted, #6b7280); font-size: 12.5px; }

.coop-card { border: 1px solid var(--border, #e5e9f0); border-radius: 12px; padding: 14px 16px; background: #fff;
  cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.coop-card:hover { border-color: var(--primary, #2563eb); box-shadow: 0 2px 10px rgba(37, 99, 235, .07); }
.coop-card-h { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; flex-wrap: wrap; }
.coop-card-h b { font-size: 14.5px; font-weight: 600; color: var(--text, #1f2937); flex: 1; min-width: 0; }
.coop-type { flex: none; font-size: 11px; padding: 2px 8px; border-radius: 6px; background: #eef2f8; color: #4b5563; }
.coop-card-m { font-size: 12.8px; color: var(--text-2, #4b5563); line-height: 1.6; margin-bottom: 8px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.coop-card-f { display: flex; align-items: center; gap: 14px; font-size: 12px; color: var(--muted, #6b7280); flex-wrap: wrap; }
.coop-budget { color: #b91c1c; font-weight: 600; }
.coop-meta { margin-left: auto; }
.coop-card-a { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; padding-top: 10px;
  border-top: 1px solid var(--border, #eef1f5); font-size: 12px; color: var(--muted, #6b7280); }
.coop-card-btns { display: flex; align-items: center; gap: 8px; }

/* 任务详情抽屉 */
.coop-detail { display: flex; flex-direction: column; gap: 12px; }
.coop-detail-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.coop-detail-h h3 { font-size: 16px; font-weight: 600; color: var(--text, #1f2937); flex: 1; min-width: 0; }
.coop-detail-meta { font-size: 12.5px; color: var(--muted, #6b7280); display: flex; gap: 16px; flex-wrap: wrap; }
.coop-detail-row { display: flex; gap: 12px; font-size: 13px; line-height: 1.7; }
.coop-detail-row > span { flex: none; width: 56px; color: var(--muted, #6b7280); }
.coop-detail-ext { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; background: #fafbfd; border-radius: 8px; }
.coop-detail-ext > div { display: flex; gap: 12px; font-size: 12.5px; }
.coop-detail-ext span { flex: none; width: 80px; color: var(--muted, #6b7280); }
.coop-contact { border: 1px dashed var(--border-strong, #c7d2fe); border-radius: 10px; padding: 12px 14px; background: #f8faff; }
.coop-contact.unlocked { border-style: solid; border-color: #22b07d; background: #f0faf6; }
.coop-contact-t { font-size: 12px; font-weight: 600; color: var(--text-2, #4b5563); margin-bottom: 8px; }
.coop-contact.unlocked .coop-contact-t { color: #15803d; }
.coop-contact-row { display: flex; gap: 12px; font-size: 13px; padding: 3px 0; }
.coop-contact-row span { flex: none; width: 40px; color: var(--muted, #6b7280); }
.coop-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }

/* 任务附件 */
.coop-att { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; background: #f8fafc; margin-bottom: 6px; }
.coop-att-name { font-size: 13px; color: var(--primary, #2563eb); text-decoration: none; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.coop-att-name:hover { text-decoration: underline; }
.coop-att-meta { font-size: 11.5px; color: var(--muted, #6b7280); flex: none; }


/* 接单申请 */
.coop-offer { border: 1px solid var(--border, #e5e9f0); border-radius: 10px; padding: 12px 14px; margin-bottom: 10px; }
.coop-offer.pending { border-color: #fcd34d; background: #fffbeb; }
.coop-offer-h { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.coop-offer-h b { font-size: 13.5px; font-weight: 600; }
.coop-offer-i { font-size: 12.5px; color: var(--text-2, #4b5563); margin-bottom: 8px; }

/* 留言 */
.coop-msg-list { max-height: 280px; overflow-y: auto; margin-bottom: 12px; }
.coop-msg { padding: 10px 12px; border-radius: 8px; background: #f8fafc; margin-bottom: 8px; }
.coop-msg b { font-size: 12.5px; font-weight: 600; color: var(--text, #1f2937); margin-right: 8px; }
.coop-msg span { font-size: 11px; color: var(--muted, #6b7280); }
.coop-msg p { margin: 4px 0 0; font-size: 13px; line-height: 1.6; }

/* 资源共创 */
.coop-resource .coop-sec-h { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.coop-sec-h h3 { font-size: 15px; font-weight: 600; }
.coop-sec-h h4 { font-size: 13.5px; font-weight: 600; }
.coop-sec-desc { font-size: 12.5px; color: var(--muted, #6b7280); margin-bottom: 12px; }

/* 交付流程时间轴 */
.coop-timeline { display: flex; align-items: flex-start; gap: 0; padding: 10px 0 4px; flex-wrap: wrap; }
.coop-tl-step { display: flex; flex-direction: column; align-items: center; gap: 5px; min-width: 72px; position: relative; }
.coop-tl-step::before { content: ''; position: absolute; top: 6px; left: -50%; width: 100%; height: 2px; background: #e5e9f0; z-index: 0; }
.coop-tl-step:first-child::before { display: none; }
.coop-tl-step .coop-tl-dot { width: 12px; height: 12px; border-radius: 50%; background: #e5e9f0; border: 2px solid #fff; box-shadow: 0 0 0 2px #e5e9f0; z-index: 1; }
.coop-tl-step .coop-tl-name { font-size: 11.5px; color: #9ca3af; }
.coop-tl-step.done::before { background: var(--primary, #2563eb); }
.coop-tl-step.done .coop-tl-dot { background: var(--primary, #2563eb); box-shadow: 0 0 0 2px var(--primary, #2563eb); }
.coop-tl-step.done .coop-tl-name { color: var(--primary, #2563eb); }
.coop-tl-step.current .coop-tl-dot { background: #fff; box-shadow: 0 0 0 2px var(--primary, #2563eb); }
.coop-tl-step.current .coop-tl-name { color: var(--text-1, #111827); font-weight: 600; }
.coop-timeline.canceled .coop-tl-note,
.coop-timeline.dispute .coop-tl-note { color: #b91c1c; }
.coop-tl-note { width: 100%; font-size: 12px; margin-top: 6px; color: #b91c1c; }

/* 业务派单：对应业务官方交付流程 */
.coop-bizflow { margin: 6px 0 2px; padding: 10px 12px; background: #f5f8ff; border: 1px solid #e0e8fb; border-radius: 8px; }
.coop-bizflow-h { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.coop-bizflow .coop-timeline.biz { flex-direction: column; align-items: stretch; gap: 6px; padding: 4px 0 0; flex-wrap: nowrap; }
.coop-bizflow .coop-timeline.biz .coop-tl-step { flex-direction: row; align-items: center; gap: 8px; min-width: 0; }
.coop-bizflow .coop-timeline.biz .coop-tl-step::before { left: 5px; top: -9px; width: 2px; height: 20px; }
.coop-bizflow .coop-tl-step .coop-tl-name { color: #374151; font-size: 12.5px; }
.coop-bizflow .coop-tl-sub { font-size: 11px; color: #9ca3af; margin-left: auto; }

@media (max-width: 720px) {
  .coop-g-stats { grid-template-columns: 1fr; }
  .coop-filter input { min-width: 0; width: 100%; }
}

/* ============ AI 消耗统计（员工 × 板块） ============ */
.aub-board th, .aub-board td { white-space: nowrap; }
.aub-board .aub-fix { position: sticky; left: 0; background: #fff; z-index: 1; }
.aub-board thead .aub-fix { z-index: 2; background: #f8fafc; }
.aub-board .aub-col { min-width: 74px; }
.aub-board .aub-n { font-weight: 600; color: var(--text-1, #111827); }
.aub-board .aub-t { display: block; font-size: 11px; color: var(--muted, #6b7280); font-weight: 400; }


/* ==================== AI 外出拜访助手 ==================== */
.va-result-head { margin-top: 16px; }
.va-result-head .card-head { flex-wrap: wrap; gap: 8px; }
.sub-h { font-weight: 600; font-size: 13px; color: var(--text-1, #111827); margin: 14px 0 6px; }
.sub-h:first-child { margin-top: 0; }
.kv-row { display: flex; gap: 24px; flex-wrap: wrap; margin-bottom: 6px; }
.kv { min-width: 140px; }
.kv label { display: block; font-size: 11px; color: var(--muted, #6b7280); margin-bottom: 2px; }
.kv b { font-size: 14px; font-weight: 600; }
.va-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.va-biz { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 4px; }
ul.dot { margin: 6px 0; padding-left: 18px; }
ul.dot li { font-size: 13px; line-height: 1.7; margin: 3px 0; }
.va-sop { display: flex; flex-direction: column; gap: 10px; }
.va-sop-item { display: flex; gap: 10px; align-items: flex-start; }
.va-sop-label { flex: none; font-size: 11.5px; font-weight: 600; color: var(--primary, #2563eb); background: var(--primary-soft, #eef2ff); padding: 2px 9px; border-radius: 5px; margin-top: 2px; white-space: nowrap; }
.va-sop-body { font-size: 13px; line-height: 1.7; color: var(--text-2, #374151); min-width: 0; }
.va-script-block { border-bottom: 1px dashed var(--line, #e5e7eb); padding: 8px 0; }
.va-script-block:last-child { border-bottom: none; }
.va-script { font-size: 13px; line-height: 1.75; margin: 4px 0; }
.va-script.warn { color: var(--danger, #dc2626); }
.va-obj { background: var(--bg-soft, #f8fafc); border-radius: 8px; padding: 10px 12px; margin: 8px 0; }
.va-obj b { color: var(--text-1, #111827); }
.va-plans { display: flex; flex-direction: column; gap: 12px; }
.va-plan { border: 1px solid var(--line, #e5e7eb); border-radius: 10px; padding: 12px 14px; }
.va-plan-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.va-plan-head b { font-size: 14px; }
.va-plan-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 20px; }
.va-plan-grid label { display: block; font-size: 11px; color: var(--muted, #6b7280); margin-bottom: 1px; }
.va-plan-grid span { font-size: 13px; line-height: 1.6; }
.money { color: var(--primary, #2563eb); font-weight: 600; }
.va-ask { display: flex; gap: 8px; }
.va-ask .fin { flex: 1; }
.va-ask-out { margin-top: 10px; }
.va-ask-ans { background: var(--bg-soft, #f8fafc); border-left: 3px solid var(--primary, #2563eb); border-radius: 6px; padding: 10px 12px; font-size: 13px; line-height: 1.7; }
.va-ask-q { color: var(--muted, #6b7280); font-size: 12px; margin-bottom: 6px; }
.va-plan-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line, #e5e7eb); }
.va-plan-row:last-child { border-bottom: none; }
.va-plan-actions { display: flex; gap: 6px; flex: none; }
.va-modal-body { max-height: 72vh; overflow: auto; padding-right: 4px; }
.danger { color: var(--danger, #dc2626); }
.warn { color: var(--warn, #d97706); }

/* ==================== AI 申报方案计划书（PC） ==================== */
.sb-flow { display: flex; flex-direction: column; gap: 12px; padding: 4px 2px 20px; }
.sb-steps { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted, #6b7280); }
.sb-steps span { padding: 4px 12px; border-radius: 14px; background: var(--bg-soft, #f3f5f8); }
.sb-steps span.on { background: var(--primary, #2563eb); color: #fff; font-weight: 600; }
.sb-steps i { font-style: normal; color: #cbd5e1; }
.sb-kinds { display: flex; gap: 6px; flex-wrap: wrap; }
.sb-kind { font-size: 11px; padding: 2px 8px; border-radius: 10px; }
.sb-kind-a { background: #eff6ff; color: #1d4ed8; }
.sb-kind-b { background: #fef3c7; color: #b45309; }
.sb-kind-c { background: #ecfdf5; color: #047857; }
.sb-sec { background: #fff; border: 1px solid var(--border, #e5e7eb); border-radius: 8px; padding: 12px 14px; }
.sb-sec-h { font-size: 14px; font-weight: 600; margin-bottom: 10px; color: var(--text-1, #1f2937); }
.sb-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.sb-grid .field { margin: 0; }
.sb-pick { position: relative; }
.sb-pick input { width: 100%; box-sizing: border-box; }
.sb-pick-list {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 30; margin-top: 4px;
  max-height: 220px; overflow-y: auto; background: #fff; border: 1px solid var(--border, #e5e7eb);
  border-radius: 8px; box-shadow: 0 8px 24px rgba(16, 24, 40, .12); display: none;
}
.sb-pick-item { padding: 8px 12px; font-size: 13px; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.sb-pick-item:hover { background: var(--bg-soft, #f3f5f8); }
.sb-pick-item.on { background: var(--primary-soft, #eff6ff); color: var(--primary, #2563eb); }
.sb-pick-item i { font-style: normal; font-size: 11.5px; color: var(--muted, #6b7280); flex: none; }
.sb-pick-empty { padding: 12px; font-size: 12.5px; color: var(--muted, #6b7280); text-align: center; }
.sb-pick-hint { font-size: 12px; color: var(--muted, #6b7280); margin-top: 4px; cursor: pointer; }
.sb-pick-hint:hover { color: var(--primary, #2563eb); }
.sb-hint { font-size: 13px; color: var(--muted, #6b7280); line-height: 1.7; }
.sb-sec-sub { font-size: 12.5px; color: var(--muted, #6b7280); margin: -4px 0 10px; line-height: 1.6; }
.sb-q-row { display: flex; align-items: center; gap: 12px; padding: 6px 0; border-bottom: 1px dashed #eef1f5; font-size: 13px; }
.sb-q-row:last-child { border-bottom: none; }
.sb-q-label { flex: 1; min-width: 0; color: var(--text-2, #4b5563); line-height: 1.55; }
.sb-q-req { color: var(--danger, #dc2626); margin-left: 2px; }
.sb-q-row > [data-sb-q] { flex: none; width: 220px; display: flex; align-items: center; gap: 6px; }
.sb-q-row > [data-sb-q] select, .sb-q-row > [data-sb-q] input { width: 100%; box-sizing: border-box; }
.sb-q-unit { font-size: 12px; color: var(--muted, #6b7280); flex: none; }
.sb-q-ms { flex: 1; display: flex; flex-wrap: wrap; gap: 6px 14px; }
.sb-q-chk { display: flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--text-2, #4b5563); cursor: pointer; }
.sb-q-chk input { margin: 0; }
.sb-qg { margin-bottom: 12px; }
.sb-qg-h { font-size: 13px; font-weight: 600; color: var(--text-2, #4b5563); margin-bottom: 6px; }
.sb-q-item { display: flex; align-items: flex-start; gap: 8px; padding: 5px 0; font-size: 13px; line-height: 1.6; }
.sb-q-item .sb-q-sel { flex: none; width: 96px; font-size: 12px; }
.sb-dim { border: 1px solid var(--line, #e5e7eb); border-radius: 6px; padding: 10px 12px; margin-bottom: 8px; }
.sb-dim-h { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.sb-dim-h b { color: var(--text-1, #1f2937); }
.sb-dim-w { font-size: 12px; color: var(--primary, #2563eb); }
.sb-dim-d { font-size: 12px; color: var(--muted, #6b7280); margin: 4px 0 6px; }
.sb-dim-in input { font-size: 13px; }
.sb-score-bar { padding: 10px 14px; border-radius: 8px; font-size: 14px; font-weight: 500; }
.sb-score-bar b { font-size: 20px; }
.sb-score-bar.ok { background: #ecfdf5; color: #047857; }
.sb-score-bar.mid { background: #fffbeb; color: #b45309; }
.sb-score-bar.low { background: #fef2f2; color: #b91c1c; }
.sb-score-bar .sb-v { float: right; font-size: 12px; color: var(--muted, #6b7280); }
.sb-report { display: flex; flex-direction: column; gap: 14px; }
.sb-report-sec { background: #fff; border: 1px solid var(--border, #e5e7eb); border-radius: 8px; padding: 14px 16px; }
.sb-sec-t { font-size: 15px; font-weight: 700; color: var(--text-1, #1f2937); margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px solid #f1f5f9; }
.sb-p { font-size: 13px; line-height: 1.75; color: var(--text-2, #4b5563); margin: 0 0 8px; text-align: justify; }
.sb-kv { width: 100%; border-collapse: collapse; font-size: 13px; margin: 4px 0 8px; }
.sb-kv th { width: 22%; text-align: left; font-weight: 500; color: #5b6577; background: #fafbfc; padding: 7px 10px; border: 1px solid var(--line, #e5e7eb); vertical-align: top; }
.sb-kv td { padding: 7px 10px; border: 1px solid var(--line, #e5e7eb); line-height: 1.65; }
.sb-tb { width: 100%; border-collapse: collapse; font-size: 12.5px; margin: 4px 0 8px; }
.sb-tb th { background: #f3f5f8; text-align: left; font-weight: 600; padding: 7px 10px; border: 1px solid var(--line, #e5e7eb); }
.sb-tb td { padding: 7px 10px; border: 1px solid var(--line, #e5e7eb); line-height: 1.6; vertical-align: top; }
.sb-tb .num { text-align: center; }
.sb-ul, .sb-ol { margin: 0 0 8px; padding-left: 20px; font-size: 13px; line-height: 1.7; }
.sb-ul li, .sb-ol li { margin-bottom: 3px; }
.sb-lbl { font-size: 12px; font-weight: 600; color: #374151; margin: 8px 0 4px; }
.sb-co { border-radius: 6px; padding: 10px 12px; margin: 4px 0 8px; border-left: 3.5px solid; }
.sb-co-h { font-size: 13px; font-weight: 700; margin-bottom: 4px; }
.sb-co-b { font-size: 12.5px; line-height: 1.7; }
.sb-co-info { background: #eff6ff; border-left-color: #2563eb; color: #1e3a8a; }
.sb-co-warn { background: #fffbeb; border-left-color: #d97706; color: #78350f; }
.sb-co-danger { background: #fef2f2; border-left-color: #dc2626; color: #7f1d1d; }
.sb-foot { display: flex; gap: 8px; justify-content: flex-end; padding-top: 12px; border-top: 1px solid var(--line, #e5e7eb); }
.sb-hist-list { display: flex; flex-direction: column; gap: 10px; }
.sb-hist-card { background: #fff; border: 1px solid var(--border, #e5e7eb); border-radius: 8px; padding: 12px 14px; }
.sb-hist-h { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 14px; }
.sb-hist-m { font-size: 12px; color: var(--muted, #6b7280); margin: 4px 0; }
.sb-hist-s { font-size: 12px; color: var(--text-2, #4b5563); }
.sb-hist-a { display: flex; gap: 6px; margin-top: 8px; }


/* ---------- AI 外出拜访助手（2026-11-18 返工：议程 / 事实卡 / 阶段动作） ---------- */
.va-agenda { display: flex; flex-wrap: wrap; gap: 8px; }
.va-ag { display: flex; align-items: center; gap: 6px; font-size: 12px; background: #f8fafc;
  border: 1px solid var(--line, #e5e7eb); border-radius: 6px; padding: 5px 10px; }
.va-ag b { color: #2563eb; font-variant-numeric: tabular-nums; font-weight: 600; }
.va-ag span { color: #374151; }

.va-kv4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 14px; }
.va-kv4 > div, .va-kv2 > div { min-width: 0; }
.va-kv4 label, .va-kv2 label { display: block; font-size: 11.5px; color: #6b7280; margin-bottom: 2px; }
.va-kv4 b { font-size: 13px; font-weight: 600; color: #111827; }
.va-kv2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 14px; }
.va-kv2 span { font-size: 12.5px; line-height: 1.65; color: #374151; }

.va-attach { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }

/* SOP 从「左标签 + 右一段话」改成纵向卡片：目标 / 动作清单 / 判断标准 */
.va-sop-item { display: block; border: 1px solid var(--line, #e5e7eb); border-radius: 8px;
  padding: 10px 12px; background: #fff; }
.va-sop-item .va-sop-label { margin-bottom: 6px; display: block; background: none; padding: 0;
  color: #111827; font-size: 13px; white-space: normal; }
.va-sop-goal { font-size: 12.5px; color: #374151; background: #f8fafc;
  border-left: 3px solid #2563eb; padding: 5px 9px; border-radius: 4px; margin: 0 0 7px; }
.va-sop-item ul.dot { margin: 0 0 6px 16px; padding: 0; }
.va-sop-item ul.dot li { font-size: 12.5px; line-height: 1.7; color: #374151; margin-bottom: 3px; }
.va-sop-item .tiny { line-height: 1.65; }

@media (max-width: 1200px) { .va-kv4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* 多选勾选组（拜访目标 / 携带资料）：flex-wrap 会让每行起止参差不齐，
   改成固定 3 列网格，勾选框纵向对齐，扫一眼就知道漏了哪项 */
.va-checks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 14px; padding: 4px 0; }
.va-checks > label { display: flex; align-items: flex-start; gap: 6px; font-size: 12.5px;
  line-height: 1.55; color: #374151; cursor: pointer; min-width: 0; }
.va-checks > label input[type=checkbox] { width: 15px; height: 15px; min-width: 15px; flex: none; margin: 3px 0 0;
  accent-color: var(--primary); }
/* 文字必须有自己的盒子：直接写成 label 里的裸文本时，它是匿名 flex 项，
   会被压到「一个字的宽度」然后每行两个字地折行（实测只有 18px 宽，折成 8 行） */
.va-checks > label > span { flex: 1 1 auto; min-width: 0; }
@media (max-width: 1320px) { .va-checks { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------------- 数据源接入（平台预留模块） ---------------- */
/* 卡片网格：minmax(0,1fr) 是必须的，纯 1fr 会被长接口地址撑破，整列溢出 */
.ds-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); margin-bottom: 6px; }
.ds-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px 15px 12px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.ds-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.ds-name { font-size: 14.5px; font-weight: 600; color: var(--text); margin-bottom: 2px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-addr { font-size: 12px; color: var(--text-2); background: var(--bg); border: 1px solid var(--border);
  border-radius: 6px; padding: 6px 8px; font-family: var(--mono, ui-monospace, monospace);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-meta { display: flex; gap: 14px; font-size: 12px; color: var(--muted); }
.ds-err { font-size: 12px; color: var(--danger); background: var(--danger-soft); border-radius: 6px;
  padding: 5px 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-acts { display: flex; gap: 8px; margin-top: 2px; }
.ds-acts .btn { flex: none; }
.ds-tenant-list { max-height: 170px; overflow: auto; border: 1px solid var(--border);
  border-radius: 8px; padding: 8px 10px; background: var(--bg); }
.ds-tenant-list .ck { margin: 5px 0; }

.form-row2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.map-grid2 { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px 14px; }
@media (max-width: 760px) { .form-row2 { grid-template-columns: minmax(0, 1fr); } }
/* 复选框行：文字单独一个 span，别写成裸文本（会被 flex 压成一字宽折行） */
.ck { display: flex; align-items: flex-start; gap: 7px; font-size: 13px; line-height: 1.6; margin: 3px 0; }
.ck > input[type=checkbox] { width: auto; flex: none; margin: 3px 0 0; }
.ck > span { flex: 1 1 auto; min-width: 0; }
/* 空状态：比通用 .empty 紧凑，避免页面上出现一大片空白 */
.ds-empty { background: var(--card); border: 1px dashed var(--border-strong); border-radius: var(--radius);
  padding: 26px 20px; text-align: center; margin-bottom: 6px; }

/* ---------------- 通用搜索下拉（选客户 / 选成交订单） ---------------- */
/* 全站选客户统一用它：原来 <select> 铺几百条要滚半天，上万客户根本没法用 */
.pk { position: relative; width: 100%; }
.pk-box {
  display: flex; align-items: center; gap: 7px; min-height: 38px;
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  background: #fff; padding: 0 10px; transition: border-color .15s, box-shadow .15s;
}
.pk-box:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, .1); }
.pk-ico { color: var(--muted); display: flex; flex: none; }
.pk-input {
  flex: 1 1 auto; min-width: 0; width: 100% !important;
  border: none !important; outline: none; background: transparent !important;
  padding: 8px 0 !important; font-size: 13.5px; box-shadow: none !important;
}
.pk-input::placeholder { color: #a3aab6; }
.pk.has-val .pk-input { color: var(--text); font-weight: 500; }
.pk-clear {
  flex: none; width: 20px; height: 20px; border-radius: 50%; color: var(--muted);
  font-size: 15px; line-height: 1; display: grid; place-items: center;
}
.pk-clear:hover { background: #f1f5f9; color: var(--text); }

.pk-drop {
  position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 40;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); overflow: hidden;
  display: flex; flex-direction: column;
}
.pk-drop[hidden] { display: none; }
.pk-drop.up { top: auto; bottom: calc(100% + 4px); }
.pk-list { flex: 1 1 auto; min-height: 0; max-height: 264px; overflow-y: auto; padding: 4px; }
.pk-item {
  display: flex; align-items: center; gap: 8px; width: 100%; text-align: left;
  padding: 7px 9px; border-radius: 6px; font-size: 13px; color: var(--text);
}
.pk-item:hover, .pk-item.on { background: var(--primary-soft); }
.pk-name { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pk-sub { flex: none; font-size: 11.5px; color: var(--muted); }
.pk-tail { flex: none; font-size: 11.5px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.pk-item.pk-none { color: var(--muted); border-bottom: 1px dashed var(--border); border-radius: 0; margin-bottom: 2px; }
.pk-empty { padding: 16px 10px; text-align: center; font-size: 12.5px; color: var(--muted); }
.pk-foot { padding: 0 10px; font-size: 11.5px; color: var(--muted); }
.pk-foot:not(:empty) { padding: 7px 10px; border-top: 1px solid var(--border); background: #fafbfc; }

/* ---------------- 业务类型：分类下拉多选 ---------------- */
/* 117 个业务类型全铺开一屏塞不下，改成「分类 + 勾选」，只显示当前分类 */
.bzp { position: relative; }
.bzp-trigger {
  display: flex; align-items: center; gap: 8px; width: 100%; min-height: 38px;
  border: 1px dashed var(--border-strong); border-radius: var(--radius-sm); background: #fff;
  padding: 7px 10px; font-size: 13.5px; color: var(--text-2); text-align: left;
}
.bzp-trigger:hover { border-color: #bcd0f7; background: #fafcff; }
.bzp-trigger .bzp-plus { font-size: 15px; color: var(--primary); font-weight: 500; }
.bzp-trigger .bzp-count { margin-left: auto; font-size: 12px; color: var(--primary); }
.bzp-panel {
  position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 40;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); display: flex; flex-direction: column; max-height: 380px;
}
.bzp-panel[hidden] { display: none; }
.bzp-top { padding: 8px; border-bottom: 1px solid var(--border); }
.bzp-search {
  width: 100% !important; height: 32px; border: 1px solid var(--border-strong) !important;
  border-radius: 6px; padding: 0 9px !important; font-size: 13px;
}
.bzp-body { display: grid; grid-template-columns: 116px minmax(0, 1fr); min-height: 200px; flex: 1 1 auto; overflow: hidden; }
.bzp-cats { border-right: 1px solid var(--border); overflow-y: auto; background: #fafbfc; padding: 4px; }
.bzp-cat {
  display: flex; align-items: center; justify-content: space-between; gap: 4px;
  width: 100%; padding: 7px 8px; border-radius: 6px; font-size: 12.5px; color: var(--text-2); text-align: left;
}
.bzp-cat:hover { background: #f1f5f9; }
.bzp-cat.on { background: var(--primary-soft); color: var(--primary); font-weight: 500; }
.bzp-cat em { font-style: normal; font-size: 11px; color: var(--muted); }
.bzp-items { overflow-y: auto; padding: 6px; display: flex; flex-direction: column; gap: 2px; }
.bzp-item {
  display: flex; align-items: center; gap: 8px; width: 100%; text-align: left;
  padding: 7px 8px; border-radius: 6px; font-size: 13px;
}
.bzp-item:hover { background: #f6f8fb; }
.bzp-item.on { background: var(--primary-soft); }
.bzp-item .bzp-check {
  width: 15px; height: 15px; flex: none; border: 1.5px solid var(--border-strong); border-radius: 4px;
  display: grid; place-items: center; background: #fff; color: #fff;
}
.bzp-item.on .bzp-check { background: var(--primary); border-color: var(--primary); }
.bzp-item .bzp-nm { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bzp-item .bzp-cost { flex: none; font-size: 11.5px; color: var(--muted); }
.bzp-empty { padding: 22px 10px; text-align: center; font-size: 12.5px; color: var(--muted); }
.bzp-foot {
  display: flex; align-items: center; gap: 8px; padding: 7px 10px;
  border-top: 1px solid var(--border); background: #fafbfc; font-size: 12px; color: var(--muted);
}
.bzp-foot .spacer { flex: 1; }
.bzp-selected { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.bzp-chip {
  display: inline-flex; align-items: center; gap: 6px; max-width: 100%;
  background: var(--primary-soft); color: #1e40af; border: 1px solid #cddcff;
  border-radius: 999px; padding: 3px 6px 3px 10px; font-size: 12.5px;
}
.bzp-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bzp-chip button {
  width: 16px; height: 16px; border-radius: 50%; display: grid; place-items: center;
  color: #5b7cc9; font-size: 13px; line-height: 1; flex: none;
}
.bzp-chip button:hover { background: #dbe7ff; color: #1e40af; }

@media (max-width: 760px) {
  .bzp-body { grid-template-columns: 96px minmax(0, 1fr); }
  .bzp-panel { max-height: 60vh; }
  .pk-drop { max-width: 100%; }
}
.pk.is-disabled .pk-box { background: #f7f8fa; border-color: var(--border); }
.pk.is-disabled .pk-input { color: var(--text-2); cursor: default; }

/* ---------------- 数据复盘：员工跟进明细下钻 ---------------- */
.fd-hint { margin-left: 6px; font-size: 11px; color: var(--muted); }
.fd-sum { margin-bottom: 10px; }
.fd-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin-bottom: 8px; }
.fd-kpi { background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; text-align: center; }
.fd-kpi b { display: block; font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
.fd-kpi span { font-size: 11.5px; color: var(--muted); }
.fd-range { font-size: 12px; color: var(--muted); }
.fd-list { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.fd-row { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 10px;
  padding: 10px 12px; border-bottom: 1px solid var(--border); }
.fd-row:last-child { border-bottom: 0; }
.fd-row:hover { background: #fafbfc; }
.fd-time { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; padding-top: 2px; }
.fd-line { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 3px; }
.fd-cust { font-size: 13px; font-weight: 500; }
.fd-txt { font-size: 13px; color: var(--text-2); line-height: 1.6; word-break: break-word; }
.fd-next { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.fd-more { text-align: center; margin-top: 10px; }
@media (max-width: 760px) {
  .fd-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .fd-row { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .fd-time { padding-top: 0; }
}
/* 从看板下钻到明细页时的返回条 */
.back-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; padding: 8px 10px;
  background: var(--primary-soft); border: 1px solid #dbe7ff; border-radius: 8px; }
.back-bar .tiny { flex: 1 1 auto; min-width: 0; }

/* ---------- AI 知识库 · 两级分类导航（2026-11-22） ----------
   一级 12 个、二级 8~14 个，原来的单行 .tabs 会把后面几类滚出屏幕，
   所以这里用可换行的 chip 网格，不依赖横向滚动。 */
.kbnav { margin-bottom: 14px; }
.kbnav-row { display: flex; flex-wrap: wrap; gap: 6px; }
.kbnav-sub { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; padding: 10px 12px;
  background: #f7f8fa; border: 1px solid var(--border); border-radius: 10px; }
.kbnav-sub .kbchip { background: #fff; }
.kbchip { display: inline-flex; align-items: center; gap: 5px; padding: 6px 11px;
  border: 1px solid var(--border); border-radius: 8px; background: #fff;
  font-size: 12.5px; color: var(--text-2); cursor: pointer; white-space: nowrap;
  transition: border-color .15s, color .15s, background .15s; }
.kbnav-row .kbchip { font-size: 13px; font-weight: 500; padding: 7px 12px; }
.kbchip:hover { border-color: var(--primary); color: var(--primary); }
.kbchip.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.kbchip.on b { color: #fff; opacity: .85; }
.kbchip b { font-size: 11px; font-weight: 600; color: var(--muted); }
.kbchip .kbchip-ic { font-size: 14px; line-height: 1; }
.kbnav-tip { font-size: 12px; color: var(--muted); margin-top: 8px; }

/* 成交案例草稿条（订单办结自动生成的 pending 草稿，等主管补三句话）
   刻意做成一条浅色提示带而不是卡片：它不是主功能，是一个「待办」。 */
.kb-draft {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 12px; padding: 9px 12px;
  background: #fdf7ec; border: 1px solid #f3e3c6; border-radius: 8px;
  font-size: 12.5px; color: #8a5a12;
}
.kb-draft .kbd-ic { font-size: 14px; line-height: 1; }
.kb-draft .kbd-txt { flex: 1; min-width: 0; line-height: 1.5; }
.kb-draft .kbd-txt b { color: #a8630a; font-weight: 700; }
.kb-draft .btn { flex: none; }

/* ---------- AI 知识库 · 正文 Markdown 排版 ----------
   知识库正文统一用 Markdown 写（表格/清单/加粗/引用），这里给一套阅读友好的排版。
   原来 renderBody 只认"短行当小标题"，表格和列表全挤成一坨。 */
.kb-body h2 { font-size: 16.5px; font-weight: 700; margin: 22px 0 10px; padding-left: 9px;
  border-left: 3px solid var(--primary); line-height: 1.4; color: var(--text); }
.kb-body h2:first-child { margin-top: 0; }
.kb-body h3 { font-size: 14.5px; font-weight: 600; margin: 16px 0 7px; color: var(--text); }
.kb-body p { margin: 0 0 10px; line-height: 1.85; color: var(--text-2); word-break: break-word; }
.kb-body strong { color: var(--text); font-weight: 600; }
.kb-body ul, .kb-body ol { margin: 0 0 12px; padding-left: 22px; }
.kb-body li { line-height: 1.85; margin-bottom: 5px; color: var(--text-2); word-break: break-word; }
.kb-body li::marker { color: var(--primary); }
.kb-body blockquote { margin: 10px 0 14px; padding: 10px 14px; background: #f7f9fc;
  border-left: 3px solid #b9cdf5; border-radius: 0 8px 8px 0; color: var(--text-2); }
.kb-body blockquote p { margin: 0; }
.kb-body blockquote p + p { margin-top: 6px; }
.kb-body code { background: #f1f3f7; padding: 1px 5px; border-radius: 4px;
  font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12.5px; }
.kb-body pre { background: #f6f8fa; border: 1px solid var(--border); border-radius: 8px;
  padding: 12px 14px; overflow-x: auto; margin: 0 0 14px; }
.kb-body pre code { background: none; padding: 0; font-size: 12.5px; line-height: 1.7; }
.kb-body .kb-table-wrap { overflow-x: auto; margin: 0 0 16px; border: 1px solid var(--border); border-radius: 8px; }
.kb-body table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 420px; }
.kb-body th { background: #f6f8fb; text-align: left; font-weight: 600; color: var(--text);
  padding: 9px 12px; border-bottom: 1px solid var(--border); white-space: normal; word-break: keep-all; }
.kb-body td { padding: 9px 12px; border-bottom: 1px solid #eef0f4; color: var(--text-2); vertical-align: top; }
.kb-body tr:last-child td { border-bottom: 0; }
.kb-body tbody tr:hover { background: #fafbfd; }
.kb-body hr { border: 0; border-top: 1px solid var(--border); margin: 18px 0; }
@media (max-width: 760px) {
  .kb-body table { min-width: 0; font-size: 12.5px; }
  .kb-body th, .kb-body td { padding: 7px 9px; }
}

/* ---------- 分类管理弹窗（管理员维护目录树） ---------- */
.cmm-list { display: flex; flex-direction: column; gap: 10px; max-height: 58vh; overflow: auto; padding-right: 2px; }
.cmm-top { border: 1px solid var(--border); border-radius: 9px; overflow: hidden; }
.cmm-top-row { display: flex; align-items: center; gap: 8px; padding: 9px 12px; background: #f8f9fb; }
.cmm-top-row b { flex: 1; min-width: 0; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmm-kids { border-top: 1px solid var(--border); }
.cmm-kid { display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 26px;
  font-size: 12.5px; color: var(--text-2); border-bottom: 1px solid #f1f2f5; }
.cmm-kid:last-child { border-bottom: 0; }
.cmm-kid > span:first-child { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmm-n { font-size: 11.5px; color: var(--muted); min-width: 40px; text-align: right; }
.btn-xs { padding: 3px 8px; font-size: 11.5px; border-radius: 5px; }

/* ---------- 流程管理列表（一单多业务、多列，窄屏横向滚动不挤压） ---------- */
/* 表格给一个明确的最小宽度，列多时整表横向滚动（.table-wrap 已 overflow-x:auto），
   而不是把客户名/业务名压成三字一行的竖排。 */
.flw-table { min-width: 1320px; }
/* 关键：给容器一个可视区高度，让横向滚动条固定在表格底部（不用先滚到页面最底部），
   表头 sticky 钉在顶部，行多时在容器内上下滚动、左右滑动随时可用 */
.flw-wrap { max-height: 58vh; overflow: auto; }
.flw-wrap thead th { position: sticky; top: 0; background: #f7f8fa; z-index: 2; }
/* 各列给下限 + 禁止折行，长文本用省略号，避免撑破列宽 */
.flw-table thead th { white-space: nowrap; }
.flw-biz { min-width: 170px; }
.flw-name { min-width: 130px; }
.flw-cust { min-width: 150px; }
.flw-no { min-width: 140px; }
.flw-app { min-width: 110px; }
.flw-team { min-width: 130px; }
.flw-date { white-space: nowrap; }
.flw-prog { min-width: 110px; }
/* 长文本列：单行 + 省略号，杜绝「孤字成行 / 限公司」这类断行。
   表格整体 min-width 1320 + 可横向滚动，宁可让用户横滑也不竖排折断。 */
.flw-table td.flw-biz,
.flw-table td.flw-name,
.flw-table td.flw-cust,
.flw-table td.flw-no,
.flw-table td.flw-app,
.flw-table td.flw-team { max-width: 240px; }
.flw-table .flw-biz .row-main,
.flw-table .flw-biz .cell-sub,
.flw-table .flw-name,
.flw-table .flw-cust a,
.flw-table .flw-cust .cell-sub,
.flw-table .flw-no b,
.flw-table .flw-no .cell-sub,
.flw-table .flw-app,
.flw-table .flw-team .cell-main,
.flw-table .flw-team .cell-sub {
  max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
/* 空值「—」统一样式：淡灰、不占视觉焦点 */
.flw-table .muted { color: #b6bcc6; }
/* 当前节点是「技术交底与检索（1/9）」这类长文本，禁止折行（整表已可横向滚动） */
.flw-table td.hide-m { white-space: nowrap; }
.flw-table .cell-main { font-size: 12.5px; color: var(--text); }
/* 高级筛选内嵌面板 */
.flw-adv { margin-bottom: 8px; padding: 10px 12px 6px; }
.flw-adv-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--border); }
.flw-adv-sec { margin-bottom: 8px; }
.flw-adv-sec:last-child { margin-bottom: 0; }
.flw-adv-title { font-size: 12.5px; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.flw-adv-title::before { content: ''; display: inline-block; width: 3px; height: 12px; background: var(--brand, #2563eb); border-radius: 2px; margin-right: 6px; vertical-align: -1px; }
/* 固定列数栅格：5 列等宽对齐，信息密度更高、右侧不留空；
   日期/金额区间字段占两列（.fp-item.wide），输入框有空间，「至」字不挤 */
.flw-adv-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px 10px; }
/* 收紧：label 与输入框、字段行之间更紧凑，信息密度更高（流程管理 + 交付中心两处高级筛选共用） */
.flw-adv-grid .fp-item label { margin-bottom: 2px; }
.flw-adv-grid .fp-item input, .flw-adv-grid .fp-item select { padding: 4px 7px; height: 28px; }
@media (max-width: 1180px) { .flw-adv-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 900px) { .flw-adv-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .flw-adv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* 日期/金额区间：两个输入 + 中间「至」，占两列宽 */
.flw-adv .dvc-adv2 { display: flex; align-items: center; gap: 6px; }
.flw-adv .dvc-adv2 input { flex: 1; min-width: 0; }
.flw-adv .dvc-adv2 .tiny { flex: 0 0 auto; }
/* 区间字段占两列，避免两个输入框挤在一个窄格里 */
.flw-adv .fp-item.wide { grid-column: span 2; }
@media (max-width: 760px) {
  /* 手机端卡片模式：列竖排，min-width 失效也无需横向滚动 */
  .flw-table { min-width: 0; }
  .flw-biz, .flw-name, .flw-cust, .flw-no, .flw-app, .flw-team, .flw-prog { min-width: 0; }
  .flw-table td.hide-m { white-space: normal; }
}

/* ===== AI 成长中心（2026-11-29）===== */
/* 反馈三连：复制 / 用了 / 没用（销售助手、演练复盘共用） */
.g-fb { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.g-fb .btn-xs[disabled] { opacity: .55; cursor: default; }
.g-fb .g-fb-use { color: #15803d; border-color: #bfe3c8; }
.g-fb .g-fb-no { color: #b91c1c; border-color: #f0cdcd; }
.g-fb.done-use .g-fb-use { background: #15803d; color: #fff; border-color: #15803d; }
.g-fb.done-no .g-fb-no { background: #b91c1c; color: #fff; border-color: #b91c1c; }
.sa-script-foot, .rp-script-foot { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }
.sa-script-foot .hint, .rp-script-foot .hint { flex: 1; min-width: 200px; }
.sa-script-foot .hint:empty, .rp-script-foot .hint:empty { display: none; }
.sa-grown { flex: none; }
.rp-scene-group { font-size: 11px; color: var(--muted); padding: 8px 10px 4px; }

.ag-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 14px; margin-bottom: 14px; align-items: start; }
.ag-loop { display: flex; flex-direction: column; gap: 8px; }
.ag-loop-i { display: flex; gap: 10px; font-size: 12.5px; line-height: 1.7; color: var(--muted); padding: 8px 10px; border-radius: 8px; background: #fafbfe; }
.ag-loop-i.on { color: var(--text); background: #f0f7ff; }
.ag-loop-i b { flex: none; color: var(--text); }
.ag-last { margin-top: 12px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; font-size: 12.5px; line-height: 1.7; }
.ag-last-h { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 4px; }
.ag-notes { margin: 6px 0 0; padding-left: 16px; color: var(--muted); font-size: 12px; }
.ag-bar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.ag-bar .segmented { flex-wrap: wrap; }
.ag-lessons { display: flex; flex-direction: column; gap: 12px; }
.ag-lesson .card-head { flex-wrap: wrap; row-gap: 6px; }
.ag-lesson .card-head h3 { font-size: 13.5px; }
.ag-acts { display: flex; gap: 6px; flex-wrap: wrap; }
.ag-body { white-space: pre-wrap; font-size: 13px; line-height: 1.8; color: var(--text); margin-bottom: 8px; }
.ag-lines { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
.ag-line { display: flex; gap: 8px; font-size: 12.8px; line-height: 1.7; padding: 7px 10px; border-radius: 8px; background: #f4f6fa; }
.ag-line.me { background: #eef4ff; }
.ag-line span { flex: none; color: var(--muted); font-size: 11px; padding-top: 2px; }
.ag-ev, .ag-quotes { font-size: 12px; color: var(--muted); line-height: 1.7; margin-top: 6px; }
.ag-quotes { color: var(--text-2); }
.ag-sig td, .ag-sig th { font-size: 12.5px; }
.ag-unh { display: flex; gap: 10px; font-size: 12.8px; line-height: 1.7; padding: 6px 0; border-bottom: 1px dashed var(--border); }
.ag-unh:last-of-type { border-bottom: 0; }
.ag-unh b { flex: none; color: var(--primary); }
.ag-switch { display: flex; align-items: center; gap: 12px; justify-content: space-between; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 12px; }
.ag-chks { display: flex; gap: 14px; flex-wrap: wrap; }
.ag-chk { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; cursor: pointer; }
.ag-chk input { width: 16px; height: 16px; }
.ag-prompt-foot { display: flex; gap: 12px; align-items: center; margin-top: 8px; }
.ag-prompt-foot .hint { flex: 1; min-width: 200px; }
.ag-ell { max-width: 360px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ag-patch-meta { font-size: 12.5px; color: var(--muted); margin-bottom: 10px; }
@media (max-width: 900px) {
  .ag-grid { grid-template-columns: minmax(0, 1fr); }
  .ag-ell { max-width: 200px; }
}

/* ==================== AI 主管 · 主动介入 ==================== */
/* 工作台顶部「主管叫你」卡片：有待处理才出现，处理完即消失 */
.iv-callout { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; padding: 14px 16px; border: 1px solid #f3d9b5; border-left: 4px solid #e0a13a; border-radius: 10px; background: linear-gradient(180deg, #fffaf0, #fff); }
.iv-callout .ivc-ava { flex: none; width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: #fff; background: linear-gradient(135deg, #2563eb, #7c3aed); }
.iv-callout .ivc-main { flex: 1; min-width: 0; }
.ivc-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; font-size: 13.5px; }
.ivc-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 8px 10px; border-top: 1px dashed #f1e3cb; font-size: 13px; }
.ivc-row .ivc-title { color: var(--text); }
.ivc-row .spacer { flex: 1; }
/* 主管介入页签 */
.iv-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.iv-div { width: 1px; height: 18px; background: var(--border); }
.iv-hint { margin-bottom: 12px; }
.iv-card { margin-bottom: 10px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg); }
.iv-card.s-high { border-left: 4px solid var(--danger); }
.iv-card.s-normal { border-left: 4px solid var(--warning, #e0a13a); }
.iv-card.s-good { border-left: 4px solid var(--success, #16a34a); }
.iv-card.closed { opacity: .78; }
.iv-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.iv-title { font-size: 14.5px; }
.iv-user { font-size: 11.5px; color: var(--primary); background: #eef4ff; border-radius: 4px; padding: 1px 6px; }
.iv-meta { font-size: 12px; color: var(--muted); }
.iv-detail { margin-top: 6px; font-size: 13px; line-height: 1.8; color: var(--text-2); }
.iv-more { margin-top: 8px; }
.iv-more > summary { cursor: pointer; font-size: 12.5px; color: var(--primary); user-select: none; }
.iv-more[open] > summary { margin-bottom: 4px; }
.iv-body { padding: 4px 0 0; }
.iv-note { margin-top: 8px; padding: 7px 10px; border-radius: 8px; font-size: 12.5px; line-height: 1.7; background: #f4f6fa; color: var(--text-2); }
.iv-note.warn { background: var(--warn-soft); color: #a15c07; }
.iv-acts { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }
.iv-input { width: 100%; box-sizing: border-box; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; font: inherit; font-size: 13px; line-height: 1.7; resize: vertical; }
.iv-sec-t { font-size: 12.5px; font-weight: 600; margin: 14px 0 8px; color: var(--text); }
.iv-times { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.iv-times .field { margin: 0; }
.iv-times label { font-size: 12px; color: var(--muted); }
#iv-quiet { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.iv-q { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }
.iv-q .fin { width: 130px; }
.iv-q .x { width: 26px; height: 26px; line-height: 1; font-size: 16px; }
.iv-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }
.iv-grid .field { margin: 0; }
.iv-wx { display: flex; align-items: center; gap: 10px; }
.iv-wx label { font-size: 12px; color: var(--muted); }
@media (max-width: 760px) {
  .iv-callout { padding: 12px; }
  .ivc-row .btn { padding: 4px 10px; }
  .iv-q .fin { width: 110px; }
}

/* ==================== 状态画像（P2 · 读人） ==================== */
.ps-card { border: 1px solid var(--border); border-radius: 12px; background: var(--bg); padding: 16px; margin-bottom: 12px; }
.ps-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; }
.ps-name { font-size: 15px; font-weight: 600; }
.ps-risk { display: flex; align-items: center; gap: 8px; }
.ps-risk b { font-size: 22px; font-weight: 700; }
.ps-boundary { margin-top: 10px; padding: 8px 12px; border-radius: 8px; background: #f4f6fa; color: var(--text-2); font-size: 12.5px; line-height: 1.7; }
.ps-labels { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-top: 14px; }
.ps-label { border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; background: var(--bg-soft, #fafbfc); }
.ps-label b { font-size: 13.5px; }
.ps-label .tiny { display: block; margin-top: 4px; }
.ps-sigs { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; margin-top: 14px; }
.ps-sig { border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; }
.ps-sig-head { display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; color: var(--muted); margin-bottom: 6px; }
.ps-sig-val { font-size: 20px; font-weight: 700; }
.ps-sig-val small { font-size: 12px; font-weight: 400; color: var(--muted); margin-left: 3px; }
.ps-sig-note { margin-top: 6px; font-size: 12px; color: var(--muted); line-height: 1.6; }
.ps-sec-t { font-size: 12.5px; font-weight: 600; margin: 16px 0 8px; color: var(--text); }
.ps-advices { display: flex; flex-direction: column; gap: 8px; }
.ps-advice { border-left: 3px solid var(--primary); padding: 8px 12px; background: var(--bg-soft, #fafbfc); border-radius: 0 8px 8px 0; }
.ps-adv-t { font-size: 13px; font-weight: 600; margin-bottom: 3px; }
.ps-team { display: flex; flex-direction: column; gap: 10px; }
.ps-row { border: 1px solid var(--border); border-radius: 10px; background: var(--bg); padding: 10px 12px; }
.ps-row-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ps-row-head b { font-size: 14px; }
.ps-row .ps-card { margin: 12px 0 2px; border-color: var(--border); }

/* 团队健康度周报（P3） */
.wk-list { display: flex; flex-direction: column; gap: 8px; }
.wk-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.wk-row b { font-size: 13.5px; }
.wk-grid { align-items: start; }

/* 分享面板里的「微信卡片预览」（2026-12-01）
   老板反馈分享出去没图，但他在后台看不到「发出去到底长什么样」，
   只能发一次试一次。这里把微信聊天里那张卡片的真实版式画出来：
   左方图 + 右标题摘要，作者改完封面立刻能看到结果。
   kbDetail（知识库）和 marketing（营销文章）共用这套类名。 */
.kbp-hd { font-size: 12px; color: var(--muted, #8b93a1); margin: 14px 0 7px; }
.kbp-card { display: flex; gap: 10px; padding: 11px; border-radius: 9px;
  background: #f7f8fa; border: 1px solid #ebedf1; }
.kbp-thumb { width: 62px; height: 62px; border-radius: 6px; flex: 0 0 auto;
  background: #dfe3e9 center/cover no-repeat; }
.kbp-info { min-width: 0; flex: 1; display: flex; flex-direction: column; justify-content: center; }
.kbp-title { font-size: 13.5px; line-height: 1.45; color: #1a1d21; font-weight: 600;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.kbp-digest { font-size: 12px; line-height: 1.5; color: #8b93a1; margin-top: 4px;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.kbp-warn { font-size: 12px; line-height: 1.6; color: #a06a15; background: #fdf7e8;
  border: 1px solid #f5e6c4; border-radius: 7px; padding: 8px 10px; margin-top: 10px; }
