/*
 * Coast & Range availability search bar – [cr_search_bar]
 *
 * Everything is scoped under .cr-search. Colours and fonts are custom
 * properties that follow the site's Elementor globals (Site Settings >
 * Global Colors / Fonts), with the design values as fallbacks for pages
 * where Elementor's variables are not defined (the demo pages):
 *
 *   --cr-cream  Primary (site background)   --e-global-color-primary
 *   --cr-sand   Alt. background             --e-global-color-e38b3fa
 *   --cr-ink    Text / backgrounds brown    --e-global-color-c9d9ea6
 *   --cr-olive  Text                        --e-global-color-text
 *   --cr-sky    Accent                      --e-global-color-accent
 *   --cr-font-body / --cr-font-caps         --e-global-typography-text-font-family
 *   (--cr-stone, --cr-muted and --cr-alert have no global equivalent.)
 *
 * From 1025px up the value text (the chosen / placeholder text under each
 * label), the Search label and the collapsed summary's values are
 * --cr-value-size-desktop (16px) / --cr-value-weight-desktop (700); the
 * small uppercase labels keep their size, tablet and mobile are unchanged.
 *
 * The defaults sit on :where(.cr-search) (zero specificity) so any rule the
 * site adds wins, whatever order the stylesheets load in, e.g. in
 * Elementor > Site Settings > Custom CSS: .cr-search { --cr-sky: #BFD6D8; }
 * or .cr-search { --cr-value-size-desktop: 17px; --cr-value-weight-desktop: 600; }
 *
 * The sticky offset below a fixed site header is --cr-sticky-top; set it
 * on :root (e.g. :root { --cr-sticky-top: 90px; }). When it is not set the
 * script measures a fixed/sticky header and sets it automatically.
 *
 * Google Fonts are NOT loaded here; the theme already provides them.
 */

