/*
 * Bundle offer section.
 *
 * Ported from the Stitch mockup, which was built on the Tailwind CDN. Loading
 * that CDN inside WordPress would drag in Preflight and reset the whole theme,
 * so every utility it used is written out here instead. Everything is scoped
 * under .hbo-root and prefixed hbo-, because the home page already owns
 * ham-btn / ham-step and generic names collide with Glozin.
 */

.hbo-root {
	--hbo-primary: #a62658;
	--hbo-primary-dark: #8c0c45;
	--hbo-primary-soft: #ffd9e1;
	--hbo-accent: #d0473e;
	--hbo-secondary: #af2f29;
	--hbo-surface: #fbf9f7;
	--hbo-card: #ffffff;
	--hbo-low: #f5f3f1;
	--hbo-container: #efedec;
	--hbo-high: #eae8e6;
	--hbo-highest: #e4e2e0;
	--hbo-ink: #1b1c1b;
	--hbo-ink-soft: #574146;
	--hbo-outline: #8a7176;
	--hbo-outline-soft: #ddbfc5;
	--hbo-error-bg: #ffdad6;
	--hbo-error-ink: #93000a;

	--hbo-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
	--hbo-serif: 'Bodoni Moda', Georgia, 'Times New Roman', serif;

	box-sizing: border-box;
	width: 100%;
	max-width: 1440px;
	margin: 0 auto;
	padding: 8px 0 48px;
	font-family: var(--hbo-sans);
	color: var(--hbo-ink);
	line-height: 1.5;
}

.hbo-root *,
.hbo-root *::before,
.hbo-root *::after {
	box-sizing: border-box;
}

/* Glozin styles headings and buttons globally; re-assert ours. */
.hbo-root h2,
.hbo-root h3,
.hbo-root p,
.hbo-root ul {
	margin: 0;
	padding: 0;
}

.hbo-headline {
	font-family: var(--hbo-serif);
	font-weight: 500;
	letter-spacing: -0.01em;
}

/* -------------------------------------------------- bundle selector strip */

.hbo-picker {
	margin-bottom: 32px;
}

.hbo-picker-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 14px;
	flex-wrap: wrap;
}

.hbo-picker-title {
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--hbo-ink-soft);
}

.hbo-picker-count {
	font-size: 13px;
	color: var(--hbo-ink-soft);
}

/* A row on desktop, a swipeable rail on phones. */
.hbo-picker-rail {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: minmax(220px, 1fr);
	gap: 12px;
	overflow-x: auto;
	padding-bottom: 6px;
	scrollbar-width: thin;
}

.hbo-chip {
	display: flex;
	gap: 12px;
	align-items: center;
	text-align: left;
	padding: 12px;
	border: 1.5px solid var(--hbo-highest);
	border-radius: 12px;
	background: var(--hbo-card);
	cursor: pointer;
	transition: border-color .2s, box-shadow .2s, transform .2s;
	font-family: inherit;
	color: inherit;
	width: 100%;
}

/* Glozin paints its own background and colour on button:hover / :focus /
   :active, which turned the selected chip solid black. These re-assert ours
   at a specificity the theme cannot reach. */
.hbo-root .hbo-chip,
.hbo-root .hbo-chip:hover,
.hbo-root .hbo-chip:focus,
.hbo-root .hbo-chip:active,
.hbo-root .hbo-chip[aria-selected="true"] {
	background: var(--hbo-card);
	color: var(--hbo-ink);
	box-shadow: none;
}

.hbo-root .hbo-chip:hover {
	border-color: var(--hbo-outline-soft);
	transform: translateY(-2px);
	box-shadow: 0 8px 20px -12px rgba(166, 38, 88, .45);
}

.hbo-root .hbo-chip[aria-selected="true"] {
	border-color: var(--hbo-primary);
	background: linear-gradient(0deg, rgba(255, 217, 225, .35), rgba(255, 217, 225, .35)), var(--hbo-card);
	box-shadow: 0 0 0 3px rgba(166, 38, 88, .12);
}

.hbo-chip:focus-visible {
	outline: 3px solid var(--hbo-primary);
	outline-offset: 2px;
}

