:root {
  color-scheme: light;
  --menu-height-desktop: 56px;
  --menu-height-mobile: 64px;
  --menu-bg: #ffffff;
  --menu-border: #e5e7eb;
  --menu-text: #111827;
  --menu-muted: #6b7280;
  --overlay-bg: rgba(15, 23, 42, 0.6);
  --surface: #ffffff;
  --surface-alt: #f8fafc;
  --border: #e2e8f0;
  --text: #0f172a;
  --muted: #64748b;
  --highlight: #2563eb;
  --unpublished: #94a3b8;
  --menu-hover: #f1f5f9;
  --panel-bg: rgba(255, 255, 255, 0.95);
  --card-bg: #ffffff;
  --card-border: #e5e7eb;
  --badge-bg: #dbeafe;
  --badge-text: #1e3a8a;
  --badge-border: #93c5fd;
  --warning-bg: #fff7ed;
  --warning-border: #fdba74;
  --warning-text: #9a3412;
  --marker-icon-color: #ffffff;
  --marker-border-color: #ffffff;
  --accent: #2563eb;
  --panel: #ffffff;
  --panel-muted: #f8fafc;
  --line-muted: #e2e8f0;
}

:root[data-theme="light"] {
  color-scheme: light;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --menu-bg: #0b1220;
  --menu-border: #1f2937;
  --menu-text: #f8fafc;
  --menu-muted: #cbd5e1;
  --overlay-bg: rgba(2, 6, 23, 0.72);
  --surface: #0f172a;
  --surface-alt: #020617;
  --border: #334155;
  --text: #f8fafc;
  --muted: #94a3b8;
  --highlight: #60a5fa;
  --unpublished: #cbd5e1;
  --menu-hover: #1e293b;
  --panel-bg: rgba(15, 23, 42, 0.92);
  --card-bg: #0f172a;
  --card-border: #334155;
  --badge-bg: #1e293b;
  --badge-text: #bfdbfe;
  --badge-border: #334155;
  --warning-bg: #431407;
  --warning-border: #9a3412;
  --warning-text: #fed7aa;
  /* Keep map markers legible on dark tiles while softening bright white outlines. */
  --marker-icon-color: #e2e8f0;
  --marker-border-color: #020617;
  --accent: #60a5fa;
  --panel: #0f172a;
  --panel-muted: #1e293b;
  --line-muted: #334155;
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  margin: 0;
  font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
  color: var(--menu-text);
}

body {
  background: var(--surface-alt);
}

body.docs-page {
  color: var(--text);
}

.menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--menu-height-desktop);
  background: var(--menu-bg);
  border-bottom: 1px solid var(--menu-border);
  display: flex;
  align-items: center;
  padding: 0 20px 0 4px;
  z-index: 580;
}

.menu__title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  margin-right: 18px;
}

.menu__title-lines {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.05;
}

.menu__title-line {
  display: block;
}

.menu__logo {
  width: calc(var(--menu-height-desktop) - 8px);
  height: calc(var(--menu-height-desktop) - 8px);
  border-radius: 8px;
  object-fit: cover;
}

.menu__items {
  display: flex;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.menu__item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  color: var(--menu-muted);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 999px;
  transition: background 0.2s ease, color 0.2s ease;
}

.menu__item:hover {
  background: var(--menu-hover);
  color: var(--menu-text);
}

.menu__item[aria-current="page"] {
  background: var(--menu-hover);
  color: var(--menu-text);
}

.menu__icon {
  font-size: 1.1rem;
  line-height: 1;
}

.menu__unread-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  margin-left: 4px;
  vertical-align: middle;
  flex-shrink: 0;
}

/* ---- Public menu: user account dropdown ---- */

.menu__user-dropdown {
  position: relative;
  margin-left: auto;
}

.menu__user-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--menu-border);
  background: var(--surface);
  color: var(--menu-text);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.85rem;
  cursor: pointer;
  font-family: inherit;
}

.menu__user-trigger:hover {
  background: var(--menu-hover);
}

.menu__user-trigger--signin {
  text-decoration: none;
}

.menu__user-name {
  font-weight: 600;
}

.menu__user-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.menu__user-caret {
  font-size: 0.6rem;
  opacity: 0.55;
  transition: transform 0.15s;
  line-height: 1;
}

.menu__user-dropdown.is-open .menu__user-caret {
  transform: rotate(180deg);
}

.menu__user-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 600;
  min-width: 180px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.14s;
}

.menu__user-dropdown.is-open .menu__user-panel {
  opacity: 1;
  pointer-events: auto;
}

.menu__user-panel-inner {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.10), 0 2px 6px rgba(15, 23, 42, 0.06);
  display: grid;
  gap: 2px;
}

.menu__user-item {
  display: block;
  text-decoration: none;
  color: var(--text);
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 0.875rem;
  white-space: nowrap;
  background: transparent;
  font-family: inherit;
  text-align: left;
  width: 100%;
  cursor: pointer;
  transition: background 0.1s;
}

.menu__user-item:hover {
  background: var(--menu-hover);
}

.menu__user-item--signout {
  color: #dc2626;
}

.menu__user-divider {
  border-top: 1px solid var(--border);
  margin: 4px 2px;
}

.menu__user-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  /* Must stay below .menu's stacking context (z-index: 580) so the user
     panel inside .menu is not obscured by the backdrop on mobile. */
  z-index: 578;
}

.menu__view-mode-button {
  display: none;
}

body.map-page .menu__view-mode-button {
  display: block;
}

.menu__parking-toggle {
  display: none;
  justify-content: space-between;
  align-items: center;
}

body.map-page .menu__parking-toggle {
  display: flex;
}

.menu__toggle-pill {
  flex-shrink: 0;
  width: 36px;
  height: 20px;
  border-radius: 10px;
  background: var(--border);
  position: relative;
  transition: background 0.2s ease;
}

.menu__toggle-pill::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.menu__parking-toggle[aria-pressed="true"] .menu__toggle-pill {
  background: var(--highlight, #2563eb);
}

.menu__parking-toggle[aria-pressed="true"] .menu__toggle-pill::after {
  transform: translateX(16px);
}

.map-layout {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr;
  padding-top: var(--menu-height-desktop);
}

#map {
  position: relative;
  height: 100%;
  min-height: 0;
}

/* In dark mode, keep the map canvas black while tiles load to avoid bright flashes. */
:root[data-theme="dark"] #map,
:root[data-theme="dark"] #map .leaflet-container {
  background: #000000;
}

.osm-attribution {
  position: absolute;
  bottom: 10px;
  left: 10px;
  z-index: 800;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 3px 8px;
  font-size: 0.72rem;
  color: var(--text);
  backdrop-filter: blur(4px);
  transition: opacity 1s ease, visibility 1s ease;
  pointer-events: auto;
}

:root[data-theme="dark"] .osm-attribution {
  background: rgba(15, 23, 42, 0.85);
}

.osm-attribution a {
  color: var(--highlight);
  text-decoration: none;
}

.osm-attribution a:hover {
  text-decoration: underline;
}

.osm-attribution.is-faded {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

@media (max-width: 768px) {
  .osm-attribution {
    bottom: calc(var(--menu-height-mobile) + 6px);
  }
}

.map-list {
  display: none;
  background: var(--surface-alt);
  border-left: 1px solid var(--border);
  overflow-y: auto;
  min-height: 0;
}

.map-layout--list {
  grid-template-rows: 1fr;
}

.map-layout--list .leaflet-top.leaflet-left {
  left: min(380px, 38vw);
}

.map-layout--list .map-list {
  display: block;
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
  align-self: stretch;
  width: min(380px, 38vw);
  z-index: 450;
  border-left: none;
  border-right: 1px solid var(--border);
  box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
}

.map-layout--list #map {
  grid-column: 1;
  grid-row: 1;
  height: auto;
}

.map-controls {
  position: fixed;
  top: calc(var(--menu-height-desktop) + 16px);
  right: 16px;
  z-index: 550;
}

/* Hide the floating filter trigger while the filter dialog is already open. */
.filter-toggle[aria-expanded="true"] {
  display: none;
}


.marker-cluster {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.8rem;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.35);
  border: 2px solid #ffffff;
}

.marker-cluster__label {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.marker-cluster--small {
  background: rgba(100, 116, 139, 0.85);
}

.marker-cluster--medium {
  background: rgba(59, 130, 246, 0.85);
}

.marker-cluster--large {
  background: rgba(147, 51, 234, 0.85);
}

.restaurant-marker {
  background: transparent;
  border: 0;
}

.restaurant-marker--highlighted .restaurant-marker__glyph {
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.28), 0 0 0 10px rgba(14, 165, 233, 0.18), 0 3px 10px rgba(15, 23, 42, 0.35);
  transform: scale(calc(var(--marker-scale, 1) * 1.16));
}

.restaurant-marker--open .restaurant-marker__glyph {
  box-shadow: 0 0 0 3px #22c55e, 0 3px 10px rgba(15, 23, 42, 0.35);
  position: relative;
}

.restaurant-marker--open .restaurant-marker__glyph::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background-color: rgba(34, 197, 94, 0.45);
  animation: open-venue-pulse 2s ease-out infinite;
  pointer-events: none;
}

@keyframes open-venue-pulse {
  0%   { transform: scale(0.75); opacity: 1; }
  100% { transform: scale(2.4);  opacity: 0; }
}

.restaurant-marker--visited .restaurant-marker__glyph::before {
  content: "✓";
  position: absolute;
  top: -7px;
  right: -7px;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #16a34a;
  color: #ffffff;
  font-size: 0.55rem;
  font-weight: 700;
  line-height: 14px;
  text-align: center;
  z-index: 1;
  pointer-events: none;
  border: 1.5px solid #ffffff;
}

.restaurant-marker__glyph {
  position: relative;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: var(--highlight);
  color: var(--marker-icon-color);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.35);
  border: 2px solid var(--marker-border-color);
  font-size: 0.85rem;
  transform: scale(var(--marker-scale, 1));
  transform-origin: center bottom;
  transition: transform 0.15s ease;
}

.restaurant-marker__glyph--unrated {
  background: #6b7280;
}

.restaurant-marker__glyph--avoid {
  background: #dc2626;
}

.restaurant-marker__glyph--ok {
  background: #eab308;
}

.restaurant-marker__glyph--good {
  background: #16a34a;
}

