/**
 * Bookelaar Vehicle Listings frontend styles.
 */

:root {
	--bv-black: #0b0b0d;
	--bv-charcoal: #151519;
	--bv-red: #c91414;
	--bv-red-dark: #960f0f;
	--bv-silver: #d8d8dc;
	--bv-silver-dark: #8d8d94;
	--bv-white: #ffffff;
	--bv-soft: #f5f5f6;
	--bv-border: rgba(255, 255, 255, 0.14);
	--bv-text: #242428;
	--bv-radius: 16px;
	--bv-shadow: 0 18px 45px rgba(0, 0, 0, 0.16);
}

.bv-template-wrap,
.bv-vehicle-details,
.bv-vehicle-filter,
.bv-vehicle-grid {
	box-sizing: border-box;
}

.bv-template-wrap {
	max-width: 1240px;
	margin: 0 auto;
	padding: 42px 20px 64px;
}

.bv-archive-header {
	margin-bottom: 26px;
	padding: 34px;
	border-radius: var(--bv-radius);
	background: linear-gradient(135deg, var(--bv-black), #222228);
	color: var(--bv-white);
	box-shadow: var(--bv-shadow);
}

.bv-archive-header h1 {
	margin: 0 0 8px;
	font-size: clamp(2rem, 4vw, 3.5rem);
	line-height: 1.05;
	letter-spacing: -0.04em;
}

.bv-archive-header p {
	margin: 0;
	max-width: 760px;
	color: var(--bv-silver);
	font-size: 1.05rem;
}

.bv-vehicle-grid {
	display: grid;
	gap: 26px;
	align-items: stretch;
}

.bv-columns-1 { grid-template-columns: 1fr; }
.bv-columns-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.bv-columns-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.bv-columns-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.bv-vehicle-card {
	overflow: hidden;
	display: flex;
	flex-direction: column;
	min-width: 0;
	border-radius: var(--bv-radius);
	background: var(--bv-white);
	box-shadow: 0 12px 34px rgba(0, 0, 0, 0.12);
	border: 1px solid rgba(0, 0, 0, 0.06);
	transition: transform 180ms ease, box-shadow 180ms ease;
}

.bv-vehicle-card:hover {
	transform: translateY(-3px);
	box-shadow: var(--bv-shadow);
}

.bv-vehicle-card-image {
	position: relative;
	display: block;
	aspect-ratio: 16 / 10;
	background: linear-gradient(135deg, var(--bv-black), #2c2c31);
	color: var(--bv-white);
	text-decoration: none;
	overflow: hidden;
}

.bv-vehicle-card-image img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 220ms ease;
}

.bv-vehicle-card:hover .bv-vehicle-card-image img {
	transform: scale(1.03);
}

.bv-vehicle-placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 100%;
	font-size: 1.1rem;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--bv-silver);
}

.bv-featured-badge,
.bv-status-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 7px 10px;
	border-radius: 999px;
	font-size: 0.74rem;
	font-weight: 800;
	line-height: 1;
	text-transform: uppercase;
	letter-spacing: 0.06em;
}

.bv-featured-badge {
	position: absolute;
	top: 14px;
	left: 14px;
	background: var(--bv-red);
	color: var(--bv-white);
	box-shadow: 0 8px 22px rgba(0, 0, 0, 0.22);
}

.bv-status-badge {
	background: var(--bv-charcoal);
	color: var(--bv-white);
}

.bv-status-available,
.bv-status-spanish-registered {
	background: #126b3a;
}

.bv-status-reserved,
.bv-status-incoming,
.bv-status-import-in-progress,
.bv-status-registration-in-progress {
	background: #a66c00;
}

.bv-status-sold {
	background: #5f6368;
}

.bv-vehicle-card-body {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: 22px;
}

.bv-card-topline {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 14px;
}

.bv-card-price {
	font-size: 1rem;
	font-weight: 900;
	color: var(--bv-red);
	white-space: nowrap;
}