.hbo-chip-thumb {
	width: 46px;
	height: 46px;
	flex: 0 0 46px;
	border-radius: 9px;
	object-fit: cover;
	background: var(--hbo-container);
}

.hbo-chip-body {
	min-width: 0;
}

.hbo-chip-name {
	font-size: 14px;
	font-weight: 600;
	line-height: 1.3;
	/* Two lines then ellipsis, so a long bundle name cannot stretch the rail. */
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.hbo-chip-meta {
	font-size: 12px;
	color: var(--hbo-ink-soft);
	margin-top: 3px;
}

.hbo-chip-price {
	color: var(--hbo-primary);
	font-weight: 700;
}

.hbo-chip.is-ended {
	opacity: .55;
}

.hbo-chip.is-ended .hbo-chip-price {
	color: var(--hbo-ink-soft);
}

/* ------------------------------------------------------------- promo card */

.hbo-card {
	position: relative;
	background: var(--hbo-card);
	border: 2px dashed var(--hbo-outline-soft); /* running-stitch edge */
	border-radius: 16px;
	box-shadow: 0 20px 45px -30px rgba(27, 28, 27, .45);
	padding: 32px;
	overflow: hidden;
}

/* Soft colour wash in two corners. */
.hbo-card::before,
.hbo-card::after {
	content: '';
	position: absolute;
	width: 380px;
	height: 380px;
	border-radius: 50%;
	filter: blur(80px);
	pointer-events: none;
	z-index: 0;
}

.hbo-card::before {
	top: -90px;
	right: -90px;
	background: rgba(166, 38, 88, .07);
}

.hbo-card::after {
	bottom: -90px;
	left: -90px;
	background: rgba(175, 47, 41, .06);
}

.hbo-card > * {
	position: relative;
	z-index: 1;
}

.hbo-top {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 24px;
	margin-bottom: 28px;
	flex-wrap: wrap;
}

.hbo-eyebrow {
	display: inline-block;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--hbo-primary);
	background: rgba(255, 217, 225, .6);
	padding: 5px 12px;
	border-radius: 999px;
	margin-bottom: 12px;
}

.hbo-title {
	font-family: var(--hbo-serif);
	font-size: 40px;
	line-height: 1.1;
	letter-spacing: -0.02em;
	font-weight: 500;
	color: var(--hbo-ink);
}

.hbo-tagline {
	font-size: 17px;
	line-height: 1.6;
	color: var(--hbo-ink-soft);
	margin-top: 10px;
	max-width: 46em;
}

/* The design count is the loudest number in the block. */
.hbo-stat {
	display: flex;
	align-items: center;
	gap: 16px;
	background: var(--hbo-low);
	padding: 16px 22px;
	border-radius: 12px;
	flex: 0 0 auto;
}

.hbo-stat-icon {
	width: 46px;
	height: 46px;
	border-radius: 50%;
	background: var(--hbo-primary-soft);
	color: var(--hbo-primary);
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 46px;
}

.hbo-stat-num {
	font-family: var(--hbo-serif);
	font-size: 26px;
	font-weight: 600;
	line-height: 1.2;
	white-space: nowrap;
}

.hbo-stat-label {
	font-size: 10px;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--hbo-ink-soft);
	margin-top: 2px;
}

/* ----------------------------------------------------------- spec badges */

.hbo-specs {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	padding-bottom: 26px;
	margin-bottom: 30px;
	border-bottom: 1px solid var(--hbo-highest);
	list-style: none;
}

.hbo-spec {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 15px;
	border-radius: 999px;
	background: var(--hbo-container);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.03em;
}

.hbo-spec svg {
	color: var(--hbo-primary);
	flex: 0 0 auto;
}

/* --------------------------------------------------------------- columns */

.hbo-grid {
	display: grid;
	grid-template-columns: 5fr 7fr;
	gap: 28px;
	align-items: stretch;
	margin-bottom: 30px;
}

