/*
 * Dora Wollinger – Ergänzungen zu theme.json.
 * Nur das, was theme.json nicht ausdrücken kann: Fokus, Stilvarianten, eigene Klassen, Blüten.
 */

h1, h2, h3, .wp-block-site-title, .wp-block-quote p, .wp-block-post-title { text-wrap: balance; }
p { text-wrap: pretty; }

/* Sichtbarer Fokus, überall gleich */
:where(a, button, input, select, textarea, [tabindex]):focus-visible {
	outline: 3px solid var(--wp--preset--color--rose);
	outline-offset: 3px;
	border-radius: 4px;
}

/* Links im Fließtext: kräftige rosa Linie */
.wp-block-post-content a:not(.wp-block-button__link),
.dw-footer a {
	font-weight: 700;
	text-decoration-thickness: 2px;
	text-underline-offset: 0.2em;
	text-decoration-color: var(--wp--preset--color--blossom);
}
.wp-block-post-content a:not(.wp-block-button__link):hover,
.dw-footer a:hover {
	text-decoration-color: var(--wp--preset--color--rose);
}

/* Kopfbereich */
.dw-header {
	padding-top: var(--wp--preset--spacing--20);
	padding-bottom: var(--wp--preset--spacing--20);
}
/* Mobiles Menü: Knopf im Stil der Buttons, Overlay in Creme mit großen Links */
.dw-header .wp-block-navigation__responsive-container-open {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	min-height: 2.75rem;
	padding: 0.5rem 1rem 0.5rem 0.85rem;
	border-radius: 999px;
	background: var(--wp--preset--color--mauve);
	color: var(--wp--preset--color--cream);
	font-family: var(--wp--preset--font-family--sans);
	font-size: var(--wp--preset--font-size--small);
	font-weight: 700;
}
.dw-header .wp-block-navigation__responsive-container-open::after {
	content: "Menü";
}
.dw-header .wp-block-navigation__responsive-container-open svg {
	width: 1.5rem;
	height: 1.5rem;
	fill: currentColor;
}
.dw-header .wp-block-navigation__responsive-container-open:hover,
.dw-header .wp-block-navigation__responsive-container-open:focus-visible {
	background: var(--wp--preset--color--cocoa);
	color: var(--wp--preset--color--paper);
}
@media (min-width: 600px) {
	.dw-header .wp-block-navigation__responsive-container-open:not(.always-shown) { display: none; }
}

.dw-header .wp-block-navigation__responsive-container.is-menu-open {
	background: var(--wp--preset--color--cream);
	color: var(--wp--preset--color--cocoa);
	padding: var(--wp--preset--spacing--30);
	background-image: url("../img/flowers.svg");
	background-repeat: no-repeat;
	background-position: right -6rem bottom -6rem;
	background-size: 22rem auto;
}
.dw-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
	padding-top: 4.5rem;
}
.dw-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container {
	gap: var(--wp--preset--spacing--20);
}
.dw-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
	font-family: var(--wp--preset--font-family--display);
	font-size: var(--wp--preset--font-size--xx-large);
	font-weight: 600;
	line-height: 1.1;
	color: var(--wp--preset--color--mauve);
	text-decoration: none;
	padding: 0.25rem 0;
}
.dw-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content:hover,
.dw-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content:focus-visible {
	text-decoration: underline;
	text-decoration-thickness: 3px;
	text-decoration-color: var(--wp--preset--color--blossom);
	text-underline-offset: 0.15em;
}
.dw-header .wp-block-navigation__responsive-container-close {
	top: var(--wp--preset--spacing--30);
	right: var(--wp--preset--spacing--30);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.75rem;
	height: 2.75rem;
	border-radius: 999px;
	background: var(--wp--preset--color--mauve);
	color: var(--wp--preset--color--cream);
}
.dw-header .wp-block-navigation__responsive-container-close svg { fill: currentColor; }

