/*
Theme Name: Ferienhaus Osterwald
Theme URI: https://ferienwohnung-osterwald.de
Author: Sascha Simon
Description: Massgeschneidertes Theme für das Ferienhaus Osterwald in Schmallenberg. Klassisches Theme für Beaver Builder, mit Hell- und Dunkelmodus.
Version: 2.0.6
Requires at least: 6.5
Tested up to: 7.0
Requires PHP: 8.0
Text Domain: osterwald
*/

/* ==========================================================================
   Schriften — lokal eingebunden, keine externen Anfragen (DSGVO)
   ========================================================================== */

@font-face {
	font-family: 'Inter';
	src: url('assets/fonts/inter-var.woff2') format('woff2-variations');
	font-weight: 400 700;
	font-style: normal;
	font-display: swap;
}

/* ==========================================================================
   Design-Token

   Die Palette stammt aus dem Logo — Tannengrün, Tinte, Creme — ergänzt um
   ein Cognac als Akzent, das die Ledermöbel der Wohnungen aufgreift.
   ========================================================================== */

:root {
	--ff-display: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	--ff-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
	--display-weight: 600;
	--display-tracking: -0.025em;

	--fs-xs: 0.78rem;
	--fs-sm: 0.9375rem;
	--fs-base: 1.0625rem;
	--fs-lg: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
	--fs-xl: clamp(1.15rem, 1rem + 0.8vw, 1.45rem);
	--fs-2xl: clamp(1.5rem, 1.2rem + 1.7vw, 2.25rem);
	--fs-3xl: clamp(2rem, 1.35rem + 3.2vw, 3.8rem);

	--sp-1: 0.5rem;
	--sp-2: 1rem;
	--sp-3: 1.5rem;
	--sp-4: 2rem;
	--sp-5: 3rem;
	--sp-6: 4.5rem;
	--sp-7: 6.5rem;

	--radius-sm: 8px;
	--radius: 14px;
	--radius-lg: 22px;
	--radius-xl: 32px;
	--wrap: 1220px;
	--wrap-narrow: 720px;

	--header-h: 76px;
	--ease: cubic-bezier(0.22, 1, 0.36, 1);
	--ease-soft: cubic-bezier(0.4, 0, 0.2, 1);

	/* Native Steuerelemente (Datumswähler, Checkboxen, Scrollbalken) folgen
	   damit dem Farbmodus — sonst zeichnet der Browser sie schwarz auf dunkel. */
	color-scheme: light;

	/* Hell */
	--c-bg: #faf6ec;
	--c-surface: #fffdf7;
	--c-surface-alt: #f2ecdc;
	--c-text: #241f17;
	--c-muted: #6c6455;
	--c-primary: #2c4413;
	--c-primary-hover: #3c5b1c;
	--c-on-primary: #fcf8dc;
	--c-accent: #a9683c;
	--c-accent-soft: #f0e0d2;
	--c-border: #e4dcc7;
	--c-deep: #1e2c0e;
	--c-on-deep: #f3f0dd;
	--c-deep-accent: #cfe39c;
	--c-free: #4b7c2f;
	--c-busy: #b3543c;

	--shadow-sm: 0 1px 2px rgb(36 31 23 / 0.05), 0 2px 8px rgb(36 31 23 / 0.04);
	--shadow: 0 4px 12px rgb(36 31 23 / 0.07), 0 12px 32px rgb(36 31 23 / 0.07);
	--shadow-lg: 0 8px 24px rgb(36 31 23 / 0.1), 0 28px 64px rgb(36 31 23 / 0.12);
	--shadow-hero: 0 20px 60px rgb(30 44 14 / 0.25);
}

@media (prefers-color-scheme: dark) {
	:root:not([data-theme='light']) {
		color-scheme: dark;
		--c-bg: #1f2123;
		--c-surface: #282a2d;
		--c-surface-alt: #2f3235;
		--c-text: #ecebe9;
		--c-muted: #a3a2a0;
		--c-primary: #a6d06e;
		--c-primary-hover: #bade8a;
		--c-on-primary: #1a1b1c;
		--c-accent: #d29c6c;
		--c-accent-soft: #38393c;
		--c-border: #3b3d40;
		--c-deep: #161719;
		--c-on-deep: #ecebe9;
		--c-deep-accent: #cfe39c;
		--c-free: #84c079;
		--c-busy: #db8a6a;

		--shadow-sm: 0 1px 2px rgb(0 0 0 / 0.3);
		--shadow: 0 4px 14px rgb(0 0 0 / 0.4);
		--shadow-lg: 0 10px 30px rgb(0 0 0 / 0.5);
		--shadow-hero: 0 20px 60px rgb(0 0 0 / 0.55);
	}
}

:root[data-theme='light'] {
	color-scheme: light;
}

:root[data-theme='dark'] {
	color-scheme: dark;
	--c-bg: #1f2123;
	--c-surface: #282a2d;
	--c-surface-alt: #2f3235;
	--c-text: #ecebe9;
	--c-muted: #a3a2a0;
	--c-primary: #a6d06e;
	--c-primary-hover: #bade8a;
	--c-on-primary: #1a1b1c;
	--c-accent: #d29c6c;
	--c-accent-soft: #38393c;
	--c-border: #3b3d40;
	--c-deep: #161719;
	--c-on-deep: #ecebe9;
	--c-deep-accent: #cfe39c;
	--c-free: #84c079;
	--c-busy: #db8a6a;

	--shadow-sm: 0 1px 2px rgb(0 0 0 / 0.3);
	--shadow: 0 4px 14px rgb(0 0 0 / 0.4);
	--shadow-lg: 0 10px 30px rgb(0 0 0 / 0.5);
	--shadow-hero: 0 20px 60px rgb(0 0 0 / 0.55);
}

