/* ==========================================================================
   Timeline Wave v1.2.0 — front-end styles
   ========================================================================== */

.tlw-timeline {
	--tlw-navy:      #1b2a6b;
	--tlw-navy-dark: #14215a;
	--tlw-tan:       #c79760;
	--tlw-tan-light: #d9ad7c;
	--tlw-text:      #3a3a3a;
	--tlw-text-light:#5a5a5a;

	position: relative;
	background: transparent;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	border-top: 6px solid var(--tlw-tan);
}

.tlw-timeline * {
	box-sizing: border-box;
}

/* ── Inner wrapper ───────────────────────────────────────────────────────── */

.tlw-inner {
	position: relative;
	max-width: 1100px;
	margin: 0 auto;
	padding: 30px 0 60px;
}

.tlw-title {
	text-align: center;
	color: var(--tlw-navy);
	font-size: 2.4rem;
	font-weight: 800;
	letter-spacing: 0.04em;
	margin: 0 0 10px;
	text-transform: uppercase;
}

/* ── Stage wrapper: positions both the scroll strip and the overlay ──────── */

.tlw-stage-wrap {
	position: relative;
	/* No fixed height — stage-wrap grows to hold the wave height.
	   The overlay is absolute so it doesn't add height. */
	overflow: visible;
}

/* ── Stage: normal block, sets the wave height, scrolls horizontally ─────── */

.tlw-stage {
	position: relative;
	height: 360px;
	overflow-x: hidden; /* JS sets scrollLeft */
	overflow-y: visible;
}

.tlw-wave-scroll {
	position: absolute;
	top: 0;
	left: 0;
	/* width & height set by JS to match the full SVG canvas */
}

.tlw-path-svg {
	display: block;
	overflow: visible;
}

.tlw-path {
	stroke: var(--tlw-navy);
	stroke-width: 4;
	fill: none;
}

/* ── Overlay: photo + arrows, sits on top of stage, never scrolls ────────── */

.tlw-overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 360px;   /* matches .tlw-stage height */
	overflow: visible;
	pointer-events: none;
	z-index: 10;
}

/* Re-enable pointer events only on the interactive children */
.tlw-overlay .tlw-arrow,
.tlw-overlay .tlw-photo-wrap {
	pointer-events: auto;
}

/* ── Circular photo ──────────────────────────────────────────────────────── */

.tlw-photo-wrap {
	position: absolute;
	top: 10px;
	left: 50%;
	transform: translateX(-50%);
	width: 240px;
	height: 240px;
	border-radius: 50% !important;
	overflow: hidden;
	background: #ccc;
	border: 7px solid #ffffff;
	box-shadow: 0 6px 24px rgba(0,0,0,0.22);
	pointer-events: none;
}

.tlw-timeline .tlw-photo-wrap img.tlw-photo,
.tlw-timeline img.tlw-photo {
	display: block !important;
	width: 100% !important;
	max-width: 100% !important;
	height: 100% !important;
	max-height: none !important;
	object-fit: cover !important;
	object-position: center center; /* overridden per-event via JS */
	border: none !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	margin: 0 !important;
	padding: 0 !important;
	transition: opacity 0.22s ease;
}

.tlw-timeline img.tlw-photo.tlw-fading {
	opacity: 0;
}

/* ── Navigation arrows ───────────────────────────────────────────────────── */

.tlw-timeline .tlw-arrow {
	position: absolute !important;
	top: 115px !important;
	width: 44px !important;
	height: 44px !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	background: transparent !important;
	background-color: transparent !important;
	background-image: none !important;
	border: none !important;
	border-radius: 50% !important;
	box-shadow: none !important;
	padding: 0 !important;
	cursor: pointer !important;
	color: var(--tlw-navy) !important;
	font-size: 2.4rem !important;
	line-height: 1 !important;
	transition: opacity 0.2s ease, transform 0.15s ease;
}

.tlw-timeline .tlw-arrow span {
	color: var(--tlw-navy) !important;
	font-size: 2.4rem !important;
	line-height: 1 !important;
	display: block;
}

.tlw-timeline .tlw-arrow:hover {
	background: transparent !important;
	opacity: 0.7;
	transform: scale(1.15);
}

.tlw-timeline .tlw-arrow:focus-visible {
	outline: 2px solid var(--tlw-navy) !important;
	outline-offset: 3px;
}

.tlw-timeline .tlw-arrow-prev {
	left: calc(50% - 200px) !important;
}

.tlw-timeline .tlw-arrow-next {
	left: calc(50% + 160px) !important;
}

