/* mapSpot — single stylesheet.
   Direction: calm, tactile, a little warm. A travel journal: warm paper, moss ink,
   serif titles. The wordmark's “o” is a terracotta map pin.
   Replaces the old styles / catalog / home / editorial layers. */

/* ───────── Tokens ───────── */
:root {
  --bg: #f5f2eb;
  --surface: #fbf9f4;
  --raised: #ebe7dc;
  --line: rgb(28 38 32 / 0.1);
  --ink: #1c2620;
  --ink-2: #4d5850;
  --ink-3: #626d64;
  --accent: #2f5d46;
  --accent-ink: #ffffff;
  --scrim: 10 18 13;
  --pin: #d9704a;

  --font: system-ui, -apple-system, "PingFang TC", "Noto Sans TC", "Hiragino Sans", "Microsoft JhengHei", "Segoe UI", sans-serif;
  --serif: "Noto Serif TC", "Songti TC", "Source Han Serif TC", "Hiragino Mincho ProN", Georgia, serif;

  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
  --r-xl: 24px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-float: 0 1px 2px rgb(20 30 24 / 0.06), 0 8px 24px rgb(20 30 24 / 0.08);

  /* Legacy names still read by community-integration.css, legal.css and the photo editor. */
  --page: var(--bg);
  --navy: var(--ink);
  --muted: var(--ink-3);
  --soft: var(--raised);
  --blue: var(--accent);
  --accent-fill: var(--accent);
  --on-accent: var(--accent-ink);

  color-scheme: light;
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  background: var(--bg);
  font-synthesis: none;
}
:root[data-theme="dark"] {
  --bg: #111611;
  --surface: #181e19;
  --raised: #222a23;
  --line: rgb(236 240 230 / 0.1);
  --ink: #ecefe6;
  --ink-2: #aab3a6;
  --ink-3: #8a9486;
  --accent: #b4d69b;
  --accent-ink: #162218;
  --pin: #e8855f;
  --shadow-float: 0 1px 2px rgb(0 0 0 / 0.3), 0 8px 24px rgb(0 0 0 / 0.35);
  color-scheme: dark;
}