/* ==========================================================================
   Grundlagen
   ========================================================================== */

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

html {
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: calc(var(--header-h) + 1rem);
}

body {
	margin: 0;
	background: var(--c-bg);
	color: var(--c-text);
	font-family: var(--ff-body);
	font-size: var(--fs-base);
	line-height: 1.7;
	font-synthesis-weight: none;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

img,
picture,
video,
iframe {
	max-width: 100%;
	height: auto;
	display: block;
}

a {
	color: var(--c-primary);
	text-underline-offset: 0.2em;
	text-decoration-thickness: 1px;
}

a:hover {
	color: var(--c-primary-hover);
}

h1,
h2,
h3,
h4 {
	font-family: var(--ff-display);
	font-weight: var(--display-weight);
	line-height: 1.12;
	letter-spacing: var(--display-tracking);
	margin: 0 0 var(--sp-2);
	text-wrap: balance;
}

h1 {
	font-size: var(--fs-3xl);
}

h2 {
	font-size: var(--fs-2xl);
}

h3 {
	font-size: var(--fs-xl);
}

p {
	margin: 0 0 var(--sp-2);
	text-wrap: pretty;
}

:focus-visible {
	outline: 2px solid var(--c-primary);
	outline-offset: 3px;
	border-radius: 3px;
}

::selection {
	background: var(--c-primary);
	color: var(--c-on-primary);
}

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

.skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 999;
	background: var(--c-primary);
	color: var(--c-on-primary);
	padding: var(--sp-1) var(--sp-2);
	border-radius: 0 0 var(--radius-sm) 0;
}

.skip-link:focus {
	left: 0;
	top: 0;
}

/* ==========================================================================
   Bewegung

   Elemente treten beim Scrollen sanft ein. Wer Bewegung reduziert haben will,
   sieht sie sofort und vollständig.
   ========================================================================== */

[data-reveal] {
	opacity: 0;
	transform: translateY(26px);
	transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
	transition-delay: var(--reveal-delay, 0ms);
	will-change: opacity, transform;
}

[data-reveal].is-visible {
	opacity: 1;
	transform: none;
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}

	[data-reveal] {
		opacity: 1;
		transform: none;
	}
}

/* ==========================================================================
   Layout
   ========================================================================== */

.o-wrap {
	width: min(100% - 2.5rem, var(--wrap));
	margin-inline: auto;
}

.o-wrap--narrow {
	width: min(100% - 2.5rem, var(--wrap-narrow));
}

.o-section {
	padding-block: var(--sp-6);
}

.o-eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 0.6em;
	font-family: var(--ff-body);
	font-size: var(--fs-xs);
	font-weight: 500;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--c-accent);
	margin: 0 0 var(--sp-2);
}

.o-eyebrow::before {
	content: '';
	width: 1.9rem;
	height: 1px;
	background: currentColor;
	opacity: 0.55;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.o-btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.55em;
	padding: 0.85em 1.75em;
	border: 1px solid var(--c-primary);
	border-radius: 100px;
	background: var(--c-primary);
	color: var(--c-on-primary);
	font: inherit;
	font-weight: 500;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	overflow: hidden;
	isolation: isolate;
	transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease),
		background-color 0.25s var(--ease-soft), border-color 0.25s var(--ease-soft);
}

.o-btn:hover {
	background: var(--c-primary-hover);
	border-color: var(--c-primary-hover);
	color: var(--c-on-primary);
	transform: translateY(-2px);
	box-shadow: 0 10px 24px color-mix(in srgb, var(--c-primary) 30%, transparent);
}

.o-btn:active {
	transform: translateY(0);
}

.o-btn--ghost {
	background: transparent;
	color: var(--c-primary);
}

.o-btn--ghost:hover {
	background: color-mix(in srgb, var(--c-primary) 10%, transparent);
	color: var(--c-primary);
	box-shadow: none;
}

.o-btn[disabled] {
	opacity: 0.5;
	cursor: not-allowed;
	transform: none;
}

/* ==========================================================================
   Kopfbereich

   Über dem Hero schwebt der Header transparent; sobald gescrollt wird,
   legt er sich als getönte Leiste über den Inhalt.
   ========================================================================== */

.o-header {
	position: fixed;
	inset: 0 0 auto 0;
	z-index: 100;
	transition: background-color 0.35s var(--ease-soft), box-shadow 0.35s var(--ease-soft),
		border-color 0.35s var(--ease-soft);
	border-bottom: 1px solid transparent;
}

.o-header__inner {
	display: flex;
	align-items: center;
	gap: var(--sp-2);
	min-height: var(--header-h);
}

/* Am Seitenanfang über einem Hero: durchsichtig mit hellem Text. */
body:has(.o-hero) .o-header:not(.is-stuck) {
	background: transparent;
}

body:has(.o-hero) .o-header:not(.is-stuck) .o-brand,
body:has(.o-hero) .o-header:not(.is-stuck) .o-nav a,
body:has(.o-hero) .o-header:not(.is-stuck) .o-iconbtn {
	color: #fff;
}

