/* =========================================================
   StoreCalc 5.0 · 全国 49 城 GIS 工作台
   ========================================================= */
:root {
  --ink: #0b1220;
  --ink-2: #111c31;
  --slate-900: #0f172a;
  --slate-800: #1e293b;
  --text: #172033;
  --text-2: #334155;
  --muted: #5b6b82;
  --faint: #5f6f85;
  --line: #e2e8f0;
  --line-2: #eef2f7;
  --bg: #f2f5fa;
  --paper: #ffffff;
  --blue: #2563eb;
  --blue-600: #1d4ed8;
  --blue-soft: #eff5ff;
  --cyan: #0ea5e9;
  --emerald: #10b981;
  --emerald-soft: #ecfdf5;
  --amber: #f59e0b;
  --amber-soft: #fffbeb;
  --rose: #ef4444;
  --rose-soft: #fff1f2;
  --violet: #8b5cf6;
  --violet-soft: #f5f3ff;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 12px 30px -18px rgba(15, 23, 42, .18);
  --shadow-lg: 0 24px 60px -30px rgba(15, 23, 42, .35);
  --topbar-h: 76px;
  --tabs-h: 64px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --mono: "SF Mono", "Cascadia Code", "JetBrains Mono", Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(1100px 420px at 12% -8%, rgba(37, 99, 235, .08), transparent 60%),
    radial-gradient(900px 380px at 90% 0%, rgba(14, 165, 233, .06), transparent 55%),
    var(--bg);
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p { margin: 0; }
b, strong { font-weight: 650; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
::selection { background: #bfdbfe; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.hidden { display: none !important; }
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon {
  width: 18px; height: 18px; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.7;
  stroke-linecap: round; stroke-linejoin: round;
}
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* ---------------- 顶部导航 ---------------- */
.topbar {
  position: sticky; top: 0; z-index: 1000;
  background: linear-gradient(105deg, #0a1120 0%, #0e1a2f 52%, #0b1729 100%);
  color: #e2e8f0;
  border-bottom: 1px solid rgba(148, 163, 184, .16);
  box-shadow: 0 12px 30px -24px rgba(2, 6, 23, .9);
}
.topbar::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(620px 90px at 18% 0%, rgba(59, 130, 246, .16), transparent 70%);
}
.topbar-inner {
  position: relative; z-index: 1;
  max-width: 1540px; margin: 0 auto; min-height: var(--topbar-h);
  padding: 12px 26px;
  display: flex; align-items: center; gap: 24px;
}
.brand { display: flex; align-items: center; gap: 11px; flex: none; }
.brand-mark {
  width: 36px; height: 36px; flex: none; display: block; border-radius: 10px;
  filter: drop-shadow(0 8px 18px rgba(37, 99, 235, .45));
}
.brand-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.brand-title { display: flex; align-items: center; gap: 6px; font-size: 19px; font-weight: 750; letter-spacing: .2px; color: #f8fafc; white-space: nowrap; }
.brand-title .ver {
  display: inline-block; flex: none; vertical-align: 2px;
  padding: 1px 6px; border-radius: 6px; white-space: nowrap;
  font-size: 10px; letter-spacing: .08em;
  color: #dbeafe; background: rgba(59, 130, 246, .22); border: 1px solid rgba(147, 197, 253, .3);
}
.brand-sub { font-size: 10.5px; color: #94a3b8; letter-spacing: .04em; white-space: nowrap; }
.top-controls { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.top-status {
  display: inline-flex; align-items: center; gap: 7px;
  height: 38px; padding: 0 11px; border-radius: 10px;
  font-size: 11px; color: #cbd5e1; white-space: nowrap;
  background: rgba(148, 163, 184, .08);
  border: 1px solid rgba(148, 163, 184, .16);
}
.top-status .dot { width: 6px; height: 6px; border-radius: 50%; background: #94a3b8; box-shadow: 0 0 0 3px rgba(148, 163, 184, .12); }
.top-status.live { color: #bbf7d0; background: rgba(16, 185, 129, .1); border-color: rgba(16, 185, 129, .25); }
.top-status.live .dot { background: #34d399; box-shadow: 0 0 0 3px rgba(16, 185, 129, .16); }
.top-status.model { color: #fde68a; background: rgba(245, 158, 11, .09); border-color: rgba(245, 158, 11, .22); }
.top-status.model .dot { background: #fbbf24; box-shadow: 0 0 0 3px rgba(245, 158, 11, .15); }
.top-status small { color: #94a3b8; font-size: 10px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 38px; padding: 0 14px;
  border-radius: 10px; border: 1px solid var(--line);
  background: #fff; color: var(--text-2); font-weight: 600; font-size: 12.5px;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease;
  white-space: nowrap;
}
.btn:hover { border-color: #cbd5e1; box-shadow: 0 8px 18px -12px rgba(15, 23, 42, .35); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn .icon { width: 16px; height: 16px; }
.btn.primary {
  background: linear-gradient(135deg, #2f6fed, #1d4ed8);
  border-color: #1d4ed8; color: #fff;
  box-shadow: 0 12px 24px -12px rgba(37, 99, 235, .65);
}
.btn.primary:hover { background: linear-gradient(135deg, #2563eb, #1e40af); }
.btn.dark { background: var(--slate-900); border-color: var(--slate-900); color: #f8fafc; }
.btn.light { background: #f8fafc; border-color: #e2e8f0; color: var(--slate-900); }
.btn.ghost { background: #fff; }
.btn.ghost-dark { background: rgba(255, 255, 255, .06); border-color: rgba(148, 163, 184, .28); color: #e2e8f0; }
.btn.ghost-dark:hover { background: rgba(255, 255, 255, .12); }
.btn.top-btn { height: 38px; min-height: 38px; background: rgba(255, 255, 255, .08); border-color: rgba(148, 163, 184, .24); color: #e2e8f0; }
.btn.top-btn:hover { background: rgba(255, 255, 255, .14); }
.btn.top-btn.ghost { background: transparent; }
.btn.small { min-height: 32px; padding: 0 11px; font-size: 12px; border-radius: 8px; }
.btn.block { width: 100%; }
.btn.big { min-height: 46px; font-size: 14px; border-radius: 12px; }
.btn.danger { color: #b91c1c; border-color: #fecaca; background: #fff7f7; }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
#btn-to-model.blocked { background: #fee2e2; border-color: #fca5a5; color: #991b1b; opacity: 1; }
#btn-to-model.blocked .icon { color: #991b1b; }
.link-btn {
  border: 0; background: none; padding: 0; color: var(--blue);
  font-size: 12px; font-weight: 600; display: inline-flex; align-items: center; gap: 4px;
}
.link-btn:hover { text-decoration: underline; }
.link-btn.light { color: #93c5fd; }
.link-btn.danger { color: #dc2626; }

/* 城市切换 */
.city-combo { position: relative; }
.combo-trigger {
  display: flex; align-items: center; gap: 9px;
  min-width: 216px; height: 44px; padding: 6px 11px;
  border-radius: 11px; border: 1px solid rgba(148, 163, 184, .26);
  background: rgba(255, 255, 255, .06); color: #e2e8f0;
  transition: background .16s ease, border-color .16s ease;
}
.combo-trigger:hover { background: rgba(255, 255, 255, .11); border-color: rgba(147, 197, 253, .4); }
.combo-trigger > .icon { color: #93c5fd; }
.combo-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 0; line-height: 1.25; }
.combo-copy b { font-size: 13px; color: #f1f5f9; font-weight: 650; }
.combo-copy small { font-size: 10px; color: #94a3b8; }
.combo-trigger .chev { margin-left: auto; width: 15px; height: 15px; color: #94a3b8; transition: transform .2s ease; }
.city-combo.open .combo-trigger .chev { transform: rotate(180deg); }
.combo-pop {
  position: absolute; top: calc(100% + 9px); left: 0; width: 390px; max-width: 88vw;
  background: #fff; color: var(--text); border: 1px solid var(--line);
  border-radius: 16px; box-shadow: var(--shadow-lg); overflow: hidden;
  z-index: 1200; animation: popIn .16s ease;
}
@keyframes popIn { from { opacity: 0; transform: translateY(-5px) scale(.99); } to { opacity: 1; transform: none; } }
.combo-search { display: flex; align-items: center; gap: 8px; padding: 11px 12px; border-bottom: 1px solid var(--line-2); }
.combo-search .icon { width: 16px; height: 16px; color: var(--muted); }
.combo-search input { flex: 1; border: 0; outline: none; font-size: 13px; min-width: 0; }
.combo-search input::placeholder { color: var(--faint); }
.combo-search kbd { font-size: 9px; padding: 2px 5px; border: 1px solid var(--line); border-radius: 5px; color: var(--faint); background: #f8fafc; }
.combo-meta { padding: 7px 13px 5px; font-size: 10.5px; color: var(--muted); border-bottom: 1px solid var(--line-2); }
.combo-list { max-height: 348px; overflow-y: auto; padding: 5px; }
.city-group-label { padding: 8px 9px 3px; font-size: 9.5px; font-weight: 700; letter-spacing: .14em; color: var(--faint); text-transform: uppercase; }
.city-option {
  width: 100%; display: flex; align-items: center; gap: 9px;
  padding: 8px 9px; border: 0; border-radius: 9px; background: none; text-align: left;
}
.city-option:hover, .city-option.focused { background: #f1f5f9; }
.city-option.current { background: var(--blue-soft); }
.city-option-main { display: flex; flex-direction: column; min-width: 0; }
.city-option-main b { font-size: 12.5px; font-weight: 650; }
.city-option-main small { font-size: 10px; color: var(--muted); }
.city-option .tier-chip {
  margin-left: auto; font-size: 9.5px; font-weight: 650;
  padding: 2px 6px; border-radius: 5px; white-space: nowrap;
  color: var(--blue-600); background: var(--blue-soft); border: 1px solid #dbeafe;
}
.city-option .tier-chip.t1 { color: #7c3aed; background: var(--violet-soft); border-color: #ede9fe; }
.city-option .tier-chip.t2 { color: #0f766e; background: #f0fdfa; border-color: #ccfbf1; }
.city-empty { padding: 22px; text-align: center; color: var(--muted); font-size: 12px; }

/* 业态选择 */
.industry-picker {
  position: relative; display: flex; align-items: center; gap: 8px;
  height: 44px; padding: 6px 10px; border-radius: 11px;
  border: 1px solid rgba(148, 163, 184, .26);
  background: rgba(255, 255, 255, .06);
  transition: background .16s ease, border-color .16s ease;
}
.industry-picker:hover { background: rgba(255, 255, 255, .11); border-color: rgba(147, 197, 253, .4); }
.picker-icon { width: 27px; height: 27px; border-radius: 8px; display: grid; place-items: center; background: rgba(59, 130, 246, .18); color: #93c5fd; }
.picker-icon .icon { width: 15px; height: 15px; }
.picker-copy { display: flex; flex-direction: column; line-height: 1.2; min-width: 118px; }
.picker-copy small { font-size: 9.5px; color: #94a3b8; }
.industry-picker select {
  appearance: none; -webkit-appearance: none;
  border: 0; outline: none; background: transparent; color: #f1f5f9;
  font-size: 12.5px; font-weight: 650; padding: 0 14px 0 0; cursor: pointer;
  width: 168px;
}
.industry-picker select option { color: var(--text); background: #fff; }
.industry-picker .chev { width: 14px; height: 14px; color: #94a3b8; position: absolute; right: 9px; top: 15px; pointer-events: none; }

/* ---------------- 模块 Tabs ---------------- */
.tabs {
  position: sticky; top: var(--topbar-h); z-index: 900;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.tabs-inner {
  max-width: 1540px; margin: 0 auto; padding: 0 26px;
  display: flex; align-items: stretch; gap: 4px; min-height: var(--tabs-h);
}
.tab {
  position: relative; display: flex; align-items: center; gap: 11px;
  padding: 0 20px; border: 0; background: none; color: var(--muted);
  transition: color .16s ease, background .16s ease;
}
.tab::after {
  content: ""; position: absolute; left: 18px; right: 18px; bottom: 0; height: 2.5px;
  border-radius: 3px 3px 0 0; background: transparent; transition: background .16s ease;
}
.tab:hover { color: var(--text); background: rgba(248, 250, 252, .7); }
.tab.active { color: var(--text); }
.tab.active::after { background: linear-gradient(90deg, #2563eb, #0ea5e9); }
.tab .step {
  width: 27px; height: 27px; border-radius: 50%;
  display: grid; place-items: center; flex: none;
  font-family: var(--mono); font-size: 10px; font-weight: 700;
  color: #94a3b8; background: #f1f5f9; border: 1px solid #e2e8f0;
  transition: all .16s ease;
}
.tab.active .step { color: #fff; background: linear-gradient(135deg, #2563eb, #0ea5e9); border-color: transparent; box-shadow: 0 4px 10px -4px rgba(37, 99, 235, .7); }
.tab-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; line-height: 1.2; }
.tab-copy b { font-size: 12.5px; font-weight: 650; }
.tab-copy small { font-size: 9.5px; color: var(--faint); letter-spacing: .02em; }
.tabs-right { margin-left: auto; display: flex; align-items: center; gap: 9px; padding: 10px 0; font-size: 11px; color: var(--muted); }
.tabs-right b { color: var(--text-2); font-weight: 650; }
.tabs-right .sep { width: 1px; height: 16px; background: var(--line); }

/* ---------------- 通用布局 ---------------- */
.main { max-width: 1540px; margin: 0 auto; padding: 26px; }
.page { display: none; animation: pageIn .28s ease both; }
.page.active { display: block; }
@keyframes pageIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 20px; }
.eyebrow {
  display: inline-block; font-family: var(--mono); font-size: 9.5px; font-weight: 700;
  letter-spacing: .16em; color: var(--blue); text-transform: uppercase;
  padding: 3px 8px; border-radius: 5px; background: var(--blue-soft); border: 1px solid #dbeafe;
}
.eyebrow.light { color: #bfdbfe; background: rgba(59, 130, 246, .16); border-color: rgba(147, 197, 253, .28); }
.page-head h2 { margin-top: 7px; font-size: 27px; letter-spacing: -.02em; font-weight: 750; line-height: 1.2; }
.page-head p { margin-top: 5px; max-width: 720px; color: var(--muted); font-size: 12.5px; }
.head-chips { display: flex; gap: 9px; flex: none; }
.head-chip {
  min-width: 130px; padding: 9px 13px; border-radius: 12px;
  background: rgba(255, 255, 255, .7); border: 1px solid var(--line);
  box-shadow: 0 1px 2px rgba(15, 23, 42, .03);
  display: flex; flex-direction: column; line-height: 1.28;
}
.head-chip small { font-size: 9.5px; color: var(--faint); letter-spacing: .06em; }
.head-chip b { font-size: 16px; font-weight: 750; font-variant-numeric: tabular-nums; }
.head-chip span { font-size: 9.5px; color: var(--muted); }
.applied-chip {
  display: inline-flex; align-items: center; gap: 8px; flex: none;
  padding: 9px 13px; border-radius: 11px;
  background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow);
  font-size: 11.5px; color: var(--text-2);
}
.applied-chip b { font-weight: 700; }
.applied-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--emerald); box-shadow: 0 0 0 3px rgba(16, 185, 129, .14); }
.applied-chip small { color: var(--faint); }

.card {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.card-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 14px;
  margin-bottom: 15px;
}
.card-head h3 { font-size: 14.5px; font-weight: 700; letter-spacing: -.01em; }
.card-sub { margin-top: 2px; font-size: 10.5px; color: var(--muted); line-height: 1.45; }
.hint { font-size: 10.5px; color: var(--muted); }
.data-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 7px; border-radius: 6px; white-space: nowrap;
  font-size: 9.5px; font-weight: 700; letter-spacing: .02em;
  color: #92400e; background: var(--amber-soft); border: 1px solid #fde68a;
}
.data-badge.official { color: #047857; background: var(--emerald-soft); border-color: #a7f3d0; }
.data-badge.live { color: #1d4ed8; background: var(--blue-soft); border-color: #bfdbfe; }
.data-badge.measured { color: #6d28d9; background: var(--violet-soft); border-color: #ddd6fe; }
.data-badge.model { color: #92400e; background: var(--amber-soft); border-color: #fde68a; }
.data-badge.offline { color: #475569; background: #f1f5f9; border-color: #e2e8f0; }

/* ---------------- 01 GIS 工作台 ---------------- */
.gis-grid {
  display: grid; grid-template-columns: minmax(0, 3fr) minmax(370px, 2fr);
  gap: 20px; align-items: start;
}
.map-card {
  position: sticky; top: calc(var(--topbar-h) + var(--tabs-h) + 16px);
  height: calc(100vh - var(--topbar-h) - var(--tabs-h) - 34px);
  min-height: 610px; max-height: 920px;
  display: flex; flex-direction: column; overflow: hidden;
}
.map-topline {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 12px 16px; border-bottom: 1px solid var(--line-2); flex: none;
}
.map-title { display: flex; align-items: center; gap: 9px; min-width: 0; }
.map-title b { display: block; font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.map-title small { display: block; font-size: 9.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--emerald); box-shadow: 0 0 0 4px rgba(16, 185, 129, .12); flex: none; }
.map-top-actions { display: flex; align-items: center; gap: 8px; flex: none; }
.tile-switch {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 8px; border: 1px solid var(--line); border-radius: 8px;
  background: #f8fafc; color: var(--muted);
}
.tile-switch .icon { width: 13px; height: 13px; }
.tile-switch select { border: 0; background: none; outline: none; font-size: 10.5px; color: var(--text-2); cursor: pointer; max-width: 118px; }
.map-canvas-wrap { position: relative; flex: 1; min-height: 0; background: #e8eef6; }
#map { position: absolute; inset: 0; }
.leaflet-container { font-family: var(--font); background: #e8eef6; }
.leaflet-control-attribution {
  font-size: 8.5px !important; background: rgba(255, 255, 255, .8) !important;
  padding: 1px 5px !important; border-radius: 4px 0 0 0;
}
.leaflet-control-zoom { border: 0 !important; box-shadow: var(--shadow) !important; border-radius: 10px !important; overflow: hidden; }
.leaflet-control-zoom a {
  width: 30px !important; height: 30px !important; line-height: 30px !important;
  color: var(--text-2) !important; background: rgba(255, 255, 255, .96) !important;
  border-bottom: 1px solid var(--line-2) !important; font-size: 16px !important;
}
.leaflet-control-zoom a:hover { background: #f1f5f9 !important; }
.leaflet-control-scale-line { border-color: rgba(71, 85, 105, .5) !important; color: var(--slate-800); font-size: 9px; background: rgba(255, 255, 255, .7); }
.leaflet-popup-content-wrapper { border-radius: 12px !important; box-shadow: var(--shadow-lg) !important; }
.leaflet-popup-content { margin: 11px 13px !important; font-size: 12px; }
.popup-card { display: flex; flex-direction: column; gap: 2px; min-width: 150px; }
.popup-card b { font-size: 12.5px; }
.popup-card span { color: var(--muted); font-size: 10.5px; }
.popup-card small { color: var(--faint); font-size: 9.5px; word-break: break-all; }
.city-center-marker { background: none; border: 0; }
.ccm-dot {
  position: absolute; left: 1px; top: 1px; width: 10px; height: 10px; border-radius: 50%;
  background: #2563eb; border: 2px solid #fff; box-shadow: 0 0 0 4px rgba(37, 99, 235, .22), 0 0 0 9px rgba(37, 99, 235, .08);
}
.ccm-label {
  position: absolute; left: 12px; top: -7px; white-space: nowrap;
  font-size: 10px; font-weight: 700; color: #1e3a8a;
  background: rgba(255, 255, 255, .92); padding: 2px 6px; border-radius: 5px;
  box-shadow: 0 3px 10px -4px rgba(15, 23, 42, .35);
}

.map-tools {
  position: absolute; top: 12px; left: 12px; z-index: 500;
  width: 86px; padding: 7px 6px;
  background: rgba(255, 255, 255, .94); backdrop-filter: blur(10px);
  border: 1px solid rgba(203, 213, 225, .8); border-radius: 12px;
  box-shadow: 0 16px 34px -18px rgba(15, 23, 42, .4);
  display: flex; flex-direction: column; gap: 2px;
}
.tool-group-label {
  font-size: 8px; letter-spacing: .16em; font-weight: 700; color: var(--faint);
  padding: 3px 7px 5px; text-transform: uppercase;
}
.map-tool {
  display: flex; align-items: center; gap: 6px;
  height: 31px; padding: 0 6px; border: 0; border-radius: 7px;
  background: none; color: var(--text-2); font-size: 10.5px; font-weight: 600;
  white-space: nowrap; text-align: left;
}
.map-tool .icon { width: 14px; height: 14px; color: var(--muted); }
.map-tool:hover { background: #f1f5f9; }
.map-tool.active { background: var(--blue-soft); color: var(--blue-600); }
.map-tool.active .icon { color: var(--blue-600); }
.map-tool.danger:hover { background: var(--rose-soft); color: #b91c1c; }
.map-tool.danger:hover .icon { color: #b91c1c; }
.tool-sep { height: 1px; background: var(--line-2); margin: 3px 5px; }

.map-result-float {
  position: absolute; left: 12px; bottom: 12px; z-index: 480;
  max-width: calc(100% - 205px);
  padding: 8px 12px; border-radius: 10px;
  background: rgba(11, 18, 32, .88); color: #e2e8f0;
  backdrop-filter: blur(8px); border: 1px solid rgba(148, 163, 184, .2);
  box-shadow: 0 12px 30px -16px rgba(2, 6, 23, .8);
  display: flex; flex-direction: column; gap: 1px; line-height: 1.3;
  font-size: 11px;
}
.map-result-float b { font-size: 12.5px; color: #f8fafc; font-variant-numeric: tabular-nums; }
.map-result-float small { font-size: 9px; color: #94a3b8; }
.map-result-float .mf-grid { display: flex; gap: 14px; align-items: baseline; }
.map-result-float .mf-grid span { display: flex; flex-direction: column; }
.map-result-float .mf-grid em { font-style: normal; font-size: 8.5px; color: #94a3b8; }
.map-legend {
  position: absolute; right: 12px; top: 12px; z-index: 480;
  display: flex; flex-direction: column; gap: 4px;
  padding: 7px 9px; border-radius: 9px;
  background: rgba(255, 255, 255, .9); border: 1px solid rgba(203, 213, 225, .8);
  font-size: 8.5px; color: var(--muted); backdrop-filter: blur(6px);
}
.map-legend span { display: flex; align-items: center; gap: 5px; }
.map-legend i { width: 9px; height: 9px; display: inline-block; border-radius: 50%; }
.lg-ring { border: 1.5px dashed #0ea5e9; background: transparent; }
.lg-poi { background: #ef4444; }
.lg-other { background: #94a3b8; }

.assess-panel { display: flex; flex-direction: column; gap: 15px; min-width: 0; }
.panel-card { padding: 17px 18px; }
.panel-card .card-head { margin-bottom: 12px; }
.panel-footnote { font-size: 9.5px; color: var(--faint); line-height: 1.5; padding: 0 4px; }

.area-empty {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 26px 16px; text-align: center;
  border: 1.5px dashed #cbd5e1; border-radius: 12px; background: #fafcff;
  color: var(--muted);
}
.area-empty .icon { width: 26px; height: 26px; color: #94a3b8; }
.area-empty b { font-size: 12px; color: var(--text-2); }
.area-empty span { font-size: 10.5px; max-width: 280px; }

.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.metric {
  padding: 9px 11px; border: 1px solid var(--line-2); border-radius: 10px;
  background: #f8fafc; min-width: 0;
}
.metric-label { display: block; font-size: 9.5px; color: var(--muted); letter-spacing: .02em; }
.metric-value { display: block; font-size: 19px; font-weight: 750; line-height: 1.25; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.metric-unit { font-size: 9px; color: var(--faint); font-weight: 500; margin-left: 2px; }
.metric-wide { grid-column: 1 / -1; }
.metric-sub { display: block; font-size: 9px; color: var(--faint); margin-top: 1px; }

.area-divider { height: 1px; background: var(--line-2); margin: 12px 0; }
.poi-summary { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; }
.poi-estimate { display: flex; align-items: baseline; gap: 5px; }
.poi-estimate b { font-size: 28px; line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.poi-estimate span { font-size: 10.5px; color: var(--muted); }
.poi-summary-meta { font-size: 9.5px; color: var(--faint); text-align: right; line-height: 1.4; }
.poi-note {
  margin-top: 9px; padding: 7px 9px; border-radius: 8px;
  background: var(--amber-soft); border: 1px solid #fef3c7;
  color: #92400e; font-size: 9.5px; line-height: 1.45;
}
.poi-note.offline { color: #475569; background: #f8fafc; border-color: var(--line); }
.poi-note.info { color: #1e40af; background: var(--blue-soft); border-color: #dbeafe; }
.poi-list { margin-top: 10px; display: flex; flex-direction: column; gap: 5px; max-height: 180px; overflow-y: auto; }
.poi-item { display: flex; gap: 8px; padding: 6px 8px; border-radius: 8px; background: #f8fafc; }
.poi-item .poi-rank {
  width: 18px; height: 18px; border-radius: 5px; flex: none;
  display: grid; place-items: center; font-size: 8.5px; font-weight: 700;
  color: #b91c1c; background: var(--rose-soft);
}
.poi-item-main { min-width: 0; display: flex; flex-direction: column; }
.poi-item-main b { font-size: 10.5px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.poi-item-main small { font-size: 9px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.poi-actions { margin-top: 10px; display: flex; gap: 7px; align-items: center; }
.poi-actions .link-btn { font-size: 10.5px; }

.bench-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.bench-item {
  padding: 8px 9px; border: 1px solid var(--line-2); border-radius: 9px;
  background: #fbfdff; min-width: 0;
}
.bench-item-top { display: flex; align-items: center; justify-content: space-between; gap: 5px; }
.bench-label { font-size: 9px; color: var(--muted); }
.bench-value { display: block; font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.35; letter-spacing: -.01em; }
.bench-value small { font-size: 9px; color: var(--faint); font-weight: 500; }
.bench-note {
  margin-top: 9px; display: flex; gap: 6px; align-items: flex-start;
  font-size: 9.5px; color: var(--muted); line-height: 1.5;
}
.bench-note .icon { width: 13px; height: 13px; color: var(--amber); margin-top: 1px; }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.field { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.field-label { font-size: 9.5px; font-weight: 600; color: var(--muted); display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.field-label em { font-style: normal; color: var(--faint); font-weight: 500; font-size: 8.5px; }
.field-input {
  display: flex; align-items: center; gap: 4px;
  height: 34px; padding: 0 9px; border-radius: 8px;
  border: 1px solid var(--line); background: #fff;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.field-input:focus-within { border-color: #93c5fd; box-shadow: 0 0 0 3px rgba(37, 99, 235, .1); }
.field-input input, .field-input select { width: 100%; min-width: 0; border: 0; outline: none; background: none; font-size: 12px; font-variant-numeric: tabular-nums; }
.field-input select { cursor: pointer; }
.field-input .suffix { font-size: 9px; color: var(--faint); white-space: nowrap; }
.field-wide { grid-column: 1 / -1; }
.rent-readout {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  margin-top: 10px; padding: 9px 11px; border-radius: 9px;
  background: linear-gradient(135deg, #0f172a, #1e293b); color: #e2e8f0;
}
.rent-readout span { font-size: 9.5px; color: #94a3b8; }
.rent-readout b { font-size: 19px; font-variant-numeric: tabular-nums; letter-spacing: -.02em; color: #f8fafc; }
.rent-readout small { font-size: 9px; color: #94a3b8; }
.rent-scale-wrap { margin-top: 11px; }
.rent-scale-labels { display: flex; justify-content: space-between; font-size: 8.5px; color: var(--faint); margin-bottom: 4px; }
.rent-scale {
  position: relative; height: 7px; border-radius: 5px;
  background: linear-gradient(90deg, #bbf7d0, #fde68a 45%, #fecaca);
}
.rent-scale .scale-zone { position: absolute; top: 0; bottom: 0; background: rgba(16, 185, 129, .25); border-radius: 5px; }
.rent-scale .scale-marker {
  position: absolute; top: 50%; width: 13px; height: 13px; border-radius: 50%;
  transform: translate(-50%, -50%); background: #fff; border: 2.5px solid var(--blue);
  box-shadow: 0 2px 6px rgba(15, 23, 42, .25);
}
.rent-compare { margin-top: 8px; display: flex; align-items: center; gap: 6px; font-size: 9.5px; color: var(--muted); }
.rent-compare b { font-weight: 700; }
.rent-compare .pos { color: #b45309; }
.rent-compare .neg { color: #047857; }
.rent-apply { margin-top: 11px; display: flex; gap: 8px; }
.rent-apply .btn { flex: 1; }

.deep-pack { margin-top: 13px; border-top: 1px solid var(--line-2); padding-top: 11px; }
.deep-pack-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.deep-pack-head b { font-size: 11px; }
.deep-pack-head small { font-size: 8.5px; color: var(--faint); }
.street-list { margin-top: 8px; display: flex; flex-direction: column; gap: 4px; max-height: 242px; overflow-y: auto; padding-right: 2px; }
.street-item {
  display: flex; align-items: center; gap: 7px;
  width: 100%; padding: 7px 8px; border: 1px solid transparent; border-radius: 8px;
  background: #f8fafc; text-align: left;
}
.street-item:hover { background: #f1f5f9; border-color: var(--line); }
.street-item.selected { background: var(--blue-soft); border-color: #bfdbfe; }
.street-main { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.street-main b { font-size: 10.5px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.street-main small { font-size: 8.5px; color: var(--faint); }
.street-rent { text-align: right; flex: none; }
.street-rent b { font-size: 12px; font-variant-numeric: tabular-nums; }
.street-rent small { display: block; font-size: 8px; color: var(--faint); }
.street-rent .up { color: #b45309; }
.street-rent .down { color: #047857; }

.heat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.heat-item {
  padding: 9px 10px; border: 1px solid var(--line-2); border-radius: 9px;
  background: linear-gradient(180deg, #fbfdff, #f8fafc);
}
.heat-label { display: flex; align-items: center; gap: 5px; font-size: 9px; color: var(--muted); }
.heat-label i { width: 5px; height: 5px; border-radius: 50%; background: var(--cyan); }
.heat-label i.hot { background: var(--rose); }
.heat-label i.xhs { background: #e11d48; }
.heat-label i.mt { background: #f59e0b; }
.heat-value { display: block; margin-top: 3px; font-size: 17px; font-weight: 750; line-height: 1.2; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.heat-value small { font-size: 9px; color: var(--faint); font-weight: 500; }
.heat-note { margin-top: 8px; font-size: 9px; color: var(--faint); line-height: 1.45; }
.heat-actions { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 10px; }
.heat-actions .btn { min-height: 30px; font-size: 10.5px; }

/* ---------------- 02 驾驶舱 ---------------- */
.cockpit-grid { display: grid; grid-template-columns: 352px minmax(0, 1fr); gap: 20px; align-items: start; }
.ctl-card {
  position: sticky; top: calc(var(--topbar-h) + var(--tabs-h) + 16px);
  padding: 17px 16px 14px; max-height: calc(100vh - var(--topbar-h) - var(--tabs-h) - 34px);
  overflow-y: auto;
}
.ctl-card .card-head { margin-bottom: 10px; }
.ctl-subtitle { margin-top: 2px; font-size: 10px; color: var(--muted); }
.control-group { border-top: 1px solid var(--line-2); padding-top: 11px; margin-top: 11px; }
.control-group:first-child { border-top: 0; margin-top: 0; padding-top: 0; }
.control-group-head {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  margin-bottom: 8px;
}
.control-group-head b { font-size: 10px; font-weight: 700; letter-spacing: .06em; color: var(--muted); text-transform: uppercase; }
.control-group-head span { font-size: 8.5px; color: var(--faint); }
.control-row { margin-bottom: 9px; }
.control-row:last-child { margin-bottom: 0; }
.control-label { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 3px; }
.control-label > span { font-size: 10.5px; color: var(--text-2); font-weight: 550; }
.control-label em { font-style: normal; font-size: 8.5px; color: var(--faint); font-weight: 400; }
.control-value {
  font-family: var(--mono); font-size: 10.5px; font-weight: 700; color: var(--text);
  padding: 1px 5px; border-radius: 5px; background: #f1f5f9;
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.control-line { display: flex; align-items: center; gap: 8px; }
.control-line input[type="range"] { flex: 1; min-width: 0; }
.control-line .num-input {
  width: 64px; height: 27px; padding: 0 6px; border: 1px solid var(--line);
  border-radius: 6px; font-size: 10.5px; text-align: right; font-variant-numeric: tabular-nums;
  background: #fff;
}
.control-line .num-input:focus { border-color: #93c5fd; outline: none; box-shadow: 0 0 0 3px rgba(37, 99, 235, .08); }
input[type="range"] {
  -webkit-appearance: none; appearance: none; height: 4px; border-radius: 4px;
  background: linear-gradient(90deg, #bfdbfe, #e2e8f0); outline: none; cursor: pointer;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 14px; height: 14px; border-radius: 50%;
  background: #fff; border: 2.5px solid var(--blue); box-shadow: 0 2px 5px rgba(15, 23, 42, .2);
  cursor: grab;
}
input[type="range"]::-moz-range-thumb {
  width: 13px; height: 13px; border-radius: 50%; background: #fff;
  border: 2.5px solid var(--blue); box-shadow: 0 2px 5px rgba(15, 23, 42, .2);
}
.control-hint { margin-top: 2px; font-size: 8.5px; color: var(--faint); line-height: 1.35; }
.control-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.control-pair .control-row { margin-bottom: 0; }

.invest-mini {
  margin-top: 13px; padding: 10px 11px; border-radius: 10px;
  background: #f8fafc; border: 1px solid var(--line-2);
}
.invest-total { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.invest-total span { font-size: 9.5px; color: var(--muted); }
.invest-total b { font-size: 17px; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.invest-rows { margin-top: 6px; display: grid; grid-template-columns: 1fr 1fr; gap: 2px 8px; }
.invest-row { display: flex; justify-content: space-between; gap: 5px; font-size: 8.5px; color: var(--muted); }
.invest-row b { color: var(--text-2); font-weight: 600; font-variant-numeric: tabular-nums; }
.ctl-note { margin-top: 10px; font-size: 8.5px; color: var(--faint); line-height: 1.45; }

.cockpit-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.kpi-card {
  position: relative; padding: 14px 15px 12px; overflow: hidden;
  background: #fff; border: 1px solid var(--line); border-radius: 15px;
  box-shadow: var(--shadow);
}
.kpi-card::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: var(--blue); opacity: .85;
}
.kpi-card.green::before { background: var(--emerald); }
.kpi-card.amber::before { background: var(--amber); }
.kpi-card.rose::before { background: var(--rose); }
.kpi-card.violet::before { background: var(--violet); }
.kpi-head { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.kpi-label { font-size: 9.5px; color: var(--muted); font-weight: 600; }
.kpi-card .data-badge { font-size: 8px; padding: 2px 5px; }
.kpi-value { display: block; margin-top: 5px; font-size: 25px; font-weight: 750; letter-spacing: -.035em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.kpi-value small { font-size: 10px; font-weight: 500; color: var(--faint); letter-spacing: 0; margin-left: 2px; }
.kpi-sub { display: block; margin-top: 3px; font-size: 9px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi-sub b { color: var(--text-2); font-weight: 650; }
.kpi-foot { display: flex; align-items: center; gap: 5px; margin-top: 7px; font-size: 8.5px; color: var(--muted); }
.kpi-foot .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--emerald); }
.kpi-foot.warn .dot { background: var(--amber); }
.kpi-foot.bad .dot { background: var(--rose); }

.capacity-card { padding: 17px 18px; }
.capacity-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 12px; }
.capacity-head h3 { font-size: 14px; }
.capacity-formula { margin-top: 3px; font-size: 9.5px; color: var(--muted); }
.capacity-formula code { font-family: var(--mono); font-size: 9px; color: var(--blue-600); background: var(--blue-soft); padding: 1px 4px; border-radius: 4px; }
.capacity-stats { display: flex; gap: 18px; flex: none; }
.capacity-stat { text-align: right; }
.capacity-stat span { display: block; font-size: 8.5px; color: var(--faint); }
.capacity-stat b { font-size: 16px; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.capacity-stat b small { font-size: 9px; color: var(--faint); font-weight: 500; }
.capacity-bar {
  position: relative; height: 16px; border-radius: 8px; overflow: hidden;
  background: #eef2f7; border: 1px solid var(--line-2);
}
.capacity-fill {
  position: absolute; inset: 0 auto 0 0; width: 0; border-radius: 8px;
  background: linear-gradient(90deg, #34d399, #10b981);
  transition: width .45s cubic-bezier(.2, .8, .2, 1);
}
.capacity-fill.warn { background: linear-gradient(90deg, #fbbf24, #f59e0b); }
.capacity-fill.bad { background: linear-gradient(90deg, #fb7185, #ef4444); }
.capacity-limit { position: absolute; top: -3px; bottom: -3px; width: 2px; left: 100%; background: #0f172a; opacity: .55; }
.capacity-scale { display: flex; justify-content: space-between; margin-top: 5px; font-size: 8px; color: var(--faint); font-variant-numeric: tabular-nums; }
.capacity-notes { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.cap-chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 8px; border-radius: 6px; font-size: 8.5px;
  background: #f8fafc; border: 1px solid var(--line-2); color: var(--muted);
}
.cap-chip b { color: var(--text-2); font-weight: 650; font-variant-numeric: tabular-nums; }
.cap-chip.warn { background: var(--amber-soft); border-color: #fde68a; color: #92400e; }
.cap-chip.bad { background: var(--rose-soft); border-color: #fecaca; color: #b91c1c; }

.chart-card { padding: 17px 18px 13px; }
.chart-legend { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.legend-item {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 9.5px; color: var(--muted); border: 0; background: none; padding: 2px 0;
  cursor: pointer; transition: opacity .15s ease;
}
.legend-item i { width: 14px; height: 3px; border-radius: 2px; }
.legend-item.off { opacity: .35; }
.legend-item b { font-weight: 650; color: var(--text-2); font-variant-numeric: tabular-nums; }
.chart-wrap { position: relative; height: 352px; margin-top: 4px; }
#cashflow-chart { width: 100%; height: 100%; display: block; overflow: visible; }
.axis-text { font-size: 9px; fill: #94a3b8; font-family: var(--font); }
.axis-text.bold { font-weight: 650; fill: #64748b; }
.grid-line { stroke: #eef2f7; stroke-width: 1; }
.zero-line { stroke: #94a3b8; stroke-width: 1.1; stroke-dasharray: 4 4; }
.season-band { fill: #eef6ff; opacity: .65; }
.season-label { font-size: 8px; fill: #60a5fa; font-family: var(--font); }
.cf-area { fill-opacity: .08; }
.cf-line { fill: none; stroke-width: 2.1; stroke-linecap: round; stroke-linejoin: round; }
.cf-dot { stroke: #fff; stroke-width: 1.2; }
.cf-dot.base { fill: #2563eb; }
.cf-dot.optimistic { fill: #10b981; }
.cf-dot.pessimistic { fill: #f59e0b; }
.cf-payback-line { stroke: #10b981; stroke-width: 1; stroke-dasharray: 3 3; opacity: .8; }
.cf-payback-text { font-size: 8.5px; fill: #059669; font-weight: 650; }
.chart-tip {
  position: absolute; z-index: 10; pointer-events: none;
  min-width: 158px; padding: 8px 10px; border-radius: 9px;
  background: rgba(11, 18, 32, .94); color: #e2e8f0;
  box-shadow: var(--shadow-lg); font-size: 9.5px; line-height: 1.5;
}
.chart-tip b { display: block; font-size: 10.5px; color: #fff; margin-bottom: 2px; }
.chart-tip .row { display: flex; justify-content: space-between; gap: 12px; }
.chart-tip .row span { color: #94a3b8; }
.chart-tip .row em { font-style: normal; font-variant-numeric: tabular-nums; }
.chart-foot { display: flex; flex-wrap: wrap; gap: 7px; padding-top: 8px; border-top: 1px solid var(--line-2); }
.chart-foot .cap-chip { font-size: 8.5px; }

.cost-card { padding: 17px 18px; }
.unit-profit {
  font-size: 12px; font-weight: 750; font-variant-numeric: tabular-nums;
  color: #047857; background: var(--emerald-soft); border: 1px solid #a7f3d0;
  padding: 4px 9px; border-radius: 7px; white-space: nowrap;
}
.unit-profit.neg { color: #b91c1c; background: var(--rose-soft); border-color: #fecaca; }
.cost-stack {
  display: flex; height: 30px; border-radius: 8px; overflow: hidden;
  background: #f1f5f9; border: 1px solid var(--line-2);
}
.stack-seg { position: relative; height: 100%; transition: width .4s ease; min-width: 0; }
.stack-seg:hover { filter: brightness(.94); }
.stack-seg.loss { background: repeating-linear-gradient(45deg, #fecaca, #fecaca 5px, #fee2e2 5px, #fee2e2 10px); }
.cost-legend { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px 16px; margin-top: 12px; }
.cost-item { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 9.5px; }
.cost-dot { width: 7px; height: 7px; border-radius: 2px; flex: none; }
.cost-name { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; }
.cost-value { font-variant-numeric: tabular-nums; font-weight: 650; color: var(--text-2); white-space: nowrap; }
.cost-pct { width: 38px; text-align: right; color: var(--faint); font-size: 8.5px; font-variant-numeric: tabular-nums; }
.cost-divider { height: 1px; background: var(--line-2); margin: 13px 0 11px; }
.unit-table { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 22px; }
.tax-basis { margin-top: 12px; padding: 10px 12px; border: 1px solid #e2e8f0; border-radius: 10px; background: #f8fafc; }
.tax-basis-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tax-basis-head b { font-size: 10.5px; color: var(--slate-900); }
.tax-basis-head span { font-size: 8.5px; color: #7c3aed; background: #f3e8ff; border: 1px solid #e9d5ff; border-radius: 6px; padding: 2px 6px; }
.tax-basis-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(92px, 1fr)); gap: 6px 12px; margin-top: 8px; }
.tax-basis-grid div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tax-basis-grid small { font-size: 8px; color: var(--faint); }
.tax-basis-grid b { font-size: 10.5px; color: var(--slate-900); font-variant-numeric: tabular-nums; }
.tax-basis-grid b.pos { color: #047857; }
.tax-basis-grid b.neg { color: #b91c1c; }
.tax-basis p { margin: 7px 0 0; font-size: 8.5px; line-height: 1.5; color: var(--faint); }
.tax-entity-box { display: flex; align-items: stretch; gap: 12px; margin-top: 12px; padding: 10px 12px; border: 1px solid #dbeafe; border-radius: 10px; background: #f5f9ff; }
.tax-entity-box > .field { flex: 0 0 220px; margin: 0; }
.tax-entity-note { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.tax-entity-note b { font-size: 10px; color: #1d4ed8; }
.tax-entity-note span { font-size: 8.5px; color: var(--muted); }
.tax-entity-note p { margin: 2px 0 0; font-size: 8.5px; line-height: 1.5; color: var(--faint); }
.unit-row { display: grid; grid-template-columns: 78px 1fr 58px; align-items: center; gap: 7px; padding: 4px 0; border-bottom: 1px dashed var(--line-2); font-size: 9.5px; }
.unit-row:last-child { border-bottom: 0; }
.unit-row .ur-label { color: var(--muted); white-space: nowrap; }
.unit-row .ur-bar { height: 5px; border-radius: 3px; background: #f1f5f9; overflow: hidden; }
.unit-row .ur-bar i { display: block; height: 100%; border-radius: 3px; background: var(--blue); }
.unit-row .ur-value { text-align: right; font-variant-numeric: tabular-nums; font-weight: 650; color: var(--text-2); }
.unit-row.profit .ur-value { color: #047857; }
.unit-row.profit .ur-bar i { background: var(--emerald); }

.plan-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 13px 16px;
}
.plan-bar-text { display: flex; flex-direction: column; gap: 1px; }
.plan-bar-text strong { font-size: 12px; }
.plan-bar-text span { font-size: 9.5px; color: var(--muted); }
.plan-actions { display: flex; gap: 7px; flex: none; }
.compare-card { padding: 17px 18px; }
.compare-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.compare-col { border: 1px solid var(--line); border-radius: 11px; overflow: hidden; }
.compare-col-head { padding: 9px 12px; background: #f8fafc; border-bottom: 1px solid var(--line-2); display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.compare-col-head b { font-size: 11.5px; }
.compare-col-head span { font-size: 8.5px; color: var(--faint); }
.compare-row { display: flex; justify-content: space-between; gap: 8px; padding: 6px 12px; border-bottom: 1px dashed var(--line-2); font-size: 9.5px; }
.compare-row:last-child { border-bottom: 0; }
.compare-row span { color: var(--muted); }
.compare-row b { font-variant-numeric: tabular-nums; color: var(--text-2); }
.compare-row b.better { color: #047857; }
.compare-row b.worse { color: #b91c1c; }

.advanced-card, .monthly-card { padding: 0; overflow: hidden; }
.advanced-card summary, .monthly-card summary {
  list-style: none; cursor: pointer; padding: 14px 18px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.advanced-card summary::-webkit-details-marker, .monthly-card summary::-webkit-details-marker { display: none; }
.advanced-card summary div, .monthly-card summary div { display: flex; flex-direction: column; gap: 1px; }
.advanced-card summary b, .monthly-card summary { font-size: 12.5px; font-weight: 650; }
.advanced-card summary span, .monthly-card summary { font-size: 9.5px; color: var(--muted); }
.summary-caret {
  width: 8px; height: 8px; border-right: 1.6px solid var(--muted); border-bottom: 1.6px solid var(--muted);
  transform: rotate(45deg); transition: transform .2s ease; margin-right: 3px;
}
details[open] .summary-caret { transform: rotate(225deg); }
.adv-body { padding: 0 18px 18px; border-top: 1px solid var(--line-2); }
.adv-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px 14px; margin-top: 12px; }
.adv-note { margin-top: 10px; font-size: 9px; color: var(--faint); line-height: 1.5; }
.adv-toggle { display: flex; align-items: center; gap: 8px; margin-top: 10px; font-size: 10px; color: var(--text-2); }
.adv-toggle input { accent-color: var(--blue); width: 14px; height: 14px; }
.monthly-card > #monthly-table { border-top: 1px solid var(--line-2); }
.table-wrap { overflow-x: auto; }
table.monthly {
  width: 100%; border-collapse: collapse; font-size: 10px;
  font-variant-numeric: tabular-nums;
}
table.monthly th {
  text-align: right; padding: 8px 10px; background: #f8fafc; color: var(--muted);
  font-weight: 650; font-size: 9px; white-space: nowrap;
  border-bottom: 1px solid var(--line);
}
table.monthly th:first-child, table.monthly td:first-child { text-align: left; }
table.monthly td { padding: 7px 10px; text-align: right; border-bottom: 1px solid var(--line-2); white-space: nowrap; }
table.monthly tr:hover td { background: #f8fbff; }
table.monthly td.pos { color: #047857; }
table.monthly td.neg { color: #b91c1c; }
table.monthly .m-month { font-weight: 650; color: var(--text-2); }
table.monthly .m-season { font-size: 8px; color: var(--faint); margin-left: 4px; }
table.monthly tfoot td { background: #f8fafc; font-weight: 700; }

/* ---------------- 03 风险 ---------------- */
.verdict-banner {
  display: flex; align-items: center; gap: 16px;
  padding: 18px 22px; border-radius: var(--radius);
  color: #065f46; background: linear-gradient(105deg, #ecfdf5, #f0fdfa);
  border: 1px solid #a7f3d0; margin-bottom: 16px;
}
.verdict-banner.warn { color: #92400e; background: linear-gradient(105deg, #fffbeb, #fefce8); border-color: #fde68a; }
.verdict-banner.bad { color: #991b1b; background: linear-gradient(105deg, #fff1f2, #fff5f5); border-color: #fecaca; }
.verdict-icon {
  width: 44px; height: 44px; border-radius: 12px; flex: none;
  display: grid; place-items: center; background: rgba(16, 185, 129, .13); color: #047857;
}
.verdict-banner.warn .verdict-icon { background: rgba(245, 158, 11, .15); color: #b45309; }
.verdict-banner.bad .verdict-icon { background: rgba(239, 68, 68, .12); color: #b91c1c; }
.verdict-icon .icon { width: 22px; height: 22px; }
.verdict-copy { display: flex; flex-direction: column; gap: 1px; }
.verdict-copy b { font-size: 17px; letter-spacing: -.01em; }
.verdict-copy span { font-size: 10.5px; opacity: .85; }
.verdict-score { margin-left: auto; text-align: right; flex: none; }
.verdict-score b { display: block; font-size: 28px; line-height: 1; font-variant-numeric: tabular-nums; letter-spacing: -.03em; }
.verdict-score span { font-size: 8.5px; opacity: .7; }
.risk-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: 16px; margin-bottom: 16px; align-items: start; }
.risk-grid > .card { padding: 17px 18px; }
.redline-list { list-style: none; margin: 0; padding: 0; }
.redline-item {
  display: flex; gap: 11px; padding: 11px 0; border-bottom: 1px solid var(--line-2);
}
.redline-item:last-child { border-bottom: 0; }
.redline-status {
  width: 25px; height: 25px; border-radius: 8px; flex: none;
  display: grid; place-items: center;
  color: #047857; background: var(--emerald-soft); border: 1px solid #a7f3d0;
}
.redline-status .icon { width: 13px; height: 13px; }
.redline-item.fail .redline-status { color: #b91c1c; background: var(--rose-soft); border-color: #fecaca; }
.redline-item.info .redline-status { color: #1d4ed8; background: var(--blue-soft); border-color: #bfdbfe; }
.redline-main { min-width: 0; flex: 1; }
.redline-top { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.redline-name { font-size: 11.5px; font-weight: 650; }
.redline-actual { font-family: var(--mono); font-size: 12px; font-weight: 750; font-variant-numeric: tabular-nums; white-space: nowrap; }
.redline-item.fail .redline-actual { color: #b91c1c; }
.redline-item.pass .redline-actual { color: #047857; }
.redline-meta { display: flex; align-items: center; gap: 7px; margin-top: 2px; }
.redline-threshold { font-size: 8.5px; color: var(--faint); }
.redline-cat {
  font-size: 8px; padding: 1px 5px; border-radius: 4px;
  color: #475569; background: #f1f5f9; border: 1px solid #e2e8f0;
}
.redline-detail { margin-top: 4px; font-size: 9px; color: var(--muted); line-height: 1.5; }
.sensitivity-wrap { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.sens-row { display: flex; flex-direction: column; gap: 3px; }
.sens-top { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.sens-label { font-size: 10px; color: var(--text-2); }
.sens-value { font-family: var(--mono); font-size: 10px; font-weight: 700; font-variant-numeric: tabular-nums; }
.sens-value.neg { color: #b91c1c; }
.sens-value.pos { color: #047857; }
.sens-track { position: relative; height: 6px; border-radius: 4px; background: #f1f5f9; overflow: hidden; }
.sens-bar { position: absolute; top: 0; bottom: 0; border-radius: 4px; }
.sens-bar.neg { background: linear-gradient(90deg, #fca5a5, #ef4444); }
.sens-bar.pos { background: linear-gradient(90deg, #6ee7b7, #10b981); }
.sens-mid { position: absolute; left: 50%; top: -2px; bottom: -2px; width: 1px; background: #cbd5e1; }
.sens-pct { font-size: 8.5px; color: var(--faint); }
.reserve-note {
  margin-top: 14px; padding: 10px 12px; border-radius: 9px;
  background: #f8fafc; border: 1px solid var(--line-2);
  font-size: 9.5px; color: var(--muted); line-height: 1.55;
}
.reserve-note b { color: var(--text-2); font-variant-numeric: tabular-nums; }
.reserve-note .cap-chip { margin: 4px 4px 0 0; }
.report-card {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 22px 26px; color: #e2e8f0;
  background:
    radial-gradient(420px 180px at 18% 0%, rgba(59, 130, 246, .2), transparent 70%),
    linear-gradient(115deg, #0b1220, #132039 60%, #0d1a2e);
  border-color: #1e293b;
}
.report-card h3 { margin-top: 5px; font-size: 21px; color: #f8fafc; letter-spacing: -.01em; }
.report-card p { margin-top: 3px; max-width: 680px; font-size: 10.5px; color: #94a3b8; }

/* ---------------- 04 合规 ---------------- */
.progress-card { padding: 17px 20px; margin-bottom: 16px; }
.progress-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.progress-head > div { display: flex; flex-direction: column; gap: 1px; }
.progress-label { font-size: 9px; letter-spacing: .08em; color: var(--faint); text-transform: uppercase; font-weight: 700; }
.progress-head b { font-size: 15px; }
.progress-pct { font-family: var(--mono); font-size: 26px; font-weight: 750; letter-spacing: -.03em; color: var(--blue-600); }
.progress-bar { height: 9px; border-radius: 6px; background: #eef2f7; overflow: hidden; margin-top: 11px; }
.progress-bar i { display: block; height: 100%; width: 0; border-radius: 6px; background: linear-gradient(90deg, #2563eb, #0ea5e9); transition: width .4s ease; }
.progress-meta { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 8px; font-size: 9.5px; color: var(--muted); }
.compliance-snapshot { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.snapshot-card { padding: 16px 18px; }
.snapshot-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.snap-item {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 8px; border-radius: 6px; font-size: 9px;
  color: #475569; background: #f8fafc; border: 1px solid var(--line);
}
.snap-item.required { color: #9a3412; background: #fff7ed; border-color: #fed7aa; }
.snap-item.high { color: #991b1b; background: var(--rose-soft); border-color: #fecaca; }
.snap-item.conditional { color: #1d4ed8; background: var(--blue-soft); border-color: #dbeafe; }
.snapshot-desc { font-size: 9.5px; color: var(--muted); line-height: 1.5; }
.timeline { position: relative; display: flex; flex-direction: column; gap: 16px; }
.timeline::before {
  content: ""; position: absolute; left: 25px; top: 14px; bottom: 14px; width: 1.5px;
  background: linear-gradient(180deg, #bfdbfe, #e2e8f0 70%, transparent);
}
.phase { position: relative; padding-left: 52px; }
.phase-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.phase-badge {
  position: absolute; left: 8px; top: 0;
  width: 35px; height: 35px; border-radius: 11px;
  display: grid; place-items: center; z-index: 1;
  font-family: var(--mono); font-size: 9px; font-weight: 750;
  color: var(--blue-600); background: #fff; border: 1.5px solid #bfdbfe;
  box-shadow: 0 4px 10px -5px rgba(37, 99, 235, .4);
}
.phase-title { font-size: 13.5px; font-weight: 700; }
.phase-count { font-size: 9.5px; color: var(--faint); }
.phase-progress { margin-left: auto; font-family: var(--mono); font-size: 9px; color: var(--muted); }
.task-list { display: flex; flex-direction: column; gap: 5px; }
.task {
  display: flex; align-items: flex-start; gap: 9px;
  padding: 9px 11px; border-radius: 9px;
  background: #fff; border: 1px solid var(--line);
  transition: background .15s ease, border-color .15s ease;
}
.task:hover { border-color: #cbd5e1; }
.task.checked { background: #f8fafc; border-color: var(--line-2); }
.task.checked .task-text { color: var(--faint); text-decoration: line-through; text-decoration-color: #cbd5e1; }
.task-check {
  appearance: none; -webkit-appearance: none;
  width: 17px; height: 17px; margin: 0; flex: none; margin-top: 1px;
  border: 1.5px solid #cbd5e1; border-radius: 5px; background: #fff;
  display: grid; place-items: center; cursor: pointer; transition: all .15s ease;
}
.task-check:checked { background: var(--blue); border-color: var(--blue); }
.task-check:checked::after {
  content: ""; width: 8px; height: 4.5px;
  border-left: 1.8px solid #fff; border-bottom: 1.8px solid #fff;
  transform: translateY(-1px) rotate(-45deg);
}
.task-body { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 1px; }
.task-text { font-size: 10.5px; line-height: 1.5; color: var(--text-2); }
.task-meta { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 2px; }
.task-level {
  font-size: 8px; font-weight: 650; padding: 1px 5px; border-radius: 4px;
  color: #475569; background: #f1f5f9; border: 1px solid #e2e8f0;
}
.task-level.required, .task-level.high { color: #991b1b; background: var(--rose-soft); border-color: #fecaca; }
.task-level.conditional { color: #1d4ed8; background: var(--blue-soft); border-color: #dbeafe; }
.task-level.medium { color: #92400e; background: var(--amber-soft); border-color: #fde68a; }
.task-source { font-size: 8px; color: var(--faint); }

/* ---------------- Footer ---------------- */
.footer { background: #0b1220; color: #94a3b8; margin-top: 26px; }
.footer-inner {
  max-width: 1540px; margin: 0 auto; padding: 22px 26px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.footer strong { color: #e2e8f0; font-size: 12.5px; }
.footer p { margin-top: 3px; max-width: 860px; font-size: 9.5px; line-height: 1.6; }
.footer-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex: none; }
.footer-asof { font-family: var(--mono); font-size: 8.5px; color: #64748b; }

/* ---------------- Toast & Dialog ---------------- */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(12px);
  z-index: 3000; padding: 9px 15px; border-radius: 10px;
  background: rgba(11, 18, 32, .94); color: #e2e8f0;
  border: 1px solid rgba(148, 163, 184, .25); box-shadow: var(--shadow-lg);
  font-size: 11.5px; opacity: 0; transition: opacity .18s ease, transform .18s ease;
  pointer-events: none; max-width: min(90vw, 540px);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.err { border-color: rgba(239, 68, 68, .4); }
.toast.ok { border-color: rgba(16, 185, 129, .4); }
.toast.warn { border-color: rgba(245, 158, 11, .5); color: #fde68a; }

.data-dialog {
  width: min(980px, calc(100vw - 32px)); max-height: 88vh;
  padding: 0; border: 0; border-radius: 20px;
  background: #fff; color: var(--text); box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.data-dialog::backdrop { background: rgba(2, 6, 23, .55); backdrop-filter: blur(3px); }
.dialog-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
  padding: 18px 22px 14px; border-bottom: 1px solid var(--line-2);
  background: linear-gradient(180deg, #fbfdff, #fff);
}
.dialog-head h3 { margin-top: 4px; font-size: 20px; letter-spacing: -.02em; }
.icon-btn {
  width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line);
  background: #fff; display: grid; place-items: center; color: var(--muted);
}
.icon-btn:hover { background: #f8fafc; color: var(--text); }
.dialog-body { max-height: calc(88vh - 83px); overflow-y: auto; padding: 18px 22px 22px; }
.dialog-section { padding: 16px 0; border-bottom: 1px solid var(--line-2); }
.dialog-section:first-child { padding-top: 0; }
.dialog-section:last-child { border-bottom: 0; padding-bottom: 0; }
.dialog-section h4 { font-size: 13px; margin-bottom: 3px; }
.dialog-section > p { font-size: 10px; color: var(--muted); line-height: 1.55; margin-bottom: 10px; }
.transparency-strip { display: flex; flex-wrap: wrap; gap: 7px; margin: 8px 0 9px; }
.offline-strip {
  display: flex; align-items: flex-start; gap: 8px;
  padding: 9px 11px; border-radius: 9px;
  background: var(--amber-soft); border: 1px solid #fde68a;
  font-size: 9.5px; color: #92400e; line-height: 1.5;
}
.offline-strip .icon { width: 14px; height: 14px; flex: none; margin-top: 1px; }
.radio-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.radio-card {
  display: flex; gap: 8px; align-items: flex-start;
  padding: 10px; border: 1px solid var(--line); border-radius: 10px;
  background: #fff; cursor: pointer; transition: border-color .15s ease, background .15s ease;
}
.radio-card:hover { border-color: #cbd5e1; background: #fbfdff; }
.radio-card.selected { border-color: #93c5fd; background: var(--blue-soft); }
.radio-card input { accent-color: var(--blue); margin-top: 2px; }
.radio-card b { display: block; font-size: 10.5px; }
.radio-card span { display: block; font-size: 8.5px; color: var(--muted); line-height: 1.4; }
.api-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: end; margin-top: 10px; }
.api-row .field { min-width: 0; }
.api-row .field-input { height: 36px; }
.proxy-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: end; margin-top: 10px; }
.proxy-row .field { min-width: 0; }
.proxy-actions { display: flex; gap: 6px; }
.field-input:has(textarea) { height: auto; align-items: stretch; padding: 7px 9px; }
.field-input textarea { width: 100%; min-height: 84px; border: 0; outline: none; background: none; resize: vertical; font-size: 12px; line-height: 1.55; }
.feedback-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.legal-meta { font-size: 9px; color: var(--faint); margin-bottom: 6px; }
.legal-list { margin: 8px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; }
.legal-list li { font-size: 9.5px; line-height: 1.65; color: var(--text-2); }
.legal-list b { color: var(--slate-900); }
.info-dialog { max-width: 720px; }
.api-note { margin-top: 6px; font-size: 8.5px; color: var(--faint); line-height: 1.5; }
.dialog-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.drop-zone {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  min-height: 98px; padding: 14px; border: 1.5px dashed #cbd5e1; border-radius: 11px;
  background: #fafcff; text-align: center; cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}
.drop-zone:hover, .drop-zone.dragover { border-color: #93c5fd; background: var(--blue-soft); }
.drop-zone .icon { width: 24px; height: 24px; color: #94a3b8; }
.drop-zone b { font-size: 10.5px; }
.drop-zone span { font-size: 8.5px; color: var(--muted); }
.dataset-status {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-top: 8px; padding: 8px 10px; border-radius: 8px;
  background: #f8fafc; border: 1px solid var(--line-2);
  font-size: 9px; color: var(--muted);
}
.dataset-status b { color: var(--text-2); }
.source-table { width: 100%; border-collapse: collapse; font-size: 9px; }
.source-table th { text-align: left; padding: 6px 8px; background: #f8fafc; color: var(--muted); font-weight: 650; border-bottom: 1px solid var(--line); }
.source-table td { padding: 6px 8px; border-bottom: 1px solid var(--line-2); color: var(--text-2); vertical-align: top; }
.source-table td:last-child { white-space: nowrap; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; padding-top: 14px; }
.dialog-actions .spacer { margin-right: auto; }
.check-row { display: flex; align-items: flex-start; gap: 7px; font-size: 9.5px; color: var(--text-2); }
.check-row input { accent-color: var(--blue); margin-top: 2px; }

/* ---------------- 打印报告 ---------------- */
.print-only { display: none; }
@media print {
  body { background: #fff !important; }
  .app, .toast, .data-dialog, .leaflet-container { display: none !important; }
  .print-only { display: block !important; color: #111827; font-family: var(--font); }
  .print-report { padding: 0; }
  .pr-page { page-break-after: always; padding: 12mm 14mm; }
  .pr-page:last-child { page-break-after: auto; }
  .pr-head { display: flex; justify-content: space-between; gap: 20px; border-bottom: 2px solid #111827; padding-bottom: 8px; margin-bottom: 10px; }
  .pr-head-main { display: flex; align-items: center; gap: 9px; min-width: 0; }
  .pr-head-main > div { min-width: 0; }
  .pr-brand-svg { width: 34px; height: 34px; flex: none; display: block; }
  .pr-head h1 { font-size: 23px; margin: 0; }
  .pr-head p { font-size: 9px; color: #4b5563; margin-top: 3px; }
  .pr-badge { font-size: 9px; border: 1px solid #111827; padding: 3px 7px; border-radius: 4px; height: fit-content; }
  .pr-meta { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 10px; }
  .pr-meta div { border: 1px solid #d1d5db; border-radius: 6px; padding: 6px 9px; }
  .pr-meta small { display: block; font-size: 8px; color: #6b7280; }
  .pr-meta b { font-size: 12px; }
  .pr-section { margin-top: 10px; }
  .pr-section h2 { font-size: 13.5px; margin: 0 0 5px; border-left: 3px solid #2563eb; padding-left: 7px; page-break-after: avoid; break-after: avoid; }
  .pr-section p { font-size: 9.5px; color: #374151; line-height: 1.45; }
  .pr-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
  .pr-kpi { border: 1px solid #d1d5db; border-radius: 6px; padding: 6px 9px; }
  .pr-kpi small { display: block; font-size: 8px; color: #6b7280; }
  .pr-kpi b { font-size: 13px; }
  table.pr-table { width: 100%; border-collapse: collapse; font-size: 8.5px; margin-top: 5px; }
  table.pr-table-dense { font-size: 7px; }
  table.pr-table-dense th, table.pr-table-dense td { padding: 2px 3px; }
  table.pr-table-dense small { font-size: 6px; color: #6b7280; }
  table.pr-table th { background: #f3f4f6; text-align: right; padding: 3px 5px; border: 1px solid #d1d5db; font-weight: 600; }
  table.pr-table td { padding: 3px 5px; border: 1px solid #e5e7eb; text-align: right; }
  table.pr-table th:first-child, table.pr-table td:first-child { text-align: left; }
  .pr-note { font-size: 8px; color: #6b7280; line-height: 1.4; margin-top: 6px; }
  .pr-sign { display: flex; justify-content: space-between; margin-top: 18px; font-size: 9px; color: #6b7280; }
  .pr-sign div { border-top: 1px solid #9ca3af; width: 42%; padding-top: 4px; }
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 1420px) {
  .brand-sub { display: none; }
  .top-status { display: none; }
  .top-controls { gap: 8px; }
  .combo-trigger { min-width: 190px; }
  .industry-picker select { width: 150px; }
  .tab { padding: 0 15px; }
  .kpi-value { font-size: 22px; }
}
@media (max-width: 1220px) {
  .gis-grid { grid-template-columns: 1fr; }
  .map-card { position: relative; top: 0; height: 620px; max-height: none; }
  .cockpit-grid { grid-template-columns: 1fr; }
  .ctl-card { position: relative; top: 0; max-height: none; }
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .risk-grid { grid-template-columns: 1fr; }
  .adv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .head-chips { display: none; }
  .page-head { align-items: flex-start; }
}
@media (max-width: 980px) {
  .topbar-inner { flex-wrap: wrap; gap: 10px; padding: 10px 16px; }
  .brand { flex: 1 1 100%; }
  .top-controls { width: 100%; flex-wrap: wrap; margin-left: 0; }
  .city-combo { flex: 1 1 220px; }
  .combo-trigger { width: 100%; min-width: 0; }
  .industry-picker { flex: 1 1 210px; }
  .industry-picker select { width: 100%; }
  .btn.top-btn span { display: none; }
  .btn.top-btn { padding: 0 10px; }
  .tabs { top: 0; position: relative; }
  .tabs-inner { overflow-x: auto; padding: 0 12px; }
  .tab { flex: none; }
  .tabs-right { display: none; }
  .main { padding: 16px; }
  .page-head h2 { font-size: 23px; }
  .map-card { height: 540px; min-height: 540px; }
  .map-legend { display: none; }
  .map-result-float { max-width: calc(100% - 24px); right: 12px; }
  .unit-table { grid-template-columns: 1fr; }
  .compliance-snapshot { grid-template-columns: 1fr; }
  .report-card { align-items: flex-start; flex-direction: column; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-actions { align-items: flex-start; }
}
@media (max-width: 620px) {
  .page-head { flex-direction: column; gap: 10px; }
  .kpi-grid { grid-template-columns: 1fr; }
  .form-grid, .heat-grid, .bench-grid { grid-template-columns: 1fr; }
  .metric-grid { grid-template-columns: 1fr; }
  .cost-legend { grid-template-columns: 1fr; }
  .adv-grid { grid-template-columns: 1fr; }
  .radio-cards { grid-template-columns: 1fr; }
  .dialog-grid-2 { grid-template-columns: 1fr; }
  .compare-grid { grid-template-columns: 1fr; }
  .capacity-stats { gap: 10px; }
  .tax-basis-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tax-entity-box { flex-direction: column; }
  .tax-entity-box > .field { flex: none; }
  .map-card { height: 500px; min-height: 500px; }
  .chart-wrap { height: 280px; }
  .plan-bar { flex-direction: column; align-items: flex-start; }
  .plan-actions { width: 100%; }
  .plan-actions .btn { flex: 1; }
  .progress-meta { align-items: flex-start; flex-direction: column; gap: 5px; }
  .phase { padding-left: 44px; }
}

/* =========================================================
   StoreCalc 5.0 · 一屏式 GIS 工作台 / 空间漏斗 / 蒙特卡洛
   ========================================================= */
.tabs { position: relative; top: auto; }
.gis-grid { grid-template-columns: minmax(0, 3fr) minmax(430px, 2fr); align-items: stretch; }
.map-card {
  position: sticky; top: 88px;
  height: calc(100vh - 180px); min-height: 640px; max-height: none;
}
.inspector-card {
  position: sticky; top: 88px;
  height: calc(100vh - 180px); min-height: 640px;
  display: flex; flex-direction: column; overflow: hidden;
}
.inspector-tabs {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px; padding: 8px; border-bottom: 1px solid var(--line-2);
  background: linear-gradient(180deg, #fbfdff, #f8fafc); flex: none;
}
.inspector-tab {
  display: flex; align-items: center; gap: 6px; min-width: 0;
  padding: 8px 7px; border: 1px solid transparent; border-radius: 9px;
  background: none; text-align: left; color: var(--muted);
}
.inspector-tab .icon { width: 15px; height: 15px; flex: none; }
.inspector-tab > span { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.inspector-tab { font-size: 10.5px; font-weight: 650; }
.inspector-tab small { font-size: 8px; color: var(--faint); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inspector-tab:hover { background: #fff; border-color: var(--line); }
.inspector-tab.active { color: var(--blue-600); background: #fff; border-color: #bfdbfe; box-shadow: 0 4px 12px -10px rgba(37, 99, 235, .6); }
.inspector-tab.active small { color: #60a5fa; }
.inspector-body { flex: 1; min-height: 0; overflow-y: auto; padding: 0 18px; }
.inspector-panel { display: none; padding-bottom: 16px; }
.inspector-panel.active { display: block; }
.inspector-section { padding: 15px 0; border-bottom: 1px solid var(--line-2); }
.inspector-section:last-child { border-bottom: 0; }
.inspector-section .section-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.inspector-section .section-head h3 { font-size: 13px; font-weight: 700; }
.inspector-section .section-head p { margin-top: 2px; font-size: 9.5px; color: var(--muted); }
.inspector-foot { flex: none; padding: 12px 18px 14px; border-top: 1px solid var(--line-2); background: #fff; }
.inspector-foot .panel-footnote { margin-top: 7px; padding: 0; }
.inspector-foot .btn { min-height: 42px; }

/* 地图落点与双圈 */
.store-pin-marker { background: none; border: 0; }
.store-pin-head {
  position: absolute; left: 3px; top: 0; width: 20px; height: 20px; border-radius: 50% 50% 50% 4px;
  transform: rotate(-45deg); background: linear-gradient(135deg, #2563eb, #1d4ed8);
  border: 2px solid #fff; box-shadow: 0 4px 12px -4px rgba(37, 99, 235, .9);
  color: #fff; font-size: 9px; font-weight: 750; display: grid; place-items: center;
}
.store-pin-head::after { content: "店"; transform: rotate(45deg); font-size: 9px; }
.store-pin-stem { position: absolute; left: 12px; top: 18px; width: 2px; height: 12px; background: #1d4ed8; }
.store-pin-label {
  position: absolute; left: 26px; top: 1px; white-space: nowrap;
  font-size: 9px; font-weight: 700; color: #1e3a8a;
  background: rgba(255, 255, 255, .94); padding: 2px 6px; border-radius: 5px;
  box-shadow: 0 3px 10px -5px rgba(15, 23, 42, .4);
}
.dual-label.leaflet-tooltip {
  background: rgba(255, 255, 255, .92); border: 1px solid #dbeafe; color: #1e40af;
  font-size: 8.5px; font-weight: 650; padding: 1px 6px; border-radius: 5px;
  box-shadow: 0 2px 8px -5px rgba(15, 23, 42, .35);
}
.dual-label.leaflet-tooltip.outer { color: #6d28d9; border-color: #ddd6fe; }
.dual-label.leaflet-tooltip::before { display: none; }
.map-tool.primary { color: var(--blue-600); background: var(--blue-soft); }
.map-tool.primary .icon { color: var(--blue-600); }
.map-tool.primary.active { background: #dbeafe; box-shadow: inset 0 0 0 1px #93c5fd; }
#map.pin-mode { cursor: crosshair; }
.map-legend .lg-pin { background: #2563eb; box-shadow: 0 0 0 2px #fff inset; }
.map-legend .lg-inner { border: 1.6px solid #2563eb; background: rgba(59, 130, 246, .18); }
.map-legend .lg-outer { border: 1.6px dashed #8b5cf6; background: rgba(139, 92, 246, .08); }

.map-funnel-bar {
  flex: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 1px; align-items: stretch;
  background: #0f172a; color: #e2e8f0;
  border-top: 1px solid #1e293b;
}
.mf-stat { padding: 9px 14px; display: flex; flex-direction: column; line-height: 1.22; border-right: 1px solid rgba(148, 163, 184, .14); }
.mf-stat span { font-size: 8.5px; color: #94a3b8; letter-spacing: .03em; }
.mf-stat b { font-size: 17px; font-weight: 750; color: #f8fafc; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.mf-stat small { font-size: 8px; color: #64748b; }
.mf-guard {
  align-self: center; margin: 0 10px; padding: 4px 8px; border-radius: 6px;
  font-size: 8.5px; font-weight: 650; color: #fde68a; background: rgba(245, 158, 11, .14);
  border: 1px solid rgba(245, 158, 11, .28); white-space: nowrap;
}

/* 空间漏斗推导 */
.funnel-lead {
  padding: 11px 12px; border-radius: 11px; background: linear-gradient(135deg, #0f172a, #1e293b);
  color: #e2e8f0; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px;
}
.funnel-lead small { display: block; font-size: 8.5px; color: #94a3b8; }
.funnel-lead b { font-size: 24px; font-weight: 750; color: #f8fafc; font-variant-numeric: tabular-nums; letter-spacing: -.03em; }
.funnel-lead b span { font-size: 9px; color: #94a3b8; font-weight: 500; margin-left: 2px; }
.funnel-lead .funnel-status { font-size: 8.5px; padding: 3px 7px; border-radius: 6px; background: rgba(148, 163, 184, .16); color: #cbd5e1; }
.funnel-lead .funnel-status.under { color: #fde68a; background: rgba(245, 158, 11, .14); }
.funnel-lead .funnel-status.over { color: #fecaca; background: rgba(239, 68, 68, .16); }
.funnel-lead .funnel-status.invalid { color: #fee2e2; background: rgba(220, 38, 38, .28); border: 1px solid rgba(248, 113, 113, .5); }
.funnel-message { margin-top: 8px; padding: 8px 10px; border-radius: 8px; font-size: 9.5px; line-height: 1.5; color: #92400e; background: var(--amber-soft); border: 1px solid #fde68a; }
.funnel-message.over { color: #991b1b; background: var(--rose-soft); border-color: #fecaca; }
.funnel-message.under { color: #92400e; background: var(--amber-soft); border-color: #fde68a; }
.funnel-message.ok { color: #047857; background: var(--emerald-soft); border-color: #a7f3d0; }
.funnel-message.invalid { color: #7f1d1d; background: #fef2f2; border-color: #fca5a5; font-weight: 600; }
.funnel-chain { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 9px; }
.funnel-cell { padding: 7px 8px; border: 1px solid var(--line-2); border-radius: 8px; background: #fbfdff; min-width: 0; }
.funnel-cell span { display: block; font-size: 8.5px; color: var(--muted); }
.funnel-cell b { font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; }
.funnel-cell small { display: block; font-size: 8px; color: var(--faint); }
.funnel-note { margin-top: 8px; font-size: 8.5px; color: var(--faint); line-height: 1.5; }
.dual-control { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 9px; }
.dual-control .field-input { height: 30px; }
.dual-control .field-label { font-size: 8.5px; }
.scale-guard {
  margin-top: 9px; display: flex; gap: 7px; align-items: flex-start;
  padding: 8px 10px; border-radius: 8px; font-size: 9px; line-height: 1.5;
  color: #92400e; background: #fffbeb; border: 1px solid #fde68a;
}
.scale-guard .icon { width: 13px; height: 13px; flex: none; margin-top: 1px; color: #d97706; }
.demand-anchor { margin-top: 5px; font-size: 8.5px; color: var(--blue-600); display: flex; align-items: center; gap: 5px; }
.demand-anchor i { width: 1.5px; height: 12px; background: var(--blue); display: inline-block; }
.demand-warning { margin-top: 6px; padding: 6px 8px; border-radius: 7px; font-size: 8.5px; color: #92400e; background: var(--amber-soft); border: 1px solid #fde68a; }
.control-line.anchored { position: relative; padding-top: 16px; }
.anchor-mark { position: absolute; top: 0; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; pointer-events: none; }
.anchor-mark i { width: 1.5px; height: 9px; background: #2563eb; }
.anchor-mark em { font-style: normal; font-size: 7.5px; font-weight: 700; color: #1d4ed8; background: #eff6ff; border: 1px solid #bfdbfe; padding: 0 3px; border-radius: 3px; white-space: nowrap; transform: translateY(-1px); }

/* 商圈档位 */
.district-grid { display: flex; flex-direction: column; gap: 5px; }
.district-option {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 7px 9px; border: 1px solid var(--line); border-radius: 8px;
  background: #fff; text-align: left;
}
.district-option:hover { background: #f8fafc; }
.district-option.selected { border-color: #93c5fd; background: var(--blue-soft); }
.district-option span { display: flex; flex-direction: column; }
.district-option b { font-size: 10.5px; }
.district-option small { font-size: 8px; color: var(--faint); }
.district-option em { font-style: normal; font-size: 9px; color: var(--muted); }

/* 蒙特卡洛 */
.mc-card { padding: 17px 18px; }
.mc-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.mc-stat { padding: 9px 11px; border-radius: 9px; border: 1px solid var(--line-2); background: #fbfdff; }
.mc-stat span { display: block; font-size: 8.5px; color: var(--muted); }
.mc-stat b { display: block; font-size: 21px; line-height: 1.2; font-weight: 750; font-variant-numeric: tabular-nums; letter-spacing: -.03em; }
.mc-stat small { font-size: 8px; color: var(--faint); }
.mc-stat.good b { color: #047857; }
.mc-stat.warn b { color: #b45309; }
.mc-stat.bad b { color: #b91c1c; }
.mc-bar-wrap { margin-top: 13px; }
.mc-bar-head { display: flex; justify-content: space-between; font-size: 8.5px; color: var(--muted); margin-bottom: 5px; }
.mc-bar { position: relative; height: 13px; border-radius: 7px; background: linear-gradient(90deg, #10b981, #fbbf24 55%, #f87171); overflow: hidden; }
.mc-bar .mc-band { position: absolute; top: 0; bottom: 0; background: rgba(255, 255, 255, .34); border-left: 1px solid rgba(255, 255, 255, .75); border-right: 1px solid rgba(255, 255, 255, .75); }
.mc-marker { position: absolute; top: -3px; bottom: -3px; width: 2px; background: #0f172a; }
.mc-marker em { position: absolute; top: -15px; left: 50%; transform: translateX(-50%); font-style: normal; font-size: 7.5px; font-weight: 700; color: #0f172a; background: #fff; padding: 0 3px; border-radius: 3px; white-space: nowrap; }
.mc-axis { display: flex; justify-content: space-between; margin-top: 5px; font-size: 7.5px; color: var(--faint); }
.mc-foot { margin-top: 8px; font-size: 8.5px; color: var(--faint); line-height: 1.5; }
.risk-mc-card { padding: 12px 16px; margin-bottom: 14px; display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.risk-mc-card .mc-inline { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.risk-mc-card .mc-inline span { font-size: 9px; color: var(--muted); }
.risk-mc-card .mc-inline b { font-size: 15px; font-variant-numeric: tabular-nums; }

/* Round2：闭店止损决策卡 */
.closure-card {
  padding: 14px 18px; margin-bottom: 16px;
  border: 1px solid #fde68a;
  background: linear-gradient(135deg, #fffbeb 0%, #fffdf5 52%, #fff 100%);
  box-shadow: 0 16px 34px -30px rgba(180, 83, 9, .55);
}
.closure-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.closure-head .eyebrow.light {
  color: #b45309; background: rgba(245, 158, 11, .12); border-color: #fde68a;
  letter-spacing: .1em;
}
.closure-head h3 { margin: 4px 0 2px; font-size: 15px; color: #78350f; letter-spacing: -.01em; }
.closure-head p { margin: 0; font-size: 9px; color: #a16207; }
.closure-amount { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; text-align: right; }
.closure-amount small { font-size: 8.5px; color: #a16207; }
.closure-amount b { font-size: 26px; line-height: 1.1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.closure-amount b.neg { color: #b91c1c; }
.closure-amount b.pos { color: #047857; }
.closure-amount span { font-size: 8px; color: #a16207; }
.closure-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-top: 11px; }
.closure-grid > div { padding: 7px 9px; border: 1px solid rgba(245, 158, 11, .3); border-radius: 8px; background: rgba(255, 255, 255, .72); }
.closure-grid small { display: block; font-size: 8px; color: #a16207; }
.closure-grid b { display: block; margin-top: 1px; font-size: 12.5px; color: #78350f; font-variant-numeric: tabular-nums; }
.closure-note { margin: 9px 0 0; font-size: 8.5px; line-height: 1.55; color: #92400e; }
@media (max-width: 768px) {
  .closure-card { padding: 12px 13px; }
  .closure-head h3 { font-size: 13.5px; }
  .closure-amount { align-items: flex-start; text-align: left; }
  .closure-amount b { font-size: 22px; }
  .closure-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* 长 VAT 明细不得撑破风险网格 */
  .risk-grid { grid-template-columns: minmax(0, 1fr); }
  .redline-top { flex-wrap: wrap; gap: 2px 8px; }
  .redline-actual { white-space: normal; text-align: right; }
}

/* 4.0 打印图 */
.pr-chart { width: 100%; height: auto; margin-top: 6px; border: 1px solid #e5e7eb; border-radius: 5px; background: #fff; page-break-inside: avoid; }
.pr-stack { display: flex; height: 22px; border-radius: 5px; overflow: hidden; margin-top: 7px; border: 1px solid #e5e7eb; page-break-inside: avoid; }
.pr-stack-seg { height: 100%; }
.pr-stack-legend { display: flex; flex-wrap: wrap; gap: 4px 13px; margin-top: 5px; font-size: 7.5px; color: #374151; }
.pr-stack-legend i { display: inline-block; width: 7px; height: 7px; border-radius: 2px; margin-right: 3px; }
.pr-mc { margin-top: 6px; padding: 6px 8px; border: 1px solid #d1d5db; border-radius: 5px; page-break-inside: avoid; }
.pr-mc-bar { position: relative; height: 12px; border-radius: 6px; margin-top: 4px; overflow: hidden; background: linear-gradient(90deg, #10b981, #fbbf24 55%, #f87171); }
.pr-mc-marker { position: absolute; top: -2px; bottom: -2px; width: 1.5px; background: #111827; }
.pr-funnel-table { margin-top: 5px; }
.pr-funnel-table td { vertical-align: top; }

@media print {
  body { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .pr-chart, .pr-stack, .pr-stack-seg, .pr-mc-bar { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

@media (max-width: 1420px) {
  .map-card, .inspector-card { min-height: 620px; }
  .inspector-tab { padding: 7px 5px; }
  .inspector-tab small { display: none; }
}
@media (max-width: 1220px) {
  .gis-grid { grid-template-columns: 1fr; }
  .map-card, .inspector-card { position: relative; top: 0; height: auto; min-height: 0; max-height: none; }
  .map-card { height: 620px; min-height: 620px; }
  .inspector-card { max-height: none; }
  .inspector-body { max-height: none; overflow: visible; }
  .inspector-tab small { display: block; }
}
@media (max-width: 980px) {
  .map-card { height: 560px; min-height: 560px; }
  .map-funnel-bar { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .mf-guard { grid-column: 1 / -1; margin: 0 10px 7px; justify-self: start; }
  .inspector-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .map-card { height: 500px; min-height: 500px; }
  .map-funnel-bar { grid-template-columns: 1fr 1fr; }
  .mf-stat { padding: 7px 10px; }
  .mf-stat b { font-size: 14px; }
  .funnel-chain { grid-template-columns: 1fr; }
  .mc-grid { grid-template-columns: 1fr; }
  .dual-control { grid-template-columns: 1fr; }
  .inspector-body { padding: 0 13px; }
  .inspector-foot { padding: 10px 13px 12px; }
}
/* ---------------- 4.0 补充：租赁条款 / 季度分界 / 打印 ---------------- */
.rent-lease-note {
  margin-top: 9px; padding: 8px 10px; border-radius: 8px;
  font-size: 9px; line-height: 1.55; color: var(--muted);
  background: #f8fafc; border: 1px solid var(--line-2);
}
.rent-lease-note b { color: var(--text-2); font-variant-numeric: tabular-nums; }
.cf-quarter-line { stroke: #cbd5e1; stroke-width: .8; stroke-dasharray: 2 3; opacity: .75; }
.cf-quarter-label { font-size: 7.5px; fill: #94a3b8; font-family: var(--font); }
.cf-quarter-label.taxed { fill: #b45309; font-weight: 650; }

.pr-chart { overflow: visible; }
.pr-mc small { display: block; margin-top: 4px; font-size: 7.5px; color: #4b5563; line-height: 1.45; }
.pr-mc-fill { position: absolute; left: 0; top: 0; bottom: 0; background: rgba(16, 185, 129, .28); }

@media (max-width: 760px) {
  .rent-lease-note { font-size: 8.5px; }
  .mc-bar-head { font-size: 8px; }
}

/* 4.0 移动端：地图标题与工具栏换行 */
@media (max-width: 620px) {
  .map-topline { flex-wrap: wrap; gap: 7px; padding: 10px 12px; }
  .map-title { flex: 1 1 100%; }
  .map-title > div { min-width: 0; }
  .map-title b, .map-title small { white-space: normal; }
  .map-top-actions { width: 100%; justify-content: space-between; }
  .tile-switch select { max-width: 150px; }
  .tabs-inner { scrollbar-width: none; }
  .tabs-inner::-webkit-scrollbar { display: none; }
}

.mc-bar { overflow: visible; }
.mc-marker em { z-index: 2; }

@media print {
  .pr-section { margin-top: 8px; }
  .pr-section ul { margin: 3px 0 0; padding-left: 16px; }
  .pr-section li { font-size: 8px; line-height: 1.32; }
  .pr-sign { margin-top: 8px; }
}

@media (max-width: 768px) {
  .map-canvas-wrap { display: flex; flex-direction: column; }
  #map { position: relative; inset: auto; flex: 1 1 auto; width: 100%; min-height: 0; }
  .map-tools {
    position: static; order: 2; flex: none; width: auto;
    margin: 6px 8px 8px; padding: 5px 6px; border-radius: 12px;
    flex-direction: row; align-items: center; gap: 2px;
    overflow-x: auto; overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    z-index: 520;
  }
  .map-tools::-webkit-scrollbar { display: none; }
  .tool-group-label { display: none; }
  .tool-sep { flex: none; width: 1px; height: 20px; margin: 0 3px; }
  .map-tool { flex: 0 0 auto; height: 34px; padding: 0 8px; gap: 4px; font-size: 10px; }
  .map-tool .icon { width: 16px; height: 16px; }
  .map-tool span { display: inline; font-size: 10px; white-space: nowrap; }
  .map-card { height: 560px; min-height: 560px; }

  /* Round2：横向工具条右缘淡出遮罩 + 滑动提示 */
  .map-canvas-wrap::after {
    content: ""; position: absolute; right: 0; bottom: 8px;
    width: 38px; height: 44px; z-index: 530; pointer-events: none;
    border-radius: 0 12px 12px 0;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, .86) 58%, #fff 100%);
    box-shadow: inset -1px 0 0 rgba(148, 163, 184, .28);
  }
  .map-canvas-wrap::before {
    content: "→"; position: absolute; right: 4px; bottom: 22px;
    z-index: 531; pointer-events: none;
    width: 16px; height: 16px; display: grid; place-items: center;
    border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgba(15, 23, 42, .18);
    font-size: 11px; font-weight: 800; line-height: 1; color: #475569;
  }
}

/* Round2：移动端顶部两行紧凑布局 */
@media (max-width: 768px) {
  .topbar-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand actions"
      "city industry";
    align-items: center;
    gap: 6px 8px;
    padding: 6px 12px 8px;
    min-height: 0;
  }
  .brand { grid-area: brand; min-width: 0; gap: 7px; }
  .brand-mark { width: 30px; height: 30px; border-radius: 8px; }
  .brand-title { font-size: 15px; gap: 4px; }
  .brand-title .ver { font-size: 8px; padding: 0 4px; vertical-align: 1px; }
  .brand-sub { display: none; }
  .top-controls { display: contents; }
  .top-status { display: none; }
  .city-combo { grid-area: city; min-width: 0; }
  .combo-trigger { width: 100%; min-width: 0; height: 34px; padding: 4px 8px; gap: 6px; border-radius: 9px; }
  .combo-trigger > .icon { width: 15px; height: 15px; }
  .combo-copy b { font-size: 11.5px; }
  .combo-copy small { font-size: 8.5px; }
  .combo-trigger .chev { width: 12px; height: 12px; }
  .industry-picker { grid-area: industry; min-width: 0; height: 34px; padding: 0 8px; gap: 4px; border-radius: 9px; }
  .picker-icon { display: none; }
  .picker-copy { min-width: 0; flex: 1; }
  .picker-copy small { display: none; }
  .industry-picker select { width: 100%; font-size: 11px; padding-right: 10px; }
  .industry-picker .chev { width: 12px; height: 12px; right: 5px; top: 11px; }
  .top-actions { grid-area: actions; justify-self: end; display: flex; gap: 4px; }
  .top-actions .btn.top-btn { width: 32px; height: 32px; min-height: 32px; padding: 0; border-radius: 9px; }
  .top-actions .btn.top-btn .icon { width: 16px; height: 16px; }
}

.sens-arrow { display: inline-grid; place-items: center; width: 14px; height: 14px; margin-right: 5px; border-radius: 4px; font-style: normal; font-size: 9px; font-weight: 800; vertical-align: 1px; }
.sens-arrow.up { color: #047857; background: var(--emerald-soft); border: 1px solid #a7f3d0; }
.sens-arrow.down { color: #b91c1c; background: var(--rose-soft); border: 1px solid #fecaca; }

/* ---------------- Round1：地址搜索 / 地块校验 ---------------- */
.map-searchbar {
  flex: none; position: relative; z-index: 540;
  padding: 8px 14px 7px; border-bottom: 1px solid var(--line-2);
  display: flex; flex-wrap: wrap; align-items: center; gap: 3px 8px;
  background: #fff;
}
.place-search-field {
  flex: 1 1 300px; display: flex; align-items: center; gap: 6px;
  height: 34px; padding: 0 6px 0 9px;
  border: 1px solid var(--line); border-radius: 9px; background: #f8fafc;
}
.place-search-field:focus-within { border-color: #93c5fd; background: #fff; box-shadow: 0 0 0 3px rgba(37, 99, 235, .08); }
.place-search-field .icon { width: 14px; height: 14px; color: var(--muted); flex: none; }
.place-search-field input { flex: 1; min-width: 0; border: 0; outline: none; background: none; font-size: 11.5px; color: var(--text); }
.place-search-field .btn { flex: none; height: 26px; padding: 0 9px; font-size: 10px; }
.place-search-status { flex: 1 1 100%; font-size: 8px; color: var(--faint); line-height: 1.4; }
.place-search-status.live { color: #047857; }
.place-search-status.warn { color: #b91c1c; }
.place-results {
  position: absolute; left: 14px; right: 14px; top: calc(100% - 2px); z-index: 650;
  max-height: 300px; overflow-y: auto; padding: 4px;
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  box-shadow: 0 18px 38px -18px rgba(15, 23, 42, .45);
}
.place-result {
  width: 100%; display: flex; align-items: flex-start; gap: 7px;
  padding: 7px 9px; border: 0; border-radius: 7px; background: none;
  text-align: left; color: var(--text-2); font-size: 10.5px; line-height: 1.35;
}
.place-result:hover, .place-result:focus-visible { background: var(--blue-soft); }
.place-result .pr-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.place-result b { font-size: 10.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.place-result small { font-size: 8px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.place-result .pr-src { flex: none; font-size: 7.5px; color: var(--faint); border: 1px solid var(--line-2); border-radius: 4px; padding: 1px 4px; }
.place-empty { padding: 9px 10px; font-size: 9px; color: var(--muted); line-height: 1.5; }
.land-alert {
  flex: none; display: flex; align-items: center; gap: 9px;
  padding: 8px 14px; color: #991b1b; background: #fff1f2; border-bottom: 1px solid #fecaca;
}
.land-alert .icon { width: 17px; height: 17px; flex: none; color: #dc2626; }
.land-alert > div { display: flex; flex-direction: column; gap: 1px; min-width: 0; line-height: 1.4; }
.land-alert b { font-size: 10.5px; }
.land-alert span { font-size: 8.5px; color: #b91c1c; }
.land-alert small { font-size: 8px; color: #b45309; }
.land-alert .btn { flex: none; margin-left: auto; height: 26px; padding: 0 8px; font-size: 9px; color: #b91c1c; border-color: #fecaca; }
.land-alert.warn { color: #92400e; background: #fffbeb; border-bottom-color: #fde68a; }
.land-alert.warn .icon { color: #d97706; }
.land-alert.warn b { color: #92400e; }
.land-alert.warn span { color: #b45309; }
.land-alert.warn .btn { color: #b45309; border-color: #fde68a; }

@media (max-width: 768px) {
  .map-searchbar { padding: 7px 10px 6px; }
  .place-search-field { flex: 1 1 100%; }
  .place-results { left: 10px; right: 10px; }
  .land-alert { padding: 7px 10px; flex-wrap: wrap; }
  .land-alert .btn { margin-left: 26px; }
}