.restaurant-marker__glyph--amazing-rare-gem {
  background: radial-gradient(circle at 30% 30%, #e0f2fe 5%, #38bdf8 40%, #1d4ed8 95%);
  position: relative;
}

.restaurant-marker__glyph--permanently-closed {
  background: #b91c1c;
  border-color: #7f1d1d;
}


.map-popup {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.map-popup--permanently-closed {
  background: rgba(185, 28, 28, 0.08);
  border-radius: 8px;
  padding: 8px;
  margin: -8px;
}

.map-popup__closed-notice {
  margin: 0;
  font-weight: 600;
  font-size: 0.82rem;
  color: #b91c1c;
  display: flex;
  align-items: center;
  gap: 6px;
}

:root[data-theme="dark"] .map-popup--permanently-closed {
  background: rgba(248, 113, 113, 0.1);
}

:root[data-theme="dark"] .map-popup__closed-notice {
  color: #f87171;
}

.map-popup--compact {
  gap: 6px;
}

.leaflet-popup-content-wrapper,
.leaflet-popup-tip {
  background: var(--card-bg);
  color: var(--text);
  border: 1px solid var(--card-border);
}

.leaflet-popup-content {
  margin: 12px;
}


.leaflet-popup-content p {
  margin: 0;
}

.map-popup__title {
  margin: 0;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
}

.map-popup__subtitle {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.map-popup__section {
  display: grid;
  gap: 6px;
}

.map-popup__label {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.map-popup__icon-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.map-popup__icon-item {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--surface-alt);
  color: var(--text);
  border: 1px solid var(--border);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.map-popup__rating {
  display: block;
  width: 120px;
  max-width: 100%;
  height: auto;
}

.map-popup__button {
  align-self: flex-start;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--surface-alt);
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.map-popup__button:hover,
.map-popup__button:focus-visible {
  background: var(--highlight);
  color: #ffffff;
  border-color: var(--highlight);
}

.map-popup__button--admin {
  width: 32px;
  height: 32px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.map-popup__address {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.map-popup__cuisine {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text);
}

.map-popup__hygiene {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.8rem;
  color: var(--text);
}

.map-popup__hygiene--pending {
  color: var(--muted);
}

.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;
}


.map-filters {
  width: min(360px, calc(100vw - 32px));
  max-height: min(80vh, 640px);
  overflow: auto;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.16);
  pointer-events: auto;
}

.map-filters h2 {
  margin: 0;
  font-size: 1rem;
}

.map-filters__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.map-filters__close {
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  border-radius: 999px;
  width: 32px;
  height: 32px;
  cursor: pointer;
}

.map-filters__search {
  display: grid;
  gap: 6px;
  margin-top: 12px;
  font-size: 0.88rem;
  color: var(--text);
}

.map-filters__search input {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.95rem;
  font-family: inherit;
  background: var(--surface);
  color: var(--text);
}

.map-filters__hint {
  margin: 10px 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}

.map-filters__suggestions {
  margin-top: 8px;
}

.map-filters__suggestions-title {
  margin: 0 0 6px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}

.map-filters__suggestions-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.map-filters__suggestion-chip {
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  padding: 6px 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  cursor: pointer;
}

.map-filters__suggestion-chip span {
  color: var(--muted);
  font-size: 0.72rem;
}

.map-filters__suggestion-chip:hover,
.map-filters__suggestion-chip:focus-visible {
  background: var(--menu-hover);
}

.map-filters__tour-button {
  margin-top: 8px;
  margin-right: 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  padding: 8px 12px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-weight: 600;
}

.map-filters__tour-button:hover,
.map-filters__tour-button:focus-visible {
  background: var(--menu-hover);
}

.map-filters__reset-button {
  margin-top: 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  padding: 8px 12px;
  cursor: pointer;
  font-weight: 600;
}

.map-filters__reset-button:hover,
.map-filters__reset-button:focus-visible {
  background: var(--menu-hover);
}


.map-filters__form {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.map-filters__group {
  margin: 0;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: var(--surface);
}

.map-filters__group-summary {
  list-style: none;
  cursor: pointer;
  padding: 9px 10px;
  font-weight: 600;
  font-size: 0.86rem;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}

.map-filters__group-summary-label {
  flex: 1;
}

.map-filters__group-summary.is-active {
  color: var(--highlight);
}

.map-filters__group-summary-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--menu-hover);
  color: var(--text);
  font-size: 0.74rem;
  font-weight: 700;
}

.map-filters__group-summary::-webkit-details-marker {
  display: none;
}

.map-filters__group-summary::after {
  content: "▾";
  transition: transform 0.2s ease;
  margin-left: auto;
}

.map-filters__group:not([open]) .map-filters__group-summary::after {
  transform: rotate(-90deg);
}

.map-filters__group-options {
  margin: 0;
  padding: 0 10px 10px;
  display: grid;
  gap: 8px;
}

.map-filters__option {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  color: var(--text);
}

.map-filters__option span:first-of-type {
  flex: 1;
}

.map-filters__option-count {
  font-size: 0.74rem;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 1px 6px;
  line-height: 1.2;
}

.map-filters__option input {
  margin: 0;
}

.map-filters__color-swatch {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 3px;
  margin-right: 6px;
  vertical-align: middle;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.map-filters__tag-icon {
  margin-right: 6px;
  font-size: 0.85em;
  color: var(--muted);
  width: 1.1em;
  text-align: center;
}

.map-filters.is-empty {
  display: none;
}

.filters-dialog {
  position: fixed;
  inset: 0;
  background: transparent;
  display: none;
  align-items: flex-start;
  justify-content: flex-end;
  padding: calc(var(--menu-height-desktop) + 16px) 16px 16px;
  z-index: 560;
  /* Let desktop map interactions pass through while keeping the panel itself clickable. */
  pointer-events: none;
}

.filters-dialog.is-open {
  display: flex;
}

.onboarding-tour {
  position: fixed;
  inset: 0;
  background: var(--overlay-bg);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 570;
}

.onboarding-tour.is-open {
  display: flex;
}

.onboarding-tour__card {
  width: min(460px, calc(100vw - 32px));
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--card-bg);
  color: var(--text);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.3);
  padding: 16px;
}

.onboarding-tour__step {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--highlight);
}

.onboarding-tour__body {
  margin: 10px 0 0;
  font-size: 0.95rem;
  color: var(--text);
}

.onboarding-tour__actions {
  margin-top: 14px;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.filter-toggle,
.view-toggle {
  border: none;
  border-radius: 999px;
  padding: 10px 14px;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  cursor: pointer;
}

.filter-toggle {
  background: var(--highlight);
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.3);
}

.filter-toggle__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: #fff;
  color: var(--highlight);
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
  margin-left: 0.25rem;
}

.view-toggle-wrapper {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 550;
}

.view-toggle {
  background: var(--highlight);
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.3);
}

.map-list__results {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.map-list__item {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  padding: 12px;
  display: grid;
  gap: 8px;
  cursor: pointer;
}

.map-list__item[hidden] {
  display: none;
}

.map-list__item--highlighted {
  border-color: var(--highlight);
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.25);
}

.map-list__item--permanently-closed {
  background: rgba(185, 28, 28, 0.06);
  border-color: rgba(185, 28, 28, 0.3);
}

.map-list__title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
}

.map-list__closed-badge {
  margin: 0;
  font-weight: 600;
  font-size: 0.78rem;
  color: #b91c1c;
  display: flex;
  align-items: center;
  gap: 6px;
}

:root[data-theme="dark"] .map-list__item--permanently-closed {
  background: rgba(248, 113, 113, 0.08);
  border-color: rgba(248, 113, 113, 0.35);
}

:root[data-theme="dark"] .map-list__closed-badge {
  color: #f87171;
}

.map-list__subtitle {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}


.map-list__heading {
  margin: 0;
  padding: 16px 14px 8px;
  font-size: 1.1rem;
}

.map-list__intro {
  margin: 0;
  padding: 0 14px 10px;
  color: var(--muted);
  font-size: 0.9rem;
}

.map-list__meta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px 10px;
  gap: 8px;
}

.map-list__count {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.map-list__sort-label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.82rem;
  color: var(--muted);
  white-space: nowrap;
  cursor: default;
}

.map-list__sort-select {
  font-size: 0.82rem;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2px 6px;
  cursor: pointer;
}

.map-list__title a {
  color: inherit;
  text-decoration: underline;
}

.map-list__meta {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.map-list__section {
  display: grid;
  gap: 6px;
}

.map-list__label {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.map-list__icon-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.map-list__icon-item {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--surface-alt);
  color: var(--text);
  border: 1px solid var(--border);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.map-list__rating {
  display: block;
  width: 120px;
  max-width: 100%;
  height: auto;
}

.map-list__cuisine {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text);
}

.map-list__hygiene {
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 0;
  font-size: 0.8rem;
  color: var(--text);
}

.map-list__empty {
  margin: 0;
  padding: 18px 14px;
  color: var(--muted);
  font-size: 0.9rem;
}

.zoom-locate-control {
  border: 1px solid var(--border) !important;
  border-radius: 12px !important;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.16);
  background: var(--surface);
  display: flex;
  flex-direction: column;
}

.zoom-locate-control__button {
  width: 40px;
  height: 40px;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
}

.zoom-locate-control__button:last-child {
  border-bottom: 0;
}

.zoom-locate-control__button:hover,
.zoom-locate-control__button:focus-visible {
  background: var(--menu-hover);
}

.zoom-locate-control__button:disabled {
  cursor: wait;
  opacity: 0.8;
}

.zoom-locate-control__button.is-loading i {
  animation: spin 0.9s linear infinite;
}

.roulette-toast {
  position: absolute;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 8px);
  max-width: min(360px, calc(100vw - 32px));
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 0.9rem;
  text-align: center;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.16);
  z-index: 556;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.roulette-toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.leaflet-control-attribution {
  display: none;
}

/* #map is a grid item that starts below the menu via padding-top on .map-layout,
   so only a small gap is needed here — no need to add menu-height again. */
.leaflet-top {
  top: 6px;
}

.leaflet-left {
  left: 8px;
}

/* Lower Leaflet's control container below the nav bar stacking contexts so that
   nav dropdowns (user panel inside .menu at z-index 580, admin panel inside
   .top-nav at z-index 600) paint above the zoom/locate buttons.
   Leaflet's own CSS sets this to 1000, which traps the dropdowns behind it. */
.leaflet-top,
.leaflet-bottom {
  z-index: 555;
}


.spinner {
  width: 24px;
  height: 24px;
  border: 3px solid rgba(248, 250, 252, 0.4);
  border-top-color: #f8fafc;
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* User location marker */
.user-location-marker {
  width: 18px;
  height: 18px;
  background-color: #3b82f6;
  border: 3px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 2px #3b82f6;
  position: relative;
}

.user-location-marker::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  background-color: rgba(59, 130, 246, 0.25);
  animation: user-location-pulse 2s ease-out infinite;
}