body:has(.o-hero) .o-header:not(.is-stuck) .o-brand__sub {
	color: rgb(255 255 255 / 0.75);
}

body:has(.o-hero) .o-header:not(.is-stuck) .o-iconbtn {
	border-color: rgb(255 255 255 / 0.35);
}

body:has(.o-hero) .o-header:not(.is-stuck) .o-iconbtn:hover {
	border-color: #fff;
	background: rgb(255 255 255 / 0.12);
}

body:has(.o-hero) .o-header:not(.is-stuck) .o-header__cta {
	background: rgb(255 255 255 / 0.14);
	border-color: rgb(255 255 255 / 0.5);
	color: #fff;
	backdrop-filter: blur(6px);
}

body:has(.o-hero) .o-header:not(.is-stuck) .o-header__cta:hover {
	background: #fff;
	border-color: #fff;
	color: #2c4413; /* fester Wert — im Dunkelmodus wäre --c-primary hellgrün auf weiss */
}

.o-header.is-stuck,
body:not(:has(.o-hero)) .o-header {
	background: color-mix(in srgb, var(--c-bg) 82%, transparent);
	backdrop-filter: blur(14px) saturate(1.4);
	border-bottom-color: var(--c-border);
	box-shadow: var(--shadow-sm);
}

/* Ohne Hero muss der Inhalt unter der fixierten Leiste beginnen. */
body:not(:has(.o-hero)) #inhalt {
	padding-top: var(--header-h);
}

.o-brand {
	display: flex;
	align-items: center;
	gap: 0.7rem;
	margin-right: auto;
	text-decoration: none;
	color: var(--c-text);
	transition: color 0.35s var(--ease-soft), transform 0.3s var(--ease);
}

.o-brand:hover {
	transform: translateY(-1px);
}

.o-brand img {
	width: 48px;
	height: 48px;
	border-radius: 50%;
	box-shadow: var(--shadow-sm);
	transition: width 0.35s var(--ease), height 0.35s var(--ease),
		opacity 0.3s var(--ease-soft), margin-right 0.35s var(--ease);
}

/* Solange die Leiste durchsichtig über dem Hero schwebt, tritt das Logo
   grösser auf; beim Andocken schrumpft es weich auf Leistenmass. */
body:has(.o-hero) .o-header:not(.is-stuck) .o-brand img {
	width: 66px;
	height: 66px;
}

@media (max-width: 979px) {
	body:has(.o-hero) .o-header:not(.is-stuck) .o-brand img {
		width: 56px;
		height: 56px;
	}
}

/* Auf dem Handy zeigt der Hero direkt darunter das grosse, lesbare
   Abzeichen — das winzige daneben in der Leiste wäre doppelt und
   gedrängt. Es blendet erst ein, wenn die Leiste andockt und das
   Hero-Abzeichen aus dem Blick ist. */
@media (max-width: 767px) {
	body:has(.o-hero) .o-header:not(.is-stuck) .o-brand img {
		width: 0;
		opacity: 0;
		margin-right: -0.7rem; /* gleicht den Flex-Abstand aus */
	}
}

.o-brand__name {
	font-family: var(--ff-display);
	font-size: 1.09rem;
	font-weight: 600;
	line-height: 1.1;
	letter-spacing: -0.01em;
}

.o-brand__sub {
	display: block;
	font-family: var(--ff-body);
	font-size: 0.66rem;
	font-weight: 400;
	letter-spacing: 0.19em;
	text-transform: uppercase;
	color: var(--c-muted);
	transition: color 0.35s var(--ease-soft);
}

.o-nav ul {
	display: flex;
	align-items: center;
	gap: var(--sp-3);
	list-style: none;
	margin: 0;
	padding: 0;
}

.o-nav a {
	position: relative;
	color: var(--c-text);
	text-decoration: none;
	font-size: var(--fs-sm);
	padding-block: 0.45rem;
	transition: color 0.25s var(--ease-soft);
}

.o-nav a::after {
	content: '';
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0.1rem;
	height: 1.5px;
	background: currentColor;
	border-radius: 2px;
	transform: scaleX(0);
	transform-origin: left;
	transition: transform 0.3s var(--ease);
}

.o-nav a:hover::after,
.o-nav .current-menu-item > a::after {
	transform: scaleX(1);
}

.o-header__actions {
	display: flex;
	align-items: center;
	gap: 0.6rem;
}

.o-header__cta {
	padding: 0.7em 1.4em;
	font-size: var(--fs-sm);
}

.o-iconbtn {
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	padding: 0;
	border: 1px solid var(--c-border);
	border-radius: 50%;
	background: transparent;
	color: var(--c-text);
	cursor: pointer;
	transition: border-color 0.25s var(--ease-soft), color 0.25s var(--ease-soft),
		background-color 0.25s var(--ease-soft), transform 0.25s var(--ease);
}

.o-iconbtn:hover {
	border-color: var(--c-primary);
	color: var(--c-primary);
	transform: rotate(-12deg);
}

.o-iconbtn svg {
	width: 19px;
	height: 19px;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.6;
	stroke-linecap: round;
	stroke-linejoin: round;
}

/* Der Umschalter zeigt immer das Symbol des Modus, in den er wechselt. */
.o-themetoggle .o-icon--moon {
	display: none;
}

