/* CampingSite styles. Earthy palette: eucalypt green, ochre, sand, night-sky navy. */
:root {
  --brand: #2f7d4f;
  --brand-dark: #1f3b2d;
  --accent: #d9822b;
  --accent-2: #f2b134;
  --sand: #f3e9d2;
  --bg: #fbf8f2;
  --surface: #ffffff;
  --surface-2: #f4efe4;
  --text: #1d2a22;
  --muted: #5f6b63;
  --line: #e3dccd;
  --ok: #2f7d4f;
  --warn: #b26a00;
  --err: #b3261e;
  --shadow: 0 1px 2px rgba(31, 59, 45, .06), 0 6px 20px rgba(31, 59, 45, .08);
  --radius: 14px;
  --sky-top: #f6d6a8; --sky-bottom: #fbeed8; --sun: #f2b134;
  --hill-far: #9cb59c; --hill-near: #5f8f6a; --ground: #3f6b4c;
  --topbar-h: 60px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #5fbf86; --brand-dark: #0f1a14; --accent: #f0a050; --accent-2: #f2c25a; --sand: #e9dcc0;
    --bg: #0f1612; --surface: #17211b; --surface-2: #1d2a22; --text: #e8efe9; --muted: #9db0a3; --line: #2a3a30;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.35);
    --sky-top: #0d1b2a; --sky-bottom: #1b2f3f; --sun: #e9dcc0; --hill-far: #1f3b2d; --hill-near: #162b20; --ground: #0f1a14;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --brand: #5fbf86; --brand-dark: #0f1a14; --accent: #f0a050; --accent-2: #f2c25a; --sand: #e9dcc0;
  --bg: #0f1612; --surface: #17211b; --surface-2: #1d2a22; --text: #e8efe9; --muted: #9db0a3; --line: #2a3a30;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.35);
  --sky-top: #0d1b2a; --sky-bottom: #1b2f3f; --sun: #e9dcc0; --hill-far: #1f3b2d; --hill-near: #162b20; --ground: #0f1a14;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
body.no-scroll { overflow: hidden; }
a { color: var(--brand); text-underline-offset: 2px; }
a:hover { color: var(--accent); }
img { max-width: 100%; display: block; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.01em; margin: 0 0 .5em; }
h1 { font-size: clamp(1.7rem, 3.5vw, 2.6rem); }
h2 { font-size: 1.35rem; }
h3, .h3 { font-size: 1.08rem; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.tiny { font-size: .8rem; }
.hint { font-size: .88rem; color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; z-index: 100; border-radius: 8px; }
.skip:focus { left: 8px; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 460px; margin: 40px auto; }
.narrow-lg { max-width: 820px; }
.center-text { text-align: center; }
.section { margin: 48px 0; }
.section-title { font-size: 1.4rem; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
:focus-visible { outline: 3px solid var(--accent-2); outline-offset: 2px; }

/* ---------- Buttons, chips, forms ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid transparent;
  border-radius: 999px; padding: 10px 18px; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: background .15s, transform .1s, border-color .15s; white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #c46f1c; color: #fff; }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn-link { background: none; color: var(--brand); padding: 6px 0; }
.btn-sm { padding: 6px 12px; font-size: .9rem; }
.btn-block { width: 100%; margin-bottom: 8px; }
.btn:disabled { opacity: .6; cursor: wait; }
.icon-btn { background: none; border: 0; color: inherit; width: 38px; height: 38px; border-radius: 50%; cursor: pointer; display: inline-grid; place-items: center; font-size: 1rem; }
.icon-btn:hover { background: var(--surface-2); }
.chips, .quickbar { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 4px; padding: 7px 13px; border-radius: 999px; background: var(--surface);
  border: 1px solid var(--line); color: var(--text); text-decoration: none; font: inherit; font-size: .9rem; cursor: pointer; white-space: nowrap;
}
.chip:hover { border-color: var(--brand); color: var(--text); }
.chip[aria-pressed="true"] { background: var(--brand-dark); color: #fff; border-color: var(--brand-dark); }
:root[data-theme="dark"] .chip[aria-pressed="true"] { background: var(--brand); color: #0f1612; }
.badge { background: var(--accent); color: #fff; border-radius: 999px; font-size: .75rem; padding: 1px 7px; }
label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 12px; }
input, select, textarea {
  display: block; width: 100%; margin-top: 4px; padding: 10px 12px; font: inherit; font-weight: 400; color: var(--text);
  background: var(--surface); border: 1px solid var(--line); border-radius: 10px;
}
input:focus, select:focus, textarea:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 25%, transparent); }
input[type=checkbox], input[type=radio] { display: inline-block; width: auto; margin: 0 6px 0 0; accent-color: var(--brand); }
input[type=range] { padding: 0; accent-color: var(--accent); border: 0; background: none; }
label.check { display: flex; align-items: center; font-weight: 500; }
fieldset { border: 0; padding: 0; margin: 0 0 20px; }
legend { font-weight: 700; margin-bottom: 8px; display: flex; gap: 8px; align-items: baseline; }
.row3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0 12px; }
.form-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.notice { padding: 12px 16px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); margin: 12px 0; }
.notice-warn { background: color-mix(in srgb, var(--accent-2) 18%, var(--surface)); border-color: color-mix(in srgb, var(--accent-2) 50%, transparent); }
.notice-error { background: color-mix(in srgb, var(--err) 12%, var(--surface)); border-color: color-mix(in srgb, var(--err) 40%, transparent); }
.notice-ok { background: color-mix(in srgb, var(--ok) 12%, var(--surface)); border-color: color-mix(in srgb, var(--ok) 40%, transparent); }
.flash { position: fixed; top: calc(var(--topbar-h) + 12px); left: 50%; transform: translateX(-50%); z-index: 60; padding: 12px 18px; border-radius: 12px;
  background: var(--brand-dark); color: #fff; box-shadow: var(--shadow); max-width: min(560px, calc(100% - 32px)); transition: opacity .4s; }
:root[data-theme="dark"] .flash { background: var(--surface-2); color: var(--text); }
.flash-error { background: var(--err); color: #fff; }
.flash-hide { opacity: 0; pointer-events: none; }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40; height: var(--topbar-h); display: flex; align-items: center; gap: 20px; padding: 0 16px;
  background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--text); font-size: 1.2rem; letter-spacing: -.02em; }
.brand b { color: var(--accent); }
.brand-mark { width: 30px; height: 30px; }
.mainnav { display: flex; gap: 4px; }
.mainnav a { padding: 8px 12px; border-radius: 999px; text-decoration: none; color: var(--text); font-weight: 500; }
.mainnav a:hover, .mainnav a[aria-current] { background: var(--surface-2); color: var(--brand); }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.menu-btn { display: none; }
.mobile-menu { position: fixed; top: var(--topbar-h); left: 0; right: 0; z-index: 39; background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: var(--shadow); padding: 8px 16px 16px; }
.mobile-menu a { display: block; padding: 12px 4px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--text); font-weight: 600; }
@media (max-width: 800px) {
  .mainnav { display: none; }
  .menu-btn { display: inline-grid; }
}

/* ---------- Home ---------- */
.hero { position: relative; overflow: hidden; padding: 64px 0 140px; }
.hero-bg { position: absolute; inset: 0; z-index: -1; }
.hero-bg svg { width: 100%; height: 100%; }
.hero-inner { max-width: 760px; text-align: center; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.3rem); color: var(--brand-dark); }
:root[data-theme="dark"] .hero h1 { color: var(--sand); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hero h1 { color: var(--sand); } }
.lede { font-size: 1.15rem; color: var(--muted); }
.hero .chips { justify-content: center; margin-top: 16px; }
.searchbox { position: relative; display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 6px 6px 6px 16px; box-shadow: var(--shadow); text-align: left; }
.searchbox input { border: 0; margin: 0; padding: 8px 4px; background: none; box-shadow: none !important; }
.sb-icon { color: var(--muted); flex: none; }
.ac-list { position: absolute; z-index: 50; left: 0; right: 0; top: calc(100% + 6px); list-style: none; margin: 0; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); max-height: 320px; overflow: auto; }
.ac-list li { padding: 10px 12px; border-radius: 10px; cursor: pointer; display: flex; gap: 8px; }
.ac-list li.active, .ac-list li:hover { background: var(--surface-2); }
.stats-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: -60px; position: relative; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; text-align: center; box-shadow: var(--shadow); }
.stat b { display: block; font-size: 1.6rem; color: var(--accent); }
.stat span { color: var(--muted); font-size: .9rem; }
@media (max-width: 700px) { .stats-row { grid-template-columns: repeat(2, 1fr); } }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin-top: 40px; }
.feature { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; text-decoration: none; color: var(--text); box-shadow: var(--shadow); transition: transform .15s; }
.feature:hover { transform: translateY(-2px); color: var(--text); border-color: var(--brand); }
.feature-icon { font-size: 2rem; }
.feature-wild { background: linear-gradient(160deg, #1f3b2d, #0f1a14); color: var(--sand); border-color: #1f3b2d; }
.feature-wild:hover { color: var(--sand); }
.feature-wild p { color: #cbd8cf; }
.cta-band, .info-band, .aff-band { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: center; background: var(--surface-2); border-radius: var(--radius); padding: 28px; margin: 40px 0; }
.cta-band p, .info-band p { margin: 0; color: var(--muted); }
.info-band > div:first-child { flex: 1 1 360px; }
.info-links { display: grid; gap: 8px; }
.aff-band.small { padding: 16px; display: block; margin: 16px 0; }
.aff-band.small a { display: inline-block; margin: 6px 12px 0 0; }
.aff-links { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 14px; }
.cards-compact { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .15s, transform .15s, box-shadow .15s; }
.card:hover { border-color: var(--brand); box-shadow: var(--shadow); }
.card-link { display: block; padding: 14px 16px; color: var(--text); text-decoration: none; }
.card-link:hover { color: var(--text); }
.card h3 { margin: 6px 0 4px; font-size: 1.02rem; }
.card-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.card-meta { font-size: .87rem; margin: 0 0 6px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; font-size: .82rem; }
.tags span { background: var(--surface-2); border-radius: 999px; padding: 2px 8px; }
.kind-pill { display: inline-block; white-space: nowrap; font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--kind, var(--brand));
  background: color-mix(in srgb, var(--kind, var(--brand)) 14%, transparent); border-radius: 999px; padding: 3px 9px; }
.kind-pill-soft { --kind: var(--muted); }
.price { font-weight: 700; font-size: .92rem; white-space: nowrap; }
.price-free { color: var(--ok); }
.stars { color: var(--accent-2); letter-spacing: 1px; }
.stars-off { color: var(--line); }
.fit { font-size: .76rem; font-weight: 700; border-radius: 999px; padding: 2px 8px; }
.fit-no { background: color-mix(in srgb, var(--err) 15%, transparent); color: var(--err); }
.fit-tight { background: color-mix(in srgb, var(--accent-2) 25%, transparent); color: var(--warn); }
.fit-ok { background: color-mix(in srgb, var(--ok) 15%, transparent); color: var(--ok); }

/* ---------- Trips, states, collections ---------- */
.trip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.trip-card { position: relative; overflow: hidden; display: block; padding: 22px; border-radius: var(--radius); color: #fff; text-decoration: none;
  background: linear-gradient(150deg, var(--trip), color-mix(in srgb, var(--trip) 55%, #000)); min-height: 150px; }
.trip-card:hover { color: #fff; transform: translateY(-2px); }
.trip-card h2, .trip-card h3 { margin: 6px 0; }
.trip-card p { margin: 0 0 6px; opacity: .92; }
.trip-card .muted { color: rgba(255, 255, 255, .85); }
.trip-km { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; opacity: .85; }
.state-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.state-tile { display: grid; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--text); }
.state-tile b { font-size: 1.4rem; color: var(--accent); }
.state-tile small { color: var(--muted); }
.state-tile:hover { border-color: var(--brand); color: var(--text); }
.collection-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.collection { display: grid; padding: 14px 16px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--text); }
.collection span { color: var(--muted); font-size: .88rem; }
.collection:hover { border-color: var(--brand); color: var(--text); }
.town-links { display: flex; flex-wrap: wrap; gap: 8px; }
.town-links a { padding: 6px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--text); font-size: .92rem; }
.town-links small { color: var(--muted); }
.town-links a:hover { border-color: var(--brand); }
.crumbs { font-size: .88rem; color: var(--muted); margin: 20px 0 12px; }
.crumbs a { color: var(--muted); }
.hub-head { margin: 24px 0; }
.hub-head .chips { margin-top: 12px; }
.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-weight: 700; font-size: .8rem; color: var(--accent); margin-bottom: 6px; }
.pager { display: flex; justify-content: center; gap: 20px; align-items: center; margin: 24px 0; }
.embedmap-wrap { position: relative; margin: 16px 0; }
.embedmap { height: 380px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--surface-2); }
.embedmap-open { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); box-shadow: var(--shadow); }

