/**
 * Haven Theme - the search capsule (one stylesheet for every search bar)
 *
 * The centred capsule (fields, divider hairlines and an ink "Show homes" button), its frosted
 * glass variant for photos, the control row under it (the count on the left, quiet pills on the
 * right) and the Who? panel. Used by /vacation-rentals/ and the destination pages: the homes
 * bar and the hero bar. It carries its own tokens, so it needs none of the search page's
 * (body.haven-streamline-search-page) and works wherever it is loaded.
 *
 * Sizing (Samuel, 2026-12-02): the capsule is as wide as its fields and each field is as wide as
 * its own words plus even padding, so an empty bar is about 600px and it grows as a guest picks
 * values. A long value stops at 220px with an ellipsis. One line, always: under 760px the
 * fields tighten and "Show homes" becomes a round search button, its words still the button's
 * accessible name. Never wider than its container.
 *
 * Markup (the connector's templates and the theme's destination partials):
 *   .hsc-capsule                       the bar
 *     .hsc-capsule__field              one field: a label and a value, or an input / select / button
 *       (+ --date, --resort)           .is-set once it holds a value
 *       .hsc-capsule__value            the words, clipped with an ellipsis
 *     .hsc-capsule__go                 the submit button, its words in .hsc-capsule__go-label
 *   .hsc-capsule--glass                frosted glass over a photo (the destination hero)
 *   .hsc-capsule-row                   count (left) and tools (right) under the bar
 *     .hsc-capsule-row__count, .hsc-capsule-row__tools, .hsc-capsule-pill
 *   .hsc-who                           the Who? field and its panel (the connector's shared partial)
 *   .hsc-featured-filters              a destination page's Filters pill and its panel (bedrooms, sort...)
 *   .hsc-booking-calendar-picker--results   the shared calendar's Exact / Flexible footer and chosen-day look
 *
 * No gradients. Two faces: Cormorant Garamond for the placeholders and counts, Manrope for the rest.
 *
 * Spec: docs/superpowers/specs/2026-12-02-centred-search-bar-and-destination-search-design.md
 */

/* ==========================================================================
   The capsule
   ========================================================================== */

.hsc-capsule {
	position: relative;
	z-index: 2;
	box-sizing: border-box;
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	width: fit-content;
	max-width: 100%;
	margin-inline: auto;
	padding: 5px 5px 5px 6px;
	background: #FFFDF9;
	border: 1px solid rgba(196, 160, 120, .3);
	border-radius: 999px;
	box-shadow: 0 24px 52px rgba(30, 26, 20, .10);
}

/* The tokens, so the sheet works on pages that carry no search-page tokens. The values are the
   search page's own (haven-streamline-luxury-search.css), so the two never disagree there. */
.hsc-capsule,
.hsc-capsule-row,
.hsc-who,
.hsc-featured-filters__panel,
.hsc-booking-calendar-picker--results {
	--el-linen: #FAF7F1;
	--el-ink: #1A1612;
	--el-bronze: #8A6A40;
	--el-gold: #C4A078;
	--el-muted: #76695C;
	--el-display: "Cormorant Garamond", "Cormorant", Georgia, "Times New Roman", serif;
	--el-ui: "Manrope", "Helvetica Neue", Arial, sans-serif;
	--vr-paper: #FFFDF9;
	--vr-sand: #F2ECE2;
	--vr-ink-2: #3B332B;
	--vr-line: rgba(196, 160, 120, .30);
	--vr-ease: cubic-bezier(.2, .8, .2, 1);
}

/* The bar grows as a guest picks values. The capsule itself never animates: its computed width
   stays fit-content while its content grows, so a transition on it would never start. What can
   animate is the width the shared script (HSCCapsule.fit) sets in px on an input or select, so the
   .2s width transition sits there. Where the browser supports field-sizing: content the script
   sets no width and the bar grows without animation. Reduced motion removes the transition. */
.hsc-capsule__field input,
.hsc-capsule__field select {
	transition: width .2s ease;
}

/* A field is as wide as its words (flex 0 0 auto), 220px at most. The words inside it
   (.hsc-capsule__value, an input, a select, the Who? toggle) are what clip with an ellipsis; the
   field itself never clips, because the Who? panel hangs off it. Empty, it reads as a
   placeholder: Cormorant Garamond italic, muted. */
.hsc-capsule__field {
	position: relative;
	box-sizing: border-box;
	display: flex;
	flex: 0 0 auto;
	flex-direction: column;
	justify-content: center;
	min-width: 0;
	max-width: 220px;
	margin: 0;
	padding: 10px 22px;
	background: transparent;
	border: 0;
	border-radius: 999px;
	font-family: var(--el-display);
	font-size: 18px;
	font-style: italic;
	font-weight: 500;
	line-height: 1.2;
	letter-spacing: 0;
	text-align: left;
	text-transform: none;
	text-overflow: ellipsis;
	white-space: nowrap;
	color: var(--el-muted);
	cursor: pointer;
	transition: background-color 0.2s var(--vr-ease), box-shadow 0.2s var(--vr-ease);
}

