/*!
 * Bollard Boys Site — 01 Bollard Selector.
 * Section chrome (templates/sections/selector.php) + the .bs-* markup that
 * assets/js/bollard-selector.js renders into #bbs-selector-mount.
 *
 * Ported from BollardSelector.module.css and handoff/bollard-selector.css.
 * Every selector starts `body.bbs-active .bbs-home` — see bbs-tokens.css.
 * Deliberately no overflow on the section: the result card is position:sticky,
 * and any overflow other than visible on an ancestor silently disables it.
 */

/* ==========================================================================
   Section chrome
   ========================================================================== */

body.bbs-active .bbs-home .bbs-selector {
	position: relative;
	background: var(--bbs-dark-navy);
	color: var(--bbs-surface);
}

/* Monogram watermark. Sits inside the section's right edge at every width it is
   shown, so nothing needs clipping. */
body.bbs-active .bbs-home img.bbs-selector__watermark {
	position: absolute;
	top: 60px;
	right: 52px;
	width: 280px;
	max-width: none;
	height: auto;
	filter: invert(1);
	mix-blend-mode: screen;
	opacity: 0.07;
	pointer-events: none;
	transform: rotate(-0.2deg);
	user-select: none;
}

body.bbs-active .bbs-home .bbs-selector__inner {
	position: relative;
	padding-block: 96px 104px;
}

body.bbs-active .bbs-home .bbs-selector__head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 24px 48px;
	margin-bottom: 44px;
}

body.bbs-active .bbs-home .bbs-selector__copy {
	max-width: 56ch;
	min-width: 0;
}

body.bbs-active .bbs-home .bbs-selector__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	margin: 0;
	font-family: var(--bbs-font-mono);
	font-size: var(--bbs-fs-meta, 12px);
	line-height: 1.4;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--bbs-blue-200);
}

body.bbs-active .bbs-home .bbs-selector__rule {
	display: block;
	flex: none;
	width: 26px;
	height: 2px;
	background: var(--bbs-accent);
}

body.bbs-active .bbs-home h2.bbs-selector__title {
	margin: 16px 0;
	font-family: var(--bbs-font-display);
	font-weight: 800;
	font-size: 54px;
	line-height: 1.02;
	letter-spacing: -0.03em;
	color: var(--bbs-surface);
}

body.bbs-active .bbs-home .bbs-selector__lede {
	margin: 0;
	font-size: 19px;
	line-height: 1.55;
	color: var(--bbs-on-dark-mid);
}

body.bbs-active .bbs-home .bbs-selector__standard {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0;
}

