/*
Theme Name: wasfliegtda
Theme URI: https://wasfliegtda.de/
Description: Child-Theme von Twenty Twenty-Five im Erscheinungsbild von wasfliegtda.de: dunkel, Sora für Überschriften, Onest für Text, Lila und Gelb als Akzente. Schriften liegen lokal im Theme.
Template: twentytwentyfive
Version: 0.2.1
Requires at least: 6.7
Requires PHP: 8.1
License: GPLv2 or later
Text Domain: wasfliegtda
*/

/*
 * Farben, Schriften, Größen und Abstände stehen in theme.json (aus dem CI-Paket, siehe
 * design/DESIGN.md im Plugin „Was fliegt da“). Hier steht nur, was theme.json nicht kann.
 */

/* Fokus immer sichtbar. */
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
	outline: 2px solid var(--wp--preset--color--satellitengelb);
	outline-offset: 3px;
}

/* Die Seite ist dunkel: Formularfelder und Rollbalken des Browsers passen sich an. */
:root {
	color-scheme: dark;
}

body {
	-webkit-font-smoothing: antialiased;
}

/* Fließtext nicht breiter als rund 70 Zeichen, Überschriften ausgeglichen umbrochen. */
h1,
h2,
h3,
h4,
h5,
h6 {
	text-wrap: balance;
}

:where(p) {
	text-wrap: pretty;
}

a {
	text-decoration-thickness: 1px;
	text-underline-offset: 0.2em;
}

/* Zahlen, die sich ändern, springen nicht. */
.zahl,
time {
	font-variant-numeric: tabular-nums;
}

/* Kopf: Logo nie verzerren, Mindestbreite 120 px. */
.wasfliegtda-logo {
	display: block;
	line-height: 0;
}

.wasfliegtda-logo img {
	display: block;
	width: auto;
	height: 28px;
	min-width: 120px;
}

/*
 * Navigation im Kopf: auf jeder Seite gleich. Die Seite, auf der man ist, trägt einen Strich in
 * Orbitlila. Auf dem Handy öffnet der Knopf rechts oben das Menü; er sitzt immer an derselben Stelle.
 */
.wasfliegtda-kopf .wp-block-navigation {
	font-family: var(--wp--preset--font-family--body);
	font-weight: 600;
}

.wasfliegtda-kopf .wp-block-navigation-item__content {
	padding-block: var(--wp--preset--spacing--2);
	text-decoration: none;
}

.wasfliegtda-kopf .current-menu-item > .wp-block-navigation-item__content {
	text-decoration: underline;
	text-decoration-color: var(--wp--preset--color--orbitlila);
	text-decoration-thickness: 2px;
	text-underline-offset: 0.4em;
}

.wasfliegtda-kopf .wp-block-navigation-item__content:hover {
	color: var(--wp--preset--color--lila-200);
}

/* Menü-Knopf und Schließen-Knopf: Trefferfläche 48 px, das Symbol bleibt, wo es ist. */
.wasfliegtda-kopf .wp-block-navigation__responsive-container-open,
.wasfliegtda-kopf .wp-block-navigation__responsive-container-close {
	margin: calc(-1 * var(--wp--preset--spacing--3));
	padding: var(--wp--preset--spacing--3);
}

/* Geöffnetes Menü auf dem Handy: große, linksbündige Einträge statt einer schmalen Spalte am Rand. */
.wasfliegtda-kopf .wp-block-navigation__responsive-container.is-menu-open {
	padding: var(--wp--preset--spacing--4) var(--wp--preset--spacing--50);
}

.wasfliegtda-kopf .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content,
.wasfliegtda-kopf .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container {
	align-items: flex-start;
	gap: var(--wp--preset--spacing--2);
}

.wasfliegtda-kopf .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
	padding-top: var(--wp--preset--spacing--8);
}

.wasfliegtda-kopf .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
	/* Navigation bleibt in der Stufe „button“ (Onest 600); groß wird nur die Trefferfläche. */
	padding-block: var(--wp--preset--spacing--4);
	font-size: var(--wp--preset--font-size--body);
}

.wasfliegtda-fuss {
	border-top: 1px solid var(--wp--preset--color--rahmen);
	color: var(--wp--preset--color--text-sekundaer);
}

/* Suchfeld und andere Eingabefelder: Fläche, kräftiger Rahmen, mittlerer Radius. */
.wp-block-search__input,
:where(input[type="text"], input[type="search"], input[type="email"], input[type="url"], input[type="tel"], input[type="number"], textarea, select) {
	border: 1px solid var(--wp--preset--color--rahmen-kraeftig);
	border-radius: 12px;
	background: var(--wp--preset--color--flaeche);
	color: var(--wp--preset--color--contrast);
	font-family: var(--wp--preset--font-family--body);
}

.wp-block-search__input::placeholder {
	color: var(--wp--preset--color--text-gedaempft);
	opacity: 1;
}
