/* 小物在线系统工作台 —— 布局与组件样式（引用 tokens.css，不写裸 hex） */

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, sans-serif;
  background: var(--grad-page);
  color: var(--text-primary);
  font-size: var(--fs-base);
}
a { color: var(--accent-500); text-decoration: none; }

.zs-app { display: flex; height: 100vh; overflow: hidden; }

/* ===== 侧栏 ===== */
.zs-sidebar {
  width: 232px; flex: 0 0 232px;
  background: linear-gradient(180deg, var(--sidebar-bg) 0%, var(--sidebar-bg-2) 100%);
  color: var(--sidebar-text);
  display: flex; flex-direction: column;
}
.zs-brand { padding: 22px 20px 18px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.zs-brand-title { font-size: var(--fs-md); font-weight: 700; color: #fff; }
.zs-brand-sub { font-size: var(--fs-xs); color: rgba(255,255,255,0.5); margin-top: 2px; }
.zs-nav { padding: 12px 12px; overflow-y: auto; flex: 1; }
.zs-nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 14px; border-radius: var(--radius-sm); cursor: pointer;
  color: var(--sidebar-text); font-size: var(--fs-base); margin-bottom: 4px; transition: background .15s;
}
.zs-nav-item:hover { background: rgba(255,255,255,0.06); color: #fff; }
.zs-nav-item.active { background: var(--sidebar-active-bg); color: var(--sidebar-text-active); font-weight: 600; }
.zs-nav-icon { width: 18px; height: 18px; display: inline-block; opacity: .9; }
.zs-sidebar-foot { padding: 14px 18px; font-size: var(--fs-xs); color: rgba(255,255,255,0.4); border-top: 1px solid rgba(255,255,255,0.08); }

/* ===== 主区 ===== */
.zs-main { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
.zs-topbar {
  height: 60px; flex: 0 0 60px; background: var(--topbar-bg);
  border-bottom: 1px solid var(--border-light);
  display: flex; align-items: center; justify-content: space-between; padding: 0 24px;
  box-shadow: var(--shadow-sm);
}
.zs-topbar-left { font-size: var(--fs-md); font-weight: 700; }
.zs-topbar-right { display: flex; align-items: center; gap: 14px; }
.zs-mode-badge {
  font-size: var(--fs-xs); padding: 4px 10px; border-radius: var(--radius-full);
  background: var(--brand-100); color: var(--brand-700); font-weight: 600;
}
.zs-user-chip { display: flex; align-items: center; gap: 8px; font-size: var(--fs-sm); color: var(--text-regular); }
.zs-user-avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--grad-accent); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: var(--fs-sm); font-weight: 700; }
.zs-content { flex: 1; overflow-y: auto; padding: 24px; }

/* ===== 视图头 ===== */
.view-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 18px; gap: 16px; flex-wrap: wrap; }
.view-title { font-size: var(--fs-xl); font-weight: 700; margin: 0; }
.view-desc { color: var(--text-secondary); font-size: var(--fs-sm); margin: 6px 0 0; }

/* ===== 工具栏（列表筛选） ===== */
.zs-toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 14px; }
.zs-toolbar .zs-input { min-width: 140px; }
.zs-toolbar .zs-input[style*="min-width:160px"] { min-width: 200px; }

/* ===== KPI ===== */
.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.kpi-card {
  background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md);
  padding: 18px 20px; box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
}
.kpi-card::after { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--accent-500); }
.kpi-brand::after { background: var(--accent-500); }
.kpi-success::after { background: var(--success); }
.kpi-gold::after { background: var(--brand-500); }
.kpi-info::after { background: var(--info); }
.kpi-danger::after { background: var(--danger); }
.kpi-label { color: var(--text-secondary); font-size: var(--fs-sm); }
.kpi-value { font-size: var(--fs-xxxl); font-weight: 800; margin: 6px 0 2px; line-height: 1.1; }
.kpi-gold .kpi-value { color: var(--brand-600); }
.kpi-brand .kpi-value { color: var(--accent-600); }
.kpi-info .kpi-value { color: var(--info); }
.kpi-success .kpi-value { color: var(--success); }
.kpi-danger .kpi-value { color: var(--danger); }
.kpi-sub { color: var(--text-placeholder); font-size: var(--fs-xs); }