.bv-vehicle-card-title {
	margin: 0;
	font-size: 1.25rem;
	line-height: 1.2;
}

.bv-vehicle-card-title a {
	color: var(--bv-black);
	text-decoration: none;
}

.bv-vehicle-card-title a:hover {
	color: var(--bv-red);
}

.bv-card-subtitle,
.bv-card-headline,
.bv-card-excerpt {
	margin: 8px 0 0;
	color: #55555b;
	line-height: 1.55;
}

.bv-card-subtitle {
	font-weight: 700;
	color: var(--bv-silver-dark);
	text-transform: uppercase;
	letter-spacing: 0.05em;
	font-size: 0.82rem;
}

.bv-card-headline {
	font-weight: 600;
	color: var(--bv-text);
}

.bv-card-specs {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 16px 0 0;
	padding: 0;
	list-style: none;
}

.bv-card-specs li {
	padding: 7px 9px;
	border-radius: 999px;
	background: var(--bv-soft);
	color: var(--bv-text);
	font-size: 0.82rem;
	font-weight: 700;
}

.bv-card-excerpt {
	margin-top: 14px;
	font-size: 0.96rem;
}

.bv-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 42px;
	padding: 11px 18px;
	border-radius: 999px;
	border: 1px solid transparent;
	font-weight: 800;
	line-height: 1.1;
	text-decoration: none !important;
	cursor: pointer;
	transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

.bv-button:hover {
	transform: translateY(-1px);
}

.bv-button-primary {
	background: var(--bv-red);
	color: var(--bv-white) !important;
}

.bv-button-primary:hover {
	background: var(--bv-red-dark);
}

.bv-button-secondary {
	background: var(--bv-white);
	color: var(--bv-black) !important;
	border-color: rgba(0, 0, 0, 0.18);
}

.bv-card-button {
	margin-top: auto;
	align-self: flex-start;
}

.bv-vehicle-empty {
	grid-column: 1 / -1;
	padding: 24px;
	border-radius: var(--bv-radius);
	background: var(--bv-soft);
	color: var(--bv-text);
}

.bv-vehicle-filter {
	margin: 0 0 30px;
	padding: 22px;
	border-radius: var(--bv-radius);
	background: var(--bv-black);
	color: var(--bv-white);
	box-shadow: var(--bv-shadow);
}

.bv-filter-grid {
	display: grid;
	grid-template-columns: repeat(6, minmax(0, 1fr));
	gap: 14px;
}

.bv-filter-field {
	display: flex;
	flex-direction: column;
	gap: 7px;
	min-width: 0;
}

.bv-filter-field span {
	font-size: 0.78rem;
	font-weight: 800;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--bv-silver);
}

.bv-filter-field select,
.bv-filter-field input {
	width: 100%;
	min-height: 42px;
	border: 1px solid var(--bv-border);
	border-radius: 10px;
	background: #202025;
	color: var(--bv-white);
	padding: 8px 10px;
}

.bv-filter-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 16px;
}

.bv-vehicle-details {
	color: var(--bv-text);
}

.bv-details-header {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 28px;
	margin-bottom: 28px;
	padding: 34px;
	border-radius: var(--bv-radius);
	background: linear-gradient(135deg, var(--bv-black), #24242a);
	color: var(--bv-white);
	box-shadow: var(--bv-shadow);
}

.bv-details-title {
	margin: 14px 0 0;
	font-size: clamp(2rem, 5vw, 4.2rem);
	line-height: 0.98;
	letter-spacing: -0.055em;
	color: var(--bv-white);
}

.bv-details-headline {
	max-width: 780px;
	margin: 14px 0 0;
	font-size: 1.08rem;
	line-height: 1.55;
	color: var(--bv-silver);
}

.bv-details-price-wrap {
	min-width: 180px;
	padding: 18px;
	border: 1px solid var(--bv-border);
	border-radius: 14px;
	background: rgba(255, 255, 255, 0.06);
	text-align: right;
}

.bv-details-price-label {
	display: block;
	font-size: 0.78rem;
	font-weight: 800;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--bv-silver);
}

