/* ===========================================================================
 * เสน่ห์แม่กลอง — site.css
 * mobile-first (ออกแบบที่ 375px) · โทนแบรนด์: น้ำตาลแดงเข้ม (#2E1514 จากไอคอน/เว็บสำรวจ)
 * + ส้มอิฐร่มตลาด + ครีมพื้น · ไม่มี framework
 * =========================================================================== */

:root {
  --brand: #2E1514;
  --brand-2: #5B2B21;
  --accent: #C4532B;
  --accent-d: #A4411F;
  --accent-bg: #FBEDE6;
  --saffron: #E3A23B;
  --river: #1D6B72;
  --river-bg: #E3F1F2;

  --bg: #FBF7F0;
  --section: #F3ECE1;
  --surface: #FFFFFF;
  --text: #241815;
  --muted: #6E605A;
  --faint: #A1958E;
  --line: rgba(46, 21, 20, .10);
  --line-strong: rgba(46, 21, 20, .2);

  --open: #17774A;   --open-bg: #E2F3E9;
  --closing: #9B5A00; --closing-bg: #FCEFD8;
  --closed: #9A3A31; --closed-bg: #F8E7E4;
  --irr: #56657A;    --irr-bg: #ECEFF3;

  --r-lg: 18px;
  --r: 14px;
  --r-sm: 10px;
  --shadow: 0 1px 2px rgba(46, 21, 20, .06), 0 4px 14px rgba(46, 21, 20, .06);
  --shadow-lg: 0 10px 30px rgba(46, 21, 20, .16);
  --top-h: 56px;
  --bottom-h: 62px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --font: "IBM Plex Sans Thai", "Noto Sans Thai", -apple-system, "Segoe UI", Tahoma, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--top-h) + 8px); }
