:root {
  --bg: #f7f4eb;
  --panel: #fffdf8;
  --green-deep: #245b3a;
  --green-soft: #5f8f5c;
  --gold: #e5b84c;
  --gold-soft: #f0d88d;
  --cream: #fff7e4;
  --earth: #8d6d4d;
  --text: #243126;
  --muted: #586c5d;
  --shadow: rgba(40, 55, 38, 0.12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: #ffffc2;
  color: var(--text);
  line-height: 1.6;
}

img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }

.container {
  width: min(1100px, calc(100% - 32px));
  margin: 0 auto;
}

.project-banner {
  background: var(--green-deep);
  color: rgba(255, 255, 255, 0.92);
  text-align: center;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 8px 0;
}

header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: #f7f1a7;
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(36, 91, 58, 0.12);
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 74px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--green-deep);
}

.brand-mark {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--gold), #f9e9a8);
  border-radius: 50%;
  color: var(--green-deep);
  font-size: 1.1rem;
}

.nav-links {
  display: flex;
  gap: 26px;
  align-items: center;
  color: var(--green-deep);
  font-weight: 600;
}

.nav-links a:hover {
  color: var(--green-soft);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.5rem;
  border-radius: 999px;
  border: none;
  font-weight: 700;
  transition: 0.2s ease;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(135deg, var(--gold), #edc65d);
  color: var(--text);
  box-shadow: 0 10px 20px rgba(229, 184, 76, 0.25);
}
.btn-primary:hover { transform: translateY(-1px); }

.btn-secondary {
  background: rgba(36, 91, 58, 0.08);
  color: var(--green-deep);
  border: 1px solid rgba(36, 91, 58, 0.14);
}
.btn-secondary:hover { background: rgba(36, 91, 58, 0.12); }

.hero {
  background: #fcfcb3;
  padding: 80px 0 60px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 28px;
  align-items: center;
}

.eyebrow {
  display: inline-block;
  padding: 0.35rem 0.8rem;
  background: rgba(36, 91, 58, 0.08);
  color: var(--green-deep);
  border-radius: 999px;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

h1, h2, h3 {
  margin: 0 0 0.6rem;
  line-height: 1.1;
  color: var(--green-deep);
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  letter-spacing: -0.05em;
}

.hero-copy p {
  font-size: 1.08rem;
  color: var(--muted);
  margin: 1rem 0 1.8rem;
  max-width: 560px;
}

.hero-actions {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(100px, 1fr));
  gap: 18px;
  max-width: 560px;
}

.stat {
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 18px;
  padding: 1rem;
  text-align: center;
}

.stat strong {
  display: block;
  font-size: 1.5rem;
  color: var(--green-deep);
}
.stat span {
  color: var(--muted);
  font-size: 0.82rem;
}

.hero-visual {
  position: relative;
}

.image-card {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 28px 50px var(--shadow);
}

.image-card img {
  width: 100%;
  height: 560px;
  object-fit: cover;
}

.badge {
  position: absolute;
  right: 18px;
  bottom: 18px;
  background: rgba(255,255,255,0.85);
  border: 1px solid rgba(36, 91, 58, 0.08);
  color: var(--green-deep);
  border-radius: 18px;
  padding: 0.9rem 1rem;
  box-shadow: 0 12px 30px rgba(36, 91, 58, 0.12);
  font-weight: 700;
}

section {
  padding: 86px 0;
}

.section-heading {
  text-align: center;
  margin-bottom: 42px;
}
.section-heading h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.04em;
}
.section-heading p {
  margin: 0 auto;
  max-width: 650px;
  color: var(--muted);
}

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

.card {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 22px;
  padding: 1.6rem;
  box-shadow: 0 12px 30px rgba(52, 63, 48, 0.06);
}

.card-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(229,184,76,0.2), rgba(95,143,92,0.2));
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

.card h3 {
  font-size: 1.45rem;
  margin-bottom: 0.7rem;
}

.card p {
  color: var(--muted);
  margin: 0;
}

.feature-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  align-items: center;
}