.bv-details-price {
	display: block;
	margin-top: 4px;
	font-size: 1.8rem;
	color: var(--bv-white);
}

.bv-details-layout {
	display: grid;
	grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.75fr);
	gap: 28px;
	align-items: start;
}

.bv-details-media,
.bv-details-summary,
.bv-details-panel {
	border-radius: var(--bv-radius);
	background: var(--bv-white);
	box-shadow: 0 10px 28px rgba(0, 0, 0, 0.09);
	border: 1px solid rgba(0, 0, 0, 0.06);
}

.bv-details-media {
	overflow: hidden;
	padding: 0;
}

.bv-main-image {
	display: block;
	width: 100%;
	aspect-ratio: 16 / 10;
	height: auto;
	object-fit: cover;
	background: var(--bv-black);
}

.bv-main-image-placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 360px;
	color: var(--bv-silver);
}

.bv-gallery-thumbs {
	display: grid;
	grid-template-columns: repeat(6, minmax(0, 1fr));
	gap: 8px;
	padding: 12px;
	background: #111115;
}

.bv-gallery-thumb {
	padding: 0;
	border: 2px solid transparent;
	border-radius: 9px;
	background: transparent;
	cursor: pointer;
	overflow: hidden;
}

.bv-gallery-thumb:hover,
.bv-gallery-thumb.is-active {
	border-color: var(--bv-red);
}

.bv-gallery-thumb img {
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	height: auto;
	object-fit: cover;
}

.bv-details-summary {
	position: static;
	padding: 24px;
}

.bv-details-summary h2,
.bv-details-panel h2 {
	margin: 0 0 16px;
	font-size: 1.35rem;
	letter-spacing: -0.02em;
	color: var(--bv-black);
}

.bv-spec-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.95rem;
}

.bv-spec-table th,
.bv-spec-table td {
	padding: 10px 0;
	border-bottom: 1px solid rgba(0, 0, 0, 0.08);
	vertical-align: top;
}

.bv-spec-table th {
	width: 45%;
	padding-right: 16px;
	color: #686872;
	font-weight: 800;
	text-align: left;
}

.bv-spec-table td {
	color: var(--bv-black);
	font-weight: 700;
}

.bv-spec-table tr:last-child th,
.bv-spec-table tr:last-child td {
	border-bottom: 0;
}

.bv-details-cta {
	width: 100%;
	margin-top: 22px;
}

.bv-details-content-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(280px, 0.55fr);
	gap: 28px;
	margin-top: 28px;
}

.bv-details-panel {
	padding: 26px;
}

.bv-details-panel:first-child {
	grid-row: span 2;
}

.bv-vehicle-description,
.bv-import-notes,
.bv-details-panel p {
	font-size: 1rem;
	line-height: 1.75;
	color: #424248;
}

.bv-highlights-list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.bv-highlights-list li {
	position: relative;
	padding: 11px 0 11px 28px;
	border-bottom: 1px solid rgba(0, 0, 0, 0.08);
	font-weight: 700;
}

.bv-highlights-list li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 17px;
	width: 10px;
	height: 10px;
	border-radius: 999px;
	background: var(--bv-red);
}