html, body { overflow-x: hidden; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 400 15px/1.6 var(--font);
  padding-bottom: calc(var(--bottom-h) + var(--safe-b));
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
h1, h2, h3 { line-height: 1.3; margin: 0; font-weight: 700; letter-spacing: -.005em; }
p { margin: 0 0 .7em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 2000; background: var(--brand); color: #fff; padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }
[hidden] { display: none !important; }
:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; }
.ic { width: 20px; height: 20px; flex: 0 0 auto; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.sep { margin: 0 .35em; color: var(--faint); }
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background .15s, border-color .15s, transform .1s;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-d); }
.btn-ghost { background: var(--surface); border-color: var(--line-strong); color: var(--text); }
.btn-ghost:hover { border-color: var(--brand); }
.btn-line { background: #06C755; color: #fff; }
.btn-sm { min-height: 36px; padding: 0 14px; font-size: 14px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.btn-row.center { justify-content: center; }
.iconbtn {
  width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex: 0 0 auto; padding: 0;
}
.linkbtn { background: none; border: 0; color: var(--accent); font-weight: 600; cursor: pointer; padding: 4px; }

/* ---------------------------------------------------------------- top bar & nav */
.topbar {
  position: sticky; top: 0; z-index: 1000; height: var(--top-h);
  background: rgba(251, 247, 240, .92); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar-in { max-width: 1120px; margin: 0 auto; height: 100%; padding: 0 12px 0 16px; display: flex; align-items: center; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; min-width: 0; flex: 1 1 auto; }
.brand img { width: 36px; height: 36px; border-radius: 10px; background: #fff; border: 1px solid var(--line); }
.brand-name { display: flex; flex-direction: column; font-weight: 700; font-size: 17px; line-height: 1.15; color: var(--brand); white-space: nowrap; }
.brand-name small { font-size: 11.5px; font-weight: 500; color: var(--muted); letter-spacing: .02em; }
.topnav { display: none; }
.bottomnav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 1000;
  height: calc(var(--bottom-h) + var(--safe-b)); padding-bottom: var(--safe-b);
  background: var(--surface); border-top: 1px solid var(--line);
  display: grid; grid-template-columns: repeat(5, 1fr);
}
.bottomnav a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  text-decoration: none; font-size: 11.5px; font-weight: 500; color: var(--muted);
}
.bottomnav a .ic { width: 23px; height: 23px; }
.bottomnav a.is-active { color: var(--accent); font-weight: 700; }
.bottomnav a.is-active .ic { stroke-width: 2.2; }

@media (min-width: 900px) {
  body { padding-bottom: 0; }
  .bottomnav { display: none; }
  .topnav { display: flex; gap: 4px; }
  .topnav a {
    display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 999px;
    text-decoration: none; font-weight: 500; color: var(--muted);
  }
  .topnav a .ic { width: 18px; height: 18px; }
  .topnav a:hover { color: var(--text); background: var(--section); }
  .topnav a.is-active { color: var(--brand); background: var(--section); font-weight: 700; }
}

/* ---------------------------------------------------------------- breadcrumb / headings */
.crumbs { display: flex; align-items: center; flex-wrap: wrap; gap: 2px; font-size: 13px; color: var(--muted); padding: 12px 0 4px; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--accent); }
.crumbs .ic { width: 14px; height: 14px; color: var(--faint); }
.crumbs span[aria-current] { color: var(--text); max-width: 60vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.page-head { margin: 4px 0 16px; }
.page-title { font-size: 25px; color: var(--brand); margin: 4px 0 6px; }
.page-sub { color: var(--muted); margin: 0; }
.sec { margin: 26px 0; }
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.sec-head h2 { font-size: 19px; color: var(--brand); }
.sec-head p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.more { display: inline-flex; align-items: center; gap: 2px; color: var(--accent); font-weight: 600; font-size: 14px; text-decoration: none; white-space: nowrap; }
.more .ic { width: 16px; height: 16px; }

/* ---------------------------------------------------------------- hero */
/* ภาพ hero จังหวัดเป็นภาพวาดแนวตั้ง (800×1005) ที่มีตัวอักษรในภาพเอง
   → ไม่วางข้อความทับภาพ: มือถือ = ภาพเต็มกว้างแล้วตามด้วยแผงข้อความ · desktop = 2 คอลัมน์
   พื้นหลังโทนสว่าง (ครีม) ตั้งใจ — ภาพ hero แต่ละจังหวัดสี/พื้นไม่เหมือนกัน พื้นมืดหาภาพเข้ากันยาก */
.hero {
  --hero-bg: #F4EBDD;
  position: relative; color: var(--text); overflow: hidden;
  background: linear-gradient(180deg, var(--hero-bg) 0%, var(--bg) 100%);
}
.hero-grid { display: flex; flex-direction: column; }
.hero-art { margin: 0 -16px; position: relative; }
.hero-art img { width: 100%; height: auto; max-height: 64vh; object-fit: cover; object-position: center top; }
.hero-art::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 90px; background: linear-gradient(180deg, rgba(244,235,221,0), var(--hero-bg)); }
.hero-in { position: relative; width: 100%; padding: 4px 0 32px; margin-top: -36px; }
.hero.no-art .hero-in { margin-top: 0; padding-top: 56px; }
.hero-kicker { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; font-weight: 600; }
.hero h1 { font-size: 40px; line-height: 1.15; color: var(--brand); }
.hero-tag { font-size: 17px; margin: 8px 0 18px; color: var(--muted); }
.hero-search {
  display: flex; align-items: center; gap: 6px; background: #fff; color: var(--text);
  border-radius: 999px; padding: 5px 5px 5px 16px; box-shadow: var(--shadow-lg); max-width: 560px; border: 1px solid var(--line);
}
.hero-search .ic { color: var(--faint); }
.hero-search input { flex: 1 1 auto; min-width: 0; border: 0; outline: 0; background: transparent; height: 42px; font-size: 15px; }
.hero-search input::-webkit-search-cancel-button { display: none; }
.hero-search button { border: 0; background: var(--accent); color: #fff; font-weight: 600; border-radius: 999px; height: 42px; padding: 0 18px; cursor: pointer; white-space: nowrap; }

/* ภาพ hero/ประกาศทำมาให้แอป: ส่วนบนเป็นพื้นที่โปร่งเผื่อ status bar + แถบหัวของแอปทับ
   (template 800×1005 เว้นบน 182px = 22.75% ของความกว้าง) → เว็บครอปทิ้งทุกขนาดจอ
   margin-top เป็น % อิงความกว้างกล่อง = อิงความกว้างภาพพอดี · ปรับได้ที่ --hero-crop ตัวเดียว */
.hero-art { overflow: hidden; }
.hero-art > img, .hero-art .ann-track { margin-top: calc(-1 * var(--hero-crop, 22.75%)); }

/* สไลด์ประกาศจังหวัดแทน hero (js/hero-slides.js) — ความสูงตามภาพ ไม่ล็อกสัดส่วน (ProvinceAnnouncement §0 ข้อ 3) */
.ann-track {
  display: flex; align-items: flex-start; overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.ann-track::-webkit-scrollbar { display: none; }
.ann-slide { flex: 0 0 100%; scroll-snap-align: start; scroll-snap-stop: always; }
.ann-slide a, .ann-slide img { display: block; }
.ann-dots { position: absolute; left: 0; right: 0; bottom: 46px; z-index: 2; display: flex; justify-content: center; gap: 6px; }
.ann-dots button {
  width: 8px; height: 8px; padding: 0; border: 0; border-radius: 999px; cursor: pointer;
  background: rgba(46, 21, 20, .28); transition: width .25s ease, background-color .25s ease;
}
.ann-dots button[aria-selected="true"] { width: 22px; background: var(--accent); }


@media (min-width: 900px) {
  .hero-grid { flex-direction: row-reverse; align-items: center; gap: 48px; padding-top: 36px; padding-bottom: 64px; }
  .hero-art { margin: 0; flex: 0 0 380px; border-radius: 24px; box-shadow: 0 18px 40px rgba(46,21,20,.18); }
  .hero-art img { max-height: none; }
  .hero-art::after { display: none; }
  .ann-dots { bottom: 12px; }
  .hero-in { margin-top: 0; padding: 0; flex: 1 1 auto; }
  .hero h1 { font-size: 60px; }
  .hero-tag { font-size: 20px; }
}

/* ---------------------------------------------------------------- horizontal rows & tiles */
.hscroll {
  display: flex; gap: 12px; overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-padding: 0 16px; padding: 2px 16px 10px;
  scrollbar-width: none;
}
.hscroll::-webkit-scrollbar { display: none; }
.hs-item { flex: 0 0 auto; width: min(72vw, 270px); scroll-snap-align: start; display: flex; }
@media (min-width: 1152px) { .hscroll { padding-left: calc((100vw - 1120px) / 2 + 16px); scroll-padding-left: calc((100vw - 1120px) / 2 + 16px); } }

.tile {
  display: flex; flex-direction: column; width: 100%; text-decoration: none; background: var(--surface);
  border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--line);
  transition: transform .15s, box-shadow .15s;
}
.tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.tile-img { position: relative; aspect-ratio: 16 / 10; background: var(--section); }
.tile-img img { width: 100%; height: 100%; object-fit: cover; }
.tile-img .noimg, .noimg { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 40px; background: linear-gradient(135deg, var(--section), #EADFCF); }
.tile-badge { position: absolute; left: 8px; bottom: 8px; background: rgba(36,24,21,.78); color: #fff; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; }
.tile-body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 5px; flex: 1 1 auto; }
.tile-title { font-weight: 700; font-size: 15.5px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tile-sub { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 4px; }
.tile-sub .ic { width: 15px; height: 15px; }
.tile-sub.clamp2 { display: -webkit-box; }
.tile-sig { font-size: 13px; color: var(--text); margin-top: auto; }
.tile-sig b { color: var(--accent); font-weight: 600; }
.tile-link { margin-top: auto; color: var(--river); font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 4px; }
.tile-link .ic { width: 15px; height: 15px; }
.tile .fpill { position: absolute; left: 8px; top: 8px; }

/* ---------------------------------------------------------------- status pill */
.pill {
  display: inline-flex; align-items: center; gap: 6px; align-self: flex-start;
  font-size: 13px; font-weight: 600; padding: 3px 10px 3px 8px; border-radius: 999px; line-height: 1.4;
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.pill-sm { font-size: 12px; padding: 2px 9px 2px 7px; }
.pill-open { background: var(--open-bg); color: var(--open); }
.pill-open .dot { box-shadow: 0 0 0 3px rgba(23,119,74,.18); }
.pill-closing { background: var(--closing-bg); color: var(--closing); }
.pill-closed { background: var(--closed-bg); color: var(--closed); }
.pill-irregular, .pill-unknown { background: var(--irr-bg); color: var(--irr); }

.fpill { display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.fpill-live { background: #D93B2B; color: #fff; }
.fpill-upcoming { background: var(--saffron); color: #3B2300; }
.fpill-past { background: rgba(36,24,21,.72); color: #fff; }
.countdown { font-size: 13px; font-weight: 700; color: #A26A0B; }

/* ---------------------------------------------------------------- shop card (row) */
.shop-list { display: grid; gap: 10px; }
.card-shop {
  display: grid; grid-template-columns: 104px 1fr; gap: 12px; align-items: start;
  text-decoration: none; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: 10px; box-shadow: var(--shadow); transition: border-color .15s, box-shadow .15s;
}
.card-shop:hover { border-color: var(--line-strong); box-shadow: var(--shadow-lg); }
.cs-img { width: 104px; height: 104px; border-radius: 11px; overflow: hidden; background: var(--section); }
.cs-img img { width: 100%; height: 100%; object-fit: cover; }
.cs-img .noimg { font-size: 34px; }
.cs-body { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.cs-title { font-weight: 700; font-size: 15.5px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cs-sub { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-sig { font-size: 13px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cs-sig b { color: var(--accent); font-weight: 600; }
.cs-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 12.5px; color: var(--muted); }
.cs-meta span { display: inline-flex; align-items: center; gap: 3px; }
.cs-meta .ic { width: 14px; height: 14px; }
.meta-dist { color: var(--river); font-weight: 600; }
.meta-age { color: #8A5A10; }
@media (min-width: 640px) {
  .shop-list-2 { grid-template-columns: 1fr 1fr; }
}

/* ---------------------------------------------------------------- /shops layout + filters */
.shops-layout { display: block; }
.searchbar { display: flex; gap: 8px; align-items: center; position: sticky; top: var(--top-h); z-index: 20; background: var(--bg); padding: 8px 0; }
.search {
  flex: 1 1 auto; min-width: 0; display: flex; align-items: center; gap: 8px; height: 46px; padding: 0 14px;
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: 999px;
}
.search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(196,83,43,.15); }
.search .ic { color: var(--faint); }
.search input { flex: 1 1 auto; min-width: 0; border: 0; outline: 0; background: transparent; height: 100%; font-size: 15px; }
.btn-filter {
  position: relative; flex: 0 0 auto; height: 46px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-strong);
  background: var(--surface); display: inline-flex; align-items: center; gap: 6px; font-weight: 600; cursor: pointer;
}
.badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 12px; display: inline-flex; align-items: center; justify-content: center; }
.qchips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 0 8px; margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
.qchips::-webkit-scrollbar { display: none; }
.qchip {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 5px; height: 36px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: var(--surface); text-decoration: none; font-size: 14px; font-weight: 500; white-space: nowrap;
}
.qchip .ic { width: 16px; height: 16px; }
.qchip.is-on { background: var(--brand); border-color: var(--brand); color: #fff; }
.achips { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 8px; align-items: center; }
.achip {
  display: inline-flex; align-items: center; gap: 4px; padding: 4px 8px 4px 12px; border-radius: 999px;
  background: var(--accent-bg); color: var(--accent-d); font-size: 13px; font-weight: 600; text-decoration: none;
}
.achip .ic { width: 15px; height: 15px; }
.achip-clear { font-size: 13px; color: var(--muted); text-decoration: underline; margin-left: 4px; }
.geo-msg { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; background: var(--river-bg); color: #134A50; border-radius: var(--r-sm); padding: 10px 12px; font-size: 13.5px; margin: 4px 0 10px; }
.geo-msg > span { flex: 1 1 180px; }
.res-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 4px 0 10px; }
.res-count { margin: 0; font-size: 14px; color: var(--muted); }
.res-count b { color: var(--text); font-size: 17px; }
.res-tools { display: flex; align-items: center; gap: 6px; }
.sort { position: relative; display: inline-flex; align-items: center; }
.sort .ic { position: absolute; right: 8px; width: 16px; height: 16px; pointer-events: none; color: var(--muted); }
.sort select {
  appearance: none; -webkit-appearance: none; height: 36px; border-radius: 999px; border: 1px solid var(--line-strong);
  background: var(--surface); padding: 0 28px 0 12px; font-size: 13.5px; max-width: 150px; cursor: pointer;
}
.viewtg { display: inline-flex; background: var(--section); border-radius: 999px; padding: 3px; }
.viewtg button { border: 0; background: transparent; height: 30px; padding: 0 10px; border-radius: 999px; display: inline-flex; align-items: center; gap: 4px; font-size: 13px; cursor: pointer; color: var(--muted); }
.viewtg button .ic { width: 16px; height: 16px; }
.viewtg button.is-on { background: var(--surface); color: var(--text); font-weight: 600; box-shadow: 0 1px 3px rgba(0,0,0,.1); }
@media (max-width: 400px) { .viewtg button span { display: none; } }
.shops-map { height: 62vh; min-height: 360px; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); background: var(--section); }
.map-loading { height: 100%; display: flex; align-items: center; justify-content: center; color: var(--muted); padding: 20px; text-align: center; }
.noscript-hint { font-size: 13px; color: var(--muted); }

/* sheet (mobile) */
.filters {
  position: fixed; inset: 0; z-index: 1500; background: var(--bg); display: flex; flex-direction: column;
  transform: translateY(100%); visibility: hidden; transition: transform .25s ease, visibility 0s linear .25s;
}
body.sheet-open { overflow: hidden; }
body.sheet-open .filters { transform: none; visibility: visible; transition: transform .25s ease; }
.sheet-backdrop { display: none; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px 10px 16px; border-bottom: 1px solid var(--line); background: var(--surface); }
.sheet-head h2 { font-size: 18px; }
.sheet-body { flex: 1 1 auto; overflow-y: auto; padding: 4px 16px 16px; overscroll-behavior: contain; }
.sheet-foot { display: flex; gap: 8px; padding: 10px 16px calc(10px + var(--safe-b)); border-top: 1px solid var(--line); background: var(--surface); }
.sheet-foot .btn { flex: 1 1 0; }
.sheet-foot .btn-primary { flex: 2 1 0; }
.fg { border: 0; margin: 0; padding: 14px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.fg:last-child { border-bottom: 0; }
.fg legend { font-weight: 700; font-size: 15px; padding: 0; margin-bottom: 2px; color: var(--brand); }
.fg-hint { font-size: 12.5px; color: var(--muted); margin: 0 0 8px; }
.tgs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.tg { position: relative; display: inline-flex; cursor: pointer; }
.tg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.tg span {
  display: inline-flex; align-items: center; gap: 5px; min-height: 38px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: var(--surface); font-size: 14px; user-select: none;
}
.tg span .ic { width: 16px; height: 16px; }
.tg span small { color: var(--faint); font-size: 12px; }
.tg input:checked + span { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
.tg input:checked + span small { color: rgba(255,255,255,.7); }
.tg input:focus-visible + span { outline: 2.5px solid var(--accent); outline-offset: 2px; }
.fg-row { display: flex; gap: 8px; width: 100%; }
.sel { flex: 1 1 0; display: flex; flex-direction: column; gap: 2px; font-size: 12.5px; color: var(--muted); }
.sel select { height: 40px; border-radius: var(--r-sm); border: 1px solid var(--line-strong); background: var(--surface); padding: 0 10px; font-size: 14px; color: var(--text); }
.seg { display: flex; width: 100%; gap: 0; background: var(--section); border-radius: 999px; padding: 3px; }
.seg .tg { flex: 1 1 0; }
.seg .tg span { width: 100%; justify-content: center; border: 0; background: transparent; min-height: 34px; padding: 0 6px; }
.seg .tg input:checked + span { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.switch { display: flex; align-items: center; gap: 10px; width: 100%; margin-top: 6px; cursor: pointer; font-size: 14px; position: relative; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch .sw { width: 42px; height: 24px; border-radius: 999px; background: var(--line-strong); position: relative; flex: 0 0 auto; transition: background .15s; }
.switch .sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .15s; }
.switch input:checked + .sw { background: var(--open); }
.switch input:checked + .sw::after { transform: translateX(18px); }
.switch input:focus-visible + .sw { outline: 2.5px solid var(--accent); outline-offset: 2px; }

@media (min-width: 960px) {
  .shops-layout { display: grid; grid-template-columns: 290px 1fr; gap: 24px; align-items: start; }
  .filters {
    position: sticky; top: calc(var(--top-h) + 12px); inset: auto; transform: none; visibility: visible; transition: none;
    max-height: calc(100vh - var(--top-h) - 24px); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; z-index: 1;
  }
  .sheet-head [data-close-sheet] { display: none; }
  .sheet-head { background: transparent; }
  .btn-filter { display: none; }
  .qchips { margin: 0; padding-left: 0; padding-right: 0; flex-wrap: wrap; }
  body.sheet-open { overflow: auto; }
  .sort select { max-width: none; }
}

/* ---------------------------------------------------------------- empty / error */
.empty { text-align: center; padding: 36px 16px; background: var(--surface); border: 1px dashed var(--line-strong); border-radius: var(--r-lg); margin: 8px 0 16px; }
.empty-art { font-size: 44px; width: 84px; height: 84px; margin: 0 auto 10px; border-radius: 50%; background: var(--section); display: flex; align-items: center; justify-content: center; }
.empty h3 { font-size: 17px; margin-bottom: 6px; }
.empty p { color: var(--muted); max-width: 420px; margin: 0 auto 12px; font-size: 14px; }
.empty-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.err { text-align: center; padding: 56px 16px 40px; max-width: 560px; }
.err-art { font-size: 64px; }
.err-code { font-weight: 700; color: var(--accent); letter-spacing: .1em; margin: 8px 0 0; }
.err h1 { font-size: 26px; color: var(--brand); margin: 4px 0 10px; }
.err p { color: var(--muted); }

/* ---------------------------------------------------------------- boxes / shop page */
.box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px; margin-bottom: 12px; }
.box h2 { font-size: 17px; color: var(--brand); display: flex; align-items: center; gap: 6px; margin-bottom: 10px; }
.box h2 .ic { width: 19px; height: 19px; color: var(--accent); }
.box-app { background: linear-gradient(135deg, #FFF6EC, #FCEBDD); border-color: #F3D5BE; }
.shop-hero { background: var(--brand); }
.gallery { position: relative; max-width: 1120px; margin: 0 auto; }
.gallery-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.gallery-track::-webkit-scrollbar { display: none; }
.gallery-track figure { margin: 0; flex: 0 0 100%; scroll-snap-align: start; aspect-ratio: 4 / 3; background: #1b0d0c; }
.gallery-track img { width: 100%; height: 100%; object-fit: cover; }
.gallery-count { position: absolute; right: 12px; bottom: 12px; background: rgba(0,0,0,.6); color: #fff; font-size: 12.5px; padding: 3px 10px; border-radius: 999px; }
.gallery-empty { aspect-ratio: 16 / 7; display: flex; align-items: center; justify-content: center; font-size: 60px; background: linear-gradient(135deg, var(--brand), var(--brand-2)); }
@media (min-width: 900px) {
  .gallery-track figure { flex-basis: 50%; aspect-ratio: 4 / 3; max-height: 420px; }
  .gallery-track:has(figure:only-child) figure { flex-basis: 100%; aspect-ratio: 21 / 9; }
}
.shop-main { padding-bottom: 8px; }
.shop-head { margin: 4px 0 14px; }
.shop-cats { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.cat { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; background: var(--section); padding: 3px 10px; border-radius: 999px; text-decoration: none; }
.cat-type { background: var(--river-bg); color: var(--river); }
.shop-head h1, .fest-head h1 { font-size: 26px; color: var(--brand); margin-bottom: 6px; }
.shop-summary { color: var(--muted); font-size: 15.5px; }
.shop-status { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 13.5px; }
.actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 8px; margin: 0 0 16px; }
.act {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 64px;
  border-radius: var(--r); border: 1px solid var(--line); background: var(--surface); text-decoration: none; font-size: 13px; font-weight: 600; cursor: pointer; padding: 6px 4px;
}
.act .ic { width: 22px; height: 22px; color: var(--accent); }
.act-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.act-primary .ic { color: #fff; }
.shop-grid { display: grid; gap: 0; }
@media (min-width: 900px) {
  .shop-grid { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 16px; align-items: start; }
  .shop-side { position: sticky; top: calc(var(--top-h) + 12px); }
  .actions { max-width: 560px; }
  .shop-head h1, .fest-head h1 { font-size: 34px; }
}
.sigs { list-style: none; margin: 0; padding: 0; }
.sig { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-top: 1px dashed var(--line); }
.sig:first-child { border-top: 0; padding-top: 0; }
.sig img { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; }
.sig-body { flex: 1 1 auto; min-width: 0; }
.sig-name { font-weight: 600; }
.sig-desc, .sig-note { font-size: 13px; color: var(--muted); }
.sig-price { font-weight: 700; color: var(--accent); white-space: nowrap; }
.sig-price .muted { font-weight: 400; font-size: 12.5px; }
.story p { color: #3a2d29; }
.story h3 { font-size: 15.5px; margin: 8px 0 6px; }
.story img, .wide { border-radius: 12px; margin: 8px 0; width: 100%; height: auto; }
.hours { width: 100%; border-collapse: collapse; font-size: 14px; }
.hours th, .hours td { padding: 7px 8px; text-align: left; border-top: 1px solid var(--line); font-weight: 400; }
.hours tr:first-child th, .hours tr:first-child td { border-top: 0; }
.hours td { text-align: right; font-variant-numeric: tabular-nums; }
.hours tr.is-today { background: var(--accent-bg); font-weight: 700; }
.hours tr.is-today th, .hours tr.is-today td { font-weight: 700; }
.hours tr.is-today th { border-radius: 8px 0 0 8px; }
.hours tr.is-today td { border-radius: 0 8px 8px 0; }
.today-tag { font-size: 11px; background: var(--accent); color: #fff; padding: 1px 7px; border-radius: 999px; margin-left: 4px; vertical-align: 1px; }
.flags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.flag { font-size: 12px; font-weight: 600; padding: 2px 9px; border-radius: 999px; }
.flag-warn { background: var(--closing-bg); color: var(--closing); }
.note { font-size: 13.5px; background: var(--section); padding: 8px 10px; border-radius: 10px; margin: 10px 0 0; }
.amen { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.amen li { display: flex; align-items: center; gap: 8px; font-size: 14px; background: var(--section); border-radius: 10px; padding: 8px 10px; }
.amen li span { font-size: 18px; }
.facts { list-style: none; padding: 0; margin: 0; }
.facts li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-top: 1px solid var(--line); font-size: 14px; }
.facts li:first-child { border-top: 0; }
.facts span { color: var(--muted); }
.facts b { text-align: right; }
.links { list-style: none; padding: 0; margin: 0; }
.links a { display: flex; align-items: center; gap: 6px; padding: 6px 0; color: var(--river); font-weight: 600; text-decoration: none; }
.links .ic { width: 16px; height: 16px; }
.ingr { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 8px; }
.ingr li { display: flex; gap: 10px; align-items: center; }
.ingr img { width: 48px; height: 48px; border-radius: 10px; object-fit: cover; }
.ingr li div { display: flex; flex-direction: column; font-size: 14px; }
.ingr li span { color: var(--muted); font-size: 13px; }
.thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.thumbs img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; }
.g-title { font-size: 14px; margin: 10px 0 6px; color: var(--muted); }
.verified { font-size: 12.5px; color: var(--open); margin: 4px 0 0; }

/* ---------------------------------------------------------------- app CTA / store buttons */
.app-cta {
  display: flex; gap: 16px; align-items: center; margin: 28px 0;
  background: radial-gradient(120% 140% at 100% 0%, #7A3A2A 0%, var(--brand) 60%); color: #fff;
  border-radius: var(--r-lg); padding: 20px; box-shadow: var(--shadow-lg); overflow: hidden;
}
.app-cta-art img { width: 72px; height: 72px; border-radius: 18px; background: #fff; }
.app-cta-body { min-width: 0; }
.app-cta h2 { font-size: 19px; margin-bottom: 4px; }
.app-cta p { color: rgba(255,255,255,.82); font-size: 14px; margin-bottom: 12px; }
.app-cta.is-compact { margin: 0 0 20px; }
@media (max-width: 560px) {
  .app-cta { flex-direction: column; align-items: flex-start; }
  .app-cta-art img { width: 56px; height: 56px; border-radius: 14px; }
}
.store-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.store-btn {
  display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 14px 0 12px; border-radius: 12px;
  background: #0d0d0d; color: #fff; text-decoration: none; border: 1px solid rgba(255,255,255,.18);
}
.store-btn svg { width: 22px; height: 22px; }
.store-btn span { display: flex; flex-direction: column; line-height: 1.1; font-weight: 600; font-size: 15px; }
.store-btn small { font-size: 10.5px; font-weight: 400; opacity: .8; }
.store-btns.is-light .store-btn { background: var(--brand); }

/* ---------------------------------------------------------------- promo / footer */
.promo {
  display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between;
  background: var(--river-bg); border-radius: var(--r-lg); padding: 18px; color: #123F44;
}
.promo h2 { font-size: 18px; margin-bottom: 4px; }
.promo p { margin: 0; font-size: 14px; }
.footer { background: var(--section); border-top: 1px solid var(--line); padding: 28px 0 24px; margin-top: 32px; }
.footer-row { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; }
.footer-brand { display: flex; align-items: center; gap: 10px; }
.footer-brand img { width: 40px; height: 40px; border-radius: 10px; background: #fff; }
.footer-brand div { display: flex; flex-direction: column; line-height: 1.3; }
.footer-brand b { color: var(--brand); }
.footer-brand span { font-size: 13px; color: var(--muted); }
.footer-brand a { color: var(--accent); font-weight: 600; text-decoration: none; }
.footer-links { display: flex; flex-wrap: wrap; gap: 14px; font-size: 14px; }
.footer-links a { text-decoration: none; color: var(--muted); }
.footer-links a:hover { color: var(--accent); }
.footer-note { font-size: 12.5px; color: var(--faint); margin: 14px 0 0; }

/* ---------------------------------------------------------------- missions */
.grid-cards { display: grid; gap: 14px; }
@media (min-width: 640px) { .grid-cards { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .grid-cards { grid-template-columns: 1fr 1fr 1fr; } }
.card-mission, .card-fest {
  display: flex; flex-direction: column; text-decoration: none; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow); transition: transform .15s, box-shadow .15s;
}
.card-mission:hover, .card-fest:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.cm-img, .cf-img { position: relative; aspect-ratio: 16 / 9; background: var(--section); }
.cm-img img, .cf-img img { width: 100%; height: 100%; object-fit: cover; }
.cf-img .fpill { position: absolute; left: 10px; top: 10px; }
.cm-body, .cf-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; }
.cm-body h3, .cf-body h3 { font-size: 17px; }
.mtypes { display: flex; flex-wrap: wrap; gap: 6px; }
.mtype { font-size: 12.5px; background: var(--section); padding: 2px 9px; border-radius: 999px; }
.reward { font-size: 13.5px; font-weight: 600; color: #8A5A10; }
.card-fest.is-past .cf-img img { filter: saturate(.55); }
.cf-cat { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.cf-tag { color: var(--muted); font-size: 14px; margin: 0; }
.cf-meta { display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; color: var(--muted); }
.cf-meta span { display: flex; align-items: center; gap: 6px; }
.cf-meta .ic { width: 16px; height: 16px; color: var(--accent); }

.mission-hero {
  position: relative; color: #fff; padding: 0 0 22px;
  background: var(--brand); overflow: hidden;
}
.mission-hero.no-cover { background: radial-gradient(120% 140% at 100% 0%, #7A3A2A 0%, var(--brand) 65%); }
.mission-hero .crumbs, .mission-hero .crumbs span[aria-current] { color: rgba(255,255,255,.8); }
.mission-hero h1 { font-size: 27px; margin: 110px 0 10px; text-shadow: 0 2px 12px rgba(0,0,0,.4); }
.mission-hero.no-cover h1 { margin-top: 40px; }
.mission-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 14px; margin-bottom: 10px; }
.mission-meta span { display: inline-flex; align-items: center; gap: 5px; }
.mission-meta .ic { width: 17px; height: 17px; }
.mission-hero .mtype { background: rgba(255,255,255,.16); }
.mission-grid { display: grid; gap: 0; margin-top: 16px; }
@media (min-width: 900px) {
  .mission-grid { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 16px; align-items: start; }
  .mission-grid aside { position: sticky; top: calc(var(--top-h) + 12px); }
  .mission-hero h1 { font-size: 36px; margin-top: 160px; }
}
.steps { list-style: none; margin: 0; padding: 0; position: relative; }
.step { position: relative; display: flex; gap: 12px; padding: 0 0 18px; }
.step::before { content: ""; position: absolute; left: 15px; top: 34px; bottom: 0; border-left: 2px dashed var(--line-strong); }
.step:last-child::before { display: none; }
.step:last-child { padding-bottom: 0; }
.step-n { flex: 0 0 32px; height: 32px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.step-body { flex: 1 1 auto; min-width: 0; }
.step-type { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.step h3 { font-size: 16px; margin: 2px 0 4px; }
.step blockquote { margin: 4px 0; padding: 8px 12px; background: var(--section); border-radius: 4px 12px 12px 12px; font-size: 14px; color: #4a3a35; }
.step-img { width: 72px; height: 72px; border-radius: 12px; object-fit: cover; flex: 0 0 auto; }
.route-map { height: 280px; border-radius: 12px; overflow: hidden; background: var(--section); margin-bottom: 8px; }
.play-cta { background: var(--surface); border: 2px solid var(--accent); border-radius: var(--r-lg); padding: 18px; margin-bottom: 12px; }
.play-cta h2 { font-size: 19px; color: var(--accent-d); margin-bottom: 6px; }
.play-cta p { color: var(--muted); font-size: 14px; }

/* ---------------------------------------------------------------- festivals */
.tabs { display: flex; gap: 4px; background: var(--section); border-radius: 999px; padding: 4px; margin-bottom: 16px; }
.tabs a { flex: 1 1 0; text-align: center; text-decoration: none; padding: 8px 6px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--muted); white-space: nowrap; }
.tabs a small { font-size: 11.5px; margin-left: 4px; background: rgba(0,0,0,.07); padding: 0 6px; border-radius: 999px; }
.tabs a.is-on { background: var(--surface); color: var(--brand); box-shadow: 0 1px 4px rgba(0,0,0,.1); }
@media (min-width: 640px) { .tabs { display: inline-flex; } .tabs a { padding: 8px 18px; } }
.fest-cover { background: var(--brand); max-height: 440px; overflow: hidden; display: flex; justify-content: center; }
.fest-cover img { width: 100%; max-width: 1120px; aspect-ratio: 16 / 9; object-fit: cover; max-height: 440px; }
.fest-cover .noimg { aspect-ratio: 16 / 7; font-size: 64px; }
.fest-head { margin: 4px 0 16px; }
.fest-badges { display: flex; gap: 6px; align-items: center; margin-bottom: 8px; }
.fest-when { display: flex; flex-direction: column; gap: 8px; margin: 10px 0 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; }
.fest-when > div { display: flex; gap: 10px; align-items: flex-start; }
.fest-when .ic { color: var(--accent); margin-top: 2px; }
.fest-when span { display: flex; flex-direction: column; }
.fest-when small { color: var(--muted); }
.schedule { list-style: none; padding: 0; margin: 0; }
.schedule li { display: grid; grid-template-columns: 96px 1fr; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.schedule li:first-child { border-top: 0; }
.sch-when { display: flex; flex-direction: column; font-size: 13px; color: var(--muted); }
.sch-when b { color: var(--text); }
.info { list-style: none; margin: 0; padding: 0; }
.info li { display: flex; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.info li:first-child { border-top: 0; }
.info .ic { color: var(--accent); margin-top: 3px; }
.info div { display: flex; flex-direction: column; font-size: 14px; }
.info span { font-size: 12.5px; color: var(--muted); }
.info small { color: var(--muted); }
.rel { list-style: none; margin: 0; padding: 0; }
.rel a, .rel .li-static { display: flex; align-items: center; gap: 10px; padding: 8px 0; text-decoration: none; border-top: 1px solid var(--line); }
.rel li:first-child a, .rel li:first-child .li-static { border-top: 0; }
.rel img { width: 40px; height: 40px; border-radius: 10px; object-fit: cover; }
.rel span:not(.noimg-sm) { flex: 1 1 auto; display: flex; flex-direction: column; font-size: 14px; }
.rel small { color: var(--muted); font-size: 12.5px; }
.rel .ic { width: 16px; height: 16px; color: var(--faint); }
.noimg-sm { width: 40px; height: 40px; border-radius: 10px; background: var(--section); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.collect { list-style: none; padding: 0; margin: 10px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.collect li { background: rgba(255,255,255,.7); border-radius: 12px; padding: 10px 6px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.collect img, .collect-ph { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; }
.collect-ph { display: flex; align-items: center; justify-content: center; font-size: 28px; background: #fff; filter: grayscale(.3); }
.collect b { font-size: 13px; line-height: 1.3; }
.collect small { font-size: 11.5px; color: var(--muted); }

/* ---------------------------------------------------------------- /map */
body.pg-map { padding-bottom: 0; }
.map-page { position: fixed; left: 0; right: 0; top: var(--top-h); bottom: calc(var(--bottom-h) + var(--safe-b)); }
@media (min-width: 900px) { .map-page { bottom: 0; } }
.bigmap { position: absolute; inset: 0; background: var(--section); z-index: 1; }
.map-fallback { padding: 72px 16px 16px; overflow: auto; height: 100%; }
.map-fallback details { background: var(--surface); border-radius: 12px; padding: 8px 12px; margin-bottom: 8px; }
.map-layers {
  position: absolute; z-index: 500; left: 0; right: 0; top: 10px; display: flex; gap: 6px;
  overflow-x: auto; padding: 0 12px; scrollbar-width: none;
}
.map-layers::-webkit-scrollbar { display: none; }
.ltg {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 5px; height: 36px; padding: 0 12px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: rgba(255,255,255,.95); font-size: 13.5px; font-weight: 600; cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,.12); color: var(--muted);
}
.ltg small { font-size: 11.5px; color: var(--faint); }
.ltg.is-on { background: var(--brand); border-color: var(--brand); color: #fff; }
.ltg.is-on small { color: rgba(255,255,255,.7); }
.locate-btn {
  position: absolute; z-index: 500; right: 12px; bottom: 112px; width: 44px; height: 44px; border-radius: 12px;
  background: #fff; border: 1px solid var(--line-strong); box-shadow: 0 2px 8px rgba(0,0,0,.15); cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--river);
}
.locate-btn.is-busy { opacity: .6; }
.map-card {
  position: absolute; z-index: 600; left: 10px; right: 10px; bottom: 10px; background: var(--surface);
  border-radius: var(--r-lg); box-shadow: var(--shadow-lg); padding: 12px; max-width: 460px; margin: 0 auto;
}
.mc-close { position: absolute; right: 8px; top: 8px; width: 32px; height: 32px; border: 0; background: var(--section); }
.mc { display: flex; gap: 12px; padding-right: 32px; }
.mc-img { width: 84px; height: 84px; border-radius: 12px; overflow: hidden; flex: 0 0 auto; background: var(--section); }
.mc-img img { width: 100%; height: 100%; object-fit: cover; }
.mc-img .noimg { font-size: 32px; }
.mc-body { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.mc-title { font-weight: 700; font-size: 15.5px; line-height: 1.35; }
.mc-sub { font-size: 12.5px; color: var(--muted); }
.mc-actions { display: flex; gap: 8px; margin-top: 10px; }
.mc-actions .btn { flex: 1 1 0; }

/* หมุดแผนที่ */
.pin-wrap { background: none; border: 0; }
.pin {
  width: 36px; height: 36px; border-radius: 50% 50% 50% 4px; transform: rotate(-45deg);
  background: #fff; border: 2.5px solid var(--accent); box-shadow: 0 3px 8px rgba(0,0,0,.25);
  display: flex; align-items: center; justify-content: center;
}
.pin span { transform: rotate(45deg); font-size: 17px; line-height: 1; font-weight: 700; color: var(--brand); }
.pin-shops { border-color: var(--accent); }
.pin-shops.st-open, .pin-shops.st-closing { border-color: var(--open); }
.pin-shops.st-closed { border-color: #B9A9A2; }
.pin-attractions { border-color: var(--river); }
.pin-checkins { border-color: #6A4A9C; }
.pin-missions { border-color: var(--saffron); background: var(--saffron); }
.pin-missions span { font-size: 14px; color: #3B2300; }
.pin-festivals { border-color: #D93B2B; }
.pin-festivals.st-past { border-color: #9a8f8a; }
.pin-num { width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; border: 3px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.3); }
.you-dot { width: 22px; height: 22px; border-radius: 50%; background: #2B7DE9; border: 4px solid #fff; box-shadow: 0 0 0 6px rgba(43,125,233,.25), 0 2px 6px rgba(0,0,0,.3); }
.mini-pop .leaflet-popup-content { margin: 8px; }
.mini .card-shop { grid-template-columns: 72px 1fr; box-shadow: none; border: 0; padding: 0; }
.mini .cs-img { width: 72px; height: 72px; }
.leaflet-container { font-family: var(--font); }
.marker-cluster-small, .marker-cluster-medium, .marker-cluster-large { background-color: rgba(196,83,43,.25) !important; }
.marker-cluster-small div, .marker-cluster-medium div, .marker-cluster-large div { background-color: var(--accent) !important; color: #fff !important; font-weight: 700; font-family: var(--font); }

/* ---------------------------------------------------------------- share sheet / toast */
.share-sheet { position: fixed; inset: 0; z-index: 3000; display: flex; align-items: flex-end; justify-content: center; }
.share-bd { position: absolute; inset: 0; background: rgba(20,10,8,.45); }
.share-panel { position: relative; width: 100%; max-width: 480px; background: var(--surface); border-radius: 20px 20px 0 0; padding: 14px 16px calc(18px + var(--safe-b)); }
@media (min-width: 600px) { .share-sheet { align-items: center; } .share-panel { border-radius: 20px; } }
.share-head { display: flex; align-items: center; justify-content: space-between; }
.share-title { font-weight: 600; margin: 8px 0 6px; }
.share-url { font-size: 13px; color: var(--muted); background: var(--section); border-radius: 10px; padding: 8px 10px; word-break: break-all; }
.share-actions { display: flex; gap: 8px; margin-top: 12px; }
.share-actions .btn { flex: 1 1 0; }
.toast {
  position: fixed; left: 50%; bottom: calc(var(--bottom-h) + var(--safe-b) + 16px); transform: translate(-50%, 10px); z-index: 3500;
  background: #241815; color: #fff; padding: 10px 16px; border-radius: 999px; font-size: 14px; opacity: 0; transition: opacity .2s, transform .2s; max-width: calc(100vw - 32px); text-align: center;
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }
@media (min-width: 900px) { .toast { bottom: 24px; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}

/* กล่องรูปแบบ aspect-ratio: ให้รูปวางแบบ absolute กันรูปแนวตั้งดันกล่องให้สูงเกินสัดส่วน */
.tile-img, .cm-img, .cf-img { overflow: hidden; }
.tile-img > img, .cm-img > img, .cf-img > img, .tile-img > .noimg, .cm-img > .noimg, .cf-img > .noimg { position: absolute; inset: 0; width: 100%; height: 100%; }
.gallery-track figure { overflow: hidden; position: relative; }
.gallery-track figure img { position: absolute; inset: 0; }

@media (min-width: 1100px) { .results .shop-list { grid-template-columns: 1fr 1fr; } }

/* ภาพปกภารกิจเป็น <img> (ไม่ใส่ URL ลง style attribute) + เงาไล่ทับด้วย ::before */
.mission-cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.mission-hero::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(46,21,20,.35), rgba(30,12,10,.9)); }
.mission-hero.no-cover::before { display: none; }
.mission-hero > .wrap { position: relative; z-index: 2; }