/* The hairline between two fields. A pseudo-element rather than a border, so a field's rounded
   hover and focus shape stays clean. */
.hsc-capsule__field + .hsc-capsule__field::before {
	content: "";
	position: absolute;
	top: 24%;
	bottom: 24%;
	left: 0;
	width: 1px;
	background: rgba(196, 160, 120, .3);
	pointer-events: none;
}

.hsc-capsule__field:hover {
	background: var(--vr-sand);
}

.hsc-capsule__field:focus-within {
	background: #FFFFFF;
	box-shadow: 0 6px 20px rgba(30, 26, 20, .12);
}

.hsc-capsule__field:has(:focus-visible) {
	box-shadow: 0 0 0 2px var(--el-bronze);
}

/* Browsers without :has() ring the field on :focus-within, so keyboard focus is never shown by a soft shadow alone. */
@supports not selector(:has(*)) {
	.hsc-capsule__field:focus-within {
		box-shadow: 0 0 0 2px var(--el-bronze);
	}
}

/* Holding a value, a field reads as a value: Manrope 600, ink, with its small label above it. */
.hsc-capsule__field.is-set {
	font-family: var(--el-ui);
	font-size: 14px;
	font-style: normal;
	font-weight: 600;
	color: var(--el-ink);
}

/* The label stays in the markup for screen readers, clipped to nothing; a set field shows it small. */
.hsc-capsule__field .hsc-field-label {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.hsc-capsule__field.is-set .hsc-field-label {
	position: static;
	width: auto;
	height: auto;
	margin: 0 0 2px;
	overflow: visible;
	clip: auto;
	clip-path: none;
	font-family: var(--el-ui);
	font-size: 11px;
	font-style: normal;
	font-weight: 500;
	line-height: 1.2;
	color: var(--el-muted);
}

/* What a field holds: plain words, or the bar's own form controls drawn as plain words. */
.hsc-capsule__field .hsc-capsule__value,
.hsc-capsule__field input,
.hsc-capsule__field select {
	display: block;
	box-sizing: border-box;
	width: auto;
	min-width: 0;
	max-width: 100%;
	height: auto;
	min-height: 0;
	margin: 0;
	padding: 0;
	background: transparent;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	outline: none;
	font: inherit;
	letter-spacing: inherit;
	text-transform: none;
	color: inherit;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	-webkit-appearance: none;
	appearance: none;
	/* Where the browser supports it, an input or select is as wide as its own text. */
	field-sizing: content;
}

.hsc-capsule__field input::placeholder {
	color: var(--el-muted);
	opacity: 1;
}

/* A control left holding a value reads as set without waiting for a class. */
.hsc-capsule__field input:not(:placeholder-shown),
.hsc-capsule__field select:not(:has(> option[value=""]:checked)) {
	font-family: var(--el-ui);
	font-size: 14px;
	font-style: normal;
	font-weight: 600;
	color: var(--el-ink);
}

.hsc-capsule__field--date,
.hsc-capsule__field--resort {
	cursor: pointer;
}

/* The ink "Show homes" button: a pill; its words sit in .hsc-capsule__go-label. */
.hsc-capsule__go {
	box-sizing: border-box;
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 40px;
	margin: 0 0 0 6px;
	padding: 13px 20px;
	background: var(--el-ink);
	border: 0;
	border-radius: 999px;
	box-shadow: none;
	font-family: var(--el-ui);
	font-size: 13px;
	font-style: normal;
	font-weight: 600;
	line-height: 1.2;
	letter-spacing: 0;
	text-transform: none;
	white-space: nowrap;
	color: var(--el-linen);
	cursor: pointer;
	transition: width .2s ease, background-color 0.2s var(--vr-ease);
}

.hsc-capsule__go:hover {
	background: var(--vr-ink-2);
}

.hsc-capsule__go:focus-visible {
	outline: 2px solid var(--el-bronze);
	outline-offset: 2px;
}

/* The theme's base sheet (haven-custom.css) paints every button[type="submit"] inside an hsc- block bronze
   with !important, which would turn this button bronze on a page that has no search page rule of its own
   (a destination page). These rules outweigh it and keep the button ink. */
.hsc-capsule button.hsc-capsule__go[type="submit"] {
	background-color: var(--el-ink) !important;
	border-color: var(--el-ink) !important;
	color: var(--el-linen) !important;
}

.hsc-capsule button.hsc-capsule__go[type="submit"]:hover {
	background-color: var(--vr-ink-2) !important;
	border-color: var(--vr-ink-2) !important;
}

.hsc-capsule__go svg {
	flex: 0 0 auto;
	width: 14px;
	height: 14px;
}

/* ==========================================================================
   Who? as a field of the capsule: it takes the field's words, not the panel's own sizes.
   The more specific selector is what beats the toggle's !important type below.
   ========================================================================== */

.hsc-capsule .hsc-capsule__field.hsc-who .hsc-who__toggle {
	font-family: inherit !important;
	font-size: inherit !important;
	font-style: inherit !important;
	font-weight: inherit !important;
	line-height: inherit !important;
	color: inherit !important;
}

/* The Who? partial prints the search bar's small field icon. A capsule field has none (Resort, Arrival and
   Departure print no icon), and on a destination page no search-page rule hides it, so hide it here. */
.hsc-capsule .hsc-search-field__icon {
	display: none !important;
}

/* The field's white-space, italic and size are meant for its words; the panel sets its own. */
.hsc-capsule__field .hsc-who__panel {
	font-size: 1rem;
	font-style: normal;
	font-weight: 400;
	line-height: 1.4;
	white-space: normal;
	text-overflow: clip;
}

/* ==========================================================================
   Glass: the capsule on a photo (the destination hero). A dark-tinted translucent fill, a fine
   light hairline and linen words, with a linen "Show homes" so it still reads as the one action.
   The blur sits on a pseudo-element, not on the capsule: a backdrop-filter on the capsule would make
   it the containing block of its fixed-position descendants and pin the phone Who? sheet to the
   capsule instead of the screen. The open date picker and the Who? panel stay solid paper.
   Contrast: the fill is dark enough that linen words clear 4.5:1 even over pure white (5.4:1),
   so no photo can wash them out; hover and an open field darken it further, never lighten it.
   tests/destinations/test-hero-capsule.php works these ratios out from this sheet.
   ========================================================================== */

.hsc-capsule--glass {
	background: rgba(26, 22, 18, .66);
	border-color: rgba(250, 247, 241, .28);
	box-shadow: 0 18px 40px rgba(0, 0, 0, .25);
	color: var(--el-linen);
}

.hsc-capsule--glass::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	border-radius: inherit;
	pointer-events: none;
	-webkit-backdrop-filter: blur(18px) saturate(140%);
	backdrop-filter: blur(18px) saturate(140%);
}

