:root {
  --bg: #f8fafc;
  --card: #fff;
  --border: #e2e8f0;
  --text: #0f172a;
  --muted: #64748b;
  --primary: #2563eb;
  --primary-soft: #eff6ff;
  --success: #16a34a;
  --warn: #d97706;
  --danger: #dc2626;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
}

/* 嵌入外账中心 2.0 壳层 */
.pricing-workspace { height: 100%; }
.pricing-workspace__body { display: flex; min-height: 0; }
.pricing-workspace .sidebar {
  width: 300px;
  min-width: 280px;
  max-width: 320px;
  border-right: 1px solid var(--border);
  background: #fff;
  display: flex;
  flex-direction: column;
}
.pricing-workspace .sidebar__context {
  font-size: 12px;
  color: var(--muted);
  margin-top: 8px;
}
.pricing-workspace .content { background: #f8fafc; padding: 12px 16px; }
.pricing-workspace .content-inner { max-width: 920px; margin: 0 auto; }
.is-hidden { display: none !important; }

/* 独立页遗留（保留兼容） */
.app { min-height: 100vh; display: flex; flex-direction: column; }

.page-header {
  background: var(--card);
  border-bottom: 1px solid var(--border);
  padding: 16px 24px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
.page-header__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}
.page-header h1 { margin: 0; font-size: 22px; font-weight: 700; }
.page-header p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.header-actions { display: flex; gap: 8px; flex-shrink: 0; }
.btn {
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 13px;
  cursor: pointer;
  transition: .15s;
}
.btn:hover { border-color: #cbd5e1; background: #f8fafc; }
.btn--primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn--primary:hover { background: #1d4ed8; }
.btn--sm { padding: 5px 10px; font-size: 12px; }
.btn--ghost { border-color: transparent; background: transparent; color: var(--primary); }
.btn:disabled { opacity: .45; cursor: not-allowed; }

.stats-row {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
}
.stat-card {
  background: #f1f5f9;
  border-radius: 10px;
  padding: 10px 14px;
  min-width: 100px;
}
.stat-card strong { display: block; font-size: 18px; }
.stat-card span { color: var(--muted); font-size: 12px; }

/* Appointment type tabs */
.type-tabs {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--border);
  margin: 0 -24px;
  padding: 0 24px;
}
.type-tab {
  border: none;
  background: none;
  padding: 10px 16px;
  font-size: 14px;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.type-tab.is-active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.type-tab__source { font-size: 11px; color: #94a3b8; display: block; margin-top: 2px; }
.type-tabs--compact { margin: 0; padding: 0; border-bottom: 1px solid var(--border); }
.type-tabs--compact .type-tab { padding: 8px 14px; font-size: 13px; }
.type-tabs--compact .type-tab__source { display: none; }

/* Workflow steps */
.workflow {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 8px 0 4px;
  overflow-x: auto;
}
.workflow.is-hidden { display: none; }
.workflow-step,
a.workflow-step {
  text-decoration: none;
  color: inherit;
}
.workflow-step {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  border: none;
  background: none;
  cursor: pointer;
  padding: 6px 4px;
  color: var(--muted);
  font-size: 13px;
}
.workflow-step__num {
  width: 22px; height: 22px;
  border-radius: 50%;
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px;
  background: #fff;
}
.workflow-step.is-active { color: var(--primary); font-weight: 600; }
.workflow-step.is-active .workflow-step__num { background: var(--primary); color: #fff; border-color: var(--primary); }
.workflow-step.is-done .workflow-step__num { background: #dcfce7; border-color: #86efac; color: #166534; }
.workflow-arrow { color: #cbd5e1; padding: 0 6px; flex-shrink: 0; }

/* Main layout */
.main { display: flex; flex: 1; min-height: 0; }
.sidebar {
  width: 300px;
  flex-shrink: 0;
  background: var(--card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}
.sidebar__head { padding: 14px; border-bottom: 1px solid var(--border); }
.sidebar__head .search {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 13px;
}
.city-list { flex: 1; overflow-y: auto; }
.city-item {
  display: block;
  width: 100%;
  text-align: left;
  border: none;
  background: none;
  padding: 12px 14px;
  border-bottom: 1px solid #f1f5f9;
  cursor: pointer;
}
.city-item:hover { background: #f8fafc; }
.city-item.is-active { background: var(--primary-soft); border-left: 3px solid var(--primary); }
.city-item__name { font-weight: 600; font-size: 14px; }
.city-item__meta { font-size: 12px; color: var(--muted); margin-top: 4px; display: flex; flex-direction: column; gap: 2px; }
.city-item__summary { color: #64748b; }
.city-item__summary.is-warn { color: var(--warn); }
.tag {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 11px;
  background: #f1f5f9;
  color: #475569;
}
.tag--ok { background: #dcfce7; color: #166534; }
.tag--warn { background: #fef3c7; color: #92400e; }
.tag--muted { background: #f1f5f9; color: #94a3b8; }

.content { flex: 1; overflow-y: auto; padding: 20px 24px; }
.panel { display: none; }
.panel.is-active { display: block; }
.panel-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}
.panel-card__head {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.panel-card__head h2 { margin: 0; font-size: 16px; }
.panel-card__head p { margin: 4px 0 0; font-size: 12px; color: var(--muted); }
.panel-card__body { padding: 16px 18px; }

.sub-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.sub-tab {
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  cursor: pointer;
}
.sub-tab.is-active { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }

.field-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}
.field-item label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 4px;
}
.field-item input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 14px;
}
.field-group-title {
  font-size: 13px;
  font-weight: 600;
  color: #334155;
  margin: 16px 0 10px;
  padding-bottom: 6px;
  border-bottom: 1px dashed var(--border);
}
.field-group-title:first-child { margin-top: 0; }

.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th, .data-table td {
  border-bottom: 1px solid var(--border);
  padding: 10px 12px;
  text-align: left;
}
.data-table th { background: #f8fafc; color: var(--muted); font-weight: 600; font-size: 12px; }
.data-table tr:hover td { background: #fafbfc; }

.platform-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.platform-card {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px;
}
.platform-card__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.platform-icon {
  width: 32px; height: 32px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 13px; color: #fff;
}
.platform-icon--wechat { background: #07c160; }
.platform-icon--douyin { background: #111; }
.platform-icon--xiaohongshu { background: #ff2442; }
.platform-icon--meituan { background: #ffc300; color: #333; }
.platform-icon--alipay { background: #1677ff; }

.switch { position: relative; width: 40px; height: 22px; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch span {
  position: absolute; inset: 0; background: #cbd5e1; border-radius: 22px; cursor: pointer; transition: .2s;
}
.switch span::before {
  content: ''; position: absolute; width: 18px; height: 18px; left: 2px; top: 2px;
  background: #fff; border-radius: 50%; transition: .2s;
}
.switch input:checked + span { background: var(--primary); }
.switch input:checked + span::before { transform: translateX(18px); }

.preview-form {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}
.preview-result {
  background: linear-gradient(135deg, #eff6ff, #f8fafc);
  border: 1px solid #bfdbfe;
  border-radius: var(--radius);
  padding: 18px;
}
.preview-result__price { font-size: 32px; font-weight: 700; color: var(--primary); }
.preview-steps { margin-top: 14px; }
.preview-step {
  display: flex; gap: 10px; padding: 8px 0;
  border-bottom: 1px dashed #e2e8f0;
  font-size: 13px;
}
.preview-step:last-child { border-bottom: none; font-weight: 700; }
.preview-step__prio {
  flex-shrink: 0;
  width: 20px; height: 20px;
  border-radius: 4px;
  background: #e2e8f0;
  font-size: 11px;
  display: flex; align-items: center; justify-content: center;
  color: #475569;
}
.preview-step.is-hit .preview-step__prio { background: var(--primary); color: #fff; }

.priority-box {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 12px;
  color: #92400e;
  margin-bottom: 14px;
}
.priority-box ol { margin: 6px 0 0; padding-left: 18px; }

.pricing-context-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  margin-bottom: 12px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
}
.pricing-context-bar__tags { display: flex; flex-wrap: wrap; gap: 8px; }
.pricing-context-bar__sku { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.pricing-context-bar__select {
  min-width: 200px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 13px;
}
.tag--primary { background: var(--primary-soft); color: var(--primary); border: 1px solid #bfdbfe; }
.tag--soft { background: #f1f5f9; color: #475569; }
.panel-hint { font-size: 12px; color: var(--muted); margin: 0 0 12px; }
.rule-audit { margin-top: 16px; }
.rule-audit strong { display: block; margin-bottom: 8px; font-size: 13px; }
.data-table--compact th, .data-table--compact td { padding: 8px 10px; font-size: 12px; }
.data-table tr.is-hit td { background: #f0fdf4; }
.data-table tr.is-miss td { color: var(--muted); }
.preview-step.is-total { border-top: 2px solid #bfdbfe; margin-top: 6px; padding-top: 12px; }

.workspace-single-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 13px;
}
.workspace-single-head span { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; font-weight: normal; }
.workspace-single-head__link {
  flex-shrink: 0;
  color: var(--primary);
  font-size: 12px;
  text-decoration: none;
  white-space: nowrap;
}
.workspace-single-head__link:hover { text-decoration: underline; }

/* 工作台首页 */
.workbench { display: flex; flex-direction: column; gap: 12px; }
.workbench-section { padding: 0; }
.workbench-section__title { margin: 0; padding: 14px 16px 0; font-size: 14px; font-weight: 600; }
.context-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 20px;
  padding: 12px 16px 16px;
  margin: 0;
}
.context-grid dt { font-size: 12px; color: var(--muted); margin-bottom: 2px; }
.context-grid dd { margin: 0; font-size: 14px; font-weight: 500; }
.inline-select {
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 13px;
  max-width: 100%;
}
.progress-list { list-style: none; margin: 0; padding: 8px 16px 14px; }
.progress-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px dashed #eef2f7;
  font-size: 13px;
}
.progress-list li:last-child { border-bottom: none; }
.progress-list li.is-done strong { color: var(--success); }
.progress-list li.is-todo strong { color: var(--warn); }
.workbench-cta { padding: 16px; text-align: center; background: linear-gradient(180deg, #f8fbff, #fff); }
.workbench-cta__hint { margin: 0 0 12px; font-size: 13px; color: var(--muted); }
.btn--lg { padding: 10px 28px; font-size: 14px; font-weight: 600; }
.workbench-logs { padding: 0 4px 8px; }
.workbench-logs__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
}
.workbench-logs__head a { color: var(--primary); text-decoration: none; font-size: 12px; }
.workbench-logs__body { font-size: 12px; }
.log-item--compact { padding: 6px 0; border-bottom: 1px solid #f1f5f9; line-height: 1.4; }
.log-item--compact.is-muted { color: var(--muted); }
.log-item--compact .log-item__time { display: inline; margin-right: 8px; color: #94a3b8; }

/* 价格预览 · 双视图 Tab */
.preview-page { padding: 4px 0 16px; }
.preview-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0;
}
.preview-tabs__btn {
  border: none;
  background: transparent;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: .15s;
}
.preview-tabs__btn:hover { color: var(--text); }
.preview-tabs__btn.is-active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}
.preview-compare-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 12px;
}
.preview-compare-summary .stat-card { min-width: 88px; }
.preview-compare-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 12px;
  align-items: flex-end;
  margin-bottom: 12px;
  padding: 12px;
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 8px;
}
.preview-compare-filters .field-item { margin: 0; min-width: 120px; }
.preview-compare-filters .field-item label { font-size: 11px; margin-bottom: 4px; }
.preview-compare-filters select,
.preview-compare-filters input[type="text"] {
  width: 100%;
  padding: 6px 8px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 12px;
}
.preview-compare-filters__checks {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
}
.preview-compare-filters__checks label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}
.preview-compare-wrap {
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: auto;
  max-height: calc(100vh - 280px);
  background: #fff;
}
.compare-table {
  width: max-content;
  min-width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.compare-table th,
.compare-table td {
  border: 1px solid #edf0f5;
  padding: 8px 10px;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
}
.compare-table thead th {
  background: #f8fafc;
  font-weight: 600;
  color: #424b59;
  position: sticky;
  top: 0;
  z-index: 2;
}
.compare-table thead tr:nth-child(2) th { top: 37px; z-index: 2; }
.compare-table .col-sticky {
  position: sticky;
  left: 0;
  z-index: 3;
  background: #fff;
  text-align: left;
  min-width: 72px;
}
.compare-table .col-sticky-2 { left: 72px; min-width: 88px; }
.compare-table .col-sticky-3 { left: 160px; min-width: 140px; }
.compare-table .col-sticky-4 { left: 300px; min-width: 72px; text-align: right; }
.compare-table thead .col-sticky,
.compare-table thead .col-sticky-2,
.compare-table thead .col-sticky-3,
.compare-table thead .col-sticky-4 { background: #f8fafc; z-index: 4; }
.compare-table .col-base { font-weight: 600; color: var(--text); }
.compare-table .plat-group { border-left: 2px solid #dbeafe; }
.compare-table .plat-head {
  background: #eff6ff;
  color: #1e40af;
  font-size: 12px;
}
.compare-table .plat-sub { font-size: 11px; color: var(--muted); font-weight: 500; }
.compare-cell__price { font-weight: 600; font-variant-numeric: tabular-nums; }
.compare-cell__state {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
}
.compare-diff--up { color: var(--danger); font-weight: 700; }
.compare-diff--down { color: #0284c7; font-weight: 700; }
.compare-diff--flat { color: var(--muted); }
.compare-diff--badge {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
}
.compare-diff--badge.is-absent { background: #f1f5f9; color: #64748b; }
.compare-diff--badge.is-unsynced { background: #fffbeb; color: #92400e; }
.compare-diff--badge.is-failed {
  background: #fef2f2;
  color: var(--danger);
  cursor: help;
  text-decoration: underline dotted;
}
.compare-table tbody tr.compare-row-link { cursor: pointer; }
.compare-row-link:hover td { background: #f8fbff; }

a.btn { text-decoration: none; display: inline-flex; align-items: center; }

.tag-red { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; padding: 2px 8px; border-radius: 4px; font-size: 12px; }
.tag-green { background: #ecfdf5; color: #166534; padding: 2px 8px; border-radius: 4px; font-size: 12px; }
.tag-orange { background: #fffbeb; color: #92400e; padding: 2px 8px; border-radius: 4px; font-size: 12px; }

.base-quote-wrap { flex: 1; min-height: 0; }
.base-quote-table th,
.base-quote-table td {
  border-top: 0 !important;
  border-left: 0 !important;
  border-right: 1px solid var(--office-border, #e5e7eb) !important;
  border-bottom: 1px solid var(--office-border, #e5e7eb) !important;
}
.base-quote-table th:last-child,
.base-quote-table td:last-child { border-right: 0 !important; }
.base-quote-table th.col-actions-sticky,
.base-quote-table td.col-actions-sticky {
  border-left: 1px solid var(--office-border, #e5e7eb) !important;
}
.base-quote-table .base-th-sku {
  background: #eff6ff;
  color: #1e40af;
  text-align: center;
  border-left: 0 !important;
}
.base-quote-table .base-th-mode {
  background: #f8fbff;
  color: #3b6ea5;
  font-size: 12px;
  font-weight: 600;
  border-left: 0 !important;
}
.base-quote-table .base-th-field {
  font-size: 11px;
  color: var(--muted);
  font-weight: 500;
}
.base-quote-table .base-city-link,
.compare-table .base-city-link {
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
}
.base-quote-table .base-city-link:hover,
.compare-table .base-city-link:hover { text-decoration: underline; }
.base-quote-table thead tr:nth-child(2) th { top: 37px; }
.base-quote-table.base-quote-table--mode-head thead tr:nth-child(3) th { top: 74px; }
.base-import-steps { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; margin:14px 0 16px; }
.base-import-steps>div { display:grid; grid-template-columns:28px 1fr; gap:1px 8px; align-items:center; padding:10px; border:1px solid #e8e8e8; border-radius:6px; background:#fafafa; }
.base-import-steps>div>span { grid-row:1/3; display:flex; width:24px; height:24px; align-items:center; justify-content:center; border-radius:50%; background:#e5e7eb; color:#687282; font-size:12px; }
.base-import-steps>div>strong { font-size:12px; color:#333; }
.base-import-steps>div>small { color:#8c8c8c; font-size:11px; }
.base-import-steps>div.is-active { border-color:#91caff; background:#f0f7ff; }
.base-import-steps>div.is-active>span { background:#1890ff; color:#fff; }
.base-import-drop { display:flex; min-height:142px; flex-direction:column; align-items:center; justify-content:center; gap:8px; border:1px dashed #91caff; border-radius:8px; background:#f7fbff; color:#595959; cursor:pointer; }
.base-import-drop:hover { border-color:#1890ff; background:#f0f7ff; }
.base-import-drop svg { width:30px; height:30px; color:#1890ff; }
.base-import-drop strong { color:#262626; font-size:13px; }
.base-import-drop span { color:#8c8c8c; font-size:12px; }
.base-import-drop span[data-selected="1"] { color:#1890ff; font-weight:600; }
.base-import-demo-row { display:flex; justify-content:center; gap:8px; margin-top:10px; }
.base-import-demo-row .btn-toolbar { gap:6px; }
.base-import-demo-row svg { width:14px; height:14px; }

.empty-state { font-size: 13px; }
.compare-table tbody tr:hover .col-sticky,
.compare-table tbody tr:hover .col-sticky-2,
.compare-table tbody tr:hover .col-sticky-3,
.compare-table tbody tr:hover .col-sticky-4 { background: #f8fbff; }
.compare-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 10px;
  font-size: 11px;
  color: var(--muted);
}
.compare-legend span { display: inline-flex; align-items: center; gap: 4px; }

.compare-price-table .plat-group {
  border-left-color: #dbe5f3;
}
.compare-price-table thead tr:nth-child(1) th.th-group {
  background: #eef4ff;
  color: #1e5f9f;
}

/* 城市报价详情 */
.city-detail-page { padding: 4px 0 20px; }
.city-detail-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.city-detail-header h2 { margin: 0; font-size: 20px; font-weight: 700; }
.city-detail-header p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.city-detail-header__actions { display: flex; gap: 8px; flex-shrink: 0; }
.city-profile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.city-profile-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
}
.city-profile-card span { display: block; font-size: 11px; color: var(--muted); margin-bottom: 4px; }
.city-profile-card strong { font-size: 15px; font-weight: 700; }
.city-detail-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 14px;
}
.city-detail-tabs__btn {
  border: none;
  background: transparent;
  padding: 10px 14px;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.city-detail-tabs__btn.is-active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.city-detail-pane { min-height: 200px; }
.city-detail-section { margin-bottom: 20px; }
.city-detail-section__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.city-detail-section__head h3 { margin: 0; font-size: 15px; font-weight: 700; }
.city-detail-section__meta { font-size: 12px; color: var(--muted); white-space: nowrap; flex-shrink: 0; }
.city-detail-table-wrap {
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: auto;
  background: #fff;
}
.city-detail-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.city-detail-table th,
.city-detail-table td {
  border-bottom: 1px solid #edf0f5;
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}
.city-detail-table thead th {
  background: #f8fafc;
  font-weight: 600;
  color: #424b59;
  white-space: nowrap;
}
.city-detail-table .col-num { text-align: right; font-variant-numeric: tabular-nums; }
.city-detail-table th:nth-child(4),
.city-detail-table td:nth-child(4) { white-space: nowrap; min-width: 108px; }
.city-detail-fields { display: flex; flex-wrap: wrap; gap: 6px 10px; }
.city-detail-fields span {
  background: #f1f5f9;
  border-radius: 4px;
  padding: 2px 6px;
  font-size: 11px;
  color: #475569;
}
.city-detail-compare-filters { margin-bottom: 10px; padding: 10px 12px; }
.city-detail-compare-table .col-sticky { left: 0; min-width: 88px; }
.city-detail-compare-table .col-sticky-2 { left: 88px; min-width: 140px; }
.city-detail-compare-table .col-sticky-3 { left: 228px; min-width: 72px; text-align: right; }

/* 动态调价首页 */
.pricing-home { padding: 8px 0 20px; }
.pricing-home__hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  background: linear-gradient(135deg, #eff6ff, #fff);
  border: 1px solid #dbeafe;
  border-radius: 12px;
  padding: 20px 22px;
  margin-bottom: 14px;
}
.pricing-home__hero h2 { margin: 0 0 6px; font-size: 20px; font-weight: 700; }
.pricing-home__hero p { margin: 0; color: var(--muted); font-size: 13px; max-width: 520px; }
.pricing-home__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.pricing-home__stat {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
  text-align: center;
}
.pricing-home__stat strong { display: block; font-size: 24px; font-weight: 700; line-height: 1.2; }
.pricing-home__stat span { font-size: 12px; color: var(--muted); }
.pricing-home__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.pricing-home__panel {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
}
.pricing-home__panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.pricing-home__panel-head h3 { margin: 0; font-size: 14px; font-weight: 700; }
.pricing-home__panel-head a { font-size: 12px; color: var(--primary); text-decoration: none; }
.pricing-home__links { display: flex; flex-direction: column; gap: 8px; }
.pricing-home__link {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 4px 10px;
  padding: 10px 12px;
  border: 1px solid #edf0f5;
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
  transition: .15s;
}
.pricing-home__link:hover { border-color: #bfdbfe; background: #f8fbff; }
.pricing-home__link i { grid-row: span 2; color: var(--primary); margin-top: 2px; }
.pricing-home__link span { font-size: 13px; font-weight: 600; }
.pricing-home__link em { grid-column: 2; font-size: 11px; color: var(--muted); font-style: normal; }
.pricing-home__logs { display: flex; flex-direction: column; gap: 8px; }
.pricing-home__log {
  display: grid;
  grid-template-columns: 72px 64px 1fr;
  gap: 8px;
  font-size: 12px;
  padding-bottom: 8px;
  border-bottom: 1px dashed #edf0f5;
}
.pricing-home__log:last-child { border-bottom: none; padding-bottom: 0; }
.pricing-home__log-time { color: var(--muted); }
.pricing-home__log-city { color: var(--primary); font-weight: 500; }
@media (max-width: 900px) {
  .pricing-home__stats { grid-template-columns: repeat(2, 1fr); }
  .pricing-home__grid { grid-template-columns: 1fr; }
}

/* 价格预览精简 */
.preview-form--compact { margin-bottom: 12px; }
.preview-actions { margin-bottom: 12px; }
.preview-result--empty {
  background: #f8fafc;
  border: 1px dashed var(--border);
  padding: 20px;
  text-align: center;
}
.preview-result__placeholder { margin: 0; color: var(--muted); font-size: 13px; }
.preview-result__meta { font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.preview-compose { margin-top: 12px; }
.preview-compose__title { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.preview-compose__row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px dashed #eef2f7;
  font-size: 13px;
}
.preview-compose__row.is-total { font-weight: 700; border-top: 2px solid #dbeafe; margin-top: 4px; padding-top: 10px; }
.preview-compose__row.is-muted { color: var(--muted); }
.preview-status {
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 13px;
}
.preview-status--ok { background: #ecfdf5; color: #166534; border: 1px solid #bbf7d0; }
.preview-status--warn { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }
.preview-advanced { margin-top: 14px; font-size: 13px; }
.preview-advanced summary { cursor: pointer; color: var(--primary); padding: 8px 0; }
.preview-advanced summary:hover { text-decoration: underline; }
.priority-box--compact { margin: 10px 0; padding: 10px 12px; font-size: 12px; }
.formula-note { font-size: 12px; color: var(--muted); margin: 10px 0 0; }
.miss-list { margin: 8px 0 0; padding-left: 18px; font-size: 12px; color: var(--muted); }
.pricing-context-bar--compact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  margin-bottom: 10px;
  font-size: 12px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
}
.pricing-context-bar--compact .context-line { color: var(--muted); flex: 1; min-width: 0; }
.pricing-context-bar--compact .pricing-context-bar__select { flex-shrink: 0; }

.empty-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--muted);
}
.empty-state strong { display: block; color: var(--text); margin-bottom: 6px; }

.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.toolbar .spacer { flex: 1; }

/* Drawer（仅 pricing workspace 操作日志；勿影响 #page-drawer 全局遮罩） */
#pricing-workspace-host > .drawer-mask {
  position: fixed; inset: 0; background: rgba(15,23,42,.35);
  z-index: 200; display: none;
}
#pricing-workspace-host > .drawer-mask.is-open { display: block; }
#pricing-workspace-host > .drawer-mask .drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(560px, 100vw);
  background: var(--card); z-index: 201;
  transform: translateX(100%); transition: .25s;
  display: flex; flex-direction: column;
  box-shadow: -4px 0 24px rgba(0,0,0,.1);
}
#pricing-workspace-host > .drawer-mask.is-open .drawer { transform: translateX(0); }
.drawer__head { padding: 16px 18px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.drawer__body { flex: 1; overflow-y: auto; padding: 16px 18px; }
.drawer__foot { padding: 14px 18px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 8px; }

.log-item { padding: 10px 0; border-bottom: 1px solid #f1f5f9; font-size: 13px; }
.log-item__time { color: var(--muted); font-size: 12px; }
.log-item__user { color: var(--primary); }

@media (max-width: 900px) {
  .main { flex-direction: column; }
  .sidebar { width: 100%; max-height: 220px; }
}

/* 城市报价详情 · 侧开抽屉 */
.pricing-city-drawer .drawer-body { padding-top: 12px; }

.drawer-danger-actions {
  margin-top: 16px;
  display: flex;
  justify-content: flex-start;
}
.pricing-city-drawer .city-detail-section { margin-bottom: 16px; }
.pricing-city-drawer .city-detail-table-wrap { max-height: min(52vh, 520px); }
.pricing-city-drawer .preview-compare-wrap { max-height: min(52vh, 520px); }
.pricing-city-drawer .empty-state { padding: 24px 8px; color: var(--muted); }
.city-detail-table tr.is-highlight-route td { background: #eef6ff; }
.cell-link { color: #1890ff; cursor: pointer; }
.cell-link:hover { text-decoration: underline; }

/* 2.4 客服排班矩阵 · 资源分组嵌套表单 */
.v24-schedule { padding: 12px 16px 16px; }
.page-list-shell .v24-schedule:not([data-sched-embed="1"]) {
  padding: 0 0 12px;
}
.v24-sched-bar {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  padding-bottom: 10px; border-bottom: 1px solid var(--office-border, #edf0f5);
}
.page-list-shell .v24-sched-bar--page {
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px 16px;
}
.page-list-shell .v24-sched-bar-main {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  flex: 1 1 auto;
  min-width: 0;
}
.page-list-shell .v24-sched-bar--page .v24-sched-stats {
  margin-left: 0;
  flex: 0 0 auto;
  align-self: flex-start;
  padding-top: 1px;
}
.v24-sched-bar .drawer-input { height: 34px; font-size: 13px; }
.v24-sched-month {
  flex: 0 0 140px;
  width: 140px;
  min-width: 140px;
  max-width: 140px;
}
.v24-sched-search {
  flex: 0 0 180px;
  width: 180px;
  min-width: 180px;
  max-width: 180px;
}
.v24-sched-tools { display: flex; flex-wrap: wrap; gap: 6px; }
.v24-sched-tool,
.v24-sched-chip {
  height: 32px; padding: 0 10px; border-radius: 6px; border: 1px solid #dfe5ee;
  background: #f6f8fb; color: #424b59; font-size: 12px; cursor: pointer;
}
.v24-sched-tool.is-on,
.v24-sched-chip.is-on { background: #eef4ff; border-color: #91caff; color: #1890ff; }
.v24-sched-chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px 0; }
.v24-sched-lock { font-size: 13px; color: #303846; }
.v24-sched-note { font-size: 12px; color: #8c8c8c; margin: 8px 0 0; line-height: 1.6; }
.v24-sched-dirty {
  margin-top: 8px; padding: 8px 12px; border-radius: 6px; background: #fff7e6;
  border: 1px solid #ffd591; color: #ad6800; font-size: 12px;
}
.v24-sched-stats {
  margin-left: auto; display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: #8c8c8c;
}
.v24-sched-stats div { display: flex; flex-direction: column; align-items: flex-end; min-width: 72px; }
.v24-sched-stats b { font-size: 14px; color: #303846; font-weight: 600; }
.v24-schedule-grid { max-height: min(62vh, 640px); margin-top: 8px; }
.v24-schedule-table th.is-weekend,
.v24-schedule-table td.is-weekend { color: #389e0d; }
.v24-sched-date {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  border: none; background: transparent; cursor: pointer; padding: 0; color: inherit; font: inherit;
}
.v24-sched-date small { font-size: 11px; opacity: .85; }
.v24-sched-cell {
  min-width: 36px; height: 36px; cursor: cell; font-size: 12px; vertical-align: middle;
  user-select: none;
}
.v24-sched-cell.is-selected { background: #bae0ff !important; outline: 1px solid #1890ff; }
.v24-schedule-table .sticky { position: sticky; z-index: 2; background: #fff; }
.v24-schedule-table .sticky-0 { left: 0; min-width: 44px; }
.v24-schedule-table .sticky-1 { left: 44px; min-width: 72px; }
.v24-schedule-table .sticky-2 { left: 116px; min-width: 72px; }
.v24-schedule-table .sticky-3 { left: 188px; min-width: 120px; box-shadow: 4px 0 8px rgba(0,0,0,.04); }
.v24-sched-dayhead { padding: 8px 0 12px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; font-size: 13px; }
.v24-shift-edit {
  display: grid; grid-template-columns: 72px 1fr 1fr auto; gap: 8px; align-items: center;
  padding: 8px 0; border-bottom: 1px solid #f0f0f0; font-size: 13px;
}
.v24-shift-next { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
#page-drawer .v24-nested-form.v24-nested-side > .drawer-mask {
  position: absolute; inset: 0; background: rgba(17, 24, 39, 0.42);
}
#page-drawer .v24-nested-form.v24-nested-side > .drawer-panel {
  position: relative; z-index: 1; height: 100%; max-height: 100%;
  width: min(960px, 96vw); box-shadow: -8px 0 32px rgba(17, 24, 39, 0.15);
}
#page-drawer.v24-form-drawer > .drawer-panel.v24-form-panel,
#page-drawer .v24-nested-form.v24-nested-side > .drawer-panel.v24-form-panel {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-height: 100%;
  min-height: 0;
}
#page-drawer.v24-form-drawer .v24-form-panel > .drawer-body,
#page-drawer .v24-nested-form.v24-nested-side .v24-form-panel > .drawer-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}
#page-drawer .v24-form-panel > .drawer-footer {
  flex-shrink: 0;
  margin-top: auto;
}
.v24-view-field .v24-view-value {
  min-height: 34px; padding: 6px 11px; font-size: 13px; color: #303846; line-height: 1.5;
  background: #fafbfc; border: 1px solid #edf0f5; border-radius: 6px; word-break: break-word;
}
.v24-view-field .v24-view-value--block { min-height: auto; }
.v24-view-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.v24-cond-table { width: 100%; font-size: 13px; margin-top: 8px; }

/* D8 报价说明配置 */
.v24-quote-note {
  background: #fff;
  min-height: 0;
  height: 100%;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
html.v23-embed .v23-embed-root--quote-note,
html.v23-embed .v23-embed-root--quote-note #list-table-host {
  height: 100%;
  min-height: 0;
  flex: 1 1 auto;
}
.v24-quote-note__scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 16px 20px 12px;
  background: #fff;
}
/* 底栏与详情 Tab drawer-footer--pane 一致：灰底贴齐 iframe/内容区四边（仅上边框分隔） */
.v24-quote-note > .drawer-footer.drawer-footer--pane,
.v24-quote-note__footer.drawer-footer--pane {
  flex: 0 0 auto;
  width: 100%;
  margin: 0 !important;
  padding: 14px 28px !important;
  box-sizing: border-box;
  border-top: 1px solid var(--office-border, #edf0f5);
  border-radius: 0;
  background: #f4f6f9 !important;
  justify-content: flex-end !important;
  gap: 0;
}
.v24-quote-note > .drawer-footer .drawer-footer-actions {
  justify-content: flex-end;
  gap: 12px;
  width: 100%;
}
.v24-quote-note > .drawer-footer .btn-drawer {
  height: 36px;
  min-height: 36px;
  flex-shrink: 0;
  white-space: nowrap;
}
.v24-quote-note > .drawer-footer .v24-quote-note__apply {
  min-width: 0;
  max-width: min(100%, 280px);
  overflow: hidden;
  text-overflow: ellipsis;
}
@media (min-width: 900px) {
  .v24-quote-note > .drawer-footer .v24-quote-note__apply {
    max-width: none;
    overflow: visible;
    text-overflow: clip;
  }
}
html.v23-embed #list-table-host:has(.v24-quote-note),
html.v23-embed .page-list-shell:has(.v24-quote-note) .flex-1.min-h-0 {
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1 1 auto;
}
html.v23-embed #list-table-host > .v24-quote-note {
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
}
html.v23-embed .v23-embed-root:has(.v24-quote-note) {
  height: 100%;
  min-height: 0 !important;
}
html.v23-embed:has(.v24-quote-note) html,
html.v23-embed:has(.v24-quote-note) body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
}
html.v23-embed:has(.v24-quote-note) #app-root {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
html.v23-embed:has(.v24-quote-note) .page-list-shell {
  flex: 1 1 auto;
  min-height: 0;
}
html.v23-embed:has(.v24-quote-note) #list-table-host {
  padding: 0;
  flex: 1 1 auto;
  min-height: 0;
}
html.v23-embed:has(.v24-quote-note) #page-drawer.open.is-center-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex !important;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.45);
}
html.v23-embed:has(.v24-quote-note) #page-drawer.open.is-center-modal .config-form-dialog {
  position: relative;
  max-height: calc(100vh - 48px);
}
.v24-qn-conds { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.v24-qn-cond-row { display: flex; align-items: flex-start; gap: 12px; font-size: 13px; }
.v24-qn-cond-label { width: 72px; flex-shrink: 0; color: #8c8c8c; line-height: 34px; }
.v24-qn-cond-chips { display: flex; flex-wrap: wrap; gap: 8px; flex: 1; min-width: 0; }
.v24-qn-chip {
  height: 34px; padding: 0 12px; border-radius: 8px; border: 1px solid transparent;
  background: #f6f8fb; color: #424b59; font-size: 13px; cursor: pointer;
}
.v24-qn-chip:hover:not(:disabled) { background: #eef6ff; color: #1890ff; }
.v24-qn-chip.is-active { background: #eef4ff; color: #1890ff; border-color: #c8dfff; font-weight: 500; }
.v24-qn-chip.is-readonly { cursor: default; }
.v24-qn-main {
  display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 16px; align-items: start;
}
@media (max-width: 1100px) { .v24-qn-main { grid-template-columns: 1fr; } }
.v24-qn-aside {
  border: 1px solid #edf0f5; border-radius: 8px; padding: 12px; background: #fafbfc;
  max-height: min(640px, calc(100vh - 320px)); overflow-y: auto;
}
.v24-qn-aside-title { font-size: 14px; font-weight: 600; color: #303846; margin-bottom: 6px; }
.v24-qn-aside-tip { font-size: 12px; color: #8a93a3; margin: 0 0 10px; line-height: 1.5; }
.v24-qn-field-group { margin-bottom: 12px; }
.v24-qn-field-group-title { font-size: 12px; color: #8c8c8c; margin-bottom: 6px; }
.v24-qn-field-list { display: flex; flex-wrap: wrap; gap: 6px; }
.v24-qn-field-chip {
  height: 28px; padding: 0 10px; border-radius: 6px; border: 1px solid #dbeafe;
  background: #eef4ff; color: #1890ff; font-size: 12px; cursor: pointer;
}
.v24-qn-field-chip:hover { background: #dbeafe; }
.v24-qn-editors { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.v24-qn-editor { border: 1px solid #edf0f5; border-radius: 8px; overflow: hidden; background: #fff; }
.v24-qn-editor-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 12px; border-bottom: 1px solid #f0f0f0; background: #fafafa;
}
.v24-qn-editor-title { font-size: 14px; font-weight: 600; color: #303846; }
.v24-qn-editor-meta { font-size: 12px; color: #8a93a3; text-align: right; }
.v24-qn-toolbar {
  display: flex; gap: 4px; padding: 6px 10px; border-bottom: 1px solid #f0f0f0; background: #fff;
}
.v24-qn-tool {
  min-width: 32px; height: 28px; padding: 0 8px; border: 1px solid #edf0f5; border-radius: 6px;
  background: #fff; color: #595959; font-size: 12px; cursor: pointer;
}
.v24-qn-tool:hover { border-color: #91caff; color: #1890ff; }
.v24-qn-body {
  min-height: 160px; max-height: 280px; overflow-y: auto; padding: 12px 14px;
  font-size: 13px; line-height: 1.65; color: #303846; outline: none;
}
.v24-qn-token {
  display: inline-flex; align-items: center; gap: 2px; margin: 0 2px; padding: 0 6px; height: 22px;
  border-radius: 4px; background: #eef4ff; color: #1890ff; border: 1px solid #c8dfff;
  font-size: 12px; vertical-align: middle;
}
.v24-qn-token-del {
  border: none; background: transparent; color: #1890ff; cursor: pointer;
  padding: 0 2px; line-height: 1; font-size: 14px;
}
.v24-qn-token-del:hover { color: #ff4d4f; }
