:root {
  color-scheme: light;
  --bg: #ffffff;
  --paper: #fff8ef;
  --surface: #ffffff;
  --surface-strong: #f4fbfc;
  --text: #132330;
  --muted: #5f6f78;
  --line: #d9e2e4;
  --navy: #142837;
  --accent: #e85a2a;
  --accent-dark: #a93517;
  --catalog: #5b4bb2;
  --catalog-dark: #43308f;
  --catalog-soft: #ece9ff;
  --sea: #16829a;
  --sea-soft: #dff5f7;
  --yellow: #ffd166;
  --shadow: 0 18px 44px rgba(19, 35, 48, 0.12);
  --radius: 8px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  overflow-x: clip;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  color: var(--accent-dark);
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

svg {
  width: 1.1em;
  height: 1.1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

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

.topbar {
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 22px 10px;
}

.brand-home {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  color: var(--navy);
}

.brand-logo {
  width: 54px;
  height: 54px;
  object-fit: contain;
}

.view-nav {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 22px 16px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.nav-tab,
.seo-nav a {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  padding: 9px 13px;
  border-radius: 999px;
  font-size: 0.94rem;
  font-weight: 700;
}

.nav-tab.active,
.seo-nav a:hover {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}

main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 22px 44px;
}

.home-hero {
  min-height: 470px;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(280px, 0.7fr);
  align-items: start;
  gap: 36px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 42px 0;
}

.hero-copy h1,
.section-heading h1 {
  margin: 0;
  max-width: 760px;
  font-size: clamp(2.4rem, 5vw, 4.8rem);
  line-height: 0.95;
  letter-spacing: 0;
  color: var(--navy);
  overflow-wrap: anywhere;
  hyphens: auto;
}

.lead-text,
.section-heading p {
  max-width: 660px;
  color: var(--muted);
  font-size: 1.1rem;
  line-height: 1.65;
}

form label,
.toolbar label {
  display: block;
  margin-bottom: 8px;
  font-weight: 800;
  color: var(--navy);
}

.search-line {
  display: flex;
  gap: 10px;
  max-width: 720px;
}

.input-wrap {
  position: relative;
  flex: 1;
}

input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 15px 46px 15px 15px;
  color: var(--text);
  background: var(--surface);
  outline: none;
}

input:focus {
  border-color: var(--sea);
  box-shadow: 0 0 0 3px rgba(22, 130, 154, 0.14);
}

.clear {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 8px;
}

.primary,
.secondary,
.filter-chip {
  border: 0;
  border-radius: var(--radius);
  font-weight: 800;
}

.primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 20px;
  background: var(--accent);
  color: #fff;
  min-width: 116px;
}

.secondary,
.secondary-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--navy);
  padding: 8px 10px;
  font-size: 0.9rem;
  font-weight: 800;
}

.small {
  font-size: 0.85rem;
}

.filter-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.filter-chip {
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  padding: 9px 12px;
}

.filter-chip.active {
  background: var(--sea);
  border-color: var(--sea);
  color: #fff;
}

.hero-card {
  align-self: start;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #fff 0%, var(--paper) 100%);
  padding: 16px;
  box-shadow: var(--shadow);
}

.hero-card img {
  width: 100%;
  max-height: 96px;
  object-fit: contain;
  margin-bottom: 10px;
}

.stat-grid {
  display: grid;
  gap: 7px;
}

.stat-grid span {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 7px;
  color: var(--muted);
}

.stat-grid b {
  font-size: 1.35rem;
  color: var(--navy);
}

.hero-card p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.4;
}

.landing-sections,
.content-grid,
.seo-section-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 28px 0;
}

.content-card,
.store-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 18px;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.content-card h2,
.store-card h3 {
  margin: 0 0 10px;
  color: var(--navy);
}

.content-card p,
.store-card p {
  margin: 0 0 10px;
  color: var(--muted);
  line-height: 1.5;
}

.home-card-link {
  transition: transform 160ms ease, border-color 160ms ease;
}

.home-card-link:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
}

.results-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.85fr);
  gap: 22px;
  align-items: start;
  margin-top: 30px;
}

.section-heading {
  padding: 44px 0 22px;
}

.compact-heading {
  padding: 0 0 12px;
}

.compact-heading h2,
.map-heading-row h2,
.store-section h2,
.source-list h2 {
  margin: 0;
  color: var(--navy);
}

.result-list,
.store-grid,
.card-grid {
  display: grid;
  gap: 14px;
}

.store-grid,
.card-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.result-list h3 {
  margin: 22px 0 2px;
  color: var(--navy);
}

.store-card-top {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  min-height: 27px;
  margin-bottom: 12px;
}

