/**
 * VEFmultiBooking — front-end styles of the booking widgets.
 *
 * Rules shared by all the widgets:
 * - The theme decides by default: no font-family, no heading size or
 *   weight imposed. A font set in the Style tab only applies through the
 *   `vefmb-has-font` body class (added by VEFMB_Style when a font is set).
 * - Form controls (button/input/select/textarea) never inherit fonts by
 *   themselves: they explicitly get `font: inherit`.
 * - Font sizes: the family scale below (fluid 360→1280px), theme preset
 *   first; body text has no size at all (theme or block setting decides).
 * - Text and borders derive from `currentColor` so they stay readable on
 *   light AND dark themes; only the accent (buttons, selected choices) and
 *   the error notice use a real color, both overridable.
 *
 * Layout rules (0.25.0):
 * - Flex everywhere (no fixed grid): parts wrap by themselves.
 * - Every value a webmaster may want to change is a `--vefmb-*` variable
 *   declared in :root below; nothing else is hard-coded in the rules.
 * - The block adapts to ITS OWN width (container queries), not to the
 *   window: a widget in a narrow column behaves like on a phone.
 * - Every variable can be overridden by the theme, by the Style tab
 *   (printed as inline CSS by VEFMB_Style / VEFMB_Block_Options) or, for a
 *   single block, by the settings of the page builder (inline on the root).
 */

:root {
	/* Font size scale — same six steps and values as the rest of the V-IMAGES
	   family: fluid between 360px (min) and 1280px (max), rem term kept so
	   browser zoom and the user's font size still apply. Each selector follows
	   the theme's preset first (--wp--preset--font-size--*), then this scale. */
	--vefmb-font-size-small: clamp(.75rem, .69rem + .26vw, .9rem);
	--vefmb-font-size-normal: clamp(.875rem, .79rem + .39vw, 1.1rem);
	--vefmb-font-size-medium: clamp(1rem, .88rem + .52vw, 1.3rem);
	--vefmb-font-size-large: clamp(1.2rem, 1.08rem + .52vw, 1.5rem);
	--vefmb-font-size-x-large: clamp(1.6rem, 1.4rem + .87vw, 2.1rem);
	--vefmb-font-size-xx-large: clamp(2rem, 1.61rem + 1.74vw, 3rem);

	/* No width limit by default: the modules fill the width the page builder gives them. */
	--vefmb-widget-max-width: none;

	/* Rhythm. The density factor (compact .7 / normal 1 / spacious 1.35) multiplies
	   the two base spacings; the derived --vefmb-space and --vefmb-gap are
	   worked out on each widget root (see below) so a per-block density works. */
	--vefmb-density: 1;
	--vefmb-space-base: clamp(.75rem, .554rem + .87vw, 1.25rem);
	--vefmb-gap-base: clamp(.5rem, .43rem + .3vw, .75rem);

	/* Shape. */
	--vefmb-widget-radius: .375rem;
	--vefmb-control-radius: .375rem;
	--vefmb-border-width: 1px;
	--vefmb-border: color-mix(in srgb, currentColor 22%, transparent);
	--vefmb-surface: color-mix(in srgb, currentColor 4%, transparent);
	--vefmb-surface-strong: color-mix(in srgb, currentColor 9%, transparent);

	/* Colors. */
	--vefmb-accent: #2271b1;
	--vefmb-button-text: #fff;
	--vefmb-on-accent: #fff;
	--vefmb-button-hover-brightness: 1.08;
	--vefmb-error: #d63638;
	--vefmb-success: #1a7f37;
	--vefmb-on-error: #fff;
	--vefmb-on-success: #fff;

	/* Glass panels (total, messages, confirmation): how much of the page shows through, and how blurred. */
	--vefmb-glass-alpha: .5;
	--vefmb-glass-blur: 18px;
	--vefmb-glyph-alert: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 3.6v5.2M8 12.2v.1' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
	--vefmb-glyph-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");

	/* Controls. */
	--vefmb-field-height: 2.75rem;
	--vefmb-focus-width: .1875rem;
	--vefmb-outline-offset: .125rem;
	--vefmb-step-size: 1.75rem;
	--vefmb-step-gap-line: .25rem;

	/* Date picker and steppers. */
	--vefmb-picker-width: 20rem;
	--vefmb-day-size: 2.5rem;
	--vefmb-stepper-btn: 2.5rem;
	--vefmb-stepper-input: 3rem;

	/* Shadows: geometry and color are separate so a color set on one block
	   works whatever geometry the site chose (see "box-shadow" uses below). */
	--vefmb-shadow-color: rgb(0 0 0 / .25);

	/* The three strengths a block can choose (geometry only: offset-x offset-y blur spread). */
	--vefmb-shadow-soft: 0 2px 8px 0;
	--vefmb-shadow-medium: 0 6px 20px 0;
	--vefmb-shadow-strong: 0 14px 40px 4px;
	--vefmb-shadow-block: 0 0 0 0;
	--vefmb-shadow-cards: 0 2px 8px 0;
	--vefmb-shadow-fields: 0 0 0 0;

	/* Cards and chips. */
	--vefmb-offers-cols: 4;
	--vefmb-card-min: 14rem;
	--vefmb-slot-min: 9rem;
	--vefmb-cal-gap: .25rem;

	/* Motion. */
	--vefmb-duration: .18s;
	--vefmb-ease: cubic-bezier(.4, 0, .2, 1);
}

/* --- Common roots ---------------------------------------------------------- */

.vefmb-widget,
.vefmb-offers-list,
.vefmb-cal,
.vefmb-confirmation {
	--vefmb-space: calc(var(--vefmb-space-base) * var(--vefmb-density));
	--vefmb-gap: calc(var(--vefmb-gap-base) * var(--vefmb-density));
	box-sizing: border-box;
}

.vefmb-widget *,
.vefmb-widget *::before,
.vefmb-widget *::after,
.vefmb-offers-list *,
.vefmb-cal *,
.vefmb-confirmation * {
	box-sizing: border-box;
}

.vefmb-has-font .vefmb-widget,
.vefmb-has-font .vefmb-offers-list,
.vefmb-has-font .vefmb-cal,
.vefmb-has-font .vefmb-confirmation {
	font-family: var(--vefmb-font-family, inherit);
}

/* A font chosen on the block itself (Gutenberg typography panel) wins over
   the global plugin font. */
.vefmb-has-font [class*="-font-family"] > .vefmb-widget,
.vefmb-has-font [class*="-font-family"] > .vefmb-offers-list,
.vefmb-has-font [class*="-font-family"] > .vefmb-cal,
.vefmb-has-font [class*="-font-family"] > .vefmb-confirmation {
	font-family: inherit;
}

/* With a plugin font set, headings follow it too (otherwise they keep the
   theme's heading font). */
.vefmb-has-font .vefmb-widget :is(h2, h3, h4, h5),
.vefmb-has-font .vefmb-offers-list :is(h2, h3, h4, h5),
.vefmb-has-font .vefmb-cal :is(h2, h3, h4, h5) {
	font-family: inherit;
}

/* Specificity 0 (:where): the controls inherit font and color, but any real rule of the plugin
   (a button's own text color, for one) always wins over this default. */
:where(.vefmb-widget, .vefmb-offers-list, .vefmb-cal) :where(button, input, select, textarea) {
	font: inherit;
	color: inherit;
}

/* Text color (block setting or Style tab): the block takes it, and the titles, labels and descriptions follow
   it even when the theme gives them a color of its own. The prices keep the accent color, the buttons their own. */
.vefmb-has-text-color {
	color: var(--vefmb-text);
}

.vefmb-has-text-color :is(h2, h3, h4, h5, h6, p, label, legend, li, dt, dd, small):not([class*="price"]) {
	color: var(--vefmb-text);
}

/* What is typed in the fields (and the choice shown in a drop-down) follows the text color too. */
.vefmb-has-text-color :is(input, select, textarea):not([type="checkbox"], [type="radio"]) {
	color: var(--vefmb-text);
}

.vefmb-has-text-color :is(input, textarea)::placeholder {
	color: color-mix(in srgb, var(--vefmb-text) 60%, transparent);
	opacity: 1;
}

