/* Saskia Weichenrieder – Familien-Blog
   Warmer, persönlicher Look, modern & responsive. */

:root {
  --sage: #819d56;          /* Grünton aus dem Original */
  --sage-dark: #5f7a3b;
  --ink: #44423d;
  --muted: #7c786f;
  --cream: #faf7f0;
  --card: #ffffff;
  --rose: #d8a7a0;
  --line: #e7e1d4;
  --shadow: 0 6px 24px rgba(80, 70, 50, .10);
  --radius: 16px;
  --serif: "Hoefler Text", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap { width: min(1040px, 92%); margin-inline: auto; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; color: var(--ink); }
a { color: var(--sage-dark); }

img { max-width: 100%; height: auto; display: block; }

/* ---------- Header / Navigation ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 247, 240, .92);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 64px; gap: 1rem;
}
.brand {
  font-family: var(--serif); font-size: 1.3rem; font-weight: 600;
  color: var(--sage-dark); text-decoration: none; letter-spacing: .2px;
}
.site-nav { display: flex; gap: 1.6rem; }
.site-nav a {
  text-decoration: none; color: var(--muted); font-size: 1rem;
  padding: .25rem 0; border-bottom: 2px solid transparent; transition: color .15s, border-color .15s;
}
.site-nav a:hover { color: var(--sage-dark); }
.site-nav a.active { color: var(--ink); border-bottom-color: var(--sage); }
.nav-toggle {
  display: none; background: none; border: 0; font-size: 1.6rem;
  color: var(--sage-dark); cursor: pointer; line-height: 1;
}

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(1200px 400px at 80% -10%, rgba(129,157,86,.16), transparent 60%),
    radial-gradient(900px 360px at 0% 10%, rgba(216,167,160,.16), transparent 55%);
  padding: clamp(2rem, 6vw, 5rem) 0;
}
.hero-inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .18em; font-size: .78rem; color: var(--sage-dark); margin: 0 0 .6rem; font-weight: 600; }
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); margin: 0 0 1rem; }
.lead { font-size: 1.08rem; color: #565248; margin: 0 0 1rem; }
.hero-actions { margin-top: 1.6rem; display: flex; gap: .8rem; flex-wrap: wrap; }
.btn {
  display: inline-block; background: var(--sage); color: #fff; text-decoration: none;
  padding: .7rem 1.4rem; border-radius: 999px; font-weight: 600; box-shadow: var(--shadow);
  transition: transform .12s, background .15s;
}
.btn:hover { background: var(--sage-dark); transform: translateY(-1px); }
.btn-ghost { background: #fff; color: var(--sage-dark); border: 1px solid var(--line); box-shadow: none; }
.btn-ghost:hover { background: #fff; border-color: var(--sage); }
.hero-media > img {
  border-radius: var(--radius); box-shadow: var(--shadow);
  border: 6px solid #fff; transform: rotate(-1.5deg);
}

/* Foto-Collage auf der Startseite */
.collage {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(.6rem, 1.2vw, 1rem);
}
.collage img {
  width: 100%; aspect-ratio: 1; object-fit: cover;
  border: 5px solid #fff; border-radius: 12px; box-shadow: var(--shadow);
}
.collage img:nth-child(1) { transform: rotate(-2deg); }
.collage img:nth-child(2) { transform: rotate(1.5deg); }
.collage img:nth-child(3) { transform: rotate(1.5deg); }
.collage img:nth-child(4) { transform: rotate(-2deg); }

/* Startseite: alles auf einen Bildschirm */
.page-home { display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
.page-home main { flex: 1 1 auto; display: flex; }
.page-home .hero { flex: 1 1 auto; display: flex; align-items: center; width: 100%; padding: clamp(1rem, 3vh, 2.5rem) 0; }
.page-home .hero h1 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: .8rem; }
.page-home .lead { font-size: clamp(.98rem, 1.1vw, 1.06rem); margin-bottom: .8rem; }
.page-home .hero-actions { margin-top: 1.2rem; }

.section { padding: clamp(1.5rem, 4vw, 3rem) 0; }
.welcome-photos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.welcome-photos img { width: 100%; border-radius: 12px; border: 5px solid #fff; box-shadow: var(--shadow); aspect-ratio: 4/3; object-fit: cover; }

/* ---------- Seitenkopf ---------- */
.page-head { padding: clamp(2rem, 5vw, 3.5rem) 0 .5rem; }
.page-head h1 { font-size: clamp(2rem, 4.5vw, 3rem); margin: 0 0 .6rem; }
.page-head .lead { max-width: 60ch; }

/* ---------- Tagebuch ---------- */
.entries { display: flex; flex-direction: column; gap: 1.6rem; padding-bottom: 3.5rem; padding-top: 1.5rem; }
.entry {
  display: grid; grid-template-columns: 300px 1fr; gap: 0;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
}
.entry-media { background: #f1ece0; }
.entry-media img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/3; }
.entry-body { padding: clamp(1.2rem, 3vw, 2rem); }
.entry-date { color: var(--sage-dark); font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; margin: 0 0 .35rem; font-weight: 600; }
.entry h2 { font-size: 1.5rem; margin: 0 0 .7rem; }
.entry p { margin: 0; color: #514d44; }
.entry:nth-child(even) { grid-template-columns: 1fr 300px; }
.entry:nth-child(even) .entry-media { order: 2; }
.entries .entry.no-image { grid-template-columns: 1fr; }

/* ---------- Galerie ---------- */
.gallery {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px; padding: 1.5rem 0 3.5rem;
}
.tile { display: block; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); background: #f1ece0; }
.tile img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: transform .25s; }
.tile:hover img { transform: scale(1.06); }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; background: rgba(40, 36, 28, .92);
  display: none; align-items: center; justify-content: center; z-index: 100;
}
.lightbox.open { display: flex; }
.lb-img { max-width: 90vw; max-height: 86vh; border-radius: 8px; box-shadow: 0 10px 50px rgba(0,0,0,.5); }
.lightbox button {
  position: absolute; background: rgba(255,255,255,.12); color: #fff; border: 0;
  width: 52px; height: 52px; border-radius: 50%; font-size: 1.8rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center; transition: background .15s;
}
.lightbox button:hover { background: rgba(255,255,255,.28); }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 18px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 18px; top: 50%; transform: translateY(-50%); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line); background: #f3eee2;
  padding: 2rem 0; margin-top: 2rem; text-align: center; color: var(--muted);
}
.site-footer p { margin: .2rem 0; font-size: .92rem; }

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-media { order: -1; max-width: 360px; }
  .entry, .entry:nth-child(even) { grid-template-columns: 1fr; }
  .entry:nth-child(even) .entry-media { order: 0; }
  .entry-media img { aspect-ratio: 16/9; }
}
@media (max-width: 640px) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; gap: 0; background: var(--cream);
    border-bottom: 1px solid var(--line); padding: .5rem 0;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: .8rem 7%; border-bottom: 1px solid var(--line); }
  .site-nav a.active { border-bottom-color: var(--line); }
  .welcome-photos { grid-template-columns: 1fr 1fr; }
}