body.bbs-active .bbs-home .bbs-selector__standard-label,
body.bbs-active .bbs-home .bbs-selector__standard-badge {
	font-family: var(--bbs-font-mono);
	font-size: var(--bbs-fs-meta, 12px);
	line-height: 1.4;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

body.bbs-active .bbs-home .bbs-selector__standard-label {
	color: var(--bbs-on-dark-faint);
}

body.bbs-active .bbs-home .bbs-selector__standard-badge {
	padding: 9px 14px;
	border: 1px solid rgba(255, 255, 255, 0.2);
	color: var(--bbs-blue-200);
}

/* Moved out of the card by the plugin (the renderer does not draw it), so it now
   sits on navy: --bbs-faint would fail AA here, the on-dark alpha passes. */
body.bbs-active .bbs-home .bbs-selector__disclaimer {
	margin: 20px 0 0;
	font-family: var(--bbs-font-mono);
	font-size: var(--bbs-fs-label, 13px);
	letter-spacing: 0.02em;
	line-height: 1.7;
	color: var(--bbs-on-dark-low);
}

/* On desktop, once the two-column grid exists, align it under the card column
   (1.3fr / 1fr with a 26px gap). Without a mounted grid it stays flush left. */
@media (min-width: 1081px) {
	body.bbs-active .bbs-home .bbs-selector__mount--ready ~ .bbs-selector__disclaimer {
		margin-left: calc((100% - 26px) * 1.3 / 2.3 + 26px);
	}
}

body.bbs-active .bbs-home .bbs-selector__noscript {
	margin: 0;
	padding: 22px 24px;
	border: 1px solid rgba(255, 255, 255, 0.12);
	background: rgba(255, 255, 255, 0.04);
	font-size: 17px;
	line-height: 1.55;
	color: var(--bbs-on-dark-hi);
}

body.bbs-active .bbs-home a.bbs-selector__noscript-link {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	font-family: var(--bbs-font-display);
	font-weight: 700;
	color: var(--bbs-blue-100);
	text-decoration: underline;
	text-underline-offset: 3px;
}

body.bbs-active .bbs-home a.bbs-selector__noscript-link:hover {
	color: var(--bbs-surface);
}

/* ==========================================================================
   Renderer markup (.bs-*). The mount element receives .bs-root from mount().
   ========================================================================== */

body.bbs-active .bbs-home .bs-root {
	display: grid;
	grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
	gap: 26px;
	align-items: start;
}

/* Question panel ---------------------------------------------------------- */

body.bbs-active .bbs-home .bs-questions {
	min-width: 0;
	padding: 8px;
	border: 1px solid rgba(255, 255, 255, 0.12);
	background: rgba(255, 255, 255, 0.04);
}

body.bbs-active .bbs-home .bs-step {
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 22px 24px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}

body.bbs-active .bbs-home .bs-step:last-child {
	border-bottom: 0;
}

/* Step 07 is no longer :last-child now that the summary row follows it; it keeps
   the closing edge wherever that row is hidden. */
body.bbs-active .bbs-home .bs-step.bs-step-width {
	border-bottom: 0;
}

/* The width step's label is a real <label>: Hello Elementor gives labels
   inline-block + line-height 1, so every property is restated. */
body.bbs-active .bbs-home .bs-step-label {
	display: flex;
	align-items: center;
	gap: 11px;
	margin: 0;
	padding: 0;
	font-family: var(--bbs-font-mono);
	font-size: var(--bbs-fs-label, 13px);
	font-weight: 400;
	line-height: 1.4;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	white-space: pre-wrap; /* keeps the renderer's two-space gap after the number */
	color: rgba(255, 255, 255, 0.55);
}

body.bbs-active .bbs-home .bs-options {
	display: flex;
	flex-wrap: wrap;
	gap: 9px;
}

/* Chips. Selected = filled accent; filled-vs-outline survives greyscale, so the
   state is not signalled by hue alone. Hello Elementor paints button:hover and
   button:focus pink and the Elementor kit restyles button:hover at (0,2,1); this
   rule is (0,3,1) and every state below is higher still. */
body.bbs-active .bbs-home .bs-chip {
	display: block;
	max-width: 100%;
	min-height: 44px;
	min-width: 44px;
	margin: 0;
	padding: 12px 15px;
	border: 1px solid rgba(255, 255, 255, 0.16);
	border-radius: 0;
	background: rgba(255, 255, 255, 0.03);
	box-shadow: none;
	color: var(--bbs-surface);
	font-family: var(--bbs-font-display);
	line-height: 1.2;
	text-align: left;
	text-transform: none;
	letter-spacing: normal;
	white-space: normal;
	cursor: pointer;
	transition: border-color 120ms ease, background-color 120ms ease;
}

body.bbs-active .bbs-home .bs-chip:hover,
body.bbs-active .bbs-home .bs-chip:focus {
	border-color: var(--bbs-accent);
	background: rgba(255, 255, 255, 0.03);
	color: var(--bbs-surface);
}

body.bbs-active .bbs-home .bs-chip.bs-chip-on,
body.bbs-active .bbs-home .bs-chip.bs-chip-on:hover,
body.bbs-active .bbs-home .bs-chip.bs-chip-on:focus {
	border-color: var(--bbs-accent);
	background: var(--bbs-accent);
	color: var(--bbs-surface);
}

/* Restore the two-tone focus ring from bbs-tokens.css: the resets above set
   box-shadow:none at equal or higher specificity, which would strip its white
   halo (accent alone is under 3:1 on navy). Functional, not decorative. */
body.bbs-active .bbs-home .bs-chip:focus-visible,
body.bbs-active .bbs-home input.bs-slider[type="range"]:focus-visible {
	outline: 2px solid var(--bbs-accent);
	outline-offset: 2px;
	box-shadow: 0 0 0 2px var(--bbs-surface);
}

body.bbs-active .bbs-home .bs-chip-label {
	display: block;
	font-family: var(--bbs-font-display);
	font-weight: 600;
	font-size: 14.5px;
	overflow-wrap: anywhere;
}

/* Full opacity on the accent fill: 0.62 white there is 2.92:1 and fails AA for
   12px text. Unselected chips sit on the near-black panel, where 0.62 passes. */
body.bbs-active .bbs-home .bs-chip-sub {
	display: block;
	margin-top: 4px;
	font-family: var(--bbs-font-mono);
	font-size: var(--bbs-fs-meta, 12px);
	font-weight: 400;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	overflow-wrap: anywhere;
}

body.bbs-active .bbs-home .bs-chip:not(.bs-chip-on) .bs-chip-sub {
	opacity: 0.62;
}

/* Width ------------------------------------------------------------------- */

body.bbs-active .bbs-home .bs-width-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 20px;
}

