/*
Theme Name: Canes Varii
Theme URI: https://canesvarii.de
Author: Canes Varii
Description: Mittelalterlich-elegantes Block-Theme für die Living-History-Gruppe Canes Varii. Ein-Seiten-Layout mit sanftem Scroll-Gleiten, Pillen-Header und pflegbaren Inhalten (Termine & Galerie) über eigene Inhaltstypen.
Requires at least: 6.5
Tested up to: 6.7
Requires PHP: 7.4
Version: 2.6.0
License: GNU General Public License v2 or later
License URI: LICENSE
Text Domain: canes-varii
*/

/* ==========================================================
   0. EIGENE SCHRIFT (selbst gehostet, kein externer Aufruf nötig)
   ========================================================== */

@font-face {
	font-family: 'Humanistic';
	src: url('assets/fonts/humanistic-medium.ttf') format('truetype');
	font-weight: 500;
	font-style: normal;
	font-display: swap;
}

/* ==========================================================
   1. GRUNDLAGEN & RESET
   ========================================================== */

:root {
	--cv-black: #111111;
	--cv-dark-green: #1a331e;
	--cv-sage: #4a5d52;
	--cv-parchment: #e8dcc0;
	--cv-parchment-dark: #d8c6a0;
	--cv-gold: #b08d38;

	--cv-header-height-desktop: 88px;
	--cv-header-height-mobile: 72px;
}

html {
	scroll-behavior: smooth;
	overflow-x: hidden;
}

/* Während das eigene JS-Scroll-Gleiten läuft, muss CSS scroll-behavior kurz aus
   dem Weg gehen - sonst überlagern sich beide Animationen und es ruckelt. */
html.js-scrolling {
	scroll-behavior: auto !important;
}

* {
	box-sizing: border-box;
}

body {
	overflow-x: hidden;
	max-width: 100%;
	background-color: var(--cv-parchment);
	background-image:
		repeating-linear-gradient(0deg, rgba(0,0,0,0.02) 0px, rgba(0,0,0,0.02) 1px, transparent 1px, transparent 3px),
		radial-gradient(ellipse at top left, rgba(255,255,255,0.15), transparent 60%),
		radial-gradient(ellipse at bottom right, rgba(0,0,0,0.08), transparent 60%);
	background-blend-mode: multiply;
}

.wp-site-blocks {
	position: relative;
}

img {
	max-width: 100%;
	height: auto;
}

/* Ruhigere Bewegungen für Menschen, die das wünschen */
@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
	*, *::before, *::after {
		animation-duration: 0.001ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.001ms !important;
	}
}

/* ==========================================================
   2. TYPOGRAFIE & ORNAMENTIK (bewusst zurückhaltend eingesetzt)
   ========================================================== */

h1, h2, h3, h4, h5, h6 {
	letter-spacing: 0.02em;
}

/* Signatur-Ornament: EIN wiederkehrendes Zeichen unter den Sektions-Überschriften */
.cv-panel h2.wp-block-heading::after,
#schedule h2.wp-block-heading::after {
	content: "❦";
	display: block;
	margin: 0.35em auto 0;
	font-size: 1.1rem;
	color: var(--cv-sage);
	opacity: 0.85;
}

a {
	text-decoration: underline;
	text-decoration-style: dotted;
	text-underline-offset: 3px;
}

/* Wiederverwendbares Listen-Zeichen (nur dort, wo bewusst eingesetzt) */
.cv-fleur-list li {
	list-style: none;
	position: relative;
	padding-left: 1.5em;
	margin-bottom: 0.4em;
}
.cv-fleur-list li::before {
	content: "⚜";
	position: absolute;
	left: 0;
	color: var(--cv-dark-green);
}

/* ==========================================================
   3. WIEDERVERWENDBARE BUTTON-KOMPONENTE
   (für heutige Formular-Buttons UND künftige Call-to-Actions)
   ========================================================== */

.cv-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 14px 38px !important;
	border-radius: 999px !important;
	border: 2px solid var(--cv-gold) !important;
	background: transparent !important;
	color: inherit;
	font-family: var(--wp--preset--font-family--heading);
	font-size: 1rem !important;
	font-weight: 700 !important;
	letter-spacing: 0.05em;
	text-decoration: none !important;
	cursor: pointer;
	transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease, transform 0.2s ease;
}

