/* 07-timeline.css — Werdegang-Timeline (Sektion 2)
   Teil von css/living-canvas (aufgeteilt). Ladereihenfolge = Dateiname.
   Siehe docs/components/ fuer die Zuordnung Sektion -> Datei. */
/* 11. Journey / Scrollytelling (Sektion 2) */
section {
  padding: 70px clamp(24px, 6vw, 80px);
}
.wrap {
  max-width: 1120px;
  margin: 0 auto;
}
.timeline-carousel {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  padding: 0;
  align-items: end; /* Säulendiagramm-Anchor unten */
  max-width: 1580px;
  margin: 0 auto;
}
@media (max-width: 1100px) {
  .timeline-carousel {
    grid-template-columns: repeat(3, 1fr);
    align-items: stretch;
  }
}
@media (max-width: 600px) {
  .timeline-carousel {
    grid-template-columns: 1fr;
  }
  /* Auf dem Handy zuerst die aktuelle Station, dann rueckwaerts durch den
     Werdegang — Grid-Items respektieren `order` genau wie Flex-Items, das
     dreht die Lesereihenfolge, ohne Markup oder Desktop-Reihenfolge
     anzufassen. Reihenfolge im HTML bleibt chronologisch (item 1 = aeltest). */
  .tl-card:nth-child(1) { order: 5; } /* B.A. Zeitbasierte Medien */
  .tl-card:nth-child(2) { order: 4; } /* Media Designer */
  .tl-card:nth-child(3) { order: 3; } /* Media Manager */
  .tl-card:nth-child(4) { order: 2; } /* Online Employer Branding Manager */
  .tl-card:nth-child(5) { order: 1; } /* Weiterbildung Productdesigner UX/UI — Aktuell */
}

.stagger > .tl-card {
  opacity: 0;
  clip-path: inset(100% 0 0 0);
  transform: translateY(40px);
}

.tl-card {
  background: #fff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--teal);
  border-radius: 16px;
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  margin-bottom: 32px;
}
@media (min-width: 1101px) {
  .tl-card:nth-child(1) { height: 280px; }
  .tl-card:nth-child(2) { height: 320px; }
  .tl-card:nth-child(3) { height: 360px; }
  .tl-card:nth-child(4) { height: 400px; }
  .tl-card:nth-child(5) { height: 460px; }
}

/* Nur bei echtem Hover (Maus) anheben — auf Touch loest :hover sonst beim
   Antippen aus und bleibt haengen, die Karte "reagiert auf Beruehrung". */
@media (hover: hover) and (pointer: fine) {
  .tl-card:hover {
    transform: translateY(-8px) scale(1) !important;
    box-shadow: 0 16px 32px rgba(16, 43, 60, 0.05);
  }
}
.tl-date {
  font-size: 11px;
  font-weight: 800;
  color: var(--teal-d);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 16px;
}
.aktuell-badge {
  position: absolute;
  top: -12px;
  right: 24px;
  /* --apricot statt --apricot-d ergab bei 10px nur 2.32:1 (weit unter AA) —
     Barrierefreiheits-Audit, Stand 25.09.2026. */
  background: var(--apricot-d);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 10px;
  border-radius: var(--radius-chip);
  box-shadow: 0 4px 12px rgba(243, 155, 109, 0.4);
}
.tl-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.15;
  color: var(--ink);
  margin-bottom: 8px;
  hyphens: auto;
  -webkit-hyphens: auto;
}
.tl-desc {
  font-size: 13px;
  color: var(--grey);
  line-height: 1.4;
  hyphens: auto;
  -webkit-hyphens: auto;
}
.tl-skills {
  margin-top: auto;
  padding-top: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tl-skills span {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--teal-d);
  background: rgba(185, 216, 214, 0.25);
  padding: 4px 10px;
  border-radius: var(--radius-chip);
}

/* Lime Circle Decoration */
.lime-circle-outline {
  position: absolute;
  border: 24px solid var(--lime);
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
  animation: float-slow 15s ease-in-out infinite;
}

/* Kopfbereich der Sektion — vorher als Inline-Styles im HTML */
.tl-header-wrap {
  display: flex;
  gap: 40px;
  align-items: flex-end;
  margin-bottom: 64px;
  position: relative;
  z-index: 2;
}
.tl-header-main {
  flex: 1.2;
  position: relative;
}
.tl-header-aside {
  flex: 1;
  padding-bottom: 12px;
  color: var(--grey);
}
.tl-header-aside p {
  margin: 0;
  font-size: 1.05rem;
}

@media (max-width: 900px) {
  .tl-header-wrap {
    flex-direction: column;
    align-items: stretch;
    gap: 20px;
    margin-bottom: 40px;
  }
  .tl-header-aside {
    padding-bottom: 0;
  }
  .tl-header-aside p {
    font-size: 1rem;
  }
  /* Der Pfeil ist auf die Zeilenumbrueche der Desktop-Headline gerechnet */
  #timelineArrow {
    display: none;
  }
  .lime-circle-outline {
    display: none;
  }
}

@media (max-width: 600px) {
  .tl-card {
    margin-bottom: 16px;
  }
}