/* input[type="range"] raises specificity above the Elementor kit's
   `.elementor-kit-N input:not([type=button]):not([type=submit])` (0,3,1). */
body.bbs-active .bbs-home input.bs-slider[type="range"] {
	flex: 1;
	min-width: 220px;
	height: 44px; /* touch target; the native track stays centred */
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	accent-color: var(--bbs-accent);
	cursor: pointer;
}

body.bbs-active .bbs-home .bs-width-value {
	font-family: var(--bbs-font-display);
	font-weight: 800;
	font-size: 26px;
	line-height: 1.2;
	letter-spacing: -0.02em;
	color: var(--bbs-surface);
	white-space: nowrap;
}

/* Summary row ------------------------------------------------------------- */

/* Repeats the rating, system and quote link after the last question. The renderer
   sets an inline display:none; only the <=1080px rule below shows it. */
body.bbs-active .bbs-home .bs-summary {
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px 24px;
	padding: 22px 24px;
}

body.bbs-active .bbs-home p.bs-summary-text {
	display: flex;
	flex: 1 1 220px;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
	margin: 0;
}

body.bbs-active .bbs-home .bs-summary-rating {
	font-family: var(--bbs-font-display);
	font-weight: 800;
	font-size: 20px;
	line-height: 1.1;
	letter-spacing: -0.01em;
	color: var(--bbs-surface);
}

body.bbs-active .bbs-home .bs-summary-title {
	font-family: var(--bbs-font-display);
	font-weight: 600;
	font-size: 16px;
	line-height: 1.3;
	overflow-wrap: break-word;
	color: var(--bbs-on-dark-hi);
}

body.bbs-active .bbs-home a.bs-summary-cta {
	display: block;
	flex: 0 0 auto;
	min-height: 44px;
	padding: 15px 22px;
	background: var(--bbs-accent);
	color: var(--bbs-surface);
	font-family: var(--bbs-font-display);
	font-weight: 700;
	font-size: 14.5px;
	line-height: 1.3;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	text-align: center;
	text-decoration: none;
}

body.bbs-active .bbs-home a.bs-summary-cta:hover,
body.bbs-active .bbs-home a.bs-summary-cta:focus {
	background: var(--bbs-surface);
	color: var(--bbs-navy);
}

/* Result card ------------------------------------------------------------- */

body.bbs-active .bbs-home .bs-card {
	position: sticky;
	top: calc(var(--bbs-header-h) + var(--bbs-adminbar) + 20px);
	min-width: 0;
	background: var(--bbs-surface);
	color: var(--bbs-text);
}

body.bbs-active .bbs-home .bs-card-head {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 18px;
	padding: 26px 28px;
	background: var(--bbs-navy);
	color: var(--bbs-surface);
}

body.bbs-active .bbs-home .bs-card-eyebrow {
	font-family: var(--bbs-font-mono);
	font-size: var(--bbs-fs-meta, 12px);
	line-height: 1.4;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--bbs-blue-100);
}

body.bbs-active .bbs-home .bs-card-rating {
	font-family: var(--bbs-font-display);
	font-weight: 800;
	font-size: 30px;
	line-height: 1;
	letter-spacing: -0.02em;
	white-space: nowrap;
}

/* The plate: 216px tall, photo fills the whole box; object-fit (cover or
   contain) is set inline per recommendation by the renderer. #f1f3f5 is the
   design's plate grey and has no token. */
body.bbs-active .bbs-home .bs-card-photo {
	position: relative;
	height: 216px;
	background: #f1f3f5;
	border-bottom: 1px solid var(--bbs-border-soft);
}

body.bbs-active .bbs-home .bs-card-photo img {
	position: absolute;
	inset: 0;
	display: block;
	width: 100%;
	max-width: none;
	height: 100%;
	object-position: center;
}

body.bbs-active .bbs-home .bs-card-body {
	display: flex;
	flex-direction: column;
	gap: 20px;
	padding: 28px 28px 30px;
}

body.bbs-active .bbs-home h3.bs-card-title {
	margin: 0;
	font-family: var(--bbs-font-display);
	font-weight: 700;
	font-size: 27px;
	line-height: 1.14;
	letter-spacing: -0.02em;
	color: var(--bbs-text);
}

