/*
Theme Name: SC Bonn Beuel
Description: Child-Theme von Twenty Twenty-Five für den Schachclub Bonn Beuel. Quelle: github.com/littlecapa/homepage_scbb
Template: twentytwentyfive
Version: 0.9.28
Requires at least: 6.7
Text Domain: scbb
*/

/* ---------- Kopfbereich ---------- */
.scbb-header {
	background: #fff;
	color: #000;
}

.scbb-header__top {
	position: relative;
	min-height: 170px;
	padding: 18px max(24px, calc((100vw - 1240px) / 2)) 18px max(24px, calc((100vw - 1240px) / 2));
	gap: 28px;
	background: #fff url("assets/header-board.svg?v=4") no-repeat right center / auto 100%;
}

.scbb-header__logo {
	position: relative;
	z-index: 2;
	display: block;
	flex: 0 0 auto;
}

.scbb-header__logo img {
	display: block;
	width: 150px;
	height: 150px;
	border-radius: 50%;
	background: #fff;
}

.scbb-header__titles {
	gap: 4px !important;
}

.scbb-header .scbb-header__title,
.scbb-header .scbb-header__title a {
	margin: 0;
	color: #000;
	font-size: clamp(1.6rem, 3vw, 2.4rem);
	font-weight: 600;
	line-height: 1.15;
	text-decoration: none;
}

.scbb-header .scbb-header__tagline {
	margin: 0;
	color: var(--wp--preset--color--scbb-blau-dunkel);
	font-size: clamp(1rem, 1.6vw, 1.2rem);
}

/* ---------- Menüleiste ---------- */
.scbb-header__nav {
	background: var(--wp--preset--color--scbb-blau);
	/* Erster Menüpunkt bündig mit dem Logo (Innenabstand der Links ausgleichen) */
	padding: 0 max(24px, calc((100vw - 1240px) / 2)) 0 calc(max(24px, calc((100vw - 1240px) / 2)) - 16px);
}

.scbb-nav,
.scbb-nav .wp-block-navigation__container {
	gap: 0 !important;
}

.scbb-nav .wp-block-navigation-item__content {
	display: block;
	padding: 14px 16px;
	color: #fff !important;
	font-size: 0.875rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	text-decoration: none;
}

.scbb-nav .wp-block-navigation-item__content:hover,
.scbb-nav .wp-block-navigation-item__content:focus,
.scbb-nav .current-menu-item > .wp-block-navigation-item__content {
	background: var(--wp--preset--color--scbb-blau-dunkel);
}

.scbb-nav .wp-block-navigation__responsive-container-open {
	color: #fff;
	padding: 12px 0;
}

/* ---------- Schmale Bildschirme ---------- */
@media (max-width: 781px) {
	.scbb-abend {
		padding: 14px 16px;
	}

	.scbb-abend__kopf {
		padding-right: 0;
		padding-top: 22px;
	}

	.scbb-abend__liste dt {
		flex-basis: 100%;
	}

	.scbb-header__top {
		min-height: 110px;
		gap: 16px;
		background-image: none; /* Brett-Grafik würde den Slogan überdecken */
	}

	.scbb-header__logo img {
		width: 84px;
		height: 84px;
	}

	.scbb-header__nav {
		padding-left: 24px;
	}

}

/* Geöffnetes Handy-Menü: deckend blau, über allem */
.scbb-nav .wp-block-navigation__responsive-container.is-menu-open {
	z-index: 100000;
	padding: 20px 24px;
	background: var(--wp--preset--color--scbb-blau) !important;
	color: #fff !important;
	opacity: 1;
}

.scbb-nav .is-menu-open .wp-block-navigation__responsive-container-close {
	color: #fff;
}

.scbb-nav .is-menu-open .wp-block-navigation__container {
	gap: 4px !important;
	padding-top: 32px;
}

.scbb-nav .is-menu-open .wp-block-navigation-item__content {
	padding: 10px 0;
	font-size: 1.1rem;
}

.scbb-header__logo {
	z-index: 1;
}

/* ---------- Startseite: Vereinsabend ---------- */
.scbb-abend {
	position: relative;
	margin-block: 0 var(--wp--preset--spacing--40);
	padding: 14px 20px;
	background: var(--wp--preset--color--scbb-blau-hell);
	border-left: 6px solid var(--wp--preset--color--scbb-blau);
	border-radius: 4px;
}

.scbb-abend__kopf {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 6px 20px;
	margin-bottom: 8px;
	padding-right: 96px; /* Platz für den Sprachumschalter */
}

.scbb-abend__titel {
	margin: 0;
	font-size: 1.6rem;
	font-weight: 700;
}

.scbb-abend__titel span {
	color: inherit; /* „jeden Dienstag“ wie „Vereinsabend“ (Wunsch Roger) */
	font-weight: inherit;
}

.scbb-abend__naechster {
	margin: 0;
	padding: 4px 12px;
	background: var(--wp--preset--color--scbb-blau);
	color: #fff;
	border-radius: 999px;
	font-size: 0.95rem;
}

.scbb-abend__spalten {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
	gap: 0 48px;
}

.scbb-abend__liste {
	margin: 0;
}

.scbb-abend__liste > div {
	display: flex;
	flex-wrap: wrap;
	gap: 2px 16px;
	padding: 5px 0;
	border-bottom: 1px solid rgba(65, 105, 225, 0.22);
}

