:root {
  --bg: #fffaf2;
  --panel: rgba(255,255,255,.78);
  --panel-strong: #fff;
  --ink: #1f1b16;
  --muted: #756b60;
  --line: #eadfce;
  --brand: #c9542c;
  --brand-dark: #8d321d;
  --accent: #26735d;
  --chip: #f6ead9;
  --shadow: 0 18px 45px rgba(85, 54, 28, .13);
}
* { box-sizing: border-box; }
body { margin: 0; font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; background: radial-gradient(circle at 20% 0%, #ffe7c6, transparent 34rem), var(--bg); color: var(--ink); }
a { color: inherit; }
.app-shell { min-height: 100vh; }
.hero { padding: 40px 40px 22px; display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: end; }
.eyebrow { color: var(--brand); font-weight: 800; letter-spacing: .08em; text-transform: uppercase; font-size: 12px; }
h1 { margin: 8px 0 10px; font-size: clamp(34px, 5vw, 72px); letter-spacing: -.06em; line-height: .95; }
.hero p { max-width: 720px; color: var(--muted); line-height: 1.65; margin: 0; }
.stats { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.stat { background: var(--panel-strong); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: 22px; padding: 13px 16px; min-width: 110px; }
.stat b { display:block; font-size: 24px; }
.stat span { color: var(--muted); font-size: 12px; }
.layout { padding: 0 40px 40px; display: grid; grid-template-columns: 310px 1fr; gap: 22px; align-items: start; }
.sidebar, .results, .detail-panel { background: var(--panel); border: 1px solid var(--line); border-radius: 28px; box-shadow: var(--shadow); backdrop-filter: blur(12px); }
.sidebar { position: sticky; top: 16px; padding: 18px; }
.section-title { display: flex; justify-content: space-between; align-items: baseline; margin: 8px 0 12px; font-weight: 900; }
.section-title small { color: var(--muted); font-weight: 600; }
.search { width: 100%; border: 1px solid var(--line); border-radius: 18px; padding: 13px 14px; background: #fff; font-size: 15px; outline: none; }
.search:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(201,84,44,.12); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.chip { border: 1px solid transparent; background: var(--chip); color: var(--ink); padding: 8px 10px; border-radius: 999px; cursor: pointer; font-weight: 700; font-size: 13px; }
.chip:hover { border-color: #e1c7a4; }
.chip.active { background: var(--brand); color: #fff; }
.chip .count { opacity: .68; margin-left: 5px; }
.clear-btn { border: 0; background: transparent; color: var(--brand-dark); cursor: pointer; font-weight: 800; }
.content { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 22px; }
.results { padding: 18px; }
.toolbar { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 14px; }
.path { color: var(--muted); font-size: 14px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.card { border: 1px solid var(--line); border-radius: 22px; padding: 16px; background: rgba(255,255,255,.84); cursor: pointer; transition: transform .15s ease, box-shadow .15s ease; }
.card:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(85,54,28,.12); }
.card.selected { outline: 3px solid rgba(201,84,44,.18); border-color: var(--brand); }
.card h3 { margin: 0 0 9px; font-size: 19px; letter-spacing: -.02em; }
.meta { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0; }
.badge { background: #f2f5e9; color: #52621f; padding: 5px 8px; border-radius: 999px; font-size: 12px; font-weight: 800; }
.badge.region { background: #e9f3ef; color: var(--accent); }
.address { color: var(--muted); line-height: 1.45; font-size: 14px; }
.video-title { color: var(--muted); font-size: 13px; line-height: 1.35; margin-top: 12px; }
.detail-panel { padding: 20px; position: sticky; top: 16px; }
.detail-panel h2 { margin: 0 0 12px; letter-spacing: -.04em; }
.detail-row { border-top: 1px solid var(--line); padding: 12px 0; }
.detail-row small { display:block; color: var(--muted); font-weight: 800; margin-bottom: 4px; }
.actions { display:flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.action { text-decoration:none; border-radius: 14px; padding: 10px 12px; background: var(--brand); color:#fff; font-weight: 900; }
.action.secondary { background: #efe2d1; color: var(--brand-dark); }
.mobile-filter { display:none; padding: 0 18px 18px; }
@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; padding: 26px 18px 16px; }
  .stats { justify-content: flex-start; }
  .layout { display: block; padding: 0 14px 28px; }
  .sidebar { position: static; margin-bottom: 14px; border-radius: 22px; }
  .content { display: block; }
  .detail-panel { position: static; margin-top: 14px; border-radius: 22px; }
  .cards { grid-template-columns: 1fr; }
  .toolbar { align-items: flex-start; flex-direction: column; }
}
@media (max-width: 640px) {
  h1 { font-size: 38px; }
  .hero p { font-size: 14px; }
  .stat { min-width: 96px; padding: 10px 12px; }
  .stat b { font-size: 20px; }
  .sidebar .desktop-only { display:none; }
  .mobile-filter { display:block; }
  .sidebar { padding: 14px; }
  .results { padding: 12px; }
  .card { border-radius: 18px; }
}

/* MoonBit UX variations: scoped so other implementations keep their original styling. */
.moon-mode {
  --m-bg: #f7f7f4;
  --m-surface: #ffffff;
  --m-surface-2: #f0f0eb;
  --m-ink: #171714;
  --m-muted: #65645d;
  --m-faint: #8a887f;
  --m-line: #deddd4;
  --m-line-strong: #c9c7bb;
  --m-accent: #b44625;
  --m-accent-soft: #f4e5de;
  --m-green: #386b58;
  color: var(--m-ink);
  background: var(--m-bg);
}
.moon-mode .hero,
.moon-mode .layout,
.moon-mode .flow-switcher { max-width: 1440px; margin-inline: auto; }
.moon-mode .hero { padding: 34px 32px 18px; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; align-items: end; }
.moon-mode .eyebrow { color: var(--m-muted); letter-spacing: 0; text-transform: none; font-size: 13px; font-weight: 700; }
.moon-mode h1 { margin: 8px 0 10px; max-width: 720px; font-size: clamp(42px, 5.4vw, 78px); line-height: .96; letter-spacing: -.035em; text-wrap: balance; }
.moon-mode .hero p { max-width: 650px; color: var(--m-muted); line-height: 1.55; }
.moon-mode .stats { gap: 0; border: 1px solid var(--m-line); background: var(--m-surface); border-radius: 14px; overflow: hidden; }
.moon-mode .stat { min-width: 104px; padding: 13px 16px; border: 0; border-radius: 0; box-shadow: none; background: transparent; }
.moon-mode .stat + .stat { border-left: 1px solid var(--m-line); }
.moon-mode .stat b { font-size: 22px; letter-spacing: -.02em; }
.moon-mode .stat span { color: var(--m-muted); font-size: 12px; }
.moon-mode .flow-switcher { padding: 0 32px 18px; display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 8px; }
.moon-mode .flow-tab { text-align: left; border: 1px solid var(--m-line); background: transparent; color: var(--m-ink); border-radius: 12px; padding: 11px 12px; cursor: pointer; transition: background .16s ease, border-color .16s ease, color .16s ease; }
.moon-mode .flow-tab span { display: block; font-weight: 760; font-size: 14px; }
.moon-mode .flow-tab small { display: block; color: var(--m-muted); margin-top: 3px; line-height: 1.25; }
.moon-mode .flow-tab:hover { background: var(--m-surface); border-color: var(--m-line-strong); }
.moon-mode .flow-tab.active { background: var(--m-ink); color: var(--m-surface); border-color: var(--m-ink); }
.moon-mode .flow-tab.active small { color: rgba(255,255,255,.72); }
.moon-mode .layout { padding: 0 32px 40px; gap: 14px; grid-template-columns: 288px minmax(0, 1fr); }
.moon-mode .sidebar,
.moon-mode .results,
.moon-mode .detail-panel { background: var(--m-surface); border: 1px solid var(--m-line); border-radius: 14px; box-shadow: none; backdrop-filter: none; }
.moon-mode .sidebar { top: 14px; padding: 14px; }
.moon-mode .content { gap: 14px; grid-template-columns: minmax(0, 1fr) 340px; }
.moon-mode .results { padding: 14px; }
.moon-mode .detail-panel { top: 14px; padding: 18px; }
.moon-mode .search { border-color: var(--m-line); border-radius: 10px; padding: 12px 12px; background: var(--m-bg); color: var(--m-ink); }
.moon-mode .search:focus { border-color: var(--m-ink); box-shadow: 0 0 0 3px rgba(23,23,20,.08); }
.moon-mode .section-title { margin: 14px 0 8px; font-size: 14px; font-weight: 760; }
.moon-mode .section-title small,
.moon-mode .path { color: var(--m-muted); }
.moon-mode .chips { gap: 6px; margin-bottom: 10px; }
.moon-mode .chip { background: transparent; color: var(--m-ink); border: 1px solid var(--m-line); border-radius: 999px; padding: 7px 9px; font-size: 12px; font-weight: 680; }
.moon-mode .chip:hover { border-color: var(--m-line-strong); background: var(--m-surface-2); }
.moon-mode .chip.active { background: var(--m-accent-soft); color: var(--m-accent); border-color: #dfb6a6; }
.moon-mode .clear-btn { color: var(--m-accent); padding: 8px 0 2px; }
.moon-mode .cards { grid-template-columns: repeat(auto-fill, minmax(244px, 1fr)); gap: 8px; }
.moon-mode .card { border-color: var(--m-line); border-radius: 12px; padding: 13px; background: var(--m-surface); transition: background .14s ease, border-color .14s ease, transform .14s ease; }
.moon-mode .card:hover { transform: none; box-shadow: none; background: #fbfbf8; border-color: var(--m-line-strong); }
.moon-mode .card.selected { outline: none; border-color: var(--m-ink); background: #fbfaf4; }
.moon-mode .card h3 { font-size: 17px; letter-spacing: -.015em; margin-bottom: 7px; }
.moon-mode .meta { gap: 5px; margin: 8px 0; }
.moon-mode .badge { background: var(--m-surface-2); color: var(--m-muted); border-radius: 999px; padding: 4px 7px; font-size: 11px; font-weight: 720; }
.moon-mode .badge.region { background: #e6eee9; color: var(--m-green); }
.moon-mode .address { color: var(--m-muted); font-size: 13px; line-height: 1.38; }
.moon-mode .video-title { color: var(--m-faint); font-size: 12px; }
.moon-mode .detail-panel h2 { letter-spacing: -.025em; line-height: 1.05; }
.moon-mode .detail-row { border-top-color: var(--m-line); padding: 10px 0; color: var(--m-ink); }
.moon-mode .detail-row small { color: var(--m-muted); font-weight: 720; }
.moon-mode .action { border-radius: 10px; padding: 10px 12px; background: var(--m-ink); color: var(--m-surface); }
.moon-mode .action.secondary { background: var(--m-surface-2); color: var(--m-ink); }
.moon-mode .empty-state { padding: 34px 22px; color: var(--m-muted); }
.moon-mode .empty-state h3 { margin: 0 0 6px; color: var(--m-ink); font-size: 18px; letter-spacing: -.015em; }
.moon-mode .empty-state p { margin: 0; line-height: 1.5; }

/* 1. Discover — balanced catalog: filters left, cards center, detail right. */
.mode-discover .content { grid-template-columns: minmax(0, 1fr) 340px; }
.mode-discover .cards { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }

/* 2. Focus — decision flow: detail becomes the reading pane before the list. */
.mode-focus .layout { grid-template-columns: 248px minmax(0, 1fr); }
.mode-focus .content { grid-template-columns: 430px minmax(0, 1fr); }
.mode-focus .detail-panel { order: -1; min-height: 520px; }
.mode-focus .cards { grid-template-columns: 1fr; }
.mode-focus .card { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; align-items: start; }
.mode-focus .card .address,
.mode-focus .card .video-title { grid-column: 1 / -1; }

/* 3. Nearby — location-first: filters become a top map-like rail, then results. */
.mode-nearby .layout { display: block; }
.mode-nearby .sidebar { position: static; margin-bottom: 14px; }
.mode-nearby .sidebar .chips { max-height: none; }
.mode-nearby .content { grid-template-columns: minmax(0, 1fr) 320px; }
.mode-nearby .cards { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.mode-nearby .sidebar { display: grid; grid-template-columns: 260px 1fr 1fr 1fr auto; gap: 12px; align-items: start; }
.mode-nearby .sidebar > .section-title { margin-top: 0; }

/* 4. Menu — craving-first: wider cards reveal foods, detail supports confirmation. */
.mode-menu .layout { grid-template-columns: 330px minmax(0, 1fr); }
.mode-menu .content { grid-template-columns: minmax(0, 1fr) 300px; }
.mode-menu .cards { grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); }
.mode-menu .card { padding: 15px; }
.mode-menu .card .meta:last-of-type .badge { background: var(--m-accent-soft); color: var(--m-accent); }

/* 5. Scan — lowest ink: dense list for quick compare. */
.mode-compact .hero { padding-bottom: 10px; }
.mode-compact h1 { font-size: 42px; }
.mode-compact .layout { grid-template-columns: 230px minmax(0, 1fr); }
.mode-compact .content { grid-template-columns: minmax(0, 1fr) 280px; }
.mode-compact .cards { display: block; }
.mode-compact .card { border-width: 0 0 1px; border-radius: 0; padding: 10px 4px; }
.mode-compact .card.selected { border-color: var(--m-ink); background: transparent; }
.mode-compact .card h3 { margin: 0 0 4px; font-size: 15px; }
.mode-compact .card .meta { display: inline-flex; margin: 0 8px 0 0; }
.mode-compact .card .video-title { display: none; }
.mode-compact .badge { padding: 2px 6px; }
.mode-compact .detail-panel,
.mode-compact .sidebar,
.mode-compact .results { background: transparent; }

/* 6. Anthropic — clean product alternative: stronger hierarchy, selected detail as the decision rail. */
.mode-anthropic {
  --m-bg: #f6f7f2;
  --m-surface: #ffffff;
  --m-surface-2: #eef1eb;
  --m-ink: #111715;
  --m-muted: #5f6864;
  --m-faint: #89918d;
  --m-line: #d9dfd8;
  --m-line-strong: #aeb9b1;
  --m-accent: #235bc8;
  --m-accent-soft: #e7eefc;
  --m-green: #2b6957;
  background:
    linear-gradient(90deg, rgba(17,23,21,.035) 1px, transparent 1px) 0 0 / 88px 88px,
    linear-gradient(180deg, #fbfcf8 0%, var(--m-bg) 44%, #eef1eb 100%);
}
.mode-anthropic .hero { padding-top: 42px; padding-bottom: 22px; align-items: center; }
.mode-anthropic .eyebrow { color: var(--m-accent); font-weight: 820; letter-spacing: .02em; }
.mode-anthropic h1 { max-width: 860px; font-size: clamp(48px, 6.7vw, 96px); line-height: .88; letter-spacing: -.07em; }
.mode-anthropic .hero p { max-width: 560px; font-size: 17px; color: #3f4945; }
.mode-anthropic .stats { border-radius: 22px; background: rgba(255,255,255,.86); box-shadow: 0 18px 54px rgba(45,57,51,.10); }
.mode-anthropic .stat { min-width: 126px; padding: 18px 20px; }
.mode-anthropic .stat b { font-size: 30px; }
.mode-anthropic .flow-tab { border-radius: 999px; padding: 10px 14px; background: rgba(255,255,255,.48); }
.mode-anthropic .flow-tab span { font-size: 13px; }
.mode-anthropic .flow-tab small { display: none; }
.mode-anthropic .flow-tab.active { background: var(--m-accent); border-color: var(--m-accent); color: #fff; }
.mode-anthropic .layout { grid-template-columns: 320px minmax(0, 1fr); gap: 18px; }
.mode-anthropic .content { grid-template-columns: minmax(0, 1fr) 390px; gap: 18px; align-items: start; }
.mode-anthropic .sidebar,
.mode-anthropic .results,
.mode-anthropic .detail-panel { border-radius: 24px; border-color: rgba(174,185,177,.70); background: rgba(255,255,255,.88); box-shadow: 0 20px 70px rgba(45,57,51,.09); }
.mode-anthropic .sidebar { padding: 18px; }
.mode-anthropic .results { padding: 0; overflow: hidden; }
.mode-anthropic .toolbar { margin: 0; padding: 20px 22px; border-bottom: 1px solid var(--m-line); background: rgba(251,252,248,.72); }
.mode-anthropic .section-title { font-size: 15px; margin: 16px 0 10px; }
.mode-anthropic .toolbar .section-title { margin: 0 0 5px; font-size: 18px; }
.mode-anthropic .path { max-width: 680px; font-size: 13px; }
.mode-anthropic .search { border-radius: 16px; padding: 15px 15px; background: #fff; font-size: 15px; }
.mode-anthropic .search:focus { border-color: var(--m-accent); box-shadow: 0 0 0 4px rgba(35,91,200,.11); }
.mode-anthropic .chip { border-radius: 12px; padding: 8px 10px; background: #fff; }
.mode-anthropic .chip.active { background: var(--m-accent); border-color: var(--m-accent); color: #fff; }
.mode-anthropic .cards { display: block; }
.mode-anthropic .card { position: relative; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(180px, .85fr); gap: 8px 18px; border-width: 0 0 1px; border-radius: 0; padding: 18px 22px 18px 28px; background: transparent; }
.mode-anthropic .card::before { content: ""; position: absolute; inset: 14px auto 14px 12px; width: 4px; border-radius: 999px; background: transparent; }
.mode-anthropic .card:hover { background: #fbfcf8; }
.mode-anthropic .card.selected { border-color: var(--m-line); background: var(--m-accent-soft); }
.mode-anthropic .card.selected::before { background: var(--m-accent); }
.mode-anthropic .card h3 { margin: 0; font-size: clamp(20px, 2vw, 30px); line-height: 1; letter-spacing: -.045em; }
.mode-anthropic .card .meta { margin: 0; align-content: start; }
.mode-anthropic .card .address { grid-column: 1; font-size: 14px; color: #48524e; }
.mode-anthropic .card .video-title { grid-column: 1 / -1; max-width: 720px; margin-top: 0; color: var(--m-faint); }
.mode-anthropic .badge { border-radius: 10px; background: var(--m-surface-2); color: #52605a; }
.mode-anthropic .badge.region { background: #e2f0ea; color: var(--m-green); }
.mode-anthropic .detail-panel { padding: 0; overflow: hidden; }
.mode-anthropic .detail-panel .eyebrow { padding: 20px 20px 0; }
.mode-anthropic .detail-panel h2 { margin: 4px 20px 18px; font-size: clamp(28px, 3vw, 42px); line-height: .94; letter-spacing: -.06em; }
.mode-anthropic .detail-panel > p { margin: 0; padding: 20px; }
.mode-anthropic .detail-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 16px; padding: 14px 20px; }
.mode-anthropic .detail-row small { margin: 0; color: var(--m-faint); }
.mode-anthropic .actions { padding: 18px 20px 20px; margin: 0; background: #f8faf5; border-top: 1px solid var(--m-line); }
.mode-anthropic .action { border-radius: 14px; background: var(--m-accent); }
.mode-anthropic .action.secondary { background: #e8ece5; color: var(--m-ink); }

/* 7. Taste: anti-template editorial food archive, with the selected record as the feature clipping. */
.mode-taste {
  --m-bg: #f2f4f1;
  --m-surface: #fbfbf7;
  --m-surface-2: #e9ece6;
  --m-ink: #171815;
  --m-muted: #62675f;
  --m-faint: #85897f;
  --m-line: #cfd4ca;
  --m-line-strong: #9fa89a;
  --m-accent: #c43e2f;
  --m-accent-soft: #f5dcd7;
  --m-green: #405f4b;
  background:
    linear-gradient(90deg, rgba(23,24,21,.06) 1px, transparent 1px) 0 0 / 42px 42px,
    linear-gradient(180deg, #fbfbf7 0%, var(--m-bg) 42%, #e8ece6 100%);
}
.mode-taste .hero {
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr);
  align-items: end;
  padding-top: 32px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--m-ink);
}
.mode-taste .eyebrow { color: var(--m-accent); font-weight: 780; letter-spacing: .01em; }
.mode-taste h1 {
  max-width: 820px;
  font-family: Georgia, "Times New Roman", ui-serif, serif;
  font-size: clamp(50px, 7.2vw, 112px);
  line-height: .9;
  letter-spacing: -.06em;
}
.mode-taste .hero p { max-width: 520px; font-size: 18px; color: #3d433c; }
.mode-taste .stats {
  justify-self: stretch;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-radius: 0;
  border-color: var(--m-ink);
  background: var(--m-surface);
}
.mode-taste .stat { padding: 16px 18px; }
.mode-taste .stat b { font-family: Georgia, "Times New Roman", ui-serif, serif; font-size: 34px; }
.mode-taste .stat span { color: var(--m-muted); }
.mode-taste .flow-switcher {
  border-bottom: 1px solid var(--m-line-strong);
  padding-top: 14px;
  padding-bottom: 14px;
  gap: 0;
}
.mode-taste .flow-tab {
  border-width: 0 0 1px;
  border-radius: 0;
  background: transparent;
  padding: 9px 10px 11px;
}
.mode-taste .flow-tab:hover { background: rgba(196,62,47,.06); }
.mode-taste .flow-tab.active { background: transparent; color: var(--m-accent); border-color: var(--m-accent); }
.mode-taste .flow-tab.active small { color: var(--m-accent); opacity: .72; }
.mode-taste .layout {
  grid-template-columns: 274px minmax(0, 1fr);
  gap: 20px;
  padding-top: 22px;
}
.mode-taste .sidebar,
.mode-taste .results,
.mode-taste .detail-panel {
  border-radius: 0;
  border-color: var(--m-line-strong);
  background: rgba(251,251,247,.92);
  box-shadow: none;
}
.mode-taste .sidebar {
  top: 18px;
  padding: 16px;
  border-left: 4px solid var(--m-ink);
}
.mode-taste .content {
  grid-template-columns: minmax(340px, .86fr) minmax(0, 1.14fr);
  gap: 20px;
  align-items: start;
}
.mode-taste .detail-panel {
  order: -1;
  top: 18px;
  padding: 0;
  overflow: hidden;
  border-color: var(--m-ink);
}
.mode-taste .detail-panel .eyebrow { padding: 18px 20px 0; color: var(--m-accent); }
.mode-taste .detail-panel h2 {
  margin: 6px 20px 20px;
  font-family: Georgia, "Times New Roman", ui-serif, serif;
  font-size: clamp(36px, 4vw, 60px);
  line-height: .9;
  letter-spacing: -.055em;
}
.mode-taste .detail-panel > p { margin: 0; padding: 18px 20px; }
.mode-taste .detail-row {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 14px;
  padding: 13px 20px;
  border-top-color: var(--m-line-strong);
}
.mode-taste .detail-row small { margin: 0; color: var(--m-faint); font-weight: 760; }
.mode-taste .actions {
  margin: 0;
  padding: 18px 20px 20px;
  border-top: 1px solid var(--m-ink);
  background: var(--m-surface-2);
}
.mode-taste .action { border-radius: 999px; background: var(--m-accent); color: #fffaf7; }
.mode-taste .action.secondary { background: transparent; color: var(--m-ink); border: 1px solid var(--m-ink); }
.mode-taste .results { padding: 0; overflow: hidden; }
.mode-taste .toolbar {
  margin: 0;
  padding: 17px 20px;
  border-bottom: 1px solid var(--m-line-strong);
  align-items: end;
}
.mode-taste .toolbar .section-title { margin: 0 0 5px; font-size: 18px; }
.mode-taste .path { color: var(--m-muted); }
.mode-taste .cards { display: block; }
.mode-taste .card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(160px, .56fr);
  gap: 7px 18px;
  padding: 18px 20px 18px 24px;
  border-width: 0 0 1px;
  border-radius: 0;
  background: transparent;
}
.mode-taste .card:hover { background: rgba(196,62,47,.045); transform: none; box-shadow: none; }
.mode-taste .card.selected { background: #fff6f3; border-color: var(--m-line-strong); outline: none; }
.mode-taste .card.selected::before { content: ""; position: absolute; inset: 14px auto 14px 0; width: 5px; background: var(--m-accent); }
.mode-taste .card h3 {
  margin: 0;
  font-family: Georgia, "Times New Roman", ui-serif, serif;
  font-size: clamp(23px, 2.5vw, 36px);
  line-height: .95;
  letter-spacing: -.045em;
}
.mode-taste .card .meta { margin: 0; align-content: start; }
.mode-taste .card .address { grid-column: 1; color: #555b53; }
.mode-taste .card .video-title { grid-column: 1 / -1; max-width: 760px; margin-top: 2px; color: var(--m-faint); }
.mode-taste .badge { border-radius: 0; background: var(--m-surface-2); color: #4e544d; }
.mode-taste .badge.region { background: #dfe8df; color: var(--m-green); }
.mode-taste .search {
  border-radius: 0;
  border-color: var(--m-ink);
  background: var(--m-surface);
}
.mode-taste .search:focus { border-color: var(--m-accent); box-shadow: 0 0 0 3px rgba(196,62,47,.14); }
.mode-taste .chip { border-radius: 0; background: transparent; }
.mode-taste .chip.active { background: var(--m-accent); border-color: var(--m-accent); color: #fffaf7; }
.mode-taste .clear-btn { color: var(--m-accent); }

/* 8. HighEnd — premium cinematic black-room layout with machined double-bezel panels. */
.mode-highend {
  --m-bg: #050505;
  --m-surface: rgba(12, 13, 15, .96);
  --m-surface-2: rgba(255, 255, 255, .055);
  --m-ink: #f8f4ec;
  --m-muted: #a59f96;
  --m-faint: #78736c;
  --m-line: rgba(255, 255, 255, .105);
  --m-line-strong: rgba(255, 255, 255, .18);
  --m-accent: #d7b56d;
  --m-accent-soft: rgba(215, 181, 109, .14);
  --m-green: #76d8b5;
  min-height: 100dvh;
  position: relative;
  isolation: isolate;
  overflow-x: clip;
  font-family: "Geist", "Plus Jakarta Sans", ui-sans-serif, system-ui, sans-serif;
  color: var(--m-ink);
  background:
    radial-gradient(circle at 12% -10%, rgba(117, 89, 255, .34), transparent 34rem),
    radial-gradient(circle at 86% 10%, rgba(55, 230, 173, .22), transparent 31rem),
    radial-gradient(circle at 48% 104%, rgba(215, 181, 109, .16), transparent 35rem),
    linear-gradient(180deg, #060607 0%, #050505 46%, #0a0908 100%);
}
.mode-highend::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='.8'/%3E%3C/svg%3E");
}
.mode-highend > * { position: relative; z-index: 1; }
.mode-highend .hero,
.mode-highend .layout,
.mode-highend .flow-switcher { max-width: 1540px; }
.mode-highend .hero {
  min-height: 52dvh;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, .72fr);
  align-items: end;
  gap: clamp(28px, 6vw, 92px);
  padding: clamp(72px, 9vw, 140px) 40px 30px;
  animation: highend-rise 900ms cubic-bezier(.32,.72,0,1) both;
}
.mode-highend .eyebrow {
  width: max-content;
  border: 1px solid rgba(215,181,109,.22);
  border-radius: 999px;
  padding: 7px 11px;
  background: rgba(215,181,109,.08);
  color: #e7c980;
  font-size: 10px;
  font-weight: 760;
  letter-spacing: .2em;
  text-transform: uppercase;
}
.mode-highend h1 {
  max-width: 980px;
  margin-top: 18px;
  font-family: "Clash Display", "Geist", "Plus Jakarta Sans", ui-sans-serif, system-ui, sans-serif;
  font-size: clamp(58px, 9vw, 142px);
  line-height: .82;
  letter-spacing: -.085em;
  text-wrap: balance;
}
.mode-highend .hero p {
  max-width: 640px;
  color: rgba(248,244,236,.68);
  font-size: clamp(16px, 1.45vw, 21px);
  line-height: 1.7;
}
.mode-highend .stats {
  justify-self: stretch;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  border: 1px solid rgba(255,255,255,.095);
  border-radius: 32px;
  padding: 6px;
  overflow: visible;
  background: rgba(255,255,255,.045);
  box-shadow: 0 34px 90px rgba(36, 20, 74, .18), inset 0 1px 0 rgba(255,255,255,.10);
}
.mode-highend .stat {
  min-width: 0;
  border: 0;
  border-radius: 26px;
  padding: 20px 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.09), rgba(255,255,255,.035));
  box-shadow: inset 0 1px 1px rgba(255,255,255,.16);
}
.mode-highend .stat + .stat { border-left: 0; }
.mode-highend .stat b {
  font-family: "Clash Display", "Geist", sans-serif;
  font-size: clamp(30px, 3.2vw, 50px);
  line-height: .9;
  letter-spacing: -.06em;
  color: #fffaf1;
}
.mode-highend .stat span { color: rgba(248,244,236,.54); font-size: 11px; letter-spacing: .05em; text-transform: uppercase; }
.mode-highend .flow-switcher {
  width: min(1140px, calc(100% - 80px));
  margin: 0 auto 32px;
  grid-template-columns: repeat(10, minmax(0, 1fr));
  gap: 4px;
  padding: 6px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 999px;
  background: rgba(255,255,255,.055);
  box-shadow: 0 28px 70px rgba(36, 20, 74, .16), inset 0 1px 0 rgba(255,255,255,.10);
  animation: highend-rise 900ms 90ms cubic-bezier(.32,.72,0,1) both;
}
.mode-highend .flow-tab {
  overflow: hidden;
  text-align: center;
  border: 0;
  border-radius: 999px;
  padding: 11px 13px;
  background: transparent;
  color: rgba(248,244,236,.72);
  transition: transform 700ms cubic-bezier(.32,.72,0,1), background 700ms cubic-bezier(.32,.72,0,1), color 700ms cubic-bezier(.32,.72,0,1);
}
.mode-highend .flow-tab:hover { transform: translateY(-1px); background: rgba(255,255,255,.075); }
.mode-highend .flow-tab span { font-size: 13px; font-weight: 760; }
.mode-highend .flow-tab small { display: none; }
.mode-highend .flow-tab.active {
  color: #0a0908;
  background: linear-gradient(135deg, #f3df9d 0%, #d7b56d 48%, #a67c37 100%);
  box-shadow: inset 0 1px 1px rgba(255,255,255,.52), 0 12px 30px rgba(215,181,109,.18);
}
.mode-highend .layout {
  grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  gap: 18px;
  padding: 0 40px clamp(64px, 8vw, 120px);
  animation: highend-rise 940ms 160ms cubic-bezier(.32,.72,0,1) both;
}
.mode-highend .content { grid-template-columns: minmax(0, 1fr) minmax(360px, 430px); gap: 18px; align-items: start; }
.mode-highend .sidebar,
.mode-highend .results,
.mode-highend .detail-panel {
  position: relative;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 32px;
  padding: 7px;
  background: rgba(255,255,255,.052);
  box-shadow: 0 36px 110px rgba(28, 19, 54, .20), inset 0 1px 0 rgba(255,255,255,.10);
}
.mode-highend .sidebar,
.mode-highend .detail-panel { backdrop-filter: blur(22px); }
.mode-highend .results { overflow: hidden; }
.mode-highend .sidebar::before,
.mode-highend .results::before,
.mode-highend .detail-panel::before,
.mode-highend .card::before {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 25px;
  background: linear-gradient(180deg, rgba(10,11,13,.98), rgba(13,13,15,.92));
  box-shadow: inset 0 1px 1px rgba(255,255,255,.14);
  pointer-events: none;
}
.mode-highend .sidebar > *,
.mode-highend .results > *,
.mode-highend .detail-panel > *,
.mode-highend .card > * { position: relative; z-index: 1; }
.mode-highend .sidebar { position: sticky; top: 22px; }
.mode-highend .detail-panel { position: sticky; top: 22px; padding: 8px; overflow: hidden; }
.mode-highend .search {
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 22px;
  padding: 16px 17px;
  background: rgba(255,255,255,.055);
  color: #fffaf1;
  font-size: 15px;
  transition: border-color 700ms cubic-bezier(.32,.72,0,1), box-shadow 700ms cubic-bezier(.32,.72,0,1), transform 700ms cubic-bezier(.32,.72,0,1);
}
.mode-highend .search::placeholder { color: rgba(248,244,236,.42); }
.mode-highend .search:focus { border-color: rgba(215,181,109,.62); box-shadow: 0 0 0 5px rgba(215,181,109,.11); transform: translateY(-1px); }
.mode-highend .section-title { margin: 20px 7px 10px; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; }
.mode-highend .section-title small,
.mode-highend .path { color: rgba(248,244,236,.46); }
.mode-highend .chips { gap: 7px; margin: 0 0 14px; }
.mode-highend .chip {
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 999px;
  padding: 8px 10px;
  background: rgba(255,255,255,.045);
  color: rgba(248,244,236,.72);
  font-size: 12px;
  font-weight: 720;
  transition: transform 700ms cubic-bezier(.32,.72,0,1), border-color 700ms cubic-bezier(.32,.72,0,1), background 700ms cubic-bezier(.32,.72,0,1), color 700ms cubic-bezier(.32,.72,0,1);
}
.mode-highend .chip:hover { transform: translateY(-1px); border-color: rgba(255,255,255,.22); background: rgba(255,255,255,.075); }
.mode-highend .chip.active { border-color: rgba(215,181,109,.55); background: rgba(215,181,109,.16); color: #f4d98d; }
.mode-highend .clear-btn { color: #e6c87e; padding: 10px 7px 4px; transition: transform 700ms cubic-bezier(.32,.72,0,1), color 700ms cubic-bezier(.32,.72,0,1); }
.mode-highend .clear-btn:hover { transform: translateX(2px); color: #ffe7a4; }
.mode-highend .toolbar {
  margin: 0;
  padding: 18px 19px 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.mode-highend .toolbar .section-title { margin: 0 0 6px; font-size: 15px; color: #fffaf1; }
.mode-highend .cards {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-auto-flow: dense;
  gap: 8px;
  padding: 8px;
}
.mode-highend .card {
  min-height: 188px;
  grid-column: span 3;
  position: relative;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 30px;
  padding: 22px;
  background: rgba(255,255,255,.05);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08);
  transition: transform 760ms cubic-bezier(.32,.72,0,1), border-color 760ms cubic-bezier(.32,.72,0,1), background 760ms cubic-bezier(.32,.72,0,1), box-shadow 760ms cubic-bezier(.32,.72,0,1);
  animation: highend-card 820ms cubic-bezier(.32,.72,0,1) both;
}
.mode-highend .card:nth-child(6n+1) { grid-column: span 4; }
.mode-highend .card:nth-child(6n+4) { grid-column: span 2; }
.mode-highend .card:nth-child(2) { animation-delay: 60ms; }
.mode-highend .card:nth-child(3) { animation-delay: 100ms; }
.mode-highend .card:nth-child(4) { animation-delay: 140ms; }
.mode-highend .card::before { inset: 6px; border-radius: 24px; background: linear-gradient(180deg, rgba(255,255,255,.065), rgba(255,255,255,.026)); }
.mode-highend .card:hover { transform: translateY(-4px) rotate(-.35deg); border-color: rgba(215,181,109,.30); background: rgba(255,255,255,.075); box-shadow: 0 20px 54px rgba(28, 19, 54, .16), inset 0 1px 0 rgba(255,255,255,.10); }
.mode-highend .card.selected { grid-column: span 6; min-height: 230px; border-color: rgba(215,181,109,.56); outline: none; background: linear-gradient(135deg, rgba(215,181,109,.16), rgba(255,255,255,.055)); }
.mode-highend .card h3 {
  max-width: 620px;
  font-family: "Clash Display", "Geist", sans-serif;
  font-size: clamp(22px, 2.3vw, 38px);
  line-height: .94;
  letter-spacing: -.055em;
  color: #fffaf1;
}
.mode-highend .card.selected h3 { font-size: clamp(34px, 4.8vw, 72px); }
.mode-highend .meta { gap: 6px; margin: 13px 0; }
.mode-highend .badge {
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 999px;
  padding: 5px 8px;
  background: rgba(255,255,255,.065);
  color: rgba(248,244,236,.63);
  font-size: 11px;
  font-weight: 760;
}
.mode-highend .badge.region { color: #97e6c6; background: rgba(118,216,181,.10); border-color: rgba(118,216,181,.20); }
.mode-highend .address { color: rgba(248,244,236,.58); line-height: 1.55; }
.mode-highend .video-title { color: rgba(248,244,236,.42); margin-top: 14px; }
.mode-highend .detail-panel .eyebrow { margin: 16px 16px 0; }
.mode-highend .detail-panel h2 {
  margin: 16px;
  font-family: "Clash Display", "Geist", sans-serif;
  font-size: clamp(38px, 4.6vw, 66px);
  line-height: .86;
  letter-spacing: -.07em;
  color: #fffaf1;
}
.mode-highend .detail-panel > p { margin: 0; padding: 20px; color: rgba(248,244,236,.64); }
.mode-highend .detail-row {
  display: grid;
  grid-template-columns: 94px minmax(0, 1fr);
  gap: 18px;
  margin: 0 8px;
  padding: 14px 10px;
  border-top: 1px solid rgba(255,255,255,.085);
  color: rgba(248,244,236,.76);
}
.mode-highend .detail-row small { margin: 0; color: rgba(248,244,236,.42); font-size: 10px; letter-spacing: .15em; text-transform: uppercase; }
.mode-highend .actions { margin: 0; padding: 18px 16px 16px; }
.mode-highend .action {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border-radius: 999px;
  padding: 7px 7px 7px 18px;
  background: linear-gradient(135deg, #f4df9e, #d7b56d 55%, #9f7432);
  color: #080706;
  box-shadow: inset 0 1px 1px rgba(255,255,255,.52), 0 18px 42px rgba(215,181,109,.16);
  transition: transform 700ms cubic-bezier(.32,.72,0,1), box-shadow 700ms cubic-bezier(.32,.72,0,1);
}
.mode-highend .action::after {
  content: "↗";
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(5,5,5,.14);
  transition: transform 700ms cubic-bezier(.32,.72,0,1), background 700ms cubic-bezier(.32,.72,0,1);
}
.mode-highend .action:hover::after { transform: translate(3px, -1px) scale(1.05); background: rgba(5,5,5,.22); }
.mode-highend .action:active { transform: scale(.98); }
.mode-highend .action.secondary { background: rgba(255,255,255,.075); color: #fffaf1; box-shadow: inset 0 1px 1px rgba(255,255,255,.13); }
@keyframes highend-rise { from { opacity: 0; transform: translateY(38px); } to { opacity: 1; transform: translateY(0); } }
@keyframes highend-card { from { opacity: 0; transform: translateY(28px) scale(.985); } to { opacity: 1; transform: translateY(0) scale(1); } }
@media (prefers-reduced-motion: reduce) {
  .mode-highend .hero,
  .mode-highend .layout,
  .mode-highend .flow-switcher,
  .mode-highend .card { animation: none; }
  .mode-highend .flow-tab,
  .mode-highend .card,
  .mode-highend .chip,
  .mode-highend .search,
  .mode-highend .action,
  .mode-highend .action::after { transition: none; }
}

/* 9. Impeccable — polished app shell: refined controls, visible states, decision-first inspector. */
.mode-impeccable {
  --m-bg: oklch(96.8% 0.009 248);
  --m-surface: oklch(99.2% 0.003 248);
  --m-surface-2: oklch(94.4% 0.012 248);
  --m-ink: oklch(20% 0.025 248);
  --m-muted: oklch(42% 0.028 248);
  --m-faint: oklch(56% 0.022 248);
  --m-line: oklch(86.5% 0.018 248);
  --m-line-strong: oklch(75% 0.025 248);
  --m-accent: oklch(47% 0.15 246);
  --m-accent-soft: oklch(93.5% 0.035 246);
  --m-green: oklch(39% 0.09 166);
  --state-warning: oklch(56% 0.12 72);
  min-height: 100dvh;
  background: var(--m-bg);
  color: var(--m-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.mode-impeccable .hero,
.mode-impeccable .layout,
.mode-impeccable .flow-switcher { max-width: 1520px; }
.mode-impeccable .hero {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  padding: 24px 32px 16px;
  border-bottom: 1px solid var(--m-line);
}
.mode-impeccable .eyebrow { color: var(--m-accent); font-size: 13px; font-weight: 760; letter-spacing: 0; text-transform: none; }
.mode-impeccable h1 { max-width: 680px; margin: 6px 0 8px; font-size: 2.25rem; line-height: 1.05; letter-spacing: -.025em; text-wrap: balance; }
.mode-impeccable .hero p { max-width: 680px; color: var(--m-muted); font-size: 15px; line-height: 1.55; text-wrap: pretty; }
.mode-impeccable .stats {
  align-self: stretch;
  display: grid;
  grid-template-columns: repeat(3, minmax(88px, 1fr));
  border: 1px solid var(--m-line);
  border-radius: 16px;
  background: var(--m-surface);
  overflow: hidden;
}
.mode-impeccable .stat { min-width: 0; padding: 14px 16px; background: transparent; border: 0; box-shadow: none; }
.mode-impeccable .stat + .stat { border-left: 1px solid var(--m-line); }
.mode-impeccable .stat b { color: var(--m-ink); font-size: 24px; line-height: 1; letter-spacing: -.03em; }
.mode-impeccable .stat span { color: var(--m-muted); font-size: 12px; }
.mode-impeccable .flow-switcher {
  display: flex;
  gap: 6px;
  padding: 12px 32px;
  overflow-x: auto;
  border-bottom: 1px solid var(--m-line);
  scrollbar-width: thin;
}
.mode-impeccable .flow-tab {
  flex: 0 0 132px;
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 9px 11px;
  background: transparent;
  color: var(--m-muted);
  transition: background .18s ease, border-color .18s ease, color .18s ease;
}
.mode-impeccable .flow-tab:hover { background: var(--m-surface); border-color: var(--m-line); color: var(--m-ink); }
.mode-impeccable .flow-tab.active { background: var(--m-accent); border-color: var(--m-accent); color: #fff; }
.mode-impeccable .flow-tab span { font-size: 13px; font-weight: 780; }
.mode-impeccable .flow-tab small { display: none; }
.mode-impeccable .layout { grid-template-columns: 304px minmax(0, 1fr); gap: 16px; padding: 16px 32px 42px; }
.mode-impeccable .sidebar,
.mode-impeccable .results,
.mode-impeccable .detail-panel { border: 1px solid var(--m-line); border-radius: 16px; background: var(--m-surface); box-shadow: none; backdrop-filter: none; }
.mode-impeccable .sidebar { top: 16px; padding: 16px; }
.mode-impeccable .content { grid-template-columns: minmax(0, 1fr) 376px; gap: 16px; align-items: start; }
.mode-impeccable .results { padding: 0; overflow: hidden; }
.mode-impeccable .toolbar { margin: 0; padding: 16px 18px; border-bottom: 1px solid var(--m-line); background: var(--m-surface-2); }
.mode-impeccable .toolbar .section-title { margin: 0 0 5px; font-size: 16px; }
.mode-impeccable .section-title { margin: 16px 0 8px; font-size: 13px; font-weight: 780; }
.mode-impeccable .section-title small,
.mode-impeccable .path { color: var(--m-muted); }
.mode-impeccable .search {
  border-color: var(--m-line-strong);
  border-radius: 12px;
  padding: 13px 13px;
  background: var(--m-surface);
  color: var(--m-ink);
  font-size: 14px;
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}
.mode-impeccable .search::placeholder { color: var(--m-muted); }
.mode-impeccable .search:focus { border-color: var(--m-accent); box-shadow: 0 0 0 4px oklch(47% 0.15 246 / .14); }
.mode-impeccable button:focus-visible,
.mode-impeccable a:focus-visible,
.mode-impeccable .search:focus-visible { outline: 3px solid oklch(47% 0.15 246 / .30); outline-offset: 2px; }
.mode-impeccable .chips { gap: 6px; margin-bottom: 12px; }
.mode-impeccable .chip {
  border: 1px solid var(--m-line);
  border-radius: 999px;
  background: var(--m-surface);
  color: var(--m-ink);
  padding: 7px 9px;
  font-size: 12px;
  font-weight: 720;
  transition: background .18s ease, border-color .18s ease, color .18s ease;
}
.mode-impeccable .chip:hover { border-color: var(--m-line-strong); background: var(--m-surface-2); }
.mode-impeccable .chip.active { background: var(--m-accent-soft); border-color: var(--m-accent); color: var(--m-accent); }
.mode-impeccable .chip:disabled { opacity: .55; cursor: not-allowed; }
.mode-impeccable .chip .count { color: var(--m-faint); opacity: 1; }
.mode-impeccable .chip.active .count { color: currentColor; opacity: .78; }
.mode-impeccable .clear-btn { color: var(--m-accent); padding: 8px 0 0; text-decoration: underline; text-underline-offset: 3px; }
.mode-impeccable .clear-btn:hover { color: var(--m-ink); }
.mode-impeccable .cards { display: block; }
.mode-impeccable .card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(170px, .48fr);
  gap: 7px 16px;
  border-width: 0 0 1px;
  border-color: var(--m-line);
  border-radius: 0;
  padding: 16px 18px;
  background: transparent;
  transition: background .18s ease, border-color .18s ease;
}
.mode-impeccable .card:hover { transform: none; box-shadow: none; background: oklch(97.8% 0.012 248); border-color: var(--m-line-strong); }
.mode-impeccable .card.selected { outline: none; background: var(--m-accent-soft); border-color: var(--m-accent); box-shadow: inset 0 0 0 1px var(--m-accent); }
.mode-impeccable .card h3 { margin: 0; color: var(--m-ink); font-size: 18px; line-height: 1.15; letter-spacing: -.02em; }
.mode-impeccable .card .meta { margin: 0; align-content: start; }
.mode-impeccable .card .address { grid-column: 1; color: var(--m-muted); font-size: 13px; line-height: 1.4; }
.mode-impeccable .card .video-title { grid-column: 1 / -1; margin-top: 2px; color: var(--m-faint); font-size: 12px; }
.mode-impeccable .badge { border: 1px solid transparent; border-radius: 999px; background: var(--m-surface-2); color: var(--m-muted); padding: 4px 7px; font-size: 11px; font-weight: 760; }
.mode-impeccable .badge.region { background: oklch(93% 0.03 166); color: var(--m-green); }
.mode-impeccable .detail-panel { top: 16px; padding: 0; overflow: hidden; }
.mode-impeccable .detail-panel .eyebrow { padding: 18px 18px 0; color: var(--m-muted); }
.mode-impeccable .detail-panel h2 { margin: 5px 18px 16px; font-size: 1.55rem; line-height: 1.08; letter-spacing: -.03em; }
.mode-impeccable .detail-panel > p { margin: 0; padding: 18px; color: var(--m-muted); }
.mode-impeccable .detail-row { display: grid; grid-template-columns: 94px minmax(0, 1fr); gap: 14px; padding: 12px 18px; border-top-color: var(--m-line); color: var(--m-ink); }
.mode-impeccable .detail-row small { margin: 0; color: var(--m-muted); font-size: 12px; font-weight: 760; }
.mode-impeccable .actions { margin: 0; padding: 16px 18px 18px; border-top: 1px solid var(--m-line); background: var(--m-surface-2); }
.mode-impeccable .action { border-radius: 12px; padding: 10px 12px; background: var(--m-accent); color: #fff; transition: background .18s ease, transform .18s ease; }
.mode-impeccable .action:hover { background: oklch(40% 0.15 246); transform: translateY(-1px); }
.mode-impeccable .action:active { transform: translateY(0); }
.mode-impeccable .action.secondary { background: var(--m-surface); color: var(--m-ink); border: 1px solid var(--m-line-strong); }
.mode-impeccable .empty-state { padding: 42px 24px; }
.mode-impeccable .empty-state h3 { font-size: 20px; }
@media (prefers-reduced-motion: reduce) {
  .mode-impeccable .flow-tab,
  .mode-impeccable .chip,
  .mode-impeccable .card,
  .mode-impeccable .search,
  .mode-impeccable .action { transition: none; }
  .mode-impeccable .action:hover { transform: none; }
}

/* 10. Foundations — visual foundations pass: type scale, 8px rhythm, semantic color, measured composition. */
.mode-foundations {
  --m-bg: #f7f3eb;
  --m-surface: #fffdfa;
  --m-surface-2: #f0e9dd;
  --m-ink: #17130f;
  --m-muted: #655d53;
  --m-faint: #8a8175;
  --m-line: #ded2c0;
  --m-line-strong: #b9aa94;
  --m-accent: #285f4d;
  --m-accent-soft: #e5f0ea;
  --m-green: #285f4d;
  --foundation-warm: #a44d2f;
  min-height: 100dvh;
  background:
    linear-gradient(90deg, rgba(23,19,15,.045) 1px, transparent 1px) 0 0 / 64px 64px,
    linear-gradient(180deg, #fffdfa 0%, var(--m-bg) 48%, #eee5d7 100%);
  color: var(--m-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.mode-foundations .hero,
.mode-foundations .layout,
.mode-foundations .flow-switcher { max-width: 1408px; }
.mode-foundations .hero {
  grid-template-columns: minmax(0, 1fr) minmax(280px, 384px);
  gap: 48px;
  align-items: end;
  padding: 48px 32px 24px;
}
.mode-foundations .eyebrow { color: var(--m-accent); font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.mode-foundations h1 { max-width: 760px; margin: 8px 0 16px; font-size: clamp(48px, 6.6vw, 88px); line-height: .98; letter-spacing: -.055em; text-wrap: balance; }
.mode-foundations .hero p { max-width: 65ch; color: var(--m-muted); font-size: clamp(16px, 1.25vw, 18px); line-height: 1.65; }
.mode-foundations .stats {
  align-self: stretch;
  display: grid;
  grid-template-columns: 1fr;
  border: 1px solid var(--m-line-strong);
  border-radius: 24px;
  background: rgba(255,253,250,.86);
  box-shadow: 0 18px 54px rgba(58,43,28,.08);
  overflow: hidden;
}
.mode-foundations .stat { min-width: 0; display: grid; grid-template-columns: 84px 1fr; gap: 16px; align-items: baseline; padding: 18px 20px; border: 0; background: transparent; box-shadow: none; }
.mode-foundations .stat + .stat { border-left: 0; border-top: 1px solid var(--m-line); }
.mode-foundations .stat b { font-size: 32px; line-height: 1; letter-spacing: -.04em; color: var(--m-ink); }
.mode-foundations .stat span { color: var(--m-muted); font-size: 13px; line-height: 1.3; }
.mode-foundations .flow-switcher {
  display: flex;
  gap: 8px;
  padding: 0 32px 24px;
  overflow-x: auto;
  scrollbar-width: thin;
}
.mode-foundations .flow-tab {
  flex: 0 0 132px;
  border: 1px solid var(--m-line);
  border-radius: 999px;
  padding: 10px 14px;
  background: rgba(255,253,250,.62);
  color: var(--m-muted);
  text-align: center;
  transition: background .18s ease, border-color .18s ease, color .18s ease, transform .18s ease;
}
.mode-foundations .flow-tab span { font-size: 13px; font-weight: 800; }
.mode-foundations .flow-tab small { display: none; }
.mode-foundations .flow-tab:hover { transform: translateY(-1px); border-color: var(--m-line-strong); background: var(--m-surface); color: var(--m-ink); }
.mode-foundations .flow-tab.active { background: var(--m-accent); border-color: var(--m-accent); color: #fffdfa; }
.mode-foundations .layout { grid-template-columns: 304px minmax(0, 1fr); gap: 24px; padding: 0 32px 56px; }
.mode-foundations .content { grid-template-columns: minmax(0, 1fr) 384px; gap: 24px; align-items: start; }
.mode-foundations .sidebar,
.mode-foundations .results,
.mode-foundations .detail-panel { border: 1px solid var(--m-line); border-radius: 24px; background: rgba(255,253,250,.9); box-shadow: 0 16px 48px rgba(58,43,28,.07); backdrop-filter: blur(10px); }
.mode-foundations .sidebar { top: 24px; padding: 24px; }
.mode-foundations .results { padding: 0; overflow: hidden; }
.mode-foundations .detail-panel { top: 24px; padding: 0; overflow: hidden; }
.mode-foundations .search { border-color: var(--m-line-strong); border-radius: 16px; padding: 14px 16px; background: #fffdfa; color: var(--m-ink); font-size: 16px; line-height: 1.5; }
.mode-foundations .search::placeholder { color: var(--m-faint); }
.mode-foundations .search:focus { border-color: var(--m-accent); box-shadow: 0 0 0 4px rgba(40,95,77,.13); }
.mode-foundations button:focus-visible,
.mode-foundations a:focus-visible,
.mode-foundations .search:focus-visible { outline: 3px solid rgba(40,95,77,.28); outline-offset: 3px; }
.mode-foundations .section-title { margin: 24px 0 12px; font-size: 14px; font-weight: 800; line-height: 1.3; }
.mode-foundations .section-title small,
.mode-foundations .path { color: var(--m-muted); }
.mode-foundations .chips { gap: 8px; margin-bottom: 8px; }
.mode-foundations .chip { border: 1px solid var(--m-line); border-radius: 999px; background: #fffdfa; color: var(--m-ink); padding: 8px 11px; font-size: 13px; font-weight: 720; }
.mode-foundations .chip:hover { border-color: var(--m-line-strong); background: var(--m-surface-2); }
.mode-foundations .chip.active { background: var(--m-accent-soft); border-color: var(--m-accent); color: var(--m-accent); }
.mode-foundations .chip .count { color: var(--m-faint); opacity: 1; }
.mode-foundations .chip.active .count { color: currentColor; opacity: .8; }
.mode-foundations .clear-btn { margin-top: 8px; color: var(--foundation-warm); text-decoration: underline; text-underline-offset: 4px; }
.mode-foundations .toolbar { margin: 0; padding: 24px; border-bottom: 1px solid var(--m-line); background: rgba(240,233,221,.58); }
.mode-foundations .toolbar .section-title { margin: 0 0 8px; font-size: 18px; }
.mode-foundations .path { max-width: 72ch; font-size: 14px; line-height: 1.5; }
.mode-foundations .cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(272px, 1fr)); gap: 16px; padding: 16px; }
.mode-foundations .card { position: relative; border-color: var(--m-line); border-radius: 20px; padding: 20px; background: #fffdfa; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.mode-foundations .card:hover { transform: translateY(-2px); border-color: var(--m-line-strong); box-shadow: 0 14px 32px rgba(58,43,28,.08); }
.mode-foundations .card.selected { outline: none; border-color: var(--m-accent); background: linear-gradient(180deg, #fffdfa, #f6fbf7); box-shadow: inset 0 0 0 2px rgba(40,95,77,.16); }
.mode-foundations .card.selected::before { content: ""; position: absolute; inset: 18px auto 18px 0; width: 4px; border-radius: 0 999px 999px 0; background: var(--m-accent); }
.mode-foundations .card h3 { margin: 0 0 12px; font-size: 21px; line-height: 1.2; letter-spacing: -.025em; }
.mode-foundations .meta { gap: 8px; margin: 12px 0; }
.mode-foundations .badge { border-radius: 999px; background: var(--m-surface-2); color: var(--m-muted); padding: 5px 8px; font-size: 12px; font-weight: 800; }
.mode-foundations .badge.region { background: var(--m-accent-soft); color: var(--m-accent); }
.mode-foundations .address { color: var(--m-muted); font-size: 14px; line-height: 1.5; }
.mode-foundations .video-title { color: var(--m-faint); font-size: 13px; line-height: 1.45; margin-top: 16px; }
.mode-foundations .detail-panel .eyebrow { padding: 24px 24px 0; color: var(--foundation-warm); }
.mode-foundations .detail-panel h2 { margin: 8px 24px 20px; font-size: clamp(28px, 3vw, 40px); line-height: 1.08; letter-spacing: -.04em; }
.mode-foundations .detail-panel > p { margin: 0; padding: 24px; color: var(--m-muted); line-height: 1.6; }
.mode-foundations .detail-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 16px; padding: 14px 24px; border-top-color: var(--m-line); color: var(--m-ink); line-height: 1.5; }
.mode-foundations .detail-row small { margin: 0; color: var(--m-muted); font-size: 12px; font-weight: 800; line-height: 1.3; }
.mode-foundations .actions { margin: 0; padding: 24px; border-top: 1px solid var(--m-line); background: rgba(240,233,221,.58); }
.mode-foundations .action { border-radius: 14px; padding: 11px 14px; background: var(--m-accent); color: #fffdfa; }
.mode-foundations .action.secondary { background: #fffdfa; color: var(--m-ink); border: 1px solid var(--m-line-strong); }
.mode-foundations .empty-state { padding: 48px 24px; color: var(--m-muted); }
.mode-foundations .empty-state h3 { margin: 0 0 8px; color: var(--m-ink); font-size: 22px; line-height: 1.2; }
@media (prefers-reduced-motion: reduce) {
  .mode-foundations .flow-tab,
  .mode-foundations .card { transition: none; }
  .mode-foundations .flow-tab:hover,
  .mode-foundations .card:hover { transform: none; }
}

@media (max-width: 1180px) {
  .moon-mode .flow-switcher { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .mode-highend .hero { grid-template-columns: 1fr; min-height: auto; padding-top: 86px; }
  .mode-highend .flow-switcher { width: min(760px, calc(100% - 36px)); border-radius: 30px; }
  .mode-nearby .sidebar { display: block; }
  .mode-focus .content,
  .mode-menu .content,
  .moon-mode .content { grid-template-columns: minmax(0, 1fr); }
  .mode-focus .detail-panel { min-height: auto; }
}
@media (max-width: 980px) {
  .moon-mode .hero { grid-template-columns: 1fr; padding: 26px 18px 16px; }
  .moon-mode .flow-switcher { padding: 0 18px 14px; grid-template-columns: 1fr 1fr; }
  .mode-highend .hero { padding: 72px 18px 28px; }
  .mode-highend .flow-switcher { padding: 6px; margin-bottom: 18px; }
  .mode-highend .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mode-highend .card,
  .mode-highend .card:nth-child(6n+1),
  .mode-highend .card:nth-child(6n+4),
  .mode-highend .card.selected { grid-column: span 1; }
  .moon-mode .layout { display: block; padding: 0 14px 28px; }
  .moon-mode .sidebar,
  .moon-mode .detail-panel { position: static; }
  .mode-highend .sidebar,
  .mode-highend .detail-panel { backdrop-filter: none; }
  .moon-mode .sidebar { margin-bottom: 14px; }
}
@media (max-width: 640px) {
  .moon-mode h1,
  .mode-compact h1 { font-size: 36px; }
  .moon-mode .flow-switcher { grid-template-columns: 1fr; }
  .moon-mode .stats { display: none; }
  .moon-mode .hero p { font-size: 14px; }
  .moon-mode .cards,
  .mode-menu .cards,
  .mode-discover .cards,
  .mode-nearby .cards { grid-template-columns: 1fr; }
  .mode-anthropic h1 { font-size: 42px; }
  .mode-anthropic .card { grid-template-columns: 1fr; padding: 16px 18px 16px 26px; }
  .mode-anthropic .card .address,
  .mode-anthropic .card .video-title { grid-column: 1; }
  .mode-anthropic .detail-row { grid-template-columns: 1fr; gap: 4px; }
  .mode-highend h1 { font-size: 50px; }
  .mode-highend .hero { padding: 56px 16px 24px; }
  .mode-highend .flow-switcher { width: calc(100% - 28px); grid-template-columns: 1fr; border-radius: 28px; }
  .mode-highend .cards { grid-template-columns: 1fr; padding: 7px; }
  .mode-highend .card,
  .mode-highend .card:nth-child(6n+1),
  .mode-highend .card:nth-child(6n+4),
  .mode-highend .card.selected { grid-column: 1; min-height: auto; transform: none; }
  .mode-highend .card:hover { transform: translateY(-2px); }
  .mode-highend .card.selected h3 { font-size: 36px; }
  .mode-highend .detail-row { grid-template-columns: 1fr; gap: 4px; }
  .mode-impeccable h1 { font-size: 1.9rem; }
  .mode-impeccable .card { grid-template-columns: 1fr; }
  .mode-impeccable .card .address,
  .mode-impeccable .card .video-title { grid-column: 1; }
  .mode-impeccable .detail-row { grid-template-columns: 1fr; gap: 4px; }
  .mode-foundations h1 { font-size: 42px; }
  .mode-foundations .card { padding: 18px; }
  .mode-foundations .detail-row { grid-template-columns: 1fr; gap: 4px; }
  .mode-taste h1 { font-size: 42px; }
  .mode-taste .card { grid-template-columns: 1fr; padding: 16px 18px 16px 24px; }
  .mode-taste .card .address,
  .mode-taste .card .video-title { grid-column: 1; }
  .mode-taste .detail-row { grid-template-columns: 1fr; gap: 4px; }
}