.feature-panel {
  background: linear-gradient(135deg, rgba(255,255,255,0.7), rgba(245,240,229,0.8));
  border-radius: 28px;
  border: 1px solid rgba(36, 91, 58, 0.08);
  padding: 2rem;
  box-shadow: 0 18px 34px rgba(52, 63, 48, 0.06);
}

.featurelist {
  list-style: none;
  padding: 0;
  margin: 25px 0 0;
  display: grid;
  gap: 14px;
}
.featurelist li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: var(--muted);
}
.featurelist li::before {
  content: "✦";
  font-size: 1rem;
  color: var(--gold);
  margin-top: 2px;
}

.feature-image img {
  border-radius: 28px;
  height: 100%;
  min-height: 440px;
  object-fit: cover;
  box-shadow: 0 28px 50px rgba(32, 50, 30, 0.12);
}

#garden-map,
#gardens-map {
  height: 420px;
  width: 100%;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(36, 91, 58, 0.08);
  box-shadow: 0 28px 50px rgba(32, 50, 30, 0.12);
}

#garden-map.map-large,
#gardens-map.map-large {
  height: 560px;
}

.map-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--green-deep);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
}

.toggle input {
  width: 18px;
  height: 18px;
  accent-color: var(--gold);
  cursor: pointer;
}

.feed-panel {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 28px;
  padding: 1.2rem;
  box-shadow: 0 18px 34px rgba(52, 63, 48, 0.06);
  display: grid;
  gap: 10px;
  max-height: 500px;
  overflow-y: auto;
}

.feed-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0.85rem 1rem;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(36, 91, 58, 0.06);
  border-radius: 16px;
}

.feed-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.feed-body {
  flex: 1;
  min-width: 0;
}

.feed-title {
  font-weight: 700;
  color: var(--green-deep);
}

.feed-meta {
  color: var(--muted);
  font-size: 0.85rem;
}

.feed-observer {
  color: var(--earth);
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
}

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

.hotspot-card {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 20px;
  padding: 1.4rem;
  box-shadow: 0 12px 30px rgba(52, 63, 48, 0.06);
}

.hotspot-card h3 {
  margin-bottom: 0.4rem;
}

.hotspot-stats {
  display: flex;
  gap: 24px;
  margin-top: 1rem;
}

.hotspot-stats strong {
  display: block;
  font-size: 1.3rem;
  color: var(--green-deep);
}

.hotspot-stats span {
  color: var(--muted);
  font-size: 0.8rem;
}

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

.garden-card {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(52, 63, 48, 0.06);
}

.garden-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.garden-card-body {
  padding: 1.2rem 1.4rem 1.4rem;
}

.garden-address {
  color: var(--earth);
  font-size: 0.85rem;
  font-weight: 600;
  margin: 0 0 0.6rem;
}

.garden-card-body > p:not(.garden-address):not(.garden-maintainer) {
  color: var(--muted);
}

.garden-plantings {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0.8rem 0;
}

.garden-maintainer {
  color: var(--muted);
  font-size: 0.8rem;
  font-style: italic;
  margin: 0;
}

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

.species-card {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 20px;
  padding: 1.2rem 1.4rem;
  box-shadow: 0 12px 30px rgba(52, 63, 48, 0.06);
}

.species-icon {
  font-size: 2rem;
  flex-shrink: 0;
}

.species-card h3 {
  margin-bottom: 0.15rem;
  font-size: 1.1rem;
}

.species-latin {
  margin: 0 0 0.4rem;
  color: var(--muted);
  font-style: italic;
  font-size: 0.85rem;
}

