/* ============================================================
   BrotZeit – Timeline-Entwürfe (Arbeitsversion, nur localhost)
   Nutzt Tokens/Fonts aus styles.css (Fraunces + Work Sans,
   --brown-*, --gold-400, --sand-200, --cream-*, --paper).
   3 Varianten: v1 Editorial · v2 Reise · v3 Scrollytelling
   ============================================================ */

/* ---------- gemeinsamer Kopf / Umschalter ---------- */
.tl-top {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 20px;
  justify-content: space-between;
  padding: 12px 24px;
  background: rgba(245, 240, 232, 0.86);
  backdrop-filter: saturate(1.2) blur(10px);
  border-bottom: 1px solid var(--sand-200);
}
.tl-top__brand img { height: 34px; width: auto; }
.tl-switch {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  font-size: 0.85rem;
}
.tl-switch__label { color: var(--brown-500); margin-right: 4px; font-weight: 600; }
.tl-switch a {
  text-decoration: none;
  color: var(--brown-700);
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s;
}
.tl-switch a:hover { background: var(--sand-200); }
.tl-switch a.is-active {
  background: var(--brown-700);
  color: #fff;
  font-weight: 600;
}
.tl-top__home { text-decoration: none; color: var(--brown-500); font-size: 0.85rem; white-space: nowrap; }
.tl-top__home:hover { color: var(--brown-900); }

/* Kopf auf schmalen Screens: Marke + Startseite oben, Umschalter als
   horizontale Scroll-Leiste darunter (statt vieler gestapelter Zeilen) */
@media (max-width: 720px) {
  .tl-top { flex-wrap: wrap; gap: 8px 12px; padding: 10px 14px; }
  .tl-switch {
    order: 3;
    width: 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
  }
  .tl-switch::-webkit-scrollbar { display: none; }
  .tl-switch__label { display: none; }
}

/* ---------- gemeinsamer Intro-Block ---------- */
.tl-hero {
  max-width: 820px;
  margin: 0 auto;
  padding: 64px 24px 20px;
  text-align: center;
}
.tl-hero__eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--gold-400);
  margin: 0 0 14px;
}
.tl-hero h1 {
  font-family: var(--serif);
  font-size: clamp(2rem, 5vw, 3.2rem);
  margin: 0 0 14px;
  color: var(--brown-900);
}
.tl-hero p {
  font-size: 1.05rem;
  color: var(--brown-700);
  margin: 0 auto;
  max-width: 60ch;
}
.tl-variant-note {
  display: inline-block;
  margin-top: 18px;
  font-size: 0.8rem;
  color: var(--brown-500);
  background: var(--cream-100);
  border: 1px solid var(--sand-200);
  padding: 6px 14px;
  border-radius: 999px;
}

.tl-foot {
  text-align: center;
  padding: 48px 24px 72px;
  color: var(--brown-500);
  font-size: 0.85rem;
}
.tl-foot a { color: var(--brown-700); }

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
}

/* ============================================================
   VARIANTE 5 — VERTIKALER ZEITSTRAHL (oben -> unten)
   Übersicht: Datum + Schlagwort je Meilenstein.
   Klick/Tipp öffnet die Detail-Kachel (Bild + Text) — Desktop & Handy gleich.
   ============================================================ */
.v5 { max-width: 680px; margin: 0 auto; padding: 24px 24px 52px; }
.v5-list { list-style: none; margin: 0; padding: 0; position: relative; }
.v5-item { position: relative; padding-left: 34px; }
/* durchgehende vertikale Linie */
.v5-item::before {
  content: "";
  position: absolute;
  left: 7px; top: 0; bottom: 0;
  width: 2px;
  background: var(--sand-200);
}
.v5-item:first-child::before { top: 20px; }
.v5-item:last-child::before { bottom: auto; height: 20px; }
/* Punkt auf der Linie */
.v5-dot {
  position: absolute;
  left: 0; top: 15px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--paper);
  border: 2px solid var(--sand-200);
  z-index: 1;
  transition: background 0.2s, border-color 0.2s, transform 0.2s;
}
.v5-head:hover .v5-dot,
.v5-item.is-open .v5-dot { border-color: var(--gold-400); background: var(--gold-400); transform: scale(1.15); }

/* Kopfzeile: Datum + Schlagwort (Übersicht) */
.v5-head {
  display: flex;
  align-items: baseline;
  gap: 16px;
  width: 100%;
  background: none;
  border: 0;
  cursor: pointer;
  font: inherit;
  text-align: left;
  padding: 12px 10px;
  border-radius: 10px;
  transition: background 0.15s;
}
.v5-head:hover { background: var(--cream-100); }
.v5-date { font-size: 0.8rem; font-weight: 700; color: var(--gold-400); min-width: 92px; white-space: nowrap; }
.v5-label { font-family: var(--serif); font-size: 1.3rem; color: var(--brown-900); flex: 1; line-height: 1.2; }
.v5-plus { color: var(--brown-500); font-size: 1.25rem; line-height: 1; transition: transform 0.25s; }
.v5-item.is-open .v5-plus { transform: rotate(45deg); }