.evidence-badge,
.review-flag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 0.78rem;
  font-weight: 850;
}

.evidence-badge.direct {
  background: #ffe5d8;
  color: var(--accent-dark);
}

.evidence-badge.catalog {
  background: var(--catalog-soft);
  color: var(--catalog-dark);
}

.evidence-badge.chain {
  background: var(--sea-soft);
  color: #075468;
}

.review-flag {
  background: #fff4c2;
  color: #765800;
}

.address {
  color: var(--text) !important;
  font-weight: 700;
}

.website {
  margin-top: -4px !important;
  color: var(--sea) !important;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.website a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

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

.card-meta {
  font-weight: 800;
  color: var(--sea) !important;
}

.card-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.map-panel {
  position: sticky;
  top: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-strong);
  padding: 16px;
}

.static-map-panel {
  position: static;
  margin: 24px 0;
}

.map-heading-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.map-heading-row p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

#store-map,
.static-map {
  min-height: 430px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: #e7f2f4;
  overflow: hidden;
}

.map-fallback {
  min-height: 220px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  margin: 0;
  padding: 18px;
}

.map-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.35;
}

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

.map-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
}

.map-legend-marker {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
}

.map-popup {
  display: grid;
  gap: 4px;
  font-size: 0.9rem;
}

.map-popup span,
.map-popup em {
  color: #52636d;
}

.leaflet-marker-icon.directory-marker {
  background: transparent;
  border: 0;
}

.directory-marker {
  display: grid;
  place-items: center;
}

.map-popup,
.map-popup a {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.fish-marker {
  position: relative;
  display: grid;
  place-items: center;
  border: 3px solid #fff;
  box-shadow: 0 8px 18px rgba(19, 35, 48, 0.28);
}

.fish-marker-direct {
  width: 31px;
  height: 31px;
  background: var(--accent);
  border-radius: 50% 50% 50% 7px;
  transform: rotate(-45deg);
}

.fish-marker-direct::after {
  content: "";
  position: absolute;
  right: -2px;
  bottom: -2px;
  width: 9px;
  height: 9px;
  background: var(--accent);
  border-right: 3px solid #fff;
  border-bottom: 3px solid #fff;
}

.fish-marker-chain {
  width: 32px;
  height: 32px;
  background: var(--sea);
  border-radius: 7px;
}

.fish-marker-catalog {
  width: 31px;
  height: 31px;
  background: var(--catalog);
  border-radius: 50% 50% 50% 7px;
  transform: rotate(-45deg);
}

.fish-marker-catalog::after {
  content: "";
  position: absolute;
  right: -2px;
  bottom: -2px;
  width: 9px;
  height: 9px;
  background: var(--catalog);
  border-right: 3px solid #fff;
  border-bottom: 3px solid #fff;
}

.fish-shape {
  position: relative;
  width: 17px;
  height: 10px;
  background: #fff;
  border-radius: 55% 45% 45% 55%;
  z-index: 1;
}

.fish-marker-direct .fish-shape {
  transform: rotate(45deg);
}

.fish-marker-catalog .fish-shape {
  transform: rotate(45deg);
}

.fish-shape::before {
  content: "";
  position: absolute;
  right: -6px;
  top: 0;
  width: 0;
  height: 0;
  border-left: 7px solid #fff;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
}

.fish-eye {
  content: "";
  position: absolute;
  left: 4px;
  top: 3px;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: var(--navy);
}

.toolbar {
  max-width: 540px;
  margin-bottom: 22px;
}

.store-section,
.source-list {
  margin: 30px 0;
}

.source-list ul {
  margin: 12px 0 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.7;
}

footer {
  max-width: 1180px;
  margin: 0 auto;
  padding: 28px 22px 44px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

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

.empty,
.load-error {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 24px;
  color: var(--muted);
  display: flex;
  gap: 12px;
  align-items: center;
}

[hidden] {
  display: none !important;
}

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

  .map-panel {
    position: static;
  }

  .landing-sections,
  .content-grid,
  .seo-section-grid,
  .store-grid,
  .card-grid {
    grid-template-columns: 1fr;
  }

  .search-line {
    flex-direction: column;
  }

  .primary {
    min-height: 50px;
  }

  .hero-copy h1,
  .section-heading h1 {
    font-size: clamp(2rem, 10vw, 3rem);
    line-height: 1;
  }
}

@media (max-width: 560px) {
  .topbar,
  .view-nav,
  main,
  footer {
    padding-left: 16px;
    padding-right: 16px;
  }

  .home-hero {
    padding: 32px 0;
    min-height: auto;
  }

  #store-map,
  .static-map {
    min-height: 320px;
  }
}