/* No backdrop blur: a darker translucent ink keeps the words readable over any photo. */
@supports not ((backdrop-filter: none) or (-webkit-backdrop-filter: none)) {
	.hsc-capsule--glass {
		background: rgba(26, 22, 18, .8);
	}
}

.hsc-capsule--glass .hsc-capsule__field {
	color: var(--el-linen);
}

.hsc-capsule--glass .hsc-capsule__field.is-set,
.hsc-capsule--glass .hsc-capsule__field input:not(:placeholder-shown),
.hsc-capsule--glass .hsc-capsule__field select:not(:has(> option[value=""]:checked)) {
	color: var(--el-linen);
}

.hsc-capsule--glass .hsc-capsule__field.is-set .hsc-field-label {
	color: var(--el-linen);
}

.hsc-capsule--glass .hsc-capsule__field input::placeholder {
	color: var(--el-linen);
}

.hsc-capsule--glass .hsc-capsule__field + .hsc-capsule__field::before {
	background: rgba(250, 247, 241, .28);
}

/* Hover and an open field: a deeper ink with a linen hairline. A lighter wash would pull the
   linen words under 4.5:1 over a bright photo. */
.hsc-capsule--glass .hsc-capsule__field:hover {
	background: rgba(26, 22, 18, .22);
	box-shadow: inset 0 0 0 1px rgba(250, 247, 241, .4);
}

.hsc-capsule--glass .hsc-capsule__field:focus-within,
.hsc-capsule--glass .hsc-who.is-open {
	background: rgba(26, 22, 18, .32) !important;
	box-shadow: inset 0 0 0 1px rgba(250, 247, 241, .55) !important;
}

.hsc-capsule--glass .hsc-capsule__field:has(:focus-visible) {
	box-shadow: 0 0 0 2px var(--el-linen) !important;
}

.hsc-capsule--glass .hsc-capsule__go {
	background: var(--el-linen);
	color: var(--el-ink);
}

.hsc-capsule--glass .hsc-capsule__go:hover {
	background: #FFFFFF;
}

.hsc-capsule--glass .hsc-capsule__go:focus-visible {
	outline-color: var(--el-linen);
}

.hsc-capsule--glass button.hsc-capsule__go[type="submit"] {
	background-color: var(--el-linen) !important;
	border-color: var(--el-linen) !important;
	color: var(--el-ink) !important;
}

.hsc-capsule--glass button.hsc-capsule__go[type="submit"]:hover {
	background-color: #FFFFFF !important;
	border-color: #FFFFFF !important;
}

/* ==========================================================================
   Narrow screens: still one line. The fields tighten (760px, then 430px) and "Show homes"
   becomes a round search button; its words stay for screen readers, clipped to nothing.
   ========================================================================== */

@media (max-width: 760px) {
	.hsc-capsule__field {
		padding: 9px 13px;
		font-size: 16.5px;
	}

	.hsc-capsule__field.is-set,
	.hsc-capsule__field input:not(:placeholder-shown),
	.hsc-capsule__field select:not(:has(> option[value=""]:checked)) {
		font-size: 13px;
	}

	.hsc-capsule__field.is-set .hsc-field-label {
		font-size: 10px;
	}

	.hsc-capsule__go {
		min-width: 40px;
		margin-left: 2px;
		padding: 12px;
	}

	.hsc-capsule__go-label {
		position: absolute;
		width: 1px;
		height: 1px;
		margin: -1px;
		padding: 0;
		overflow: hidden;
		clip: rect(0 0 0 0);
		clip-path: inset(50%);
		white-space: nowrap;
		border: 0;
	}
}