.cv-btn:hover {
	background: var(--cv-gold) !important;
	color: var(--cv-black) !important;
	box-shadow: 0 0 20px rgba(176, 141, 56, 0.45);
	transform: translateY(-2px);
}

/* Gefüllte Variante für den jeweiligen Haupt-Call-to-Action einer Sektion */
.cv-btn--solid {
	background: var(--cv-gold) !important;
	color: var(--cv-black) !important;
}
.cv-btn--solid:hover {
	background: transparent !important;
	color: inherit !important;
}

/* ==========================================================
   4. HEADER: PILLEN-NAVIGATION
   ========================================================== */

.magischer-header {
	background: var(--cv-black);
	color: var(--cv-parchment);
	padding: 14px 28px;
	transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	max-width: 100%;
	margin: 0;
	border-radius: 0;
	box-shadow: none;
	z-index: 9999;
}

.magischer-header > .wp-block-group {
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	gap: 24px;
}

.magischer-header.scrolled {
	background: rgba(17, 17, 17, 0.92);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	width: 100%;
	max-width: 1160px;
	top: 14px;
	left: 50%;
	transform: translateX(-50%);
	border-radius: 50px;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
	padding: 8px 32px;
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
	.magischer-header.scrolled {
		background: var(--cv-black);
	}
}

.magischer-header .wp-block-site-logo img {
	max-height: 42px;
	width: auto;
}

.magischer-header .wp-block-site-title a,
.magischer-header .wp-block-site-title {
	font-family: 'Humanistic', serif !important;
	font-size: 1.9rem !important;
	font-weight: normal !important;
	color: var(--cv-parchment) !important;
	letter-spacing: 0.03em;
	text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
	transition: color 0.3s ease;
}
.magischer-header .wp-block-site-title a:hover {
	color: var(--cv-gold) !important;
	text-decoration: none !important;
}

.magischer-header .wp-block-navigation-item a {
	font-family: var(--wp--preset--font-family--body) !important;
	font-size: 1.02rem !important;
	font-weight: 500;
	letter-spacing: 0.04em;
	padding: 6px 0;
	position: relative;
	text-decoration: none !important;
	transition: color 0.3s ease;
}
.magischer-header .wp-block-navigation-item a:hover {
	color: var(--cv-gold) !important;
}
.magischer-header .wp-block-navigation-item a::after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 50%;
	width: 0;
	height: 1px;
	background-color: var(--cv-gold);
	transition: width 0.3s ease, left 0.3s ease;
}
.magischer-header .wp-block-navigation-item a:hover::after {
	width: 100%;
	left: 0;
}
.magischer-header .wp-block-navigation-item {
	margin-left: 26px !important;
}

@media (max-width: 767px) {
	.magischer-header {
		padding: 10px 16px;
	}
	.magischer-header.scrolled {
		width: 92%;
		max-width: 500px;
		padding: 6px 16px;
	}
	.magischer-header .wp-block-site-title a {
		font-size: 1.4rem !important;
	}
	.magischer-header .wp-block-navigation__responsive-container.is-menu-open {
		position: fixed !important;
		top: 0 !important;
		left: 0 !important;
		width: 100vw !important;
		height: 100vh !important;
		background: var(--cv-black) !important;
		z-index: 100000 !important;
		display: flex !important;
		flex-direction: column !important;
		align-items: center !important;
		justify-content: center !important;
		padding: 40px !important;
		box-sizing: border-box !important;
	}
	.magischer-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
		display: flex !important;
		flex-direction: column !important;
		align-items: center !important;
		gap: 30px !important;
		width: 100% !important;
	}
	.magischer-header .wp-block-navigation__responsive-container.is-menu-open a {
		font-family: var(--wp--preset--font-family--heading) !important;
		color: var(--cv-parchment) !important;
		font-size: 1.7rem !important;
	}
	.magischer-header .wp-block-navigation-item {
		margin-left: 0 !important;
	}
}

/* ==========================================================
   5. SEKTIONS-GRUNDGERÜST (snap-abschnitt)
   ========================================================== */

