/* Copyright (c) 2026 ADS Solutions. See LICENSE.txt for dual-license terms. */

/* ────────────────────────────────────────────────────────────────────────
 * DatePicker — Airbnb-style calendar
 *
 * Visual language adopted from airbnb.gr's date picker:
 *   - Soft rounded card with a layered shadow
 *   - Circular nav arrows in the top corners with a thin border
 *   - 16px, weight 500 month label
 *   - Single-letter weekday headers (mixed case, muted)
 *   - Day cells are 40px circles
 *   - Hover renders a thin circle outline around the day number
 *   - Selected day is a solid filled circle with inverted text
 *   - Today (when unselected) gets the circle outline + bolder weight
 *   - Range midline is a light gray bar that extends behind the days,
 *     meeting the endpoint circles flush via half-gradient bookends
 *
 * Typography + colours come from the theme tokens — the wizard's
 * Harbor / Helm direction restyles the calendar automatically via the
 * [data-cb-direction] blocks in tokens.css.  No hex codes in the
 * component CSS, only var() references with practical fallbacks for
 * admin-context rendering where no direction is active.
 *
 * Responsive: below 640px viewport the two-month layout stacks
 * vertically and the popover clamps to viewport width.
 * ──────────────────────────────────────────────────────────────────────── */

/* ── Wrapper + text input (the field above the popover) ────────────────── */

.cb-datepicker {
	position: relative;
	display: inline-block;
	width: 100%;
	max-width: 18rem;
	font-family: var( --cb-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif );
}

.cb-datepicker__input-wrap {
	position: relative;
	display: flex;
	align-items: center;
}

