.wp-block-timeline-event {
	position: relative;
	display: grid;
	align-items: start;
	column-gap: 0;
	row-gap: 1rem;
	transition:
		transform 0.35s ease,
		box-shadow 0.35s ease,
		filter 0.35s ease;
}

.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event {
	grid-template-columns: minmax(0, 1fr) 0 minmax(0, 1fr);
}

.wp-block-timeline-timeline.is-layout-left .wp-block-timeline-event {
	grid-template-columns: calc(var(--timeline-event-column-gap) + (var(--timeline-marker-size) / 2)) minmax(0, 1fr);
}

.wp-block-timeline-timeline.is-layout-right .wp-block-timeline-event {
	grid-template-columns: minmax(0, 1fr) calc(var(--timeline-event-column-gap) + (var(--timeline-marker-size) / 2));
}

.timeline-event__marker {
	width: var(--timeline-marker-size);
	min-height: var(--timeline-marker-size);
	padding: 0.625rem;
	border: var(--timeline-line-width) solid var(--timeline-accent-color);
	border-radius: 999px;
	background: var(--timeline-marker-background);
	color: var(--timeline-marker-text-color);
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	justify-self: center;
	align-self: start;
	z-index: 1;
	line-height: 1.1;
	grid-row: 1;
}

.timeline-event__marker:empty,
.wp-block-timeline-timeline.has-marker-type-none .timeline-event__marker {
	display: none;
}

.timeline-event__marker-text {
	display: block;
	font-size: 0.95rem;
	font-weight: 700;
	overflow-wrap: anywhere;
}

.timeline-event__marker-icon {
	align-items: center;
	justify-content: center;
	font-size: calc(var(--timeline-marker-size) * 0.44);
	line-height: 1;
}

.timeline-event__marker-image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 999px;
}

.timeline-event__marker-icon,
.timeline-event__marker-image {
	display: none;
}

.wp-block-timeline-timeline.has-marker-type-icon .timeline-event__marker-text,
.wp-block-timeline-timeline.has-marker-type-icon .timeline-event__marker-image {
	display: none;
}

.wp-block-timeline-timeline.has-marker-type-icon .timeline-event__marker-icon {
	display: inline-flex;
}

.wp-block-timeline-timeline.has-marker-type-image .timeline-event__marker.has-marker-image .timeline-event__marker-text,
.wp-block-timeline-timeline.has-marker-type-image .timeline-event__marker.has-marker-image .timeline-event__marker-icon {
	display: none;
}

.wp-block-timeline-timeline.has-marker-type-image .timeline-event__marker.has-marker-image .timeline-event__marker-image {
	display: block;
}

.timeline-event__card {
	position: relative;
	min-width: 0;
	padding: var(--timeline-card-padding);
	border: var(--timeline-card-stroke) var(--timeline-card-border-style) var(--timeline-card-border-color);
	border-radius: var(--timeline-border-radius);
	background-color: var(--timeline-card-background);
	background-image: var(--timeline-card-background-image);
	background-position: var(--timeline-card-background-position);
	background-repeat: var(--timeline-card-background-repeat);
	background-size: var(--timeline-card-background-size);
	background-attachment: var(--timeline-card-background-attachment);
	color: var(--timeline-text-color);
	font-size: var(--timeline-card-font-size);
	line-height: var(--timeline-card-line-height);
	font-family: var(--timeline-card-font-family);
	font-weight: var(--timeline-card-font-weight);
	font-style: var(--timeline-card-font-style);
	letter-spacing: var(--timeline-card-letter-spacing);
	text-transform: var(--timeline-card-text-transform);
	text-decoration: var(--timeline-card-text-decoration);
	box-shadow: var(--timeline-card-shadow);
	grid-row: 1;
	overflow: visible;
	z-index: 1;
	isolation: isolate;
}

.timeline-event__card > * {
	position: relative;
	z-index: 2;
}

.timeline-event__card-marker {
	display: none;
	margin: 0 0 0.75rem;
	color: var(--timeline-accent-color);
	font-size: 0.95rem;
	font-weight: 700;
	line-height: 1.2;
}

.timeline-event__card::before,
.timeline-event__card::after {
	content: "";
	position: absolute;
	display: none;
	pointer-events: none;
}

