:root {
  --teal-deep: #0f3a3e;
  --teal-mid: #1d6b6f;
  --amber: #c98a3b;
  --slate: #6b7475;
  --ink: #1b2a2c;
  --bg: #f6f5f1;
  --card: #ffffff;
  --border: #e1ddd2;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
}

header.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  background: var(--teal-deep);
  color: #fff;
}

header.site-header a { color: #fff; text-decoration: none; }

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
}

nav.site-nav a {
  margin-left: 18px;
  font-size: 0.95rem;
  opacity: 0.9;
}
nav.site-nav a:hover { opacity: 1; text-decoration: underline; }

main { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

#map {
  width: 100%;
  height: 72vh;
  min-height: 480px;
}

.map-page main { max-width: none; padding: 0; }

.map-filters {
  background: var(--card);
  border-bottom: 1px solid var(--border);
  padding: 12px 20px;
}
.map-filters-row {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
}
.filter-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.filter-group-end { margin-left: auto; gap: 14px; }
.filter-group-label {
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--teal-deep);
  margin-right: 2px;
}
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.85rem;
  color: var(--ink);
  background: #f0eee7;
  border-radius: 999px;
  padding: 4px 10px 4px 8px;
  cursor: pointer;
  user-select: none;
}
.filter-chip input { accent-color: var(--teal-mid); cursor: pointer; }
#species-filter {
  font-size: 0.85rem;
  padding: 5px 8px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--ink);
  max-width: 180px;
}
.filter-count { font-size: 0.85rem; color: var(--slate); white-space: nowrap; }
.filter-clear {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--teal-mid);
  background: none;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 12px;
  cursor: pointer;
  white-space: nowrap;
}
.filter-clear:hover { background: #f0eee7; }
@media (max-width: 900px) {
  .map-filters-row { gap: 12px; }
  .filter-group-end { margin-left: 0; width: 100%; justify-content: space-between; }
}

.hero-map {
  background: linear-gradient(135deg, var(--teal-deep), var(--teal-mid));
  border-radius: 14px;
  margin: 32px 0;
  padding: 56px 32px;
  text-align: center;
  color: #fff;
}
.hero-map-inner { max-width: 640px; margin: 0 auto; }
.hero-map h1 { font-size: 2rem; margin: 0 0 12px; color: #fff; }
.hero-map p { font-size: 1.05rem; color: #dcebe9; margin: 0 0 24px; }
.hero-cta {
  display: inline-block;
  background: var(--amber);
  color: #fff;
  font-weight: 700;
  padding: 12px 28px;
  border-radius: 999px;
  text-decoration: none;
  font-size: 1rem;
}
.hero-cta:hover { opacity: 0.92; }

.home-about {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
.home-about .spot-detail { padding: 40px 0 64px; }
.home-about h2 { color: var(--teal-deep); margin-bottom: 16px; margin-top: 40px; }
.home-about h2:first-child { margin-top: 0; }

.feature-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 8px;
}
.feature-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
  text-decoration: none;
  color: var(--ink);
  transition: box-shadow 0.15s, transform 0.15s;
}
.feature-card:hover { box-shadow: 0 4px 14px rgba(15, 58, 62, 0.12); transform: translateY(-2px); }
.feature-icon { width: 48px; height: 48px; object-fit: contain; }
.feature-title { font-weight: 700; color: var(--teal-deep); }
.feature-desc { font-size: 0.88rem; color: var(--slate); }

.latest-spots-list {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 8px;
  background: var(--card);
}
.latest-spot-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 10px 16px;
  text-decoration: none;
  color: var(--ink);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  overflow: hidden;
}
.latest-spot-row:last-child { border-bottom: 0; }
.latest-spot-row:hover { background: #f0eee7; }
.latest-spot-name {
  font-weight: 700;
  color: var(--teal-deep);
  flex: 0 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
}
.latest-spot-meta {
  color: var(--slate);
  font-size: 0.88rem;
  flex: 0 0 auto;
}
.latest-spot-species {
  color: var(--slate);
  font-size: 0.85rem;
  margin-left: auto;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: right;
}
@media (max-width: 640px) {
  .latest-spot-row { flex-wrap: wrap; white-space: normal; }
  .latest-spot-species { text-align: left; margin-left: 0; }
}

.leaflet-popup-content-wrapper { border-radius: 8px; }
.spot-popup h3 { margin: 0 0 6px; font-size: 1rem; }
.spot-popup p { margin: 2px 0; font-size: 0.85rem; }
.spot-popup a { color: var(--teal-mid); font-weight: 600; }
.species-pill {
  display: inline-block;
  background: #e7f3ef;
  color: var(--teal-deep);
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 0.75rem;
  margin: 2px 3px 0 0;
}

.spot-detail { padding: 32px 0 64px; }
.spot-detail h1 { color: var(--teal-deep); margin-bottom: 4px; }
.spot-meta { color: var(--slate); font-size: 0.95rem; margin-bottom: 20px; }
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-right: 8px;
}
.badge-free { background: #e7f3ef; color: var(--teal-deep); }
.badge-day-ticket { background: #fbf0e3; color: var(--amber); }
.badge-club { background: #eceded; color: var(--slate); }

.species-table { width: 100%; border-collapse: collapse; margin: 20px 0; }
.species-table th, .species-table td {
  text-align: left;
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
}
.species-table th { background: #f0eee7; }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 20px;
}

.rod-licence-note {
  background: #fff8e8;
  border: 1px solid #e9d9a8;
  border-radius: 8px;
  padding: 14px 16px;
  font-size: 0.9rem;
  margin: 20px 0;
}
.rod-licence-note a { color: var(--teal-mid); }

footer.site-footer {
  padding: 24px;
  text-align: center;
  color: var(--slate);
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
  margin-top: 40px;
}
footer.site-footer a { color: var(--slate); }

.back-link { display: inline-block; margin: 16px 0; color: var(--teal-mid); font-weight: 600; text-decoration: none; }

@media (max-width: 640px) {
  header.site-header { flex-direction: column; align-items: flex-start; gap: 8px; }
  nav.site-nav a { margin-left: 0; margin-right: 14px; }
}