.species-tag {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  background: rgba(36, 91, 58, 0.08);
  color: var(--green-deep);
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.species-count {
  margin-left: auto;
  text-align: center;
  flex-shrink: 0;
}

.species-count strong {
  display: block;
  font-size: 1.3rem;
  color: var(--green-deep);
}

.species-count span {
  color: var(--muted);
  font-size: 0.75rem;
}

.gallery-preview {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.preview-item {
  background: rgba(255,255,255,0.7);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 22px;
  overflow: hidden;
}

.preview-item img {
  height: 260px;
  width: 100%;
  object-fit: cover;
}

.preview-item .caption {
  padding: 1rem 1rem 1.2rem;
}
.preview-item h3 {
  margin-bottom: 0.25rem;
  font-size: 1.2rem;
}
.preview-item p {
  margin: 0;
  color: var(--muted);
}

.callout {
  background: linear-gradient(135deg, #fffde0, #fdf8cd);
  border-radius: 30px;
  padding: 34px 32px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  box-shadow: 0 18px 34px rgba(52, 63, 48, 0.08);
}

.callout h3 {
  margin-bottom: 0.2rem;
}

footer {
  background: #234a38;
  color: rgba(255,255,255,0.8);
  padding: 26px 0;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.footer-credit {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.82rem;
}

.nav-auth {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-user {
  color: var(--green-deep);
  font-weight: 700;
  font-size: 0.9rem;
  white-space: nowrap;
}

.nav-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}

.google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 0.9rem 1.5rem;
  border-radius: 999px;
  background: var(--panel);
  border: 1px solid rgba(36, 91, 58, 0.18);
  color: var(--text);
  font-weight: 700;
  box-shadow: 0 12px 30px rgba(52, 63, 48, 0.08);
  transition: 0.2s ease;
}

.google-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 34px rgba(52, 63, 48, 0.12);
}

.auth-note {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  margin: 1.2rem 0 0;
}

#signout-btn {
  font-size: 0.85rem;
  padding: 0.65rem 1.1rem;
}

.auth-card {
  max-width: 460px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 28px;
  padding: 2rem;
  box-shadow: 0 18px 34px rgba(52, 63, 48, 0.08);
}

.auth-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 1.6rem;
  background: rgba(36, 91, 58, 0.06);
  border-radius: 999px;
  padding: 4px;
}

.auth-tab {
  flex: 1;
  border: none;
  background: transparent;
  padding: 0.7rem 1rem;
  border-radius: 999px;
  font-weight: 700;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.9rem;
}

.auth-tab.active {
  background: var(--panel);
  color: var(--green-deep);
  box-shadow: 0 6px 16px rgba(52, 63, 48, 0.1);
}

.auth-form {
  display: grid;
  gap: 16px;
}

.auth-form label {
  display: grid;
  gap: 6px;
  font-weight: 700;
  color: var(--green-deep);
  font-size: 0.9rem;
}

.auth-form input,
.auth-form select,
.auth-form textarea {
  font: inherit;
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  border: 1px solid rgba(36, 91, 58, 0.18);
  background: var(--panel);
  color: var(--text);
}

.auth-form textarea {
  resize: vertical;
}

.field-hint {
  font-weight: 400;
  color: var(--muted);
  font-size: 0.78rem;
}

.auth-form .btn {
  justify-self: start;
}

.form-error {
  color: #a4341f;
  background: rgba(164, 52, 31, 0.08);
  border: 1px solid rgba(164, 52, 31, 0.18);
  border-radius: 10px;
  padding: 0.6rem 0.9rem;
  font-size: 0.85rem;
  margin: 0;
}

.form-success {
  color: var(--green-deep);
  background: rgba(95, 143, 92, 0.12);
  border: 1px solid rgba(95, 143, 92, 0.24);
  border-radius: 10px;
  padding: 0.6rem 0.9rem;
  font-size: 0.85rem;
  margin: 0;
}

.muted-note {
  color: var(--muted);
  text-align: center;
  padding: 2rem 1rem;
}

.feed-notes {
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 4px;
  font-style: italic;
}

.page-hero {
  background: #f8f2a1;
  padding: 96px 0 60px;
  text-align: center;
}

.page-hero p {
  color: var(--muted);
  max-width: 700px;
  margin: 0 auto;
}

.story-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 28px;
  align-items: center;
}
.story-layout img {
  border-radius: 28px;
  height: 100%;
  min-height: 500px;
  object-fit: cover;
  box-shadow: 0 26px 50px rgba(32, 50, 30, 0.12);
}

