/**
 * Cup of Air — sitewide Black Friday promo (strip + modal + product offer).
 * Loaded only while campaign date gate (or ?coa_bf_sitewide=1) is active.
 *
 * Height is reserved from first paint via body.coa-bf-active (PHP).
 * JS mounts the fixed strip without changing layout (transform/opacity only).
 */

/* First-paint reserve — 40px desktop, 54px below 768px */
body.coa-bf-active,
body.coa-bf-strip-on {
	--coa-bf-strip-h: 40px;
	padding-top: var(--coa-bf-strip-h) !important;
}

@media (max-width: 767px) {
	body.coa-bf-active,
	body.coa-bf-strip-on {
		--coa-bf-strip-h: 54px;
	}
}

/*
 * Sticky = menu only under the BF strip.
 * Logo (#sp-logo-centered) stays in document flow and scrolls away — never
 * pinned, never resized, never injected into the sticky header.
 */
body.coa-bf-active #sp-header.sticky .sticky__wrapper,
body.coa-bf-active .sticky .sticky__wrapper,
body.coa-bf-strip-on #sp-header.sticky .sticky__wrapper,
body.coa-bf-strip-on .sticky .sticky__wrapper {
	top: var(--coa-bf-strip-h) !important;
	z-index: 1200 !important;
	background-color: #ffffff !important;
	background-image: none !important;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
}

/* Helix puts a compact logo inside sticky menu — keep it out */
body.coa-bf-active #sp-header.sticky .sp-sticky-logo,
body.coa-bf-active #sp-header.sticky .logo,
body.coa-bf-active #sp-header.sticky .has-sticky-logo,
body.coa-bf-strip-on #sp-header.sticky .sp-sticky-logo,
body.coa-bf-strip-on #sp-header.sticky .logo,
body.coa-bf-strip-on #sp-header.sticky .has-sticky-logo {
	display: none !important;
}

/* Beat Helix inline #sp-header a { color: #d9d9d9 } on sticky */
body.coa-bf-active #sp-header.sticky a:not(.coa-nav-cta),
body.coa-bf-active #sp-header.sticky #sp-menu .sp-megamenu-parent > li > a:not(.coa-nav-cta),
body.coa-bf-active #sp-header.sticky #sp-menu .sp-megamenu-parent > li > span,
body.coa-bf-strip-on #sp-header.sticky a:not(.coa-nav-cta),
body.coa-bf-strip-on #sp-header.sticky #sp-menu .sp-megamenu-parent > li > a:not(.coa-nav-cta),
body.coa-bf-strip-on #sp-header.sticky #sp-menu .sp-megamenu-parent > li > span {
	color: #013a58 !important;
}

body.coa-bf-active #offcanvas-toggler,
body.coa-bf-strip-on #offcanvas-toggler {
	top: calc(12px + var(--coa-bf-strip-h)) !important;
}

/* Shared BF discount gradient (matches landing .coa-bf-discount-value) */
.coa-bf-sw-discount {
	display: inline-flex;
	align-items: center;
	gap: 0.35em;
	line-height: 1;
}