.wp-block-timeline-event.is-active .timeline-event__card {
	border-color: var(--timeline-accent-color);
	box-shadow: 0 16px 32px rgba(0, 0, 0, 0.12);
}

.wp-block-timeline-event.is-active {
	transform: scale(1.02);
	z-index: 2;
}

.wp-block-timeline-timeline.is-orientation-horizontal .wp-block-timeline-event.is-active {
	transform: none;
}

.wp-block-timeline-timeline.has-connection-line .wp-block-timeline-event.is-active {
	transform: none;
}

.wp-block-timeline-timeline.is-orientation-horizontal .wp-block-timeline-event {
	display: block;
	flex: 0 0 min(100%, var(--timeline-horizontal-event-width));
	min-width: min(100%, var(--timeline-horizontal-event-width));
	padding-top: var(--timeline-horizontal-card-offset);
	scroll-snap-align: start;
	z-index: 1;
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line .wp-block-timeline-event::before {
	content: "";
	position: absolute;
	left: 50%;
	pointer-events: none;
	transform: translateX(-50%);
	z-index: 0;
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line .wp-block-timeline-event::before {
	top: var(--timeline-horizontal-connector-start);
	width: var(--timeline-connector-line-thickness);
	height: var(--timeline-horizontal-connector-visible-length);
	background: var(--timeline-line-color);
	border-radius: 999px;
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line .wp-block-timeline-event.is-active::before {
	width: var(--timeline-line-active-width);
	background: var(--timeline-accent-color);
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line.is-marker-placement-card .wp-block-timeline-event::before,
.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line.has-marker-type-none .wp-block-timeline-event::before {
	top: var(--timeline-horizontal-connector-axis-start);
	height: var(--timeline-horizontal-connector-axis-length);
}

.wp-block-timeline-timeline.is-orientation-horizontal .wp-block-timeline-event .timeline-event__card {
	grid-row: auto;
	margin-left: 0;
	margin-right: 0;
}

.wp-block-timeline-timeline.is-orientation-horizontal.is-marker-placement-line .wp-block-timeline-event .timeline-event__marker {
	position: absolute;
	top: 0;
	left: 50%;
	transform: translateX(-50%);
	grid-column: auto;
	align-self: auto;
	justify-self: auto;
	margin: 0;
}

.wp-block-timeline-timeline.is-orientation-horizontal.is-marker-placement-line .wp-block-timeline-event .timeline-event__card {
	padding-right: var(--timeline-card-padding-right);
}

.timeline-event__card > *:first-child {
	margin-top: 0;
}

.timeline-event__card > *:last-child {
	margin-bottom: 0;
}

.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card,
.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card {
	grid-column: 1;
	margin-right: var(--timeline-event-column-gap);
	margin-left: 0;
}

.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card,
.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card {
	grid-column: 3;
	margin-left: var(--timeline-event-column-gap);
	margin-right: 0;
}

.wp-block-timeline-timeline.is-layout-left .wp-block-timeline-event .timeline-event__card {
	grid-column: 2;
	margin-left: 0;
	margin-right: 0;
}

.wp-block-timeline-timeline.is-layout-right .wp-block-timeline-event .timeline-event__card {
	grid-column: 1;
	margin-right: 0;
	margin-left: 0;
}

.wp-block-timeline-timeline.is-orientation-horizontal.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card,
.wp-block-timeline-timeline.is-orientation-horizontal.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card,
.wp-block-timeline-timeline.is-orientation-horizontal.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card,
.wp-block-timeline-timeline.is-orientation-horizontal.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card,
.wp-block-timeline-timeline.is-orientation-horizontal.is-layout-left .wp-block-timeline-event .timeline-event__card,
.wp-block-timeline-timeline.is-orientation-horizontal.is-layout-right .wp-block-timeline-event .timeline-event__card {
	grid-column: auto;
	margin-left: 0;
	margin-right: 0;
}

.wp-block-timeline-timeline.is-marker-placement-line.is-layout-alternating .wp-block-timeline-event .timeline-event__marker {
	position: absolute;
	top: var(--timeline-connection-anchor-y);
	left: 50%;
	grid-column: auto;
	align-self: auto;
	justify-self: auto;
	transform: translate(-50%, -50%);
}

.wp-block-timeline-timeline.is-marker-placement-line.is-layout-left .wp-block-timeline-event .timeline-event__marker {
	position: absolute;
	top: var(--timeline-connection-anchor-y);
	left: calc(var(--timeline-marker-size) / 2);
	grid-column: auto;
	align-self: auto;
	justify-self: auto;
	transform: translate(-50%, -50%);
}

.wp-block-timeline-timeline.is-marker-placement-line.is-layout-right .wp-block-timeline-event .timeline-event__marker {
	position: absolute;
	top: var(--timeline-connection-anchor-y);
	left: calc(100% - (var(--timeline-marker-size) / 2));
	grid-column: auto;
	align-self: auto;
	justify-self: auto;
	transform: translate(-50%, -50%);
}

.wp-block-timeline-timeline.is-orientation-horizontal.is-marker-placement-line.is-layout-alternating .wp-block-timeline-event .timeline-event__marker,
.wp-block-timeline-timeline.is-orientation-horizontal.is-marker-placement-line.is-layout-left .wp-block-timeline-event .timeline-event__marker,
.wp-block-timeline-timeline.is-orientation-horizontal.is-marker-placement-line.is-layout-right .wp-block-timeline-event .timeline-event__marker {
	top: 0;
	left: 50%;
	transform: translateX(-50%);
}

.wp-block-timeline-timeline.is-marker-placement-card .wp-block-timeline-event .timeline-event__marker {
	display: none;
}

.wp-block-timeline-timeline.is-marker-placement-card .wp-block-timeline-event .timeline-event__card {
	padding-right: var(--timeline-card-padding-right);
}

.wp-block-timeline-timeline.is-marker-placement-card .wp-block-timeline-event .timeline-event__card-marker:not(:empty) {
	display: block;
}

/* ---- Arrow connector: one rotated square clipped to the outward half ---- */

.wp-block-timeline-timeline.has-connection-arrow .timeline-event__card {
	--_arrow-border-color: var(--timeline-card-border-color);
	--_arrow-fill-color: var(--timeline-card-background);
}

.wp-block-timeline-event.is-active .timeline-event__card {
	--_arrow-border-color: var(--timeline-accent-color);
}

.wp-block-timeline-timeline.has-connection-arrow .timeline-event__card::after {
	display: block;
	content: "";
	position: absolute;
	width: var(--timeline-connector-arrow-size);
	height: var(--timeline-connector-arrow-size);
	box-sizing: border-box;
	background-color: var(--_arrow-fill-color);
	background-image: var(--timeline-card-background-image);
	background-position: var(--timeline-card-background-position);
	background-repeat: var(--timeline-card-background-repeat);
	background-size: var(--timeline-card-background-size);
	background-attachment: var(--timeline-card-background-attachment);
	background-clip: padding-box;
	border: var(--timeline-card-stroke) var(--timeline-card-border-style) var(--_arrow-border-color);
	border-radius: 0;
	pointer-events: none;
	transform-origin: 50% 50%;
	z-index: -1;
}

/* ---- Right-pointing arrows (card on left, marker/line on right) ---- */
/* alternating odd + is-layout-right */

.wp-block-timeline-timeline.has-connection-arrow.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-arrow.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-arrow.is-layout-right .wp-block-timeline-event .timeline-event__card::after {
	top: calc(var(--timeline-connection-anchor-y) - (var(--timeline-connector-arrow-size) / 2));
	left: calc(100% - ((var(--timeline-connector-arrow-edge-offset) / 2) + (var(--timeline-card-stroke) * 2)));
	clip-path: polygon(0 0, 100% 0, 100% 100%, 100% 100%);
	transform: rotate(45deg);
}

/* ---- Left-pointing arrows (card on right, marker/line on left) ---- */
/* alternating even + is-layout-left */

.wp-block-timeline-timeline.has-connection-arrow.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-arrow.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-arrow.is-layout-left .wp-block-timeline-event .timeline-event__card::after {
	top: calc(var(--timeline-connection-anchor-y) - (var(--timeline-connector-arrow-size) / 2));
	right: calc(100% - ((var(--timeline-connector-arrow-edge-offset) / 2) + (var(--timeline-card-stroke) * 2)));
	left: auto;
	clip-path: polygon(0 0, 0 0, 100% 100%, 0 100%);
	transform: rotate(45deg);
}

.wp-block-timeline-timeline.has-connection-line .timeline-event__card::after {
	display: block;
	top: var(--timeline-connection-anchor-y);
	height: var(--timeline-connector-line-thickness);
	background: var(--timeline-line-color);
	transform: translateY(-50%);
}

.wp-block-timeline-timeline.has-connection-line .wp-block-timeline-event.is-active .timeline-event__card::after {
	background: var(--timeline-accent-color);
}

.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event.is-active:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event.is-active:nth-child(even):not(.is-side-left) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event.is-active.is-side-left .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event.is-active.is-side-right .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-left .wp-block-timeline-event.is-active .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-right .wp-block-timeline-event.is-active .timeline-event__card::after {
	height: var(--timeline-line-active-width) !important;
}

.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-right .wp-block-timeline-event .timeline-event__card::after {
	left: 100%;
	width: var(--timeline-connector-line-length);
}

.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-layout-left .wp-block-timeline-event .timeline-event__card::after {
	right: 100%;
	width: var(--timeline-connector-line-length);
}

.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-right .wp-block-timeline-event .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-right .wp-block-timeline-event .timeline-event__card::after {
	width: var(--timeline-connector-line-axis-length);
}

.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-left .wp-block-timeline-event .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-left .wp-block-timeline-event .timeline-event__card::after {
	width: var(--timeline-connector-line-axis-length);
}

.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-alternating .wp-block-timeline-event:first-child:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-alternating .wp-block-timeline-event:last-child:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-alternating .wp-block-timeline-event:first-child:nth-child(even):not(.is-side-left) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-alternating .wp-block-timeline-event:last-child:nth-child(even):not(.is-side-left) .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-alternating .wp-block-timeline-event:first-child.is-side-left .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-alternating .wp-block-timeline-event:last-child.is-side-left .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-alternating .wp-block-timeline-event:first-child.is-side-right .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-alternating .wp-block-timeline-event:last-child.is-side-right .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-left .wp-block-timeline-event:first-child .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-left .wp-block-timeline-event:last-child .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-right .wp-block-timeline-event:first-child .timeline-event__card::after,
.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal).is-layout-right .wp-block-timeline-event:last-child .timeline-event__card::after {
	top: calc(var(--timeline-connection-anchor-y) + var(--timeline-connector-edge-shift));
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line .timeline-event__card::after {
	display: none;
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line .timeline__line + .wp-block-timeline-event::before,
.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line .wp-block-timeline-event:last-child::before {
	top: calc(var(--timeline-horizontal-connector-start) - var(--timeline-connector-edge-overlap));
	height: calc(var(--timeline-horizontal-connector-visible-length) + var(--timeline-connector-edge-overlap));
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line .timeline__line + .wp-block-timeline-event::before {
	left: calc(50% + (var(--timeline-connector-line-thickness) / 2));
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line .wp-block-timeline-event:last-child::before {
	left: calc(50% - (var(--timeline-connector-line-thickness) / 2));
}

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line.is-marker-placement-card .timeline__line + .wp-block-timeline-event::before,
.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line.is-marker-placement-card .wp-block-timeline-event:last-child::before,
.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line.has-marker-type-none .timeline__line + .wp-block-timeline-event::before,
.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-line.has-marker-type-none .wp-block-timeline-event:last-child::before {
	top: calc(var(--timeline-horizontal-connector-axis-start) - var(--timeline-connector-edge-overlap));
	height: calc(var(--timeline-horizontal-connector-axis-length) + var(--timeline-connector-edge-overlap));
}

/* ---- Up-pointing arrows (horizontal orientation — card below, marker above) ---- */

.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-arrow.is-layout-alternating .wp-block-timeline-event .timeline-event__card::after,
.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-arrow.is-layout-left .wp-block-timeline-event .timeline-event__card::after,
.wp-block-timeline-timeline.is-orientation-horizontal.has-connection-arrow.is-layout-right .wp-block-timeline-event .timeline-event__card::after {
	top: calc(0px - ((var(--timeline-connector-arrow-edge-offset) / 2) + (var(--timeline-card-stroke) * 2))) !important;
	left: calc(50% - (var(--timeline-connector-arrow-size) / 2) + var(--timeline-card-stroke)) !important;
	right: auto !important;
	bottom: auto !important;
	clip-path: polygon(0 0, 100% 0, 100% 0, 0 100%) !important;
	transform: rotate(45deg) !important;
}

@media (max-width: 782px) {
	.wp-block-timeline-event,
	.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event,
	.wp-block-timeline-timeline.is-layout-left .wp-block-timeline-event,
	.wp-block-timeline-timeline.is-layout-right .wp-block-timeline-event {
		grid-template-columns: var(--timeline-marker-size) minmax(0, 1fr);
	}

	.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card,
	.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card,
	.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card,
	.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card,
	.wp-block-timeline-timeline.is-layout-alternating .wp-block-timeline-event .timeline-event__card,
	.wp-block-timeline-timeline.is-layout-left .wp-block-timeline-event .timeline-event__card,
	.wp-block-timeline-timeline.is-layout-right .wp-block-timeline-event .timeline-event__card {
		grid-column: 2;
		margin-left: max(0px, calc(var(--timeline-event-column-gap) - (var(--timeline-marker-size) / 2)));
		margin-right: 0;
	}

	.wp-block-timeline-timeline.is-marker-placement-line.is-layout-alternating .wp-block-timeline-event .timeline-event__marker,
	.wp-block-timeline-timeline.is-marker-placement-line.is-layout-left .wp-block-timeline-event .timeline-event__marker,
	.wp-block-timeline-timeline.is-marker-placement-line.is-layout-right .wp-block-timeline-event .timeline-event__marker {
		left: calc(var(--timeline-marker-size) / 2);
		transform: translate(-50%, -50%);
	}

	.wp-block-timeline-timeline.is-marker-placement-card .wp-block-timeline-event .timeline-event__card {
		padding-right: var(--timeline-card-padding-right);
	}

	/* Mobile vertical: all arrows point left (card always on right of marker) */
	.wp-block-timeline-timeline:not(.is-orientation-horizontal).has-connection-arrow.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
	.wp-block-timeline-timeline:not(.is-orientation-horizontal).has-connection-arrow.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card::after,
	.wp-block-timeline-timeline:not(.is-orientation-horizontal).has-connection-arrow.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card::after,
	.wp-block-timeline-timeline:not(.is-orientation-horizontal).has-connection-arrow.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card::after,
	.wp-block-timeline-timeline:not(.is-orientation-horizontal).has-connection-arrow.is-layout-left .wp-block-timeline-event .timeline-event__card::after,
	.wp-block-timeline-timeline:not(.is-orientation-horizontal).has-connection-arrow.is-layout-right .wp-block-timeline-event .timeline-event__card::after {
		top: calc(var(--timeline-connection-anchor-y) - (var(--timeline-connector-arrow-size) / 2)) !important;
		right: calc(100% - ((var(--timeline-connector-arrow-edge-offset) / 2) + (var(--timeline-card-stroke) * 2))) !important;
		left: auto !important;
		clip-path: polygon(0 0, 0 0, 100% 100%, 0 100%) !important;
		transform: rotate(45deg) !important;
	}

	.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-layout-left .wp-block-timeline-event .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-layout-right .wp-block-timeline-event .timeline-event__card::after {
		left: auto !important;
		right: 100% !important;
		width: var(--timeline-connector-line-length) !important;
		height: var(--timeline-connector-line-thickness) !important;
		top: var(--timeline-connection-anchor-y) !important;
		transform: translateY(-50%) !important;
	}

	.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-left .wp-block-timeline-event .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.is-marker-placement-card.is-layout-right .wp-block-timeline-event .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-alternating .wp-block-timeline-event:nth-child(odd):not(.is-side-right) .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-alternating .wp-block-timeline-event:nth-child(even):not(.is-side-left) .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-alternating .wp-block-timeline-event.is-side-left .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-alternating .wp-block-timeline-event.is-side-right .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-left .wp-block-timeline-event .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line.has-marker-type-none.is-layout-right .wp-block-timeline-event .timeline-event__card::after {
		width: var(--timeline-connector-line-axis-length) !important;
	}

	.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal) .wp-block-timeline-event:first-child .timeline-event__card::after,
	.wp-block-timeline-timeline.has-connection-line:not(.is-orientation-horizontal) .wp-block-timeline-event:last-child .timeline-event__card::after {
		top: calc(var(--timeline-connection-anchor-y) + var(--timeline-connector-edge-shift)) !important;
	}
}
