/*
Theme Name: Sonnenbad
Template: twentytwentyfive
Description: Schlichtes Garten-Theme für den Kleingartenverein Sonnenbad. Farben aus Blattgrün, Erde, Terrakotta und Holz; Schriften Literata und Fira Sans, lokal eingebunden.
Version: 1.1
Text Domain: sonnenbad
*/

/* Titelbilder der Startseite: zwei Fotos blenden langsam ineinander über.
   Reines CSS statt Slider-Plugin, damit kein Fremdcode dazukommt. */
.sonnenbad-titel {
	position: relative;
	min-height: clamp(260px, 38vw, 520px);
	overflow: hidden;
	display: flex;
	align-items: flex-end;
}
.sonnenbad-titel__bild {
	position: absolute;
	inset: 0;
	/* WordPress gibt jedem zweiten Block einen Abstand nach oben; der würde
	   Bild 2 nach unten schieben, sodass oben Bild 1 hervorschaut */
	margin: 0 !important;
	background-size: cover;
	background-position: center;
}
.sonnenbad-titel__bild--1 { background-image: url("assets/titelbild-1.jpg"); }
.sonnenbad-titel__bild--2 {
	background-image: url("assets/titelbild-2.jpg");
	opacity: 0;
	animation: sonnenbad-ueberblenden 16s ease-in-out infinite;
}
@keyframes sonnenbad-ueberblenden {
	0%, 40% { opacity: 0; }
	50%, 90% { opacity: 1; }
	100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
	.sonnenbad-titel__bild--2 { animation: none; }
}
/* Schrift auf dem Foto lesbar halten: dunkler Verlauf nur am unteren Rand */
.sonnenbad-titel::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(to top, rgba(31, 41, 28, 0.75), rgba(31, 41, 28, 0) 60%);
}
.sonnenbad-titel > .wp-block-group {
	position: relative;
	z-index: 1;
	width: 100%;
}

/* Fußbereich direkt an den Inhalt anschließen, ohne hellen Streifen dazwischen */
.wp-site-blocks > footer.wp-block-template-part { margin-block-start: 0; }

/* Kontaktformular (Contact Form 7) im Stil der Seite */
.wpcf7 label { display: block; font-weight: 600; margin-bottom: 1.2rem; }
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 textarea {
	display: block;
	width: 100%;
	margin-top: 0.35rem;
	padding: 0.6rem 0.75rem;
	font: inherit;
	font-weight: 400;
	color: var(--wp--preset--color--contrast);
	background: #fff;
	border: 1px solid var(--wp--preset--color--accent-4);
	border-radius: 4px;
}
.wpcf7 input:focus,
.wpcf7 textarea:focus {
	outline: 2px solid var(--wp--preset--color--accent-3);
	outline-offset: 1px;
}
.wpcf7 .wpcf7-acceptance label { font-weight: 400; }
.wpcf7 input[type="submit"] {
	font: inherit;
	font-weight: 600;
	padding: 0.7rem 1.6rem;
	color: var(--wp--preset--color--base);
	background: var(--wp--preset--color--accent-3);
	border: 0;
	border-radius: 4px;
	cursor: pointer;
}
.wpcf7 input[type="submit"]:hover { background: var(--wp--preset--color--accent-5); }
.wpcf7 input[type="submit"]:disabled { opacity: 0.5; cursor: not-allowed; }

/* Platzhalter für die Google-Karte, bis jemand sie lädt (assets/karte.js) */
.sonnenbad-karte {
	padding: 1.5rem;
	background: var(--wp--preset--color--accent-2);
	border-radius: 4px;
}
.sonnenbad-karte button {
	font: inherit;
	font-weight: 600;
	padding: 0.6rem 1.4rem;
	margin-right: 1rem;
	color: var(--wp--preset--color--base);
	background: var(--wp--preset--color--accent-3);
	border: 0;
	border-radius: 4px;
	cursor: pointer;
}
.sonnenbad-karte button:hover { background: var(--wp--preset--color--accent-5); }

/* Joomla-Altlasten in importierten Texten: feste Breiten und Höhen an Bildern */
.entry-content img { max-width: 100%; height: auto; }
.entry-content table { width: 100%; border-collapse: collapse; }
.entry-content td { padding: 0.4em 0.6em; vertical-align: top; }
