/**
 * VAPOD'OR rental + signup UI — refined, editorial design system.
 * Matches the hotel dashboard: restrained palette, hairline borders, calm typography.
 * Set --vapod-accent to your brand colour to rebrand.
 */
.vapod-configurator,
.vapod-signup {
	/* Neutrals */
	--vapod-ink: #12161c;
	--vapod-text: #3b434c;
	--vapod-muted: #6b7480;
	--vapod-faint: #98a1ab;
	--vapod-line: #e9eaec;
	--vapod-line-2: #dfe1e4;
	--vapod-bg: #f6f6f4;
	--vapod-card: #ffffff;
	/* One restrained accent + a quiet wash of it */
	--vapod-accent: #0c6b60;
	--vapod-accent-hover: #0a564d;
	--vapod-accent-wash: rgba(12, 107, 96, 0.08);
	--vapod-danger: #b42318;
	/* Soft, refined error tone for inline validation — recognisable but never alarm-red as a fill. */
	--vapod-error-ink: #8a554c;
	--vapod-error-bg: #faf5f3;
	--vapod-error-border: #ecdcd6;
	/* Back-compat aliases (older inline references) */
	--vapod-accent-soft: var(--vapod-accent-wash);
	--vapod-border: var(--vapod-line);
	/* Radius */
	--vapod-radius: 12px;
	--vapod-radius-sm: 8px;
	--vapod-sh: 0 1px 2px rgba(18, 22, 28, 0.04);
	--vapod-sh-hover: 0 4px 14px rgba(18, 22, 28, 0.07);

	font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--vapod-text);
	font-size: 15px;
	line-height: 1.55;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
	font-feature-settings: "tnum" 1;
	box-sizing: border-box;
}

.vapod-configurator *,
.vapod-signup * {
	box-sizing: border-box;
}

/* ---------- Configurator grid ---------- */
.vapod-configurator {
	display: grid;
	grid-template-columns: repeat( auto-fill, minmax( 290px, 1fr ) );
	gap: 20px;
}

/* ---------- Product card ---------- */
.vapod-product {
	display: flex;
	flex-direction: column;
	background: var(--vapod-card);
	border: 1px solid var(--vapod-line);
	border-radius: var(--vapod-radius);
	overflow: hidden;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.vapod-product:hover {
	border-color: var(--vapod-line-2);
	box-shadow: var(--vapod-sh-hover);
}

.vapod-product.is-soldout {
	opacity: 0.7;
}

.vapod-product__media {
	aspect-ratio: 16 / 10;
	overflow: hidden;
	background: var(--vapod-bg);
	border-bottom: 1px solid var(--vapod-line);
}

.vapod-product__media img,
.vapod-product__img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.vapod-product__body {
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 20px;
}

.vapod-product__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 10px;
}

.vapod-product__title {
	margin: 0;
	font-size: 1.1rem;
	font-weight: 640;
	line-height: 1.3;
	letter-spacing: -0.01em;
	color: var(--vapod-ink);
}

.vapod-product__desc {
	color: var(--vapod-muted);
	font-size: 0.9rem;
	line-height: 1.5;
	margin: -4px 0 0;
}

.vapod-product__desc p {
	margin: 0;
}

/* Availability badge — quiet chip with a dot, not a candy pill */
.vapod-badge {
	flex: none;
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-size: 0.74rem;
	font-weight: 600;
	padding: 4px 10px 4px 8px;
	border-radius: 7px;
	border: 1px solid var(--vapod-line-2);
	color: var(--vapod-muted);
	background: var(--vapod-card);
	white-space: nowrap;
}

.vapod-badge::before {
	content: "";
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: currentColor;
}

.vapod-badge--ok {
	color: var(--vapod-accent);
	border-color: rgba(12, 107, 96, 0.25);
}

.vapod-badge--out {
	color: var(--vapod-faint);
}

/* Price */
.vapod-product__price {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 6px;
}

.vapod-product__amount {
	font-size: 1.5rem;
	font-weight: 680;
	letter-spacing: -0.02em;
	color: var(--vapod-ink);
	font-variant-numeric: tabular-nums;
}