.cb-datepicker__input {
	width: 100%;
	height: 3rem;
	padding: 0 2.75rem 0 1rem;
	border: 1px solid var( --cb-border, #dddddd );
	border-radius: 12px;
	background: var( --cb-card, #ffffff );
	color: var( --cb-text, #222222 );
	font-family: inherit;
	font-size: 0.9375rem;
	line-height: 1.2;
	transition: border-color 120ms ease, box-shadow 120ms ease;
}

.cb-datepicker__input::-moz-placeholder {
	color: var( --cb-muted, #717171 );
	opacity: 1;
}

.cb-datepicker__input::placeholder {
	color: var( --cb-muted, #717171 );
	opacity: 1;
}

.cb-datepicker__input:hover:not(:disabled) {
	border-color: var( --cb-text, #222222 );
}

.cb-datepicker__input:focus {
	outline: none;
	border-color: var( --cb-text, #222222 );
	box-shadow: 0 0 0 1px var( --cb-text, #222222 );
}

.cb-datepicker__input:disabled {
	background: var( --cb-surface-2, #f7f7f7 );
	color: var( --cb-muted, #717171 );
	cursor: not-allowed;
}

.cb-datepicker__trigger {
	position: absolute;
	right: 0.5rem;
	top: 50%;
	transform: translateY( -50% );
	width: 2rem;
	height: 2rem;
	border: 0;
	background: transparent;
	color: var( --cb-muted, #717171 );
	border-radius: 999px;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 120ms ease, color 120ms ease;
}

.cb-datepicker__trigger:hover:not(:disabled) {
	background: var( --cb-surface-2, #f2f2f2 );
	color: var( --cb-text, #222222 );
}

.cb-datepicker__trigger:disabled {
	cursor: not-allowed;
	opacity: 0.4;
}

/* ── Popover chrome ────────────────────────────────────────────────────── */

.cb-datepicker__popover {
	position: absolute;
	z-index: 50;
	top: calc( 100% + 0.5rem );
	left: 0;
	background: var( --cb-card, #ffffff );
	border: 1px solid var( --cb-border, rgba( 0, 0, 0, 0.04 ) );
	/* Generous 16px radius to echo Airbnb's card-like popover */
	border-radius: 16px;
	box-shadow:
		0 6px 20px rgba( 0, 0, 0, 0.14 ),
		0 2px 4px rgba( 0, 0, 0, 0.08 );
	padding: 1.5rem 1.25rem 1.25rem;
	min-width: 18rem;
	font-family: var( --cb-font-family, inherit );
	color: var( --cb-text, #222222 );
}

/* Phase 2 — when the trigger sits near the viewport's right edge (admin
 * topbar, day plan), DatePicker.jsx measures the popover on open and adds
 * this modifier to flip it to right-anchored so it doesn't clip off-screen. */
.cb-datepicker__popover--align-right {
	left: auto;
	right: 0;
}

/* ── react-day-picker v9 structural reset ──────────────────────────────── */

/* Library ships .rdp-day with default padding, border, and hover bg — we
 * flatten all of that so our selectors below are the single source of truth. */

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-root,
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-root * {
	box-sizing: border-box;
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-root {
	--rdp-accent-color:             var( --cb-primary, #222222 );
	--rdp-accent-background-color:  var( --cb-surface-2, #f2f2f2 );
	--rdp-day-height:               2.75rem;
	--rdp-day-width:                2.75rem;
	--rdp-day_button-width:         2.5rem;
	--rdp-day_button-height:        2.5rem;
	--rdp-day_button-border-radius: 999px;
	--rdp-today-color:              inherit;
	--rdp-range_middle-background-color: var( --cb-surface-2, #f0f0f0 );
	--rdp-range_middle-color:       var( --cb-text, #222222 );
	--rdp-selected-border:          0;
	font-family: var( --cb-font-family, inherit );
	color: var( --cb-text, #222222 );
	margin: 0;
}

/* Kill the library's default day padding + borders */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day {
	padding: 0;
	border: 0;
	vertical-align: middle;
	text-align: center;
}

/* ── Month caption row — label centered, nav buttons absolute ──────────── */

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-month {
	margin: 0;
}

/* Caption row = [prev] [label] [next] in a single flex row, with the
 * nav wrapper flattened via `display: contents` so its children
 * participate directly in the parent flexbox. This keeps the arrows
 * vertically centered on the month label (the old absolute-positioning
 * approach dropped them onto the weekday row below). */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-month_caption {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0 0 1rem;
	gap: 0.5rem;
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-caption_label {
	flex: 1;
	font-family: var( --cb-display-font, var( --cb-font-family, inherit ) );
	font-size: 1rem;
	font-weight: 500;
	color: var( --cb-text, #222222 );
	letter-spacing: normal;
	text-transform: none;
	padding: 0;
	margin: 0;
	border: 0;
	background: none;
	line-height: 1.4;
	text-align: center;
}

/* ── Nav arrows — chromeless round icon buttons ────────────────────────── */

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-nav {
	display: contents;
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-button_previous,
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-button_next {
	flex-shrink: 0;
	width: 2rem;
	height: 2rem;
	padding: 0;
	border: 1px solid var( --cb-border, #dddddd );
	background: var( --cb-card, #ffffff );
	color: var( --cb-text, #222222 );
	border-radius: 999px;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 120ms ease, border-color 120ms ease;
}
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-button_previous { order: -1; }
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-button_next     { order: 1;  }

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-button_previous:hover:not([disabled]),
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-button_next:hover:not([disabled]) {
	background: var( --cb-surface-2, #f7f7f7 );
	border-color: var( --cb-text, #222222 );
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-button_previous[disabled],
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-button_next[disabled] {
	opacity: 0.3;
	cursor: default;
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-chevron {
	width: 14px;
	height: 14px;
	fill: currentColor;
}

/* ── Weekday headers ───────────────────────────────────────────────────── */

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-weekdays {
	border-bottom: 0;
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-weekday {
	font-family: var( --cb-font-family, inherit );
	font-size: 0.75rem;
	font-weight: 400;
	color: var( --cb-muted, #717171 );
	text-transform: none;
	letter-spacing: normal;
	text-align: center;
	padding: 0.25rem 0;
	width: 2.75rem;
}

/* ── Day cells ─────────────────────────────────────────────────────────── */

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day_button {
	width: 2.5rem;
	height: 2.5rem;
	padding: 0;
	margin: 0;
	border: 1px solid transparent;
	background: transparent;
	color: var( --cb-text, #222222 );
	font-family: inherit;
	font-size: 0.875rem;
	font-weight: 400;
	border-radius: 999px;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 120ms ease, color 120ms ease, border-color 120ms ease;
}

/* Hover — thin circle outline around the day number (Airbnb's signature) */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day_button:hover:not([disabled]) {
	border-color: var( --cb-text, #222222 );
	background: transparent;
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day_button:focus-visible {
	outline: none;
	border-color: var( --cb-text, #222222 );
	box-shadow: 0 0 0 2px var( --cb-card, #ffffff ), 0 0 0 3px var( --cb-text, #222222 );
}

/* Today (when not selected) — bolder weight + outlined ring so it stands
 * out against neighbours without stealing the selected style */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-today:not(.rdp-selected):not(.rdp-range_start):not(.rdp-range_end) .rdp-day_button {
	font-weight: 600;
	border-color: var( --cb-text, #222222 );
}

/* Selected — solid fill with inverted text.  Drives the primary
 * brand colour (so each preset's selection picks up the theme). */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day.rdp-selected .rdp-day_button,
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day.rdp-range_start .rdp-day_button,
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day.rdp-range_end .rdp-day_button {
	background: var( --cb-primary, #222222 );
	color: var( --cb-on-primary, var( --cb-card, #ffffff ) );
	border-color: var( --cb-primary, #222222 );
	font-weight: 500;
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day.rdp-selected .rdp-day_button:hover,
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day.rdp-range_start .rdp-day_button:hover,
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day.rdp-range_end .rdp-day_button:hover {
	background: var( --cb-primary-dark, var( --cb-primary, #222222 ) );
	border-color: var( --cb-primary-dark, var( --cb-primary, #222222 ) );
}

/* Disabled / outside-month */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-disabled .rdp-day_button,
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-outside .rdp-day_button {
	color: var( --cb-muted, #dddddd );
	opacity: 0.4;
	cursor: default;
}

/* G3 (v2.4.1) — 135° hatching pattern for blocked / past dates per the B3
 * punch list row P-3. Applied only to actually-disabled days (past, beyond
 * window, blocked-dates), NOT outside-month padding cells which already
 * have the muted-grey treatment above. The pattern reads at every viewport
 * — including 360px mobile where text-decoration-only failed before — and
 * the color-mix keeps it token-driven so Harbor / Helm direction restyles. */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-disabled:not(.rdp-outside) .rdp-day_button {
	background-image: repeating-linear-gradient(
		135deg,
		transparent 0,
		transparent 4px,
		color-mix( in oklab, var( --cb-text, #16243a ) 18%, transparent ) 4px,
		color-mix( in oklab, var( --cb-text, #16243a ) 18%, transparent ) 5px
	);
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-disabled .rdp-day_button:hover,
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-outside .rdp-day_button:hover {
	border-color: transparent;
	/* `background-color` (not the `background` shorthand) so the G3 hatching
	 * pattern applied on `.rdp-disabled:not(.rdp-outside)` is preserved when
	 * the cursor passes over a disabled day. */
	background-color: transparent;
}

/* Hidden cells (month-padding spacers) */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-hidden {
	visibility: hidden;
}

/* ── Range-bar bookends — endpoints meet the midline flush ─────────────── */

/* The .rdp-day <td> gets the gray bar; the inner day_button stays
 * transparent so its text reads through. */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-range_middle {
	background: var( --cb-surface-2, #f0f0f0 );
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-range_middle .rdp-day_button {
	background: transparent;
	color: var( --cb-text, #222222 );
	border-color: transparent;
	font-weight: 400;
}

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-range_middle .rdp-day_button:hover {
	border-color: var( --cb-text, #222222 );
}

/* Half-gradient bookends on the range endpoints so the grey bar meets
 * the circle flush on one side only. */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-range_start {
	background: linear-gradient( to right, transparent 50%, var( --cb-surface-2, #f0f0f0 ) 50% );
}
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-range_end {
	background: linear-gradient( to right, var( --cb-surface-2, #f0f0f0 ) 50%, transparent 50% );
}
/* Single-day "range" (start === end) gets no bar */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-range_start.rdp-range_end {
	background: transparent;
}

[dir="rtl"] :is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-range_start {
	background: linear-gradient( to left, transparent 50%, var( --cb-surface-2, #f0f0f0 ) 50% );
}
[dir="rtl"] :is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-range_end {
	background: linear-gradient( to left, var( --cb-surface-2, #f0f0f0 ) 50%, transparent 50% );
}

/* ── Two-month layout for range picker ─────────────────────────────────── */

:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-months {
	display: flex;
	/* Library default is `flex-wrap: wrap` — combined with our `display:
	 * contents` on `.rdp-nav`, that wrapped the prev/next buttons onto
	 * separate rows whenever the popover container was narrower than
	 * [prev]+[month]+[next] (e.g. inside a constrained admin layout).
	 * `nowrap` keeps them in one row and lets the popover grow to natural
	 * content width. */
	flex-wrap: nowrap;
	gap: 2.5rem;
	justify-content: center;
	align-items: flex-start;
}

/* ── Responsive: stack on mobile ───────────────────────────────────────── */

@media ( max-width: 640px ) {
	.cb-datepicker__popover {
		min-width: auto;
		max-width: calc( 100vw - 1.5rem );
		padding: 1.25rem 0.75rem 1rem;
	}

	:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-months {
		flex-direction: column;
		gap: 1.5rem;
	}

	:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-root {
		--rdp-day-height:        2.5rem;
		--rdp-day-width:         2.5rem;
		--rdp-day_button-width:  2.25rem;
		--rdp-day_button-height: 2.25rem;
	}

	:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-day_button {
		width: 2.25rem;
		height: 2.25rem;
		font-size: 0.85rem;
	}

	:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-weekday {
		width: 2.5rem;
		font-size: 0.7rem;
	}
}

/* ── v2.6.0 — Mobile bottom-sheet (B2 picker spec) ─────────────────────────
 * At <640px the popover is suppressed and the calendar renders as a
 * fixed-bottom sheet that slides up from the viewport edge. Backdrop dims
 * the page; the sheet itself has the iOS-style grab handle, a Cancel /
 * Title / Done bar, and the calendar below it. Day cells go up to 42px
 * for thumb-friendly hit targets per the design.
 * ──────────────────────────────────────────────────────────────────────── */

.cb-datepicker__backdrop {
	position: fixed;
	inset: 0;
	background: rgba(22, 36, 58, 0.42);
	z-index: 60;
	-webkit-tap-highlight-color: transparent;
}

.cb-datepicker__sheet {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 61;
	background: var( --bu-bg-elev, #fff );
	border-top-left-radius: var( --bu-radius-lg, 18px );
	border-top-right-radius: var( --bu-radius-lg, 18px );
	box-shadow: 0 -16px 40px -8px rgba(0, 0, 0, 0.18);
	padding: 14px 16px 18px;
	max-height: 90vh;
	overflow-y: auto;
	animation: cb-datepicker-sheet-rise 0.22s ease-out;
}

@keyframes cb-datepicker-sheet-rise {
	from { transform: translateY(20px); opacity: 0; }
	to   { transform: translateY(0);    opacity: 1; }
}

.cb-datepicker__sheet-handle {
	width: 36px;
	height: 4px;
	border-radius: 999px;
	background: var( --bu-line, rgba(22, 36, 58, 0.10) );
	margin: 0 auto 12px;
}

.cb-datepicker__sheet-bar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 8px;
	gap: 8px;
}

.cb-datepicker__sheet-title {
	font-family: var( --bu-font-display, var( --cb-display-font, serif ) );
	font-weight: 600;
	font-size: var( --bu-fs-base, 15px );
	color: var( --bu-ink, #16243a );
}

.cb-datepicker__sheet-action {
	-webkit-appearance: none;
	   -moz-appearance: none;
	        appearance: none;
	border: 1px solid transparent;
	background: transparent;
	font-family: inherit;
	font-size: var( --bu-fs-sm, 13px );
	padding: 8px 14px;
	border-radius: var( --bu-radius, 10px );
	cursor: pointer;
	font-weight: 500;
	white-space: nowrap;
}

.cb-datepicker__sheet-action--ghost {
	color: var( --bu-ink-2, #3d4a60 );
	border-color: var( --bu-line );
}

.cb-datepicker__sheet-action--primary {
	background: var( --bu-primary, #16243a );
	color: #fff;
	font-weight: 600;
}

/* Mobile bottom-sheet — bump day-cell touch targets so they're thumb-friendly.
 * The popover styles above already apply (see :is() unifying them in v2.10.1);
 * these are sheet-only tweaks on top.
 *
 * v2.10.2 — operator phone walk surfaced two layout issues with the
 * bottom-sheet calendar:
 *   1) The forward (next-month) arrow was rendering BELOW the grid instead
 *      of next to the back arrow. React-day-picker v9 emits .rdp-nav as a
 *      sibling of .rdp-month_caption (not a child), so the v2.6.0
 *      `display: contents` + flex `order` trick didn't reposition it.
 *   2) The grid was content-sized + centered, leaving wasted side padding.
 *
 * v2.13.1 — the v2.10.2 fix put the grid on .rdp-month, but the prev/next
 * buttons live in .rdp-nav which is a *sibling* of .rdp-month, not a
 * descendant — both are children of .rdp-months. The buttons' grid-area
 * declarations had no grid context to bind to, so they fell back to the
 * parent's flex layout: prev wrapped to the row above the calendar, next
 * wrapped to the row below. Operator-reported on iOS (390x844) on demo.
 *
 * Fix: hoist the grid to .rdp-months and make BOTH .rdp-nav and .rdp-month
 * `display: contents` so their direct descendants (prev, next, caption,
 * grid) all become grid items of .rdp-months. The grid-template-areas
 * registration is unchanged. */
.cb-datepicker__sheet .rdp {
	margin: 0;
}

.cb-datepicker__sheet .rdp-months {
	display: grid;
	grid-template-columns: auto 1fr auto;
	grid-template-areas:
		"prev caption next"
		"grid grid    grid";
	-moz-column-gap: 0.5rem;
	     column-gap: 0.5rem;
	row-gap: 0.75rem;
	width: 100%;
	align-items: center;
}

.cb-datepicker__sheet .rdp-month_caption {
	grid-area: caption;
	padding: 0;
	justify-content: center;  /* dropdowns / label centred between the arrows */
}

.cb-datepicker__sheet .rdp-month_grid {
	grid-area: grid;
	width: 100%;
	table-layout: fixed;
}

/* Both .rdp-nav and .rdp-month collapse to `display: contents` so their
 * direct children (prev, next, caption, grid) become the grid items of
 * .rdp-months. */
.cb-datepicker__sheet .rdp-nav,
.cb-datepicker__sheet .rdp-month {
	display: contents;
}
.cb-datepicker__sheet .rdp-button_previous { grid-area: prev; }
.cb-datepicker__sheet .rdp-button_next     { grid-area: next; }

.cb-datepicker__sheet .rdp-root {
	--rdp-day-height:        3rem;
	--rdp-day-width:         100%;
	--rdp-day_button-width:  2.75rem;
	--rdp-day_button-height: 2.75rem;
}
.cb-datepicker__sheet .rdp-weekdays { width: 100%; }
.cb-datepicker__sheet .rdp-weekday  {
	width: auto;
	font-size: 0.7rem;
}
/* table-layout:fixed + width:100% on the grid distributes the 7 columns
 * evenly. Days now fill the sheet's content area edge-to-edge. */
.cb-datepicker__sheet .rdp-day {
	width: auto;
}

/* ── v2.10.1 — DOB picker (captionLayout="dropdown") fixes ──────────────
 * When react-day-picker renders both the dropdowns AND the rdp-caption_label
 * text, "May 2026" appears twice. Hide the redundant label visually but keep
 * it for screen readers. :has() is supported in Chrome 105+, Safari 15.4+,
 * Firefox 121+ — ample for our admin + customer-flow targets. */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-month_caption:has(.rdp-dropdowns) .rdp-caption_label {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0,0,0,0);
	white-space: nowrap;
	border: 0;
}

/* Style the native dropdowns so they don't render as bare browser controls. */
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-dropdowns {
	display: flex;
	gap: 0.5rem;
	flex: 1;
	justify-content: center;
}
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-dropdown_root {
	position: relative;
}
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-dropdown {
	-moz-appearance: none;
	     appearance: none;
	-webkit-appearance: none;
	background: var( --cb-card, #ffffff );
	border: 1px solid var( --cb-border, #dddddd );
	border-radius: 8px;
	padding: 0.4rem 1.5rem 0.4rem 0.7rem;
	font-family: var( --cb-display-font, var( --cb-font-family, inherit ) );
	font-size: 0.9rem;
	font-weight: 500;
	color: var( --cb-text, #222222 );
	cursor: pointer;
	min-width: 5.5rem;
}
:is(.cb-datepicker__popover, .cb-datepicker__sheet) .rdp-dropdown:focus {
	outline: 2px solid var( --cb-primary, #222222 );
	outline-offset: 2px;
}

/* When dropdowns are present (DOB context), the heavy 135° hatching that
 * reads as "blocked / booked" on the wizard's date pickers is the wrong
 * affordance — out-of-range future dates aren't blocked, they're just outside
 * the valid window. Replace with a soft grayed-out treatment. */
:is(.cb-datepicker__popover, .cb-datepicker__sheet):has(.rdp-dropdowns) .rdp-disabled:not(.rdp-outside) .rdp-day_button {
	background-image: none;
	color: var( --cb-muted, #9ba3b3 );
	opacity: 0.55;
}

/* Phase T Batch D — SoldOutScreen
 *
 * Displayed by DateStep when getAvailability() returns 0 boats. Round 7's
 * design uses a stack of three "option" cards with a small uppercase label,
 * a display-font title, and a sub-line. The third card hosts an inline
 * waitlist form; on success it morphs into a thank-you message.
 */

.cb-soldout__options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1rem;
}

.cb-soldout__option {
    display: block;
    width: 100%;
    text-align: left;
    background: var(--cb-card, #ffffff);
    border: 1px solid var(--cb-border, rgba(22, 36, 58, 0.10));
    border-radius: var(--cb-card-radius, 14px);
    padding: calc(1rem * var(--cb-density, 1)) calc(1.1rem * var(--cb-density, 1));
    color: inherit;
    font-family: inherit;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
    box-shadow: 0 1px 2px rgba(22, 36, 58, 0.04), 0 1px 3px rgba(22, 36, 58, 0.06);
}

.cb-soldout__option:hover:not(:disabled):not(.cb-soldout__option--primary) {
    border-color: var(--cb-primary, #16243a);
}

.cb-soldout__option:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.cb-soldout__option--primary {
    /* Highlighted card for the waitlist signup. Matches Round 7's "primary"
     * affordance — the card itself is wrapped, not a button, because it hosts
     * a form. */
    border: 2px solid var(--cb-primary, #16243a);
    padding: calc(1rem * var(--cb-density, 1) - 1px) calc(1.1rem * var(--cb-density, 1) - 1px);
    cursor: default;
}

.cb-soldout__option-eyebrow {
    font-size: 0.6875rem;
    color: var(--cb-muted, #6b7689);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.cb-soldout__option--primary .cb-soldout__option-eyebrow {
    color: var(--cb-primary, #16243a);
}

.cb-soldout__option-title {
    font-family: var(--cb-display-font, var(--cb-font-family, system-ui), serif);
    font-size: 1.0625rem;
    font-weight: 600;
    line-height: 1.2;
    color: var(--cb-text, #16243a);
    margin-bottom: 0.2rem;
}

.cb-soldout__option-sub {
    font-size: 0.8125rem;
    color: var(--cb-muted, #6b7689);
    line-height: 1.4;
}

/* ── Waitlist form ───────────────────────────────────────────────────────── */

.cb-soldout__waitlist-form {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-top: 0.75rem;
}

.cb-soldout__waitlist-fields {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

@media (min-width: 640px) {
    .cb-soldout__waitlist-fields {
        flex-direction: row;
    }

    .cb-soldout__waitlist-fields > .cb-booking-input {
        flex: 1;
    }
}

.cb-soldout__waitlist-error {
    margin: 0;
}

.cb-soldout__waitlist-success {
    margin-top: 0.5rem;
    padding: 0.75rem 0.9rem;
    background: var(--cb-success-soft, rgba(5, 150, 105, 0.08));
    color: var(--cb-success-text, #065f46);
    border: 1px solid var(--cb-success-border, rgba(5, 150, 105, 0.2));
    border-radius: var(--cb-btn-radius, 0.5rem);
    font-size: 0.875rem;
    line-height: 1.5;
}

.cb-stepper {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--cb-border, rgba(22, 36, 58, 0.10));
    border-radius: var(--cb-btn-radius, 14px);
    background: var(--cb-card, #ffffff);
    height: calc(46px * var(--cb-density, 1));
    padding: 4px;
}

.cb-stepper__btn {
    width: 36px;
    height: 36px;
    border: 0;
    background: transparent;
    border-radius: calc(var(--cb-btn-radius, 14px) - 4px);
    cursor: pointer;
    color: var(--cb-text, #16243a);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
    font-family: inherit;
    padding: 0;
}

.cb-stepper__btn:hover:not(:disabled) {
    background: var(--cb-surface-2, #f0ebe1);
}

.cb-stepper__btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.cb-stepper__value {
    min-width: 48px;
    text-align: center;
    font-size: 1rem;
    font-weight: 600;
    color: var(--cb-text, #16243a);
    font-variant-numeric: tabular-nums;
    -webkit-user-select: none;
       -moz-user-select: none;
            user-select: none;
}

.cb-payment-method {
    -webkit-appearance: none;
       -moz-appearance: none;
            appearance: none;
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: flex-start;
    padding: 14px 16px;
    background: var(--cb-card, #ffffff);
    border: 1px solid var(--cb-border, rgba(22, 36, 58, 0.10));
    border-radius: var(--cb-btn-radius, 14px);
    cursor: pointer;
    color: var(--cb-text, #16243a);
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 500;
    text-align: left;
    transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
    width: 100%;
    min-height: 56px;
}

.cb-payment-method:hover:not(:disabled) {
    border-color: var(--cb-primary, #16243a);
}

.cb-payment-method.is-selected {
    border: 2px solid var(--cb-primary, #16243a);
    /* G6 P-11 (v2.4.5) — bumped from rgba(...,0.08) to 0.12 so the selected
     * payment method (PayPal / Viva / Worldline / etc.) reads more
     * obviously as the active choice. Per the B3 punch list. */
    background: rgba(var(--cb-primary-rgb, 22, 36, 58), 0.12);
    padding: 13px 15px;
}

.cb-payment-method:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.cb-payment-method__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--cb-text, #16243a);
    flex-shrink: 0;
}

.cb-payment-method.is-selected .cb-payment-method__icon {
    color: var(--cb-primary, #16243a);
}

.cb-payment-method__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.cb-payment-method__label {
    font-weight: 500;
    color: inherit;
}

.cb-payment-method__sub {
    font-size: 0.75rem;
    color: var(--cb-muted, #6b7689);
    font-weight: 400;
}

.cb-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 8px 0;
    border-bottom: 1px solid var(--cb-border, rgba(22, 36, 58, 0.06));
    font-size: 0.8125rem;
    gap: 1rem;
}

.cb-summary-row:last-child {
    border-bottom: 0;
}

.cb-summary-row__label {
    color: var(--cb-muted, #6b7689);
    flex-shrink: 0;
}

.cb-summary-row__value {
    color: var(--cb-text, #16243a);
    font-weight: 500;
    text-align: right;
    word-break: break-word;
}

.cb-summary-row.is-emphasized {
    padding-top: 12px;
    padding-bottom: 12px;
    font-size: 1rem;
    border-top: 1px solid var(--cb-border, rgba(22, 36, 58, 0.10));
    border-bottom: 0;
    margin-top: 4px;
}

.cb-summary-row.is-emphasized .cb-summary-row__label {
    color: var(--cb-text, #16243a);
    font-weight: 500;
}

.cb-summary-row.is-emphasized .cb-summary-row__value {
    font-family: var(--cb-display-font, var(--cb-font-family, system-ui), serif);
    font-size: 1.5rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.cb-price-line {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 5px 0;
    font-size: 0.8125rem;
    color: var(--cb-text, #16243a);
    font-weight: 500;
    gap: 1rem;
}

.cb-price-line__label {
    color: inherit;
}

.cb-price-line__amount {
    font-variant-numeric: tabular-nums;
    color: inherit;
    text-align: right;
}

.cb-price-line--muted {
    color: var(--cb-muted, #6b7689);
}

.cb-price-line--accent {
    color: var(--cb-accent, #c1683a);
}

.cb-price-line--bold {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--cb-text, #16243a);
}

/* Phase T Batch D — FailedPaymentScreen
 *
 * Reuses .cb-booking-card chrome from booking.css. Only the screen-specific
 * pieces (icon, heading colour, action stack) live here so the chrome stays
 * in lock-step with the rest of the wizard's cards.
 */

.cb-failed-payment {
    text-align: center;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

.cb-failed-payment__icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--cb-danger-soft, rgba(220, 38, 38, 0.10));
    color: var(--cb-danger, #dc2626);
    display: grid;
    place-items: center;
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0 auto 18px;
}

.cb-failed-payment__heading {
    color: var(--cb-danger, #dc2626);
    margin-bottom: 0.5rem;
}

.cb-failed-payment__message {
    /* Inherit cb-booking-subtitle styling but tighten the bottom margin —
     * the action stack provides the breathing room below. */
    margin-bottom: 1.25rem;
}

.cb-failed-payment__actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.cb-failed-payment__retry,
.cb-failed-payment__alt {
    width: 100%;
    justify-content: center;
}

.cb-failed-payment__help {
    margin: 1rem 0 0;
    font-size: 0.8125rem;
    color: var(--cb-muted, #6b7689);
    line-height: 1.5;
}

.cb-failed-payment__help a {
    color: var(--cb-primary, #16243a);
    text-decoration: underline;
}

/* Copyright (c) 2026 ADS Solutions. See LICENSE.txt for dual-license terms. */

/* ────────────────────────────────────────────────────────────────────────
 * DateRangePicker — Airbnb-style range calendar
 *
 * Complements DatePicker.css with range-specific layout and states.
 * The range midline bar + half-gradient bookend treatment lives in
 * DatePicker.css under .cb-datepicker__popover; this file adds the
 * inline-mode styling + the two-input field layout above the popover.
 *
 * Airbnb's range picker specifics we mirror here:
 *   - Two months side-by-side on desktop, stacked below 640px
 *   - Inline calendar (no popover) renders inside a card with the
 *     same shadow + radius as the popover — used by the rental step
 *   - "N nights selected" footer is a subdued line above the card's
 *     bottom edge, not an accented pill
 * ──────────────────────────────────────────────────────────────────────── */

.cb-daterange {
	/* Anchor for the absolute-positioned popover below; without `relative`
	 * the popover finds the next positioned ancestor (often <body>) and
	 * renders at the bottom of the page instead of below the inputs. */
	position: relative;
	font-family: var( --cb-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif );
	width: 100%;
	color: var( --cb-text, #222222 );
}

/* ── Two-input field (Start / End) above the popover ───────────────────── */

.cb-daterange__inputs {
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	gap: 0.75rem;
	align-items: end;
}

.cb-daterange__arrow {
	padding-bottom: 0.875rem;
	color: var( --cb-muted, #717171 );
	font-size: 1.125rem;
	line-height: 1;
}

.cb-daterange__label {
	display: block;
	font-family: var( --cb-font-family, inherit );
	font-size: 0.75rem;
	font-weight: 500;
	text-transform: none;
	letter-spacing: normal;
	color: var( --cb-muted, #717171 );
	margin-bottom: 0.375rem;
}

/* ── Popover override — wider for the two-month view ──────────────────── */

.cb-daterange__popover {
	/* Inherits rounded card + shadow from .cb-datepicker__popover in
	 * DatePicker.css. We just widen it so both months fit side-by-side. */
	left: 0;
	right: auto;
	min-width: 640px;
	max-width: calc( 100vw - 1.5rem );
}

/* Nav buttons inherit the flex-caption layout from DatePicker.css — no
 * per-popover override needed.  With numberOfMonths=2 the library places
 * prev on the first caption row and next on the last, both participating
 * in their caption's flex row. */

/* ── Inline mode — embedded calendar card (used by RentalDateRangeStep) ── */

.cb-daterange__calendar--inline {
	/* Same card chrome as the popover — so inline + popover feel like one
	 * visual system.  No absolute positioning; sits in the form flow. */
	background: var( --cb-card, #ffffff );
	border: 1px solid var( --cb-border, rgba( 0, 0, 0, 0.04 ) );
	border-radius: 16px;
	box-shadow:
		0 6px 20px rgba( 0, 0, 0, 0.08 ),
		0 2px 4px rgba( 0, 0, 0, 0.04 );
	padding: 1.5rem 1.25rem 1.25rem;
	display: flex;
	flex-direction: column;
	align-items: center;
	width: 100%;
	max-width: 720px;
	margin: 0 auto;
	color: var( --cb-text, #222222 );
	position: relative;
}

/* Reuse every .rdp-* override from DatePicker.css by matching its selector
 * chain with .cb-daterange__calendar--inline as an alternate ancestor. */

.cb-daterange__calendar--inline .rdp-root,
.cb-daterange__calendar--inline .rdp-root * {
	box-sizing: border-box;
}

.cb-daterange__calendar--inline .rdp-root {
	--rdp-accent-color:             var( --cb-primary, #222222 );
	--rdp-accent-background-color:  var( --cb-surface-2, #f2f2f2 );
	--rdp-day-height:               2.75rem;
	--rdp-day-width:                2.75rem;
	--rdp-day_button-width:         2.5rem;
	--rdp-day_button-height:        2.5rem;
	--rdp-day_button-border-radius: 999px;
	--rdp-today-color:              inherit;
	--rdp-range_middle-background-color: var( --cb-surface-2, #f0f0f0 );
	--rdp-range_middle-color:       var( --cb-text, #222222 );
	--rdp-selected-border:          0;
	font-family: var( --cb-font-family, inherit );
	color: var( --cb-text, #222222 );
	margin: 0;
}

.cb-daterange__calendar--inline .rdp-day {
	padding: 0;
	border: 0;
	vertical-align: middle;
	text-align: center;
}

.cb-daterange__calendar--inline .rdp-month {
	margin: 0;
}

/* Same [prev] [label] [next] flex caption as DatePicker — see
 * DatePicker.css for the rationale behind display:contents. */
.cb-daterange__calendar--inline .rdp-month_caption {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0 0 1rem;
	gap: 0.5rem;
}

.cb-daterange__calendar--inline .rdp-caption_label {
	flex: 1;
	font-family: var( --cb-display-font, var( --cb-font-family, inherit ) );
	font-size: 1rem;
	font-weight: 500;
	color: var( --cb-text, #222222 );
	letter-spacing: normal;
	text-transform: none;
	padding: 0;
	margin: 0;
	border: 0;
	background: none;
	line-height: 1.4;
	text-align: center;
}

.cb-daterange__calendar--inline .rdp-nav {
	display: contents;
}

.cb-daterange__calendar--inline .rdp-button_previous,
.cb-daterange__calendar--inline .rdp-button_next {
	flex-shrink: 0;
	width: 2rem;
	height: 2rem;
	padding: 0;
	border: 1px solid var( --cb-border, #dddddd );
	background: var( --cb-card, #ffffff );
	color: var( --cb-text, #222222 );
	border-radius: 999px;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 120ms ease, border-color 120ms ease;
}
.cb-daterange__calendar--inline .rdp-button_previous { order: -1; }
.cb-daterange__calendar--inline .rdp-button_next     { order: 1;  }

.cb-daterange__calendar--inline .rdp-button_previous:hover:not([disabled]),
.cb-daterange__calendar--inline .rdp-button_next:hover:not([disabled]) {
	background: var( --cb-surface-2, #f7f7f7 );
	border-color: var( --cb-text, #222222 );
}

.cb-daterange__calendar--inline .rdp-button_previous[disabled],
.cb-daterange__calendar--inline .rdp-button_next[disabled] {
	opacity: 0.3;
	cursor: default;
}

.cb-daterange__calendar--inline .rdp-chevron {
	width: 14px;
	height: 14px;
	fill: currentColor;
}

.cb-daterange__calendar--inline .rdp-weekdays {
	border-bottom: 0;
}

.cb-daterange__calendar--inline .rdp-weekday {
	font-family: var( --cb-font-family, inherit );
	font-size: 0.75rem;
	font-weight: 400;
	color: var( --cb-muted, #717171 );
	text-transform: none;
	letter-spacing: normal;
	text-align: center;
	padding: 0.25rem 0;
	width: 2.75rem;
}

.cb-daterange__calendar--inline .rdp-day_button {
	width: 2.5rem;
	height: 2.5rem;
	padding: 0;
	margin: 0;
	border: 1px solid transparent;
	background: transparent;
	color: var( --cb-text, #222222 );
	font-family: inherit;
	font-size: 0.875rem;
	font-weight: 400;
	border-radius: 999px;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 120ms ease, color 120ms ease, border-color 120ms ease;
}

.cb-daterange__calendar--inline .rdp-day_button:hover:not([disabled]) {
	border-color: var( --cb-text, #222222 );
	background: transparent;
}

.cb-daterange__calendar--inline .rdp-day_button:focus-visible {
	outline: none;
	border-color: var( --cb-text, #222222 );
	box-shadow: 0 0 0 2px var( --cb-card, #ffffff ), 0 0 0 3px var( --cb-text, #222222 );
}

.cb-daterange__calendar--inline .rdp-today:not(.rdp-selected):not(.rdp-range_start):not(.rdp-range_end) .rdp-day_button {
	font-weight: 600;
	border-color: var( --cb-text, #222222 );
}

.cb-daterange__calendar--inline .rdp-day.rdp-selected .rdp-day_button,
.cb-daterange__calendar--inline .rdp-day.rdp-range_start .rdp-day_button,
.cb-daterange__calendar--inline .rdp-day.rdp-range_end .rdp-day_button {
	background: var( --cb-primary, #222222 );
	color: var( --cb-on-primary, var( --cb-card, #ffffff ) );
	border-color: var( --cb-primary, #222222 );
	font-weight: 500;
}

.cb-daterange__calendar--inline .rdp-day.rdp-selected .rdp-day_button:hover,
.cb-daterange__calendar--inline .rdp-day.rdp-range_start .rdp-day_button:hover,
.cb-daterange__calendar--inline .rdp-day.rdp-range_end .rdp-day_button:hover {
	background: var( --cb-primary-dark, var( --cb-primary, #222222 ) );
	border-color: var( --cb-primary-dark, var( --cb-primary, #222222 ) );
}

.cb-daterange__calendar--inline .rdp-disabled .rdp-day_button,
.cb-daterange__calendar--inline .rdp-outside .rdp-day_button {
	color: var( --cb-muted, #dddddd );
	opacity: 0.4;
	cursor: default;
}

/* G3 (v2.4.1) — 135° hatching pattern replaces the v1.36-era line-through
 * per the B3 punch list row P-3 ("Line-through only — not visible on
 * mobile"). The hatch reads at every viewport (including 360px) and the
 * color-mix keeps it token-driven so Harbor / Helm direction restyles
 * automatically. The `:not(.rdp-outside)` guard keeps next/prev-month
 * padding days at the muted-opacity treatment they already have above.
 *
 * Note: the legend label below the calendar reads "Booked" — this rule
 * is what the customer maps to that visual key. */
.cb-daterange__calendar--inline .rdp-disabled:not(.rdp-outside) .rdp-day_button {
	background-image: repeating-linear-gradient(
		135deg,
		transparent 0,
		transparent 4px,
		color-mix( in oklab, var( --cb-text, #16243a ) 18%, transparent ) 4px,
		color-mix( in oklab, var( --cb-text, #16243a ) 18%, transparent ) 5px
	);
}

.cb-daterange__calendar--inline .rdp-disabled .rdp-day_button:hover,
.cb-daterange__calendar--inline .rdp-outside .rdp-day_button:hover {
	border-color: transparent;
	/* `background-color` (not the `background` shorthand) so the hatching
	 * pattern from the rule above is preserved when the cursor passes over. */
	background-color: transparent;
}

.cb-daterange__calendar--inline .rdp-hidden {
	visibility: hidden;
}

/* Range midline — td background so text reads through the button */
.cb-daterange__calendar--inline .rdp-range_middle {
	background: var( --cb-surface-2, #f0f0f0 );
}

.cb-daterange__calendar--inline .rdp-range_middle .rdp-day_button {
	background: transparent;
	color: var( --cb-text, #222222 );
	border-color: transparent;
	font-weight: 400;
}

.cb-daterange__calendar--inline .rdp-range_middle .rdp-day_button:hover {
	border-color: var( --cb-text, #222222 );
}

/* Half-gradient bookends */
.cb-daterange__calendar--inline .rdp-range_start {
	background: linear-gradient( to right, transparent 50%, var( --cb-surface-2, #f0f0f0 ) 50% );
}
.cb-daterange__calendar--inline .rdp-range_end {
	background: linear-gradient( to right, var( --cb-surface-2, #f0f0f0 ) 50%, transparent 50% );
}
.cb-daterange__calendar--inline .rdp-range_start.rdp-range_end {
	background: transparent;
}

[dir="rtl"] .cb-daterange__calendar--inline .rdp-range_start {
	background: linear-gradient( to left, transparent 50%, var( --cb-surface-2, #f0f0f0 ) 50% );
}
[dir="rtl"] .cb-daterange__calendar--inline .rdp-range_end {
	background: linear-gradient( to left, var( --cb-surface-2, #f0f0f0 ) 50%, transparent 50% );
}

.cb-daterange__calendar--inline .rdp-months,
.cb-daterange__popover .rdp-months {
	display: flex;
	/* Match DatePicker.css — see same comment there. `nowrap` prevents the
	 * `display: contents` nav children from being pushed onto separate rows
	 * when the container is narrower than [prev]+months+[next]. */
	flex-wrap: nowrap;
	gap: 2.5rem;
	justify-content: center;
	align-items: flex-start;
}

/* ── "N days selected" footer — quiet, not a pill ──────────────────────── */

.cb-daterange__footer {
	margin-top: 1rem;
	padding-top: 0.75rem;
	border-top: 1px solid var( --cb-border, #ebebeb );
	color: var( --cb-text, #222222 );
	font-size: 0.875rem;
	text-align: center;
	width: 100%;
}

.cb-daterange__footer strong {
	font-weight: 600;
}

/* ── Responsive: stack on mobile ───────────────────────────────────────── */

@media ( max-width: 640px ) {
	.cb-daterange__inputs {
		grid-template-columns: 1fr;
		gap: 0.5rem;
	}

	.cb-daterange__arrow {
		display: none;
	}

	.cb-daterange__popover {
		min-width: auto;
		max-width: calc( 100vw - 1.5rem );
	}

	.cb-daterange__calendar--inline {
		padding: 1.25rem 0.75rem 1rem;
		border-radius: 12px;
	}

	.cb-daterange__calendar--inline .rdp-months,
	.cb-daterange__popover .rdp-months {
		flex-direction: column;
		gap: 1.5rem;
	}

	.cb-daterange__calendar--inline .rdp-root {
		--rdp-day-height:        2.5rem;
		--rdp-day-width:         2.5rem;
		--rdp-day_button-width:  2.25rem;
		--rdp-day_button-height: 2.25rem;
	}

	.cb-daterange__calendar--inline .rdp-day_button {
		width: 2.25rem;
		height: 2.25rem;
		font-size: 0.85rem;
	}

	.cb-daterange__calendar--inline .rdp-weekday {
		width: 2.5rem;
		font-size: 0.7rem;
	}
}

/* ── v2.6.0 — B2 spec footer price chip + mobile sheet stacking ───────── */

.cb-daterange__price-chip {
	margin-left: 8px;
	color: var( --bu-accent, #c1683a );
	font-weight: 600;
}

/* On the mobile bottom-sheet variant the two months stack vertically since
   side-by-side won't fit on a phone. The .cb-datepicker__sheet base styles
   (in DatePicker.css) handle the chrome; this overrides the months layout
   to a column when present inside .cb-daterange__sheet. */
.cb-daterange__sheet .rdp-months {
	flex-direction: column;
	gap: 0.5rem;
}
.cb-daterange__sheet .rdp-day_button {
	width: 2.4rem;
	height: 2.4rem;
	font-size: 0.9rem;
}
.cb-daterange__sheet .rdp-weekday {
	width: 2.4rem;
	font-size: 0.7rem;
}
.cb-daterange__sheet .cb-datepicker__sheet-action--primary[disabled] {
	opacity: 0.5;
	cursor: not-allowed;
}

/* Copyright (c) 2026 ADS Solutions. See LICENSE.txt for dual-license terms. */

/* ────────────────────────────────────────────────────────────────────────
 * TimePicker — popover with a scrollable grid of time slots
 *
 * Visual system mirrors DatePicker.css so a form that has both a date
 * and a time picker feels like ONE thing:
 *   - Same rounded card + layered shadow on the popover
 *   - Same theme-token-driven typography
 *   - Slots use the DatePicker's hover/selected conventions — thin
 *     outline on hover, solid-fill on selected
 *   - Grid is 3-up on desktop, 2-up on mobile
 *   - Popover is scrollable (max-height) so 96 slots at 15-min
 *     intervals don't blow out the card
 *
 * Uses theme tokens exclusively; no literal colors.
 * ──────────────────────────────────────────────────────────────────────── */

/* ── Wrapper + text input ──────────────────────────────────────────────── */

.cb-timepicker {
	position: relative;
	display: inline-block;
	width: 100%;
	max-width: 10rem;
	font-family: var( --cb-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif );
}

.cb-timepicker__input-wrap {
	position: relative;
	display: flex;
	align-items: center;
}

.cb-timepicker__input {
	width: 100%;
	height: 3rem;
	padding: 0 2.75rem 0 1rem;
	border: 1px solid var( --cb-border, #dddddd );
	border-radius: 12px;
	background: var( --cb-card, #ffffff );
	color: var( --cb-text, #222222 );
	font-family: inherit;
	font-size: 0.9375rem;
	font-variant-numeric: tabular-nums;
	line-height: 1.2;
	transition: border-color 120ms ease, box-shadow 120ms ease;
}

.cb-timepicker__input::-moz-placeholder {
	color: var( --cb-muted, #717171 );
	opacity: 1;
}

.cb-timepicker__input::placeholder {
	color: var( --cb-muted, #717171 );
	opacity: 1;
}

.cb-timepicker__input:hover:not(:disabled) {
	border-color: var( --cb-text, #222222 );
}

.cb-timepicker__input:focus {
	outline: none;
	border-color: var( --cb-text, #222222 );
	box-shadow: 0 0 0 1px var( --cb-text, #222222 );
}

.cb-timepicker__input:disabled {
	background: var( --cb-surface-2, #f7f7f7 );
	color: var( --cb-muted, #717171 );
	cursor: not-allowed;
}

.cb-timepicker__trigger {
	position: absolute;
	right: 0.5rem;
	top: 50%;
	transform: translateY( -50% );
	width: 2rem;
	height: 2rem;
	border: 0;
	background: transparent;
	color: var( --cb-muted, #717171 );
	border-radius: 999px;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 120ms ease, color 120ms ease;
}

.cb-timepicker__trigger:hover:not(:disabled) {
	background: var( --cb-surface-2, #f2f2f2 );
	color: var( --cb-text, #222222 );
}

.cb-timepicker__trigger:disabled {
	cursor: not-allowed;
	opacity: 0.4;
}

/* ── Popover ───────────────────────────────────────────────────────────── */

.cb-timepicker__popover {
	position: absolute;
	z-index: 50;
	top: calc( 100% + 0.5rem );
	left: 0;
	background: var( --cb-card, #ffffff );
	border: 1px solid var( --cb-border, rgba( 0, 0, 0, 0.04 ) );
	border-radius: 16px;
	box-shadow:
		0 6px 20px rgba( 0, 0, 0, 0.14 ),
		0 2px 4px rgba( 0, 0, 0, 0.08 );
	padding: 0.75rem;
	/* Wide enough that 3 columns of "HH:MM" (5 tabular chars) never wrap.
	 * Previously 14rem → "00:00" was breaking across two lines. */
	min-width: 17rem;
	max-height: 18rem;
	overflow-y: auto;
	font-family: var( --cb-font-family, inherit );
	color: var( --cb-text, #222222 );
}

.cb-timepicker__grid {
	display: grid;
	/* min of 3.5rem per column prevents shrinking below "HH:MM" content. */
	grid-template-columns: repeat( 3, minmax( 3.5rem, 1fr ) );
	gap: 0.25rem;
}

.cb-timepicker__slot {
	padding: 0.5rem 0.5rem;
	border: 1px solid transparent;
	background: transparent;
	color: var( --cb-text, #222222 );
	font-family: inherit;
	font-size: 0.9rem;
	font-weight: 400;
	font-variant-numeric: tabular-nums;
	white-space: nowrap;            /* never wrap "HH:MM" across lines */
	border-radius: 999px;
	cursor: pointer;
	text-align: center;
	transition: background 120ms ease, color 120ms ease, border-color 120ms ease;
}

.cb-timepicker__slot:hover:not(:disabled) {
	border-color: var( --cb-text, #222222 );
	background: transparent;
}

.cb-timepicker__slot:focus-visible {
	outline: none;
	border-color: var( --cb-text, #222222 );
	box-shadow: 0 0 0 2px var( --cb-card, #ffffff ), 0 0 0 3px var( --cb-text, #222222 );
}

.cb-timepicker__slot--selected {
	background: var( --cb-primary, #222222 );
	color: var( --cb-on-primary, var( --cb-card, #ffffff ) );
	border-color: var( --cb-primary, #222222 );
	font-weight: 500;
}

.cb-timepicker__slot--selected:hover {
	background: var( --cb-primary-dark, var( --cb-primary, #222222 ) );
	border-color: var( --cb-primary-dark, var( --cb-primary, #222222 ) );
}

/* v2.25.0 — slot is in a disabled range (booked + buffer cooldown) for the
 * current date. Still rendered (operators want customers to see what was
 * taken) but unclickable + visually struck-through. */
.cb-timepicker__slot--disabled,
.cb-timepicker__slot:disabled {
	color: var( --cb-text-muted, #94a3b8 );
	background: var( --cb-surface-subtle, #f8fafc );
	text-decoration: line-through;
	cursor: not-allowed;
	opacity: 0.55;
}
.cb-timepicker__slot--disabled:hover,
.cb-timepicker__slot:disabled:hover {
	border-color: var( --cb-border, #e2e8f0 );
	color: var( --cb-text-muted, #94a3b8 );
}

.cb-timepicker__empty {
	padding: 1rem;
	text-align: center;
	color: var( --cb-muted, #717171 );
	font-size: 0.875rem;
}

/* ── Responsive: tighter grid on mobile ────────────────────────────────── */

@media ( max-width: 640px ) {
	.cb-timepicker__popover {
		padding: 0.5rem;
		min-width: 13rem;
		max-width: calc( 100vw - 1.5rem );
	}

	.cb-timepicker__grid {
		grid-template-columns: repeat( 2, minmax( 3.5rem, 1fr ) );
	}

	.cb-timepicker__slot {
		padding: 0.5rem 0.5rem;
		font-size: 0.875rem;
	}
}

/* ── v2.6.0 — B2 spec mobile bottom-sheet w/ two-wheel iOS-style picker ── */

.cb-timepicker__backdrop {
	position: fixed;
	inset: 0;
	background: rgba(22, 36, 58, 0.42);
	z-index: 60;
}
.cb-timepicker__sheet {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 61;
	background: var( --bu-bg-elev, #fff );
	border-top-left-radius: var( --bu-radius-lg, 18px );
	border-top-right-radius: var( --bu-radius-lg, 18px );
	box-shadow: 0 -16px 40px -8px rgba(0, 0, 0, 0.18);
	padding: 14px 16px 18px;
	max-height: 90vh;
	overflow: hidden;
	animation: cb-datepicker-sheet-rise 0.22s ease-out;
}
.cb-timepicker__sheet-handle {
	width: 36px;
	height: 4px;
	border-radius: 999px;
	background: var( --bu-line, rgba(22, 36, 58, 0.10) );
	margin: 0 auto 12px;
}
.cb-timepicker__sheet-bar {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 12px;
	gap: 8px;
}
.cb-timepicker__sheet-title {
	font-family: var( --bu-font-display, var( --cb-display-font, serif ) );
	font-weight: 600;
	font-size: var( --bu-fs-base, 15px );
	color: var( --bu-ink, #16243a );
}
.cb-timepicker__sheet-action {
	-webkit-appearance: none;
	   -moz-appearance: none;
	        appearance: none;
	border: 1px solid transparent;
	background: transparent;
	font-family: inherit;
	font-size: var( --bu-fs-sm, 13px );
	padding: 8px 14px;
	border-radius: var( --bu-radius, 10px );
	cursor: pointer;
	font-weight: 500;
	white-space: nowrap;
}
.cb-timepicker__sheet-action--ghost {
	color: var( --bu-ink-2, #3d4a60 );
	border-color: var( --bu-line );
}
.cb-timepicker__sheet-action--primary {
	background: var( --bu-primary, #16243a );
	color: #fff;
	font-weight: 600;
}

/* Two-wheel layout */
.cb-timepicker__wheels {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 14px;
	height: 240px;
	/* v2.14.1 — exposed as a CSS variable so the wheel-track padding can
	 * compute its centring offset off the wheels' actual height. The
	 * previous `calc(50% - 22px)` resolved 50% against the track's
	 * WIDTH (CSS spec for padding %), not its height — on a ~175px-wide
	 * wheel that gave ~65px of padding instead of the 98px needed to
	 * centre the selection over the highlight band. Operator-reported
	 * on Android / 390x844: selected hour appeared at the top of the
	 * wheel, band sat below it. */
	--cb-timepicker-wheel-h: 240px;
	--cb-timepicker-item-h:  44px;
}
.cb-timepicker__wheel {
	position: relative;
	overflow: hidden;
	border-radius: var( --bu-radius, 10px );
	background: var( --bu-bg-sunk, #f0ebe1 );
}
.cb-timepicker__wheel-label {
	position: absolute;
	top: 8px;
	left: 12px;
	font-size: 11px;
	color: var( --bu-ink-3 );
	text-transform: uppercase;
	letter-spacing: 0.06em;
	font-weight: 600;
	z-index: 1;
	pointer-events: none;
}
.cb-timepicker__wheel-band {
	position: absolute;
	left: 8px;
	right: 8px;
	top: 50%;
	transform: translateY(-22px);
	height: 44px;
	border-radius: 8px;
	background: color-mix(in oklab, var( --bu-primary ) 12%, transparent);
	pointer-events: none;
}
.cb-timepicker__wheel-track {
	position: relative;
	height: 100%;
	overflow-y: scroll;
	scroll-snap-type: y mandatory;
	scrollbar-width: none;
	/* v2.14.1 — height-based centring: half the wheel minus half the item.
	 * Was `calc(50% - 22px)` — but padding-% resolves against the parent's
	 * WIDTH, not its height, which broke alignment on phones. */
	padding: calc((var(--cb-timepicker-wheel-h, 240px) - var(--cb-timepicker-item-h, 44px)) / 2) 0;
}
.cb-timepicker__wheel-track::-webkit-scrollbar { display: none; }
.cb-timepicker__wheel-item {
	scroll-snap-align: center;
	text-align: center;
	font-size: var( --bu-fs-lg, 17px );
	font-variant-numeric: tabular-nums;
	color: var( --bu-ink-2 );
	font-weight: 500;
	transition: color 0.12s, font-weight 0.12s;
}
.cb-timepicker__wheel-item.is-selected {
	color: var( --bu-primary );
	font-weight: 700;
}

.cb-skipper-option {
    -webkit-appearance: none;
       -moz-appearance: none;
            appearance: none;
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: flex-start;
    padding: calc(14px * var(--cb-density, 1)) calc(16px * var(--cb-density, 1));
    background: var(--cb-card, #ffffff);
    border: 1px solid var(--cb-border, rgba(22, 36, 58, 0.10));
    border-radius: var(--cb-card-radius, 14px);
    cursor: pointer;
    color: var(--cb-text, #16243a);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: left;
    transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
    width: 100%;
    min-height: 64px;
}

.cb-skipper-option:hover:not(:disabled) {
    border-color: var(--cb-primary, #16243a);
}

.cb-skipper-option.is-selected {
    border: 2px solid var(--cb-primary, #16243a);
    background: rgba(var(--cb-primary-rgb, 22, 36, 58), 0.08);
    padding: calc(14px * var(--cb-density, 1) - 1px) calc(16px * var(--cb-density, 1) - 1px);
}

.cb-skipper-option:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.cb-skipper-option__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--cb-text, #16243a);
    flex-shrink: 0;
}

.cb-skipper-option.is-selected .cb-skipper-option__icon {
    color: var(--cb-primary, #16243a);
}

.cb-skipper-option__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 1;
}

.cb-skipper-option__label {
    font-weight: 600;
    color: inherit;
    font-size: 0.95rem;
}

.cb-skipper-option__sub {
    font-size: 0.78rem;
    color: var(--cb-muted, #6b7689);
    font-weight: 400;
    line-height: 1.35;
    /* v2.10.1 — allow the sub-line to wrap to up to 2 lines instead of
     * truncating with an ellipsis. The "Captain operates the boat …" /
     * "Operate it yourself (license required)" sublines were getting cut
     * off on phones where the card is narrower; readability matters more
     * than a one-line cap. Desktop usually fits in one line anyway. */
    white-space: normal;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
}

.cb-skipper-option__price {
    flex-shrink: 0;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--cb-text, #16243a);
    margin-left: auto;
    padding-left: 8px;
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.cb-skipper-option.is-selected .cb-skipper-option__price {
    color: var(--cb-primary, #16243a);
}

/* G1 Wizard chrome components — co-located styles
   These complement tokens.css. Drop into:
     cruise-booking/assets/src/booking/components/wizard-chrome.css

   All values reference --bu-* tokens. No hardcoded colors / fonts / radii.
   Breakpoints follow Tailwind defaults: sm = 640px, lg = 1024px.
*/

/* ─────────────────────────────────────────────────────────────
   Shared accessibility helper
   ───────────────────────────────────────────────────────────── */
.bu-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;
}

/* ═════════════════════════════════════════════════════════════
   1. ProgressStrip
   ═════════════════════════════════════════════════════════════ */
.bu-progress {
  width: 100%;
  background: var(--bu-bg-elev);
  border-bottom: 1px solid var(--bu-line);
  padding: calc(var(--bu-step) * 1.25) calc(var(--bu-step) * 2);
}

/* Mobile: visible by default; hidden ≥640 */
.bu-progress__mobile { display: block; }
.bu-progress__chips  { display: none; }

@media (min-width: 640px) {
  .bu-progress__mobile { display: none; }
  .bu-progress__chips  {
    display: flex;
    align-items: center;
    gap: calc(var(--bu-step) * 0.5);
    margin: 0;
    padding: 0;
    list-style: none;
  }
}

/* ── Mobile bar ─────────────────────────────────────────────── */
.bu-progress__bar {
  height: 4px;
  width: 100%;
  background: var(--bu-bg-sunk);
  border-radius: var(--bu-radius-pill);
  overflow: hidden;
  margin-bottom: calc(var(--bu-step) * 0.75);
}
.bu-progress__bar-fill {
  height: 100%;
  background: var(--bu-accent);
  border-radius: var(--bu-radius-pill);
  transition: width .25s ease;
}
.bu-progress__mobile-label {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: var(--bu-fs-sm);
  color: var(--bu-ink-2);
}
.bu-progress__counter   { color: var(--bu-ink-3); font-size: var(--bu-fs-xs); text-transform: uppercase; letter-spacing: 0.06em; }
.bu-progress__separator { color: var(--bu-ink-4); }
.bu-progress__current   { color: var(--bu-ink); font-size: var(--bu-fs-base); }

/* ── Tablet+desktop chip row ────────────────────────────────── */
.bu-progress__chip {
  display: flex;
  align-items: center;
  gap: calc(var(--bu-step) * 0.75);
  flex: 1 1 0;
  min-width: 0;        /* allow children to shrink */
  position: relative;
  color: var(--bu-ink-3);
  font-size: var(--bu-fs-sm);
  font-weight: 500;
}
.bu-progress__chip:last-child { flex: 0 0 auto; }

.bu-progress__dot {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bu-bg-sunk);
  color: var(--bu-ink-3);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: var(--bu-fs-xs);
  font-weight: 600;
  line-height: 1;
  border: 1px solid var(--bu-line);
  transition: background .15s, color .15s, border-color .15s;
}

.bu-progress__chip.is-current .bu-progress__dot {
  background: var(--bu-primary);
  color: var(--bu-primary-ink);
  border-color: var(--bu-primary);
  box-shadow: 0 0 0 4px color-mix(in oklab, var(--bu-primary) 12%, transparent);
}
.bu-progress__chip.is-complete .bu-progress__dot {
  background: var(--bu-success-soft);
  color: var(--bu-success);
  border-color: transparent;
}

.bu-progress__label {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 0;        /* tablet collapses labels — see lg override */
  opacity: 0;
  flex: 0 1 auto;
  transition: max-width .2s, opacity .2s;
}
.bu-progress__chip.is-current .bu-progress__label {
  max-width: 120px;
  opacity: 1;
  color: var(--bu-ink);
}

@media (min-width: 1024px) {
  .bu-progress__label { max-width: 160px; opacity: 1; }
  .bu-progress__chip.is-complete .bu-progress__label { color: var(--bu-ink-2); }
}

.bu-progress__rail {
  flex: 1 1 auto;
  height: 2px;
  min-width: 8px;
  background: var(--bu-line);
  border-radius: var(--bu-radius-pill);
}
.bu-progress__rail.is-complete { background: var(--bu-success); opacity: 0.6; }


/* ═════════════════════════════════════════════════════════════
   2. SummaryRail
   ═════════════════════════════════════════════════════════════ */

/* v2.4.9 — display / tnum helpers scoped to the booking widget. The same
   classes were defined in `assets/src/components/KpiCard.css` for the admin
   chrome but never made it into the wizard's stylesheet, so `.bu-display`
   on the rail's Total ("€250") was rendering in the body font. */
.bu-display { font-family: var(--bu-font-display); }
.bu-tnum    { font-feature-settings: 'tnum' 1, 'lnum' 1; }

/* Sticky panel — desktop + tablet (≥640).
   v2.4.9 — fill the parent grid column (was `width: 220px` / `260px`,
   which left the 360px column with empty space and made the card look
   visually small per Claude Design's B4 spec which targets a 320px /
   280px column + rail-fills-column). */
.bu-rail {
  display: none;
}
@media (min-width: 640px) {
  .bu-rail--sticky {
    display: block;
    position: sticky;
    top: calc(var(--bu-progress-height, 96px) + 16px); /* host sets --bu-progress-height */
    width: 100%;
    max-height: calc(100vh - var(--bu-progress-height, 96px) - 32px);
    overflow: auto;
    background: var(--bu-bg-elev);
    border: 1px solid var(--bu-line);
    border-radius: var(--bu-radius-lg);
    padding: var(--bu-pad-card);
    box-shadow: var(--bu-shadow-1);
    align-self: start;
  }
}

.bu-rail__body { display: flex; flex-direction: column; gap: calc(var(--bu-step) * 1.25); }

/* v2.4.8 — "Your booking" eyebrow above the paired rows */
.bu-rail__title {
  font-size: var(--bu-fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--bu-ink-3);
  font-weight: 600;
  margin-bottom: calc(var(--bu-step) * 0.75);
}

/* v2.4.8 — label/value pairs (Boat / Skipper / Dates / Days) */
.bu-rail__pair {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--bu-step);
  font-size: var(--bu-fs-sm);
  line-height: 1.3;
}
.bu-rail__pair-label { color: var(--bu-ink-3); }
.bu-rail__pair-value { color: var(--bu-ink); text-align: right; }
.bu-rail__pair-value.bu-display { font-size: var(--bu-fs-base); }

/* v2.4.8 — soft note strip for the cancellation policy footer */
.bu-rail__note {
  margin-top: calc(var(--bu-step) * 0.5);
  padding: calc(var(--bu-step) * 1) calc(var(--bu-step) * 1.25);
  background: var(--bu-bg-sunk);
  border-radius: var(--bu-radius-sm);
  font-size: var(--bu-fs-xs);
  color: var(--bu-ink-2);
  line-height: 1.4;
}

.bu-rail__row { display: flex; flex-direction: column; gap: 4px; }
.bu-rail__row--boat { flex-direction: row; align-items: center; gap: calc(var(--bu-step) * 1.25); }

.bu-rail__thumb {
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  border-radius: var(--bu-radius);
  background: var(--bu-bg-sunk);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}
.bu-rail__thumb img { width: 100%; height: 100%; -o-object-fit: cover; object-fit: cover; display: block; }
.bu-rail__thumb-placeholder { color: var(--bu-ink-4); }

@media (min-width: 1024px) {
  .bu-rail__thumb { width: 64px; height: 64px; }
}

.bu-rail__eyebrow {
  font-size: var(--bu-fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--bu-ink-3);
  font-weight: 600;
}
.bu-rail__boat-name { font-size: var(--bu-fs-lg); color: var(--bu-ink); line-height: 1.2; }
.bu-rail__date-line {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--bu-fs-sm);
  color: var(--bu-ink);
  flex-wrap: wrap;
}
.bu-rail__arrow { color: var(--bu-ink-4); }
.bu-rail__day-count { font-size: var(--bu-fs-xs); color: var(--bu-ink-3); }

.bu-rail__totals {
  background: var(--bu-accent-soft);
  border-radius: var(--bu-radius);
  padding: calc(var(--bu-step) * 1.5);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.bu-rail__total-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--bu-step);
}
.bu-rail__total-label { font-size: var(--bu-fs-sm); color: var(--bu-ink-2); }
.bu-rail__total-value { color: var(--bu-ink); }
.bu-rail__total-row--gross .bu-rail__total-value {
  font-size: var(--bu-fs-2xl);
  letter-spacing: -0.02em;
  line-height: 1;
}
.bu-rail__total-row--deposit { padding-top: 6px; border-top: 1px solid color-mix(in oklab, var(--bu-accent) 18%, transparent); }
.bu-rail__total-row--deposit .bu-rail__total-value { font-size: var(--bu-fs-base); color: var(--bu-ink-2); }

.bu-rail__empty {
  font-size: var(--bu-fs-sm);
  color: var(--bu-ink-3);
  font-style: italic;
}

/* Bottom-bar — mobile only */
.bu-rail-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  background: var(--bu-bg-elev);
  border-top: 1px solid var(--bu-line);
  box-shadow: var(--bu-shadow-3);
}
@media (min-width: 640px) {
  .bu-rail-bar { display: none; }
}

.bu-rail-bar__btn {
  -webkit-appearance: none;
     -moz-appearance: none;
          appearance: none;
  border: 0;
  background: transparent;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: calc(var(--bu-step) * 1.5) calc(var(--bu-step) * 2);
  font-family: inherit;
  cursor: pointer;
  text-align: left;
}
.bu-rail-bar__total {
  font-family: var(--bu-font-display);
  font-size: var(--bu-fs-xl);
  color: var(--bu-ink);
  letter-spacing: -0.02em;
}
.bu-rail-bar__cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--bu-fs-sm);
  font-weight: 500;
  color: var(--bu-accent);
}
.bu-rail-bar__chev { font-size: var(--bu-fs-xs); }

.bu-rail-bar__sheet {
  max-height: 0;
  overflow: hidden;
  transition: max-height .25s ease;
  padding: 0 calc(var(--bu-step) * 2);
}
.bu-rail-bar__sheet.is-open {
  max-height: 60vh;
  overflow: auto;
  padding-bottom: calc(var(--bu-step) * 2);
  border-top: 1px solid var(--bu-line);
  padding-top: calc(var(--bu-step) * 1.5);
}


/* ═════════════════════════════════════════════════════════════
   3. WizardBrandStrip
   ═════════════════════════════════════════════════════════════ */
.bu-brand-strip {
  width: 100%;
  background: var(--bu-bg);                        /* matches page bg — feels like a top crown, not a card */
  border-bottom: 1px solid var(--bu-line-2);
}
.bu-brand-strip__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bu-step);
  padding: calc(var(--bu-step) * 1.25) calc(var(--bu-step) * 2);
}

.bu-brand-strip__lhs {
  display: flex;
  align-items: center;
  gap: calc(var(--bu-step) * 1.25);
  min-width: 0;
}
.bu-brand-strip__logo {
  height: 28px;
  width: auto;
  max-width: 180px;
  -o-object-fit: contain;
     object-fit: contain;
}
.bu-brand-strip__name {
  font-size: var(--bu-fs-lg);
  color: var(--bu-ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
@media (min-width: 1024px) {
  .bu-brand-strip__name { font-size: var(--bu-fs-xl); }
  .bu-brand-strip__logo { height: 32px; }
}

.bu-brand-strip__rhs {
  flex: 0 0 auto;
}

/* Phone link — full vs icon variants */
.bu-brand-strip__phone {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  font-size: var(--bu-fs-sm);
  font-weight: 500;
  color: var(--bu-ink-2);
  border-radius: var(--bu-radius-pill);
  padding: 6px 12px;
  transition: background .15s, color .15s;
}
.bu-brand-strip__phone:hover { background: var(--bu-bg-sunk); color: var(--bu-ink); }
.bu-brand-strip__phone-icon { font-size: var(--bu-fs-base); }
.bu-brand-strip__phone-prefix { color: var(--bu-ink-3); font-weight: 400; }
.bu-brand-strip__phone-number { color: var(--bu-ink); font-weight: 600; }

.bu-brand-strip__phone--full { display: none; }
.bu-brand-strip__phone--icon {
  width: 40px;
  height: 40px;
  justify-content: center;
  padding: 0;
  background: var(--bu-bg-sunk);
}

@media (min-width: 640px) {
  .bu-brand-strip__phone--full { display: inline-flex; }
  .bu-brand-strip__phone--icon { display: none; }
}

/* BoatUP — design tokens (Phase R)
 *
 * Single source of truth for the visual layer across all 3 surfaces:
 *   - Admin UI         (#cb-root scope)
 *   - Customer wizard  (.cb-booking-widget scope, with operator-overridable colors)
 *   - Partner portal   (.cb-partner-portal-body scope, with operator-overridable colors)
 *
 * Design direction: modern minimal (Stripe / Vercel / Linear).
 *
 * Tokens are layered:
 *   1. Raw scale  — `--cb-color-blue-500`, `--cb-space-4`, `--cb-text-base`
 *   2. Semantic   — `--cb-text-primary`, `--cb-surface`, `--cb-border`
 *
 * Components ALWAYS read the semantic tokens. Surface-level customisation
 * (operator branding, theme presets, dark mode in the future) only needs to
 * remap the semantic tokens to different raw-scale values.
 */

/* ── BoatUP admin tokens (Phase 2 / Phase U) ────────────────────────────────
 *
 * The admin SPA uses --bu-* tokens (the handoff naming) rather than --cb-*
 * (the wizard naming) so the handoff JSX in BoatUP-handoff/boatup/project/
 * admin.jsx can be ported almost line-for-line. Most --bu-* aliases map to
 * existing --cb-* tokens; a few admin-only tokens (--bu-bg-elev, --bu-bg-sunk,
 * --bu-line, the soft/strong success/danger pairs, fs-3xl) don't have --cb-*
 * equivalents and live here as the source of truth for the admin chrome.
 *
 * The admin is direction-agnostic — always Harbor (cream + serif). No
 * [data-cb-direction] block is needed here; admin chrome reads --bu-*
 * directly. Values are sampled from BoatUP-handoff/boatup/project/tokens.css.
 */
:root {
    /* Ink scale — primary / secondary / tertiary text */
    --bu-ink-1:          #16243a;
    --bu-ink-2:          #3d4a60;
    --bu-ink-3:          #6b7689;
    --bu-ink-4:          #9ba3b3;

    /* Surfaces */
    --bu-bg:             #f8f5ef;       /* page background (Harbor cream) */
    --bu-bg-elev:        #ffffff;       /* card / panel background */
    --bu-bg-sunk:        #f0ebe1;       /* hover / track / inset */
    --bu-line:           rgba(22, 36, 58, 0.10);
    --bu-line-2:         rgba(22, 36, 58, 0.06);

    /* Brand */
    --bu-primary:        #16243a;
    --bu-primary-rgb:    22, 36, 58;
    --bu-primary-ink:    #ffffff;
    --bu-primary-soft:   rgba(22, 36, 58, 0.08);
    --bu-accent:         #c1683a;       /* terracotta */
    --bu-accent-soft:    #f3e3d6;

    /* Status — strong + soft pairs for KPI deltas, schedule bars, etc. */
    --bu-success:        #2e7a55;
    --bu-success-soft:   #d8ead9;
    --bu-warn:           #b87a14;
    --bu-warn-soft:      #f4e6c5;
    --bu-danger:         #a52a2a;
    --bu-danger-soft:    #f1d9d4;

    /* Type families */
    --bu-display:        'Fraunces', 'Cormorant Garamond', Georgia, serif;
    --bu-body:           'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --bu-mono:           ui-monospace, 'SF Mono', 'Cascadia Mono', 'JetBrains Mono', monospace;

    /* Type scale (admin uses fixed sizes, no scale multiplier) */
    --bu-fs-xs:          11px;
    --bu-fs-sm:          13px;
    --bu-fs-md:          15px;
    --bu-fs-lg:          17px;
    --bu-fs-xl:          24px;
    --bu-fs-2xl:         28px;
    --bu-fs-3xl:         34px;
    --bu-fs-4xl:         64px;

    /* Radii */
    --bu-radius-sm:      6px;
    --bu-radius-md:      10px;
    --bu-radius-lg:      18px;
    --bu-radius-pill:    999px;

    /* Shadows */
    --bu-shadow-1:       0 1px 2px rgba(22, 36, 58, 0.06), 0 0 0 1px rgba(22, 36, 58, 0.04);
    --bu-shadow-2:       0 2px 6px rgba(22, 36, 58, 0.06), 0 8px 24px rgba(22, 36, 58, 0.08);
    /* ── Color: raw scale ──────────────────────────────────────────────────── */

    /* Slate (neutral) */
    --cb-color-slate-50:  #f8fafc;
    --cb-color-slate-100: #f1f5f9;
    --cb-color-slate-200: #e2e8f0;
    --cb-color-slate-300: #cbd5e1;
    --cb-color-slate-400: #94a3b8;
    --cb-color-slate-500: #64748b;
    --cb-color-slate-600: #475569;
    --cb-color-slate-700: #334155;
    --cb-color-slate-800: #1e293b;
    --cb-color-slate-900: #0f172a;

    /* Blue (primary brand) */
    --cb-color-blue-50:   #eff6ff;
    --cb-color-blue-100:  #dbeafe;
    --cb-color-blue-200:  #bfdbfe;
    --cb-color-blue-300:  #93c5fd;
    --cb-color-blue-400:  #60a5fa;
    --cb-color-blue-500:  #3b82f6;
    --cb-color-blue-600:  #2563eb;
    --cb-color-blue-700:  #1d4ed8;
    --cb-color-blue-800:  #1e40af;
    --cb-color-blue-900:  #1e3a8a;

    /* Green (success) */
    --cb-color-green-50:  #f0fdf4;
    --cb-color-green-100: #dcfce7;
    --cb-color-green-500: #22c55e;
    --cb-color-green-600: #16a34a;
    --cb-color-green-700: #15803d;

    /* Amber (warning) */
    --cb-color-amber-50:  #fffbeb;
    --cb-color-amber-100: #fef3c7;
    --cb-color-amber-500: #f59e0b;
    --cb-color-amber-600: #d97706;
    --cb-color-amber-700: #b45309;

    /* Red (danger / error) */
    --cb-color-red-50:    #fef2f2;
    --cb-color-red-100:   #fee2e2;
    --cb-color-red-500:   #ef4444;
    --cb-color-red-600:   #dc2626;
    --cb-color-red-700:   #b91c1c;

    /* Pure */
    --cb-color-white:     #ffffff;
    --cb-color-black:     #000000;

    /* ── Color: semantic ───────────────────────────────────────────────────── */

    /* Surfaces */
    --cb-bg:                   var( --cb-color-slate-50  );  /* page background */
    --cb-surface:              var( --cb-color-white     );  /* cards, panels */
    --cb-surface-raised:       var( --cb-color-white     );  /* modals, popovers */
    --cb-surface-subtle:       var( --cb-color-slate-100 );  /* striped rows, hover bg */

    /* Text */
    --cb-text-primary:         var( --cb-color-slate-900 );
    --cb-text-secondary:       var( --cb-color-slate-700 );
    --cb-text-muted:           var( --cb-color-slate-500 );
    --cb-text-inverse:         var( --cb-color-white     );

    /* Borders / dividers */
    --cb-border:               var( --cb-color-slate-200 );
    --cb-border-strong:        var( --cb-color-slate-300 );
    --cb-border-subtle:        var( --cb-color-slate-100 );

    /* Brand (operator-overridable on wizard / partner — semantic stays the same) */
    --cb-brand:                var( --cb-color-blue-600  );
    --cb-brand-hover:          var( --cb-color-blue-700  );
    --cb-brand-subtle:         var( --cb-color-blue-50   );
    --cb-brand-text:           var( --cb-color-blue-700  );
    --cb-on-brand:             var( --cb-color-white     );

    /* Status */
    --cb-success:              var( --cb-color-green-600 );
    --cb-success-subtle:       var( --cb-color-green-50  );
    --cb-success-text:         var( --cb-color-green-700 );

    --cb-warning:              var( --cb-color-amber-600 );
    --cb-warning-subtle:       var( --cb-color-amber-50  );
    --cb-warning-text:         var( --cb-color-amber-700 );

    --cb-danger:               var( --cb-color-red-600   );
    --cb-danger-hover:         var( --cb-color-red-700   );
    --cb-danger-subtle:        var( --cb-color-red-50    );
    --cb-danger-text:          var( --cb-color-red-700   );

    /* ── Spacing: 4px grid ─────────────────────────────────────────────────── */

    --cb-space-0:   0;
    --cb-space-1:   0.25rem;   /*  4px */
    --cb-space-2:   0.5rem;    /*  8px */
    --cb-space-3:   0.75rem;   /* 12px */
    --cb-space-4:   1rem;      /* 16px */
    --cb-space-5:   1.25rem;   /* 20px */
    --cb-space-6:   1.5rem;    /* 24px */
    --cb-space-8:   2rem;      /* 32px */
    --cb-space-10:  2.5rem;    /* 40px */
    --cb-space-12:  3rem;      /* 48px */
    --cb-space-16:  4rem;      /* 64px */
    --cb-space-20:  5rem;      /* 80px */

    /* ── Border radius ─────────────────────────────────────────────────────── */

    --cb-radius-none: 0;
    --cb-radius-sm:   0.25rem;  /* 4px */
    --cb-radius-md:   0.375rem; /* 6px — default for buttons + inputs */
    --cb-radius-lg:   0.5rem;   /* 8px — default for cards */
    --cb-radius-xl:   0.75rem;  /* 12px */
    --cb-radius-2xl:  1rem;     /* 16px */
    --cb-radius-full: 9999px;   /* pills, avatars */

    /* ── Shadows ───────────────────────────────────────────────────────────── */

    /* Shadow scale tuned for light backgrounds + minimal-modern feel.
     * `focus` is the focus-visible ring; never use box-shadow for non-focus rings. */
    --cb-shadow-none: none;
    --cb-shadow-sm:   0 1px 2px 0 rgba( 15, 23, 42, 0.04 );
    --cb-shadow-md:   0 1px 3px 0 rgba( 15, 23, 42, 0.06 ), 0 1px 2px -1px rgba( 15, 23, 42, 0.04 );
    --cb-shadow-lg:   0 4px 6px -1px rgba( 15, 23, 42, 0.08 ), 0 2px 4px -2px rgba( 15, 23, 42, 0.04 );
    --cb-shadow-xl:   0 10px 15px -3px rgba( 15, 23, 42, 0.10 ), 0 4px 6px -4px rgba( 15, 23, 42, 0.06 );
    --cb-shadow-focus: 0 0 0 3px rgba( 59, 130, 246, 0.35 );  /* blue-500 @ 35% */

    /* ── Typography ────────────────────────────────────────────────────────── */

    /* Font stack — Inter takes priority when locally installed (some operators have
     * it as a system font). Falls back to native system fonts so the plugin works
     * out of the box without shipping woff2 binaries. Operators who want guaranteed
     * Inter rendering can drop the woff2 files into assets/branding/fonts/ later. */
    --cb-font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    --cb-font-mono: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, 'Liberation Mono', monospace;

    /* Type scale (tight, info-dense, but readable) */
    --cb-text-xs:   0.75rem;   /* 12px — meta text */
    --cb-text-sm:   0.8125rem; /* 13px — body small */
    --cb-text-base: 0.875rem;  /* 14px — body default */
    --cb-text-lg:   1rem;      /* 16px — large body */
    --cb-text-xl:   1.125rem;  /* 18px — section heading */
    --cb-text-2xl:  1.5rem;    /* 24px — page heading */
    --cb-text-3xl:  1.875rem;  /* 30px — display */

    /* Weight + line-height + letter spacing */
    --cb-font-weight-regular:  400;
    --cb-font-weight-medium:   500;
    --cb-font-weight-semibold: 600;
    --cb-font-weight-bold:     700;

    --cb-line-height-tight:    1.2;
    --cb-line-height-snug:     1.4;
    --cb-line-height-normal:   1.5;
    --cb-line-height-relaxed:  1.6;

    --cb-letter-spacing-tight: -0.01em;  /* headings */
    --cb-letter-spacing-wide:  0.025em;  /* small caps, labels */

    /* ── Motion ────────────────────────────────────────────────────────────── */

    --cb-duration-fast:    100ms;
    --cb-duration-base:    150ms;
    --cb-duration-medium:  200ms;
    --cb-duration-slow:    300ms;

    --cb-ease-standard:    cubic-bezier( 0.4, 0, 0.2, 1 );
    --cb-ease-in:          cubic-bezier( 0.4, 0, 1, 1 );
    --cb-ease-out:         cubic-bezier( 0, 0, 0.2, 1 );

    /* ── Z-index ───────────────────────────────────────────────────────────── */

    --cb-z-base:     0;
    --cb-z-dropdown: 1000;
    --cb-z-sticky:   1020;
    --cb-z-overlay:  1040;
    --cb-z-modal:    1050;
    --cb-z-toast:    1080;
}

/* ─────────────────────────────────────────────────────────────
 * Phase T — Customer wizard directions (BoatUP design system)
 *
 * Two directions replace the four Phase-S presets (ocean / sunset /
 * minimal / classic). Each direction re-declares every token the
 * wizard reads, scoped under [data-cb-direction] so the swap is a
 * single attribute on the wizard root with no residual state.
 *
 *   Harbor — warm editorial: Fraunces serif display + Inter body,
 *            terracotta accent on a cream/navy palette.
 *   Helm   — cool dense: Inter throughout, deep teal primary on a
 *            cool gray palette.
 *
 * Operators on the four old presets are migrated by
 * `class-settings.php::migrate_theme_preset_to_direction()` on
 * plugin load:
 *   ocean | sunset | classic | custom → harbor
 *   minimal                            → helm
 *
 * Live operator tweaks layer on top via [data-cb-density],
 * [data-cb-radius], [data-cb-btn], and an inline `--cb-scale` font
 * multiplier. See sections further down.
 * ───────────────────────────────────────────────────────────── */

/* Token consumers — the wizard reads these names today (build_wizard_css
 * and inline JSX), so direction blocks meet consumers where they live:
 *
 *   --cb-background  page bg              --cb-primary         brand
 *   --cb-card        card / popover bg    --cb-primary-rgb     "r, g, b"
 *   --cb-border      divider / input      --cb-primary-dark    hover
 *   --cb-text        body text            --cb-primary-light   subtle fill
 *   --cb-muted       muted text colour    --cb-accent          secondary brand
 *   --cb-surface-2   second surface tint  --cb-accent-soft     subtle accent fill
 *   --cb-display-font headings            --cb-font-family     body font
 *   --cb-btn-radius  button + input       --cb-card-radius     larger card corners
 *   --cb-density     padding multiplier   --cb-scale           font-size multiplier
 *
 * Admin UI keeps its own --cb-text-muted etc. in :root — there is
 * intentionally a two-namespace split between admin and wizard. */

/* Harbor — DEFAULT direction. Tokens emitted both with no attribute
 * (so existing wizards without the attr render as Harbor) and under
 * the explicit [data-cb-direction="harbor"] selector for clarity. */
.cb-booking-widget,
[data-cb-direction="harbor"] {
    --cb-background:   #f8f5ef;
    --cb-card:         #ffffff;
    --cb-surface-2:    #f0ebe1;
    --cb-border:       rgba(22, 36, 58, 0.10);
    --cb-text:         #16243a;
    --cb-muted:        #6b7689;
    --cb-primary:      #16243a;
    --cb-primary-rgb:  22, 36, 58;
    --cb-primary-dark: #0c1525;
    --cb-primary-light: rgba(22, 36, 58, 0.08);
    --cb-accent:       #c1683a;
    --cb-accent-rgb:   193, 104, 58;
    --cb-accent-soft:  #f3e3d6;
    --cb-display-font: 'Fraunces', 'Cormorant Garamond', Georgia, serif;
    --cb-font-family:  'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --cb-btn-radius:   14px;
    --cb-card-radius:  22px;
}

[data-cb-direction="helm"] {
    --cb-background:   #f6f7f8;
    --cb-card:         #ffffff;
    --cb-surface-2:    #eef0f2;
    --cb-border:       rgba(13, 27, 34, 0.10);
    --cb-text:         #0d1b22;
    --cb-muted:        #5b6873;
    --cb-primary:      #0a6f6a;
    --cb-primary-rgb:  10, 111, 106;
    --cb-primary-dark: #075752;
    --cb-primary-light: rgba(10, 111, 106, 0.08);
    --cb-accent:       #d3791d;
    --cb-accent-rgb:   211, 121, 29;
    --cb-accent-soft:  #faecd7;
    --cb-display-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --cb-font-family:  'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --cb-btn-radius:   14px;
    --cb-card-radius:  22px;
}

/* ── Live operator tweaks ─────────────────────────────────────
 *
 * These three attribute blocks override radius across the wizard,
 * which is the most user-visible tweak. Density is a multiplier
 * applied as a CSS variable that consumers (button heights, card
 * paddings, gaps) read via calc(). Font-scale is set inline on the
 * wizard root from JS (operator setting) — there's no preset block
 * for it, just the variable definition below.
 * ───────────────────────────────────────────────────────────── */

/* Density multiplier — defaults below; overrides via attribute */
.cb-booking-widget,
[data-cb-direction="harbor"],
[data-cb-direction="helm"] {
    --cb-density: 1;
    --cb-scale:   1;
}
[data-cb-density="compact"]     { --cb-density: 0.78; }
[data-cb-density="cozy"]        { --cb-density: 0.9;  }
[data-cb-density="comfortable"] { --cb-density: 1.1;  }

/* Radius tweak — overrides direction's btn + card radius */
[data-cb-radius="sharp"] {
    --cb-btn-radius:   4px;
    --cb-card-radius:  6px;
}
[data-cb-radius="rounded"] {
    --cb-btn-radius:   14px;
    --cb-card-radius:  22px;
}
[data-cb-radius="pill"] {
    --cb-btn-radius:   999px;
    --cb-card-radius:  28px;
}

/* Button-style tweak — soft and outline variants apply at the
 * component layer (booking.css reads --cb-btn-bg / --cb-btn-fg
 * accordingly). Filled is the default. */
[data-cb-btn="filled"] {
    --cb-btn-bg: var(--cb-primary);
    --cb-btn-fg: var(--cb-on-brand, #ffffff);
    --cb-btn-border: transparent;
}
[data-cb-btn="outline"] {
    --cb-btn-bg: transparent;
    --cb-btn-fg: var(--cb-primary);
    --cb-btn-border: var(--cb-primary);
}
[data-cb-btn="soft"] {
    --cb-btn-bg: rgba(var(--cb-primary-rgb), 0.12);
    --cb-btn-fg: var(--cb-primary);
    --cb-btn-border: transparent;
}

/* ─────────────────────────────────────────────────────────────────────
 * Inherit modes — opt the wizard out of its own colour or typography
 * tokens so the host theme bleeds through. Layout + spacing + radius
 * always come from the base tokens so the wizard doesn't break
 * structurally regardless of which (or both) inherit toggles are on.
 *
 * v2.18.0 — split into two independent attributes (was single
 * [data-cb-inherit="true"] block). The legacy attribute is kept as
 * a one-release alias that maps to "inherit both" so any external
 * CSS that depended on it doesn't break.
 * ───────────────────────────────────────────────────────────────────── */

/* Inherit fonts: typography only — colour palette stays branded. */
[data-cb-inherit-fonts="true"] {
    --cb-font-family:  inherit;
    --cb-display-font: inherit;
}

/* Inherit colours: bg/text/muted dissolve into the host theme. The
 * --cb-primary stays currentColor so links / CTAs still show contrast
 * even when the operator hasn't set a wizard_color_primary. Operator
 * colour overrides via build_wizard_css are NOT emitted in this mode
 * (build_wizard_css gates on wizard_inherit_theme_colors), so this
 * block is the source of truth for the inherited surfaces. */
[data-cb-inherit-colors="true"] {
    --cb-background:   transparent;
    --cb-card:         transparent;
    --cb-surface:      transparent;
    --cb-text:         inherit;
    --cb-muted:        inherit;
    --cb-primary:      currentColor;
    --cb-primary-rgb:  0, 0, 0;
    --cb-primary-dark: currentColor;
    --cb-primary-light:currentColor;
}

/* Legacy single-toggle alias — pre-v2.18.0 installs that wrote
 * data-cb-inherit="true" directly continue to inherit both. */
[data-cb-inherit="true"] {
    --cb-background:   transparent;
    --cb-card:         transparent;
    --cb-surface:      transparent;
    --cb-text:         inherit;
    --cb-muted:        inherit;
    --cb-primary:      currentColor;
    --cb-primary-rgb:  0, 0, 0;
    --cb-primary-dark: currentColor;
    --cb-primary-light:currentColor;
    --cb-display-font: inherit;
    --cb-font-family:  inherit;
}

/* ─────────────────────────────────────────────────────────────────────
 * G1 (v2.4.0) — Wizard chrome aliases.
 *
 * The Phase 7 handoff (Claude Design Batch G1) ships components that
 * reference a slightly different set of token names than the Phase T
 * `--bu-*` system that already lives above. Rather than rewrite every
 * `var(--bu-*)` reference inside the handoff CSS (and risk drifting from
 * Claude Design's source-of-truth files in `cruise-booking/docs/phase-7/g1-handoff/`),
 * we publish a thin alias bridge here. Five aliases + three net-new vars.
 *
 * If/when a future batch renames the existing `--bu-*` tokens to match
 * the handoff convention everywhere, this block can disappear.
 * ───────────────────────────────────────────────────────────────────── */
:root {
    /* Aliases — handoff name → existing canonical name */
    --bu-ink:          var(--bu-ink-1);          /* primary text colour */
    --bu-fs-base:      var(--bu-fs-md);          /* body font size */
    --bu-radius:       var(--bu-radius-md);      /* default corner radius */
    --bu-font-display: var(--bu-display);        /* display / heading font */
    --bu-font-body:    var(--bu-body, -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif);
    --bu-font-mono:    var(--bu-mono);

    /* Net-new — values lifted from the G1 handoff tokens.css */
    --bu-step:         8px;                       /* spacing unit (multiplied in calc()) */
    --bu-pad-card:     calc(28px * var(--bu-density, 1));
    --bu-shadow-3:     0 24px 60px -20px rgba(22, 36, 58, .25);
}

/* <Button> — primitive
 *
 * Base + variant + size + state. Variants: primary | secondary | ghost | danger.
 * Sizes: sm | md. The loading state swaps the leading icon slot for a spinner
 * and disables interaction; the disabled state mutes the entire affordance.
 */

.cb-ui-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var( --cb-space-2 );

    padding: var( --cb-space-2 ) var( --cb-space-4 );
    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-base );
    font-weight: var( --cb-font-weight-medium );
    line-height: 1.25;
    letter-spacing: 0;

    border: 1px solid transparent;
    border-radius: var( --cb-radius-md );
    background: transparent;
    color: var( --cb-text-primary );

    cursor: pointer;
    -webkit-user-select: none;
       -moz-user-select: none;
            user-select: none;
    transition:
        background-color var( --cb-duration-base ) var( --cb-ease-standard ),
        border-color     var( --cb-duration-base ) var( --cb-ease-standard ),
        color            var( --cb-duration-base ) var( --cb-ease-standard ),
        box-shadow       var( --cb-duration-base ) var( --cb-ease-standard );
}

.cb-ui-btn:focus-visible {
    outline: none;
    box-shadow: var( --cb-shadow-focus );
}

.cb-ui-btn:disabled,
.cb-ui-btn[ aria-disabled="true" ] {
    opacity: 0.55;
    cursor: not-allowed;
}

/* ── Sizes ─────────────────────────────────────────────────────────────── */

.cb-ui-btn--sm {
    padding: var( --cb-space-1 ) var( --cb-space-3 );
    font-size: var( --cb-text-sm );
    border-radius: var( --cb-radius-sm );
}

/* ── Variants ──────────────────────────────────────────────────────────── */

.cb-ui-btn--primary {
    background: var( --cb-brand );
    color: var( --cb-on-brand );
}
.cb-ui-btn--primary:hover:not( :disabled ) {
    background: var( --cb-brand-hover );
}

.cb-ui-btn--secondary {
    background: var( --cb-surface );
    color: var( --cb-text-primary );
    border-color: var( --cb-border-strong );
}
.cb-ui-btn--secondary:hover:not( :disabled ) {
    background: var( --cb-surface-subtle );
    border-color: var( --cb-border-strong );
}

.cb-ui-btn--ghost {
    background: transparent;
    color: var( --cb-text-secondary );
}
.cb-ui-btn--ghost:hover:not( :disabled ) {
    background: var( --cb-surface-subtle );
    color: var( --cb-text-primary );
}

.cb-ui-btn--danger {
    background: var( --cb-danger );
    color: var( --cb-text-inverse );
}
.cb-ui-btn--danger:hover:not( :disabled ) {
    background: var( --cb-danger-hover );
}

/* ── Icon slot + loading spinner ───────────────────────────────────────── */

.cb-ui-btn__icon {
    display: inline-flex;
    flex-shrink: 0;
    width: 1em;
    height: 1em;
}

.cb-ui-btn__spinner {
    display: inline-block;
    flex-shrink: 0;
    width: 1em;
    height: 1em;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: var( --cb-radius-full );
    animation: cb-ui-btn-spin var( --cb-duration-slow ) linear infinite;
}

@keyframes cb-ui-btn-spin {
    to { transform: rotate( 360deg ); }
}

/* <Input> — primitive
 *
 * Replaces the legacy `.cb-input`. Visual states: default, focus, hover, disabled,
 * error. Optional leading/trailing icon slots. Helper-text + error-text live in
 * <FormField> (R2.9), not here — Input stays a single control.
 */

.cb-ui-input {
    display: block;
    width: 100%;

    padding: var( --cb-space-2 ) var( --cb-space-3 );
    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-base );
    font-weight: var( --cb-font-weight-regular );
    line-height: 1.4;
    color: var( --cb-text-primary );

    background: var( --cb-surface );
    border: 1px solid var( --cb-border );
    border-radius: var( --cb-radius-md );

    transition:
        border-color var( --cb-duration-base ) var( --cb-ease-standard ),
        box-shadow   var( --cb-duration-base ) var( --cb-ease-standard ),
        background   var( --cb-duration-base ) var( --cb-ease-standard );
}

.cb-ui-input::-moz-placeholder {
    color: var( --cb-text-muted );
}

.cb-ui-input::placeholder {
    color: var( --cb-text-muted );
}

.cb-ui-input:hover:not( :disabled ):not( :focus ) {
    border-color: var( --cb-border-strong );
}

.cb-ui-input:focus,
.cb-ui-input:focus-visible {
    outline: none;
    border-color: var( --cb-brand );
    box-shadow: var( --cb-shadow-focus );
}

.cb-ui-input:disabled {
    background: var( --cb-surface-subtle );
    color: var( --cb-text-muted );
    cursor: not-allowed;
}

.cb-ui-input--error {
    border-color: var( --cb-danger );
}
.cb-ui-input--error:focus {
    border-color: var( --cb-danger );
    box-shadow: 0 0 0 3px rgba( 239, 68, 68, 0.25 );  /* red-500 @ 25% */
}

/* ── Wrapper for icon slots ────────────────────────────────────────────── */

.cb-ui-input-wrap {
    position: relative;
    display: block;
    width: 100%;
}

.cb-ui-input-wrap--has-leading .cb-ui-input  { padding-left: var( --cb-space-10 ); }
.cb-ui-input-wrap--has-trailing .cb-ui-input { padding-right: var( --cb-space-10 ); }

.cb-ui-input__icon {
    position: absolute;
    top: 50%;
    transform: translateY( -50% );
    display: inline-flex;
    color: var( --cb-text-muted );
    pointer-events: none;
}
.cb-ui-input__icon--leading  { left:  var( --cb-space-3 ); }
.cb-ui-input__icon--trailing { right: var( --cb-space-3 ); }

/* <Card> — primitive
 *
 * Replaces the legacy `.cb-card` (which baked in p-6 + shadow-sm + a fixed
 * border colour). Variants split into:
 *   - flat        : surface + border, no shadow
 *   - elevated    : surface + shadow-md, no border (modern Stripe-style "lift")
 *   - interactive : flat at rest, elevated + brand-tinted border on hover/focus
 *
 * Padding presets give callers a single switch instead of every page hand-rolling
 * its own .p-* override.
 */

.cb-ui-card {
    display: block;
    background: var( --cb-surface );
    border-radius: var( --cb-radius-lg );
    transition:
        box-shadow   var( --cb-duration-medium ) var( --cb-ease-standard ),
        border-color var( --cb-duration-medium ) var( --cb-ease-standard ),
        transform    var( --cb-duration-medium ) var( --cb-ease-standard );
}

/* ── Variants ──────────────────────────────────────────────────────────── */

.cb-ui-card--flat {
    border: 1px solid var( --cb-border );
    box-shadow: var( --cb-shadow-none );
}

.cb-ui-card--elevated {
    border: 1px solid transparent;
    box-shadow: var( --cb-shadow-md );
}

.cb-ui-card--interactive {
    border: 1px solid var( --cb-border );
    box-shadow: var( --cb-shadow-none );
    cursor: pointer;
    text-align: inherit;  /* normalise <button> default */
    width: 100%;
    font: inherit;
    color: inherit;
}
.cb-ui-card--interactive:hover,
.cb-ui-card--interactive:focus-visible {
    border-color: var( --cb-brand );
    box-shadow: var( --cb-shadow-lg );
    outline: none;
}
.cb-ui-card--interactive:focus-visible {
    box-shadow: var( --cb-shadow-lg ), var( --cb-shadow-focus );
}

/* ── Padding presets ───────────────────────────────────────────────────── */

.cb-ui-card--p-none { padding: 0; }
.cb-ui-card--p-sm   { padding: var( --cb-space-3 ); }
.cb-ui-card--p-md   { padding: var( --cb-space-4 ); }
.cb-ui-card--p-lg   { padding: var( --cb-space-6 ); }
.cb-ui-card--p-xl   { padding: var( --cb-space-8 ); }

/* <Badge> — primitive
 *
 * Replaces the legacy `.cb-badge` family. Variants map to the semantic status
 * tokens, so theme presets recolour every badge in one place. The optional dot
 * indicator preserves StatusBadge's existing visual idiom; sm vs md only
 * changes padding + font size.
 */

.cb-ui-badge {
    display: inline-flex;
    align-items: center;
    gap: var( --cb-space-1 );

    padding: 2px var( --cb-space-2 );
    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-xs );
    font-weight: var( --cb-font-weight-medium );
    line-height: 1.4;
    white-space: nowrap;

    border: 1px solid transparent;
    border-radius: var( --cb-radius-full );
}

/* ── Sizes ─────────────────────────────────────────────────────────────── */

.cb-ui-badge--md {
    padding: 2px var( --cb-space-3 );
    font-size: var( --cb-text-sm );
}

/* ── Variants (semantic) ───────────────────────────────────────────────── */

.cb-ui-badge--neutral {
    background: var( --cb-surface-subtle );
    color: var( --cb-text-secondary );
}

.cb-ui-badge--success {
    background: var( --cb-success-subtle );
    color: var( --cb-success-text );
}

.cb-ui-badge--warning {
    background: var( --cb-warning-subtle );
    color: var( --cb-warning-text );
}

.cb-ui-badge--error {
    background: var( --cb-danger-subtle );
    color: var( --cb-danger-text );
}

.cb-ui-badge--info {
    background: var( --cb-brand-subtle );
    color: var( --cb-brand-text );
}

/* ── Dot indicator ─────────────────────────────────────────────────────── */

.cb-ui-badge__dot {
    width: 6px;
    height: 6px;
    border-radius: var( --cb-radius-full );
    background: currentColor;
    flex-shrink: 0;
}

/* <Modal> — primitive
 *
 * Centred dialog with blurred backdrop. Header / body / footer are slot props
 * on the JSX side; this file just owns the shell + sizing + motion. The focus
 * trap + Escape handler + initial focus management live in Modal.jsx.
 *
 * Sizes (max-width):
 *   sm  = 360px   confirm / alert
 *   md  = 480px   default form
 *   lg  = 640px   wider form / detail view
 *   xl  = 800px   data-heavy panel
 *   fullscreen = full viewport (mobile sheet, gallery)
 */

.cb-ui-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: var( --cb-z-overlay );

    display: flex;
    align-items: center;
    justify-content: center;
    padding: var( --cb-space-4 );

    background: rgba( 15, 23, 42, 0.55 );  /* slate-900 @ 55% */
    backdrop-filter: blur( 2px );

    animation: cb-ui-modal-backdrop-in var( --cb-duration-medium ) var( --cb-ease-out );
}

.cb-ui-modal {
    position: relative;
    z-index: var( --cb-z-modal );

    display: flex;
    flex-direction: column;
    width: 100%;
    max-height: calc( 100vh - var( --cb-space-8 ) );

    background: var( --cb-surface-raised );
    border-radius: var( --cb-radius-xl );
    box-shadow: var( --cb-shadow-xl );

    animation: cb-ui-modal-in var( --cb-duration-medium ) var( --cb-ease-out );
}

.cb-ui-modal:focus { outline: none; }

/* ── Sizes ─────────────────────────────────────────────────────────────── */

.cb-ui-modal--sm { max-width: 360px; }
.cb-ui-modal--md { max-width: 480px; }
.cb-ui-modal--lg { max-width: 640px; }
.cb-ui-modal--xl { max-width: 800px; }
.cb-ui-modal--fullscreen {
    max-width: none;
    max-height: 100vh;
    width: 100vw;
    height: 100vh;
    border-radius: 0;
}

/* ── Sections ──────────────────────────────────────────────────────────── */

.cb-ui-modal__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: var( --cb-space-4 );
    padding: var( --cb-space-5 ) var( --cb-space-6 );
    border-bottom: 1px solid var( --cb-border );
}

.cb-ui-modal__title {
    margin: 0;
    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-lg );
    font-weight: var( --cb-font-weight-semibold );
    letter-spacing: var( --cb-letter-spacing-tight );
    color: var( --cb-text-primary );
    line-height: var( --cb-line-height-snug );
}

.cb-ui-modal__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var( --cb-space-8 );
    height: var( --cb-space-8 );
    margin: calc( -1 * var( --cb-space-2 ) ) calc( -1 * var( --cb-space-2 ) ) 0 0;
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: var( --cb-radius-md );
    color: var( --cb-text-muted );
    cursor: pointer;
    transition: background var( --cb-duration-base ) var( --cb-ease-standard );
}
.cb-ui-modal__close:hover { background: var( --cb-surface-subtle ); color: var( --cb-text-primary ); }
.cb-ui-modal__close:focus-visible { outline: none; box-shadow: var( --cb-shadow-focus ); }

.cb-ui-modal__body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: var( --cb-space-6 );
    color: var( --cb-text-secondary );
    font-size: var( --cb-text-base );
    line-height: var( --cb-line-height-normal );
}

.cb-ui-modal__footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: var( --cb-space-2 );
    padding: var( --cb-space-4 ) var( --cb-space-6 );
    border-top: 1px solid var( --cb-border );
    background: var( --cb-bg );
    border-radius: 0 0 var( --cb-radius-xl ) var( --cb-radius-xl );
}

.cb-ui-modal--fullscreen .cb-ui-modal__footer {
    border-radius: 0;
}

/* ── Motion ────────────────────────────────────────────────────────────── */

@keyframes cb-ui-modal-backdrop-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes cb-ui-modal-in {
    from { opacity: 0; transform: translateY( 8px ) scale( 0.98 ); }
    to   { opacity: 1; transform: translateY( 0 )    scale( 1 ); }
}

@media ( prefers-reduced-motion: reduce ) {
    .cb-ui-modal-backdrop,
    .cb-ui-modal { animation: none; }
}

/* <Table> — primitive
 *
 * Replaces the raw <table> instances on Reservations / Customers / Partners /
 * Pricing. Columns live in a `columns` array prop (JSX side); this file owns
 * the visual grid — row dividers, hover affordance, sort-indicator chrome,
 * sticky-header behaviour for scrollable wrappers.
 */

.cb-ui-table-wrap {
    width: 100%;
    overflow-x: auto;
    /* See Tabs.css — explicit overflow-y stops the browser computing it as
     * `auto` and surfacing a phantom 1px scrollbar from sub-pixel mismatch. */
    overflow-y: hidden;
    background: var( --cb-surface );
    border: 1px solid var( --cb-border );
    border-radius: var( --cb-radius-lg );
    box-shadow: var( --cb-shadow-sm );
}

.cb-ui-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-base );
    color: var( --cb-text-primary );
}

/* ── Header ────────────────────────────────────────────────────────────── */

.cb-ui-table thead th {
    position: sticky;
    top: 0;
    z-index: 1;

    padding: var( --cb-space-3 ) var( --cb-space-4 );
    background: var( --cb-bg );
    color: var( --cb-text-muted );
    font-size: var( --cb-text-xs );
    font-weight: var( --cb-font-weight-semibold );
    text-transform: uppercase;
    letter-spacing: var( --cb-letter-spacing-wide );
    text-align: left;
    white-space: nowrap;
    border-bottom: 1px solid var( --cb-border );
}

.cb-ui-table th.cb-ui-table__th--sortable {
    cursor: pointer;
    -webkit-user-select: none;
       -moz-user-select: none;
            user-select: none;
}
.cb-ui-table th.cb-ui-table__th--sortable:hover {
    color: var( --cb-text-primary );
}

.cb-ui-table__sort-icon {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin-left: var( --cb-space-1 );
    vertical-align: middle;
    opacity: 0.4;
}
.cb-ui-table__th--sorted .cb-ui-table__sort-icon { opacity: 1; }

/* Alignment helpers (column `align` prop) */
.cb-ui-table__cell--start  { text-align: left; }
.cb-ui-table__cell--center { text-align: center; }
.cb-ui-table__cell--end    { text-align: right; }

/* ── Body ──────────────────────────────────────────────────────────────── */

.cb-ui-table tbody td {
    padding: var( --cb-space-3 ) var( --cb-space-4 );
    border-bottom: 1px solid var( --cb-border-subtle );
    color: var( --cb-text-primary );
    vertical-align: middle;
}

.cb-ui-table tbody tr:last-child td {
    border-bottom: 0;
}

.cb-ui-table tbody tr.cb-ui-table__row--clickable {
    cursor: pointer;
    transition: background var( --cb-duration-base ) var( --cb-ease-standard );
}
.cb-ui-table tbody tr.cb-ui-table__row--clickable:hover td {
    background: var( --cb-surface-subtle );
}

/* Right-aligned action column (row actions slot) */
.cb-ui-table__actions {
    display: inline-flex;
    gap: var( --cb-space-2 );
    justify-content: flex-end;
}

/* ── Empty + loading states ────────────────────────────────────────────── */

.cb-ui-table__empty {
    padding: var( --cb-space-12 ) var( --cb-space-6 );
    text-align: center;
    color: var( --cb-text-muted );
    font-size: var( --cb-text-base );
}

.cb-ui-table__skeleton-cell {
    height: 1em;
    border-radius: var( --cb-radius-sm );
    background: linear-gradient(
        90deg,
        var( --cb-surface-subtle ) 0%,
        var( --cb-border ) 50%,
        var( --cb-surface-subtle ) 100%
    );
    background-size: 200% 100%;
    animation: cb-ui-table-shimmer 1.4s ease-in-out infinite;
}

@keyframes cb-ui-table-shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* <Tabs> — primitive
 *
 * Underlined horizontal tab bar with a sliding indicator beneath the active
 * tab. Replaces the custom pill bars in Settings + Reservations filters. JS
 * owns keyboard navigation (arrow keys, Home, End) and roving tabindex; this
 * file owns the visual treatment only.
 *
 * v2.5.0 — adds (1) badge chip support per item (e.g. "v2.2" on the User
 * Levels tab), (2) mobile dropdown picker variant at <640px since a
 * sideways-scrolling 10-item chip row is hostile on a phone, and (3) a
 * right-edge fade gradient hint when the desktop/tablet strip overflows.
 * All driven by Claude Design's Batch 1 settings-tabs spec.
 */

.cb-ui-tabs {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* ── Mobile dropdown picker (≤639px) ─────────────────────────────────────── */
.cb-ui-tabs__mobile-picker {
    display: none;
    flex-direction: column;
    gap: 6px;
    width: 100%;
    margin-bottom: var( --cb-space-3, 12px );
}
.cb-ui-tabs__mobile-label {
    font-size: var( --bu-fs-xs, 11px );
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var( --bu-ink-3 );
    font-weight: 600;
}
.cb-ui-tabs__mobile-select-wrap {
    position: relative;
    display: flex;
    align-items: center;
    background: var( --bu-bg-elev );
    border: 1px solid var( --bu-line );
    border-radius: var( --bu-radius );
    padding: 0;
    overflow: hidden;
}
.cb-ui-tabs__mobile-select {
    -moz-appearance: none;
         appearance: none;
    -webkit-appearance: none;
    flex: 1 1 auto;
    background: transparent;
    border: 0;
    padding: 12px 36px 12px 14px;
    font-family: inherit;
    font-size: var( --bu-fs-base );
    color: var( --bu-ink );
    cursor: pointer;
}
.cb-ui-tabs__mobile-select:focus { outline: none; }
.cb-ui-tabs__mobile-select-wrap:focus-within {
    box-shadow: var( --cb-shadow-focus, 0 0 0 2px var( --bu-accent ) );
}
.cb-ui-tabs__mobile-chevron {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY( -50% );
    color: var( --bu-ink-3 );
    pointer-events: none;
    font-size: 14px;
}

@media ( max-width: 639px ) {
    .cb-ui-tabs__mobile-picker { display: flex; }
    .cb-ui-tabs__list          { display: none; }
}

.cb-ui-tabs__list {
    position: relative;
    display: flex;
    gap: var( --cb-space-1 );
    padding: 0;
    margin: 0;
    border-bottom: 1px solid var( --cb-border );
    overflow-x: auto;
    /* When overflow-x isn't `visible`, browsers compute overflow-y as `auto`
     * — any 1px sub-pixel mismatch (focus ring, border) then surfaces a
     * phantom vertical scrollbar. Force-hide the Y axis. */
    overflow-y: hidden;
    scrollbar-width: thin;
}

/* v2.5.0 — right-edge fade hint when the strip overflows. Pure CSS — uses
 * `mask-image` so it survives every theme palette without hard-coding the
 * background colour. Applied to the list itself so the fade tracks scroll.
 */
.cb-ui-tabs__list {
    -webkit-mask-image: linear-gradient( 90deg, #000 0, #000 calc( 100% - 24px ), transparent 100% );
            mask-image: linear-gradient( 90deg, #000 0, #000 calc( 100% - 24px ), transparent 100% );
}

.cb-ui-tabs__tab {
    position: relative;

    display: inline-flex;
    align-items: center;
    gap: var( --cb-space-2 );
    flex-shrink: 0;

    padding: var( --cb-space-3 ) var( --cb-space-4 );
    margin-bottom: -1px;  /* overlap border-bottom so active underline sits flush */

    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-base );
    font-weight: var( --cb-font-weight-medium );
    line-height: 1.25;
    color: var( --cb-text-muted );

    background: transparent;
    border: 0;
    border-bottom: 2px solid transparent;
    cursor: pointer;
    white-space: nowrap;

    transition:
        color        var( --cb-duration-base ) var( --cb-ease-standard ),
        border-color var( --cb-duration-base ) var( --cb-ease-standard ),
        background   var( --cb-duration-base ) var( --cb-ease-standard );
}

.cb-ui-tabs__tab:hover:not( [ aria-disabled="true" ] ) {
    color: var( --cb-text-primary );
    background: var( --cb-surface-subtle );
    border-top-left-radius: var( --cb-radius-sm );
    border-top-right-radius: var( --cb-radius-sm );
}

.cb-ui-tabs__tab:focus-visible {
    outline: none;
    box-shadow: var( --cb-shadow-focus );
    border-top-left-radius: var( --cb-radius-sm );
    border-top-right-radius: var( --cb-radius-sm );
}

.cb-ui-tabs__tab[ aria-selected="true" ] {
    color: var( --cb-brand-text );
    border-bottom-color: var( --cb-brand );
}

.cb-ui-tabs__tab[ aria-disabled="true" ] {
    opacity: 0.45;
    cursor: not-allowed;
}

/* v2.5.0 — chip badge alongside the label (e.g. "v2.2" on User Levels).
 * Sized per the B1 spec: `padding: 1px 7px; font-size: 10px; height: 18px`.
 */
.cb-ui-tabs__tab-badge {
    display: inline-flex;
    align-items: center;
    height: 18px;
    padding: 1px 7px;
    border-radius: var( --bu-radius-pill, 999px );
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.04em;
    background: var( --bu-accent-soft );
    color: var( --bu-accent );
    white-space: nowrap;
}

.cb-ui-tabs__panel {
    padding: var( --cb-space-5 ) 0;
}

.cb-ui-tabs__panel:focus-visible {
    outline: none;
    box-shadow: var( --cb-shadow-focus );
    border-radius: var( --cb-radius-sm );
}

/* <FormField> — primitive
 *
 * Label + required-asterisk + helper-text + error-text wrapper. DRYs out ~50
 * form groups across the admin that currently inline this markup.
 */

.cb-ui-formfield {
    display: flex;
    flex-direction: column;
    gap: var( --cb-space-1 );
    margin-bottom: var( --cb-space-4 );
}

.cb-ui-formfield__label {
    display: inline-flex;
    align-items: center;
    gap: var( --cb-space-1 );

    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-sm );
    font-weight: var( --cb-font-weight-medium );
    color: var( --cb-text-primary );
    line-height: var( --cb-line-height-snug );
}

.cb-ui-formfield__required {
    color: var( --cb-danger );
    font-weight: var( --cb-font-weight-semibold );
}

.cb-ui-formfield__optional {
    margin-left: auto;
    font-size: var( --cb-text-xs );
    font-weight: var( --cb-font-weight-regular );
    color: var( --cb-text-muted );
}

.cb-ui-formfield__control {
    display: block;
    width: 100%;
}

.cb-ui-formfield__helper,
.cb-ui-formfield__error {
    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-xs );
    line-height: var( --cb-line-height-snug );
}

.cb-ui-formfield__helper {
    color: var( --cb-text-muted );
}

.cb-ui-formfield__error {
    color: var( --cb-danger-text );
    font-weight: var( --cb-font-weight-medium );
}

/* <Select> — primitive
 *
 * Thin token-themed shell around the existing CustomSelect (which owns the
 * portal dropdown, keyboard nav, and optional search). This file adds:
 *   - Consistent token-based trigger styling (matches <Input>)
 *   - Error-state hook (red border + focus ring)
 *   - Disabled + focus treatments aligned with the rest of the UI
 *
 * Selectors use higher specificity to override CustomSelect's built-in
 * `.cb-cs-*` rules while leaving the legacy call sites untouched during
 * migration (the new wrapper opts in via `.cb-ui-select`).
 */

.cb-ui-select {
    display: block;
    width: 100%;
}

.cb-ui-select .cb-cs-trigger {
    padding: var( --cb-space-2 ) var( --cb-space-3 );
    font-family: var( --cb-font-sans );
    font-size: var( --cb-text-base );
    font-weight: var( --cb-font-weight-regular );
    color: var( --cb-text-primary );

    background: var( --cb-surface );
    border: 1px solid var( --cb-border );
    border-radius: var( --cb-radius-md );

    transition:
        border-color var( --cb-duration-base ) var( --cb-ease-standard ),
        box-shadow   var( --cb-duration-base ) var( --cb-ease-standard );
}

.cb-ui-select .cb-cs-trigger:hover:not( :disabled ) {
    border-color: var( --cb-border-strong );
}

.cb-ui-select .cb-cs-trigger:focus,
.cb-ui-select .cb-cs-trigger:focus-visible {
    outline: none;
    border-color: var( --cb-brand );
    box-shadow: var( --cb-shadow-focus );
}

.cb-ui-select .cb-cs-placeholder {
    color: var( --cb-text-muted );
}

.cb-ui-select.cb-ui-select--error .cb-cs-trigger {
    border-color: var( --cb-danger );
}
.cb-ui-select.cb-ui-select--error .cb-cs-trigger:focus {
    box-shadow: 0 0 0 3px rgba( 239, 68, 68, 0.25 );  /* red-500 @ 25% */
}

/* BoatUP UI primitives — Phase R component library
 *
 * Per-primitive stylesheets live next to each .jsx and are aggregated here.
 * Surface CSS files (admin index.css, wizard booking.css, partner partner.css)
 * `@import` this file so the same primitive markup renders correctly under any
 * of the three scopes. All rules consume semantic tokens from tokens.css —
 * never raw colour scales — so theme presets and operator overrides "just
 * work" by remapping the semantic layer.
 *
 * Class prefix: `.cb-ui-*` (distinct from legacy `.cb-*` so the two systems
 * coexist during migration without collision).
 */

/* BoatUP — Phase T Batch C / part 2 — mobile responsive overrides
 *
 * Reflows the Cruise + Rental wizard chrome (and the shared primitives) for
 * small viewports. Targets the same chrome class names used by Batch B
 * (`cb-booking-layout`, `cb-booking-layout__main`, `cb-booking-card`,
 * `cb-step-wrapper`, `cb-booking-grid`, `cb-booking-option`,
 * `cb-booking-nav`, `cb-step-indicator*`, `cb-summary-rail*`,
 * `cb-payment-method`, `cb-pax-compact-grid`, etc).
 *
 * Loaded by `booking.css` (the main session adds the @import). CSS-only —
 * no JSX changes. Token vars come from `tokens.css`.
 *
 * ── Reference designs ──
 *   MobileWizard1, 2, 5  — `BoatUP Audit + Mobile.html`
 *   MobileWizard3, 4     — `BoatUP Round 3.html`
 *
 * Visual targets:
 *   - `StepIndicator` numbered circles compress into a thin horizontal
 *     progress bar (5 segments — filled in `--cb-primary`, empty in
 *     `--cb-border`). Labels hide. The component still renders the same
 *     markup; CSS reshapes it.
 *   - `SummaryRail` (currently `display: none` below 1024px) becomes a
 *     fixed bottom drawer at <=768px showing condensed Total + Continue
 *     CTA. Expandable summary deferred — keeping the bottom unit
 *     condensed avoids relying on `:has()` quirks.
 *   - Booking-grid cards stack to one column with image on top.
 *   - 2-col contact / passenger grids collapse to 1-col.
 *   - Continue CTA inside `.cb-booking-nav` sticks to the viewport
 *     bottom (above the SummaryRail drawer).
 */


/* ─── 1. Tablet + phone breakpoint (<= 768px) ──────────────────────────── */

@media (max-width: 768px) {

    /* ── 1a. Wizard root padding so the sticky bottom drawer doesn't
     *      cover the last form row. The drawer is roughly 84–96px tall
     *      (Total line + 48px CTA + 14px padding × 2). Plus the sticky
     *      Back/Continue nav (~64px). Reserve space below the form.
     *
     *      We add the bottom space to the layout main column rather
     *      than the wizard root so blocks below the wizard (Testimonials,
     *      FAQ etc) keep their normal flow. */
    .cb-booking-layout__main {
        padding-bottom: calc(96px + 64px + env(safe-area-inset-bottom, 0px));
    }

    /* Inquiry-mode and other simple flows that don't render a SummaryRail
     * still get the sticky CTA. The :has() selector trims padding when
     * no rail exists — fallback (no :has support) keeps the larger
     * padding, which simply gives extra whitespace at the bottom. */
    .cb-booking-layout:not(:has(.cb-summary-rail)) .cb-booking-layout__main {
        padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px));
    }


    /* ── 1b. Step indicator → horizontal progress bar.
     *
     *      The component renders:
     *          .cb-step-indicator (flex row)
     *            .cb-step-indicator__item (circle + label)
     *              .cb-step-indicator__circle
     *              .cb-step-indicator__label
     *            .cb-step-indicator__line  (between items)
     *
     *      We squash the circles to thin segment-fillers, hide the
     *      labels, and stretch the connecting lines so the whole row
     *      reads as a 6px progress bar. Active + done states change
     *      the segment colour. */
    .cb-step-indicator {
        gap: 0;
        padding: 6px 0 4px;
        margin-bottom: 1rem;
        align-items: center;
    }

    .cb-step-indicator__item {
        gap: 0;
        flex: 1 1 auto;
        min-width: 0;
    }

    .cb-step-indicator__circle {
        width: 100%;
        height: 6px;
        min-width: 0;
        max-width: 100%;
        border-radius: 3px;
        background: var(--cb-border, rgba(22, 36, 58, 0.12));
        color: transparent;
        font-size: 0;
        border: 0 !important;
        padding: 0;
        box-sizing: border-box;
        flex: 1 1 auto;
        overflow: hidden;
    }

    /* Hide the checkmark icon text inside circles on mobile — the bar fill
     * communicates progress on its own. */
    .cb-step-indicator__circle > svg,
    .cb-step-indicator__circle > * {
        display: none;
    }

    .cb-step-indicator__item.is-done .cb-step-indicator__circle,
    .cb-step-indicator__item.is-active .cb-step-indicator__circle {
        background: var(--cb-primary, #16243a);
    }

    /* Labels become invisible — the bar shows progress visually, and the
     * "Step N of M" eyebrow above the bar (rendered by StepIndicator.jsx
     * into a sibling .cb-step-indicator__progress-text) gives the
     * explicit count. The active item keeps its label readable for
     * screen readers (sr-only) but visually hidden. */
    .cb-step-indicator__label {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    /* "Step N of M" eyebrow above the segmented bar. Matches the
     * SummaryRail label eyebrow style (uppercase + tracking) so the
     * visual language stays consistent on mobile. The shell wrapper
     * stays `display: contents` (StepIndicator.css default) so the
     * eyebrow + bar lay out as siblings of whatever contains the
     * StepIndicator — no shell-level layout fight. */
    .cb-step-indicator__progress-text {
        display: block;
        font-size: 0.75rem;
        font-weight: 500;
        color: var(--cb-muted, #6b7689);
        text-align: center;
        text-transform: uppercase;
        letter-spacing: 0.06em;
        margin-bottom: 6px;
    }

    /* Connecting line becomes a thin 4px gap between segments so they
     * read as separate progress chunks rather than one solid bar. */
    .cb-step-indicator__line {
        flex: 0 0 4px;
        min-width: 4px;
        height: 6px;
        margin: 0;
        background: transparent;
    }


    /* ── 1c. Booking layout — single column, no rail offset.
     *
     *      Desktop: `cb-booking-layout` is grid 1fr 360px. The mobile
     *      grid is already 1fr (booking.css line 18-23), so we just
     *      need to make sure gap/alignment still work. No-op in most
     *      cases, kept here for clarity. */
    .cb-booking-layout {
        gap: 1rem;
    }


    /* ── 1d. Step card padding — slightly tighter on mobile than the
     *      cosy desktop look. Density already shrinks paddings; we trim
     *      a touch more so the card edges feel hugged by the viewport. */
    .cb-booking-card {
        padding: calc(1.25rem * var(--cb-density, 1));
        border-radius: var(--cb-card-radius, 18px);
        margin-bottom: 1rem;
    }

    .cb-booking-title {
        font-size: 1.5rem;
        line-height: 1.15;
    }

    .cb-step-title {
        /* Already responsive via clamp(); cap on mobile so a long step
         * heading doesn't push the form below the fold. */
        font-size: clamp(1.5rem, 6vw, 1.875rem);
    }

    .cb-booking-subtitle,
    .cb-step-subtitle {
        font-size: 0.875rem;
        margin-bottom: 1rem;
    }


    /* ── 1e. Card grids — collapse to single column.
     *
     *      `cb-booking-grid` is 3-col on desktop, 2-col on tablet
     *      (existing rule at booking.css line 919-925), 1-col below
     *      480px. We promote the 1-col stack up to 768px so all card
     *      types (cruise types, boats, rental offerings) get the
     *      image-on-top stacked layout per MobileWizard1 / 3. */
    .cb-booking-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    /* Card image keeps height across mobile so there's still a strong
     * visual anchor at the top of each card. */
    .cb-card-img,
    .cb-card-img-placeholder {
        height: 180px;
    }

    /* Cruise / boat / offering option cards.
     *
     *  `cb-booking-option--card` already has `padding: 0; overflow: hidden`,
     *  so the image sits flush with the card's top edge. The card body
     *  (.cb-booking-option > div with inline padding) keeps its inline
     *  styles — we just reinforce stacking. */
    .cb-booking-option--card,
    .cb-booking-option {
        width: 100%;
        max-width: 100%;
    }


    /* ── 1f. Form fields — collapse to single column.
     *
     *      Lead-passenger fields use `cb-booking-form-group`, which is
     *      already block-level. The optional-passenger compact grid
     *      `cb-pax-compact-grid` is 3-col on desktop, 2-col below 480px;
     *      promote 1-col up to 768px so DOB + ID don't squash. */
    .cb-pax-compact-grid {
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }

    .cb-booking-form-group {
        max-width: 100%;
    }

    /* Tighten input + label spacing on mobile. */
    .cb-booking-input {
        font-size: 1rem;            /* >=16px — prevents iOS zoom on focus */
        padding: calc(0.7rem * var(--cb-density, 1)) 0.75rem;
    }

    .cb-form-row {
        /* Batch B's 2-col form row primitive collapses to 1-col on mobile.
         * The exact display mode (grid vs flex) varies per usage; we
         * normalise to a single-column block stack regardless. */
        display: flex;
        flex-direction: column;
        gap: 0.85rem;
    }


    /* ── 1g. Payment method cards — stack one-up.
     *
     *      `PaymentMethod` is already `width: 100%`, but if a wrapper
     *      uses a 2-col grid, force 1-col here. The Batch B PaymentStep
     *      typically renders a column of `<PaymentMethod>` directly, so
     *      this is mostly defensive. */
    .cb-payment-methods,
    .cb-payment-method-grid {
        grid-template-columns: 1fr !important;
        gap: 0.5rem;
    }

    .cb-payment-method {
        min-height: 56px;
        padding: 14px 16px;
    }


    /* ── 1h. Sticky Back / Continue nav.
     *
     *      Booking nav already stacks vertically below 480px (existing
     *      rule). Promote the column-reverse + sticky-bottom positioning
     *      to 768px. Sticky-within-step-wrapper keeps the buttons
     *      anchored at the bottom of the form area while it scrolls.
     *
     *      Stacking order on mobile (bottom → top):
     *        1. SummaryRail bottom drawer (z-index 30, position: fixed)
     *        2. Sticky `cb-booking-nav` Continue + Back row (sticky)
     *        3. Form content (normal flow, scrolls)
     *
     *      We use `position: sticky` with `bottom: 96px` so the nav
     *      sits directly above the SummaryRail drawer when scrolled.
     *      Inquiry-mode and screens without a rail have `bottom: 0` via
     *      the :has() override below. */
    .cb-booking-nav {
        position: sticky;
        bottom: calc(96px + env(safe-area-inset-bottom, 0px));
        z-index: 20;
        background: var(--cb-card, #ffffff);
        border-top: 1px solid var(--cb-border, rgba(22, 36, 58, 0.10));
        margin: 1rem calc(-1.25rem * var(--cb-density, 1)) calc(-1.25rem * var(--cb-density, 1));
        padding: 0.75rem calc(1.25rem * var(--cb-density, 1));
        flex-direction: row;
        /* v2.10.1 — allow buttons to wrap to a second row on phones when 3+
           buttons (e.g. RentalExtrasStep: Back / Continue without add-ons /
           Continue) don't fit on a single row. Without flex-wrap the third
           button gets clipped past the viewport's right edge. */
        flex-wrap: wrap;
        gap: 0.5rem;
        box-shadow: 0 -2px 8px rgba(22, 36, 58, 0.06);
    }

    /* The empty spacer div used to push right-side buttons right on desktop
     * is a 0-width flex item; on mobile we want it OUT of the layout so the
     * three real buttons share the available width evenly. */
    .cb-booking-nav .cb-booking-nav__spacer { display: none; }

    /* When there is no SummaryRail rendered (inquiry mode, confirmation
     * screens), the nav sits flush with the viewport bottom. */
    .cb-booking-layout:not(:has(.cb-summary-rail)) .cb-booking-nav {
        bottom: 0;
    }

    .cb-booking-nav .cb-booking-btn,
    .cb-booking-nav .cb-booking-btn-secondary {
        flex: 1 1 auto;
        text-align: center;
        justify-content: center;
        padding: 0.85rem 1rem;
        font-size: 0.95rem;
        min-height: 48px;
    }

    /* If only one button is present (e.g. ConfirmationStep "Done"),
     * let it span the full width. */
    .cb-booking-nav .cb-booking-btn:only-child {
        width: 100%;
    }


    /* ── 1i. SummaryRail → fixed bottom drawer.
     *
     *      Desktop: `display: none` below 1024px (existing rule). At
     *      <=768px we override to a fixed bottom drawer that shows the
     *      condensed Total amount + the customer's reference info.
     *      The Continue CTA inside `.cb-booking-nav` sits *above* this
     *      drawer (see 1h above) — keeping money + action visible at
     *      all times.
     *
     *      We don't show the full row breakdown on mobile to keep the
     *      drawer to ~96px tall. The user has the full detail on the
     *      Confirmation step (where the SummaryRail hides anyway since
     *      that step doesn't render the layout grid). */
    .cb-summary-rail {
        display: block;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 30;
        background: var(--cb-card, #ffffff);
        border-top: 1px solid var(--cb-border, rgba(22, 36, 58, 0.12));
        box-shadow: 0 -4px 16px rgba(22, 36, 58, 0.08);
        padding: 0.6rem 1rem calc(0.6rem + env(safe-area-inset-bottom, 0px));
        margin: 0;
        max-height: 96px;
        overflow: hidden;
        animation: none;
    }

    /* Strip card chrome — the drawer itself is the card now. */
    .cb-summary-rail__card {
        padding: 0;
        background: transparent;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    /* Hide the eyebrow + heading + helper sub-text on mobile — only
     * the Total row matters in the condensed bar. */
    .cb-summary-rail__eyebrow,
    .cb-summary-rail__heading,
    .cb-summary-rail__sub {
        display: none;
    }

    /* Hide non-emphasised summary rows in the drawer; show only the
     * Total. The full breakdown is available on the Confirmation step. */
    .cb-summary-rail__rows {
        display: none;
    }

    /* The Total row's own typography is generous on desktop. On mobile
     * we tighten it so the drawer fits in ~64–80px of vertical space. */
    .cb-summary-rail .cb-summary-row.is-emphasized {
        padding: 4px 0;
        margin: 0;
        border-top: 0;
        font-size: 0.8125rem;
    }

    .cb-summary-rail .cb-summary-row.is-emphasized .cb-summary-row__label {
        font-size: 0.75rem;
        color: var(--cb-muted, #6b7689);
        font-weight: 500;
        text-transform: uppercase;
        letter-spacing: 0.06em;
    }

    .cb-summary-rail .cb-summary-row.is-emphasized .cb-summary-row__value {
        font-size: 1.375rem;
        line-height: 1.1;
        font-weight: 600;
    }


    /* ── 1j. Wizard hero — trim padding on mobile. */
    .cb-wizard-hero {
        min-height: 140px;
        margin-bottom: 1rem;
    }

    .cb-wizard-hero-text {
        padding: 1.5rem 1.25rem;
    }

    .cb-wizard-hero-headline {
        font-size: 1.5rem;
    }

    .cb-wizard-hero-subheadline {
        font-size: 0.9375rem;
    }


    /* ── 1k. Step wrapper animation respects scroll-anchor — without
     *      this, the slide-up animation can fight the sticky CTA on
     *      slow phones. */
    .cb-booking-layout__main .cb-step-wrapper {
        animation-duration: 180ms;
    }
}


/* ─── 2. Phone breakpoint (<= 480px) — finer tuning ────────────────────── */

@media (max-width: 480px) {

    /* Card grid gap tightens further. */
    .cb-booking-grid {
        gap: 0.5rem;
    }

    /* Card image height slightly trimmed at the smallest sizes so the
     * card body (name + price) is visible without scrolling each card. */
    .cb-card-img,
    .cb-card-img-placeholder {
        height: 160px;
    }

    /* Step card hugs the viewport edges. */
    .cb-booking-card {
        padding: calc(1rem * var(--cb-density, 1));
        border-radius: 12px;
    }

    /* Booking nav buttons remain side-by-side at <=480px (vs the
     * existing booking.css default which stacks them vertically).
     * The sticky bar pattern reads better as a horizontal Back ↔
     * Continue, matching MobileWizard's design. The minimal-button
     * width means even narrow phones (320px) still fit both. */
    .cb-booking-nav {
        flex-direction: row;
        gap: 0.4rem;
    }

    .cb-booking-nav .cb-booking-btn,
    .cb-booking-nav .cb-booking-btn-secondary {
        font-size: 0.875rem;
        padding: 0.75rem 0.6rem;
    }

    /* Back button shrinks to a chevron-only width if both are present
     * — the customer's mental model is "go forward" on mobile, so the
     * Continue button gets the wider tap target. */
    .cb-booking-nav .cb-booking-btn-secondary:not(:only-child) {
        flex: 0 0 auto;
        min-width: 80px;
    }
    .cb-booking-nav .cb-booking-btn:not(:only-child):not(.cb-booking-btn-secondary) {
        flex: 1 1 auto;
    }


    /* Stepper gets a wider value column so 2-digit guest counts (10+)
     * don't crowd the +/- buttons. */
    .cb-stepper__value {
        min-width: 56px;
    }


    /* SummaryRail drawer trims further at the smallest sizes. */
    .cb-summary-rail {
        padding: 0.5rem 0.85rem calc(0.5rem + env(safe-area-inset-bottom, 0px));
        max-height: 84px;
    }

    .cb-summary-rail .cb-summary-row.is-emphasized .cb-summary-row__value {
        font-size: 1.25rem;
    }
}


/* ─── 3. Reduced-motion override — stop the step indicator's transitions
 *      from running when the bar is being repainted on each step change. */
@media (max-width: 768px) and (prefers-reduced-motion: reduce) {
    .cb-step-indicator__circle {
        transition: none;
    }
}

/* Phase R — shared design tokens (palette, spacing, type, motion). The wizard's
 * existing operator-customisable colors (build_wizard_css) override the brand
 * tokens on top; this import provides the rest of the scale + sensible defaults. */

/* Phase R — primitive component library. */

/* Phase T Batch C — mobile responsive overrides (<=768px / <=480px). */

.cb-booking-widget {
    max-width: 100%;
    margin: 2rem auto;
    font-family: var(--cb-font-family, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif);
    color: var(--cb-text, #0f172a);
    background: var(--cb-background, #ffffff);
    box-sizing: border-box;
}

.cb-booking-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    align-items: flex-start;
    /* v2.4.8 — operator feedback: breathing room between the ProgressStrip
       and the step content below it. The chip row was visually tight against
       the step card; this margin matches the Claude Design rental-flow gap. */
    margin-top: 1.5rem;
}

@media (min-width: 1024px) {
    .cb-booking-layout {
        grid-template-columns: minmax(0, 1fr) 360px;
        gap: 2rem;
        margin-top: 2rem;
    }
}

.cb-booking-layout__main {
    min-width: 0;
}

.cb-booking-widget *,
.cb-booking-widget *::before,
.cb-booking-widget *::after {
    box-sizing: inherit;
}

/* ── Blocks below the wizard (Phase 2) ────────────────────────────────────── */

.cb-wizard-blocks {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}
.cb-block {
    background: var(--cb-card, #f8fafc);
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1.5rem;
}
.cb-block-heading {
    margin: 0 0 1rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--cb-text, #0f172a);
    text-align: center;
}

/* Testimonials */
.cb-testi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1rem;
}
.cb-testi-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.cb-testi-stars {
    font-size: 0.95rem;
    letter-spacing: 0.1em;
    color: #cbd5e1;
}
.cb-testi-stars .filled {
    color: #f59e0b;
}
.cb-testi-body {
    margin: 0;
    font-size: 0.9rem;
    color: var(--cb-text, #0f172a);
    line-height: 1.5;
    font-style: italic;
}
.cb-testi-author {
    margin-top: 0.25rem;
    font-size: 0.82rem;
    color: var(--cb-muted, #64748b);
}
.cb-testi-location {
    font-weight: normal;
}

/* FAQ */
.cb-faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.cb-faq-item {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    overflow: hidden;
}
.cb-faq-question {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 0.85rem 1rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--cb-text, #0f172a);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}
.cb-faq-question:hover {
    background: var(--cb-primary-light, rgba(14, 165, 233, 0.06));
}
.cb-faq-chevron {
    color: var(--cb-primary, #0ea5e9);
    font-size: 1.1rem;
    font-weight: 700;
    flex-shrink: 0;
}
.cb-faq-answer {
    padding: 0 1rem 1rem;
    color: var(--cb-muted, #475569);
    font-size: 0.9rem;
    line-height: 1.55;
}
.cb-faq-answer p {
    margin: 0 0 0.5rem;
}
.cb-faq-answer p:last-child {
    margin-bottom: 0;
}

/* Trust badges */
.cb-trust-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.75rem;
}
.cb-trust-badge {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 0.75rem 0.9rem;
}
.cb-trust-icon {
    font-size: 1.4rem;
    line-height: 1;
    flex-shrink: 0;
}
.cb-trust-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--cb-text, #0f172a);
}

/* ── Step fade-in transition (Phase 3) ────────────────────────────────────── */

.cb-step-wrapper {
    animation: cb-step-fade 240ms ease-out;
}
@keyframes cb-step-fade {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
    .cb-step-wrapper { animation: none; }
}

/* ── G3 (v2.4.1) — Rental mode toggle as a segmented control (P-2) ────────
 *
 * Per ROADMAP §16.4 G3 + the B3 punch list row P-2: "Move into card header
 * with explicit segmented-control styling". The class was rendered without
 * any CSS rule; this block lifts it from "three loose buttons" to a single
 * bordered segmented-control surface with a clearly-selected state.
 *
 * Token-driven (`--bu-*` references) so the Harbor / Helm direction switch
 * restyles automatically. Falls back to literal hex values for non-wizard
 * contexts where tokens.css isn't loaded. */

.cb-rental-mode-toggle {
    display: inline-flex;
    align-items: stretch;
    gap: 0;
    margin: 0 0 1.25rem 0;
    padding: 4px;
    background: var( --bu-bg-sunk, #f0ebe1 );
    border: 1px solid var( --bu-line, rgba( 22, 36, 58, 0.10 ) );
    border-radius: var( --bu-radius, 14px );
}

.cb-rental-mode-toggle__btn {
    -webkit-appearance: none;
       -moz-appearance: none;
            appearance: none;
    border: 0;
    background: transparent;
    font-family: inherit;
    font-size: var( --bu-fs-sm, 13px );
    font-weight: 500;
    color: var( --bu-ink-3, #6b7689 );
    padding: 8px 16px;
    border-radius: calc( var( --bu-radius, 14px ) - 6px );
    cursor: pointer;
    transition: background .15s, color .15s, box-shadow .15s;
    white-space: nowrap;
}
.cb-rental-mode-toggle__btn:hover {
    color: var( --bu-ink, var( --bu-ink-1, #16243a ) );
}
.cb-rental-mode-toggle__btn.is-selected {
    background: var( --bu-bg-elev, #ffffff );
    color: var( --bu-ink, var( --bu-ink-1, #16243a ) );
    box-shadow: var( --bu-shadow-1, 0 1px 2px rgba( 22, 36, 58, .06 ), 0 0 0 1px rgba( 22, 36, 58, .04 ) );
}
.cb-rental-mode-toggle__btn:focus-visible {
    outline: 2px solid var( --bu-primary, #16243a );
    outline-offset: 2px;
}

/* Mobile (≤640): keep the inline-flex shape but allow the segmented control
 * to fill the row when the parent step card is narrow. */
@media ( max-width: 640px ) {
    .cb-rental-mode-toggle {
        display: flex;
        width: 100%;
    }
    .cb-rental-mode-toggle__btn {
        flex: 1 1 0;
        text-align: center;
    }
}

/* ── Autosave "Continue?" banner (Phase 3) ────────────────────────────────── */

.cb-autosave-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.9rem 1.1rem;
    margin-bottom: 1rem;
    border-radius: 0.5rem;
    background: var(--cb-primary-light, rgba(14, 165, 233, 0.08));
    border: 1px solid var(--cb-primary, #0ea5e9);
    color: var(--cb-text, #0f172a);
    flex-wrap: wrap;
}
.cb-autosave-text {
    font-size: 0.9rem;
    font-weight: 500;
    flex: 1 1 240px;
}
.cb-autosave-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}
.cb-autosave-actions .cb-booking-btn {
    padding: 0.45rem 0.9rem;
    font-size: 0.85rem;
}

/* Hero banner */
.cb-wizard-hero {
    position: relative;
    margin-bottom: 1.5rem;
    border-radius: 0.75rem;
    overflow: hidden;
    min-height: 180px;
    background: linear-gradient(135deg, var(--cb-primary, #0ea5e9), var(--cb-primary-dark, #0284c7));
}
.cb-wizard-hero-image {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    z-index: 0;
}
.cb-wizard-hero-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom right, rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.55));
}
.cb-wizard-hero-text {
    position: relative;
    z-index: 1;
    padding: 2.5rem 1.75rem;
    color: #fff;
    text-align: center;
}
.cb-wizard-hero-headline {
    font-size: 1.875rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    line-height: 1.2;
}
.cb-wizard-hero-subheadline {
    font-size: 1rem;
    margin: 0;
    opacity: 0.95;
}

.cb-wizard-hero-trust {
    margin-top: 0.875rem;
    display: flex;
    justify-content: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}
.cb-wizard-hero-trust__item {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.92);
    letter-spacing: 0.02em;
}
.cb-wizard-hero-trust__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var( --cb-success, #16a34a );
    flex-shrink: 0;
}

.cb-booking-card {
    background: var(--cb-card, #ffffff);
    border: 1px solid var(--cb-border, #e2e8f0);
    border-radius: var(--cb-card-radius, 0.75rem);
    padding: calc(2rem * var(--cb-density, 1));
    margin-bottom: 1.5rem;
    box-sizing: border-box;
    box-shadow: 0 1px 2px rgba(22, 36, 58, 0.04), 0 1px 3px rgba(22, 36, 58, 0.06);
}

.cb-booking-title {
    font-family: var(--cb-display-font, var(--cb-font-family, system-ui), serif);
    font-size: 1.875rem;
    font-weight: 600;
    line-height: 1.05;
    letter-spacing: -0.02em;
    color: var(--cb-text, #16243a);
    margin: 0 0 0.5rem;
}

.cb-booking-subtitle {
    color: var(--cb-muted, #6b7689);
    margin: 0 0 1.5rem;
    font-size: 0.95rem;
}

.cb-booking-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    align-items: start;
}

.cb-booking-option {
    border: 1px solid var(--cb-border, #e2e8f0);
    border-radius: var(--cb-card-radius, 0.5rem);
    padding: 1.25rem;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
    background: var(--cb-card, #fff);
    color: inherit;
    text-align: left;
    width: 100%;
    box-shadow: 0 1px 2px rgba(22, 36, 58, 0.04), 0 1px 3px rgba(22, 36, 58, 0.06);
}

.cb-booking-option:hover {
    border-color: var(--cb-primary, #0ea5e9);
    box-shadow: 0 2px 6px rgba(22, 36, 58, 0.06), 0 8px 24px rgba(22, 36, 58, 0.08);
}

.cb-booking-option.selected {
    border: 2px solid var(--cb-primary, #0ea5e9);
    /* G6 P-11 (v2.4.5) — bumped from rgba(...,0.06) to 0.12 so the selected
     * Full / Deposit card promotes its primary-tinted background more
     * visibly. Per the B3 punch list: "Promote selected card with
     * primary-tinted background, not just border". */
    background: rgba(var(--cb-primary-rgb, 14, 165, 233), 0.12);
    padding: calc(1.25rem - 1px);
    box-shadow: 0 2px 6px rgba(22, 36, 58, 0.06), 0 8px 24px rgba(22, 36, 58, 0.08);
}

.cb-booking-option h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.125rem;
    color: #1e293b;
    line-height: 1.3;
}

.cb-booking-option p {
    font-size: 0.8rem;
    color: #64748b;
    margin: 0;
    line-height: 1.35;
}

.cb-booking-option--card {
    padding: 0;
    position: relative;
    overflow: hidden;
}

.cb-booking-option--card.selected {
    padding: 0;
}

.cb-booking-btn {
    background: var(--cb-btn-bg, var(--cb-primary, #0ea5e9));
    color: var(--cb-btn-fg, #fff);
    border: 1px solid var(--cb-btn-border, transparent);
    border-radius: var(--cb-btn-radius, 0.5rem);
    padding: calc(0.75rem * var(--cb-density, 1)) calc(1.5rem * var(--cb-density, 1));
    font-size: 0.9375rem;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s, transform 0.12s, box-shadow 0.15s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    white-space: nowrap;
}

.cb-booking-btn:hover:not(:disabled) {
    background: var(--cb-primary-dark, #0284c7);
    transform: translateY(-1px);
}

.cb-booking-btn:active:not(:disabled) {
    transform: translateY(0);
}

.cb-booking-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.cb-booking-btn-secondary {
    background: transparent;
    color: var(--cb-text, #16243a);
    border: 1px solid var(--cb-border, #e2e8f0);
}

.cb-booking-btn-secondary:hover:not(:disabled) {
    background: var(--cb-surface-2, #f8fafc);
}

.cb-booking-btn-sm {
    padding: calc(0.4rem * var(--cb-density, 1)) calc(0.85rem * var(--cb-density, 1));
    font-size: 0.8125rem;
}

.cb-booking-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
    gap: 1rem;
}

.cb-booking-input {
    width: 100%;
    padding: calc(0.7rem * var(--cb-density, 1)) 0.85rem;
    background: var(--cb-card, #fff);
    border: 1px solid var(--cb-border, #e2e8f0);
    color: var(--cb-text, #16243a);
    border-radius: var(--cb-btn-radius, 0.5rem);
    font-family: inherit;
    font-size: 0.95rem;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.cb-booking-input:focus {
    border-color: var(--cb-primary, #0ea5e9);
    box-shadow: 0 0 0 3px rgba(var(--cb-primary-rgb, 14, 165, 233), 0.15);
}

.cb-booking-label {
    display: block;
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--cb-muted, #6b7689);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.4rem;
}

.cb-booking-form-group {
    margin-bottom: 1rem;
    max-width: 480px;
}

.cb-booking-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    color: #dc2626;
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.cb-booking-price-box {
    background: var(--cb-surface-2, #f0f9ff);
    border: 1px solid var(--cb-border, #bae6fd);
    border-radius: var(--cb-btn-radius, 0.5rem);
    padding: 1rem;
    margin-bottom: 1rem;
}

/* Logo header */
.cb-booking-logo {
    text-align: center;
    margin-bottom: 1.25rem;
}

.cb-booking-logo img {
    max-height: 64px;
    width: auto;
    display: inline-block;
}

/* Step indicator v2 */
.cb-booking-steps {
    display: flex;
    align-items: flex-start;
    overflow-x: auto;
    overflow-y: hidden;
    margin-bottom: 1.5rem;
    gap: 0;
}

.cb-step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.cb-step-circle {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    background: #d1d5db;
    color: #6b7280;
    flex-shrink: 0;
}

.cb-step-circle.active {
    background: var(--cb-primary, #0ea5e9);
    color: white;
}

.cb-step-circle.done {
    background: #22c55e;
    color: white;
}

.cb-step-label {
    font-size: 0.625rem;
    margin-top: 4px;
    text-align: center;
    max-width: 56px;
    color: #6b7280;
    white-space: nowrap;
}

.cb-step-label.active {
    color: var(--cb-primary, #0ea5e9);
    font-weight: 600;
}

.cb-step-connector {
    flex: 1;
    height: 2px;
    background: #d1d5db;
    margin-top: 14px;
    min-width: 12px;
}

.cb-step-connector.done {
    background: #22c55e;
}

@media (max-width: 480px) {
    .cb-step-circle {
        width: 22px;
        height: 22px;
        font-size: 0.65rem;
    }
    .cb-step-label {
        display: none;
    }
    .cb-step-connector {
        margin-top: 11px;
    }
}

/* Rich card content — Tasks 18 + 19 */
.cb-card-img {
    width: 100%;
    height: 180px;
    -o-object-fit: cover;
       object-fit: cover;
    border-radius: 0.375rem 0.375rem 0 0;
    display: block;
}

.cb-card-img-placeholder {
    width: 100%;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e0f2fe 0%, #f0f9ff 50%, #e0f2fe 100%);
    border-radius: 0.375rem 0.375rem 0 0;
    color: #94a3b8;
    font-size: 2.5rem;
}

.cb-gallery-placeholder {
    width: 50px;
    height: 50px;
    border-radius: 4px;
    flex-shrink: 0;
    background: linear-gradient(135deg, #e2e8f0, #f1f5f9);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #cbd5e1;
    font-size: 1rem;
}

.cb-gallery-strip {
    display: flex;
    gap: 4px;
    padding: 6px 10px 0;
    overflow: hidden;
}

.cb-gallery-strip img {
    width: 50px;
    height: 50px;
    -o-object-fit: cover;
       object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
}

.cb-duration-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--cb-primary, #0ea5e9);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 999px;
    pointer-events: none;
}

.cb-card-desc {
    font-size: 0.8rem;
    color: #64748b;
    margin: 0.125rem 0 0.25rem;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    white-space: pre-line; /* v2.43.6 — honour \n in legacy plain-text descriptions */
}
/* v2.43.6 fix — block elements override pre-line so source whitespace
   between tags doesn't pad the truncated preview. */
.cb-card-desc ul,
.cb-card-desc ol,
.cb-card-desc li,
.cb-card-desc p,
.cb-card-desc h1,
.cb-card-desc h2,
.cb-card-desc h3,
.cb-card-desc h4,
.cb-card-desc h5,
.cb-card-desc h6,
.cb-card-desc blockquote {
    white-space: normal;
}
.cb-card-desc li > p {
    margin: 0;
    display: inline;
}

/* v2.43.6 — Reset rich-text formatting inside the truncated preview so an
   <h3> doesn't blow up the card height and bullets don't double-indent.
   Description full formatting still renders correctly in the detail modal. */
.cb-card-desc h1,
.cb-card-desc h2,
.cb-card-desc h3,
.cb-card-desc h4,
.cb-card-desc h5,
.cb-card-desc h6 {
    font-size: inherit;
    font-weight: 600;
    margin: 0;
    display: inline;
}
.cb-card-desc p {
    margin: 0;
    display: inline;
}
.cb-card-desc ul,
.cb-card-desc ol {
    margin: 0;
    padding-left: 1rem;
}
.cb-card-desc blockquote {
    margin: 0;
    padding-left: 0.5rem;
    border-left: 2px solid #cbd5e1;
}

/* v2.43.6 — Whole-card clickable info area on the cruise type card.
   Image + description + chips all open the detail modal; SELECT button
   below stays separate and stops propagation. */
.cb-card-clickable {
    cursor: pointer;
    border-radius: 6px;
    transition: background-color 120ms ease;
}
.cb-card-clickable:hover {
    background: rgba(15, 23, 42, 0.025);
}
.cb-card-clickable:focus-visible {
    outline: 2px solid var(--cb-accent, #0369a1);
    outline-offset: 2px;
}

.cb-feature-chip {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    background: #e0f2fe;
    color: #0369a1;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 500;
    margin: 2px 2px 2px 0;
}

.cb-meeting-point {
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 0.25rem;
    line-height: 1.3;
}

.cb-meeting-point a {
    color: var(--cb-primary, #0ea5e9);
    text-decoration: none;
    margin-left: 4px;
}

.cb-specs-row {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 0.25rem;
}

.cb-spec-chip {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 8px;
    background: #f1f5f9;
    border-radius: 999px;
    font-size: 0.7rem;
    color: #475569;
}

.cb-spec-val {
    font-weight: 500;
}

/* Detail Modal — Task 4.1 */
.cb-detail-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.cb-detail-modal {
    background: #fff;
    border-radius: 0.75rem;
    max-width: 640px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.cb-detail-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: background 0.15s;
}

.cb-detail-close:hover {
    background: rgba(0, 0, 0, 0.7);
}

.cb-detail-gallery {
    position: relative;
}

.cb-detail-main-img {
    width: 100%;
    aspect-ratio: 16 / 9;
    -o-object-fit: cover;
       object-fit: cover;
    border-radius: 0.75rem 0.75rem 0 0;
    display: block;
}

.cb-detail-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.9);
    color: #1e293b;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}

.cb-detail-nav:hover {
    background: #fff;
}

.cb-detail-nav--prev { left: 8px; }
.cb-detail-nav--next { right: 8px; }

.cb-detail-thumbs {
    display: flex;
    gap: 6px;
    padding: 8px 12px;
    overflow-x: auto;
    overflow-y: hidden;
}

.cb-detail-thumb {
    width: 56px;
    height: 56px;
    -o-object-fit: cover;
       object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    border: 2px solid transparent;
    opacity: 0.6;
    transition: opacity 0.15s, border-color 0.15s;
    flex-shrink: 0;
}

.cb-detail-thumb:hover {
    opacity: 0.9;
}

.cb-detail-thumb.active {
    border-color: var(--cb-primary, #0ea5e9);
    opacity: 1;
}

.cb-detail-content {
    padding: 1.25rem 1.5rem 1.5rem;
}

.cb-detail-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 0.5rem;
}

.cb-detail-badge {
    display: inline-block;
    background: var(--cb-primary, #0ea5e9);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 10px;
    border-radius: 999px;
    margin-bottom: 0.75rem;
}

.cb-detail-desc {
    font-size: 0.9rem;
    color: #475569;
    margin: 0 0 1rem;
    line-height: 1.6;
    white-space: pre-line; /* v2.43.6 — honour \n in legacy plain-text descriptions */
}

/* v2.43.6 fix — block elements override the parent's pre-line so source-code
   newlines between <li> / <p> tags don't render as visible blank space.
   pre-line still applies to direct text children (legacy plain-text content). */
.cb-detail-desc ul,
.cb-detail-desc ol,
.cb-detail-desc li,
.cb-detail-desc p,
.cb-detail-desc h1,
.cb-detail-desc h2,
.cb-detail-desc h3,
.cb-detail-desc h4,
.cb-detail-desc h5,
.cb-detail-desc h6,
.cb-detail-desc blockquote {
    white-space: normal;
}
/* TipTap wraps <li> contents in <p>; collapse the inner paragraph margin
   so bullets don't get ~1rem of dead space per item. */
.cb-detail-desc li > p {
    margin: 0;
}

/* v2.43.6 — Detail modal renders full rich-text. Compact spacing rules
   tuned for mobile: section headings hug their following content, gaps
   between sections are just enough air to read as distinct. */
.cb-detail-desc h1,
.cb-detail-desc h2 {
    font-size: 1.05rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0.4rem 0 0.05rem;
}
.cb-detail-desc h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0.3rem 0 0.05rem;
}
.cb-detail-desc h4 {
    font-size: 0.95rem;
    font-weight: 600;
    color: #334155;
    margin: 0.25rem 0 0.05rem;
}
.cb-detail-desc p {
    margin: 0.15rem 0;
}
.cb-detail-desc ul,
.cb-detail-desc ol {
    margin: 0.15rem 0;
    padding-left: 1.5rem;
}
.cb-detail-desc li {
    margin: 0;
}
.cb-detail-desc strong,
.cb-detail-desc b {
    font-weight: 600;
    color: #1e293b;
}
.cb-detail-desc em,
.cb-detail-desc i {
    font-style: italic;
}
.cb-detail-desc blockquote {
    margin: 0.4rem 0;
    padding-left: 0.75rem;
    border-left: 3px solid #cbd5e1;
    color: #64748b;
}
.cb-detail-desc a {
    color: var(--cb-accent, #0369a1);
    text-decoration: underline;
}
.cb-detail-desc hr {
    margin: 1rem 0;
    border: none;
    border-top: 1px solid #e2e8f0;
}
.cb-detail-desc code {
    background: #f1f5f9;
    padding: 0.1rem 0.35rem;
    border-radius: 4px;
    font-size: 0.85em;
}

.cb-detail-section {
    margin-bottom: 1rem;
}

.cb-detail-section-title {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
    margin: 0 0 0.5rem;
}

.cb-detail-specs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.cb-detail-spec {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px 12px;
}

.cb-detail-spec-label {
    display: block;
    font-size: 0.7rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.cb-detail-spec-val {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #1e293b;
}

.cb-view-details {
    display: inline-block;
    font-size: 0.75rem;
    color: var(--cb-primary, #0ea5e9);
    cursor: pointer;
    margin-top: 0.25rem;
    background: none;
    border: none;
    padding: 0;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.cb-view-details:hover {
    color: var(--cb-primary-dark, #0284c7);
}

/* v2.23.0 — paired action row at the bottom of cruise-type / boat /
 * rental-offering cards. "View Details" + "Select" sit side-by-side; the
 * Select CTA is the primary path now that the card is no longer the
 * click target. */
.cb-card-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-top: 0.5rem;
}
.cb-card-actions .cb-view-details {
    margin-top: 0;
}
.cb-card-actions .cb-booking-btn-sm {
    flex-shrink: 0;
}

@media (max-width: 480px) {
    .cb-detail-modal {
        max-height: 100vh;
        border-radius: 0;
    }
    .cb-detail-main-img {
        aspect-ratio: 16 / 9;
        border-radius: 0;
    }
    .cb-detail-specs {
        grid-template-columns: 1fr;
    }
}

/* Cancel booking button — Task 21 */
.cb-booking-btn-cancel {
    background: white;
    color: #dc2626;
    border: 1px solid #fca5a5;
    border-radius: 0.5rem;
    padding: 0.5rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s;
}

.cb-booking-btn-cancel:hover:not(:disabled) {
    background: #fef2f2;
}

.cb-booking-btn-cancel:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ── Responsive text & tables (all breakpoints) ───────────────────────────── */
.cb-booking-card p,
.cb-booking-card .cb-booking-subtitle {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.cb-booking-price-box table {
    word-break: break-word;
}

.cb-booking-price-box table td {
    vertical-align: top;
}

/* ── Mobile Responsive ────────────────────────────────────────────────────── */

/* Tablet: 768px */
@media (max-width: 768px) {
    .cb-booking-widget {
        max-width: 100%;
        margin: 1rem auto;
    }
    .cb-booking-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile: 480px */
@media (max-width: 480px) {
    .cb-booking-widget {
        margin: 0.5rem auto;
        overflow-x: hidden;
    }
    .cb-booking-card {
        padding: 1.25rem;
        border-radius: 0.5rem;
        margin-bottom: 1rem;
    }
    .cb-booking-title {
        font-size: 1.25rem;
    }
    .cb-booking-subtitle {
        font-size: 0.8rem;
        margin-bottom: 1rem;
    }
    .cb-booking-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    .cb-card-img {
        height: 150px;
    }
    /* Phase T Batch C: .cb-booking-nav layout is owned by wizard-mobile.css
       (sticky bottom CTA, row direction). Old column-reverse rule removed. */
    .cb-booking-btn {
        padding: 0.75rem 1rem;
        font-size: 0.95rem;
    }
    .cb-booking-price-box {
        padding: 0.75rem;
        font-size: 0.85rem;
    }
    .cb-booking-price-box table {
        font-size: 0.8rem;
    }
    .cb-booking-price-box table td:first-child {
        white-space: nowrap;
        padding-right: 0.5rem;
    }
    .cb-booking-logo img {
        max-height: 48px;
    }
    .cb-gallery-strip img {
        width: 40px;
        height: 40px;
    }
    .cb-booking-form-group {
        max-width: 100%;
    }
    .cb-booking-error {
        font-size: 0.8rem;
        padding: 0.625rem 0.75rem;
    }
    .cb-booking-label {
        font-size: 0.8rem;
    }
    .cb-booking-input {
        font-size: 0.9rem;
        padding: 0.5rem 0.625rem;
    }
}

/* ── Custom Select — base styles (needed because booking is a separate bundle) ── */
.cb-custom-select {
    position: relative;
    display: inline-block;
    width: 100%;
}
.cb-cs-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    line-height: 1.25rem;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 0.375rem;
    cursor: pointer;
    color: #1e293b;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.cb-cs-trigger:hover { border-color: #94a3b8; }
.cb-cs-trigger:focus { outline: none; border-color: var(--cb-primary, #0ea5e9); box-shadow: 0 0 0 2px rgba(var(--cb-primary-rgb, 14, 165, 233), .25); }
.cb-cs-trigger:disabled { opacity: .5; cursor: not-allowed; }
.cb-cs-placeholder { color: #64748b; }
.cb-cs-chevron {
    width: 1rem; height: 1rem; flex-shrink: 0; margin-left: 0.5rem;
    transition: transform 0.2s;
}
.cb-custom-select.open .cb-cs-chevron { transform: rotate(180deg); }
.cb-cs-dropdown {
    position: absolute; left: 0; right: 0; top: 100%; margin-top: 4px;
    background: #fff; border: 1px solid #e2e8f0; border-radius: 0.375rem;
    box-shadow: 0 4px 16px rgba(0,0,0,.1); z-index: 9999;
}
.cb-cs-search-wrap { padding: 0.5rem; border-bottom: 1px solid #e2e8f0; }
.cb-cs-search {
    width: 100%; padding: 0.375rem 0.5rem; font-size: 0.8125rem;
    border: 1px solid #e2e8f0; border-radius: 0.25rem; outline: none;
}
.cb-cs-search:focus { border-color: var(--cb-primary, #0ea5e9); box-shadow: 0 0 0 2px rgba(var(--cb-primary-rgb, 14, 165, 233), .2); }
.cb-cs-options {
    list-style: none; margin: 0; padding: 4px 0;
    max-height: 220px; overflow-y: auto;
}
.cb-cs-option {
    display: flex; align-items: center; justify-content: space-between;
    padding: 0.4rem 0.75rem; font-size: 0.8125rem; cursor: pointer;
    color: #1e293b; transition: background 0.1s;
}
.cb-cs-option:hover, .cb-cs-option.highlighted { background: #f1f5f9; }
.cb-cs-option.selected { font-weight: 600; color: var(--cb-primary, #0ea5e9); }
.cb-cs-check { width: 1rem; height: 1rem; color: var(--cb-primary, #0ea5e9); flex-shrink: 0; }
.cb-cs-empty { padding: 0.75rem; text-align: center; font-size: 0.8125rem; color: #64748b; }

/* ── Custom Select (booking variant overrides) ────────────────────────── */
.cb-custom-select.booking .cb-cs-trigger {
    padding: 0.625rem 0.75rem;
    font-size: 0.95rem;
    border-radius: 0.5rem;
    border-color: #e2e8f0;
}
.cb-custom-select.booking .cb-cs-trigger:focus {
    border-color: var(--cb-primary, #0ea5e9);
    box-shadow: 0 0 0 3px rgba(14,165,233,.1);
}
.cb-custom-select.booking .cb-cs-dropdown {
    border-radius: 0.5rem;
}
.cb-custom-select.booking .cb-cs-search:focus {
    border-color: var(--cb-primary, #0ea5e9);
    box-shadow: 0 0 0 2px rgba(14,165,233,.15);
}
.cb-custom-select.booking .cb-cs-option.selected {
    color: var(--cb-primary, #0ea5e9);
}
.cb-custom-select.booking .cb-cs-check {
    color: var(--cb-primary, #0ea5e9);
}

/* ── react-datepicker booking variant ───────────────────────────────────── */
.react-datepicker-wrapper {
  display: block !important;
  width: 100% !important;
}
.react-datepicker__input-container {
  width: 100%;
}

/* ── Passenger cards ─────────────────────────────────────────────────────── */
.cb-pax-compact {
  padding: 0.6rem 0.85rem;
  background: var(--cb-surface-2, #f9fafb);
  border: 1px solid var(--cb-border, #e5e7eb);
  border-radius: var(--cb-btn-radius, 8px);
}

.cb-pax-optional-badge {
  display: inline-block;
  background: var(--cb-border, #e5e7eb);
  color: var(--cb-muted, #6b7280);
  font-size: 0.7rem;
  font-weight: 400;
  border-radius: 999px;
  padding: 1px 7px;
  margin-left: 6px;
  vertical-align: middle;
}

.cb-pax-compact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

@media (max-width: 480px) {
  .cb-pax-compact-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* ── Step headline typography (Phase S Task 13) ───────────────────────────── */
/* References theme tokens so preset mode swaps in Fraunces / Cormorant / etc. */

.cb-step-title {
    font-family: var( --cb-display-font, var( --cb-font-family, system-ui ), serif );
    font-size: clamp( 1.75rem, 3vw, 2.75rem );
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.01em;
    color: var( --cb-text, #0f172a );
    margin: 0 0 0.5rem;
}

.cb-step-subtitle {
    font-family: var( --cb-font-family, system-ui );
    font-size: 1rem;
    color: var( --cb-muted, #6b7280 );
    margin: 0 0 1.5rem;
    max-width: 50ch;
}

/* ── TypeChooser handoff design (Phase 1.0a) ─────────────────────────────── */

.cb-type-chooser-eyebrow {
    font-size: 0.6875rem;          /* 11px to match handoff */
    color: var( --cb-muted, #6b7280 );
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin: 0 0 0.375rem;
    font-weight: 500;
}

.cb-type-card-placeholder {
    height: 90px;
    margin-bottom: 0.75rem;
    background: var( --cb-background, #f1f5f9 );
    border: 1px dashed var( --cb-border, #cbd5e1 );
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6875rem;
    letter-spacing: 0.15em;
    color: var( --cb-muted, #94a3b8 );
    font-weight: 600;
}

/* v2.20.12 — operator-uploaded banner image inside each TypeChooserStep
 * card (replaces the .cb-type-card-placeholder zone when set). Matches the
 * placeholder's 90px desktop height for visual rhythm; bumps to 130px on
 * narrow viewports (≤640px) where the card spans the full width and a
 * taller banner reads better. `object-fit: cover` keeps the operator's
 * image full-bleed regardless of source aspect ratio. */
.cb-type-card-banner {
    display: block;
    width: 100%;
    height: 90px;
    -o-object-fit: cover;
       object-fit: cover;
    border-radius: 8px;
    margin-bottom: 0.75rem;
}

@media (max-width: 640px) {
    .cb-type-card-banner {
        height: 130px;
    }
}

.cb-type-chooser-reassurance {
    margin-top: 1.25rem;
    padding: 0.875rem 1rem;
    background: var( --cb-card, #f8fafc );
    border-radius: var( --cb-radius-lg, 0.5rem );
    display: flex;
    gap: 0.625rem;
    align-items: center;
    font-size: 0.8125rem;
    color: var( --cb-text, #0f172a );
}

.cb-type-chooser-reassurance__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var( --cb-success, #16a34a );
    flex-shrink: 0;
}

/* ── TypeChooser Phase 1.0b: featured tag + price hint ───────────────────── */

.cb-type-card-tag {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 0.125rem 0.5rem;
    background: var( --cb-primary, #0ea5e9 );
    color: #fff;
    border-radius: 999px;
    font-size: 0.625rem;          /* 10px to match handoff bu-chip */
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    line-height: 1.4;
}

.cb-type-card-price {
    margin-top: 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var( --cb-primary, #0ea5e9 );
}

/* ── G4 (v2.4.3) — RentalBoatOffering image-forward card layout
 *
 * Per ROADMAP §16.4 (B3) G4 + the B3 punch list rows P-4 + P-5 + L3:
 *   L3 — image-forward boat cards (160px hero photo on top, body + price below)
 *   P-4 — sold-out boats stay visible at 55% opacity with a "Sold out" pill
 *         (was: shown but nondescript-disabled with placeholder text)
 *   P-5 — license-required warning banner uses the subtler bu-warn-soft tint
 *
 * `.cb-rental-offering` and `.cb-rental-warning` had NO existing CSS rule
 * (same gap pattern as the v2.4.1 G3 mode-toggle); this block fills it.
 *
 * Token-driven (--bu-*) so Harbor / Helm direction restyles automatically;
 * literal-hex fallbacks cover non-wizard contexts. */

.cb-rental-offering-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin: 1.25rem 0;
}
@media ( min-width: 640px ) {
    .cb-rental-offering-list {
        grid-template-columns: repeat( auto-fill, minmax( 280px, 1fr ) );
    }
}

.cb-rental-offering {
    -webkit-appearance: none;
       -moz-appearance: none;
            appearance: none;
    border: 1px solid var( --bu-line, rgba( 22, 36, 58, 0.10 ) );
    background: var( --bu-bg-elev, #ffffff );
    border-radius: var( --bu-radius, 14px );
    padding: 0;
    overflow: hidden;
    cursor: pointer;
    text-align: left;
    display: flex;
    flex-direction: column;
    transition: border-color .15s, box-shadow .15s, transform .15s, opacity .15s;
    font-family: inherit;
}
.cb-rental-offering:hover:not( [disabled] ) {
    border-color: var( --bu-primary, #16243a );
    box-shadow: var( --bu-shadow-2, 0 2px 6px rgba( 22, 36, 58, .06 ), 0 8px 24px rgba( 22, 36, 58, .08 ) );
    transform: translateY( -2px );
}
.cb-rental-offering.is-selected {
    border-color: var( --bu-primary, #16243a );
    box-shadow: 0 0 0 3px color-mix( in oklab, var( --bu-primary, #16243a ) 18%, transparent );
}
.cb-rental-offering[ disabled ] {
    cursor: not-allowed;
    /* P-4 — sold-out boats stay visible at 55% opacity (was: hidden behind a
     * disabled state with no clear "why"). The Sold-out pill carries the
     * unambiguous status. */
    opacity: 0.55;
}
.cb-rental-offering:focus-visible {
    outline: 2px solid var( --bu-primary, #16243a );
    outline-offset: 2px;
}

/* L3 hero image — 160px on top of the card */
.cb-rental-offering__img {
    width: 100%;
    height: 160px;
    -o-object-fit: cover;
       object-fit: cover;
    display: block;
    background: var( --bu-bg-sunk, #f0ebe1 );
}
.cb-rental-offering__img--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var( --bu-ink-4, #9ba3b3 );
}

.cb-rental-offering__body {
    padding: 1rem 1.25rem 0.75rem;
    flex: 1 1 auto;
}
.cb-rental-offering__title {
    font-family: var( --bu-font-display, var( --bu-display, 'Fraunces', serif ) );
    font-size: var( --bu-fs-lg, 17px );
    font-weight: 600;
    color: var( --bu-ink, var( --bu-ink-1, #16243a ) );
    margin: 0 0 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    line-height: 1.2;
}

/* License-required chip on boat name (P-5 — "yellow tag, OK") */
.cb-rental-offering__chip {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: var( --bu-radius-pill, 999px );
    font-family: var( --bu-font-body, inherit );
    font-size: var( --bu-fs-xs, 11px );
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    background: var( --bu-warn-soft, #f4e6c5 );
    color: var( --bu-warn, #b87a14 );
    white-space: nowrap;
}

/* P-4 — Sold-out pill (replaces the older "Not available…" text block) */
.cb-rental-offering__sold-out-pill {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    margin-top: 0.5rem;
    border-radius: var( --bu-radius-pill, 999px );
    font-size: var( --bu-fs-xs, 11px );
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    background: var( --bu-danger-soft, #f1d9d4 );
    color: var( --bu-danger, #a52a2a );
}

.cb-rental-offering__meta {
    color: var( --bu-ink-3, #6b7689 );
    font-size: var( --bu-fs-sm, 13px );
    line-height: 1.4;
}
.cb-rental-offering__desc {
    color: var( --bu-ink-3, #6b7689 );
}
/* v2.19.1 — capacity notice. Renders just under the title, above the meta
 * line, in the secondary ink color so it sits between the boat name and the
 * offering description without competing with either. */
.cb-rental-offering__capacity {
    color: var( --bu-ink-2, #3d4a60 );
    font-size: var( --bu-fs-sm, 13px );
    font-weight: 500;
    line-height: 1.4;
    margin: -0.25rem 0 0.4rem;
}
.cb-rental-offering__notice {
    margin-top: 0.5rem;
    color: var( --bu-warn, #b87a14 );
    font-size: var( --bu-fs-xs, 11px );
}

.cb-rental-offering__price {
    padding: 0.75rem 1.25rem;
    border-top: 1px solid var( --bu-line-2, rgba( 22, 36, 58, 0.06 ) );
    background: var( --bu-bg-sunk, #f0ebe1 );
}
.cb-rental-offering__price-amt {
    font-family: var( --bu-font-display, var( --bu-display, 'Fraunces', serif ) );
    font-size: var( --bu-fs-xl, 22px );
    font-weight: 600;
    color: var( --bu-ink, var( --bu-ink-1, #16243a ) );
    line-height: 1.2;
    letter-spacing: -0.01em;
}
.cb-rental-offering__price-sub {
    font-size: var( --bu-fs-xs, 11px );
    color: var( --bu-ink-3, #6b7689 );
    margin-top: 2px;
}

/* P-5 — License-required warning banner (the standalone block under the
 * offering grid). Replaces a plain unstyled <div className="cb-rental-warning">
 * with a subtle bu-warn-soft tint + left border accent. The banner text and
 * leading ⚠️ emoji are operator-editable copy; only the wrapper styling
 * changes here. */
.cb-rental-warning {
    margin: 1rem 0;
    padding: 0.75rem 1rem;
    border-radius: var( --bu-radius, 14px );
    background: var( --bu-warn-soft, #fef3c7 );
    color: var( --bu-warn, #b87a14 );
    font-size: var( --bu-fs-sm, 13px );
    line-height: 1.5;
    border-left: 3px solid var( --bu-warn, #b87a14 );
}

.cb-rental-empty {
    padding: 1.5rem;
    text-align: center;
    color: var( --bu-ink-3, #6b7689 );
    background: var( --bu-bg-sunk, #f0ebe1 );
    border-radius: var( --bu-radius, 14px );
    font-size: var( --bu-fs-sm, 13px );
}

.cb-rental-total {
    margin: 1rem 0;
    text-align: right;
    font-family: var( --bu-font-display, var( --bu-display, 'Fraunces', serif ) );
    font-size: var( --bu-fs-xl, 22px );
    font-weight: 600;
    color: var( --bu-ink, var( --bu-ink-1, #16243a ) );
}

.cb-rental-skipper {
    margin: 1rem 0;
}
.cb-rental-skipper__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}
@media ( min-width: 640px ) {
    .cb-rental-skipper__grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* ── G5 (v2.4.4) — RentalExtrasStep polish (P-6 + P-7 + R2)
 *
 * Per ROADMAP §16.4 (B3) G5 + the B3 punch list:
 *   P-6 — Mobile: at qty=0 show an "Add" button; ‐ qty + only after adding.
 *   P-7 — Subtotal row → tinted strip with display-font total (matches the
 *         G1 SummaryRail's `--bu-accent-soft` totals palette for consistency).
 *   R2  — Mobile: hide the per-line unit-price subtitle. The unit price is
 *         already visible on the previous step's day-count math, and on a
 *         360px viewport every extra gains ~20px of vertical noise.
 *
 * `cb-rental-extras-list`, `cb-rental-extra`, `cb-rental-extra__*`, and
 * `cb-rental-extras-summary` had NO existing CSS rule (third gap fill in
 * the Phase D rollout — same pattern as v2.4.0 G1 chrome and v2.4.3 G4
 * boat cards). Token-driven (--bu-*) so Harbor / Helm direction restyles
 * automatically; literal-hex fallbacks cover non-wizard contexts. */

.cb-rental-extras-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin: 1rem 0 1.25rem;
}

.cb-rental-extra {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: var( --bu-bg-elev, #ffffff );
    border: 1px solid var( --bu-line, rgba( 22, 36, 58, 0.10 ) );
    border-radius: var( --bu-radius, 14px );
    transition: border-color .15s, box-shadow .15s;
}
.cb-rental-extra.is-selected {
    border-color: var( --bu-primary, #16243a );
    box-shadow: 0 0 0 1px var( --bu-primary, #16243a );
}

.cb-rental-extra__body {
    min-width: 0;
}
.cb-rental-extra__name {
    font-size: var( --bu-fs-base, 15px );
    font-weight: 600;
    color: var( --bu-ink, var( --bu-ink-1, #16243a ) );
    line-height: 1.3;
}
.cb-rental-extra__sub {
    margin-top: 2px;
    font-size: var( --bu-fs-xs, 11px );
    color: var( --bu-ink-3, #6b7689 );
}

.cb-rental-extra__controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* P-6 — Mobile-only "Add" affordance (hidden ≥640) */
.cb-rental-extra__add-mobile {
    -webkit-appearance: none;
       -moz-appearance: none;
            appearance: none;
    border: 1px solid var( --bu-primary, #16243a );
    background: transparent;
    color: var( --bu-primary, #16243a );
    font-family: inherit;
    font-size: var( --bu-fs-sm, 13px );
    font-weight: 600;
    padding: 6px 14px;
    border-radius: var( --bu-radius-pill, 999px );
    cursor: pointer;
    transition: background .15s, color .15s;
}
.cb-rental-extra__add-mobile:hover {
    background: var( --bu-primary, #16243a );
    color: var( --bu-primary-ink, #ffffff );
}
.cb-rental-extra__add-mobile:focus-visible {
    outline: 2px solid var( --bu-primary, #16243a );
    outline-offset: 2px;
}

/* Default (≥640): hide the mobile add button entirely */
@media ( min-width: 640px ) {
    .cb-rental-extra__add-mobile { display: none; }
}

/* Mobile (≤639) — hide the stepper when no qty selected; the Add button
 * is what the customer sees. Once qty > 0 (`is-selected`) the stepper
 * comes back so the customer can adjust or remove. */
@media ( max-width: 639px ) {
    .cb-rental-extra:not( .is-selected ) .cb-rental-extra__stepper-wrap {
        display: none;
    }
    /* R2 — hide the per-day unit-price subtitle on mobile. The unit price
     * is already covered by the previous step's day-count quote; mobile
     * keeps the line clean: name on the left, line-total on the right. */
    .cb-rental-extra__sub {
        display: none;
    }
}

.cb-rental-extra__line-total {
    font-family: var( --bu-font-display, var( --bu-display, 'Fraunces', serif ) );
    font-size: var( --bu-fs-lg, 17px );
    font-weight: 600;
    color: var( --bu-ink, var( --bu-ink-1, #16243a ) );
    min-width: 4ch;
    text-align: right;
    line-height: 1;
}

/* P-7 — Totals strip. Matches the v2.4.0 G1 SummaryRail's tinted-strip
 * pattern (--bu-accent-soft surface, display-font on the grand total). */
.cb-rental-extras-summary {
    margin: 1rem 0;
    padding: 1rem 1.25rem;
    background: var( --bu-accent-soft, #f3e3d6 );
    border-radius: var( --bu-radius, 14px );
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.cb-rental-extras-summary__row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: var( --bu-fs-sm, 13px );
    color: var( --bu-ink-2, #3d4a60 );
}
.cb-rental-extras-summary__total {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding-top: 6px;
    border-top: 1px solid color-mix( in oklab, var( --bu-accent, #c1683a ) 18%, transparent );
    color: var( --bu-ink, var( --bu-ink-1, #16243a ) );
    font-size: var( --bu-fs-sm, 13px );
}
.cb-rental-extras-summary__total > :last-child {
    font-family: var( --bu-font-display, var( --bu-display, 'Fraunces', serif ) );
    font-size: var( --bu-fs-2xl, 28px );
    font-weight: 600;
    line-height: 1;
    letter-spacing: -0.02em;
}

/* ── G6 P-10 (v2.4.5) — PaymentStep split layout at ≥1024
 *
 * Per the B3 punch list: "Switch to 1fr/1fr at ≥1024 — mirrors Stripe-style
 * flows". Below 1024 the step keeps its existing single-column flow exactly
 * as v2.4.4 shipped — title + summary + form stack. Above 1024:
 *   • Title + subtitle span both columns (full-width header)
 *   • Booking summary anchors to the right column (col 2), spans many rows
 *     so it stays visible while the form scrolls in the left column
 *   • All other children flow into the left column via grid auto-placement
 *
 * This is a CSS-only rearrangement — JSX source order is unchanged, so
 * mobile/tablet behaviour is identical to v2.4.4. Only the desktop layout
 * gains the split. */
@media ( min-width: 1024px ) {
    .cb-payment-card {
        display: grid;
        grid-template-columns: 1fr 1fr;
        -moz-column-gap: 2rem;
             column-gap: 2rem;
    }
    .cb-payment-card > .cb-booking-title,
    .cb-payment-card > .cb-booking-subtitle {
        grid-column: 1 / -1;
    }
    .cb-payment-card > .cb-booking-price-box {
        grid-column: 2;
        /* span enough rows that the price-box sticks to the right side
         * regardless of how many items end up in the left column */
        grid-row: span 99;
        align-self: start;
        position: sticky;
        top: 16px;
        margin-bottom: 0;
    }
}