:where(.cr-search) {
	--cr-cream: var(--e-global-color-primary, #F9F6ED);
	--cr-sand: var(--e-global-color-e38b3fa, #F0EADA);
	--cr-ink: var(--e-global-color-c9d9ea6, #443B27);
	--cr-olive: var(--e-global-color-text, #584E06);
	--cr-sky: var(--e-global-color-accent, #C1D8DB);
	--cr-sky-hover: #AECBCD;
	--cr-stone: #D9D2C0;
	--cr-muted: #B5AE9C;
	--cr-alert: #8A2D1B;
	--cr-font-body: var(--e-global-typography-text-font-family, 'Work Sans'), sans-serif;
	--cr-font-caps: var(--e-global-typography-text-font-family, 'Work Sans'), sans-serif;
	--cr-value-size-desktop: 16px;
	--cr-value-weight-desktop: 700;
	--cr-coral: #F57047;   /* the site's Book button colour (measured on staging; no Elementor global): the count line */
	--cr-body-size: 16px;  /* body text everywhere in the plugin (client feedback, Oct 11) */
	--cr-body-lh: 1.5;
	--cr-hit: 44px;        /* the smallest clickable control */
	--cr-z: 90;
}

/* ---------- base / resets (the theme and Elementor style buttons globally) ---------- */

.cr-search,
.cr-search *,
.cr-search *::before,
.cr-search *::after {
	box-sizing: border-box;
}

.cr-search {
	position: relative;
	z-index: var(--cr-z, 90);
	font-family: var(--cr-font-body);
	font-size: var(--cr-body-size, 16px);
	line-height: var(--cr-body-lh, 1.5);
	color: var(--cr-ink);
	-webkit-font-smoothing: antialiased;
}

/*
 * Hello Elementor's reset paints every hovered button magenta on white and removes its
 * underline (button:hover { background-color: #c36; color: #fff; text-decoration: none }),
 * and colours hovered links magenta. Every link and button in the bar names its own
 * background, border, colour and underline on :hover, :focus-visible and :active: this base
 * (and the button reset below) for the text controls, each boxed control for itself.
 */
.cr-search a,
.cr-search button {
	color: var(--cr-ink);
}

.cr-search a:hover,
.cr-search a:focus-visible,
.cr-search a:active,
.cr-search button:hover,
.cr-search button:focus-visible,
.cr-search button:active {
	background-color: transparent;
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search p,
.cr-search h3,
.cr-search h4,
.cr-search small,
.cr-search output {
	margin: 0;
	padding: 0;
}

.cr-search button {
	-webkit-appearance: none;
	appearance: none;
	display: inline-block;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	font: inherit;
	line-height: inherit;
	letter-spacing: inherit;
	text-transform: none;
	text-decoration: none;
	color: inherit;
	cursor: pointer;
	transition: none;
}

.cr-search button:hover,
.cr-search button:focus,
.cr-search button:focus-visible,
.cr-search button:active {
	color: inherit;
	background: none;
	border-color: var(--cr-ink);
	text-decoration: none;
	box-shadow: none;
	transform: none;
}

.cr-search :focus {
	outline: none;
}

.cr-search :focus-visible {
	outline: 2px solid var(--cr-olive);
	outline-offset: 2px;
}

.cr-search .cr-search__trigger:focus-visible,
.cr-search .cr-search__go:focus-visible,
.cr-search .cr-search__sum-cell:focus-visible,
.cr-search .cr-search__day:focus-visible {
	outline-offset: -3px;
}

.cr-search__caps {
	font-family: var(--cr-font-caps);
	font-size: 12px;
	font-weight: 500;
	letter-spacing: 1.5px;
	text-transform: uppercase;
}

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

.cr-search [hidden] {
	display: none !important;
}

/* ---------- the bar ---------- */

.cr-search__form {
	position: relative;
	margin: 0;
	background: var(--cr-cream);
	border: 1px solid var(--cr-ink);
}

.cr-search__bar {
	display: grid;
	grid-template-columns: 1.15fr 1.35fr 0.95fr 0.8fr auto;
}

.cr-search--explore .cr-search__bar {
	grid-template-columns: 1.1fr 1.3fr 0.9fr 0.85fr auto auto;
}

.cr-search__cell {
	position: relative;
	min-width: 0;
	border-right: 1px solid var(--cr-ink);
}

.cr-search .cr-search__trigger {
	display: block;
	width: 100%;
	min-height: 64px;
	padding: 12px 16px;
	text-align: left;
}

.cr-search--explore .cr-search__trigger {
	min-height: 56px;
	padding: 9px 16px;
}

.cr-search .cr-search__trigger[aria-expanded="true"] {
	background: var(--cr-sand);
}

.cr-search__label {
	display: block;
	font-family: var(--cr-font-caps);
	font-size: 11px;
	font-weight: 500;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--cr-olive);
}

.cr-search__cell.has-error .cr-search__label {
	color: var(--cr-alert);
}

.cr-search__value {
	display: block;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.cr-search__value.is-placeholder {
	color: var(--cr-muted);
}

.cr-search .cr-search__go {
	min-height: 64px;
	padding: 0 30px;
	background: var(--cr-sky);
	color: var(--cr-ink);
}

.cr-search--explore .cr-search__go {
	min-height: 56px;
	padding: 0 28px;
}

.cr-search .cr-search__go:hover,
.cr-search .cr-search__go:focus-visible,
.cr-search .cr-search__go:active {
	background-color: var(--cr-sky-hover);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

/* Error text sits below the cell so the bar itself never changes height. */
.cr-search__err {
	position: absolute;
	left: 16px;
	bottom: -26px;
	font-size: 13px;
	color: var(--cr-alert);
	white-space: nowrap;
}

.cr-search__err:empty {
	display: none;
}

/* ---------- popovers (absolute: opening one never shifts the layout) ---------- */

/* A bar with an open popover sits above neighbouring content (sticky bars included). */
.cr-search.is-open {
	z-index: calc(var(--cr-z, 90) + 1);
}

.cr-search__pop {
	position: absolute;
	top: calc(100% + 1px);
	left: -1px;
	z-index: 10;
	min-width: calc(100% + 2px);
	padding: 14px;
	background: var(--cr-cream);
	border: 1px solid var(--cr-ink);
	color: var(--cr-ink);
	font-size: var(--cr-body-size, 16px);
	text-align: left;
}

.cr-search__pop.is-flipped {
	left: auto;
	right: -1px;
}

.cr-search .cr-search__opt {
	display: block;
	width: 100%;
	min-height: var(--cr-hit, 44px);
	margin: 0 0 8px;
	padding: 10px 12px;
	border: 1px solid var(--cr-ink);
	text-align: left;
	white-space: nowrap;
}

.cr-search .cr-search__opt:last-child {
	margin-bottom: 0;
}

.cr-search .cr-search__opt:hover,
.cr-search .cr-search__opt:focus-visible,
.cr-search .cr-search__opt:active {
	background-color: var(--cr-sand);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search .cr-search__opt[aria-pressed="true"],
.cr-search .cr-search__opt[aria-pressed="true"]:hover,
.cr-search .cr-search__opt[aria-pressed="true"]:focus-visible,
.cr-search .cr-search__opt[aria-pressed="true"]:active {
	background-color: var(--cr-sky);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search__opt em {
	display: block;
	font-style: normal;
	font-size: 13px;
	color: var(--cr-olive);
}

.cr-search__hint {
	margin-top: 10px;
	font-size: var(--cr-body-size, 16px);
	color: var(--cr-olive);
}

/* guests stepper */
.cr-search__stepper {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}

.cr-search .cr-search__step {
	width: var(--cr-hit, 44px);
	height: var(--cr-hit, 44px);
	flex: none;
	border: 1px solid var(--cr-ink);
	background: var(--cr-cream);
	font-size: 18px;
	line-height: 1;
}

.cr-search .cr-search__step:hover,
.cr-search .cr-search__step:focus-visible,
.cr-search .cr-search__step:active {
	background-color: var(--cr-sand);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search .cr-search__step:disabled,
.cr-search .cr-search__step:disabled:hover {
	color: var(--cr-muted);
	border-color: var(--cr-muted);
	background: var(--cr-cream);
	cursor: default;
}

.cr-search__stepper output {
	display: inline-block;
	min-width: 24px;
	font-size: 18px;
	text-align: center;
}

/* pets */
.cr-search__pets {
	display: flex;
	gap: 8px;
}

.cr-search .cr-search__pets .cr-search__opt {
	margin: 0;
	text-align: center;
}

/* ---------- calendar ---------- */

/*
 * Sized from its content: two months of 7 × 44px days (320px each, 20px apart) plus the
 * padding, never narrower than the bar cell (.cr-search__pop's min-width) and never wider
 * than the viewport minus a gutter. Below 861px the mobile rules show one month across the
 * bar instead, so the two-month layout never has to shrink.
 */
.cr-search__pop--dates {
	width: max-content;
	max-width: calc(100vw - 24px);
}

.cr-search__cal-nav {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 8px;
	margin-bottom: 8px;
}

.cr-search .cr-search__cal-btn {
	width: var(--cr-hit, 44px);
	height: var(--cr-hit, 44px);
	flex: none;
	border: 1px solid var(--cr-ink);
	background: var(--cr-cream);
	font-size: 18px;
	line-height: 1;
}

.cr-search .cr-search__cal-btn:hover,
.cr-search .cr-search__cal-btn:focus-visible,
.cr-search .cr-search__cal-btn:active {
	background-color: var(--cr-sand);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search .cr-search__cal-btn:disabled,
.cr-search .cr-search__cal-btn:disabled:hover {
	color: var(--cr-muted);
	border-color: var(--cr-muted);
	background: var(--cr-cream);
	cursor: default;
}

.cr-search__cal-hint {
	text-align: center;
	color: var(--cr-ink);
}

.cr-search__months {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 20px;
}

.cr-search__month h4 {
	margin: 0 0 6px;
	text-align: center;
	color: var(--cr-ink);
}

.cr-search__grid {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	gap: 2px;
	text-align: center;
	font-size: 14px;
}

.cr-search__dow {
	padding: 4px 0;
	font-family: var(--cr-font-caps);
	font-size: 11px;
	font-weight: 500;
	color: var(--cr-ink);
}

.cr-search .cr-search__day {
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: var(--cr-hit, 44px);
	min-height: var(--cr-hit, 44px);
	padding: 0;
	border: 0;
	background: none;
	color: var(--cr-ink);
	line-height: 1.4;
}

.cr-search .cr-search__day:hover,
.cr-search .cr-search__day:focus-visible,
.cr-search .cr-search__day:active {
	background-color: var(--cr-sand);
	border-color: transparent;
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search .cr-search__day:disabled,
.cr-search .cr-search__day:disabled:hover {
	color: var(--cr-muted);
	background: none;
	cursor: default;
}

.cr-search .cr-search__day.is-in,
.cr-search .cr-search__day.is-in:hover,
.cr-search .cr-search__day.is-in:focus-visible,
.cr-search .cr-search__day.is-in:active {
	background-color: var(--cr-sky);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search .cr-search__day.is-edge,
.cr-search .cr-search__day.is-edge:hover,
.cr-search .cr-search__day.is-edge:focus-visible,
.cr-search .cr-search__day.is-edge:active {
	background-color: var(--cr-ink);
	color: var(--cr-cream);
	text-decoration: none;
}

.cr-search__pop-foot {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 10px;
	padding-top: 10px;
	border-top: 1px solid var(--cr-ink);
}

.cr-search .cr-search__link {
	display: inline-flex;
	align-items: center;
	min-height: var(--cr-hit, 44px);
	padding: 0 8px;
	color: var(--cr-ink);
	text-decoration: underline;
}

/* A text link: transparent on hover, underline kept (the theme rule removes it). */
.cr-search .cr-search__link:hover,
.cr-search .cr-search__link:focus-visible,
.cr-search .cr-search__link:active {
	background-color: transparent;
	border-color: transparent;
	color: var(--cr-olive);
	text-decoration: underline;
}

.cr-search .cr-search__done {
	display: inline-flex;
	align-items: center;
	min-height: var(--cr-hit, 44px);
	padding: 8px 18px;
	background: var(--cr-ink);
	color: var(--cr-cream);
}

.cr-search .cr-search__done:hover,
.cr-search .cr-search__done:focus-visible,
.cr-search .cr-search__done:active {
	background-color: var(--cr-olive);
	border-color: var(--cr-olive);
	color: var(--cr-cream);
	text-decoration: none;
}

/* ---------- explore mode: sticky bar, results count, collapsed summary ---------- */

.cr-search--explore {
	position: -webkit-sticky;
	position: sticky;
	top: var(--cr-sticky-top, 0px);
}

/*
 * Inside an Elementor shortcode widget the widget wrapper is exactly the
 * bar's height, so position: sticky on the bar alone could never stick.
 * Make the wrapper sticky too. The widget must sit in the same Elementor
 * container as the results grid, and no ancestor may clip overflow.
 */
.elementor-widget:has(> .elementor-widget-container > .cr-search--explore),
.elementor-widget:has(> .cr-search--explore) {
	position: -webkit-sticky;
	position: sticky;
	top: var(--cr-sticky-top, 0px);
	z-index: var(--cr-z, 90);
}

.cr-search--explore .cr-search__form {
	border-bottom-width: 2px;
}

/* ---------- filters button, tags row, panel (explore mode) ---------- */

.cr-search .cr-search__filters {
	display: flex;
	align-items: center;
	gap: 8px;
	min-height: 56px;
	padding: 0 18px;
	border-right: 1px solid var(--cr-ink);
	white-space: nowrap;
}

.cr-search .cr-search__filters:hover,
.cr-search .cr-search__filters:focus-visible,
.cr-search .cr-search__filters:active,
.cr-search .cr-search__filters[aria-expanded="true"] {
	background-color: var(--cr-sand);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search__filters svg {
	flex: none;
}

/*
 * Tags row under the bar: active-filter pills, "Clear all" and, at the end,
 * the results-count line (as in the mockup). Hidden by the script when it
 * has neither.
 */
.cr-search__tags {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	border-top: 1px solid var(--cr-ink);
}

.cr-search__taglist {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	padding: 6px 16px;
}

.cr-search__tag {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 3px 6px 3px 12px;
	border: 1px solid var(--cr-ink);
	border-radius: 999px;
	background: var(--cr-sky);
	font-size: 11px;
	letter-spacing: 1px;
	line-height: 1.5;
}

.cr-search .cr-search__tag-x {
	position: relative;
	padding: 0 4px;
	font-family: var(--cr-font-body);
	font-size: 15px;
	line-height: 1;
	letter-spacing: 0;
	text-transform: none;
}

/* The chip stays small; the × gets a 44 × 44 hit area around it. */
.cr-search .cr-search__tag-x::before {
	content: "";
	position: absolute;
	inset: -16px -14px;
}

.cr-search .cr-search__tag-x:hover,
.cr-search .cr-search__tag-x:focus-visible,
.cr-search .cr-search__tag-x:active {
	background-color: transparent;
	border-color: transparent;
	color: var(--cr-alert);
	text-decoration: none;
}

/* Same horizontal padding as the cells. The selector must outrank the `.cr-search p` reset above. */
/* The count line stands out: bold coral, 18px (16px on mobile). The same element carries "N homes open …" and the nothing-open count. */
.cr-search .cr-search__count {
	margin-left: auto;
	padding: 6px 16px;
	font-size: 18px;
	font-weight: 700;
	color: var(--cr-coral);
}

.cr-search__count:empty {
	display: none;
}

/* The panel overlays the page below the bar (absolute: nothing shifts when it opens). */
.cr-search__fpanel {
	position: absolute;
	left: 0;
	right: 0;
	top: 100%;
	z-index: 10;
	padding: 20px 16px 16px;
	background: var(--cr-cream);
	border: 1px solid var(--cr-ink);
	border-top: 0;
	border-bottom-width: 2px;
	color: var(--cr-ink);
	font-size: var(--cr-body-size, 16px);
	text-align: left;
}

.cr-search .cr-fpanel__title {
	margin: 0 0 10px;
	font-family: var(--cr-font-caps);
	font-size: 12px;
	font-weight: 500;
	line-height: 1.6;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--cr-olive);
}

.cr-fpanel__group + .cr-fpanel__group {
	margin-top: 20px;
}

.cr-fpanel__checks {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
	gap: 10px 16px;
}

.cr-search .cr-fpanel__check {
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: var(--cr-hit, 44px);
	margin: 0;
	font-weight: 400;
	cursor: pointer;
}

.cr-search .cr-fpanel__box {
	-webkit-appearance: none;
	appearance: none;
	display: grid;
	place-content: center;
	flex: none;
	width: 18px;
	height: 18px;
	margin: 0;
	border: 1px solid var(--cr-ink);
	border-radius: 0;
	background: var(--cr-cream);
	cursor: pointer;
}

.cr-search .cr-fpanel__box:checked {
	background: var(--cr-sky);
}

.cr-search .cr-fpanel__box:checked::after {
	content: "";
	width: 9px;
	height: 5px;
	border-left: 2px solid var(--cr-ink);
	border-bottom: 2px solid var(--cr-ink);
	transform: rotate(-45deg) translateY(-1px);
}

.cr-fpanel__foot {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 20px;
	padding-top: 14px;
	border-top: 1px solid var(--cr-ink);
}

.cr-search .cr-fpanel__show {
	display: inline-flex;
	align-items: center;
	min-height: var(--cr-hit, 44px);
	padding: 10px 22px;
	border: 1px solid var(--cr-ink);
	background: var(--cr-sky);
	color: var(--cr-ink);
}

.cr-search .cr-fpanel__show:hover,
.cr-search .cr-fpanel__show:focus-visible,
.cr-search .cr-fpanel__show:active {
	background-color: var(--cr-sky-hover);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

/*
 * Collapsed state. The full form keeps its box (visibility: hidden) so the
 * page below never jumps; the summary overlays its top edge and the rest
 * of the reserved area is transparent and click-through.
 */
.cr-search--explore.is-collapsed {
	pointer-events: none;
}

.cr-search--explore.is-collapsed .cr-search__form {
	visibility: hidden;
	pointer-events: none;
}

.cr-search__summary {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	display: grid;
	grid-template-columns: 1.2fr 1.3fr 0.9fr auto auto;
	background: var(--cr-cream);
	border: 1px solid var(--cr-ink);
	border-bottom-width: 2px;
	pointer-events: auto;
}

.cr-search__sum-cells,
.cr-search__sum-actions {
	display: contents;
}

.cr-search .cr-search__sum-filters {
	display: flex;
	align-items: center;
	padding: 0 16px;
	border-right: 1px solid var(--cr-ink);
	white-space: nowrap;
}

.cr-search .cr-search__sum-filters:hover,
.cr-search .cr-search__sum-filters:focus-visible,
.cr-search .cr-search__sum-filters:active {
	background-color: var(--cr-sand);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search .cr-search__sum-cell {
	display: block;
	min-width: 0;
	padding: 6px 16px;
	border-right: 1px solid var(--cr-ink);
	text-align: left;
	white-space: nowrap;
	overflow: hidden;
}

.cr-search .cr-search__sum-cell:hover,
.cr-search .cr-search__sum-cell:focus-visible,
.cr-search .cr-search__sum-cell:active {
	background-color: var(--cr-sand);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

.cr-search__sum-cell .cr-search__label {
	font-size: 11px;
	letter-spacing: 1px;
}

.cr-search__sum-value {
	display: block;
	font-size: var(--cr-body-size, 16px);
	overflow: hidden;
	text-overflow: ellipsis;
}

.cr-search .cr-search__sum-edit {
	display: flex;
	align-items: center;
	padding: 0 18px;
	background: var(--cr-sky);
	color: var(--cr-ink);
	font-weight: 500;
}

.cr-search .cr-search__sum-edit:hover,
.cr-search .cr-search__sum-edit:focus-visible,
.cr-search .cr-search__sum-edit:active {
	background-color: var(--cr-sky-hover);
	border-color: var(--cr-ink);
	color: var(--cr-ink);
	text-decoration: none;
}

/* ---------- desktop (1025px and up): larger, bold values ---------- */

/*
 * Value text, the Search label and the collapsed summary's values only; the
 * labels keep their size. line-height 1.5 gives the 16px text the same 24px
 * line box the 15px / 1.6 text had, so the bar does not change height.
 * `.cr-search .cr-search__go` outranks the `.cr-search button` reset above.
 */
@media (min-width: 1025px) {
	.cr-search__value,
	.cr-search__sum-value {
		font-size: var(--cr-value-size-desktop, 16px);
		font-weight: var(--cr-value-weight-desktop, 700);
		line-height: 1.5;
	}

	.cr-search .cr-search__go {
		font-size: var(--cr-value-size-desktop, 16px);
		font-weight: var(--cr-value-weight-desktop, 700);
	}
}

/* ---------- mobile ---------- */

@media (max-width: 860px) {
	.cr-search__bar,
	.cr-search--explore .cr-search__bar {
		grid-template-columns: 1fr 1fr;
	}

	.cr-search__cell {
		border-bottom: 1px solid var(--cr-ink);
	}

	.cr-search__cell--loc,
	.cr-search__cell--dates {
		grid-column: 1 / -1;
		border-right: 0;
	}

	.cr-search__cell--pets {
		border-right: 0;
	}

	.cr-search .cr-search__go {
		grid-column: 1 / -1;
		min-height: 52px;
		padding: 12px;
	}

	/* With a Filters button the two share the last row. */
	.cr-search .cr-search__filters {
		justify-content: center;
		min-height: 52px;
		padding: 12px;
	}

	.cr-search .cr-search__filters:not([hidden]) + .cr-search__go {
		grid-column: auto;
	}

	.cr-search__taglist {
		padding: 6px 12px;
	}

	.cr-search .cr-search__count {
		width: 100%;
		margin-left: 0;
		font-size: var(--cr-body-size, 16px);
	}

	/* Under the stuck bar only (viewport − header − bar) is reachable; --cr-bar-h is that offset when the map script measured it. */
	.cr-search__fpanel {
		max-height: max(200px, calc(100vh - var(--cr-bar-h, 320px) - 12px));
		overflow: auto;
		padding: 16px 12px 14px;
	}

	.cr-fpanel__checks {
		grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
	}

	.cr-search__err {
		position: static;
		display: block;
		padding: 0 16px 8px;
		white-space: normal;
	}

	.cr-search__pop--dates,
	.cr-search__pop--dates.is-flipped {
		left: -1px;
		right: -1px;
		width: auto;
		min-width: 0;
		max-width: none;
	}

	.cr-search__months {
		grid-template-columns: 1fr;
	}

	.cr-search__month--second {
		display: none;
	}

	/* collapsed summary: location, then "dates · guests" on one line, plus an Edit pill */
	.cr-search__summary {
		display: block;
		padding: 6px 12px 8px;
	}

	.cr-search__sum-cells {
		display: block;
		font-size: var(--cr-body-size, 16px);
		line-height: 1.5;
	}

	/* Inline, so the sentence flows; the vertical padding only widens the hit area to 44px. */
	.cr-search .cr-search__sum-cell {
		display: inline;
		padding: 11px 0;
		border: 0;
		white-space: normal;
		overflow: visible;
	}

	.cr-search .cr-search__sum-cell[data-edit="loc"] {
		display: block;
	}

	.cr-search .cr-search__sum-cell:hover,
	.cr-search .cr-search__sum-cell:focus-visible,
	.cr-search .cr-search__sum-cell:active {
		background-color: transparent;
		text-decoration: underline;
	}

	.cr-search .cr-search__sum-cell[data-edit="guests"]::before {
		content: "\00a0\00b7\00a0";
	}

	.cr-search__sum-cell .cr-search__label {
		display: none;
	}

	.cr-search__sum-value {
		display: inline;
	}

	/* "Edit" then "Filters · N" as pills on one line. */
	.cr-search__sum-actions {
		display: flex;
		flex-wrap: wrap;
		gap: 6px;
		margin-top: 6px;
	}

	.cr-search .cr-search__sum-edit,
	.cr-search .cr-search__sum-filters {
		display: inline-flex;
		align-items: center;
		min-height: var(--cr-hit, 44px);
		margin: 0;
		padding: 0 14px;
		border: 1px solid var(--cr-ink);
		border-radius: 999px;
		font-size: 11px;
		letter-spacing: 1px;
	}

	.cr-search .cr-search__sum-filters {
		order: 1;
		background: var(--cr-cream);
	}
}

@media (prefers-reduced-motion: no-preference) {
	.cr-search .cr-search__go,
	.cr-search .cr-search__opt,
	.cr-search .cr-search__day,
	.cr-search .cr-search__sum-edit,
	.cr-search .cr-search__filters,
	.cr-search .cr-fpanel__show {
		transition: background-color 0.12s ease;
	}
}