.hbo-buy {
	background: var(--hbo-low);
	padding: 28px;
	border-radius: 12px;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

.hbo-deal {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 14px;
	flex-wrap: wrap;
}

.hbo-off {
	background: var(--hbo-accent);
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	padding: 5px 12px;
	border-radius: 999px;
}

.hbo-save {
	font-size: 12px;
	color: var(--hbo-ink-soft);
	font-weight: 600;
}

.hbo-prices {
	display: flex;
	align-items: baseline;
	gap: 14px;
	flex-wrap: wrap;
	margin-bottom: 6px;
}

.hbo-price {
	font-family: var(--hbo-serif);
	font-size: 46px;
	line-height: 1.1;
	font-weight: 500;
	color: var(--hbo-primary);
}

.hbo-was {
	font-size: 20px;
	color: var(--hbo-outline);
	text-decoration: line-through;
}

.hbo-per {
	font-size: 13px;
	color: var(--hbo-ink-soft);
	font-weight: 500;
}

/* The 48-hour rule must be visible before payment, so it sits directly
   above the button rather than in the fine print. */
.hbo-window {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	background: var(--hbo-surface);
	padding: 12px 16px;
	border-radius: 9px;
	font-size: 13px;
	margin: 22px 0 16px;
}

.hbo-window svg {
	color: var(--hbo-primary);
	flex: 0 0 auto;
	margin-top: 1px;
}

.hbo-cta {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	width: 100%;
	padding: 16px 20px;
	border: 0;
	border-radius: 12px;
	background: var(--hbo-primary);
	color: #fff;
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.05em;
	cursor: pointer;
	text-decoration: none;
	transition: background-color .25s, transform .25s, box-shadow .25s;
}

.hbo-root .hbo-cta,
.hbo-root .hbo-cta:link,
.hbo-root .hbo-cta:visited {
	background: var(--hbo-primary);
	color: #fff;
}

.hbo-root .hbo-cta:hover,
.hbo-root .hbo-cta:focus,
.hbo-root .hbo-cta:active {
	background: var(--hbo-primary-dark);
	color: #fff;
	transform: translateY(-2px);
	box-shadow: 0 10px 25px -5px rgba(166, 38, 88, .3);
}

.hbo-cta:focus-visible {
	outline: 3px solid var(--hbo-primary-dark);
	outline-offset: 3px;
}

.hbo-cta.is-loading {
	opacity: .7;
	pointer-events: none;
}

.hbo-inside {
	display: block;
	text-align: center;
	margin-top: 14px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.04em;
	color: var(--hbo-ink-soft);
	text-underline-offset: 4px;
}

.hbo-inside:hover {
	color: var(--hbo-primary);
}

/* ------------------------------------------------------------- countdown */

.hbo-right {
	display: flex;
	flex-direction: column;
	gap: 22px;
}

.hbo-timer {
	background: var(--hbo-container);
	padding: 22px;
	border-radius: 12px;
}

.hbo-timer-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 16px;
	flex-wrap: wrap;
}

.hbo-timer-title {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--hbo-ink-soft);
}

.hbo-timer-title svg {
	color: var(--hbo-secondary);
}

.hbo-timer-note {
	font-size: 13px;
	color: var(--hbo-secondary);
	font-weight: 500;
}

.hbo-clock {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 10px;
	text-align: center;
	margin-bottom: 14px;
}

.hbo-unit {
	background: var(--hbo-surface);
	padding: 12px 6px;
	border-radius: 9px;
}

.hbo-unit-num {
	font-family: var(--hbo-serif);
	font-size: 26px;
	font-weight: 600;
	color: var(--hbo-primary);
	font-variant-numeric: tabular-nums;
}

.hbo-unit-label {
	font-size: 10px;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--hbo-ink-soft);
	margin-top: 3px;
}

.hbo-scarcity {
	font-size: 13px;
	text-align: center;
	color: var(--hbo-ink-soft);
}

/* --------------------------------------------------------------- gallery */

.hbo-gal-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 12px;
	flex-wrap: wrap;
}

.hbo-gal-title {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--hbo-ink-soft);
}

.hbo-gal-note {
	font-size: 13px;
	color: var(--hbo-primary);
	font-weight: 500;
}

.hbo-gal {
	display: grid;
	grid-template-columns: repeat(6, 1fr);
	gap: 10px;
}

.hbo-tile {
	aspect-ratio: 1 / 1;
	border-radius: 9px;
	overflow: hidden;
	background: var(--hbo-container);
	position: relative;
}

.hbo-tile img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.hbo-tile-more {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	border: 1px solid rgba(221, 191, 197, .5);
	padding: 4px;
}