@keyframes user-location-pulse {
  0% {
    transform: scale(0.6);
    opacity: 1;
  }
  100% {
    transform: scale(2);
    opacity: 0;
  }
}

body.about-page main {
  max-width: 860px;
  margin: 0 auto;
  padding: calc(var(--menu-height-desktop) + 16px) 24px 56px;
}

.about-hero {
  text-align: center;
  padding: 48px 24px 40px;
}

.about-hero__icon {
  width: 120px;
  height: 120px;
  border-radius: 26px;
  box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.15), 0 8px 32px rgba(37, 99, 235, 0.25), 0 0 64px rgba(37, 99, 235, 0.12);
  margin-bottom: 24px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.about-hero__title {
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 14px;
  line-height: 1.15;
}

.about-hero__tagline {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.65;
}

.about-sections {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.about-section h2 {
  margin-top: 0;
  font-size: 1.15rem;
  font-weight: 600;
}

.made-by {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 4px;
}

.made-by__detail {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.made-by__label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  font-weight: 600;
}

.made-by__value {
  font-size: 1rem;
  font-weight: 500;
  color: var(--highlight);
  text-decoration: none;
}

.made-by__value:hover {
  text-decoration: underline;
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 8px;
}

.tool-card {
  padding: 14px 16px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.tool-card__name {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  margin-bottom: 4px;
}

.tool-card__desc {
  font-size: 0.83rem;
  color: var(--muted);
  line-height: 1.4;
}

.ai-note {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.ai-note__title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 12px;
  color: var(--text);
}

.ai-note__cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.ai-note__col-heading {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 6px;
}

.ai-note__col p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text);
}

@media (max-width: 540px) {
  .ai-note__cols {
    grid-template-columns: 1fr;
  }
}

.credit-contact {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.credit-contact__label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  font-weight: 600;
}

.credit-contact__link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--highlight);
  text-decoration: none;
  width: fit-content;
}

.credit-contact__link:hover {
  text-decoration: underline;
}

:root[data-theme="dark"] .about-hero__icon {
  box-shadow: 0 0 0 1px rgba(96, 165, 250, 0.2), 0 8px 32px rgba(96, 165, 250, 0.2), 0 0 80px rgba(96, 165, 250, 0.1);
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 28px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.card h1 {
  margin-top: 0;
  font-size: 1.9rem;
}

.card p {
  line-height: 1.6;
  color: var(--text);
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 20px 0 0;
  display: grid;
  gap: 12px;
}

.contact-list a {
  color: var(--highlight);
  text-decoration: none;
}

.contact-list a:hover {
  text-decoration: underline;
}

.muted {
  color: var(--muted);
}

.report-panel {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  overflow-y: auto;
  z-index: 700;
}

.report-panel.is-open {
  display: flex;
}

.report-panel__card {
  background: var(--surface);
  border-radius: 20px;
  padding: 24px;
  width: min(520px, 100%);
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.2);
}

.report-panel__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.report-panel__close {
  border: none;
  background: transparent;
  font-size: 1.2rem;
  cursor: pointer;
  color: var(--muted);
}

.report-form {
  display: grid;
  gap: 14px;
  margin-top: 12px;
}

.form-field {
  display: grid;
  gap: 6px;
  font-size: 0.9rem;
}

.form-field input,
.form-field textarea {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.95rem;
  font-family: inherit;
}

.form-field textarea {
  resize: vertical;
}

.form-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
}

.form-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

.button {
  border-radius: 999px;
  padding: 10px 18px;
  border: 1px solid transparent;
  font-weight: 600;
  cursor: pointer;
  font-size: 0.95rem;
  text-decoration: none;
  display: inline-block;
}

.button--primary {
  background: var(--highlight);
  color: #ffffff;
}

.button--primary:hover {
  background: #1d4ed8;
}

.button--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.button--ghost:hover {
  background: var(--surface-alt);
  border-color: var(--muted);
}

body.location-page {
  color: var(--text);
}

.location-layout {
  max-width: 1080px;
  margin: 0 auto;
  padding: calc(var(--menu-height-desktop) + 24px) 24px 48px;
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 16px;
  align-items: start;
}

.location-eyebrow {
  margin: 0;
  color: var(--muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}


.location-subtitle {
  margin: 6px 0 0;
  color: var(--muted);
}

.location-subtitle--secondary {
  margin-top: 2px;
}

.venue-hero-image-wrap {
  margin: -24px -24px 16px;
  border-radius: 14px 14px 0 0;
  overflow: hidden;
  max-height: 300px;
}

.venue-hero-image {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 170px;
  max-height: 300px;
  object-fit: cover;
}

.venue-gallery {
  margin: 14px 0 18px;
  display: grid;
  gap: 10px;
}

.venue-gallery h2 {
  margin: 0;
}

.venue-gallery__row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
}

.venue-gallery__item {
  display: block;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: var(--surface-alt);
}

.venue-gallery__item img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.food-rating-badge {
  display: inline-block;
  vertical-align: middle;
  margin-left: 8px;
  max-height: 36px;
  max-width: 100%;
  width: auto;
}

.food-rating-badge--small {
  max-height: 24px;
  margin-left: 0;
}

