:root {
  --bg: #faf8f4;
  --surface: #ffffff;
  --text: #333333;
  --muted: #6b6b6b;
  --line: #e4dfd6;
  --accent: #3f8789;
  --accent-soft: #72b1b3;
  --serif: "Hiragino Mincho ProN", "Yu Mincho", YuMincho, "Noto Serif JP", serif;
  --sans: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", YuGothic, "Noto Sans JP", Meiryo, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: 0.02em;
  overflow-wrap: anywhere;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main { flex: 1 0 auto; width: 100%; }

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

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

/* Kopf */
header.site {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  padding: 4px 16px 0;
  text-align: center;
}
header.site nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 4px;
}
header.site nav a {
  display: block;
  padding: 8px 12px 10px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  border-bottom: 2px solid transparent;
}
header.site nav a:hover { color: var(--text); }
header.site nav a[aria-current="page"] { color: var(--text); border-bottom-color: var(--accent-soft); }

/* Inhalt */
main {
  max-width: 800px;
  margin: 0 auto;
  padding: 32px 16px 48px;
}
h1 {
  font-family: var(--serif);
  font-weight: normal;
  font-size: 1.7rem;
  letter-spacing: 0.08em;
  margin: 0 0 28px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
h3 {
  font-family: var(--serif);
  font-weight: normal;
  font-size: 1.2rem;
  margin: 1.6em 0 0.6em;
}
p { margin: 0 0 0.35em; }
.sp { height: 1em; }
hr { border: 0; border-top: 1px solid var(--line); margin: 40px 0; }

figure { margin: 28px 0; }
figure img { margin: 0 auto; border-radius: 2px; }
figure a.zoom { display: block; cursor: zoom-in; }
figcaption { margin-top: 8px; font-size: 0.88rem; color: var(--muted); text-align: center; }

/* Startseite: Titelbild ueber die volle Breite wie im Original */
.hero { margin: 0; }
.hero a.zoom { display: block; }
.hero img { width: 100%; height: min(56vw, 80vh); min-height: 260px; object-fit: cover; object-position: center 55%; }
.hero-text { text-align: center; padding: 56px 16px 48px; border-bottom: 1px solid var(--line); background: var(--surface); }
.hero-text h1 { border: 0; padding: 0; margin: 0 0 20px; font-size: 2.2rem; }
.hero-text p { color: var(--muted); font-size: 0.9rem; }

/* Zweispaltig (Unterrichtsseite) */
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; margin: 8px 0 32px; }

/* Videos */
.video a.yt { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: #000; }
.video a.yt img { width: 100%; height: 100%; object-fit: cover; opacity: 0.9; }
.video a.yt::after {
  content: "";
  position: absolute;
  inset: 50% auto auto 50%;
  width: 68px;
  height: 48px;
  margin: -24px 0 0 -34px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.7) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 5v14l11-7z' fill='%23fff'/%3E%3C/svg%3E") center / 28px no-repeat;
  transition: background-color 0.2s;
}
.video a.yt:hover::after { background-color: #c00; }
.video iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; display: block; }
main.page-videos { max-width: 1040px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 28px; }
.page-videos > h1, .page-videos > .card { grid-column: 1 / -1; }
.page-videos figure { margin: 12px 0 24px; }

.card {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 16px;
  margin-bottom: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.9rem;
  line-height: 1.7;
}
.card:hover { color: var(--text); border-color: var(--accent-soft); }
.card img { width: 88px; height: 88px; border-radius: 50%; flex: none; }
.card small { color: var(--muted); }

/* Fuss */
footer.site {
  border-top: 1px solid var(--line);
  background: var(--surface);
  padding: 24px 16px;
  text-align: center;
  font-size: 0.85rem;
  color: var(--muted);
}

@media (max-width: 720px) {
  body { font-size: 15px; }
  header.site nav a { padding: 6px 8px 8px; font-size: 0.85rem; }
  main { padding-top: 24px; }
  h1 { font-size: 1.4rem; }
  .cols, .page-videos { grid-template-columns: 1fr; gap: 20px; }
  .hero img { height: 70vw; }
  .hero-text { padding: 36px 16px 32px; }
  .hero-text h1 { font-size: 1.5rem; }
}