/* ───────── Base ───────── */
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); line-height: 1.6; }
body, input, select, button, textarea { font-family: var(--font); }
h1, h2, h3, p { margin: 0; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
button:disabled { cursor: not-allowed; }
a, button { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
::selection { background: color-mix(in srgb, var(--accent) 28%, transparent); }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip { position: absolute; top: -80px; left: 16px; z-index: 200; padding: 12px 16px; background: var(--ink); color: var(--bg); border-radius: var(--r-md); }
.skip:focus { top: 12px; }
.container { width: calc(100% - 64px); max-width: 1360px; margin-inline: auto; }
#main { padding-top: 88px; }
#main:focus { outline: none; }
#section-title:focus { outline: none; }
#catalog-top:empty { display: none; }

/* ───────── Kicker ───────── */
.eyebrow { display: flex; align-items: center; margin: 0 0 12px; font-size: 13px; line-height: 20px; font-weight: 500; color: var(--ink-3); }
.eyebrow:empty { display: none; }

/* ───────── Floating navigation ───────── */
.site-header { height: 0; position: static; border: 0; background: none; }
.header-inner { display: flex; align-items: center; justify-content: space-between; }
.header-inner.fixed-nav {
  position: fixed; z-index: 100; top: 12px; right: 12px; margin: 0;
  width: max-content; max-width: calc(100vw - 24px); min-height: 52px; height: auto;
  gap: 16px; padding: 6px 8px 6px 20px; border-radius: 999px; color: var(--ink); isolation: isolate;
}
.nav-surface {
  position: absolute; display: block; inset: 0; z-index: -1; pointer-events: none; transform-origin: right center;
  background: var(--surface); border: 1px solid var(--line); border-radius: inherit; box-shadow: var(--shadow-float);
}
.brand { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; white-space: nowrap; }
.brand img { display: block; width: auto; height: 22px; }
.brand .logo-dark { display: none; }
:root[data-theme="dark"] .brand .logo-light { display: none; }
:root[data-theme="dark"] .brand .logo-dark { display: block; }
.fixed-nav #global-nav { display: flex; align-items: center; gap: 4px; flex-wrap: nowrap; }
.fixed-nav #global-nav a {
  padding: 8px 12px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--ink-2); white-space: nowrap;
  transition: background-color 160ms var(--ease), color 160ms var(--ease);
}
.fixed-nav #global-nav a:hover, .fixed-nav #global-nav a:focus-visible { background: var(--raised); color: var(--ink); }
.fixed-nav #global-nav a[aria-current] { color: var(--ink); }
.preferences { display: flex; align-items: center; gap: 4px; flex-wrap: nowrap; }
.fixed-nav select { max-width: 96px; padding: 8px 4px; border: 0; background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 500; }
.fixed-nav #theme { display: none !important; }
.theme-toggle { display: grid; place-items: center; flex: none; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--ink-2); transition: background-color 160ms var(--ease), color 160ms var(--ease); }
.theme-toggle:hover, .theme-toggle:focus-visible { background: var(--raised); color: var(--ink); }
.theme-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.theme-toggle .sun-icon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun-icon { display: block; }
:root[data-theme="dark"] .theme-toggle .moon-icon { display: none; }
.account-entry { display: inline-flex; align-items: center; min-height: 36px; padding: 0 16px; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: 13px; font-weight: 500; white-space: nowrap; transition: opacity 160ms var(--ease); }
.account-entry:hover, .account-entry:focus-visible { opacity: 0.86; }
.nav-toggle { display: none; align-items: center; gap: 12px; padding: 8px 4px 8px 0; border: 0; background: none; color: inherit; font-size: 13px; font-weight: 600; white-space: nowrap; }
.nav-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; }
.fixed-nav[data-scrolled="true"]:not(.is-collapsed) .nav-toggle, .fixed-nav.is-collapsed .nav-toggle { display: flex; }
.fixed-nav.is-collapsed { min-height: 48px; max-width: 168px; padding-right: 16px; }
.fixed-nav.is-collapsed > :not(.nav-toggle):not(.nav-surface) { display: none !important; }
.community-menu { position: relative; }
.community-menu summary { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border-radius: 50%; overflow: hidden; cursor: pointer; list-style: none; background: var(--raised); font-size: 13px; font-weight: 500; }
.community-menu summary::-webkit-details-marker { display: none; }
.community-menu img { width: 100%; height: 100%; object-fit: cover; }
.community-options { position: absolute; z-index: 102; right: 0; top: 48px; width: 208px; padding: 8px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); color: var(--ink); box-shadow: var(--shadow-float); }
.community-options a, .community-options button { display: block; width: 100%; padding: 10px 12px; border: 0; border-radius: var(--r-md); background: none; color: inherit; text-align: left; font-size: 13px; font-weight: 500; }
.community-options a:hover, .community-options button:hover { background: var(--raised); }

/* ───────── Search bar and filters ───────── */
.global-bar { display: flex; justify-content: center; padding-top: 88px; }
#header-search { display: flex; align-items: center; width: 640px; max-width: 100%; height: 52px; padding: 0 8px 0 24px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
#header-search:focus-within { border-color: var(--accent); }
#header-query { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 15px; }
#header-query::placeholder { color: var(--ink-3); }
#header-search button { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--ink-2); transition: background-color 160ms var(--ease); }
#header-search button:hover { background: var(--raised); }
#header-search button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; }
.catalog-filters { margin: 16px 0 8px; font-size: 14px; color: var(--ink-2); }
.catalog-filters summary { display: inline-flex; align-items: center; min-height: 36px; cursor: pointer; }
.catalog-filters > div { display: flex; flex-wrap: wrap; gap: 16px; padding: 12px 0; }
.catalog-filters label { display: grid; gap: 8px; flex: 1; min-width: 152px; }
.catalog-filters select, #recommendation-form select { min-height: 44px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); color: var(--ink); font-size: 14px; }
.search-note { margin: 8px 0 24px; font-size: 13px; color: var(--ink-3); }