@media (max-width: 430px) {
	.hsc-capsule {
		padding: 4px;
	}

	/* On a very narrow screen a field may give way (its words end in an ellipsis) rather than push the bar past the screen. */
	.hsc-capsule__field {
		flex: 0 1 auto;
		padding: 7px 7px;
		font-size: 14.5px;
	}

	.hsc-capsule__field.is-set,
	.hsc-capsule__field input:not(:placeholder-shown),
	.hsc-capsule__field select:not(:has(> option[value=""]:checked)) {
		font-size: 11.5px;
	}

	.hsc-capsule__go {
		padding: 10px;
	}
}

/* hsc-tap-areas:start */
/* ==========================================================================
   Tap areas (spec 4h, Samuel 2026-12-02): at 820px and narrower a finger lands on Where to?, Arrival,
   Departure, Who? and the round search button anywhere on a 44px square around each one's middle, in every
   bar, docked or not, and on Clear dates in the calendar. The bar grows no taller: what a tap gains is an
   invisible box, never paint. A field's box is its own width and 46px tall, beneath its words (z-index -1 in
   the capsule's stacking), so a tap on the words still reaches the control and a tap beside them reaches the
   field, which opens the calendar or the select as before. Who? already takes a tap anywhere on its pill
   (the toggle's box); it reaches 46px too. The search button's box reaches only into its own 2px margin and
   the capsule's padding, so no box ever covers a neighbour. A field is never narrower than 48px: where two
   fields meet on a fraction of a pixel, the browser can give up to a pixel of one field's edge to the next, and
   48px still leaves a whole 44px. Wider than 820px nothing here applies. The render test strips this block,
   between its markers, to compare the bar with and without it.
   ========================================================================== */

@media (max-width: 820px) {
	.hsc-capsule .hsc-capsule__field {
		min-width: 48px;
	}

	.hsc-capsule .hsc-capsule__field:not(.hsc-who)::after {
		content: "";
		position: absolute;
		top: min(0px, calc(50% - 23px));
		right: 0;
		bottom: min(0px, calc(50% - 23px));
		left: 0;
		z-index: -1;
	}

	.hsc-capsule .hsc-capsule__field.hsc-who .hsc-who__toggle::after {
		top: min(0px, calc(50% - 23px));
		bottom: min(0px, calc(50% - 23px));
	}

	.hsc-capsule .hsc-capsule__go {
		position: relative;
	}

	.hsc-capsule .hsc-capsule__go::after {
		content: "";
		position: absolute;
		top: min(0px, calc(50% - 23px));
		right: -4px;
		bottom: min(0px, calc(50% - 23px));
		left: -2px;
	}

	/* Clear dates keeps its look (as tall as the Exact / Flexible group with a mouse); its box reaches 46px. */
	.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results button.hsc-cal-clear {
		position: relative;
	}

	.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results button.hsc-cal-clear::after {
		content: "";
		position: absolute;
		top: min(0px, calc(50% - 23px));
		right: 0;
		bottom: min(0px, calc(50% - 23px));
		left: 0;
	}
}
/* hsc-tap-areas:end */

/* ==========================================================================
   The control row: the count on the left, quiet pills on the right (Filters, Reservation builder,
   Saved homes, the Map switch on /vacation-rentals/; Filters and Clear on a destination page).
   ========================================================================== */

.hsc-capsule-row {
	box-sizing: border-box;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	width: 100%;
	margin: 26px 0 16px;
}

.hsc-capsule-row__count {
	margin: 0;
	font-family: var(--el-display);
	font-size: 30px;
	font-weight: 500;
	line-height: 1.1;
	color: var(--el-ink);
}

.hsc-capsule-row__tools {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin-left: auto;
}

/* The connector's public.css gives the old homes bar's Clear a 112px basis under 768px; in this row it would push
   Filters and Clear into a ragged column on phones. */
.hsc-featured-properties__search--capsule .hsc-capsule-row [data-featured-search-reset] {
	flex: 0 0 auto;
}

.hsc-capsule-pill {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	gap: 7px;
	min-height: 40px;
	margin: 0;
	padding: 0 16px;
	background: transparent;
	border: 1px solid rgba(26, 22, 18, .2);
	border-radius: 999px;
	box-shadow: none;
	font-family: var(--el-ui);
	font-size: 12.8px;
	font-style: normal;
	font-weight: 600;
	line-height: 1;
	letter-spacing: 0;
	text-transform: none;
	white-space: nowrap;
	color: var(--el-ink);
	cursor: pointer;
	transition: border-color 0.15s var(--vr-ease), background-color 0.15s var(--vr-ease);
}

.hsc-capsule-pill:hover {
	background: var(--vr-sand);
	border-color: var(--el-ink);
}

.hsc-capsule-pill:focus-visible {
	outline: 2px solid var(--el-bronze);
	outline-offset: 2px;
}

.hsc-capsule-pill svg {
	flex: 0 0 auto;
	width: 14px;
	height: 14px;
}