:root[data-theme='dark'] .o-themetoggle .o-icon--moon,
:root:not([data-theme='light']) .o-themetoggle .o-icon--sun {
	display: block;
}

:root[data-theme='dark'] .o-themetoggle .o-icon--sun {
	display: none;
}

@media (prefers-color-scheme: dark) {
	:root:not([data-theme='light']) .o-themetoggle .o-icon--sun {
		display: none;
	}

	:root:not([data-theme='light']) .o-themetoggle .o-icon--moon {
		display: block;
	}
}

:root[data-theme='light'] .o-themetoggle .o-icon--sun {
	display: block;
}

:root[data-theme='light'] .o-themetoggle .o-icon--moon {
	display: none;
}

.o-burger {
	display: none;
}

@media (max-width: 979px) {
	.o-burger {
		display: grid;
	}

	.o-nav {
		position: fixed;
		inset: var(--header-h) 0 auto 0;
		background: var(--c-surface);
		border-bottom: 1px solid var(--c-border);
		box-shadow: var(--shadow);
		max-height: 0;
		overflow: hidden;
		transition: max-height 0.4s var(--ease);
	}

	.o-nav[data-open='true'] {
		max-height: 75vh;
		overflow-y: auto;
	}

	body:has(.o-hero) .o-header:not(.is-stuck) .o-nav a {
		color: var(--c-text);
	}

	.o-nav ul {
		flex-direction: column;
		align-items: stretch;
		gap: 0;
		padding: var(--sp-1) 1.25rem var(--sp-3);
	}

	.o-nav li + li {
		border-top: 1px solid var(--c-border);
	}

	.o-nav a {
		display: block;
		padding: 1rem 0;
		font-size: var(--fs-lg);
		font-family: var(--ff-display);
	}

	.o-nav a::after {
		display: none;
	}

	.o-header__cta {
		display: none;
	}
}

/* ==========================================================================
   Hero
   ========================================================================== */

.o-hero {
	position: relative;
	display: grid;
	place-items: center;
	padding: calc(var(--header-h) + var(--sp-6)) 1.25rem var(--sp-6);
	background-color: var(--c-deep);
	color: #fff;
	text-align: center;
	overflow: hidden;
	isolation: isolate;
}

.o-hero--klein {
	min-height: 56vh;
}

.o-hero--mittel {
	min-height: 68vh;
}

.o-hero--gross {
	min-height: min(94vh, 900px);
}

/* Das Hintergrundbild liegt als eigene Ebene darunter und zoomt langsam —
   das gibt der Startseite Bewegung, ohne den Text zu stören. */
.o-hero__bg {
	position: absolute;
	inset: 0;
	z-index: -2;
	background-size: cover;
	background-position: center;
	animation: o-kenburns 26s ease-out both;
}

@keyframes o-kenburns {
	from {
		transform: scale(1.12);
	}

	to {
		transform: scale(1);
	}
}

@media (prefers-reduced-motion: reduce) {
	.o-hero__bg {
		animation: none;
	}
}

/* Die Innenaufnahmen sind hell und kontrastarm. Neben dem Verlauf von oben
   nach unten dunkelt eine zweite Ebene die Bildmitte ab, damit die Schrift
   auch über weissen Wänden sicher lesbar bleibt. */
.o-hero::after {
	content: '';
	position: absolute;
	inset: 0;
	z-index: -1;
	background:
		radial-gradient(ellipse 80% 62% at 50% 50%, rgb(18 21 12 / 0.62), transparent 72%),
		linear-gradient(180deg, rgb(18 21 12 / 0.62) 0%, rgb(18 21 12 / 0.3) 42%, rgb(18 21 12 / 0.78) 100%);
}

.o-hero__inner {
	max-width: 52rem;
	animation: o-hero-in 1s var(--ease) both 0.15s;
}

