.timeline-krabb {
	position: relative;
	padding: 20px 0;
	max-width: 1000px;
	margin: 0 auto;
}

.timeline-krabb__line {
	position: absolute;
	top: 0;
	bottom: 0;
	left: 50%;
	transform: translateX(-50%);
	border-left-width: 2px;
	border-left-style: solid;
	border-left-color: #E0E0E0;
}

/* --- Item row --- */
.timeline-krabb__item {
	position: relative;
	display: flex;
	align-items: flex-start;
	margin-bottom: 40px;
	width: 100%;
}

.timeline-krabb__item:last-child {
	margin-bottom: 0;
}

/* --- Center column: dot --- */
.timeline-krabb__center {
	position: absolute;
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 2;
	top: 0;
}

.timeline-krabb__dot {
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background-color: #4054B2;
	flex-shrink: 0;
}

/* --- Date label --- */
.timeline-krabb__date {
	position: absolute;
	top: 0;
	white-space: nowrap;
	font-size: 18px;
	font-weight: 700;
	color: #1d2327;
}

/* --- Card --- */
.timeline-krabb__card {
	position: relative;
	width: calc(50% - 50px);
	background-color: #FFFFFF;
	border-radius: 8px;
	padding: 20px;
	box-sizing: border-box;
}

/* Arrow on card */
.timeline-krabb__card::before {
	content: '';
	position: absolute;
	top: 8px;
	width: 0;
	height: 0;
	border-style: solid;
}

/* --- RIGHT side item (odd: 1st, 3rd, 5th) --- card on right, date on left --- */
.timeline-krabb__item--right .timeline-krabb__card {
	margin-left: auto;
	margin-right: 0;
}

.timeline-krabb__item--right .timeline-krabb__card::before {
	left: -10px;
	border-width: 10px 10px 10px 0;
	border-color: transparent;
	border-right-color: inherit;
}

.timeline-krabb__item--right .timeline-krabb__date {
	right: calc(50% + 30px);
	text-align: right;
}

/* --- LEFT side item (even: 2nd, 4th, 6th) --- card on left, date on right --- */
.timeline-krabb__item--left .timeline-krabb__card {
	margin-left: 0;
	margin-right: auto;
}

.timeline-krabb__item--left .timeline-krabb__card::before {
	right: -10px;
	border-width: 10px 0 10px 10px;
	border-color: transparent;
	border-left-color: inherit;
}

.timeline-krabb__item--left .timeline-krabb__date {
	left: calc(50% + 30px);
	text-align: left;
}

/* Arrow inherits card background color */
.timeline-krabb__card::before {
	border-right-color: var(--tkrabb-card-bg, #FFFFFF);
	border-left-color: var(--tkrabb-card-bg, #FFFFFF);
}

.timeline-krabb__item--right .timeline-krabb__card::before {
	border-color: transparent;
	border-right-color: var(--tkrabb-card-bg, #FFFFFF);
}

.timeline-krabb__item--left .timeline-krabb__card::before {
	border-color: transparent;
	border-left-color: var(--tkrabb-card-bg, #FFFFFF);
}

/* --- Card content --- */
.timeline-krabb__title {
	margin: 0 0 6px 0;
	padding: 0;
	font-size: 18px;
	font-weight: 600;
	color: #1d2327;
	line-height: 1.3;
}

.timeline-krabb__initial-text {
	color: #50575e;
	line-height: 1.6;
}

.timeline-krabb__initial-text p:first-child {
	margin-top: 0;
}

.timeline-krabb__initial-text p:last-child {
	margin-bottom: 0;
}

.timeline-krabb__extra {
	max-height: 0;
	overflow: hidden;
	transition: max-height 0.4s ease, opacity 0.3s ease;
	opacity: 0;
	color: #50575e;
	line-height: 1.6;
}

.timeline-krabb__extra.is-open {
	opacity: 1;
}

.timeline-krabb__extra p:first-child {
	margin-top: 10px;
}

.timeline-krabb__extra p:last-child {
	margin-bottom: 0;
}

.timeline-krabb__toggle {
	display: inline-block;
	margin-top: 10px;
	padding: 0;
	border: none;
	background: none;
	color: #4054B2;
	cursor: pointer;
	font-size: 14px;
	font-weight: 500;
	transition: color 0.2s;
}

.timeline-krabb__toggle:hover {
	color: #2d3a8c;
}

.timeline-krabb--empty {
	text-align: center;
	padding: 40px 20px;
	color: #646970;
	font-style: italic;
}

/* --- Responsive: all items right-side on mobile --- */
@media (max-width: 767px) {
	.timeline-krabb__line {
		left: 20px;
		transform: none;
	}

	.timeline-krabb__item {
		flex-wrap: wrap;
	}

	/* Date sits above card, full width, offset to align with card */
	.timeline-krabb__item--right .timeline-krabb__date,
	.timeline-krabb__item--left .timeline-krabb__date {
		position: relative;
		left: auto;
		right: auto;
		text-align: left;
		width: 100%;
		padding-left: 50px;
		margin-bottom: 8px;
		order: -1;
	}

	/* Dot stays left, vertically aligned with card top */
	.timeline-krabb__center {
		position: relative;
		left: auto;
		transform: none;
		flex-shrink: 0;
		width: 40px;
		display: flex;
		align-items: flex-start;
		justify-content: center;
		top: auto;
		padding-top: 4px;
	}

	/* Card takes remaining space on the right */
	.timeline-krabb__item--right .timeline-krabb__card,
	.timeline-krabb__item--left .timeline-krabb__card {
		width: auto;
		flex: 1;
		min-width: 0;
		margin-left: 10px;
		margin-right: 0;
	}

	/* Arrow always points left toward the dot */
	.timeline-krabb__item--right .timeline-krabb__card::before,
	.timeline-krabb__item--left .timeline-krabb__card::before {
		left: -10px;
		right: auto;
		border-width: 10px 10px 10px 0;
		border-color: transparent;
		border-right-color: var(--tkrabb-card-bg, #FFFFFF);
	}
}
