/* 山伴 — app.css
   山伴風格：淺米灰綠底、深森林綠主色、鼠尾草綠 chip、細淺灰框白卡、襯線標題。
   手機優先（390px），桌機內容最大寬 880px 置中。 */
:root {
  --bg: #f5f6f1;
  --panel: #edefe7;
  --sage: #e6ebe1;
  --sage-2: #dfe6d9;
  --sage-line: #b8c9b2;
  --card: #ffffff;
  --field: #f8f9f5;
  --line: #dfe2da;
  --line-soft: #ebede6;
  --forest: #234a3c;
  --forest-2: #2f5c4b;
  --forest-ink: #1f3a30;
  --ink: #26332d;
  --ink-soft: #6b7a70;
  --ink-faint: #a3ada5;
  --eyebrow: #4f7a64;
  --amber: #e2b06a;
  --amber-2: #d9a566;
  --amber-tint: #f6ead6;
  --link-hover: #a8571a; /* 路線連結 hover／focus 文字色：與地圖暖橘協調，白底對比約 5.2:1 */
  --danger: #a8423a;
  --danger-tint: #f6e4e1;
  --warn-bg: #f4efdc;
  --warn-ink: #6a5521;
  --line-green: #06c755;
  --r-sm: 6px;
  --r: 10px;
  --r-lg: 16px;
  --font: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", "Noto Sans CJK TC", system-ui, sans-serif;
  --serif: "Noto Serif TC", "Noto Serif CJK TC", "Source Han Serif TC", "Songti TC", "PMingLiU", serif;
  --shadow-float: 0 12px 32px rgba(35, 74, 60, .18);
  --focus: 0 0 0 3px rgba(35, 74, 60, .28);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; }
body {
  margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg);
  line-height: 1.7; font-size: 16px; min-height: 100vh; display: flex; flex-direction: column;
}
a { color: var(--forest); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--forest); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { margin: 0 0 .5rem; line-height: 1.3; font-weight: 700; color: var(--forest-ink); }
h1 { font-size: 1.75rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 .75rem; }
.muted { color: var(--ink-soft); }
.small { font-size: .85rem; }
.hint { color: var(--ink-soft); font-size: .875rem; line-height: 1.6; margin: .35rem 0 0; }
.hint a { margin-left: .4rem; text-decoration: underline; text-underline-offset: 3px; }
.sub { margin-top: 1.25rem; color: var(--forest-ink); font-family: var(--serif); }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--forest); color: #fff; padding: .5rem 1rem; z-index: 100; border-radius: var(--r-sm); }
.skip-link:focus { left: 8px; top: 8px; }
.container { width: 100%; max-width: 912px; margin: 0 auto; padding: 0 16px; }
main.container { flex: 1; padding-top: .75rem; padding-bottom: 3rem; }
main:focus { outline: none; }

/* ---- 字體角色 ---- */
.serif-title { font-family: var(--serif); font-weight: 700; color: var(--forest-ink); letter-spacing: .01em; }
.eyebrow { font-size: .75rem; letter-spacing: .2em; text-transform: uppercase; color: var(--eyebrow); font-weight: 600; margin: 0 0 .45rem; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; margin: 1rem 0 1.25rem; }
.page-head .serif-title { font-size: 1.85rem; margin: 0 0 .35rem; line-height: 1.25; }
.page-lead { color: var(--ink-soft); margin: 0; max-width: 40em; }
.crumbs { font-size: .85rem; color: var(--ink-soft); margin: .75rem 0 0; }
.crumbs a { color: var(--ink-soft); text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; }
.crumbs a:hover { color: var(--forest); }
.crumbs + .page-head, .crumbs + .card { margin-top: .75rem; }

/* ---- 頂欄 ---- */
.topbar { background: var(--bg); position: sticky; top: 0; z-index: 50; border-bottom: 1px solid transparent; }
.topbar-inner { max-width: 912px; margin: 0 auto; padding: 0 16px; height: 60px; display: flex; align-items: center; gap: .5rem; }
.logo { display: inline-flex; align-items: center; gap: .4rem; color: var(--forest); margin-right: auto; flex: none; }
.logo:hover { text-decoration: none; }
.logo-mark { width: 18px; height: 22px; flex: none; }
.logo-mark path { fill: none; stroke: currentColor; stroke-width: 3.4; stroke-linecap: round; stroke-linejoin: round; }
.logo-text { font-family: var(--serif); font-weight: 700; font-size: 1.3rem; letter-spacing: .01em; line-height: 1; }
.logo-text small { font-family: var(--font); font-weight: 500; font-size: .78rem; color: var(--ink-soft); margin-left: .45rem; letter-spacing: .05em; }
.nav-links { display: flex; align-self: stretch; gap: .1rem; }
.nav-links a { display: inline-flex; align-items: center; padding: 0 .5rem; color: var(--ink-soft); font-weight: 500; font-size: .95rem; position: relative; white-space: nowrap; }
.nav-links a:hover { color: var(--forest); text-decoration: none; }
.nav-links a.active { color: var(--forest-ink); font-weight: 700; }
.nav-links a.active::after { content: ""; position: absolute; left: .5rem; right: .5rem; bottom: 6px; height: 4px; border-radius: 2px; background: var(--forest); }
.auth-box { display: flex; align-items: center; gap: .35rem; flex: none; }
.btn-auth { display: inline-flex; align-items: center; font: inherit; font-size: .88rem; font-weight: 700; color: var(--forest-ink); background: var(--sage); border: 0; border-radius: var(--r); padding: .45rem .75rem; cursor: pointer; white-space: nowrap; min-height: 38px; }
.btn-auth:hover { background: var(--sage-2); text-decoration: none; }
.btn-auth-out { background: transparent; color: var(--ink-soft); font-weight: 500; padding: .45rem .4rem; }
.user-chip { display: inline-flex; align-items: center; gap: .4rem; color: var(--forest-ink); font-weight: 600; font-size: .9rem; }
.user-chip:hover { text-decoration: none; }
.user-name { max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 639px) {
  .logo-text { font-size: 1.15rem; }
  .logo-text small { display: none; }
  .nav-links a { padding: 0 .4rem; font-size: .9rem; }
  .nav-links a.active::after { left: .4rem; right: .4rem; }
  .user-name { display: none; }
  .btn-auth { padding: .4rem .6rem; font-size: .84rem; }
}
@media (max-width: 359px) { .logo-text { display: none; } }
@media (min-width: 640px) {
  .topbar-inner { height: 68px; gap: 1rem; }
  .nav-links { gap: .75rem; }
  .nav-links a { font-size: 1rem; }
}