/* ---------- Guides / prose ---------- */
.guide-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.guide-card { display: block; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--text); }
.guide-card:hover { border-color: var(--brand); color: var(--text); }
.guide-icon { font-size: 2rem; }
.prose-wrap { max-width: 780px; }
.prose { font-size: 1.05rem; }
.prose h2 { margin-top: 1.6em; }
.prose li { margin-bottom: .4em; }
.prose table { width: 100%; border-collapse: collapse; font-size: .95rem; display: block; overflow-x: auto; }
.prose th, .prose td { text-align: left; padding: 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.route-list li { padding: 4px 0; }
.ad { margin: 24px 0; text-align: center; }
.ad-label { display: block; font-size: .7rem; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }

/* ---------- Wild camping ---------- */
.theme-wild .wild-hero { background: radial-gradient(ellipse at 70% 0%, #2a4a39 0%, #0f1a14 60%), #0f1a14; color: var(--sand); padding: 56px 0 48px; }
.wild-hero h1 { color: var(--sand); }
.wild-hero .lede { color: #c9d6cd; }
.wild-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.wild-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.link-list { display: flex; flex-wrap: wrap; gap: 6px 12px; }

/* ---------- Campsite page ---------- */
.cs-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: flex-end; margin-bottom: 16px; }
.cs-head h1 { margin: 8px 0 4px; }
.cs-head p { margin: 0; }
.cs-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.gallery { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: 160px 160px; gap: 6px; border-radius: var(--radius); overflow: hidden; margin-bottom: 20px; }
.gallery figure { margin: 0; position: relative; overflow: hidden; background: var(--line); }
.gallery a { display: block; overflow: hidden; height: 100%; }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.gallery .g-main { grid-row: span 2; }
.gallery-small { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)) !important; grid-template-rows: 280px !important; }
.gallery-small .g-main { grid-row: auto !important; grid-column: auto !important; }
@media (max-width: 700px) { .gallery { grid-template-columns: 1fr 1fr; grid-template-rows: 200px 110px; } .gallery .g-main { grid-column: span 2; grid-row: auto; } .gallery figure:nth-child(n+4) { display: none; } }
.cs-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 28px; align-items: start; }
@media (max-width: 960px) { .cs-grid { grid-template-columns: 1fr; } .cs-side { order: -1; } }
.cs-side { position: sticky; top: calc(var(--topbar-h) + 16px); display: grid; gap: 14px; }
@media (max-width: 960px) { .cs-side { position: static; } }
.side-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.side-card h3 { margin-bottom: 10px; }
.side-safety a { display: block; padding: 6px 0; text-decoration: none; }
.book-card { box-shadow: var(--shadow); }
.book-price { font-size: 1.4rem; margin-bottom: 12px; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; margin-bottom: 18px; }
.facts > div { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.facts span { display: block; font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; }
.facts b { font-size: 1.05rem; }
.facts small { display: block; color: var(--muted); }
.rigfit { padding: 10px 14px; border-radius: 10px; margin-bottom: 18px; font-weight: 600; }
.block { margin: 0 0 30px; }
.amenities { display: flex; flex-wrap: wrap; gap: 8px; }
.amen { padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: .92rem; }
.amen.no { color: var(--muted); text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--muted) 50%, transparent); }
.nearby-list { list-style: none; padding: 0; margin: 0 0 12px; display: grid; gap: 4px; }
.nearby-list li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.reports { list-style: none; padding: 0; margin: 0 0 12px; }
.reports li { padding: 10px 0; border-bottom: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.reports p { width: 100%; margin: 4px 0 0; }
.pill { background: var(--surface-2); border-radius: 999px; padding: 2px 10px; font-size: .86rem; }
.review { padding: 14px 0; border-bottom: 1px solid var(--line); }
.review header { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-bottom: 6px; }
.formbox { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 0; margin-top: 12px; }
.formbox summary { cursor: pointer; padding: 14px 18px; font-weight: 700; color: var(--brand); }
.formbox form, .formbox > p { padding: 0 18px 18px; }
.fix-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 0 12px; }
.rating-input { display: inline-flex; flex-direction: row-reverse; gap: 2px; margin-bottom: 12px; }
.rating-input input { position: absolute; opacity: 0; width: 1px; }
.rating-input label { font-size: 1.9rem; color: var(--line); cursor: pointer; margin: 0; }
.rating-input input:checked ~ label, .rating-input label:hover, .rating-input label:hover ~ label { color: var(--accent-2); }
.rating-input input:focus-visible + label { outline: 2px solid var(--accent-2); }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 6px; }
.thumbs img { aspect-ratio: 4/3; object-fit: cover; border-radius: 8px; width: 100%; }
.minimap { height: 220px; border-radius: 10px; overflow: hidden; margin-bottom: 6px; }
.site-marker { width: 22px; height: 22px; border-radius: 50%; background: var(--kind); border: 3px solid #fff; box-shadow: 0 2px 8px rgba(0,0,0,.35); }
.wx { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; text-align: center; font-size: .82rem; }
.wx-day { display: grid; gap: 2px; padding: 6px 0; border-radius: 8px; background: var(--surface-2); }
.wx-day b { font-size: 1.3rem; }
.stay22 { width: 100%; height: 360px; border: 0; border-radius: 10px; }
.source { margin: 24px 0 48px; }

/* ---------- Map app ---------- */
.app-page { overflow: hidden; }
.mapapp, .tripapp { display: grid; grid-template-columns: 420px 1fr; height: calc(100dvh - var(--topbar-h)); }
.panel { background: var(--bg); border-right: 1px solid var(--line); display: flex; flex-direction: column; overflow: hidden; z-index: 5; }
.panel-handle { display: none; }
.panel-search { padding: 14px 14px 8px; }
.panel .searchbox { box-shadow: none; }
.panel .quickbar { padding: 0 14px 10px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
.panel .quickbar::-webkit-scrollbar { display: none; }
.results-head { display: flex; justify-content: space-between; align-items: center; padding: 6px 14px 10px; font-weight: 600; font-size: .92rem; border-bottom: 1px solid var(--line); }
.sort { display: flex; align-items: center; gap: 6px; margin: 0; font-weight: 500; color: var(--muted); }
.sort select { width: auto; margin: 0; padding: 4px 8px; font-size: .88rem; }
.results { overflow-y: auto; padding: 12px 14px; display: grid; gap: 10px; align-content: start; flex: 1; }
.results-foot { padding: 0 14px 12px; font-size: .82rem; margin: 0; }
.card-row .card-link { padding: 12px 14px; }
.empty { text-align: center; padding: 30px 10px; color: var(--muted); }
.mapwrap { position: relative; }
.mapwrap .map { position: absolute; inset: 0; }
.map-tools { position: absolute; top: 90px; right: 10px; display: grid; gap: 6px; z-index: 3; }
.map-btn { width: 30px; height: 30px; border-radius: 6px; border: 0; background: #fff; box-shadow: 0 0 0 2px rgba(0,0,0,.1); cursor: pointer; font-size: 15px; }
.layers-pop { position: absolute; right: 38px; top: 36px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; box-shadow: var(--shadow); width: 190px; }
.layers-pop label { margin: 4px 0; font-weight: 500; display: flex; align-items: center; }
.search-area { position: absolute; top: 14px; left: 50%; transform: translateX(-50%); z-index: 3; box-shadow: var(--shadow); }
.legend { position: absolute; left: 10px; bottom: 28px; display: flex; flex-wrap: wrap; gap: 6px 12px; background: color-mix(in srgb, var(--surface) 92%, transparent); padding: 8px 12px; border-radius: 12px; font-size: .8rem; box-shadow: var(--shadow); max-width: calc(100% - 80px); z-index: 2; }
.legend span { display: inline-flex; align-items: center; gap: 5px; }
.legend i { width: 11px; height: 11px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.15); }
.legend-star { background: #f2b134; }
.me-dot { width: 18px; height: 18px; border-radius: 50%; background: #2b7bb9; border: 3px solid #fff; box-shadow: 0 0 0 6px rgba(43, 123, 185, .25); }

.filters-sheet { position: fixed; inset: 0; z-index: 70; background: rgba(10, 20, 14, .45); display: flex; justify-content: flex-start; }
.filters-sheet[hidden] { display: none; }
.filters-inner { background: var(--bg); width: min(460px, 100%); height: 100%; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.filters-head, .filters-foot { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.filters-head h2 { margin: 0; }
.filters-foot { border-top: 1px solid var(--line); border-bottom: 0; gap: 10px; }
.filters-foot .btn-primary { flex: 1; }
.filters-body { overflow-y: auto; padding: 18px; flex: 1; }
.checks { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 10px; }
.check { padding: 6px 0; margin: 0; cursor: pointer; }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg label { margin: 0; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; font-weight: 500; cursor: pointer; display: flex; align-items: center; }
.seg label:has(input:checked) { background: var(--brand-dark); color: #fff; border-color: var(--brand-dark); }
.seg input { position: absolute; opacity: 0; width: 1px; }
.rig-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: end; }
.rig-row label { display: flex; align-items: center; gap: 6px; margin: 0; }
.rig-row select { margin: 0; }
.rig-row input { width: 80px; margin: 0; }

/* Popups */
.maplibregl-popup-content { background: var(--surface); color: var(--text); border-radius: 14px; padding: 12px 14px; box-shadow: var(--shadow); }
.maplibregl-popup-tip { border-top-color: var(--surface) !important; border-bottom-color: var(--surface) !important; }
.maplibregl-popup-close-button { font-size: 18px; right: 4px; top: 2px; color: var(--muted); }
.pop { display: grid; gap: 4px; text-decoration: none; color: var(--text); font-size: .9rem; }
.pop:hover { color: var(--text); }
.pop b { font-size: 1rem; }
.pop-meta { color: var(--muted); }
.pop-amen { display: flex; gap: 4px; }
.pop-go { color: var(--accent); font-weight: 700; }

/* Trip planner */
.trip-panel { overflow-y: auto; }
.trip-form { padding: 16px; border-bottom: 1px solid var(--line); }
.trip-title { font-size: 1.4rem; }
.waypoints { display: grid; gap: 8px; }
.wp { display: flex; align-items: center; gap: 8px; position: relative; }
.wp-field { position: relative; flex: 1; }
.wp-field input { margin: 0; }
.wp-dot { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: .78rem; font-weight: 800; background: var(--surface-2); border: 2px solid var(--line); }
.wp-dot.start { background: var(--brand); color: #fff; border-color: var(--brand); }
.wp-dot.end { background: var(--accent); color: #fff; border-color: var(--accent); }
.wp-marker { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .8rem; background: var(--surface); border: 3px solid var(--muted); color: var(--text); box-shadow: 0 2px 8px rgba(0,0,0,.3); }
.wp-marker.start { background: var(--brand); border-color: #fff; color: #fff; }
.wp-marker.end { background: var(--accent); border-color: #fff; color: #fff; }
.trip-options { display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; margin: 12px 0 4px; }
.trip-options label { font-size: .85rem; }
.trip-options .check { grid-column: span 2; }
.tripapp .quickbar { margin: 4px 0 14px; }
.trip-error { color: var(--err); font-weight: 600; margin: 8px 0 0; }
.trip-results { padding: 16px; }
.trip-results .results { padding: 0; overflow: visible; }
.trip-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 8px; margin-bottom: 12px; }
.trip-stats div { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px; text-align: center; }
.trip-stats b { display: block; font-size: 1.15rem; color: var(--accent); }
.trip-stats span { font-size: .78rem; color: var(--muted); }
.trip-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.share-box { margin-bottom: 12px; }
.itin { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 10px; }
.itin li { display: grid; grid-template-columns: 56px 1fr; gap: 10px; align-items: start; }
.itin .day { background: var(--brand-dark); color: #fff; border-radius: 10px; padding: 6px 0; text-align: center; font-weight: 700; font-size: .8rem; }
:root[data-theme="dark"] .itin .day { background: var(--brand); color: #0f1612; }
.itin .card { margin-top: 6px; }

/* Mobile: bottom sheet over full-screen map */
@media (max-width: 800px) {
  .mapapp, .tripapp { grid-template-columns: 1fr; position: relative; }
  .mapwrap { position: absolute; inset: 0; }
  .panel {
    position: absolute; left: 0; right: 0; bottom: 0; height: 52%; border-right: 0; border-top: 1px solid var(--line);
    border-radius: 18px 18px 0 0; box-shadow: 0 -8px 24px rgba(0,0,0,.18); transition: height .25s ease;
  }
  .panel[data-sheet="peek"] { height: 150px; }
  .panel[data-sheet="full"] { height: calc(100% - 20px); }
  .panel-handle { display: grid; place-items: center; padding: 8px 0 2px; cursor: grab; }
  .panel-handle span { width: 44px; height: 5px; border-radius: 9px; background: var(--line); }
  .legend { display: none; }
  .map-tools { top: 80px; }
  .filters-inner { width: 100%; }
  .checks { grid-template-columns: 1fr; }
}

/* Account / admin */
.account-head { display: flex; justify-content: space-between; align-items: center; }
.account-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.rig-form { max-width: 420px; }
.plain-list { padding-left: 18px; }
.admin-item { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin-bottom: 10px; }
.admin-item pre { white-space: pre-wrap; font-size: .82rem; background: var(--surface-2); padding: 10px; border-radius: 8px; max-height: 260px; overflow: auto; }
.admin-actions { display: flex; gap: 8px; margin-top: 8px; }
.admin-photo { display: grid; gap: 4px; font-size: .8rem; }
.pickmap { height: 340px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); margin: 6px 0; }

/* Footer */
.footer { margin-top: 64px; background: var(--brand-dark); color: #cbd8cf; padding: 40px 0 20px; }
:root[data-theme="dark"] .footer { background: #0a110d; }
.footer a { color: #e8efe9; text-decoration: none; display: block; padding: 3px 0; font-size: .92rem; }
.footer a:hover { color: var(--accent-2); }
.footer h3 { color: #fff; font-size: .95rem; }
.footer .brand { color: #fff; font-size: 1.3rem; display: inline-flex; }
.footer .muted { color: #a9bcae; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1.4fr 1fr; gap: 24px; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; border-top: 1px solid rgba(255,255,255,.12); margin-top: 24px; padding-top: 16px; font-size: .82rem; }
.footer-base a { display: inline; }

@media print {
  .topbar, .footer, .mapwrap, .trip-form, .trip-actions, .aff-band, .panel-handle, .legend { display: none !important; }
  .mapapp, .tripapp { display: block; height: auto; }
  .panel { position: static; height: auto !important; box-shadow: none; border: 0; }
  .app-page { overflow: visible; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }

/* Photos on cards */
.card { position: relative; overflow: clip; }
.results { grid-auto-rows: max-content; }
.card-link { padding: 0; }
.card-img { aspect-ratio: 16 / 9; background: var(--line); overflow: hidden; }
.card-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.card:hover .card-img img { transform: scale(1.03); }
.card-img-ph img { object-fit: cover; opacity: .95; }
.card-body { padding: 12px 16px 14px; }
.card-row .card-link { padding: 0; display: grid; grid-template-columns: 112px 1fr; }
.card-row .card-img { aspect-ratio: auto; height: 100%; min-height: 104px; }
.card-row .card-body { padding: 10px 12px; min-width: 0; }
.card-row h3 { font-size: .98rem; margin: 4px 0 2px; }
.compare-btn { position: absolute; top: 8px; right: 8px; z-index: 2; border: 0; border-radius: 999px; padding: 4px 10px;
  font: 600 .78rem/1.4 inherit; background: rgba(255,255,255,.92); color: #1e2a22; cursor: pointer; box-shadow: 0 1px 4px rgba(0,0,0,.2); }
.compare-btn:hover { background: #fff; }
.compare-btn[aria-pressed="true"] { background: var(--brand); color: #fff; }
.card-row .compare-btn { top: 6px; left: 6px; right: auto; padding: 2px 8px; font-size: .72rem; }
.cs-actions [data-compare][aria-pressed="true"] { background: var(--brand); color: #fff; border-color: var(--brand); }
.pop-img { width: 100%; height: 110px; object-fit: cover; border-radius: 8px; margin-bottom: 4px; background: var(--line); }
.maplibregl-popup-content .pop { min-width: 220px; }

/* Campsite page gallery */
.gallery figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 8px 4px; font-size: .7rem; color: #fff;
  background: linear-gradient(transparent, rgba(0,0,0,.6)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
.gallery figure:not(.g-main) figcaption { display: none; }
.gallery-small figure figcaption { display: block !important; }
.photo-note { margin: -12px 0 18px; }
.gallery-empty { display: block; position: relative; height: 200px; grid-template-columns: none; grid-template-rows: none; }
.gallery-empty img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.85); }
.gallery-empty .btn { position: absolute; left: 50%; bottom: 20px; transform: translateX(-50%); box-shadow: var(--shadow); }

/* Compare bar */
.compare-bar { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 50; width: min(760px, calc(100% - 24px));
  display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: 14px;
  background: var(--surface); border: 1px solid var(--line); box-shadow: 0 8px 30px rgba(0,0,0,.22); }
.compare-items { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; min-width: 0; }
.compare-chip { display: inline-flex; align-items: center; gap: 4px; max-width: 180px; padding: 3px 4px 3px 10px; border-radius: 999px;
  background: var(--bg); border: 1px solid var(--line); font-size: .82rem; font-weight: 600; }
.compare-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.compare-chip button { flex-shrink: 0; }
.compare-chip button { border: 0; background: none; cursor: pointer; color: var(--muted); font-size: 1rem; line-height: 1; padding: 0 4px; }
.compare-hint { font-size: .82rem; }
.compare-actions { display: flex; gap: 6px; flex-shrink: 0; }
.btn.is-disabled { opacity: .5; pointer-events: none; }
.page-map .compare-bar { bottom: 12px; left: auto; right: 12px; transform: none; width: min(560px, calc(100% - 24px)); }
@media (max-width: 700px) {
  .compare-bar { flex-direction: row; flex-wrap: wrap; align-items: center; bottom: 8px; padding: 8px; gap: 6px; }
  .compare-chip { max-width: 140px; font-size: .76rem; }
  .compare-actions { margin-left: auto; }
  .compare-actions { justify-content: flex-end; }
  .page-map .compare-bar { left: 12px; right: 12px; width: auto; bottom: auto; top: 64px; }
}

/* Compare page */
.cmp-tools { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.cmp-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.cmp-table { width: 100%; border-collapse: collapse; min-width: calc(150px + var(--cols) * 190px); table-layout: fixed; }
.cmp-table th, .cmp-table td { padding: 9px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; font-size: .92rem; }
.cmp-table tbody th { width: 170px; font-weight: 600; color: var(--muted); position: sticky; left: 0; background: var(--surface); z-index: 1; }
.cmp-table thead th { vertical-align: bottom; background: var(--surface); }
.cmp-table thead .cmp-label { width: 170px; position: sticky; left: 0; z-index: 1; }
.cmp-photo { display: block; aspect-ratio: 16 / 10; border-radius: 10px; overflow: hidden; margin-bottom: 8px; background: var(--line); }
.cmp-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cmp-name { display: block; font-size: 1rem; margin: 6px 0 2px; color: var(--text); }
.cmp-where { display: block; font-size: .82rem; font-weight: 400; }
.cmp-remove { font-size: .8rem; padding: 2px 0; border: 0; background: none; cursor: pointer; color: var(--muted); text-decoration: underline; }
.cmp-group th { background: var(--bg) !important; color: var(--text) !important; font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; }
.cmp-best { background: color-mix(in srgb, var(--brand) 12%, transparent); box-shadow: inset 3px 0 0 var(--brand); }
.cmp-best::after { content: ' Best'; font-size: .7rem; font-weight: 700; color: var(--brand); text-transform: uppercase; margin-left: 4px; }
.cmp-yes { color: var(--brand); font-weight: 600; }
.cmp-no { color: #b3412e; }
.cmp-unk { display: inline-block; width: 18px; height: 18px; line-height: 18px; text-align: center; border-radius: 50%; background: var(--line); color: var(--muted); font-size: .75rem; font-weight: 700; }
.cmp-same { display: none; }
.cmp-actions td .btn { margin: 0 4px 4px 0; }
.gallery-empty a.btn { height: auto; width: auto; display: inline-flex; overflow: visible; white-space: nowrap; }
@media (max-width: 700px) {
  .gallery-empty { height: 190px; }
  .cmp-table { min-width: calc(112px + var(--cols) * 150px); }
  .cmp-table tbody th, .cmp-table thead .cmp-label { width: 112px; font-size: .82rem; }
  .cmp-table th, .cmp-table td { padding: 8px; font-size: .85rem; }
}

/* WikiCamps-gap features */
.lvl { display: inline-block; font-size: .72rem; font-weight: 600; padding: 1px 8px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); color: var(--muted); vertical-align: middle; }
.paid { display: inline-block; margin-left: 6px; font-size: .8rem; font-weight: 600; color: var(--brand); }
.paid-input { border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px 10px; margin: 0 0 12px; }
.paid-input legend { font-weight: 600; font-size: .92rem; padding: 0 4px; }
.paid-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.paid-row .paid-amt { display: flex; align-items: center; gap: 4px; margin: 0; font-weight: 600; }
.paid-row .paid-amt input { width: 90px; margin: 0; }
.paid-row select { width: auto; margin: 0; }
.paid-row .check { padding: 0; }
.pts { font-size: .75rem; font-weight: 600; opacity: .85; margin-left: 4px; }
.contrib-card { display: flex; gap: 14px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin: 0 0 18px; }
.contrib-badge { font-size: 2.2rem; line-height: 1; }
.contrib-card p { margin: 6px 0 0; }
.contrib-bar { height: 8px; border-radius: 999px; background: var(--line); overflow: hidden; margin: 6px 0 2px; max-width: 320px; }
.contrib-bar span { display: block; height: 100%; background: var(--brand); }
.cs-actions [data-list="visited"][aria-pressed="true"] { background: var(--brand); color: #fff; border-color: var(--brand); }
.coords { display: grid; gap: 4px; margin-top: 8px; }
.coords div { display: flex; align-items: center; gap: 8px; font-size: .85rem; }
.coords code { font-size: .82rem; background: var(--bg); padding: 1px 6px; border-radius: 6px; }
.coords .muted { width: 30px; }
.coords .btn-link { padding: 0; border: 0; background: none; cursor: pointer; }
.fuel-calc { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; margin: 10px 0; font-size: .9rem; }
.fuel-calc label { display: flex; align-items: center; gap: 4px; margin: 0; font-weight: 500; }
.fuel-calc input { width: 64px; margin: 0; padding: 4px 6px; }
.fuel-calc b { color: var(--brand); }
.dupes ul { margin: 6px 0; padding-left: 18px; }
.gallery-4 figure:nth-child(4) { grid-column: span 2; }
@media (max-width: 700px) { .gallery-4 figure:nth-child(4) { grid-column: auto; } }

/* Town pages: about, things to do, places of interest */
.town-about { display: grid; gap: 20px; align-items: start; margin: 8px 0 24px; }
.town-about.has-img { grid-template-columns: minmax(0, 1fr) 420px; }
.town-about h2 { margin-top: 0; }
.town-about p { max-width: 70ch; }
.town-img { margin: 0; }
.town-img img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--radius); display: block; background: var(--line); }
.town-img figcaption { margin-top: 4px; }
@media (max-width: 760px) { .town-about.has-img { grid-template-columns: 1fr; } .town-img { order: -1; } }
.todo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.todo { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; }
.todo h3 { font-size: 1rem; margin: 0 0 6px; }
.todo ul, .poi-list { list-style: none; margin: 0; padding: 0; }
.todo li { padding: 4px 0; border-top: 1px solid var(--line); }
.todo li:first-child { border-top: 0; }
.poi-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 6px 18px; }
.poi-list li { padding: 6px 0; border-bottom: 1px solid var(--line); }
.poi-kind { display: inline-block; font-size: .72rem; font-weight: 600; padding: 1px 8px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); color: var(--muted); margin-right: 4px; }
.sources { margin-top: 32px; padding-top: 12px; border-top: 1px solid var(--line); }