/* ───────── Hero ───────── */
.editorial-home #main { width: 100%; max-width: none; padding-top: 0; }
.editorial-home #catalog-top { margin: 12px; }
.editorial-hero {
  position: relative; isolation: isolate; display: flex; align-items: flex-end; gap: 48px; overflow: hidden;
  height: min(820px, 94vh); min-height: 592px; padding: 64px 48px; border-radius: var(--r-xl); background: #243b2d; color: #fff;
}
.hero-photo { position: absolute; inset: 0; z-index: -2; }
.hero-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgb(var(--scrim) / 0.82), transparent 72%), linear-gradient(90deg, rgb(var(--scrim) / 0.32), transparent 70%); }
.hero-copy { flex: 1; max-width: 800px; }
.hero-copy .eyebrow { color: rgb(255 255 255 / 0.86); font-size: 14px; }
.hero-copy h1 { font-family: var(--serif); font-weight: 500; font-size: clamp(40px, 5.6vw, 76px); line-height: 1.24; letter-spacing: -0.01em; text-wrap: balance; overflow-wrap: normal; }
.hero-actions { margin-top: 32px; }
.hero-primary { display: inline-flex; align-items: center; min-height: 48px; padding: 0 24px; border-radius: 999px; background: #f4f1e7; color: #1f3a2a; font-size: 15px; font-weight: 500; transition: background-color 160ms var(--ease); }
.hero-primary:hover, .hero-primary:focus-visible { background: #fff; }
.hero-primary:focus-visible { outline-color: #fff; }
.photo-caption { flex: 0 0 28%; max-width: 320px; }
.photo-caption > span { display: flex; align-items: center; gap: 6px; font-size: 14px; }
.photo-caption svg { width: 16px; height: 16px; flex: none; }
.photo-caption h2 { margin: 12px 0; font-family: var(--serif); font-size: 28px; line-height: 1.3; font-weight: 500; color: #fff; }
.photo-caption > p { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font-size: 14px; line-height: 1.7; color: rgb(255 255 255 / 0.9); }
.photo-caption .catalog-byline, .photo-caption .catalog-byline a { color: #fff; }
.photo-credit { position: absolute; right: 20px; bottom: 12px; font-size: 12px; color: rgb(255 255 255 / 0.7); }
.hero-no-photo .hero-copy { max-width: 800px; }

/* ───────── Section headings ───────── */
.directory { padding-top: 24px; }
.editorial-home .directory, .editorial-home .save-tip { width: calc(100% - 64px); max-width: 1360px; margin-inline: auto; }
.editorial-home .directory { padding-top: 0; }
.breadcrumbs { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; min-height: 24px; font-size: 13px; color: var(--ink-3); }
.breadcrumbs a:hover { color: var(--ink); }
.breadcrumbs [aria-current="page"] { color: var(--ink); }
.editorial-home .breadcrumbs, .journey-page .breadcrumbs, .journey-page .directory > .section-heading { display: none; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin: 32px 0 24px; }
.section-heading h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(26px, 3vw, 40px); line-height: 1.3; max-width: 1040px; }
.editorial-home .directory > .section-heading { margin-top: 64px; }
.count { font-size: 13px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.editorial-home #section-count { display: none; }
.explore-all { flex: none; display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--ink-2); transition: background-color 160ms var(--ease), color 160ms var(--ease); }
.explore-all:hover, .explore-all:focus-visible { background: var(--raised); color: var(--ink); }

/* ───────── Photo cards ───────── */
.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.card-grid .catalog-card, .card-grid .country-card {
  position: relative; isolation: isolate; height: 420px; overflow: hidden; border: 0; border-radius: 20px; background: #33513f; color: #fff;
  transition: box-shadow 160ms var(--ease);
}
.card-grid .catalog-card:hover, .card-grid .country-card:hover { box-shadow: 0 12px 28px rgb(var(--scrim) / 0.28); }
.catalog-card:focus-within { outline: 2px solid var(--accent); outline-offset: 3px; }
.country-card > a { display: block; height: 100%; }
.cover { position: relative; overflow: hidden; }
.card-grid .cover { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; }
.cover img { display: block; width: 100%; height: 100%; object-fit: cover; }
.card-grid .cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgb(var(--scrim) / 0.9), transparent 80%); pointer-events: none; }
.cover-fallback { display: flex; align-items: center; justify-content: center; height: 100%; padding: 24px; background: linear-gradient(140deg, #6f9380, #28402f); color: #eef3e8; font-family: var(--serif); font-size: 24px; text-align: center; }
.card-grid .card-tags { position: absolute; top: 16px; left: 16px; right: 16px; pointer-events: none; }
.catalog-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.catalog-chips a { padding: 4px 8px; border-radius: var(--r-sm); background: rgb(251 249 244 / 0.92); color: #263a2e; font-size: 12px; font-weight: 500; line-height: 16px; transition: background-color 160ms var(--ease); }
.catalog-chips a:hover, .catalog-chips a:focus-visible { background: #fff; }
.card-grid .card-body { position: absolute; inset: auto 0 0; display: flex; flex-direction: column; gap: 8px; padding: 20px; pointer-events: none; }
.card-grid .card-title { font-family: var(--serif); font-size: 24px; line-height: 1.3; font-weight: 500; color: #fff; }
.card-grid .card-description { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 13px; line-height: 20px; color: rgb(255 255 255 / 0.9); overflow-wrap: anywhere; }
.catalog-card .card-title a { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: inherit; }
.catalog-card .card-cover-link { position: absolute; inset: 0; z-index: 1; cursor: pointer; }
.catalog-card .card-body a, .catalog-card .card-tags a { position: relative; z-index: 3; pointer-events: auto; }
.catalog-match { font-size: 12px; color: rgb(255 255 255 / 0.88); }
.catalog-location { display: flex; align-items: center; gap: 6px; font-size: 12px; line-height: 16px; font-weight: 500; color: rgb(255 255 255 / 0.9); }
.catalog-location svg { flex: none; width: 14px; height: 14px; }
.catalog-footer { display: flex; align-items: center; gap: 8px; min-height: 24px; }
.card-grid .catalog-footer .catalog-byline { flex: 1; min-width: 0; }
.card-grid .card-arrow, .card-grid .region-tag, .card-grid .card-english { display: none; }
.card-grid .country-card .card-meta { display: flex; align-items: center; gap: 6px; font-size: 12px; color: rgb(255 255 255 / 0.9); }
.card-meta svg { width: 14px; height: 14px; flex: none; }

/* Byline and avatar */
.catalog-byline { display: flex; align-items: center; flex-wrap: wrap; gap: 4px; font-size: 12px; line-height: 24px; color: var(--ink-3); overflow-wrap: anywhere; }
.catalog-byline a { display: inline-flex; align-items: center; gap: 6px; border-radius: var(--r-sm); text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 3px; transition: text-decoration-color 160ms var(--ease); }
.catalog-byline a:hover, .catalog-byline a:focus-visible { text-decoration-color: currentColor; }
.catalog-card .catalog-byline { color: rgb(255 255 255 / 0.86); }
.catalog-card .catalog-byline a { color: #fff; }
.byline-avatar { position: relative; display: inline-grid; place-items: center; flex: none; width: 20px; height: 20px; overflow: hidden; border-radius: 50%; background: var(--raised); color: var(--accent); font-size: 12px; font-weight: 600; line-height: 1; }
.byline-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.byline-avatar img:not([src]) { display: none; }
.catalog-card .byline-avatar { background: rgb(251 249 244 / 0.92); color: #263a2e; }
.list-stats { margin-left: auto; font-size: 12px; font-variant-numeric: tabular-nums; color: var(--ink-3); }
.list-stats[data-empty] { visibility: hidden; }
.card-grid .list-stats { flex: none; color: rgb(255 255 255 / 0.86); }
.stats-count { font-size: inherit; white-space: nowrap; }

/* Home rail */
.editorial-home #cards { display: flex; gap: 16px; overflow-x: auto; padding-bottom: 8px; scrollbar-width: none; }
.editorial-home #cards .catalog-card { flex: 0 0 336px; height: 400px; }
.editorial-home [data-home-extra] { display: block; }
.drag-rail { cursor: grab; scrollbar-width: none; touch-action: pan-x pan-y; }
.drag-rail::-webkit-scrollbar { display: none; }
.drag-rail.dragging { cursor: grabbing; user-select: none; }

.cards-more { display: block; min-height: 44px; margin: 24px auto; padding: 0 28px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink); font-size: 14px; font-weight: 500; }
.cards-more[hidden] { display: none; }
.empty { grid-column: 1 / -1; padding: 48px 24px; border-radius: var(--r-lg); background: var(--raised); color: var(--ink-2); line-height: 1.8; }
.empty a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }

/* ───────── Creators ───────── */
.creator-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.creator-tile { display: flex; flex-direction: column; gap: 8px; height: 160px; min-height: 160px; padding: 20px 24px; border-radius: 20px; background: var(--raised); color: var(--ink); transition: background-color 160ms var(--ease), color 160ms var(--ease); }
.creator-tile:hover, .creator-tile:focus-visible { background: var(--accent); color: var(--accent-ink); }
.creator-tile .creator-heading { display: flex; align-items: center; gap: 12px; flex: none; min-height: 40px; }
.creator-tile h3 { font-size: 17px; line-height: 24px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.creator-tile p { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 14px; line-height: 22px; color: inherit; opacity: 0.86; }
.creator-tile small { margin-top: auto; font-size: 12px; line-height: 16px; color: inherit; opacity: 0.8; font-variant-numeric: tabular-nums; }
.creator-avatar { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--surface); color: var(--ink); }
.creator-avatar > .byline-avatar { width: 100%; height: 100%; font-size: 18px; background: transparent; color: inherit; }
#home-creators { margin-top: 64px; }
#home-creators .section-heading h2 { font-size: clamp(24px, 2.6vw, 32px); }
#home-creators .creator-grid { display: grid; grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: calc((100% - 32px) / 3); overflow-x: auto; scrollbar-width: none; margin-bottom: 0; }
.creator-controls { display: flex; align-items: center; gap: 12px; font-size: 13px; font-weight: 500; }
.creator-controls a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-2); transition: background-color 160ms var(--ease); }
.creator-controls a:hover { background: var(--raised); }
.creator-controls button { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: none; color: var(--ink-2); }
.creator-controls button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.card-grid .creator-tile { grid-column: auto; }
.profile-intro { padding: 36px 0 24px; }
.profile-banner { height: clamp(152px, 23vw, 300px); overflow: hidden; border-radius: var(--r-xl); background: var(--raised); }
.profile-banner img { display: block; width: 100%; height: 100%; object-fit: cover; }
.profile-intro > .creator-avatar { position: relative; width: 88px; height: 88px; margin: -44px 0 0 24px; border: 4px solid var(--bg); }
.profile-intro > .creator-avatar > .byline-avatar { font-size: 32px; }
.profile-intro h1 { margin: 16px 0 8px; font-family: var(--serif); font-weight: 500; font-size: clamp(28px, 3.5vw, 40px); line-height: 1.3; }
.profile-intro p { color: var(--ink-2); line-height: 1.8; }
.profile-intro a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }

/* ───────── List detail ───────── */
.detail-wrap { width: 100%; max-width: 1360px; margin: 0 auto; }
.detail-heading { max-width: 1152px; margin: 24px auto 32px; text-align: center; }
.detail-heading .eyebrow { justify-content: center; margin-bottom: 12px; }
.detail-heading h1 { font-family: var(--serif); font-weight: 500; font-size: clamp(32px, 4.6vw, 56px); line-height: 1.3; text-wrap: balance; }
.detail-intro.intro-stacked { display: flex; flex-direction: column; gap: 24px; max-width: 1200px; margin: 0 auto 40px; }
.detail-intro #intro { width: 100%; max-width: 1000px; margin-inline: auto; font-size: 16px; line-height: 1.9; color: var(--ink-2); }
.detail-intro #intro .catalog-byline { justify-content: center; margin-bottom: 16px; }
.detail-intro #intro p { max-width: 40rem; margin-inline: auto; text-wrap: pretty; }
.text-link { display: inline-block; margin-top: 12px; font-size: 14px; font-weight: 500; color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.detail-media { width: 100%; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--r-xl); background: var(--raised); }
.detail-media img, .detail-media iframe { display: block; width: 100%; height: 100%; border: 0; object-fit: cover; }
.detail-section { margin: 32px 0; }
.detail-section h2 { margin-bottom: 16px; font-family: var(--serif); font-weight: 500; font-size: 24px; line-height: 1.4; }
.reading-copy { max-width: 720px; line-height: 1.9; color: var(--ink-2); }
.reading-copy p + p { margin-top: 16px; }
.detail-wrap > .detail-section, .detail-wrap > .map-spots { width: calc(100% - 64px); max-width: 1240px; margin-inline: auto; }
.map-spots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
.map-spots section { min-width: 0; margin: 0; }
.spots-toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.spots-toolbar > a, .map-entry-menu summary { display: inline-flex; align-items: center; gap: 12px; min-height: 40px; padding: 0 20px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-size: 14px; font-weight: 500; list-style: none; cursor: pointer; transition: opacity 160ms var(--ease); }
.spots-toolbar > a:hover, .map-entry-menu summary:hover { opacity: 0.88; }
.map-entry-menu { position: relative; z-index: 4; max-width: 100%; }
.map-entry-menu summary::-webkit-details-marker { display: none; }
.map-entry-menu summary::after { content: ""; width: 14px; height: 14px; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat center / contain; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat center / contain; transition: transform 160ms var(--ease); }
.map-entry-menu[open] summary::after { transform: rotate(180deg); }
.map-entry-menu > div { position: absolute; top: calc(100% + 8px); left: 0; min-width: 208px; padding: 8px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); box-shadow: var(--shadow-float); }
.spots-toolbar .map-entry-menu a { display: block; padding: 10px 12px; border-radius: var(--r-md); color: var(--ink); font-size: 14px; }
.spots-toolbar .map-entry-menu a:hover { background: var(--raised); }
#spot-note { margin-bottom: 16px; font-size: 13px; line-height: 1.7; color: var(--ink-3); }
.spot-grid.vertical { display: flex; flex-direction: column; gap: 8px; max-height: 632px; overflow-y: auto; padding: 2px; scrollbar-width: thin; }
.spot { position: relative; isolation: isolate; flex-shrink: 0; overflow: hidden; padding: 16px 20px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); }
.spot.has-photo { min-height: 152px; }
.spot > div { position: relative; z-index: 2; max-width: 65%; }
.spot:not(.has-photo) > div { max-width: 100%; }
.spot small { font-size: 12px; font-variant-numeric: tabular-nums; color: var(--ink-3); }
.spot h3 { margin: 4px 0; font-size: 17px; line-height: 1.4; font-weight: 600; }
.spot p { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; margin: 4px 0; font-size: 13px; line-height: 1.7; color: var(--ink-2); }
.spot a { font-size: 13px; text-decoration: underline; text-underline-offset: 3px; color: var(--accent); }
.spot figure { position: absolute; inset: 0; z-index: 0; margin: 0; }
.spot figure::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--surface) 0%, color-mix(in srgb, var(--surface) 92%, transparent) 32%, transparent 100%); }
.spot figure img { width: 100%; height: 100%; object-fit: cover; }
.spot figcaption { position: absolute; z-index: 3; right: 8px; bottom: 8px; max-width: 70%; padding: 4px 8px; border-radius: var(--r-sm); background: rgb(var(--scrim) / 0.8); color: #fff; }
.spot figcaption a { font-size: 11px; color: #fff; text-decoration: none; }
.wide-map { display: block; width: 100%; height: 632px; border: 0; border-radius: var(--r-lg); }
.catalog-detail > .list-stats { margin-top: 24px; text-align: right; }

/* ───────── Legacy destination and collection pages ───────── */
.continent-nav { display: flex; flex-wrap: wrap; gap: 24px; margin-top: 32px; padding-bottom: 0; border-bottom: 1px solid var(--line); overflow-x: auto; }
.continent-tab { display: inline-flex; align-items: center; padding: 8px 0; border-bottom: 2px solid transparent; font-size: 14px; font-weight: 500; color: var(--ink-3); white-space: nowrap; transition: color 160ms var(--ease); }
.continent-tab:hover { color: var(--ink); }
.continent-tab[aria-current] { color: var(--accent); border-bottom-color: var(--accent); }
.map-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px; border: 1px solid var(--line); border-radius: 999px; background: var(--raised); color: var(--ink); font-size: 14px; font-weight: 500; transition: background-color 160ms var(--ease); }
.map-button:hover { background: var(--line); }
.map-button:disabled { color: var(--ink-3); background: var(--raised); opacity: 0.7; }
.map-button svg { width: 16px; height: 16px; }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 16px; }
.alternative-maps { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.theme-card .actions { grid-template-columns: 1fr; }
.story-link { display: flex; align-items: center; justify-content: center; min-height: 44px; margin-top: 16px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--raised); color: var(--ink); font-size: 14px; font-weight: 500; }
.travel-story { max-width: 832px; margin: auto; overflow: hidden; border: 1px solid var(--line); border-radius: var(--r-xl); background: var(--surface); }
.travel-story .cover { aspect-ratio: 2.2; }
.story-body { padding: clamp(20px, 4vw, 44px); }
.story-prose { margin: 32px 0; font-size: 17px; line-height: 1.95; overflow-wrap: anywhere; }
.story-prose p { white-space: pre-wrap; }
.embedded-map { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line); }
.embedded-map p, .translation-note { font-size: 14px; line-height: 1.8; color: var(--ink-3); }
.embedded-map iframe { display: block; width: 100%; height: 480px; max-height: 70vh; margin-top: 20px; border: 0; border-radius: var(--r-md); }
.story-body .actions { max-width: 440px; }
.combined { display: inline-block; margin-top: 12px; padding: 4px 8px; border-radius: var(--r-sm); background: var(--raised); color: var(--ink-2); font-size: 12px; }