.snap-abschnitt {
	min-height: 100vh;
	width: 100%;
	position: relative;
	box-sizing: border-box;
	scroll-margin-top: 0; /* Zielposition wird von JS exakt berechnet, siehe canes-varii.js */
}

/* Kontakt ist die einzige Sektion ohne erzwungene Vollbild-Höhe */
#contact.snap-abschnitt {
	min-height: auto;
}

/* ==========================================================
   6. WIEDERVERWENDBARES INHALTS-PANEL
   (About, Termine, Kontakt & künftige Sektionen teilen sich diese Bausteine)
   ========================================================== */

.cv-panel {
	max-width: 1100px;
	width: 100%;
	margin: 0 auto;
	padding: clamp(100px, 20vw, 150px) clamp(20px, 5vw, 60px) clamp(56px, 8vw, 90px);
	box-sizing: border-box;
	position: relative;
}

.snap-abschnitt:not(.hero-bereich):not(#gallery) {
	display: flex;
	align-items: center;
	justify-content: center;
}

/* Helle Variante: gealtertes Pergament, für About & künftige "helle" Sektionen */
.cv-panel--light {
	background-color: var(--cv-parchment);
	background-image:
		repeating-linear-gradient(0deg, rgba(0,0,0,0.025) 0px, rgba(0,0,0,0.025) 1px, transparent 1px, transparent 3px),
		radial-gradient(ellipse at top left, rgba(255,255,255,0.3), transparent 60%),
		radial-gradient(ellipse at bottom right, rgba(0,0,0,0.07), transparent 60%);
	background-blend-mode: multiply;
	border-radius: 6px;
	border: 1px solid var(--cv-dark-green);
	outline: 4px double var(--cv-black);
	outline-offset: -10px;
	box-shadow: 0 20px 45px rgba(0, 0, 0, 0.25);
	color: var(--cv-black);
}

/* Dunkle Variante: Wappen-Farben, für Termine & künftige "dunkle" Sektionen */
.cv-panel--dark {
	background-color: var(--cv-black);
	background-image: radial-gradient(ellipse at center, var(--cv-dark-green) 0%, var(--cv-black) 100%);
	border-radius: 6px;
	border: 2px solid var(--cv-gold);
	box-shadow: 0 25px 50px rgba(0, 0, 0, 0.6);
	color: var(--cv-parchment);
}

.cv-panel--light h2.wp-block-heading,
.cv-panel--dark h2.wp-block-heading {
	font-family: var(--wp--preset--font-family--heading) !important;
	font-size: clamp(2.1rem, 4vw, 3rem) !important;
	text-align: center !important;
	margin-top: 0 !important;
	margin-bottom: 0.2em !important;
	width: 100% !important;
	display: block !important;
}
.cv-panel--light h2.wp-block-heading { color: var(--cv-dark-green) !important; }
.cv-panel--dark h2.wp-block-heading { color: var(--cv-parchment) !important; text-shadow: 2px 2px 4px rgba(0,0,0,0.8); }

.cv-panel-intro {
	font-family: Georgia, serif;
	text-align: center;
	max-width: 640px;
	margin: 0.6em auto 2.2em auto;
	opacity: 0.9;
	line-height: 1.6;
}

/* ==========================================================
   7. HERO
   ========================================================== */

.hero-bereich {
	padding: 0;
}

.hero-bereich .wp-block-cover {
	border: none;
	outline: none;
	padding: 0;
}

.helden-text-box {
	max-width: 650px;
	margin-left: 8%;
	margin-right: auto;
	text-align: left;
}

.titel-wappen-wrapper {
	display: flex;
	align-items: center;
	gap: 25px;
	margin-bottom: 15px;
}

.helden-wappen {
	max-height: 150px;
	width: auto;
	filter: drop-shadow(2px 2px 5px rgba(0,0,0,0.6));
}

h1.wp-block-heading.helden-titel {
	font-family: 'Humanistic', serif !important;
	font-size: clamp(2.6rem, 6vw, 4.6rem) !important;
	line-height: 1.1 !important;
	color: var(--cv-parchment) !important;
	text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.9) !important;
	margin: 0 !important;
}

