/**
 * Little Lotus Reservierungen – Formulare
 *
 * Übernimmt Farben/Schriften aus dem Theme (theme.json-Presets), mit Fallbacks
 * für andere Themes. Touch-Ziele ≥ 44 px, sichtbarer Fokus, Kontraste ≥ 4.5:1.
 */

.llr {
	--llr-accent: var(--wp--preset--color--olive, #5E6B45);
	--llr-accent-dark: var(--wp--preset--color--olive-dark, #4C5838);
	--llr-ink: var(--wp--preset--color--ink, #2E2A25);
	--llr-sub: var(--wp--preset--color--sub, #6B6458);
	--llr-field: var(--wp--preset--color--field, #8F877A);
	--llr-line: var(--wp--preset--color--line, #E4DED3);
	--llr-error: var(--wp--preset--color--error, #A23B32);
	--llr-bg: var(--wp--preset--color--white, #FFFFFF);
	--llr-ground: var(--wp--preset--color--ground, #FAF8F4);
	--llr-soft: var(--wp--preset--color--sage, #E9EDE0);
	--llr-wood: var(--wp--preset--color--wood, #EFE6D8);
	--llr-linen: var(--wp--preset--color--linen, #F3F1EA);
	--llr-muted: #F4F1EC;
	--llr-radius: 12px;
	--llr-font: var(--wp--preset--font-family--body, inherit);
	--llr-display: var(--wp--preset--font-family--display, inherit);
	color: var(--llr-ink);
	font-family: var(--llr-font);
	font-size: 1rem;
	line-height: 1.6;
}

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

.llr [hidden] {
	display: none !important;
}

/* Ohne JavaScript: Schritt-Elemente ausblenden; mit JavaScript: Fallbacks ausblenden */
.llr:not(.is-enhanced) [data-llr-js-only] {
	display: none !important;
}

.llr.is-enhanced [data-llr-nojs-only] {
	display: none !important;
}

.llr-sr {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.llr-hp {
	position: absolute !important;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.llr :focus-visible {
	outline: 2px solid var(--llr-accent);
	outline-offset: 2px;
}

/* -------------------------------------------------------------------------
   Layout
   ---------------------------------------------------------------------- */

.llr--table {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(260px, 340px);
	gap: clamp(24px, 4vw, 48px);
	align-items: start;
}

.llr--table.is-preview,
.llr--table .llr--table {
	display: block;
}

.llr__main {
	min-width: 0;
	background: var(--llr-bg);
	border-radius: 24px;
	padding: clamp(20px, 3.5vw, 40px);
}

.llr--editor .llr__main {
	padding: 0;
	background: none;
}

.llr__aside {
	display: grid;
	gap: 16px;
	position: sticky;
	top: calc(var(--ll-header-h, 76px) + 16px);
}

.llr__aside > * {
	margin: 0 !important;
}

@media (max-width: 900px) {
	.llr--table {
		grid-template-columns: minmax(0, 1fr);
	}

	.llr__aside {
		position: static;
	}
}

.llr-form--cols {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
	gap: 0 clamp(24px, 4vw, 48px);
}

.llr-col > * + * {
	margin-top: 18px;
}

.llr-grid-2 {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	gap: 16px;
}

@media (max-width: 640px) {
	.llr-col + .llr-col {
		margin-top: 18px;
	}
}

/* -------------------------------------------------------------------------
   Schritte
   ---------------------------------------------------------------------- */

.llr-steps {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 8px;
	list-style: none;
	margin: 0 0 28px;
	padding: 0;
	counter-reset: none;
}

.llr-steps li {
	padding: 12px 14px;
	border-radius: 12px;
	background: var(--llr-wood);
	color: #5C564C;
	font-weight: 700;
	line-height: 1.3;
	font-size: .9375rem;
}

.llr-steps li.is-done {
	background: var(--llr-soft);
	color: var(--llr-ink);
}

.llr-steps li[aria-current="step"] {
	background: var(--llr-accent);
	color: #FFFFFF;
}

.llr-steps__n {
	display: block;
	font-size: .75rem;
	font-weight: 500;
	letter-spacing: .04em;
	opacity: .9;
}

@media (max-width: 480px) {
	.llr-steps li {
		padding: 10px;
		font-size: .875rem;
	}
}

.llr-step + .llr-step {
	margin-top: 32px;
}

.llr.is-enhanced .llr-step + .llr-step {
	margin-top: 0;
}

.llr-step > * + * {
	margin-top: 18px;
}

.llr-step__title {
	font-family: var(--llr-display);
	font-weight: 500;
	font-size: 1.5rem;
	line-height: 1.4;
	margin: 0;
}

.llr-step__heading:focus {
	outline: none;
}

/* -------------------------------------------------------------------------
   Felder
   ---------------------------------------------------------------------- */

.llr-fieldset {
	border: 0;
	margin: 0 0 26px;
	padding: 0;
	min-width: 0;
}

.llr-legend {
	font-family: var(--llr-display);
	font-size: 1.1875rem;
	font-weight: 500;
	margin: 0 0 6px;
	padding: 0;
}

.llr-label {
	display: block;
	font-size: .9375rem;
	font-weight: 500;
	margin: 0 0 6px;
	color: var(--llr-ink);
}

.llr-optional {
	font-weight: 400;
	color: var(--llr-sub);
}

.llr-field + .llr-field {
	margin-top: 18px;
}

.llr-input {
	display: block;
	width: 100%;
	min-height: 50px;
	padding: 12px 14px;
	border: 1px solid var(--llr-field);
	border-radius: var(--llr-radius);
	background: var(--llr-bg);
	color: var(--llr-ink);
	font: inherit;
	font-size: 16px; /* verhindert Zoom auf iOS */
	line-height: 1.4;
	appearance: none;
	-webkit-appearance: none;
}

select.llr-input {
	padding-right: 40px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%232E2A25' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 14px center;
}

textarea.llr-input {
	min-height: 96px;
	resize: vertical;
}

.llr-input:focus {
	outline: 2px solid var(--llr-accent);
	outline-offset: 1px;
	border-color: var(--llr-accent);
}

.llr-input[aria-invalid="true"],
.has-error .llr-input,
.has-error .llr-stepper {
	border-color: var(--llr-error);
	border-width: 2px;
}

.llr-hint {
	margin: 6px 0 0;
	font-size: .8125rem;
	color: var(--llr-sub);
}

.llr-fieldset > .llr-hint:first-of-type {
	margin: 0 0 12px;
}

.llr-error {
	margin: 6px 0 0;
	font-size: .875rem;
	font-weight: 600;
	color: var(--llr-error);
}

.llr-error::before {
	content: "! ";
}

.llr-required-note {
	margin: 0 0 18px;
	font-size: .8125rem;
	color: var(--llr-sub);
}

.llr-privacy {
	font-size: .8125rem;
	color: var(--llr-sub);
	margin: 18px 0 0;
}

.llr-privacy a {
	color: var(--llr-ink);
}

.llr-note {
	margin: 14px 0 0;
	padding: 12px 16px;
	border-radius: 12px;
	background: var(--llr-linen);
	font-size: .9375rem;
}

.llr-note--warn {
	background: #FBE9E6;
	color: #7A2B24;
	font-weight: 500;
}

/* Checkboxen */
.llr-checks {
	display: grid;
	gap: 10px;
}

.llr-check {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	min-height: 44px;
	padding-top: 10px;
	font-size: .9375rem;
	cursor: pointer;
}

.llr-check input {
	flex: none;
	width: 22px;
	height: 22px;
	margin: 1px 0 0;
	accent-color: var(--llr-accent);
	cursor: pointer;
}

/* Zähler */
.llr-stepper {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px;
	border: 1px solid var(--llr-field);
	border-radius: 999px;
	background: var(--llr-bg);
}

.llr-stepper__btn {
	width: 44px;
	height: 44px;
	border-radius: 50%;
	border: 1px solid var(--llr-line);
	background: var(--llr-ground);
	color: var(--llr-ink);
	font-size: 1.375rem;
	line-height: 1;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background .2s, border-color .2s;
}

.llr-stepper__btn:hover:not(:disabled) {
	border-color: var(--llr-accent);
	color: var(--llr-accent);
}

.llr-stepper__btn:disabled {
	opacity: .4;
	cursor: not-allowed;
}

.llr-stepper__input {
	width: 3.2em;
	min-height: 44px;
	border: 0;
	background: transparent;
	text-align: center;
	font: inherit;
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--llr-ink);
	-moz-appearance: textfield;
}

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

/* Tage */
.llr-days {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 16px;
}

.llr-day {
	min-width: 84px;
	min-height: 44px;
	padding: 8px 12px;
	border: 1.5px solid var(--llr-line);
	border-radius: 14px;
	background: var(--llr-bg);
	color: var(--llr-ink);
	font: 600 1rem/1.25 var(--llr-font);
	text-align: center;
	cursor: pointer;
	display: flex;
	flex-direction: column;
	align-items: center;
	transition: border-color .2s, background .2s;
}

.llr-day:hover {
	border-color: var(--llr-accent);
}

.llr-day__dm {
	font-weight: 400;
	font-size: .875rem;
}

.llr-day__note {
	font-weight: 500;
	font-size: .75rem;
	min-height: 1em;
}

.llr-day.is-closed {
	background: var(--llr-muted);
	color: #5C564C;
	border-style: dashed;
}

.llr-day[aria-pressed="true"] {
	background: var(--llr-accent);
	border-color: var(--llr-accent);
	color: #FFFFFF;
}

.llr-day[aria-pressed="true"].is-closed {
	background: #7A6F62;
	border-color: #7A6F62;
}

.llr-field--date .llr-input {
	max-width: 260px;
}

/* Zeitfenster & Chips (echte Radio-Buttons) */
.llr-slots {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
	gap: 8px;
}

.llr-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.llr-slot,
.llr-chip {
	position: relative;
	display: block;
	cursor: pointer;
}

.llr-slot__input,
.llr-chip__input {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
}

.llr-slot__label,
.llr-chip__label {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 8px 12px;
	border: 1.5px solid var(--llr-line);
	border-radius: 14px;
	background: var(--llr-bg);
	font-weight: 600;
	text-align: center;
	line-height: 1.2;
	transition: border-color .2s, background .2s, color .2s;
}

.llr-chip__label {
	border-radius: 999px;
	border-color: var(--llr-field);
	padding: 0 16px;
	font-weight: 500;
	font-size: .9375rem;
}

.llr-slot__note {
	font-size: .6875rem;
	font-weight: 500;
	margin-top: 2px;
}

.llr-slot:hover .llr-slot__label,
.llr-chip:hover .llr-chip__label {
	border-color: var(--llr-accent);
}

.llr-slot__input:checked + .llr-slot__label,
.llr-chip__input:checked + .llr-chip__label {
	background: var(--llr-accent);
	border-color: var(--llr-accent);
	color: #FFFFFF;
}

.llr-slot__input:focus-visible + .llr-slot__label,
.llr-chip__input:focus-visible + .llr-chip__label {
	outline: 2px solid var(--llr-accent);
	outline-offset: 2px;
}

.llr-slot.is-full,
.llr-slot.is-past {
	cursor: not-allowed;
}

.llr-slot.is-full .llr-slot__label,
.llr-slot.is-past .llr-slot__label {
	background: var(--llr-muted);
	color: #5C564C;
	border-style: dashed;
}

.llr-slot.is-full .llr-slot__time {
	text-decoration: line-through;
	text-decoration-thickness: 1px;
}

.llr-status:not(:empty) {
	margin-top: 12px;
	font-size: .9375rem;
	color: var(--llr-sub);
}

.llr-status.is-full {
	padding: 14px 16px;
	border-radius: 12px;
	background: var(--llr-linen);
	color: var(--llr-ink);
}

.llr-status.is-full strong {
	display: block;
}

.llr-slots[aria-busy="true"] {
	opacity: .5;
}

/* -------------------------------------------------------------------------
   Buttons & Aktionen
   ---------------------------------------------------------------------- */

.llr-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: 52px;
	padding: 0 28px;
	border-radius: 999px;
	border: 1px solid transparent;
	font: 500 .9375rem/1.2 var(--llr-font);
	letter-spacing: .02em;
	text-decoration: none;
	cursor: pointer;
	transition: background .2s, color .2s, border-color .2s;
}

.llr-btn--primary {
	background: var(--llr-accent);
	color: #FFFFFF;
}

.llr-btn--primary:hover,
.llr-btn--primary:focus-visible {
	background: var(--llr-accent-dark);
	color: #FFFFFF;
}

.llr-btn--line {
	background: var(--llr-bg);
	color: var(--llr-ink);
	border-color: #CFC8BA;
}

.llr-btn--line:hover {
	border-color: var(--llr-accent);
	color: var(--llr-accent);
}

.llr-btn:disabled {
	opacity: .65;
	cursor: progress;
}

.llr-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: 12px 16px;
	margin-top: 28px;
	padding-top: 20px;
	border-top: 1px solid var(--llr-line);
}

.llr-actions__alt {
	margin: 0 auto 0 0;
	font-size: .9375rem;
	color: var(--llr-sub);
}

.llr-actions__alt a {
	color: var(--llr-ink);
}

.llr-actions--center {
	justify-content: center;
	border-top: 0;
	padding-top: 0;
}

.llr-form--cols .llr-btn--primary {
	margin-top: 22px;
}

@media (max-width: 480px) {
	.llr-actions .llr-btn {
		flex: 1 1 100%;
	}

	.llr-actions__alt {
		flex: 1 1 100%;
		text-align: center;
	}
}

/* -------------------------------------------------------------------------
   Übersicht, Hinweise, Erfolg
   ---------------------------------------------------------------------- */

.llr-review {
	margin: 0;
	border-top: 1px solid var(--llr-line);
}

.llr-review > div {
	display: grid;
	grid-template-columns: minmax(110px, 160px) 1fr;
	gap: 12px;
	padding: 14px 0;
	border-bottom: 1px solid var(--llr-line);
}

.llr-review dt {
	color: var(--llr-sub);
	font-size: .875rem;
}

.llr-review dd {
	margin: 0;
	font-weight: 500;
}

.llr-review--compact {
	max-width: 520px;
	margin: 20px auto 0;
	text-align: left;
}

@media (max-width: 480px) {
	.llr-review > div {
		grid-template-columns: 1fr;
		gap: 2px;
	}
}

.llr-info-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
	gap: 12px;
}

.llr-info {
	padding: 18px;
	border-radius: 16px;
	background: var(--llr-linen);
	font-size: .875rem;
}

.llr-info h3 {
	margin: 0 0 4px;
	font-family: var(--llr-display);
	font-weight: 500;
	font-size: 1rem;
}

.llr-info p {
	margin: 0;
	color: var(--llr-sub);
}

.llr-alert {
	margin: 18px 0 0;
	padding: 14px 18px;
	border-radius: 12px;
	border-left: 4px solid var(--llr-error);
	background: #FBE9E6;
	color: #5E1F19;
	font-size: .9375rem;
}

.llr-alert ul {
	margin: 8px 0 0;
	padding-left: 20px;
}

.llr-alert a {
	color: inherit;
}

.llr-alert--success {
	border-left-color: var(--llr-accent);
	background: var(--llr-soft);
	color: var(--llr-ink);
	margin: 0 0 20px;
}

.llr-success {
	text-align: center;
	padding: clamp(12px, 3vw, 28px) 0;
}

.llr-success .llr-lotus {
	color: var(--llr-accent);
	margin: 0 auto 12px;
	display: block;
}

.llr-success__title {
	font-family: var(--llr-display);
	font-weight: 500;
	font-size: clamp(1.375rem, 2.6vw, 1.75rem);
	line-height: 1.4;
	margin: 0 0 10px;
}

.llr-success__title:focus {
	outline: none;
}

.llr-success p {
	max-width: 52ch;
	margin: 0 auto;
}

.llr-success .llr-actions {
	margin-top: 22px;
}

/* Geburtstag: Richtwert */
.llr-estimate {
	margin-top: 18px;
	padding: 18px 20px;
	border-radius: 16px;
	background: var(--llr-wood);
}

.llr-estimate p {
	margin: 0;
}

.llr-estimate__label {
	font-size: .8125rem;
	color: var(--llr-sub);
}

.llr-estimate__value {
	font-family: var(--llr-display);
	font-size: 1.375rem;
	margin: 2px 0 !important;
}

.llr-estimate__note {
	font-size: .8125rem;
	color: var(--llr-sub);
}

/* Seitenleiste */
.llr-summary {
	padding: 24px;
	border-radius: 24px;
	background: var(--llr-bg);
	border: 1px solid var(--llr-line);
}

.llr-summary__title {
	font-family: var(--llr-display);
	font-weight: 500;
	font-size: 1.1875rem;
	margin: 0 0 10px;
}

.llr-summary dl {
	display: grid;
	grid-template-columns: auto 1fr;
	gap: 6px 16px;
	margin: 0;
}

.llr-summary dt {
	color: var(--llr-sub);
	font-size: .875rem;
}

.llr-summary dd {
	margin: 0;
	font-weight: 600;
	text-align: right;
}

.llr-summary__note {
	margin: 14px 0 0;
	padding-top: 12px;
	border-top: 1px solid var(--llr-line);
	font-size: .8125rem;
	color: var(--llr-sub);
}

/* Platzhalter für offene Inhalte */
.llr mark {
	background: var(--llr-linen);
	color: var(--llr-sub);
	border: 1px dashed #C9C0B1;
	border-radius: 6px;
	padding: 0 6px;
}

/* Editor */
.llr-editor-hint {
	margin: 0 0 8px;
	font: 12px/1.4 system-ui, sans-serif;
	color: var(--llr-sub);
}

.llr-editor-loading {
	padding: 24px;
	color: var(--llr-sub);
}

@media (prefers-reduced-motion: reduce) {
	.llr *,
	.llr *::before,
	.llr *::after {
		transition: none !important;
	}
}
