/* ═══════════════════════════════════════════════════════
   SAR Travel Booking – Termine + Ansprechpartner
   ═══════════════════════════════════════════════════════ */

.sar-travel-booking {
	margin: 48px 0;
	scroll-margin-top: 100px; /* Sprungziel #sar-travel-dates: Offset fuer Sticky-Header */
}

/* ─── Titel ─── */

.sar-booking-title {
	margin: 0 0 24px;
}

/* ─── Zweispaltiges Layout ─── */

.sar-booking-layout {
	display: block;
}

/* ═══════════════════════════════════════════════════════
   Termine (linke Spalte)
   ═══════════════════════════════════════════════════════ */

.sar-booking-year {
	margin: 24px 0 12px;
}

.sar-booking-year:first-child {
	margin-top: 0;
}

/* ─── Einzelner Termin ─── */

.sar-booking-date {
	border-bottom: 1px solid #e8e8e8;
	padding: 12px 0;
}

.sar-booking-date:last-of-type {
	border-bottom: none;
}

.sar-booking-date__row {
	display: grid;
	/* Button-Spalte darf mit längeren Labels (z. B. „Weitere Reisen im
	   selben Zeitraum") über die 120px hinauswachsen. */
	grid-template-columns: 36px 1fr auto minmax(120px, auto);
	align-items: center;
	gap: 8px;
}

/* Status-Icon */
.sar-booking-date__status {
	line-height: 1;
}

/* Status-Markierungen in den Termin-Zeilen auf 32x32px. */
.sar-booking-date__status .sar-booking-icon {
	width: 32px;
	height: 32px;
}

/* Legenden-Symbole kompakter halten, damit die Legende in eine Zeile passt. */
.sar-booking-legend__item .sar-booking-icon {
	width: 20px;
	height: 20px;
}

/* Datum */
.sar-booking-date__range {
	display: flex;
	align-items: center;
	gap: 4px;
}

.sar-booking-date__info {
	background: none;
	border: none;
	cursor: help;
	padding: 0;
}


/* Dauer + Preis */
.sar-booking-date__details {
	text-align: right;
	white-space: nowrap;
}

/* Buchen-Button: Größe/Padding/Schrift kommen von Neves Standard-Button
   (Klassen button button-primary, Customizer-gesteuert). Hier wird nur
   Farbe + Layout in der Spalte gesetzt; die Selektoren sind bewusst
   spezifischer als Neves .button.button-primary. */
.sar-booking-dates .sar-booking-date__btn.button {
	display: block;
	width: 100%;
	text-align: center;
	background: #2e7d32;
	color: var(--custom-6);
	text-decoration: none;
	white-space: nowrap;
	transition: background 0.2s;
}

.sar-booking-dates .sar-booking-date__btn.button:hover {
	background: #1b5e20;
	color: var(--custom-6);
}

/* Ausgebucht-Alternative: Reisefinder im selben Zeitraum (dunkelblau,
   sonst identisch zum normalen Buchen-Button) */
.sar-booking-dates .sar-booking-date__btn--alt.button {
	background: #1a3a5c;
}

.sar-booking-dates .sar-booking-date__btn--alt.button:hover,
.sar-booking-dates .sar-booking-date__btn--alt.button:focus {
	background: #142e4a;
	color: var(--custom-6);
}

.sar-booking-dates .sar-booking-date__btn--disabled.button,
.sar-booking-dates .sar-booking-date__btn--disabled.button:hover {
	background: #bbb;
	cursor: not-allowed;
}

/* Unterzeilen (Variante, Notiz) – bündig mit dem Datum (36px Icon-Spalte + 8px Gap) */
.sar-booking-date__sub {
	margin-top: 4px;
	padding-left: 44px;
	font-size: 13px;
	line-height: 1.4;
	color: #50575e;
}
.sar-booking-date__sub::before {
	content: '– ';
}

/* „Alle Termine anzeigen" (pro Jahr, ab dem 8. Termin), mittig, Toggle */
.sar-booking-show-all {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	margin: 10px auto 4px;
	padding: 4px 12px;
	background: none;
	border: none;
	cursor: pointer;
	font: inherit;
	font-size: 14px;
	font-weight: 600;
	color: #1a4d2e;
}

.sar-booking-year-group .sar-booking-show-all:hover,
.sar-booking-year-group .sar-booking-show-all:focus,
.sar-booking-year-group .sar-booking-show-all:active {
	text-decoration: underline;
	background: none;
	color: #1a4d2e;
}

.sar-booking-show-all__chevron {
	transition: transform 0.2s ease;
}

.sar-booking-show-all[aria-expanded="true"] .sar-booking-show-all__chevron {
	transform: rotate(180deg);
}

/* Allgemeine Termin-Bemerkung */
.sar-booking-dates-note {
	margin-top: 16px;
}

/* ═══════════════════════════════════════════════════════
   Kombireisen
   ═══════════════════════════════════════════════════════ */