.helden-slogan {
	font-family: Georgia, serif !important;
	font-size: clamp(1.15rem, 2.2vw, 1.7rem) !important;
	color: var(--cv-gold) !important;
	text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.9) !important;
	margin: 0 !important;
	font-style: italic;
}

@media (max-width: 767px) {
	.helden-text-box {
		margin-left: auto;
		margin-right: auto;
		text-align: center;
		padding: 0 20px;
	}
	.titel-wappen-wrapper {
		flex-direction: column;
		gap: 15px;
	}
	.helden-wappen {
		max-height: 100px;
	}
}

.lagerfeuer-scroll-wrapper {
	position: absolute;
	bottom: 8vh;
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 15px;
	z-index: 99;
	width: 100%;
	text-align: center;
}

.wp-block-cover.alignfull {
	position: relative;
}

.lagerfeuer-text {
	font-family: Georgia, serif;
	font-size: 1.15rem;
	font-style: italic;
	color: var(--cv-parchment);
	text-shadow: 2px 2px 6px rgba(0,0,0,0.9);
	letter-spacing: 0.05em;
	white-space: nowrap;
}

.lagerfeuer-button {
	width: 72px;
	height: 72px;
	background-color: transparent;
	border: 3px solid var(--cv-gold);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
	box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
	transition: all 0.3s ease-in-out;
	position: relative;
}
.lagerfeuer-chevron {
	width: 30px;
	height: 30px;
	color: var(--cv-gold);
	transition: transform 0.3s ease-in-out, color 0.3s ease-in-out;
	animation: pfeil-schweben 2s infinite ease-in-out;
}
.lagerfeuer-button:hover {
	background-color: var(--cv-gold);
	box-shadow: 0 0 25px rgba(176, 141, 56, 0.7);
	transform: scale(1.08);
}
.lagerfeuer-button:hover .lagerfeuer-chevron {
	color: var(--cv-black);
}
@keyframes pfeil-schweben {
	0%, 100% { transform: translateY(-2px); }
	50%      { transform: translateY(4px); }
}
@media (prefers-reduced-motion: reduce) {
	.lagerfeuer-chevron { animation: none; }
}

/* ==========================================================
   8. ABOUT / CHRONIK (helle Sektion)
   ========================================================== */

.about-chronik-container p {
	font-family: Georgia, serif;
	font-size: 1.2rem;
	line-height: 1.8;
	color: var(--cv-black);
	text-align: justify;
	margin: 0;
}

.chronik-absatz-voll {
	max-width: 900px;
	margin: 0 auto 55px auto;
}
.chronik-absatz-voll p {
	text-align: center;
	font-style: italic;
	font-size: 1.3rem;
}

.chronik-block {
	margin-bottom: 55px;
}
.chronik-block:last-child {
	margin-bottom: 0;
}

@media (min-width: 992px) {
	.chronik-block {
		display: flex;
		flex-direction: row;
		flex-wrap: nowrap;
		align-items: center;
		gap: 56px;
	}
	.chronik-text {
		flex: 0 0 52%;
		max-width: 52%;
	}
	.chronik-bild {
		flex: 0 0 44%;
		max-width: 44%;
	}
	/* Reihenfolge im HTML ist für beide Blöcke bewusst text-dann-bild (damit
	   mobil sauber text-foto-text-foto alterniert, siehe unten). Die
	   sichtbare Desktop-Anordnung wird stattdessen über "order" gesteuert:
	   Block 1 = Foto links, Text rechts. Block 2 = Text links, Foto rechts. */
	.bild-links .chronik-bild { order: 1; }
	.bild-links .chronik-text { order: 2; }
	.bild-rechts .chronik-text { order: 1; }
	.bild-rechts .chronik-bild { order: 2; }
}

.chronik-text p::first-letter {
	font-family: 'Humanistic', serif;
	font-size: 3.6rem;
	float: left;
	line-height: 0.82;
	margin: 6px 12px 0 2px;
	color: var(--cv-dark-green);
}

.chronik-bild img {
	width: 100%;
	height: auto;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	border: 6px solid #ffffff;
	outline: 1px solid var(--cv-parchment-dark);
	box-shadow: 0 10px 25px rgba(0, 0, 0, 0.18);
	border-radius: 4px;
	display: block;
}

