/*
 * Basis: Design-Werte als CSS-Variablen, Grundtypografie, Textstile, Knöpfe.
 * Quelle der Werte ist der verbindliche Entwurf (v24).
 */

/* ---------- 1. Design-Werte ---------- */

:root {
	/* Petrol */
	--kfo-petrol: #0E2A33;
	--kfo-petrol-tief: #0B2730;
	--kfo-petrol-knopf: #06222A;
	--kfo-petrol-linie: #24505D;
	--kfo-petrol-rand: #3A6674;

	/* Cyan */
	--kfo-cyan: #00B8DD;
	--kfo-cyan-text: #00708A;

	/* Messing */
	--kfo-messing: #C9AE78;
	--kfo-messing-mittel: #B89A62;
	--kfo-messing-text: #7A6233;

	/* Flächen und Text */
	--kfo-seite: #F5F8F9;
	--kfo-weiss: #FFFFFF;
	--kfo-text: #1B333B;
	--kfo-text-grau: #4E666E;
	--kfo-linie: #DCE6E9;
	--kfo-rand: #9DB3B9;
	--kfo-hell: #E8F1F3;
	--kfo-hell-2: #C3D5DA;
	--kfo-hell-3: #9FB8BF;

	/* Schrift */
	--kfo-schrift-kopf: Archivo, sans-serif;
	--kfo-schrift-text: Manrope, system-ui, sans-serif;
	--kfo-laufweite-kopf: -0.02em;

	/* Maße */
	--kfo-breite: 1240px;
	--kfo-rand-seite: 32px;
	--kfo-ecke: 4px;
	--kfo-ecke-foto: 16px;
	--kfo-schatten-foto: 0 30px 70px rgba(0, 0, 0, 0.38);
	--kfo-schatten-foto-hell: 0 24px 60px rgba(11, 39, 48, 0.2);
}

/* ---------- 2. Grundlagen ---------- */

html {
	scroll-behavior: smooth;
}

body {
	margin: 0;
	background: var(--kfo-seite);
	color: var(--kfo-text);
	font-family: var(--kfo-schrift-text);
	font-size: 17px;
	line-height: 1.6;
}

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

img {
	max-width: 100%;
}

a {
	color: var(--kfo-cyan-text);
	text-decoration: none;
}

a:hover {
	color: var(--kfo-petrol-tief);
}

button {
	font: inherit;
	cursor: pointer;
}

:focus-visible {
	outline: 2px solid var(--kfo-petrol-tief);
	outline-offset: 3px;
}

/*
 * Fokusrahmen: Auf hellen Flächen dunkel, auf dunklen Flächen (.kfo-dk, Fuß) Cyan.
 * Cyan auf Weiß hätte nur 2,4:1 Kontrast, verlangt sind 3:1 (WCAG 1.4.11).
 */
.kfo-btn:focus-visible,
.kfo-pille-aktiv:focus-visible {
	outline-color: var(--kfo-petrol-tief);
}

.kfo-dk :focus-visible {
	outline-color: var(--kfo-cyan);
}

.kfo-dk .kfo-btn:focus-visible {
	outline-color: var(--kfo-weiss);
}

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

/* ---------- 3. Überschriften und Textstile ---------- */

.kfo-h1-start,
.kfo-h1,
.kfo-h2-gross,
.kfo-h2,
.kfo-h2-mittel,
.kfo-h2-32,
.kfo-h2-27,
.kfo-h3,
.kfo-h3-karte,
.kfo-zahl {
	font-family: var(--kfo-schrift-kopf);
	font-weight: 800;
	letter-spacing: var(--kfo-laufweite-kopf);
	color: var(--kfo-petrol-tief);
}

.kfo-h1-start {
	font-size: clamp(37px, 5vw, 70px);
	line-height: 1.02;
}

.kfo-h1 {
	font-size: clamp(35px, 4.3vw, 61px);
	line-height: 1.04;
}

.kfo-h2-gross {
	font-size: clamp(30px, 3.5vw, 48px);
	line-height: 1.08;
}

.kfo-h2 {
	font-size: clamp(27px, 3vw, 42px);
	line-height: 1.1;
}

.kfo-h2-mittel {
	font-size: clamp(26px, 2.7vw, 37px);
	line-height: 1.12;
}

.kfo-h2-32 {
	font-size: 32px;
	line-height: 1.1;
}

.kfo-h2-27 {
	font-size: 27px;
	line-height: 1.1;
}

.kfo-h3 {
	font-size: 22px;
	line-height: 1.6;
}

.kfo-h3-karte {
	font-size: 27px;
	line-height: 1.6;
}

