/* =========================================================
   文保打卡 · 视觉系统
   纸、墨、朱砂、金
   ========================================================= */
:root {
  --paper: #f7f2e8;
  --paper-2: #f1e9da;
  --paper-3: #e9dfcc;
  --card: #fcf9f3;
  --ink: #24211b;
  --ink-2: #4b453a;
  --muted: #847b6b;
  --faint: #a99f8e;
  --line: #ded4c2;
  --line-soft: #e9e1d2;
  --red: #a63a2b;
  --red-2: #bf503c;
  --red-soft: #f3e2dc;
  --gold: #a9854f;
  --gold-soft: #efe4cf;
  --jade: #456b5e;
  --jade-soft: #e0e9e4;
  --blue: #3d5c78;
  --shadow-sm: 0 2px 8px rgba(58, 45, 25, 0.06);
  --shadow: 0 14px 40px rgba(58, 45, 25, 0.12);
  --shadow-lg: 0 30px 80px rgba(45, 34, 18, 0.2);
  --serif: "Songti SC", "STSong", "Noto Serif SC", "Source Han Serif SC", "SimSun", serif;
  --sans: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", "Hiragino Sans GB", system-ui, -apple-system, sans-serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --radius: 14px;
  --topbar-h: 64px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image:
    radial-gradient(circle at 12% 20%, rgba(169, 133, 79, 0.06), transparent 38%),
    radial-gradient(circle at 88% 8%, rgba(166, 58, 43, 0.045), transparent 32%),
    radial-gradient(circle at 50% 100%, rgba(69, 107, 94, 0.05), transparent 45%);
}
body.no-scroll { overflow: hidden; }
::selection { background: rgba(166, 58, 43, 0.18); }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
img { max-width: 100%; display: block; }
svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

/* ---------- 顶部 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 900;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  gap: 30px;
  padding: 0 clamp(18px, 3vw, 44px);
  background: rgba(247, 242, 232, 0.9);
  border-bottom: 1px solid rgba(222, 212, 194, 0.8);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
}
.brand { display: flex; align-items: center; gap: 11px; flex: none; }
.brand-seal {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: var(--red);
  color: #fbf3e6;
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 1px;
  border-radius: 7px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18), 0 4px 10px rgba(166, 58, 43, 0.22);
  position: relative;
  overflow: hidden;
}
.brand-seal::after {
  content: "";
  position: absolute;
  inset: 3px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 4px;
}
.brand-name {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 1px;
  line-height: 1.1;
  display: flex;
  flex-direction: column;
}
.brand-name small {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 1.6px;
  color: var(--muted);
  font-weight: 400;
  margin-top: 3px;
}
.main-nav { display: flex; align-items: center; gap: 4px; }
.nav-btn {
  position: relative;
  padding: 9px 15px;
  border-radius: 999px;
  color: var(--ink-2);
  font-size: 14px;
  letter-spacing: 1px;
  transition: background 0.2s, color 0.2s;
}
.nav-btn:hover { background: rgba(222, 212, 194, 0.5); }
.nav-btn.is-active { color: var(--red); background: var(--red-soft); font-weight: 600; }
.nav-route-ico { width: 13px; height: 13px; vertical-align: -2px; margin-right: 2px; }
.nav-badge {
  display: inline-grid;
  place-items: center;
  min-width: 17px;
  height: 17px;
  margin-left: 5px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  vertical-align: 1px;
}
.nav-btn.is-active .nav-badge { background: var(--red); }
.lang-switch { display: inline-flex; align-items: center; }
.lang-switch select { height: 30px; padding: 0 24px 0 9px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); color: var(--ink-3); font: inherit; font-size: 10px; cursor: pointer; }
.lang-switch select:focus { outline: none; border-color: var(--gold); }
.en-guide { background: #f7f1e5; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.en-guide-inner { max-width: 1120px; margin: 0 auto; padding: 26px 24px 24px; }
.en-guide-head h2 { margin: 7px 0 8px; font-family: var(--serif); font-size: clamp(22px, 3vw, 30px); font-weight: 600; color: var(--ink); }
.en-guide-head p { max-width: 850px; margin: 0; color: var(--ink-3); font-size: 13px; line-height: 1.9; }
.en-guide-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 18px 0 0; padding: 0; list-style: none; }
.en-guide-list li { padding: 13px 14px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255, 252, 245, 0.65); color: var(--ink-3); font-size: 12px; line-height: 1.8; }
.en-guide-list strong { color: var(--ink); }
@media (max-width: 760px) {
  .lang-switch select { height: 28px; padding-left: 8px; padding-right: 20px; font-size: 10px; }
  .en-guide-inner { padding: 20px 16px 18px; }
  .en-guide-head h2 { font-size: 22px; }
  .en-guide-head p { font-size: 12px; }
  .en-guide-list { grid-template-columns: 1fr; gap: 9px; }
  .en-guide-list li { font-size: 11px; }
}
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.top-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(252, 249, 243, 0.7);
  font-size: 13px;
  color: var(--ink-2);
  transition: all 0.2s;
}
.top-btn svg { width: 15px; height: 15px; }
.top-btn:hover { border-color: var(--gold); color: var(--red); background: #fff; }
.top-btn.ghost { border-color: transparent; background: transparent; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(115deg, rgba(252, 249, 243, 0.92) 0%, rgba(247, 242, 232, 0.6) 55%, rgba(241, 233, 218, 0.5) 100%);
}
.hero-bg { position: absolute; inset: 0; color: rgba(133, 124, 109, 0.18); pointer-events: none; }
.hero-bg svg { width: 100%; height: 100%; }
.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 1560px;
  margin: 0 auto;
  padding: 52px clamp(22px, 4vw, 64px) 48px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  gap: clamp(30px, 5vw, 80px);
  align-items: center;
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 11px;
  letter-spacing: 3.5px;
  color: var(--gold);
  text-transform: uppercase;
  font-weight: 600;
}
.eyebrow span { width: 28px; height: 1px; background: var(--gold); display: inline-block; }
.hero h1 {
  font-family: var(--serif);
  font-size: clamp(38px, 4.6vw, 64px);
  line-height: 1.16;
  margin: 16px 0 18px;
  letter-spacing: 2px;
  font-weight: 700;
  color: var(--ink);
}
.hero h1 em {
  font-style: normal;
  color: var(--red);
  position: relative;
  white-space: nowrap;
}
.hero h1 em::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 4px;
  height: 8px;
  background: rgba(166, 58, 43, 0.13);
  z-index: -1;
}
.hero-lead {
  max-width: 580px;
  color: var(--ink-2);
  font-size: 15px;
  line-height: 1.9;
  margin: 0 0 26px;
}
.hero-search {
  position: relative;
  display: flex;
  align-items: center;
  max-width: 620px;
  height: 56px;
  padding: 0 8px 0 18px;
  background: #fffdf8;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.hero-search:focus-within { border-color: var(--gold); box-shadow: 0 0 0 4px rgba(169, 133, 79, 0.1), var(--shadow-sm); }
.search-icon { width: 19px; height: 19px; color: var(--muted); flex: none; }
.hero-search input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  padding: 0 12px;
  font-size: 15px;
}
.hero-search input::placeholder { color: var(--faint); }
.hero-search kbd {
  flex: none;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--faint);
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: 5px;
  padding: 2px 7px;
  margin-right: 8px;
}
.search-go {
  flex: none;
  height: 40px;
  padding: 0 20px;
  border-radius: 8px;
  background: var(--red);
  color: #fff8ee;
  font-size: 14px;
  letter-spacing: 2px;
  transition: background 0.2s, transform 0.2s;
}
.search-go:hover { background: var(--red-2); }
.search-go:active { transform: scale(0.97); }
.hero-quick { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.hero-quick button {
  font-size: 12px;
  color: var(--ink-2);
  border: 1px solid var(--line);
  background: rgba(255, 253, 248, 0.7);
  padding: 5px 12px;
  border-radius: 999px;
  transition: all 0.2s;
}
.hero-quick button:hover { border-color: var(--red); color: var(--red); background: #fff; }

.hero-art { position: relative; display: flex; flex-direction: column; align-items: flex-end; gap: 22px; }
.hero-seal {
  width: 158px;
  height: 158px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--red);
  color: #fbf1e1;
  font-family: var(--serif);
  font-size: 54px;
  line-height: 1;
  letter-spacing: 4px;
  border-radius: 12px;
  transform: rotate(4deg);
  box-shadow: 0 18px 38px rgba(166, 58, 43, 0.26), inset 0 0 0 5px rgba(255, 250, 240, 0.1);
  position: relative;
}
.hero-seal::before, .hero-seal::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(255, 248, 236, 0.32);
  border-radius: 7px;
}
.hero-seal::before { inset: 7px; }
.hero-seal::after { inset: 12px; border-style: dashed; opacity: 0.55; }
.hero-seal small {
  display: block;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 8px;
  margin-top: 12px;
  padding-left: 8px;
  opacity: 0.85;
}
.hero-note {
  font-family: var(--serif);
  font-size: 15px;
  line-height: 1.9;
  color: var(--muted);
  letter-spacing: 3px;
  text-align: right;
  border-right: 2px solid var(--gold);
  padding-right: 14px;
}
.hero-stats {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}
.hero-stats div { background: rgba(252, 249, 243, 0.88); padding: 15px 18px; }
.hero-stats strong {
  display: block;
  font-family: var(--serif);
  font-size: 27px;
  line-height: 1;
  color: var(--ink);
  letter-spacing: 1px;
}
.hero-stats span { display: block; font-size: 10px; color: var(--muted); letter-spacing: 1.4px; margin-top: 7px; }

/* ---------- 工作区 ---------- */
.workspace {
  max-width: 1600px;
  margin: 0 auto;
  padding: 22px clamp(14px, 2.4vw, 38px) 64px;
  display: grid;
  grid-template-columns: 252px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}