.chronik-abschluss-name {
	font-family: 'Humanistic', serif;
	font-size: clamp(2rem, 4vw, 2.7rem);
	color: var(--cv-dark-green);
	text-align: center;
	width: 100%;
	margin-top: 40px;
	clear: both;
}

@media (max-width: 991px) {
	.chronik-block {
		display: block;
	}
	.chronik-text,
	.chronik-bild {
		width: 100%;
		max-width: 100%;
		margin: 0 0 22px 0;
	}
	.chronik-text p::first-letter {
		float: none;
		display: inline;
		font-size: inherit;
		font-family: inherit;
		color: inherit;
		margin: 0;
	}
	.about-chronik-container p {
		text-align: left;
		font-size: 1.1rem;
	}
	.chronik-absatz-voll p {
		text-align: center;
	}
	.chronik-bild img {
		max-width: 420px;
		margin: 0 auto;
	}
}

/* ==========================================================
   9. TERMINE / SCHAUTAFEL (dunkle Sektion)
   ========================================================== */

.termine-sektion-titel {
	font-family: var(--wp--preset--font-family--heading);
	font-size: 1.7rem;
	color: var(--cv-gold);
	margin: 10px 0 22px 0;
	text-align: center;
	border-bottom: 1px dashed rgba(232, 220, 192, 0.2);
	padding-bottom: 10px;
}
.termine-sektion-titel.archiv-titel {
	color: #9a9a9a;
}

.termine-trenner {
	text-align: center;
	font-size: 1.4rem;
	color: rgba(232, 220, 192, 0.25);
	margin: 45px 0;
	letter-spacing: 10px;
}

.termine-liste-wrapper {
	display: flex;
	flex-direction: column;
	gap: 22px;
	width: 100%;
}

.termin-karte {
	display: flex;
	flex-direction: row;
	gap: 28px;
	align-items: center;
	background: var(--cv-parchment);
	background-image: repeating-linear-gradient(0deg, rgba(0,0,0,0.01) 0px, rgba(0,0,0,0.01) 1px, transparent 1px, transparent 3px);
	border: 1px solid var(--cv-gold);
	padding: 22px;
	border-radius: 4px;
	box-shadow: 3px 3px 12px rgba(0, 0, 0, 0.4);
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.termin-karte:hover {
	transform: translateY(-3px);
	box-shadow: 5px 8px 20px rgba(0, 0, 0, 0.6);
}

.termin-bild-spalte {
	flex: 0 0 26%;
	width: 26%;
}
.termin-bild-spalte img,
.termin-bild-spalte iframe {
	width: 100%;
	aspect-ratio: 16 / 10;
	object-fit: cover;
	border: 4px solid var(--cv-black);
	box-shadow: 2px 2px 6px rgba(0,0,0,0.3);
	display: block;
}
.termin-bild-spalte--platzhalter {
	width: 100%;
	aspect-ratio: 16 / 10;
	background: var(--cv-parchment-dark);
	border: 4px solid var(--cv-black);
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--cv-dark-green);
	font-size: 1.6rem;
}

.termin-info-spalte {
	flex: 1 1 auto;
	display: flex;
	flex-direction: column;
	gap: 6px;
	min-width: 0;
}

.termin-datum-badge {
	font-family: Georgia, serif;
	font-size: 0.92rem;
	font-weight: bold;
	color: var(--cv-dark-green);
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

h3.termin-titel {
	font-family: Georgia, serif;
	font-size: 1.35rem;
	color: var(--cv-black);
	margin: 0;
	font-weight: bold;
}

.termin-fotos-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	align-self: flex-start;
	background: none;
	border: none;
	padding: 0;
	margin: 0;
	font-family: Georgia, serif;
	font-size: 0.92rem;
	color: var(--cv-dark-green);
	font-style: italic;
	text-decoration: underline;
	text-decoration-style: dotted;
	text-underline-offset: 2px;
	cursor: pointer;
	transition: color 0.2s ease;
}
.termin-fotos-btn:hover {
	color: var(--cv-gold);
}
.termin-fotos-btn svg {
	width: 14px;
	height: 14px;
	flex-shrink: 0;
	fill: currentColor;
}

