/* Chequered Past. Spec-sheet look: condensed headings, mono data labels, one purple accent.
   Every component sets its own surface and text colour so it reads on any theme. */

.hs, .hs-controls {
	--hs-bg: #E8ECF1;
	--hs-surface: #F6F8FA;
	--hs-ink: #0F1A26;
	--hs-muted: #566372;
	--hs-line: #C4CCD7;
	--hs-accent: #5A3C9E;
	--hs-accent-ink: #FFFFFF;
	--hs-good: #1B7A4B;
	--hs-warn: #A5530A;
	--hs-display: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", sans-serif;
	--hs-body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
	--hs-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
	font-family: var(--hs-body);
	font-size: 15px;
	line-height: 1.55;
	color: var(--hs-ink);
}
.hs *, .hs *::before, .hs *::after, .hs-controls *, .hs-controls *::before, .hs-controls *::after { box-sizing: border-box; }
.hs a, .hs-controls a { color: inherit; }
.hs :focus-visible, .hs-controls :focus-visible { outline: 2px solid var(--hs-accent); outline-offset: 2px; }

.hs-single, .hs-archive { background: var(--hs-bg); padding-block: 8px 56px; }
.hs-wrap { max-width: 1080px; margin: 0 auto; padding-inline: 16px; }

.hs h1, .hs h2, .hs h3, .hs .hs-h3 {
	font-family: var(--hs-display);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.01em;
	line-height: 1.05;
	margin: 0;
	color: var(--hs-ink);
	text-wrap: balance;
}
.hs h1 { font-size: clamp(2.2rem, 6vw, 3.6rem); }
.hs h2 { font-size: 1.7rem; }
.hs h3, .hs .hs-h3 { font-size: 1.2rem; }
.hs p { margin: 0 0 0.8em; }

.hs-label, .hs-eyebrow {
	font-family: var(--hs-mono);
	font-size: 11px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--hs-muted);
}
.hs-eyebrow { font-size: 12px; }
.hs-note { font-size: 12px; color: var(--hs-muted); margin: 0; }
.hs-sub { font-size: 12px; color: var(--hs-muted); }
.hs-mono { font-family: var(--hs-mono); }
.hs [data-hs], .hs-controls [data-hs] { font-variant-numeric: tabular-nums; }