@keyframes o-hero-in {
	from {
		opacity: 0;
		transform: translateY(28px);
	}

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

/* Das Abzeichen gross und lesbar über der Überschrift — in der Kopfleiste
   bleibt es bewusst klein, dort liest der Namenszug daneben. */
.o-hero__logo {
	width: clamp(120px, 8vw + 70px, 170px);
	height: auto;
	margin: 0 auto var(--sp-3);
	border-radius: 50%;
	box-shadow: 0 12px 44px rgb(0 0 0 / 0.4);
}

.o-hero__eyebrow {
	color: #fff;
	opacity: 0.9;
	justify-content: center;
}

.o-hero__title {
	color: #fff;
	margin-bottom: var(--sp-3);
	text-shadow: 0 2px 30px rgb(20 23 14 / 0.5);
}

/* Auf Unterseiten steht der Titel eine Stufe kleiner als auf der Startseite —
   sonst erschlägt er den Inhalt darunter. */
.o-hero--mittel .o-hero__title,
.o-hero--klein .o-hero__title {
	font-size: var(--fs-2xl);
}

.o-hero__text {
	font-size: var(--fs-lg);
	color: #fff;
	opacity: 0.93;
	margin-inline: auto;
	max-width: 40rem;
}

.o-hero__action {
	margin-top: var(--sp-4);
	margin-bottom: 0;
	display: flex;
	justify-content: center;
	gap: var(--sp-2);
	flex-wrap: wrap;
}

/* Der Hero liegt immer über einem abgedunkelten Foto — der Knopf bleibt
   deshalb in beiden Modi hell mit dunkelgrüner Schrift. Mit Moduls-Token
   würde er im Dunkelmodus fast schwarz. */
.o-hero .o-btn {
	background: #fcf8dc;
	border-color: #fcf8dc;
	color: #2c4413;
	padding: 1em 2.1em;
	font-size: var(--fs-base);
}

.o-hero .o-btn:hover {
	background: #fff;
	border-color: #fff;
	color: #1e2c0e;
	box-shadow: 0 14px 34px rgb(0 0 0 / 0.3);
}

/* Scroll-Hinweis am unteren Rand des grossen Heros */
.o-hero__scroll {
	position: absolute;
	left: 50%;
	bottom: 1.6rem;
	transform: translateX(-50%);
	width: 26px;
	height: 42px;
	border: 1.5px solid rgb(255 255 255 / 0.5);
	border-radius: 14px;
	z-index: 1;
}

.o-hero__scroll::after {
	content: '';
	position: absolute;
	left: 50%;
	top: 8px;
	width: 3px;
	height: 7px;
	margin-left: -1.5px;
	border-radius: 2px;
	background: rgb(255 255 255 / 0.85);
	animation: o-scrollhint 2s var(--ease-soft) infinite;
}

@keyframes o-scrollhint {
	0%, 100% {
		opacity: 0;
		transform: translateY(0);
	}

	30% {
		opacity: 1;
	}

	70% {
		opacity: 0;
		transform: translateY(13px);
	}
}

@media (max-width: 767px) {
	.o-hero__scroll {
		display: none;
	}
}

/* ==========================================================================
   Fussbereich
   ========================================================================== */

.o-footer {
	margin-top: var(--sp-6);
	background: var(--c-deep);
	color: var(--c-on-deep);
	padding-block: var(--sp-6) var(--sp-3);
	font-size: var(--fs-sm);
}

.o-footer__grid {
	display: grid;
	gap: var(--sp-4);
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.o-footer h2 {
	font-size: var(--fs-lg);
	margin-bottom: var(--sp-2);
	color: #fff;
}

.o-footer ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.o-footer li + li {
	margin-top: 0.45rem;
}

.o-footer a {
	color: var(--c-on-deep);
	text-decoration: none;
	opacity: 0.86;
	transition: opacity 0.2s var(--ease-soft), color 0.2s var(--ease-soft);
}

/* Der Fussbereich ist in beiden Modi dunkel — die Hover-Farbe muss deshalb
   aus dem immer-hellen Akzent kommen. --c-primary wäre im Hellmodus
   dunkelgrün auf dunkelgrün. */
.o-footer a:hover {
	opacity: 1;
	color: var(--c-deep-accent);
	text-decoration: underline;
}

.o-footer__bottom {
	margin-top: var(--sp-5);
	padding-top: var(--sp-2);
	border-top: 1px solid rgb(255 255 255 / 0.14);
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--sp-1) var(--sp-3);
	justify-content: space-between;
	opacity: 0.72;
	font-size: var(--fs-xs);
}

.o-footer__legal {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem 1.25rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

/* Muss spezifischer sein als `.o-footer li + li`, sonst rutschen das zweite
   und dritte Element um den Zeilenabstand nach unten. */
.o-footer .o-footer__legal li,
.o-footer .o-footer__legal li + li {
	margin: 0;
}

/* ==========================================================================
   Inhaltsseiten ohne Beaver Builder
   ========================================================================== */

.o-page {
	padding-block: var(--sp-5);
}

.o-page__header {
	margin-bottom: var(--sp-4);
}

.o-prose > * + * {
	margin-top: var(--sp-2);
}

.o-prose h2 {
	margin-top: var(--sp-4);
}

.o-prose h3 {
	margin-top: var(--sp-3);
}

.o-prose ul,
.o-prose ol {
	padding-left: 1.25rem;
}

.o-prose li + li {
	margin-top: 0.35rem;
}

.o-prose table {
	width: 100%;
	border-collapse: collapse;
}

.o-prose th,
.o-prose td {
	border-bottom: 1px solid var(--c-border);
	padding: 0.6rem 0.5rem;
	text-align: left;
}

.o-prose blockquote {
	margin: var(--sp-3) 0;
	padding-left: var(--sp-2);
	border-left: 3px solid var(--c-accent);
	color: var(--c-muted);
	font-style: italic;
}

.o-prose img {
	border-radius: var(--radius);
}

/* ==========================================================================
   Galerie im Bento-Raster
   ========================================================================== */

/* Die Reihenhöhe ist fest vorgegeben, damit gespannte Kacheln exakt zwei
   Reihen füllen. Mit einer Seitenverhältnis-Angabe je Kachel entstünden
   Rundungsdifferenzen und dadurch Löcher im Raster. */
.o-gallery {
	display: grid;
	gap: 0.75rem;
	grid-template-columns: repeat(2, 1fr);
	grid-auto-rows: 9rem;
	grid-auto-flow: dense;
}

@media (min-width: 700px) {
	.o-gallery {
		grid-template-columns: repeat(4, 1fr);
		grid-auto-rows: 10.5rem;
	}

	/* Jedes siebte Bild wird zum Blickfang über zwei mal zwei Felder. */
	.o-gallery__item:nth-child(7n + 1) {
		grid-column: span 2;
		grid-row: span 2;
	}
}

@media (min-width: 1100px) {
	.o-gallery {
		grid-auto-rows: 12rem;
	}
}

.o-gallery__item {
	position: relative;
	margin: 0;
	padding: 0;
	border: 0;
	background: var(--c-surface-alt);
	cursor: zoom-in;
	overflow: hidden;
	border-radius: var(--radius);
	box-shadow: var(--shadow-sm);
	transition: box-shadow 0.35s var(--ease), transform 0.35s var(--ease);
}

.o-gallery__item:hover {
	box-shadow: var(--shadow);
	transform: translateY(-3px);
}

.o-gallery__item::after {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, transparent 55%, rgb(20 23 14 / 0.4));
	opacity: 0;
	transition: opacity 0.35s var(--ease-soft);
}

.o-gallery__item:hover::after {
	opacity: 1;
}

.o-gallery__item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.6s var(--ease);
}