.termin-beschreibung {
	font-size: 1.05rem;
	line-height: 1.5;
	text-align: left;
	color: #222222;
	margin: 0;
}

.termin-karte.termin-ist-archiv {
	background: var(--cv-parchment-dark);
	border-color: #888888;
	opacity: 0.8;
}
.termin-karte.termin-ist-archiv .termin-bild-spalte img {
	filter: grayscale(100%) sepia(15%);
	border-color: #555555;
}
.termin-karte.termin-ist-archiv h3.termin-titel,
.termin-karte.termin-ist-archiv .termin-beschreibung {
	color: #444444;
}

.keine-termine {
	text-align: center;
	font-style: italic;
	opacity: 0.8;
}

@media (max-width: 767px) {
	.termin-karte {
		display: block;
		text-align: center;
		padding: 20px 16px;
	}
	.termin-bild-spalte,
	.termin-bild-spalte--platzhalter,
	.termin-info-spalte {
		width: 100%;
	}
	.termin-bild-spalte img,
	.termin-bild-spalte iframe,
	.termin-bild-spalte--platzhalter {
		max-width: 280px;
		margin: 0 auto 15px auto;
	}
	.termin-fotos-btn {
		justify-content: center;
		align-self: center;
	}
	.termin-beschreibung {
		text-align: center;
	}
}

/* ==========================================================
   10. GALERIE: BILDSCHIRMFÜLLENDER ENDLOS-SLIDER
   ========================================================== */

#gallery.snap-abschnitt {
	height: 100vh;
	min-height: 100vh;
	overflow: hidden;
	background-color: var(--cv-black);
}

.galerie-slider-viewport {
	width: 100%;
	height: 100%;
	overflow: hidden;
	position: relative;
}

.galerie-slider-track {
	display: flex;
	align-items: center;
	height: 100%;
	width: max-content;
	animation: galerie-rotieren 46s linear infinite;
}
.galerie-slider-track:hover {
	animation-play-state: paused;
}

.galerie-bild {
	flex: 0 0 auto;
	height: 100%;
	margin: 0;
}
.galerie-bild img {
	display: block;
	height: 100%;
	width: auto;
	max-width: none;
	object-fit: cover;
}

@keyframes galerie-rotieren {
	from { transform: translateX(0); }
	to   { transform: translateX(-50%); }
}

@media (max-width: 767px) {
	.galerie-slider-track {
		animation-duration: 28s;
	}
}

.galerie-leer-hinweis {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--cv-parchment);
	font-family: Georgia, serif;
	font-style: italic;
	text-align: center;
	padding: 0 20px;
	opacity: 0.7;
}

/* ==========================================================
   11. KONTAKT (helle Sektion)
   ========================================================== */

.kontakt-formular-wrapper .wpforms-field-label,
.kontakt-formular-wrapper .wpforms-title,
.kontakt-formular-wrapper .wpforms-description,
.kontakt-formular-wrapper .wpforms-field-description {
	color: var(--cv-black) !important;
}
.kontakt-formular-wrapper .wpforms-required-label {
	color: var(--cv-dark-green) !important;
}
.kontakt-formular-wrapper input:not([type="checkbox"]):not([type="radio"]),
.kontakt-formular-wrapper textarea,
.kontakt-formular-wrapper select {
	background-color: rgba(255,255,255,0.6) !important;
	border: 1px solid var(--cv-parchment-dark) !important;
	border-radius: 4px !important;
}
.kontakt-formular-wrapper .wpforms-submit {
	background-color: transparent !important;
	color: var(--cv-black) !important;
	border: 2px solid var(--cv-gold) !important;
	border-radius: 999px !important;
	padding: 12px 28px !important;
	font-weight: bold !important;
	transition: background-color 0.3s ease-in-out, color 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
	/* Verhindert Überlauf bei längeren Button-Texten auf schmalen Bildschirmen */
	display: inline-block !important;
	box-sizing: border-box !important;
	width: auto !important;
	max-width: 100% !important;
	height: auto !important;
	white-space: normal !important;
	line-height: 1.3 !important;
	text-align: center !important;
	word-break: break-word;
}
.kontakt-formular-wrapper .wpforms-submit:hover {
	background-color: var(--cv-gold) !important;
	color: var(--cv-black) !important;
	box-shadow: 0 0 15px rgba(176, 141, 56, 0.4) !important;
	cursor: pointer;
}

