/* HTML Block Pages — Standard-Styling für alle Blöcke
 * Bewusst mit .hbp-* Klassen isoliert, damit es Theme-Stile kaum stört.
 */

.hbp-page {
	--hbp-accent: #2563eb;
	--hbp-accent-dark: #1d4ed8;
	--hbp-text: #1f2933;
	--hbp-muted: #52606d;
	--hbp-bg-soft: #f5f7fa;
	--hbp-border: #e4e7eb;
	--hbp-radius: 12px;
	--hbp-maxw: 1080px;

	container-type: inline-size;
	color: var( --hbp-text );
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	line-height: 1.6;
}

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

.hbp-block {
	margin: 0 auto;
}
.hbp-block + .hbp-block {
	margin-top: 8px;
}

.hbp-page img {
	max-width: 100%;
	height: auto;
	display: block;
}

/* Buttons --------------------------------------------------------- */
.hbp-btn {
	display: inline-block;
	background: var( --hbp-accent );
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	padding: 12px 24px;
	border-radius: 999px;
	transition: background 0.15s ease, transform 0.15s ease;
}
.hbp-btn:hover {
	background: var( --hbp-accent-dark );
	transform: translateY( -1px );
}
.hbp-btn-light {
	background: #fff;
	color: var( --hbp-accent-dark );
}
.hbp-btn-light:hover {
	background: #f0f3ff;
}

.hbp-rich :first-child {
	margin-top: 0;
}
.hbp-rich :last-child {
	margin-bottom: 0;
}
.hbp-rich a {
	color: var( --hbp-accent );
}

/* 1. Hero --------------------------------------------------------- */
.hbp-hero {
	position: relative;
	min-height: 420px;
	display: flex;
	align-items: center;
	overflow: hidden;
	color: #fff;
}
.hbp-hero-bg {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.hbp-hero::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient( 180deg, rgba( 0, 0, 0, 0.25 ), rgba( 0, 0, 0, 0.55 ) );
}
.hbp-hero-overlay {
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: var( --hbp-maxw );
	margin: 0 auto;
	padding: 64px 24px;
}
.hbp-eyebrow {
	text-transform: uppercase;
	letter-spacing: 0.08em;
	font-size: 14px;
	font-weight: 700;
	opacity: 0.9;
	margin: 0 0 8px;
}
.hbp-hero-title {
	font-size: clamp( 1.8rem, 6cqw, 3.25rem );
	line-height: 1.1;
	margin: 0 0 16px;
}
.hbp-hero-text {
	font-size: 1.15rem;
	max-width: 620px;
	margin-bottom: 24px;
}

/* 2. Textabschnitt ------------------------------------------------ */
.hbp-section {
	max-width: var( --hbp-maxw );
	margin: 0 auto;
	padding: 56px 24px;
}
.hbp-title {
	font-size: clamp( 1.4rem, 4cqw, 2.25rem );
	line-height: 1.2;
	margin: 0 0 16px;
}
.hbp-rich {
	font-size: 1.05rem;
	color: var( --hbp-muted );
}

/* 3. Bild mit Text ------------------------------------------------ */
.hbp-imgtext {
	max-width: var( --hbp-maxw );
	margin: 0 auto;
	padding: 56px 24px;
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 40px;
	align-items: center;
}
.hbp-imgtext-media img {
	width: 100%;
	border-radius: var( --hbp-radius );
}
.hbp-imgtext-body .hbp-btn {
	margin-top: 20px;
}

/* 4. Call to Action ----------------------------------------------- */
.hbp-cta {
	background: var( --hbp-accent );
	color: #fff;
	text-align: center;
	padding: 64px 24px;
}
.hbp-cta-title {
	font-size: clamp( 1.5rem, 5cqw, 2.5rem );
	margin: 0 0 12px;
}
.hbp-cta-text {
	font-size: 1.15rem;
	max-width: 640px;
	margin: 0 auto 24px;
	opacity: 0.95;
}

/* 5. Download / Datei --------------------------------------------- */
.hbp-download {
	max-width: var( --hbp-maxw );
	margin: 32px auto;
	padding: 28px 24px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	flex-wrap: wrap;
	background: var( --hbp-bg-soft );
	border: 1px solid var( --hbp-border );
	border-radius: var( --hbp-radius );
}
.hbp-download-title {
	margin: 0 0 6px;
	font-size: 1.25rem;
}
.hbp-file {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: var( --hbp-accent );
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	padding: 12px 22px;
	border-radius: 8px;
	white-space: nowrap;
}
.hbp-file::before {
	content: "⬇";
	font-size: 1.1em;
}
.hbp-file:hover {
	background: var( --hbp-accent-dark );
}