/* ===== 图表区 ===== */
.dash-charts { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 16px; margin-top: 16px; }
.chart-card { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: 16px; box-shadow: var(--shadow-sm); }
.chart-title { font-size: var(--fs-sm); font-weight: 600; color: var(--text-regular); margin-bottom: 10px; }
.chart-box { min-height: 240px; }
.chart-box-center { display: flex; flex-direction: column; align-items: center; justify-content: center; }
.zs-chart { width: 100%; }
.zs-chart-axis { font-size: 10px; fill: var(--text-placeholder); }
.zs-donut-center { font-size: 20px; font-weight: 800; fill: var(--text-primary); }
.zs-donut-sub { font-size: 11px; fill: var(--text-secondary); }
.zs-legend { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; font-size: var(--fs-xs); color: var(--text-regular); }
.zs-legend-item { display: inline-flex; align-items: center; gap: 6px; }
.zs-legend-item i { width: 10px; height: 10px; border-radius: 2px; display: inline-block; }
.zs-fault-legend { width: 100%; margin-top: 10px; }
.zs-fault-row { display: flex; justify-content: space-between; font-size: var(--fs-xs); color: var(--text-secondary); padding: 3px 0; border-bottom: 1px dashed var(--border-light); }

/* ===== 工具栏 / 表单 ===== */
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; align-items: center; }
.zs-input {
  height: 36px; padding: 0 12px; border: 1px solid var(--border-regular); border-radius: var(--radius-sm);
  background: var(--bg-card); color: var(--text-primary); font-size: var(--fs-sm); min-width: 160px; outline: none;
}
.zs-input:focus { border-color: var(--brand-500); box-shadow: var(--ring-brand); }
textarea.zs-input { height: auto; padding: 8px 12px; min-width: 100%; }
.zs-btn {
  height: 36px; padding: 0 16px; border: 1px solid var(--border-regular); border-radius: var(--radius-sm);
  background: var(--bg-card); color: var(--text-regular); font-size: var(--fs-sm); cursor: pointer; transition: all .15s;
}
.zs-btn:hover { border-color: var(--brand-500); color: var(--brand-700); }
.zs-btn-brand { background: var(--grad-brand); border: none; color: var(--accent-700); font-weight: 600; box-shadow: var(--shadow-gold); }
.zs-btn-brand:hover { background: var(--grad-brand-press); color: var(--accent-700); }
.zs-btn-ghost { background: transparent; }
.zs-btn-danger { background: var(--danger-bg); border-color: var(--danger-bg); color: var(--danger); }
.zs-btn-danger:hover { background: var(--danger); color: #fff; }
.zs-btn-sm { height: 30px; padding: 0 10px; font-size: var(--fs-xs); }

.period-tabs { display: inline-flex; background: var(--gray-100); border-radius: var(--radius-full); padding: 4px; }
.period-tab { border: none; background: transparent; padding: 6px 14px; border-radius: var(--radius-full); cursor: pointer; font-size: var(--fs-sm); color: var(--text-secondary); }
.period-tab.active { background: var(--bg-card); color: var(--brand-700); font-weight: 600; box-shadow: var(--shadow-sm); }

/* ===== 表格 ===== */
.table-wrap { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); overflow: auto; box-shadow: var(--shadow-sm); }
.zs-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.zs-table th { text-align: left; padding: 12px 14px; background: var(--gray-50); color: var(--text-secondary); font-weight: 600; border-bottom: 1px solid var(--border-light); white-space: nowrap; }
.zs-table td { padding: 11px 14px; border-bottom: 1px solid var(--border-light); color: var(--text-regular); white-space: nowrap; }
.zs-table tbody tr:hover { background: var(--bg-hover); }

/* ===== 徽章 ===== */
.badge { display: inline-block; padding: 2px 9px; border-radius: var(--radius-full); font-size: var(--fs-xs); font-weight: 600; }
.badge-success { background: var(--success-bg); color: var(--success); }
.badge-warning { background: var(--warning-bg); color: var(--warning); }
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-info { background: var(--info-bg); color: var(--info); }
.badge-muted { background: var(--gray-100); color: var(--text-secondary); }
.badge-brand { background: var(--brand-100); color: var(--brand-700); }
.badge-primary { background: var(--brand-100); color: var(--brand-700); }