.values {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}
.value-box {
  background: rgba(255,255,255,0.7);
  border: 1px solid rgba(36, 91, 58, 0.08);
  border-radius: 20px;
  padding: 1.4rem;
}
.value-box h3 {
  margin-bottom: 0.5rem;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.gallery-grid img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: 0 18px 30px rgba(32, 50, 30, 0.08);
}

.species-card {
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.species-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(52, 63, 48, 0.12);
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(36, 46, 30, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 100;
}
.modal-overlay[hidden] {
  display: none;
}

.modal-card {
  position: relative;
  width: min(520px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  background: var(--panel);
  border-radius: 26px;
  box-shadow: 0 30px 60px rgba(20, 30, 16, 0.35);
}

.modal-card img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: 26px 26px 0 0;
}

.modal-body {
  padding: 1.6rem 1.8rem 2rem;
}

.modal-body h2 {
  margin: 0.4rem 0 0.2rem;
}

.species-modal-links {
  margin-top: 0.8rem;
  font-size: 0.9rem;
}

.species-modal-links a {
  color: inherit;
  font-weight: 600;
  text-decoration: underline;
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  color: var(--green-deep);
  font-size: 1rem;
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: 0 8px 18px rgba(20, 30, 16, 0.25);
}
.modal-close:hover {
  background: #fff;
}

@media (max-width: 860px) {
  .hero-grid,
  .feature-split,
  .story-layout,
  .cards,
  .values,
  .gallery-grid,
  .gallery-preview,
  .hotspot-grid,
  .species-grid,
  .garden-grid {
    grid-template-columns: 1fr;
  }

  .nav-links {
    gap: 12px;
    font-size: 0.9rem;
  }

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

  .hero-stats {
    grid-template-columns: 1fr;
  }
}
.pledge-checks {
  border: 1px solid rgba(36, 91, 58, 0.18);
  border-radius: 16px;
  padding: 14px 16px 16px;
  margin: 6px 0 4px;
  display: grid;
  gap: 12px;
}

.pledge-checks legend {
  font-weight: bold;
  color: var(--green-deep);
  padding: 0 6px;
}

.check-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: normal;
  line-height: 1.5;
}

.check-row input[type="checkbox"] {
  margin-top: 4px;
  width: 18px;
  height: 18px;
  flex: none;
  accent-color: var(--green-deep);
}

/* ---- admin page ---- */
.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;
}

.admin-actions {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 14px;
}

.btn-small {
  padding: 6px 14px;
  font-size: 0.85rem;
}

.table-scroll {
  overflow-x: auto;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(36, 91, 58, 0.12);
  border-radius: 20px;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
}

.admin-table th,
.admin-table td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(36, 91, 58, 0.1);
  vertical-align: middle;
}

.admin-table th {
  color: var(--green-deep);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.admin-table tr:last-child td {
  border-bottom: none;
}

/* ---- "My Account" nav dropdown ---- */
.nav-menu {
  position: relative;
}

.nav-menu summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--green-deep);
  white-space: nowrap;
}

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

.nav-menu summary::after {
  content: "▾";
  font-size: 0.75em;
  transition: transform 0.15s ease;
}

.nav-menu[open] summary::after {
  transform: rotate(180deg);
}

.nav-menu summary:hover {
  color: var(--green-soft);
}

.nav-menu-panel {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  min-width: 180px;
  display: grid;
  background: var(--panel);
  border: 1px solid rgba(36, 91, 58, 0.14);
  border-radius: 16px;
  box-shadow: 0 14px 30px rgba(36, 46, 30, 0.14);
  padding: 8px;
  z-index: 30;
}

.nav-menu-panel a {
  padding: 9px 12px;
  border-radius: 10px;
  color: var(--green-deep);
  white-space: nowrap;
}

.nav-menu-panel a:hover {
  background: rgba(36, 91, 58, 0.08);
}

.nav-menu-panel a[aria-current="page"] {
  background: rgba(36, 91, 58, 0.12);
}