.kfo-zahl {
	font-size: 51px;
	line-height: 1;
}

/* Hervorhebung in Überschriften: Cyan statt Kursivschrift. */
.kfo-h1-start em,
.kfo-h1 em,
.kfo-h2-gross em,
.kfo-h2 em {
	font-style: normal;
	color: var(--kfo-cyan-text);
}

/* Kleine Zeile über Überschriften. */
.kfo-dachzeile {
	font-family: var(--kfo-schrift-text);
	font-size: 12.5px;
	line-height: 1.6;
	letter-spacing: 0.26em;
	text-transform: uppercase;
	font-weight: 600;
	color: var(--kfo-messing-text);
}

.kfo-dachzeile a,
.kfo-dachzeile a:hover,
.kfo-dk .kfo-dachzeile a,
.kfo-dk .kfo-dachzeile a:hover {
	color: inherit;
}

/* Der Link hat die Farbe des Textes daneben. Die Unterstreichung macht ihn als Link erkennbar (WCAG 1.4.1). */
.kfo-dachzeile a {
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
}

.kfo-dachzeile a:hover {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.kfo-lead {
	font-size: 20px;
	line-height: 1.6;
}

.kfo-lead-eng {
	font-size: 20px;
	line-height: 1.55;
}

.kfo-grau {
	color: var(--kfo-text-grau);
}

.kfo-klein {
	font-size: 15.5px;
}

.kfo-kleiner {
	font-size: 15px;
}

.kfo-hinweis {
	font-size: 14px;
}

.kfo-cyan {
	color: var(--kfo-cyan-text);
	font-weight: 600;
}

.kfo-gross-19 {
	font-size: 19px;
}

/* ---------- 4. Dunkle Abschnitte ---------- */

.kfo-dk {
	background: var(--kfo-petrol);
	color: var(--kfo-hell);
}

.kfo-dk .kfo-h1-start,
.kfo-dk .kfo-h1,
.kfo-dk .kfo-h2-gross,
.kfo-dk .kfo-h2,
.kfo-dk .kfo-h2-mittel {
	color: var(--kfo-hell);
}

.kfo-dk .kfo-h1-start em,
.kfo-dk .kfo-h1 em,
.kfo-dk .kfo-h2-gross em,
.kfo-dk .kfo-h2 em {
	color: var(--kfo-cyan);
}

.kfo-dk .kfo-dachzeile {
	/* Etwas heller als --kfo-messing: Auf dem hellsten Teil des Verlaufs sonst nur 4,45:1 statt 4,5:1 (WCAG 1.4.3). */
	color: #D2B985;
}

.kfo-dk .kfo-lead,
.kfo-dk .kfo-lead-eng,
.kfo-dk .kfo-hell-2 {
	color: var(--kfo-hell-2);
}

.kfo-dk .kfo-hell-3,
.kfo-dk .kfo-hinweis {
	color: var(--kfo-hell-3);
}

.kfo-dk a {
	color: var(--kfo-hell);
}

.kfo-dk a:hover {
	color: var(--kfo-cyan);
}

.kfo-dk strong {
	color: var(--kfo-messing);
}

/* Dunkler Seitenkopf mit weichem, langsam wanderndem Lichtschein. */
.kfo-band {
	position: relative;
	overflow: hidden;
	background:
		radial-gradient(900px 540px at 80% 12%, rgba(0, 184, 221, 0.24), rgba(0, 184, 221, 0) 62%),
		radial-gradient(720px 480px at 4% 108%, rgba(201, 174, 120, 0.12), rgba(201, 174, 120, 0) 60%),
		var(--kfo-petrol);
}

.kfo-band::before {
	content: "";
	position: absolute;
	inset: -30%;
	background: radial-gradient(closest-side at 62% 38%, rgba(0, 184, 221, 0.2), rgba(0, 184, 221, 0) 70%);
	/* Läuft einmal und endet nach 5 Sekunden: Bewegung, die länger dauert, müsste sich anhalten lassen (WCAG 2.2.2). */
	animation: kfo-drift 5s ease-in-out 1 both;
	pointer-events: none;
}

@keyframes kfo-drift {
	from {
		transform: translate(-10%, -6%);
	}

	to {
		transform: translate(12%, 8%);
	}
}

@keyframes kfo-rise {
	from {
		opacity: 0;
		transform: translateY(16px);
	}

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

.kfo-rise {
	animation: kfo-rise 0.8s 0.2s ease-out both;
}

@media (prefers-reduced-motion: reduce) {
	.kfo-rise,
	.kfo-band::before {
		animation: none;
	}
}

/* ---------- 5. Knöpfe und Textlinks ---------- */

/* Kadence-Knopfreihe: Abstände wie im Entwurf. */
.wp-block-kadence-advancedbtn.kb-buttons-wrap {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-start;
	gap: 16px 28px;
}

.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-btn,
.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-link,
.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-btn-rahmen,
.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-pille,
.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-pille-dk {
	display: inline-block;
	margin: 0;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	font-family: var(--kfo-schrift-text);
	font-size: inherit;
	line-height: 1.6;
	letter-spacing: 0;
	text-transform: none;
	text-decoration: none;
	transition: color 0.15s ease, background-color 0.15s ease;
}

/* Hauptknopf: Cyan-Pille. */
.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-btn,
.kfo-btn,
.kfo-btn:hover,
.kfo-dk .kfo-btn,
.kfo-dk .kfo-btn:hover {
	--kb-btn-padding: 16px 32px;
	display: inline-block;
	background: var(--kfo-cyan);
	color: var(--kfo-petrol-knopf);
	padding: 16px 32px;
	border-radius: 999px;
	font-weight: 700;
	text-align: center;
}

/* Textlink mit Messing-Unterstreichung. */
.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-link {
	--kb-btn-padding: 12px 0;
	padding: 12px 0;
	border-bottom: 1px solid var(--kfo-messing-mittel);
	font-weight: 700;
	color: var(--kfo-cyan-text);
}

.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-link:hover {
	color: var(--kfo-petrol-tief);
}

.kfo-dk .wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-link {
	border-bottom-color: var(--kfo-messing);
	color: var(--kfo-hell);
}

.kfo-dk .wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-link:hover {
	color: var(--kfo-cyan);
}

.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-link.kfo-link-600 {
	--kb-btn-padding: 14px 0;
	font-weight: 600;
	padding: 14px 0;
}

.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-link.kfo-link-8 {
	--kb-btn-padding: 8px 0;
	padding: 8px 0;
}

.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-link.kfo-link-10 {
	--kb-btn-padding: 10px 0;
	padding: 10px 0;
}

/* Knopf mit Rahmen. */
.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-btn-rahmen {
	--kb-btn-padding: 14px 28px;
	border: 1px solid var(--kfo-petrol-tief);
	color: var(--kfo-petrol-tief);
	padding: 14px 28px;
	border-radius: 999px;
	font-weight: 700;
}

.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-btn-rahmen:hover {
	background: var(--kfo-petrol-tief);
	color: var(--kfo-weiss);
}

/* Kleine Pillen (weitere Leistungen). */
.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-pille {
	--kb-btn-padding: 11px 20px;
	border: 1px solid var(--kfo-rand);
	color: var(--kfo-petrol-tief);
	padding: 11px 20px;
	border-radius: 999px;
	font-weight: 600;
	font-size: 15.5px;
}

.wp-block-kadence-advancedbtn.kb-buttons-wrap .kb-button.kfo-pille:hover {
	border-color: var(--kfo-cyan-text);
	color: var(--kfo-cyan-text);
}

.wp-block-kadence-advancedbtn.kb-buttons-wrap.kfo-pillen {
	gap: 10px;
}

/* ---------- 6. Abstände (Werte aus dem Entwurf) ---------- */

.kfo-mt-0 { margin-top: 0; }
.kfo-mt-2 { margin-top: 2px; }
.kfo-mt-4 { margin-top: 4px; }
.kfo-mt-6 { margin-top: 6px; }
.kfo-mt-8 { margin-top: 8px; }
.kfo-mt-10 { margin-top: 10px; }
.kfo-mt-12 { margin-top: 12px; }
.kfo-mt-14 { margin-top: 14px; }
.kfo-mt-16 { margin-top: 16px; }
.kfo-mt-18 { margin-top: 18px; }
.kfo-mt-20 { margin-top: 20px; }
.kfo-mt-24 { margin-top: 24px; }
.kfo-mt-28 { margin-top: 28px; }
.kfo-mt-32 { margin-top: 32px; }
.kfo-mt-36 { margin-top: 36px; }
.kfo-mt-40 { margin-top: 40px; }
.kfo-mt-48 { margin-top: 48px; }
.kfo-mt-56 { margin-top: 56px; }

.kfo-mw-440 { max-width: 440px; }
.kfo-mw-460 { max-width: 460px; }
.kfo-mw-500 { max-width: 500px; }
.kfo-mw-520 { max-width: 520px; }
.kfo-mw-560 { max-width: 560px; }
.kfo-mw-600 { max-width: 600px; }
.kfo-mw-640 { max-width: 640px; }

/* Nur für Screenreader sichtbar. */
.kfo-sr {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}