.score-label {
  font-size: 0.82em;
  color: var(--text-muted, #666);
}

.table-scroll {
  overflow-x: auto;
}

.detail-grid {
  display: grid;
  gap: 16px;
}

.detail-list {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 8px;
}

.pill-list {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill-list li {
  background: var(--border);
  color: var(--text);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.map-filters__recent-searches li button {
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
}

.freshness-panel {
  margin: 16px 0;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-alt);
}

.freshness-panel h2,
.freshness-panel h3 {
  margin-top: 0;
}

.source-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.source-badge {
  background: var(--badge-bg);
  color: var(--badge-text);
  border: 1px solid var(--badge-border);
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.8rem;
  font-weight: 600;
}

.stale-warning {
  margin: 12px 0 0;
  padding: 10px 12px;
  border: 1px solid var(--warning-border);
  border-radius: 10px;
  background: var(--warning-bg);
  color: var(--warning-text);
  font-weight: 600;
}

/* ── Location page – BGG rating + tag chip glow up ───────── */

.loc-hero-placeholder {
  margin: -24px -24px 16px;
  min-height: 160px;
  border-radius: 14px 14px 0 0;
  background: linear-gradient(160deg, #e0f2fe 0%, #bae6fd 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: rgba(14, 165, 233, 0.25);
}

.loc-venue-meta {
  margin: 6px 0 0;
  font-size: 0.85rem;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.loc-venue-meta i {
  font-size: 0.78rem;
  flex-shrink: 0;
}

.loc-info-footer {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.loc-info-dl {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
  margin: 0 0 12px;
  padding: 0;
}

.loc-info-dl__row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: 0.85rem;
}

.loc-info-dl__row dt {
  font-weight: 600;
  color: var(--muted);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.loc-info-dl__row dd {
  margin: 0;
  color: var(--text);
}

.loc-rating-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 14px 0 6px;
}

.loc-bgg-badge {
  font-size: 0.88rem;
  padding: 6px 16px;
  gap: 0;
}

.loc-bgg-badge__prefix {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  opacity: 0.8;
  margin-right: 6px;
}

.loc-food-badge-hero {
  max-height: 44px;
}

.loc-tags-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 16px 0 8px;
}

.loc-tag-type-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 5px;
}

.loc-tags-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.loc-tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  border-radius: 8px;
  font-size: 0.82rem;
  border: 1px solid var(--border);
  background: var(--surface-alt);
  color: var(--text);
}

.loc-tag-chip i {
  font-size: 0.72rem;
  color: var(--muted);
}

.loc-tag-chip--negative {
  border-color: #fca5a5;
  background: #fee2e2;
  color: #b91c1c;
}

.loc-tag-chip--negative i {
  color: #b91c1c;
}

.loc-tag-chip--negative .loc-tag-chip__label {
  text-decoration: line-through;
}

:root[data-theme="dark"] .loc-tag-chip--negative {
  border-color: #7f1d1d;
  background: #450a0a;
  color: #fca5a5;
}

:root[data-theme="dark"] .loc-tag-chip--negative i {
  color: #fca5a5;
}

/* ── Location page sidebar ───────────────────────────────────── */

.loc-sidebar {
  grid-column: 2 / 3;
  grid-row: 1 / 10;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.loc-card-error {
  grid-column: 1 / -1;
}

.loc-sidebar-section {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.loc-sidebar-section:last-child {
  border-bottom: none;
}

.loc-sidebar-section h3 {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  font-weight: 600;
  margin: 0 0 12px;
}

.loc-sidebar__rating-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.loc-sidebar__fhrs-badge {
  max-height: 64px;
  width: auto;
  display: block;
}

.loc-sidebar__fhrs-meta {
  font-size: 0.75rem;
  color: var(--muted);
  text-align: center;
  line-height: 1.5;
}

.loc-sidebar__bgg-wrap {
  text-align: center;
}

.loc-sidebar__bgg-note {
  font-size: 0.7rem;
  color: var(--muted);
  margin-top: 5px;
}

.loc-scores-dl {
  display: grid;
  gap: 0;
}

.loc-scores-dl__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.83rem;
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
}

.loc-scores-dl__row:last-child {
  border-bottom: none;
}

.loc-scores-dl__row dt {
  color: var(--muted);
}

.loc-scores-dl__row dd {
  font-weight: 600;
  margin: 0;
}

.loc-history-toggle {
  margin-top: 12px;
  background: none;
  border: none;
  padding: 0;
  color: var(--highlight);
  font-size: 0.82rem;
  cursor: pointer;
  font-family: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.loc-history-wrap {
  margin-top: 10px;
}

.loc-history-wrap .data-table {
  font-size: 0.78rem;
}

.loc-sidebar__actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.loc-sidebar__actions .button,
.loc-sidebar__actions a.button {
  width: 100%;
  text-align: center;
  justify-content: center;
  font-size: 0.875rem;
}

.loc-suggest-card {
  background: var(--surface-alt);
  border: 2px dashed var(--border) !important;
}

.loc-suggest-card__inner {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.loc-suggest-card__icon {
  font-size: 1.5rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.loc-suggest-card__text h2 {
  font-size: 1rem;
  margin: 0 0 6px;
}

.loc-suggest-card__text p {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0 0 12px;
}

.loc-details-summary {
  padding: 18px 24px;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text);
  border-radius: 16px;
  user-select: none;
}

/* Left-border accent so the accordion reads as interactive */
.loc-card-details {
  border-left: 4px solid var(--border) !important;
  transition: border-color 0.15s ease;
}

.loc-card-details:hover,
.loc-card-details[open] {
  border-left-color: var(--highlight) !important;
}

.loc-details-summary::-webkit-details-marker {
  display: none;
}

details.loc-card-details[open] .loc-details-summary {
  border-bottom: 1px solid var(--border);
  border-radius: 16px 16px 0 0;
}

.loc-details-summary:hover {
  background: var(--surface-alt);
}

.loc-details-body {
  padding: 20px 24px 24px;
}

.loc-details-body h3 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 18px 0 10px;
}

.loc-details-body h3:first-child {
  margin-top: 0;
}

/* ── Sidebar badge header (FHRS image bleeds into top of card) ── */

.loc-sidebar-card--hygiene {
  padding: 0;
}

.loc-sidebar__badge-header {
  display: block;
  width: auto;
  max-width: calc(100% - 24px);
  height: auto;
  margin: 12px auto 0;
  border-radius: 8px;
}

/* ── Sidebar section title ── */

.loc-sidebar-section-title {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  font-weight: 700;
  margin: 0 0 10px;
}

/* ── Sidebar editor rating card ── */

.loc-sidebar-card--editor-rating {
  border-left-width: 4px;
}

.loc-sidebar-card--editor-rating.loc-editor-rating--avoid        { background: #fef2f2; border-color: #dc2626; }
.loc-sidebar-card--editor-rating.loc-editor-rating--ok           { background: #fffbeb; border-color: #b45309; }
.loc-sidebar-card--editor-rating.loc-editor-rating--good         { background: #f0fdf4; border-color: #16a34a; }
.loc-sidebar-card--editor-rating.loc-editor-rating--amazing_rare_gem { background: #eff6ff; border-color: #1d4ed8; }

:root[data-theme="dark"] .loc-sidebar-card--editor-rating.loc-editor-rating--avoid        { background: #450a0a; border-color: #f87171; }
:root[data-theme="dark"] .loc-sidebar-card--editor-rating.loc-editor-rating--ok           { background: #431407; border-color: #fbbf24; }
:root[data-theme="dark"] .loc-sidebar-card--editor-rating.loc-editor-rating--good         { background: #052e16; border-color: #4ade80; }
:root[data-theme="dark"] .loc-sidebar-card--editor-rating.loc-editor-rating--amazing_rare_gem { background: #1e3a5f; border-color: #60a5fa; }

.loc-editor-rating {
  padding: 16px 20px;
}

.loc-editor-rating__eyebrow {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 6px;
  opacity: 0.75;
}

.loc-editor-rating__value {
  font-size: 1rem;
  font-weight: 700;
}

.loc-editor-rating__desc {
  margin-top: 10px;
  font-size: 0.85rem;
  line-height: 1.5;
  opacity: 0.85;
}

@media (max-width: 720px) {
  .loc-editor-rating {
    display: flex;
    gap: 16px;
    align-items: flex-start;
  }
  .loc-editor-rating__main {
    flex-shrink: 0;
    min-width: 90px;
  }
  .loc-editor-rating__desc {
    margin-top: 4px;
  }
}

/* ── Sidebar external reviews card ── */

.loc-external-review {
  padding: 10px 0;
  border-top: 1px solid var(--border);
}

.loc-external-review:first-of-type {
  border-top: none;
  padding-top: 0;
}

.loc-external-review__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.loc-external-review__platform {
  font-weight: 700;
  font-size: 0.9rem;
}

.loc-external-review__stars {
  font-size: 0.85rem;
  color: var(--muted);
}

.loc-external-review__count {
  margin: 4px 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}

.loc-external-review__summary {
  margin: 6px 0 0;
  font-size: 0.85rem;
  line-height: 1.5;
}

.loc-external-review__link {
  display: inline-block;
  margin-top: 6px;
  font-size: 0.8rem;
}

/* ── Gallery filter buttons ── */

.loc-gallery-filters {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.loc-gallery-filter {
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-alt);
  font-size: 0.8rem;
  cursor: pointer;
  color: var(--text);
}

.loc-gallery-filter--active {
  background: var(--highlight);
  border-color: var(--highlight);
  color: #fff;
}

/* ── Card title ── */

.loc-card-title {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 16px;
}

/* ── Section label (small-caps heading inside cards) ── */

.loc-section-label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  font-weight: 600;
  margin: 0 0 10px;
}

/* ── Menu highlights (dishes + prices) ── */

.loc-dishes-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.loc-dishes-list__item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border, rgba(0, 0, 0, 0.08));
}

.loc-dishes-list__item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.loc-dishes-list__price {
  font-weight: 600;
  white-space: nowrap;
}

.loc-dishes-note {
  margin: 12px 0 0;
  font-size: 0.74rem;
}

/* ── Consistency streak / rating signal notes ── */

.loc-consistency-note,
.loc-rating-drop-note,
.loc-reinspection-note {
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 0.78rem;
}

.loc-consistency-note {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}

.loc-rating-drop-note {
  background: #fff7ed;
  border: 1px solid #fdba74;
  color: #9a3412;
}

.loc-reinspection-note {
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  color: #0c4a6e;
}

/* ── Opening hours in hero ── */

.loc-opening-hours {
  display: flex;
  align-items: baseline;
  gap: 7px;
  margin-top: 12px;
  font-size: 0.88rem;
  color: var(--text);
}

.loc-opening-hours .fa-clock {
  color: var(--muted);
  flex-shrink: 0;
}

.loc-opening-hours--unknown {
  color: var(--muted);
  font-style: italic;
}

/* ── Stale banner in hero ── */

.loc-stale-banner {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  background: #fff7ed;
  border: 1px solid #fdba74;
  color: #9a3412;
  font-size: 0.82rem;
}

/* ── Permanently closed banner in hero ── */

.loc-card-hero--permanently-closed {
  background: rgba(185, 28, 28, 0.06);
  border-color: rgba(185, 28, 28, 0.35);
}

.loc-permanently-closed-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: #b91c1c;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.9rem;
}

:root[data-theme="dark"] .loc-card-hero--permanently-closed {
  background: rgba(248, 113, 113, 0.08);
  border-color: rgba(248, 113, 113, 0.35);
}

/* ── Gallery empty state ── */

.loc-gallery-empty {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0 4px;
  color: var(--muted);
  font-size: 0.88rem;
}

/* ── Hero address block ── */

.loc-address {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 14px;
  font-size: 0.9rem;
  color: var(--muted);
}

.loc-address .fa-location-dot {
  margin-top: 3px;
  flex-shrink: 0;
  color: var(--muted);
}

.loc-address__lines {
  display: flex;
  flex-direction: column;
  line-height: 1.7;
}

.loc-address__lines strong {
  color: var(--text);
  font-weight: 700;
}

/* ── Contact link pill buttons ── */

.loc-contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.loc-contact-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--highlight);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 12px;
  background: var(--surface-alt);
}

.loc-contact-link:hover {
  background: var(--border);
}

/* ── Breadcrumb ── */

.breadcrumb {
  max-width: 1080px;
  margin: 0 auto 16px;
  padding: 0 16px;
  font-size: 0.8rem;
  color: var(--muted);
}

.breadcrumb a {
  color: var(--highlight);
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
  .loc-sidebar__badge-header {
    max-width: 200px;
  }
}

/* ── Accordion chevron rotation ── */

.loc-details-chevron {
  display: inline-block;
  transition: transform 0.2s ease;
  font-style: normal;
}

details.loc-card-details[open] .loc-details-chevron {
  transform: rotate(180deg);
}

/* ── Directions select in sidebar actions ── */

.loc-directions-select {
  width: 100%;
  padding: 9px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-alt);
  color: var(--text);
  font-size: 0.9rem;
  font-family: inherit;
  font-weight: 500;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2364748b' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

/* ── Suggest modal — tag group sections ── */

.suggestion-tag-group {
  margin-bottom: 4px;
}

.suggestion-tag-group__label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin: 0 0 8px;
}

/* ── Suggest modal — styled file upload ── */

.suggestion-upload {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.suggestion-upload__label {
  font-size: 0.9rem;
  font-weight: 500;
}

.suggestion-upload__optional {
  font-weight: 400;
  color: var(--muted);
}

.suggestion-upload__btn {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

.suggestion-upload__btn-text {
  display: inline-block;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-alt);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  transition: background 0.15s, border-color 0.15s;
}

.suggestion-upload__btn:hover .suggestion-upload__btn-text {
  background: var(--highlight);
  color: #ffffff;
  border-color: var(--highlight);
}

.suggestion-upload__input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
}

.suggestion-upload__filename {
  font-size: 0.8rem;
  color: var(--muted);
}

.form-alert {
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.9rem;
}

.form-alert--success {
  background: #dcfce7;
  color: #166534;
}

.form-alert--error {
  background: #fee2e2;
  color: #991b1b;
}

.form-alert--info {
  background: #dbeafe;
  color: #1e3a8a;
}

:root[data-theme="dark"] .form-alert--info {
  background: #1e3a8a;
  color: #bfdbfe;
}

.form-hint {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0.25rem 0 0;
}


.contact-form-wrapper {
  margin-top: 24px;
  border-top: 1px solid var(--border);
  padding-top: 20px;
}

.admin-page {
  background: var(--surface-alt);
}

.admin-layout {
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 24px 48px;
}

.table-wrapper {
  overflow-x: auto;
  margin-top: 20px;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.data-table th,
.data-table td {
  border-bottom: 1px solid var(--border);
  padding: 12px;
  text-align: left;
  vertical-align: top;
}

.data-table th {
  background: var(--surface-alt);
  color: var(--muted);
  font-weight: 600;
}

.empty-state {
  text-align: center;
  color: var(--muted);
  padding: 24px;
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 20px;
  height: 56px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 600;
}

.top-nav--live {
  background: #fff7ed;
  border-bottom-color: #fb923c;
}

:root[data-theme="dark"] .top-nav--live {
  background: #431407;
  border-bottom-color: #f97316;
}

.top-nav__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.top-nav__logo {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.top-nav__brand-name {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.top-nav__brand-line {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text);
}

.top-nav__brand-sub {
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.docs-layout {
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  min-height: calc(100vh - 64px);
}

.docs-sidebar {
  background: var(--surface);
  border-right: 1px solid var(--border);
  padding: 24px;
}

.docs-sidebar h2 {
  margin: 0 0 16px;
  font-size: 1rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.doc-select {
  display: none;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.doc-select label {
  font-size: 0.85rem;
  color: var(--muted);
}

.doc-select select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  font-size: 0.95rem;
  background: var(--surface);
  color: var(--text);
}

.doc-select option {
  color: var(--text);
  background: var(--surface);
}

.doc-select option.is-unpublished {
  color: var(--unpublished);
}

.doc-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.doc-section-heading {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  padding: 12px 12px 4px;
}

.doc-section-heading:first-child {
  padding-top: 0;
}

.doc-button {
  width: 100%;
  text-align: left;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  color: var(--text);
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.doc-button:hover,
.doc-button:focus-visible {
  border-color: var(--border);
  background: var(--menu-hover);
}

.doc-button.is-active {
  border-color: rgba(37, 99, 235, 0.4);
  background: rgba(37, 99, 235, 0.08);
  color: var(--highlight);
}

.doc-button.is-unpublished {
  color: var(--unpublished);
}

.doc-badge {
  font-size: 0.75rem;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted);
}

.docs-content {
  padding: 32px 40px;
  overflow-y: auto;
}

.docs-content article {
  max-width: 900px;
  background: var(--surface);
  padding: 28px 32px;
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.06);
  border: 1px solid var(--border);
}

.docs-content h1,
.docs-content h2,
.docs-content h3 {
  margin-top: 24px;
}

.docs-content p,
.docs-content li {
  line-height: 1.6;
}

.docs-empty {
  color: var(--muted);
  font-size: 1rem;
}


@media (max-width: 900px) {
  .docs-layout {
    grid-template-columns: 1fr;
  }

  .docs-sidebar {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .docs-content {
    padding: 24px;
  }
}

@media (max-width: 768px) {
  .docs-sidebar {
    padding: 16px 20px;
  }

  .docs-sidebar h2 {
    margin-bottom: 8px;
  }

  .doc-select {
    display: flex;
  }

  .doc-list {
    display: none;
  }

  .docs-content {
    padding: 16px 20px 32px;
  }

  .docs-content article {
    max-width: none;
    padding: 20px 22px;
  }

  .location-layout {
    grid-template-columns: 1fr;
    padding: 14px 14px calc(var(--menu-height-mobile) + 20px);
  }
  .loc-sidebar        { grid-column: auto; grid-row: auto; order: 2; }
  .loc-card-hero      { order: 1; }
  .loc-card-tags      { order: 3; }
  .loc-card-gallery   { order: 4; }
  .loc-card-history   { order: 5; }
  .loc-card-details   { order: 6; }
  .loc-card-suggest   { order: 7; }
  .loc-card-admin     { order: 8; }
  .loc-card-error     { order: 1; }

  .venue-hero-image-wrap,
  .loc-hero-placeholder {
    margin: -20px -20px 16px;
  }

  .map-layout {
    padding-top: 0;
    padding-bottom: var(--menu-height-mobile);
  }

  #map {
    padding-top: 0;
    padding-bottom: 0;
  }

  .map-layout--list {
    grid-template-columns: 1fr;
  }

  .map-layout--list #map {
    display: none;
  }

  .map-layout--list .map-list {
    display: block;
    justify-self: stretch;
    width: 100%;
    z-index: auto;
    border-left: 0;
    border-right: 0;
    box-shadow: none;
  }

  .map-filters {
    width: min(420px, 100%);
    max-height: min(70vh, 540px);
  }

  .filters-dialog {
    align-items: flex-end;
    justify-content: center;
    padding: 12px 12px calc(var(--menu-height-mobile) + 12px);
    /* Restore backdrop taps on mobile so outside-click dismissal still works. */
    pointer-events: auto;
  }

  .map-controls {
    top: 12px;
    right: 12px;
  }

  .view-toggle-wrapper {
    right: 12px;
    bottom: calc(var(--menu-height-mobile) + 12px);
  }

  .filter-toggle,
  .view-toggle {
    padding: 9px 12px;
  }

  .leaflet-top {
    top: 8px;
  }

  .menu {
    top: auto;
    bottom: 0;
    height: var(--menu-height-mobile);
    border-top: 1px solid var(--menu-border);
    border-bottom: none;
    justify-content: space-around;
    padding: 0 12px 0 3px;
  }

  .menu__title {
    display: inline-flex;
    margin-right: 6px;
    font-size: 0.68rem;
    gap: 4px;
  }

  .menu__title-lines {
    line-height: 1;
  }

  .menu__logo {
    width: calc(var(--menu-height-mobile) - 10px);
    height: calc(var(--menu-height-mobile) - 10px);
    border-radius: 7px;
  }

  .menu__items {
    width: 100%;
    justify-content: space-around;
  }

  .menu__user-trigger {
    margin-left: 0;
    padding: 6px 8px;
    border: none;
    background: transparent;
    flex-direction: column;
    gap: 4px;
  }

  .menu__user-name {
    display: block;
    font-size: 0.65rem;
    letter-spacing: 0.01em;
  }

  .menu__user-caret {
    display: none;
  }

  .menu__user-panel {
    position: fixed;
    top: auto;
    right: auto;
    left: 0;
    width: 100%;
    min-width: unset;
    bottom: var(--menu-height-mobile);
  }

  .menu__user-panel-inner {
    border-radius: 14px 14px 10px 10px;
    margin: 0 10px 10px;
  }

  .menu__item {
    flex-direction: column;
    gap: 4px;
    font-size: 0.75rem;
    padding: 6px 8px;
  }

  .menu__label {
    display: block;
    font-size: 0.65rem;
    letter-spacing: 0.01em;
  }

  .top-nav {
    padding: 0 16px;
    height: 52px;
    overflow: hidden;
  }

  body.about-page main {
    padding: 16px 16px calc(var(--menu-height-mobile) + 32px);
  }

  .about-hero {
    padding: 32px 16px 28px;
  }

  .about-hero__icon {
    width: 96px;
    height: 96px;
  }

  .about-hero__title {
    font-size: 1.8rem;
  }

  .about-hero__tagline {
    font-size: 1rem;
  }

  .tools-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.form-field select {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.95rem;
  font-family: inherit;
  background: var(--surface);
  color: var(--text);
}

.form-field option {
  color: var(--text);
  background: var(--surface);
}

.button--secondary {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text);
  text-decoration: none;
}

.button--secondary:hover {
  background: var(--menu-hover);
}

.button--danger {
  background: #dc2626;
  color: #ffffff;
}

.button--danger:hover {
  background: #b91c1c;
}


/* ---- Admin nav: desktop inline ---- */

.admin-nav-inline {
  display: none; /* shown via min-width query below */
  align-items: center;
  gap: 2px;
  flex: 1;
  flex-wrap: nowrap;
  min-width: 0;
}

@media (min-width: 769px) {
  .admin-nav-inline {
    display: flex;
  }
}

.admin-nav-link {
  text-decoration: none;
  color: var(--muted);
  font-size: 0.875rem;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
  font-family: inherit;
  transition: color 0.12s, background 0.12s;
}

.admin-nav-link--button {
  font-family: inherit;
}

.admin-nav-link--signout {
  color: #dc2626;
}

.admin-nav-link:hover {
  color: var(--text);
  background: var(--menu-hover);
}

.admin-nav-link--active {
  color: var(--highlight);
  border-color: rgba(37, 99, 235, 0.25);
  background: rgba(37, 99, 235, 0.08);
}

/* ---- Admin nav: new-message badge ---- */

.admin-nav-new-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  margin-left: 5px;
  border-radius: 9999px;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
  background: #dc2626;
  color: #fff;
  vertical-align: middle;
}

/* ---- Admin nav: hover dropdown ---- */

.admin-nav-dropdown {
  position: relative;
}

.admin-nav-dropdown__trigger {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.admin-nav-dropdown__caret {
  font-size: 0.6rem;
  opacity: 0.55;
  transition: transform 0.15s;
  line-height: 1;
}

.admin-nav-dropdown:hover .admin-nav-dropdown__caret,
.admin-nav-dropdown:focus-within .admin-nav-dropdown__caret {
  transform: rotate(180deg);
}

.admin-nav-dropdown__panel {
  position: absolute;
  /* Sits flush against the trigger with no gap — padding-top provides
     visual breathing room while keeping the hover zone continuous. */
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 620;
  min-width: 190px;
  /* Transparent padding bridges the hover zone between trigger and visible panel. */
  padding-top: 8px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.14s;
}

.admin-nav-dropdown__panel-inner {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.10), 0 2px 6px rgba(15, 23, 42, 0.06);
  display: grid;
  gap: 2px;
}

.admin-nav-dropdown__panel--right {
  left: auto;
  right: 0;
  transform: none;
}

.admin-nav-dropdown:hover .admin-nav-dropdown__panel,
.admin-nav-dropdown:focus-within .admin-nav-dropdown__panel {
  opacity: 1;
  pointer-events: auto;
}

.admin-nav-dropdown__item {
  display: block;
  text-decoration: none;
  color: var(--text);
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 0.875rem;
  white-space: nowrap;
  background: transparent;
  font-family: inherit;
  text-align: left;
  width: 100%;
  cursor: pointer;
  transition: background 0.1s;
}

.admin-nav-dropdown__item:hover {
  background: var(--menu-hover);
}

.admin-nav-dropdown__item--active {
  color: var(--highlight);
  border-color: rgba(37, 99, 235, 0.25);
  background: rgba(37, 99, 235, 0.08);
}

.admin-nav-dropdown__item--signout {
  color: #dc2626;
}

.admin-nav-dropdown__divider {
  border-top: 1px solid var(--border);
  margin: 4px 2px;
}

/* ---- Admin nav: mobile hamburger ---- */

.admin-nav-mobile-toggle {
  display: flex; /* hidden via min-width query below */
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 5px 10px;
  cursor: pointer;
  color: var(--text);
  font-size: 1.1rem;
  line-height: 1;
  flex-shrink: 0;
}

@media (min-width: 769px) {
  .admin-nav-mobile-toggle {
    display: none;
  }
}

/* Pushes the ⚙ dropdown to the far right of the flex row */
.admin-nav-dropdown--push-right {
  margin-left: auto;
}

/* ---- Admin nav: mobile menu dialog ---- */

.admin-mobile-menu {
  position: fixed;
  inset: 0;
  margin: 0;
  padding: 0;
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  background: transparent;
  border: none;
  overflow: hidden;
}

.admin-mobile-menu::backdrop {
  background: rgba(15, 23, 42, 0.5);
}

.admin-mobile-menu__panel {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-radius: 16px 16px 0 0;
  max-height: 85vh;
  overflow-y: auto;
  padding-bottom: env(safe-area-inset-bottom, 12px);
}

.admin-mobile-menu__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px 12px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--surface);
  z-index: 1;
}

.admin-mobile-menu__title {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
}

.admin-mobile-menu__close {
  background: var(--menu-hover);
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  cursor: pointer;
  color: var(--text);
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.admin-mobile-menu__links {
  display: grid;
  gap: 2px;
  padding: 8px 10px 4px;
}

.admin-mobile-menu__section {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  padding: 10px 10px 4px;
}

.admin-mobile-menu__divider {
  border-top: 1px solid var(--border);
  margin: 6px 4px;
}

.admin-mobile-menu__item {
  display: block;
  text-decoration: none;
  color: var(--text);
  padding: 11px 10px;
  border-radius: 10px;
  font-size: 0.95rem;
  border: 1px solid transparent;
  background: transparent;
  font-family: inherit;
  text-align: left;
  width: 100%;
  cursor: pointer;
}

.admin-mobile-menu__item:hover {
  background: var(--menu-hover);
}

.admin-mobile-menu__item--active {
  color: var(--highlight);
  border-color: rgba(37, 99, 235, 0.25);
  background: rgba(37, 99, 235, 0.08);
}

.admin-mobile-menu__item--button {
  font-family: inherit;
}

.admin-mobile-menu__item--signout {
  color: #dc2626;
}

.admin-actions-cell {
  min-width: 260px;
}


.admin-image-preview {
  width: 120px;
  max-width: 100%;
  height: 90px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #ffffff;
}

.admin-row-form {
  display: grid;
  gap: 10px;
  margin-top: 8px;
  margin-bottom: 10px;
}

.form-field--compact {
  gap: 4px;
  font-size: 0.8rem;
}

.form-field--compact input,
.form-field--compact textarea,
.form-field--compact select {
  padding: 8px 10px;
  font-size: 0.85rem;
}

.form-actions--compact {
  justify-content: flex-start;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.status-pill--new {
  background: #e0f2fe;
  color: #075985;
}

.status-pill--in_progress {
  background: #fef3c7;
  color: #92400e;
}

.status-pill--resolved {
  background: #dcfce7;
  color: #166534;
}

.admin-action-time {
  margin-top: 6px;
}

.tag-group {
  margin-top: 24px;
}

.tag-group__title {
  margin: 0 0 8px;
  font-size: 1.15rem;
}

.tag-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.tag-list__item {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.tag-editor {
  padding: 0;
}

.tag-editor__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  padding: 10px 12px;
  font-size: 0.92rem;
}

.tag-editor__name {
  font-weight: 600;
  color: var(--text);
}

.tag-editor__meta {
  font-size: 0.8rem;
  color: var(--muted);
}

.tag-editor .admin-row-form {
  border-top: 1px solid var(--border);
  margin: 0;
  padding: 10px 12px 12px;
}

.tag-editor__actions {
  margin-bottom: 8px;
}

.tag-delete-form {
  border-top: 1px dashed var(--border);
  padding-top: 10px;
}

.tag-delete-form .button--danger {
  font-size: 0.82rem;
  padding: 7px 12px;
}

.tag-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 10px 14px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 0.88rem;
  color: var(--muted);
  margin-bottom: 16px;
}

.tag-stats__item strong {
  color: var(--text);
}

.tag-stats__item--warning strong {
  color: #d97706;
}

:root[data-theme="dark"] .tag-stats__item--warning strong {
  color: #fbbf24;
}

.tag-search-wrap {
  margin-bottom: 20px;
}

.tag-search {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font-size: 0.92rem;
}

.tag-search:focus {
  outline: 2px solid var(--highlight);
  outline-offset: 1px;
  border-color: transparent;
}

.tag-search::placeholder {
  color: var(--muted);
}

.tag-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.tag-toolbar .tag-search {
  flex: 1;
}

.tag-manager-actions {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 16px;
}

.tag-add-dialog {
  width: min(500px, calc(100% - 32px));
  border: none;
  padding: 0;
  background: transparent;
}

.tag-add-dialog::backdrop {
  background: rgba(15, 23, 42, 0.55);
}

.tag-add-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.25);
  padding: 20px;
}

.tag-add-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.tag-add-panel__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}

.tag-add-panel__close {
  width: 32px;
  height: 32px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  flex-shrink: 0;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-row--compact {
  gap: 8px;
}

@media (max-width: 480px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

details.tag-group > summary {
  list-style: none;
}

details.tag-group > summary::-webkit-details-marker {
  display: none;
}

.tag-group__header {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 6px 0;
  margin-bottom: 0;
  user-select: none;
}

.tag-group__header .tag-group__title {
  margin: 0;
}

.tag-group__chevron {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.75rem;
  flex-shrink: 0;
  transition: transform 0.18s ease;
}

details[open].tag-group > .tag-group__header .tag-group__chevron {
  transform: rotate(90deg);
}

.tag-group .tag-list {
  margin-top: 10px;
}

.tag-count-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 20px;
  padding: 0 6px;
  background: var(--badge-bg);
  color: var(--badge-text);
  border: 1px solid var(--badge-border);
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
}

.icon-preview-wrap {
  margin: 0;
  padding: 6px 10px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.85rem;
  color: var(--muted);
}

.icon-preview-wrap--compact {
  font-size: 0.8rem;
  padding: 4px 8px;
}

.icon-preview-el {
  color: var(--text);
  margin-left: 2px;
}

.tag-no-results {
  display: none;
  text-align: center;
  color: var(--muted);
  padding: 20px 0;
  font-size: 0.92rem;
}

.tag-no-results--visible {
  display: block;
}

.bulk-panel {
  display: grid;
  gap: 16px;
}


.bulk-panel__details {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel);
  padding: 10px 12px 12px;
}

.bulk-panel__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
}

