.vehicle {
	overflow: hidden;
	background: var(--ink);
}

.vehicle__stage {
	position: relative;
	padding-block: var(--section-space);
}

.vehicle__intro {
	position: relative;
	z-index: 2;
	text-align: center;
}

.vehicle__media {
	position: relative;
	width: min(100%, 90rem);
	margin: clamp(2rem, 5vw, 4rem) auto 0;
	padding-inline: var(--gutter);
}

.vehicle__still {
	width: 100%;
}

.vehicle__canvas,
.vehicle__progress {
	display: none;
}

.vehicle__callouts {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
	gap: 2rem;
	margin-top: clamp(2rem, 5vw, 4rem);
	padding-left: var(--gutter);
	list-style: none;
}

.vehicle__callout {
	display: grid;
	gap: 0.25rem;
	padding-top: 1rem;
	border-top: 1px solid var(--ink-line);
}

.vehicle__callout-number {
	color: var(--sky);
	font-family: var(--font-heading);
	font-size: 1rem;
	font-weight: 600;
	letter-spacing: 0.14em;
}

.vehicle__callout-title {
	font-family: var(--font-heading);
	font-size: 1.625rem;
	font-weight: 700;
	line-height: 1.1;
	text-transform: uppercase;
}

.vehicle__callout-text {
	color: var(--bone-muted);
	font-size: 0.9375rem;
	line-height: 1.5;
}

/* Sequence mode: set by sequence.js when the scroll animation runs. */
.vehicle.is-sequence .vehicle__stage {
	height: 100vh;
	height: 100svh;
	padding: 0;
	overflow: hidden;
}

.vehicle.is-sequence .vehicle__intro {
	position: absolute;
	inset: calc(var(--header-height) + clamp(1rem, 4vh, 3rem)) 0 auto;
}

.vehicle.is-sequence .vehicle__media {
	position: absolute;
	inset: 0;
	width: auto;
	margin: 0;
	padding: 0;
}

.vehicle.is-sequence .vehicle__still,
.vehicle.is-sequence .vehicle__canvas {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
}

.vehicle.is-sequence .vehicle__still {
	object-fit: contain;
}

.vehicle.is-sequence .vehicle__canvas {
	display: block;
}

.vehicle.is-ready .vehicle__still {
	visibility: hidden;
}

.vehicle.is-sequence .vehicle__callouts {
	position: absolute;
	inset: calc(var(--header-height) + 1.5rem) 0 4rem;
	display: block;
	width: auto;
	max-width: none;
	margin: 0;
	padding: 0;
	pointer-events: none;
}

.vehicle.is-sequence .vehicle__callout {
	position: absolute;
	width: min(17rem, 40vw);
}

.vehicle.is-sequence .vehicle__callout:nth-child(1) {
	top: 4%;
	left: var(--gutter);
}

.vehicle.is-sequence .vehicle__callout:nth-child(2) {
	top: 4%;
	right: var(--gutter);
}

.vehicle.is-sequence .vehicle__callout:nth-child(3) {
	bottom: 0;
	left: var(--gutter);
}

.vehicle.is-sequence .vehicle__callout:nth-child(4) {
	right: var(--gutter);
	bottom: 0;
}

.vehicle.is-sequence .vehicle__progress {
	position: absolute;
	inset: auto var(--gutter) 1.75rem;
	display: block;
	height: 2px;
	background: var(--ink-line);
}

.vehicle__progress span {
	display: block;
	height: 100%;
	background: var(--sky);
	transform: scaleX(0);
	transform-origin: left;
}

@media (max-width: 767px) {
	.vehicle.is-sequence .vehicle__callout {
		width: 44vw;
	}

	.vehicle.is-sequence .vehicle__callout-title {
		font-size: 1.25rem;
	}

	.vehicle.is-sequence .vehicle__callout-text {
		font-size: 0.8125rem;
	}
}

/*
 * Breakdown: the vehicle photo comes apart into seven parts (sequence.js).
 * .breakdown keeps the photo's 4:3 shape so the part outlines line up with it.
 */
.breakdown {
	position: relative;
	width: 100%;
	aspect-ratio: 4 / 3;
}

