/*
 * Jetour Vehicle Manager - offer landing page (Option B "finance strip").
 * Only loaded on pages created by JVM_Offer_Pages. Everything is scoped to
 * .jvm-op so nothing leaks into Bricks; font-family follows the rest of the
 * site (HarmonyOS Sans, same as the Compare tool) and falls back to the
 * theme's own body font.
 */

.jvm-op {
	--jvm-op-accent: #009CA5;
	--jvm-op-ink: #141416;
	--jvm-op-band: #141416;
	--jvm-op-line: #2F3236;
	--jvm-op-muted: #A3A8AF;
	--jvm-op-paper: #FFFFFF;
	--jvm-op-soft: #F4F5F6;
	/* Side padding = the site footer's container padding at each Bricks
	   breakpoint (desktop 96px, tablet <=991px 50px, mobile <=767px 20px),
	   so content lines up with the header/footer edges. Desktop and tablet
	   values are set on Jetour Vehicles > Offer Pages and arrive inline. */
	--jvm-op-pad-desktop: 96px;
	--jvm-op-pad-tablet: 50px;
	--jvm-op-pad-mobile: 20px;
	--jvm-op-gutter: var(--jvm-op-pad-desktop);

	font-family: "HarmonyOS Sans", sans-serif;
	color: var(--jvm-op-ink);
	background: var(--jvm-op-paper);
	line-height: 1.5;
	/* Full bleed even if a theme wrapper constrains the content width. */
	width: 100vw;
	max-width: 100vw;
	margin-left: calc(50% - 50vw);
	overflow-x: clip;
}
.jvm-op *, .jvm-op *::before, .jvm-op *::after { box-sizing: border-box; }
.jvm-op-main { display: block; }

.jvm-op .jvm-op-wrap {
	width: 100%;
	max-width: none; /* full width on any display; edges set by the padding */
	margin: 0;
	padding: 0 var(--jvm-op-gutter);
}

/* ---------- Hero ---------- */
.jvm-op .jvm-op-hero {
	position: relative;
	background: #202327;
	color: #fff;
	min-height: clamp(460px, 44vw, 760px);
	display: flex;
	align-items: flex-end;
	isolation: isolate;
}
.jvm-op .jvm-op-hero-media,
.jvm-op .jvm-op-hero-img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	display: block;
	z-index: -2;
}
/* !important: some themes/plugins print inline width/height styles on
   attachment images, which would otherwise squash the cover crop. */
.jvm-op .jvm-op-hero-img {
	width: 100% !important;
	height: 100% !important;
	max-width: none !important;
	object-fit: cover;
	object-position: center;
}
.jvm-op .jvm-op-hero-scrim {
	position: absolute;
	inset: auto 0 0 0;
	height: 65%;
	z-index: -1;
	background: linear-gradient(to top, rgba(10, 11, 13, 0.78), rgba(10, 11, 13, 0));
	pointer-events: none;
}
.jvm-op .jvm-op-hero--noimg .jvm-op-hero-scrim { display: none; }
.jvm-op .jvm-op-hero-text { padding-top: 120px; padding-bottom: clamp(32px, 5vw, 72px); }

.jvm-op .jvm-op-title {
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 14px;
	font: inherit;
	color: #fff;
}
/* Logo scales with the screen, in step with the variant/price text beneath
   it: ~104px tall on a wide desktop, ~54px at tablet width, ~32px on a
   phone (where the variant line is 20px and the price 30px). */
.jvm-op .jvm-op-logo img {
	display: block;
	height: auto !important;
	width: auto !important;
	max-width: clamp(150px, 30vw, 440px) !important;
	max-height: clamp(32px, 6vw, 104px) !important;
	object-fit: contain;
	object-position: left center;
}
.jvm-op .jvm-op-model {
	font-size: clamp(48px, 7vw, 96px);
	font-weight: 700;
	line-height: 0.95;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}
.jvm-op .jvm-op-variant {
	font-size: clamp(20px, 2.2vw, 30px);
	font-weight: 600;
	letter-spacing: 0.08em;
	line-height: 1.2;
	text-transform: uppercase;
}
.jvm-op .jvm-op-hero-price {
	margin: 10px 0 0;
	font-size: clamp(30px, 3.6vw, 48px);
	font-weight: 700;
	line-height: 1.05;
	letter-spacing: 0.01em;
	text-transform: uppercase;
	color: #fff;
}