.bulk-panel__summary::-webkit-details-marker {
  margin-right: 8px;
}

.bulk-panel__details[open] .bulk-panel__summary {
  margin-bottom: 10px;
}

.bulk-tag-groups {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.bulk-tag-group {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px;
  background: var(--surface);
}

.bulk-tag-group legend {
  padding: 0 6px;
  color: var(--muted);
  font-size: 0.85rem;
}

.tag-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.tag-tristate {
  margin-bottom: 8px;
}

.tag-tristate__button {
  display: flex;
  align-items: center;
  gap: 8px;
  font: inherit;
  font-size: 0.9rem;
  color: var(--text);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

.tag-tristate__icon {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  border: 1.5px solid var(--border);
  border-radius: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.tag-tristate__icon::after {
  font-size: 10px;
  line-height: 1;
  color: #fff;
}

.tag-tristate[data-state="positive"] .tag-tristate__icon {
  background: #16a34a;
  border-color: #16a34a;
}

.tag-tristate[data-state="positive"] .tag-tristate__icon::after {
  content: "\2713";
}

.tag-tristate[data-state="negative"] .tag-tristate__icon {
  background: #dc2626;
  border-color: #dc2626;
}

.tag-tristate[data-state="negative"] .tag-tristate__icon::after {
  content: "\2715";
}

.tag-tristate[data-state="negative"] .tag-tristate__label {
  color: #dc2626;
  text-decoration: line-through;
}

.tag-tristate-hint {
  margin-top: 10px;
  font-size: 0.82rem;
}

.restaurant-editor {
  display: grid;
  gap: 18px;
}

.editor-map {
  width: 100%;
  height: 320px;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.inline-search-row {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

@media (max-width: 700px) {
  .inline-search-row {
    grid-template-columns: 1fr;
  }
}

.inline-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.inline-filter-row .form-field {
  flex: 1;
  min-width: 160px;
}

/* Collapsible filter section */
.filter-details {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel);
  padding: 10px 12px 12px;
}

.filter-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  list-style: none;
}

.filter-summary::-webkit-details-marker {
  display: none;
}

.filter-summary::before {
  content: '▶';
  font-size: 0.7rem;
  color: var(--muted);
  margin-right: 6px;
  transition: transform 0.15s ease;
  display: inline-block;
}

.filter-details[open] .filter-summary::before {
  transform: rotate(90deg);
}

.filter-details[open] .filter-summary {
  margin-bottom: 12px;
}

.filter-summary__count {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--highlight);
  background: var(--badge-bg);
  border: 1px solid var(--badge-border);
  border-radius: 999px;
  padding: 2px 8px;
}

/* Sortable column header links */
.sort-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
}

.sort-link:hover {
  color: var(--text);
}

.sort-link--active {
  color: var(--highlight);
}

.sort-indicator {
  font-size: 0.75rem;
}

/* Published badge */
.published-badge {
  display: inline-block;
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.8rem;
  font-weight: 600;
}

.published-badge--yes {
  background: #dcfce7;
  color: #15803d;
}

.published-badge--no {
  background: var(--surface-alt);
  color: var(--muted);
  border: 1px solid var(--border);
}

.published-badge--closed {
  background: #fee2e2;
  color: #b91c1c;
  margin-left: 6px;
}

:root[data-theme="dark"] .published-badge--yes {
  background: #14532d;
  color: #86efac;
}

:root[data-theme="dark"] .published-badge--closed {
  background: #450a0a;
  color: #f87171;
}

/* Responsive table — card layout on small screens */
@media (max-width: 640px) {
  .data-table--responsive {
    display: block;
  }

  .data-table--responsive thead {
    display: none;
  }

  .data-table--responsive tbody {
    display: block;
  }

  .data-table--responsive tbody tr {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0 12px;
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 12px;
    padding: 12px;
    background: var(--surface);
  }

  .data-table--responsive td {
    display: contents;
  }

  /* Checkbox cell: spans first column, all rows */
  .data-table--responsive td:first-child {
    display: flex;
    align-items: flex-start;
    grid-column: 1;
    grid-row: 1 / span 6;
    padding-top: 2px;
    border: none;
  }

  /* Venue name: takes remaining space on first row */
  .data-table--responsive td:nth-child(2) {
    display: block;
    grid-column: 2;
    grid-row: 1;
    border: none;
    padding: 0 0 4px;
    font-size: 0.95rem;
  }

  /* All other data cells: label + value inline */
  .data-table--responsive td:nth-child(n+3):not(:last-child) {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    grid-column: 2;
    border: none;
    padding: 3px 0;
    font-size: 0.88rem;
    border-top: 1px solid var(--line-muted);
  }

  .data-table--responsive td:nth-child(n+3):not(:last-child)::before {
    content: attr(data-label);
    color: var(--muted);
    font-size: 0.8rem;
    flex-shrink: 0;
  }

  /* Actions cell */
  .data-table--responsive td:last-child {
    display: flex;
    justify-content: flex-end;
    grid-column: 2;
    border: none;
    padding-top: 8px;
  }

  .data-table--responsive td:last-child .button {
    padding: 6px 14px;
    font-size: 0.85rem;
  }
}



.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
  margin-bottom: 12px;
}