.o-gallery__item:hover img {
	transform: scale(1.06);
}

/* ==========================================================================
   Lightbox
   ========================================================================== */

.o-lightbox {
	position: fixed;
	inset: 0;
	z-index: 1000;
	display: grid;
	place-items: center;
	background: rgb(12 14 8 / 0.94);
	backdrop-filter: blur(6px);
	padding: var(--sp-2);
	animation: o-fade 0.25s var(--ease-soft);
}

@keyframes o-fade {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

.o-lightbox[hidden] {
	display: none;
}

.o-lightbox img {
	max-width: 100%;
	max-height: 84vh;
	border-radius: var(--radius);
	object-fit: contain;
	box-shadow: var(--shadow-lg);
}

.o-lightbox__caption {
	color: #fff;
	text-align: center;
	font-size: var(--fs-sm);
	margin-top: var(--sp-2);
	opacity: 0.8;
}

.o-lightbox__btn {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 50px;
	height: 50px;
	display: grid;
	place-items: center;
	border: 0;
	border-radius: 50%;
	background: rgb(255 255 255 / 0.14);
	color: #fff;
	font-size: 1.7rem;
	line-height: 1;
	cursor: pointer;
	transition: background-color 0.2s var(--ease-soft), transform 0.2s var(--ease);
}

.o-lightbox__btn:hover {
	background: rgb(255 255 255 / 0.28);
	transform: translateY(-50%) scale(1.08);
}

.o-lightbox__prev {
	left: var(--sp-2);
}

.o-lightbox__next {
	right: var(--sp-2);
}

.o-lightbox__close {
	top: var(--sp-2);
	right: var(--sp-2);
	transform: none;
}

.o-lightbox__close:hover {
	transform: scale(1.08) rotate(90deg);
}

.o-lightbox__count {
	position: absolute;
	top: 1.35rem;
	left: 1.5rem;
	color: #fff;
	opacity: 0.75;
	font-size: var(--fs-sm);
	font-variant-numeric: tabular-nums;
}

/* ==========================================================================
   Nach-oben-Knopf
   ========================================================================== */

.o-totop {
	position: fixed;
	right: 1.4rem;
	bottom: 1.4rem;
	z-index: 80;
	width: 46px;
	height: 46px;
	display: grid;
	place-items: center;
	padding: 0;
	border: 1px solid var(--c-border);
	border-radius: 50%;
	background: color-mix(in srgb, var(--c-surface) 92%, transparent);
	backdrop-filter: blur(10px);
	color: var(--c-text);
	cursor: pointer;
	box-shadow: var(--shadow);
	opacity: 0;
	transform: translateY(10px);
	pointer-events: none;
	transition: opacity 0.3s var(--ease-soft), transform 0.3s var(--ease),
		color 0.2s var(--ease-soft), border-color 0.2s var(--ease-soft);
}

.o-totop.is-visible {
	opacity: 1;
	transform: none;
	pointer-events: auto;
}

.o-totop:hover {
	color: var(--c-primary);
	border-color: var(--c-primary);
}

/* Auf schmalen Bildschirmen mit Buchungsleiste würde der Knopf sie überlagern. */
@media (max-width: 899px) {
	body:has([data-osb-booking]) .o-totop {
		display: none;
	}
}

/* ==========================================================================
   Ausstattung
   ========================================================================== */

.o-amenities {
	display: grid;
	gap: 0.8rem;
	grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
	list-style: none;
	margin: 0;
	padding: 0;
}

.o-amenities li {
	display: flex;
	align-items: center;
	gap: 0.85rem;
	font-size: var(--fs-sm);
	padding: 0.85rem 1rem;
	border-radius: var(--radius-sm);
	background: color-mix(in srgb, var(--c-surface) 65%, transparent);
	border: 1px solid color-mix(in srgb, var(--c-border) 65%, transparent);
	transition: border-color 0.25s var(--ease-soft), transform 0.25s var(--ease);
}

.o-amenities li:hover {
	border-color: color-mix(in srgb, var(--c-primary) 40%, transparent);
	transform: translateY(-2px);
}

.o-amenities svg {
	flex: 0 0 auto;
	width: 22px;
	height: 22px;
	fill: none;
	stroke: var(--c-primary);
	stroke-width: 1.5;
	stroke-linecap: round;
	stroke-linejoin: round;
}

/* ==========================================================================
   Zahlenband
   ========================================================================== */

.o-stats {
	display: grid;
	gap: var(--sp-2);
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	list-style: none;
	margin: 0;
	padding: 0;
	text-align: center;
}

.o-stats li {
	padding: var(--sp-2) var(--sp-1);
}

.o-stats b {
	display: block;
	font-family: var(--ff-display);
	font-size: clamp(2rem, 1.4rem + 2.2vw, 3rem);
	font-weight: 600;
	line-height: 1;
	letter-spacing: -0.03em;
	color: var(--c-primary);
}

.o-stats span {
	display: block;
	margin-top: 0.45rem;
	font-size: var(--fs-xs);
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--c-muted);
}

