/* ==========================================================================
   FHG Timeline v1.0.0
   Design: Figma FHG_Website / Das Forsthaus - Timeline (Node 1168:2012)
   Vertikaler Zeitstrahl mit alternierenden Einträgen
   Colors: Dark Forest #0D2102
   Fonts: SangBleu Kingdom (Jahr, Titel), Poppins (Subtitle, Text)
   ========================================================================== */

/* --- Container --- */

.fhg-timeline {
	position: relative;
	width: 100%;
	color: #0D2102;
}

/* --- Titel --- */

.fhg-timeline__title {
	font-family: 'SangBleu Kingdom', serif;
	font-weight: 500;
	font-size: 60px;
	line-height: 60px;
	letter-spacing: -1.8px;
	text-align: center;
	color: inherit;
	margin: 0 0 80px;
}

.fhg-timeline__title em,
.fhg-timeline__title i {
	font-style: italic;
}

/* --- Wrapper (relative für Linie) --- */

.fhg-timeline__wrapper {
	position: relative;
}

/* --- Vertikale Mittellinie --- */

.fhg-timeline__line {
	position: absolute;
	top: 0;
	bottom: 0;
	left: 50%;
	width: 1px;
	background-color: #0D2102;
	transform: translateX(-0.5px);
}

/* --- Einträge --- */

.fhg-timeline__entries {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 200px;
}

/* --- Einzelner Eintrag --- */

.fhg-timeline__entry {
	display: grid;
	grid-template-columns: calc(50% - 92.5px) 25px calc(50% - 92.5px);
	gap: 0 80px;
	align-items: center;
}

/* --- Dot (Punkt auf der Linie) --- */

.fhg-timeline__dot {
	width: 25px;
	height: 25px;
	border-radius: 50%;
	background-color: #0D2102;
	flex-shrink: 0;
	justify-self: center;
	z-index: 1;
}

/* --- Content Block --- */

.fhg-timeline__content {
	display: flex;
	flex-direction: column;
	gap: 55px;
}

.fhg-timeline__content--right {
	text-align: right;
	align-items: flex-end;
}

.fhg-timeline__content--left {
	text-align: left;
	align-items: flex-start;
}

/* --- Jahreszahl --- */

.fhg-timeline__year {
	font-family: 'SangBleu Kingdom', serif;
	font-weight: 500;
	font-size: 60px;
	line-height: 60px;
	letter-spacing: -1.8px;
	display: block;
}

/* --- Text-Block (Subtitle + Description) --- */

.fhg-timeline__text {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.fhg-timeline__subtitle {
	font-family: 'Poppins', sans-serif;
	font-weight: 500;
	font-size: 26px;
	line-height: 30px;
	letter-spacing: -0.26px;
	color: inherit;
	margin: 0;
}

.fhg-timeline__desc {
	font-family: 'Poppins', sans-serif;
	font-weight: 400;
	font-size: 24px;
	line-height: 32px;
	letter-spacing: -0.24px;
	color: #000;
	margin: 0;
	max-width: 652px;
}

.fhg-timeline__content--right .fhg-timeline__desc {
	margin-left: auto;
}

/* --- Bild --- */

.fhg-timeline__media {
	display: flex;
	align-items: center;
}

.fhg-timeline__entry--text-left .fhg-timeline__media {
	justify-content: flex-start;
}

.fhg-timeline__entry--text-right .fhg-timeline__media {
	justify-content: flex-end;
}

.fhg-timeline__image {
	position: relative;
	border-radius: 20px;
	overflow: hidden;
}

.fhg-timeline__image--landscape {
	width: 637px;
	height: 461px;
}

.fhg-timeline__image--portrait {
	width: 460px;
	height: 575px;
}

.fhg-timeline__image img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100% !important;
	max-width: none;
	object-fit: cover;
	object-position: center;
}

/* ==========================================================================
   Scroll Animations
   ========================================================================== */

.fhg-timeline__entry.fhg-scroll-ready {
	opacity: 0;
	transform: translateY(40px);
	transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fhg-timeline__entry.fhg-scroll-ready.fhg-visible {
	opacity: 1;
	transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
	.fhg-timeline__entry.fhg-scroll-ready {
		opacity: 1;
		transform: none;
		transition: none;
	}
}

/* ==========================================================================
   Tablet
   ========================================================================== */

@media (max-width: 1024px) {
	.fhg-timeline__entry {
		grid-template-columns: calc(50% - 92.5px) 25px calc(50% - 92.5px);
		gap: 0 40px;
	}

	.fhg-timeline__year {
		font-size: 42px;
		line-height: 42px;
	}

	.fhg-timeline__subtitle {
		font-size: 20px;
		line-height: 26px;
	}

	.fhg-timeline__desc {
		font-size: 18px;
		line-height: 26px;
	}

	.fhg-timeline__image--landscape {
		width: 100%;
		height: auto;
		aspect-ratio: 637 / 461;
	}

	.fhg-timeline__image--portrait {
		width: 100%;
		height: auto;
		aspect-ratio: 460 / 575;
	}

	.fhg-timeline__entries {
		gap: 120px !important;
	}
}

/* ==========================================================================
   Mobile
   ========================================================================== */

@media (max-width: 767px) {
	.fhg-timeline__title {
		font-size: 42px;
		line-height: 42px;
		letter-spacing: -1.2px;
		margin-bottom: 50px;
		text-align: left;
	}

	/* Einspaltiges Layout: Linie links */
	.fhg-timeline__line {
		left: 12px;
	}

	.fhg-timeline__entry {
		grid-template-columns: 25px 1fr;
		gap: 0 20px;
	}

	/* Dot immer in Spalte 1, vertikal mittig zur Jahreszahl
	   Year-Mobile: line-height 36px, Dot: 25px → (36-25)/2 = 5.5px */
	.fhg-timeline__dot {
		grid-column: 1;
		grid-row: 1;
		align-self: start;
		margin-top: 6px;
	}

	/* Content immer in Spalte 2 */
	.fhg-timeline__content {
		grid-column: 2;
		grid-row: 1;
		text-align: left !important;
		align-items: flex-start !important;
		gap: 30px;
	}

	.fhg-timeline__content--right .fhg-timeline__desc {
		margin-left: 0;
	}

	/* Media unter dem Content */
	.fhg-timeline__media {
		grid-column: 2;
		grid-row: 2;
		margin-top: 20px;
		justify-content: flex-start !important;
	}

	.fhg-timeline__image--landscape,
	.fhg-timeline__image--portrait {
		width: 100%;
		height: auto;
	}

	.fhg-timeline__image--landscape {
		aspect-ratio: 637 / 461;
	}

	.fhg-timeline__image--portrait {
		aspect-ratio: 460 / 575;
		max-width: 280px;
	}

	.fhg-timeline__year {
		font-size: 36px;
		line-height: 36px;
		letter-spacing: -1px;
	}

	.fhg-timeline__subtitle {
		font-size: 18px;
		line-height: 24px;
	}

	.fhg-timeline__desc {
		font-size: 18px;
		line-height: 26px;
		max-width: 100%;
	}

	.fhg-timeline__entries {
		gap: 80px !important;
	}
}