/* ---------- Finance strip ---------- */
.jvm-op .jvm-op-finance { background: var(--jvm-op-band); color: #fff; }
.jvm-op .jvm-op-strip { display: flex; align-items: stretch; }
.jvm-op .jvm-op-fields {
	flex: 1 1 auto;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
}
.jvm-op .jvm-op-field {
	flex: 1 1 130px;
	padding: 28px 16px 28px 0;
	margin-right: 16px;
	border-right: 1px solid var(--jvm-op-line);
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
}
.jvm-op .jvm-op-field:last-child { border-right: 0; margin-right: 0; }
.jvm-op .jvm-op-field dt {
	margin: 0;
	padding: 0;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--jvm-op-muted);
}
.jvm-op .jvm-op-field dd {
	margin: 0;
	padding: 0;
	margin-top: auto; /* values line up even when a label wraps to 2 lines */
	white-space: nowrap;
	font-size: clamp(16px, 1.35vw, 20px);
	font-weight: 700;
	line-height: 1.2;
	color: #fff;
}
.jvm-op .jvm-op-fields.is-centred .jvm-op-field { align-items: center; text-align: center; }
.jvm-op .jvm-op-fields.is-centred .jvm-op-field dt { text-wrap: balance; }

.jvm-op .jvm-op-monthly {
	flex: 0 0 auto;
	min-width: 250px;
	background: var(--jvm-op-accent);
	color: #fff;
	padding: 22px 28px;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 4px;
}
.jvm-op .jvm-op-monthly-label {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}
.jvm-op .jvm-op-monthly-value {
	white-space: nowrap;
	font-size: clamp(26px, 2.3vw, 36px);
	font-weight: 700;
	line-height: 1.05;
}