.pagination__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}

.pagination__link:hover {
  border-color: var(--accent);
}

.pagination__link.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.tools-loading-indicator {
  margin-top: 0.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.tools-loading-indicator .spinner {
  width: 18px;
  height: 18px;
  border-width: 2px;
  border-color: rgba(30, 41, 59, 0.25);
  border-top-color: var(--accent);
}


.admin-command-output {
  margin-top: 0.75rem;
  padding: 0.75rem;
  border-radius: 0.5rem;
  background: var(--panel-muted);
  border: 1px solid var(--line-muted);
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 18rem;
  overflow: auto;
}


/* ── News intro ───────────────────────────────────────── */

.news-intro {
  margin-bottom: 20px;
  border-left: 4px solid var(--accent);
}

.news-intro h1 {
  margin: 0 0 6px;
  font-size: 1.6rem;
}

.news-intro .muted {
  margin: 0;
  font-size: 0.95rem;
}

/* ── News overview grid ───────────────────────────────── */

.news-overview {
  display: grid;
  gap: 16px;
}

.news-overview--upcoming {
  margin-bottom: 8px;
}

/* ── News card base ───────────────────────────────────── */

.news-card {
  transition: box-shadow 0.15s ease, transform 0.15s ease;
  position: relative;
}

.news-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

/* ── Featured (latest) card ───────────────────────────── */

.news-card--featured {
  border-left: 4px solid var(--accent);
}

/* ── Upcoming card ────────────────────────────────────── */

.news-card--upcoming {
  border: 2px dashed var(--border);
  background: var(--surface-alt);
  box-shadow: none;
}

.news-card--upcoming:hover {
  box-shadow: none;
  transform: none;
}

.news-card__upcoming-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--badge-bg);
  border: 1px solid var(--badge-border);
  border-radius: 999px;
  padding: 3px 10px;
  margin-bottom: 10px;
}