/* ===== 加载 / 空态 ===== */
.zs-loading, .zs-empty { padding: 40px; text-align: center; color: var(--text-placeholder); font-size: var(--fs-sm); }
.muted { color: var(--text-placeholder); }

/* ===== 模态 ===== */
.zs-modal-overlay { position: fixed; inset: 0; background: var(--bg-mask); display: flex; align-items: center; justify-content: center; z-index: 1000; }
.zs-modal { width: 560px; max-width: 92vw; max-height: 88vh; overflow: auto; background: var(--bg-card); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }
.zs-modal-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--border-light); font-weight: 700; }
.zs-modal-x { border: none; background: transparent; font-size: 22px; cursor: pointer; color: var(--text-secondary); line-height: 1; }
.zs-modal-body { padding: 20px; }
.zs-modal-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-item { display: flex; flex-direction: column; gap: 6px; }
.form-item label { font-size: var(--fs-xs); color: var(--text-secondary); }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; }
.detail-item { display: flex; flex-direction: column; gap: 3px; }
.detail-k { font-size: var(--fs-xs); color: var(--text-secondary); }
.detail-v { font-size: var(--fs-sm); color: var(--text-primary); font-weight: 500; }
.detail-desc { margin-top: 16px; font-size: var(--fs-sm); color: var(--text-regular); line-height: 1.6; }
.detail-actions { margin-top: 18px; display: flex; gap: 10px; flex-wrap: wrap; }

/* ===== 业态多选（客户可同时经营多种业态） ===== */
.zt-types { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 2px; }
.zt-type { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid var(--border-regular); border-radius: var(--radius-sm); background: var(--bg-card); font-size: var(--fs-sm); color: var(--text-primary); cursor: pointer; user-select: none; transition: all .15s; }
.zt-type:hover { border-color: var(--brand-400); }
.zt-type input { width: 14px; height: 14px; accent-color: var(--brand-500); cursor: pointer; }
.zt-type:has(input:checked) { border-color: var(--brand-500); background: var(--brand-50); color: var(--brand-700); font-weight: 600; }

/* ===== Toast ===== */
#zs-toast { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 2000; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.zs-toast-item { padding: 10px 18px; border-radius: var(--radius-sm); color: #fff; font-size: var(--fs-sm); box-shadow: var(--shadow-md); transition: opacity .3s; }
.zs-toast-info { background: var(--accent-500); }
.zs-toast-success { background: var(--success); }
.zs-toast-danger { background: var(--danger); }
.zs-toast-hide { opacity: 0; }