.breakdown__base {
	position: relative;
	z-index: 2;
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.breakdown__part,
.breakdown__label {
	display: none;
}

.vehicle--breakdown.is-sequence .vehicle__media {
	inset: calc(var(--header-height) + clamp(7.5rem, 17vh, 10rem)) var(--gutter) clamp(3rem, 7vh, 4.5rem);
	display: grid;
	place-items: center;
	container-type: size;
}

/* As large as fits, leaving room above and below for the labels. */
.vehicle--breakdown.is-sequence .breakdown {
	width: min(100cqw, (100cqh - 9rem) * 4 / 3);
}

.vehicle--breakdown.is-sequence .vehicle__callouts {
	display: none;
}

.vehicle--breakdown.is-sequence .breakdown__part {
	position: absolute;
	inset: 0;
	display: block;
	will-change: transform;
}

.vehicle--breakdown.is-sequence .breakdown__piece {
	will-change: filter;
}

.breakdown__piece {
	position: absolute;
	inset: 0;
}

/*
 * 3D disassembly (sequence.js): the stage gives depth, the vehicle and its parts keep their 3D positions,
 * and a soft ground shadow spreads beneath while it comes apart.
 */
.vehicle--breakdown.is-sequence .vehicle__media {
	perspective: 1800px;
	perspective-origin: 50% 40%;
}

/* isolation (set on .breakdown--cutout) would flatten the 3D scene; the stage's perspective already keeps the glow behind. */
.vehicle--breakdown.is-sequence .breakdown,
.vehicle--breakdown.is-sequence .breakdown__part {
	isolation: auto;
	transform-style: preserve-3d;
}

.breakdown__shadow {
	display: none;
}

.vehicle--breakdown.is-sequence .breakdown__shadow {
	position: absolute;
	inset: auto 8% -6%;
	display: block;
	height: 16%;
	background: radial-gradient(closest-side, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.3) 55%, transparent);
	opacity: 0.45;
	pointer-events: none;
}

.breakdown__piece img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.vehicle--breakdown.is-sequence .breakdown__label {
	position: absolute;
	display: grid;
	gap: 0.125rem;
	width: max-content;
	max-width: 16rem;
	padding: 0.5rem 0.75rem;
	border-left: 2px solid var(--sky);
	background: rgba(16, 19, 24, 0.9);
	visibility: hidden;
}

.breakdown__label--end {
	border-right: 2px solid var(--sky);
	border-left: 0;
	text-align: right;
}

.breakdown__label--center {
	width: 16rem;
	margin-left: -8rem;
	border-top: 2px solid var(--sky);
	border-left: 0;
	text-align: center;
}

.breakdown__label .vehicle__callout-title {
	font-size: 1.375rem;
}

@media (max-width: 767px) {
	.vehicle--breakdown.is-sequence .vehicle__media {
		inset: calc(var(--header-height) + 10.5rem) var(--gutter) 3.5rem;
	}

	/* Narrower than the screen, so the outer parts and their labels stay in view when they fly apart. */
	.vehicle--breakdown.is-sequence .breakdown {
		width: min(82cqw, (100cqh - 7rem) * 4 / 3);
	}

	.vehicle--breakdown.is-sequence .breakdown__label {
		max-width: 9rem;
		padding: 0.375rem 0.5rem;
	}

	.breakdown__label--center {
		width: 9rem;
		margin-left: -4.5rem;
	}

	.breakdown__label .vehicle__callout-title {
		font-size: 1rem;
	}

	.breakdown__label .vehicle__callout-text {
		display: none;
	}
}

/* Cut-out vehicle (no background): a soft light behind it and a shadow on the ground. */
.breakdown--cutout {
	isolation: isolate;
}

.breakdown--cutout::before,
.breakdown--cutout::after {
	content: "";
	position: absolute;
	z-index: -1;
	pointer-events: none;
}

.breakdown--cutout::before {
	inset: 0 -10% 0;
	background: radial-gradient(45% 50% at 50% 55%, rgba(60, 191, 240, 0.16), transparent 72%);
}

.breakdown--cutout::after {
	inset: auto 4% -3%;
	height: 9%;
	background: radial-gradient(50% 50% at 50% 50%, rgba(0, 0, 0, 0.7), transparent 72%);
}