.sidebar {
  position: sticky;
  top: calc(var(--topbar-h) + 16px);
  height: calc(100vh - var(--topbar-h) - 32px);
  display: flex;
  flex-direction: column;
  background: rgba(252, 249, 243, 0.72);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  z-index: 20;
}
.sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line-soft);
  font-size: 13px;
  letter-spacing: 2px;
  color: var(--ink-2);
}
.sidebar-head span { display: flex; align-items: center; gap: 7px; }
.sidebar-head svg { width: 14px; height: 14px; color: var(--gold); }
.sidebar-head button { font-size: 11px; color: var(--muted); letter-spacing: 1px; }
.sidebar-head button:hover { color: var(--red); }
.filter-scroll { flex: 1; overflow-y: auto; padding: 4px 16px 18px; scrollbar-width: thin; }
.filter-group { padding: 15px 0; border-bottom: 1px dashed var(--line-soft); }
.filter-group:last-child { border-bottom: 0; }
.filter-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.4px;
  color: var(--ink-2);
  margin-bottom: 10px;
}
.filter-hint { font-size: 9px; color: var(--faint); font-weight: 400; letter-spacing: 0; }
.province-list { display: flex; flex-direction: column; gap: 1px; max-height: 200px; overflow-y: auto; padding-right: 4px; scrollbar-width: thin; }
.province-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 5px 8px;
  border-radius: 6px;
  font-size: 12.5px;
  color: var(--ink-2);
  text-align: left;
  transition: background 0.15s, color 0.15s;
}
.province-item span:last-child { font-size: 10px; color: var(--faint); font-variant-numeric: tabular-nums; }
.province-item:hover { background: var(--paper-2); }
.province-item.is-active { background: var(--red); color: #fff; }
.province-item.is-active span:last-child { color: rgba(255, 255, 255, 0.7); }
.province-item.all { font-weight: 600; }
.province-item.is-zero { opacity: 0.35; }
.chip-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 253, 248, 0.6);
  font-size: 11.5px;
  color: var(--ink-2);
  line-height: 1.3;
  transition: all 0.15s;
}
.chip b { font-weight: 500; font-size: 9px; color: var(--faint); font-variant-numeric: tabular-nums; }
.chip:hover { border-color: var(--gold); }
.chip.is-active { background: var(--ink); border-color: var(--ink); color: #f9f4e9; }
.chip.is-active b { color: rgba(249, 244, 233, 0.55); }
.chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--c, var(--gold)); }
.chip.is-zero { opacity: 0.38; }
.select {
  width: 100%;
  height: 36px;
  padding: 0 32px 0 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fffdf8 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23847b6b' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center;
  appearance: none;
  font-size: 12.5px;
}
.select.small { width: auto; height: 34px; font-size: 12px; }
.select:disabled { opacity: 0.55; cursor: not-allowed; background: rgba(239, 231, 217, 0.55); }
.switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 0;
  font-size: 12.5px;
  color: var(--ink-2);
  cursor: pointer;
}
.switch-row input { position: absolute; opacity: 0; pointer-events: none; }
.switch-row i {
  width: 34px;
  height: 19px;
  border-radius: 999px;
  background: var(--line);
  position: relative;
  flex: none;
  transition: background 0.2s;
}
.switch-row i::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s var(--ease);
}
.switch-row input:checked + i { background: var(--jade); }
.switch-row input:checked + i::after { transform: translateX(15px); }
.sidebar-foot { padding: 14px 16px; border-top: 1px solid var(--line-soft); background: rgba(241, 233, 218, 0.4); }
.mini-progress > div:first-child { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); letter-spacing: 1px; }
.mini-progress b { color: var(--red); font-size: 13px; }
.mini-progress .bar { height: 4px; border-radius: 99px; background: var(--line); margin: 7px 0 5px; overflow: hidden; }
.mini-progress .bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), var(--red)); border-radius: 99px; transition: width 0.5s var(--ease); }
.mini-progress small { font-size: 9px; color: var(--faint); letter-spacing: 0.6px; }
.text-link { margin-top: 12px; display: inline-flex; align-items: center; gap: 5px; font-size: 11px; color: var(--muted); }
.text-link svg { width: 12px; height: 12px; }
.text-link:hover { color: var(--red); }