/* ==========================================================================
   Textbausteine
   ========================================================================== */

.o-intro {
	max-width: 46rem;
	margin-inline: auto;
	text-align: center;
}

.o-intro p:last-child {
	margin-bottom: 0;
	color: var(--c-muted);
}

.o-note {
	font-size: var(--fs-sm);
	color: var(--c-muted);
}

.o-facts-box {
	padding: var(--sp-3);
	border: 1px solid var(--c-border);
	border-radius: var(--radius-lg);
	background: var(--c-surface);
	box-shadow: var(--shadow-sm);
}

.o-facts-box > :first-child {
	margin-top: 0;
}

.o-facts-box > :last-child {
	margin-bottom: 0;
}

.o-facts-box h3 {
	font-size: var(--fs-lg);
	padding-bottom: var(--sp-1);
	border-bottom: 1px solid var(--c-border);
}

.o-factlist {
	display: grid;
	grid-template-columns: auto 1fr;
	gap: 0.55rem var(--sp-2);
	margin: 0;
	font-size: var(--fs-sm);
}

.o-factlist dt {
	color: var(--c-muted);
}

.o-factlist dd {
	margin: 0;
	font-weight: 500;
	text-align: right;
}

.o-factlist--wide {
	max-width: 34rem;
}

/* Offene Angaben in den Rechtstexten deutlich markieren. */
.ow-todo {
	padding: 0.7rem 1rem;
	border-left: 3px solid var(--c-busy);
	border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
	background: color-mix(in srgb, var(--c-busy) 10%, transparent);
	color: var(--c-busy);
	font-size: var(--fs-sm);
}

/* ==========================================================================
   Beaver Builder — Korrekturen
   ========================================================================== */

.fl-row-content-wrap {
	margin: 0;
}

.fl-row-full-width > .fl-row-content-wrap {
	padding-left: 0;
	padding-right: 0;
}

.fl-row-full-width .fl-row-content {
	max-width: none;
}

/* Abgesetzte Sektionen: Farbe aus den Token, damit sie im Dunkelmodus
   mitschaltet. */
.o-band > .fl-row-content-wrap {
	background-color: var(--c-surface-alt);
}

/* Dunkles Band als kräftiger Gegenpol. */
.o-band--deep > .fl-row-content-wrap {
	background-color: var(--c-deep);
	color: var(--c-on-deep);
}

.o-band--deep h1,
.o-band--deep h2,
.o-band--deep h3 {
	color: #fff;
}

.o-band--deep .o-stats b {
	color: var(--c-deep-accent);
}

.o-band--deep .o-stats span,
.o-band--deep .o-note {
	color: rgb(255 255 255 / 0.65);
}

.o-band--deep .o-amenities li {
	background: rgb(255 255 255 / 0.05);
	border-color: rgb(255 255 255 / 0.12);
}

.o-band--deep .o-amenities svg {
	stroke: var(--c-deep-accent);
}

@media (max-width: 1260px) {
	.fl-row:not(.fl-row-full-width) > .fl-row-content-wrap {
		padding-left: 1.25rem;
		padding-right: 1.25rem;
	}
}

.fl-builder-content h1,
.fl-builder-content h2,
.fl-builder-content h3 {
	font-family: var(--ff-display);
}

/* Dokumentseiten: Ein Textmodul, das eine H1 enthält (Impressum, Datenschutz,
   Buchungsbedingungen, Kontakt), ist ein Fliesstext-Dokument. Dort gelten
   Lese- statt Marketinggrössen — sonst erdrücken die Überschriften die
   kurzen Absätze dazwischen. */
.fl-rich-text:has(h1) h1 {
	font-size: clamp(1.8rem, 1.3rem + 1.6vw, 2.4rem);
}

.fl-rich-text:has(h1) h2 {
	font-size: clamp(1.2rem, 1.05rem + 0.5vw, 1.4rem);
	margin-top: var(--sp-4);
}

.fl-rich-text:has(h1) h3 {
	font-size: 1.1rem;
}

.fl-rich-text > * + * {
	margin-top: var(--sp-2);
}

.fl-rich-text h2 {
	margin-top: 0;
}

.fl-rich-text h3 {
	margin-top: var(--sp-3);
}

.fl-rich-text ul,
.fl-rich-text ol {
	padding-left: 1.25rem;
}

.fl-rich-text li + li {
	margin-top: 0.35rem;
}

.fl-rich-text a:not(.o-btn) {
	color: var(--c-primary);
}

.fl-module-photo img {
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow);
}

/* Steht ein Bild allein neben einer Textspalte, wirkt eine vertikal
   zentrierte Anordnung ruhiger. */
@media (min-width: 768px) {
	.fl-col-group:has(> .fl-col > .fl-col-content > .fl-module-photo:only-child) {
		align-items: center;
	}
}

