/* 中国过山车地图 · 全站样式 */
/* 设计语言：「黄昏钢轨 Twilight Steel」——落日橙（兴奋／坠落）× 钢蓝灰（机械／冷）。
   过山车的情感是矛盾的复合体：控制下的危险、失重、欢愉的尖叫、钢铁与童年。
   所以配色必须有冷暖对抗：暖的兴奋，冷的机械。
   主题机制：所有跟主题相关的颜色走 CSS 变量。
   深色 = :root 默认（「夜行钢轨 Night Rail」：夜幕游乐园，车厢灯橙 × 冷钢蓝，暗场发光）；
   浅色 = html[data-theme="light"] 覆盖（「黄昏钢轨」：落日游乐园，米色纸张 + 陶土橙）。
   切换按钮脚本内联在每页底部（build.py 的 THEME_TOGGLE），防闪错主题脚本在 <head> 内。 */

:root {
  /* ---------- 夜行钢轨 Night Rail ---------- */
  --bg: #14161d;
  --bg-card: #1b1e28;
  --bg-card-2: #171a23;
  --border: #333849;
  --border-light: #2a2f3e;
  --text: #f0ece4;
  --text-strong: #ffffff;
  --muted: #a8a3b4;
  --faint: #6f6b80;
  --nav-fg: #b3aebe;
  --link: #7fa8d0;
  --link-hover: #ff8a4c;
  --accent: #ff8a4c;
  --accent-2: #d94f6a;
  --grad: linear-gradient(135deg, #ff8a4c, #d94f6a);
  --topbar-bg: rgba(20, 22, 29, 0.92);
  --bg-decor: radial-gradient(1200px 420px at 18% -80px, rgba(255, 138, 76, 0.07), transparent 70%),
              radial-gradient(900px 380px at 85% -60px, rgba(74, 107, 138, 0.10), transparent 70%);
  --card-grad: linear-gradient(180deg, #1e2129, var(--bg-card-2));
  --th-bg: #262b3a;
  --th-fg: #d8d3e0;
  --row-alt: rgba(255, 255, 255, 0.018);
  --row-hover: rgba(255, 138, 76, 0.08);
  --shadow-card: 0 8px 30px rgba(0, 0, 0, 0.5);
  --shadow-hover: 0 6px 22px rgba(0, 0, 0, 0.5);
  --overlay-bg: rgba(27, 30, 40, 0.94);
  --overlay-border: #3d4356;
  --overlay-title: #ffffff;
  --overlay-sub: #a8a3b4;
  --overlay-accent: #ffb98a;
  --logo-glow: rgba(255, 138, 76, 0.4);

  /* 地图 / 数据可视化专用（与原型 final-map.html 严格一致） */
  --map-land: #1b1e28;
  --map-land-hover: #242836;
  --map-land-on: #2e3345;
  --map-rule: #333849;
  --map-prov-line: #3d4356;
  --map-prov-hi: #ff8a4c;
  --map-label: #6f6b80;
  --lv0: #4a6b8a;
  --lv1: #f0b357;
  --lv2: #ff8a4c;
  --lv3: #d94f6a;
  --map-vignette: rgba(0, 0, 0, 0.5);
}

/* 「黄昏钢轨」浅色主题：落日游乐园，米色纸张 + 陶土橙 */
html[data-theme="light"] {
  --bg: #f6f1e6;
  --bg-card: #fffcf5;
  --bg-card-2: #f9f4e9;
  --border: #ddcfb4;
  --border-light: #e8ddc8;
  --text: #2f2820;
  --text-strong: #221b15;
  --muted: #6a5f50;
  --faint: #9c8f7c;
  --nav-fg: #5c5245;
  --link: #a8452c;
  --link-hover: #c2492e;
  --accent: #c2492e;
  --accent-2: #7a2136;
  --grad: linear-gradient(135deg, #e0a458, #c2492e);
  --topbar-bg: rgba(250, 246, 238, 0.94);
  --bg-decor: radial-gradient(1200px 420px at 18% -80px, rgba(224, 164, 88, 0.10), transparent 70%),
              radial-gradient(900px 380px at 85% -60px, rgba(159, 179, 192, 0.12), transparent 70%);
  --card-grad: linear-gradient(180deg, #fffdf8, #f7f1e4);
  --th-bg: #efe6d4;
  --th-fg: #5a4b38;
  --row-alt: rgba(120, 95, 60, 0.035);
  --row-hover: rgba(194, 73, 46, 0.06);
  --shadow-card: 0 8px 26px rgba(90, 70, 45, 0.13);
  --shadow-hover: 0 6px 18px rgba(90, 70, 45, 0.16);
  --overlay-bg: rgba(255, 252, 245, 0.95);
  --overlay-border: #ddcfb4;
  --overlay-title: #221b15;
  --overlay-sub: #6a5f50;
  --overlay-accent: #c2492e;
  --logo-glow: rgba(194, 73, 46, 0.22);

  /* 地图 */
  --map-land: #fffcf5;
  --map-land-hover: #f5eddd;
  --map-land-on: #e8dcc6;
  --map-rule: #cbbfa8;
  --map-prov-line: #b3a58c;
  --map-prov-hi: #c2492e;
  --map-label: #9c8f7c;
  --lv0: #9fb3c0;
  --lv1: #e0a458;
  --lv2: #c2492e;
  --lv3: #7a2136;
  --map-vignette: rgba(150, 130, 100, 0.09);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 15px;
  line-height: 1.65;
  color: var(--text);
  background-color: var(--bg);
  background-image: var(--bg-decor);
  background-repeat: no-repeat;
  transition: background-color 0.35s ease, color 0.35s ease;
}
a { color: var(--link); text-decoration: none; transition: color 0.15s; }
a:hover { color: var(--link-hover); text-decoration: none; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 18px; }

/* 顶栏 */
.topbar { border-bottom: 1px solid var(--border-light); background: var(--topbar-bg); backdrop-filter: blur(8px); position: sticky; top: 0; z-index: 60; }
.topbar::after { content: ""; display: block; height: 2px; background: linear-gradient(90deg, var(--accent), var(--accent-2) 30%, transparent 75%); }
.site-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 4px; padding: 10px 0 8px; }
.site-title { font-size: 19px; font-weight: 800; color: var(--text-strong); letter-spacing: 0.5px; display: inline-flex; align-items: center; }
.site-title::before { content: ""; width: 10px; height: 18px; background: var(--grad); margin-right: 9px; transform: skewX(-14deg); border-radius: 2px; box-shadow: 0 0 12px var(--logo-glow); }
.site-title:hover { color: var(--text-strong); text-decoration: none; }
nav a { margin-left: 18px; font-size: 14px; color: var(--nav-fg); }
nav a:hover { color: var(--text-strong); }

main { padding: 26px 0 56px; }
/* 地图页：真·全屏——去掉 main 内外边距，让地图铺满顶栏以下全部空间
   （否则地图向下溢出视口，悬浮按钮会与右下角浮层打架） */
main.map-main { padding: 0; }

h1 { font-size: 24px; margin: 0 0 16px; font-weight: 800; letter-spacing: 0.4px; color: var(--text-strong); }
h1 .sub { font-size: 14px; color: var(--faint); font-weight: 400; margin-left: 10px; letter-spacing: 0; }
h2 { font-size: 17px; margin: 34px 0 12px; padding-bottom: 8px; border-bottom: 1px solid var(--border-light); color: var(--text-strong); display: flex; align-items: center; }
h2::before { content: ""; width: 5px; height: 15px; background: var(--grad); margin-right: 9px; transform: skewX(-14deg); border-radius: 1px; }
p.lead { color: var(--muted); }

/* 面包屑 */
.breadcrumb { font-size: 13px; color: var(--faint); margin-bottom: 12px; }
.breadcrumb a { color: var(--faint); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb .sep { margin: 0 7px; opacity: 0.6; }

/* 统计卡片 */
.stat-cards { display: flex; flex-wrap: wrap; gap: 12px; margin: 18px 0 10px; }
.stat-card { border: 1px solid var(--border); border-radius: 10px; padding: 12px 22px; min-width: 140px; background: var(--card-grad); }
.stat-card .num { font-size: 28px; font-weight: 800; line-height: 1.2; background: linear-gradient(135deg, #ffb36b, var(--accent)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat-card .lbl { font-size: 13px; color: var(--muted); }

/* 表格 */
table.data { border-collapse: collapse; width: 100%; margin: 12px 0 20px; font-size: 14px; }
table.data th { background: var(--th-bg); color: var(--th-fg); border: 1px solid var(--border); text-align: left; padding: 7px 10px; font-weight: 600; white-space: nowrap; }
table.data td { border: 1px solid var(--border); padding: 6px 10px; }
table.data tr:nth-child(even) td { background: var(--row-alt); }
table.data tr:hover td { background: var(--row-hover); }
.table-scroll { overflow-x: auto; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* 标签（暖色系：与陶土／落日橙主调协调） */
.tag { display: inline-block; padding: 0 7px; border-radius: 4px; font-size: 12px; line-height: 19px; white-space: nowrap; }
.tag-op { background: rgba(94, 168, 122, 0.18); color: #7fc79a; }
.tag-so { background: rgba(240, 179, 87, 0.18); color: #f0b357; }
.tag-de { background: rgba(148, 143, 160, 0.18); color: #a8a3b4; }
.t-extreme { background: rgba(217, 79, 106, 0.20); color: #ec7f95; }
.t-thrill { background: rgba(255, 138, 76, 0.20); color: #ffab7d; }
.t-family { background: rgba(122, 168, 208, 0.20); color: #9dc4e6; }
.t-kids { background: rgba(126, 199, 154, 0.18); color: #8fd6ab; }
/* 浅色主题下标签提高对比度（暖色纸张上，浅色字不可读） */
html[data-theme="light"] .tag-op { background: rgba(34, 140, 80, 0.13); color: #1d6b45; }
html[data-theme="light"] .tag-so { background: rgba(196, 138, 40, 0.16); color: #8a5a12; }
html[data-theme="light"] .tag-de { background: rgba(110, 104, 96, 0.12); color: #6a5f50; }
html[data-theme="light"] .t-extreme { background: rgba(160, 44, 62, 0.13); color: #96233a; }
html[data-theme="light"] .t-thrill { background: rgba(194, 73, 46, 0.13); color: #9d3a24; }
html[data-theme="light"] .t-family { background: rgba(58, 110, 158, 0.13); color: #2a5d8f; }
html[data-theme="light"] .t-kids { background: rgba(34, 130, 78, 0.13); color: #1d6b45; }

/* 参数表（详情页 / 乐园页） */
table.param { border-collapse: collapse; width: 100%; max-width: 760px; font-size: 14px; margin: 14px 0; }
table.param td { border: 1px solid var(--border); padding: 8px 12px; vertical-align: top; }
table.param td.k { background: var(--bg-card); width: 150px; color: var(--muted); white-space: nowrap; }
p.param-note { font-size: 13px; color: var(--muted); margin: -6px 0 14px; }
p.param-note a { color: var(--accent, var(--muted)); }
p.section-note { font-size: 13px; color: var(--muted); margin: -6px 0 12px; }
span.rank-flag { color: var(--accent, #ff8a3d); font-weight: 600; margin-left: 3px; cursor: help; }
p.rank-note { font-size: 13px; color: var(--muted); margin: -4px 0 18px; }

/* 朴素项目符号列表（404 页等说明性页面用） */
ul.plain-list { margin: 0 0 18px; padding-left: 22px; }
ul.plain-list li { margin: 6px 0; }
ul.plain-list a { color: var(--accent, #ff8a3d); }

/* 纠错反馈按钮（详情页：复制资料 + 跳转问卷） */
.fb-row { margin: 20px 0 4px; display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.fb-btn {
  font: inherit; font-size: 13px; font-weight: 600; color: #fff;
  padding: 7px 16px; border: none; border-radius: 6px; cursor: pointer;
  background: var(--grad);
  box-shadow: 0 2px 10px var(--logo-glow);
  transition: filter 0.15s, transform 0.1s;
}
.fb-btn:hover { filter: brightness(1.12); }
.fb-btn:active { transform: translateY(1px); }
.fb-hint { font-size: 12px; color: var(--faint); }

/* 省份卡片（首页 / 省份索引） */
.province-cards { display: flex; flex-wrap: wrap; gap: 12px; margin: 12px 0; }
.province-card { position: relative; border: 1px solid var(--border); border-radius: 10px; padding: 16px 20px 16px 26px; display: block; color: inherit; min-width: 230px; background: var(--card-grad); transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s; overflow: hidden; }
.province-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--grad); }
.province-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow-hover); text-decoration: none; }
.province-card .pname { font-size: 17px; font-weight: 700; color: var(--text-strong); }
.province-card .pmeta { font-size: 13px; color: var(--muted); margin-top: 3px; }
.more-link { font-size: 13px; margin: 4px 0 0; }

/* 详情页前后导航 */
.prevnext { display: flex; justify-content: space-between; margin-top: 26px; font-size: 14px; flex-wrap: wrap; gap: 8px; }

/* 首页地图 hero */
.map-hero { position: relative; width: 100%; height: 68vh; min-height: 430px; border-bottom: 1px solid var(--border-light); background: var(--map-land); }
#home-map { width: 100%; height: 100%; display: block; background: var(--map-land); cursor: grab; }
#home-map.dragging, #full-map.dragging { cursor: grabbing; }
.map-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 56%, var(--map-vignette) 100%); }
/* 地图覆盖卡片：两张卡统一堆在右下角。左上/右上/左下让给腾讯地图自带控件与版权条，
   本站覆盖层只占右下角一个位置，避免互相遮挡；悬浮主题按钮固定在右下角，
   因此地图场景下 mo-stack 上移让位（按钮在最下，形成"图例→标题卡→按钮"竖列） */
.mo-stack { position: absolute; right: 16px; bottom: 16px; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; max-width: min(390px, calc(100% - 32px)); pointer-events: none; }
.mo-stack > * { pointer-events: auto; }
/* 地图页右下的浮层需要为悬浮按钮让位（按钮固定在视口右下角）；首页 hero 不会碰到按钮，保持原样 */
.full-map-wrap .mo-stack { bottom: 74px; }
.map-overlay { background: var(--overlay-bg); border: 1px solid var(--overlay-border); border-radius: 10px; padding: 12px 18px; max-width: 100%; box-shadow: var(--shadow-card); backdrop-filter: blur(6px); }
.map-overlay .mo-title { font-size: 17px; font-weight: 800; margin: 0; color: var(--overlay-title); }
.map-overlay .mo-sub { font-size: 13px; color: var(--overlay-sub); margin-top: 3px; }
.map-overlay .mo-sub b { color: var(--overlay-accent); }
.mo-legend { background: var(--overlay-bg); border: 1px solid var(--overlay-border); border-radius: 10px; padding: 8px 14px; font-size: 12px; color: var(--muted); box-shadow: var(--shadow-card); backdrop-filter: blur(6px); }
.mo-legend span { margin-right: 12px; white-space: nowrap; }
.mo-legend span:last-child { margin-right: 0; }
.mo-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; vertical-align: -1px; }
.mo-legend i.lg0 { background: var(--lv0); }
.mo-legend i.lg1 { background: var(--lv1); }
.mo-legend i.lg2 { background: var(--lv2); }
.mo-legend i.lg3 { background: var(--lv3); }
.home-body { padding-top: 8px; }

/* 页面配图（乐园 / 过山车） */
.page-photo { width: 100%; max-width: 960px; border-radius: 12px; border: 1px solid var(--border); display: block; margin: 2px 0 18px; }
.iw-photo { width: 100%; height: 96px; object-fit: cover; border-radius: 6px; margin-bottom: 8px; display: block; }

/* 独立地图页（高度用 JS 测得的顶栏真实高度计算，窄屏折行也精确铺满；无 JS 时回退 54px） */
.full-map-wrap { position: relative; height: calc(100vh - var(--topbar-h, 54px)); min-height: 420px; background: var(--map-land); }
#full-map { width: 100%; height: 100%; display: block; background: var(--map-land); cursor: grab; }
.full-map-wrap::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 56%, var(--map-vignette) 100%); }

/* ===== 纯矢量地图（2026-10-21 起，替代腾讯地图） ===== */
.prov { fill: var(--map-land); stroke: var(--map-prov-line); stroke-width: 0.9;
  vector-effect: non-scaling-stroke; transition: fill 0.26s ease, stroke 0.26s ease; }
.prov:hover { fill: var(--map-land-hover); }
.prov.on { fill: var(--map-land-on); stroke: var(--map-prov-hi); stroke-width: 2; }

.prov-label { fill: var(--map-label); font-size: 11px; pointer-events: none;
  text-anchor: middle; dominant-baseline: central; letter-spacing: 0.06em; }

.mk { cursor: pointer; }
.mk circle { transition: fill-opacity 0.16s ease; }
.mk:hover circle { fill-opacity: 1; }
.mk.on circle { stroke: var(--text-strong); }
/* 圆点半径与描边宽度由 JS 按缩放动态设置（见 updateMarkerScale），
   因此这里不写死 stroke-width，避免覆盖脚本计算值。 */
.mk .lv0 { fill: var(--lv0); } .mk .lv1 { fill: var(--lv1); }
.mk .lv2 { fill: var(--lv2); } .mk .lv3 { fill: var(--lv3); }
html:not([data-theme="light"]) .mk .lv2 { filter: drop-shadow(0 0 5px rgba(255, 138, 76, 0.7)); }
html:not([data-theme="light"]) .mk .lv3 { filter: drop-shadow(0 0 7px rgba(217, 79, 106, 0.8)); }

#vmap-tip { position: absolute; pointer-events: none; z-index: 12; opacity: 0;
  transition: opacity 0.14s; transform: translate(-50%, -152%);
  background: var(--text-strong); color: var(--bg); padding: 8px 13px;
  font-size: 12.5px; line-height: 1.5; white-space: nowrap;
  border-radius: 6px; box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3); }
#vmap-tip b { font-weight: 700; }
#vmap-tip .c { display: block; opacity: 0.72; font-size: 10.5px;
  letter-spacing: 0.08em; margin-top: 2px; }

.vmap-card { position: absolute; z-index: 11; width: 250px;
  background: var(--overlay-bg); border: 1px solid var(--overlay-border);
  border-radius: 10px; padding: 11px 13px; font-size: 13px; line-height: 1.55;
  box-shadow: var(--shadow-card); backdrop-filter: blur(8px);
  white-space: normal; overflow-wrap: anywhere; }
.vmap-card .iw-name { font-weight: 700; font-size: 15px; color: var(--overlay-title); }
.vmap-card .iw-meta { color: var(--overlay-sub); font-size: 12px; margin-top: 1px; }
.vmap-card .iw-cars { margin-top: 6px; padding-top: 6px;
  border-top: 1px solid var(--border-light); max-height: 190px; overflow-y: auto; }
.vmap-card .iw-car { display: block; padding: 2px 0; color: var(--link); text-decoration: none; }
.vmap-card .iw-car:hover { text-decoration: underline; }
.vmap-card .iw-st { color: var(--faint); font-size: 11px; }
.vmap-card .iw-park { display: inline-block; margin-top: 8px; font-weight: 600;
  color: var(--accent); text-decoration: none; }
.vmap-card .iw-park:hover { text-decoration: underline; }
.vmap-card .iw-photo { width: 100%; height: 96px; object-fit: cover;
  border-radius: 6px; margin-bottom: 8px; display: block; }

.vmap-tools { position: absolute; left: 16px; top: 16px; z-index: 11; display: flex; }
.vmap-tools button { font: inherit; font-size: 12px; letter-spacing: 0.1em;
  color: var(--overlay-sub); background: var(--overlay-bg);
  border: 1px solid var(--overlay-border); border-right: none;
  padding: 6px 14px; cursor: pointer; backdrop-filter: blur(6px);
  transition: background 0.16s, color 0.16s; }
.vmap-tools button:last-child { border-right: 1px solid var(--overlay-border); }
.vmap-tools button:hover { color: var(--accent); }
.vmap-tools button.on { background: var(--accent); color: #fff; border-color: var(--accent); }

/* 省界加载失败提示（多为 file:// 直接打开所致） */
.vmap-notice { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%);
  z-index: 13; max-width: min(560px, calc(100% - 40px));
  background: var(--overlay-bg); border: 1px solid var(--overlay-border);
  border-left: 3px solid var(--accent);
  border-radius: 8px; padding: 11px 16px; font-size: 12.5px; line-height: 1.6;
  color: var(--overlay-sub); box-shadow: var(--shadow-card); backdrop-filter: blur(8px); }

/* 地图信息窗（保持浅色系，与浅色底图协调；两主题下均不变） */
.iw-card { padding: 10px 12px; font-size: 13px; line-height: 1.55; width: 226px; background: #fff; color: #1a2233; white-space: normal; overflow-wrap: anywhere; }
.iw-name { font-weight: 700; font-size: 15px; color: #111; }
.iw-meta { color: #777; font-size: 12px; margin-top: 1px; }
.iw-cars { margin-top: 6px; padding-top: 6px; border-top: 1px solid #eee; max-height: 200px; overflow-y: auto; }
.iw-car { display: block; padding: 2px 0; color: #2a6db4; text-decoration: none; }
.iw-car:hover { text-decoration: underline; }
.iw-st { color: #999; font-size: 11px; }
.iw-park { display: inline-block; margin-top: 8px; font-weight: 600; color: #2a6db4; text-decoration: none; }
.iw-park:hover { text-decoration: underline; }
.iw-pop { animation: iwPop 0.26s ease-out; }
@keyframes iwPop {
  from { transform: scale(0.85); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* 白天/黑夜主题切换按钮（全站常驻：右下角透明悬浮圆钮；图标＝点击后切换到的目标） */
.theme-toggle {
  position: fixed; right: 16px; bottom: 16px; z-index: 80;
  width: 42px; height: 42px; padding: 0;
  border-radius: 50%; border: 1px solid var(--border);
  background: var(--overlay-bg); color: var(--muted);
  backdrop-filter: blur(6px); box-shadow: var(--shadow-card);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: color 0.15s, border-color 0.15s, transform 0.1s;
}
.theme-toggle:hover { color: var(--accent); border-color: var(--accent); }
.theme-toggle:active { transform: scale(0.94); }
.theme-toggle svg { width: 20px; height: 20px; display: block; }
.theme-toggle .icon-moon { display: none; }
html[data-theme="light"] .theme-toggle .icon-sun { display: none; }
html[data-theme="light"] .theme-toggle .icon-moon { display: block; }

/* 列表页工具栏（搜索 + 筛选） */
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 14px 0; }
.toolbar input[type="search"], .toolbar select { font: inherit; font-size: 14px; padding: 6px 11px; border: 1px solid var(--border); border-radius: 7px; background: var(--bg-card); color: var(--text); }
.toolbar input[type="search"]::placeholder { color: var(--faint); }
.toolbar input[type="search"] { flex: 1 1 180px; min-width: 160px; }
.toolbar input[type="search"]:focus, .toolbar select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 2px rgba(194, 73, 46, 0.16); }
.toolbar .count { font-size: 13px; color: var(--muted); margin-left: auto; white-space: nowrap; }
th.sortable { cursor: pointer; user-select: none; }
th.sortable:hover { color: var(--overlay-accent); }
th.sortable::after { content: "⇅"; font-size: 11px; color: #5a6b84; margin-left: 3px; }
html[data-theme="light"] th.sortable::after { color: #9aa7b8; }

/* 页脚 */
footer { border-top: 1px solid var(--border-light); color: var(--faint); font-size: 13px; padding: 20px 0 40px; margin-top: 24px; position: relative; }
footer::before { content: ""; position: absolute; top: -1px; left: 0; right: 0; height: 2px; background: linear-gradient(90deg, transparent, var(--accent) 50%, transparent); opacity: 0.45; }
footer a { color: var(--faint); }
footer a:hover { color: var(--accent); }

@media (max-width: 720px) {
  nav a { margin-left: 12px; }
  h1 { font-size: 20px; }
  table.data th, table.data td { padding: 4px 6px; }
  table.param td.k { width: 110px; }
  .map-hero { height: 56vh; min-height: 360px; }
  .mo-stack { right: 10px; bottom: 10px; max-width: calc(100% - 20px); }
  .full-map-wrap .mo-stack { bottom: 62px; }
  .mo-legend { font-size: 11px; padding: 6px 10px; }
  .map-overlay { padding: 10px 14px; }
  .theme-toggle { width: 38px; height: 38px; right: 10px; bottom: 10px; }
  .theme-toggle svg { width: 18px; height: 18px; }
}

@media print {
  .theme-toggle { display: none; }
}