/* Fußbereich: rosa Fläche mit Blüten am Rand */
.dw-footer {
	position: relative;
	overflow: hidden;
	padding-top: var(--wp--preset--spacing--50);
	padding-bottom: var(--wp--preset--spacing--50);
	margin-top: 0 !important;
}
.dw-footer::after {
	content: "";
	position: absolute;
	right: -3rem;
	bottom: -7rem;
	width: 26rem;
	height: 18rem;
	background: url("../img/flowers.svg") no-repeat center / contain;
	opacity: 0.5;
	pointer-events: none;
}
.dw-footer > * { position: relative; }
.dw-footer a { color: inherit; }
.dw-footer__address { line-height: 1.7; }

/* Sektionen: feine Linie oben, keine Kästen */
.dw-section + .dw-section { border-top: 1px solid var(--wp--preset--color--line); }
.dw-about, .dw-about + .dw-section { border-top: 0; }

/* Einstieg mit Blüten links oben */
.dw-hero { position: relative; overflow: hidden; }
.dw-hero::before {
	content: "";
	position: absolute;
	left: -4rem;
	top: -2rem;
	width: 24rem;
	height: 16rem;
	background: url("../img/flowers.svg") no-repeat center / contain;
	opacity: 0.6;
	pointer-events: none;
}
.dw-hero > * { position: relative; }
.dw-hero__title { margin-bottom: var(--wp--preset--spacing--30); }
.dw-hero__lead { max-width: 36ch; }
.dw-hero__title { hyphens: manual; overflow-wrap: normal; }

/* Tafel (Gruppen-Stil): weiße Fläche, große Rundung, feine Linie unten */
.is-style-panel {
	padding: var(--wp--preset--spacing--30);
	border-radius: var(--wp--custom--radius);
	box-shadow: 0 1px 0 var(--wp--preset--color--line);
}

/* Rundes Porträt mit Blütenring */
.dw-portrait { margin: 0; }
.dw-portrait img {
	border-radius: 50%;
	aspect-ratio: 1;
	object-fit: cover;
	border: 0.5rem solid var(--wp--preset--color--blossom);
	background: var(--wp--preset--color--blossom);
}
.dw-portrait--large img { width: min(20rem, 100%); height: auto; }

/* Nächster Kurs: Porträt sitzt oben auf der Tafel */
.dw-next { position: relative; padding-top: 4.5rem; }
.dw-next__portrait {
	position: absolute;
	left: var(--wp--preset--spacing--30);
	top: 0;
	width: 8.5rem;
	z-index: 1;
}
.dw-next__panel { padding-top: 5.5rem; }
.dw-next__facts { margin-top: 0; }

/* Zeiten: Uhrzeit groß in Fredoka, Alter daneben */
.dw-times {
	display: grid;
	gap: 0.5rem;
	margin: 0 0 var(--wp--preset--spacing--20);
	padding: var(--wp--preset--spacing--20) 0;
	border-top: 1px solid var(--wp--preset--color--line);
	border-bottom: 1px solid var(--wp--preset--color--line);
}
.dw-times li { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.dw-times__time {
	font-family: var(--wp--preset--font-family--display);
	font-size: var(--wp--preset--font-size--large);
	font-weight: 600;
	color: var(--wp--preset--color--mauve);
	font-variant-numeric: tabular-nums;
}

/* Blüte vor einem Hinweis oder einem Listenpunkt */
.dw-flower-note,
.dw-bausteine li {
	padding-left: 2.25rem;
	position: relative;
}
.dw-flower-note::before,
.dw-bausteine li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.15em;
	width: 1.5rem;
	height: 1.5rem;
	background: url("../img/flower.svg") no-repeat center / contain;
}
.dw-flower-note { margin-top: var(--wp--preset--spacing--10); }
.dw-flower-note::before { width: 1.25rem; height: 1.25rem; }

/* Bausteine der Stunde */
.dw-bausteine { display: grid; gap: var(--wp--preset--spacing--30); }
@media (min-width: 782px) { .dw-bausteine { grid-template-columns: 1fr 1fr; } }
.dw-bausteine li strong {
	display: block;
	font-family: var(--wp--preset--font-family--display);
	font-size: var(--wp--preset--font-size--large);
	font-weight: 600;
	color: var(--wp--preset--color--mauve);
	margin-bottom: 0.25rem;
}