.main-panel { min-width: 0; }
.result-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  min-height: 40px;
}
.result-main { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.result-count { display: flex; align-items: baseline; gap: 5px; }
.result-count strong { font-family: var(--serif); font-size: 25px; letter-spacing: 1px; color: var(--ink); }
.result-count span { font-size: 11px; color: var(--muted); letter-spacing: 1px; }
.result-sub { padding-left: 8px; border-left: 1px solid var(--line); }
.active-filters { display: flex; gap: 5px; flex-wrap: wrap; }
.active-filter {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10.5px;
  background: var(--gold-soft);
  color: #7a5a2e;
  border-radius: 999px;
  padding: 3px 8px;
}
.active-filter button { display: grid; place-items: center; width: 13px; height: 13px; color: #7a5a2e; }
.active-filter svg { width: 9px; height: 9px; }
.result-actions { display: flex; align-items: center; gap: 8px; }
.segmented { display: flex; padding: 2px; background: var(--paper-2); border: 1px solid var(--line); border-radius: 8px; }
.segmented button {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px 9px;
  border-radius: 6px;
  font-size: 10.5px;
  color: var(--muted);
  letter-spacing: 0.5px;
}
.segmented svg { width: 12px; height: 12px; }
.segmented button.is-active { background: #fffdf8; color: var(--ink); box-shadow: 0 1px 3px rgba(58, 45, 25, 0.08); }
.mobile-filter { display: none; }
.mobile-prov-strip { display: none; }

/* ---------- 地图与列表 ---------- */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1.32fr) minmax(350px, 0.92fr);
  height: calc(100vh - 210px);
  min-height: 540px;
  max-height: 920px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--card);
  box-shadow: var(--shadow-sm);
}
.split.mode-map { grid-template-columns: 1fr; }
.split.mode-list { grid-template-columns: 1fr; }
.split.mode-map .list-panel, .split.mode-list .map-panel { display: none; }
.map-panel { position: relative; min-height: 0; background: #e9e1d1; }
#map { position: absolute; inset: 0; z-index: 1; background: #e9e1d1; }
.map-top {
  position: absolute;
  z-index: 410;
  top: 16px;
  left: 16px;
  background: rgba(252, 249, 243, 0.9);
  border: 1px solid rgba(222, 212, 194, 0.9);
  border-radius: 10px;
  padding: 10px 14px;
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(8px);
  pointer-events: none;
}
.map-title { font-family: var(--serif); font-size: 15px; letter-spacing: 1.5px; }
.map-sub { font-size: 10px; color: var(--muted); letter-spacing: 0.5px; margin-top: 2px; }
.map-tools {
  position: absolute;
  z-index: 410;
  right: 14px;
  top: 14px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.map-tools button {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: rgba(252, 249, 243, 0.94);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink-2);
  box-shadow: var(--shadow-sm);
  transition: all 0.15s;
}
.map-tools button:hover { background: #fff; color: var(--red); }
.map-tools svg { width: 15px; height: 15px; }
.map-legend {
  position: absolute;
  z-index: 410;
  left: 14px;
  bottom: 34px;
  display: flex;
  flex-wrap: wrap;
  gap: 5px 10px;
  max-width: calc(100% - 28px);
  padding: 8px 11px;
  background: rgba(252, 249, 243, 0.9);
  border: 1px solid var(--line);
  border-radius: 8px;
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
}
.legend-item { display: flex; align-items: center; gap: 5px; font-size: 10px; color: var(--ink-2); letter-spacing: 0.4px; cursor: pointer; }
.legend-item i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.legend-item.is-off { opacity: 0.35; }
.map-foot {
  position: absolute;
  z-index: 410;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: space-between;
  padding: 4px 10px;
  font-size: 9px;
  color: rgba(36, 33, 27, 0.55);
  background: rgba(247, 242, 232, 0.72);
  pointer-events: none;
}
.list-panel { display: flex; flex-direction: column; min-height: 0; background: #fbf8f1; }
.list-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 13px 16px 9px;
  border-bottom: 1px solid var(--line-soft);
}
.list-head span { font-family: var(--serif); font-size: 15px; letter-spacing: 2px; }
.list-head small { font-size: 9.5px; color: var(--faint); letter-spacing: 0.5px; }
.site-list { flex: 1; overflow-y: auto; padding: 8px 10px 20px; scrollbar-width: thin; scroll-behavior: smooth; }
.site-card {
  position: relative;
  display: block;
  width: 100%;
  text-align: left;
  padding: 11px 12px 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
  cursor: pointer;
}
.site-card + .site-card { margin-top: 2px; }
.site-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 2px;
  border-radius: 2px;
  background: transparent;
  transition: background 0.15s;
}
.site-card:hover { background: #fff; border-color: var(--line-soft); }
.site-card:hover::before { background: var(--gold); }
.site-card.is-active { background: #fff; border-color: var(--line); box-shadow: var(--shadow-sm); }
.site-card.is-active::before { background: var(--red); }
.card-top { display: flex; align-items: center; gap: 7px; }
.card-name {
  font-family: var(--serif);
  font-size: 15.5px;
  font-weight: 700;
  letter-spacing: 0.5px;
  line-height: 1.35;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.card-name mark { background: rgba(169, 133, 79, 0.22); color: inherit; padding: 0 1px; border-radius: 2px; }
.card-alias { margin: 2px 0 0 0; color: var(--faint); font-size: 10px; line-height: 1.5; }
.detail-alias { margin: 2px 0 4px; color: var(--faint); font-size: 11px; }
.card-meta { display: flex; align-items: center; gap: 6px; margin-top: 4px; font-size: 10.5px; color: var(--muted); }
.card-meta .sep { width: 1px; height: 9px; background: var(--line); }
.card-addr {
  margin: 5px 0 0;
  font-size: 10.5px;
  color: var(--faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.2px;
}
.card-foot { display: flex; align-items: center; gap: 6px; margin-top: 7px; }
.mini-btn {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  height: 22px;
  padding: 0 7px;
  border: 1px solid var(--line);
  border-radius: 5px;
  font-size: 9.5px;
  color: var(--muted);
  background: rgba(255, 253, 248, 0.5);
  transition: all 0.15s;
}
.mini-btn svg { width: 10px; height: 10px; }
.mini-btn:hover { border-color: var(--gold); color: var(--ink); }
.mini-btn.is-on { background: var(--jade); border-color: var(--jade); color: #fff; }
.mini-btn.wish.is-on { background: var(--gold); border-color: var(--gold); }
.card-code { margin-left: auto; font-family: var(--mono); font-size: 8.5px; color: var(--faint); letter-spacing: 0; }
.card-flags { display: flex; gap: 3px; }
.flag {
  font-size: 8px;
  padding: 1px 4px;
  border-radius: 2px;
  background: var(--paper-2);
  color: var(--muted);
  letter-spacing: 0.5px;
}
.flag.visited { background: var(--jade-soft); color: var(--jade); }
.flag.wish { background: var(--gold-soft); color: #8a6428; }
.flag.approx { background: #eee9df; color: #8d8373; }
.batch-badge {
  flex: none;
  display: inline-flex;
  align-items: center;
  height: 17px;
  padding: 0 5px;
  border-radius: 3px;
  font-size: 8.5px;
  letter-spacing: 0.3px;
  color: #fff;
  background: var(--ink-2);
}
.batch-badge.b1 { background: #8c3b2c; }
.batch-badge.b2 { background: #9b5a35; }
.batch-badge.b3 { background: #7e6a3f; }
.batch-badge.b4 { background: #556b4f; }
.batch-badge.b5 { background: #3f615d; }
.batch-badge.b6 { background: #3f5874; }
.batch-badge.b7 { background: #5c5470; }
.batch-badge.b8 { background: #6d4b45; }
.cat-label { display: inline-flex; align-items: center; gap: 4px; font-size: 10px; color: var(--muted); }
.cat-label i { width: 6px; height: 6px; border-radius: 50%; background: var(--c); }
.list-sentinel { height: 1px; }
.list-empty { padding: 60px 24px; text-align: center; color: var(--muted); }
.empty-seal {
  width: 58px;
  height: 58px;
  margin: 0 auto 14px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: var(--serif);
  font-size: 24px;
  color: var(--faint);
  transform: rotate(-4deg);
}
.list-empty p { margin: 0 0 12px; font-size: 13px; }
.list-empty button { font-size: 12px; color: var(--red); border-bottom: 1px solid currentColor; }

/* ---------- Leaflet ---------- */
.leaflet-container { background: #e9e1d1; font-family: var(--sans); }
.leaflet-overlay-pane svg { width: auto !important; height: auto !important; max-width: none !important; max-height: none !important; }
.leaflet-control-attribution { display: none; }
.leaflet-interactive { transition: fill-opacity 0.15s; }
.leaflet-tooltip.map-tip {
  background: rgba(36, 33, 27, 0.92);
  color: #fbf6ec;
  border: 0;
  border-radius: 5px;
  padding: 4px 8px;
  font-size: 11px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}
.leaflet-tooltip.map-tip::before { display: none; }
.cluster-icon {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: rgba(252, 249, 243, 0.95);
  color: #a63a2b;
  font-family: var(--sans);
  font-size: 10.5px;
  font-weight: 700;
  border: 2px solid rgba(166, 58, 43, 0.85);
  box-shadow: 0 3px 12px rgba(90, 40, 25, 0.2);
  letter-spacing: -0.2px;
}
.cluster-icon.small {
  background: rgba(252, 249, 243, 0.95);
  color: #456b5e;
  border-color: rgba(69, 107, 94, 0.8);
}
.cluster-icon.large {
  background: rgba(166, 58, 43, 0.94);
  color: #fff8ee;
  border-color: rgba(255, 248, 238, 0.75);
  box-shadow: 0 5px 18px rgba(90, 40, 25, 0.3);
}
.leaflet-tile-pane { filter: saturate(0.72) sepia(0.08) contrast(0.98) brightness(1.02); }
.selected-ring {
  border-radius: 50%;
  border: 2px solid var(--red);
  box-shadow: 0 0 0 6px rgba(166, 58, 43, 0.14);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(166, 58, 43, 0.12); }
  50% { box-shadow: 0 0 0 12px rgba(166, 58, 43, 0.02); }
}

/* ---------- 详情抽屉 ---------- */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(32, 27, 19, 0.32);
  backdrop-filter: blur(2px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.drawer-backdrop.is-open { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed;
  z-index: 1010;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(460px, 100vw);
  background: var(--paper);
  border-left: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
  transform: translateX(102%);
  transition: transform 0.4s var(--ease);
  display: flex;
  flex-direction: column;
}
.drawer.is-open { transform: translateX(0); }
.drawer.is-route-preview .detail-pager,
.drawer.is-route-preview [data-action="focus"] { display: none; }
.drawer-scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; }
.drawer-inner { padding: 0 28px 40px; }
.drawer-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(252, 249, 243, 0.9);
  border: 1px solid var(--line);
  color: var(--ink-2);
}
.drawer-close:hover { color: var(--red); background: #fff; }
.drawer-close svg { width: 15px; height: 15px; }
.detail-head {
  padding: 34px 0 22px;
  border-bottom: 1px solid var(--line);
  position: relative;
}
.detail-badges { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.detail-badges .batch-badge { height: 20px; font-size: 10px; padding: 0 7px; border-radius: 4px; }
.detail-cat {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 20px;
  padding: 0 7px;
  border-radius: 4px;
  background: var(--paper-2);
  font-size: 10px;
  color: var(--ink-2);
}
.detail-cat i { width: 6px; height: 6px; border-radius: 50%; background: var(--c); }
.detail-name {
  font-family: var(--serif);
  font-size: clamp(26px, 3.4vw, 34px);
  line-height: 1.3;
  letter-spacing: 1px;
  margin: 0 0 6px;
  font-weight: 700;
}
.detail-en { font-size: 10.5px; color: var(--faint); letter-spacing: 0.4px; margin: 0 0 14px; text-transform: uppercase; }
.detail-loc { display: flex; align-items: flex-start; gap: 7px; font-size: 12.5px; color: var(--ink-2); }
.detail-loc svg { width: 14px; height: 14px; color: var(--red); flex: none; margin-top: 3px; }
.detail-loc small { display: block; color: var(--muted); font-size: 10.5px; margin-top: 3px; }
.detail-actions { display: flex; gap: 8px; margin: 20px 0 8px; }
.big-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 44px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #fffdf8;
  font-size: 13px;
  letter-spacing: 1px;
  transition: all 0.2s;
}
.big-btn svg { width: 16px; height: 16px; }
.big-btn:hover { border-color: var(--gold); }
.big-btn.primary { background: var(--red); border-color: var(--red); color: #fff8ee; }
.big-btn.primary:hover { background: var(--red-2); }
.big-btn.primary.is-on { background: var(--jade); border-color: var(--jade); }
.big-btn.wish { color: var(--ink-2); }
.big-btn.wish.is-on { background: var(--gold); border-color: var(--gold); color: #fff; }
.detail-section { padding: 20px 0; border-bottom: 1px solid var(--line-soft); }
.detail-section:last-child { border-bottom: 0; }
.section-label {
  font-size: 10px;
  letter-spacing: 2.5px;
  color: var(--faint);
  text-transform: uppercase;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-label::after { content: ""; flex: 1; height: 1px; background: var(--line-soft); }
.fact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; }
.fact { min-width: 0; }
.fact dt { font-size: 9.5px; color: var(--faint); letter-spacing: 1px; }
.fact dd { margin: 3px 0 0; font-size: 12.5px; color: var(--ink); line-height: 1.5; }
.fact dd.mono { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0; color: var(--muted); }
.addr-box {
  font-size: 12.5px;
  line-height: 1.8;
  color: var(--ink-2);
  background: rgba(241, 233, 218, 0.55);
  border: 1px solid var(--line-soft);
  border-radius: 8px;
  padding: 11px 13px;
}
.addr-box .approx-note { display: block; margin-top: 6px; font-size: 10px; color: var(--gold); }
.nav-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.nav-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  height: 38px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 7px;
  font-size: 11.5px;
  color: var(--ink-2);
  background: #fffdf8;
  transition: all 0.15s;
}
.nav-link:hover { border-color: var(--red); color: var(--red); }
.nav-link svg { width: 12px; height: 12px; color: var(--faint); }
.nav-link:hover svg { color: var(--red); }
.note-field { width: 100%; min-height: 74px; resize: vertical; border: 1px solid var(--line); border-radius: 8px; background: #fffdf8; padding: 10px 12px; font-size: 12.5px; line-height: 1.7; outline: 0; }
.note-field:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(169, 133, 79, 0.1); }
.note-field::placeholder { color: var(--faint); }
.nearby-list { display: flex; flex-direction: column; gap: 2px; }
.nearby-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 6px;
  border-radius: 6px;
  text-align: left;
  font-size: 12px;
  width: 100%;
}
.nearby-item:hover { background: var(--paper-2); }
.nearby-item .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nearby-item .dist { font-size: 10px; color: var(--faint); flex: none; }
.nearby-item .batch-badge { height: 15px; font-size: 8px; }
.detail-pager { display: flex; gap: 8px; margin-top: 22px; }
.detail-pager button { flex: 1; height: 38px; border: 1px solid var(--line); border-radius: 7px; font-size: 11px; color: var(--muted); display: flex; align-items: center; justify-content: center; gap: 4px; }
.detail-pager button:hover { border-color: var(--gold); color: var(--ink); }
.detail-pager svg { width: 12px; height: 12px; }
.detail-stamp {
  position: absolute;
  right: 2px;
  top: 30px;
  width: 74px;
  height: 74px;
  border: 2px solid var(--red);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--red);
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 1px;
  line-height: 1.2;
  text-align: center;
  transform: rotate(-12deg);
  opacity: 0.85;
  animation: stampIn 0.35s var(--ease);
  pointer-events: none;
}
@keyframes stampIn {
  from { transform: rotate(-12deg) scale(1.6); opacity: 0; }
  to { transform: rotate(-12deg) scale(1); opacity: 0.85; }
}

/* ---------- 数据页 ---------- */
.page-view { position: relative; z-index: 1; }
.page-inner { max-width: 1320px; margin: 0 auto; padding: 52px clamp(18px, 4vw, 48px) 80px; }
.page-head { max-width: 760px; margin-bottom: 34px; }
.page-head h2 {
  text-wrap: balance;
  font-family: var(--serif);
  font-size: clamp(32px, 4vw, 50px);
  line-height: 1.25;
  letter-spacing: 1px;
  margin: 14px 0 12px;
}
.page-head h2 em { font-style: normal; color: var(--red); }
.page-head p { color: var(--muted); font-size: 14px; line-height: 1.9; margin: 0; }
.stat-hero { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; margin-bottom: 26px; }
.stat-hero div { background: var(--card); padding: 22px 24px; }
.stat-hero strong { display: block; font-family: var(--serif); font-size: 40px; line-height: 1; letter-spacing: 1px; }
.stat-hero span { display: block; margin-top: 8px; font-size: 10.5px; color: var(--muted); letter-spacing: 1.5px; }
.stat-hero div:nth-child(2) strong { color: var(--red); }
.stat-hero div:nth-child(3) strong { color: var(--jade); }
.stat-hero div:nth-child(4) strong { color: var(--gold); }
.chart-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 20px; margin-bottom: 20px; }
.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 24px;
  min-width: 0;
}
.panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.panel-head h3 { font-family: var(--serif); font-size: 18px; letter-spacing: 1.5px; margin: 0; }
.panel-head span { font-size: 10px; color: var(--faint); letter-spacing: 0.5px; }
.bar-chart { display: flex; flex-direction: column; gap: 9px; }
.bar-row { display: grid; grid-template-columns: 58px 1fr 44px; align-items: center; gap: 10px; cursor: pointer; }
.bar-row:hover .bar-fill { filter: brightness(1.08); }
.bar-label { font-size: 11.5px; color: var(--ink-2); letter-spacing: 0.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-track { height: 15px; background: var(--paper-2); border-radius: 3px; overflow: hidden; }
.bar-fill { height: 100%; background: linear-gradient(90deg, #c8a46a, #a9854f); border-radius: 3px; transition: width 0.8s var(--ease); min-width: 2px; }
.bar-row:nth-child(1) .bar-fill, .bar-row:nth-child(2) .bar-fill, .bar-row:nth-child(3) .bar-fill { background: linear-gradient(90deg, #bd5642, #a63a2b); }
.bar-value { font-family: var(--mono); font-size: 10px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.donut-wrap { display: flex; align-items: center; gap: 24px; }
.donut { width: 190px; height: 190px; flex: none; }
.donut circle { transition: stroke-width 0.2s, opacity 0.2s; cursor: pointer; }
.donut circle:hover { stroke-width: 30; }
.donut-legend { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.donut-item { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--ink-2); cursor: pointer; }
.donut-item i { width: 8px; height: 8px; border-radius: 2px; background: var(--c); flex: none; }
.donut-item b { margin-left: auto; font-family: var(--mono); font-size: 10px; color: var(--muted); font-weight: 400; }
.timeline { display: grid; grid-template-columns: repeat(8, 1fr); gap: 8px; }
.timeline-item {
  position: relative;
  padding: 14px 10px 12px;
  border: 1px solid var(--line-soft);
  border-radius: 9px;
  background: rgba(255, 253, 248, 0.6);
  text-align: left;
  transition: all 0.2s;
}
.timeline-item:hover { border-color: var(--gold); transform: translateY(-2px); }
.timeline-item.is-active { background: var(--ink); color: #f9f4e9; border-color: var(--ink); }
.timeline-item .yr { font-family: var(--mono); font-size: 9px; color: var(--gold); letter-spacing: 0; }
.timeline-item.is-active .yr { color: #d9b982; }
.timeline-item strong { display: block; font-family: var(--serif); font-size: 15px; margin: 4px 0 2px; letter-spacing: 1px; }
.timeline-item span { display: block; font-size: 9.5px; color: var(--muted); }
.timeline-item.is-active span { color: rgba(249, 244, 233, 0.65); }
.insight-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 20px; }
.insight {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px 20px;
}
.insight .k { font-size: 9.5px; letter-spacing: 2px; color: var(--faint); }
.insight .v { font-family: var(--serif); font-size: 23px; margin: 4px 0 2px; letter-spacing: 1px; }
.insight .d { font-size: 11px; color: var(--muted); line-height: 1.6; }
.era-chart { display: flex; flex-direction: column; gap: 7px; }
.era-row { display: grid; grid-template-columns: 72px 1fr 38px; align-items: center; gap: 9px; font-size: 11px; }
.era-row .bar-track { height: 9px; }
.era-row .bar-fill { background: linear-gradient(90deg, #7d9a8c, #456b5e); }

/* ---------- 我的足迹 ---------- */
.trail-hero {
  display: grid;
  grid-template-columns: 210px 1fr;
  gap: 30px;
  align-items: center;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 28px 32px;
  margin-bottom: 22px;
}
.ring-wrap { position: relative; width: 180px; height: 180px; }
.ring-wrap svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-bg { fill: none; stroke: var(--paper-3); stroke-width: 8; }
.ring-fg { fill: none; stroke: var(--red); stroke-width: 8; stroke-linecap: round; transition: stroke-dashoffset 1s var(--ease); }
.ring-text { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.ring-text strong { font-family: var(--serif); font-size: 38px; line-height: 1; }
.ring-text span { font-size: 9.5px; color: var(--muted); letter-spacing: 1.5px; margin-top: 6px; }
.trail-summary h3 { font-family: var(--serif); font-size: 26px; letter-spacing: 1px; margin: 0 0 8px; text-wrap: balance; }
.trail-summary p { color: var(--muted); font-size: 12.5px; margin: 0 0 16px; }
.trail-kpis { display: flex; gap: 26px; flex-wrap: wrap; }
.trail-kpis div strong { display: block; font-family: var(--serif); font-size: 24px; }
.trail-kpis div span { font-size: 10px; color: var(--faint); letter-spacing: 1px; }
.trail-kpis .wish strong { color: var(--gold); }
.trail-kpis .prov strong { color: var(--jade); }
.trail-actions { margin-left: auto; display: flex; gap: 8px; align-self: flex-start; }
.trail-actions button { height: 34px; padding: 0 12px; border: 1px solid var(--line); border-radius: 7px; font-size: 11px; display: flex; align-items: center; gap: 5px; color: var(--ink-2); }
.trail-actions button:hover { border-color: var(--gold); color: var(--red); }
.trail-actions svg { width: 12px; height: 12px; }
.trail-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 22px; }
.progress-list { display: flex; flex-direction: column; gap: 9px; }
.progress-row { display: grid; grid-template-columns: 64px 1fr 44px; gap: 9px; align-items: center; font-size: 11px; }
.progress-row .bar-track { height: 8px; }
.progress-row .bar-fill { background: linear-gradient(90deg, #6d9284, #456b5e); }
.trail-panel { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px; }
.trail-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.trail-tab { padding: 9px 14px; font-size: 12.5px; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.trail-tab.is-active { color: var(--red); border-color: var(--red); font-weight: 600; }
.trail-tab b { font-size: 9px; margin-left: 4px; color: var(--faint); }
.trail-item { display: flex; align-items: flex-start; gap: 12px; padding: 12px 6px; border-bottom: 1px dashed var(--line-soft); }
.trail-item:last-child { border-bottom: 0; }
.trail-item .idx { font-family: var(--mono); font-size: 9px; color: var(--faint); width: 26px; flex: none; padding-top: 3px; }
.trail-item .body { flex: 1; min-width: 0; }
.trail-item .nm { font-family: var(--serif); font-size: 14px; font-weight: 700; letter-spacing: 0.3px; cursor: pointer; }
.trail-item .nm:hover { color: var(--red); }
.trail-item .meta { font-size: 10px; color: var(--muted); margin-top: 2px; }
.trail-item .note { font-size: 11px; color: var(--ink-2); margin-top: 4px; background: var(--paper-2); padding: 4px 8px; border-radius: 4px; }
.trail-item .ops { display: flex; gap: 4px; flex: none; }
.trail-item .ops button { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 5px; color: var(--faint); }
.trail-item .ops button:hover { background: var(--red-soft); color: var(--red); }
.trail-item .ops svg { width: 12px; height: 12px; }
.trail-empty { padding: 50px 20px; text-align: center; color: var(--muted); }
.trail-empty .empty-seal { margin-bottom: 14px; }
.trail-empty button { margin-top: 12px; color: var(--red); font-size: 12px; border-bottom: 1px solid currentColor; }
.trail-empty p { font-size: 12.5px; margin: 0; }

/* ---------- 弹窗 / Toast ---------- */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1100;
  background: rgba(32, 27, 19, 0.38);
  backdrop-filter: blur(3px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.modal-backdrop.is-open { opacity: 1; pointer-events: auto; }
.modal {
  position: fixed;
  z-index: 1110;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -46%) scale(0.98);
  width: min(620px, calc(100vw - 32px));
  max-height: calc(100vh - 60px);
  overflow-y: auto;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s, transform 0.3s var(--ease);
}
.modal.is-open { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.modal-close { position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; color: var(--muted); }
.modal-close:hover { background: var(--paper-2); color: var(--red); }
.modal-close svg { width: 15px; height: 15px; }
.modal-body { padding: 34px 36px 32px; }
.modal h2 { font-family: var(--serif); font-size: 30px; letter-spacing: 1px; margin: 12px 0 16px; }
.modal h3 { font-size: 12px; letter-spacing: 2px; color: var(--gold); margin: 24px 0 8px; }
.modal p { font-size: 12.5px; line-height: 1.9; color: var(--ink-2); margin: 0 0 8px; }
.source-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.source-list li { border: 1px solid var(--line-soft); border-radius: 8px; padding: 10px 12px; background: rgba(255, 253, 248, 0.6); }
.source-list a { font-size: 12.5px; color: var(--red); display: inline-flex; align-items: center; gap: 4px; }
.source-list a svg { width: 11px; height: 11px; }
.source-list p { font-size: 10.5px; color: var(--muted); margin: 3px 0 0; line-height: 1.7; }
.modal-foot { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line); }
.modal-foot a { font-size: 11px; color: var(--muted); display: inline-flex; align-items: center; gap: 4px; }
.modal-foot a:hover { color: var(--red); }
.modal-foot svg { width: 11px; height: 11px; }
.toast {
  position: fixed;
  z-index: 1300;
  left: 50%;
  bottom: 32px;
  transform: translate(-50%, 20px);
  background: rgba(36, 33, 27, 0.94);
  color: #fbf6ec;
  font-size: 12px;
  padding: 10px 18px;
  border-radius: 999px;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s var(--ease);
  white-space: nowrap;
  max-width: calc(100vw - 32px);
  overflow: hidden;
  text-overflow: ellipsis;
}
.toast.is-show { opacity: 1; transform: translate(-50%, 0); }
.back-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 500;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: rgba(252, 249, 243, 0.9);
  border: 1px solid var(--line);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
  color: var(--ink-2);
  opacity: 0;
  pointer-events: none;
  transition: all 0.2s;
}
.back-top.is-show { opacity: 1; pointer-events: auto; }
.back-top svg { width: 14px; height: 14px; transform: rotate(90deg); }

/* ---------- 响应式 ---------- */
@media (max-width: 1180px) {
  .hero-inner { grid-template-columns: 1fr 330px; padding-top: 40px; padding-bottom: 38px; }
  .hero-seal { width: 132px; height: 132px; font-size: 44px; }
  .hero-stats strong { font-size: 23px; }
  .workspace { grid-template-columns: 228px minmax(0, 1fr); gap: 14px; }
  .split { grid-template-columns: minmax(0, 1.15fr) minmax(330px, 0.9fr); }
  .timeline { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 980px) {
  .topbar { gap: 16px; }
  .brand-name small { display: none; }
  .hero-inner { grid-template-columns: 1fr; gap: 28px; }
  .hero-art { display: none; }
  .hero h1 { font-size: clamp(36px, 7vw, 54px); }
  .workspace { grid-template-columns: 1fr; padding-top: 14px; }
  .sidebar {
    position: fixed;
    z-index: 1050;
    top: 0;
    left: 0;
    bottom: 0;
    height: 100vh;
    width: min(320px, 88vw);
    border-radius: 0;
    transform: translateX(-102%);
    transition: transform 0.35s var(--ease);
    background: var(--paper);
    box-shadow: var(--shadow-lg);
  }
  .sidebar.is-open { transform: translateX(0); }
  .mobile-filter { display: inline-flex; align-items: center; gap: 4px; height: 30px; padding: 0 9px; border: 1px solid var(--line); border-radius: 6px; font-size: 11px; color: var(--ink-2); }
  .mobile-filter svg { width: 12px; height: 12px; }
  .split { height: calc(100vh - 150px); min-height: 500px; grid-template-columns: 1fr; grid-template-rows: minmax(280px, 0.95fr) minmax(260px, 1.05fr); }
  .split.mode-map, .split.mode-list { grid-template-rows: 1fr; }
  .list-panel { border-left: 0; border-top: 1px solid var(--line); }
  .stat-hero { grid-template-columns: repeat(2, 1fr); }
  .chart-grid { grid-template-columns: 1fr; }
  .trail-hero { grid-template-columns: 170px 1fr; gap: 20px; padding: 22px; }
  .ring-wrap { width: 150px; height: 150px; }
  .trail-columns { grid-template-columns: 1fr; }
  .timeline { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 760px) {
  :root { --topbar-h: 58px; }
  body { padding-bottom: 64px; }
  .topbar { padding: 0 14px; gap: 10px; }
  .brand-seal { width: 33px; height: 33px; font-size: 13px; }
  .brand-name { font-size: 17px; }
  .main-nav {
    position: fixed;
    z-index: 950;
    left: 0;
    right: 0;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    background: rgba(252, 249, 243, 0.96);
    border-top: 1px solid var(--line);
    backdrop-filter: blur(14px);
    padding: 5px 4px calc(5px + env(safe-area-inset-bottom));
  }
  .nav-btn { padding: 8px 4px; border-radius: 8px; font-size: 11.5px; letter-spacing: 1px; }
  .nav-btn.is-active { background: transparent; color: var(--red); }
  .nav-btn.is-active::after { content: ""; position: absolute; left: 50%; bottom: 1px; width: 15px; height: 2px; border-radius: 2px; background: var(--red); transform: translateX(-50%); }
  .nav-badge { min-width: 15px; height: 15px; font-size: 9px; }
  .top-actions { gap: 4px; }
  .top-btn { width: 34px; height: 34px; padding: 0; justify-content: center; border-radius: 50%; }
  .top-btn span { display: none; }
  .hero-inner { padding: 30px 18px 30px; gap: 18px; }
  .hero h1 { font-size: clamp(32px, 9vw, 44px); margin: 12px 0 14px; letter-spacing: 1px; }
  .hero-lead { font-size: 13px; line-height: 1.8; margin-bottom: 18px; }
  .hero-search { height: 50px; padding-left: 14px; }
  .hero-search kbd { display: none; }
  .hero-search input { font-size: 14px; }
  .search-go { height: 36px; padding: 0 14px; font-size: 12px; letter-spacing: 1px; }
  .hero-quick { margin-top: 12px; gap: 6px; }
  .hero-quick button { font-size: 10.5px; padding: 4px 9px; }
  .workspace { padding: 10px 10px 30px; gap: 8px; }
  .result-bar { margin-bottom: 8px; gap: 8px; }
  .result-count strong { font-size: 21px; }
  .result-sub { display: none; }
  .result-actions { width: 100%; justify-content: space-between; }
  .segmented button span { display: none; }
  .segmented button { padding: 6px 10px; }
  .segmented svg { width: 14px; height: 14px; }
  .split { height: calc(100vh - 255px); min-height: 470px; border-radius: 10px; grid-template-rows: minmax(240px, 0.9fr) minmax(230px, 1.1fr); }
  .map-top { top: 10px; left: 10px; padding: 7px 10px; }
  .map-title { font-size: 13px; }
  .map-sub { display: none; }
  .map-tools { top: 10px; right: 10px; gap: 4px; }
  .map-tools button { width: 30px; height: 30px; }
  .map-legend { left: 8px; bottom: 26px; gap: 3px 8px; padding: 6px 8px; }
  .legend-item { font-size: 9px; }
  .list-head { padding: 10px 12px 7px; }
  .site-list { padding: 5px 7px 14px; }
  .site-card { padding: 9px 9px 8px; }
  .card-name { font-size: 14.5px; }
  .drawer { width: 100vw; top: 0; }
  .drawer-inner { padding: 0 20px 36px; }
  .detail-head { padding-top: 30px; }
  .page-inner { padding: 34px 16px 60px; }
  .stat-hero { grid-template-columns: repeat(2, 1fr); }
  .stat-hero strong { font-size: 30px; }
  .stat-hero div { padding: 16px 16px; }
  .panel { padding: 17px 16px; }
  .donut-wrap { flex-direction: column; gap: 14px; }
  .donut { width: 160px; height: 160px; }
  .donut-legend { width: 100%; }
  .timeline { grid-template-columns: repeat(2, 1fr); }
  .insight-grid { grid-template-columns: 1fr; }
  .trail-hero { grid-template-columns: 1fr; text-align: center; padding: 22px 18px; }
  .ring-wrap { margin: 0 auto; }
  .trail-summary p { margin-bottom: 12px; }
  .trail-kpis { justify-content: center; gap: 18px; }
  .trail-actions { margin: 0 auto; }
  .trail-columns { gap: 12px; }
  .modal-body { padding: 28px 20px 24px; }
  .modal h2 { font-size: 24px; }
  .back-top { display: none; }
  .toast { bottom: 78px; }
  .bar-row { grid-template-columns: 48px 1fr 37px; gap: 7px; }
  .bar-label { font-size: 10.5px; }
}
@media (max-width: 420px) {
  .hero h1 { font-size: 32px; }
  .hero-lead { display: none; }
  .hero-quick button:nth-child(4) { display: none; }
  .split { grid-template-rows: minmax(220px, 0.85fr) minmax(240px, 1.15fr); }
  .card-code { display: none; }
  .fact-grid { grid-template-columns: 1fr; }
  .nav-grid { grid-template-columns: 1fr; }
  .stat-hero { grid-template-columns: 1fr 1fr; }
  .stat-hero strong { font-size: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

/* 滚动条 */
::-webkit-scrollbar { width: 7px; height: 7px; }
::-webkit-scrollbar-thumb { background: rgba(133, 124, 109, 0.25); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: rgba(133, 124, 109, 0.4); }
::-webkit-scrollbar-track { background: transparent; }

/* ---------- 详情：简介、图片与灯箱 ---------- */
.media-loading { display: inline-block; padding: 10px 0; color: var(--faint); font-size: 11px; letter-spacing: 0.5px; }
.detail-intro { font-size: 13px; line-height: 1.95; color: var(--ink-2); letter-spacing: 0.2px; }
.detail-source { margin-top: 9px; font-size: 10px; line-height: 1.7; color: var(--faint); }
.detail-source a { color: var(--gold); display: inline-flex; align-items: center; gap: 3px; border-bottom: 1px dotted rgba(169, 133, 79, 0.45); }
.detail-source a:hover { color: var(--red); }
.detail-source svg { width: 10px; height: 10px; }
.media-count { font-size: 9px; color: var(--faint); letter-spacing: 0; margin-left: 4px; }
.gallery-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.gallery-grid.single { grid-template-columns: 1fr; }
.gallery-item {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  padding: 0;
  border: 1px solid var(--line-soft);
  border-radius: 6px;
  overflow: hidden;
  background: var(--paper-2);
}
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.35s var(--ease); }
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item.is-broken { display: none; }
.media-empty {
  padding: 28px 18px;
  text-align: center;
  color: var(--faint);
  font-size: 11px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: rgba(241, 233, 218, 0.35);
}
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1500;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 30px;
  background: rgba(20, 17, 12, 0.92);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}
.lightbox.is-open { opacity: 1; pointer-events: auto; }
.lightbox img { height: min(82vh, 900px); width: auto; max-width: 94vw; object-fit: contain; border-radius: 4px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5); }
.lightbox-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #f7efe2;
  border: 1px solid rgba(247, 239, 226, 0.3);
  background: rgba(255, 255, 255, 0.06);
}
.lightbox-close:hover { background: rgba(255, 255, 255, 0.16); }
.lightbox-close svg { width: 16px; height: 16px; }
.lightbox-caption { color: rgba(247, 239, 226, 0.72); font-size: 11px; letter-spacing: 1px; }
@media (max-width: 760px) {
  .gallery-grid { gap: 5px; }
  .lightbox { padding: 16px; }
}

/* ---------- 移动端导航与筛选抽屉 ---------- */
.mobile-nav { display: none; }
.sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1040;
  background: rgba(32, 27, 19, 0.34);
  backdrop-filter: blur(2px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}
.sidebar-backdrop.is-open { opacity: 1; pointer-events: auto; }
.sidebar-head-actions { display: flex; align-items: center; gap: 10px; }
.sidebar-close { display: none; width: 28px; height: 28px; place-items: center; border-radius: 50%; color: var(--ink-2); }
.sidebar-close:hover { background: var(--paper-2); color: var(--red); }
.sidebar-close svg { width: 14px; height: 14px; }
.trail-hero { grid-template-columns: 200px minmax(0, 1fr) auto; }
.trail-actions { margin-left: 0; align-self: start; flex-direction: row; flex-wrap: wrap; justify-content: flex-end; max-width: 230px; }

@media (max-width: 760px) {
  .main-nav { display: none !important; }
  .mobile-nav {
    position: fixed;
    z-index: 950;
    left: 0;
    right: 0;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: rgba(252, 249, 243, 0.97);
    border-top: 1px solid var(--line);
    backdrop-filter: blur(14px);
    padding: 4px 4px calc(4px + env(safe-area-inset-bottom));
  }
  .mobile-nav .nav-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 5px 4px;
    border-radius: 8px;
    font-size: 10px;
    letter-spacing: 0.5px;
    color: var(--muted);
    position: relative;
  }
  .mobile-nav .nav-btn svg { width: 17px; height: 17px; }
  .mobile-nav .nav-btn.is-active { color: var(--red); background: transparent; font-weight: 600; }
  .mobile-nav .nav-btn.is-active::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 1px;
    width: 14px;
    height: 2px;
    border-radius: 2px;
    background: var(--red);
    transform: translateX(-50%);
  }
  .mobile-nav .nav-badge {
    position: absolute;
    top: 2px;
    left: calc(50% + 8px);
    min-width: 14px;
    height: 14px;
    font-size: 8px;
    margin-left: 0;
  }
  .sidebar-backdrop { display: block; }
  .sidebar-close { display: grid; }
  .province-list { max-height: 220px; overflow-y: auto; }
  .mobile-prov-strip {
    display: flex;
    gap: 5px;
    overflow-x: auto;
    padding: 2px 0 9px;
    margin: 0 0 8px;
    border-bottom: 1px solid var(--line-soft);
    scrollbar-width: none;
  }
  .mobile-prov-strip::-webkit-scrollbar { display: none; }
  .mprov-chip {
    flex: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 9px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 253, 248, 0.82);
    font-size: 10.5px;
    color: var(--ink-2);
    white-space: nowrap;
  }
  .mprov-chip b { color: var(--red); font-size: 10px; font-weight: 700; }
  .mprov-chip.is-zero { opacity: 0.38; }
  .mprov-chip.is-active { background: var(--ink); border-color: var(--ink); color: #f9f4e9; }
  .mprov-chip.is-active b { color: #f9f4e9; }
  .prov-label-wrap { display: none !important; }
  .map-top { display: none; }
  .map-legend { display: none; }
  .trail-hero { grid-template-columns: 1fr; }
  .trail-actions { margin: 0 auto; justify-content: center; max-width: none; }
}
@media (min-width: 761px) {
  .sidebar-backdrop, .sidebar-close { display: none !important; }
}
@media (max-width: 980px) and (min-width: 761px) {
  .trail-hero { grid-template-columns: 170px minmax(0, 1fr); }
  .trail-actions { grid-column: 1 / -1; justify-content: flex-start; max-width: none; }
}
/* ---------- 补充：加载、空状态、页脚说明---------- */
.workspace { scroll-margin-top: 76px; }
.map-loading {
  position: absolute;
  inset: 0;
  z-index: 6;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 13px;
  background: #e9e1d1;
  color: var(--muted);
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 3px;
}
.map-loading span {
  width: 26px;
  height: 26px;
  border: 2px solid rgba(132, 123, 107, 0.2);
  border-top-color: var(--red);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
#map.map-none {
  background:
    radial-gradient(circle at 30% 20%, rgba(169, 133, 79, 0.08), transparent 45%),
    repeating-linear-gradient(0deg, transparent 0 39px, rgba(169, 133, 79, 0.05) 39px 40px),
    repeating-linear-gradient(90deg, transparent 0 39px, rgba(169, 133, 79, 0.05) 39px 40px),
    #efe7d8;
}
.cluster-wrap { background: none !important; border: 0 !important; }
#map.map-overview .leaflet-marker-pane .cluster-wrap,
#map.map-overview .leaflet-marker-pane .site-dot-wrap { display: none !important; }
#map.map-overview {
  background:
    radial-gradient(circle at 28% 18%, rgba(169, 133, 79, 0.08), transparent 46%),
    radial-gradient(circle at 78% 82%, rgba(166, 58, 43, 0.05), transparent 40%),
    #f3ebdc;
}
#map.map-overview .leaflet-tile-pane { opacity: 0; }
.leaflet-tile-pane { transition: opacity 0.35s ease; }
.site-dot-wrap { background: none !important; border: 0 !important; }
.site-dot {
  display: block;
  width: 12px;
  height: 12px;
  margin: 1px;
  border-radius: 50%;
  background: var(--c);
  border: 2px solid rgba(255, 252, 244, 0.95);
  box-shadow: 0 1px 6px rgba(40, 30, 15, 0.45);
  transition: transform 0.15s;
}
.site-dot.is-approx {
  width: 6px;
  height: 6px;
  margin: 4px;
  opacity: 0.7;
  border: 1px dashed rgba(70, 60, 40, 0.65);
  box-shadow: 0 0 0 1px rgba(255, 252, 244, 0.75);
}
.site-dot.is-visited {
  box-shadow: 0 0 0 2px #456b5e, 0 0 0 4px rgba(255, 252, 244, 0.9), 0 1px 6px rgba(40, 30, 15, 0.35);
}
.site-dot.is-wish {
  box-shadow: 0 0 0 2px #a9854f, 0 0 0 4px rgba(255, 252, 244, 0.9), 0 1px 6px rgba(40, 30, 15, 0.35);
}
.site-dot.is-selected {
  width: 17px;
  height: 17px;
  margin: -2.5px;
  background: #a63a2b;
  border-width: 2.5px;
  box-shadow: 0 0 0 3px rgba(166, 58, 43, 0.2), 0 0 0 1.5px #fff9ef, 0 2px 10px rgba(80, 30, 15, 0.45);
}
.site-label-wrap { background: none !important; border: 0 !important; }
.site-label {
  display: inline-block;
  padding: 3px 7px;
  background: rgba(252, 249, 243, 0.96);
  border: 1px solid rgba(166, 58, 43, 0.45);
  border-radius: 5px;
  color: var(--ink);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.3px;
  white-space: nowrap;
  box-shadow: 0 3px 10px rgba(40, 30, 15, 0.18);
  transform: translateY(-50%);
}
.leaflet-marker-icon.site-dot-wrap:hover .site-dot { transform: scale(1.35); }
.prov-bubble-wrap { background: none !important; border: 0 !important; }
.prov-label-wrap { background: none !important; border: 0 !important; }
.prov-label {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: rgba(252, 249, 243, 0.94);
  border: 1px solid rgba(166, 58, 43, 0.55);
  border-radius: 4px;
  color: var(--ink-2);
  box-shadow: 0 2px 7px rgba(90, 40, 25, 0.14);
  backdrop-filter: blur(2px);
  white-space: nowrap;
}
.prov-label b { color: var(--red); font-size: 10.5px; line-height: 1; font-weight: 700; letter-spacing: -0.2px; }
.prov-label span { font-size: 8.5px; line-height: 1; letter-spacing: 0.2px; }
.prov-label.is-lg { border-color: rgba(166, 58, 43, 0.72); }
.prov-label.is-lg b { font-size: 11px; }
.prov-label.is-xl { background: rgba(166, 58, 43, 0.93); border-color: rgba(255, 248, 238, 0.65); }
.prov-label.is-xl b { color: #fff8ee; font-size: 11px; }
.prov-label.is-xl span { color: rgba(255, 248, 238, 0.8); }
.prov-label:hover { background: #fff; }
.prov-bubble {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(252, 249, 243, 0.93);
  border: 1.5px solid rgba(166, 58, 43, 0.72);
  color: var(--red);
  box-shadow: 0 4px 14px rgba(90, 40, 25, 0.18);
  backdrop-filter: blur(2px);
}
.prov-bubble b { font-size: 11px; line-height: 1; font-weight: 700; letter-spacing: -0.3px; }
.prov-bubble span { font-size: 7.5px; color: var(--ink-2); margin-top: 2px; letter-spacing: 0.3px; }
.prov-bubble.lg b { font-size: 13px; }
.prov-bubble.xl { border-width: 2px; }
.prov-bubble.xl b { font-size: 15px; }
.prov-bubble:hover { background: #fff; }
.load-more {
  width: 100%;
  margin: 12px 0 4px;
  padding: 10px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.15s;
}
.load-more:hover { border-color: var(--gold); color: var(--red); background: rgba(255, 253, 248, 0.6); }
.load-more span { font-family: var(--mono); font-size: 9px; color: var(--faint); }
.muted { color: var(--muted); }
.small { font-size: 10.5px; }
.detail-visited-at {
  margin-top: 9px;
  font-size: 10px;
  color: var(--jade);
  letter-spacing: 1px;
  font-family: var(--mono);
}
.detail-desc { font-size: 12px; line-height: 1.9; color: var(--ink-2); margin: 0 0 8px; }
.detail-desc.batch-note { font-size: 11px; color: var(--muted); margin-bottom: 0; }
.note-saved { margin-top: 5px; text-align: right; font-size: 9.5px; color: var(--faint); letter-spacing: 0.5px; }
.data-note {
  margin-top: 26px;
  padding: 20px 24px;
  background: rgba(241, 233, 218, 0.45);
  border-left: 2px solid var(--gold);
  border-radius: 0 10px 10px 0;
}
.data-note strong { font-family: var(--serif); font-size: 15px; letter-spacing: 1px; }
.data-note p { margin: 7px 0 0; font-size: 11.5px; line-height: 1.9; color: var(--muted); }
.fatal {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px;
  text-align: center;
  background: var(--paper);
}
.fatal-seal {
  width: 66px;
  height: 66px;
  display: grid;
  place-items: center;
  background: var(--red);
  color: #fff6e8;
  border-radius: 10px;
  font-family: var(--serif);
  font-size: 24px;
  letter-spacing: 2px;
  transform: rotate(-4deg);
  margin-bottom: 20px;
}
.fatal h1 { font-family: var(--serif); font-size: 28px; letter-spacing: 2px; margin: 0 0 12px; }
.fatal p { max-width: 560px; font-size: 13px; line-height: 1.9; color: var(--ink-2); margin: 0 0 8px; }
.fatal code { font-family: var(--mono); font-size: 11px; background: var(--paper-2); padding: 2px 5px; border-radius: 3px; }
.fatal-err { font-family: var(--mono); font-size: 10.5px; color: var(--muted); word-break: break-all; }



/* ---------- AI 路线 ---------- */
.route-view { background: linear-gradient(180deg, var(--paper) 0%, #f3ebdc 100%); min-height: 100vh; }
.route-inner { max-width: 1280px; }
.route-head { margin-bottom: 22px; }
.route-head h2 { max-width: 760px; }
.route-layout { display: grid; grid-template-columns: minmax(360px, 0.92fr) minmax(0, 1.08fr); gap: 18px; align-items: start; }
.route-panel, .route-map-card, .route-result { border: 1px solid var(--line); background: rgba(255, 252, 245, 0.72); box-shadow: var(--shadow-sm); border-radius: 12px; }
.route-panel { padding: 18px; }
.route-tabs { display: flex; gap: 4px; padding: 4px; background: var(--paper-2); border-radius: 9px; margin-bottom: 16px; }
.route-tabs button { flex: 1; padding: 9px 8px; border-radius: 7px; color: var(--ink-3); font-size: 12px; letter-spacing: 1px; }
.route-tabs button.is-active { background: var(--paper); color: var(--red); box-shadow: 0 2px 8px rgba(70, 50, 25, 0.06); font-weight: 700; }
.route-mode-panel { margin-bottom: 16px; }
.route-panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.route-panel-head strong { display: block; font-size: 13px; color: var(--ink); letter-spacing: 0.5px; }
.route-panel-head span { font-size: 11px; color: var(--faint); }
.route-mini-link { color: var(--gold); font-size: 11px; white-space: nowrap; }
.route-mini-link:hover { color: var(--red); }
.route-wish-list { display: flex; flex-direction: column; gap: 4px; max-height: 190px; overflow-y: auto; }
.route-wish-item { display: flex; align-items: center; gap: 8px; padding: 7px 8px; border: 1px solid var(--line-soft); background: rgba(255, 253, 248, 0.7); border-radius: 7px; text-align: left; }
.route-wish-item .idx { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: var(--red-soft); color: var(--red); font-size: 9px; font-weight: 700; flex: none; }
.route-wish-item .nm { min-width: 0; flex: 1; font-size: 12px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.route-wish-item .loc { font-size: 10px; color: var(--faint); flex: none; max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.route-wish-item .rm { color: var(--faint); flex: none; width: 20px; height: 20px; display: grid; place-items: center; }
.route-wish-item .rm:hover { color: var(--red); }
.route-empty { padding: 16px 12px; color: var(--faint); font-size: 11px; line-height: 1.8; border: 1px dashed var(--line); border-radius: 8px; background: rgba(241, 233, 218, 0.35); }
.route-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.route-label { font-size: 11px; color: var(--ink-3); letter-spacing: 0.8px; }
.route-label small { color: var(--faint); font-size: 10px; letter-spacing: 0; }
.route-input { width: 100%; height: 36px; padding: 0 10px; border: 1px solid var(--line); border-radius: 7px; background: var(--paper); color: var(--ink); font: inherit; font-size: 12px; }
.route-input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(169, 133, 79, 0.12); }
.route-origin-row { display: flex; gap: 6px; }
.route-origin-row .route-input { flex: 1; }
.route-locate { width: 36px; height: 36px; flex: none; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 7px; color: var(--ink-3); background: var(--paper); }
.route-locate:hover { color: var(--red); border-color: var(--gold); }
.route-locate.is-loading { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.route-locate svg { width: 15px; height: 15px; }
.route-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.route-seg { display: flex; padding: 3px; background: var(--paper-2); border-radius: 7px; gap: 2px; }
.route-seg button { flex: 1; padding: 7px 5px; border-radius: 5px; color: var(--ink-3); font-size: 11px; }
.route-seg button.is-active { background: var(--paper); color: var(--red); font-weight: 700; box-shadow: 0 1px 4px rgba(70, 50, 25, 0.08); }
.route-cat-chips .chip { font-size: 10px; padding: 5px 7px; }
.route-check { display: flex; align-items: center; gap: 7px; color: var(--ink-3); font-size: 11px; margin: 2px 0 0; }
.route-check input { accent-color: var(--red); }
.route-region-box { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 10px; border: 1px dashed var(--line); border-radius: 7px; background: rgba(241, 233, 218, 0.35); }
.route-region-box strong { display: block; font-size: 11px; color: var(--ink-2); }
.route-region-box span { font-size: 10px; color: var(--faint); }
.route-region-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 5px; flex: none; }
.route-hint { margin-top: 7px; color: var(--faint); font-size: 10px; line-height: 1.7; }
.route-btn { display: inline-flex; align-items: center; justify-content: center; gap: 5px; height: 32px; padding: 0 10px; border-radius: 6px; background: var(--ink); color: var(--paper); font-size: 11px; }
.route-btn:hover { background: var(--red); }
.route-btn.ghost { background: transparent; border: 1px solid var(--line); color: var(--ink-3); }
.route-btn.ghost:hover { border-color: var(--red); color: var(--red); }
.route-btn.small { height: 28px; padding: 0 8px; font-size: 10px; }
.route-actions { display: flex; align-items: center; gap: 10px; padding-top: 4px; border-top: 1px solid var(--line-soft); margin-top: 4px; padding-top: 15px; }
.route-generate { height: 40px; padding: 0 18px; display: inline-flex; align-items: center; gap: 7px; border-radius: 7px; background: var(--red); color: #fff9ee; font-size: 13px; letter-spacing: 1px; box-shadow: 0 8px 18px rgba(166, 58, 43, 0.18); }
.route-generate:hover { background: #8f2f23; }
.route-generate svg { width: 15px; height: 15px; }
.route-status { color: var(--faint); font-size: 10px; line-height: 1.6; }
.route-status.is-error { color: var(--red); }
.route-load { margin-left: auto; color: var(--gold); font-size: 10px; border-bottom: 1px dotted rgba(169, 133, 79, 0.45); white-space: nowrap; }

.route-map-card { overflow: hidden; }
.route-map-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px 10px; }
.route-map-head strong { font-size: 12px; color: var(--ink); letter-spacing: 0.8px; }
.route-map-head span { margin-left: 6px; font-size: 10px; color: var(--faint); }
.route-map-legend { display: inline-flex; align-items: center; gap: 5px; color: var(--faint); font-size: 10px; }
.route-map-legend i { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 2px rgba(169, 133, 79, 0.14); }
.route-map { height: 470px; background: #e9e4d8; }
.route-map-tools { display: flex; align-items: center; gap: 6px; padding: 10px 12px 6px; flex-wrap: wrap; }
.route-map-btn { height: 28px; padding: 0 9px; border-radius: 5px; border: 1px solid var(--line); background: var(--paper); color: var(--ink-3); font-size: 10px; }
.route-map-btn:hover { border-color: var(--gold); color: var(--red); }
.route-map-btn.ghost { background: transparent; }
.route-map-btn.is-active { background: var(--red); border-color: var(--red); color: #fff9ee; }
.route-map-tools span { margin-left: auto; color: var(--faint); font-size: 10px; }
.route-map-hint { padding: 0 12px 12px; color: var(--faint); font-size: 10px; line-height: 1.6; }
.route-map.leaflet-container { font: inherit; }
.route-map .leaflet-control-zoom a { color: var(--ink-3); }

.route-result { margin-top: 20px; padding: 0; overflow: hidden; }
.route-result-empty { padding: 48px 24px; text-align: center; }
.route-result-mark { width: 46px; height: 46px; margin: 0 auto 12px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); color: var(--red); font-family: var(--serif); font-size: 22px; }
.route-result-empty h3 { font-family: var(--serif); font-size: 20px; color: var(--ink); margin-bottom: 6px; }
.route-result-empty p { color: var(--faint); font-size: 12px; line-height: 1.8; max-width: 440px; margin: 0 auto; }
.route-summary { padding: 18px 20px; border-bottom: 1px solid var(--line-soft); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: center; background: rgba(241, 233, 218, 0.35); }
.route-summary h3 { font-family: var(--serif); font-size: 22px; color: var(--ink); letter-spacing: 0.5px; margin: 2px 0 4px; }
.route-summary p { color: var(--ink-3); font-size: 11px; line-height: 1.7; }
.route-summary-stats { display: flex; gap: 18px; flex-wrap: wrap; }
.route-summary-stats div { min-width: 58px; }
.route-summary-stats strong { display: block; font-family: var(--serif); font-size: 20px; color: var(--red); }
.route-summary-stats span { font-size: 9px; color: var(--faint); letter-spacing: 0.5px; }
.route-summary-side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
@media (max-width: 760px) { .route-summary-side { align-items: flex-start; } }
.route-summary-actions { display: flex; gap: 5px; flex-wrap: wrap; justify-content: flex-end; }
.route-summary-btn { height: 30px; padding: 0 9px; border: 1px solid var(--line); border-radius: 5px; background: var(--paper); color: var(--ink-3); font-size: 10px; display: inline-flex; align-items: center; gap: 4px; }
.route-summary-btn:hover { border-color: var(--gold); color: var(--red); }
.route-summary-btn svg { width: 12px; height: 12px; }
.route-days { padding: 8px 20px 22px; }
.route-day { border-top: 1px solid var(--line-soft); padding: 18px 0; }
.route-day:first-child { border-top: 0; }
.route-day-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 10px; }
.route-day-num { font-family: var(--serif); color: var(--red); font-size: 15px; letter-spacing: 1px; }
.route-day-head h4 { font-family: var(--serif); font-size: 19px; color: var(--ink); }
.route-day-head span { color: var(--faint); font-size: 10px; margin-left: auto; }
.route-timeline { position: relative; padding-left: 19px; }
.route-timeline::before { content: ""; position: absolute; left: 5px; top: 4px; bottom: 4px; border-left: 1px dashed var(--line); }
.route-leg { position: relative; display: flex; gap: 9px; padding: 5px 0; color: var(--ink-3); font-size: 11px; line-height: 1.7; }
.route-leg::before { content: ""; position: absolute; left: -17px; top: 11px; width: 5px; height: 5px; border-radius: 50%; background: var(--paper); border: 1px solid var(--gold); }
.route-leg-icon { flex: none; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: var(--paper-2); color: var(--gold); margin-top: 1px; }
.route-leg-icon svg { width: 11px; height: 11px; }
.route-leg .time { flex: none; width: 38px; color: var(--faint); font-size: 10px; }
.route-leg .body { min-width: 0; }
.route-leg .body b { font-weight: 600; color: var(--ink-2); }
.route-leg .meta { color: var(--faint); font-size: 10px; }
.route-leg.is-lunch { color: var(--faint); font-style: italic; }
.route-site { position: relative; display: flex; gap: 10px; padding: 8px 0 10px; }
.route-site::before { content: ""; position: absolute; left: -18px; top: 14px; width: 9px; height: 9px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 3px var(--red-soft); }
.route-site .num { flex: none; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: var(--red); color: #fff9ee; font-size: 9px; margin-top: 1px; }
.route-site .info { min-width: 0; flex: 1; }
.route-site .nm { display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap; }
.route-site .nm a { font-family: var(--serif); font-size: 16px; color: var(--ink); border-bottom: 1px dotted transparent; }
.route-site .nm a:hover { color: var(--red); border-color: var(--red); }
.route-site .tag { font-size: 9px; color: var(--gold); border: 1px solid rgba(169, 133, 79, 0.3); border-radius: 3px; padding: 1px 4px; }
.route-site .where { color: var(--faint); font-size: 10px; margin-top: 2px; line-height: 1.6; }
.route-site .when { color: var(--ink-3); font-size: 10px; margin-top: 2px; }
.route-day-note { margin-top: 8px; padding: 8px 10px; border-radius: 6px; background: rgba(241, 233, 218, 0.45); color: var(--faint); font-size: 10px; line-height: 1.7; }
.route-query-wrap { margin-top: 3px; }
.route-query { display: inline-flex; align-items: center; gap: 3px; color: var(--gold); font-size: 10px; border-bottom: 1px dotted rgba(169, 133, 79, 0.45); }
.route-query:hover { color: var(--red); }
.route-query svg { width: 10px; height: 10px; }
.route-leg-nav, .route-site-nav { display: flex; align-items: center; flex-wrap: wrap; gap: 5px; margin-top: 4px; color: var(--faint); font-size: 10px; line-height: 1.6; }
.route-leg-nav b, .route-site-nav b { color: var(--ink-2); font-weight: 600; }
.route-nav-addr, .route-site-addr { width: 100%; color: var(--faint); font-size: 9px; line-height: 1.6; }
.route-copy { color: var(--gold); font-size: 10px; border-bottom: 1px dotted rgba(169, 133, 79, 0.45); }
.route-copy:hover { color: var(--red); }
.route-leg-nav a, .route-site-nav a { color: var(--gold); display: inline-flex; align-items: center; gap: 2px; }
.route-leg-nav a svg, .route-site-nav a svg { width: 10px; height: 10px; }
.route-edit-hint { margin-top: 6px; color: var(--gold); font-size: 10px; line-height: 1.7; }
.route-edit { display: flex; gap: 2px; flex: none; margin-left: 4px; }
.route-edit button { width: 22px; height: 22px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 4px; color: var(--ink-3); background: var(--paper); font-size: 11px; }
.route-edit button:hover:not(:disabled) { color: var(--red); border-color: var(--gold); }
.route-edit button:disabled { opacity: 0.25; cursor: default; }
.route-add-row { margin-top: 8px; padding-left: 28px; }
.route-add-row select { width: 100%; max-width: 320px; height: 30px; padding: 0 8px; border: 1px dashed var(--line); border-radius: 5px; background: rgba(241, 233, 218, 0.35); color: var(--ink-3); font-size: 10px; }
.route-add-row select:focus { outline: none; border-color: var(--gold); }
.route-disclaimer { margin-top: 14px; padding: 12px 14px; border-top: 1px solid var(--line-soft); color: var(--faint); font-size: 10px; line-height: 1.8; }
.route-stop-icon { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--red); color: #fff9ee; border: 2px solid #fff8ec; box-shadow: 0 2px 8px rgba(70, 50, 25, 0.25); font-size: 10px; font-weight: 700; }
.route-stop-icon.is-start { background: var(--gold); }
.route-map .route-rect { cursor: crosshair; }

@media (max-width: 980px) {
  .route-layout { grid-template-columns: 1fr; }
  .route-map { height: 380px; }
}
@media (max-width: 760px) {
  .route-view { padding-bottom: 30px; }
  .route-head h2 { font-size: 30px; }
  .route-panel { padding: 14px; }
  .route-layout { gap: 12px; }
  .route-map { height: 300px; }
  .route-map-tools span { margin-left: 0; width: 100%; order: 3; }
  .route-summary { grid-template-columns: 1fr; padding: 15px 14px; }
  .route-summary-actions { justify-content: flex-start; }
  .route-days { padding: 4px 14px 18px; }
  .route-summary-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; width: 100%; }
  .route-summary-stats strong { font-size: 18px; }
  .route-summary-stats span { font-size: 8px; }
  .route-day-head h4 { font-size: 17px; }
  .route-site .nm a { font-size: 15px; }
  .route-grid-2 { grid-template-columns: 1fr; gap: 0; }
}
@media print {
  .topbar, .mobile-nav, .route-panel, .route-map-card, .route-summary-actions, .back-top { display: none !important; }
  .route-view { background: #fff; }
  .route-result { box-shadow: none; border: 0; }
  .route-day { break-inside: avoid; }
}