/* 6. Galerie ------------------------------------------------------ */
.hbp-gallery {
	max-width: var( --hbp-maxw );
	margin: 0 auto;
	padding: 40px 24px;
	display: grid;
	grid-template-columns: repeat( 3, 1fr );
	gap: 16px;
}
.hbp-gallery-item {
	margin: 0;
}
.hbp-gallery-item img {
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	border-radius: var( --hbp-radius );
}

/* 7. Zwei Spalten ------------------------------------------------- */
.hbp-cols {
	max-width: var( --hbp-maxw );
	margin: 0 auto;
	padding: 56px 24px;
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 40px;
}

/* Responsive (Container-Query: reagiert auf die Vorschau-/Seitenbreite) -- */
@container ( max-width: 782px ) {
	.hbp-imgtext,
	.hbp-cols {
		grid-template-columns: 1fr;
	}
	.hbp-gallery {
		grid-template-columns: 1fr 1fr;
	}
	.hbp-download {
		flex-direction: column;
		align-items: flex-start;
	}
	.hbp-hero-overlay,
	.hbp-section,
	.hbp-imgtext,
	.hbp-cols,
	.hbp-gallery,
	.hbp-cta {
		padding-left: 18px;
		padding-right: 18px;
	}
}

@container ( max-width: 480px ) {
	.hbp-gallery {
		grid-template-columns: 1fr;
	}
	.hbp-hero {
		min-height: 320px;
	}
}

/* Fallback für sehr alte Browser ohne Container-Queries */
@supports not ( container-type: inline-size ) {
	@media ( max-width: 782px ) {
		.hbp-imgtext,
		.hbp-cols {
			grid-template-columns: 1fr;
		}
		.hbp-gallery {
			grid-template-columns: 1fr 1fr;
		}
		.hbp-download {
			flex-direction: column;
			align-items: flex-start;
		}
	}
}

/* ================================================================== *
 * Vereins-/Schwimmen-Blöcke (.hbp-club) — eigenständig & gekapselt
 * Container-Queries, damit auch die Geräte-Vorschau korrekt reagiert.
 * ================================================================== */
.hbp-club {
	container-type: inline-size;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	color: #1a1a1a;
	max-width: 1100px;
	margin: 0 auto;
	padding: 20px;
}
.hbp-club .section {
	margin-bottom: 0;
}
.hbp-club h2 {
	font-size: 26px;
	margin: 0 0 18px;
	font-weight: 600;
}
.hbp-club .card {
	background: #fff;
	border-radius: 14px;
	padding: 20px;
	line-height: 1.6;
	box-shadow: 0 8px 25px rgba( 0, 0, 0, 0.05 );
}
.hbp-club .card p {
	margin-bottom: 10px;
}
.hbp-club .highlight {
	color: #0073ff;
	font-weight: 500;
}
.hbp-club .ansprechpartner {
	display: flex;
	align-items: center;
	gap: 20px;
}
.hbp-club .ansprechpartner img {
	width: 90px;
	height: 90px;
	border-radius: 50%;
	object-fit: cover;
	flex-shrink: 0;
	box-shadow: 0 4px 12px rgba( 0, 0, 0, 0.1 );
}
.hbp-club .ansprechpartner-info p {
	margin-bottom: 4px;
}
.hbp-club .anforderungen {
	background: #fff8d6;
	border-left: 4px solid #f5c518;
	border-radius: 10px;
	padding: 14px 18px;
	margin-top: 18px;
}
.hbp-club .anforderungen p {
	margin: 0;
}
.hbp-club .training-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 20px;
	margin-top: 10px;
}
.hbp-club .training-grid h4 {
	margin: 0 0 8px;
	font-size: 15px;
	color: #0073ff;
	font-weight: 600;
}
.hbp-club .trainer-grid {
	display: grid;
	grid-template-columns: repeat( auto-fit, minmax( 240px, 1fr ) );
	gap: 25px;
	justify-items: center;
}
.hbp-club .trainer-card {
	background: #fff;
	border-radius: 18px;
	padding: 18px;
	text-align: center;
	box-shadow: 0 10px 25px rgba( 0, 0, 0, 0.06 );
	transition: transform 0.25s ease;
	width: 100%;
	max-width: 280px;
}
.hbp-club .trainer-card:hover {
	transform: translateY( -5px );
}
.hbp-club .trainer-card img {
	width: 100%;
	max-width: 250px;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	border-radius: 16px;
	margin-bottom: 12px;
}
.hbp-club .trainer-card h3 {
	margin: 8px 0 4px;
	font-size: 17px;
}
.hbp-club .trainer-card p {
	font-size: 13px;
	color: #666;
}
@container ( max-width: 600px ) {
	.hbp-club .training-grid {
		grid-template-columns: 1fr;
	}
	.hbp-club .ansprechpartner {
		flex-direction: column;
		text-align: center;
	}
}
@container ( max-width: 768px ) {
	.hbp-club .trainer-grid {
		grid-template-columns: 1fr;
	}
}