/* ===== 登录 ===== */
/* ===== 登录页（美化版 · 左右分栏品牌卡）===== */
.lg-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: var(--sp-lg); background: var(--grad-page); }
.lg-card { display: grid; grid-template-columns: 1.05fr 1fr; width: 100%; max-width: 880px; background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-xl); overflow: hidden; box-shadow: var(--shadow-lg); }
.lg-brand { position: relative; display: flex; flex-direction: column; padding: var(--sp-xxl) 34px; background: var(--grad-accent); color: var(--text-inverse); overflow: hidden; }
.lg-brand::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--grad-brand); }
.lg-brand::before { content: ""; position: absolute; right: -60px; top: -60px; width: 200px; height: 200px; border-radius: 50%; background: var(--sidebar-active-bg); }
.lg-logo { position: relative; width: 52px; height: 52px; border-radius: var(--radius-md); background: var(--grad-brand); color: var(--accent-700); font-weight: var(--fw-bold); font-size: var(--fs-xl); display: flex; align-items: center; justify-content: center; margin-bottom: var(--sp-lg); box-shadow: var(--shadow-gold); }
.lg-brand-title { position: relative; font-size: var(--fs-xl); font-weight: var(--fw-bold); margin: 0 0 6px; line-height: 1.3; }
.lg-brand-sub { position: relative; color: var(--sidebar-text); font-size: var(--fs-sm); margin: 0 0 var(--sp-lg); letter-spacing: 1px; }
.lg-feats { position: relative; list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.lg-feats li { position: relative; padding-left: 20px; font-size: var(--fs-sm); color: var(--sidebar-text); line-height: 1.5; }
.lg-feats li::before { content: ""; position: absolute; left: 0; top: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--brand-400); }
.lg-brand-foot { position: relative; margin-top: var(--sp-xl); padding-top: var(--sp-lg); border-top: 1px solid var(--sidebar-active-bg); font-size: var(--fs-xs); color: var(--sidebar-text); }
.lg-form { display: flex; flex-direction: column; padding: var(--sp-xxl) 34px; }
.lg-form-title { font-size: var(--fs-xl); font-weight: var(--fw-bold); color: var(--text-primary); margin: 0 0 4px; }
.lg-form-sub { color: var(--text-secondary); font-size: var(--fs-sm); margin: 0 0 22px; }
.lg-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.lg-field label { font-size: var(--fs-xs); color: var(--text-secondary); }
.lg-field .zs-input { min-width: 0; width: 100%; }
.lg-submit { width: 100%; justify-content: center; height: 44px; margin-top: 6px; font-size: var(--fs-md); letter-spacing: 2px; }
.lg-demo { margin-top: var(--sp-lg); padding-top: var(--sp-md); border-top: 1px dashed var(--border-light); }
.lg-demo-title { font-size: var(--fs-xs); color: var(--text-secondary); margin-bottom: 10px; }
.lg-demo-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.lg-quick { flex: 1; min-width: 132px; justify-content: center; }
.lg-hint { margin-top: var(--sp-md); font-size: var(--fs-xs); color: var(--text-placeholder); line-height: 1.6; }
/* ★ 2026-11-02：登录失败时的应急入口说明（lg-fallback 由 JS 控制显隐） */
.lg-demo-note { margin-top: 10px; font-size: var(--fs-xs); color: var(--text-placeholder); line-height: 1.7; }
.lg-fallback .lg-demo-title { color: var(--text-secondary); font-weight: var(--fw-medium); }
@media (max-width: 720px) {
  .lg-card { grid-template-columns: 1fr; }
  .lg-brand { padding: var(--sp-xl) 24px; }
  .lg-feats { display: none; }
  .lg-form { padding: var(--sp-xl) 24px; }
}

@media (max-width: 1100px) {
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .dash-charts { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .zs-sidebar { display: none; }
  .kpi-grid { grid-template-columns: 1fr; }
}

/* ===== 侧栏分组标题 ===== */
.zs-nav-group { font-size: var(--fs-xs); color: rgba(255,255,255,0.45); text-transform: uppercase; letter-spacing: .05em; padding: 16px 14px 6px; }

/* ===== 投诉台 KPI 行 ===== */
.kpi-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin-bottom: 18px; }
.kpi-warning::after { background: var(--warning); }
.kpi-warning .kpi-value { color: var(--warning); }
.kpi-muted::after { background: var(--gray-400); }
.kpi-muted .kpi-value { color: var(--text-secondary); }
.nowrap { white-space: nowrap; }