@media (max-width: 760px) {
	.hsc-capsule-row__count {
		font-size: 26px;
	}
}

@keyframes haven-search-sheet {
	from { opacity: 0; transform: translateY(24px); }
	to { opacity: 1; transform: none; }
}

/* ==========================================================================
   Calendar: the two faces, and the Exact dates / Flexible dates footer. Used wherever the shared
   calendar takes a flex_selector (it then carries --results): the /vacation-rentals/ bar and the
   destination bars. Moved here from the search page sheet, which destination pages never load.
   The picker script moves the open calendar to <body>, out of the form and the capsule, so these
   rules hang off the picker's own class. It is written twice (.hsc-booking-calendar-picker + --results)
   to keep the weight the old body-scoped rules had against the connector's single-class calendar sheet.
   ========================================================================== */

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results {
	--hsc-font-serif: var(--el-display);
	--hsc-font-sans: var(--el-ui);
	--hsc-display-font: var(--el-display);
}

/* Flat surface and flat ink for the chosen days (the shared calendar uses teal and blue gradients). */
.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-booking-calendar-picker__content {
	background: var(--vr-paper) !important;
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-day--checkin,
.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-day--checkout-selected {
	background: var(--el-ink) !important;
	color: var(--el-linen) !important;
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-day--in-range {
	background: var(--vr-sand) !important;
	color: var(--el-ink) !important;
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-booking-calendar-picker__footer {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-start;
	gap: 10px 16px;
	margin: 0;
	padding: 12px 16px 14px;
	border-top: 1px solid var(--vr-line);
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-flex {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 4px;
	padding: 4px;
	background: var(--vr-paper);
	border: 1px solid var(--vr-line);
	border-radius: 999px;
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-flex__btn {
	min-height: 0;
	margin: 0;
	padding: 8px 13px;
	background: transparent;
	border: 0;
	border-radius: 999px;
	box-shadow: none;
	font-family: var(--el-ui);
	font-size: 0.74rem;
	font-weight: 600;
	line-height: 1;
	letter-spacing: 0;
	text-transform: none;
	color: var(--el-muted);
	cursor: pointer;
	transition: background-color 0.2s var(--vr-ease), color 0.2s var(--vr-ease);
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-flex__btn:hover {
	color: var(--el-ink);
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-flex__btn[aria-pressed="true"] {
	background: var(--el-ink);
	color: var(--el-linen);
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-flex__btn:focus-visible {
	outline: 2px solid var(--el-bronze);
	outline-offset: 2px;
}

/* Clear dates (spec 4e): a quiet outline pill as tall as the Exact / Flexible group, its words where the group's
   start. It keeps to the right of the footer: beside the group when both fit, else on its own line below it.
   aria-disabled (no date set) dims it; it stays focusable. */
.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-clear {
	flex: 0 0 auto;
	min-height: 0;
	margin: 0 0 0 auto;
	padding: 12px 17px;
	background: transparent;
	border: 1px solid var(--vr-line);
	border-radius: 999px;
	box-shadow: none;
	font-family: var(--el-ui);
	font-size: 0.74rem;
	font-weight: 600;
	line-height: 1;
	letter-spacing: 0;
	text-transform: none;
	white-space: nowrap;
	color: var(--el-muted);
	cursor: pointer;
	transition: color 0.2s var(--vr-ease), border-color 0.2s var(--vr-ease), opacity 0.2s var(--vr-ease);
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-clear:hover {
	color: var(--el-ink);
	border-color: var(--el-ink);
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-clear:focus-visible {
	outline: 2px solid var(--el-bronze);
	outline-offset: 2px;
}

.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-clear[aria-disabled="true"] {
	color: var(--el-muted);
	border-color: var(--vr-line);
	opacity: 0.5;
	cursor: default;
}

@media (pointer: coarse) {
	/* A finger needs 44px: the Exact / Flexible choices are as tall as a button. */
	.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-flex__btn {
		min-height: 44px;
	}
}

/* ==========================================================================
   Filters on a destination page (the homes bar's row): a pill that opens a panel of the bedrooms,
   bathrooms, cities and sort selects (and, under 560px, the Resort field). It is the featured bar's
   own control (templates/property/property-featured.php), not the search page's #hsc-more-filters.
   The panel opens under its own button, right-aligned, on paper like the Who? panel; under 768px it
   is a bottom sheet (a dropdown right-aligned to a button that sits left of the Clear pill would
   run off the left edge of a phone). Hidden with [hidden].
   ========================================================================== */

.hsc-featured-filters {
	position: relative;
	display: inline-block;
}

.hsc-capsule-pill[aria-expanded="true"] {
	background: var(--vr-sand);
	border-color: var(--el-ink);
}

.hsc-featured-filters__panel {
	position: absolute;
	top: calc(100% + 10px);
	right: 0;
	z-index: 60;
	box-sizing: border-box;
	width: 360px;
	max-width: calc(100vw - 32px);
	margin: 0;
	padding: 22px 24px 12px;
	background: var(--vr-paper);
	border: 1px solid var(--vr-line);
	border-radius: 24px;
	box-shadow: 0 28px 60px rgba(30, 26, 20, .16);
	color: var(--el-ink);
	font-family: var(--el-ui);
	font-size: 14px;
	font-style: normal;
	font-weight: 400;
	line-height: 1.4;
	text-align: left;
	white-space: normal;
	cursor: default;
	animation: haven-who-in 0.22s var(--vr-ease);
}

.hsc-featured-filters__panel[hidden] {
	display: none !important;
}

.hsc-featured-filters__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px 14px;
}

.hsc-featured-filters__group {
	min-width: 0;
	margin: 0;
	padding: 0;
}

.hsc-featured-filters__group label,
.hsc-featured-filters__panel .hsc-capsule__field--resort .hsc-field-label {
	display: block;
	margin: 0 0 6px;
	font-family: var(--el-ui);
	font-size: 11px;
	font-style: normal;
	font-weight: 600;
	line-height: 1.2;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--el-muted);
}

.hsc-featured-filters__group select,
.hsc-featured-filters__panel .hsc-capsule__field.hsc-capsule__field--resort select.hsc-capsule__value {
	-webkit-appearance: none;
	appearance: none;
	box-sizing: border-box;
	display: block;
	width: 100% !important; /* the capsule script sizes a select in px; here it fills its cell */
	min-width: 0;
	max-width: none;
	height: 44px;
	margin: 0;
	padding: 0 34px 0 14px;
	background: #FFFFFF url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none' stroke='%231A1612' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 14px center / 12px 8px;
	border: 1px solid var(--vr-line);
	border-radius: 14px;
	box-shadow: none;
	font-family: var(--el-ui);
	font-size: 14px;
	font-style: normal;
	font-weight: 600;
	letter-spacing: 0;
	line-height: 1.2;
	text-transform: none;
	text-overflow: ellipsis;
	white-space: nowrap;
	color: var(--el-ink);
	cursor: pointer;
	field-sizing: fixed;
}

.hsc-featured-filters__group select:focus-visible,
.hsc-featured-filters__panel .hsc-capsule__field--resort select:focus-visible {
	outline: 2px solid var(--el-bronze);
	outline-offset: 2px;
}

/* The Resort field, once the script has moved it into this panel (under 560px): a labelled select in
   the grid like its neighbours, not a pill (no hover wash, no divider, no 220px cap). */
.hsc-featured-filters__panel .hsc-capsule__field--resort {
	grid-column: 1 / -1;
	display: block;
	width: auto;
	max-width: none;
	margin: 0 0 16px;
	padding: 0;
	background: transparent;
	border-radius: 0;
	box-shadow: none;
	font-family: var(--el-ui);
	font-size: 14px;
	font-style: normal;
	font-weight: 600;
	color: var(--el-ink);
	cursor: default;
}

.hsc-featured-filters__panel .hsc-capsule__field--resort::before {
	display: none;
}

.hsc-featured-filters__panel .hsc-capsule__field--resort:hover,
.hsc-featured-filters__panel .hsc-capsule__field--resort:focus-within,
.hsc-featured-filters__panel .hsc-capsule__field--resort:has(:focus-visible) {
	background: transparent;
	box-shadow: none;
}

.hsc-featured-filters__panel .hsc-capsule__field--resort .hsc-field-label {
	position: static;
	width: auto;
	height: auto;
	overflow: visible;
	clip: auto;
	clip-path: none;
	white-space: normal;
}

.hsc-featured-filters__footer {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	margin-top: 18px;
	padding-top: 6px;
	border-top: 1px solid var(--vr-line);
}

.hsc-featured-filters__clear {
	min-height: 44px;
	margin: 0;
	padding: 0 2px;
	background: transparent;
	border: 0;
	box-shadow: none;
	font-family: var(--el-ui);
	font-size: 0.86rem;
	font-weight: 600;
	letter-spacing: 0;
	text-transform: none;
	color: var(--el-ink);
	text-decoration: underline;
	text-decoration-color: var(--el-gold);
	text-underline-offset: 4px;
	cursor: pointer;
}

.hsc-featured-filters__clear:hover {
	background: transparent;
	color: var(--el-ink);
}

.hsc-featured-filters__clear:focus-visible {
	outline: 2px solid var(--el-bronze);
	outline-offset: 2px;
}

@media (max-width: 380px) {
	.hsc-featured-filters__grid {
		grid-template-columns: minmax(0, 1fr);
	}
}

/* ==========================================================================
   Who? (owner 2026-12-02): the words in the bar open a panel of three counters, Adults (13 and
   above), Children (under 13) and Pets, on paper under the field, with hairlines between the rows,
   round outline steppers, and Clear and an ink Done at the foot. On phones it rises from the bottom
   as a sheet, like the rate chooser. The counts ride in hidden fields, so nothing here touches them.
   ========================================================================== */

.hsc-who__toggle {
	display: block !important;
	width: 100% !important;
	min-width: 0 !important;
	height: auto !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	background: transparent !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	outline: none;
	font-family: var(--el-display) !important;
	font-size: 1.2rem !important;
	font-weight: 600 !important;
	font-style: normal;
	line-height: 1.1 !important;
	letter-spacing: 0 !important;
	text-align: left !important;
	text-transform: none !important;
	color: var(--el-ink) !important;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	cursor: pointer;
}

/* The whole pill opens the panel, not just the words. */
.hsc-who__toggle::after {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: inherit;
}

/* Untouched, "Who?" reads like the Arrival and Departure placeholders. */
.hsc-who:not(.is-set) .hsc-who__toggle {
	font-style: italic;
	font-weight: 500 !important;
	color: var(--el-muted) !important;
}

.hsc-who.is-open {
	background: #FFFFFF !important;
	box-shadow: 0 6px 20px rgba(30, 26, 20, .12) !important;
}

/* The capsule is a stacking context (z-index 2), so the fixed phone Who? sheet (z-index 100000) is only as
   high as the capsule. While a Who? inside it is open the capsule steps up, so a sticky header or bottom bar
   on a destination page cannot cover the sheet. The glass blur sits on a ::before inside the capsule, so it
   is not affected. */
.hsc-capsule:has(.hsc-who.is-open) {
	z-index: 100000;
}

.hsc-who__panel {
	position: absolute;
	top: calc(100% + 14px);
	right: 0;
	z-index: 60;
	width: min(400px, calc(100vw - 32px));
	margin: 0;
	padding: 6px 24px 18px;
	background: var(--vr-paper);
	border: 1px solid var(--vr-line);
	border-radius: 24px;
	box-shadow: 0 28px 60px rgba(30, 26, 20, .16);
	color: var(--el-ink);
	font-family: var(--el-ui);
	text-align: left;
	cursor: default;
	animation: haven-who-in 0.22s var(--vr-ease);
}

.hsc-who__panel[hidden] {
	display: none !important;
}

.hsc-who__row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 18px;
	padding: 18px 0;
	border-bottom: 1px solid var(--vr-line);
}

.hsc-who__text {
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
}

.hsc-who__name {
	font-family: var(--el-display);
	font-size: 1.28rem;
	font-weight: 600;
	line-height: 1.15;
	color: var(--el-ink);
}

.hsc-who__note {
	font-family: var(--el-ui);
	font-size: 0.82rem;
	line-height: 1.45;
	color: var(--el-muted);
}

.hsc-who__stepper {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 12px;
}

.hsc-who__step {
	display: grid !important;
	place-items: center;
	width: 38px !important;
	height: 38px !important;
	min-width: 0 !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	background: transparent !important;
	border: 1px solid rgba(26, 22, 18, .26) !important;
	border-radius: 50% !important;
	box-shadow: none !important;
	color: var(--el-ink) !important;
	cursor: pointer;
	transition: border-color 0.15s var(--vr-ease), background-color 0.15s var(--vr-ease), transform 0.1s var(--vr-ease);
}

.hsc-who__step:hover:not([aria-disabled="true"]) {
	background: var(--vr-sand) !important;
	border-color: var(--el-ink) !important;
}

.hsc-who__step:active:not([aria-disabled="true"]) {
	transform: scale(.94);
}

.hsc-who__step[aria-disabled="true"] {
	opacity: .3;
	cursor: not-allowed;
}

.hsc-who__step:focus-visible,
.hsc-who__clear:focus-visible,
.hsc-who__done:focus-visible {
	outline: 2px solid var(--el-bronze);
	outline-offset: 2px;
}

.hsc-who__count {
	display: block;
	min-width: 1.6em;
	font-family: var(--el-ui);
	font-size: 1rem;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	line-height: 1;
	text-align: center;
	color: var(--el-ink);
}

.hsc-who__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding-top: 16px;
}

.hsc-who__clear {
	min-height: 44px;
	margin: 0 !important;
	padding: 0 2px !important;
	background: transparent !important;
	border: 0 !important;
	box-shadow: none !important;
	font-family: var(--el-ui) !important;
	font-size: 0.86rem !important;
	font-weight: 600 !important;
	letter-spacing: 0 !important;
	text-transform: none !important;
	color: var(--el-ink) !important;
	text-decoration: underline;
	text-decoration-color: var(--el-gold);
	text-underline-offset: 4px;
	cursor: pointer;
}

.hsc-who__clear[aria-disabled="true"] {
	color: var(--el-muted) !important;
	text-decoration: none;
	cursor: default;
}

.hsc-who__done {
	min-height: 44px;
	margin: 0 !important;
	padding: 0 28px !important;
	background: var(--el-ink) !important;
	border: 0 !important;
	border-radius: 999px !important;
	box-shadow: none !important;
	font-family: var(--el-ui) !important;
	font-size: 0.78rem !important;
	font-weight: 700 !important;
	letter-spacing: 0.14em !important;
	text-transform: uppercase !important;
	color: var(--el-linen) !important;
	cursor: pointer;
	transition: background-color 0.15s var(--vr-ease);
}

.hsc-who__done:hover {
	background: var(--vr-ink-2) !important;
}

@keyframes haven-who-in {
	from {
		opacity: 0;
		transform: translateY(-6px);
	}
	to {
		opacity: 1;
		transform: none;
	}
}

/* Between 768 and 820px the capsule stays on one line on every page, /vacation-rentals/ included (Samuel,
   2026-12-02: no fold), and the Who? field is its rightmost field, so the panel hangs from the field's right
   edge and stays inside the screen. Under 768px the panel is the bottom sheet below, which this rule must
   not narrow. */
@media (min-width: 768px) and (max-width: 820px) {
	.hsc-who__panel {
		right: 0;
		left: auto;
		max-width: calc(100vw - 32px);
	}
}

/* Phones: a sheet from the bottom of the screen. */
@media (max-width: 767px) {
	.hsc-who__panel {
		position: fixed;
		top: auto;
		right: 0;
		bottom: 0;
		left: 0;
		z-index: 100000;
		width: auto;
		max-height: 82vh;
		overflow-y: auto;
		padding: 8px 20px calc(16px + env(safe-area-inset-bottom, 0px));
		border-width: 1px 0 0;
		border-radius: 22px 22px 0 0;
		box-shadow: 0 -20px 50px rgba(30, 26, 20, .22);
		animation: haven-search-sheet 0.3s var(--vr-ease);
	}

	/* The chat bubble sits over the sheet's Done button, so it steps aside while the sheet is open. */
	body.hsc-who-open #havenchat-widget {
		visibility: hidden !important;
	}

	/* The Filters panel on a destination page is a sheet too: a dropdown right-aligned to a button that sits
	   beside the Clear pill would run off the left edge of a phone. It sits in the row under the capsule, which
	   is not a stacking context, so its z-index reaches the page. */
	.hsc-featured-filters__panel {
		position: fixed;
		top: auto;
		right: 0;
		bottom: 0;
		left: 0;
		z-index: 100000;
		width: auto;
		max-width: none;
		max-height: 82vh;
		overflow-y: auto;
		padding: 22px 20px calc(10px + env(safe-area-inset-bottom, 0px));
		border-width: 1px 0 0;
		border-radius: 22px 22px 0 0;
		box-shadow: 0 -20px 50px rgba(30, 26, 20, .22);
		animation: haven-search-sheet 0.3s var(--vr-ease);
	}

	body:has([data-featured-filters-panel]:not([hidden])) #havenchat-widget {
		visibility: hidden !important;
	}
}

/* ==========================================================================
   Who? and a docked search bar (spec 4f, Task 14: the Vacation Rentals bar docks under the site header; the
   dock itself is in haven-streamline-luxury-search.css). The same on every page.
   ========================================================================== */

/* The compare tray the card script fixes to the foot of the window (in <body>, z-index 100000) would cover Done
   in a short window, and a search block is its own stacking context (isolation: isolate), so no layer inside it
   can rise above the tray: it steps aside while Who? is open, as the chat bubble does for the phone sheet
   (body.hsc-who-open is the capsule script's, at every width). */
body.hsc-who-open #hsc-compare-tray {
	visibility: hidden !important;
}

/* From 768px Who? hangs under its field. In a docked bar (.hsc-dock-ready, .is-stuck) it rides with the bar, so
   in a short window (a phone on its side) its foot would sit below the screen where no scroll can reach it: it
   fits the window below the bar and scrolls inside itself, Clear and Done kept in view at its foot. */
@media (min-width: 768px) {
	.hsc-dock-ready > .hsc-search-topbar.is-stuck .hsc-who__panel {
		max-height: calc(100vh - var(--hsc-sticky-top, 0px) - 120px);
		max-height: calc(100dvh - var(--hsc-sticky-top, 0px) - 120px);
		overflow-y: auto;
		overscroll-behavior: contain;
	}

	.hsc-dock-ready > .hsc-search-topbar.is-stuck .hsc-who__foot {
		position: sticky;
		bottom: 0;
		background: inherit;
	}
}

/* A finger needs 44px. */
@media (pointer: coarse) {
	.hsc-who__step {
		width: 44px !important;
		height: 44px !important;
	}

	.hsc-capsule-pill {
		min-height: 44px;
	}
}

/* The theme's base sheets treat every [aria-live] element as an off-screen announcer (absolute, left
   -10000px, 1px, overflow hidden). The count is a live region that must be read on screen, so put it
   back in the flow. (Moved from the luxury search sheet's list of such regions.) */
.hsc-who .hsc-who__count {
	position: static;
	left: auto;
	width: auto;
	height: auto;
	overflow: visible;
}

@media (prefers-reduced-motion: reduce) {
	.hsc-capsule__field input,
	.hsc-capsule__field select {
		transition: none;
	}

	.hsc-capsule__go {
		transition: none;
	}

	.hsc-capsule__field,
	.hsc-capsule-pill {
		transition: none;
	}

	.hsc-who__panel,
	.hsc-featured-filters__panel {
		animation: none;
	}

	.hsc-who__step {
		transition: none;
	}

	.hsc-booking-calendar-picker--results .hsc-cal-flex__btn {
		transition: none;
	}

	/* As heavy as the rule that sets the fade, so it wins. */
	.hsc-booking-calendar-picker.hsc-booking-calendar-picker--results .hsc-cal-clear {
		transition: none;
	}
}