/* Detail-Kachel (klappt bei Klick auf) */
.v5-card { max-height: 0; overflow: hidden; transition: max-height 0.4s ease; }
.v5-item.is-open .v5-card { max-height: 1300px; }
.v5-card__inner {
  margin: 4px 10px 20px;
  background: var(--paper);
  border: 1px solid rgba(233, 221, 202, 0.7);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.v5-card__inner img { width: 100%; aspect-ratio: 16/10; object-fit: cover; display: block; }
/* Poster/Hochformat: in voller Höhe zeigen, nicht beschneiden */
.v5-card__inner img.v5-poster { aspect-ratio: auto; object-fit: contain; background: var(--cream-100); }
.v5-card__body { padding: 16px 20px 20px; }

/* Video-Kacheln: klickbarer Play-Button (überdeckt eingebrannte IG-Buttons) */
.v5-thumb { position: relative; display: block; line-height: 0; }
.v5-thumb--video::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 24%;
  aspect-ratio: 1;
  border-radius: 50%;
  background-color: rgba(20, 14, 8, 0.55);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffffff'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 55% center;
  background-size: 44%;
  pointer-events: none;
}

.v5-thumb--read {
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  width: 100%;
}
.v5-thumb--read::after {
  content: "";
  position: absolute;
  top: 53%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 15%;
  aspect-ratio: 1;
  border-radius: 50%;
  background-color: rgba(20, 14, 8, 0.55);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 60%;
  pointer-events: none;
}

/* Willkommens-Kachel: Heidis Foto + Logo-Siegel + Text daneben */
.v5-welcome { display: grid; grid-template-columns: 0.82fr 1.18fr; align-items: stretch; }
.v5-welcome__photo { position: relative; background: var(--sand-200); min-height: 320px; }
.v5-welcome__photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 28%; aspect-ratio: auto; }
.v5-welcome__logo {
  position: absolute;
  bottom: 16px; right: 16px;
  width: 128px; height: 128px;
  border-radius: 50%;
  background: var(--paper);
  box-shadow: 0 6px 18px rgba(58, 44, 28, 0.22);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  z-index: 2;
}
.v5-welcome__logo img { width: 106px; height: 106px; object-fit: contain; aspect-ratio: auto; }
.v5-welcome__body { padding: 30px 34px; display: flex; flex-direction: column; justify-content: center; }
.v5-welcome__eyebrow { text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.72rem; font-weight: 700; color: var(--gold-400); margin: 0 0 10px; }
.v5-welcome__body h3 { font-family: var(--serif); font-size: 1.75rem; margin: 0 0 14px; }
.v5-welcome__body p { margin: 0 0 16px; color: var(--brown-700); font-size: 0.98rem; }
.v5-welcome__sign { font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--brown-900); }

@media (max-width: 640px) {
  .v5-welcome { grid-template-columns: 1fr; }
  .v5-welcome__photo { min-height: 260px; }
  .v5-welcome__logo { width: 104px; height: 104px; }
  .v5-welcome__logo img { width: 86px; height: 86px; }
  .v5-welcome__body { padding: 22px 22px 24px; }
  .v5-welcome__body h3 { font-size: 1.45rem; }
}
.v5-card__body h3 { margin: 0 0 8px; font-size: 1.2rem; }
.v5-card__body p { margin: 0; color: var(--brown-700); font-size: 0.94rem; }
.v5-card__body p + .v5-schedule { margin-top: 14px; }
.v5-schedule { margin: 0; padding: 0; }
.v5-schedule > div {
  display: flex;
  gap: 14px;
  padding: 7px 0;
  border-top: 1px solid var(--sand-200);
}
.v5-schedule > div:first-child { border-top: none; }
.v5-schedule dt {
  flex: 0 0 44px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--brown-900);
  font-size: 0.9rem;
}
.v5-schedule dd {
  margin: 0;
  color: var(--brown-700);
  font-size: 0.9rem;
}
.v5-card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--brown-700);
  text-decoration: none;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: inherit;
}
.v5-card__link:hover { color: var(--brown-900); text-decoration: underline; }

@media (max-width: 720px) {
  .v5-head { gap: 12px; padding: 12px 6px; }
  .v5-date { min-width: 82px; font-size: 0.74rem; }
  .v5-label { font-size: 1.12rem; }
}