.scbb-abend__liste dt {
	flex: 0 0 10.5em;
	font-weight: 600;
}

.scbb-abend__liste dd {
	margin: 0;
}

.scbb-abend__ort {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
	gap: 2px 48px;
	margin-top: 8px;
	font-size: 0.9rem;
}

.scbb-abend__ort p {
	margin: 0;
}


/* ---------- Fußbereich ---------- */
.wp-block-template-part:has(> .scbb-footer) {
	margin-top: var(--wp--preset--spacing--60);
}

.scbb-footer {
	background: #fff;
	border-top: 6px solid var(--wp--preset--color--scbb-blau);
	color: #222;
	font-size: 0.95rem;
}

.scbb-footer a {
	color: #000;
	text-decoration: none;
}

.scbb-footer a:hover,
.scbb-footer a:focus {
	color: var(--wp--preset--color--scbb-blau);
	text-decoration: underline;
}

.scbb-footer__inner {
	display: grid;
	grid-template-columns: 1.4fr 1fr 1fr 1fr;
	gap: 32px 48px;
	padding: 48px max(24px, calc((100vw - 1240px) / 2));
}

.scbb-footer__logo img {
	display: block;
	width: 72px;
	height: 72px;
	border-radius: 50%;
	background: #fff;
}

.scbb-footer__name {
	margin: 14px 0 4px;
	color: #000;
	font-size: 1.15rem;
	font-weight: 600;
}

.scbb-footer__slogan {
	margin: 0;
	color: var(--wp--preset--color--scbb-blau-dunkel);
}