.tlw-timeline .tlw-arrow[disabled] {
	opacity: 0.25 !important;
	cursor: default !important;
}


/* ── Active year label (centered below the stage, in document flow) ──────── */

.tlw-active-year-wrap {
	display: none !important;
}

/* ── Dots (live inside .tlw-wave-scroll, scroll with wave) ─── */

.tlw-dots-layer {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	pointer-events: none;
}

.tlw-timeline .tlw-dot {
	position: absolute !important;
	width: 18px !important;
	height: 18px !important;
	border-radius: 50% !important;
	background: var(--tlw-navy) !important;
	background-color: var(--tlw-navy) !important;
	background-image: none !important;
	border: none !important;
	box-shadow: none !important;
	padding: 0 !important;
	transform: translate(-50%, -50%) !important;
	cursor: pointer;
	pointer-events: auto;
	transition: transform 0.15s ease;
}

.tlw-timeline .tlw-dot:hover {
	transform: translate(-50%, -50%) scale(1.3) !important;
}

.tlw-timeline .tlw-dot:focus-visible {
	outline: 2px solid var(--tlw-tan) !important;
	outline-offset: 3px;
}

.tlw-timeline .tlw-dot.is-active {
	visibility: hidden !important; /* marker sits on top of active dot */
}

.tlw-year-label {
	position: absolute;
	transform: translateX(-50%);
	font-weight: 700;
	font-size: 1.1rem;
	color: var(--tlw-text-light);
	white-space: nowrap;
	pointer-events: none;
	transition: color 0.2s ease;
}

.tlw-year-label.is-active {
	color: var(--tlw-navy);
}

/* ── The tan-halo marker that travels along the path ─────────────────────── */

.tlw-marker {
	position: absolute;
	width: 58px;
	height: 58px;
	transform: translate(-50%, -50%);
	z-index: 6;
	pointer-events: none;
}

.tlw-marker-halo {
	position: absolute;
	inset: 0;
	border-radius: 50%;
	background: var(--tlw-tan);
}

.tlw-marker-dot {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: var(--tlw-navy);
	transform: translate(-50%, -50%);
}

/* ── Content below the timeline ─────────────────────────────────────────── */

.tlw-content {
	max-width: 800px;
	margin: 0 auto;
	padding: 0 24px;
	text-align: left;
}

.tlw-timeline .tlw-content-heading {
	text-align: center !important;
	color: var(--tlw-navy) !important;
	font-size: 1.8rem !important;
	font-weight: 800 !important;
	margin: 0 0 18px !important;
	padding: 0 !important;
	display: block !important;
	visibility: visible !important;
	transition: opacity 0.22s ease;
}

.tlw-content-body {
	color: var(--tlw-text-light);
	font-size: 1rem;
	line-height: 1.65;
	transition: opacity 0.22s ease;
}

.tlw-content-body p {
	margin: 0 0 16px;
}

.tlw-content.tlw-fading .tlw-content-heading,
.tlw-content.tlw-fading .tlw-content-body {
	opacity: 0;
}

/* ── Responsive ─────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
	.tlw-title {
		font-size: 1.8rem;
	}

	.tlw-stage {
		height: 310px;
	}

	.tlw-overlay {
		height: 310px;
	}

	.tlw-photo-wrap {
		width: 180px;
		height: 180px;
	}

	.tlw-timeline .tlw-arrow {
		top: 90px !important;
		width: 38px !important;
		height: 38px !important;
		font-size: 2rem !important;
	}

	.tlw-timeline .tlw-arrow span {
		font-size: 2rem !important;
	}

	.tlw-timeline .tlw-arrow-prev {
		left: calc(50% - 155px) !important;
	}

	.tlw-timeline .tlw-arrow-next {
		left: calc(50% + 120px) !important;
	}

	.tlw-marker {
		width: 46px;
		height: 46px;
	}

	.tlw-marker-dot {
		width: 18px;
		height: 18px;
	}

	.tlw-content-heading {
		font-size: 1.4rem;
	}
}

@media (max-width: 480px) {
	.tlw-stage {
		height: 270px;
	}

	.tlw-overlay {
		height: 270px;
	}

	.tlw-photo-wrap {
		width: 140px;
		height: 140px;
	}

	.tlw-timeline .tlw-arrow {
		top: 68px !important;
	}

	.tlw-timeline .tlw-arrow-prev {
		left: calc(50% - 118px) !important;
	}

	.tlw-timeline .tlw-arrow-next {
		left: calc(50% + 82px) !important;
	}
}