.jvm-op .jvm-op-strip-foot {
	border-top: 1px solid var(--jvm-op-line);
	padding: 16px 0 20px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px 24px;
	flex-wrap: wrap;
}
.jvm-op .jvm-op-validity { margin: 0; font-size: 14px; color: var(--jvm-op-muted); }
.jvm-op .jvm-op-validity strong { color: #fff; font-weight: 600; }
.jvm-op .jvm-op-validity a { color: #fff; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.jvm-op .jvm-op-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- Buttons ---------- */
.jvm-op .jvm-op-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 0 24px;
	border-radius: 8px;
	border: 1.5px solid transparent;
	font-size: 15px;
	font-weight: 700;
	line-height: 1;
	text-decoration: none;
	cursor: pointer;
	transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.jvm-op .jvm-op-btn--light { background: #fff; color: var(--jvm-op-ink); }
.jvm-op .jvm-op-btn--light:hover { background: var(--jvm-op-accent); color: #fff; }
.jvm-op .jvm-op-btn--ghost { border-color: #fff; color: #fff; background: transparent; }
.jvm-op .jvm-op-btn--ghost:hover { background: #fff; color: var(--jvm-op-ink); }
.jvm-op .jvm-op-btn--outline { border-color: var(--jvm-op-ink); color: var(--jvm-op-ink); background: transparent; }
.jvm-op .jvm-op-btn--outline:hover { background: var(--jvm-op-ink); color: #fff; }
.jvm-op a:focus-visible,
.jvm-op .jvm-op-btn:focus-visible { outline: 3px solid var(--jvm-op-accent); outline-offset: 3px; }

/* ---------- Content sections ---------- */
.jvm-op .jvm-op-section { padding: clamp(48px, 6vw, 88px) 0 0; scroll-margin-top: 110px; }
.jvm-op .jvm-op-section:last-child { padding-bottom: clamp(56px, 7vw, 104px); }
.jvm-op .jvm-op-h2 {
	margin: 0 0 24px;
	font-family: inherit;
	font-size: clamp(26px, 2.6vw, 34px);
	font-weight: 700;
	line-height: 1.15;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	color: var(--jvm-op-ink);
}

.jvm-op .jvm-op-spec-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	column-gap: 40px;
}
.jvm-op .jvm-op-spec-list li {
	position: relative;
	margin: 0;
	padding: 14px 0 14px 22px;
	border-bottom: 1px solid #E4E6E9;
	font-size: 16px;
}
.jvm-op .jvm-op-spec-list li::before {
	content: "";
	position: absolute;
	left: 0;
	top: calc(14px + 0.75em - 4px);
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--jvm-op-accent);
}
.jvm-op .jvm-op-more { margin: 28px 0 0; }

.jvm-op .jvm-op-terms-body {
	font-size: 14px;
	line-height: 1.7;
	color: #4A4F56;
}
.jvm-op .jvm-op-terms-body p { margin: 0 0 1em; }

.jvm-op .jvm-op-testdrive { outline: none; }
.jvm-op .jvm-op-testdrive .jvm-op-h2 { text-align: center; }
.jvm-op .jvm-op-form .jvm-op-flash { animation: jvmOpFlash 1.2s ease; }
@keyframes jvmOpFlash {
	0% { box-shadow: 0 0 0 0 var(--jvm-op-accent); }
	100% { box-shadow: 0 0 0 10px rgba(0, 0, 0, 0); }
}

/* ---------- Tablet ---------- */
@media (max-width: 991px) {
	.jvm-op { --jvm-op-gutter: var(--jvm-op-pad-tablet); }
	.jvm-op .jvm-op-strip { flex-direction: column-reverse; }
	.jvm-op .jvm-op-monthly {
		flex: none;
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
		margin: 0 calc(-1 * var(--jvm-op-gutter));
		padding: 18px var(--jvm-op-gutter);
	}
	.jvm-op .jvm-op-fields {
		display: grid;
		grid-template-columns: repeat(3, minmax(0, 1fr));
		column-gap: 24px;
	}
	.jvm-op .jvm-op-field { border-right: 0; margin-right: 0; padding: 18px 0; border-bottom: 1px solid var(--jvm-op-line); }
}

/* ---------- Mobile ---------- */
@media (max-width: 767px) {
	.jvm-op { --jvm-op-gutter: var(--jvm-op-pad-mobile); }

	/* Mobile hero: the image is shown whole - scaled to the screen width and
	   centred - instead of a cover crop. Portrait phones with a mobile image
	   keep the text over its lower part; otherwise (wide image only, or a
	   phone in landscape, which always gets the wide image - see the <source>
	   media query) the text sits on the dark band below the image. */
	.jvm-op .jvm-op-hero { min-height: 0; display: block; position: relative; }
	.jvm-op .jvm-op-hero-media { position: relative; z-index: -2; display: block; height: auto; }
	.jvm-op .jvm-op-hero-img {
		position: static;
		display: block;
		width: 100% !important;
		height: auto !important;
		margin: 0 auto;
		object-fit: contain;
		object-position: center;
	}
	.jvm-op .jvm-op-hero-text { padding-top: 24px; padding-bottom: 28px; }
	.jvm-op .jvm-op-hero-scrim { display: none; }
	.jvm-op .jvm-op-hero--noimg .jvm-op-hero-text { padding-top: 96px; }

	.jvm-op .jvm-op-fields { display: block; padding-top: 4px; }
	.jvm-op .jvm-op-field,
	.jvm-op .jvm-op-fields.is-centred .jvm-op-field {
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
		text-align: left;
		gap: 16px;
		padding: 15px 0;
	}
	.jvm-op .jvm-op-field:last-child { border-bottom: 0; }
	.jvm-op .jvm-op-field dt { font-size: 11px; letter-spacing: 0.1em; }
	.jvm-op .jvm-op-field dd { margin-top: 0; font-size: 17px; text-align: right; }
	.jvm-op .jvm-op-monthly-label { max-width: 9em; }
	.jvm-op .jvm-op-strip-foot { flex-direction: column-reverse; align-items: stretch; text-align: center; padding-bottom: 24px; }
	.jvm-op .jvm-op-actions { flex-direction: column; }
	.jvm-op .jvm-op-btn { width: 100%; min-height: 50px; }
	.jvm-op .jvm-op-spec-list { grid-template-columns: 1fr; }
	.jvm-op .jvm-op-more .jvm-op-btn { width: 100%; }
}
@media (max-width: 767px) and (orientation: portrait) {
	.jvm-op .jvm-op-hero--mobileimg .jvm-op-hero-text { position: absolute; left: 0; right: 0; bottom: 0; padding-top: 0; }
	.jvm-op .jvm-op-hero--mobileimg .jvm-op-hero-scrim { display: block; }
}

@media (prefers-reduced-motion: reduce) {
	.jvm-op .jvm-op-btn { transition: none; }
	.jvm-op .jvm-op-form .jvm-op-flash { animation: none; }
}