.coa-bf-sw-discount-value,
.coa-bf-sw-discount-off {
	font-weight: 800;
	background: linear-gradient(115deg, #9ad6ff 0%, #c4a1ff 42%, #e8c989 100%);
	background-size: 100% 100%;
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	-webkit-text-fill-color: transparent;
	filter: none;
	animation: none;
}

.coa-bf-sw-discount-value {
	letter-spacing: 0.02em;
	text-transform: lowercase;
}

.coa-bf-sw-discount-off {
	letter-spacing: -0.03em;
	text-transform: none;
	font-weight: 900;
}

@keyframes coa-bf-sw-sheen {
	0%, 100% { background-position: 0% 50%; }
	50% { background-position: 100% 50%; }
}

@media (prefers-reduced-motion: reduce) {
	.coa-bf-sw-discount-value {
		animation: none;
	}
}

/* ——— Top strip (fixed — does not affect document flow; padding reserves space) ——— */
.coa-bf-strip {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 1300;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: var(--coa-bf-strip-h, 40px);
	padding: 8px 40px 8px 16px;
	box-sizing: border-box;
	background: #10182c;
	color: #f7f9fd;
	border-bottom: 1px solid rgba(170, 198, 235, 0.18);
	font-family: "Sofia Sans", "Segoe UI", sans-serif;
	font-size: 13px;
	line-height: 1.35;
	text-align: center;
	transform: translateY(0);
	opacity: 1;
	transition: transform 0.2s ease, opacity 0.2s ease;
	pointer-events: auto;
}

.coa-bf-strip.is-mounting {
	transform: translateY(-100%);
	opacity: 0;
}

/* Dismiss: hide visually, keep body padding until next navigation */
.coa-bf-strip.is-dismissed,
.coa-bf-strip[hidden] {
	transform: translateY(-100%);
	opacity: 0;
	pointer-events: none;
	visibility: hidden;
}

@media (prefers-reduced-motion: reduce) {
	.coa-bf-strip {
		transition: none;
	}
}

.coa-bf-strip-inner {
	display: inline-flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: center;
	gap: 0.45em;
	max-width: calc(100% - 36px);
}

.coa-bf-strip-link {
	display: inline-flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: center;
	gap: 0.45em;
	color: #f7f9fd !important;
	text-decoration: none !important;
	font-weight: 600;
	letter-spacing: 0.01em;
}

.coa-bf-strip-link:hover,
.coa-bf-strip-link:focus {
	text-decoration: none !important;
}

.coa-bf-strip-link:hover .coa-bf-strip-before,
.coa-bf-strip-link:focus .coa-bf-strip-before,
.coa-bf-strip-dates:hover,
.coa-bf-strip-dates:focus {
	color: #8fd0ff;
}

.coa-bf-strip-models {
	display: inline-flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.35em;
}

.coa-bf-strip-model {
	color: #9ad6ff !important;
	font-weight: 800;
	text-decoration: none !important;
	border-bottom: 1px solid rgba(154, 214, 255, 0.35);
}

.coa-bf-strip-model:hover,
.coa-bf-strip-model:focus {
	color: #c4e7ff !important;
	border-bottom-color: rgba(196, 231, 255, 0.75);
}

.coa-bf-strip-joiner {
	color: rgba(247, 249, 253, 0.72);
	font-weight: 500;
}

.coa-bf-strip-sep {
	opacity: 0.45;
	font-weight: 500;
}

/* Strip discount / offer line: sharp neon solids (no clip, no halo) */
.coa-bf-strip .coa-bf-sw-discount-value,
.coa-bf-strip .coa-bf-sw-discount-off,
.coa-bf-strip .coa-bf-sw-offer-line {
	background: none;
	-webkit-background-clip: border-box;
	background-clip: border-box;
	filter: none;
	text-shadow: none;
}

.coa-bf-strip .coa-bf-sw-discount-value {
	font-size: 1em;
	letter-spacing: 0.01em;
	font-weight: 800;
	color: #5ef0ff;
	-webkit-text-fill-color: #5ef0ff;
}

.coa-bf-strip .coa-bf-sw-discount-off {
	font-size: 1.2em;
	transform: none;
	font-weight: 900;
	color: #ff5ac8;
	-webkit-text-fill-color: #ff5ac8;
}

/* Quote-only offer line: same size as strip body so 40/54px reserve holds */
.coa-bf-strip .coa-bf-sw-offer-line {
	font-size: 1em;
	font-weight: 800;
	letter-spacing: 0.01em;
	color: #5ef0ff;
	-webkit-text-fill-color: #5ef0ff;
	line-height: 1.25;
}

.coa-bf-strip-dismiss {
	position: absolute;
	right: 8px;
	top: 50%;
	transform: translateY(-50%);
	width: 32px;
	height: 32px;
	padding: 0;
	border: 0;
	border-radius: 8px;
	background: transparent;
	color: rgba(247, 249, 253, 0.78);
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
}

.coa-bf-strip-dismiss:hover,
.coa-bf-strip-dismiss:focus {
	color: #fff;
	background: rgba(255, 255, 255, 0.08);
}

@media (max-width: 767px) {
	/* Dates drop on narrow so the −10% / 2+ line fits in the 54px reserve */
	.coa-bf-strip-dates,
	.coa-bf-strip-inner > .coa-bf-strip-sep:last-of-type {
		display: none;
	}
}

@media (max-width: 575px) {
	.coa-bf-strip {
		font-size: 11.5px;
		padding: 6px 36px 6px 12px;
	}

	.coa-bf-strip .coa-bf-sw-discount-value {
		font-size: 1.2em;
	}
}

/* ——— Soft modal ——— */
.coa-bf-modal {
	position: fixed;
	inset: 0;
	z-index: 1400;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	box-sizing: border-box;
}

.coa-bf-modal[hidden] {
	display: none !important;
}

.coa-bf-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(8, 12, 22, 0.72);
	backdrop-filter: none;
}