@media (max-width: 767px) {
	.fl-col + .fl-col {
		margin-top: var(--sp-3);
	}
}

.fl-col-content > .fl-module:first-child > .fl-module-content {
	margin-top: 0;
}

.fl-col-content > .fl-module:last-child > .fl-module-content {
	margin-bottom: 0;
}

/* Der Hero füllt die Fensterbreite; der Standard-Aussenabstand des Builders
   liesse sonst einen 20-px-Rand stehen. */
.fl-module-osterwald-hero > .fl-module-content {
	margin: 0;
}

/* Das Zahlenband als abgesetzte Fläche mit weichen Ecken. */
.o-band--deep > .fl-row-content-wrap {
	border-radius: var(--radius-lg);
	overflow: hidden;
}

@media (max-width: 1260px) {
	.o-band--deep > .fl-row-content-wrap {
		border-radius: 0;
	}
}

/* ==========================================================================
   Wohnungskarten
   ========================================================================== */

/* Beide Karten sollen gleich hoch enden, unabhängig von der Textlänge. */
.o-unitcards .fl-col-group {
	display: flex;
	align-items: stretch;
	flex-wrap: wrap;
}

.o-unitcards .fl-col {
	display: flex;
}

.o-unitcards .fl-col:first-child .fl-col-content {
	margin-right: 0.9rem;
}

.o-unitcards .fl-col:last-child .fl-col-content {
	margin-left: 0.9rem;
}

@media (max-width: 767px) {
	.o-unitcards .fl-col .fl-col-content {
		margin-inline: 0;
	}
}

.o-unitcards .fl-col-content {
	display: flex;
	flex-direction: column;
	flex: 1;
	height: 100%;
	overflow: hidden;
	border: 1px solid var(--c-border);
	border-radius: var(--radius-lg);
	background: var(--c-surface);
	box-shadow: var(--shadow-sm);
	transition: box-shadow 0.4s var(--ease), transform 0.4s var(--ease),
		border-color 0.4s var(--ease-soft);
}

.o-unitcards .fl-col-content:hover {
	border-color: color-mix(in srgb, var(--c-primary) 40%, var(--c-border));
	transform: translateY(-6px);
	box-shadow: var(--shadow-lg);
}

.o-unitcards .fl-module-photo,
.o-unitcards .fl-module-photo .fl-module-content {
	margin: 0;
}

.o-unitcards .fl-module-photo .fl-photo-content {
	overflow: hidden;
}

.o-unitcards .fl-module-photo img {
	width: 100%;
	aspect-ratio: 16 / 11;
	object-fit: cover;
	border-radius: 0;
	box-shadow: none;
	transition: transform 0.7s var(--ease);
}

.o-unitcards .fl-col-content:hover .fl-module-photo img {
	transform: scale(1.05);
}

.o-unitcards .fl-module-rich-text {
	flex: 1;
	display: flex;
}

.o-unitcards .fl-module-rich-text .fl-module-content {
	margin: 0;
	padding: var(--sp-3);
	display: flex;
	flex-direction: column;
	flex: 1;
}

.o-unitcards .fl-rich-text {
	display: flex;
	flex-direction: column;
	flex: 1;
}

.o-unitcards .fl-rich-text h3 {
	margin-top: 0;
}

.o-unitcards .fl-rich-text h3 a {
	color: var(--c-text);
	text-decoration: none;
	transition: color 0.25s var(--ease-soft);
}

.o-unitcards .fl-col-content:hover .fl-rich-text h3 a {
	color: var(--c-primary);
}

.o-unitcards .fl-rich-text .o-note {
	margin-bottom: var(--sp-2);
	padding-bottom: var(--sp-2);
	border-bottom: 1px solid var(--c-border);
}

.o-unitcards .fl-rich-text > p:last-child {
	margin-top: auto;
	margin-bottom: 0;
	padding-top: var(--sp-2);
}

/* ==========================================================================
   Fixierte Buchungsleiste auf schmalen Bildschirmen
   ========================================================================== */

.o-bookingbar {
	position: fixed;
	inset: auto 0 0 0;
	z-index: 90;
	display: none;
	align-items: center;
	justify-content: space-between;
	gap: var(--sp-2);
	padding: 0.7rem 1.1rem calc(0.7rem + env(safe-area-inset-bottom));
	background: color-mix(in srgb, var(--c-surface) 92%, transparent);
	backdrop-filter: blur(14px);
	border-top: 1px solid var(--c-border);
	box-shadow: 0 -4px 20px rgb(36 31 23 / 0.1);
	transform: translateY(110%);
	transition: transform 0.4s var(--ease);
}

.o-bookingbar.is-visible {
	transform: none;
}

.o-bookingbar__price {
	font-size: var(--fs-sm);
	line-height: 1.3;
}

.o-bookingbar__price b {
	display: block;
	font-family: var(--ff-display);
	font-size: 1.25rem;
	font-weight: 600;
	color: var(--c-text);
}

.o-bookingbar__price span {
	color: var(--c-muted);
	font-size: var(--fs-xs);
}

.o-bookingbar .o-btn {
	padding: 0.75em 1.4em;
	white-space: nowrap;
}

@media (max-width: 900px) {
	body:has([data-osb-booking]) .o-bookingbar {
		display: flex;
	}

	body:has([data-osb-booking]) {
		padding-bottom: 4.5rem;
	}
}