/* ===== 设计规范页 ===== */
.dg-section { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: 18px 20px; margin-bottom: 16px; box-shadow: var(--shadow-sm); }
.dg-h3 { font-size: var(--fs-md); font-weight: 700; margin: 0 0 14px; }
.dg-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 12px; }
.dg-swatch { display: flex; flex-direction: column; gap: 6px; }
.dg-color { height: 46px; border-radius: var(--radius-sm); border: 1px solid var(--border-light); }
.dg-name { font-size: var(--fs-xs); font-weight: 600; color: var(--text-regular); }
.dg-var { font-size: var(--fs-xs); color: var(--text-placeholder); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.dg-info { font-size: var(--fs-sm); color: var(--text-regular); line-height: 1.7; }

/* ===== 招商租赁线新增样式 ===== */
/* 演示数据徽标 */
.view-demo { display: inline-block; padding: 3px 10px; border-radius: var(--radius-full); font-size: var(--fs-xs); font-weight: 600; background: var(--brand-100); color: var(--brand-700); align-self: flex-start; }

/* 分段切换（按企业/按房间、财务三表） */
.seg { display: inline-flex; gap: 4px; background: var(--gray-100); padding: 4px; border-radius: var(--radius-md); }
.seg-btn { border: none; background: transparent; padding: 7px 16px; border-radius: var(--radius-sm); font-size: var(--fs-sm); font-weight: 600; color: var(--text-secondary); cursor: pointer; }
.seg-btn.on { background: var(--bg-card); color: var(--brand-700); box-shadow: var(--shadow-sm); }

/* 双列图表区 */
.ov-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
.chart-card { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: 16px 18px; box-shadow: var(--shadow-sm); }
.chart-title { font-size: var(--fs-md); font-weight: 700; margin: 0 0 12px; }
.ov-center-label { text-align: center; font-size: var(--fs-sm); color: var(--text-secondary); margin-top: 6px; }

/* 迷你汇总条（应收催缴 / 财务档案） */
.ov-kpi-mini { display: flex; flex-wrap: wrap; gap: 18px; padding: 12px 16px; background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.ov-kpi-mini span { font-size: var(--fs-sm); color: var(--text-secondary); }
.ov-kpi-mini b { color: var(--text-primary); font-weight: 700; }

/* 折叠/展开行 */
.more-row td { text-align: center; padding: 12px; background: var(--gray-50); color: var(--text-secondary); font-size: var(--fs-sm); }

/* 应收催缴：企业分组行 / 子账单 */
tr.grp { background: var(--gray-50); }
tr.grp td { font-weight: 600; border-top: 1px solid var(--border-light); }
tr.bill.sub td { background: var(--bg-card); padding-left: 28px; }
tr.bill.sub:hover td { background: var(--bg-hover); }
.lnk { color: var(--brand-600); cursor: pointer; font-size: var(--fs-sm); font-weight: 600; }

/* 表格内小按钮 / 文本色 */
.ib { border: 1px solid var(--border-light); background: var(--bg-card); border-radius: var(--radius-sm); width: 26px; height: 26px; cursor: pointer; color: var(--text-secondary); font-size: var(--fs-sm); }
.ib:hover { border-color: var(--brand-500); color: var(--brand-700); }
.m-red { color: var(--danger); }
.muted { color: var(--text-placeholder); }

/* 招商漏斗 */
.funnel { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.fn-row { display: grid; grid-template-columns: 132px 1fr 96px; align-items: center; gap: 10px; font-size: var(--fs-sm); }
.fn-lab { color: var(--text-regular); font-weight: 600; }
.fn-bar-wrap { background: var(--gray-100); border-radius: var(--radius-sm); overflow: hidden; height: 22px; }
.fn-bar { height: 100%; background: linear-gradient(90deg, var(--brand-600), var(--accent-500)); border-radius: var(--radius-sm); }
.fn-num { text-align: right; color: var(--text-secondary); }

/* 模态内表单 / 文书 / 催收记录 */
.form-row { display: flex; gap: 12px; margin-bottom: 12px; font-size: var(--fs-sm); }
.form-row label { width: 84px; flex: 0 0 84px; color: var(--text-secondary); padding-top: 7px; }
.form-row > div { flex: 1; color: var(--text-regular); padding-top: 7px; }
.doc-acts { display: flex; gap: 10px; margin-top: 16px; }
.doc-acts .zs-btn { flex: 1; justify-content: center; }
.doc-text { width: 100%; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: var(--fs-sm); line-height: 1.7; }
.urge-log { white-space: pre-wrap; color: var(--text-secondary); font-size: var(--fs-xs); line-height: 1.6; }
/* 审计日志明细（本次迭代阶段 1 子任务 3）：JSON 明细等宽展示，复用令牌不写裸 hex */
.al-detail { margin: 0; white-space: pre-wrap; word-break: break-all; color: var(--text-secondary); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: var(--fs-xs); line-height: 1.6; max-height: 320px; overflow: auto; }

/* 分页 */
.pager { display: flex; align-items: center; gap: 12px; margin-top: 14px; }
.pager .zs-btn[disabled] { opacity: .45; cursor: not-allowed; }
.pg-info { font-size: var(--fs-sm); color: var(--text-secondary); }

/* 移动端：双列图表落单列 */
@media (max-width: 1100px) { .ov-2col { grid-template-columns: 1fr; } }

/* 合同管理 / 渠道联通 补充样式 */
.m-warn { color: var(--warning); font-weight: 600; }
.zs-table-sm { font-size: var(--fs-xs); }
.zs-table-sm td { padding: 7px 10px; }
.card-block { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: var(--sp-md); }
.cl-list { list-style: none; margin: 4px 0 0; padding: 0; }
.cl-list li { padding: 7px 0 7px 16px; position: relative; font-size: var(--fs-sm); color: var(--text-regular); border-bottom: 1px dashed var(--border-light); }
.cl-list li:last-child { border-bottom: 0; }
.cl-list li::before { content: ''; position: absolute; left: 0; top: 14px; width: 6px; height: 6px; border-radius: 50%; background: var(--brand-500); }

/* 费项图例（应收催缴） */
.fee-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 12px 0 4px; }
.fl-label { font-size: var(--fs-sm); color: var(--text-secondary); }
.fl-chip { font-size: var(--fs-xs); padding: 3px 10px; border-radius: 999px; background: var(--bg-soft); color: var(--text-secondary); border: 1px solid var(--border-light); }
.fl-chip.fl-new { background: rgba(200,162,75,.14); color: var(--brand-600); border-color: rgba(200,162,75,.5); font-weight: 600; }

/* ===== 商业综合体视图补充样式（多业态新增 · 2026-10-15） ===== */
/* 指标条 / 卡片 */
.stat-strip { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 14px; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat-card { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: 14px 16px; min-width: 120px; }
.stat-card.stat-warn { border-color: var(--warning); box-shadow: inset 3px 0 0 var(--warning); }
.stat-num { font-size: 22px; font-weight: 700; color: var(--text-primary); line-height: 1.2; }
.stat-label { font-size: var(--fs-xs); color: var(--text-secondary); margin-top: 4px; }

/* 经营分析布局 */
.ca-content { padding-top: 4px; }
.ca-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 900px) { .ca-grid { grid-template-columns: 1fr; } }
.ca-block { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: 16px; }
.ca-block-title { font-size: var(--fs-sm); font-weight: 600; color: var(--text-primary); margin-bottom: 12px; }

/* 分布条形 */
.bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 9px; }
.bar-label { width: 84px; flex: 0 0 84px; font-size: var(--fs-xs); color: var(--text-secondary); text-align: right; }
.bar-track { flex: 1; height: 14px; background: var(--bg-hover); border-radius: var(--radius-full); overflow: hidden; }
.bar-fill { display: block; height: 100%; border-radius: var(--radius-full); }
.bar-val { width: 32px; flex: 0 0 32px; font-size: var(--fs-xs); color: var(--text-primary); font-weight: 600; text-align: left; }
.bar-primary { background: var(--brand-500); }
.bar-info { background: var(--info); }
.bar-success { background: var(--success); }
.bar-warning { background: var(--warning); }
.bar-danger { background: var(--danger); }
.bar-muted { background: var(--text-secondary); }

/* 提示条 */
.zs-tip { font-size: var(--fs-xs); color: var(--text-secondary); padding: 8px 12px; background: var(--bg-hover); border-radius: var(--radius-sm); margin-bottom: 12px; }
.zs-tip-warn { color: var(--warning); background: var(--warning-bg); }
.zs-tip-danger { color: var(--danger); background: var(--danger-bg); }

/* 餐饮合规：记录区 */
.record-head { font-size: var(--fs-sm); font-weight: 600; color: var(--text-primary); margin: 14px 0 8px; }
.record-add { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 10px; }
.record-add .zs-input { min-width: 100px; }

/* ===== 部署业态开关：首次部署向导 + 业态卡片 ===== */
.zs-wizard-overlay {
  position: fixed; inset: 0; background: rgba(15, 23, 42, 0.55);
  display: flex; align-items: center; justify-content: center; z-index: 1000; padding: 20px;
}
.zs-wizard {
  background: var(--bg-card); border-radius: var(--radius-lg); max-width: 660px; width: 100%;
  padding: 28px; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}
.zs-wizard-head { font-size: var(--fs-lg); font-weight: 700; color: var(--text-primary); }
.zs-wizard-sub { margin: 8px 0 18px; color: var(--text-secondary); font-size: var(--fs-xs); line-height: 1.6; }
.zs-wizard-types, .dc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.zs-type-card {
  display: flex; flex-direction: column; gap: 4px; border: 1px solid var(--border-light);
  border-radius: var(--radius-md); padding: 14px; cursor: pointer; background: var(--bg-card); transition: 0.15s;
}
.zs-type-card:hover { border-color: var(--brand-500); }
.zs-type-card.on, .dc-card.on { border-color: var(--brand-500); background: var(--brand-500-bg); }
.zs-type-icon { font-size: 26px; }
.zs-type-label { font-weight: 600; color: var(--text-primary); font-size: var(--fs-sm); }
.zs-type-desc { font-size: var(--fs-xs); color: var(--text-secondary); line-height: 1.5; }
.zs-wizard-actions, .dc-actions { display: flex; gap: 10px; align-items: center; margin-top: 18px; }
.zs-wizard-actions { justify-content: flex-end; }
.dc-content { max-width: 760px; }
.dc-actions { justify-content: flex-start; }

/* ===== 平台级总后台（SaaS 多租户愿景 · 平台超管专属）===== */
.pd-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 960px) { .pd-grid { grid-template-columns: 1fr; } }
.pd-card { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); overflow: hidden; }
.pd-card-h { padding: 14px 16px; border-bottom: 1px solid var(--border-light); font-weight: 700; color: var(--text-regular); display: flex; align-items: center; justify-content: space-between; }
.pd-card-b { padding: 14px 16px; }
.mod-group { margin-bottom: 16px; }
.mod-group:last-child { margin-bottom: 0; }
.mod-group-h { font-weight: 600; color: var(--text-regular); margin-bottom: 8px; display: flex; align-items: center; gap: 8px; }
.mod-count { color: var(--text-secondary); font-weight: 400; font-size: var(--fs-sm); }
.mod-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.mod-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px dashed var(--border-light); }
.mod-row:last-child { border-bottom: 0; }
.mod-row-info { min-width: 0; }
.mod-row-name { font-weight: 600; color: var(--text-regular); }
.mod-row-desc { font-size: var(--fs-xs); color: var(--text-secondary); margin-top: 2px; }
.pd-summary { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.pd-summary-item { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: 12px 16px; min-width: 150px; }
.pd-summary-val { font-size: var(--fs-xl); font-weight: 800; color: var(--accent-600); }
.pd-summary-label { font-size: var(--fs-sm); color: var(--text-secondary); margin-top: 2px; }
/* 模块授权（按客户逐家）：左客户列表 + 右授权矩阵 */
.ma-layout { display: grid; grid-template-columns: 300px 1fr; gap: 16px; align-items: start; }
@media (max-width: 960px) { .ma-layout { grid-template-columns: 1fr; } }
.ma-cust { padding: 10px 12px; border: 1px solid var(--border-light); border-radius: var(--radius-md); margin-bottom: 10px; cursor: pointer; transition: 0.15s; background: var(--bg-card); }
.ma-cust:hover { border-color: var(--brand-500); }
.ma-cust.on { border-color: var(--brand-500); background: var(--brand-500-bg); }
.ma-cust-name { font-weight: 600; color: var(--text-primary); margin-bottom: 6px; }
.ma-cust-meta { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 4px; }
.ma-cust-mod { font-size: var(--fs-xs); color: var(--text-secondary); }
.ma-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding-bottom: 12px; margin-bottom: 8px; border-bottom: 1px solid var(--border-light); color: var(--text-secondary); font-size: var(--fs-sm); }
.ma-toolbar-btns { margin-left: auto; display: flex; gap: 8px; }
/* 业务模块数据汇总卡（总平台只看汇总，不落业务明细） */
.mod-stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 10px; }
.mod-stat { border: 1px solid var(--border-light); border-radius: var(--radius-md); padding: 10px 12px; background: var(--bg-card); }
.mod-stat-head { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-weight: 600; color: var(--text-regular); font-size: var(--fs-sm); }
.mod-stat-cust { font-weight: 400; font-size: var(--fs-xs); color: var(--text-secondary); background: var(--gray-100); border-radius: 10px; padding: 1px 7px; }
.mod-stat-val { font-size: var(--fs-xl); font-weight: 800; color: var(--accent-600); line-height: 1.2; margin-top: 6px; }
.mod-stat-label { font-size: var(--fs-xs); color: var(--text-secondary); }
.mod-stat-sub { font-size: var(--fs-xs); color: var(--text-secondary); margin-top: 4px; }
/* 平台总览：分布条（业态 / 状态） */
.pf-dist { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; font-size: var(--fs-sm); }
.pf-dist:last-child { margin-bottom: 0; }
.pf-dist-label { width: 96px; color: var(--text-regular); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pf-dist-bar { flex: 1; height: 8px; border-radius: 4px; background: var(--gray-100); overflow: hidden; }
.pf-dist-bar i { display: block; height: 100%; background: var(--brand-500); border-radius: 4px; }
.pf-dist-val { width: 56px; text-align: right; color: var(--text-secondary); }



/* ============================================================
 * 账号安全页（本次迭代 R12 新增：登录设备管理 + 共享口令轮换）
 *
 * ★ 样式纪律：全部走 tokens.css 的 CSS 变量令牌，**零裸 hex**。
 *   门禁 tools/tests/verify-session-revoke.js 会扫描本段并断言无裸 hex。
 *   需要新颜色时先在 tokens.css 里加令牌，不要在这里写死色值。
 * ============================================================ */
.acct-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 16px; margin-bottom: 16px; }
.acct-card { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); padding: 16px 18px; }
.acct-card-wide { margin-top: 0; }
.acct-card-head { margin-bottom: 12px; }
.acct-card-title { font-size: var(--fs-md); font-weight: 700; color: var(--text-primary); }
.acct-card-desc { font-size: var(--fs-sm); color: var(--text-secondary); margin-top: 4px; }