/* ───────── Save tip, footer ───────── */
.save-tip { display: flex; align-items: center; gap: 16px; margin: 64px 0 48px; padding: 24px 0; border-block: 1px solid var(--line); }
.tip-icon { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--raised); color: var(--accent); }
.tip-icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.save-tip strong { display: block; font-size: 15px; font-weight: 600; }
.save-tip p { margin-top: 4px; font-size: 14px; line-height: 1.7; color: var(--ink-2); }
.site-footer { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 32px 0; border-top: 1px solid var(--line); }
.site-footer strong { display: block; font-size: 14px; font-weight: 600; }
.site-footer > div > span { display: block; margin-top: 8px; font-size: 13px; color: var(--ink-3); }
.release-version { display: block; margin-top: 8px; font-size: 12px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.footer-links { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px; font-size: 13px; color: var(--ink-3); }
.footer-links > a, .footer-links > button { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0; border: 0; background: none; color: inherit; font-size: inherit; transition: color 160ms var(--ease); }
.footer-links > a:hover, .footer-links > button:hover { color: var(--ink); }
.translation-footer { padding-bottom: 24px; }
#translation-notice { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--ink-3); }
#translation-notice img { display: block; max-width: 100%; height: auto; padding: 0; border-radius: var(--r-sm); background: #fff; }
#translation-notice > a:last-child { text-decoration: underline; text-underline-offset: 3px; }
.content-update { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 24px; padding: 16px 20px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--raised); font-size: 14px; }
.content-update button { min-height: 40px; padding: 0 16px; border: 0; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-size: 13px; font-weight: 500; }
.preview-banner { padding: 8px 20px; border-bottom: 1px solid var(--line); background: var(--raised); color: var(--ink-3); font-size: 12px; text-align: center; }