/* Divi 5 wraps each module in a flex item with flex-grow:0: without an
   explicit width it shrinks to its content instead of filling its column. */
[class*="vefmb_divi_"] {
	width: 100%;
}

/* The hidden attribute must always win. Some themes (the Divi reset, for one) give <section>
   and other elements an explicit display, which overrides the browser's own rule for [hidden]
   and shows every step of the booking form at once. */
.vefmb-widget [hidden],
.vefmb-cal [hidden],
.vefmb-offers-list [hidden] {
	display: none !important;
}

/* --- Booking widget -------------------------------------------------------- */

.vefmb-widget {
	container: vefmb / inline-size;
	display: flex;
	flex-direction: column;
	gap: var(--vefmb-gap);
	width: 100%;
	max-width: var(--vefmb-widget-max-width);
	margin-inline: auto;
	padding: var(--vefmb-space);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-widget-radius);
	box-shadow: var(--vefmb-shadow-block, 0 0 0 0) var(--vefmb-shadow-color);
}

.alignwide > .vefmb-widget,
.alignfull > .vefmb-widget {
	max-width: none;
}

.vefmb-widget__header {
	display: flex;
	flex-direction: column;
	gap: .25em;
}

.vefmb-widget__title {
	margin: 0;
}

.vefmb-widget__description,
.vefmb-widget__resource-description {
	margin: 0;
	opacity: .8;
	/* Texts typed in a multi-line field: keep the line breaks the webmaster typed. */
	white-space: pre-line;
}

/* The descriptions of the booking step (the block setting puts them above or below the buttons). */
.vefmb-widget__about {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .5);
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
}

.vefmb-widget__about > [hidden],
.vefmb-widget__header > [hidden] {
	display: none;
}

/* Online booking closed by the webmaster: the message gets its own panel (background, border, corners), like the other notices, instead of floating on the page. */
.vefmb-widget--closed .vefmb-widget__closed-message {
	margin: 0;
	padding: var(--vefmb-space) calc(var(--vefmb-space) * 1.25);
	background: var(--vefmb-surface-strong);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-left: 4px solid var(--vefmb-accent);
	border-radius: var(--vefmb-control-radius);
	text-align: start;
}

.vefmb-widget__notice {
	display: flex;
	align-items: center;
	gap: .6em;
	margin: 0;
	padding: .7em 1em;
}

/* A step: its own flex column, so its parts are spaced by the gap, never by margins. */
.vefmb-widget__step {
	display: flex;
	flex-direction: column;
	gap: var(--vefmb-gap);
	min-width: 0;
}

.vefmb-widget__step > h4 {
	margin: 0;
}

.vefmb-widget__step > h4:focus {
	outline: none; /* Focus is moved here on a step change (screen readers); no ring on a heading. */
}

.vefmb-widget__loading {
	margin: 0;
	opacity: .75;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
}

.vefmb-widget__slots > p {
	flex: 1 1 100%;
	margin: 0;
}

/* --- Progress steps -------------------------------------------------------- */

.vefmb-steps {
	--vefmb-steps-gap: calc(var(--vefmb-gap) * .5);
	display: flex;
	align-items: flex-start;
	gap: var(--vefmb-steps-gap);
	margin: 0;
	padding: 0;
	list-style: none;
}

.vefmb-steps__item {
	position: relative;
	display: flex;
	flex: 1 1 0;
	flex-direction: column;
	align-items: center;
	gap: .35em;
	min-width: 0;
	text-align: center;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .6;
}

/* The line that joins a step to the next one: from the edge of the previous circle to the edge of
   this one, so it never shows through a (translucent) circle. */
.vefmb-steps__item + .vefmb-steps__item::before {
	content: "";
	position: absolute;
	top: calc(var(--vefmb-step-size) / 2);
	inset-inline-end: calc(50% + var(--vefmb-step-size) / 2 + var(--vefmb-step-gap-line));
	width: max(0px, calc(100% + var(--vefmb-steps-gap) - var(--vefmb-step-size) - 2 * var(--vefmb-step-gap-line)));
	height: var(--vefmb-border-width);
	background: var(--vefmb-border);
	z-index: 0;
}

.vefmb-steps__num {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	width: var(--vefmb-step-size);
	height: var(--vefmb-step-size);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: 50%;
	background: var(--vefmb-surface-strong);
	font-weight: 600;
	line-height: 1;
}

.vefmb-steps__label {
	max-width: 100%;
	overflow-wrap: anywhere;
}

.vefmb-steps__item--done,
.vefmb-steps__item--current {
	opacity: 1;
}

.vefmb-steps__item--done .vefmb-steps__num {
	border-color: var(--vefmb-accent);
	background: color-mix(in srgb, var(--vefmb-accent) 18%, transparent);
}

.vefmb-steps__item--current .vefmb-steps__num {
	border-color: var(--vefmb-accent);
	background: var(--vefmb-accent);
	color: var(--vefmb-on-accent);
}

.vefmb-steps__item--current .vefmb-steps__label {
	font-weight: 600;
}

.vefmb-steps__item--done + .vefmb-steps__item::before,
.vefmb-steps__item--current::before {
	background: var(--vefmb-accent);
}

/* Offers still to be chosen: nothing to show yet. */
.vefmb-widget[data-step="none"] .vefmb-steps {
	display: none;
}

/* --- Offers the visitor can tick (complete module) ------------------------- */

.vefmb-widget__offers {
	min-width: 0;
	margin: 0;
	padding: 0;
	border: 0;
}

.vefmb-widget__offers[hidden] {
	display: none;
}

/* An offer that belongs to the other list (see "Add another offer"): its card is flex, which would show it anyway. */
.vefmb-widget__offer[hidden] {
	display: none;
}

.vefmb-widget__offers legend {
	margin: 0 0 var(--vefmb-gap);
	padding: 0;
	font-size: var(--wp--preset--font-size--large, var(--vefmb-font-size-large));
	font-weight: 600;
	line-height: 1.25;
}

.vefmb-widget__offers-list {
	display: flex;
	flex-wrap: wrap;
	gap: var(--vefmb-gap);
}

.vefmb-widget__offer {
	position: relative;
	display: flex;
	flex: 1 1 100%;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: calc(var(--vefmb-gap) * .75);
	min-width: 0;
	padding: calc(var(--vefmb-space) * .75);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-widget-radius);
	background: var(--vefmb-surface);
	box-shadow: var(--vefmb-shadow-cards, 0 0 0 0) var(--vefmb-shadow-color);
	cursor: pointer;
	transition: border-color var(--vefmb-duration) var(--vefmb-ease), background-color var(--vefmb-duration) var(--vefmb-ease), transform var(--vefmb-duration) var(--vefmb-ease);
}

/* Cards: as many per row as the block allows, at least --vefmb-card-min wide. */
.vefmb-widget--offers-cards .vefmb-widget__offer {
	flex: 1 1 max(var(--vefmb-card-min), calc((100% - (var(--vefmb-offers-cols) - 1) * var(--vefmb-gap)) / var(--vefmb-offers-cols)));
}

.vefmb-widget__offer:hover {
	border-color: var(--vefmb-accent);
}

.vefmb-widget__offer:has(.vefmb-widget__offer-radio:focus-visible) {
	outline: var(--vefmb-focus-width) solid color-mix(in srgb, var(--vefmb-accent) 40%, transparent);
	outline-offset: var(--vefmb-outline-offset);
}

.vefmb-widget__offer--selected {
	border-color: var(--vefmb-accent);
	background: color-mix(in srgb, var(--vefmb-accent) 9%, transparent);
	box-shadow: var(--vefmb-shadow-cards, 0 0 0 0) var(--vefmb-shadow-color), inset 0 0 0 var(--vefmb-border-width) var(--vefmb-accent);
}

.vefmb-widget__offer-radio {
	flex: 0 0 auto;
	width: 1.5rem;
	height: 1.5rem;
	margin: .1em 0 0;
	accent-color: var(--vefmb-accent);
}

.vefmb-widget__offer-body {
	display: flex;
	flex: 1 1 8rem;
	flex-direction: column;
	gap: .2em;
	min-width: 0;
}