/* Controls */
.hs-controls {
	display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px;
	padding: 10px 16px; margin: 0 0 20px;
	background: var(--hs-surface); border: 1px solid var(--hs-line);
}
.hs-ctl { display: inline-flex; align-items: center; gap: 8px; }
.hs select, .hs input[type="number"], .hs-controls select {
	font: inherit; color: var(--hs-ink); background: #fff;
	border: 1px solid var(--hs-line); padding: 6px 10px; border-radius: 3px; min-width: 0; max-width: 100%;
}
.hs-seg { display: inline-flex; border: 1px solid var(--hs-line); border-radius: 3px; overflow: hidden; }
.hs-seg button { font: inherit; background: #fff; color: var(--hs-ink); border: 0; padding: 6px 12px; cursor: pointer; }
.hs-seg button[aria-pressed="true"] { background: var(--hs-ink); color: #fff; }
.hs-rate-note { font-size: 12px; color: var(--hs-muted); }
.hs-garage-link { margin-left: auto; font-weight: 600; text-decoration: none; }
.hs-garage-link:hover { text-decoration: underline; }

/* Buttons and tags */
.hs-btn {
	display: inline-block; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
	background: var(--hs-accent); color: var(--hs-accent-ink) !important;
	border: 1px solid var(--hs-accent); padding: 8px 16px; border-radius: 3px;
}
.hs-btn:hover { filter: brightness(1.1); }
.hs-btn--ghost { background: transparent; color: var(--hs-ink) !important; border-color: var(--hs-ink); }
.hs-tag { display: inline-block; font-family: var(--hs-mono); font-size: 11px; padding: 1px 7px; border: 1px solid var(--hs-line); color: var(--hs-muted); margin-right: 4px; }
.hs-heart {
	font: inherit; font-size: 13px; background: transparent; color: var(--hs-ink);
	border: 1px solid var(--hs-line); padding: 3px 10px; border-radius: 99px; cursor: pointer;
}
.hs-heart[aria-pressed="true"] { background: var(--hs-accent); color: var(--hs-accent-ink); border-color: var(--hs-accent); }
.hs-badge { display: inline-block; font-family: var(--hs-mono); font-size: 11px; padding: 2px 8px; border: 1px solid currentColor; text-transform: uppercase; letter-spacing: 0.05em; }
.hs-badge--high { color: var(--hs-good); }
.hs-badge--medium, .hs-badge--low { color: var(--hs-warn); }

/* Single car page */
.hs-crumbs { font-size: 13px; color: var(--hs-muted); display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.hs-car-head { display: grid; gap: 8px; margin-bottom: 18px; }
.hs-head-row { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; margin-top: 4px; }
.hs-hero { margin: 0 0 28px; }
.hs-hero img { display: block; width: 100%; height: auto; max-width: 100%; aspect-ratio: 2 / 1; object-fit: cover; background: var(--hs-line); }
.hs-credit { font-size: 12px; line-height: 1.4; color: var(--hs-muted); padding: 6px 0 0; margin: 0; }
.hs-credit a { text-decoration: underline; }
.hs-layout { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 32px; align-items: start; }
.hs-col-main { display: grid; gap: 36px; min-width: 0; }
.hs-col-side { display: grid; gap: 16px; min-width: 0; }
.hs-lede { font-size: 1.2rem; line-height: 1.45; max-width: 60ch; }
.hs-prose h2 { font-size: 1.7rem; margin: 1.6em 0 0.45em; }
.hs-prose h2:first-child { margin-top: 0; }
.hs-prose p { max-width: 68ch; font-size: 1.02rem; margin: 0 0 1em; }
.hs-elig h2 { margin-bottom: 14px; }
.hs-src { font-size: 12px; color: var(--hs-muted); overflow-wrap: anywhere; }
.hs-panel { background: var(--hs-surface); border: 1px solid var(--hs-line); padding: 16px; display: grid; gap: 10px; min-width: 0; }
.hs-price { font-family: var(--hs-display); font-weight: 700; font-size: 2.2rem; line-height: 1; }
.hs-price--sm { font-size: 1.6rem; }
.hs-trio { display: flex; flex-wrap: wrap; gap: 10px 22px; }
.hs-specs { width: 100%; border-collapse: collapse; font-size: 14px; }
.hs-specs th, .hs-specs td { text-align: left; padding: 7px 4px; border-bottom: 1px solid var(--hs-line); vertical-align: top; }
.hs-specs th { font-family: var(--hs-mono); font-weight: 400; font-size: 11px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--hs-muted); white-space: nowrap; padding-right: 12px; }
.hs-partners ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.hs-partners li { display: grid; gap: 2px; }
.hs-partners li a { font-weight: 600; }
.hs-partners li span { font-size: 13px; color: var(--hs-muted); }

/* Archive and cards */
.hs-archive-head { margin-bottom: 16px; display: grid; gap: 6px; }
.hs-filter { display: flex; flex-wrap: wrap; gap: 10px 20px; margin-bottom: 20px; }
.hs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.hs-card { background: var(--hs-surface); border: 1px solid var(--hs-line); display: grid; grid-template-rows: auto 1fr auto; min-width: 0; color: var(--hs-ink); }
.hs-card-media { display: block; aspect-ratio: 8 / 5; background: var(--hs-line); overflow: hidden; }
.hs-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hs-card-body { padding: 12px; display: grid; gap: 8px; align-content: start; }
.hs-card-body h3 a { text-decoration: none; }
.hs-card-body h3 a:hover { text-decoration: underline; }
.hs-facts-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0; border-top: 1px solid var(--hs-line); padding: 10px 12px; }
.hs-facts-row dt { margin: 0; }
.hs-facts-row dd { margin: 0; font-family: var(--hs-mono); font-size: 13px; }
.hs-pagination, .hs-archive .navigation { margin-top: 24px; }

/* Featured slider */
.hs-slider { position: relative; background: #0F1A26; color: #fff; margin: 0 0 28px; }
.hs-slides { position: relative; display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.hs-slides::-webkit-scrollbar { display: none; }
.hs-slide { flex: 0 0 100%; min-width: 0; scroll-snap-align: start; display: grid; grid-template-areas: "stack" "credit"; background: #0F1A26; }
.hs-slide-media, .hs-slide-body { grid-area: stack; }
.hs-slide-media { aspect-ratio: 2 / 1; overflow: hidden; background: linear-gradient(135deg, #1B2635, #0F1A26); }
.hs-slide-media a { display: block; height: 100%; }
.hs-slide-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hs-slide-body {
	align-self: end; display: grid; gap: 8px; padding: 56px max(16px, 3vw) 22px;
	background: linear-gradient(to top, rgba(8, 12, 18, 0.92), rgba(8, 12, 18, 0.6) 55%, rgba(8, 12, 18, 0));
	color: #fff; position: relative;
}
.hs-slider .hs-slide-body h2 { color: #fff; font-size: clamp(1.8rem, 4.5vw, 3rem); }
.hs-slider .hs-slide-body h2 a { text-decoration: none; color: #fff; }
.hs-slider .hs-label { color: #C9D2DD; }
.hs-slide-tag { max-width: 60ch; margin: 0; color: #E3E9F0; }
.hs-slide-stats { display: flex; flex-wrap: wrap; gap: 6px 26px; margin: 0; }
.hs-slide-stats > div { display: grid; gap: 0; }
.hs-slide-stats dt { font-family: var(--hs-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: #C9D2DD; }
.hs-slide-stats dd { margin: 0; font-family: var(--hs-mono); font-size: 15px; }
.hs-slide-body .hs-btn { justify-self: start; margin-top: 4px; }
.hs-credit--slide { grid-area: credit; background: #0F1A26; color: #B8C2CE; padding: 6px max(16px, 3vw); }
.hs-slider-nav { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 10px 16px; background: #0F1A26; border-top: 1px solid #263240; }
.hs-nav-btn { font: inherit; width: 38px; height: 34px; background: transparent; color: #fff; border: 1px solid #44546A; border-radius: 3px; cursor: pointer; }
.hs-nav-btn:hover { background: #1B2635; }
.hs-dots { display: flex; gap: 8px; flex: 1; justify-content: center; flex-wrap: wrap; }
.hs-dot { width: 22px; height: 6px; padding: 0; border: 0; background: #44546A; cursor: pointer; border-radius: 0; }
.hs-dot[aria-current="true"] { background: #fff; }
.hs-slider :focus-visible { outline-color: #fff; }

/* Ranking */
.hs-ranking, .hs-compare, .hs-garage, .hs-poll { background: var(--hs-surface); border: 1px solid var(--hs-line); padding: 16px; margin: 0 0 24px; color: var(--hs-ink); }
.hs-ranking-head { display: flex; flex-wrap: wrap; gap: 10px 20px; justify-content: space-between; align-items: flex-end; margin-bottom: 14px; }
.hs-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.hs-chip { font: inherit; font-size: 13px; background: transparent; color: var(--hs-ink); border: 1px solid var(--hs-line); padding: 4px 10px; border-radius: 99px; cursor: pointer; }
.hs-chip[aria-pressed="true"] { background: var(--hs-ink); color: #fff; border-color: var(--hs-ink); }
.hs-bars { display: grid; gap: 4px; }
.hs-bar-row { display: grid; grid-template-columns: minmax(130px, 230px) 1fr minmax(64px, auto); gap: 10px; align-items: center; text-decoration: none; padding: 3px 0; color: var(--hs-ink); }
.hs-bar-row:hover .hs-bar-name { text-decoration: underline; }
.hs-bar-name { font-weight: 500; font-size: 14px; min-width: 0; overflow-wrap: anywhere; }
.hs-bar-track { height: 14px; background: rgba(140, 152, 168, 0.25); }
.hs-bar-fill { display: block; height: 100%; background: var(--hs-ink); }
.hs-bar-row.is-lead .hs-bar-fill { background: var(--hs-accent); }
.hs-bar-val { font-family: var(--hs-mono); font-size: 13px; text-align: right; }

/* Compare */
.hs-picker { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px; margin: 12px 0 18px; }
.hs-picker label { display: flex; gap: 8px; align-items: center; border: 1px solid var(--hs-line); padding: 6px 10px; background: #fff; cursor: pointer; font-size: 14px; min-width: 0; }
.hs-picker label.is-on { border-color: var(--hs-accent); }
.hs-scroll { overflow-x: auto; max-width: 100%; }
.hs-table { border-collapse: collapse; width: 100%; font-size: 14px; }
.hs-table th, .hs-table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--hs-line); vertical-align: top; }
.hs-table thead th { font-family: var(--hs-display); font-size: 1.1rem; text-transform: uppercase; letter-spacing: 0.03em; border-bottom: 2px solid var(--hs-ink); }
.hs-table tbody th { font-family: var(--hs-mono); font-weight: 400; font-size: 11px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--hs-muted); white-space: nowrap; }
.hs-table td.is-best { color: var(--hs-accent); font-weight: 600; }
.hs-table td.is-best::after { content: " ▲"; font-size: 10px; }
.hs-inputs, .hs-share { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; margin-top: 18px; }
.hs-share input { flex: 1 1 240px; font-family: var(--hs-mono); font-size: 12px; background: #fff; color: var(--hs-ink); border: 1px solid var(--hs-line); padding: 7px 10px; min-width: 0; }
.hs-empty { border: 1px dashed var(--hs-line); padding: 22px; text-align: center; color: var(--hs-muted); }

/* Polls */
.hs-polls { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.hs-polls .hs-poll { margin: 0; }
.hs-poll { display: grid; gap: 8px; align-content: start; }
.hs-opt { font: inherit; text-align: left; color: var(--hs-ink); background: #fff; border: 1px solid var(--hs-line); padding: 8px 12px; cursor: pointer; display: grid; grid-template-columns: 1fr auto; gap: 10px; position: relative; overflow: hidden; }
.hs-opt:hover:not([disabled]) { border-color: var(--hs-accent); }
.hs-opt[disabled] { cursor: default; opacity: 1; }
.hs-opt.is-mine { border-color: var(--hs-accent); }
.hs-opt-fill { position: absolute; inset: 0 auto 0 0; background: rgba(90, 60, 158, 0.18); z-index: 0; }
.hs-opt span { position: relative; z-index: 1; }

/* Garage list */
.hs-garage-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; margin-top: 12px; }
.hs-garage-item { background: #fff; border: 1px solid var(--hs-line); padding: 12px; display: grid; gap: 6px; }

@media (max-width: 860px) {
	.hs-layout { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
	.hs-slide { grid-template-areas: "media" "body" "credit"; }
	.hs-slide-media { grid-area: media; aspect-ratio: 4 / 3; }
	.hs-slide-body { grid-area: body; background: #0F1A26; padding: 16px; align-self: start; }
	.hs-bar-row { grid-template-columns: minmax(96px, 130px) 1fr auto; }
	.hs-garage-link { margin-left: 0; }
}
@media (prefers-reduced-motion: no-preference) {
	.hs-bar-fill { transition: width 0.35s ease; }
}
@media (prefers-reduced-motion: reduce) {
	.hs-slides { scroll-behavior: auto; }
}

/* Masthead and tagline */
.hs-masthead { margin: 0 0 20px; padding: 28px 0 8px; border-bottom: 4px solid #5A3C9E; }
.hs-masthead h1 { margin: 0; font-family: 'Barlow Condensed', 'Arial Narrow', sans-serif; font-size: clamp(40px, 8vw, 72px); line-height: 1; text-transform: uppercase; letter-spacing: .02em; }
.hs-masthead p, .hs-tagline { margin: 8px 0 12px; font-size: clamp(16px, 2.4vw, 20px); }
.hs-specs td { overflow-wrap: anywhere; }

/* Fast Facts slider (sidebar) */
.hs .hs-factbox { background: var(--hs-accent); border-color: var(--hs-accent); color: #fff; }
.hs .hs-factbox h2, .hs .hs-factbox .hs-label, .hs .hs-factbox .hs-src { color: #fff; }
.hs .hs-factbox .hs-label { opacity: 0.8; }
.hs-fslides { list-style: none; margin: 0; padding: 0; display: grid; }
.hs-fslide { display: grid; gap: 8px; align-content: start; min-width: 0; }
.hs-fslide p { margin: 0; font-size: 1.05rem; line-height: 1.45; }
.hs-factbox.is-js .hs-fslide { display: none; }
.hs-factbox.is-js .hs-fslide.is-active { display: grid; }
.hs-factbox:not(.is-js) .hs-fslide + .hs-fslide { margin-top: 14px; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, 0.3); }
.hs-src { text-decoration: underline; }
.hs-fnav { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.hs-fbtn { font: inherit; width: 34px; height: 30px; background: transparent; color: #fff; border: 1px solid rgba(255, 255, 255, 0.55); border-radius: 3px; cursor: pointer; }
.hs-fbtn:hover { background: rgba(255, 255, 255, 0.15); }
.hs-fdots { display: flex; flex: 1; gap: 6px; justify-content: center; flex-wrap: wrap; }
.hs-fdot { width: 18px; height: 5px; padding: 0; border: 0; border-radius: 0; background: rgba(255, 255, 255, 0.4); cursor: pointer; }
.hs-fdot[aria-current="true"] { background: #fff; }
.hs-factbox :focus-visible { outline-color: #fff; }

/* Car page header buttons */
.hs-btn--big, .hs-garage-big { font-size: 1.05rem; padding: 12px 24px; }
.hs-garage-big[aria-pressed="true"] { background: var(--hs-ink); border-color: var(--hs-ink); }

/* Production list in the spec table */
.hs-prod-list { display: block; margin-top: 2px; }
.hs-prod-line { display: block; }

/* Makes logo grid */
.hs-makes { margin: 0 0 20px; }
.hs-makes-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 10px; }
.hs-showall { font-size: 14px; text-decoration: underline; }
.hs-showall[aria-current="true"] { color: var(--hs-muted); text-decoration: none; pointer-events: none; }
.hs-logos { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.hs-logo { display: grid; grid-template-rows: 64px auto; gap: 6px; justify-items: center; align-items: center; padding: 12px 8px 8px; background: #fff; border: 1px solid var(--hs-line); text-decoration: none; text-align: center; min-width: 0; transition: filter 0.15s, opacity 0.15s; }
.hs-logo:hover { border-color: var(--hs-ink); }
.hs-logo-img { display: flex; align-items: center; justify-content: center; width: 100%; height: 64px; }
.hs-logo-img img { max-width: 100%; max-height: 64px; width: auto; height: auto; object-fit: contain; }
.hs-logo-name { font-family: var(--hs-mono); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--hs-muted); }
.hs-logo.is-missing { grid-template-rows: 1fr; min-height: 64px; }
.hs-logo.is-missing .hs-logo-img { display: none; }
.hs-logo.is-missing .hs-logo-name { font-family: var(--hs-display); font-size: 1.2rem; font-weight: 700; color: var(--hs-ink); }
.hs-logos.has-active .hs-logo:not(.is-on) { filter: grayscale(1); opacity: 0.4; }
.hs-logos.has-active .hs-logo:not(.is-on):hover { opacity: 0.8; }
.hs-logo.is-on { border-color: var(--hs-accent); box-shadow: 0 0 0 2px var(--hs-accent); }