/* 当前身份：两列键值表（label 固定宽度，value 自适应） */
.acct-kv { display: grid; grid-template-columns: 76px 1fr; gap: 8px 12px; font-size: var(--fs-sm); }
.acct-kv-label { color: var(--text-secondary); }
.acct-kv-value { color: var(--text-regular); font-weight: 500; word-break: break-all; }

/* 提示条：默认信息态，warn 态用于「这是全平台共享口令」这种高风险说明 */
.acct-tip { border-radius: var(--radius-sm); padding: 10px 12px; font-size: var(--fs-sm); line-height: 1.6; background: var(--info-bg); color: var(--text-regular); border-left: 3px solid var(--info); }
.acct-tip-warn { background: var(--warning-bg); border-left-color: var(--warning); margin-bottom: 14px; }
.acct-tip strong { color: var(--text-primary); }

/* 轮换表单 */
.acct-form { display: flex; flex-direction: column; gap: 12px; }
.acct-field { display: flex; flex-direction: column; gap: 6px; }
.acct-label { font-size: var(--fs-sm); color: var(--text-secondary); }
.acct-check { display: flex; align-items: flex-start; gap: 8px; font-size: var(--fs-sm); color: var(--text-regular); line-height: 1.5; cursor: pointer; }
.acct-check input { margin-top: 3px; flex: none; }
.acct-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.acct-hint { font-size: var(--fs-xs); color: var(--text-secondary); }