.vefmb-widget__offer-name {
	font-weight: 600;
}

.vefmb-widget__offer-description {
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .8;
}

.vefmb-widget__offer-price {
	flex: 0 0 auto;
	font-weight: 600;
	color: var(--vefmb-price, var(--vefmb-accent));
}

/* In a card the price sits at the bottom, on its own line. */
.vefmb-widget--offers-cards .vefmb-widget__offer-price {
	flex: 1 1 100%;
	align-self: flex-end;
	padding-top: calc(var(--vefmb-gap) * .6);
	border-top: var(--vefmb-border-width) dashed var(--vefmb-border);
}

/* Once an offer is chosen the cards shrink to a one-line choice (name and price): the offer can still
   be changed, but the form below stays in view. */
.vefmb-widget:not(.vefmb-widget--offers-select) .vefmb-widget__offers-select-field {
	display: none;
}

/* "Dropdown menu" layout: one select instead of the cards. The radios stay in the page (they carry the choice) but are hidden. */
.vefmb-widget--offers-select .vefmb-widget__offers-list {
	display: none;
}

.vefmb-widget--offers-select .vefmb-widget__offers-select-field {
	display: block;
}

.vefmb-widget__offers-select {
	width: 100%;
	max-width: 100%;
}

.vefmb-widget[data-catalog="1"]:not([data-step="none"]) .vefmb-widget__offers-list {
	gap: calc(var(--vefmb-gap) * .5);
}

.vefmb-widget[data-catalog="1"]:not([data-step="none"]) .vefmb-widget__offer {
	flex: 0 1 auto;
	align-items: center;
	padding: calc(var(--vefmb-space) * .35) calc(var(--vefmb-space) * .6);
	box-shadow: none;
}

.vefmb-widget[data-catalog="1"]:not([data-step="none"]) .vefmb-widget__offer-body {
	flex: 0 1 auto;
}

.vefmb-widget[data-catalog="1"]:not([data-step="none"]) .vefmb-widget__offer-description {
	display: none;
}

.vefmb-widget[data-catalog="1"]:not([data-step="none"]) .vefmb-widget__offer-price {
	flex: 0 0 auto;
	align-self: center;
	padding: 0;
	border: 0;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
}

/* --- Dates and times ------------------------------------------------------- */

.vefmb-widget__slots {
	display: flex;
	flex-wrap: wrap;
	gap: calc(var(--vefmb-gap) * .6);
}

.vefmb-widget__slot {
	display: flex;
	flex: 1 1 100%;
	align-items: center;
	min-height: var(--vefmb-field-height);
	padding: .55em 1em;
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: var(--vefmb-surface);
	text-align: start;
	cursor: pointer;
	transition: border-color var(--vefmb-duration) var(--vefmb-ease), background-color var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-widget--slots-grid .vefmb-widget__slot {
	flex: 1 1 var(--vefmb-slot-min);
	justify-content: center;
	text-align: center;
}

.vefmb-widget__slot:hover,
.vefmb-widget__slot:focus-visible {
	border-color: var(--vefmb-accent);
}

.vefmb-widget__slot:focus-visible {
	outline: var(--vefmb-focus-width) solid color-mix(in srgb, var(--vefmb-accent) 40%, transparent);
	outline-offset: var(--vefmb-outline-offset);
}

.vefmb-widget__slot--selected {
	border-color: var(--vefmb-accent);
	background: color-mix(in srgb, var(--vefmb-accent) 14%, transparent);
	font-weight: 600;
}

/* --- Date picker (a field that opens a month calendar) ---------------------- */

.vefmb-widget__datefield,
.vefmb-widget__times {
	display: flex;
	flex: 1 1 100%;
	flex-direction: column;
	gap: .35em;
	min-width: 0;
}

.vefmb-widget__fieldlabel {
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	font-weight: 600;
}

.vefmb-datepicker {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .5);
	width: min(100%, var(--vefmb-picker-width));
}

.vefmb-datepicker__field {
	display: flex;
	align-items: center;
	gap: .6em;
	width: 100%;
	min-height: var(--vefmb-field-height);
	padding: .5em .75em;
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: transparent;
	font-size: var(--wp--preset--font-size--normal, var(--vefmb-font-size-normal));
	text-align: start;
	cursor: pointer;
	box-shadow: var(--vefmb-shadow-fields, 0 0 0 0) var(--vefmb-shadow-color);
	transition: border-color var(--vefmb-duration) var(--vefmb-ease), box-shadow var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-datepicker__field:hover {
	border-color: color-mix(in srgb, currentColor 45%, transparent);
}

.vefmb-datepicker__field:focus-visible,
.vefmb-datepicker--open .vefmb-datepicker__field {
	outline: none;
	border-color: var(--vefmb-accent);
	box-shadow: var(--vefmb-shadow-fields, 0 0 0 0) var(--vefmb-shadow-color), 0 0 0 var(--vefmb-focus-width) color-mix(in srgb, var(--vefmb-accent) 35%, transparent);
}

.vefmb-datepicker__value {
	flex: 1 1 auto;
	min-width: 0;
	overflow-wrap: anywhere;
}

.vefmb-datepicker--empty .vefmb-datepicker__value {
	opacity: .6;
}

.vefmb-datepicker .vefmb-icon {
	flex: 0 0 auto;
	opacity: .75;
}

.vefmb-datepicker__chevron {
	transition: transform var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-datepicker--open .vefmb-datepicker__chevron {
	transform: rotate(180deg);
}

.vefmb-widget--fields-filled .vefmb-datepicker__field {
	border-color: transparent;
	background: var(--vefmb-surface-strong);
}

.vefmb-widget--fields-underlined .vefmb-datepicker__field {
	border-width: 0 0 calc(var(--vefmb-border-width) * 2);
	border-radius: 0;
	padding-inline: .25em;
}

/* The calendar opens under the field, in the page flow: a narrow column or a parent that clips
   its content never hides it. */
.vefmb-datepicker__panel {
	padding: calc(var(--vefmb-space) * .6);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-widget-radius);
	background: var(--vefmb-surface);
	box-shadow: var(--vefmb-shadow-cards, 0 0 0 0) var(--vefmb-shadow-color);
}

.vefmb-datepicker__nav {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--vefmb-gap);
	margin-bottom: calc(var(--vefmb-gap) * .5);
}

.vefmb-datepicker__month {
	flex: 1 1 auto;
	text-align: center;
	text-transform: capitalize;
	font-size: var(--wp--preset--font-size--normal, var(--vefmb-font-size-normal));
}

.vefmb-datepicker__navbtn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: var(--vefmb-day-size);
	height: var(--vefmb-day-size);
	padding: 0;
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: transparent;
	cursor: pointer;
}

.vefmb-datepicker__navbtn:hover:not(:disabled),
.vefmb-datepicker__navbtn:focus-visible {
	border-color: var(--vefmb-accent);
	outline: none;
}

.vefmb-datepicker__navbtn:disabled {
	opacity: .3;
	cursor: not-allowed;
}

/* Seven columns in flex: each cell is a seventh of the row (the gaps taken out). */
.vefmb-datepicker__grid {
	display: flex;
	flex-wrap: wrap;
	gap: var(--vefmb-cal-gap);
}

.vefmb-datepicker__weekday,
.vefmb-datepicker__blank,
.vefmb-datepicker__day {
	flex: 0 0 calc((100% - 6 * var(--vefmb-cal-gap)) / 7);
	min-width: 0;
}

.vefmb-datepicker__weekday {
	padding: .25em 0;
	text-align: center;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .65;
	text-transform: capitalize;
	overflow: hidden;
}

.vefmb-datepicker__day {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: var(--vefmb-day-size);
	padding: 0;
	border: var(--vefmb-border-width) solid transparent;
	border-radius: var(--vefmb-control-radius);
	background: transparent;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	cursor: default;
	transition: background-color var(--vefmb-duration) var(--vefmb-ease), border-color var(--vefmb-duration) var(--vefmb-ease);
}

