/* New Vehicles hub — rebuilt to match
   design_handoff_cbm_marketplace/pages/CBM New Vehicles.dc.html exactly
   (see page-templates/template-new-vehicles.php's header comment for the
   full rationale). */

/* The old .cbm-nv-sponsor-row* absolute-overlay hack has been replaced by
   the shared .cbm-textwrap component (components.css) — see
   inc/template-tags.php's cbm_render_intro_textwrap(). */

/* Two independent columns — .cbm-nv-hero-main (image, then the CNVI panel)
   and .cbm-nv-hero-aside (ad space, then the sidebar) — each a flex column
   stacking its own children back-to-back. This replaced an earlier 2-row
   grid where all four pieces were separate grid items sharing the same two
   row tracks: cropping the image shorter left a gap under it because the
   *row* still had to be as tall as the (independently-sized) ad box next
   to it, pushing the panel down to the row's height instead of sitting
   right under the now-shorter image. Splitting into two flex columns means
   each side's height is only ever the sum of its own two children — the
   image and the ad box no longer need to agree on a height at all. */
.cbm-nv-hero-grid {
	padding-block: 20px; display: grid; grid-template-columns: 3fr 1fr; gap: 24px; align-items: start;
}
.cbm-nv-hero-main, .cbm-nv-hero-aside { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
/* Cropped shorter (same width, less height) so the CBW New Vehicles Index
   panel below sits higher on the page without the visitor scrolling —
   object-fit: cover keeps the full-width photo, just trims top/bottom. */
.cbm-nv-hero-image img { width: 100%; aspect-ratio: 2.2 / 1; object-fit: cover; object-position: center 40%; display: block; border-radius: 2px; }
/* Sized on its own terms (aspect-ratio against its own column width), not
   tied to the hero image's height in any way — see the comment above. The
   ratio here (298:600) reproduces its previous rendered size at this row's
   reference (max) width. */
.cbm-nv-hero-adspace { aspect-ratio: 298 / 600; box-sizing: border-box; }
/* The sitewide topbar search box (header.php's .cbm-topbar__search) is a
   compact, content-width widget everywhere else on the site — but on this
   page it sits directly above the ad-space box, and both being anchored to
   the same right edge with different widths left a visible gap on the left
   side. Widened here, on this page only, to exactly the aside column's own
   width (1fr of this row's 3fr/1fr split) so the two boxes form one
   continuous edge, left and right. Only applies at the width this
   hero-grid actually uses that ratio at — below 1024px the grid stacks to
   one column (see the media query below), so the match is desktop-only by
   necessity, not an oversight. */
@media (min-width: 1025px) {
	body.page-template-template-new-vehicles .cbm-topbar__search {
		width: calc((min(100vw, var(--cbm-max-width)) - (var(--cbm-side-padding) * 2) - 24px) / 4);
	}
	body.page-template-template-new-vehicles .cbm-topbar__search input { flex: 1; }
}
.cbm-nv-hero-adspace .cbm-ad-empty-slot {
	background: var(--cbm-fill-light); border: 1px dashed var(--cbm-muted-grey); border-radius: 2px; min-height: 160px;
}

.cbm-nv-panel { padding: 10px 20px 20px; text-align: left; }
.cbm-nv-panel__heading { font-family: var(--cbm-font-heading); font-weight: 700; font-size: 24px; letter-spacing: 0.02em; color: #333; margin-bottom: 7px; }
.cbm-nv-panel__buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; align-items: start; }
/* Each column stacks its control with its own caption directly beneath —
   keeps the caption's width locked to that column, so it can never read
   as belonging to (or spilling under) the other column's control. */
.cbm-nv-panel__buttons-col { min-width: 0; }
/* Scoped to the New Buses/Coaches/Minibuses/All Showroom page's sidebar
   specifically (not the New Vehicles hub, which reuses the same
   .cbm-nv-panel__buttons-col class in an unrelated 1fr/1fr button pair) —
   without this, the search box fills the whole ~359px aside column while
   the skyscraper below it sits at its true 298px, so the two don't line up
   and the search box reads oddly wide next to it. Matched to
   .cbm-nvs-skyscraper's own width:298px, per the user (2026-08-26). Both
   default to the column's left edge already (neither has its own
   margin/centering), so capping the width alone is enough to line them up. */
.cbm-nvs-col-aside .cbm-nv-panel__buttons-col { width: 298px; max-width: 100%; }
/* Ranged right, not left — per the user (2026-08-26): the search box and
   skyscraper (both a fixed 298px, narrower than this ~359px aside column)
   should sit flush with the page's true right margin — the same edge the
   manufacturer bars/vehicle-card grid in the main column already reach on
   their own side — rather than flush with the aside column's own left
   edge, which left a ~60px unexplained gap between them and the right
   margin. flex-direction:column + align-items:flex-end, not a per-child
   margin-left:auto, so any future addition to this column inherits the
   same right-alignment automatically. */
.cbm-nvs-col-aside { display: flex; flex-direction: column; align-items: flex-end; }
.cbm-nv-panel__buttons-title {
	font-family: var(--cbm-font-heading); font-weight: 700; font-size: 26px; text-transform: uppercase;
	letter-spacing: 0.04em; color: #333; margin: 0 0 6px;
}
.cbm-nv-panel__btn {
	display: block; width: 100%; box-sizing: border-box; min-height: 54px; font-weight: 700; font-size: 13px; letter-spacing: 0.02em; text-transform: uppercase;
	text-align: center; padding: 12px; border-radius: 2px; border: 1px solid transparent; cursor: pointer;
}
.cbm-nv-panel__btn--red { background: var(--cbm-red); border-color: var(--cbm-red); color: #fff; }
.cbm-nv-panel__btn--logo-red { background: var(--cbm-red); border-color: var(--cbm-red); color: #fff; }
/* "Scroll the Index" is the manufacturer <select> itself, not a button
   that reveals one below it — styled to read as a button (no native
   dropdown arrow/inset shadow, centred label) while still being a real,
   directly-clickable-and-choosable form control. Same box height as
   "Search the Index" below it (shared min-height on .cbm-nv-panel__btn)
   so the two sit as a visually matched pair. */
.cbm-nv-panel__btn--select {
	appearance: none; -webkit-appearance: none; -moz-appearance: none;
	text-align-last: center; text-align: center;
}
.cbm-nv-panel__btn--select:disabled { opacity: 0.5; cursor: not-allowed; }
.cbm-nv-scroll-converter { margin-top: 8px; } /* Converter Index under Manufacturer Index (2026-10-08) */
/* "Search the Index" is likewise the search form itself, styled as one
   rectangle: the "Start typing" input fills the box, a vertical divider
   line separates it from a plain arrowhead trigger on the right — not a
   separate pill-shaped input floating inside a bigger box. */
.cbm-nv-panel__search-deep {
	display: flex; align-items: stretch; padding: 6px; gap: 0; text-align: left; text-transform: none; overflow: hidden;
}
/* Red box, white letters (2026-09-07, was white box/red text) -- same
   fix and same reasoning as .cbm-nv-inline-search above ("same wherever
   it displays on the site"). transparent lets this form's own
   .cbm-nv-panel__btn--red background show through the input instead of
   painting white over it. */
.cbm-nv-panel__search-deep input {
	flex: 1; min-width: 0; border: none; background: transparent; border-radius: 2px 0 0 2px; padding: 0 14px; font-size: 13px; font-weight: 400;
	letter-spacing: normal; text-transform: none; color: #fff; outline: none;
}
.cbm-nv-panel__search-deep input::placeholder { color: #fff; opacity: 1; }
.cbm-nv-panel__search-deep button {
	flex: 0 0 auto; width: 44px; display: flex; align-items: center; justify-content: center;
	border: none; border-left: 1px solid rgba(255,255,255,0.5); background: transparent; cursor: pointer;
}
/* A plain arrowhead — a solid triangle, no shaft/tail — drawn with the
   CSS border trick rather than relying on a Unicode glyph that varies by
   font (most "→"-style characters render with a visible tail/shaft). */
.cbm-nv-panel__search-arrowhead {
	display: block; width: 0; height: 0;
	border-top: 7px solid transparent; border-bottom: 7px solid transparent; border-left: 10px solid #fff;
}
.cbm-nv-panel__buttons-caption { font-size: 15px; color: var(--cbm-body-grey); margin: 10px 0 0; }

.cbm-nv-panel__howto { margin-top: 0; margin-bottom: 16px; }

.cbm-nv-panel__featured { margin-top: 32px; }
.cbm-nv-panel__featured-title {
	font-family: var(--cbm-font-body); font-weight: 700; font-size: 20px; color: #333; margin: 0 0 16px;
}
/* minmax(0, 1fr) — same overflow guard as .cbm-nvs-columns above; this
   nested grid was the actual source of that overflow (its two "1fr"
   columns were each computing wider than their fair share, forcing this
   whole panel — and its parent .cbm-nvs-col-main — ~250px wider than the
   1174px margin allows). */
.cbm-nv-panel__featured-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.cbm-nv-panel__featured-photo { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 2px; display: block; }
.cbm-nv-panel__featured-logo { height: 64px; width: auto; margin-bottom: 12px; }
.cbm-nv-panel__featured-name { font-family: var(--cbm-font-body); font-weight: 700; font-size: 18px; margin: 0 0 8px; }
.cbm-nv-panel__featured-copy p { font-size: 14px; line-height: 1.6; color: var(--cbm-body-grey); margin: 0 0 14px; }
.cbm-nv-panel__featured-copy .cbm-btn { margin-bottom: 14px; }
.cbm-nv-panel__featured-credit { font-size: 11px; color: var(--cbm-muted-grey); margin: 0; }
@media (max-width: 640px) {
	.cbm-nv-panel__featured-body { grid-template-columns: 1fr; }
}
.cbm-nv-panel__howto p { font-size: 14px; line-height: 1.6; color: var(--cbm-body-grey); margin: 0; }

/* "Search the Index" scope choice — shown after Enter/the arrow button is
   used, before the search actually runs, so the visitor picks whether to
   stay within New Vehicles or search every pillar. See new-vehicles.js. */
.cbm-nv-search-scope-choice { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; padding: 10px; border: 1px solid var(--cbm-hairline); border-radius: 2px; background: #fff; }
.cbm-nv-search-scope-choice[hidden] { display: none; }
.cbm-nv-search-scope-choice__prompt { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; color: #333; margin: 0; }
.cbm-nv-search-scope-choice__btn {
	width: 100%; box-sizing: border-box; padding: 8px; border-radius: 2px; border: 1px solid var(--cbm-hairline);
	background: #fff; color: #333; font-size: 13px; font-weight: 700; cursor: pointer; text-align: center;
}
.cbm-nv-search-scope-choice__btn:hover { background: var(--cbm-fill-light); }
.cbm-nv-search-scope-choice__btn--red { background: var(--cbm-red); border-color: var(--cbm-red); color: #fff; }
.cbm-nv-search-scope-choice__btn--red:hover { background: var(--cbm-red-hover); }

.cbm-nv-sidebar { display: flex; flex-direction: column; gap: 16px; }
/* Merged into one card (2026-09-07) — "Be Featured" is no longer its own
   clickable link (no self-service purchase flow exists for it), so it's
   now the header of the same card as the real contact route beneath it,
   not a separate element floating above it. */
.cbm-nv-sidebar__featured { border: 1px solid var(--cbm-hairline); border-radius: 2px; overflow: hidden; }
.cbm-nv-sidebar__featured-btn {
	background: var(--cbm-green); color: #fff; font-weight: 700; font-size: 13px; letter-spacing: 0.01em;
	text-transform: uppercase; text-align: center; padding: 14px 8px; display: block;
}
.cbm-nv-sidebar__contact { padding: 18px; text-align: center; }
.cbm-nv-sidebar__contact-label { font-family: var(--cbm-font-body); font-size: 16px; color: #555; }
.cbm-nv-sidebar__contact-phone {
	display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 8px;
	font-family: var(--cbm-font-mono); font-weight: 700; font-size: 17px; color: var(--cbm-red);
}
.cbm-nv-sidebar__contact-phone span {
	width: 26px; height: 26px; border-radius: 50%; background: var(--cbm-green); color: #fff;
	display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-family: initial;
}
.cbm-nv-sidebar__contact-email { font-size: 16px; color: #555; margin-top: 8px; }
.cbm-nv-sidebar__steps { background: #1A1A1A; color: #fff; border-radius: 2px; padding: 20px; }
.cbm-nv-sidebar__steps-title { font-family: var(--cbm-font-body); font-weight: 700; font-size: 17px; text-align: center; margin-bottom: 16px; }
.cbm-nv-sidebar__step { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; font-size: 13px; }
.cbm-nv-sidebar__step-num {
	width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
	font-size: 12px; font-weight: 700; flex-shrink: 0;
}
.cbm-nv-sidebar__steps-cta { display: block; background: var(--cbm-green); color: #fff; font-weight: 700; font-size: 13px; text-align: center; padding: 10px; border-radius: 2px; margin-top: 4px; }

@media (max-width: 1024px) {
	.cbm-nv-hero-grid { grid-template-columns: 1fr; }
	.cbm-nv-hero-adspace { aspect-ratio: auto; }
}
@media (max-width: 640px) {
	.cbm-nv-panel__buttons { grid-template-columns: 1fr; }
}

/* "New [Type] Showroom" page (template-new-vehicles-search.php) — the
   manufacturers-directory + search section below the intro textwrap block.
   Two-thirds/one-third split, per spec (not the 3fr/1fr the hub page above
   uses — deliberately different, matched to what was actually asked for
   here). The manufacturer grid reuses no card component (logos vary wildly
   in aspect ratio) — each item is just a stacked logo + name, contained to
   a fixed max-height so a very tall/wide logo can't blow out the row. */
/* minmax(0, Nfr), not a bare Nfr — without the 0 floor, a grid track's
   default min-width:auto lets any child's intrinsic content (the Featured
   Manufacturer panel's own nested grid, in practice — see
   .cbm-nv-panel__featured-body below) force this column wider than its fair
   share, overflowing .cbm-container's 1174px margin on the right rather
   than wrapping/shrinking to fit it. Confirmed live, 2026-08-26: the aside
   column (and the skyscraper ad inside it) was rendering ~135px past the
   page's true right margin before this fix — same class of bug as
   .cbm-topbar's grid tracks (see layout.css), just a different page. */
/* Three columns (2026-09-07, was two -- Featured Manufacturer sat in a
   full-width block above this row until Jonathan's sketch showed it as
   its own left-hand column instead): Featured | manufacturer list | ad.
   Ad column fixed to the skyscraper's own 160px so it doesn't stretch
   past its true reference size; Featured and the list share the rest
   equally. */
/* 7fr:3fr (2026-09-07, was equal 1fr:1fr) -- per Jonathan, after seeing
   the narrowed manufacturer list leave a gap before the ad: "It needs to
   be ranged right and the Featured Manufacturer element takes all the
   remaining space to the left of it as far as the left margin." Narrowing
   the list via the grid track itself (rather than a width on the item
   inside an unchanged-width track, the previous approach) means the list
   column IS exactly as wide as the bars need to be -- flush against the
   ad with no leftover gap -- while Featured's column grows to take
   everything else. 7:3 reproduces the same list width as the previous
   "reduce 40%" pass (list was 60% of a 1fr:1fr half-share = 30% of the
   flexible total; Featured is the remaining 70%), just positioned
   correctly instead of stranded in the middle of an oversized column. */
.cbm-nvs-columns { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 3fr) 160px; gap: 32px; align-items: start; margin-top: 32px; }
/* Featured Manufacturer's own .cbm-nv-panel__featured-body is a 2-column
   grid (photo left, copy right) everywhere else it's used, but that's too
   wide a layout for this column's narrower share of the page -- stacked
   vertically instead (photo, then logo/name/copy beneath), matching
   Jonathan's sketch (IMAGE, NAME, IMAGE, DESCRIPTION top to bottom).
   Scoped to this column only, not a global change to the shared class. */
.cbm-nvs-col-featured .cbm-nv-panel__featured-body { grid-template-columns: 1fr; }
/* No longer directly below the manufacturer grid in the same column (that
   spacing need is gone now it's a separate column) -- the extra top
   margin was redundant with .cbm-nvs-columns' own margin-top:32px above. */
.cbm-nvs-col-featured .cbm-nv-panel__featured { margin-top: 0; }
/* Manufacturer directory - redrawn 2026-08-26 from the user's own sketch:
   bordered horizontal "bar" rows (name left, logo right), three columns,
   alphabetical top-to-bottom *within* each column (i.e. column 1 gets the
   first third of the alphabet, column 2 the next third, and so on) rather
   than a left-to-right reading order across a row. CSS multi-column is
   exactly this fill behaviour natively - no JS/PHP chunking needed, the
   items just need to already be in alpha order in the DOM (they are, from
   the already-sorted $page_manufacturers list). break-inside: avoid on each
   item stops the browser splitting a single bar across the column break. */
/* Forced to a single column always (2026-09-07, was a responsive 3/2/1
   grid) -- per Jonathan: "the List of Manufacturers to be displayed in a
   column to the left of the ad space." Sits in .cbm-nvs-col-main, which
   the .cbm-nvs-columns grid already places to the left of .cbm-nvs-col-aside
   (the skyscraper), so a single column here is all that was needed to
   satisfy "to the left of the ad space" -- no separate positioning
   required. Already alpha order via $page_manufacturers, derived from the
   already-sorted $rows (see the usort() near the top of the template). */
/* Narrowed via the .cbm-nvs-columns grid track itself now (7fr:3fr,
   2026-09-07), not a width on this element -- superseded the original
   width:60% approach, which left the narrowed bars stranded with a gap
   before the ad rather than flush against it (see the grid comment
   above for the full story). Filling 100% of its own (now correctly
   narrow) column puts the bars flush right against the ad naturally,
   with no separate alignment rule needed. */
.cbm-nvs-mfr-grid { columns: 1; margin-bottom: 32px; }
/* min-height, not just padding, because bar height was otherwise
   content-dependent - a manufacturer with no logo (a plain text row) or a
   very wide/flat logo (shrunk below the 28px max-height by its own aspect
   ratio once max-width:90px kicks in) collapsed to a shorter natural height
   than a bar with a taller logo, so the columns didn't line up as same-size
   bars despite identical padding. Fixed at 28px logo + 2x8px padding, so
   every bar is this height regardless of what (if anything) fills it. */
.cbm-nvs-mfr-item {
	display: flex; align-items: center; justify-content: space-between; gap: 10px;
	border: 1px solid var(--cbm-hairline); border-radius: 2px; padding: 8px 12px;
	min-height: 44px; box-sizing: border-box;
	margin-bottom: 8px; break-inside: avoid;
	text-decoration: none; color: var(--cbm-near-black);
}
/* height: auto is required, not decorative - SVG logo attachments (used
   by several manufacturers with vector-only brand marks) get width="1"
   height="1" baked into their <img> HTML attributes because WordPress
   core can't read SVG intrinsic dimensions, and without an explicit
   `height` declaration here the browser honours that 1px attribute as
   the rendered height (max-height alone doesn't override it), shrinking
   the whole logo to a sliver. PNG/JPG logos already carry correct
   attributes so this is a no-op for them. Width is the real constraint in
   the bar layout (logos sit beside text, not above it), so max-width is
   tighter here than the old stacked-tile layout's max-height was. */
.cbm-nvs-mfr-item__logo { display: block; height: auto; max-height: 28px; width: auto; max-width: 90px; object-fit: contain; flex-shrink: 0; }
/* nowrap + ellipsis, not just a smaller font, so a long name can never grow
   a bar taller than the rest (happened to "Yutong (Pelican Bus & Coach)",
   the one manufacturer title cbm_new_vehicle_short_manufacturer_name()
   doesn't shorten, since its importer clause uses different wording than
   the "(imported to ...)" pattern that function targets) - truncating
   handles any future long name too, not just this one. min-width: 0
   overrides flexbox's default min-width:auto on flex children, which would
   otherwise refuse to shrink the name below its full text width and defeat
   the ellipsis entirely. */
.cbm-nvs-mfr-item__name {
	font-size: 13px; font-weight: 600; line-height: 1.3; text-align: left;
	white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
}
@media (max-width: 900px) {
	.cbm-nvs-columns { grid-template-columns: 1fr; }
}

/* Skyscraper ad slot (new_vehicles_showroom_skyscraper), sat below the
   search box in the page's right-hand column - same 298:600 aspect-ratio
   convention as the New Vehicles hub page's own hero ad space
   (.cbm-nv-hero-adspace above), so an ad creative sized for one slot works
   in the other without cropping. */
/* Resized to match the MHP's own true 160x600 skyscraper (2026-09-07,
   .cbm-mhp2-tbf-skyscraper in components.css) — per Jonathan: "the
   skyscraper ad box to be same shape as mhp skyscraper." Supersedes the
   2026-08-26 decision to keep this slot at 298:600 (a provisional call at
   the time, noted then as worth revisiting — this is that revisit).
   Flat width, not left to stretch to the aside column's own width, so the
   ad renders at its true reference size rather than blown up.
   max-width:100% keeps it from overflowing a column narrower than 160px. */
.cbm-nvs-skyscraper { aspect-ratio: 160 / 600; width: 160px; max-width: 100%; margin-top: 24px; }
.cbm-nvs-skyscraper .cbm-ad-empty-slot {
	display: flex; align-items: center; justify-content: center; height: 100%;
	background: var(--cbm-fill-light); border: 1px dashed var(--cbm-muted-grey); border-radius: 2px;
}
@media (max-width: 900px) {
	.cbm-nvs-skyscraper { aspect-ratio: auto; width: 100%; min-height: 250px; }
}

/* Manufacturer Page's own vehicle grid (single-manufacturer.php) — separate
   page from the hub above, unaffected by this rebuild. */
.cbm-nv-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--cbm-gap); }
@media (max-width: 1024px) { .cbm-nv-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .cbm-nv-grid { grid-template-columns: 1fr; } }
.cbm-nv-card { display: flex; flex-direction: column; border: 1px solid var(--cbm-hairline); border-radius: var(--cbm-radius); overflow: hidden; background: #fff; color: var(--cbm-near-black-alt); }
.cbm-nv-card__media { position: relative; display: block; aspect-ratio: 16/10; background: linear-gradient(135deg,#dcdcdc,#c2c2c2); }
.cbm-nv-card__media img { width: 100%; height: 100%; object-fit: cover; }
.cbm-cbw-tested { position: absolute; top: 10px; left: 10px; background: var(--cbm-green); color: #fff; font-size: 10px; font-weight: 700; letter-spacing: 0.05em; padding: 4px 8px; border-radius: 2px; }
/* B/C/M vehicle-type marker (cbm_new_vehicle_type_marker()) — top-right so
   it doesn't collide with the CBW-Tested badge (top-left) or the "Related"
   search badge (also top-left). */
.cbm-nv-type-marker {
	position: absolute; top: 10px; right: 10px; z-index: 1; background: var(--cbm-near-black);
	color: #fff; font-family: var(--cbm-font-mono); font-size: 11px; font-weight: 700;
	width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
}
.cbm-nv-card__body { padding: 14px 16px 16px; }
.cbm-nv-card__manufacturer { display: block; font-family: var(--cbm-font-mono); font-size: 10px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--cbm-muted-grey); }
.cbm-nv-card__title { display: block; font-family: var(--cbm-font-body); font-weight: 600; font-size: 16px; margin-top: 2px; }
.cbm-nv-card__meta { display: block; font-size: 12px; color: var(--cbm-muted-grey); margin-top: 8px; }
.cbm-nv-card__tco { display: flex; justify-content: space-between; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--cbm-hairline); font-size: 11px; color: var(--cbm-muted-grey); }
.cbm-nv-card__tco strong { font-family: var(--cbm-font-mono); color: var(--cbm-near-black-alt); }

/* Category switcher on the New Vehicles Search Results page — lets a
   visitor pivot between Buses/Coaches/Minibuses/All without going back to
   the homepage's FIND VEHICLES selector. */
/* Absolutely positioned against .cbm-textwrap__inner (it's now nested
   inside that container in the template, not a sibling after it) so its
   BOTTOM edge lines up with the photo's bottom edge - per the user
   (2026-08-26): "bottom of pill to line up with bottom of image" (an
   earlier pass aligned the nav's top edge to the image's bottom instead,
   which put the whole nav below the image rather than beside it; this
   corrects that). left matches where the wrapped text column starts (360px
   image width + 3em side gap, matching .cbm-textwrap--photo's own
   --cbm-tw-ad-width/--cbm-tw-ad-gap-side in components.css) - not done via
   a shared CSS variable, since custom properties scoped to .cbm-textwrap
   don't cascade to this nav the way inheritance would if it were a plain
   descendant; hardcoded to match instead, so if the photo's size changes
   again, update both together. Sits in the vertical space beside the lower
   part of the photo, below where the wrapped paragraph text currently ends
   - safe as long as that text stays short enough not to reach this deep
   into the wrap zone; if the paragraph is later lengthened, re-check this
   doesn't start overlapping it. */
/* Wraps the category switcher + inline search box as one row, absolutely
   positioned at the bottom of the intro's text-wrap area -- same left
   offset the switcher always used (ad-box width + side gap). Search box
   moved here from the aside column (2026-09-07), per Jonathan: "move the
   SEARCH box up to close the white space and sit adjacent to ALL, BUSES,
   COACHES, MINIBUSES. That will bring the ad box back to visibility" --
   fills the dead space that used to sit to the right of the switcher on
   wider screens, and leaves the skyscraper as the aside column's only
   occupant so it now sits at the very top of that column. */
.cbm-nv-search-and-switch {
	position: absolute; bottom: 0; left: calc(360px + 3em); right: 0;
	display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.cbm-nv-search-switch { display: flex; gap: 8px; flex-wrap: wrap; }
.cbm-nv-inline-search {
	display: flex; align-items: stretch; height: 35px; flex: 0 1 260px; min-width: 170px;
	background: var(--cbm-red); border-radius: 999px; overflow: hidden;
}
/* Red box, white letters (2026-09-07, was white box/red text) -- per
   Jonathan: "the Search All New Vehicles box to the right has become
   just white with red letters, please display it as a red box with
   white letters." transparent background lets the pill's own red
   (.cbm-nv-inline-search above) show straight through instead of the
   input painting over it with white. Same fix applied to
   .cbm-nv-panel__search-deep below (the New Vehicles hub's own search
   box), per "same wherever it displays on the site." */
.cbm-nv-inline-search input {
	flex: 1; min-width: 0; border: none; background: transparent; padding: 0 14px; font-size: 13px;
	font-weight: 400; letter-spacing: normal; text-transform: none; color: #fff; outline: none;
}
/* "SEARCH VEHICLES" (2026-09-07, was "Search all new vehicles...") --
   per Jonathan: "should instead just read SEARCH VEHICLES in caps."
   Caps applied here on the placeholder only (text-transform:uppercase),
   not on the input's own real value (still text-transform:none above) --
   so this reads as a caps CTA label at rest, but doesn't force-uppercase
   whatever a visitor actually types into the field. */
.cbm-nv-inline-search input::placeholder { color: #fff; opacity: 1; text-transform: uppercase; letter-spacing: 0.03em; }
.cbm-nv-inline-search button {
	flex: 0 0 auto; width: 38px; display: flex; align-items: center; justify-content: center;
	border: none; background: transparent; cursor: pointer;
}
/* Below 900px there isn't enough room beside the wrap-around ad box for
   this row (pills + search) without colliding with the wrapped paragraph
   text above it -- confirmed live at ~766px width, a pre-existing gap in
   the switcher's own absolute positioning that adding the search box
   alongside it made more visible (taller wrapped row = more overlap).
   Dropped out of the absolute/floated layout entirely at this page's own
   existing column breakpoint (.cbm-nvs-columns also switches to 1fr at
   900px) rather than picking a new one, and cleared so it drops below the
   wrapped text/floated ad box instead of overlapping it. */
@media (max-width: 900px) {
	.cbm-nv-search-and-switch {
		position: static; clear: both; flex-direction: column; align-items: stretch; margin-top: 16px; left: auto; right: auto;
	}
	.cbm-nv-inline-search { flex: 0 0 auto; width: 100%; margin-top: 8px; }
}
.cbm-nv-search-switch a {
	font-family: var(--cbm-font-body); font-weight: 700; font-size: 13px; letter-spacing: 0.03em;
	padding: 7px 16px; border-radius: 999px; border: 1px solid var(--cbm-hairline);
	color: var(--cbm-near-black-alt); text-decoration: none; text-transform: uppercase;
}
.cbm-nv-search-switch a:hover { border-color: var(--cbm-red); color: var(--cbm-red); }
.cbm-nv-search-switch a.is-active { background: var(--cbm-red); border-color: var(--cbm-red); color: #fff; }

/* "New" badge (2026-09-07) -- small red pill marking the New Vehicle
   Index as genuinely new, per Jonathan after the "for years" copy fix:
   "New badge would be interesting to see how that looks." Same red-pill
   visual language as .cbm-nv-search-switch a.is-active just above (solid
   CBM red, white text, pill radius) rather than inventing a new look --
   this is the first "new" badge on the site, so it sets the convention
   for any future one rather than following an existing badge component
   (the vehicle-card view-count badge is a different, dark/translucent
   style meant to overlay a photo, not a fit here). Reusable wherever
   else something genuinely new needs flagging, not scoped to this one
   spot. */
/* display:inline, not inline-block (2026-09-07 fix) -- Jonathan: "Badge
   still stopping second line of text from being full width" even after
   the badge's own box was set to exactly 21px. Root cause: an
   inline-block sized to exactly match the line-height can still inflate
   the surrounding LINE BOX by a sub-pixel amount when paired with
   vertical-align:middle (a known browser quirk -- the line box has to
   accommodate the inline-block's centred position relative to the
   font's own ascent/descent, which isn't guaranteed to net to zero extra
   space just because the box height matches). Measured live: line 1 (the
   badge's own line) was landing 22px below the text's true baseline
   step, while every line after it was a clean, consistent 21px -- proof
   the badge specifically was still the cause, not the text-wrap
   component's math in general. A plain inline element can't inflate the
   line box the same way -- it just contributes its own font metrics to
   the line like any other text run, so no vertical-align is needed or
   used here. */
.cbm-badge { display: inline; }
/* line-height:21px, not the ratio-based 1.5em its own 11px font-size
   would compute (16.5px) -- must match the SURROUNDING paragraph's real
   line-height exactly (14px x 1.5, this page's known --cbm-textwrap font
   size), not its own smaller font's ratio, or the badge renders taller
   than one text line. Found live (2026-09-07): badge was 22.5px against
   the paragraph's 21px, and that 1.5px overshoot alone was enough to
   throw off the text-wrap component's fixed-line-count wrap math (see
   the text-wrap-around-fixed-element skill) -- Jonathan: "the pill is
   deeper than one text line... causing the second line to wrap around
   the box and an odd white space under the title." Padding is
   horizontal-only now; line-height alone sets the vertical size and
   centers the text within it. */
.cbm-badge--new {
	background: var(--cbm-red); color: #fff;
	font-family: var(--cbm-font-body); font-weight: 700; font-size: 11px; letter-spacing: 0.06em;
	text-transform: uppercase; padding: 0 10px; line-height: 21px; border-radius: 999px; margin-right: 4px;
}

.cbm-manufacturer-header { display: flex; align-items: center; gap: 20px; padding-block: 24px 20px; }
.cbm-manufacturer-header img { max-height: 60px; }

/* Consistent manufacturer-logo slot (2026-09-10): a fixed-height band
   directly under the sitewide header row, so a page with a logo and a
   page without it open at exactly the same height and nothing jumps.
   The title itself is in the header row now, not here. */
.cbm-manufacturer-logo-slot { min-height: 90px; display: flex; align-items: center; margin-bottom: 20px; }
/* height:auto too - WordPress writes width="1" height="1" on SVG images (no size metadata), which shrank an SVG logo to 2px (found on ADL, 2026-09-28). */
.cbm-manufacturer-logo-slot__img { max-height: 84px; width: auto; height: auto; }
.cbm-manufacturer-logo-slot { padding-bottom: 20px; border-bottom: 1px solid var(--cbm-hairline); }

/* Scoped 30% larger showroom image for the manufacturer intro textwrap
   (2026-09-14, per Jonathan) — overrides .cbm-textwrap--photo's base
   360x132 box just for this context, so the New Vehicles Search page's
   own use of --photo (template-new-vehicles-search.php) is untouched. */
.cbm-manufacturer-textwrap { --cbm-tw-ad-width: 468px; --cbm-tw-ad-height: 172px; --cbm-tw-ad-gap-top: 1.5em; }
/* The base sitewide +4px buffer isn't enough here: line 1 ends only
   ~9px before the +4px exclusion boundary, not a full line-height short
   of it, so a genuine second line never has room to clear before
   exclusion kicks in - it gets swallowed into wrapping beside the image
   instead of rendering above it (confirmed via an actual screenshot,
   2026-09-15, not just DOM measurement - see project memory on the
   Browser pane's screenshot-resolution limits). +16px gives a full
   line-height of headroom past line 2's natural end. */
.cbm-manufacturer-textwrap .cbm-textwrap__float {
	shape-outside: inset( calc( ( var(--cbm-tw-lines) * 1.5em ) + 16px ) 0 0 0 );
}

/* CONTACT ME / VISIT WEBSITE float right inside the textwrap so the intro
   text wraps around both the buttons (top) and the photo (2026-09-15,
   Jonathan). Scoped to the manufacturer textwrap only - the shared
   sitewide .cbm-supplier-actions block style (dealer/directory pages)
   stays untouched. */
.cbm-manufacturer-textwrap .cbm-supplier-actions {
	/* Plain float, no shape-outside exemption - unlike the image, the
	   buttons should visually sit at the top from line 1, so text wraps
	   around them immediately. An earlier attempt gave the buttons the
	   same 2-line exemption as the image, which made text ignore the
	   buttons for those lines while the buttons were still visually
	   there - text rendered straight through/behind them. The image's
	   own 2-line exemption is what should be exempt from the buttons too
	   (see .cbm-textwrap__float below), not the other way round. */
	float: right; width: auto; padding: 0 0 20px 24px;
}
@media (max-width: 640px) {
	.cbm-manufacturer-textwrap .cbm-supplier-actions { float: none; width: 100%; padding: 20px 0; }
}

/* Address/phone shown alongside the CONTACT ME / VISIT WEBSITE button
   pair (2026-09-14) — right-aligned to sit with that button column. */
/* Moved to the foot of the page as a notional footer (2026-09-15,
   Jonathan) so the top of the page leads with CONTACT ME + the showroom
   photo instead of contact details. */
.cbm-manufacturer-contact-details {
	text-align: left; margin-top: 28px; padding-top: 16px;
	border-top: 1px solid var(--cbm-hairline);
	font-size: 13px; color: var(--cbm-muted-grey); line-height: 1.5;
}
/* Standard (bare) pages show address/phone right under the title
   instead - no footer border/margin, matches the CBW Standard Entry
   reference exactly (Jonathan, 2026-09-15). */
.cbm-manufacturer-contact-details--standard {
	margin-top: 8px; padding-top: 0; border-top: none;
	font-size: 15px; color: var(--cbm-body-grey);
}
.cbm-manufacturer-contact-details p { margin: 2px 0; }

/* Two sample "on test" video boxes below the intro text (2026-09-14) —
   reuses .cbm-video-test as-is (already flex:1, no fixed width). */
.cbm-manufacturer-videos { display: flex; gap: var(--cbm-gap); margin-top: 28px; }
.cbm-manufacturer-gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--cbm-gap); margin-top: 24px; }
.cbm-manufacturer-gallery img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: 2px; border: 1px solid var(--cbm-hairline); display: block; }
/* Small boundary is the DEFAULT for every image on this page (hero,
   inline, gallery) - Jonathan, 2026-09-15: "generally (default) all
   images should have a small boundary around them", with abutting
   (montage-style, no border/gap) reserved for a deliberate exception,
   not the default. Same border/radius values as the gallery above, on
   the two other image contexts, so all three read as one consistent
   treatment rather than three separately-tuned ones. */
.cbm-textwrap__ad img, .cbm-textwrap__text .wp-block-image img, .cbm-manufacturer-second-image img {
	border-radius: 2px; border: 1px solid var(--cbm-hairline);
}
/* Own clean block, guaranteed clear of both floats (see single-
   manufacturer.php) - just needs standard top spacing, same rhythm as
   the gallery/video sections below it. */
.cbm-manufacturer-second-image { margin: 24px 0 0; }
@media (max-width: 1024px) { .cbm-manufacturer-gallery { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .cbm-manufacturer-gallery { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
	.cbm-manufacturer-videos { flex-direction: column; }
}
/* Standard-tier manufacturer pages often have nothing but a logo and a
   model or two — this keeps that state reading as a deliberate, tidy
   design rather than bare unstyled HTML, without inventing a separate
   "standard" template. Richer manufacturers get the same treatment, it
   just has more to hold. */
.cbm-manufacturer-intro {
	font-size: 15px; line-height: 1.65; color: var(--cbm-body-grey);
	max-width: 640px; margin-top: 20px;
}
.cbm-vehicles-empty {
	text-align: center; color: var(--cbm-muted-grey); font-size: 14px;
	padding: 32px 20px; border: 1px dashed var(--cbm-hairline); border-radius: var(--cbm-radius);
}

/* "Compare Vehicles" (2026-09-06) — V1 of the whole-life-cost/margin
   comparison tool, see project memory
   "cbm_vehicle_cost_comparison_tool_plan". Just a spec table for now. */
.cbm-nv-compare { margin: 40px auto 56px; }
.cbm-nv-compare__heading { font-family: var(--cbm-font-heading); font-size: 26px; font-weight: 700; margin: 0 0 6px; }
.cbm-nv-compare__intro { color: var(--cbm-body-grey); font-size: 14px; margin: 0 0 20px; max-width: 68ch; }
/* Prominent jump link to the side-by-side section (2026-09-08) -- see
   the PHP comment in template-vehicle-type-all.php for why this exists.
   Deliberately a real bordered/tinted callout, not a plain inline text
   link -- a small link here would repeat the same \"easy to miss\"
   problem this is meant to solve, just moved higher up the page. */
.cbm-nv-compare__also {
	display: inline-flex; align-items: center; gap: 10px;
	background: var(--cbm-fill-light); border: 1px solid var(--cbm-hairline); border-left: 3px solid var(--cbm-red);
	border-radius: var(--cbm-radius); padding: 10px 16px; margin: 0 0 24px;
	text-decoration: none; transition: background 0.15s, border-color 0.15s;
}
.cbm-nv-compare__also:hover { background: #fff; border-color: var(--cbm-red); }
.cbm-nv-compare__also-label {
	font-family: var(--cbm-font-body); font-weight: 700; font-size: 10px; letter-spacing: 0.08em;
	text-transform: uppercase; color: var(--cbm-red); white-space: nowrap;
}
.cbm-nv-compare__also-text { font-size: 14px; font-weight: 600; color: var(--cbm-near-black); }
#compare-side-by-side { scroll-margin-top: 120px; }
.cbm-nv-compare__form { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 0 0 24px; }
.cbm-nv-compare__select {
	flex: 1 1 220px; max-width: 320px; padding: 9px 32px 9px 12px; border: 1px solid var(--cbm-hairline);
	border-radius: var(--cbm-radius); font-size: 13px; font-family: var(--cbm-font-body); background: #fff;
	color: var(--cbm-near-black-alt); appearance: none; cursor: pointer;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath fill='%23454b54' d='M0 0l5 6 5-6z'/%3E%3C/svg%3E");
	background-repeat: no-repeat; background-position: right 12px center; background-size: 9px;
}
.cbm-nv-compare__select:hover { border-color: var(--cbm-red); }
.cbm-nv-compare__table-wrap { overflow-x: auto; border: 1px solid var(--cbm-hairline); border-radius: var(--cbm-radius); }
.cbm-nv-compare__table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 560px; }
.cbm-nv-compare__table th, .cbm-nv-compare__table td { text-align: left; padding: 10px 16px; border-bottom: 1px solid var(--cbm-hairline); vertical-align: top; }
.cbm-nv-compare__table thead th {
	font-family: var(--cbm-font-body); font-weight: 700; background: var(--cbm-fill-light);
	color: var(--cbm-near-black); font-size: 14px;
}
.cbm-nv-compare__table tbody th {
	font-weight: 600; color: var(--cbm-body-grey); white-space: nowrap; background: var(--cbm-fill-lighter, #fafafa);
}
.cbm-nv-compare__table tbody tr:last-child th, .cbm-nv-compare__table tbody tr:last-child td { border-bottom: none; }
.cbm-nv-compare__option { display: block; color: var(--cbm-muted-grey); font-size: 12px; margin-top: 2px; }
.cbm-nv-compare__tested { color: var(--cbm-green, #1a7a4c); font-weight: 700; }
.cbm-nv-compare__hint { color: var(--cbm-body-grey); font-size: 13px; font-style: italic; }
@media (max-width: 640px) {
	.cbm-nv-compare__form { flex-direction: column; align-items: stretch; }
	.cbm-nv-compare__select { max-width: none; }
}

/* Entry-point prompt into the dedicated Compare Vehicles tool (2026-09-07)
   — see template-new-vehicles-search.php. Deliberately a full-width,
   solid strip: it needs to read as a real, permanent fixture on the
   page, not a quiet inline link easy to scroll past. */
.cbm-nv-compare-prompt {
	display: block; background: var(--cbm-red); color: #fff; text-align: center;
	font-family: var(--cbm-font-body); font-weight: 700; font-size: 15px; letter-spacing: 0.01em;
	padding: 14px 20px; border-radius: var(--cbm-radius); text-decoration: none; margin: 16px 0 0;
	transition: background 0.15s;
}
.cbm-nv-compare-prompt:hover { background: var(--cbm-red-hover); color: #fff; }

/* Extra elements added to the Compare Vehicles tool page itself
   (page-templates/template-vehicle-type-all.php) beyond what V1's own
   picker (template-new-vehicles.php) already styled. */
.cbm-nv-compare__actions { display: flex; gap: 10px; margin: 14px 0 24px; }
.cbm-nv-compare__alt-prompt {
	background: var(--cbm-fill-light); border: 1px dashed var(--cbm-hairline); border-radius: var(--cbm-radius);
	padding: 18px 20px; text-align: center; margin: 0 0 32px;
}
.cbm-nv-compare__alt-prompt p { margin: 0 0 10px; font-weight: 600; }
.cbm-nv-compare__alts { margin: 0 0 32px; }
.cbm-nv-compare__alts h3 { font-family: var(--cbm-font-body); font-size: 17px; margin: 0 0 10px; }
.cbm-nv-compare__alts h4 { font-family: var(--cbm-font-body); font-size: 14px; color: var(--cbm-body-grey); margin: 12px 0 8px; }

@media print {
	.cbm-nav, .cbm-back-wrap, .cbm-nv-compare__form, .cbm-nv-compare__actions,
	.cbm-nv-compare__alt-prompt, footer, .cbm-nv-sidebar { display: none !important; }
	.cbm-nv-compare__print-target { break-inside: avoid; }
}

/* The branded "CBM Comparison Tool" entry prompt (2026-09-07) — shown on
   New Vehicle model pages, manufacturer pages, category search results,
   and Used/Rental ad pages, via cbm_render_compare_tool_prompt() in
   inc/new-vehicles.php. CBM-red branded per Jonathan, with copy above
   the button describing what it delivers, not a plain link. */
/* Redesigned 2026-09-08 -- per Jonathan: "the Comparison tool box design
   is weak... wonder if we can improve it to look stronger, like a tool
   should." Was a plain white card with a thin hairline border and a
   4px red top accent -- functional but flat, no visual identity of its
   own. Now a dark instrument-panel card (its own distinct surface,
   not just white-on-white with the page) with a red top accent stripe,
   an icon badge, and a pill CTA with real depth (shadow, hover lift) --
   reads as a genuine product/tool, not a text callout with a button
   under it. Same markup, same two variants (full + --compact), just
   restyled. (An icon badge was added and then removed the same day --
   Jonathan: "the badge doesn't relate to anything CBM" -- so this stays
   icon-free; the strength comes from the dark card + stripe + pill CTA
   alone.)
*/
.cbm-compare-prompt {
	background: linear-gradient(155deg, #1c1c1e 0%, #2d2d30 100%);
	border: none; border-radius: var(--cbm-radius); padding: 28px 24px; margin: 20px 0;
	text-align: center; position: relative; overflow: hidden;
	box-shadow: 0 10px 28px rgba(0,0,0,0.22);
}
.cbm-compare-prompt::before {
	content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
	background: linear-gradient(90deg, var(--cbm-red), #ff7a7a);
}
.cbm-compare-prompt__label {
	font-family: var(--cbm-font-body); font-weight: 700; font-size: 12px; letter-spacing: 0.08em;
	text-transform: uppercase; color: #ff8f8f; margin-bottom: 4px;
}
.cbm-compare-prompt__title {
	font-family: var(--cbm-font-heading); font-weight: 700; font-size: 22px; color: #fff; margin-bottom: 8px;
}
.cbm-compare-prompt__body { font-size: 14px; color: rgba(255,255,255,0.72); max-width: 56ch; margin: 0 auto 16px; }
.cbm-compare-prompt__cta {
	display: inline-flex; align-items: center; gap: 6px;
	background: var(--cbm-red); color: #fff; font-family: var(--cbm-font-body);
	font-weight: 700; font-size: 14px; letter-spacing: 0.02em; text-transform: uppercase;
	padding: 12px 26px; border-radius: 999px; text-decoration: none;
	box-shadow: 0 6px 16px rgba(216,30,37,0.4);
	transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}
.cbm-compare-prompt__cta:hover {
	background: var(--cbm-red-hover); color: #fff; transform: translateY(-1px);
	box-shadow: 0 8px 20px rgba(216,30,37,0.5);
}

/* Tool page's own heading, matching the same "CBM Comparison Tool" /
   "Find Your Vehicle Options" naming, plus the optional spec filters. */
.cbm-nv-compare__label {
	font-family: var(--cbm-font-body); font-weight: 700; font-size: 12px; letter-spacing: 0.08em;
	text-transform: uppercase; color: var(--cbm-red); margin-bottom: 4px;
}
.cbm-nv-compare__filters {
	display: flex; flex-wrap: wrap; gap: 14px; margin: 4px 0 16px; padding: 14px 16px;
	background: var(--cbm-fill-light); border-radius: var(--cbm-radius);
}
.cbm-nv-compare__filter {
	flex: 1 1 180px; display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 600; color: var(--cbm-body-grey);
}
.cbm-nv-compare__filter input, .cbm-nv-compare__filter select {
	padding: 8px 10px; border: 1px solid var(--cbm-hairline); border-radius: 2px; font-size: 13px; font-family: var(--cbm-font-body);
}

/* "Find Matches" search — conditions checkboxes, age-cap select, and the
   secondary "compare specific vehicles" section (2026-09-07). */
.cbm-nv-compare__conditions {
	display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin: 14px 0;
	padding: 12px 16px; background: var(--cbm-fill-light); border-radius: var(--cbm-radius);
}
.cbm-nv-compare__conditions-label { font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--cbm-body-grey); }
.cbm-nv-compare__condition { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; cursor: pointer; }
.cbm-nv-compare__condition input { width: 16px; height: 16px; cursor: pointer; }
.cbm-nv-compare__filter--age { max-width: 320px; margin: 0 0 16px; }
.cbm-nv-compare__results { margin: 20px 0 8px; }
.cbm-nv-compare__secondary {
	margin-top: 40px; padding-top: 28px; border-top: 2px solid var(--cbm-hairline);
}
.cbm-nv-compare__secondary-title { font-family: var(--cbm-font-body); font-size: 18px; font-weight: 700; margin: 0 0 14px; }

/* "Comparison Tool" jump link in the panel heading (2026-09-07) — per
   Jonathan: "make sure that visitors easily find the tool rather than
   hoping they make it to the bottom of the page." scroll-margin-top
   keeps the jump target clear of the sticky header. */
.cbm-nv-panel__heading-link { color: var(--cbm-red); text-decoration: underline; }
.cbm-nv-panel__heading-link:hover { color: var(--cbm-red-hover); }
#compare-tool { scroll-margin-top: 120px; }

/* Compact variant of the comparison-tool prompt (2026-09-07) — sized to
   sit inside the existing .cbm-textwrap__ad box (360px wide) as a real
   side box, rather than the full-width block .cbm-compare-prompt is
   elsewhere. See template-new-vehicles-search.php. */
.cbm-compare-prompt--compact {
	/* Real bug found live (2026-09-07): the base .cbm-compare-prompt rule
	   has margin:20px 0 for its full-width use elsewhere — left
	   unreset here, it pushed this box 20px below its 190px-tall
	   .cbm-textwrap__ad parent and overflowed the bottom by the same
	   20px, breaking the wrap box's own geometry. */
	margin: 0; height: 100%; display: flex; flex-direction: column; justify-content: center;
	padding: 14px 16px; text-align: center; box-sizing: border-box;
}
.cbm-compare-prompt--compact .cbm-compare-prompt__label { font-size: 10px; margin-bottom: 3px; }
.cbm-compare-prompt--compact .cbm-compare-prompt__title { font-size: 17px; line-height: 1.15; margin-bottom: 10px; }
.cbm-compare-prompt--compact .cbm-compare-prompt__cta { padding: 9px 18px; font-size: 12px; align-self: center; }

/* ---- Manufacturer "chapters" (2026-09-28, ADL) ----------------------------
   A heading block in a manufacturer's content starts a chapter: kicker,
   heading, the manufacturer's own words, and the photos/videos that belong
   to it - each photo captioned. Replaces the caption-less gallery for pages
   that use it (see single-manufacturer.php). */
.cbm-mfr-chapter {
	display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 32px;
	align-items: start; margin-top: 40px; padding-top: 32px; border-top: 1px solid var(--cbm-hairline);
}
.cbm-mfr-chapter--flip .cbm-mfr-chapter__copy { order: 2; }
.cbm-mfr-chapter--full, .cbm-mfr-chapter--textonly { grid-template-columns: minmax(0, 1fr); gap: 20px; }
.cbm-mfr-chapter--full .cbm-mfr-chapter__copy, .cbm-mfr-chapter--textonly .cbm-mfr-chapter__copy { max-width: 760px; }
.cbm-mfr-chapter__kicker {
	margin: 0 0 6px; font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
	color: var(--cbm-red);
}
.cbm-mfr-chapter__title { margin: 0 0 12px; font-size: 28px; line-height: 1.2; }
.cbm-mfr-chapter__text { font-size: 16px; line-height: 1.6; color: var(--cbm-body-grey); }
.cbm-mfr-chapter__text p { margin: 0 0 12px; }
.cbm-mfr-chapter__text ul { margin: 0 0 12px; padding-left: 20px; }
.cbm-mfr-chapter__text li { margin: 0 0 4px; }
.cbm-mfr-chapter__text a { color: var(--cbm-red); font-weight: 700; }
.cbm-mfr-chapter__media { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--cbm-gap); }
.cbm-mfr-fig { margin: 0; grid-column: span 3; }
.cbm-mfr-fig:last-child:nth-child(odd) { grid-column: span 6; }
.cbm-mfr-fig img { width: 100%; height: auto; aspect-ratio: 3/2; object-fit: cover; display: block; border-radius: 2px; border: 1px solid var(--cbm-hairline); }
.cbm-mfr-fig--wide { grid-column: span 6; }
.cbm-mfr-fig--wide img { aspect-ratio: 2.4/1; }
.cbm-mfr-chapter__media--three .cbm-mfr-fig:not(.cbm-mfr-fig--wide) { grid-column: span 2; }
.cbm-mfr-chapter__media--mixed .cbm-mfr-fig img { aspect-ratio: 16/9; }
.cbm-mfr-fig figcaption { margin-top: 6px; font-size: 13px; line-height: 1.4; color: var(--cbm-muted-grey); }
.cbm-mfr-range-title { margin-top: 40px; padding-top: 32px; border-top: 1px solid var(--cbm-hairline); }
@media (max-width: 900px) {
	.cbm-mfr-chapter { grid-template-columns: minmax(0, 1fr); gap: 16px; }
	.cbm-mfr-chapter--flip .cbm-mfr-chapter__copy { order: 0; }
	.cbm-mfr-chapter__title { font-size: 24px; }
}
@media (max-width: 640px) {
	.cbm-mfr-fig, .cbm-mfr-chapter__media--three .cbm-mfr-fig:not(.cbm-mfr-fig--wide) { grid-column: span 6; }
}

/* Chapter call-to-action panel (2026-09-28): a hook line + tracked CONTACT ME
   button closing each chapter, so a reader who is interested never has to
   scroll back to the top to act. Sits under both columns of the chapter. */
.cbm-mfr-cta {
	grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 24px;
	padding: 16px 24px; background: var(--cbm-fill-light); border: 1px solid var(--cbm-hairline); border-radius: 2px;
}
.cbm-mfr-cta__hook { margin: 0; font-size: 18px; font-weight: 700; line-height: 1.35; color: var(--cbm-heading-color); max-width: 640px; }
.cbm-mfr-cta .cbm-supplier-actions { padding: 0; width: auto; flex: 0 0 auto; }
.cbm-mfr-cta .cbm-supplier-actions__item { max-width: 260px; }
@media (max-width: 700px) {
	.cbm-mfr-cta { flex-direction: column; align-items: stretch; padding: 16px; }
	.cbm-mfr-cta .cbm-supplier-actions { align-items: stretch; }
	.cbm-mfr-cta .cbm-supplier-actions__item { max-width: none; }
}

/* Alexander Dennis logo ~14% larger than the default 84px slot (Jonathan, 2026-09-28). */
body.postid-406 .cbm-manufacturer-logo-slot__img { max-height: 96px; }

/* Make the chapter call-to-action panels stand out (Jonathan, 2026-09-28):
   dark panel, large white hook line, red button - same family as the CBW Shop banner. */
.cbm-mfr-cta { background: var(--cbm-near-black, #1a1a1a); border-color: var(--cbm-near-black, #1a1a1a); padding: 24px 32px; margin-top: 8px; }
.cbm-mfr-cta__hook { font-size: 22px; color: #fff; }
.cbm-mfr-cta .cbm-supplier-actions__caption { color: #c9cacc; }
.cbm-mfr-cta .cbm-supplier-actions__caption--sent { color: #fff; }
.cbm-mfr-cta .cbm-supplier-actions__btn { padding-top: 16px; padding-bottom: 16px; font-size: 15px; }
@media (max-width: 700px) { .cbm-mfr-cta { padding: 20px 16px; } .cbm-mfr-cta__hook { font-size: 19px; } }

/* Showcase chapter (Jonathan, 2026-09-28): copy with a LARGE video beneath it on
   the left, the still photos stacked down the right-hand side. */
.cbm-mfr-chapter--showcase { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); align-items: stretch; }
.cbm-mfr-chapter__main, .cbm-mfr-chapter__side { display: flex; flex-direction: column; gap: var(--cbm-gap); }
.cbm-mfr-chapter--showcase .cbm-mfr-fig img { aspect-ratio: 16/10; }
@media (max-width: 900px) { .cbm-mfr-chapter--showcase { grid-template-columns: minmax(0, 1fr); } }

/* Model page enquiry panel: reuses the dark .cbm-mfr-cta look, full width under the specs. */
.cbm-vehicle-detail__contact.cbm-mfr-cta { margin-top: 32px; }
.cbm-vehicle-detail__contact-copy .cbm-vehicle-detail__incentive { margin: 6px 0 0; color: #fff; font-size: 15px; }
.cbm-vehicle-detail__contact-copy .cbm-form-error-list { color: #ff9a9d; margin: 8px 0 0; }
.cbm-vehicle-detail__contact.cbm-mfr-cta { width: 100%; max-width: none; margin-left: 0; margin-right: 0; box-sizing: border-box; }
/* TEMSA logo 20% larger than the default 84px slot (Jonathan, 2026-10-05): real page 447 + sales preview 9985. */
body.postid-447 .cbm-manufacturer-logo-slot__img, body.postid-9985 .cbm-manufacturer-logo-slot__img { max-height: 101px; }
/* Premium manufacturer range cards: thumbnail beside model name + specs (Jonathan, 2026-10-05). */
.cbm-mfr-range { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; margin-top: 24px; }
.cbm-mfr-range__card { display: flex; align-items: center; gap: 16px; padding: 12px; background: #fff; border: 1px solid var(--cbm-hairline); border-left: 4px solid var(--cbm-red, #D91E25); border-radius: var(--cbm-radius); color: var(--cbm-near-black-alt); text-decoration: none; box-shadow: 0 2px 8px rgba(0,0,0,0.06); transition: box-shadow .15s, transform .15s; }
.cbm-mfr-range__card:hover { box-shadow: 0 8px 22px rgba(0,0,0,0.14); transform: translateY(-2px); }
.cbm-mfr-range__thumb { flex: 0 0 132px; height: 88px; border-radius: 6px; overflow: hidden; background: #F4F4F4; display: flex; align-items: center; justify-content: center; }
.cbm-mfr-range__thumb img { width: 100%; height: 100%; object-fit: contain; }
.cbm-mfr-range__body { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cbm-mfr-range__name { font-family: var(--cbm-font-body); font-weight: 700; font-size: 20px; line-height: 1.1; }
.cbm-mfr-range__specs { font-size: 13px; color: var(--cbm-muted-grey); }
.cbm-mfr-range__go { font-size: 13px; font-weight: 600; color: var(--cbm-red, #D91E25); margin-top: 2px; }
/* Model photos smaller than the hero width show at natural size, uncropped, not upscaled (2026-10-05). */
.cbm-vehicle-detail__main-photo--natural { aspect-ratio: auto !important; height: auto !important; display: flex; justify-content: center; background: #fff; }
.cbm-vehicle-detail__main-photo--natural img { width: auto !important; height: auto !important; max-width: 100%; max-height: 520px; object-fit: contain !important; aspect-ratio: auto !important; }
/* Manufacturer pages (Jonathan, 2026-10-05): logos 20% larger by default
   (84 -> 101px), ADL 96 -> 115px, Volvo's round badge 130px; no thin
   separator lines between chapters / above the range / above the footer
   details - white space alone separates them. */
body.single-manufacturer .cbm-manufacturer-logo-slot__img { max-height: 101px; }
body.postid-406 .cbm-manufacturer-logo-slot__img { max-height: 64px; } /* 2026-10-13: ADL's new logo is wide (6:1), so shorter - about 385px wide */
body.postid-457 .cbm-manufacturer-logo-slot__img, body.postid-9991 .cbm-manufacturer-logo-slot__img { max-height: 130px; }
.cbm-mfr-chapter, .cbm-mfr-range-title { border-top: none; padding-top: 16px; }
body.single-manufacturer .cbm-manufacturer-contact-details { border-top: none; }
/* (2026-10-05) Logo 10px further from the CBW News ticker (was 14px gap);
   first chapter tucks up under the intro + CONTACT ME column (was 56px). */
body.single-manufacturer .cbm-manufacturer-logo-slot__img { margin-top: 10px; }
.cbm-manufacturer-textwrap + .cbm-mfr-chapter { margin-top: 4px; }
/* (2026-10-05) Tighter CONTACT ME / VISIT WEBSITE column beside the intro. */
.cbm-manufacturer-textwrap .cbm-supplier-actions { gap: 10px; padding-bottom: 0; }
.cbm-manufacturer-textwrap .cbm-supplier-actions__incentive { margin-bottom: 8px; }
.cbm-manufacturer-textwrap .cbm-supplier-actions__caption { margin-top: 5px; line-height: 1.35; }
.cbm-manufacturer-textwrap .cbm-supplier-actions__btn { padding-top: 11px; padding-bottom: 11px; }

/* 2026-10-13: manufacturer intro on tablets / small laptops. The 468px hero
   photo is absolutely positioned beside the wrapped text, with the CONTACT ME /
   VISIT WEBSITE buttons floated right - below about 880px wide the photo ran
   over the text and the buttons (found on ADL's page), and up to ~1000px the
   text between them was squeezed to a sliver. Stack it, as phones already do. */
@media (max-width: 1000px) {
	.cbm-manufacturer-textwrap .cbm-textwrap__float { float: none; width: 100%; height: auto; shape-outside: none; }
	.cbm-manufacturer-textwrap .cbm-textwrap__ad { position: static; width: 100%; max-width: 468px; margin: 16px 0; }
	.cbm-manufacturer-textwrap .cbm-supplier-actions { float: none; width: 100%; padding: 0 0 16px; }
}

/* 2026-10-15: ADL (post 406) asked for a tidier, consistently aligned top of
   page. Desktop only (above 1000px; below that the stacked layout above
   applies): intro becomes two clean columns - text, then CONTACT ME / VISIT
   WEBSITE side by side at equal width - with the photo on the right, instead
   of text wrapping around both. Logo, search and Back now line up with the
   same left/right edges as the text, photo and chapters below; intro text at
   the chapters' 16px. Scoped to ADL only; other manufacturers unchanged. */
@media (min-width: 1001px) {
	body.postid-406 .cbm-back-wrap__title--logo { margin-left: 32px; }
	body.postid-406 .cbm-back-wrap__actions { margin-right: 32px; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-textwrap__inner {
		display: grid; grid-template-columns: minmax(0, 1fr) 468px;
		column-gap: 40px; row-gap: 24px; align-items: start;
	}
	body.postid-406 .cbm-manufacturer-textwrap .cbm-textwrap__float { display: none; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-textwrap__text { grid-column: 1; grid-row: 1; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-textwrap__text p { font-size: 16px; line-height: 1.6; margin: 0 0 12px; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-textwrap__text p:last-child { margin-bottom: 0; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-textwrap__ad {
		position: static; grid-column: 2; grid-row: 1;
		width: 468px; height: auto; margin: 0;
	}
	body.postid-406 .cbm-manufacturer-textwrap .cbm-textwrap__ad img { display: block; width: 100%; height: auto; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-supplier-actions {
		grid-column: 1; grid-row: 2; float: none; width: auto; margin: 0; padding: 0;
		display: grid; grid-template-columns: repeat(2, minmax(0, 220px)); column-gap: 24px; align-items: start;
	}
	body.postid-406 .cbm-manufacturer-textwrap .cbm-supplier-actions__item { width: auto; max-width: none; margin: 0; text-align: left; align-items: stretch; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-supplier-actions__item form { margin: 0; width: 100%; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-supplier-actions__btn { display: flex; align-items: center; justify-content: center; width: 100%; height: 42px; box-sizing: border-box; padding-top: 0; padding-bottom: 0; text-align: center; }
	body.postid-406 .cbm-manufacturer-textwrap .cbm-supplier-actions__caption { text-align: left; }
	body.postid-406 .cbm-manufacturer-textwrap + .cbm-mfr-chapter { margin-top: 32px; }
}

/* 2026-10-15: CONTACT ME / VISIT WEBSITE beside a chapter instead of in the
   intro (manufacturer meta actions_chapter; ADL = 2, from ADL's own sketch).
   Copy left, buttons stacked in a right column, the chapter's photos full
   width underneath. Phones/tablets: buttons simply follow the copy. */
.cbm-mfr-chapter__actions { max-width: 320px; }
.cbm-mfr-chapter__actions .cbm-supplier-actions {
	display: flex; flex-direction: column; gap: 14px; width: 100%; margin: 0; padding: 0; float: none;
}
.cbm-mfr-chapter__actions .cbm-supplier-actions__item { width: 100%; max-width: none; margin: 0; align-items: stretch; text-align: left; }
.cbm-mfr-chapter__actions .cbm-supplier-actions__item form { margin: 0; width: 100%; }
.cbm-mfr-chapter__actions .cbm-supplier-actions__btn {
	display: flex; align-items: center; justify-content: center; width: 100%; height: 42px;
	box-sizing: border-box; padding-top: 0; padding-bottom: 0; text-align: center;
}
.cbm-mfr-chapter__actions .cbm-supplier-actions__caption { margin-top: 6px; line-height: 1.35; text-align: left; }
@media (min-width: 901px) {
	.cbm-mfr-chapter--with-actions.cbm-mfr-chapter--full,
	.cbm-mfr-chapter--with-actions.cbm-mfr-chapter--textonly { grid-template-columns: minmax(0, 1fr) 244px; column-gap: 40px; }
	.cbm-mfr-chapter--with-actions .cbm-mfr-chapter__copy { grid-column: 1; grid-row: 1; }
	.cbm-mfr-chapter--with-actions .cbm-mfr-chapter__actions { grid-column: 2; grid-row: 1; padding-top: 24px; }
	.cbm-mfr-chapter--with-actions .cbm-mfr-chapter__media { grid-column: 1 / -1; }
}

/* 2026-10-15 ADL sketch: in the video-left chapter ("THE COMPANY") the small
   red label runs across the top of the section, above the video, with the
   heading and text to the right of the video. Desktop only. */
@media (min-width: 901px) {
	body.postid-406 .cbm-mfr-chapter--flip {
		grid-template-areas: "kicker kicker" "media title" "media text";
		grid-template-rows: auto auto 1fr; row-gap: 0;
	}
	body.postid-406 .cbm-mfr-chapter--flip .cbm-mfr-chapter__copy { display: contents; }
	body.postid-406 .cbm-mfr-chapter--flip .cbm-mfr-chapter__kicker { grid-area: kicker; margin-bottom: 14px; }
	body.postid-406 .cbm-mfr-chapter--flip .cbm-mfr-chapter__title { grid-area: title; }
	body.postid-406 .cbm-mfr-chapter--flip .cbm-mfr-chapter__text { grid-area: text; }
	body.postid-406 .cbm-mfr-chapter--flip .cbm-mfr-chapter__media { grid-area: media; }
}

/* 2026-10-15 (Jonathan): one line space more above ADL's logo - it sat too
   close to the CBM Newsfeed bar. Was 10px (all manufacturers). */
body.postid-406 .cbm-manufacturer-logo-slot__img { margin-top: 34px; }

/* 2026-10-15 (Jonathan): ADL's CONTACT ME / VISIT WEBSITE float freely in the
   white space on the right, 3 lines (~77px) higher than the Electric range
   heading - so the grey divider above that chapter is dropped (the buttons
   would otherwise sit across it). Desktop only. */
@media (min-width: 901px) {
	body.postid-406 .cbm-mfr-chapter--with-actions { border-top: none; }
	body.postid-406 .cbm-mfr-chapter--with-actions .cbm-mfr-chapter__actions { padding-top: 0; margin-top: -53px; }
}

/* 2026-10-19 (Fishwick): a chapter's list with a call-out box to its right
   (wp:html block in the page content). Box colours set inline per client.
   Desktop: the list keeps its natural width, the box fills the rest of the
   row (the chapter copy's 760px cap is lifted), top level with the chapter
   heading (pulled up by the heading's height + margin), bottom level with
   the list (Jonathan: wider, bigger lettering, less white space).
   900px and below: box stacks full width under the list. */
.cbm-mfr-offer { display: flex; flex-direction: column; gap: 16px; margin: 0 0 12px; }
.cbm-mfr-offer > ul { margin: 0; }
.cbm-mfr-offer__box {
	box-sizing: border-box; padding: 22px 24px; border-radius: 4px;
	display: flex; align-items: center; justify-content: center;
	background: var(--cbm-red); color: #fff; font-weight: 700; font-size: 20px; line-height: 1.35; text-align: center;
}
.cbm-mfr-chapter__text .cbm-mfr-offer__box a { color: inherit; text-decoration: underline; }
@media (min-width: 901px) {
	.cbm-mfr-chapter__copy:has(.cbm-mfr-offer) { max-width: none; }
	.cbm-mfr-offer { flex-direction: row; align-items: stretch; gap: 40px; }
	.cbm-mfr-offer > ul { flex: 0 0 auto; }
	.cbm-mfr-offer__box { flex: 1 1 auto; font-size: 26px; margin-top: calc(-1 * (28px * 1.2 + 12px)); } /* = .cbm-mfr-chapter__title height + margin */
}
/* Heading + one video, nothing else: the video full width, 16:9. */
.cbm-mfr-chapter--video .cbm-mfr-chapter__media { width: 100%; max-width: none; }
