/* ══════════ 设计令牌（对齐设计稿）══════════ */
:root {
  --navy: #0E1B2E;
  --navy-2: #16243A;
  --navy-3: #24344D;
  --blue: #1A56DB;
  --blue-2: #3B6FE0;
  --blue-3: #5B8DEF;
  --blue-soft: #E8EFFD;
  --bg: #F4F6FA;
  --card: #FFFFFF;
  --line: #E7EBF2;
  --line-2: #E1E6EF;
  --line-3: #D7DEE9;
  --text: #101828;
  --text-2: #40506A;
  --text-3: #7A879B;
  --text-4: #9AA6B8;
  --green: #0E9F6E;
  --green-soft: #F0FBF6;
  --orange: #B54708;
  --orange-soft: #FFF8ED;
  --red: #E02424;
  --red-soft: #FEF3F2;
  --teal: #4EB8A0;
  --purple: #7C3AED;
  --radius: 12px;
  --radius-s: 7px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .04);
}

* { box-sizing: border-box; }

/* hidden 属性优先级最高：防止 .timeline 等 display:flex 的类把 hidden 冲掉 */
[hidden] { display: none !important; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', -apple-system, sans-serif;
  font-size: 13px;
  -webkit-font-smoothing: antialiased;
}

button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 13px; color: var(--text); outline: none; }
a { color: var(--blue); text-decoration: none; cursor: pointer; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #D6DEEB; border-radius: 4px; }
::-webkit-scrollbar-track { background: transparent; }

/* ══════════ 登录页 ══════════ */
.login {
  display: flex;
  min-height: 100vh;
  background: #fff;
}
.login-brand {
  width: 46%;
  min-width: 520px;
  background: var(--navy);
  padding: 64px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}
.login-brand::after {
  content: '';
  position: absolute;
  right: -160px;
  bottom: -160px;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(26, 86, 219, .55) 0%, rgba(26, 86, 219, 0) 68%);
}
.login-logo { display: flex; align-items: center; gap: 10px; height: 36px; position: relative; z-index: 2; }
.logo-mark {
  width: 34px; height: 34px; border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.logo-mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.login-logo span { color: #fff; font-size: 17px; font-weight: 600; letter-spacing: .3px; }
.login-headline {
  margin-top: 130px;
  color: #fff;
  font-size: 38px;
  line-height: 54px;
  font-weight: 700;
  letter-spacing: .5px;
  position: relative; z-index: 2;
}
.login-sub {
  margin-top: 22px;
  width: 470px;
  color: #8CA0BD;
  font-size: 14px;
  line-height: 26px;
  position: relative; z-index: 2;
}
.login-tags { margin-top: 34px; display: flex; gap: 10px; flex-wrap: wrap; position: relative; z-index: 2; }
.login-tag {
  padding: 7px 13px;
  border-radius: 6px;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .09);
  color: #A9BCD6;
  font-size: 12px;
}
.login-foot {
  margin-top: 14px;
  color: #5F7793;
  font-size: 13px;
  position: relative; z-index: 2;
}
.login-brand-logo {
  margin-top: auto;
  width: 200px;
  position: relative; z-index: 2;
}
.login-side {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
}
.login-card { width: 400px; display: flex; flex-direction: column; gap: 12px; }
.login-title { font-size: 26px; font-weight: 700; letter-spacing: -.2px; }
.login-desc { font-size: 13px; line-height: 22px; color: var(--text-3); margin-bottom: 10px; }
.role-tabs {
  display: flex; gap: 4px; padding: 4px;
  background: #F3F5F9; border-radius: 9px; height: 40px; margin-bottom: 6px;
}
.role-tab {
  flex: 1; border-radius: 6px; font-size: 13px; color: var(--text-3);
  display: flex; align-items: center; justify-content: center; transition: .15s;
}
.role-tab.on { background: #fff; color: var(--blue); font-weight: 500; box-shadow: 0 1px 3px rgba(16,24,40,.08); }
.field-label { font-size: 12px; color: var(--text-2); font-weight: 500; margin-top: 4px; }
.input-box {
  height: 44px; border-radius: 8px; background: #F7F9FC;
  border: 1px solid var(--line-2); display: flex; align-items: center;
  padding: 0 14px; gap: 8px; transition: .15s;
}
.input-box:focus-within { border-color: var(--blue); background: #fff; box-shadow: 0 0 0 3px rgba(26,86,219,.08); }
.input-box input {
  border: none; background: transparent; flex: 1; height: 100%; font-size: 13px;
}
.input-box input::placeholder { color: var(--text-4); }
.btn-login {
  height: 46px; border-radius: 8px; background: var(--blue); color: #fff;
  font-size: 15px; font-weight: 600; margin-top: 12px; transition: .15s;
}
.btn-login:hover { background: #1548BE; }
.login-note { font-size: 12px; color: var(--text-4); margin-top: 6px; text-align: center; }
.login-error {
  background: var(--red-soft); color: var(--red); font-size: 12px;
  padding: 10px 12px; border-radius: 8px; margin-top: 2px;
}

/* 卡片头部的小分段切换（如 跟进记录 / 变更记录） */
.seg { display: inline-flex; gap: 2px; background: #F3F5F9; padding: 3px; border-radius: 7px; }
.seg-btn {
  padding: 5px 11px; font-size: 12px; color: var(--text-3);
  border-radius: 5px; transition: .13s; border: none; background: transparent; cursor: pointer;
}
.seg-btn:hover { color: var(--text-2); }
.seg-btn.on { background: #fff; color: var(--text); font-weight: 500; box-shadow: 0 1px 2px rgba(16, 24, 40, .07); }

/* 转接交接单 */
.handoff {
  border: 1px solid var(--line); border-radius: 9px; padding: 10px 12px;
  margin-top: 8px; background: #FCFDFE;
}
.ho-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.ho-row { display: flex; gap: 8px; font-size: 12px; line-height: 20px; color: var(--text-2); }
.ho-row b { flex: 0 0 62px; color: var(--text-4); font-weight: 400; }
.ho-row span { flex: 1; word-break: break-word; }
.handoff-quote {
  background: #F7F9FC; border-left: 3px solid var(--blue-3);
  padding: 9px 12px; border-radius: 0 7px 7px 0;
  font-size: 12px; line-height: 20px; color: var(--text-2); margin-bottom: 12px;
}

/* 一次性凭据展示（新增员工 / 重置密码后） */
.cred-box { border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; }
.cred-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 11px 14px; border-bottom: 1px solid var(--line);
}
.cred-row:last-child { border-bottom: none; background: #F7F9FC; }
.cred-row .k { font-size: 12px; color: var(--text-3); }
.cred-row .v { font-size: 13px; color: var(--text); }
.cred-row .v.mono {
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  letter-spacing: .4px;
}
.cred-row .v.strong { font-weight: 700; color: var(--blue); font-size: 15px; }

/* ══════════ 强制设置新密码 ══════════ */
.force-pwd {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(160deg, #0E1B2E 0%, #16243A 55%, #1B2E4A 100%);
  padding: 24px;
}
.force-pwd-card {
  width: 420px; max-width: 100%; background: #fff; border-radius: 16px;
  padding: 32px 30px; display: flex; flex-direction: column;
  box-shadow: 0 24px 60px rgba(6, 16, 32, .35);
}
.fp-logo { width: 42px; height: 42px; border-radius: 11px; overflow: hidden; margin-bottom: 18px; }
.fp-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fp-title { font-size: 21px; font-weight: 700; letter-spacing: -.2px; margin-bottom: 8px; }
.fp-desc { font-size: 13px; line-height: 22px; color: var(--text-3); margin-bottom: 16px; }
.fp-rules { font-size: 12px; line-height: 20px; color: var(--text-4); margin-top: 14px; }
.fp-logout { text-align: center; margin-top: 16px; font-size: 12px; }
.fp-logout a { color: var(--text-3); text-decoration: none; }
.fp-logout a:hover { color: var(--blue); }

/* ══════════ 应用骨架 ══════════ */
.shell { display: flex; height: 100vh; overflow: hidden; }

.sidebar {
  width: 232px; flex: 0 0 232px; background: var(--navy);
  display: flex; flex-direction: column;
}
.side-logo {
  height: 64px; display: flex; align-items: center; gap: 10px; padding: 0 20px;
  flex: 0 0 64px;
}
.side-logo .logo-mark { width: 28px; height: 28px; border-radius: 7px; }
.side-logo b { color: #fff; font-size: 14px; font-weight: 600; letter-spacing: .2px; }
.nav { padding: 8px 12px; display: flex; flex-direction: column; gap: 2px; }
.nav-item {
  height: 38px; display: flex; align-items: center; gap: 10px;
  padding: 0 12px; border-radius: var(--radius-s);
  color: #8CA0BD; font-size: 13px; transition: .14s;
}
.nav-item:hover { background: rgba(255,255,255,.05); color: #C9D6EC; }
.nav-item.on { background: var(--blue); color: #fff; font-weight: 500; }
.nav-item svg { flex: 0 0 16px; opacity: .9; }
.nav-divider { height: 1px; background: rgba(255,255,255,.07); margin: 8px 14px; }
.nav-group-label {
  padding: 10px 12px 6px; font-size: 10px; letter-spacing: 1px;
  color: #52688A; text-transform: uppercase;
}

/* ── 管理员侧栏 5 组折叠（只作用于桌面管理员，其它角色零影响） ── */
.nav.is-grouped {
  gap: 0; padding-bottom: 14px;
  flex: 1 1 auto; min-height: 0; overflow-y: auto;
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.14) transparent;
}
.nav.is-grouped::-webkit-scrollbar { width: 6px; }
.nav.is-grouped::-webkit-scrollbar-thumb { background: rgba(255,255,255,.14); border-radius: 3px; }
.nav.is-grouped .nav-group { margin-bottom: 4px; }
.nav-group-head {
  width: 100%; height: 30px; display: flex; align-items: center; gap: 6px;
  padding: 0 12px; border: 0; background: transparent; cursor: pointer;
  color: #6E87AC; font-size: 11px; font-weight: 500; letter-spacing: 1px;
}
.nav-group-head:hover { color: #C9D6EC; }
.nav-group-count { margin-left: auto; font-size: 10px; letter-spacing: 0; color: #42577B; }
.nav-group-arrow { display: inline-flex; opacity: .8; transition: transform .16s; }
.nav-group.is-collapsed .nav-group-arrow { transform: rotate(-90deg); }
.nav-group.is-collapsed .nav-group-items { display: none; }
.nav-group-items { display: flex; flex-direction: column; gap: 2px; }
.nav.is-grouped .nav-item { height: 34px; font-size: 12.5px; padding-left: 16px; }

.side-user {
  margin-top: auto; height: 72px; padding: 0 16px;
  display: flex; align-items: center; gap: 10px;
  border-top: 1px solid rgba(255,255,255,.06);
}
.avatar {
  width: 32px; height: 32px; border-radius: 50%; background: var(--navy-3);
  color: #fff; font-size: 12px; display: flex; align-items: center; justify-content: center;
  flex: 0 0 32px; font-weight: 500;
}
.side-user .u-name { color: #fff; font-size: 12px; font-weight: 500; line-height: 1.4; }
.side-user .u-role { color: #6C82A3; font-size: 10px; }

.main { flex: 1; display: flex; flex-direction: column; overflow: hidden; min-width: 0; }
.topbar {
  height: 64px; flex: 0 0 64px; background: #fff; border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 12px; padding: 0 28px;
}
.topbar h1 { font-size: 16px; font-weight: 600; margin: 0; letter-spacing: -.1px; }
.topbar .sub { font-size: 12px; color: var(--text-4); }
.topbar .right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.content { flex: 1; overflow: auto; padding: 24px; display: flex; flex-direction: column; gap: 14px; }

/* ══════════ 通用组件 ══════════ */
.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 8px;
}
.card.grow { flex: 1; min-height: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 24px; }
.card-title { font-size: 13px; font-weight: 600; color: var(--text); }
.card-note { font-size: 11px; color: var(--text-4); }

.btn {
  height: 32px; padding: 0 12px; border-radius: var(--radius-s);
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 12px; font-weight: 500; transition: .14s; white-space: nowrap;
}
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: #1548BE; }
.btn-primary:disabled { background: #B9C7E2; cursor: not-allowed; }
.btn-ghost { background: #fff; border: 1px solid var(--line-3); color: var(--text-2); }
.btn-ghost:hover { border-color: var(--blue); color: var(--blue); }
.btn-sm { height: 28px; padding: 0 10px; font-size: 11px; }
.btn-text { color: var(--blue); font-size: 11px; font-weight: 500; padding: 0 2px; }
.btn-text:hover { text-decoration: underline; }
.btn-danger { background: #fff; border: 1px solid #F5C6C6; color: var(--red); }

.input, .select {
  height: 34px; border-radius: var(--radius-s); background: #F7F9FC;
  border: 1px solid var(--line-2); padding: 0 12px; font-size: 12px; color: var(--text-2);
  transition: .14s;
}
.input:focus, .select:focus { border-color: var(--blue); background: #fff; }
.input::placeholder { color: var(--text-4); }
.search-box { position: relative; display: flex; align-items: center; }
.search-box svg { position: absolute; left: 11px; pointer-events: none; }
.search-box .input { padding-left: 32px; }

.badge {
  display: inline-flex; align-items: center; height: 22px; padding: 0 8px;
  border-radius: 11px; font-size: 10px; font-weight: 500; white-space: nowrap;
}
.badge-blue { background: #EAF0FD; color: var(--blue); }
.badge-green { background: var(--green-soft); color: var(--green); }
.badge-orange { background: var(--orange-soft); color: var(--orange); }
.badge-red { background: var(--red-soft); color: var(--red); }
.badge-muted { background: #F2F4F8; color: var(--text-3); }
.badge-purple { background: #F3EEFE; color: var(--purple); }

.tag {
  display: inline-flex; align-items: center; height: 20px; padding: 0 7px;
  border-radius: 4px; background: #F2F5FA; color: var(--text-2);
  font-size: 10px; margin-right: 4px;
}
.tag.hot { background: var(--green-soft); color: var(--green); }

/* 公海池营销级别标签 */
.mchip {
  display: inline-flex; align-items: center; height: 22px; padding: 0 9px;
  border-radius: 5px; background: #EEF3FB; color: var(--text-2); font-size: 11px; font-weight: 500;
}
.mchip-gold { background: #F7E9BE; color: #8A5E00; font-weight: 600; }
.mchip-warn { background: #F2F4F8; color: var(--text-3); }

.row { display: flex; align-items: center; gap: 10px; }
.row.wrap { flex-wrap: wrap; }
.spacer { flex: 1; }
.muted { color: var(--text-4); }
.small { font-size: 11px; }
.grid-kpi { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.grid-2 { display: grid; grid-template-columns: 1fr 400px; gap: 14px; min-height: 0; }
.grid-2 > .col { display: flex; flex-direction: column; gap: 14px; min-width: 0; }

.kpi {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; display: flex; flex-direction: column; gap: 6px;
}
.kpi .k-label { font-size: 12px; color: var(--text-3); }
.kpi .k-value { font-size: 26px; font-weight: 700; letter-spacing: -.5px; line-height: 1.25; }
.kpi .k-note { font-size: 11px; color: var(--text-3); }
.kpi.dark { background: var(--navy); border-color: var(--navy); }
.kpi.dark .k-label { color: #8CA0BD; }
.kpi.dark .k-value { color: #fff; }
.kpi.dark .k-note { color: #4EB8A0; }

/* 表格 */
.tbl { display: flex; flex-direction: column; }
.tr { display: flex; align-items: center; gap: 12px; padding: 0 12px; }
.tr.head {
  height: 40px; background: #F7F9FC; border-radius: var(--radius-s);
  color: var(--text-2); font-size: 13px; font-weight: 600;
}
.tr.body {
  min-height: 58px; border-bottom: 1px solid #F1F4F9;
  padding-top: 5px; padding-bottom: 5px;
}
.tr.body:nth-child(even) { background: #FBFCFE; }
.tr.body:hover { background: #F7FAFF; }
.tr.body:last-child { border-bottom: none; }
.td { min-width: 0; display: flex; align-items: center; }
.td.col { flex-direction: column; align-items: flex-start; gap: 3px; justify-content: center; }
.td-main { font-size: 15px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.td-main .ph { font-size: 14px; font-weight: 600; color: var(--text-2); }
.td-sub { font-size: 13px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.td-sub .sep { color: var(--text-4); margin: 0 5px; }
.td-sub .lb { color: var(--text-4); }
.td-val { font-size: 13px; color: var(--text-2); }
.td-mid { font-size: 13px; font-weight: 500; }
.pager {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 12px; margin-top: auto; font-size: 11px; color: var(--text-4);
}
.pager .pages { display: flex; gap: 6px; align-items: center; color: var(--text-2); }
.pager .pg { padding: 3px 7px; border-radius: 4px; }
.pager .pg.on { background: var(--blue); color: #fff; }
.pager .pg:hover:not(.on) { background: #EEF2F9; }

.empty {
  padding: 56px 0; text-align: center; color: var(--text-4); font-size: 12px;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
}

/* 进度条 */
.progress { height: 8px; border-radius: 4px; background: #24344D; overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: 4px; background: var(--teal); transition: width .4s; }

/* 漏斗 */
.funnel-row { display: flex; align-items: center; gap: 12px; height: 26px; }
.funnel-label { width: 60px; font-size: 11px; color: var(--text-3); flex: 0 0 60px; }
.funnel-bar { height: 10px; border-radius: 5px; min-width: 4px; transition: width .5s; }
.funnel-value { font-size: 11px; font-weight: 500; color: var(--text); }

/* 排行 */
.rank-item {
  display: flex; align-items: center; gap: 10px; height: 46px;
  padding: 0 12px; border-radius: 8px;
}
.rank-item:nth-child(odd) { background: #F7F9FC; }
.rank-no { width: 24px; font-size: 12px; font-weight: 700; color: var(--text-3); }
.rank-no.top { color: var(--blue); }
.rank-name { width: 76px; font-size: 12px; font-weight: 500; }
.rank-meta { flex: 1; font-size: 11px; color: var(--text-3); }
.rank-amount { width: 100px; text-align: right; font-size: 12px; font-weight: 600; }

/* 深色额度条 */
.quota-bar {
  background: var(--navy); border-radius: var(--radius); padding: 20px;
  display: flex; align-items: center; gap: 20px;
}
.quota-bar .q-title { color: #fff; font-size: 15px; font-weight: 600; }
.quota-bar .q-sub { color: #8CA0BD; font-size: 11px; margin-top: 4px; }
.quota-bar .q-mid { margin-left: auto; display: flex; align-items: center; gap: 14px; }

/* 时间轴 */
.timeline { display: flex; flex-direction: column; gap: 16px; position: relative; }
.tl-item { display: flex; gap: 10px; }
.tl-dot {
  width: 10px; height: 10px; border-radius: 50%; margin-top: 4px; flex: 0 0 10px;
  position: relative;
}
.tl-item:not(:last-child) .tl-dot::after {
  content: ''; position: absolute; left: 4px; top: 14px; width: 2px;
  height: calc(100% + 12px); background: #EAEFF6;
}
.tl-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.tl-title { font-size: 12px; font-weight: 600; }
.tl-text { font-size: 12px; line-height: 19px; color: var(--text-2); }
.tl-meta { font-size: 11px; color: var(--text-4); }

/* 表单行 */
.form-row {
  display: flex; align-items: center; gap: 16px; padding: 14px;
  background: #F7F9FC; border-radius: 10px;
}
.form-row .f-label { font-size: 13px; font-weight: 500; }
.form-row .f-note { font-size: 11px; color: var(--text-4); margin-top: 3px; line-height: 1.5; }
.form-row .f-ctrl { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.num-box {
  width: 150px; height: 40px; border-radius: 8px; background: #fff;
  border: 1px solid #C9D6EC; display: flex; align-items: center; padding: 0 12px; gap: 6px;
}
.num-box input {
  border: none; flex: 1; min-width: 0; font-size: 15px; font-weight: 600; background: transparent;
  text-align: right;
}
.num-box .unit { font-size: 11px; color: var(--text-4); flex: 0 0 auto; }
.hint-bar {
  background: #F7F9FC; border-radius: 10px; padding: 14px;
  display: flex; gap: 10px; align-items: flex-start;
}
.hint-bar .t { font-size: 12px; line-height: 19px; color: var(--text-3); }

/* 规则配置 ·「跟进提醒与群机器人」抽屉：默认收起，展开后不影响上方规则卡高度 */
.rm-drawer { padding: 12px 14px; gap: 6px; }
.rm-drawer-head {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 32px;
  padding: 0 2px; border: 0; background: transparent; cursor: pointer; text-align: left;
}
.rm-drawer-head .card-title { flex: 1; }
.rm-drawer-label {
  font-size: 11px; color: var(--blue); background: #EDF4FF;
  border-radius: 6px; padding: 3px 9px; white-space: nowrap;
}
.rm-drawer-arrow { color: var(--text-4); display: inline-flex; transition: transform .18s ease; }
.rm-drawer.is-open .rm-drawer-arrow { transform: rotate(180deg); }
.rm-drawer-body { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }

/* 抽屉 / 弹窗 */
.modal-mask {
  position: fixed; inset: 0; background: rgba(16, 24, 40, .45);
  /* 必须高于移动端底部 Tab(z-index:60)，否则弹窗底部按钮会被导航条盖住点不到 */
  display: flex; align-items: center; justify-content: center; z-index: 90;
  animation: fade .12s ease;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.modal {
  width: 560px; max-height: 84vh; overflow: auto; background: #fff;
  border-radius: 14px; padding: 24px; display: flex; flex-direction: column; gap: 14px;
  box-shadow: 0 20px 48px rgba(16,24,40,.2);
}
.modal h3 { margin: 0; font-size: 16px; font-weight: 600; }
.modal .m-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.modal .m-actions { display: flex; gap: 8px; flex: 0 0 auto; padding-top: 1px; }
.modal .m-sub { font-size: 12px; color: var(--text-3); }
.modal .m-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 4px; }

/* 短确认 / 号码选择弹窗：始终居中，不做贴底抽屉 */
.modal-mask--center .modal { width: 420px; max-width: 100%; max-height: 80vh; }
.modal-mask--center .modal .m-head { position: static; margin: 0; padding: 0; border: 0; background: transparent; }
.modal-mask--center .modal .m-sub { white-space: normal; overflow: visible; text-overflow: clip; }
.modal-mask--center .modal .m-foot { position: static; padding-top: 4px; }

/* 拨打：蓝色实心按钮 + 多号码逐行列表 */
.btn-dial { flex: 0 0 auto; text-decoration: none !important; }
.btn-dial:hover { text-decoration: none; color: #fff; }
.btn-dial-sm { width: 28px; height: 28px; padding: 0; }
.dial-more {
  display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 9px;
  background: rgba(26, 86, 219, .12); color: var(--blue); font-size: 11px; font-weight: 600;
}
.dial-list { display: flex; flex-direction: column; gap: 8px; }
.dial-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 10px; background: #F7F9FC;
}
.dial-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.dial-num {
  font-size: 16px; font-weight: 600; color: var(--text);
  letter-spacing: .2px; font-variant-numeric: tabular-nums; word-break: break-all;
}
.dial-who { font-size: 11px; color: var(--text-4); }
.dial-row .btn-dial { height: 34px; }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-field label { font-size: 12px; color: var(--text-2); font-weight: 500; }
.form-field .input, .form-field .select { height: 38px; }
.form-field textarea {
  border: 1px solid var(--line-2); border-radius: var(--radius-s); background: #F7F9FC;
  padding: 10px 12px; min-height: 80px; resize: vertical; line-height: 1.6;
}
.form-field textarea:focus { border-color: var(--blue); background: #fff; }
.full { grid-column: 1 / -1; }

/* Toast */
#toast-root { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 100; display: flex; flex-direction: column; gap: 8px; }
.toast {
  padding: 11px 18px; border-radius: 9px; font-size: 13px; background: #fff;
  box-shadow: 0 8px 24px rgba(16,24,40,.16); border: 1px solid var(--line);
  display: flex; align-items: center; gap: 8px; animation: slideDown .18s ease;
}
.toast.ok { color: var(--green); border-color: #C6EFDF; background: #F5FDF9; }
.toast.err { color: var(--red); border-color: #F8D4D4; background: #FEF6F6; }
@keyframes slideDown { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

/* 步骤条 */
.steps {
  display: flex; align-items: center; gap: 12px; background: #fff;
  border: 1px solid var(--line); border-radius: 10px; padding: 14px;
}
.step { display: flex; align-items: center; gap: 7px; }
.step-dot {
  width: 18px; height: 18px; border-radius: 50%; background: #D7DEE9; color: #fff;
  font-size: 10px; display: flex; align-items: center; justify-content: center; font-weight: 600;
}
.step.on .step-dot { background: var(--blue); }
.step.done .step-dot { background: var(--green); }
.step-label { font-size: 12px; color: var(--text-4); }
.step.on .step-label { color: var(--text); font-weight: 500; }
.step-line { flex: 1; height: 2px; background: var(--line-2); }

/* 上传区 */
.dropzone {
  border: 1px dashed #C9D6EC; background: #F7F9FC; border-radius: 10px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px; padding: 40px; text-align: center; transition: .15s; cursor: pointer;
  min-height: 220px;
}
.dropzone:hover { border-color: var(--blue); background: #F5F9FF; }
.dropzone.drag { border-color: var(--blue); background: #EEF4FE; }
.dz-title { font-size: 14px; font-weight: 500; }
.dz-sub { font-size: 12px; color: var(--text-4); }
.dz-icon {
  width: 44px; height: 44px; border-radius: 10px; background: var(--blue-soft);
  display: flex; align-items: center; justify-content: center;
}

/* 状态胶囊流程 */
.stage-pills { display: flex; gap: 6px; }
.pill {
  flex: 1; height: 28px; border-radius: 14px; display: flex; align-items: center;
  justify-content: center; font-size: 11px; font-weight: 500;
  background: #F2F5FA; color: var(--text-4);
}
.pill.done { background: var(--green); color: #fff; }
.pill.current { background: var(--blue); color: #fff; }

.alert {
  border-radius: 8px; padding: 12px; font-size: 11px; line-height: 18px;
}
.alert-warn { background: var(--orange-soft); color: var(--orange); }
.alert-info { background: #F2F6FD; color: var(--text-2); }
.alert-danger { background: var(--red-soft); color: var(--red); }

.kv-row {
  display: flex; align-items: center; gap: 10px; padding: 12px;
  background: #F7F9FC; border-radius: 8px; min-height: 38px;
}
.kv-row .k { width: 110px; flex: 0 0 110px; font-size: 12px; color: var(--text-3); }
.kv-row .v { font-size: 12px; color: var(--text); font-weight: 500; flex: 1; }

.meta-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; }
.meta-item { display: flex; flex-direction: column; gap: 4px; }
.meta-item .k { font-size: 10px; color: var(--text-4); }
.meta-item .v { font-size: 13px; font-weight: 500; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.detail-head { display: flex; align-items: center; gap: 12px; min-height: 32px; }
.detail-head .co { font-size: 19px; font-weight: 700; letter-spacing: -.2px; max-width: 360px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.detail-head .phone { font-size: 16px; font-weight: 600; color: var(--blue); white-space: nowrap; }
.detail-head .st { margin-left: auto; font-size: 12px; font-weight: 500; white-space: nowrap; }

/* ══════════ 页签 / 勾选 / 筛选方案 ══════════ */
.tabbar { display: flex; align-items: center; gap: 4px; flex: 0 0 auto; }
.tab {
  display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px;
  border-radius: 8px; font-size: 13px; color: var(--text-2); background: transparent;
  border: 1px solid transparent; cursor: pointer;
}
.tab:hover { background: #F2F5FA; }
.tab.on { background: #fff; border-color: var(--line-3); color: var(--blue); font-weight: 600; box-shadow: 0 1px 3px rgba(16,24,40,.06); }
.tab span { font-size: 11px; font-weight: 500; color: var(--text-4); }
.tab.on span { color: var(--blue); }

.ck { width: 15px; height: 15px; accent-color: var(--blue); cursor: pointer; flex: 0 0 15px; }
.tr.body.picked { background: #F0F5FF !important; }

.chip {
  display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border-radius: 12px;
  background: #EEF3FD; color: var(--blue); font-size: 11px; font-weight: 500; cursor: pointer;
}
.chip:hover { background: #DFE9FB; }
.chip-x { cursor: pointer; font-size: 12px; color: var(--text-4); padding: 0 2px; line-height: 24px; }
.chip-x:hover { color: var(--red); }

/* ══════════ 分页跳转 / 可点击看板 ══════════ */
.pager .pg.disabled { opacity: .38; pointer-events: none; }
.pg-jump { display: inline-flex; align-items: center; gap: 5px; margin-left: 6px; font-size: 12px; color: var(--text-2); }
.pg-input {
  width: 48px; height: 24px; border: 1px solid var(--line-3); border-radius: 5px;
  text-align: center; font-size: 12px; color: var(--text); background: #fff; padding: 0 2px;
}
.pg-input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(26,86,219,.10); }
.pg-input::-webkit-outer-spin-button, .pg-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.pg-go { height: 24px !important; padding: 0 8px !important; font-size: 11px !important; }

.clickable { cursor: pointer; transition: box-shadow .15s, transform .15s, border-color .15s; }
.clickable:hover { border-color: #C7D6F5 !important; box-shadow: 0 4px 14px rgba(16,24,40,.08); transform: translateY(-1px); }
.clickable:active { transform: translateY(0); }
.kpi.clickable .k-label::after { content: '查看明细 ›'; float: right; font-size: 10px; font-weight: 500; color: var(--blue); opacity: 0; transition: opacity .15s; }
.kpi.clickable:hover .k-label::after { opacity: 1; }
.funnel-row.clickable, .rank-item.clickable, .dist-row.clickable { border-radius: 6px; }
.funnel-row.clickable:hover, .dist-row.clickable:hover { background: #F5F8FD; }
.rank-item.clickable:hover { background: #F7F9FD; }

/* ══════════════════════════════════════════════════════════════
   移动端（≤ 820px）：一套代码两端可用
   侧边栏转底部 Tab · 表格转卡片 · 弹层转全屏
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 820px) {
  html, body { height: auto; }
  body { -webkit-text-size-adjust: 100%; }

  .shell {
    flex-direction: column;
    height: auto; min-height: 100vh;
    overflow: visible;
    padding-bottom: calc(58px + env(safe-area-inset-bottom));
  }

  /* 底部 Tab 栏 */
  .sidebar {
    position: fixed; left: 0; right: 0; bottom: 0; top: auto; z-index: 60;
    width: auto; flex: 0 0 auto; height: auto;
    flex-direction: row; align-items: stretch;
    padding-bottom: env(safe-area-inset-bottom);
    box-shadow: 0 -2px 14px rgba(14, 27, 46, .22);
  }
  .side-logo, .side-user { display: none !important; }
  .nav {
    flex: 1; flex-direction: row; padding: 0; gap: 0;
    overflow-x: auto; overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .nav::-webkit-scrollbar { display: none; }
  /* 兜底：窄视口下不渲染分组；万一渲染了也拍平成原来的横滑菜单 */
  .nav-group, .nav-group-items { display: contents; }
  .nav-group-head { display: none; }
  .nav-item {
    flex: 1 0 auto; min-width: 66px; height: 48px;
    margin: 5px 2px; padding: 0 4px; border-radius: 10px;
    flex-direction: column; justify-content: center; gap: 2px;
  }
  .nav-item span { font-size: 10px; line-height: 1.1; white-space: nowrap; }
  .nav-item svg { width: 19px; height: 19px; flex: 0 0 19px; }
  .nav-item.on { background: var(--blue); color: #fff; }
  .nav-item.on svg { opacity: 1; }

  .main { height: auto; min-height: 0; overflow: visible; }

  /* 顶栏压缩，副标题换行 */
  .topbar {
    height: auto; flex: 0 0 auto; min-height: 0;
    flex-wrap: wrap; gap: 2px 10px;
    padding: 10px 14px; position: sticky; top: 0; z-index: 40;
  }
  .topbar > div:first-child { width: 100%; }
  .topbar h1 { font-size: 17px; }
  .topbar .sub {
    font-size: 11px; line-height: 16px; width: 100%;
    white-space: normal; overflow: visible;
  }
  .topbar .right { margin-left: 0; position: absolute; right: 12px; top: 10px; gap: 6px; }
  .topbar .right .badge { display: none; }

  .content { padding: 12px; gap: 12px; overflow: visible; }

  /* 栅格塌成单列 */
  .grid-kpi { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-4, .grid-3 { grid-template-columns: 1fr !important; }

  .card { padding: 13px; border-radius: 10px; }
  .kpi { padding: 13px; }
  .kpi .k-value { font-size: 21px; }
  .card-head { flex-wrap: wrap; gap: 6px; }

  /* 表格：保留横向滚动，不硬压 */
  .tr { min-width: 620px; }
  .tr.head { display: none; }

  /* 弹层全屏化，输入框加大便于点按 */
  .modal-mask { align-items: flex-end; padding: 0; }
  .modal {
    width: 100% !important; max-width: 100%;
    max-height: 92vh; border-radius: 14px 14px 0 0;
    padding: 18px 16px calc(16px + env(safe-area-inset-bottom));
  }
  /* 头部吸附在弹窗顶部：长表单滚动时右上角的保存/关闭永远点得到 */
  .modal .m-head {
    position: sticky; top: -18px; z-index: 5;
    margin: -18px -16px 0; padding: 14px 16px 10px;
    background: #fff; border-bottom: 1px solid var(--line-3);
  }
  .modal .m-head > div:first-child { flex: 1; min-width: 0; }
  .modal .m-sub {
    font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
  .modal .m-foot { position: sticky; bottom: 0; background: #fff; padding-top: 10px; }

  /* 短确认/号码选择：屏幕正中卡片，按钮完整露出、不再贴底被 Tab 遮挡 */
  .modal-mask--center { align-items: center; justify-content: center; padding: 16px; }
  .modal-mask--center .modal {
    width: calc(100% - 32px) !important; max-width: 420px;
    max-height: 78vh; border-radius: 14px; padding: 18px 16px;
    box-shadow: 0 18px 44px rgba(16, 24, 40, .28);
  }
  .modal-mask--center .modal .m-head {
    position: static; margin: 0; padding: 0 0 10px; border: 0; background: transparent;
  }
  .modal-mask--center .modal .m-foot { position: static; background: transparent; }

  /* 拨打按钮在移动端做成更大的蓝色实心按钮 */
  .btn-dial { height: 38px; padding: 0 14px; font-size: 13px; }
  .btn-dial-sm { width: 34px; height: 34px; padding: 0; }
  .dial-row { padding: 11px 12px; }
  .dial-row .dial-num { font-size: 17px; }
  .dial-row .btn-dial { height: 38px; padding: 0 14px; }
  .detail-head .phone { font-size: 13px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }

  .input, .select { height: 42px; font-size: 14px; }
  textarea.input { height: auto; min-height: 84px; padding: 10px 12px; line-height: 1.6; }
  .btn { height: 36px; }
  .btn-sm { height: 30px; font-size: 12px; }
  .btn-login { height: 48px; }

  /* 表单两列塌成一列 */
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .form-field[style*="span 2"] { grid-column: span 1 !important; }

  /* 详情页左右列改为上下 */
  .detail-head { flex-wrap: wrap; gap: 6px; }
  .detail-head .co { font-size: 15px; }
  .meta-4 { grid-template-columns: 1fr !important; }

  /* 登录页：只留表单 */
  .login { flex-direction: column; height: 100vh; }
  .login-brand { display: none; }
  .login-side { padding: 24px; width: 100%; }
  .login-card { width: 100%; max-width: 380px; }
  .force-pwd { padding: 16px; }
  .force-pwd-card { padding: 24px 20px; }

  /* 时间轴、跟进卡片更宽松 */
  .timeline { padding: 0; }
  .tl-body { min-width: 0; }
  .tl-text { word-break: break-word; }

  /* 年份/月份筛选控件不要挤 */
  .row { flex-wrap: wrap; }
}

/* 超窄屏（≤ 380px）：KPI 也塌成一列 */
@media (max-width: 380px) {
  .grid-kpi { grid-template-columns: 1fr; }
}

/* ══════════ 渠道收单明细（宽表业务台账） ══════════ */
.deals-host { display: flex; flex-direction: column; gap: 14px; flex: 1; min-height: 0; }
.deals-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; }
.deals-kpi { padding: 12px 14px; gap: 4px; }
.deals-kpi .k-value { white-space: nowrap; }

/* 渠道收单明细 · 授信 / 放款汇总看板 */
.ds-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: -2px; }
.deals-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.ds-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 16px; box-shadow: var(--shadow); min-width: 0;
}
.ds-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.ds-title { font-size: 14px; font-weight: 700; }
.ds-tag { font-size: 11px; color: var(--text-4); }
.ds-total { font-size: 26px; font-weight: 700; margin: 8px 0 6px; white-space: nowrap; }
.ds-metrics { display: flex; flex-wrap: wrap; gap: 14px; font-size: 11px; color: var(--text-3); }
.ds-metrics b { color: var(--text); font-weight: 600; }
.ds-sub { font-size: 11px; color: var(--text-4); margin: 12px 0 6px; }
.ds-bar-row { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; font-size: 11px; }
.ds-bar-label { flex: 0 0 88px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-2); }
.ds-bar-track { flex: 1; height: 8px; border-radius: 4px; background: #EEF2F8; overflow: hidden; }
.ds-bar-track i { display: block; height: 100%; border-radius: 4px; }
.ds-bar-row b { flex: 0 0 92px; text-align: right; font-weight: 600; color: var(--text); white-space: nowrap; }
.ds-none { font-size: 11px; color: var(--text-4); padding: 4px 0; }
.ds-months { font-size: 11px; color: var(--text-3); margin-top: 10px; line-height: 1.7; }
@media (max-width: 900px) {
  .deals-summary { grid-template-columns: 1fr; }
}
.deals-head { flex-wrap: wrap; gap: 10px; }
.deals-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.deals-toggle { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--text-2); cursor: pointer; white-space: nowrap; }
.deals-toggle input { accent-color: var(--blue); }

.deals-filters {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px 14px; border-bottom: 1px solid var(--line);
}
.deals-filters .select { width: 132px; height: 34px; }
.deals-filters .input[type="date"] { width: 142px; height: 34px; }
.deals-search { width: 220px; height: 34px; }

.deals-table-wrap { flex: 1; min-height: 0; overflow: auto; -webkit-overflow-scrolling: touch; }
.deals-table { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 13px; }
.deals-table th, .deals-table td {
  padding: 10px 12px; text-align: left; white-space: nowrap;
  border-bottom: 1px solid var(--line); color: var(--text-2);
}
.deals-table thead th {
  position: sticky; top: 0; z-index: 3; background: #F7F9FC;
  font-size: 12px; font-weight: 600; color: var(--text-2); cursor: pointer; user-select: none;
}
.deals-table thead th:hover { background: #EDF2FB; }
.deals-table tbody tr:hover { background: #F7FAFF; }
.deals-table tbody tr.is-error { background: var(--red-soft); }
.deals-sort { color: var(--blue); margin-left: 4px; font-weight: 700; }
.deals-ops { white-space: nowrap; }
/* 首列冻结：横向滚动时始终能看到是哪个渠道 */
.deals-table:not(.deals-preview) tbody td:first-child { position: sticky; left: 0; z-index: 2; background: #fff; font-weight: 600; color: var(--text); }
.deals-table:not(.deals-preview) thead th:first-child { z-index: 4; background: #F7F9FC; }
.deals-table:not(.deals-preview) tbody tr:hover td:first-child { background: #F7FAFF; }
.deals-pager { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-top: 1px solid var(--line); }

.deals-form { gap: 10px 14px; }
.deals-field { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--text-2); }
.deals-field.is-optional > span { color: var(--text-3); }
.deals-field .input { height: 36px; font-size: 13px; }
.deals-paste { width: 100%; min-height: 170px; padding: 10px; font-family: ui-monospace, Consolas, monospace; font-size: 12px; line-height: 1.6; resize: vertical; }
.deals-import-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 10px 0; }
.deals-import-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 10px; }
.deals-mode { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin: 8px 0; font-size: 12px; }
.deals-mode label { display: inline-flex; align-items: center; gap: 4px; cursor: pointer; }
.deals-mode input { accent-color: var(--blue); }

.deals-filter-toggle { display: none; }
.deals-date-range { display: inline-flex; align-items: center; gap: 6px; }

@media (max-width: 820px) {
  /* KPI 收成一行横向滚动，别把明细表挤出首屏 */
  .deals-host > .deals-kpis { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; }
  .deals-host > .deals-kpis .deals-kpi { flex: 0 0 112px; padding: 8px 10px; }
  .deals-host > .deals-kpis .k-value { font-size: 18px !important; }
  /* 筛选默认折叠，点开才占空间 */
  .deals-filter-toggle { display: inline-flex; align-self: flex-start; margin: 0 14px 10px; }
  .deals-filters { display: none; }
  .deals-filters.is-open { display: flex; }
  .deals-filters .select, .deals-filters .input[type="date"] { width: calc(50% - 6px); }
  .deals-date-range { width: 100%; }
  .deals-date-range .input[type="date"] { width: calc(50% - 14px); }
  .deals-search { width: 100%; }
  .deals-actions { width: 100%; }
  .deals-table { font-size: 12px; }
  .deals-table th, .deals-table td { padding: 9px 10px; }
  .deals-import-foot { flex-direction: column; align-items: stretch; }
}

/* ══════════ 重复客户审核（第八批）══════════ */
.dup-page { padding: 2px 0 20px; }
.dup-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 12px; }
.dup-kpi { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 3px; }
.dup-kpi-label { font-size: 12px; color: var(--text-3); }
.dup-kpi b { font-size: 22px; line-height: 1.2; }
.dup-kpi small { font-size: 11px; color: var(--text-3); }
.dup-note { background: #F8FAFD; border: 1px solid var(--line); border-radius: 8px; padding: 9px 12px; font-size: 12px; color: var(--text-2); margin-bottom: 12px; line-height: 1.65; }
.dup-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.dup-list { display: flex; flex-direction: column; gap: 12px; }
.dup-card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.dup-card-head { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.dup-card-title { flex: 1; min-width: 200px; font-size: 13px; }
.dup-card-title .muted { font-weight: 400; }
.dup-card-ops { display: flex; gap: 8px; }
.dup-badge { font-size: 11px; padding: 3px 8px; border-radius: 999px; white-space: nowrap; }
.dup-badge-high { background: var(--green-soft); color: var(--green); }
.dup-badge-low { background: var(--orange-soft); color: var(--orange); }
.dup-warn { padding: 8px 14px; background: var(--red-soft); color: #B42318; font-size: 12px; }
.dup-cmp-wrap { overflow-x: auto; }
.dup-cmp { border-collapse: collapse; font-size: 12px; min-width: 100%; }
.dup-cmp th, .dup-cmp td { border-bottom: 1px solid var(--line); padding: 8px 12px; text-align: left; vertical-align: top; }
.dup-cmp thead th { background: #FAFBFD; min-width: 190px; }
.dup-cmp-key { min-width: 112px; width: 112px; color: var(--text-3); font-weight: 500; position: sticky; left: 0; background: var(--card); z-index: 1; }
.dup-cmp thead .dup-cmp-key { background: #FAFBFD; }
.dup-keep { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; cursor: pointer; }
.dup-meta { font-size: 11px; color: var(--text-3); font-weight: 400; line-height: 1.55; margin-top: 4px; }
.dup-name { color: var(--text); font-weight: 600; word-break: break-all; }
.dup-val { display: flex; align-items: flex-start; gap: 6px; cursor: pointer; word-break: break-all; }
.dup-val input, .dup-keep input { margin-top: 2px; accent-color: var(--blue); flex: none; }
.dup-card-foot { padding: 9px 14px; font-size: 11px; color: var(--text-3); background: #FAFBFD; }
.dup-history { display: flex; flex-direction: column; gap: 8px; }
.dup-history-row { background: var(--card); border: 1px solid var(--line); border-radius: 9px; padding: 11px 14px; display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 13px; }
.dup-pager { margin-top: 12px; }
@media (max-width: 820px) {
  .dup-kpis { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; }
  .dup-kpi { flex: 0 0 124px; padding: 9px 11px; }
  .dup-kpi b { font-size: 18px; }
  .dup-kpi small { display: none; }
  .dup-cmp thead th { min-width: 160px; }
  .dup-card-head { align-items: flex-start; }
  .dup-card-ops { width: 100%; }
  .dup-history-row { flex-direction: column; align-items: flex-start; }
}

/* ══════════ B 批 · 提醒中心 ══════════ */
.nc-btn { position: relative; display: inline-flex; align-items: center; gap: 4px; }
.nc-count { display: none; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--red); color: #fff; font-size: 10px; font-weight: 600; align-items: center; justify-content: center; }
.nc-mask { position: fixed; inset: 0; z-index: 120; background: rgba(15, 23, 42, .34); display: flex; justify-content: flex-end; }
.nc-panel { width: 400px; max-width: 100vw; height: 100%; background: #fff; box-shadow: -12px 0 40px rgba(15, 23, 42, .16); display: flex; flex-direction: column; }
.nc-head { display: flex; align-items: flex-start; justify-content: space-between; padding: 18px 18px 12px; border-bottom: 1px solid var(--line); }
.nc-head b { font-size: 15px; }
.nc-sub { font-size: 11px; color: var(--text-3); margin-top: 4px; }
.nc-tools { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.nc-list { flex: 1; overflow: auto; padding: 12px 14px 24px; display: flex; flex-direction: column; gap: 8px; }
.nc-item { border: 1px solid var(--line); border-radius: 9px; padding: 10px 12px; cursor: pointer; background: #fff; transition: border-color .15s, background .15s; }
.nc-item:hover { border-color: var(--blue); background: #F8FAFF; }
.nc-item.is-unread { border-left: 3px solid var(--blue); }
.nc-item-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-bottom: 5px; }
.nc-tags { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; min-width: 0; }
/* 提醒生成后客户已回流 / 转派：显式打标，避免员工点进去才被告知 */
.nc-stale { font-size: 10px; padding: 2px 7px; border-radius: 999px; font-weight: 600; white-space: nowrap; background: var(--orange-soft); color: #92400E; }
.nc-time { font-size: 11px; color: var(--text-4); flex: 0 0 auto; }
.nc-kind { font-size: 10px; padding: 2px 7px; border-radius: 999px; font-weight: 600; }
.nc-kind-due { background: var(--blue-soft); color: var(--blue); }
.nc-kind-stuck { background: var(--red-soft); color: var(--red); }
.nc-kind-expiring { background: var(--orange-soft); color: var(--orange); }
.nc-kind-summary { background: var(--green-soft); color: var(--green); }
.nc-title { font-size: 12.5px; font-weight: 600; color: var(--text); }
.nc-body { font-size: 11.5px; color: var(--text-3); line-height: 1.6; margin-top: 3px; }
@media (max-width: 820px) { .nc-panel { width: 100vw; } }

/* ══════════ B 批 · 提醒设置 ══════════ */
.rm-switch { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-2); cursor: pointer; white-space: nowrap; }
.rm-switch input { accent-color: var(--blue); width: 16px; height: 16px; }

/* ══════════ B 批 · 员工月报 ══════════ */
.mr-page { display: flex; flex-direction: column; gap: 12px; padding-bottom: 24px; }
.mr-toolbar { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.mr-sheet { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 28px 32px 24px; color: var(--text); }
.mr-head { display: flex; justify-content: space-between; align-items: flex-start; border-bottom: 2px solid var(--navy); padding-bottom: 14px; margin-bottom: 16px; }
.mr-brand { font-size: 11px; letter-spacing: .12em; color: var(--blue); font-weight: 700; }
.mr-head h1 { font-size: 24px; margin: 6px 0 8px; letter-spacing: -.4px; }
.mr-meta { font-size: 12px; color: var(--text-3); }
.mr-stamp { text-align: right; font-size: 11px; color: var(--text-4); line-height: 1.5; border: 1px dashed var(--line); padding: 8px 12px; border-radius: 8px; }
.mr-stamp b { font-size: 13px; letter-spacing: .18em; color: var(--navy); }
.mr-warn { background: var(--orange-soft); color: #92400E; border-radius: 8px; padding: 10px 12px; font-size: 12px; display: flex; gap: 8px; align-items: center; margin-bottom: 14px; }
.mr-section-title { font-size: 13px; font-weight: 700; color: var(--navy); margin: 18px 0 10px; padding-left: 9px; border-left: 3px solid var(--blue); }
.mr-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.mr-kpi { border: 1px solid var(--line); border-radius: 9px; padding: 11px 13px; background: #FBFCFE; }
.mr-kpi-label { font-size: 11px; color: var(--text-3); }
.mr-kpi-value { font-size: 20px; font-weight: 700; color: var(--navy); margin-top: 3px; line-height: 1.25; }
.mr-kpi-note { font-size: 10px; color: var(--text-4); margin-top: 3px; }
.mr-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-top: 12px; }
.mr-card { border: 1px solid var(--line); border-radius: 9px; padding: 13px 14px; min-width: 0; }
.mr-card-title { font-size: 12px; font-weight: 700; margin-bottom: 10px; color: var(--text-2); }
.mr-bars { display: flex; flex-direction: column; gap: 6px; }
.mr-bar-row { display: flex; align-items: center; gap: 8px; font-size: 11px; }
.mr-bar-label { width: 86px; flex: 0 0 86px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mr-bar-track { flex: 1; height: 8px; background: #F1F4F9; border-radius: 4px; overflow: hidden; }
.mr-bar-track i { display: block; height: 100%; border-radius: 4px; }
.mr-bar-row b { width: 46px; text-align: right; font-size: 11px; color: var(--text-2); }
.mr-kv { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid #F4F6FA; font-size: 11.5px; }
.mr-kv:last-child { border-bottom: none; }
.mr-kv span:first-child { color: var(--text-3); }
.mr-note { color: var(--text-4); text-align: right; max-width: 65%; line-height: 1.5; }
.mr-table { width: 100%; border-collapse: collapse; font-size: 11.5px; }
.mr-table th { text-align: left; background: #F7F9FC; color: var(--text-3); font-weight: 600; padding: 7px 9px; border-bottom: 1px solid var(--line); }
.mr-table td { padding: 7px 9px; border-bottom: 1px solid #F4F6FA; }
.mr-empty { font-size: 11.5px; color: var(--text-4); padding: 8px 0; }
.mr-tables { align-items: start; }
.mr-foot { margin-top: 20px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 10.5px; color: var(--text-4); line-height: 1.7; }
.mr-sign { display: flex; gap: 28px; margin-top: 14px; font-size: 11.5px; color: var(--text-2); flex-wrap: wrap; }
@media (max-width: 820px) {
  .mr-sheet { padding: 18px 14px; }
  .mr-kpis { grid-template-columns: repeat(2, 1fr); }
  .mr-grid-2 { grid-template-columns: 1fr; }
  .mr-bar-label { width: 66px; flex-basis: 66px; }
}

/* ══════════ B 批 · 现场作业 ══════════ */
.vs-page { display: flex; flex-direction: column; gap: 12px; padding-bottom: 24px; }
.vs-toolbar { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.vs-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.vs-card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 14px; display: flex; flex-direction: column; gap: 9px; }
.vs-card.is-done { opacity: .72; }
.vs-card-head { display: flex; align-items: flex-start; gap: 10px; }
.vs-name { font-size: 14px; font-weight: 700; color: var(--text); word-break: break-all; }
.vs-meta { font-size: 11px; color: var(--text-3); margin-top: 4px; }
.vs-promise { background: #F7F9FC; border-left: 3px solid var(--blue); border-radius: 6px; padding: 8px 10px; font-size: 12px; color: var(--text-2); line-height: 1.6; }
.vs-promise b { display: block; font-size: 10.5px; color: var(--blue); margin-bottom: 2px; }
.vs-facts { display: flex; gap: 12px; flex-wrap: wrap; font-size: 11px; color: var(--text-3); }
.vs-facts span { display: inline-flex; align-items: center; gap: 4px; }
.vs-ops { display: flex; gap: 8px; margin-top: 2px; }
.vs-chips { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.vs-chip { border: 1px solid var(--line); background: #fff; border-radius: 9px; padding: 10px 4px; display: flex; flex-direction: column; align-items: center; gap: 3px; cursor: pointer; transition: all .15s; }
.vs-chip b { font-size: 12.5px; color: var(--text-2); }
.vs-chip small { font-size: 10px; color: var(--text-4); }
.vs-chip.on { border-color: var(--blue); background: var(--blue-soft); box-shadow: 0 0 0 2px rgba(26,86,219,.12); }
.vs-chip.on b { color: var(--blue); }
.vs-chip-ok:hover { border-color: var(--green); }
.vs-chip-no:hover { border-color: var(--red); }
.vs-preview { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.vs-thumb { position: relative; }
.vs-thumb img { width: 74px; height: 74px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }
.vs-thumb a { position: absolute; top: -6px; right: -6px; background: var(--red); border-radius: 50%; width: 18px; height: 18px; display: flex; align-items: center; justify-content: center; cursor: pointer; }
@media (max-width: 820px) {
  .vs-list { grid-template-columns: 1fr; }
  .vs-chips { grid-template-columns: repeat(3, 1fr); }
  .vs-chip { padding: 12px 4px; }
  .vs-chip b { font-size: 14px; }
}

/* ══════════ B 批 · 客户详情现场照片 ══════════ */
.ph-grid { display: flex; gap: 9px; flex-wrap: wrap; }
.ph-item { position: relative; width: 104px; }
.ph-item img { width: 104px; height: 104px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); cursor: zoom-in; display: block; }
.ph-cap { margin-top: 4px; display: flex; flex-direction: column; line-height: 1.4; }
.ph-cap span { font-size: 10.5px; color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ph-cap small { font-size: 9.5px; color: var(--text-4); }
.ph-del { position: absolute; top: -6px; right: -6px; background: var(--red); border-radius: 50%; width: 18px; height: 18px; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.ph-empty { font-size: 11.5px; color: var(--text-4); line-height: 1.7; padding: 2px 0; }

/* ══════════ C 批 · 意向标签 / 实时提醒 / 批量审批 / 模板 / 导入修正 ══════════ */
.intent-bar { border-top: 1px dashed #EEF1F6; padding-top: 10px; }
.intent-chip { border-color: var(--line-3); color: var(--text-2); background: #fff; }
.intent-chip.on { border-color: var(--blue); color: #fff; background: var(--blue); font-weight: 600; }

.live-remind { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; padding: 10px 14px;
  border: 1px solid #C3D6F5; background: #F2F7FF; border-radius: 10px; color: var(--blue); }
.live-remind.has-overdue { border-color: #F5C6C6; background: #FFF5F5; color: var(--red); }
.live-remind .t { flex: 1; min-width: 160px; font-size: 12.5px; line-height: 1.5; }
.live-remind .t .small { color: var(--text-3); }
.live-chips { gap: 8px; flex-wrap: wrap; max-width: 46%; }
.live-chips a { font-size: 11.5px; white-space: nowrap; }

.bulk-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 4px 10px;
  border-bottom: 1px solid var(--line); }
.bulk-bar .rm-switch { font-size: 12px; color: var(--text-2); display: inline-flex; align-items: center; gap: 5px; }

.ft-row { display: flex; align-items: center; gap: 6px; }
.fix-cell, .fix-import { border: 1px solid var(--line-3); border-radius: 6px; padding: 0 6px; font-size: 12px; }
.fix-cell:focus, .fix-import:focus { border-color: var(--blue); outline: none; }
.nc-kind-event { background: #EEE9FF; color: #6D45D6; }

@media (max-width: 820px) {
  .live-remind { flex-wrap: wrap; }
  .live-chips { max-width: 100%; }
  .bulk-bar .small.muted { display: none; }
  .intent-bar .small.muted:last-child { display: none; }
  .ft-row { flex-wrap: wrap; }
  .ft-row .input[data-ft-label] { width: 96px !important; }
  .ft-row .input[data-ft-text] { width: 100% !important; flex: 1 1 100% !important; }
}

/* ══════════ 打印：只留月报正文，A4 友好 ══════════ */
@media print {
  @page { size: A4; margin: 12mm; }
  body { background: #fff !important; }
  .sidebar, .topbar, .no-print, #modal-root, #toast-root, .nc-mask, .nc-btn { display: none !important; }
  .shell { display: block !important; height: auto !important; overflow: visible !important; }
  .main { display: block !important; height: auto !important; overflow: visible !important; }
  .content { display: block !important; padding: 0 !important; overflow: visible !important; height: auto !important; background: #fff !important; }
  .mr-page { padding: 0; gap: 0; }
  .mr-sheet { border: none !important; border-radius: 0 !important; padding: 0 !important; box-shadow: none !important; }
  .mr-card, .mr-kpi, .mr-table, .mr-head { break-inside: avoid; page-break-inside: avoid; }
  .mr-section-title { break-after: avoid; }
  .mr-kpi { background: #fff !important; }
  .mr-bar-track { background: #EEE !important; }
}

/* ══════════ 通话统计（第 0 期） ══════════ */
.cs-page { display: flex; flex-direction: column; gap: 16px; padding-bottom: 24px; }
.cs-toolbar { background: #fff; border: 1px solid var(--line-3); border-radius: 10px; padding: 12px 14px; }
.cs-notice { background: #F0F6FF; border: 1px solid #CFE0FF; border-radius: 10px; padding: 12px 14px; font-size: 12px; line-height: 1.8; color: #28456E; }
.cs-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.cs-kpi { background: #fff; border: 1px solid var(--line-3); border-radius: 10px; padding: 14px; min-width: 0; }
.cs-kpi-label { font-size: 12px; color: var(--text-2); white-space: nowrap; }
.cs-kpi-value { font-size: 24px; font-weight: 700; color: #16233A; margin: 6px 0 2px; white-space: nowrap; }
.cs-kpi-note { font-size: 11px; color: #8A94A6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-card { background: #fff; border: 1px solid var(--line-3); border-radius: 10px; padding: 14px; }
.cs-card-title { font-size: 14px; font-weight: 600; color: #16233A; margin-bottom: 12px; display: flex; align-items: center; gap: 12px; }
.cs-card-title .muted { font-weight: 400; font-size: 12px; }
.cs-check { margin-left: auto; font-size: 12px; font-weight: 400; color: var(--text-2); display: inline-flex; align-items: center; gap: 5px; cursor: pointer; }
.cs-trend { display: flex; gap: 10px; align-items: flex-end; justify-content: flex-start; overflow-x: auto; padding: 4px 0 2px; min-height: 150px; }
/* 固定柱宽：只有一天数据时不至于被 flex 拉成一整块蓝色 */
.cs-trend-col { flex: 0 1 76px; min-width: 46px; max-width: 96px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.cs-trend-val { font-size: 11px; color: var(--text-2); }
.cs-trend-bar { width: 100%; height: 96px; display: flex; align-items: flex-end; background: #F2F5FA; border-radius: 5px; overflow: hidden; }
.cs-trend-bar i { display: block; width: 100%; background: linear-gradient(180deg, #4C8BFF, #1A56DB); border-radius: 5px 5px 0 0; }
.cs-trend-day { font-size: 11px; color: #8A94A6; white-space: nowrap; }
.cs-table-wrap { overflow-x: auto; }
.cs-table { width: 100%; border-collapse: collapse; font-size: 13px; white-space: nowrap; }
.cs-table th, .cs-table td { padding: 9px 10px; border-bottom: 1px solid var(--line-3); text-align: left; }
.cs-table th { color: var(--text-2); font-weight: 600; background: #FAFBFD; position: sticky; top: 0; }
.cs-table td b { color: #1A56DB; }
.cs-ok { color: #0F9D58; font-weight: 600; }
.cs-no { color: #98A1B0; }
.cs-warn { color: #D97706; font-weight: 600; }
.cs-empty-card p { margin: 6px 0; font-size: 13px; line-height: 1.7; }
@media (max-width: 1100px) {
  .cs-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  /* 移动端 KPI 单行横滑，避免把首屏内容挤出去（沿用 round7/8 的收口方式） */
  .cs-kpis { display: flex; overflow-x: auto; gap: 10px; padding-bottom: 4px; scrollbar-width: thin; }
  .cs-kpi { flex: 0 0 132px; min-width: 132px; }
  .cs-kpi-value { font-size: 20px; }
  .cs-notice { font-size: 11px; }
  .cs-trend-col { flex: 0 0 44px; min-width: 44px; }
  .cs-toolbar .input, .cs-toolbar select { flex: 1 1 130px; min-width: 120px; }
}

/* 拨打结果弹窗：工作机回传的接通/时长提示（无数据时整块隐藏） */
.dial-callinfo { background: #EAF1FF; border: 1px solid #CFE0FF; border-radius: 6px; padding: 8px 10px; font-size: 12px; color: #28456E; margin-bottom: 12px; }

/* ══════════ 侧栏子菜单（员工月报 → 员工绩效看板） ══════════ */
.nav.is-grouped .nav-item.nav-sub-item { padding-left: 36px; height: 30px; font-size: 12px; color: #9FB2D0; }
.nav.is-grouped .nav-item.nav-sub-item.on { color: #fff; }
.nav.is-grouped .nav-item.nav-sub-item svg { width: 14px; height: 14px; flex: 0 0 14px; }

/* ══════════ 员工绩效看板 ══════════ */
.pf-board, .pf-preview, .pf-detail { display: flex; flex-direction: column; gap: 14px; min-height: 0; flex: 1; }
.pf-toolbar { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.pf-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.pf-kpi { padding: 14px 16px; }
.pf-list-card { min-height: 0; }
.pf-table-wrap { overflow: auto; }
.pf-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.pf-table th { background: #F5F8FD; color: var(--text-2); font-weight: 600; text-align: left; padding: 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.pf-table td { padding: 10px; border-bottom: 1px solid #F0F3F9; vertical-align: middle; }
.pf-table tbody tr:hover { background: #FAFCFF; }
.pf-grade { display: inline-block; padding: 2px 9px; border-radius: 6px; font-size: 11px; font-weight: 700; white-space: nowrap; }
.pf-grade-A { background: #E4F7EC; color: #087A45; }
.pf-grade-B { background: #E9F1FF; color: #1A56DB; }
.pf-grade-C { background: #FFF3DC; color: #B45309; }
.pf-grade-D { background: #FDECEC; color: #B42318; }
.pf-sheet { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 26px 30px 22px; color: var(--text); }
.pf-head { display: flex; justify-content: space-between; gap: 16px; border-bottom: 2px solid var(--text); padding-bottom: 12px; margin-bottom: 14px; }
.pf-brand { font-size: 11px; letter-spacing: 1px; color: var(--text-4); }
.pf-head h1 { font-size: 20px; margin: 6px 0 8px; letter-spacing: 1px; }
.pf-meta { font-size: 11.5px; color: var(--text-3); line-height: 1.8; }
.pf-stamp { border: 2px solid var(--blue); color: var(--blue); border-radius: 8px; padding: 8px 14px; text-align: center; font-size: 11px; font-weight: 600; height: fit-content; white-space: nowrap; }
.pf-stamp b { font-size: 13px; letter-spacing: 1px; }
.pf-score-table th, .pf-score-table td { border: 1px solid #DDE5F1; padding: 9px 10px; }
.pf-score-table thead th { background: #EEF3FB; text-align: center; }
.pf-score-table tbody td { text-align: center; }
.pf-score-table tbody td:nth-child(2), .pf-score-table tbody td:last-child { text-align: left; }
.pf-total-row td { background: #F7FAFF; font-weight: 600; }
.pf-cell { height: 32px; padding: 4px 6px; font-size: 12px; width: 100%; min-width: 0; }
.pf-extra { margin-top: 14px; }
.pf-veto { font-size: 12px; color: var(--text-2); display: inline-flex; align-items: center; gap: 6px; }
.pf-foot { margin-top: 16px; font-size: 11px; color: var(--text-3); line-height: 1.9; }
.pf-sign { display: flex; gap: 30px; flex-wrap: wrap; margin-top: 14px; color: var(--text-2); }
.pf-note { margin-top: 12px; padding: 10px 12px; background: #FFF8E8; border-radius: 8px; font-size: 12px; line-height: 1.7; }
.pf-adjusted { color: var(--orange); margin-left: 3px; font-size: 11px; }
.pf-config-table td { padding: 6px 8px; }
.pf-config { max-height: 62vh; overflow: auto; }

@media (max-width: 900px) {
  .pf-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pf-sheet { padding: 16px 14px; }
  .pf-head { flex-direction: column; }
  .pf-stamp { align-self: flex-start; }
  .pf-sign { gap: 14px; }
}

@media print {
  .pf-board, .pf-preview .pf-extra, .pf-toolbar { display: none !important; }
  .pf-preview, .pf-detail { display: block !important; height: auto !important; min-height: 0 !important; }
  .pf-sheet { border: none !important; border-radius: 0 !important; padding: 0 !important; box-shadow: none !important; }
  .pf-table, .pf-head, .pf-total-row { break-inside: avoid; page-break-inside: avoid; }
  .pf-cell {
    border: none !important; background: transparent !important; box-shadow: none !important;
    -webkit-appearance: none; appearance: none; padding: 0 !important; color: inherit !important;
  }
  .pf-table tbody tr:hover { background: transparent !important; }
  .pf-grade { border: 1px solid #999; }
}

/* ── 我的客户：企业名称 / 法人姓名模糊搜索（PC 与手机共用同一套 DOM） ── */
.mine-toolbar {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; background: #fff;
  border: 1px solid var(--line); border-radius: 12px;
}
.mine-search-box { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; }
.mine-search-box .input { flex: 1; min-width: 0; max-width: 360px; }
.mine-toolbar .m-filter-summary {
  flex: 0 0 auto; max-width: 42%; font-size: 12px; color: var(--text-3);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
/* 详情页「+N 个号码」在手机端是可点按钮，桌面仍是普通标记 */
.dial-more-btn { border: 0; cursor: pointer; font-family: inherit; }
.dial-more-btn:active { opacity: .75; }

/* ── 第 20 轮：通话明细「列头筛选 + 分页 + 申诉说明」 ── */
#cs-detail-card .cs-card-title { flex-wrap: wrap; }
/* ── 第 21 轮：标题栏新增「导出筛选结果」，窄屏按钮不被压扁 ── */
#cs-detail-card .cs-card-title .btn { flex-shrink: 0; }
#cs-detail-card .cs-check { margin-left: 0; }
.cs-card-title .cs-count { font-size: 12px; font-weight: 400; color: var(--text-3); }
.cs-filter-row th { background: #F7F9FC; padding: 6px 8px; font-weight: 400; white-space: nowrap; }
.cs-f { height: 28px; padding: 2px 6px; font-size: 12px; min-width: 0; }
.cs-filter-row .cs-f { width: 100%; max-width: 116px; }
.cs-dur { display: flex; align-items: center; gap: 4px; }
.cs-dur .cs-f { max-width: none; }
.cs-dur select.cs-f { width: 92px; }
.cs-dur input.cs-f { width: 58px; }
.cs-filter-btns { display: flex; gap: 4px; }
.cs-filter-btns .btn { padding: 4px 8px; }
.cs-help { background: #FFF8E8; border: 1px solid #F5D98B; border-radius: 8px;
  padding: 10px 12px; font-size: 12px; line-height: 1.85; color: #6B4E13; margin-bottom: 12px; }
.cs-help b { color: #8A5A00; }
.cs-help ul { margin: 6px 0 0; padding-left: 18px; }
.cs-help li { margin: 2px 0; }
.cs-dispute-tip { background: #FFF8E8; border: 1px solid #F5D98B; border-radius: 6px;
  padding: 8px 10px; font-size: 12px; line-height: 1.7; color: #6B4E13; margin-bottom: 12px; }
.cs-pager { display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding-top: 12px; margin-top: 12px; border-top: 1px solid var(--line-3);
  font-size: 12px; color: var(--text-2); }
.cs-pager-info b { color: var(--text); }
.cs-pager-size { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.cs-pager-size .input { width: 64px; height: 28px; padding: 2px 6px; font-size: 12px; }
.cs-pager-btns { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.cs-pager-num { min-width: 56px; text-align: center; color: var(--text-3); }
.cs-filter-m { display: grid; gap: 10px; padding: 10px;
  background: #F7F9FC; border: 1px solid var(--line-3); border-radius: 8px; margin-bottom: 12px; }
.cs-filter-field { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--text-2); }
.cs-filter-field .input { width: 100%; }
.cs-filter-actions { display: flex; gap: 8px; }
.cs-filter-actions .btn { flex: 1; }