/* A day that cannot be booked (closed, full, outside the opening periods) gets its own background, like the closed days of the availability calendar: grey fine stripes, not carried by color alone. */
.vefmb-datepicker__day:disabled {
	background:
		repeating-linear-gradient(135deg, color-mix(in srgb, #8c8f94 22%, transparent) 0 .3em, transparent .3em .6em),
		color-mix(in srgb, #8c8f94 14%, transparent);
	opacity: .55;
}

.vefmb-datepicker__day--available {
	background: color-mix(in srgb, var(--vefmb-accent) 12%, transparent);
	font-weight: 600;
	cursor: pointer;
}

.vefmb-datepicker__day--available:hover {
	background: color-mix(in srgb, var(--vefmb-accent) 26%, transparent);
}

.vefmb-datepicker__day:focus-visible {
	outline: var(--vefmb-focus-width) solid color-mix(in srgb, var(--vefmb-accent) 45%, transparent);
	outline-offset: 0;
}

/* Under the grid: a month being loaded, a month that failed to load, or a month with nothing to book. */
.vefmb-datepicker__status {
	margin: calc(var(--vefmb-gap) * .5) 0 0;
	text-align: center;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .75;
}

.vefmb-datepicker__panel[aria-busy="true"] .vefmb-datepicker__grid {
	opacity: .55;
}

.vefmb-datepicker__day--today {
	border-color: var(--vefmb-border);
}

.vefmb-datepicker__day--selected,
.vefmb-datepicker__day--selected:hover {
	background: var(--vefmb-accent);
	border-color: var(--vefmb-accent);
	color: var(--vefmb-on-accent);
}

/* The times of the chosen day: small chips, side by side. */
.vefmb-widget__timelist {
	display: flex;
	flex-wrap: wrap;
	gap: calc(var(--vefmb-gap) * .5);
}

.vefmb-widget__timelist .vefmb-widget__slot {
	flex: 0 1 auto;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: .1em;
	min-width: 5.5rem;
	padding: .4em .9em;
	text-align: center;
}

/* List layout: one time per row, rows side by side as soon as there is room, so the width is used. */
.vefmb-widget--slots-list .vefmb-widget__timelist {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr));
}

.vefmb-widget--slots-list .vefmb-widget__timelist .vefmb-widget__slot {
	flex: 1 1 100%;
	flex-direction: row;
	justify-content: space-between;
	text-align: start;
}

.vefmb-widget__slot-time {
	font-weight: 600;
}

.vefmb-widget__slot-note {
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	font-weight: 400;
	opacity: .75;
}

/* --- Number stepper ("− 2 +") ------------------------------------------------- */

.vefmb-stepper {
	display: inline-flex;
	align-items: stretch;
	align-self: flex-start;
	min-height: var(--vefmb-field-height);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: transparent;
	box-shadow: var(--vefmb-shadow-fields, 0 0 0 0) var(--vefmb-shadow-color);
	transition: border-color var(--vefmb-duration) var(--vefmb-ease), box-shadow var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-stepper:focus-within {
	border-color: var(--vefmb-accent);
	box-shadow: var(--vefmb-shadow-fields, 0 0 0 0) var(--vefmb-shadow-color), 0 0 0 var(--vefmb-focus-width) color-mix(in srgb, var(--vefmb-accent) 35%, transparent);
}

.vefmb-stepper:has(> input[hidden]) {
	display: none;
}

.vefmb-stepper__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: var(--vefmb-stepper-btn);
	padding: 0;
	border: 0;
	background: transparent;
	font-size: var(--wp--preset--font-size--medium, var(--vefmb-font-size-medium));
	line-height: 1;
	cursor: pointer;
	transition: background-color var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-stepper__btn:hover:not(:disabled) {
	background: color-mix(in srgb, var(--vefmb-accent) 14%, transparent);
}

.vefmb-stepper__btn:disabled {
	opacity: .3;
	cursor: not-allowed;
}

/* The input sits inside the stepper: no box of its own, centred, without the browser's spin arrows. */
.vefmb-stepper.vefmb-stepper > input {
	flex: 0 0 auto;
	width: var(--vefmb-stepper-input);
	min-height: 0;
	margin: 0;
	padding: 0 .1em;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	text-align: center;
	font-weight: 600;
	-moz-appearance: textfield;
	appearance: textfield;
}

.vefmb-stepper.vefmb-stepper > input:hover,
.vefmb-stepper.vefmb-stepper > input:focus {
	border: 0;
	box-shadow: none;
	outline: none;
}

.vefmb-stepper.vefmb-stepper > input::-webkit-inner-spin-button,
.vefmb-stepper.vefmb-stepper > input::-webkit-outer-spin-button {
	margin: 0;
	-webkit-appearance: none;
}

.vefmb-widget--fields-filled .vefmb-stepper {
	border-color: transparent;
	background: var(--vefmb-surface-strong);
}

.vefmb-widget--fields-underlined .vefmb-stepper {
	border-width: 0 0 calc(var(--vefmb-border-width) * 2);
	border-radius: 0;
}

/* What was chosen in the previous step, as a small line above the details. */
.vefmb-widget__recap {
	margin: 0;
	padding: calc(var(--vefmb-space) * .4) calc(var(--vefmb-space) * .75);
	border-radius: var(--vefmb-control-radius);
	background: var(--vefmb-surface);
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	font-weight: 600;
}

/* The cart: the offers already filled in, and the bar that reminds the visitor of them. */
.vefmb-widget__cart-lines {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .5);
	margin: 0;
	padding: 0;
	list-style: none;
}

.vefmb-widget__cart-line {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: calc(var(--vefmb-gap) * .5) var(--vefmb-gap);
	padding: calc(var(--vefmb-space) * .6) calc(var(--vefmb-space) * .75);
	border-radius: var(--vefmb-control-radius);
	background: var(--vefmb-surface);
}

.vefmb-widget__cart-line-text {
	display: flex;
	flex: 1 1 12rem;
	flex-direction: column;
	gap: .15em;
}

.vefmb-widget__cart-line-detail {
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .75;
}

.vefmb-widget__cart-line-amount {
	font-weight: 600;
}

.vefmb-widget .vefmb-widget__cart-remove {
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	font: inherit;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	text-decoration: underline;
	cursor: pointer;
	opacity: .75;
}

.vefmb-widget .vefmb-widget__cart-remove:hover,
.vefmb-widget .vefmb-widget__cart-remove:focus-visible {
	opacity: 1;
}

.vefmb-widget__cart-total {
	margin: 0;
	font-weight: 700;
	text-align: right;
}

.vefmb-widget__cart-bar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: calc(var(--vefmb-gap) * .5) var(--vefmb-gap);
	padding: calc(var(--vefmb-space) * .5) calc(var(--vefmb-space) * .75);
	border-radius: var(--vefmb-control-radius);
	background: var(--vefmb-surface);
	font-weight: 600;
}

.vefmb-widget__cart-bar[hidden],
.vefmb-widget__cart-total[hidden],
.vefmb-widget__cart-recap[hidden] {
	display: none;
}

.vefmb-widget__cart-recap {
	margin: 0;
	padding: calc(var(--vefmb-space) * .4) calc(var(--vefmb-space) * .75);
	border-radius: var(--vefmb-control-radius);
	background: var(--vefmb-surface);
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	font-weight: 600;
}

/* Nights and persons (and the "who is coming" list) share a line when they fit. */
.vefmb-widget__row.vefmb-widget__row--compact > .vefmb-widget__field {
	flex: 0 1 auto;
	min-width: 8rem;
	align-items: center;
}

.vefmb-widget__row.vefmb-widget__row--compact > .vefmb-widget__composition-field {
	flex: 1 1 14rem;
}

.vefmb-widget__optional {
	font-weight: 400;
	opacity: .65;
}

/* --- Form fields ----------------------------------------------------------- */

.vefmb-widget__row {
	display: flex;
	flex-wrap: wrap;
	gap: var(--vefmb-gap);
}

.vefmb-widget__row > .vefmb-widget__field {
	flex: 1 1 12rem;
}

.vefmb-widget__field {
	display: flex;
	flex-direction: column;
	gap: .35em;
	min-width: 0;
	margin: 0;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	font-weight: 600;
}

