:root {
  --ink: #16221d;
  --ink-soft: #4f5f56;
  --paper: #f6f8ef;
  --panel: #ffffff;
  --line: #d9dfd2;
  --leaf: #2f6f52;
  --leaf-bright: #3f8362;
  --mint: #d9ead7;
  --sun: #f6c453;
  --coral: #e66d4f;
  --saved-soft: #f5d8d4;
  --saved: #dc7f72;
  --petal: #f7c8d3;
  --petal-soft: #fdebf0;
  --petal-ink: #7b3147;
  --blue: #7db7c7;
  --pin-restaurant: var(--leaf);
  --pin-grocery: #3e6f82;
  --pin-hybrid: #37706a;
  --shadow: 0 18px 40px rgba(22, 34, 29, 0.12);
  --radius: 8px;
  --topbar-height: 71px;
  --search-height: 72px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background:
    linear-gradient(135deg, rgba(36, 74, 58, 0.08), transparent 42%),
    radial-gradient(circle at 12% 18%, rgba(246, 196, 83, 0.22), transparent 26%),
    var(--paper);
  color: var(--ink);
  font-family: "Bahnschrift", "Gill Sans", "Trebuchet MS", sans-serif;
}

body {
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
}

body.has-mobile-modal {
  overflow: hidden;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

noscript {
  display: block;
  padding: 24px;
  color: var(--ink);
}

.app-shell {
  min-height: 100vh;
}

@supports (min-height: 100dvh) {
  .app-shell {
    min-height: 100dvh;
  }
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 22px;
  border-bottom: 1px solid rgba(36, 74, 58, 0.18);
  background: rgba(246, 248, 239, 0.9);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.brand-copy {
  display: grid;
  gap: 2px;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: var(--radius);
  color: var(--paper);
  background: var(--leaf);
  font-weight: 800;
}

.brand-name {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.18rem;
  font-weight: 700;
}

.brand-subtitle {
  color: var(--ink-soft);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.1;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sync-note {
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.subscription-toggle,
.button,
.icon-button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 0 14px;
  cursor: pointer;
  font-weight: 700;
  text-decoration: none;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.subscription-toggle {
  color: var(--paper);
  background: var(--leaf);
}

.donation-toggle {
  background: var(--petal-ink);
}

.subscription-toggle.is-active {
  color: var(--leaf);
  border-color: rgba(36, 74, 58, 0.28);
  background: var(--mint);
}

.topbar-filter {
  color: #783f38;
  border-color: rgba(220, 127, 114, 0.34);
  background: var(--saved-soft);
}

.topbar-filter.is-active {
  color: var(--petal-ink);
  border-color: rgba(123, 49, 71, 0.24);
  background:
    linear-gradient(135deg, var(--petal), var(--petal-soft));
  box-shadow: 0 12px 28px rgba(123, 49, 71, 0.18);
}

.button--primary {
  color: var(--paper);
  background: var(--leaf);
}

.button--secondary {
  color: var(--ink);
  border-color: rgba(22, 34, 29, 0.18);
  background: var(--sun);
}

.button--ghost {
  color: var(--leaf);
  border-color: rgba(36, 74, 58, 0.22);
  background: transparent;
}

.button--saved {
  color: var(--leaf);
  border-color: rgba(36, 74, 58, 0.25);
  background: var(--mint);
}

.button--community {
  color: var(--petal-ink);
  border-color: rgba(123, 49, 71, 0.22);
  background: var(--petal-soft);
}

.button--source-icon {
  min-width: 42px;
  padding-inline: 12px;
  position: relative;
  border-color: rgba(36, 74, 58, 0.18);
  background: var(--sun);
  font-size: 0;
  line-height: 1;
}

.button--source-icon::before {
  content: "";
  display: block;
  width: 18px;
  height: 18px;
  background: var(--leaf);
  mask: url("./assets/link-icon.png") center / contain no-repeat;
  -webkit-mask: url("./assets/link-icon.png") center / contain no-repeat;
}

.button--source-icon::after {
  content: none;
}

.button--community.is-active,
.button--community:hover {
  color: var(--paper);
  background: var(--petal-ink);
}

.button:hover,
.icon-button:hover,
.subscription-toggle:hover,
.segment:hover {
  transform: translateY(-1px);
}

.workspace {
  display: grid;
  grid-template-columns: minmax(280px, 0.72fr) minmax(520px, 1.6fr);
  gap: 18px;
  height: calc(100vh - var(--topbar-height) - var(--search-height));
  max-width: 1720px;
  margin: var(--search-height) auto 0;
  padding: 18px;
  overflow: hidden;
}

.workspace.has-detail {
  grid-template-columns: minmax(280px, 0.72fr) minmax(420px, 1.08fr) minmax(380px, 1fr);
}

.control-panel,
.explore-panel,
.results-panel,
.detail-panel {
  min-width: 0;
}

.control-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
  min-height: 0;
  max-height: 100%;
  overflow: hidden;
  padding-right: 2px;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.search-strip,
.search-panel,
.control-menu,
.ad-slot,
.map-panel,
.detail-panel,
.empty-state {
  border: 1px solid rgba(36, 74, 58, 0.15);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
}

.search-strip,
.search-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 16px;
}

.search-strip {
  position: fixed;
  top: calc(var(--topbar-height) + 10px);
  left: 50%;
  z-index: 18;
  width: min(760px, calc(100% - 36px));
  margin: 0;
  padding: 10px;
  border: 1px solid rgba(36, 74, 58, 0.14);
  border-radius: 999px;
  background: rgba(246, 248, 239, 0.88);
  backdrop-filter: blur(14px);
  box-shadow: 0 12px 30px rgba(22, 34, 29, 0.12);
  transform: translateX(-50%);
}

.search-strip .field-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.search-submit {
  min-width: 110px;
}

.mobile-filter-search {
  display: none;
}

.control-menu {
  display: flex;
  flex: 1 1 auto;
  height: 100%;
  min-height: 0;
  max-height: 100%;
  flex-direction: column;
  overflow: hidden;
}

.control-menu summary {
  display: flex;
  min-height: 52px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  list-style: none;
  padding: 0 16px;
  color: var(--leaf);
  cursor: pointer;
  font-weight: 800;
}

.control-menu summary::marker {
  display: none;
  content: "";
}

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

.menu-trigger {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.menu-mark {
  display: inline-grid;
  width: 28px;
  gap: 3px;
  color: var(--coral);
}

.menu-mark span {
  display: block;
  height: 6px;
  border-top: 2px solid currentColor;
  border-radius: 999px 999px 70% 70%;
}

.menu-mark span:nth-child(1) {
  width: 20px;
  transform: rotate(-5deg);
}

.menu-mark span:nth-child(2) {
  width: 26px;
  transform: rotate(2deg);
}

.menu-mark span:nth-child(3) {
  width: 22px;
  transform: rotate(-3deg);
}

.control-menu__content {
  display: grid;
  flex: 1 1 auto;
  align-content: start;
  min-height: 0;
  max-height: calc(100vh - var(--topbar-height) - var(--search-height) - 106px);
  max-height: calc(100dvh - var(--topbar-height) - var(--search-height) - 106px);
  gap: 16px;
  overflow: auto;
  padding: 0 16px 16px;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.field-label,
.field-stack span,
.check-row,
.slider-row span,
.review-field span {
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 700;
}

.field-stack {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.control-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.location-field {
  grid-column: 1 / -1;
  min-width: 0;
}

.location-combobox {
  position: relative;
  z-index: 5;
}

.location-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.location-search-button {
  position: relative;
  width: 44px;
  min-width: 44px;
  padding: 0;
  background-image: url("./assets/city-search-icon.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: 21px 21px;
}

.search-icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.location-suggestions {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 30;
  display: grid;
  max-height: 260px;
  overflow: auto;
  border: 1px solid rgba(36, 74, 58, 0.16);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 18px 36px rgba(22, 34, 29, 0.16);
}

.location-suggestion {
  display: flex;
  width: 100%;
  min-height: 42px;
  align-items: center;
  justify-content: flex-start;
  border: 0;
  border-radius: 0;
  padding: 10px 12px;
  color: var(--ink);
  background: transparent;
  text-align: left;
  font-weight: 700;
}

.location-suggestion:hover,
.location-suggestion:focus-visible,
.location-suggestion.is-active {
  background: rgba(220, 235, 216, 0.72);
}

.location-suggestion.is-new {
  color: var(--leaf);
}

.location-status {
  margin: 6px;
  border: 1px solid rgba(230, 109, 79, 0.32);
  border-radius: var(--radius);
  padding: 12px 14px;
  color: var(--petal-ink);
  background: linear-gradient(135deg, #fff4cb 0%, #ffe5dc 56%, #e8f3d5 100%);
  box-shadow: 0 12px 22px rgba(230, 109, 79, 0.14);
  font-size: 0.85rem;
  font-weight: 800;
  line-height: 1.35;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid rgba(36, 74, 58, 0.18);
  border-radius: var(--radius);
  caret-color: var(--leaf);
  color: var(--ink);
  background: #fff;
}

input,
select {
  min-height: 44px;
  padding: 0 12px;
}

.search-strip input,
.search-strip .button {
  min-height: 38px;
}

textarea {
  resize: vertical;
  padding: 12px;
}

input:focus,
select:focus,
textarea:focus,
button:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(230, 109, 79, 0.34);
  outline-offset: 2px;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.segment {
  min-height: 38px;
  border: 1px solid rgba(36, 74, 58, 0.18);
  border-radius: var(--radius);
  color: var(--leaf);
  background: #fff;
  cursor: pointer;
  font-weight: 700;
}

.segment.is-active {
  color: var(--paper);
  background: var(--leaf);
}

.choice-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.choice-chip {
  min-height: 38px;
  border: 1px solid rgba(36, 74, 58, 0.18);
  border-radius: 999px;
  padding: 0 12px;
  color: var(--leaf);
  background: #fff;
  cursor: pointer;
  font-size: 0.86rem;
  font-weight: 800;
}

.choice-chip.is-active {
  color: var(--paper);
  background: var(--leaf);
}

.suggestion-allergy-chip {
  min-width: 42px;
  padding: 0 8px;
  color: var(--petal-ink);
  border-color: rgba(123, 49, 71, 0.22);
  background: var(--petal);
  font-size: 1.1rem;
  line-height: 1;
}

.marketplace-filter-chip {
  min-width: 42px;
  padding: 0 8px;
  color: var(--petal-ink);
  border-color: rgba(123, 49, 71, 0.22);
  background: var(--petal);
  font-size: 1.05rem;
  line-height: 1;
}

.marketplace-filter-chip:hover {
  background: var(--petal);
}

.suggestion-modal,
.marketplace-modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(22, 34, 29, 0.42);
}

.marketplace-modal {
  z-index: 92;
}

.suggestion-card {
  width: min(720px, 100%);
  max-height: min(760px, 94dvh);
  overflow: auto;
  border: 1px solid rgba(36, 74, 58, 0.18);
  border-radius: var(--radius);
  padding: 20px;
  background:
    radial-gradient(circle at 90% 0%, rgba(247, 200, 211, 0.55), transparent 34%),
    linear-gradient(145deg, rgba(217, 234, 215, 0.62), transparent 42%),
    var(--panel);
  box-shadow: var(--shadow);
  -webkit-overflow-scrolling: touch;
}

.marketplace-card {
  width: min(1120px, 100%);
  max-height: min(820px, 94dvh);
  overflow: auto;
  border: 1px solid rgba(123, 49, 71, 0.16);
  border-radius: var(--radius);
  padding: 20px;
  background:
    radial-gradient(circle at 86% 4%, rgba(247, 200, 211, 0.72), transparent 30%),
    linear-gradient(145deg, rgba(217, 234, 215, 0.56), transparent 44%),
    var(--panel);
  box-shadow: var(--shadow);
  -webkit-overflow-scrolling: touch;
}

.marketplace-heading {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: start;
  margin-bottom: 18px;
}

.marketplace-heading h2,
.marketplace-heading p,
.marketplace-hero h3,
.marketplace-hero p {
  margin: 0;
}

.marketplace-heading h2,
.marketplace-hero h3,
.marketplace-seller-card h3,
.marketplace-listing h3 {
  font-family: Georgia, "Times New Roman", serif;
}

.marketplace-heading__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.marketplace-view,
.marketplace-seller-view {
  display: grid;
  gap: 16px;
}

.marketplace-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.38fr);
  gap: 14px;
  align-items: stretch;
  border: 1px solid rgba(123, 49, 71, 0.12);
  border-radius: var(--radius);
  padding: 16px;
  background: rgba(253, 235, 240, 0.58);
}

.marketplace-fee-card,
.marketplace-info-block {
  display: grid;
  gap: 6px;
  border: 1px solid rgba(123, 49, 71, 0.14);
  border-radius: var(--radius);
  padding: 12px;
  background: rgba(255, 255, 255, 0.78);
}

.marketplace-fee-card span,
.marketplace-info-block span,
.marketplace-listing p,
.marketplace-safety-note,
.marketplace-checklist {
  color: var(--ink-soft);
  line-height: 1.42;
}

.marketplace-listings {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.marketplace-listing,
.marketplace-seller-card {
  display: grid;
  gap: 12px;
  border: 1px solid rgba(123, 49, 71, 0.13);
  border-radius: var(--radius);
  padding: 14px;
  background: rgba(255, 255, 255, 0.9);
}

.marketplace-listing__top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: start;
}

.marketplace-listing h3,
.marketplace-listing p,
.marketplace-seller-card h3,
.marketplace-seller-card p,
.marketplace-safety-note {
  margin: 0;
}

.marketplace-pill {
  color: var(--petal-ink);
  background: var(--petal-soft);
}

.marketplace-price {
  color: var(--petal-ink);
  font-size: 1.4rem;
}

.marketplace-allergy-tags span {
  color: var(--petal-ink);
  background: var(--petal-soft);
}

.marketplace-facts {
  gap: 8px;
}

.marketplace-seller-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.marketplace-seller-cta {
  width: fit-content;
}

.marketplace-checklist {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
}

.suggestion-heading {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: start;
  margin-bottom: 18px;
}

.suggestion-heading h2,
.suggestion-heading p {
  margin: 0;
}

.suggestion-heading h2 {
  margin-top: 6px;
  font-family: Georgia, "Times New Roman", serif;
}

.suggestion-form {
  display: grid;
  gap: 14px;
}

.suggestion-note,
.suggestion-status {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.4;
}

.suggestion-status {
  border-radius: var(--radius);
  padding: 10px;
  color: var(--petal-ink);
  background: var(--petal-soft);
  font-weight: 800;
}

.suggestion-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.filter-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.topbar-community-actions,
.filter-community-actions {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.topbar-community-actions .choice-chip {
  min-height: 40px;
}

.marketplace-application-form,
.auth-form {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.reset-filters-button {
  width: fit-content;
}

.check-row {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
}

.check-row input {
  min-height: 20px;
  margin: 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.stat-block {
  display: block;
  width: 100%;
  min-height: 88px;
  border: 1px solid rgba(36, 74, 58, 0.14);
  padding: 14px;
  border-radius: var(--radius);
  color: inherit;
  background: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  text-align: left;
  transition:
    background 160ms ease,
    border-color 160ms ease,
    transform 160ms ease;
}

.stat-block:hover {
  border-color: rgba(123, 49, 71, 0.28);
  background: rgba(253, 235, 240, 0.58);
  transform: translateY(-1px);
}

.stat-block strong {
  display: block;
  color: var(--leaf);
  font-size: 1.8rem;
}

.stat-block span {
  color: var(--ink-soft);
  font-size: 0.86rem;
}

.ad-slot {
  overflow: hidden;
  padding: 16px;
}

.ad-slot--green {
  background: linear-gradient(135deg, #e7f2de, #ffffff);
}

.ad-slot--blue {
  background: linear-gradient(135deg, #dceff4, #ffffff);
}

.ad-slot--yellow {
  background: linear-gradient(135deg, #fff2c4, #ffffff);
}

.ad-slot--coral {
  background: linear-gradient(135deg, #ffe1d8, #ffffff);
}

.ad-slot--mint,
.ad-slot--quiet {
  background: linear-gradient(135deg, #dceee4, #ffffff);
}

.donation-slot {
  border: 1px solid rgba(123, 49, 71, 0.22);
  background:
    linear-gradient(135deg, rgba(247, 200, 211, 0.42), transparent 54%),
    linear-gradient(145deg, #ffffff, #f6fbf2);
}

.ad-eyebrow {
  margin-bottom: 8px;
  color: var(--leaf);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.ad-body {
  display: grid;
  gap: 14px;
}

.ad-body h2 {
  margin: 0 0 6px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.25rem;
}

.ad-body p,
.ad-slot p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.45;
}

.ad-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.donation-actions {
  display: grid;
  align-items: center;
}

.donation-note {
  flex: 1 1 160px;
  min-width: 0;
  font-size: 0.84rem;
}

.donation-form {
  display: grid;
  gap: 10px;
  width: 100%;
}

.donation-amount-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  overflow: hidden;
  border: 1px solid rgba(36, 74, 58, 0.18);
  border-radius: var(--radius);
  background: #fff;
}

.donation-currency {
  display: grid;
  min-width: 38px;
  min-height: 44px;
  place-items: center;
  color: var(--leaf);
  background: var(--mint);
  font-weight: 900;
}

.donation-amount-row input {
  border: 0;
  border-radius: 0;
}

.donation-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.donation-preset {
  min-height: 34px;
  padding-inline: 10px;
}

.discovery-summary,
.location-map {
  border: 1px solid rgba(36, 74, 58, 0.15);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
}

.discovery-summary {
  overflow: hidden;
  padding: 20px;
  background:
    linear-gradient(135deg, rgba(246, 196, 83, 0.22), transparent 44%),
    linear-gradient(145deg, rgba(217, 234, 215, 0.92), rgba(255, 255, 255, 0.94));
}

.discovery-summary h1 {
  max-width: 820px;
  margin: 6px 0 10px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 5vw, 4.35rem);
  line-height: 0.98;
}

.discovery-summary p {
  max-width: 760px;
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.45;
}

.eyebrow {
  color: var(--leaf);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.explore-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 100%;
  overflow: auto;
  padding-right: 2px;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.location-map {
  display: grid;
  gap: 14px;
  padding: 16px;
}

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

.map-legend__item {
  border-radius: 999px;
  padding: 7px 10px;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
}

.map-legend__item--restaurant {
  background: var(--pin-restaurant);
}

.map-legend__item--grocery {
  background: var(--pin-grocery);
}

.map-legend__item--both {
  background: var(--pin-hybrid);
}

.map-controls {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 5px;
  border: 1px solid rgba(36, 74, 58, 0.14);
  border-radius: 18px;
  padding: 3px 5px;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.78);
  font-size: 0.82rem;
  font-weight: 800;
}

.map-main {
  display: grid;
  gap: 12px;
  min-width: 0;
  overflow-anchor: none;
}

.nearby-restaurants-panel {
  display: grid;
  align-content: start;
  gap: 12px;
  border: 1px solid rgba(36, 74, 58, 0.14);
  border-radius: var(--radius);
  padding: 16px;
  background: rgba(246, 248, 239, 0.72);
  box-shadow: var(--shadow);
}

.saved-places-panel {
  display: grid;
  align-content: start;
  gap: 12px;
  border: 1px solid rgba(123, 49, 71, 0.2);
  border-radius: var(--radius);
  padding: 16px;
  background:
    radial-gradient(circle at 100% 0%, rgba(247, 200, 211, 0.72), transparent 36%),
    linear-gradient(135deg, rgba(253, 235, 240, 0.94), rgba(245, 216, 212, 0.68));
  box-shadow: var(--shadow);
}

.saved-places-panel h3,
.nearby-restaurants-panel h3 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
}

.saved-places-panel p,
.nearby-restaurants-panel p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.84rem;
  line-height: 1.35;
}

.nearby-restaurants-list {
  display: grid;
  gap: 8px;
  max-height: 260px;
  overflow: auto;
  padding-right: 4px;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.saved-places-list {
  display: grid;
  gap: 8px;
  max-height: 220px;
  overflow: auto;
  padding-right: 4px;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.saved-place-row,
.nearby-restaurant-row {
  display: grid;
  gap: 4px;
  width: 100%;
  border: 1px solid rgba(36, 74, 58, 0.12);
  border-radius: var(--radius);
  padding: 10px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.82);
  cursor: pointer;
  text-align: left;
}

.saved-place-row {
  border-color: rgba(123, 49, 71, 0.16);
  background: rgba(255, 255, 255, 0.9);
}

.saved-place-row:hover,
.nearby-restaurant-row:hover {
  border-color: rgba(230, 109, 79, 0.5);
  background: #fff;
}

.saved-place-row span,
.nearby-restaurant-row span {
  color: var(--ink-soft);
  font-size: 0.78rem;
}

.map-control-button {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid rgba(36, 74, 58, 0.2);
  border-radius: 999px;
  color: var(--paper);
  background: var(--leaf);
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 900;
}

.map-control-button:hover {
  background: var(--leaf-bright);
}

.map-zoom-slider {
  width: 136px;
  min-height: 28px;
  padding: 0;
  accent-color: var(--leaf);
  cursor: pointer;
}

.map-canvas {
  position: relative;
  min-height: 430px;
  contain: layout paint;
  overflow: hidden;
  overflow-anchor: none;
  border: 1px solid rgba(36, 74, 58, 0.16);
  border-radius: var(--radius);
  background: #dbe8cf;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.map-canvas::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(0deg, transparent 0 47%, rgba(89, 112, 126, 0.42) 47% 48.5%, transparent 48.5% 100%),
    linear-gradient(90deg, transparent 0 18%, rgba(89, 112, 126, 0.34) 18% 19%, transparent 19% 100%),
    linear-gradient(90deg, transparent 0 72%, rgba(89, 112, 126, 0.34) 72% 73%, transparent 73% 100%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.18) 0 1px, transparent 1px 72px),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.18) 0 1px, transparent 1px 86px),
    linear-gradient(135deg, #d9e8cc, #cfdcbd);
}

.map-canvas.has-tile-fallback {
  background: #d9e8cc;
}

.map-canvas.is-dragging {
  cursor: grabbing;
}

.map-pin,
.user-location-dot {
  position: absolute;
  transform: translate(-50%, -50%);
  z-index: 2;
}

.local-map-layer {
  position: absolute;
  inset: 0;
}

.local-map-layer {
  z-index: 1;
  transform-origin: center center;
  will-change: transform;
}

.map-tile {
  position: absolute;
  z-index: 1;
  display: block;
  width: 256px;
  height: 256px;
  object-fit: cover;
  pointer-events: none;
  user-select: none;
}

.map-attribution {
  position: absolute;
  right: 8px;
  bottom: 8px;
  z-index: 5;
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.82);
  font-size: 0.68rem;
  font-weight: 800;
}

.map-pin {
  display: block;
  width: 48px;
  height: 48px;
  place-items: center;
  overflow: visible;
  border: 3px solid #fff;
  border-radius: 999px;
  color: var(--ink);
  background: var(--paper);
  box-shadow: 0 10px 18px rgba(22, 34, 29, 0.2);
  cursor: pointer;
  padding: 0;
}

.map-pin:hover,
.map-pin:focus-visible,
.map-pin.is-selected {
  z-index: 4;
  border-color: var(--coral);
  box-shadow: 0 14px 24px rgba(22, 34, 29, 0.26);
}

.map-pin--grocery {
  border-color: #d8edf3;
}

.map-pin--both {
  border-color: #d5ebe0;
}

.map-pin__photo,
.map-pin__fallback {
  position: absolute;
  inset: 3px;
  display: grid;
  width: calc(100% - 6px);
  height: calc(100% - 6px);
  place-items: center;
  border-radius: inherit;
}

.map-pin__photo {
  z-index: 2;
  object-fit: cover;
  background: var(--paper-soft);
}

.map-pin__fallback {
  z-index: 1;
  color: var(--ink-soft);
  background:
    linear-gradient(rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0.3)),
    var(--paper-soft);
  font-size: 0.5rem;
  font-weight: 900;
  line-height: 1.1;
  padding: 4px;
  text-align: center;
}

.map-pin__badge {
  position: absolute;
  right: -8px;
  bottom: -5px;
  z-index: 3;
  display: grid;
  min-width: 22px;
  height: 22px;
  place-items: center;
  border: 2px solid #fff;
  border-radius: 999px;
  color: var(--paper);
  background: var(--pin-restaurant);
  box-shadow: 0 6px 12px rgba(22, 34, 29, 0.18);
  font-size: 0.56rem;
  font-weight: 900;
  line-height: 1;
}

.map-pin--grocery .map-pin__badge {
  background: var(--pin-grocery);
}

.map-pin--both .map-pin__badge {
  min-width: 28px;
  background: var(--pin-hybrid);
}

.user-location-dot {
  display: grid;
  min-width: 54px;
  min-height: 32px;
  place-items: center;
  border: 2px solid #fff;
  border-radius: 999px;
  color: var(--paper);
  background: var(--coral);
  box-shadow: 0 10px 22px rgba(230, 109, 79, 0.26);
  font-size: 0.74rem;
  font-weight: 900;
}

.map-panel {
  padding: 16px;
}

.detail-content .map-panel {
  padding: 12px;
  box-shadow: none;
}

.detail-map-panel {
  max-width: 380px;
}

.embedded-map {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.embedded-map iframe {
  width: 100%;
  min-height: 150px;
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(36, 74, 58, 0.22);
  border-radius: var(--radius);
  background: #edf4ea;
}

.detail-embedded-map-canvas {
  min-height: 170px;
  aspect-ratio: 16 / 9;
  cursor: default;
  touch-action: auto;
}

.map-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.section-heading h1,
.section-heading h2,
.section-heading h3 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.05;
}

.section-heading h1 {
  font-size: 2rem;
}

.section-heading p {
  max-width: 42rem;
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.45;
}

.map-list {
  display: grid;
  gap: 8px;
}

.map-row {
  display: block;
  width: 100%;
  padding: 10px 0;
  border: 0;
  border-bottom: 1px solid rgba(36, 74, 58, 0.12);
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  font: inherit;
  text-align: left;
  text-decoration: none;
}

.map-row:last-child {
  border-bottom: 0;
}

.results-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 100%;
  overflow: auto;
  padding-right: 2px;
  overscroll-behavior: contain;
}

.results-list {
  display: grid;
  gap: 14px;
}

.place-card {
  display: grid;
  grid-template-columns: 148px 1fr;
  overflow: hidden;
  border: 1px solid rgba(36, 74, 58, 0.15);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 28px rgba(22, 34, 29, 0.08);
}

.place-card.is-selected {
  border-color: var(--coral);
  box-shadow: 0 16px 34px rgba(230, 109, 79, 0.16);
}

.place-card__image,
.detail-hero {
  background:
    linear-gradient(135deg, rgba(217, 234, 215, 0.96), rgba(246, 196, 83, 0.2)),
    repeating-linear-gradient(45deg, rgba(47, 111, 82, 0.08) 0 10px, transparent 10px 20px),
    var(--mint);
  background-position: center;
  background-size: cover;
}

.place-card__image {
  position: relative;
  display: grid;
  min-height: 100%;
  place-items: center;
  overflow: hidden;
}

.place-card__image img {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  min-height: 100%;
  object-fit: cover;
}

.place-card__image-fallback {
  position: relative;
  z-index: 0;
  display: grid;
  width: 72px;
  height: 72px;
  place-items: center;
  border: 2px solid rgba(255, 255, 255, 0.76);
  border-radius: 999px;
  color: var(--leaf);
  background: rgba(255, 255, 255, 0.56);
  box-shadow: 0 12px 24px rgba(22, 34, 29, 0.12);
  font-size: 0.78rem;
  font-weight: 900;
  text-align: center;
}

.place-card__body {
  display: grid;
  gap: 9px;
  padding: 14px;
}

.place-card__topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.pill {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  border: 1px solid rgba(36, 74, 58, 0.16);
  border-radius: 999px;
  padding: 5px 10px;
  color: var(--leaf);
  background: var(--mint);
  font-size: 0.75rem;
  font-weight: 800;
}

.place-card h3 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.25rem;
}

.place-card p {
  margin: 0;
  line-height: 1.4;
}

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

.mini-ratings {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mini-ratings span {
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--ink);
  background: #eef4eb;
  font-size: 0.78rem;
  font-weight: 700;
}

.card-actions,
.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.detail-panel {
  align-self: start;
  max-height: 100%;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.detail-mobile-bar {
  display: none;
}

.detail-hero {
  min-height: 190px;
  background-image:
    var(--place-image),
    linear-gradient(135deg, rgba(217, 234, 215, 0.96), rgba(246, 196, 83, 0.2)),
    repeating-linear-gradient(45deg, rgba(47, 111, 82, 0.08) 0 10px, transparent 10px 20px);
}

.detail-content {
  display: grid;
  gap: 18px;
  padding: 18px;
}

.detail-heading {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: start;
}

.detail-heading h2 {
  margin: 8px 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.85rem;
  line-height: 1.05;
}

.source-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.source-strip span {
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--ink);
  background: #f0f3ea;
  font-size: 0.78rem;
  font-weight: 700;
}

.source-strip span:nth-child(2) {
  color: var(--petal-ink);
  background: var(--petal-soft);
}

.ratings-panel,
.allergy-box,
.sources-panel,
.reviews-panel,
.review-links-panel,
.rating-form {
  display: grid;
  gap: 12px;
}

.ratings-panel,
.saved-rating-panel {
  border: 1px solid rgba(36, 74, 58, 0.12);
  border-radius: var(--radius);
  padding: 12px;
  background: rgba(246, 248, 239, 0.55);
}

.saved-rating-panel {
  border-color: rgba(123, 49, 71, 0.16);
  background:
    linear-gradient(135deg, rgba(253, 235, 240, 0.82), transparent 70%),
    rgba(217, 234, 215, 0.32);
}

.reviews-panel,
.review-links-panel {
  border: 1px solid rgba(123, 49, 71, 0.13);
  border-radius: var(--radius);
  padding: 12px;
  background: rgba(253, 235, 240, 0.42);
}

.review-list {
  display: grid;
  gap: 10px;
}

.menu-panel {
  display: grid;
  gap: 14px;
  border: 1px solid rgba(36, 74, 58, 0.14);
  border-radius: var(--radius);
  padding: 14px;
  background:
    radial-gradient(circle at 100% 0%, rgba(247, 200, 211, 0.36), transparent 34%),
    rgba(255, 255, 255, 0.9);
}

.menu-highlight-grid,
.community-item-list {
  display: grid;
  gap: 10px;
}

.menu-highlight-card,
.community-item-card,
.item-report-form {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(36, 74, 58, 0.12);
  border-radius: var(--radius);
  padding: 12px;
  background: #fff;
}

.menu-highlight-card p,
.community-item-card p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.42;
}

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

.menu-tags span,
.community-item-card__top span,
.community-finds__heading span {
  border-radius: 999px;
  padding: 4px 8px;
  color: var(--petal-ink);
  background: var(--petal-soft);
  font-size: 0.74rem;
  font-weight: 800;
}

.menu-source-link,
.community-item-card__meta a {
  width: fit-content;
  color: var(--leaf);
  font-size: 0.84rem;
  font-weight: 800;
}

.community-finds,
.item-report-form {
  display: grid;
  gap: 10px;
}

.community-reports-drawer {
  overflow: hidden;
  border: 1px solid rgba(36, 74, 58, 0.14);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
}

.community-reports-drawer__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  list-style: none;
  padding: 10px 12px;
  cursor: pointer;
}

.community-reports-drawer__summary::marker {
  display: none;
  content: "";
}

.community-reports-drawer__summary::-webkit-details-marker {
  display: none;
}

.community-reports-drawer__title {
  color: var(--leaf);
  font-weight: 800;
}

.community-reports-drawer__meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.community-reports-drawer__count {
  border-radius: 999px;
  padding: 4px 8px;
  color: var(--petal-ink);
  background: var(--petal-soft);
  font-size: 0.74rem;
  font-weight: 800;
}

.community-reports-drawer__hint {
  color: var(--ink-soft);
  font-size: 0.76rem;
  font-weight: 700;
}

.community-reports-drawer__hint-open,
.community-reports-drawer[open] .community-reports-drawer__hint-closed {
  display: none;
}

.community-reports-drawer[open] .community-reports-drawer__hint-open {
  display: inline;
}

.community-reports-drawer__content {
  display: grid;
  gap: 10px;
  border-top: 1px solid rgba(36, 74, 58, 0.12);
  padding: 0 12px 12px;
}

.community-finds__heading,
.community-item-card__top,
.community-item-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.community-finds__heading h4,
.item-report-form h4 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
}

.community-item-card__meta {
  justify-content: flex-start;
  color: var(--ink-soft);
  font-size: 0.8rem;
}

.item-report-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(130px, 0.8fr);
  gap: 10px;
}

.review-card {
  display: grid;
  gap: 6px;
  border: 1px solid rgba(123, 49, 71, 0.14);
  border-radius: var(--radius);
  padding: 12px;
  background: #fff;
}

.review-card__topline {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.review-card__topline > span:first-child {
  display: grid;
  gap: 2px;
}

.review-rating-details {
  display: grid;
  gap: 8px;
  border-top: 1px solid rgba(123, 49, 71, 0.1);
  padding-top: 8px;
}

.review-card__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  list-style: none;
  cursor: pointer;
}

.review-card__summary::marker {
  display: none;
  content: "";
}

.review-card__summary::-webkit-details-marker {
  display: none;
}

.review-card__hint {
  border: 1px solid rgba(123, 49, 71, 0.16);
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--petal-ink);
  background: var(--petal-soft);
  font-size: 0.74rem;
  font-weight: 800;
  white-space: nowrap;
}