/* Kein Formular-Plugin aktiv: freundlicher Ersatz-Hinweis statt Leerstelle */
.kontakt-fallback {
	text-align: center;
	max-width: 480px;
	margin: 0 auto;
	font-style: italic;
	opacity: 0.85;
}

/* ==========================================================
   12. FOOTER
   ========================================================== */

.magischer-footer {
	background-color: var(--cv-black);
	color: var(--cv-parchment);
	padding: 50px 24px 30px;
}
.magischer-footer a {
	color: var(--cv-parchment);
	text-decoration-color: var(--cv-gold);
}
.magischer-footer a:hover {
	color: var(--cv-gold);
}
.cv-footer-inner {
	max-width: 1100px;
	margin: 0 auto;
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: flex-start;
	gap: 30px;
}
.cv-footer-brand {
	font-family: 'Humanistic', serif;
	font-size: 1.6rem;
	color: var(--cv-parchment);
}
.cv-footer-links {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 24px;
	font-size: 0.95rem;
	list-style: none;
	margin: 0;
	padding: 0;
}
.cv-footer-meta {
	width: 100%;
	text-align: center;
	font-size: 0.85rem;
	opacity: 0.6;
	margin-top: 30px;
	padding-top: 20px;
	border-top: 1px solid rgba(232, 220, 192, 0.15);
}

@media (max-width: 600px) {
	.cv-footer-inner {
		flex-direction: column;
		align-items: center;
		text-align: center;
	}
}

/* ==========================================================
   13. GENERISCHE SEITE (Impressum, Datenschutz, ...)
   ========================================================== */

.cv-standard-seite {
	max-width: 800px;
	margin: 140px auto 80px auto;
	padding: 0 24px;
}
.cv-standard-seite h1 {
	font-family: var(--wp--preset--font-family--heading);
	color: var(--cv-dark-green);
	font-size: clamp(2rem, 4vw, 2.6rem);
}
.cv-standard-seite h2 {
	font-family: var(--wp--preset--font-family--heading);
	color: var(--cv-dark-green);
	font-size: 1.4rem;
	margin-top: 2em;
}
.cv-standard-seite p, .cv-standard-seite li {
	font-family: Georgia, serif;
	line-height: 1.7;
}

@media (max-width: 600px) {
	.cv-standard-seite {
		margin-top: 110px;
	}
}

/* ==========================================================
   14. GROSSBILDSCHIRME (4K & darüber)
   ========================================================== */

@media (min-width: 1920px) {
	.helden-titel { font-size: 5rem !important; }
	.cv-panel { max-width: 1200px; }
}

/* ==========================================================
   15. FOTO-VIEWER (Lightbox für "Fotos ansehen" bei Terminen)
   ========================================================== */

.cv-foto-viewer {
	position: fixed;
	inset: 0;
	background: rgba(10, 10, 10, 0.94);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 100000;
	padding: 60px;
	box-sizing: border-box;
}
.cv-foto-viewer.ist-offen {
	display: flex;
}
body.cv-foto-viewer-aktiv {
	overflow: hidden;
}

.cv-foto-viewer-bild {
	max-width: min(88vw, 1300px);
	max-height: 82vh;
	object-fit: contain;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
	border-radius: 4px;
}

.cv-foto-viewer-schliessen {
	position: absolute;
	top: 24px;
	right: 32px;
	background: none;
	border: none;
	color: var(--cv-parchment);
	font-size: 2.4rem;
	line-height: 1;
	cursor: pointer;
	transition: color 0.2s ease;
}
.cv-foto-viewer-schliessen:hover {
	color: var(--cv-gold);
}

.cv-foto-viewer-pfeil {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	background: rgba(232, 220, 192, 0.08);
	border: 2px solid var(--cv-gold);
	color: var(--cv-parchment);
	width: 52px;
	height: 52px;
	border-radius: 50%;
	font-size: 1.8rem;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background-color 0.2s ease, color 0.2s ease;
}
.cv-foto-viewer-pfeil:hover {
	background: var(--cv-gold);
	color: var(--cv-black);
}
.cv-foto-viewer-zurueck { left: 24px; }
.cv-foto-viewer-weiter { right: 24px; }