.vefmb-widget__field[hidden] {
	display: none;
}

.vefmb-widget__field :is(input:where(:not([type="radio"], [type="checkbox"])), select, textarea),
.vefmb-widget__option-qty,
.vefmb-widget__category-qty,
.vefmb-widget__unit-cat {
	display: block;
	width: 100%;
	min-height: var(--vefmb-field-height);
	padding: .5em .75em;
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: transparent;
	font-size: var(--wp--preset--font-size--normal, var(--vefmb-font-size-normal));
	font-weight: 400;
	box-shadow: var(--vefmb-shadow-fields, 0 0 0 0) var(--vefmb-shadow-color);
	transition: border-color var(--vefmb-duration) var(--vefmb-ease), box-shadow var(--vefmb-duration) var(--vefmb-ease), background-color var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-widget__field select {
	padding-inline-end: 2.25em;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%23888' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right .6em center;
	background-size: 1.1em;
	-moz-appearance: none;
	appearance: none;
}

.vefmb-widget__field :is(input:where(:not([type="radio"], [type="checkbox"])), select, textarea):hover,
.vefmb-widget__option-qty:hover,
.vefmb-widget__category-qty:hover,
.vefmb-widget__unit-cat:hover {
	border-color: color-mix(in srgb, currentColor 45%, transparent);
}

.vefmb-widget__field :is(input:where(:not([type="radio"], [type="checkbox"])), select, textarea):focus,
.vefmb-widget__option-qty:focus,
.vefmb-widget__category-qty:focus,
.vefmb-widget__unit-cat:focus {
	outline: none;
	border-color: var(--vefmb-accent);
	box-shadow: var(--vefmb-shadow-fields, 0 0 0 0) var(--vefmb-shadow-color), 0 0 0 var(--vefmb-focus-width) color-mix(in srgb, var(--vefmb-accent) 35%, transparent);
}

/* Field styles (setting "Field style"). */
.vefmb-widget--fields-filled .vefmb-widget__field :is(input:where(:not([type="radio"], [type="checkbox"])), select, textarea),
.vefmb-widget--fields-filled .vefmb-widget__option-qty,
.vefmb-widget--fields-filled .vefmb-widget__category-qty,
.vefmb-widget--fields-filled .vefmb-widget__unit-cat {
	border-color: transparent;
	background-color: var(--vefmb-surface-strong);
}

.vefmb-widget--fields-underlined .vefmb-widget__field :is(input:where(:not([type="radio"], [type="checkbox"])), select, textarea),
.vefmb-widget--fields-underlined .vefmb-widget__option-qty,
.vefmb-widget--fields-underlined .vefmb-widget__category-qty,
.vefmb-widget--fields-underlined .vefmb-widget__unit-cat {
	border-width: 0 0 calc(var(--vefmb-border-width) * 2);
	border-radius: 0;
	padding-inline: .25em;
}

/* A confirmation question is a box to tick, followed by its text (not a full-width field). */
.vefmb-widget__field--check {
	flex-direction: row;
	align-items: center;
	gap: .6em;
	font-size: inherit;
	font-weight: 400;
}

.vefmb-widget__field--check input[type="checkbox"] {
	flex: 0 0 auto;
	width: 1.75rem;
	min-height: 0;
	height: 1.75rem;
	margin: 0;
	padding: 0;
	accent-color: var(--vefmb-accent);
}

.vefmb-widget__categories-field {
	min-width: 0;
	margin: 0;
	padding: 0;
	border: 0;
}

.vefmb-widget__categories-field legend {
	padding: 0;
	margin-bottom: .4em;
	font-weight: 600;
}

.vefmb-widget__categories {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .6);
}

.vefmb-widget__questions {
	display: flex;
	flex-direction: column;
	gap: var(--vefmb-gap);
}

.vefmb-widget__questions:empty,
.vefmb-widget__questions[hidden] {
	display: none;
}

/* Who is coming, by price category (adult, student, child…). */
.vefmb-widget__category {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: calc(var(--vefmb-gap) * .75);
	padding: calc(var(--vefmb-space) * .5) calc(var(--vefmb-space) * .75);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: var(--vefmb-surface);
	font-weight: 400;
}

.vefmb-widget__category-name {
	flex: 1 1 8rem;
}

.vefmb-widget__category-qty,
.vefmb-widget__unit-cat {
	flex: 0 0 5rem;
	width: 5rem;
	text-align: center;
}

/* A category quantity in its stepper: the stepper takes the place, the input only its own width. */
.vefmb-widget__category > .vefmb-stepper,
.vefmb-widget__option > .vefmb-stepper {
	flex: 0 0 auto;
	align-self: center;
}

/* Optional extras (breakfast, equipment…): selectable rows. */
.vefmb-widget__options {
	display: flex;
	flex-wrap: wrap;
	gap: calc(var(--vefmb-gap) * .6);
}

.vefmb-widget__options:empty {
	display: none;
}

.vefmb-widget__option,
.vefmb-widget__room {
	display: flex;
	flex: 1 1 14rem;
	align-items: center;
	gap: .6em;
	min-width: 0;
	padding: calc(var(--vefmb-space) * .5) calc(var(--vefmb-space) * .75);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: var(--vefmb-surface);
	cursor: pointer;
	transition: border-color var(--vefmb-duration) var(--vefmb-ease), background-color var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-widget__option {
	min-height: 3.25rem;
}

.vefmb-widget__option:hover,
.vefmb-widget__option:has(:checked),
.vefmb-widget__room:hover,
.vefmb-widget__room:has(:checked) {
	border-color: var(--vefmb-accent);
}

.vefmb-widget__option:has(:checked),
.vefmb-widget__room:has(:checked) {
	background: color-mix(in srgb, var(--vefmb-accent) 9%, transparent);
}

/* --- Choice among the accommodations of one offer ---------------------------- */

.vefmb-widget__rooms {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .6);
}

.vefmb-widget__room {
	flex: 1 1 auto;
	align-items: flex-start;
}

.vefmb-widget__room-check {
	flex: 0 0 auto;
	width: 1.75rem;
	height: 1.75rem;
	margin: .1em 0 0;
	accent-color: var(--vefmb-accent);
}

/* "No preference": the name on the left, the counter on the right (it wraps under the text on a narrow screen). */
.vefmb-widget__room--any {
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	cursor: default;
}

.vefmb-widget__room--any .vefmb-stepper {
	flex: 0 0 auto;
}

.vefmb-widget__rooms-hint,
.vefmb-widget__rooms-summary {
	margin: 0 0 calc(var(--vefmb-gap) * .6);
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .8;
}

.vefmb-widget__rooms-summary {
	margin: calc(var(--vefmb-gap) * .6) 0 0;
	opacity: 1;
}

.vefmb-widget__rooms-hint[hidden],
.vefmb-widget__rooms-summary[hidden] {
	display: none;
}

.vefmb-widget__room-text {
	display: flex;
	flex: 1 1 8rem;
	flex-direction: column;
	gap: .2em;
	min-width: 0;
}

.vefmb-widget__room-description {
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .8;
}

/* Name of a product followed by how many persons it accepts. */
.vefmb-widget__room-title {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: .15em .6em;
}

.vefmb-widget__room-capacity {
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .8;
}

/* One line per product chosen: its own persons and nights, its dates and its price. */
.vefmb-widget__units {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .6);
	margin-top: calc(var(--vefmb-gap) * .6);
}

.vefmb-widget__units[hidden] {
	display: none;
}

.vefmb-widget__unit {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .5);
	padding: calc(var(--vefmb-space) * .75);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: color-mix(in srgb, var(--vefmb-accent) 5%, transparent);
}

.vefmb-widget__unit-head {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: .2em .8em;
}

.vefmb-widget__unit-price {
	font-weight: 600;
}

.vefmb-widget__unit-price:empty {
	display: none;
}

.vefmb-widget__unit-categories {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .4);
}

.vefmb-widget__unit-when {
	margin: 0;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .8;
}

.vefmb-widget__unit-when[hidden] {
	display: none;
}