.coa-bf-modal-dialog {
	position: relative;
	z-index: 1;
	overflow: hidden;
	width: min(100%, 440px);
	padding: 32px 28px 28px;
	border-radius: 22px;
	background:
		radial-gradient(115% 75% at 50% -8%, #35507f 0%, transparent 58%),
		radial-gradient(85% 55% at 82% 18%, rgba(126, 78, 180, 0.34) 0%, transparent 54%),
		linear-gradient(180deg, #152038 0%, #1a2744 48%, #121a2e 100%);
	border: 1px solid rgba(170, 198, 235, 0.24);
	box-shadow: 0 28px 90px rgba(0, 0, 0, 0.5);
	color: #f7f9fd;
	font-family: "Sofia Sans", "Segoe UI", sans-serif;
	text-align: center;
}

.coa-bf-modal-glow {
	pointer-events: none;
	position: absolute;
	left: 50%;
	top: 18%;
	width: 220px;
	height: 120px;
	transform: translateX(-50%);
	background: radial-gradient(circle, rgba(126, 200, 255, 0.22) 0%, transparent 70%);
	filter: blur(8px);
}

.coa-bf-modal-close {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 2;
	width: 36px;
	height: 36px;
	border: 0;
	border-radius: 10px;
	background: transparent;
	color: rgba(247, 249, 253, 0.8);
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}

.coa-bf-modal-close:hover,
.coa-bf-modal-close:focus {
	color: #fff;
	background: rgba(255, 255, 255, 0.08);
}

.coa-bf-modal-title {
	position: relative;
	margin: 0 0 6px;
	padding: 0;
	font: inherit;
	font-weight: inherit;
	color: inherit;
	text-align: center;
}

.coa-bf-sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.coa-bf-modal-eyebrow {
	position: relative;
	display: block;
	margin: 0 0 10px;
	font-size: 13px;
	font-weight: 800;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: #f7f9fd;
}

.coa-bf-modal-offer {
	position: relative;
	display: block;
	margin: 0;
}

.coa-bf-modal-offer .coa-bf-sw-discount {
	justify-content: center;
	gap: 10px;
}

.coa-bf-modal-offer .coa-bf-sw-discount-value {
	font-size: clamp(22px, 5vw, 32px);
	letter-spacing: 0.02em;
	filter: drop-shadow(0 0 28px rgba(126, 200, 255, 0.34));
}

.coa-bf-modal-offer .coa-bf-sw-discount-off {
	font-size: clamp(42px, 10vw, 64px);
	transform: none;
}

.coa-bf-modal-dates {
	position: relative;
	margin: 0 0 14px;
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.04em;
	color: rgba(222, 232, 248, 0.88);
}

.coa-bf-modal-models {
	position: relative;
	margin: 0 0 10px;
	font-size: clamp(20px, 4.5vw, 24px);
	font-weight: 800;
	line-height: 1.25;
	color: #9ad6ff;
}

.coa-bf-modal-lead {
	position: relative;
	margin: 0 0 22px;
	font-size: 15px;
	line-height: 1.45;
	color: rgba(222, 232, 248, 0.86);
}

.coa-bf-modal-cta {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 50px;
	padding: 12px 26px;
	border-radius: 999px;
	background: linear-gradient(105deg, #9ad6ff 0%, #7ec8ff 45%, #5aa8f0 100%);
	color: #041018 !important;
	font-weight: 800;
	font-size: 15px;
	text-decoration: none !important;
	border: 0;
	box-shadow: 0 10px 28px rgba(90, 168, 240, 0.28);
}

.coa-bf-modal-cta:hover,
.coa-bf-modal-cta:focus {
	filter: brightness(1.06);
	color: #041018 !important;
}

body.coa-bf-modal-open {
	overflow: hidden;
}

/* ——— Product detail offer ——— */
.coa-bf-pd-offer {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 8px;
	margin: 16px 0 4px;
	padding: 14px 16px;
	border-radius: 14px;
	background: rgba(16, 24, 44, 0.92);
	border: 1px solid rgba(143, 208, 255, 0.28);
	color: #f7f9fd;
	font-family: "Sofia Sans", "Segoe UI", sans-serif;
}

.coa-bf-pd-badge {
	display: inline-flex;
	align-items: center;
	padding: 4px 10px;
	border-radius: 999px;
	border: 1px solid rgba(154, 214, 255, 0.45);
	background: linear-gradient(115deg, #9ad6ff 0%, #c4a1ff 42%, #e8c989 100%);
	color: #0a1220;
	font-size: 12px;
	font-weight: 800;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	box-shadow: 0 0 16px rgba(126, 200, 255, 0.28);
}

.coa-bf-pd-text {
	margin: 0;
	font-size: 14px;
	line-height: 1.4;
	color: rgba(222, 232, 248, 0.92);
}

.coa-bf-pd-cta {
	display: inline-flex;
	align-items: center;
	margin-top: 2px;
	font-size: 14px;
	font-weight: 700;
	color: #8fd0ff !important;
	text-decoration: underline !important;
	text-underline-offset: 3px;
}

.coa-bf-pd-cta:hover,
.coa-bf-pd-cta:focus {
	color: #b8e0ff !important;
}