.sar-booking-combis {
	margin-top: 32px;
	padding-top: 24px;
	border-top: 2px solid #e8e8e8;
}

.sar-booking-combis__title {
	margin: 0 0 12px;
}

.sar-booking-combis__subtitle {
	margin: 12px 0 8px;
}

.sar-booking-combis__list {
	list-style: none;
	padding: 0;
	margin: 0;
}

.sar-booking-combis__list li {
	padding: 6px 0;
	border-bottom: 1px solid #f0f0f0;
}

.sar-booking-combis__list a {
	text-decoration: none;
}

.sar-booking-combis__list a:hover {
	color: #e87722;
}

.sar-booking-combis__list small {
	margin-left: 4px;
}

/* ═══════════════════════════════════════════════════════
   Legende
   ═══════════════════════════════════════════════════════ */

.sar-booking-legend {
	margin-top: 32px;
	padding-top: 24px;
	border-top: 2px solid #e8e8e8;
}

.sar-booking-legend__title {
	margin: 0 0 12px;
}

/* Kleinere Schrift + kompakte Abstaende, damit die Legende auf dem Desktop
   in eine Zeile passt. */
.sar-booking-legend__items {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 14px;
	font-size: 0.8em;
}

.sar-booking-legend__item {
	display: flex;
	align-items: center;
	gap: 5px;
	white-space: nowrap;
}

/* ═══════════════════════════════════════════════════════
   Wunschtermine
   ═══════════════════════════════════════════════════════ */

.sar-booking-wish-dates {
	margin-bottom: 24px;
}

.sar-booking-wish-date__heading {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 18px;
	font-weight: 600;
	margin: 0 0 10px;
	color: #1d2327;
}

.sar-booking-wish-date__picker {
	font-size: 14px;
	font-weight: 400;
	padding: 6px 12px;
	border: 1px solid #c3c4c7;
	border-radius: 0;
	width: 120px;
	text-align: center;
	cursor: pointer;
	background: #fff;
	color: #1d2327;
	transition: border-color 0.15s;
}

.sar-booking-wish-date__picker:hover,
.sar-booking-wish-date__picker:focus {
	border-color: #1a4d2e;
	outline: none;
}

.sar-booking-wish-date__label {
	font-weight: 600;
	color: #50575e;
}

/* Nach Datumswahl: Label raus, berechneter Zeitraum rein */
.sar-booking-date--wish.has-date .sar-booking-wish-date__label {
	display: none;
}

.sar-booking-date--wish .sar-booking-date__range-text {
	display: none;
}

.sar-booking-date--wish.has-date .sar-booking-date__range-text {
	display: inline;
}

.sar-booking-date__btn--private {
	white-space: nowrap;
}

/* Gesperrte Icons (Wunschtermin ohne Datum) und ausgegraute Icons
   (Kurzreiseverlauf bei aktiver Kombi-Auswahl), PDF 2.6.4.1/2.6.4.2 */
.sar-icon-locked,
.sar-icon-disabled {
	opacity: 0.3;
	pointer-events: none;
	cursor: not-allowed;
}

/* ═══════════════════════════════════════════════════════
   Icons in der Terminzeile (Info/Kurzverlauf + Puzzle)
   ═══════════════════════════════════════════════════════ */

.sar-booking-date__itin-toggle,
.sar-booking-date__combo-toggle {
	background: none;
	border: none;
	cursor: pointer;
	color: #646970;
	padding: 2px;
	vertical-align: middle;
	border-radius: 3px;
	line-height: 1;
	transition: color 0.15s, background 0.15s;
}

.sar-booking-date__itin-toggle:hover,
.sar-booking-date__itin-toggle[aria-expanded="true"] {
	color: #1a4d2e;
	background: #edf7f0;
}

.sar-booking-date__combo-toggle:hover {
	color: #1a4d2e;
	background: #edf7f0;
}

/* Aktives Puzzle: blau (PDF 2.6.4.2) */
.sar-booking-date__combo-toggle[aria-expanded="true"] {
	color: #0056b3;
	background: #e8f1fb;
}

/* „(kombiniert)"-Hinweis (PDF 2.6.4.3) */
.sar-combo-kombiniert {
	color: #0056b3;
	font-weight: 700;
	font-size: 13px;
	margin-left: 4px;
	white-space: nowrap;
}

/* ═══════════════════════════════════════════════════════
   Kurzreiseverlauf-Panel
   ═══════════════════════════════════════════════════════ */

.sar-booking-itin-panel {
	background: #f8faf9;
	border: 1px solid #d5ddd8;
	border-radius: 6px;
	margin: 8px 0 4px;
	padding: 12px 20px;
}

.sar-booking-itin-panel__list {
	list-style: none;
	margin: 0;
	padding: 0;
	font-size: 13px;
	line-height: 1.6;
}

.sar-booking-itin-panel__day {
	font-weight: 600;
	color: #1a4d2e;
}

/* ═══════════════════════════════════════════════════════
   Kombibaukasten
   ═══════════════════════════════════════════════════════ */