.vefmb-widget__option > span {
	flex: 1 1 8rem;
}

.vefmb-widget__option-checkbox {
	flex: 0 0 auto;
	width: 1.75rem;
	height: 1.75rem;
	margin: 0;
	accent-color: var(--vefmb-accent);
}

.vefmb-widget__option-qty,
.vefmb-widget__option-persons {
	flex: 0 0 4.5rem;
	width: 4.5rem;
	text-align: center;
}

/* "persons" after the number of persons covered by an option. */
.vefmb-widget__option > .vefmb-widget__option-persons-text {
	flex: 0 0 auto;
}

.vefmb-widget__option-persons-text[hidden] {
	display: none;
}

/* The options of one line (room…): inside its card, under its fields. */
.vefmb-widget__unit-options {
	margin-top: calc(var(--vefmb-gap) * .6);
}

/* --- Promo code ------------------------------------------------------------ */

.vefmb-widget__promo[hidden] {
	display: none;
}

.vefmb-widget__promo-row {
	display: flex;
	flex-wrap: wrap;
	gap: calc(var(--vefmb-space) * .5);
}

.vefmb-widget__promo-row .vefmb-widget__promo-input {
	flex: 1 1 8rem;
	min-width: 0;
}

.vefmb-widget__promo-message {
	display: block;
	min-height: 1em;
	margin-top: calc(var(--vefmb-space) * .35);
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
}

.vefmb-widget__promo-message--error {
	color: var(--vefmb-error, currentColor);
	font-weight: 700;
}

/* --- Price, actions, buttons ----------------------------------------------- */

.vefmb-widget__price {
	margin: 0;
	padding: calc(var(--vefmb-space) * .6) var(--vefmb-space);
	font-weight: 700;
	font-size: var(--wp--preset--font-size--medium, var(--vefmb-font-size-medium));
	color: var(--vefmb-price, inherit);
}

.vefmb-widget__price:empty {
	display: none;
}

.vefmb-widget__payment-note {
	margin: 0;
}

.vefmb-widget__step-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: calc(var(--vefmb-gap) * .75);
}

.vefmb-widget__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: .5em;
	min-height: var(--vefmb-field-height);
	padding: .7em 1.4em;
	background: var(--vefmb-button-bg, var(--vefmb-accent));
	color: var(--vefmb-button-text);
	/* The border leans towards the text color: the button stays a visible button even when its color is the
	   color of the background it sits on (a brown button on a brown block, say). */
	border: var(--vefmb-border-width) solid color-mix(in srgb, var(--vefmb-button-text) 55%, var(--vefmb-button-bg, var(--vefmb-accent)));
	border-radius: var(--vefmb-control-radius);
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: filter var(--vefmb-duration) var(--vefmb-ease), background-color var(--vefmb-duration) var(--vefmb-ease), transform var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-widget__button:hover {
	background: var(--vefmb-button-hover, var(--vefmb-button-bg, var(--vefmb-accent)));
	border-color: color-mix(in srgb, var(--vefmb-button-text) 55%, var(--vefmb-button-hover, var(--vefmb-button-bg, var(--vefmb-accent))));
	filter: brightness(var(--vefmb-button-hover-brightness));
}

.vefmb-widget__button:focus-visible {
	outline: var(--vefmb-focus-width) solid color-mix(in srgb, var(--vefmb-accent) 45%, transparent);
	outline-offset: var(--vefmb-outline-offset);
	filter: brightness(var(--vefmb-button-hover-brightness));
}

.vefmb-widget__button:active {
	transform: translateY(1px);
}

.vefmb-widget__button:disabled,
.vefmb-widget__button[aria-disabled="true"] {
	opacity: .55;
	cursor: not-allowed;
	filter: none;
	transform: none;
}

/* Anchor used as a button (offers list): theme link colors must not win. */
a.vefmb-widget__button,
a.vefmb-widget__button:hover,
a.vefmb-widget__button:visited {
	color: var(--vefmb-button-text);
}

.vefmb-widget .vefmb-widget__button--secondary {
	background: transparent;
	color: inherit;
	border-color: var(--vefmb-border);
}

.vefmb-widget__confirmation-actions {
	display: flex;
	margin-top: var(--vefmb-gap);
}

.vefmb-widget__payment-methods {
	display: flex;
	flex-wrap: wrap;
	gap: calc(var(--vefmb-gap) * .75);
}

.vefmb-widget__paypal-mount {
	margin-top: 0;
}

/* --- Confirmation ---------------------------------------------------------- */

.vefmb-widget__confirmation-title {
	display: flex;
	align-items: center;
	gap: .6em;
}

/* A round check mark: a round badge of the success color holding a mask-drawn symbol (light or dark, as the color needs). */
.vefmb-widget__confirmation-title {
	position: relative;
}

.vefmb-widget__confirmation-title::before {
	content: "";
	flex: 0 0 auto;
	width: 1.6em;
	height: 1.6em;
	border-radius: 50%;
	background: var(--vefmb-success);
}

.vefmb-widget__confirmation-title::after {
	content: "";
	position: absolute;
	inset-inline-start: 0;
	inset-block-start: 50%;
	translate: 0 -50%;
	width: 1.6em;
	height: 1.6em;
	background: var(--vefmb-on-success);
	-webkit-mask: var(--vefmb-glyph-check) center / 66% no-repeat;
	mask: var(--vefmb-glyph-check) center / 66% no-repeat;
}

.vefmb-widget__confirmation-content {
	display: flex;
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .75);
}

.vefmb-widget__confirmation-content > p {
	margin: 0;
}

.vefmb-widget__confirmation-details {
	display: flex;
	flex-direction: column;
	margin: 0;
	padding: 0;
	list-style: none;
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	background: var(--vefmb-surface);
}

.vefmb-widget__confirmation-details > li {
	padding: calc(var(--vefmb-space) * .5) calc(var(--vefmb-space) * .75);
}

.vefmb-widget__confirmation-details > li + li {
	border-top: var(--vefmb-border-width) solid var(--vefmb-border);
}

/* --- Narrow blocks (the width of the BLOCK, not of the window) -------------- */

@container vefmb (max-width: 30rem) {
	.vefmb-steps__item:not(.vefmb-steps__item--current) .vefmb-steps__label {
		display: none;
	}

	.vefmb-widget__step-actions {
		flex-direction: column-reverse;
		align-items: stretch;
	}

	.vefmb-widget__step-actions .vefmb-widget__button {
		width: 100%;
	}

	.vefmb-widget__category {
		flex-direction: column;
		align-items: stretch;
	}

	.vefmb-widget__category-qty,
	.vefmb-widget__unit-cat {
		flex-basis: auto;
		width: 100%;
	}
}

/* --- Offers list (block "VEF Offers") --------------------------------------- */

.vefmb-offers-list {
	container: vefmboffers / inline-size;
	display: flex;
	flex-wrap: wrap;
	gap: var(--vefmb-gap);
	width: 100%;
	max-width: var(--vefmb-widget-max-width);
	margin-inline: auto;
}

.vefmb-offers-list__item {
	display: flex;
	flex: 1 1 max(var(--vefmb-card-min), calc((100% - (var(--vefmb-offers-cols) - 1) * var(--vefmb-gap)) / var(--vefmb-offers-cols)));
	flex-direction: column;
	gap: calc(var(--vefmb-gap) * .6);
	min-width: 0;
	padding: var(--vefmb-space);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-widget-radius);
	background: var(--vefmb-surface);
	box-shadow: var(--vefmb-shadow-cards, 0 0 0 0) var(--vefmb-shadow-color);
}

.vefmb-offers-list__name {
	margin: 0;
}

.vefmb-offers-list__description {
	margin: 0;
	opacity: .8;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
}

.vefmb-offers-list__price {
	margin: 0;
	font-weight: 600;
	font-size: var(--wp--preset--font-size--medium, var(--vefmb-font-size-medium));
	color: var(--vefmb-price, var(--vefmb-accent));
}

/* The button always sits at the bottom of its card, whatever the text above it. */
.vefmb-offers-list__item > .vefmb-widget__button {
	align-self: flex-start;
	margin-top: auto;
}