/* Clipart aus dem Flyer: freigestellt, sitzt auf dem cremefarbenen Grund */
.dw-clipart { margin: var(--wp--preset--spacing--30) 0 0; }
.dw-clipart img { width: min(22rem, 100%); height: auto; }

/* Listen ohne Aufzählungszeichen */
.is-style-plain { list-style: none; padding-left: 0; }

/* Kurszeiten-Tabelle */
.is-style-schedule table { border-collapse: collapse; width: 100%; }
.is-style-schedule th,
.is-style-schedule td {
	text-align: left;
	padding: 1rem 1rem 1rem 0;
	border: 0;
	border-bottom: 1px solid var(--wp--preset--color--line);
	vertical-align: baseline;
}
.is-style-schedule th { font-weight: 700; font-size: var(--wp--preset--font-size--small); }
.is-style-schedule td:first-child {
	font-family: var(--wp--preset--font-family--display);
	font-size: var(--wp--preset--font-size--large);
	font-weight: 600;
	color: var(--wp--preset--color--mauve);
	white-space: nowrap;
}
.is-style-schedule td:nth-child(2) { font-variant-numeric: tabular-nums; white-space: nowrap; }

@media (max-width: 640px) {
	.is-style-schedule thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
	.is-style-schedule tr { display: grid; grid-template-columns: 1fr 1fr; gap: 0.2rem 1rem; padding: 0.9rem 0; border-bottom: 1px solid var(--wp--preset--color--line); }
	.is-style-schedule td { border: 0; padding: 0; }
	.is-style-schedule td:first-child { grid-column: 1 / -1; }
	.is-style-schedule td:nth-child(4), .is-style-schedule td:nth-child(5) { font-size: var(--wp--preset--font-size--small); }
	.is-style-schedule td:nth-child(3), .is-style-schedule td:nth-child(5) { text-align: right; }
}

/* Leitsatz */
.dw-quote-section { text-align: center; }
.dw-quote-section::before {
	content: "";
	display: block;
	width: 3rem;
	height: 3rem;
	margin: 0 auto var(--wp--preset--spacing--20);
	background: url("../img/flower.svg") no-repeat center / contain;
}
.dw-quote { max-width: 26ch; margin-left: auto; margin-right: auto; }
.dw-quote cite {
	display: block;
	margin-top: var(--wp--preset--spacing--20);
	font-family: var(--wp--preset--font-family--sans);
	font-size: var(--wp--preset--font-size--small);
	font-weight: 500;
	font-style: normal;
	color: var(--wp--preset--color--cocoa);
}

/* Kontakt */
.dw-contact__mail a,
.dw-contact__phone a {
	font-weight: 600;
	text-decoration-thickness: 3px;
	text-underline-offset: 0.15em;
	text-decoration-color: var(--wp--preset--color--blossom);
	word-break: break-word;
}
.dw-contact__phone a { color: var(--wp--preset--color--cocoa); text-decoration: none; font-family: var(--wp--preset--font-family--display); }

/* Umrandeter Button */
.wp-block-button.is-style-outline .wp-block-button__link {
	background: transparent;
	color: var(--wp--preset--color--mauve);
	box-shadow: inset 0 0 0 2px currentColor;
}
.wp-block-button.is-style-outline .wp-block-button__link:hover,
.wp-block-button.is-style-outline .wp-block-button__link:focus {
	background: var(--wp--preset--color--mauve);
	color: var(--wp--preset--color--cream);
}

/* Beitragsliste */
.dw-post-list__item { padding: var(--wp--preset--spacing--30) 0; border-top: 1px solid var(--wp--preset--color--line); }
.dw-post-list__item .wp-block-post-title a { text-decoration: none; }
.dw-post-list__item .wp-block-post-title a:hover { text-decoration: underline; text-decoration-color: var(--wp--preset--color--blossom); }

/* Keine Animationen im Theme; Systemeinstellung respektieren */
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
