/*
Theme Name: Heuermann Seniorendienste
Template: twentytwentyfive
Description: Child-Theme für Heuermann Seniorendienste, Münster. Barrierearm, große Schrift, Markenfarbe Orange.
Author: WOW GmbH
Version: 1.2.1
Text Domain: heuermann
*/

:root {
	--hm-radius: 22px;
	--hm-radius-sm: 14px;
	--hm-shadow: 0 12px 32px rgba(60, 35, 15, 0.08);
	--hm-shadow-hover: 0 18px 40px rgba(60, 35, 15, 0.14);
	--hm-section: clamp(3rem, 7vw, 5.5rem);
}

body {
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

:where(a, button, summary, input, textarea):focus-visible {
	outline: 3px solid var(--wp--preset--color--brand);
	outline-offset: 3px;
	border-radius: 4px;
}

/* ------------------------------------------------------------ Kopfzeile */
.hm-topbar {
	background: var(--wp--preset--color--accent-3);
	color: #fff;
	font-size: 0.95rem;
}
.hm-topbar p { margin: 0; }
.hm-topbar a { color: #fff; text-decoration: none; font-weight: 700; }
.hm-topbar a:hover { text-decoration: underline; }
@media (max-width: 781px) {
	.hm-topbar p:first-child { display: none; }
	.hm-topbar .wp-block-group { justify-content: center !important; }
}

.hm-header {
	position: sticky;
	top: 0;
	z-index: 100;
	/* kein backdrop-filter: der würde das mobile Menü-Overlay in die Kopfzeile einsperren */
	background: var(--wp--preset--color--base);
	box-shadow: 0 4px 18px rgba(60, 35, 15, 0.05);
	border-bottom: 1px solid var(--wp--preset--color--accent-6);
}
.admin-bar .hm-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .hm-header { top: 0; } }

.hm-header .wp-block-site-logo { flex-shrink: 0; }
.hm-header .wp-block-site-logo img { width: clamp(210px, 24vw, 300px); height: auto; }
.hm-header .wp-block-navigation__container { flex-wrap: nowrap; }
.hm-header .wp-block-navigation-item__content,
.hm-header .wp-block-button__link { white-space: nowrap; }

/* Burger-Menü unterhalb von 1360px, weil Logo und Menü zusammen ~1240px brauchen */
@media (max-width: 1359px) {
	.hm-header .wp-block-navigation__responsive-container-open:not(.always-shown) { display: flex !important; }
	.hm-header .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) { display: none !important; }
	.hm-header .wp-block-navigation__responsive-container-open svg { width: 32px; height: 32px; }
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container { flex-wrap: wrap; }
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content { white-space: normal; }
.hm-header .wp-block-navigation .wp-block-navigation-item__content { padding: 0.4rem 0.2rem; }
.hm-header .wp-block-navigation .wp-block-navigation-item__content:hover { color: var(--wp--preset--color--accent-1); }
.hm-header .wp-block-navigation .current-menu-item > .wp-block-navigation-item__content,
.hm-header .wp-block-navigation .current-menu-ancestor > .wp-block-navigation-item__content {
	color: var(--wp--preset--color--accent-1);
	text-decoration: underline;
	text-decoration-thickness: 3px;
	text-underline-offset: 8px;
	text-decoration-color: var(--wp--preset--color--brand);
}
.hm-header .wp-block-navigation__submenu-container {
	border: 1px solid var(--wp--preset--color--accent-6) !important;
	border-radius: var(--hm-radius-sm);
	box-shadow: var(--hm-shadow-hover);
	padding: 0.5rem !important;
	min-width: 260px !important;
}
.hm-header .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
	padding: 0.5rem 0.75rem !important;
	border-radius: 10px;
	font-weight: 500;
}
.hm-header .wp-block-navigation__submenu-container .wp-block-navigation-item__content:hover {
	background: var(--wp--preset--color--accent-2);
}
.hm-header .wp-block-button__link { padding: 0.6em 1.3em; font-size: 1rem; }
.wp-block-navigation__responsive-container.is-menu-open {
	padding: 1.5rem;
	background: var(--wp--preset--color--base) !important;
	color: var(--wp--preset--color--contrast) !important;
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
	align-items: flex-start !important;
	padding-top: 3rem;
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container,
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item { align-items: flex-start !important; }
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container > .wp-block-navigation-item > .wp-block-navigation-item__content {
	font-weight: 800;
	color: var(--wp--preset--color--accent-3);
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container {
	padding: 0.25rem 0 0.75rem 1rem !important;
	border: 0 !important;
	border-left: 3px solid var(--wp--preset--color--accent-2) !important;
	border-radius: 0;
	box-shadow: none;
	background: transparent;
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content { font-size: 1.25rem; }


/* ------------------------------------------------------------ Inhalt */
.hm-main { padding-bottom: var(--hm-section); }
.wp-block-post-content > :first-child:not(.alignfull) { margin-top: var(--hm-section); }

.hm-kicker {
	color: var(--wp--preset--color--accent-1);
	font-size: 0.9rem !important;
	font-weight: 800;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	margin-bottom: 0.5rem !important;
}
.hm-lead { font-size: clamp(1.2rem, 1.6vw, 1.35rem); line-height: 1.65; }

h1.wp-block-heading { text-wrap: balance; }
/* lange deutsche Wörter (z. B. „Pflegeunterstützungsgeld“) dürfen auf dem Handy getrennt werden */
:where(h1, h2, h3, summary) { overflow-wrap: break-word; }
@media (max-width: 600px) {
	:where(h1, h2, h3, summary) { hyphens: auto; -webkit-hyphens: auto; }
}
:where(p, li) { overflow-wrap: break-word; }
h2.wp-block-heading, h3.wp-block-heading { text-wrap: balance; }
.wp-block-post-content h2.wp-block-heading { margin-top: clamp(2.5rem, 5vw, 4rem); }
.wp-block-post-content .wp-block-group h2.wp-block-heading:first-child,
.wp-block-post-content .wp-block-column h2.wp-block-heading:first-child { margin-top: 0; }

.wp-block-post-content .wp-block-image img {
	border-radius: var(--hm-radius);
	box-shadow: var(--hm-shadow);
	height: auto;
}
.wp-block-post-content .wp-block-image:not(.hm-photo) img { max-height: 540px; width: auto; max-width: 100%; }
.wp-block-post-content li + li { margin-top: 0.4em; }
.wp-block-columns.alignwide { gap: clamp(1.5rem, 4vw, 3.5rem); }

/* Kopfbereich */
.is-style-hm-hero {
	background:
		radial-gradient(1700px 800px at 85% -15%, rgba(255, 102, 0, 0.30), rgba(255, 102, 0, 0.12) 45%, transparent 75%),
		linear-gradient(180deg, var(--wp--preset--color--accent-2) 0%, var(--wp--preset--color--base) 100%);
	padding-top: clamp(2.5rem, 7vw, 5.5rem) !important;
	padding-bottom: clamp(2.5rem, 7vw, 5rem) !important;
	margin-top: 0 !important;
	margin-bottom: clamp(2rem, 5vw, 3.5rem) !important;
}
.is-style-hm-hero > * { max-width: var(--wp--style--global--wide-size) !important; }
.is-style-hm-hero h1 { margin-top: 0; }

/* Band */
.is-style-hm-band {
	background: var(--wp--preset--color--accent-5);
	padding-top: var(--hm-section) !important;
	padding-bottom: var(--hm-section) !important;
	margin-top: var(--hm-section) !important;
	margin-bottom: var(--hm-section) !important;
}

/* Karte, Box, Hinweis */
.is-style-hm-card,
.is-style-hm-soft,
.is-style-hm-cta,
.is-style-hm-notice {
	border-radius: var(--hm-radius);
	padding: clamp(1.25rem, 2.4vw, 1.75rem) !important;
}
:where(.is-style-hm-card, .is-style-hm-soft) h3 { font-size: 1.3rem; }
.is-style-hm-card {
	background: #fff;
	border: 1px solid var(--wp--preset--color--accent-6);
	box-shadow: var(--hm-shadow);
}
.is-style-hm-soft {
	background: var(--wp--preset--color--accent-2);
	border: 1px solid #F7D9C2;
}
.is-style-hm-notice {
	background: #FFF8E6;
	border-left: 6px solid var(--wp--preset--color--brand);
}
.is-style-hm-card > :first-child,
.is-style-hm-soft > :first-child,
.is-style-hm-cta > :first-child,
.is-style-hm-notice > :first-child { margin-top: 0; }
.is-style-hm-card > :last-child,
.is-style-hm-soft > :last-child,
.is-style-hm-cta > :last-child,
.is-style-hm-notice > :last-child { margin-bottom: 0; }
/* Karten nebeneinander bündig (gleiche Höhe), unter 1024px untereinander */
.wp-block-column > :is(.is-style-hm-card, .is-style-hm-soft):only-child { height: 100%; }
/* Bildspalte neben langem Text läuft beim Scrollen mit, statt eine leere Fläche zu lassen */
@media (min-width: 1024px) {
	.wp-block-columns > .wp-block-column:has(> .wp-block-image) {
		position: sticky;
		top: 130px;
		align-self: flex-start;
	}
}
@media (max-width: 1023px) {
	.wp-block-columns:has(> .wp-block-column > :is(.is-style-hm-card, .is-style-hm-soft)):not(.hm-teasers) { flex-wrap: wrap !important; }
	.wp-block-columns:has(> .wp-block-column > :is(.is-style-hm-card, .is-style-hm-soft)):not(.hm-teasers) > .wp-block-column { flex-basis: 100% !important; }
}

.is-style-hm-cta {
	background: linear-gradient(135deg, var(--wp--preset--color--accent-1), #8F3A00);
	color: #fff;
	margin-top: var(--hm-section) !important;
	margin-bottom: var(--hm-section) !important;
	box-shadow: var(--hm-shadow-hover);
}
.is-style-hm-cta :where(h2, h3, h4) { color: #fff; }
.is-style-hm-cta a { color: #fff; font-weight: 700; }

.is-style-hm-dark {
	background-color: #1D1D1D;
	color: #fff;
	padding-top: var(--hm-section) !important;
	padding-bottom: var(--hm-section) !important;
	margin-top: var(--hm-section) !important;
}
.hm-hero-dark { padding-top: clamp(2.5rem, 5vw, 4rem) !important; padding-bottom: clamp(2.5rem, 5vw, 4rem) !important; }
.is-style-hm-dark :where(h2, h3) { color: #fff; }
.is-style-hm-dark .wp-block-button__link { background: var(--wp--preset--color--brand); color: #1D1D1D; }
.is-style-hm-dark .wp-block-button__link:hover { background: #fff; color: #1D1D1D; }

.hm-hero-dark {
	background-color: #000 !important;
	margin-top: 0 !important;
	margin-bottom: 0 !important;
	min-height: clamp(460px, 36vw, 540px);
	display: flex;
	flex-direction: column;
	justify-content: center;
}
.hm-hero-dark h1 { color: #fff; margin-top: 0; font-size: clamp(2rem, 3.2vw, 2.9rem); }
/* Text links neben dem Gesicht halten (inneren Block auf volle Breite, sonst zentriert ihn das Flex-Layout) */
.hm-hero-dark > .wp-block-group { width: 100%; }
.hm-hero-dark > .wp-block-group > * { max-width: min(640px, 50vw) !important; margin-left: 0 !important; margin-right: auto !important; }
@media (max-width: 1099px) { .hm-hero-dark > .wp-block-group > * { max-width: 640px !important; } }
.hm-hero-dark .hm-kicker { color: #FF9A57; }
.hm-hero-dark .hm-lead { color: #EDEDED; font-size: clamp(1.1rem, 1.4vw, 1.25rem); }
.hm-hero-dark .is-style-outline .wp-block-button__link { background: transparent; color: #fff; border-color: #fff; }
.hm-hero-dark .is-style-outline .wp-block-button__link:hover { background: #fff; color: #1D1D1D; }
/* schmaler: Bild als Band oben rechts (Gesicht bleibt sichtbar), Text darunter auf Schwarz */
@media (max-width: 1099px) {
	.hm-hero-dark,
	.hm-karriere {
		background-repeat: no-repeat !important;
		background-size: auto 280px !important;
		background-position: right top !important;
		padding-top: 300px !important;
		min-height: 0;
	}
}
@media (max-width: 600px) {
	.hm-hero-dark,
	.hm-karriere { background-size: auto 220px !important; padding-top: 235px !important; }
}
.hm-hero-dark, .hm-karriere { background-repeat: no-repeat !important; }
.hm-karriere { background-color: #000 !important; }
.hm-intro { margin-top: var(--hm-section) !important; }

/* Startseiten-Teaser: Raster 4 / 2 / 1 Spalten, damit nichts zerrupft */
.wp-block-columns.hm-teasers {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 1.25rem;
	margin-top: 2rem;
}
.hm-teasers > .wp-block-column { flex-basis: auto !important; margin: 0 !important; }
@media (max-width: 1099px) { .wp-block-columns.hm-teasers { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .wp-block-columns.hm-teasers { grid-template-columns: 1fr; gap: 0.85rem; } }
.hm-teaser {
	position: relative;
	height: 100%;
	display: flex !important;
	flex-direction: column;
	gap: 1rem;
	padding: 1.5rem !important;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.hm-teaser::before {
	content: "";
	flex: none;
	width: 60px;
	height: 60px;
	border-radius: 50%;
	background: var(--wp--preset--color--brand) center / 62% no-repeat;
}
.hm-teaser--herz::before { background-image: url(assets/icons/herz.svg); }
.hm-teaser--schaukelstuhl::before { background-image: url(assets/icons/schaukelstuhl.svg); }
.hm-teaser--formular::before { background-image: url(assets/icons/formular.svg); background-size: 58%; }
.hm-teaser--euro::before { background-image: url(assets/icons/euro.svg); background-size: 58%; }
.hm-teaser:hover { transform: translateY(-4px); box-shadow: var(--hm-shadow-hover); }
.hm-teaser h3 { font-size: 1.2rem; line-height: 1.3; margin: 0 !important; hyphens: manual; }
.hm-teaser h3 a { color: var(--wp--preset--color--accent-3); text-decoration: none; }
.hm-teaser h3 a::after {
	content: "Mehr erfahren →";
	display: block;
	margin-top: 0.6rem;
	font-size: 1rem;
	font-weight: 700;
	color: var(--wp--preset--color--accent-1);
}
.hm-teaser h3 a::before { content: ""; position: absolute; inset: 0; border-radius: var(--hm-radius); }
@media (max-width: 560px) {
	.hm-teaser { flex-direction: row; align-items: center; padding: 1rem 1.25rem !important; }
	.hm-teaser::before { width: 52px; height: 52px; }
}

/* Fotos mit Plakette */
.hm-photo { position: relative; }
.hm-photo img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.hm-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.85rem;
	position: relative;
	margin: -2.25rem 0 0 1.5rem !important;
	padding: 0.5rem 1.4rem 0.5rem 0.5rem;
	background: #fff;
	border-radius: 999px;
	box-shadow: var(--hm-shadow-hover);
	font-weight: 800;
	color: var(--wp--preset--color--accent-3);
}
.hm-badge::before {
	content: "";
	flex: none;
	width: 54px;
	height: 54px;
	border-radius: 50%;
	background: var(--wp--preset--color--brand) center / 70% no-repeat;
}
.hm-badge--herz::before { background-image: url(assets/icons/herz.svg); }
.hm-badge--schaukelstuhl::before { background-image: url(assets/icons/schaukelstuhl.svg); }

/* Liste mit Häkchen */
ul.is-style-hm-checks { list-style: none; padding-left: 0; }
ul.is-style-hm-checks li { position: relative; padding-left: 2.1rem; }
ul.is-style-hm-checks li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.3em;
	width: 1.35rem;
	height: 1.35rem;
	border-radius: 50%;
	background: var(--wp--preset--color--accent-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%23B84A00' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 75% no-repeat;
}

/* Aufklappbare Fragen */
.wp-block-details {
	background: #fff;
	border: 1px solid var(--wp--preset--color--accent-6);
	border-radius: var(--hm-radius-sm);
	padding: 0;
	margin-block: 0.75rem !important;
	transition: box-shadow 0.2s ease;
}
.wp-block-details[open] { box-shadow: var(--hm-shadow); }
.wp-block-details summary {
	list-style: none;
	cursor: pointer;
	padding: 1.1rem 3.5rem 1.1rem 1.4rem;
	font-weight: 700;
	position: relative;
	color: var(--wp--preset--color--accent-3);
}
.wp-block-details summary::-webkit-details-marker { display: none; }
.wp-block-details summary::after {
	content: "+";
	position: absolute;
	right: 1.2rem;
	top: 50%;
	transform: translateY(-50%);
	width: 2rem;
	height: 2rem;
	display: grid;
	place-items: center;
	border-radius: 50%;
	background: var(--wp--preset--color--accent-2);
	color: var(--wp--preset--color--accent-1);
	font-size: 1.4rem;
	line-height: 1;
}
.wp-block-details[open] summary::after { content: "–"; }
.wp-block-details > :not(summary) { padding: 0 1.4rem; }
.wp-block-details > :last-child { padding-bottom: 1.2rem; }


/* Kontakt-Icons (Linien-Icons als Maske, Farbe über background-color) */
.hm-ico { position: relative; padding-left: 2rem; }
.hm-ico::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.25em;
	width: 1.3rem;
	height: 1.3rem;
	background-color: currentColor;
	-webkit-mask: var(--hm-ico) center / contain no-repeat;
	mask: var(--hm-ico) center / contain no-repeat;
}
.hm-footer .hm-ico::before { background-color: #FF8A3D; }
.hm-topbar .hm-ico { padding-left: 1.6rem; }
.hm-topbar .hm-ico::before { width: 1.05rem; height: 1.05rem; top: 0.2em; }
.hm-ico--phone { --hm-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44' fill='none' stroke='black' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M8 4h7l3 8-4 3a20 20 0 0 0 11 11l3-4 8 3v7a3 3 0 0 1-3 3A33 33 0 0 1 5 7a3 3 0 0 1 3-3z'/%3E%3C/svg%3E"); }
.hm-ico--mail { --hm-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44' fill='none' stroke='black' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='10' width='34' height='24' rx='3'/%3E%3Cpath d='M6 12l16 12 16-12'/%3E%3C/svg%3E"); }
.hm-ico--pin { --hm-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44' fill='none' stroke='black' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 40S10 28 10 19a12 12 0 0 1 24 0c0 9-12 21-12 21z'/%3E%3Ccircle cx='22' cy='19' r='4.5'/%3E%3C/svg%3E"); }
.hm-ico--clock { --hm-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44' fill='none' stroke='black' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='22' cy='22' r='16'/%3E%3Cpath d='M22 13v9l6 4'/%3E%3C/svg%3E"); }

/* ------------------------------------------------------------ Fußzeile */
.hm-footer {
	background: var(--wp--preset--color--accent-3);
	color: #E9EDEE;
	padding-top: var(--hm-section) !important;
	padding-bottom: 2rem !important;
	margin-top: 0 !important;
}
.hm-footer :where(h2, h3, h4) { color: #fff; font-size: 1.15rem; margin-bottom: 1rem; }
.hm-footer a { color: #fff; }
.hm-footer a:hover { color: #FFB27D; }
.hm-footer .hm-footer-logo { font-size: 1.4rem; font-weight: 800; color: #fff; }
.hm-footer .hm-footer-logo span { color: #FF8A3D; }
.hm-footer-bottom {
	border-top: 1px solid rgba(255, 255, 255, 0.15);
	margin-top: 3rem !important;
	padding-top: 1.5rem;
	font-size: 0.95rem;
	color: #C5CDD0;
}
.hm-footer-links { list-style: none; padding: 0; margin: 0; }
.hm-footer-links li { margin: 0.35rem 0; }
.hm-footer .hm-ico { margin: 0 0 0.6rem !important; }

@media (prefers-reduced-motion: reduce) {
	* { transition: none !important; scroll-behavior: auto !important; }
}