/* --- Availability calendar (block "VEF Availability") ------------------------ */

.vefmb-cal {
	container: vefmbcal / inline-size;
	/* Reached by its address (the arrows without JavaScript): the calendar stops below a fixed header, not under it. */
	scroll-margin-top: 5rem;
	display: flex;
	flex-direction: column;
	gap: var(--vefmb-gap);
	width: 100%;
	max-width: var(--vefmb-widget-max-width);
	margin-inline: auto;
	padding: var(--vefmb-space);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-widget-radius);
	box-shadow: var(--vefmb-shadow-block, 0 0 0 0) var(--vefmb-shadow-color);
}

.vefmb-cal__offers {
	display: flex;
	flex-wrap: wrap;
	gap: calc(var(--vefmb-gap) * .6);
	margin: 0;
}

.vefmb-cal__offer {
	padding: .4em 1em;
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	text-decoration: none;
	color: inherit;
	transition: border-color var(--vefmb-duration) var(--vefmb-ease), background-color var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-cal__offer:hover,
.vefmb-cal__offer:focus-visible {
	border-color: var(--vefmb-accent);
}

.vefmb-cal__offer--current {
	border-color: var(--vefmb-accent);
	background: color-mix(in srgb, var(--vefmb-accent) 12%, transparent);
	font-weight: 600;
}

.vefmb-cal__title {
	margin: 0;
}

.vefmb-cal__nav {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: calc(var(--vefmb-gap) * .6);
	margin: 0;
}

.vefmb-cal__prev,
.vefmb-cal__next {
	display: inline-flex;
	align-items: center;
	min-height: var(--vefmb-field-height);
	padding: .2em .9em;
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	border-radius: var(--vefmb-control-radius);
	text-decoration: none;
	color: inherit;
}

a.vefmb-cal__prev:hover,
a.vefmb-cal__next:hover,
a.vefmb-cal__prev:focus-visible,
a.vefmb-cal__next:focus-visible {
	border-color: var(--vefmb-accent);
}

.vefmb-cal__prev--off,
.vefmb-cal__next--off {
	opacity: .3;
}

/* Seven columns, in flex: every cell takes a seventh of the row (gaps removed). */
.vefmb-cal__grid {
	display: flex;
	flex-wrap: wrap;
	gap: var(--vefmb-cal-gap);
}

.vefmb-cal__head,
.vefmb-cal__day {
	flex: 0 0 calc((100% - 6 * var(--vefmb-cal-gap)) / 7);
	min-width: 0;
}

.vefmb-cal__head {
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	text-align: center;
	opacity: .7;
	padding: .2em 0;
}

.vefmb-cal__day {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-height: 3.2em;
	padding: .2em;
	border: var(--vefmb-border-width) solid transparent;
	border-radius: var(--vefmb-control-radius);
	text-decoration: none;
	color: inherit;
	line-height: 1.15;
	transition: background-color var(--vefmb-duration) var(--vefmb-ease), border-color var(--vefmb-duration) var(--vefmb-ease);
}

.vefmb-cal__day--blank {
	visibility: hidden;
}

.vefmb-cal__day--past,
.vefmb-cal__day--none {
	opacity: .35;
}

.vefmb-cal__day--available {
	background: color-mix(in srgb, var(--vefmb-accent) 14%, transparent);
	border-color: color-mix(in srgb, var(--vefmb-accent) 60%, transparent);
	font-weight: 600;
}

a.vefmb-cal__day--available:hover,
a.vefmb-cal__day--available:focus-visible {
	background: color-mix(in srgb, var(--vefmb-accent) 28%, transparent);
}

.vefmb-cal__day--full {
	background: color-mix(in srgb, #dba617 22%, transparent);
	border-color: color-mix(in srgb, #dba617 65%, transparent);
	opacity: .85;
}

.vefmb-cal__day--closed {
	/* Neutral grey with fine stripes: unmistakable next to the accent color of the available days, and not carried by color alone. */
	background:
		repeating-linear-gradient(135deg, color-mix(in srgb, #8c8f94 22%, transparent) 0 .35em, transparent .35em .7em),
		color-mix(in srgb, #8c8f94 26%, transparent);
	border-color: color-mix(in srgb, #8c8f94 60%, transparent);
	border-style: dashed;
	color: color-mix(in srgb, currentColor 60%, transparent);
}

.vefmb-cal__small {
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	font-weight: 400;
	text-decoration: none;
}

.vefmb-cal__legend {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: calc(var(--vefmb-gap) * .6) var(--vefmb-gap);
	margin: 0;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
}

.vefmb-cal__hint {
	margin: calc(var(--vefmb-gap) * .4) 0 0;
	font-size: var(--wp--preset--font-size--small, var(--vefmb-font-size-small));
	opacity: .75;
}

.vefmb-cal__key {
	display: inline-block;
	width: .9em;
	height: .9em;
	margin-inline-end: .3em;
	border-radius: .2em;
	vertical-align: middle;
}

.vefmb-cal__key--available {
	background: color-mix(in srgb, var(--vefmb-accent) 30%, transparent);
}

.vefmb-cal__key--full {
	background: color-mix(in srgb, #dba617 45%, transparent);
}

.vefmb-cal__key--closed {
	background:
		repeating-linear-gradient(135deg, color-mix(in srgb, #8c8f94 35%, transparent) 0 .2em, transparent .2em .4em),
		color-mix(in srgb, #8c8f94 40%, transparent);
}

/* A narrow calendar keeps the day numbers and drops the small texts under them. */
@container vefmbcal (max-width: 24rem) {
	.vefmb-cal__small {
		display: none;
	}

	.vefmb-cal__day {
		min-height: 2.4em;
	}
}

/* --- Confirmation summary (block "VEF Booking summary") ---------------------- */

.vefmb-confirmation {
	display: flex;
	flex-direction: column;
	gap: var(--vefmb-gap);
	width: 100%;
	max-width: var(--vefmb-widget-max-width);
	margin-inline: auto;
	padding: var(--vefmb-space);
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	container-type: inline-size;
	border-radius: var(--vefmb-widget-radius);
	box-shadow: var(--vefmb-shadow-block, 0 0 0 0) var(--vefmb-shadow-color);
}

/* Title of the standalone summary: a round check mark, like the one of the booking module. */
.vefmb-confirmation__title {
	display: flex;
	align-items: center;
	gap: .6em;
	margin: 0;
}

.vefmb-confirmation__title {
	position: relative;
}

.vefmb-confirmation__title::before {
	content: "";
	flex: 0 0 auto;
	width: 1.6em;
	height: 1.6em;
	border-radius: 50%;
	/* The badge has its own color (not the text color): the white check stays readable whatever color the theme gives the title. */
	background: var(--vefmb-success);
}

.vefmb-confirmation__title::after {
	content: "";
	position: absolute;
	inset-inline-start: 0;
	inset-block-start: 50%;
	translate: 0 -50%;
	width: 1.6em;
	height: 1.6em;
	background: var(--vefmb-on-success);
	-webkit-mask: var(--vefmb-glyph-check) center / 66% no-repeat;
	mask: var(--vefmb-glyph-check) center / 66% no-repeat;
}

/* --- Recap of a booking (end of the booking module and "VEF Booking summary") --- */

.vefmb-recap {
	display: flex;
	flex-direction: column;
	gap: var(--vefmb-gap);
}

.vefmb-recap > p {
	margin: 0;
}

.vefmb-recap__number {
	color: color-mix(in srgb, var(--vefmb-text, currentColor) 70%, transparent);
}

.vefmb-recap__number strong {
	color: var(--vefmb-text, inherit);
	letter-spacing: .02em;
}

/* What was booked: label on the left, value on the right (stacked on a narrow block). */
.vefmb-recap__facts {
	display: flex;
	flex-direction: column;
	margin: 0;
	border: var(--vefmb-border-width) solid var(--vefmb-border);
	/* Capped: a pill-shaped radius would clip the first and last rows. */
	border-radius: min(var(--vefmb-control-radius), 1.25rem);
	background: var(--vefmb-surface);
	overflow: hidden;
}

.vefmb-recap__facts > div {
	display: grid;
	grid-template-columns: minmax(6rem, 30%) 1fr;
	gap: .25em 1em;
	padding: calc(var(--vefmb-space) * .55) calc(var(--vefmb-space) * .8);
}

.vefmb-recap__facts > div + div {
	border-top: var(--vefmb-border-width) solid var(--vefmb-border);
}

.vefmb-recap__facts dt {
	margin: 0;
	opacity: .85;
}

.vefmb-recap__facts dd {
	margin: 0;
	font-weight: 600;
}

/* The price: one line per item, the total emphasised, the balance in the accent color. */
.vefmb-recap__lines {
	display: flex;
	flex-direction: column;
	margin: 0;
	padding: 0;
	list-style: none;
}

.vefmb-recap__lines > li {
	display: flex;
	justify-content: space-between;
	gap: 1em;
	padding: calc(var(--vefmb-space) * .4) calc(var(--vefmb-space) * .2);
}

.vefmb-recap__lines > li + li {
	border-top: var(--vefmb-border-width) dashed var(--vefmb-border);
}

.vefmb-recap__amount {
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
	text-align: end;
}

.vefmb-recap__lines > .vefmb-recap__total {
	border-top: var(--vefmb-border-width) solid var(--vefmb-border);
	font-weight: 700;
	font-size: 1.1em;
}

.vefmb-recap__lines > .vefmb-recap__balance {
	color: var(--vefmb-accent);
	font-weight: 600;
}

/* Short texts under the recap: what happens next. */
.vefmb-recap__note {
	padding: calc(var(--vefmb-space) * .5) calc(var(--vefmb-space) * .8);
	border-radius: min(var(--vefmb-control-radius), 1.25rem);
	background: color-mix(in srgb, var(--vefmb-accent) 8%, transparent);
}

@container (max-width: 30rem) {
	.vefmb-recap__facts > div {
		grid-template-columns: 1fr;
	}
}

/* --- Motion and accessibility ------------------------------------------------ */

/* Motion only for visitors who did not ask for less of it. */
@media (prefers-reduced-motion: no-preference) {
	.vefmb-widget__step:not([hidden]) {
		animation: vefmb-step-in .22s var(--vefmb-ease);
	}

	.vefmb-widget__loading:not(.vefmb-widget__editor-note)::before {
		content: "";
		display: inline-block;
		width: .9em;
		height: .9em;
		margin-inline-end: .5em;
		border: .14em solid color-mix(in srgb, currentColor 25%, transparent);
		border-top-color: var(--vefmb-accent);
		border-radius: 50%;
		vertical-align: -.1em;
		animation: vefmb-spin .8s linear infinite;
	}
}

@keyframes vefmb-step-in {
	from {
		opacity: 0;
		transform: translateY(.4rem);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

@keyframes vefmb-spin {
	to {
		transform: rotate(360deg);
	}
}

/* High-contrast modes drop colors: keep the selected choices visible. */
@media (forced-colors: active) {
	.vefmb-widget__offer--selected,
	.vefmb-widget__slot--selected,
	.vefmb-steps__item--current .vefmb-steps__num {
		outline: .125rem solid Highlight;
	}
}

/* Title alignment: only when the block or the Style tab sets one (class added by VEFMB_Block_Options::root_attributes()). */
.vefmb-has-title-align :is(.vefmb-widget__title, .vefmb-widget__step > h4, .vefmb-widget__confirmation-title, .vefmb-confirmation__title, .vefmb-offers-list__name, .vefmb-cal__title) {
	text-align: var(--vefmb-title-align, start);
}

.vefmb-widget__hint {
	display: block;
	margin-top: 4px;
	font-size: .85em;
	font-weight: 400;
	opacity: .75;
}

.vefmb-widget__hint[hidden] {
	display: none;
}


/* --- Glass panels ------------------------------------------------------------
   The total, the messages and the confirmation sit on a half-transparent, blurred panel: whatever the
   site shows behind (a colour, a picture, a pattern) stays visible, and the text stays readable. The
   tint is the opposite of the text colour (dark glass under light text, light glass under dark text).
   A message starts with a round badge of the text colour holding a red or green symbol. */

.vefmb-widget__notice,
.vefmb-widget__price,
.vefmb-confirmation {
	background: color-mix(in srgb, currentColor 8%, transparent);
	border: 1px solid color-mix(in srgb, currentColor 28%, transparent);
	border-radius: calc(var(--vefmb-control-radius) * 2.5);
	-webkit-backdrop-filter: blur(var(--vefmb-glass-blur)) saturate(1.2);
	backdrop-filter: blur(var(--vefmb-glass-blur)) saturate(1.2);
	box-shadow: 0 6px 20px rgb(0 0 0 / .12);
}

@supports (background: oklch(from red calc(1 - l) 0 0 / .5)) {
	.vefmb-widget__notice,
	.vefmb-widget__price,
	.vefmb-confirmation {
		background: oklch(from currentColor clamp(.06, calc(.06 + (.62 - l) * 20), .97) 0 0 / var(--vefmb-glass-alpha));
	}
}

.vefmb-widget__notice {
	position: relative;
	padding-inline-start: 3.2em;
	min-height: 2.6em;
}

.vefmb-widget__notice::before,
.vefmb-widget__notice::after {
	content: "";
	position: absolute;
	inset-inline-start: .9em;
	inset-block-start: 50%;
	translate: 0 -50%;
	width: 1.5em;
	height: 1.5em;
}

.vefmb-widget__notice::before {
	border-radius: 50%;
	/* Own color, not the text color: the white symbol stays readable on any theme. */
	background: var(--vefmb-error);
}

.vefmb-widget__notice::after {
	background: var(--vefmb-on-error);
	-webkit-mask: var(--vefmb-glyph-alert) center / 70% no-repeat;
	mask: var(--vefmb-glyph-alert) center / 70% no-repeat;
}

@media (forced-colors: active) {
	.vefmb-widget__confirmation-title::before,
	.vefmb-confirmation__title::before,
	.vefmb-widget__notice::before {
		background: CanvasText;
	}

	.vefmb-widget__confirmation-title::after,
	.vefmb-confirmation__title::after,
	.vefmb-widget__notice::after {
		background: Canvas;
	}

	.vefmb-widget__notice,
	.vefmb-widget__price,
	.vefmb-confirmation {
		background: Canvas;
		-webkit-backdrop-filter: none;
		backdrop-filter: none;
	}
}

/* Price of an offer: one line per case when the webmaster shows every price. */
.vefmb-price-line {
	display: block;
}

/* Category filter and sort menu above a list of offers. */
.vefmb-filter {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: var(--vefmb-gap, 0.75rem);
	margin: 0 0 var(--vefmb-gap, 0.75rem);
}

.vefmb-filter__chips {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.vefmb-filter__chip {
	min-height: 2.5rem;
	padding: 0.35rem 1rem;
	border: var(--vefmb-border-width, 1px) solid var(--vefmb-border, #d1d5db);
	border-radius: 999px;
	background: var(--vefmb-surface, #fff);
	color: inherit;
	font: inherit;
	font-size: var(--vefmb-font-size-small, 0.9rem);
	cursor: pointer;
}

.vefmb-filter__chip:hover,
.vefmb-filter__chip:focus-visible {
	border-color: var(--vefmb-accent, #2563eb);
}

.vefmb-filter__chip.is-active {
	border-color: var(--vefmb-accent, #2563eb);
	background: var(--vefmb-accent, #2563eb);
	color: #fff;
}

.vefmb-filter__sort {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	margin-left: auto;
	font-size: var(--vefmb-font-size-small, 0.9rem);
}

.vefmb-filter__sort select {
	min-height: 2.5rem;
	padding: 0.25rem 0.75rem;
	border: var(--vefmb-border-width, 1px) solid var(--vefmb-border, #d1d5db);
	border-radius: var(--vefmb-control-radius, 0.5rem);
	background: var(--vefmb-surface, #fff);
	color: inherit;
	font: inherit;
}

.vefmb-widget--offers-select .vefmb-filter {
	display: none;
}

.vefmb-filtered-out {
	display: none !important;
}