.scbb-footer__titel {
	margin: 0 0 12px;
	color: #000;
	font-size: 0.85rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.scbb-footer p {
	margin: 0 0 10px;
	line-height: 1.5;
}

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

.scbb-footer li {
	margin: 0 0 6px;
}

.scbb-footer__klein {
	font-size: 0.85rem;
	color: #555;
}

.scbb-footer__unten {
	padding: 14px max(24px, calc((100vw - 1240px) / 2));
	border-top: 1px solid #dde3ef;
	font-size: 0.85rem;
	color: #555;
}

.scbb-footer__unten p {
	margin: 0;
}

@media (max-width: 960px) {
	.scbb-footer__inner {
		grid-template-columns: 1fr 1fr;
	}
}

@media (max-width: 560px) {
	.scbb-footer__inner {
		grid-template-columns: 1fr;
		padding-block: 36px;
	}
}

/* ---------- Symbole ---------- */
.scbb-icon {
	display: inline-block;
	flex: 0 0 auto;
	vertical-align: -0.2em;
}

/* ---------- Menüleiste: Instagram + Spenden ---------- */
.scbb-header__aktionen {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 14px;
	padding: 6px 0;
}

.scbb-header__insta {
	display: inline-flex;
	color: #fff;
	padding: 4px;
	border-radius: 6px;
}

.scbb-header__insta:hover,
.scbb-header__insta:focus {
	background: var(--wp--preset--color--scbb-blau-dunkel);
}

.scbb-button {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 16px;
	border-radius: 999px;
	font-size: 0.85rem;
	font-weight: 700;
	letter-spacing: 0.03em;
	text-decoration: none;
	white-space: nowrap;
}

.scbb-button--spenden {
	background: #fff;
	color: var(--wp--preset--color--scbb-blau-dunkel) !important;
}

.scbb-button--spenden .scbb-icon {
	color: var(--wp--preset--color--scbb-herz);
}

.scbb-button--spenden:hover,
.scbb-button--spenden:focus {
	background: var(--wp--preset--color--scbb-blau-hell);
}

@media (max-width: 420px) {
	.scbb-button--spenden span {
		display: none;
	}

	.scbb-button--spenden {
		padding: 8px 10px;
	}
}

/* ---------- Startseite: Kacheln Spenden / Instagram ---------- */
.scbb-kacheln {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
	gap: 16px;
	margin-block: 0 var(--wp--preset--spacing--40);
}

.scbb-kachel {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 12px 18px;
	border-radius: 6px;
	color: #fff;
	text-decoration: none;
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.scbb-kachel:hover,
.scbb-kachel:focus {
	transform: translateY(-2px);
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
}

.scbb-kachel--spenden {
	background: var(--wp--preset--color--scbb-blau);
}

.scbb-kachel--insta {
	/* Farbverlauf im Instagram-Stil; dunkle Töne links, damit der weiße Text gut lesbar bleibt */
	background: linear-gradient(100deg, #8134af 0%, #c1358a 45%, #e1306c 70%, #f77737 100%);
}

.scbb-kachel__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 44px;
	height: 44px;
	border-radius: 50%;
	background: #fff;
}

.scbb-kachel--spenden .scbb-kachel__icon {
	color: var(--wp--preset--color--scbb-herz);
}

.scbb-kachel--insta .scbb-kachel__icon {
	color: #c1358a;
}

.scbb-kachel__text {
	display: flex;
	flex-direction: column;
	gap: 2px;
	line-height: 1.35;
}

.scbb-kachel__text strong {
	font-size: 1.1rem;
}

.scbb-kachel__text span {
	font-size: 0.95rem;
	opacity: 0.9;
}

.scbb-kachel__pfeil {
	margin-left: auto;
	font-size: 1.5rem;
}

/* ---------- Fußbereich: Social ---------- */
.scbb-footer__social a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.scbb-footer__social .scbb-icon {
	vertical-align: 0;
}

/* ---------- Inhaltsseiten: Karten, Hinweis, Pfeil-Links ---------- */
.scbb-hinweis {
	padding: 22px 26px !important;
	background: var(--wp--preset--color--scbb-blau-hell);
	border-left: 6px solid var(--wp--preset--color--scbb-blau);
	border-radius: 4px;
}

.scbb-hinweis > * {
	margin-block: 0 0.5em !important;
}

.scbb-hinweis > *:last-child {
	margin-bottom: 0 !important;
}

.scbb-karten {
	display: grid !important;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
	gap: 20px !important;
}

.scbb-karten > * {
	margin: 0 !important;
}

.scbb-karte {
	padding: 20px 22px !important;
	border: 1px solid #dbe3f5;
	border-top: 4px solid var(--wp--preset--color--scbb-blau);
	border-radius: 4px;
	background: #fff;
}

.scbb-karte > * {
	margin-block: 0 0.5em !important;
}

.scbb-karte > *:last-child {
	margin-bottom: 0 !important;
}

.scbb-karte h3 {
	font-size: 1.15rem;
}

.scbb-pfeil a,
a.scbb-pfeil {
	font-weight: 600;
	text-decoration: none;
}

.scbb-pfeil a::after,
a.scbb-pfeil::after {
	content: " →";
}

.scbb-pfeil a:hover,
a.scbb-pfeil:hover {
	text-decoration: underline;
}

.scbb-zurueck a::before {
	content: "← ";
}

/* Überschriften im Hinweiskasten nicht zu groß */
.scbb-hinweis h2 {
	font-size: clamp(1.3rem, 2.2vw, 1.6rem);
}

/* Lange Adressen (E-Mail) in Karten umbrechen statt überlaufen */
.scbb-karte {
	hyphens: auto; /* deutsche Silbentrennung, wenn der Platz nicht reicht */
	overflow-wrap: break-word;
	min-width: 0;
}

/* Fotos in Inhaltsseiten (liegen unter assets/fotos/) */
.scbb-foto img {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 4px;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}

/* Kontaktliste mit Symbolen (E-Mail, Instagram) */
.scbb-kontaktliste {
	list-style: none;
	padding-left: 0;
}
.scbb-kontaktliste li {
	display: flex;
	align-items: center;
	gap: 0.6em;
	margin-block: 0.4em;
	overflow-wrap: anywhere;
}
.scbb-kontaktliste li::before {
	content: "";
	flex: none;
	width: 1.4em;
	height: 1.4em;
	background-color: var(--wp--preset--color--scbb-blau);
	-webkit-mask: var(--scbb-symbol) center / contain no-repeat;
	mask: var(--scbb-symbol) center / contain no-repeat;
}
.scbb-kontakt--mail {
	--scbb-symbol: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='m3 7 9 6 9-6'/%3E%3C/svg%3E");
}
.scbb-kontakt--insta {
	--scbb-symbol: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Crect x='3' y='3' width='18' height='18' rx='5'/%3E%3Ccircle cx='12' cy='12' r='4'/%3E%3Ccircle cx='17.5' cy='6.5' r='1' fill='black' stroke='none'/%3E%3C/svg%3E");
}

/* Vereinsabend: Sprachumschalter DE/EN (nur diese Kachel) */
.scbb-sprache {
	position: absolute;
	top: 12px;
	right: 16px;
	z-index: 1;
	display: flex;
	justify-content: flex-end;
	align-items: center;
	gap: 0.45em;
	font-size: 0.8rem;
	font-weight: 700;
	letter-spacing: 0.05em;
	cursor: pointer;
	user-select: none;
}
.scbb-sprache__schalter {
	appearance: none;
	-webkit-appearance: none;
	position: relative;
	width: 2.6em;
	height: 1.4em;
	margin: 0;
	border-radius: 1em;
	background: var(--wp--preset--color--scbb-blau);
	cursor: pointer;
}
.scbb-sprache__schalter::before {
	content: "";
	position: absolute;
	top: 0.2em;
	left: 0.2em;
	width: 1em;
	height: 1em;
	border-radius: 50%;
	background: #fff;
	transition: transform 0.15s ease;
}
.scbb-sprache__schalter:checked::before {
	transform: translateX(1.2em);
}
.scbb-sprache__schalter:focus-visible {
	outline: 2px solid var(--wp--preset--color--scbb-blau-dunkel);
	outline-offset: 2px;
}
.scbb-sprache__de { color: var(--wp--preset--color--scbb-blau); }
.scbb-sprache__en { color: #8a8a8a; }
.scbb-abend:has(.scbb-sprache__schalter:checked) .scbb-sprache__de { color: #8a8a8a; }
.scbb-abend:has(.scbb-sprache__schalter:checked) .scbb-sprache__en { color: var(--wp--preset--color--scbb-blau); }

.scbb-abend > .scbb-abend__inhalt[lang="en"] { display: none; }
.scbb-abend:has(.scbb-sprache__schalter:checked) > .scbb-abend__inhalt[lang="de"] { display: none; }
.scbb-abend:has(.scbb-sprache__schalter:checked) > .scbb-abend__inhalt[lang="en"] { display: block; }

/* ---------- Startseite: Bereiche (2x2) ---------- */
.scbb-bereiche {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px;
	margin-block: 0 var(--wp--preset--spacing--40);
}

.scbb-bereich {
	display: flex;
	flex-direction: column;
	padding: 14px 18px;
	border-top: 4px solid var(--wp--preset--color--scbb-blau);
	border-radius: 4px;
	background: #fff;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.scbb-bereich__titel {
	margin: 0 0 6px;
	font-size: 1.3rem;
	font-weight: 700;
}

.scbb-bereich__titel a {
	color: inherit;
	text-decoration: none;
}

.scbb-bereich p,
.scbb-bereich__liste {
	font-size: 1rem; /* nie größer als der Bereichstitel (1.3rem) */
}

.scbb-bereich p {
	margin: 0 0 8px;
	line-height: 1.45;
}

.scbb-bereich__liste {
	margin: 0 0 8px;
	padding: 0;
	list-style: none;
}

.scbb-bereich__liste li {
	padding: 3px 0;
	border-bottom: 1px solid rgba(65, 105, 225, 0.15);
}

.scbb-bereich__liste time {
	color: #666;
	font-size: 0.85rem;
	white-space: nowrap;
}

.scbb-bereich__mehr {
	margin-top: auto !important;
	margin-bottom: 0 !important;
	text-align: right;
}

.scbb-bereich__mehr a {
	font-weight: 700;
	text-decoration: none;
}

.scbb-bereich__mehr a:hover,
.scbb-bereich__mehr a:focus {
	text-decoration: underline;
}

@media (max-width: 700px) {
	.scbb-bereiche {
		grid-template-columns: 1fr;
	}
}

/* ---------- Headlines (Turnierseiten, Shortcode scbb_news) ---------- */
.scbb-headlines {
	list-style: none;
	padding: 0;
	margin: 0.5em 0 1.5em;
}
.scbb-headlines li {
	display: grid;
	grid-template-columns: 6.5em 1fr;
	gap: 10px;
	padding: 6px 0;
	border-bottom: 1px solid rgba(65, 105, 225, 0.2);
}
.scbb-headlines time {
	color: #666;
	font-size: 0.85rem;
	padding-top: 0.15em;
	font-variant-numeric: tabular-nums;
}

/* ---------- News-Übersicht ---------- */
/* Kopf: Überschrift links, Suchfeld rechts (auf dem Handy darunter) */
.scbb-news__kopf {
	gap: 8px 16px;
	margin-bottom: 8px;
}
.scbb-news__kopf h1 {
	margin: 0;
}
.scbb-suche {
	flex: 0 1 320px;
	margin: 0;
}
.scbb-suche .wp-block-search__input {
	font-size: 0.95rem;
	padding: 6px 10px;
	border: 1px solid rgba(65, 105, 225, 0.4);
	border-radius: 4px;
}
.scbb-suche .wp-block-search__button {
	font-size: 0.95rem;
	padding: 6px 14px;
	margin-left: 6px;
	background: #4169e1;
	color: #fff;
	border: 0;
	border-radius: 4px;
}
.scbb-suche .wp-block-search__button:hover {
	background: #2a4cc4;
}
@media (max-width: 500px) {
	.scbb-suche {
		flex-basis: 100%;
	}
}

.scbb-news__eintrag {
	padding: 10px 0 14px;
	border-bottom: 1px solid rgba(65, 105, 225, 0.2);
}

/* Teaserbild links, Text rechts; ohne Beitragsbild nur Text */
.scbb-news__eintrag:has(.scbb-news__bild) {
	display: grid;
	grid-template-columns: 150px 1fr;
	gap: 18px;
	align-items: start;
}

.scbb-news__eintrag > * {
	margin-block: 0;
}

.scbb-news__bild img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 4 / 5;
	object-fit: cover;
	border-radius: 4px;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}

@media (max-width: 500px) {
	.scbb-news__eintrag:has(.scbb-news__bild) {
		grid-template-columns: 96px 1fr;
		gap: 12px;
	}
}

.scbb-news__datum {
	color: #666;
	font-size: 0.85rem;
}

.scbb-news__titel {
	margin: 2px 0 6px;
	font-size: 1.35rem;
}

/* ---------- Mannschaftsseiten: Tabellen (Aufstellung, Termine) ---------- */
.scbb-tabelle {
	overflow-x: auto; /* breite Tabellen auf dem Handy seitlich wischen */
	font-size: 0.85rem;
	margin-block: 0.5em 1em;
}
.scbb-tabelle table {
	width: 100%;
	border-collapse: collapse;
	font-variant-numeric: tabular-nums;
}
.scbb-tabelle th,
.scbb-tabelle td {
	padding: 4px 6px;
	border: 0;
	border-bottom: 1px solid #dbe3f5;
	text-align: center;
	white-space: nowrap;
}
.scbb-tabelle thead th {
	background: var(--wp--preset--color--scbb-blau);
	color: #fff;
	font-weight: 600;
	border-bottom: 0;
}
.scbb-tabelle tbody tr:nth-child(even) {
	background: #f5f8fe;
}
.scbb-tabelle tfoot td {
	font-weight: 700;
	border-top: 2px solid var(--wp--preset--color--scbb-blau);
	border-bottom: 0;
}
/* Namen und Mannschaften linksbündig */
.scbb-tabelle td:nth-child(2),
.scbb-tabelle th:nth-child(2) {
	text-align: left;
}
.scbb-tabelle table:has(th:nth-child(5):last-child) :is(td, th):is(:nth-child(3), :nth-child(4)) {
	text-align: left; /* Termine: Heim und Gast */
}
.scbb-tabelle table:has(th:nth-child(5):last-child) td:nth-child(2) {
	text-align: center; /* Termine: Datum */
}
.scbb-tabelle tfoot td:first-child {
	text-align: left;
}
.scbb-klein {
	font-size: 0.9rem;
	color: #555;
}
.scbb-mf {
	margin-top: 0.25em !important;
}
.scbb-ergebnislinks {
	padding: 14px 20px !important;
}
/* Spielplan mit Spalte „Paar“ (Jugend): Heim und Gast linksbündig */
.scbb-tabelle--paar td:nth-child(2),
.scbb-tabelle--paar th:nth-child(2) {
	text-align: center;
}
.scbb-tabelle--paar :is(td, th):is(:nth-child(4), :nth-child(5)) {
	text-align: left;
}

/* Steckbrief (Beschriftung | Text, z. B. Ausschreibungen): Text darf umbrechen */
.scbb-tabelle--steckbrief :is(th, td) {
	white-space: normal;
	text-align: left;
	vertical-align: top;
}
.scbb-tabelle--steckbrief th {
	width: 1%;
	white-space: nowrap;
	padding-right: 1em;
}
.scbb-tabelle.scbb-tabelle--steckbrief {
	font-size: 0.95rem;
}

/* Karten: Text und Pfeil-Links nie größer als die Kartenüberschrift (h3 = 1.15rem) */
.scbb-karte p {
	font-size: 1rem;
}

/* Karten fest in 3 Spalten (z. B. Übersicht Mannschaften: 2 Reihen à 3), auf schmalen Bildschirmen 2 bzw. 1 */
.scbb-karten--3 {
	grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 700px) {
	.scbb-karten--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 420px) {
	.scbb-karten--3 { grid-template-columns: 1fr; }
}

/* Beiträge: Partien (PGN) als aufklappbarer Text, Bildunterschriften */
.wp-block-details {
	margin-block: 1em;
	padding: 10px 14px;
	border: 1px solid #dbe3f5;
	border-left: 4px solid var(--wp--preset--color--scbb-blau);
	border-radius: 4px;
	background: #f8faff;
}
.wp-block-details summary {
	cursor: pointer;
	font-weight: 600;
}
.wp-block-details .wp-block-code {
	margin: 0.75em 0 0;
	padding: 10px;
	font-size: 0.8rem;
	white-space: pre-wrap;
	overflow-wrap: anywhere;
	background: #fff;
	border: 1px solid #e3e9f6;
}
.scbb-foto .wp-element-caption {
	margin-top: 0.4em;
	font-size: 0.85rem;
	color: #555;
	text-align: center;
}

/* Termine: Spalten Termin/Details linksbündig, Datum und Zeit kompakt */
.scbb-termine td:nth-child(3),
.scbb-termine td:nth-child(4),
.scbb-termine th:nth-child(3),
.scbb-termine th:nth-child(4) {
	text-align: left;
}
.scbb-termine td:nth-child(4) {
	white-space: normal;
}
.scbb-termine td:first-child {
	text-align: left;
}
/* Termine: gleiche Spaltenbreiten in allen Monatstabellen */
@media (min-width: 700px) {
	.scbb-termine table { table-layout: fixed; }
	.scbb-termine th:nth-child(1) { width: 6.5em; }
	.scbb-termine th:nth-child(2) { width: 7em; }
	.scbb-termine th:nth-child(3) { width: 34%; }
	.scbb-termine td { white-space: normal; }
}

/* Vereinsmeisterschaft: Hochformat-Fotos nicht seitenbreit, Archiv-Kasten, Runden als aufklappbare Tabellen */
.scbb-foto--hoch img {
	max-width: 340px;
	margin-inline: auto;
}
.scbb-archiv p {
	margin: 0;
	line-height: 1.8;
}
.wp-block-details > .scbb-tabelle {
	margin-block: 0.75em 0;
}
.scbb-tabelle .wp-element-caption {
	font-size: 0.85rem;
	color: #555;
	text-align: left;
}

/* Lange Seitentitel (z. B. „Vereinsmeisterschaft“) auf dem Handy mit Silbentrennung statt Umbruch mitten im Wort */
.wp-block-post-title {
	hyphens: auto;
	overflow-wrap: break-word;
}

/* Fett sichtbar machen: Fließtext ist Light (300), „bolder“ ergäbe nur 400 – daher fest SemiBold */
strong,
b {
	font-weight: 600;
}

/* ---------- Startseite: Fotoband der neuesten News (patterns/fotoband.php) ---------- */
.scbb-fotoband {
	margin-block: 0 var(--wp--preset--spacing--40);
}
.scbb-fotoband__spur {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 16px;
}
.scbb-fotoband__foto {
	position: relative;
	display: block;
	aspect-ratio: 4 / 3;
	overflow: hidden;
	border-radius: 6px;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
	background: #eaf0fc;
}
.scbb-fotoband__foto img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.3s ease;
}
.scbb-fotoband__foto:hover img,
.scbb-fotoband__foto:focus-visible img {
	transform: scale(1.04);
}
.scbb-fotoband__titel {
	position: absolute;
	inset: auto 0 0 0;
	padding: 28px 10px 8px;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0));
	color: #fff;
	font-size: 0.85rem;
	font-weight: 600;
	line-height: 1.25;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.scbb-fotoband__punkte {
	display: none;
}

/* Handy: Karussell – immer ein Foto, seitlich wischen; Punkte zeigen die Position */
@media (max-width: 700px) {
	.scbb-fotoband__spur {
		display: flex;
		gap: 0;
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		scrollbar-width: none;
		border-radius: 6px;
	}
	.scbb-fotoband__spur::-webkit-scrollbar {
		display: none;
	}
	.scbb-fotoband__foto {
		flex: 0 0 100%;
		scroll-snap-align: start;
		border-radius: 0;
		box-shadow: none;
	}
	.scbb-fotoband__titel {
		font-size: 0.95rem;
	}
	.scbb-fotoband__punkte {
		display: flex;
		justify-content: center;
		gap: 8px;
		margin-top: 8px;
	}
	.scbb-fotoband__punkte button {
		width: 9px;
		height: 9px;
		padding: 0;
		border: 0;
		border-radius: 50%;
		background: #c5d2f0;
		cursor: pointer;
	}
	.scbb-fotoband__punkte button.ist-aktiv {
		background: var(--wp--preset--color--scbb-blau);
	}
}

/* Vereinsabend: Turnier-Link in der blauen Pille „Nächster Termin“ weiß statt blau auf blau */
.scbb-abend__naechster a {
	color: #fff;
	text-decoration: underline;
	text-underline-offset: 2px;
}
.scbb-abend__naechster a:hover,
.scbb-abend__naechster a:focus {
	text-decoration-thickness: 2px;
}

/* Karten 2×2 (Turniere-Übersicht mit vier Turnieren), auf dem Handy untereinander */
.scbb-karten--2 {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 560px) {
	.scbb-karten--2 {
		grid-template-columns: 1fr;
	}
}

/* Zwischenüberschriften (h3) direkt im Seitentext, z. B. Schutzkonzept 1.1, 1.2 …:
   gleiche Größe wie Fließtext, daher fett und mit Abstand. Karten-h3 (verschachtelt) bleiben unberührt. */
.wp-block-post-content > h3.wp-block-heading {
	font-weight: 600;
	margin-top: 2rem;
}

/* Kreuztabellen: Nr., Name und Wertzahl bleiben beim seitlichen Wischen stehen */
.scbb-kreuz table {
	border-collapse: separate;
	border-spacing: 0;
}
.scbb-kreuz :is(th, td):nth-child(-n+3) {
	position: sticky;
	z-index: 1;
	background: #fff;
	box-sizing: border-box;
}
.scbb-kreuz tbody tr:nth-child(even) :is(td):nth-child(-n+3) { background: #f5f8fe; }
.scbb-kreuz thead th:nth-child(-n+3) { background: var(--wp--preset--color--scbb-blau); z-index: 2; }
.scbb-kreuz :is(th, td):nth-child(1) { left: 0; width: 2.6rem; min-width: 2.6rem; max-width: 2.6rem; }
.scbb-kreuz :is(th, td):nth-child(2) {
	left: 2.6rem; width: 12.5rem; min-width: 12.5rem; max-width: 12.5rem;
	overflow: hidden; text-overflow: ellipsis;
}
.scbb-kreuz :is(th, td):nth-child(3) {
	left: 15.1rem; width: 3.4rem; min-width: 3.4rem; max-width: 3.4rem;
	box-shadow: inset -1px 0 0 #b9c6e6, 4px 0 6px -4px rgba(0, 0, 0, 0.25);
}
@media (max-width: 600px) {
	.scbb-kreuz :is(th, td):nth-child(1) { width: 2.1rem; min-width: 2.1rem; max-width: 2.1rem; padding-inline: 3px; }
	.scbb-kreuz :is(th, td):nth-child(2) { left: 2.1rem; width: 8.5rem; min-width: 8.5rem; max-width: 8.5rem; }
	.scbb-kreuz :is(th, td):nth-child(3) { left: 10.6rem; width: 2.9rem; min-width: 2.9rem; max-width: 2.9rem; padding-inline: 3px; }
}
/* Kreuztabellen mit Punkte/Buchholz in Spalte 4 und 5: auch diese bleiben stehen */
.scbb-kreuz--wertung :is(th, td):nth-child(-n+5) {
	position: sticky;
	z-index: 1;
	background: #fff;
	box-sizing: border-box;
}
.scbb-kreuz--wertung tbody tr:nth-child(even) td:nth-child(-n+5) { background: #f5f8fe; }
.scbb-kreuz--wertung thead th:nth-child(-n+5) { background: var(--wp--preset--color--scbb-blau); z-index: 2; }
.scbb-kreuz--wertung :is(th, td):nth-child(3) { box-shadow: none; }
.scbb-kreuz--wertung :is(th, td):nth-child(4) { left: 18.5rem; width: 3.8rem; min-width: 3.8rem; max-width: 3.8rem; }
.scbb-kreuz--wertung td:nth-child(4) { font-weight: 700; }
.scbb-kreuz--wertung :is(th, td):nth-child(5) {
	left: 22.3rem; width: 3.4rem; min-width: 3.4rem; max-width: 3.4rem;
	box-shadow: inset -1px 0 0 #b9c6e6, 4px 0 6px -4px rgba(0, 0, 0, 0.25);
}
@media (max-width: 600px) {
	/* Handy: Wertzahl wischt mit, Nr., Name, Punkte und Buchholz bleiben stehen */
	.scbb-kreuz--wertung :is(th, td):nth-child(2) { width: 7.5rem; min-width: 7.5rem; max-width: 7.5rem; }
	.scbb-kreuz--wertung :is(th, td):nth-child(3) { position: static; }
	.scbb-kreuz--wertung :is(th, td):nth-child(4) { left: 9.6rem; width: 3.4rem; min-width: 3.4rem; max-width: 3.4rem; padding-inline: 3px; }
	.scbb-kreuz--wertung :is(th, td):nth-child(5) { left: 13rem; width: 3.1rem; min-width: 3.1rem; max-width: 3.1rem; padding-inline: 3px; }
}
/* Saisonwertung der Turnierserien: Gesamt fett, Monate als Links zur Kreuztabelle, Verein linksbündig */
.scbb-saison td:nth-child(3) { font-weight: 700; }
.scbb-saison thead a { color: #fff; text-decoration: underline; text-underline-offset: 2px; }
.scbb-saison :is(td, th):last-child { text-align: left; }

/* ---------- Foto-Karussell: Galerie-Block mit Klasse scbb-karussell (assets/js/karussell.js ergänzt die Pfeile) ---------- */
.scbb-karussell-rahmen {
	position: relative;
	margin-block: var(--wp--preset--spacing--30) var(--wp--preset--spacing--40);
}
.wp-block-gallery.has-nested-images.scbb-karussell {
	display: flex;
	flex-wrap: nowrap;
	gap: 12px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	scrollbar-width: thin;
	padding-bottom: 6px;
	margin: 0;
}
.wp-block-gallery.has-nested-images.scbb-karussell figure.wp-block-image:not(#individual-image) {
	flex: 0 0 calc((100% - 24px) / 3);
	width: auto;
	margin: 0;
	scroll-snap-align: start;
	aspect-ratio: 3 / 4;
	border-radius: 6px;
	overflow: hidden;
}
.wp-block-gallery.has-nested-images.scbb-karussell figure.wp-block-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.wp-block-gallery.has-nested-images.scbb-karussell figure.wp-block-image figcaption {
	font-size: 0.85rem;
	font-weight: 600;
}
.scbb-karussell > .blocks-gallery-caption {
	display: none;
}
.scbb-karussell-quelle {
	margin-top: 4px;
	font-size: 0.8rem;
	color: #666;
	text-align: center;
}
.scbb-karussell__pfeil {
	position: absolute;
	top: calc(50% - 22px);
	transform: translateY(-50%);
	z-index: 2;
	width: 44px;
	height: 44px;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.92);
	box-shadow: 0 1px 6px rgba(0, 0, 0, 0.25);
	color: #4169e1;
	font-size: 1.6rem;
	line-height: 1;
	cursor: pointer;
}
.scbb-karussell__pfeil:hover,
.scbb-karussell__pfeil:focus-visible {
	background: #4169e1;
	color: #fff;
}
.scbb-karussell__pfeil[disabled] {
	opacity: 0;
	pointer-events: none;
}
.scbb-karussell__pfeil--zurueck {
	left: 8px;
}
.scbb-karussell__pfeil--weiter {
	right: 8px;
}
@media (max-width: 700px) {
	.wp-block-gallery.has-nested-images.scbb-karussell figure.wp-block-image:not(#individual-image) {
		flex-basis: 82%;
	}
}

/* En passant: Ausgaben je Jahr, kompakt ohne Aufzählungszeichen */
.scbb-ep-liste {
	list-style: none;
	padding-left: 0;
}
.scbb-ep-liste li {
	margin: 0.2em 0;
}
.scbb-ep-liste strong {
	display: inline-block;
	min-width: 3.2em;
}

/* ---------- Startseite: Aktuelles – zwei Bild-Kacheln mit Detailseite (patterns/aktuelles.php) ---------- */
.scbb-aktuelles {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px;
	margin-block: 0 var(--wp--preset--spacing--40);
}
.scbb-aktuell {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border-top: 4px solid var(--wp--preset--color--scbb-blau);
	border-radius: 4px;
	background: #fff;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}
.scbb-aktuell__bild {
	position: relative;
	display: block;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: #eaf0fc;
}
.scbb-aktuell__bild img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: 50% 25%;
	transition: transform 0.3s ease;
}
.scbb-aktuell:hover .scbb-aktuell__bild img {
	transform: scale(1.03);
}
.scbb-aktuell__nachweis {
	position: absolute;
	right: 0;
	bottom: 0;
	padding: 2px 6px;
	background: rgba(0, 0, 0, 0.55);
	color: #fff;
	font-size: 0.7rem;
	line-height: 1.4;
}
.scbb-aktuell__text {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: 12px 18px 14px;
}
.scbb-aktuell__titel {
	margin: 0 0 6px;
	font-size: 1.3rem;
	font-weight: 700;
	line-height: 1.25;
	hyphens: manual; /* kurze Titel: keine Trennung wie „Sin-darov“ */
}
.scbb-aktuell__titel a {
	color: inherit;
	text-decoration: none;
}
.scbb-aktuell__titel a:hover,
.scbb-aktuell__titel a:focus {
	text-decoration: underline;
}
.scbb-aktuell p {
	margin: 0 0 8px;
	font-size: 1rem;
	line-height: 1.45;
}
@media (max-width: 700px) {
	.scbb-aktuelles {
		grid-template-columns: 1fr;
	}
}


/* ---------- Menüleiste: Untermenü (z. B. Mannschaften → 1.–5. Mannschaft) ---------- */
.scbb-nav .wp-block-navigation__submenu-icon {
	color: #fff;
	margin-left: -10px;
	margin-right: 10px;
}
.scbb-nav .wp-block-navigation-item.has-child > .wp-block-navigation-item__content {
	padding-right: 8px;
}
.scbb-nav .wp-block-navigation__submenu-container {
	min-width: 200px !important;
	width: max-content !important; /* lange Namen wie „Vereinsschnellschachmeisterschaft“ in einer Zeile */
	padding: 4px 0 !important;
	border: none !important;
	background: var(--wp--preset--color--scbb-blau-dunkel) !important;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}
.scbb-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
	padding: 9px 16px;
	letter-spacing: 0.03em;
	text-transform: none;
	font-size: 0.95rem;
}
.scbb-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content:hover,
.scbb-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content:focus {
	background: var(--wp--preset--color--scbb-blau);
}
/* Handy-Menü: Untermenü eingerückt, ohne eigenen Hintergrund */
.scbb-nav .is-menu-open .wp-block-navigation__submenu-container {
	padding: 0 0 4px 16px !important;
	background: transparent !important;
	box-shadow: none;
}
.scbb-nav .is-menu-open .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
	padding: 6px 0;
	font-size: 1rem;
}

/* Zeile mit Logo links (z. B. Lichess auf /online/) */
.scbb-logo-zeile {
	display: flex;
	align-items: center;
	gap: 14px;
}
.scbb-logo-zeile img {
	flex: none;
	width: 48px;
	height: 48px;
	display: block;
}

/* ---------- Turnier-Voranmeldung (assets/js/anmeldung.js) ---------- */
.scbb-anmeldung__turnier {
	margin-block: 0 var(--wp--preset--spacing--40);
}
.scbb-anmeldung__turnier h3 {
	margin-block: 0 0.2em;
	font-size: 1.15rem;
}
.scbb-anmeldung__turnier > p {
	margin-block: 0 0.5em;
}
.scbb-anmeldung figure.scbb-tabelle {
	margin-inline: 0;
}
/* 5 Spalten wie bei den Terminen – hier aber Name und Verein linksbündig, Knopf rechts */
.scbb-anmeldung .scbb-tabelle table tbody tr :is(td, th):is(:nth-child(2), :nth-child(3)),
.scbb-anmeldung .scbb-tabelle table thead tr th:is(:nth-child(2), :nth-child(3)) {
	text-align: left;
}
.scbb-anmeldung .scbb-tabelle td:last-child {
	text-align: right;
}
.scbb-anmeldung__knopf {
	padding: 8px 18px;
	border: 0;
	border-radius: 4px;
	background: var(--wp--preset--color--scbb-blau);
	color: #fff;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
}
.scbb-anmeldung__knopf:hover {
	background: var(--wp--preset--color--scbb-blau-dunkel);
}
.scbb-anmeldung__knopf--ab {
	background: #b3261e;
}
.scbb-anmeldung__knopf--ab:hover {
	background: #8c1d18;
}
.scbb-anmeldung__knopf--leise {
	background: transparent;
	color: var(--wp--preset--color--scbb-blau-dunkel);
}
.scbb-anmeldung__knopf--leise:hover {
	background: var(--wp--preset--color--scbb-blau-hell);
}
.scbb-anmeldung__knopf:disabled {
	opacity: 0.6;
	cursor: wait;
}
.scbb-anmeldung__aendern {
	padding: 0 4px;
	border: 0;
	background: none;
	color: var(--wp--preset--color--scbb-blau-dunkel);
	font: inherit;
	text-decoration: underline;
	cursor: pointer;
}
.scbb-anmeldung__form {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
	gap: 10px 20px;
	padding: 18px 22px;
	background: var(--wp--preset--color--scbb-blau-hell);
	border-left: 6px solid var(--wp--preset--color--scbb-blau);
	border-radius: 4px;
}
.scbb-anmeldung__form > * {
	margin: 0;
}
.scbb-anmeldung__form h4,
.scbb-anmeldung__hinweis,
.scbb-anmeldung__ok,
.scbb-anmeldung__meldung,
.scbb-anmeldung__knoepfe {
	grid-column: 1 / -1;
}
.scbb-anmeldung__form h4 {
	font-size: 1.05rem;
}
.scbb-anmeldung__feld label {
	display: block;
	font-size: 0.9rem;
	font-weight: 600;
}
.scbb-anmeldung .scbb-anmeldung__feld input {
	width: 100%;
	box-sizing: border-box;
	padding: 7px 9px;
	border: 1px solid #b9c6e6;
	border-radius: 4px;
	font: inherit;
	color: #1a1a1a;
	background: #fff;
	background-color: #fff;
	-webkit-appearance: none;
	appearance: none;
}
.scbb-anmeldung .scbb-anmeldung__feld input:-webkit-autofill {
	-webkit-box-shadow: 0 0 0 40px #fff inset;
}
.scbb-anmeldung__feld input[aria-invalid] {
	border-color: #b3261e;
	outline: 2px solid #b3261e;
}
.scbb-anmeldung__knoepfe {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}
.scbb-anmeldung__meldung {
	color: #b3261e;
	font-weight: 600;
}
.scbb-anmeldung__erfolg {
	padding: 6px 10px;
	background: #e6f4ea;
	border-left: 4px solid #1e7e34;
	border-radius: 4px;
}
