/* ============================================================
   巴西 · 巴拿马 行程站 — 样式 v3
   ============================================================ */

:root {
  --ink: #0e1726;
  --ink-2: #47536b;
  --ink-3: #7c8798;
  --line: #e6ebf2;
  --bg: #f6f8fc;
  --card: #ffffff;

  --green: #009c3b;
  --gold: #ffd500;
  --blue: #005293;
  --red: #da121a;
  --brand: #0b5c4a;
  --brand-2: #005293;
  --ok: #12805c;
  --warn: #b7791f;

  --r-lg: 20px;
  --r-md: 14px;
  --r-sm: 10px;
  --shadow: 0 2px 4px rgba(14, 23, 38, .04), 0 12px 28px rgba(14, 23, 38, .07);
  --shadow-sm: 0 1px 2px rgba(14, 23, 38, .05), 0 4px 12px rgba(14, 23, 38, .05);
  --maxw: 1120px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  background: var(--bg); color: var(--ink); line-height: 1.65; -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ---------- 导航 ---------- */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .9); backdrop-filter: saturate(180%) blur(14px); border-bottom: 1px solid var(--line); }
.nav-inner { display: flex; align-items: center; gap: 20px; height: 62px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; flex-shrink: 0; }
.brand-dot { width: 26px; height: 26px; border-radius: 8px; background: linear-gradient(135deg, var(--green) 0%, var(--gold) 48%, var(--blue) 100%); box-shadow: 0 2px 8px rgba(0, 82, 147, .28); }
.nav-links { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; margin-left: auto; }
.nav-links::-webkit-scrollbar { display: none; }
.nav-links a { padding: 7px 13px; border-radius: 999px; font-size: 14px; font-weight: 500; color: var(--ink-2); white-space: nowrap; transition: .18s; }
.nav-links a:hover { background: #eef2f8; color: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; color: #fff; padding: 74px 0 88px;
  background: linear-gradient(135deg, #054a34 0%, #0b5c4a 32%, #074a72 68%, #003a68 100%);
  background-size: cover; background-position: center;
}
.hero.has-photo { background-size: cover; }
.hero::before, .hero::after { content: ""; position: absolute; border-radius: 50%; opacity: .35; }
.hero::before { width: 460px; height: 460px; right: -120px; top: -180px; background: radial-gradient(circle, var(--gold), transparent 68%); }
.hero::after { width: 380px; height: 380px; left: -140px; bottom: -200px; background: radial-gradient(circle, #2ec4b6, transparent 70%); }
.hero.has-photo::before, .hero.has-photo::after { opacity: .16; }
.hero-inner { position: relative; z-index: 2; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; padding: 6px 14px; border-radius: 999px; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .26); margin-bottom: 18px; backdrop-filter: blur(4px); }
.hero h1 { font-size: clamp(32px, 5vw, 54px); line-height: 1.12; letter-spacing: -1.4px; font-weight: 800; text-shadow: 0 2px 24px rgba(0, 0, 0, .3); }
.hero p { margin-top: 12px; font-size: 17px; color: rgba(255, 255, 255, .9); max-width: 620px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.chip { background: rgba(255, 255, 255, .15); border: 1px solid rgba(255, 255, 255, .22); padding: 7px 14px; border-radius: 10px; font-size: 14px; font-weight: 500; backdrop-filter: blur(6px); }

/* ---------- 统计 ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: -42px; position: relative; z-index: 5; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 18px; box-shadow: var(--shadow-sm); }
.stat .k { font-size: 12px; color: var(--ink-3); font-weight: 600; letter-spacing: .4px; }
.stat .v { font-size: 26px; font-weight: 800; letter-spacing: -.6px; margin-top: 4px; }
.stat .v small { font-size: 14px; font-weight: 600; color: var(--ink-3); }
.stat .s { font-size: 12px; color: var(--ink-3); margin-top: 2px; }

/* ---------- 国家介绍 ---------- */
.ct-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.ct-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-sm); transition: .22s; }
.ct-card:hover { box-shadow: var(--shadow); }
.ct-head { position: relative; height: 148px; background-size: cover; background-position: center; background-color: #0b5c4a; display: flex; align-items: flex-end; padding: 16px 20px; }
.ct-flag { position: absolute; left: 0; right: 0; top: 0; height: 5px; display: flex; }
.ct-flag i { flex: 1; }
.ct-title h3 { color: #fff; font-size: 27px; font-weight: 800; letter-spacing: -.6px; text-shadow: 0 2px 14px rgba(0, 0, 0, .45); }
.ct-en { font-size: 12.5px; color: rgba(255, 255, 255, .82); margin-top: 2px; }
.ct-body { padding: 18px 20px 22px; }
.ct-tagline { font-size: 14px; color: var(--ink-2); line-height: 1.7; }
.ct-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; margin: 14px 0 4px; }
.ct-fact { background: #f7f9fc; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.ct-fact span { display: block; font-size: 11.5px; font-weight: 700; color: var(--ink-3); letter-spacing: .3px; }
.ct-fact strong { font-size: 13px; font-weight: 700; color: var(--ink); }
.ct-sec { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--line); }
.ct-sec h4 { font-size: 15px; font-weight: 800; letter-spacing: -.2px; display: flex; align-items: center; gap: 7px; margin-bottom: 9px; }
.ct-ico { font-size: 15px; }
.ct-p { font-size: 13.5px; color: var(--ink-2); line-height: 1.75; }
.ct-hist { list-style: none; display: flex; flex-direction: column; gap: 7px; margin-top: 4px; }
.ct-hist li { display: flex; gap: 10px; font-size: 13.2px; color: var(--ink-2); line-height: 1.6; }
.ct-year { flex: 0 0 62px; font-weight: 800; color: var(--brand-2); font-variant-numeric: tabular-nums; }
.ct-phrases { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; margin-top: 10px; }
.ct-phrase { background: #f7f9fc; border-radius: 8px; padding: 6px 10px; }
.ct-phrase b { display: block; font-size: 13px; color: var(--ink); }
.ct-phrase span { font-size: 12px; color: var(--ink-3); }
.ct-rate { margin-top: 9px; font-size: 12.5px; font-weight: 700; color: var(--brand-2); background: #eaf2f9; padding: 6px 10px; border-radius: 8px; display: inline-block; }
.ct-mini { list-style: none; margin-top: 8px; display: flex; flex-direction: column; gap: 5px; }
.ct-mini li { font-size: 12.8px; color: var(--ink-2); padding-left: 14px; position: relative; }
.ct-mini li::before { content: "·"; position: absolute; left: 3px; font-weight: 800; color: var(--gold); }
.ct-clim { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.ct-clim-row { display: grid; grid-template-columns: 92px 76px 1fr; gap: 8px; align-items: baseline; font-size: 13px; background: #f7f9fc; border-radius: 9px; padding: 7px 10px; }
.cc-city { font-weight: 700; }
.cc-temp { font-weight: 800; color: var(--brand-2); font-variant-numeric: tabular-nums; }
.cc-desc { font-size: 12.5px; color: var(--ink-2); }
.ct-pack { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chip.sm { background: #fff; border: 1px solid var(--line); color: var(--ink-2); padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; }

/* ---------- 区块 ---------- */
section { padding: 52px 0 8px; scroll-margin-top: 84px; }
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.sec-head h2 { font-size: 25px; font-weight: 800; letter-spacing: -.5px; display: flex; align-items: center; gap: 10px; }
.sec-head h2::before { content: ""; width: 4px; height: 22px; border-radius: 3px; background: linear-gradient(180deg, var(--green), var(--blue)); }
.sec-head .desc { font-size: 14px; color: var(--ink-3); max-width: 540px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); overflow: hidden; }
.card-pad { padding: 22px; }
.notice { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: var(--r-md); background: #fff9e6; border: 1px solid #f5e2a3; color: #6b5210; font-size: 14px; }

/* ---------- 地图 ---------- */
.map-card { background: #061a2e; border: 1px solid #0e2c47; border-radius: var(--r-lg); overflow: hidden; box-shadow: 0 18px 44px rgba(6, 26, 46, .34); }
#mapSvg { width: 100%; height: auto; display: block; }
.mp-grat { fill: none; stroke: rgba(255, 255, 255, .07); stroke-width: .8; }
.mp-land { fill: #123a5c; stroke: #1c4a72; stroke-width: .8; }
.mp-land.hl { fill: #17557f; stroke: #4aa8ff; stroke-width: 1.1; }
.mp-country { fill: rgba(255, 255, 255, .22); font-size: 15px; font-weight: 800; letter-spacing: 5px; text-anchor: middle; }
.mp-line { fill: none; stroke-width: 2.2; stroke-linecap: round; stroke-dasharray: 7 9; opacity: .95; animation: dash 2.6s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -32; } }
.mp-pulse { fill: rgba(74, 168, 255, .3); animation: pulse 2.8s ease-out infinite; }
@keyframes pulse { 0% { r: 8; opacity: .6; } 100% { r: 24; opacity: 0; } }
.mp-dot { fill: #fff; stroke: #4aa8ff; stroke-width: 3; transition: .2s; }
.mp-node { cursor: pointer; animation: fadein .6s backwards; }
.mp-node:hover .mp-dot { fill: var(--gold); stroke: #fff; r: 8; }
.mp-label text { font-family: inherit; }
.mp-name { fill: #fff; font-size: 15px; font-weight: 700; }
.mp-sub { fill: rgba(255, 255, 255, .6); font-size: 12px; }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
.map-legend { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 16px; background: #08243c; border-top: 1px solid #0e2c47; }
.mp-chip { font-size: 13px; font-weight: 600; color: rgba(255, 255, 255, .86); background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14); padding: 5px 12px; border-radius: 999px; transition: .18s; }
.mp-chip:hover { background: rgba(255, 255, 255, .18); color: #fff; }
.mp-chip span { margin-left: 5px; opacity: .7; }

/* ---------- 时间线 ---------- */
.timeline { position: relative; padding-left: 34px; }
.timeline::before { content: ""; position: absolute; left: 11px; top: 10px; bottom: 10px; width: 2px; background: linear-gradient(180deg, var(--green), var(--gold) 40%, var(--blue)); border-radius: 2px; }
.tl-item { position: relative; margin-bottom: 16px; }
.tl-item::before { content: ""; position: absolute; left: -30px; top: 20px; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 3px solid var(--brand-2); box-shadow: 0 0 0 3px #fff; }
.tl-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 18px 20px; box-shadow: var(--shadow-sm); transition: .2s; }
.tl-card:hover { box-shadow: var(--shadow); }
.tl-top { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.tl-day { font-size: 13px; font-weight: 800; color: #fff; background: var(--brand-2); padding: 3px 10px; border-radius: 7px; }
.tl-date { font-size: 13px; color: var(--ink-3); font-weight: 600; }
.tl-city { font-size: 13px; color: var(--ink-2); background: #eef2f8; padding: 3px 10px; border-radius: 7px; font-weight: 600; }
.tl-title { font-size: 17px; font-weight: 700; margin: 8px 0 10px; letter-spacing: -.2px; }
.tl-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 18px; }
.tl-label { font-size: 12px; font-weight: 700; color: var(--ink-3); margin-bottom: 5px; }
.tl-list { list-style: none; display: flex; flex-direction: column; gap: 5px; }
.tl-list li { font-size: 14px; color: var(--ink-2); padding-left: 15px; position: relative; }
.tl-list li::before { content: ""; position: absolute; left: 3px; top: 9px; width: 5px; height: 5px; border-radius: 50%; background: #c3ccda; }
/* ---------- 每日地点 ---------- */
.pl-list { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 14px; }
.pl-chip { display: inline-flex; align-items: center; gap: 8px; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px 5px 9px; font-size: 13px; transition: .16s; box-shadow: 0 1px 2px rgba(14, 23, 38, .04); }
.pl-chip:hover { border-color: var(--brand-2); background: #f4f9fd; transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.pl-ico { font-size: 13px; }
.pl-txt { display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap; }
.pl-txt strong { font-weight: 700; color: var(--ink); }
.pl-txt em { font-style: normal; font-size: 12px; color: var(--ink-3); }
.pl-kind { font-size: 11px; font-weight: 700; color: var(--ink-3); background: #f0f3f8; padding: 1px 7px; border-radius: 5px; }
.pl-go { font-size: 11px; color: var(--brand-2); font-weight: 700; }
.pl-chip.k-机场 { border-left: 3px solid #4aa8ff; }
.pl-chip.k-酒店 { border-left: 3px solid var(--brand); }
.pl-chip.k-景点 { border-left: 3px solid var(--gold); }
.pl-del { display: none; border: none; background: #fdeaec; color: #b3261e; width: 22px; height: 22px; border-radius: 50%; font-size: 13px; cursor: pointer; line-height: 1; }
body.editing .pl-del, body.editing .li-del { display: inline-flex; align-items: center; justify-content: center; }
.li-del { display: none; border: none; background: transparent; color: #c3ccda; font-size: 13px; cursor: pointer; margin-left: 4px; }
.li-del:hover { color: #b3261e; }
.day-add { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 14px; padding-top: 13px; border-top: 1px dashed var(--line); }
.day-add input, .day-add select { font-family: inherit; font-size: 13px; padding: 6px 10px; border: 1px solid #dfe5ee; border-radius: 9px; background: #fff; color: var(--ink); }
.day-add .qa-name { flex: 1; min-width: 180px; }
.day-add .qa-time { width: 130px; }
.empty.sm { font-size: 12.5px; color: var(--ink-3); padding: 4px 0; }

.tl-notes { background: #fbfcfe; border: 1px dashed var(--line); border-radius: var(--r-sm); padding: 11px 13px; }
.tl-notes li::before { background: var(--gold); }

/* 可点击景点 */
.spot { color: var(--brand-2); font-weight: 600; border-bottom: 1.5px dashed #a7c8e4; cursor: pointer; transition: .15s; }
.spot:hover { background: #eaf4fc; border-bottom-style: solid; }

/* ---------- 票据 ---------- */
.tk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; padding: 16px 18px 18px; }
.tk { position: relative; border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 16px; background: #fff; transition: .2s; }
.tk:hover { box-shadow: var(--shadow); border-color: #d5e0ee; }
.tk.wait { background: #fffdf6; border-color: #f2e4c2; }
.tk-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.tk-type { font-size: 12px; font-weight: 700; color: var(--brand-2); background: #eaf2f9; padding: 2px 9px; border-radius: 6px; }
.tk-head .row-del { margin-left: auto; }
.tk-name { font-size: 15px; font-weight: 700; letter-spacing: -.2px; line-height: 1.4; margin-bottom: 6px; }
.tk-line { font-size: 13px; color: var(--ink-2); display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
.tk-line .ico { font-size: 12px; opacity: .7; }
.tk-qty { margin-left: 8px; font-size: 12px; font-weight: 700; color: var(--ink-3); background: #f0f3f8; padding: 1px 7px; border-radius: 5px; }
.tk-ref { font-family: ui-monospace, Menlo, monospace; font-size: 12px; color: var(--brand-2); background: #f2f7fb; padding: 3px 8px; border-radius: 6px; display: inline-block; margin: 6px 0; }
.tk-amt { font-size: 15px; font-weight: 800; margin-top: 8px; font-variant-numeric: tabular-nums; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tk-cny { font-size: 12px; font-weight: 600; color: var(--ink-3); }
.tk-map { color: var(--brand-2); font-weight: 600; border-bottom: 1px dashed #bcd8f5; }
.tk-map:hover { border-bottom-style: solid; }
.tk-files { margin: 12px 0 8px; }
.fl-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 9px; }
.fl-item { position: relative; }
.fl-item img { width: 64px; height: 64px; object-fit: cover; border-radius: 9px; border: 1px solid var(--line); background: #fff; }
.fl-item a:hover img { border-color: var(--brand-2); }
.fl-doc { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 600; color: var(--brand-2); border: 1px solid var(--line); border-radius: 9px; padding: 8px 11px; background: #f7f9fc; max-width: 190px; }
.fl-doc span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fl-doc:hover { background: #eaf2f9; }
.fl-del { position: absolute; right: -6px; top: -6px; width: 19px; height: 19px; border-radius: 50%; border: none; background: #fdeaec; color: #b3261e; font-size: 12px; line-height: 1; cursor: pointer; box-shadow: 0 1px 4px rgba(0, 0, 0, .12); }
.t-note { font-size: 12.5px; color: var(--ink-3); line-height: 1.5; }
.mini-btn { font-family: inherit; font-size: 12.5px; font-weight: 600; padding: 5px 11px; border-radius: 8px; border: 1px solid #d9e2ee; background: #fff; color: var(--ink-2); cursor: pointer; transition: .15s; }
.mini-btn:hover { background: #f2f6fa; border-color: #bcd0e4; }
.mini-btn.primary { background: var(--brand-2); border-color: var(--brand-2); color: #fff; }
.mini-btn.primary:hover { background: #00447a; }
.mini-link { display: inline-block; margin-top: 8px; font-size: 12.5px; font-weight: 600; color: var(--brand-2); }

/* ---------- 花费 ---------- */
.exp-wrap { display: grid; grid-template-columns: 1.1fr 1fr; gap: 16px; }
.bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 11px; }
.bar-name { font-size: 13.5px; font-weight: 600; width: 150px; flex-shrink: 0; }
.bar-track { flex: 1; height: 10px; background: #eef2f8; border-radius: 6px; overflow: hidden; }
.bar-fill { height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--green), var(--blue)); }
.bar-val { font-size: 13px; font-weight: 700; width: 88px; text-align: right; font-variant-numeric: tabular-nums; }
/* ---------- 实际花费 ---------- */
.bd-total { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 16px; }
.bd-cell { background: #f7f9fc; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.bd-cell span { display: block; font-size: 11.5px; font-weight: 700; color: var(--ink-3); letter-spacing: .3px; }
.bd-cell strong { display: block; font-size: 22px; font-weight: 800; letter-spacing: -.5px; font-variant-numeric: tabular-nums; margin: 2px 0 1px; }
.bd-cell em { font-style: normal; font-size: 12px; color: var(--ink-3); }
.bd-cell.accent { background: linear-gradient(150deg, #0b5c4a, #074a72); border-color: transparent; }
.bd-cell.accent span, .bd-cell.accent em { color: rgba(255, 255, 255, .82); }
.bd-cell.accent strong { color: #fff; }
.bd-row { display: grid; grid-template-columns: 84px 1fr 148px 84px; gap: 10px; align-items: center; margin-bottom: 9px; }
.bd-name { font-size: 13.5px; font-weight: 700; }
.bd-track { position: relative; height: 10px; background: #eef2f8; border-radius: 6px; overflow: hidden; }
.bd-fill { height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--green), var(--blue)); transition: width .45s ease; }
.bd-fill.over { background: linear-gradient(90deg, #e08b2a, #c0392b); }
.bd-num { font-size: 12.5px; color: var(--ink-3); text-align: right; font-variant-numeric: tabular-nums; }
.bd-num b { font-size: 13.5px; color: var(--ink); }
.bd-left { font-size: 12.5px; font-weight: 700; color: var(--ok); text-align: right; font-variant-numeric: tabular-nums; }
.bd-left.neg { color: #c0392b; }
.bd-note { font-size: 12.5px; color: var(--ink-3); margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--line); }
.bd-edit-row { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid #f0f3f8; font-size: 13.5px; }
.bd-ename { flex: 1; font-weight: 600; }
.bd-eamt { font-weight: 700; font-variant-numeric: tabular-nums; }
.bd-eamt em { font-style: normal; font-size: 11.5px; font-weight: 600; color: var(--ink-3); margin-left: 5px; }
.tag.sm { font-size: 11.5px; padding: 1px 8px; }
.total-box { background: linear-gradient(150deg, #0b5c4a, #074a72); color: #fff; border-radius: var(--r-md); padding: 22px; }
.total-box .k { font-size: 13px; opacity: .82; }
.total-box .v { font-size: 32px; font-weight: 800; letter-spacing: -1px; margin: 4px 0 2px; }
.total-box .s { font-size: 12.5px; opacity: .8; }
.bal-box { background: #fff; border: 1px solid var(--line); border-radius: var(--r-md); padding: 16px 18px; align-self: start; }
.bal-title { font-size: 12px; font-weight: 700; color: var(--ink-3); letter-spacing: .4px; margin-bottom: 10px; }
.bal-row { display: flex; justify-content: space-between; gap: 10px; font-size: 13.5px; padding: 5px 0; border-bottom: 1px dashed #eef2f7; flex-wrap: wrap; }
.bal-row:last-of-type { border-bottom: none; }
.bal-pos { color: var(--ok); font-weight: 700; }
.bal-neg { color: #c0392b; font-weight: 700; }
.bal-settle { margin-top: 10px; font-size: 13.5px; font-weight: 700; color: var(--brand-2); }
.exp-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.exp-form input, .exp-form select {
  font-family: inherit; font-size: 13.5px; padding: 7px 10px; border: 1px solid #dfe5ee;
  border-radius: 9px; background: #fff; color: var(--ink);
}
.exp-form input[type="text"] { flex: 1; min-width: 130px; }
.exp-form input[type="number"] { width: 92px; }
.exp-row { display: flex; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid #f0f3f8; font-size: 13.5px; flex-wrap: wrap; }
.exp-cat { font-size: 12px; font-weight: 700; color: var(--brand-2); background: #eaf2f9; padding: 2px 9px; border-radius: 6px; }
.exp-item { font-weight: 600; flex: 1; min-width: 100px; }
.exp-date { font-size: 12.5px; color: var(--ink-3); }
.exp-amt { font-weight: 700; font-variant-numeric: tabular-nums; }
.exp-amt em { font-style: normal; font-size: 12px; font-weight: 600; color: var(--ink-3); margin-left: 5px; }
.exp-row .row-del { margin-left: auto; }
.empty { font-size: 13.5px; color: var(--ink-3); padding: 8px 0; }

/* ---------- 待办 ---------- */
.todo-bar { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.todo-track { flex: 1; height: 8px; background: #eef2f8; border-radius: 6px; overflow: hidden; }
.todo-fill { height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--green), #2aa86a); transition: width .4s; }
.todo-pct { font-size: 12px; font-weight: 700; color: var(--brand); }
.td-add { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; padding-bottom: 14px; border-bottom: 1px dashed var(--line); }
.td-add input, .td-add select { font-family: inherit; font-size: 13.5px; padding: 7px 11px; border: 1px solid #dfe5ee; border-radius: 9px; background: #fff; color: var(--ink); }
.td-add #tdName { flex: 1; min-width: 200px; }
.td-add .sm-in { width: 130px; }
.bk-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid #f0f3f8; font-size: 14px; }
.bk-row.is-done { opacity: .62; }
.bk-name { flex: 1.4; font-weight: 600; min-width: 130px; }
.bk-dl { font-size: 12.5px; color: var(--ink-3); width: 96px; flex-shrink: 0; }
.bk-note { flex: 1; font-size: 12.5px; color: var(--ink-3); min-width: 90px; }
.bk-status { width: 96px; flex-shrink: 0; }

/* ---------- Tips / 清单 ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.tip-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 20px; box-shadow: var(--shadow-sm); }
.tip-card h3 { font-size: 15.5px; font-weight: 700; margin-bottom: 10px; }
.tip-card ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.tip-card li { font-size: 13.5px; color: var(--ink-2); padding-left: 16px; position: relative; }
.tip-card li::before { content: "›"; position: absolute; left: 3px; color: var(--ink-3); font-weight: 700; }
.check-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.check-col { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 18px; box-shadow: var(--shadow-sm); }
.check-col h4 { font-size: 14.5px; font-weight: 700; margin-bottom: 12px; }
.check-col label { display: flex; align-items: flex-start; gap: 9px; font-size: 13.5px; color: var(--ink-2); padding: 5px 0; cursor: pointer; }
.check-col input { margin-top: 4px; width: 15px; height: 15px; accent-color: var(--brand); flex-shrink: 0; }
.check-col label.done { color: var(--ink-3); text-decoration: line-through; }

/* ---------- 更新记录 ---------- */
.log-item { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid #f0f3f8; }
.log-item:last-child { border-bottom: none; }
.log-date { font-size: 13px; font-weight: 700; color: var(--ink-2); width: 92px; flex-shrink: 0; }
.log-ver { font-size: 12px; font-weight: 700; color: var(--brand-2); background: #eaf2f9; padding: 1px 8px; border-radius: 5px; }

/* ---------- 景点弹窗 ---------- */
#modal { position: fixed; inset: 0; background: rgba(8, 15, 26, .58); backdrop-filter: blur(6px); display: none; align-items: center; justify-content: center; z-index: 200; padding: 20px; }
#modal.open { display: flex; animation: fadein .2s; }
#modalBody { background: #fff; border-radius: 18px; max-width: 540px; width: 100%; max-height: 86vh; overflow: auto; box-shadow: 0 30px 70px rgba(0, 0, 0, .4); animation: pop .25s; }
@keyframes pop { from { transform: scale(.96) translateY(10px); opacity: 0; } }
.md-photo { height: 200px; background-size: cover; background-position: center; background-color: #0b5c4a; position: relative; display: flex; align-items: center; justify-content: center; }
.md-ph { font-size: 54px; font-weight: 800; color: rgba(255, 255, 255, .85); }
.md-close { position: absolute; right: 12px; top: 12px; width: 32px; height: 32px; border-radius: 50%; border: none; background: rgba(0, 0, 0, .42); color: #fff; font-size: 19px; cursor: pointer; }
.md-in { padding: 20px 22px 24px; }
.md-in h3 { font-size: 21px; font-weight: 800; letter-spacing: -.4px; margin: 8px 0 6px; }
.md-best { font-size: 13px; font-weight: 600; color: var(--warn); background: #fdf6e8; padding: 5px 10px; border-radius: 7px; display: inline-block; margin-bottom: 12px; }
.md-intro { font-size: 14px; color: var(--ink-2); line-height: 1.7; }
.md-label { font-size: 12px; font-weight: 700; color: var(--ink-3); letter-spacing: .4px; margin: 16px 0 8px; }
.md-tips { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.md-tips li { font-size: 13.5px; color: var(--ink-2); padding: 9px 12px; background: #f7f9fc; border-radius: 9px; border-left: 3px solid var(--gold); }
.md-map { display: inline-block; margin-top: 16px; font-size: 13.5px; font-weight: 700; color: #fff; background: var(--brand-2); padding: 9px 16px; border-radius: 10px; }
.md-map:hover { background: #00447a; }

/* ---------- 身份 / 同步状态（原底栏已移除，改放「花费」区块顶部） ---------- */
.who-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 14px; padding: 10px 14px; background: #f7f9fc; border: 1px solid var(--line); border-radius: 12px; }
.who-wrap { font-size: 13px; color: var(--ink-2); display: inline-flex; align-items: center; gap: 8px; }
.who-select { border: 1px solid var(--line); background: #fff; color: var(--ink); font-size: 13px; font-weight: 600; padding: 6px 9px; border-radius: 9px; font-family: inherit; cursor: pointer; }
.sync { font-size: 12.5px; font-weight: 700; padding: 5px 11px; border-radius: 999px; background: #eef2f8; color: var(--ink-3); white-space: nowrap; margin-left: auto; }
.sync.ok { background: #e6f6ee; color: #14855c; }
.sync.warn { background: #fdf3e3; color: #9a6512; }
body.editing .only-view { display: none !important; }
body:not(.editing) .only-edit { display: none !important; }
.editable { border-radius: 6px; padding: 2px 5px; margin: -2px -5px; }
body.editing .editable { background: #fff8e1; outline: 1px dashed #e0b64a; cursor: text; }
body.editing .editable:focus { background: #fff; outline: 2px solid var(--brand-2); }
.row-del, .add-row { display: none; }
body.editing .row-del, body.editing .add-row { display: inline-flex; }
.row-del { border: none; background: #fdeaec; color: #b3261e; width: 24px; height: 24px; border-radius: 7px; cursor: pointer; font-size: 15px; line-height: 1; align-items: center; justify-content: center; flex-shrink: 0; }
.add-row { align-items: center; gap: 5px; font-size: 13px; font-weight: 600; color: var(--brand-2); background: #eaf2f9; border: 1px dashed #a9c6de; padding: 6px 12px; border-radius: 9px; cursor: pointer; font-family: inherit; }

/* 待办 / 记账的删除按钮常驻（不用先进编辑模式） */
#todoList .row-del, #expList .row-del { display: inline-flex; }

/* ---------- 动效 ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .55s ease, transform .55s ease; }
.reveal.in { opacity: 1; transform: none; }
.flash { position: fixed; left: 50%; bottom: 88px; transform: translateX(-50%); background: #0e1726; color: #fff; padding: 10px 18px; border-radius: 10px; font-size: 14px; z-index: 300; box-shadow: 0 8px 24px rgba(0, 0, 0, .24); }


/* ---------- 身份 / 同步状态条 ---------- */
.who-bar {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  margin-bottom: 14px; padding: 10px 14px;
  background: #f7f9fc; border: 1px solid var(--line); border-radius: 12px;
}
.who-wrap { font-size: 13px; color: var(--ink-2); display: inline-flex; align-items: center; gap: 8px; }
.who-select {
  font: inherit; font-size: 13px; font-weight: 600; color: var(--ink);
  border: 1px solid var(--line); border-radius: 8px; padding: 5px 9px; background: #fff; cursor: pointer;
}
.sync { font-size: 12.5px; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: #eef2f8; color: var(--ink-3); }
.sync.ok { background: #e6f6ee; color: #14855c; }
.sync.warn { background: #fdf3e3; color: #9a6512; }

/* ---------- 页脚 ---------- */
.footer { margin-top: 54px; padding: 30px 0 44px; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink-3); }
.footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.ft-link { color: var(--ink-3); text-decoration: underline; text-underline-offset: 3px; }
.ft-link:hover { color: var(--brand-2); }
.ft-hint { color: var(--ok); font-weight: 600; }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .grid-3, .check-grid { grid-template-columns: repeat(2, 1fr); }
  .exp-wrap, .tl-grid { grid-template-columns: 1fr; }
  .ct-grid { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .hero { padding: 54px 0 74px; }
  .stats { margin-top: -34px; }
  .grid-3, .check-grid { grid-template-columns: 1fr; }
  .tk-grid { grid-template-columns: 1fr; padding: 14px; }
  .bar-name { width: 108px; font-size: 12.5px; }
  .bk-dl, .bk-note { display: none; }
  #mapSvg { height: 340px; }
  .bd-total { grid-template-columns: 1fr; }
  .bd-row { grid-template-columns: 70px 1fr 96px; }
  .bd-left { display: none; }
  .ct-phrases { grid-template-columns: 1fr; }
  .ct-clim-row { grid-template-columns: 80px 1fr; }
  .cc-desc { grid-column: 1 / -1; }
  .day-add .qa-time { width: 100%; }
  .md-card { width: 94vw; max-height: 88vh; }
  .md-photo { height: 168px; }
  .who-bar { flex-direction: column; align-items: flex-start; gap: 8px; }
}