.sar-booking-combo-panel {
	background: #f8faf9;
	border: 1px solid #d5ddd8;
	border-radius: 6px;
	margin: 8px 0 4px;
	padding: 16px 20px;
}

.sar-combo-selected:not(:empty) {
	margin-bottom: 20px;
}

.sar-combo-section__title {
	font-size: 14px;
	font-weight: 700;
	margin: 14px 0 8px;
	color: #1d2327;
}

.sar-combo-section__title:first-child {
	margin-top: 0;
}

/* Eine Baukasten-Zeile: Aktion | Datum | Titel/Variante */
.sar-combo-row {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	padding: 8px 0;
	border-bottom: 1px solid #e8ede9;
	font-size: 14px;
}

.sar-combo-row:last-child {
	border-bottom: none;
}

.sar-combo-row--main {
	background: #edf7f0;
	border-radius: 4px;
	margin: 0 -8px;
	padding: 8px;
}

.sar-combo-row__action {
	flex-shrink: 0;
	width: 24px;
	background: none;
	border: none;
	cursor: pointer;
	padding: 0;
	line-height: 1;
	transition: transform 0.15s;
}

/* Hover: nur Zoom, kein Hintergrund (Theme-Button-Hover neutralisieren) */
.sar-booking-combo-panel .sar-combo-row__action:hover,
.sar-booking-combo-panel .sar-combo-row__action:focus {
	transform: scale(1.15);
	background: transparent;
	border: none;
	box-shadow: none;
	outline: none;
}

.sar-combo-row__action--spacer {
	cursor: default;
	pointer-events: none;
}

.sar-combo-row__dates {
	min-width: 140px;
	flex-shrink: 0;
	font-size: 13px;
	font-weight: 600;
	color: #1d2327;
}

.sar-combo-row__info {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.sar-combo-row__name {
	color: #1a4d2e;
	font-weight: 600;
	text-decoration: none;
}

.sar-combo-row__name:hover {
	text-decoration: underline;
}

.sar-combo-row__variant,
.sar-combo-row__label {
	font-size: 12px;
	color: #646970;
}

/* ═══════════════════════════════════════════════════════
   Modal (Anfrage-Hinweis + Reset-Warnung), PDF 2.6.4.5/2.6.4.6
   ═══════════════════════════════════════════════════════ */

.sar-booking-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: none;
	align-items: center;
	justify-content: center;
}

.sar-booking-modal.is-open {
	display: flex;
}

.sar-booking-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.6);
}

.sar-booking-modal__content {
	position: relative;
	background: #fff;
	padding: 30px;
	border-radius: 8px;
	width: 90%;
	max-width: 500px;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.sar-booking-modal__title {
	font-size: 20px;
	font-weight: 700;
	margin: 0 0 15px;
	color: #1d2327;
}

.sar-booking-modal__text {
	font-size: 15px;
	line-height: 1.6;
	margin: 0 0 25px;
	color: #50575e;
}

.sar-booking-modal__buttons {
	display: flex;
	justify-content: flex-end;
	gap: 10px;
}

.sar-booking-modal__btn {
	padding: 10px 20px;
	border-radius: 100px;
	cursor: pointer;
	font-weight: 600;
	text-decoration: none;
	border: none;
	font-size: 14px;
	transition: background 0.2s;
}

.sar-booking-modal__btn--cancel {
	background: #f1f1f1;
	color: #1d2327;
}

.sar-booking-modal__btn--cancel:hover {
	background: #e2e2e2;
}

.sar-booking-modal__btn--continue {
	background: #2e7d32;
	color: #fff;
}

.sar-booking-modal__btn--continue:hover {
	background: #1b5e20;
}

/* ─── Responsive ─── */

@media (max-width: 600px) {
	.sar-booking-date__row {
		grid-template-columns: 36px 1fr;
	}

	.sar-booking-date__details {
		grid-column: 2;
		text-align: left;
	}

	.sar-booking-date__btn {
		grid-column: 2;
	}

	.sar-booking-legend__items {
		flex-direction: column;
		gap: 8px;
	}

	/* Kombibaukasten mobil: Bausteine als gestapelte Karten,
	   Aktion rechts, Datum über dem Titel (PDF 2.6.3) */
	.sar-booking-combo-panel {
		padding: 12px;
	}

	.sar-combo-row {
		flex-wrap: wrap;
		position: relative;
		padding-right: 40px;
	}

	.sar-combo-row__action {
		position: absolute;
		right: 4px;
		top: 50%;
		transform: translateY(-50%);
		width: 32px;
	}

	.sar-booking-combo-panel .sar-combo-row__action:hover,
	.sar-booking-combo-panel .sar-combo-row__action:focus {
		transform: translateY(-50%) scale(1.1);
		background: transparent;
	}

	.sar-combo-row__action svg {
		width: 28px;
		height: 28px;
	}

	.sar-combo-row__dates {
		min-width: 0;
		width: 100%;
	}

	.sar-combo-row__info {
		width: 100%;
	}
}