/* 设备行：UA 一行 + 脱敏会话 ID 一行 */
.acct-device { display: flex; align-items: center; gap: 8px; white-space: normal; color: var(--text-regular); }
.acct-badge-current { flex: none; font-size: var(--fs-xs); font-weight: 600; padding: 1px 7px; border-radius: var(--radius-full); background: var(--success-bg); color: var(--success); }
.acct-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: var(--fs-xs); color: var(--text-secondary); margin-top: 3px; }

/* ===== 滞纳金规则（账单管理 → 滞纳金规则 tab · 2026-10-27 新增）=====
 * ★ 全部走 tokens.css 的设计令牌，禁止裸 hex（本仓 style-lint 规则）：
 *   日费率是「凭空向业主收多少钱」的总闸门，界面状态必须一眼可辨 ——
 *   生效中用 success、未启用用 warning，颜色语义与审计页 / 账单页保持一致。
 */
.pm-lf-card { max-width: 820px; }
.pm-lf-head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--sp-md); flex-wrap: wrap; margin-bottom: var(--sp-md); }
.pm-lf-title { font-size: var(--fs-md); font-weight: 700; margin: 0; }
.pm-lf-status { flex: none; font-size: var(--fs-xs); font-weight: 600; padding: 3px 10px; border-radius: var(--radius-full); border: 1px solid transparent; }
.pm-lf-status.on { background: var(--success-bg); color: var(--success); border-color: var(--success); }
.pm-lf-status.off { background: var(--warning-bg); color: var(--warning); border-color: var(--warning); }
.pm-lf-switch { display: flex; align-items: flex-start; gap: var(--sp-sm); font-size: var(--fs-sm); color: var(--text-regular); line-height: 1.5; cursor: pointer; }
.pm-lf-switch input { margin-top: 3px; flex: none; }
.pm-lf-ops { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: var(--sp-md); padding-top: var(--sp-md); border-top: 1px solid var(--border-light); }