.vapod-product__amount .amount,
.vapod-total__amount .amount {
	font-weight: inherit;
}

.vapod-product__per {
	color: var(--vapod-muted);
	font-size: 0.9rem;
}

/* Catalog tile: "Mehr erfahren" — pinned to the bottom so cards align */
.vapod-product__media {
	display: block;
}

.vapod-product__more {
	margin-top: auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	font-size: 0.92rem;
	font-weight: 600;
	text-decoration: none;
	color: var(--vapod-ink);
	background: #fff;
	border: 1px solid var(--vapod-line-2);
	border-radius: var(--vapod-radius-sm);
	padding: 11px 16px;
	transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.vapod-product__more::after {
	content: "→";
	font-weight: 500;
	transition: transform 0.15s ease;
}

.vapod-product__more:hover {
	background: var(--vapod-bg);
	color: var(--vapod-accent);
	border-color: var(--vapod-line-2);
}

.vapod-product__more:hover::after {
	transform: translateX( 2px );
}

/* ---------- Product detail page ---------- */
.vapod-configurator--detail {
	display: block;
}

.vapod-detail__back {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-bottom: 18px;
	font-size: 0.9rem;
	font-weight: 550;
	text-decoration: none;
	color: var(--vapod-muted);
	transition: color 0.15s ease;
}

.vapod-detail__back:hover {
	color: var(--vapod-accent);
}

.vapod-detail {
	display: grid;
	grid-template-columns: minmax( 0, 1fr ) minmax( 0, 1fr );
	gap: 0;
	background: var(--vapod-card);
	border: 1px solid var(--vapod-line);
	border-radius: var(--vapod-radius);
	overflow: hidden;
}

.vapod-detail__media {
	background: var(--vapod-bg);
	min-height: 320px;
	border-right: 1px solid var(--vapod-line);
}

.vapod-detail__media img,
.vapod-detail__img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.vapod-detail__body {
	display: flex;
	flex-direction: column;
	gap: 16px;
	padding: 28px;
}

.vapod-detail__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
}

.vapod-detail__title {
	margin: 0;
	font-size: 1.5rem;
	font-weight: 680;
	line-height: 1.2;
	letter-spacing: -0.02em;
	color: var(--vapod-ink);
}

.vapod-detail__desc {
	color: var(--vapod-text);
	font-size: 0.95rem;
	line-height: 1.6;
}

.vapod-detail__desc p {
	margin: 0 0 10px;
}

.vapod-detail__desc :last-child {
	margin-bottom: 0;
}

.vapod-field__hint {
	margin: 2px 0 0;
	font-size: 0.8rem;
	color: var(--vapod-faint);
}

@media ( max-width: 720px ) {
	.vapod-detail {
		grid-template-columns: 1fr;
	}
	.vapod-detail__media {
		min-height: 0;
		aspect-ratio: 16 / 10;
		border-right: 0;
		border-bottom: 1px solid var(--vapod-line);
	}
}

/* ---------- Checkout: room number ---------- */
.vapod-checkout-room {
	margin: 24px 0;
	padding: 20px 22px;
	background: var(--vapod-card);
	border: 1px solid var(--vapod-line);
	border-radius: var(--vapod-radius);
}

.vapod-checkout-room h3 {
	margin: 0 0 4px;
	font-size: 1rem;
	font-weight: 640;
	letter-spacing: -0.01em;
	color: var(--vapod-ink);
}

.vapod-checkout-room__hint {
	margin: 0 0 14px;
	color: var(--vapod-muted);
	font-size: 0.9rem;
}

/* Fields */
.vapod-field {
	display: flex;
	flex-direction: column;
	gap: 7px;
}

.vapod-field__label {
	font-size: 0.78rem;
	font-weight: 600;
	letter-spacing: 0.01em;
	color: var(--vapod-muted);
}