/* ───────── Dialogs and forms ───────── */
dialog { width: min(620px, calc(100% - 32px)); padding: 28px; border: 1px solid var(--line); border-radius: var(--r-xl); background: var(--surface); color: var(--ink); }
dialog::backdrop { background: rgb(var(--scrim) / 0.55); }
.dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.dialog-head h2 { font-family: var(--serif); font-weight: 500; font-size: 24px; }
.dialog-head button { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%; background: var(--raised); color: var(--ink); }
.dialog-head button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; }
#credits-list { font-size: 14px; line-height: 1.9; }
#credits-list a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
#credits-list p { padding-bottom: 12px; border-bottom: 1px solid var(--line); }
#recommendation-dialog { max-height: 90dvh; overflow: auto; }
#recommendation-dialog > p { line-height: 1.7; color: var(--ink-2); }
#recommendation-form label { display: block; margin: 16px 0; font-size: 14px; line-height: 1.7; }
#recommendation-form input:not([type="checkbox"]), #recommendation-form textarea, #recommendation-form select { display: block; width: 100%; min-height: 44px; margin-top: 4px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--bg); color: var(--ink); font-size: 15px; }
#recommendation-form input:focus, #recommendation-form textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
#recommendation-form .consent-label { display: flex; align-items: flex-start; gap: 8px; }
#recommendation-form input[type="checkbox"] { flex-shrink: 0; margin-top: 6px; }
#recommendation-form button[type="submit"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); padding-inline: 24px; }
#recommendation-result { overflow-wrap: anywhere; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ───────── Responsive ───────── */
@media (max-width: 1000px) {
  .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fixed-nav #global-nav { gap: 0; }
  .header-inner.fixed-nav { gap: 8px; }
  .photo-caption { max-width: 264px; }
}
@media (max-width: 850px) {
  .map-spots { grid-template-columns: 1fr; }
  .wide-map { height: 340px; }
  .spot-grid.vertical { max-height: 500px; }
  .editorial-hero { gap: 32px; padding: 48px 32px; }
  .photo-caption { flex-basis: 36%; }
  .photo-caption h2 { font-size: 24px; }
  #home-creators .creator-grid { grid-auto-columns: calc((100% - 16px) / 2); }
}
@media (max-width: 650px) {
  .container, .editorial-home .directory, .editorial-home .save-tip { width: calc(100% - 32px); }
  #main { padding-top: 112px; }
  .global-bar { padding-top: 112px; }
  .header-inner.fixed-nav { top: 8px; right: 8px; max-width: calc(100vw - 16px); min-height: 48px; padding: 6px 8px 6px 16px; gap: 4px; flex-wrap: wrap; justify-content: flex-end; border-radius: 24px; }
  .fixed-nav #global-nav a { padding: 8px; font-size: 12px; }
  .fixed-nav select { max-width: 76px; font-size: 12px; }
  .brand { font-size: 13px; }
  .editorial-home #catalog-top { margin: 8px; }
  .editorial-hero { flex-direction: column; align-items: flex-start; justify-content: flex-end; gap: 32px; height: 704px; min-height: 624px; padding: 32px 24px; border-radius: 20px; }
  .hero-copy { flex: 0; }
  .hero-copy h1 { font-size: 40px; }
  .hero-copy .eyebrow { font-size: 13px; }
  .photo-caption { flex: 0; width: 100%; max-width: 100%; }
  .photo-caption h2 { font-size: 20px; }
  .photo-caption > p { font-size: 13px; -webkit-line-clamp: 2; }
  .editorial-home .directory > .section-heading { margin-top: 48px; }
  .section-heading h2 { font-size: 26px; }
  .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .card-grid .catalog-card, .card-grid .country-card { height: 312px; border-radius: 16px; }
  .card-grid .card-body { gap: 4px; padding: 12px; }
  .card-grid .card-title { font-size: 18px; }
  .card-grid .card-description { font-size: 12px; line-height: 18px; }
  .card-grid .card-tags { top: 8px; left: 8px; right: 8px; }
  .catalog-chips { gap: 4px; }
  .catalog-chips a { padding: 2px 6px; }
  .card-grid .catalog-footer { flex-wrap: wrap; gap: 2px; }
  .card-grid .list-stats { margin-left: auto; }
  .editorial-home #cards { gap: 12px; }
  .editorial-home #cards .catalog-card { flex-basis: 248px; height: 320px; }
  .card-grid .creator-tile { grid-column: 1 / -1; }
  #home-creators .creator-grid { grid-auto-columns: 88%; }
  .detail-heading { margin-top: 8px; }
  .detail-intro #intro { font-size: 15px; }
  .detail-section h2 { font-size: 22px; }
  .detail-wrap > .detail-section, .detail-wrap > .map-spots { width: 100%; }
  .spot { padding: 16px; }
  .spot > div { max-width: 75%; }
  .site-footer { flex-direction: column; align-items: flex-start; }
  .form-grid { grid-template-columns: 1fr; gap: 0; }
  .actions { grid-template-columns: 1fr; }
  .save-tip { align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