.bv-import-panel {
	background: linear-gradient(180deg, #ffffff, #f7f7f8);
}

.bv-spec-table-compact {
	margin: 18px 0;
	border-radius: var(--bv-radius);
	background: var(--bv-white);
}

@media (max-width: 1100px) {
	.bv-columns-4,
	.bv-columns-3 {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.bv-filter-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.bv-details-layout,
	.bv-details-content-grid {
		grid-template-columns: 1fr;
	}

	.bv-details-summary {
		position: static;
	}

	.bv-details-panel:first-child {
		grid-row: auto;
	}
}

@media (max-width: 720px) {
	.bv-template-wrap {
		padding: 26px 14px 44px;
	}

	.bv-columns-4,
	.bv-columns-3,
	.bv-columns-2 {
		grid-template-columns: 1fr;
	}

	.bv-filter-grid {
		grid-template-columns: 1fr;
	}

	.bv-details-header {
		align-items: stretch;
		flex-direction: column;
		padding: 24px;
	}

	.bv-details-price-wrap {
		text-align: left;
	}

	.bv-gallery-thumbs {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}

	.bv-vehicle-card-body,
	.bv-details-panel,
	.bv-details-summary {
		padding: 20px;
	}
}


/* Accessibility and refinement additions. */
.bv-button:focus-visible,
.bv-gallery-thumb:focus-visible,
.bv-filter-field select:focus-visible,
.bv-filter-field input:focus-visible {
	outline: 3px solid rgba(201, 20, 20, 0.35);
	outline-offset: 3px;
}

.bv-vehicle-card {
	isolation: isolate;
}

.bv-card-price,
.bv-details-price {
	font-variant-numeric: tabular-nums;
}

.bv-results-summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin: 0 0 18px;
	color: #55555b;
	font-weight: 700;
}

.bv-pagination {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
	margin-top: 30px;
}

.bv-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 42px;
	min-height: 42px;
	padding: 8px 12px;
	border: 1px solid rgba(0,0,0,.12);
	border-radius: 999px;
	background: #fff;
	color: #151519;
	text-decoration: none;
	font-weight: 800;
}

.bv-pagination .page-numbers.current,
.bv-pagination .page-numbers:hover {
	background: var(--bv-red);
	border-color: var(--bv-red);
	color: #fff;
}

@media (prefers-reduced-motion: reduce) {
	.bv-vehicle-card-image img,
	.bv-button { transition: none; }
	.bv-vehicle-card:hover .bv-vehicle-card-image img,
	.bv-button:hover { transform: none; }
}

/* v1.3 single-vehicle refinement */
.bv-details-main { min-width: 0; display: grid; gap: 28px; }
.bv-details-sidebar { min-width: 0; }
@media (min-width: 1101px) {
	.bv-details-sidebar { align-self: start; position: sticky; top: 32px; }
}
.bv-description-panel { margin: 0; }
.bv-key-specs { margin: 0; }
.bv-key-specs > div { display: grid; grid-template-columns: minmax(100px, .85fr) minmax(0, 1.15fr); gap: 12px; padding: 11px 0; border-bottom: 1px solid rgba(0,0,0,.08); }
.bv-key-specs dt { color: #686872; font-weight: 750; }
.bv-key-specs dd { margin: 0; color: var(--bv-black); font-weight: 850; text-align: right; overflow-wrap: anywhere; }
.bv-sidebar-note { margin: 14px 0 0; color: #686872; font-size: .86rem; line-height: 1.55; }
.bv-video-embed { position: relative; overflow: hidden; aspect-ratio: 16 / 9; border-radius: 12px; background: #000; }
.bv-video-embed iframe, .bv-video-embed video { width: 100%; height: 100%; border: 0; }
.bv-highlights-panel, .bv-full-specs-panel, .bv-import-panel { margin-top: 28px; }
.bv-highlights-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 0 28px; }
.bv-spec-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px; }
.bv-spec-item { min-width: 0; padding: 16px; border: 1px solid rgba(0,0,0,.08); border-radius: 12px; background: #f7f7f8; }
.bv-spec-item span { display: block; margin-bottom: 5px; color: #6a6a72; font-size: .75rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.bv-spec-item strong { display: block; color: var(--bv-black); overflow-wrap: anywhere; }
@media (max-width: 900px) { .bv-spec-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (max-width: 720px) { .bv-highlights-grid, .bv-spec-grid { grid-template-columns: 1fr; } .bv-key-specs > div { grid-template-columns: 1fr; gap: 2px; } .bv-key-specs dd { text-align: left; } }