@media (max-width: 600px) {
	.cv-foto-viewer {
		padding: 16px;
	}
	.cv-foto-viewer-pfeil {
		width: 42px;
		height: 42px;
		font-size: 1.4rem;
	}
	.cv-foto-viewer-zurueck { left: 8px; }
	.cv-foto-viewer-weiter { right: 8px; }
	.cv-foto-viewer-schliessen {
		top: 12px;
		right: 16px;
	}
}

/* ==========================================================
   16. MITGLIEDERBEREICH (Login, Termine & Fotos pflegen)
   ========================================================== */

.cv-mitglieder-login,
.cv-mitgliederbereich {
	max-width: 640px;
	margin: 0 auto;
}

.cv-mitglieder-formular-block {
	margin-bottom: 50px;
	padding-bottom: 40px;
	border-bottom: 1px dashed var(--cv-parchment-dark);
}
.cv-mitglieder-formular-block:last-child {
	border-bottom: none;
	margin-bottom: 0;
}

.cv-mitgliederbereich label,
.cv-mitglieder-login label {
	font-weight: bold;
	font-family: Georgia, serif;
	display: inline-block;
	margin-bottom: 4px;
}

.cv-mitgliederbereich input[type="text"],
.cv-mitgliederbereich input[type="date"],
.cv-mitgliederbereich input[type="file"],
.cv-mitgliederbereich select,
.cv-mitgliederbereich textarea,
.cv-mitglieder-login input[type="text"],
.cv-mitglieder-login input[type="password"] {
	width: 100%;
	padding: 10px 12px;
	margin-bottom: 14px;
	border: 1px solid var(--cv-parchment-dark);
	border-radius: 4px;
	font-family: Georgia, serif;
	font-size: 1rem;
	box-sizing: border-box;
	background: #ffffff;
	color: var(--cv-black);
}

.cv-mitgliederbereich textarea {
	resize: vertical;
}

.cv-meldung {
	padding: 14px 20px;
	border-radius: 4px;
	margin-bottom: 30px;
	font-weight: bold;
	text-align: center;
}
.cv-meldung--erfolg {
	background: #dff0d8;
	color: #3c763d;
	border: 1px solid #b2d8a8;
}
.cv-meldung--fehler {
	background: #f2dede;
	color: #a94442;
	border: 1px solid #e0b4b4;
}

.cv-mitglieder-willkommen {
	text-align: right;
	font-style: italic;
	margin-bottom: 30px;
}

.cv-mitglieder-login .login-remember,
.cv-mitglieder-login .login-submit {
	margin-bottom: 14px;
}

.cv-termin-laden-formular {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	margin-bottom: 24px;
}
.cv-termin-laden-formular select {
	flex: 1 1 auto;
	width: auto;
	min-width: 220px;
	margin-bottom: 0;
}

.cv-termin-bearbeiten-formular {
	margin-top: 20px;
	padding: 20px;
	background: rgba(0, 0, 0, 0.03);
	border-radius: 6px;
}

.cv-termin-loeschen-formular {
	margin-top: 4px;
}

.cv-btn--loeschen {
	border-color: #a94442 !important;
	color: #a94442;
}
.cv-btn--loeschen:hover {
	background: #a94442 !important;
	color: #ffffff !important;
	box-shadow: 0 0 20px rgba(169, 68, 66, 0.35);
}

.cv-fotoalbum-verwaltung {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin: 10px 0 20px;
}

.cv-foto-entfernen-kachel {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	width: 140px;
	padding: 8px;
	background: #ffffff;
	border: 1px solid var(--cv-parchment-dark);
	border-radius: 4px;
	font-weight: normal;
	font-family: Georgia, serif;
	font-size: 0.85rem;
	text-align: center;
}
.cv-foto-entfernen-kachel img {
	width: 100%;
	height: 100px;
	object-fit: cover;
	border-radius: 3px;
}
.cv-foto-entfernen-kachel span {
	display: flex;
	align-items: center;
	gap: 6px;
	color: #a94442;
}
.cv-foto-entfernen-kachel input[type="checkbox"] {
	width: auto;
	margin: 0;
}