.vapod-input,
.vapod-stepper__input {
	font: inherit;
	color: var(--vapod-ink);
	border: 1px solid var(--vapod-line-2);
	border-radius: var(--vapod-radius-sm);
	padding: 10px 12px;
	background: #fff;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.vapod-input:focus,
.vapod-stepper__input:focus,
.vapod-rent-button:focus-visible,
.vapod-stepper__btn:focus-visible {
	outline: none;
	border-color: var(--vapod-accent);
	box-shadow: 0 0 0 3px var(--vapod-accent-wash);
}

/* Stepper */
.vapod-stepper {
	display: inline-flex;
	align-items: stretch;
	border: 1px solid var(--vapod-line-2);
	border-radius: var(--vapod-radius-sm);
	overflow: hidden;
	width: fit-content;
	background: #fff;
}

.vapod-stepper__btn {
	border: 0;
	background: #fff;
	color: var(--vapod-muted);
	width: 40px;
	font-size: 1.1rem;
	line-height: 1;
	cursor: pointer;
	transition: background 0.12s ease, color 0.12s ease;
}

.vapod-stepper__btn:hover:not(:disabled) {
	background: var(--vapod-bg);
	color: var(--vapod-ink);
}

.vapod-stepper__btn:disabled {
	opacity: 0.4;
	cursor: not-allowed;
}

.vapod-stepper__input {
	width: 60px;
	text-align: center;
	border: 0;
	border-left: 1px solid var(--vapod-line);
	border-right: 1px solid var(--vapod-line);
	border-radius: 0;
	font-weight: 640;
	-moz-appearance: textfield;
	appearance: textfield;
}

.vapod-stepper__input::-webkit-outer-spin-button,
.vapod-stepper__input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.vapod-stepper__input:focus {
	box-shadow: none;
}

/* Segmented control */
.vapod-segment {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: 1fr;
	gap: 3px;
	padding: 3px;
	background: var(--vapod-bg);
	border: 1px solid var(--vapod-line);
	border-radius: var(--vapod-radius-sm);
}

.vapod-segment__opt {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	padding: 8px;
	font-size: 0.86rem;
	font-weight: 550;
	border-radius: 6px;
	cursor: pointer;
	color: var(--vapod-muted);
	transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.vapod-segment__opt input {
	position: absolute;
	opacity: 0;
	inset: 0;
	margin: 0;
	cursor: pointer;
}

.vapod-segment__opt:has( input:checked ) {
	background: #fff;
	color: var(--vapod-ink);
	box-shadow: var(--vapod-sh);
}

/* Fallback for browsers without :has() */
.vapod-segment__opt input:checked ~ span {
	color: var(--vapod-ink);
}

/* Required field asterisk — discreet brand accent, not alarm-red */
.vapod-required {
	color: var(--vapod-accent);
	font-weight: 600;
}

/* Total */
.vapod-total {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	padding-top: 14px;
	border-top: 1px solid var(--vapod-line);
}

.vapod-total__label {
	font-size: 0.86rem;
	color: var(--vapod-muted);
	font-weight: 600;
}

.vapod-total__amount {
	font-size: 1.3rem;
	font-weight: 680;
	letter-spacing: -0.02em;
	color: var(--vapod-ink);
	font-variant-numeric: tabular-nums;
}

/* Live per-unit breakdown under the total */
.vapod-total__calc {
	margin: 0;
	font-size: 0.78rem;
	color: var(--vapod-faint);
	font-variant-numeric: tabular-nums;
	min-height: 1em;
}

/* CTA button */
.vapod-rent-button,
.vapod-signup-button {
	font: inherit;
	font-size: 0.95rem;
	font-weight: 600;
	color: #fff;
	background: var(--vapod-accent);
	border: 1px solid var(--vapod-accent);
	border-radius: var(--vapod-radius-sm);
	padding: 12px 18px;
	cursor: pointer;
	transition: background 0.15s ease, border-color 0.15s ease, transform 0.04s ease;
	width: 100%;
}

.vapod-rent-button:hover:not(:disabled),
.vapod-signup-button:hover:not(:disabled) {
	background: var(--vapod-accent-hover);
	border-color: var(--vapod-accent-hover);
}

.vapod-rent-button:active:not(:disabled),
.vapod-signup-button:active:not(:disabled) {
	transform: translateY( 1px );
}

.vapod-rent-button:disabled,
.vapod-signup-button:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.vapod-rent-button.is-loading,
.vapod-signup-button.is-loading {
	color: transparent;
	position: relative;
}

.vapod-rent-button.is-loading::after,
.vapod-signup-button.is-loading::after {
	content: "";
	position: absolute;
	width: 16px;
	height: 16px;
	top: calc( 50% - 8px );
	left: calc( 50% - 8px );
	border: 2px solid rgba( 255, 255, 255, 0.5 );
	border-top-color: #fff;
	border-radius: 50%;
	animation: vapod-spin 0.6s linear infinite;
}

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

/* Result message */
.vapod-result {
	min-height: 1.1em;
	margin: 0;
	font-size: 0.86rem;
	text-align: center;
}

.vapod-result.is-error {
	color: var(--vapod-error-ink);
}

.vapod-result.is-loading {
	color: var(--vapod-muted);
}

.vapod-error {
	padding: 14px 16px;
	border-radius: var(--vapod-radius-sm);
	background: var(--vapod-error-bg);
	color: var(--vapod-error-ink);
	border: 1px solid var(--vapod-error-border);
	font-size: 0.92rem;
}

/* Discreet hint shown instead of the configurator's own picker when the intro switch is present. */
.vapod-config-note {
	margin: 0;
	padding: 18px 16px;
	text-align: center;
	color: var(--vapod-muted);
	font-size: 0.95rem;
	line-height: 1.5;
}

/* Fallback hotel picker (no ?ref= / ?hotel=) */
.vapod-configurator--picker {
	display: block;
}

.vapod-hotel-picker {
	max-width: 520px;
	margin: 0 auto;
	padding: 24px;
	background: var(--vapod-card);
	border: 1px solid var(--vapod-line);
	border-radius: var(--vapod-radius);
}

.vapod-hotel-picker__hint {
	margin: 0 0 16px;
	color: var(--vapod-muted);
	font-size: 0.95rem;
	line-height: 1.5;
}

.vapod-hotel-picker__form {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.vapod-hotel-picker__form .vapod-input {
	width: 100%;
}

.vapod-hotel-picker__form .vapod-rent-button {
	width: auto;
	align-self: flex-start;
}

/* ---------- Hotel signup form ---------- */
.vapod-signup {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
	max-width: 640px;
	padding: 28px;
	background: var(--vapod-card);
	border: 1px solid var(--vapod-line);
	border-radius: var(--vapod-radius);
}

.vapod-signup .vapod-field {
	gap: 6px;
}

.vapod-signup .vapod-field input,
.vapod-signup .vapod-field select {
	font: inherit;
	width: 100%;
	color: var(--vapod-ink);
	padding: 11px 13px;
	border: 1px solid var(--vapod-line-2);
	border-radius: var(--vapod-radius-sm);
	background: #fff;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.vapod-signup .vapod-field input:focus,
.vapod-signup .vapod-field select:focus {
	outline: none;
	border-color: var(--vapod-accent);
	box-shadow: 0 0 0 3px var(--vapod-accent-wash);
}

.vapod-signup .vapod-field span {
	font-size: 0.78rem;
	font-weight: 600;
	color: var(--vapod-muted);
}

/* Full-width rows: name, button, result */
.vapod-signup .vapod-field--full,
.vapod-signup-button,
.vapod-signup-result {
	grid-column: 1 / -1;
}

.vapod-signup-result {
	min-height: 1.1em;
	margin: 0;
	font-size: 0.9rem;
	text-align: center;
}

.vapod-signup-result.is-error {
	color: var(--vapod-error-ink);
}

.vapod-signup-result.is-success {
	color: var(--vapod-accent);
	font-weight: 600;
}

.vapod-signup-result.is-loading {
	color: var(--vapod-muted);
}

@media ( max-width: 540px ) {
	.vapod-signup {
		grid-template-columns: 1fr;
		padding: 20px;
	}
}

/* ---------- Mobile touch targets (≥44 px per HIG / WCAG 2.5.5) ---------- */
@media ( max-width: 768px ) {
	.vapod-stepper__btn {
		min-height: 44px;
		width: 44px;
	}

	.vapod-stepper__input {
		min-height: 44px;
	}

	.vapod-segment__opt {
		min-height: 44px;
		padding: 11px 12px;
	}

	.vapod-rent-button,
	.vapod-signup-button {
		min-height: 44px;
		padding: 13px 18px;
	}

	.vapod-input,
	.vapod-room {
		min-height: 44px;
		padding: 11px 12px;
	}

	.vapod-detail__body {
		padding: 20px;
	}
}

/* Billing address fields hidden for pure rental checkouts (Aufgabe B, §33 UStDV). */
.vapod-checkout-hidden {
	display: none !important;
}

.vapod-product__gross {
	display: block;
	flex-basis: 100%;
	margin-top: 2px;
	font-size: 11px;
	font-weight: 500;
	letter-spacing: .03em;
	text-transform: uppercase;
	color: var(--vapod-muted);
}

.vapod-total__gross {
	margin: -4px 0 8px;
	font-size: 12px;
	color: var(--vapod-muted);
}

/* ---------- Theme reset guard ----------
 * Some themes ship an aggressive reset that paints buttons magenta, e.g.
 *   button, [type=button], [type=submit] { color:#cc3366 }
 *   button:hover, button:focus, [type=button]:hover/:focus, [type=submit]:hover/:focus
 *     { color:#cc3366; background:#cc3366 }
 * The [type=…] attribute selectors tie our class selectors, so the theme can win on the tie /
 * unknown load order — for BOTH colour and background. We therefore pin colour + background for the
 * base and every interactive state of our buttons with !important. Colours/states only — no layout
 * change; the focus ring and the loading spinner's transparent label are preserved. */

/* CTA buttons: white text on accent, base + all states. */
.vapod-rent-button,
.vapod-signup-button { color: #fff !important; }
.vapod-rent-button.is-loading,
.vapod-signup-button.is-loading { color: transparent !important; } /* keep the spinner's hidden label */
.vapod-rent-button:not(:disabled):hover,
.vapod-rent-button:not(:disabled):focus,
.vapod-rent-button:not(:disabled):focus-visible,
.vapod-rent-button:not(:disabled):active,
.vapod-signup-button:not(:disabled):hover,
.vapod-signup-button:not(:disabled):focus,
.vapod-signup-button:not(:disabled):focus-visible,
.vapod-signup-button:not(:disabled):active {
	background: var(--vapod-accent-hover) !important;
	border-color: var(--vapod-accent-hover);
	color: #fff !important;
}
.vapod-rent-button:disabled:hover,
.vapod-rent-button:disabled:focus,
.vapod-signup-button:disabled:hover,
.vapod-signup-button:disabled:focus {
	background: var(--vapod-accent) !important;
	border-color: var(--vapod-accent);
}
.vapod-rent-button:focus-visible,
.vapod-signup-button:focus-visible {
	outline: none;
	box-shadow: 0 0 0 3px var(--vapod-accent-wash);
}

/* Stepper +/- buttons: muted glyph at rest, ink on hover/focus; light wash background. */
.vapod-stepper__btn { color: var(--vapod-muted) !important; }
.vapod-stepper__btn:hover:not(:disabled),
.vapod-stepper__btn:focus:not(:disabled),
.vapod-stepper__btn:focus-visible:not(:disabled),
.vapod-stepper__btn:active:not(:disabled) {
	background: var(--vapod-bg) !important;
	color: var(--vapod-ink) !important;
}
.vapod-stepper__btn:disabled:hover,
.vapod-stepper__btn:disabled:focus {
	background: #fff !important;
}

/* Segment toggle (.vapod-segment__opt) is a <label> wrapping a radio — it is not matched by the
 * theme's button/[type=button]/[type=submit] selectors, so its own colours already win; pinned here
 * defensively for the rare theme that also resets labels. */
.vapod-segment__opt { color: var(--vapod-muted) !important; }
.vapod-segment__opt:has( input:checked ),
.vapod-segment__opt input:checked ~ span { color: var(--vapod-ink) !important; }