.review-rating-details[open] .review-card__hint {
  color: var(--paper);
  background: var(--petal-ink);
}

.review-card__hint-open,
.review-rating-details[open] .review-card__hint-closed {
  display: none;
}

.review-rating-details[open] .review-card__hint-open {
  display: inline;
}

.review-card p {
  margin: 0;
  line-height: 1.42;
}

.review-score-list {
  display: grid;
  gap: 8px;
  border-top: 1px solid rgba(123, 49, 71, 0.12);
  padding-top: 10px;
}

.review-score-title {
  color: var(--petal-ink);
  font-size: 0.86rem;
}

.review-score-row {
  display: grid;
  grid-template-columns: minmax(118px, 1fr) minmax(90px, 1fr) 48px;
  gap: 8px;
  align-items: center;
}

.review-score-row span {
  color: var(--ink-soft);
  font-size: 0.84rem;
}

.review-score-track {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #f0dce2;
}

.review-score-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--petal), var(--sun));
}

.review-score-row strong {
  color: var(--petal-ink);
  font-size: 0.82rem;
  text-align: right;
}

.rating-row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(110px, 1.2fr) 42px;
  gap: 10px;
  align-items: center;
}

.rating-row span {
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.rating-track {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #e6ebe0;
}

.rating-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--leaf-bright), var(--sun));
}

dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

dt {
  color: var(--ink);
  font-weight: 800;
}

dd {
  margin: 3px 0 0;
  color: var(--ink-soft);
  line-height: 1.42;
}

.safety-note {
  margin: 0;
  border-left: 4px solid var(--coral);
  padding: 10px 12px;
  color: var(--ink);
  background: #fff2ed;
  line-height: 1.4;
}

.tag-cloud,
.source-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag-cloud span,
.source-links a {
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--leaf);
  background: #edf4ea;
  font-size: 0.8rem;
  font-weight: 800;
  text-decoration: none;
}

.slider-row,
.review-field {
  display: grid;
  gap: 8px;
}

.slider-row {
  grid-template-columns: minmax(130px, 1fr) minmax(130px, 1.4fr) 38px;
  align-items: center;
}

.slider-row input {
  accent-color: var(--leaf);
}

.slider-value {
  display: grid;
  min-height: 32px;
  place-items: center;
  border: 1px solid rgba(36, 74, 58, 0.16);
  border-radius: var(--radius);
  color: var(--leaf);
  background: var(--mint);
}

.empty-state {
  padding: 22px;
}

.empty-state h2 {
  margin: 0 0 8px;
  font-family: Georgia, "Times New Roman", serif;
}

.empty-state p {
  margin: 0;
  color: var(--ink-soft);
}