/* ---- email 橫幅 ---- */
.email-banner { background: var(--warn-bg); color: var(--warn-ink); border-bottom: 1px solid #e6dcb8; }
.banner-form { max-width: 912px; margin: 0 auto; padding: .6rem 16px; display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.banner-text { font-weight: 600; flex: 1 1 100%; }
.banner-form input { flex: 1 1 180px; min-width: 0; }
@media (min-width: 720px) { .banner-text { flex: 0 0 auto; margin-right: .5rem; } }

/* ---- 卡片 ---- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 1.25rem; margin-bottom: 1rem; }
.card-title { font-family: var(--serif); font-size: 1.2rem; color: var(--forest-ink); margin-bottom: .85rem; }
.center-card { text-align: center; max-width: 480px; margin: 2rem auto; padding: 2rem 1.25rem; }
.center-card .eyebrow { margin-bottom: .25rem; }
.result-icon { width: 64px; height: 64px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 2rem; font-weight: 700; margin-bottom: .75rem; }
.result-icon.ok { background: var(--sage); color: var(--forest); }
.result-icon.bad { background: var(--danger-tint); color: var(--danger); }
@media (min-width: 720px) { .card { padding: 1.5rem 1.75rem; } }

/* ---- 按鈕 ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; border-radius: var(--r-sm); padding: .6rem 1.1rem; font: inherit; font-weight: 700; cursor: pointer; border: 1px solid transparent; background: var(--sage); color: var(--forest-ink); text-decoration: none; line-height: 1.25; min-height: 44px; transition: background .15s, border-color .15s, color .15s; }
.btn:hover { text-decoration: none; background: var(--sage-2); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--forest); color: #fff; }
.btn-primary:hover { background: var(--forest-ink); }
.btn-outline { background: #fff; color: var(--forest); border-color: var(--forest); }
.btn-outline:hover { background: var(--sage); }
.btn-ghost { background: #fff; border-color: var(--line); color: var(--ink); font-weight: 500; }
.btn-ghost:hover { background: var(--field); border-color: var(--sage-line); }
.btn-danger { background: var(--danger-tint); color: var(--danger); border-color: #e7c2bd; }
.btn-danger:hover { background: #f0d3ce; }
.btn-sm { padding: .3rem .75rem; min-height: 34px; font-size: .9rem; }
.btn-lg { padding: .85rem 1.4rem; font-size: 1.05rem; min-height: 52px; border-radius: var(--r-sm); }
.btn-line { background: var(--line-green); color: #fff; }
.btn-line:hover { background: #05b04c; }
.btn-row { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: .75rem; }
.btn-row.center { justify-content: center; }
.link { font-size: .9rem; font-weight: 600; }
.link-btn { font: inherit; background: none; border: 0; padding: .25rem .1rem; color: var(--forest-ink); font-weight: 600; cursor: pointer; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; }
.link-btn:hover { color: var(--forest); }

/* ---- pill（篩選、單選） ---- */
.pills { display: flex; flex-wrap: wrap; gap: .375rem; margin: 0 0 .6rem; }
.pill { font: inherit; font-size: .875rem; background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: 999px; padding: .45rem .75rem; cursor: pointer; min-height: 40px; line-height: 1.2; }
.pill:hover { border-color: var(--sage-line); background: var(--field); }
.pill.active { background: var(--forest); color: #fff; border-color: var(--forest); font-weight: 700; }
.pills-sm .pill { font-size: .9rem; padding: .35rem .9rem; min-height: 36px; }

/* ---- 表單 ---- */
input, select, textarea { font: inherit; color: var(--ink); background: var(--field); border: 1px solid var(--line); border-radius: var(--r-sm); padding: .55rem .8rem; width: 100%; min-height: 46px; line-height: 1.4; }
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--ink-soft) 50%), linear-gradient(135deg, var(--ink-soft) 50%, transparent 50%); background-position: calc(100% - 18px) 52%, calc(100% - 13px) 52%; background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-right: 2.2rem; }
textarea { min-height: 96px; resize: vertical; line-height: 1.6; }
input::placeholder, textarea::placeholder { color: var(--ink-faint); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--forest); box-shadow: var(--focus); background-color: #fff; }
select:disabled, input:disabled { color: var(--ink-faint); background-color: var(--panel); }
.fs { border: 0; padding: 0; margin: 0 0 1.75rem; min-width: 0; }
.fs legend { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; color: var(--forest-ink); margin-bottom: .75rem; padding: 0; display: flex; align-items: baseline; gap: .6rem; }
.fs-num { font-family: var(--serif); font-size: .85rem; color: #fff; background: var(--forest); border-radius: 999px; min-width: 2rem; height: 1.6rem; display: inline-flex; align-items: center; justify-content: center; letter-spacing: .02em; flex: none; align-self: center; }
.field { display: flex; flex-direction: column; gap: .35rem; margin-bottom: .85rem; min-width: 0; }
.field label { font-size: .875rem; color: var(--ink-soft); }
.grid-2, .grid-3 { display: grid; grid-template-columns: 1fr; gap: 0 .85rem; }
@media (min-width: 560px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-3 { grid-template-columns: 1fr 1fr 1fr; } }
.form-actions { margin-top: 1rem; display: flex; flex-direction: column; gap: .6rem; align-items: flex-start; }
.counter { text-align: right; }
.inline-form { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: .5rem; }
.inline-form input { flex: 1 1 200px; }
.edit-wrap textarea { margin-bottom: .25rem; }
.group-label { font-size: .875rem; color: var(--ink-soft); margin: 0 0 .4rem; }
.radio-row { display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: .6rem; }
.radio, .check { position: relative; display: inline-flex; align-items: center; gap: .4rem; padding: .45rem 1rem; border: 1px solid var(--line); border-radius: 999px; background: #fff; cursor: pointer; font-size: .95rem; min-height: 40px; }
.radio:hover, .check:hover { border-color: var(--sage-line); }
.radio input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.check input { accent-color: var(--forest); margin: 0; width: 18px; height: 18px; min-height: 0; flex: none; }
.radio:has(input:checked) { background: var(--forest); color: #fff; border-color: var(--forest); font-weight: 700; }
.radio:has(input:disabled) { opacity: .45; cursor: not-allowed; }
.check:has(input:checked) { background: var(--sage); border-color: var(--sage-line); }
.radio:has(input:focus-visible), .check:has(input:focus-visible) { outline: 2px solid var(--forest); outline-offset: 2px; }
.radio-row + .hint { margin: -.2rem 0 .8rem; }
.mode-cards { display: grid; grid-template-columns: 1fr; gap: .6rem; }
@media (min-width: 560px) { .mode-cards { grid-template-columns: 1fr 1fr; } }
.radio.radio-card { display: flex; align-items: flex-start; gap: .55rem; padding: .9rem 1rem; border-radius: var(--r); }
.radio-card-title { display: block; font-family: var(--serif); font-weight: 700; font-size: 1.1rem; line-height: 1.4; }
.radio-card-desc { display: block; font-size: .85rem; color: var(--ink-soft); line-height: 1.55; font-weight: 400; }
.radio-card:has(input:checked) .radio-card-desc { color: #d5e1d9; }
.check.check-block { display: flex; align-items: flex-start; line-height: 1.6; border-radius: var(--r); padding: .75rem 1rem; }
.check-block input { margin-top: .2rem; }
.check-agree:has(input:checked) { background: var(--sage); border-color: var(--forest); }
.create-form .form-actions { border-top: 1px solid var(--line-soft); padding-top: 1.25rem; }
.create-form .form-actions .btn { width: 100%; }
@media (min-width: 560px) { .create-form .form-actions .btn { width: auto; min-width: 240px; } }

/* ---- 狀態 ---- */
.state { padding: 1.1rem; text-align: center; color: var(--ink-soft); border-radius: var(--r); }
.state-loading { display: flex; align-items: center; justify-content: center; gap: .5rem; }
.state-empty { background: var(--card); border: 1px dashed var(--sage-line); }
.state-error { background: var(--danger-tint); color: var(--danger); display: flex; flex-direction: column; gap: .5rem; align-items: center; }
.spinner { width: 16px; height: 16px; border: 2px solid var(--line); border-top-color: var(--forest); border-radius: 50%; display: inline-block; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- 便條 ---- */
.notice { padding: .7rem 1rem; border-radius: var(--r-sm); font-size: .9rem; line-height: 1.65; }
.notice-muted { background: var(--panel); color: var(--ink-soft); border: 1px solid var(--line); }
.notice-warn { background: var(--warn-bg); color: var(--warn-ink); border: 1px solid #e6dcb8; }
.disclaimer { margin: 1rem 0; }

/* ---- Toast ---- */
.toast-host { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); display: flex; flex-direction: column; gap: .5rem; z-index: 200; width: min(92vw, 420px); pointer-events: none; }
.toast-host { z-index: 1100; } /* 要蓋在徽章動畫（z-index 1000）之上 */
.toast { background: var(--forest-ink); color: #fff; padding: .75rem 1rem; border-radius: var(--r); box-shadow: var(--shadow-float); opacity: 0; transform: translateY(8px); transition: opacity .2s, transform .2s; font-size: .95rem; }
.toast.show { opacity: 1; transform: none; }
.toast-error { background: var(--danger); }
.toast-success { background: var(--forest); }
.toast-warn { background: #7a5d16; }

/* ---- chip / badge ---- */
.badge { display: inline-flex; align-items: center; font-size: .8rem; font-weight: 500; padding: .15rem .6rem; border-radius: var(--r-sm); line-height: 1.6; white-space: nowrap; background: var(--sage); color: var(--forest-2); }
.chip-row { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin-bottom: .6rem; }
.badge-status-open { background: var(--sage); color: var(--forest-2); }
.badge-status-formed { background: var(--forest); color: #fff; }
.badge-status-closed { background: var(--panel); color: var(--ink-faint); }
.badge-status-cancelled { background: var(--danger-tint); color: var(--danger); }
.badge-count { background: var(--amber-tint); color: #7b5520; font-weight: 700; }
.badge-host { background: var(--forest); color: #fff; }
.badge-me { background: var(--sage); color: var(--forest); }
.badge-ok { background: var(--sage); color: var(--forest); }
.badge-warn { background: var(--warn-bg); color: var(--warn-ink); }
.badge-license { background: var(--sage); color: var(--forest); }
.badge-custom { background: var(--panel); color: var(--ink-soft); }
.badge-tag { background: #fff; color: var(--ink-soft); box-shadow: inset 0 0 0 1px var(--line); }
.badge-exp { background: var(--amber-tint); color: #7b5520; }
.badge-mode-hike { background: var(--forest); color: #fff; }
.badge-mode-ride_only { background: #fff; color: #8a5a22; box-shadow: inset 0 0 0 1px var(--amber-2); }
.badge-transport { background: #fff; color: var(--ink-soft); box-shadow: inset 0 0 0 1px var(--line); }
.badge-nocar { background: var(--warn-bg); color: var(--warn-ink); }

/* ---- 頭像 ---- */
.avatar { --size: 32px; }
.avatar-22 { --size: 22px; } .avatar-28 { --size: 28px; } .avatar-36 { --size: 36px; } .avatar-56 { --size: 56px; }
.avatar { width: var(--size); height: var(--size); border-radius: 50%; background: var(--sage); color: var(--forest); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: calc(var(--size) * .45); overflow: hidden; flex: none; vertical-align: middle; font-family: var(--serif); }
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.inline-user { display: inline-flex; align-items: center; gap: .3rem; }

/* ---- 鍵值表 ---- */
.kv { display: grid; grid-template-columns: auto 1fr; gap: .45rem 1rem; margin: 0; font-size: .95rem; }
.kv dt { color: var(--ink-soft); white-space: nowrap; font-size: .875rem; padding-top: .1em; }
.kv dd { margin: 0; overflow-wrap: anywhere; color: var(--ink); }
@media (min-width: 640px) { .kv-2col { grid-template-columns: auto 1fr auto 1fr; } }

/* ================= 首頁 ================= */
.hero { position: relative; overflow: hidden; background: var(--panel); border-radius: var(--r-lg); padding: 2.25rem 1.5rem 0; margin: .5rem 0 1.5rem; display: flex; flex-direction: column; }
.hero-copy { position: relative; z-index: 1; }
.hero-title { font-family: var(--serif); font-weight: 700; font-size: 2.6rem; line-height: 1.3; letter-spacing: .08em; color: var(--forest-ink); margin: .75rem 0 1rem; }
.hero-lead { color: var(--ink-soft); font-size: 1rem; line-height: 1.95; margin-bottom: 1.5rem; }
.hero-note { font-size: .85rem; color: var(--ink-soft); margin: .9rem 0 0; }
.hero-art { display: block; width: 90%; margin: .75rem -1.5rem 0 auto; height: auto; align-self: flex-end; }
.hero-art .sun-a { stop-color: #ecd6a4; }
.hero-art .sun-b { stop-color: #e2b06a; }
.hero-art .m-far { fill: #a6b8a8; }
.hero-art .m-snow { fill: #f2f3ee; }
.hero-art .m-snow-shade { fill: #c9d4c9; }
.hero-art .m-mid { fill: #739580; }
.hero-art .m-near { fill: #46695a; }
.hero-art .trail { fill: none; stroke: #d9cba5; stroke-width: 6; stroke-linejoin: miter; stroke-linecap: butt; }
.hero-art .hiker-head { fill: #e2b06a; }
.hero-art .hiker-pack { fill: #d9a566; }
.hero-art .hiker-body { fill: none; stroke: #f2ead6; stroke-width: 2.6; stroke-linecap: round; }
.hero-art .tree { fill: #2f5546; }
.hero-art-text { font: 600 9px var(--font); letter-spacing: .35em; fill: #fff; opacity: .16; }
@media (min-width: 720px) {
  .hero { padding: 3.25rem 3rem; min-height: 420px; justify-content: center; }
  .hero-copy { max-width: 25rem; }
  .hero-title { font-size: 3.4rem; }
  .hero-art { position: absolute; right: 0; bottom: 0; width: 64%; margin: 0; }
}
.notice-strip { display: grid; grid-template-columns: auto 1fr; gap: .4rem .75rem; align-items: start; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 1rem 1.1rem; margin-bottom: 2.75rem; }
.ns-icon { width: 34px; height: 34px; border-radius: 50%; background: var(--sage); color: var(--forest); display: inline-flex; align-items: center; justify-content: center; font-size: 1rem; }
.ns-text { margin: 0; color: var(--ink-soft); font-size: .92rem; line-height: 1.75; }
.ns-link { grid-column: 2; font-weight: 700; color: var(--forest-ink); font-size: .92rem; white-space: nowrap; }
@media (min-width: 640px) {
  .notice-strip { grid-template-columns: auto 1fr auto; align-items: center; }
  .ns-link { grid-column: auto; }
}
.section-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: 1.1rem; }
.section-head .serif-title { font-size: 1.85rem; margin: 0; line-height: 1.3; }
.section-head .eyebrow { white-space: nowrap; }
@media (max-width: 479px) { .section-head .eyebrow { font-size: .68rem; letter-spacing: .13em; } }
.section-head .btn { flex: none; margin-top: .3rem; }
.search-card { padding: 1.4rem 1.25rem 1.25rem; }
.search-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 .85rem; }
.search-grid .span-2 { grid-column: 1 / -1; }
.search-actions { display: grid; grid-template-columns: 1fr 1fr; gap: .85rem; align-items: center; margin-top: .25rem; }
.search-actions .link-btn { justify-self: center; font-size: 1.05rem; }
.search-actions .btn { min-height: 52px; font-size: 1.05rem; }
.search-status { margin: .6rem 0 0; font-size: .85rem; color: var(--eyebrow); text-align: right; }
.search-status:empty { display: none; }
@media (min-width: 720px) {
  .search-grid { grid-template-columns: 2fr 1fr 1fr; }
  .search-grid .span-2 { grid-column: span 1; }
  .search-actions { grid-template-columns: auto 220px; justify-content: end; gap: 1.5rem; }
}

/* ---- 月曆卡 ---- */
.cal-card { padding: 0; overflow: hidden; margin-bottom: 2.25rem; }
.cal-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: .1rem .75rem; padding: 1.4rem 1.1rem 1.2rem; }
.cal-head-text { display: contents; }
.cal-sub { grid-column: 1 / -1; }
.cal-title { white-space: nowrap; font-family: var(--serif); font-weight: 700; font-size: 1.6rem; color: var(--forest-ink); margin: 0 0 .3rem; line-height: 1.2; letter-spacing: .02em; }
.cal-sub { margin: 0; font-size: .82rem; color: var(--ink-soft); }
.cal-navs { display: flex; gap: .35rem; flex: none; grid-column: 2; grid-row: 1; }
.cal-title { grid-column: 1; grid-row: 1; }
.cal-sub { grid-row: 2; }
.cal-btn { font: inherit; background: #fff; border: 1px solid var(--line); border-radius: var(--r-sm); min-width: 38px; height: 38px; padding: 0 .6rem; color: var(--forest-ink); cursor: pointer; font-size: .95rem; }
.cal-btn:hover { background: var(--field); border-color: var(--sage-line); }
.cal-grid { border-top: 1px solid var(--line); }
.cal-row { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-weekdays { background: #f2f5ee; border-bottom: 1px solid var(--line); }
.cal-weekday { text-align: center; font-size: .85rem; color: var(--ink-soft); padding: .65rem 0; }
.cal-row + .cal-row:not(.cal-weekdays) { border-top: 1px solid var(--line); }
.cal-cell { font: inherit; background: #fff; border: 0; border-left: 1px solid var(--line); min-height: 72px; padding: .4rem .3rem .35rem; text-align: left; cursor: pointer; display: flex; flex-direction: column; align-items: flex-start; gap: 3px; color: var(--ink); position: relative; line-height: 1.3; min-width: 0; }
.cal-cell:first-child { border-left: 0; }
.cal-cell:hover { background: var(--field); }
.cal-cell:focus-visible { outline: 2px solid var(--forest); outline-offset: -3px; border-radius: 0; z-index: 1; }
.cal-cell.out { background: #fafbf8; }
.cal-cell.out .cal-day { color: #c3c9c3; }
.cal-day { font-size: .85rem; color: var(--ink-soft); min-width: 1.75rem; height: 1.75rem; display: inline-flex; align-items: center; justify-content: center; margin: -.15rem 0 0 -.1rem; border-radius: 50%; font-variant-numeric: tabular-nums; }
.cal-cell.today, .cal-cell.today:hover { background: var(--amber-tint); }
.cal-cell.today .cal-day { color: var(--forest); font-weight: 700; box-shadow: inset 0 0 0 1.5px var(--forest); }
.cal-cell.selected .cal-day { background: var(--forest); color: #fff; font-weight: 700; box-shadow: none; }
.cal-chips { display: flex; flex-direction: column; gap: 2px; width: 100%; min-width: 0; }
.cal-chip { display: block; background: var(--sage); color: var(--forest-2); border-radius: 4px; font-size: .66rem; padding: .1rem .25rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; line-height: 1.45; }
.cal-cell.selected .cal-chip { background: #d4e0d0; color: var(--forest-ink); }
.cal-cell.past:not(.out) .cal-chip { opacity: .65; }
.cal-more { font-size: .66rem; color: var(--ink-soft); padding-left: .2rem; }
@media (min-width: 640px) {
  .cal-head { padding: 1.75rem 1.75rem 1.4rem; }
  .cal-title { font-size: 2rem; }
  .pill { font-size: .95rem; padding: .45rem 1.05rem; }
  .pills { gap: .5rem; }
  .cal-cell { min-height: 96px; padding: .5rem .45rem; }
  .cal-day { font-size: .92rem; }
  .cal-chip { font-size: .76rem; padding: .15rem .4rem; }
}

/* ---- 約定清單（票根卡） ---- */
.board-list-head { display: flex; align-items: baseline; flex-wrap: wrap; gap: .3rem .75rem; margin: 0 0 1rem; }
.section-title { font-size: 1.5rem; margin: 0; }
.board-count { color: var(--ink-soft); font-size: .92rem; }
.board-list-head .link-btn { margin-left: auto; font-size: .92rem; }
.gcard-list { display: flex; flex-direction: column; gap: 1rem; }
.gcard { display: grid; grid-template-columns: 96px 1fr; background: #fff; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; color: var(--ink); transition: border-color .15s, transform .15s; }
.gcard:hover { text-decoration: none; border-color: var(--sage-line); }
.gcard:hover .gcard-title, .gcard:focus-visible .gcard-title { color: var(--link-hover); text-decoration: none; }
.gcard:focus-visible { outline: 2px solid var(--forest); outline-offset: 2px; border-radius: var(--r); }
.ticket { position: relative; background: var(--sage); display: flex; flex-direction: column; align-items: center; padding: 1.1rem .5rem 0; min-height: 150px; overflow: hidden; }
.ticket-card { position: relative; z-index: 1; background: #f7f9f4; border-radius: var(--r-sm); width: 64px; padding: .45rem 0 .35rem; display: flex; flex-direction: column; align-items: center; line-height: 1.1; }
.ticket-month { font-size: .8rem; color: var(--forest-ink); }
.ticket-day { font-family: var(--serif); font-weight: 700; font-size: 1.9rem; color: var(--forest-ink); line-height: 1.15; margin-top: .25rem; letter-spacing: .02em; font-variant-numeric: lining-nums; }
.ticket-trail { position: absolute; left: 0; right: 0; bottom: 0; height: 64px; }
.ticket-trail::before, .ticket-trail::after { content: ""; position: absolute; bottom: -4px; width: 7px; height: 66px; background: var(--sage-line); border-radius: 2px; }
.ticket-trail::before { left: 15%; transform: rotate(20deg); transform-origin: bottom center; }
.ticket-trail::after { right: 15%; transform: rotate(-20deg); transform-origin: bottom center; }
.ticket-big { width: 104px; min-height: 140px; border-radius: var(--r); flex: none; }
.gcard-body { padding: 1.05rem 1.1rem .9rem; min-width: 0; display: flex; flex-direction: column; }
.gcard-top { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-bottom: .55rem; }
.gcard-title { font-family: var(--serif); font-weight: 700; font-size: 1.2rem; color: var(--forest-ink); margin: 0 0 .35rem; line-height: 1.4; overflow-wrap: anywhere; }
.gcard-sub { color: var(--ink-soft); font-size: .88rem; margin: 0 0 .5rem; overflow-wrap: anywhere; line-height: 1.6; }
.gcard-tags { display: flex; flex-wrap: wrap; gap: .3rem; margin-bottom: .75rem; }
.gcard-tags .badge { font-size: .74rem; padding: .05rem .5rem; }
.gcard-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; gap: .5rem; border-top: 1px solid var(--line-soft); padding-top: .7rem; font-size: .85rem; }
.gcard-host { color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.gcard-people { color: var(--ink); white-space: nowrap; font-variant-numeric: tabular-nums; }
.arrow { color: var(--forest); }
@media (min-width: 640px) {
  .gcard { grid-template-columns: 120px 1fr; }
  .ticket-card { width: 76px; }
  .ticket-day { font-size: 2.2rem; }
  .gcard-body { padding: 1.2rem 1.5rem 1rem; }
  .gcard-title { font-size: 1.3rem; }
}

/* ================= 探索路線 ================= */
.map-panel { background: var(--panel); border-radius: var(--r-lg); padding: 1rem .5rem 1.25rem; margin-bottom: 1.5rem; }
.map-box { width: 100%; max-width: 460px; margin: 0 auto; }
.tw-map { width: 100%; height: auto; display: block; overflow: visible; }
.map-cap { text-align: center; color: var(--ink-soft); font-size: .8rem; margin: .5rem 0 0; line-height: 1.8; text-wrap: balance; }
.tw-north text { font: 500 12px var(--font); fill: #6f8a78; }
.tw-north path { fill: none; stroke: #6f8a78; stroke-width: 1.1; stroke-linecap: round; stroke-linejoin: round; }
.tw-county { cursor: pointer; }
.tw-county-shape { stroke: none; transition: fill .2s, filter .2s; }
/* 地圖配色（使用者指定）：底 F0F7EE；北 C4D7F2、中 AFDEDC、南 91A8A4、東 776871。選中區域保留原色，其他區域淡化 */
:root { --rg-north: #C4D7F2; --rg-central: #AFDEDC; --rg-south: #91A8A4; --rg-east: #776871; --rg-bg: #F0F7EE; }
.tw-county-north .tw-county-shape { fill: var(--rg-north); }
.tw-county-central .tw-county-shape { fill: var(--rg-central); }
.tw-county-south .tw-county-shape { fill: var(--rg-south); }
.tw-county-east .tw-county-shape { fill: var(--rg-east); }
.tw-county .tw-county-shape { transition: fill .2s, filter .2s, opacity .2s; }
.tw-has-region .tw-county:not(.is-region) .tw-county-shape { opacity: .28; }
.map-panel { background: var(--rg-bg); }
.tw-label-callout .tw-county-label, .tw-peak-label { stroke: var(--rg-bg); }
.map-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: .35rem 1rem; margin: .6rem 0 0; padding: 0; list-style: none; font-size: .85rem; color: var(--ink); }
.map-legend li { display: inline-flex; align-items: center; gap: .35rem; }
.map-legend i { width: 14px; height: 14px; border-radius: 4px; display: inline-block; }
.tw-county:hover .tw-county-shape { filter: brightness(.92); }
.tw-county.is-region:hover .tw-county-shape { filter: brightness(.95); }
.tw-county:focus { outline: none; }
.tw-county:focus-visible .tw-county-shape { stroke: var(--forest); stroke-width: 2; }
.tw-borders { fill: none; stroke: #fff; stroke-width: .8; stroke-linejoin: round; pointer-events: none; }
.tw-coast { fill: none; stroke: #4f6b5a; stroke-width: .9; stroke-linejoin: round; pointer-events: none; }
.tw-selected-outline { fill: none; stroke: var(--forest); stroke-width: 5; stroke-linejoin: round; pointer-events: none; }
.tw-county-label { font: 700 12px var(--font); fill: var(--forest-ink); pointer-events: none; paint-order: stroke; stroke: rgba(255, 255, 255, .85); stroke-width: 3px; stroke-linejoin: round; }
.tw-label.is-selected .tw-county-label { font-size: 13px; }
.tw-label-callout .tw-county-label { font-size: 12px; stroke: var(--panel); }
.tw-leader { stroke: #6f8a78; stroke-width: .7; }
.tw-leader-dot { fill: var(--forest-ink); }
/* 精選山：暖棕小三角＋細淡引線＋島外標籤（比縣市名小一號、非粗體）；版面由 tools/build-tw-map.mjs 算好 */
.tw-peak { cursor: pointer; }
.tw-peak, .tw-peak:hover { text-decoration: none; }
.tw-peak-leader { stroke: #a0825f; stroke-width: .5; opacity: .55; }
.tw-peak-hit { fill: transparent; }
.tw-peak-mark { fill: #8a5a2b; stroke: #fff; stroke-width: .9; stroke-linejoin: round; }
.tw-peak-label { font: 400 11px var(--font); fill: #6b4524; paint-order: stroke; stroke: var(--panel); stroke-width: 3px; stroke-linejoin: round; }
.tw-peak:hover .tw-peak-label, .tw-peak:focus-visible .tw-peak-label { fill: var(--link-hover); }
.tw-peak:hover .tw-peak-mark, .tw-peak:focus-visible .tw-peak-mark { fill: var(--link-hover); }
.tw-peak:hover .tw-peak-leader, .tw-peak:focus-visible .tw-peak-leader { stroke: var(--link-hover); opacity: 1; stroke-width: .9; }
.tw-peak:focus-visible .tw-peak-label { stroke: #f6e3c8; stroke-width: 5px; }
@media (max-width: 480px) { .tw-peak-label { font-size: 12px; } }
.map-filters .pills { margin-bottom: .5rem; }
.filter-note { color: var(--ink-soft); font-size: .9rem; margin: 0 0 1rem; }
.county-row { display: flex; align-items: center; gap: .85rem; margin-bottom: 1.1rem; }
.county-row label { font-size: 1rem; color: var(--ink); white-space: nowrap; }
.county-row select { max-width: 280px; background-color: #fff; }
.result-note { margin-top: .4rem; }
.rcard-list { display: flex; flex-direction: column; gap: .9rem; }
.rcard { display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 1.25rem 1.35rem; color: var(--ink); }
a.rcard:hover { text-decoration: none; border-color: var(--sage-line); }
a.rcard:hover .rcard-title, a.rcard:focus-visible .rcard-title, a.rcard:hover .arrow, a.rcard:focus-visible .arrow { color: var(--link-hover); text-decoration: none; }
.rcard-top { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .6rem; }
.rcard-title { font-family: var(--serif); font-weight: 700; font-size: 1.25rem; color: var(--forest-ink); margin: 0 0 .35rem; line-height: 1.4; }
.rcard-sub { color: var(--ink-soft); font-size: .9rem; margin: 0; overflow-wrap: anywhere; }
.rcard-subs { list-style: none; margin: .85rem 0 0; padding: 0; border-top: 1px solid var(--line-soft); }
.rcard-subs li + li { border-top: 1px solid var(--line-soft); }
.rcard-subs a { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: .75rem; padding: .65rem .1rem; color: var(--ink); }
.rcard-subtext { display: flex; flex-wrap: wrap; align-items: baseline; gap: .1rem .6rem; min-width: 0; }
.rcard-subs a:hover, .rcard-subs a:focus-visible { text-decoration: none; background: var(--field); }
.rcard-subs a:hover .rcard-subname, .rcard-subs a:focus-visible .rcard-subname { color: var(--link-hover); }
.rcard-subname { font-weight: 700; color: var(--forest-ink); }
.rcard-submeta { color: var(--ink-soft); font-size: .85rem; }

@media (min-width: 880px) {
  .map-page { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 1.75rem; align-items: start; }
  .map-page > .page-head { grid-column: 1 / -1; }
  .map-page > .map-panel { position: sticky; top: 84px; }
}

/* ================= 路線頁 ================= */
.route-title { font-size: 1.9rem; margin: 0 0 .3rem; }
.route-info .page-lead { margin-bottom: 1.1rem; }
.route-info .kv { border-top: 1px solid var(--line-soft); padding-top: 1rem; }
.route-desc { margin-top: 1rem; max-width: 40em; }
.sibling-routes { margin: 1.75rem 0 2rem; }
.route-page .board { margin-top: 1.75rem; }

/* ---- 業者 ---- */
.operator-list { display: grid; grid-template-columns: 1fr; gap: .75rem; margin-top: .75rem; }
@media (min-width: 720px) { .operator-list { grid-template-columns: 1fr 1fr; } }
.operator-card { border: 1px solid var(--line); border-radius: var(--r); padding: .9rem; background: #fff; }
.operator-head { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-bottom: .5rem; }
.operator-card .kv { font-size: .9rem; }

/* ================= 團頁 ================= */
.group-head { padding-top: 1.25rem; }
.group-top { display: flex; gap: 1.1rem; align-items: stretch; margin-bottom: 1.25rem; }
.group-top-text { min-width: 0; display: flex; flex-direction: column; justify-content: center; }
.group-top-text .serif-title { font-size: 1.6rem; margin: 0 0 .3rem; line-height: 1.35; overflow-wrap: anywhere; }
.group-top-text .page-lead { font-size: .92rem; margin-bottom: .35rem; }
.group-top .chip-row { margin-bottom: .45rem; }
.group-head > .kv { border-top: 1px solid var(--line-soft); padding-top: 1.1rem; }
.group-desc { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--line-soft); }
.group-desc .sub { margin-top: 0; }
.group-desc p { white-space: pre-wrap; overflow-wrap: anywhere; max-width: 40em; }
.group-actions { flex-direction: row; flex-wrap: wrap; align-items: center; padding-top: 1.1rem; border-top: 1px solid var(--line-soft); }
.member-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.member { display: flex; align-items: center; gap: .7rem; padding: .7rem 0; border-bottom: 1px solid var(--line-soft); }
.member:last-child { border-bottom: 0; }
.member-name { font-weight: 700; overflow-wrap: anywhere; }
.member-body { flex: 1; min-width: 0; }
.member-line { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem .45rem; }
.member-intro { margin: .15rem 0 0; font-size: .85rem; color: var(--ink-soft); line-height: 1.55; overflow-wrap: anywhere; }
.btn-kick { color: var(--danger); }
.btn-car { margin-left: auto; }
.transport-edit { display: inline-flex; align-items: center; gap: .4rem; flex-wrap: wrap; }
.transport-select { width: auto; padding: .25rem 2rem .25rem .6rem; font-size: .9rem; min-height: 34px; }
.join-panel { flex: 1 1 100%; border: 1px solid var(--line); border-radius: var(--r); padding: 1.1rem 1.15rem; background: var(--field); margin-top: .25rem; }
.join-panel-title { font-family: var(--serif); font-weight: 700; font-size: 1.1rem; color: var(--forest-ink); margin-bottom: .75rem; }
.join-panel .field { max-width: 30rem; }
.join-panel .notice { margin-bottom: .85rem; }
.join-panel .check { margin-bottom: .5rem; }
.join-panel .check + .hint { margin: 0 0 .85rem; }
.ride-note { margin: 1rem 0 0; }
.origin-edit { margin: .6rem 0 .75rem; }
.btn-edit-origin { margin-top: .75rem; }
@media (max-width: 479px) {
  .ticket-big { width: 84px; min-height: 120px; }
  .ticket-big .ticket-card { width: 60px; }
  .group-top { gap: .85rem; }
  .group-top-text .serif-title { font-size: 1.35rem; }
}

/* ================= 我的團／說明 ================= */
.profile-head { display: flex; align-items: center; gap: .85rem; margin-bottom: .85rem; }
.profile-head h2 { margin: 0; font-size: 1.35rem; }
.profile-head p { margin: 0; }
.email-status { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.me-section { margin: 2rem 0 0; }
.me-page .state-empty + .btn { margin-top: .75rem; }
.about-card { padding: 1.35rem 1.25rem; }
.about-title { font-family: var(--serif); font-size: 1.2rem; display: flex; align-items: center; gap: .6rem; margin-bottom: .75rem; }
.about-list { margin: 0; padding-left: 1.1rem; color: var(--ink); }
.about-list li { margin-bottom: .5rem; line-height: 1.75; }
.about-list li::marker { color: var(--sage-line); }

/* ---- 出發地多選（origin-picker） ---- */
.origin-picker-box { margin-bottom: .75rem; }
.op-hint { margin: 0 0 .6rem; }
.origin-picker { border: 1px solid var(--line); border-radius: var(--r); background: var(--field); padding: .75rem; }
.op-head { display: flex; align-items: flex-start; gap: .5rem; margin-bottom: .6rem; }
.op-chips { flex: 1; display: flex; flex-wrap: wrap; gap: .35rem; min-height: 30px; }
.op-empty { font-size: .9rem; line-height: 30px; }
.op-chip { display: inline-flex; align-items: center; gap: .2rem; background: var(--forest); color: #fff; border-radius: 999px; padding: .1rem .2rem .1rem .7rem; font-size: .85rem; font-weight: 600; line-height: 1.6; }
.op-chip-x { font: inherit; border: 0; background: transparent; color: #fff; cursor: pointer; width: 24px; height: 24px; border-radius: 50%; line-height: 1; font-size: 1rem; display: inline-flex; align-items: center; justify-content: center; }
.op-chip-x:hover { background: rgba(255, 255, 255, .18); }
.op-count { flex: 0 0 auto; font-size: .85rem; color: var(--ink-soft); white-space: nowrap; line-height: 30px; }
.op-count-full { color: #8a5a22; font-weight: 700; }
.op-search { margin-bottom: .6rem; min-height: 42px; background-color: #fff; }
.op-list { max-height: 360px; overflow-y: auto; padding-top: .1rem; }
.op-region { border: 1px solid var(--line); border-radius: var(--r-sm); margin: 6px 0; background: #fff; }
.op-region > summary { padding: 10px 12px; cursor: pointer; font-weight: 700; color: var(--forest-ink); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; list-style: none; }
.op-region > summary::-webkit-details-marker { display: none; }
.op-region > summary::before { content: ""; width: 7px; height: 7px; border-right: 2px solid var(--ink-soft); border-bottom: 2px solid var(--ink-soft); transform: rotate(-45deg); transition: transform .15s; flex: none; margin-right: 4px; }
.op-region[open] > summary::before { transform: rotate(45deg); }
.op-region > summary .muted { font-weight: 400; font-size: 12px; }
.op-region-body { padding: 0 8px 8px; }
.op-region-body .op-county { margin-left: 4px; }
.op-county { border-bottom: 1px solid var(--line-soft); }
.op-county:last-child { border-bottom: 0; }
.op-county summary { cursor: pointer; padding: .5rem .25rem; display: flex; align-items: center; gap: .5rem; font-weight: 600; list-style: none; }
.op-county summary::-webkit-details-marker { display: none; }
.op-county summary::before { content: '›'; display: inline-block; transition: transform .15s; color: var(--ink-soft); width: 1em; }
.op-county[open] summary::before { transform: rotate(90deg); }
.op-county-badge { font-size: .75rem; background: var(--sage); color: var(--forest); border-radius: 999px; padding: 0 .5rem; font-weight: 700; }
.op-county-body { padding: 0 .25rem .6rem 1.25rem; }
.op-item { display: flex; align-items: center; gap: .45rem; font-size: .92rem; padding: .25rem .25rem; border-radius: var(--r-sm); cursor: pointer; min-height: 34px; }
.op-item:hover { background: var(--field); }
.op-item input { width: 18px; height: 18px; min-height: 0; margin: 0; flex: 0 0 auto; accent-color: var(--forest); }
.op-item input:disabled + span { color: var(--ink-faint); }
.op-item-all { font-weight: 700; color: var(--forest-ink); margin-bottom: .2rem; }
.op-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 .5rem; }
@media (min-width: 720px) { .op-grid { grid-template-columns: repeat(4, 1fr); } .op-list { max-height: 420px; } }
.op-nomatch { padding: .75rem .25rem; }

/* ---- 頁尾 ---- */
.footer { margin-top: auto; }
.footer-inner { max-width: 912px; margin: 0 auto; padding: 0 16px 2.25rem; }
.footer-row { display: flex; align-items: center; gap: 1.1rem; border-top: 1px solid var(--line); padding-top: 2rem; margin-bottom: 1.25rem; }
.logo-foot { margin: 0; }
.logo-foot .logo-text { font-size: 1.35rem; }
.logo-foot .logo-mark { width: 16px; height: 20px; }
.footer-tag { margin: 0; color: var(--ink-soft); font-size: .92rem; line-height: 1.75; }
.footer-link { display: inline-block; color: var(--forest-ink); font-size: .9rem; text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 5px; }


@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
.ticket-big .ticket-trail::before, .ticket-big .ticket-trail::after { height: 46px; }

/* ---- 約定卡：行程線 ---- */
.gcard-trip { display: flex; flex-wrap: wrap; align-items: center; gap: .15rem .4rem; margin: .1rem 0 .15rem; color: var(--forest-ink); font-size: .92rem; font-weight: 500; }
.gcard-trip .trip-arrow { color: var(--amber-2); font-weight: 700; }
.gcard-trip .trip-type { font-size: .72rem; font-weight: 600; padding: .05rem .45rem; border-radius: 999px; margin-left: .15rem; }
.gcard-trip .trip-round { background: var(--sage); color: var(--forest-2); }
.gcard-trip .trip-oneway { background: var(--amber-tint); color: #8a5a1f; }
.field .field-label { font-size: .875rem; color: var(--ink-soft); }
.trip-preview { color: var(--forest-2); margin-top: -.2rem; }

/* ---- 日期票根：路線代表照 ---- */
.ticket-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.ticket-photo::after { content: ""; position: absolute; inset: 0; z-index: 0; background: linear-gradient(180deg, rgba(20,40,32,.05) 0%, rgba(20,40,32,.35) 100%); pointer-events: none; }
.ticket-photo .ticket-trail { display: none; }
.ticket-photo .ticket-card { box-shadow: 0 1px 4px rgba(0,0,0,.18); }
.result-note { scroll-margin-top: 136px; }
/* ---- 探索頁：依分類分段 ---- */
.cat-section-title { font-family: var(--serif); font-size: 1.15rem; color: var(--forest); margin: 1.4rem 0 .5rem; padding-bottom: .35rem; border-bottom: 1px solid var(--line); }
.cat-section-title:first-child { margin-top: .4rem; }
.cat-section-title .muted { font-family: inherit; font-size: .85rem; font-weight: 400; }

/* ---------- 評價與信用紀錄 ---------- */
.badge-new { background: var(--warn-bg); color: var(--warn-ink); font-weight: 700; }
.badge-trust { background: #fff; color: var(--forest-2); box-shadow: inset 0 0 0 1px var(--sage-line); }
.badge-praise { background: var(--sage); color: var(--forest); gap: .3rem; }
.badge-report { background: var(--danger-tint); color: var(--danger); }
.praise-n { font-weight: 700; }
.gcard-host .badge { font-size: .72rem; padding: 0 .45rem; vertical-align: 1px; }
.trust-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .5rem; }
@media (max-width: 560px) { .trust-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.trust-stat { display: flex; flex-direction: column; gap: .1rem; background: var(--panel); border-radius: var(--r-sm); padding: .65rem .8rem; min-width: 0; }
.trust-stat.is-warn { background: var(--warn-bg); }
.trust-num { font-family: var(--serif); font-size: 1.15rem; font-weight: 700; color: var(--forest-ink); line-height: 1.35; }
.trust-stat.is-warn .trust-num { color: var(--warn-ink); }
.trust-key { font-size: .8rem; color: var(--ink-soft); }
.trust .notice { margin: .85rem 0 0; }
.trust-tags { display: flex; flex-wrap: wrap; gap: .35rem; margin: .85rem 0 0; }
.trust .hint { margin-top: .75rem; }
.trust-card-head { display: flex; justify-content: space-between; align-items: baseline; gap: .75rem; flex-wrap: wrap; }
.me-trust { border-top: 1px solid var(--line-soft); margin-top: 1rem; padding-top: .25rem; }
.me-trust .sub { display: flex; align-items: center; gap: .5rem; }
.profile-name { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin: 0; }
.profile-name .badge { font-family: var(--font); }
.user-note { margin-top: 1rem; }
.member-name { color: var(--forest-ink); }
a.member-name:hover { color: var(--link-hover); }
.review-card { border-color: var(--amber-2); }
.review-lead { margin: 0 0 .25rem; color: var(--ink-soft); font-size: .92rem; }
.review-list { list-style: none; margin: 0; padding: 0; }
.review-target { padding: 1rem 0; border-bottom: 1px solid var(--line-soft); }
.review-target:last-child { border-bottom: 0; }
.review-head { display: flex; align-items: center; gap: .5rem; margin-bottom: .6rem; }
.tag-picks { display: flex; flex-wrap: wrap; gap: .4rem; }
.check.check-sm { padding: .25rem .8rem; min-height: 36px; font-size: .88rem; }
.check.check-neg:has(input:checked) { background: var(--danger-tint); border-color: var(--danger); }
.review-report { margin-top: .6rem; }
.review-report summary { cursor: pointer; font-size: .85rem; color: var(--ink-soft); width: fit-content; }
.review-report summary:hover { color: var(--link-hover); }
.review-report[open] .tag-picks { margin-top: .5rem; }
.review-mine, .review-their { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; font-size: .88rem; }
.review-their { margin: .6rem 0 0; color: var(--ink-soft); }
.review-label { font-weight: 700; color: var(--ink); margin-right: .15rem; }
.review-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; border-top: 1px solid var(--line-soft); padding-top: 1rem; }
.review-actions .hint { margin: 0; }
.me-section > .hint { margin: -.35rem 0 .9rem; }
.trust-again { display: flex; flex-wrap: wrap; align-items: baseline; gap: .35rem; margin: .85rem 0 0; font-size: .92rem; }
.trust-again-key { font-weight: 700; color: var(--forest-ink); }
.trust-again-num { font-family: var(--serif); font-size: 1.15rem; color: var(--forest-ink); }
.restrict-line { margin: 0; }
.restrict-line + .restrict-line { margin-top: .3rem; }
.report-row { margin-top: .75rem; text-align: right; }
.report-btn { font-size: .85rem; color: var(--ink-soft); }
.report-btn:hover { color: var(--danger); }
.report-done { text-align: right; }
.radio-col { display: flex; flex-direction: column; gap: .4rem; margin: .75rem 0 0; }
.radio-col .check input { accent-color: var(--danger); }
.hidden-note { margin: 0 0 1rem; }
.report-panel { text-align: left; margin-top: .5rem; }
.trust-pending { margin: .75rem 0 0; }
.nav-links a[hidden] { display: none; }

/* ---------- 徽章 ---------- */
.emblem { display: block; flex: none; overflow: visible; }
.emblem text { font-family: var(--font); font-weight: 700; }
.emblem .e-inner { fill: none; }
.emblem .e-snow { fill: #fff; }
.emblem-b .e-base { fill: #234a3c; stroke: #d9a566; stroke-width: 2.5; }
.emblem-b .e-inner { stroke: rgba(255, 255, 255, .22); stroke-width: 1; }
.emblem-b .e-mtn { fill: #4f8a6f; }
.emblem-b .e-no { fill: #f6d9a8; font-size: 8.5px; }
.emblem-b .e-kind { fill: rgba(255, 255, 255, .78); font-size: 6.5px; letter-spacing: .5px; }
.emblem-x .e-base { fill: #c98a45; stroke: #8a5a24; stroke-width: 2; }
.emblem-x .e-inner { stroke: rgba(255, 255, 255, .38); stroke-width: 1; }
.emblem-x .e-mtn { fill: #2f5c4b; }
.emblem-x .e-snow { fill: #f6ead6; }
.emblem-x .e-no { fill: #fff; font-size: 8.5px; }
.emblem-x .e-kind { fill: rgba(255, 255, 255, .9); font-size: 6.5px; }
.emblem-series .e-base { fill: #1f3a30; stroke: #d9a566; stroke-width: 3; }
.emblem-series .e-inner { stroke: rgba(217, 165, 102, .55); stroke-width: .9; }
.emblem-series .e-mtn { fill: #d9a566; }
.emblem-series .e-title { fill: #f6d9a8; font-family: var(--serif); font-size: 11px; letter-spacing: 1px; }
.emblem-medal .e-num { font-family: var(--serif); font-size: 18px; }
.emblem-medal .e-kind { font-size: 6.5px; }
.emblem-medal-b .e-base { fill: #234a3c; stroke: #d9a566; stroke-width: 3; }
.emblem-medal-b .e-inner { stroke: rgba(217, 165, 102, .6); stroke-width: 1; }
.emblem-medal-b .e-num, .emblem-medal-b .e-kind { fill: #f6d9a8; }
.emblem-medal-b .e-ribbon { fill: #a8571a; } .emblem-medal-b .e-ribbon-2 { fill: #c4733a; }
.emblem-medal-x .e-base { fill: #c98a45; stroke: #8a5a24; stroke-width: 2.5; }
.emblem-medal-x .e-inner { stroke: rgba(255, 255, 255, .45); stroke-width: 1; }
.emblem-medal-x .e-num, .emblem-medal-x .e-kind { fill: #fff; }
.emblem-medal-x .e-ribbon { fill: #2f5c4b; } .emblem-medal-x .e-ribbon-2 { fill: #4f7a64; }
.is-locked .emblem { filter: grayscale(1); opacity: .32; }

.badge-wall-head { display: flex; justify-content: space-between; align-items: flex-end; gap: .5rem 1rem; flex-wrap: wrap; }
.badge-wall-head .card-title { margin: 0; }
.badge-stats { display: flex; flex-wrap: wrap; gap: .25rem 1rem; margin: 0; font-size: .88rem; color: var(--ink-soft); }
.badge-stats b { font-family: var(--serif); font-size: 1.15rem; color: var(--forest-ink); }
.badge-h { margin: 1.4rem 0 .65rem; }
.series-grid, .medal-row, .badge-grid { list-style: none; margin: 0; padding: 0; }
.series-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr)); gap: .75rem; }
.series-card { display: flex; gap: .85rem; align-items: center; background: var(--panel); border-radius: var(--r); padding: .8rem .9rem; min-width: 0; }
.series-body { display: flex; flex-direction: column; gap: .45rem; min-width: 0; flex: 1; }
.series-title { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; }
.series-title b { font-family: var(--serif); font-size: 1.05rem; color: var(--forest-ink); }
.series-count { font-size: .82rem; color: var(--ink-soft); font-weight: 700; }
.series-card:not(.is-locked) .series-count { color: var(--link-hover); }
.progress { display: block; height: 6px; background: #fff; border-radius: 99px; overflow: hidden; }
.progress-fill { display: block; height: 100%; background: var(--amber-2); border-radius: 99px; }
.series-peaks { display: flex; flex-wrap: wrap; gap: .3rem; }
.series-peak { font-size: .76rem; padding: .05rem .5rem; border-radius: 99px; background: #fff; color: var(--ink-faint); }
.series-peak.on { background: var(--sage-2); color: var(--forest); font-weight: 700; }
.medal-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: .75rem .4rem; }
.badge-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 1rem .4rem; }
.badge-grid-sm { grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: .8rem .3rem; }
.badge-item { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; min-width: 0; }
.badge-name { margin-top: .35rem; font-size: .84rem; font-weight: 700; color: var(--forest-ink); line-height: 1.3; word-break: keep-all; overflow-wrap: anywhere; }
.badge-sub { font-size: .72rem; color: var(--ink-soft); }
.badge-item.is-locked .badge-name { color: var(--ink-faint); font-weight: 500; }
.badge-grid-sm .badge-name { font-size: .78rem; }
.badge-new-dot { position: absolute; top: -4px; right: calc(50% - 40px); background: var(--danger); color: #fff; font-size: .66rem; font-weight: 700; border-radius: 99px; padding: 0 .38rem; line-height: 1.5; }
.badge-all { margin-top: 1.25rem; border-top: 1px solid var(--line-soft); padding-top: .9rem; }
.badge-all summary { cursor: pointer; font-weight: 700; color: var(--forest); width: fit-content; }
.badge-all summary:hover { color: var(--link-hover); }
.badge-all-h { margin: 1.1rem 0 .65rem; font-size: .95rem; color: var(--ink-soft); }
.badge-wall .hint { margin-top: 1rem; }
.route-badges .badge-grid { margin-top: .5rem; }
.medal-row + .medal-row { margin-top: .9rem; padding-top: .9rem; border-top: 1px dashed var(--line); }
.route-series { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; margin: .9rem 0 0; font-size: .88rem; color: var(--ink-soft); }
@media (max-width: 480px) { .badge-grid { grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); } }

/* 徽章插畫（badge-art.js） */
.emblem-art .e-frame { stroke-width: 2.6; }
.emblem-art.emblem-b .e-frame { stroke: #d9a566; }
.emblem-art.emblem-x .e-frame { stroke: #9a6530; }
.emblem-art .e-ring { stroke: rgba(255, 255, 255, .55); stroke-width: .8; }
.emblem-art.emblem-b .e-band { fill: #1f3a30; }
.emblem-art.emblem-x .e-band { fill: #7a4f22; }
.emblem-art .e-no { font-size: 6.4px; font-weight: 700; letter-spacing: .3px; }
.emblem-art.emblem-b .e-no { fill: #f6d9a8; }
.emblem-art.emblem-x .e-no { fill: #fff3e0; }
.emblem-series .e-frame { stroke: #d9a566; stroke-width: 3; }
.emblem-series .e-band { fill: #1f3a30; stroke: #d9a566; stroke-width: .8; }
.emblem-series .e-title { fill: #f6d9a8; font-family: var(--serif); font-size: 7.4px; font-weight: 700; letter-spacing: .6px; }
.emblem-medal .e-icon { color: #5a3a1e; }
.emblem-medal .e-band { fill: rgba(0, 0, 0, .28); }
.emblem-medal .e-num { fill: #fff; font-family: var(--serif); font-size: 7px; font-weight: 700; }
.emblem-medal .e-inner { fill: none; stroke-width: 1; }
.medal-bronze .e-base { fill: #c98a52; stroke: #8a5a2c; stroke-width: 2.4; } .medal-bronze .e-inner { stroke: #f0c08e; } .medal-bronze .e-icon { color: #6a3c18; }
.medal-silver .e-base { fill: #c9d1d6; stroke: #7f8b93; stroke-width: 2.4; } .medal-silver .e-inner { stroke: #f2f6f8; } .medal-silver .e-icon { color: #3f4b54; }
.medal-gold .e-base { fill: #e6bd5a; stroke: #a07a22; stroke-width: 2.4; } .medal-gold .e-inner { stroke: #fff0b8; } .medal-gold .e-icon { color: #6a4a10; }
.medal-platinum .e-base { fill: #2f5c4b; stroke: #d9a566; stroke-width: 3; } .medal-platinum .e-inner { stroke: #f6d9a8; } .medal-platinum .e-icon { color: #f6d9a8; }
.medal-b .e-ribbon { fill: #2f5c4b; } .medal-b .e-ribbon-2 { fill: #3f7a63; }
.medal-x .e-ribbon { fill: #a8571a; } .medal-x .e-ribbon-2 { fill: #c4733a; }
.badge-src { margin-top: .15rem; font-size: .66rem; font-weight: 700; padding: 0 .4rem; border-radius: 99px; line-height: 1.6; }
.badge-src-team { background: var(--sage-2); color: var(--forest); }
.badge-src-gpx { background: var(--amber-tint); color: #8a4a14; }
.badge-grid-sm .badge-src { display: none; }
.gpx-box { margin-top: 1.25rem; border-top: 1px solid var(--line-soft); padding-top: .25rem; }
.gpx-lead { margin: 0 0 .5rem; font-size: .92rem; color: var(--ink-soft); }
.gpx-rules { margin: 0 0 .85rem; padding-left: 1.2rem; font-size: .85rem; color: var(--ink-soft); }
.gpx-rules li + li { margin-top: .15rem; }
.gpx-row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.gpx-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.gpx-row label.btn:focus-within, .gpx-input:focus + * { box-shadow: var(--focus); }
.gpx-fname { font-size: .85rem; min-width: 0; overflow-wrap: anywhere; }
.gpx-result .notice { margin: .75rem 0 0; }
.notice-ok { background: var(--sage); color: var(--forest-ink); }

/* ---------- 分享卡（揪團文案） ---------- */
.share-card { border-color: var(--sage-line); }
.share-card.share-new { border: 2px solid var(--forest); box-shadow: var(--shadow-float); }
.share-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem; }
.share-head .card-title { margin-bottom: .5rem; }
.badge-seat { background: var(--amber-tint); color: #7a4f12; font-weight: 700; white-space: nowrap; }
.share-lead { color: var(--ink-soft); font-size: .92rem; line-height: 1.7; margin: 0 0 .75rem; max-width: 42rem; }
.share-text { width: 100%; font: inherit; font-size: .9rem; line-height: 1.7; padding: .8rem .9rem; background: var(--field); border: 1px solid var(--line); border-radius: var(--r-sm); color: var(--ink); resize: vertical; white-space: pre-wrap; }
.share-text:focus { outline: none; box-shadow: var(--focus); border-color: var(--forest); }
.share-actions { margin: .75rem 0 1rem; flex-wrap: wrap; }
.share-sub { font-size: .8rem; color: var(--ink-soft); margin: 0 0 .4rem; }
.share-preview { display: grid; grid-template-columns: 96px 1fr; max-width: 26rem; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; background: #fff; }
.share-preview-img { width: 96px; height: 100%; min-height: 96px; object-fit: cover; display: block; }
.share-preview-blank { background: var(--sage); }
.share-preview-body { padding: .6rem .8rem; min-width: 0; }
.share-preview-title { font-weight: 700; font-size: .9rem; color: var(--ink); margin: 0 0 .2rem; line-height: 1.45; }
.share-preview-desc { font-size: .8rem; color: var(--ink-soft); margin: 0 0 .25rem; line-height: 1.5; }
.share-preview-host { font-size: .72rem; color: var(--ink-faint); margin: 0; }
.share-card .hint { margin: .6rem 0 0; }
.share-details > summary { cursor: pointer; list-style: none; }
.share-details > summary::-webkit-details-marker { display: none; }
.share-details > summary .card-title::after { content: " ＋"; color: var(--ink-faint); font-family: var(--font); font-size: .95rem; }
.share-details[open] > summary .card-title::after { content: " －"; }
.share-details[open] > summary { margin-bottom: .5rem; }
.login-first { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem 1rem; margin-bottom: 1rem; }

/* ---------- 首頁熱門路線快捷 ---------- */
.hot-routes { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; margin-bottom: 1rem; }
.hot-label { font-size: .8rem; font-weight: 700; color: var(--eyebrow); letter-spacing: .08em; margin-right: .2rem; }
.hot-chip { font: inherit; font-size: .88rem; padding: .32rem .85rem; border-radius: 999px; border: 1px solid var(--sage-line); background: #fff; color: var(--forest-ink); cursor: pointer; }
.hot-chip:hover { background: var(--sage); }
.hot-chip:focus-visible { outline: none; box-shadow: var(--focus); }
.hot-chip[aria-pressed="true"] { background: var(--forest); border-color: var(--forest); color: #fff; }

/* ---------- 首頁關鍵字搜尋 ---------- */
.search-grid .span-all { grid-column: 1 / -1; }
.kw-wrap { position: relative; }
.kw-wrap input { padding-left: 2.4rem; }
.kw-icon { position: absolute; left: .85rem; top: 50%; width: 15px; height: 15px; transform: translateY(-60%); border: 2px solid var(--ink-soft); border-radius: 50%; pointer-events: none; }
.kw-icon::after { content: ""; position: absolute; width: 2px; height: 7px; background: var(--ink-soft); right: -4px; bottom: -6px; transform: rotate(-45deg); border-radius: 1px; }
.map-kw { margin-bottom: 1rem; max-width: 34rem; }
/* 關鍵字搜尋中：區域／縣市／分類暫不套用，淡化顯示（點了會清掉關鍵字） */
.map-filters.is-searching .pills, .map-filters.is-searching .county-row, .map-filters.is-searching .filter-note:not(.result-note) { opacity: .45; }
.map-filters.is-searching .pill.active { background: #fff; color: var(--forest-ink); border-color: var(--sage-line); }
.map-legend i { box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); }

/* ---------- 徽章 v2（復古布章風格） ---------- */
.emblem-v2 { display: block; flex: none; overflow: visible; }
.is-locked .emblem-v2 { filter: grayscale(1); opacity: .32; }

/* ---------- 路線選擇面板（route-picker.js）：搜尋框在第一列，下面北中南東，點地區才展開 ---------- */
.rp { position: relative; }
.rp-trigger { display: flex; align-items: center; width: 100%; min-height: 46px; padding: .55rem 2.6rem .55rem .8rem; font: inherit; text-align: left; color: var(--ink); background: var(--field); border: 1px solid var(--line); border-radius: var(--r-sm); cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-soft) 50%), linear-gradient(135deg, var(--ink-soft) 50%, transparent 50%); background-position: calc(100% - 18px) 52%, calc(100% - 13px) 52%; background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; }
.rp-trigger:focus-visible, .rp.is-open .rp-trigger { outline: none; border-color: var(--forest); box-shadow: var(--focus); background-color: #fff; }
.rp-value { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-value.is-empty { color: var(--ink-soft); }
.rp-clear { position: absolute; right: 2rem; top: 23px; transform: translateY(-50%); width: 28px; height: 28px; border: 0; border-radius: 99px; background: transparent; color: var(--ink-soft); font-size: 1.2rem; line-height: 1; cursor: pointer; }
.rp-clear:hover { background: var(--panel); color: var(--ink); }
.rp-panel { position: absolute; z-index: 40; top: calc(100% + 8px); left: 0; width: min(560px, 100%); background: #fff; border-radius: 16px; box-shadow: var(--shadow-float); border: 1px solid var(--line); padding: 1rem 1rem .75rem; display: flex; flex-direction: column; max-height: min(70vh, 580px); }
.rp-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: .75rem; }
.rp-title { margin: 0; font-weight: 700; font-size: 1.05rem; color: var(--ink); }
.rp-close { width: 36px; height: 36px; border: 0; background: transparent; font-size: 1.6rem; line-height: 1; color: var(--ink-soft); cursor: pointer; border-radius: 99px; }
.rp-close:hover { background: var(--panel); color: var(--ink); }
.rp-search-wrap { margin-bottom: .75rem; flex: none; }
.rp-search { background: #fff; }
.rp-body { overflow-y: auto; overscroll-behavior: contain; display: flex; flex-direction: column; gap: .5rem; padding-bottom: .25rem; }
.rp-region { display: flex; align-items: center; gap: .6rem; width: 100%; padding: .85rem 1rem; border: 0; border-radius: 10px; background: #eef4ef; color: var(--forest-ink); font: inherit; font-weight: 700; cursor: pointer; text-align: left; }
.rp-region:hover { background: var(--sage); }
.rp-region:focus-visible { outline: none; box-shadow: var(--focus); }
.rp-region-count { font-size: .8rem; font-weight: 500; color: var(--ink-soft); margin-left: auto; }
.rp-chev { width: 9px; height: 9px; border-right: 2px solid var(--forest); border-bottom: 2px solid var(--forest); transform: rotate(45deg) translate(-2px, -2px); transition: transform .15s; }
.rp-region[aria-expanded="true"] .rp-chev { transform: rotate(225deg) translate(-2px, -2px); }
.rp-region[aria-expanded="true"] { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.rp-list { display: flex; flex-direction: column; padding: .25rem .25rem .5rem; border: 1px solid #eef4ef; border-top: 0; border-radius: 0 0 10px 10px; }
.rp-results { border: 0; padding: 0; }
.rp-cat { margin: .6rem .75rem .2rem; font-size: .76rem; font-weight: 700; color: var(--ink-faint); letter-spacing: .05em; }
.rp-opt { display: flex; align-items: baseline; justify-content: space-between; gap: .75rem; width: 100%; padding: .55rem .75rem; border: 0; border-radius: 8px; background: transparent; font: inherit; color: var(--ink); text-align: left; cursor: pointer; min-height: 40px; }
.rp-opt:hover, .rp-opt:focus-visible { background: var(--field); outline: none; }
.rp-opt.is-selected { background: var(--sage); font-weight: 700; color: var(--forest-ink); }
.rp-opt-sub { font-size: .8rem; color: var(--ink-soft); white-space: nowrap; flex: none; }
.rp-empty { margin: .5rem; color: var(--ink-soft); font-size: .9rem; }
@media (max-width: 560px) {
  .rp-panel { position: fixed; inset: auto 0 0 0; top: 12vh; width: auto; max-height: none; border-radius: 18px 18px 0 0; padding: 1rem 16px calc(1rem + env(safe-area-inset-bottom)); box-shadow: 0 0 0 100vmax rgba(20, 30, 25, .4); z-index: 60; }
}
.map-legend .rg-dot-north { background: var(--rg-north); }
.map-legend .rg-dot-central { background: var(--rg-central); }
.map-legend .rg-dot-south { background: var(--rg-south); }
.map-legend .rg-dot-east { background: var(--rg-east); }