.news-card__upcoming-badge::before {
  content: "⏳";
  font-size: 0.8em;
}

/* ── Card header ──────────────────────────────────────── */

.news-card__header {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 4px;
}

.news-card__title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.news-card__latest-badge {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #ffffff;
  background: var(--accent);
  border-radius: 999px;
  padding: 2px 9px;
  white-space: nowrap;
  flex-shrink: 0;
}

.news-card__title {
  margin: 0;
  font-size: 1.2rem;
  line-height: 1.3;
}

.news-card--featured .news-card__title {
  font-size: 1.3rem;
}

.news-card--upcoming .news-card__title {
  color: var(--muted);
  font-size: 1.15rem;
}

.news-card__title-link {
  color: inherit;
  text-decoration: none;
}

.news-card__title-link:hover,
.news-card__title-link:focus-visible {
  color: var(--highlight);
  text-decoration: underline;
}

.news-card__date {
  color: var(--muted);
  font-size: 0.85rem;
}

/* ── Card body ────────────────────────────────────────── */

.news-overview .pill-list {
  margin-top: 12px;
  margin-bottom: 4px;
}

.news-card__summary {
  margin: 10px 0 0;
  color: var(--text);
  line-height: 1.65;
  font-size: 0.95rem;
}

.news-card__actions {
  margin: 16px 0 0;
}

/* ── Detail page ──────────────────────────────────────── */

.news-detail__back-link {
  color: var(--highlight);
  font-size: 0.9rem;
}

.news-detail__header {
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.news-detail__header h1 {
  margin: 0 0 8px;
  font-size: 1.6rem;
  line-height: 1.25;
}

.news-detail__meta {
  color: var(--muted);
  font-size: 0.875rem;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.news-post__content h1,
.news-post__content h2,
.news-post__content h3 {
  margin: 24px 0 10px;
  line-height: 1.3;
}

.news-post__content h2 {
  font-size: 1.15rem;
}

.news-post__content h3 {
  font-size: 1rem;
}

.news-post__content p,
.news-post__content li {
  color: var(--text);
  line-height: 1.7;
}

.news-post__content a {
  color: var(--highlight);
}

.news-post__content code {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1px 6px;
  font-size: 0.85rem;
}

/* ── News section heading ─────────────────────────────── */

.news-section-heading {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 4px;
  grid-column: 1 / -1;
}

/* ── Review rating badge ──────────────────────────────── */

.review-rating-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #fff;
  background: var(--muted);
  white-space: nowrap;
}

.review-rating-badge--avoid {
  background: #dc2626;
}

.review-rating-badge--ok {
  background: #b45309;
  color: #fff;
}

.review-rating-badge--good {
  background: #16a34a;
}

.review-rating-badge--amazing_rare_gem {
  background: linear-gradient(135deg, #38bdf8, #1d4ed8);
}

/* ── Review card thumbnail ────────────────────────────── */

.news-card--review {
  overflow: hidden;
}

.news-card__review-thumb-wrap {
  margin: -20px -20px 14px;
  height: 180px;
  overflow: hidden;
}

.news-card__review-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.news-card__review-badge {
  flex-shrink: 0;
}

/* ── Review detail page ───────────────────────────────── */

.review-hero-wrap {
  margin: -20px -20px 20px;
}

.review-hero-wrap .venue-hero-image {
  max-height: 340px;
}

.review-detail__header {
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}

.review-detail__header h1 {
  margin: 6px 0 10px;
  font-size: 1.6rem;
  line-height: 1.25;
}

.review-detail__date {
  margin-top: 8px;
}

.review-detail__body {
  margin-bottom: 24px;
  line-height: 1.7;
}

.review-detail__body p {
  margin: 0 0 14px;
}

/* ── Review gallery ───────────────────────────────────── */

.review-gallery {
  margin-bottom: 24px;
}

.review-gallery__heading {
  font-size: 1.1rem;
  margin: 0 0 12px;
}

.review-gallery__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
}

.review-gallery__item {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 8px;
  background: var(--surface-alt);
}

.review-gallery__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.2s ease;
}

.review-gallery__photo:hover {
  transform: scale(1.03);
}

/* ── Review venue info card ───────────────────────────── */

.review-venue-info {
  margin-top: 0;
}

.review-venue-info__heading {
  font-size: 1.05rem;
  margin: 0 0 14px;
}

.review-venue-info__list {
  margin: 0 0 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.review-venue-info__row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  align-items: baseline;
}

.review-venue-info__row dt {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--muted);
  min-width: 120px;
}

.review-venue-info__row dd {
  margin: 0;
  font-size: 0.9rem;
}

.review-fha-badge {
  height: 44px;
  width: auto;
}

.review-venue-info__actions {
  margin: 0;
}

/* ── Map editor: full-screen layout ─────────────────────────────────── */

.admin-map-editor-page {
  min-height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.admin-map-editor {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: row;
  max-width: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

/* ── Sidebar panel ───────────────────────────────────────────────────── */

.admin-map-editor__panel {
  width: 320px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 0;
  border-right: 1px solid var(--border);
  background: var(--surface);
}

.admin-map-editor__panel-header {
  padding: 1rem 1rem 0;
  flex-shrink: 0;
}

.admin-map-editor__title {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0 0 0.75rem;
}

/* ── Tabs ────────────────────────────────────────────────────────────── */

.admin-map-editor__tabs {
  display: flex;
  border-bottom: 2px solid var(--border);
  flex-shrink: 0;
}

.admin-map-editor__tab {
  flex: 1;
  padding: 0.55rem 0.4rem;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.15s, border-color 0.15s;
}

.admin-map-editor__tab:hover {
  color: var(--text);
}

.admin-map-editor__tab--active {
  color: var(--link, #1d4ed8);
  border-bottom-color: var(--link, #1d4ed8);
}

.admin-map-editor__tab-panels {
  flex: 1;
  min-height: 0;
  position: relative;
}

.admin-map-editor__tab-panel {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  padding: 1rem;
}

/* ── Status bar ──────────────────────────────────────────────────────── */

.admin-map-editor__status {
  flex-shrink: 0;
  margin: 0;
  border-radius: 0;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
}

/* ── Find & Link panel ───────────────────────────────────────────────── */

.admin-map-editor__find-link-panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(300px, 100%);
  max-height: 100%;
  background: var(--surface);
  border-left: 1px solid var(--border);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  padding: 0.75rem;
  box-shadow: -2px 0 8px rgba(0,0,0,0.08);
  overflow: hidden;
  box-sizing: border-box;
}

.admin-map-editor__find-link-panel[hidden] {
  display: none;
}

.admin-map-editor__find-link-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

/* ── Map area ────────────────────────────────────────────────────────── */

.admin-map-editor__map-wrap {
  flex: 1;
  min-width: 0;
  position: relative;
}

.admin-map-editor__map {
  position: absolute;
  inset: 0;
}

/* Match admin map zoom controls with the public map's compact icon button styling. */
.admin-map-zoom-control {
  border: 1px solid var(--border) !important;
  border-radius: 12px !important;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.16);
  background: var(--surface);
  display: flex;
  flex-direction: column;
}

.admin-map-zoom-control__button {
  width: 40px;
  height: 40px;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
}

.admin-map-zoom-control__button:last-child {
  border-bottom: 0;
}

.admin-map-zoom-control__button:hover,
.admin-map-zoom-control__button:focus-visible {
  background: var(--menu-hover);
}

.admin-map-zoom-control__button:disabled {
  cursor: wait;
  opacity: 0.8;
}

.admin-map-zoom-control__button.is-loading i {
  animation: spin 0.9s linear infinite;
}

/* ── Panel component styles ──────────────────────────────────────────── */

.admin-map-editor__layers {
  border: 1px solid var(--line-muted);
  border-radius: 0.75rem;
  padding: 0.75rem;
  margin: 0.75rem 0;
}

.admin-map-editor__layers label,
.admin-map-editor__tag-group label {
  display: block;
  margin: 0.25rem 0;
}

.admin-map-editor__layers label {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.admin-map-editor__layer-swatch {
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 999px;
  background: var(--swatch-colour, rgba(59, 130, 246, 0.5));
  border: 1px solid rgba(255, 255, 255, 0.85);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.55rem;
  line-height: 1;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.95);
}

.admin-map-editor__tag-filters,
.admin-map-editor__bulk-tags {
  max-height: 14rem;
  overflow: auto;
  border: 1px solid var(--line-muted);
  border-radius: 0.75rem;
  padding: 0.5rem;
  margin-bottom: 0.75rem;
}

.admin-map-editor__click-hint {
  background: var(--surface-alt);
  border: 1px dashed var(--line-muted);
  border-radius: 0.5rem;
  padding: 0.55rem 0.75rem;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 0.75rem;
  text-align: center;
}

/* ── Marker & popup ──────────────────────────────────────────────────── */

.admin-map-editor__marker span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35);
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  color: rgba(255, 255, 255, 0.95);
}

.admin-map-editor__popup {
  min-width: 170px;
}

.admin-map-editor__popup .button {
  margin-top: 0.45rem;
  margin-right: 0.35rem;
}

