/* Elementor Tidslinje Widget */

.hb-timeline {
	--hb-connector-h: 50px;
	position: relative;
	width: 100%;
	padding: 20px 0;
	box-sizing: border-box;
}

.hb-timeline-row {
	display: grid;
	grid-template-rows: auto var(--hb-connector-h) auto;
	column-gap: 20px;
	position: relative;
}

/* Horisontell huvudlinje - ligger i mittraden och centreras vertikalt automatiskt */
.hb-timeline-track {
	grid-row: 2;
	align-self: center;
	justify-self: stretch;
	height: 2px;
	background-color: #1a1a1a;
	width: 100%;
}

/* Innehåll (rubrik + beskrivning) */
.hb-item-content {
	padding: 0 15px;
	box-sizing: border-box;
	text-align: left;
}

.hb-item-content.hb-pos-top {
	align-self: end; /* ligger an mot kopplingslinjen underifrån */
}

.hb-item-content.hb-pos-bottom {
	align-self: start; /* ligger an mot kopplingslinjen ovanifrån */
}

.hb-item-title {
	font-family: Georgia, 'Times New Roman', serif;
	font-size: 22px;
	line-height: 1.3;
	color: #1a1a1a;
	margin: 0 0 8px 0;
}

.hb-item-desc {
	font-size: 14px;
	line-height: 1.5;
	color: #555555;
	margin: 0;
}

/* Vertikala kopplingslinjer mellan huvudlinjen och varje steg */
.hb-item-connector {
	justify-self: center;
	width: 2px;
	background-color: #1a1a1a;
}

.hb-item-connector.hb-pos-top {
	grid-row: 2;
	align-self: start;
	height: 50%;
}

.hb-item-connector.hb-pos-bottom {
	grid-row: 2;
	align-self: end;
	height: 50%;
}

/* ---------------------------------------------- */
/* Mobil: stapla stegen vertikalt                  */
/* ---------------------------------------------- */
@media (max-width: 767px) {
	.hb-timeline.hb-stack-mobile .hb-timeline-row {
		display: flex;
		flex-direction: column;
		grid-template-columns: none !important;
	}

	.hb-timeline.hb-stack-mobile .hb-timeline-track {
		display: none;
	}

	.hb-timeline.hb-stack-mobile .hb-item-content,
	.hb-timeline.hb-stack-mobile .hb-item-connector {
		grid-column: unset !important;
		grid-row: unset !important;
		width: auto;
		align-self: center !important;
	}

	.hb-timeline.hb-stack-mobile .hb-item-connector {
		height: var(--hb-connector-h);
		width: 2px;
		margin: 0 auto;
	}

	.hb-timeline.hb-stack-mobile .hb-item-content {
		text-align: left;
		padding: 4px 10px;
	}
}