body.bbs-active .bbs-home .bs-card-note {
	margin: 0;
	font-size: 16px;
	line-height: 1.55;
	color: var(--bbs-body-alt);
}

body.bbs-active .bbs-home .bs-specs {
	display: flex;
	flex-direction: column;
}

body.bbs-active .bbs-home .bs-spec-row {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 16px;
	padding: 13px 0;
	border-top: 1px solid var(--bbs-border-soft);
}

body.bbs-active .bbs-home .bs-spec-k {
	flex: 0 1 auto;
	font-family: var(--bbs-font-mono);
	font-size: var(--bbs-fs-label, 13px);
	line-height: 1.5;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	color: var(--bbs-muted-alt);
}

body.bbs-active .bbs-home .bs-spec-v {
	flex: 0 1 auto;
	min-width: 0;
	font-family: var(--bbs-font-display);
	font-weight: 600;
	font-size: 15.5px;
	line-height: 1.35;
	text-align: right;
	overflow-wrap: break-word;
	color: var(--bbs-text);
}

body.bbs-active .bbs-home a.bs-card-cta {
	display: block;
	min-height: 44px;
	padding: 19px 26px;
	background: var(--bbs-navy);
	color: var(--bbs-surface);
	font-family: var(--bbs-font-display);
	font-weight: 700;
	font-size: 14.5px;
	line-height: 1.3;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	text-align: center;
	text-decoration: none;
}

body.bbs-active .bbs-home a.bs-card-cta:hover,
body.bbs-active .bbs-home a.bs-card-cta:focus {
	background: var(--bbs-accent);
	color: var(--bbs-surface);
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 1180px) {
	body.bbs-active .bbs-home img.bbs-selector__watermark {
		width: 240px;
		right: 40px;
	}
}

/* Below 1080px the card loses its sticky pin, so it moves above the questions —
   otherwise the answer sits ~1700px below the last question on a phone. */
@media (max-width: 1080px) {
	body.bbs-active .bbs-home img.bbs-selector__watermark {
		display: none;
	}

	body.bbs-active .bbs-home .bs-root {
		grid-template-columns: minmax(0, 1fr);
	}

	body.bbs-active .bbs-home .bs-card {
		position: static;
		order: -1;
	}

	body.bbs-active .bbs-home .bs-step.bs-step-width {
		border-bottom: 1px solid rgba(255, 255, 255, 0.09);
	}

	/* !important beats the renderer's inline display:none (see .bs-summary above). */
	body.bbs-active .bbs-home .bs-summary {
		display: flex !important;
	}
}

@media (max-width: 980px) {
	body.bbs-active .bbs-home .bbs-selector__head {
		margin-bottom: 36px;
	}
}

@media (max-width: 900px) {
	body.bbs-active .bbs-home h2.bbs-selector__title {
		font-size: 40px;
	}

	body.bbs-active .bbs-home .bbs-selector__lede {
		font-size: 17px;
	}
}

@media (max-width: 640px) {
	body.bbs-active .bbs-home .bs-step,
	body.bbs-active .bbs-home .bs-summary {
		padding: 18px 16px;
	}

	body.bbs-active .bbs-home a.bs-summary-cta {
		flex: 1 1 100%;
		padding: 15px 18px;
	}

	/* The 220px floor plus the panel padding overflowed below ~324px. */
	body.bbs-active .bbs-home input.bs-slider[type="range"] {
		min-width: 160px;
	}

	body.bbs-active .bbs-home .bs-card-head {
		flex-wrap: wrap;
		padding: 20px;
	}

	body.bbs-active .bbs-home .bs-card-body {
		padding: 22px 20px 24px;
	}

	body.bbs-active .bbs-home h3.bs-card-title {
		font-size: 23px;
	}

	body.bbs-active .bbs-home a.bs-card-cta {
		padding: 17px 18px;
	}

	body.bbs-active .bbs-home .bbs-selector__noscript {
		padding: 18px 16px;
	}
}

@media (max-width: 380px) {
	body.bbs-active .bbs-home h2.bbs-selector__title {
		font-size: 34px;
	}

	body.bbs-active .bbs-home .bs-questions {
		padding: 4px;
	}

	body.bbs-active .bbs-home .bs-step,
	body.bbs-active .bbs-home .bs-summary {
		padding: 16px 12px;
	}

	body.bbs-active .bbs-home .bs-chip {
		padding: 11px 12px;
	}

	body.bbs-active .bbs-home .bs-width-value {
		font-size: 22px;
	}

	body.bbs-active .bbs-home .bs-spec-row {
		gap: 12px;
	}
}