.hbo-tile-more strong {
	font-size: 14px;
	color: var(--hbo-primary);
	font-weight: 700;
}

.hbo-tile-more span {
	font-size: 10px;
	letter-spacing: 0.02em;
	text-transform: uppercase;
	color: var(--hbo-ink-soft);
}

/* ------------------------------------------------------------- trust row */

.hbo-trust {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	flex-wrap: wrap;
	padding-top: 24px;
	border-top: 1px solid var(--hbo-highest);
	font-size: 13px;
	color: var(--hbo-ink-soft);
	list-style: none;
}

.hbo-trust li {
	display: flex;
	align-items: center;
	gap: 8px;
}

.hbo-trust svg {
	color: var(--hbo-primary);
	flex: 0 0 auto;
}

/* --------------------------------------------------------- ended variant */

.hbo-ended-badge {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: var(--hbo-error-bg);
	color: var(--hbo-error-ink);
	padding: 7px 14px;
	border-radius: 999px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	margin-bottom: 16px;
}

.hbo-ended-title {
	font-family: var(--hbo-serif);
	font-size: 26px;
	font-weight: 600;
	margin-bottom: 8px;
}

.hbo-ended-text {
	font-size: 15px;
	color: var(--hbo-ink-soft);
}

.hbo-alt {
	background: var(--hbo-surface);
	padding: 18px;
	border-radius: 9px;
	border: 1px solid rgba(221, 191, 197, .3);
	margin-top: 22px;
}

.hbo-alt p {
	font-size: 13px;
	font-weight: 500;
	margin-bottom: 12px;
}

.hbo-alt-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	padding: 12px;
	border-radius: 9px;
	background: var(--hbo-highest);
	color: var(--hbo-ink);
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	transition: background-color .2s;
}

.hbo-root .hbo-alt-btn,
.hbo-root .hbo-alt-btn:link,
.hbo-root .hbo-alt-btn:visited {
	background: var(--hbo-highest);
	color: var(--hbo-ink);
}

.hbo-root .hbo-alt-btn:hover,
.hbo-root .hbo-alt-btn:focus {
	background: var(--hbo-outline-soft);
	color: var(--hbo-ink);
}

/* The card keeps its shape when the offer is over; only buying disappears. */
.hbo-card.is-ended .hbo-timer {
	opacity: .5;
}

/* ------------------------------------------------------------ responsive */

@media (max-width: 1024px) {
	.hbo-grid {
		grid-template-columns: 1fr;
	}

	.hbo-title {
		font-size: 34px;
	}

	.hbo-gal {
		grid-template-columns: repeat(4, 1fr);
	}
}

@media (max-width: 782px) {
	.hbo-root {
		padding-bottom: 32px;
	}

	.hbo-card {
		padding: 22px 18px;
		border-radius: 14px;
	}

	/* On a 390px phone the name, the count, the price, the timer and the
	   button all have to land above the fold, so everything tightens. */
	.hbo-title {
		font-size: 27px;
	}

	.hbo-tagline {
		font-size: 15px;
	}

	.hbo-top {
		gap: 16px;
		margin-bottom: 20px;
	}

	.hbo-stat {
		width: 100%;
		padding: 12px 16px;
	}

	.hbo-specs {
		gap: 8px;
		padding-bottom: 18px;
		margin-bottom: 22px;
	}

	.hbo-spec {
		padding: 7px 12px;
		font-size: 11px;
	}

	.hbo-buy {
		padding: 20px 18px;
	}

	.hbo-price {
		font-size: 38px;
	}

	.hbo-grid {
		gap: 20px;
		margin-bottom: 22px;
	}

	.hbo-clock {
		gap: 7px;
	}

	.hbo-unit-num {
		font-size: 22px;
	}

	.hbo-gal {
		grid-template-columns: repeat(3, 1fr);
	}

	.hbo-trust {
		flex-direction: column;
		align-items: flex-start;
		gap: 10px;
	}

	.hbo-picker-rail {
		grid-auto-columns: minmax(200px, 78%);
	}
}

@media (prefers-reduced-motion: reduce) {
	.hbo-root * {
		transition: none !important;
	}

	.hbo-cta:hover,
	.hbo-chip:hover {
		transform: none;
	}
}