/* ── Mobile ──────────────────────────────────────────────────────────── */

@media (max-width: 700px) {
  .admin-map-editor-page {
    overflow: auto;
  }

  .admin-map-editor {
    flex-direction: column;
    overflow: visible;
    min-height: 0;
  }

  .admin-map-editor__map-wrap {
    order: 1;
    height: 50dvh;
    min-height: 280px;
    flex-shrink: 0;
    position: relative;
  }

  .admin-map-editor__panel {
    order: 2;
    width: 100%;
    border-right: none;
    border-top: 1px solid var(--border);
    border-radius: 0;
    max-height: 55dvh;
  }

  .admin-map-editor__tab-panels {
    position: relative;
  }

  .admin-map-editor__tab-panel {
    position: static;
    overflow: visible;
  }
}

/* ── Admin overview dashboard ── */

.admin-overview-dashboard .admin-overview-dashboard__title {
  margin-top: 0;
  font-size: 1.5rem;
}

.admin-overview-stats-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}

.admin-overview-stat {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

a.admin-overview-stat {
  text-decoration: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

a.admin-overview-stat:hover {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(var(--accent-rgb, 37 99 235) / 0.12);
}

.admin-overview-stat--accent {
  border-color: var(--accent);
}

.admin-overview-stat__value {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.1;
}

.admin-overview-stat--accent .admin-overview-stat__value {
  color: var(--accent);
}

.admin-overview-stat__label {
  font-size: 0.82rem;
  color: var(--muted);
  font-weight: 500;
}

.admin-overview-dashboard h2 {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0 0 8px;
}

.admin-overview-chart-wrap {
  position: relative;
  height: 280px;
  margin-bottom: 24px;
}

.admin-overview-panels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.admin-overview-panel {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 16px;
}

.admin-overview-panel h3 {
  margin: 0 0 10px;
  font-size: 0.95rem;
  font-weight: 600;
}

.admin-overview-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.9rem;
}

.admin-overview-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-overview-list li a {
  display: flex;
  align-items: center;
  gap: 8px;
  color: inherit;
  text-decoration: none;
  border-radius: 6px;
  padding: 2px 4px;
  margin: -2px -4px;
  transition: background 0.12s;
}

.admin-overview-list li a:hover {
  background: var(--surface-alt);
  text-decoration: underline;
}


.admin-overview-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
  padding: 0 7px;
  border-radius: 9999px;
  font-size: 0.78rem;
  font-weight: 700;
  background: var(--badge-bg);
  color: var(--badge-text);
  border: 1px solid var(--badge-border);
}

.admin-overview-badge--warn {
  background: var(--warning-bg);
  color: var(--warning-text);
  border-color: var(--warning-border);
}

.admin-overview-stat--warn .admin-overview-stat__value {
  color: var(--warning-text);
}

.admin-overview-ok {
  color: #16a34a;
  font-weight: 500;
  font-size: 0.9rem;
  margin: 0;
}

:root[data-theme="dark"] .admin-overview-ok {
  color: #4ade80;
}

/* Sync freshness / meta lists */

.admin-overview-list--meta li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.admin-overview-meta-label {
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--muted);
}

.admin-overview-meta-value {
  font-size: 0.85rem;
  color: var(--text);
  text-align: right;
}

/* Chart panels (half-width) */

.admin-overview-panel--chart {
  min-height: 300px;
  overflow: hidden;
}

.admin-overview-chart-wrap--small {
  position: relative;
  width: 100%;
  height: 260px;
}

/* Recently updated */

.admin-overview-recent {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 8px;
}

.admin-overview-recent__item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  font-size: 0.88rem;
  transition: background 0.15s, border-color 0.15s;
}

.admin-overview-recent__item:hover {
  background: var(--menu-hover);
  border-color: var(--accent);
}

.admin-overview-recent__name {
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

.admin-overview-recent__date {
  font-size: 0.78rem;
  color: var(--muted);
  white-space: nowrap;
  flex-shrink: 0;
}

@media (max-width: 768px) {
  .admin-overview-stats-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .admin-overview-stat {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
  }

  .admin-overview-stat__value {
    font-size: 1.4rem;
  }

  .admin-overview-panels {
    grid-template-columns: 1fr;
  }

  .admin-overview-chart-wrap {
    height: 220px;
  }

  .admin-overview-chart-wrap--small {
    height: 200px;
  }

  .admin-overview-recent {
    grid-template-columns: 1fr;
  }
}

/* ── Isochrone panel ─────────────────────────────────────────────────────── */

.isochrone-panel {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 500;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.18);
  padding: 14px 16px 12px;
  min-width: 220px;
  max-width: calc(100vw - 32px);
}

@media (min-width: 769px) {
  .isochrone-panel {
    /* On desktop, position near the control stack rather than the screen centre. */
    left: 60px;
    transform: none;
    bottom: 28px;
  }
}

.isochrone-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.isochrone-panel__title {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted, var(--text));
  margin: 0;
}

.isochrone-panel__close {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text);
  font-size: 0.9rem;
  line-height: 1;
  padding: 2px 4px;
  border-radius: 4px;
  opacity: 0.7;
}

.isochrone-panel__close:hover {
  opacity: 1;
  background: var(--menu-hover);
}

.isochrone-panel__modes {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
}

.isochrone-panel__mode {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font-size: 0.8rem;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.isochrone-panel__mode:hover {
  background: var(--menu-hover);
}

.isochrone-panel__mode--active {
  background: var(--accent, #3b82f6);
  border-color: var(--accent, #3b82f6);
  color: #fff;
}

.isochrone-panel__mode--active:hover {
  background: var(--accent, #3b82f6);
  opacity: 0.9;
}

/* Loading state dims the panel while rings are being fetched. */
.isochrone-panel.is-loading {
  opacity: 0.6;
  pointer-events: none;
}

.isochrone-legend {
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.isochrone-legend__item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  color: var(--text);
}

.isochrone-legend__swatch {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.isochrone-legend__swatch--5min  { background: #22c55e; }
.isochrone-legend__swatch--10min { background: #eab308; }
.isochrone-legend__swatch--15min { background: #f97316; }
.isochrone-legend__swatch--30min { background: #ef4444; }

.isochrone-panel__note {
  margin: 0;
  font-size: 0.72rem;
  color: var(--text-muted, var(--text));
  opacity: 0.75;
}

/* ── Directions deep-link buttons (map popups + location page) ─────────────── */
.directions-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.directions-links__button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  background: var(--surface-alt);
  color: var(--text);
  border: 1px solid var(--border);
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.directions-links__button:hover,
.directions-links__button:focus-visible {
  background: var(--highlight);
  color: #ffffff;
  border-color: var(--highlight);
}

/* ── Directions dropdown (map popups) ───────────────────────────────────────── */
.directions-dropdown {
  align-self: flex-start;
}

.directions-dropdown__toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--surface-alt);
  color: var(--text);
  border: 1px solid var(--border);
  cursor: pointer;
  list-style: none;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.directions-dropdown__toggle::-webkit-details-marker {
  display: none;
}

.directions-dropdown[open] .directions-dropdown__toggle {
  background: var(--highlight);
  color: #ffffff;
  border-color: var(--highlight);
}

.directions-dropdown__toggle:hover,
.directions-dropdown__toggle:focus-visible {
  background: var(--highlight);
  color: #ffffff;
  border-color: var(--highlight);
}

.directions-dropdown__menu {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 6px;
  padding: 6px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 10px;
}

.directions-dropdown__option {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--text);
  transition: background 0.12s ease;
}

.directions-dropdown__option:hover,
.directions-dropdown__option:focus-visible {
  background: var(--surface-alt);
}

/* ─────────────────────────────────────────────────────────────────────────────
   User system — badges, filter bars, pagination, session panel
   ───────────────────────────────────────────────────────────────────────────── */

.badge {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  vertical-align: middle;
}

.badge--admin   { background: #fee2e2; color: #b91c1c; }
.badge--editor  { background: #fef3c7; color: #92400e; }
.badge--user    { background: #dbeafe; color: #1e3a8a; }
.badge--system  { background: #e0e7ff; color: #3730a3; }
.badge--success { background: #dcfce7; color: #166534; }
.badge--stale   { background: #ffedd5; color: #9a3412; }
.badge--negative-capable { background: #fee2e2; color: #b91c1c; }

:root[data-theme="dark"] .badge--admin   { background: #450a0a; color: #fca5a5; }
:root[data-theme="dark"] .badge--editor  { background: #431407; color: #fde68a; }
:root[data-theme="dark"] .badge--user    { background: #1e3a5f; color: #93c5fd; }
:root[data-theme="dark"] .badge--system  { background: #1e1b4b; color: #a5b4fc; }
:root[data-theme="dark"] .badge--success { background: #052e16; color: #86efac; }
:root[data-theme="dark"] .badge--stale   { background: #431407; color: #fdba74; }
:root[data-theme="dark"] .badge--negative-capable { background: #450a0a; color: #fca5a5; }

.button--small {
  padding: 0.25rem 0.7rem;
  font-size: 0.8rem;
}

.admin-filter-bar {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: flex-end;
  margin-bottom: 1.5rem;
}

.admin-filter-bar label {
  font-size: 0.82rem;
  font-weight: 600;
}

.admin-filter-bar select,
.admin-filter-bar input[type="text"],
.admin-filter-bar input[type="search"] {
  font-size: 0.82rem;
  padding: 0.3rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
}

.admin-tab-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  align-items: center;
}

.admin-tab {
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  text-decoration: none;
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 0.875rem;
}

.admin-tab--active {
  background: var(--highlight);
  border-color: transparent;
  color: #fff;
}

.admin-pagination {
  display: flex;
  gap: 0.4rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
  align-items: center;
}

.admin-pagination a,
.admin-pagination span {
  padding: 0.3rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 0.875rem;
  color: var(--text);
  background: var(--surface);
  text-decoration: none;
}

.admin-pagination a:hover { background: var(--menu-hover); }

.admin-pagination .current {
  background: var(--highlight);
  color: #fff;
  border-color: transparent;
}

.admin-cell--mono {
  font-family: monospace;
  font-size: 0.75rem;
  max-width: 220px;
  word-break: break-word;
}

.admin-cell--truncate {
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-sessions-panel {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem;
  margin: 0.5rem 0 0.75rem;
}

.admin-sessions-panel h3 {
  margin: 0 0 0.75rem;
  font-size: 0.9rem;
}

.admin-session-row {
  display: flex;
  gap: 1rem;
  align-items: center;
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.82rem;
  flex-wrap: wrap;
}

.admin-session-row:last-child { border-bottom: none; }