@media (max-width: 1220px) {
  .workspace,
  .workspace.has-detail {
    grid-template-columns: minmax(260px, 0.8fr) minmax(360px, 1fr);
    height: auto;
    margin-top: var(--search-height);
    overflow: visible;
  }

  .control-panel,
  .explore-panel,
  .results-panel {
    max-height: none;
    overflow: visible;
  }

  .detail-panel {
    grid-column: 1 / -1;
    max-height: none;
    overflow: visible;
  }
}

@media (min-width: 981px) and (max-width: 1220px) {
  .workspace,
  .workspace.has-detail {
    height: calc(100vh - var(--topbar-height) - var(--search-height));
    overflow: hidden;
  }

  .control-panel,
  .explore-panel,
  .results-panel {
    max-height: 100%;
  }

  .control-panel {
    height: 100%;
    min-height: 0;
    overflow: hidden;
  }

  .explore-panel,
  .results-panel {
    overflow: auto;
  }
}

@media (max-width: 980px) {
  html {
    scroll-padding-top: 92px;
  }

  .topbar {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .topbar-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    align-items: stretch;
    gap: 8px;
  }

  .topbar-community-actions {
    display: contents;
  }

  .topbar-community-actions .choice-chip {
    min-width: 0;
    width: 100%;
    min-height: 38px;
  }

  .subscription-toggle {
    width: 100%;
    min-height: 38px;
    padding: 0 10px;
    font-size: 0.88rem;
  }

  .sync-note {
    grid-column: 1 / -1;
    font-size: 0.82rem;
  }

  .topbar-actions .subscription-toggle:last-child {
    grid-column: 1 / -1;
  }

  .workspace,
  .workspace.has-detail {
    grid-template-columns: 1fr;
    gap: 12px;
    height: auto;
    margin-top: 0;
    overflow: visible;
    padding: 10px;
    padding-bottom: max(22px, env(safe-area-inset-bottom));
  }

  .control-panel,
  .explore-panel,
  .results-panel {
    max-height: none;
    overflow: visible;
  }

  .control-panel {
    position: sticky;
    top: 8px;
    z-index: 16;
    display: block;
    width: 100%;
    max-width: none;
    padding: 0;
  }

  .control-menu:not([open]) {
    width: 100%;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 10px 26px rgba(22, 34, 29, 0.12);
    backdrop-filter: blur(12px);
  }

  .control-menu:not([open]) .control-menu__summary {
    min-height: 42px;
    gap: 8px;
    padding: 0 14px;
    font-size: 0.84rem;
  }

  .control-menu:not([open]) .control-menu__summary strong {
    display: none;
  }

  .control-menu:not([open]) .menu-trigger {
    gap: 7px;
  }

  .control-menu:not([open]) .menu-mark {
    width: 18px;
    gap: 1px;
    color: rgba(36, 74, 58, 0.72);
  }

  .control-menu:not([open]) .menu-mark span {
    height: 4px;
    border-top-width: 1px;
  }

  .control-menu:not([open]) .menu-mark span:nth-child(1) {
    width: 13px;
  }

  .control-menu:not([open]) .menu-mark span:nth-child(2) {
    width: 17px;
  }

  .control-menu:not([open]) .menu-mark span:nth-child(3) {
    width: 14px;
  }

  .search-strip {
    display: none;
  }

  .search-row {
    grid-template-columns: 1fr;
  }

  .search-submit {
    width: 100%;
  }

  .mobile-filter-search {
    display: flex;
    flex-direction: column;
    gap: 14px;
    border: 1px solid rgba(36, 74, 58, 0.15);
    border-radius: var(--radius);
    padding: 16px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow);
  }

  .map-canvas {
    min-height: 320px;
    min-height: min(360px, 58dvh);
  }

  .control-menu[open] {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: flex;
    flex-direction: column;
    max-height: 100vh;
    max-height: 100dvh;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background:
      linear-gradient(145deg, rgba(217, 234, 215, 0.68), transparent 42%),
      var(--paper);
  }

  .control-menu[open] .control-menu__summary {
    position: sticky;
    top: 0;
    z-index: 2;
    min-height: 72px;
    border-bottom: 1px solid rgba(36, 74, 58, 0.15);
    padding-right: max(18px, env(safe-area-inset-right));
    padding-left: max(18px, env(safe-area-inset-left));
    background: rgba(246, 248, 239, 0.96);
    backdrop-filter: blur(14px);
  }

  .control-menu[open] .control-menu__content {
    flex: 1;
    align-content: start;
    max-height: none;
    overflow: auto;
    padding: 18px max(18px, env(safe-area-inset-right)) max(28px, env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left));
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .control-menu[open] .search-panel,
  .control-menu[open] .ad-slot {
    background: rgba(255, 255, 255, 0.9);
  }

  .detail-panel {
    display: none;
  }

  .detail-panel.is-open {
    position: fixed;
    inset: 0;
    z-index: 70;
    display: block;
    max-height: 100vh;
    max-height: 100dvh;
    overflow: auto;
    border: 0;
    border-radius: 0;
    background: var(--paper);
    box-shadow: none;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .detail-panel.is-open .detail-mobile-bar {
    position: sticky;
    top: 0;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 64px;
    border-bottom: 1px solid rgba(36, 74, 58, 0.15);
    padding: 10px max(14px, env(safe-area-inset-right)) 10px max(14px, env(safe-area-inset-left));
    background: rgba(246, 248, 239, 0.96);
    backdrop-filter: blur(14px);
  }

  .detail-panel.is-open .detail-content {
    overflow: visible;
  }

  .detail-panel.is-open .detail-hero {
    min-height: 210px;
  }

  .marketplace-modal {
    display: flex;
    overflow: hidden;
    padding: 0;
    background: var(--paper);
  }

  .marketplace-card {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    overflow-y: auto;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .marketplace-heading,
  .marketplace-hero,
  .marketplace-listings,
  .marketplace-seller-grid {
    grid-template-columns: 1fr;
  }

  .marketplace-heading__actions {
    justify-content: stretch;
  }

  .marketplace-heading__actions .button,
  .marketplace-heading__actions .icon-button,
  .marketplace-seller-cta {
    width: 100%;
  }

  .section-heading {
    align-items: start;
    flex-direction: column;
  }

  .section-heading h1 {
    font-size: 1.65rem;
  }

  .place-card {
    grid-template-columns: 1fr;
  }

  .place-card__image {
    aspect-ratio: 16 / 9;
    min-height: 150px;
  }

  .detail-map-panel {
    display: none;
  }

  .control-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .detail-heading {
    grid-template-columns: 1fr;
  }

  .rating-row {
    grid-template-columns: 1fr 1fr 42px;
  }

  .slider-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 470px) {
  .topbar {
    padding: 12px;
  }

  .brand-name {
    font-size: 1rem;
  }

  .brand-subtitle {
    font-size: 0.68rem;
  }

  .search-panel,
  .mobile-filter-search,
  .search-strip,
  .ad-slot,
  .discovery-summary,
  .location-map,
  .saved-places-panel,
  .nearby-restaurants-panel,
  .map-panel,
  .detail-content {
    padding: 12px;
  }

  .stat-block {
    min-height: 72px;
  }

  .stat-block strong {
    font-size: 1.45rem;
  }

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

  .card-actions .button,
  .action-row .button,
  .map-actions .button {
    width: 100%;
  }

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

  .rating-row {
    grid-template-columns: 1fr;
  }

  .item-report-grid {
    grid-template-columns: 1fr;
  }

  .review-card__summary {
    align-items: start;
    flex-direction: column;
  }

  .review-score-row {
    grid-template-columns: 1fr;
  }

  .review-score-row strong {
    text-align: left;
  }
}

.legal-footer {
  display: grid;
  gap: 8px;
  padding: 18px 24px 26px;
  color: var(--ink-soft);
  font-size: 0.82rem;
}

.legal-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.legal-footer a {
  color: var(--green-900);
  font-weight: 800;
  text-decoration: none;
}

.legal-footer p {
  max-width: 920px;
  margin: 0;
}

.legal-page {
  min-height: 100vh;
  background: var(--cream);
  color: var(--ink);
}

.legal-page__header,
.legal-page__content,
.legal-page__footer {
  width: min(920px, calc(100% - 32px));
  margin: 0 auto;
}

.legal-page__header {
  display: grid;
  gap: 10px;
  padding: 38px 0 22px;
}

.legal-page__header a,
.legal-page__footer a {
  color: var(--green-900);
  font-weight: 800;
  text-decoration: none;
}

.legal-page__header h1 {
  margin: 0;
  font-size: clamp(2rem, 6vw, 4rem);
  line-height: 0.98;
}

.legal-page__content {
  display: grid;
  gap: 22px;
  padding: 10px 0 36px;
}

.legal-page__content section,
.contact-panel {
  display: grid;
  gap: 10px;
  padding: 18px 0;
  border-top: 1px solid rgba(36, 74, 58, 0.16);
}

.legal-page__content h2,
.contact-panel h2 {
  margin: 0;
  font-size: 1.35rem;
}

.legal-page__content p,
.legal-page__content li {
  color: var(--ink-soft);
  line-height: 1.65;
}

.legal-page__content ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
}

.legal-page__footer {
  padding: 0 0 36px;
}

.contact-form {
  display: grid;
  gap: 14px;
  max-width: 680px;
}

.contact-form__grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.contact-form label {
  display: grid;
  gap: 6px;
  font-weight: 800;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid rgba(36, 74, 58, 0.22);
  border-radius: 8px;
  padding: 12px;
  font: inherit;
}

.contact-form textarea {
  resize: vertical;
}

.contact-status {
  min-height: 1.25rem;
  color: var(--green-900);
  font-weight: 800;
}

@media (max-width: 640px) {
  .contact-form__grid {
    grid-template-columns: 1fr;
  }
}
