:root {
  --grund: #f7f3ec;
  --karte: #fffdf9;
  --text: #2a2620;
  --leise: #6f665a;
  --linie: #e4dccf;
  --erde: #b4532a;      /* rote Erde */
  --gruen: #2f5d3a;     /* Regenwald */
  --gold: #d9a441;
  --schatten: 0 1px 3px rgba(60, 40, 20, .08), 0 6px 20px rgba(60, 40, 20, .06);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --grund: #1b1916;
    --karte: #24211d;
    --text: #ece6dc;
    --leise: #a89f92;
    --linie: #3a352e;
    --erde: #e07a4c;
    --gruen: #7fb48a;
    --gold: #e5b95c;
    --schatten: none;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--grund);
  color: var(--text);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
}
img { max-width: 100%; display: block; }

.kopf {
  background: linear-gradient(135deg, #2f5d3a, #1f3f28 70%);
  color: #fff;
  padding: 2.5rem 1rem 2rem;
}
.kopf-innen, main, .fuss { max-width: 760px; margin: 0 auto; }
.untertitel {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .78rem;
  color: var(--gold);
}
h1 {
  margin: .2rem 0 .1rem;
  font: 700 clamp(2.2rem, 8vw, 3.4rem)/1.05 Georgia, "Times New Roman", serif;
}
.zeitraum { margin: 0; opacity: .85; }
.zuletzt {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  margin: 1.2rem 0 0;
  padding: .45rem .9rem;
  background: rgba(255, 255, 255, .12);
  border-radius: 999px;
  font-size: .92rem;
}
.punkt {
  flex: none;
  width: .6rem; height: .6rem; border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 0 rgba(217, 164, 65, .7);
  animation: puls 2s infinite;
}
@keyframes puls { 70% { box-shadow: 0 0 0 .5rem rgba(217, 164, 65, 0); } 100% { box-shadow: 0 0 0 0 rgba(217, 164, 65, 0); } }
@media (prefers-reduced-motion: reduce) { .punkt { animation: none; } }

main { padding: 0 1rem; }
.karte-box { margin: -1rem 0 2rem; }
#karte {
  height: min(55vh, 420px);
  border-radius: 14px;
  box-shadow: var(--schatten);
  border: 1px solid var(--linie);
  z-index: 0;
}
.hinweis { margin: .4rem .2rem 0; font-size: .8rem; color: var(--leise); }

.leer, .tag {
  background: var(--karte);
  border: 1px solid var(--linie);
  border-radius: 14px;
  box-shadow: var(--schatten);
  padding: 1.2rem 1.2rem .6rem;
  margin-bottom: 1.4rem;
}
.leer { padding-bottom: 1.2rem; }
.leer h2 { margin-top: 0; font-family: Georgia, serif; }

.tag-kopf { border-bottom: 1px solid var(--linie); padding-bottom: .6rem; margin-bottom: .8rem; }
.tag-nummer {
  margin: 0;
  color: var(--erde);
  font-weight: 600;
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.tag-kopf h2 { margin: .15rem 0 0; font: 700 1.5rem/1.25 Georgia, serif; }

.eintrag { display: grid; grid-template-columns: 3.2rem 1fr; gap: .6rem; margin-bottom: 1rem; }
.uhrzeit { color: var(--leise); font-size: .85rem; padding-top: .15rem; font-variant-numeric: tabular-nums; }
.text { margin: 0; white-space: pre-line; overflow-wrap: anywhere; }
.foto img { border-radius: 10px; width: auto; max-width: 100%; max-height: 70vh; height: auto; cursor: zoom-in; }
.foto + .text { margin-top: .45rem; color: var(--leise); font-size: .95rem; }

.fuss { padding: 1rem; color: var(--leise); font-size: .8rem; text-align: center; }

#lightbox { border: 0; padding: 0; background: transparent; max-width: 96vw; max-height: 94vh; }
#lightbox::backdrop { background: rgba(10, 8, 5, .88); }
#lightbox img { max-width: 96vw; max-height: 94vh; border-radius: 6px; }
.schliessen {
  position: fixed; top: calc(.6rem + env(safe-area-inset-top)); right: .8rem;
  width: 2.6rem; height: 2.6rem; border: 0; border-radius: 50%;
  background: rgba(255, 255, 255, .9); font-size: 1.6rem; line-height: 1; cursor: pointer;
}

.leaflet-popup-content img { width: 200px; border-radius: 6px; }
.leaflet-popup-content p { margin: .3rem 0 0; }

@media (max-width: 480px) {
  body { font-size: 16px; }
  .eintrag { grid-template-columns: 1fr; gap: .2rem; }
}
