/*
Theme Name: Eppmann & Schaaf Classic
Description: Variante im Look der bisherigen Website (Kopfbild, Siegel, blaue Leisten, Kacheln). Child-Theme von „Eppmann & Schaaf“ – Inhalte und Funktionen sind identisch, nur die Optik wechselt.
Template: eppmann-schaaf
Version: 1.0
Requires at least: 6.6
Requires PHP: 7.4
Text Domain: eppmann-schaaf-classic
License: GPL-2-or-later
*/

:root {
	--ec-blue: #3d5998;
	--ec-blue-light: #697eb3;
	--ec-navy: #1e3056;
	--ec-red: #9c1818;
	--ec-grey: #e8ecef;
	--ec-ink: #242424;
	--ec-max: 1620px;
	--ec-gutter: clamp(1.1rem, 4vw, 3rem);
	--ec-head: 114px;
	--es-display: "Alegreya Sans", system-ui, sans-serif;
	--es-radius: 0px;
	--es-shadow: none;
	--es-navy: #3d5998;
	--es-blue: #3d5998;
	--es-red: #9c1818;
	--es-ink: #242424;
	--es-muted: #242424;
	--es-line: #d9dee4;
	--es-ice: #e8ecef;
	--es-frost: #e8ecef;

	/* Symbole in den Button-Kästchen */
	--ec-i-termin: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='5' width='17' height='15'/%3E%3Cpath d='M3.5 10h17M8 3v4M16 3v4M8 13.5h2M14 13.5h2M8 16.5h2'/%3E%3C/svg%3E");
	--ec-i-list: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='4' width='14' height='17'/%3E%3Cpath d='M9 2.5h6v3H9zM8.5 10h7M8.5 13.5h7M8.5 17h4'/%3E%3C/svg%3E");
	--ec-i-thermo: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 13.8V5a2 2 0 0 1 4 0v8.8a4 4 0 1 1-4 0z'/%3E%3Cpath d='M12 9v7.5'/%3E%3C/svg%3E");
	--ec-i-plus: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='8'/%3E%3Cpath d='M12 8.5v7M8.5 12h7'/%3E%3C/svg%3E");
	--ec-i-file: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 3h8l4 4v14H6z'/%3E%3Cpath d='M14 3v4h4M9 13h6M9 16.5h4'/%3E%3C/svg%3E");
	--ec-i-star: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linejoin='round'%3E%3Cpath d='m12 3.5 2.6 5.4 5.9.800-4.3 4.1 1.1 5.9L12 16.9l-5.3 2.8 1.1-5.9-4.3-4.1 5.9-.800z'/%3E%3C/svg%3E");

	/* Symbole der vier Leistungskacheln */
	--ec-t-snow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48' fill='none' stroke='%23242424' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M24 4v40M6.7 14l34.6 20M6.7 34l34.6-20'/%3E%3Cpath d='m19 8 5 5 5-5M19 40l5-5 5 5M6 21l6.8-1.8L11 12.4M37 35.6l-1.8-6.8L42 27M6 27l6.8 1.8L11 35.6M37 12.4l-1.8 6.8L42 21'/%3E%3C/svg%3E");
	--ec-t-fan: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48' fill='none' stroke='%23242424' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='24' cy='24' r='3.5'/%3E%3Cpath d='M24 20.5c-3-5-2-11 3-12s8 4 5 8-6 4-8 4zM27.5 24c5-3 11-2 12 3s-4 8-8 5-4-6-4-8zM24 27.5c3 5 2 11-3 12s-8-4-5-8 6-4 8-4zM20.5 24c-5 3-11 2-12-3s4-8 8-5 4 6 4 8z'/%3E%3Cpath d='M8 12a20 20 0 0 1 6-5M40 36a20 20 0 0 1-6 5'/%3E%3C/svg%3E");
	--ec-t-sun: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48' fill='none' stroke='%23242424' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='24' cy='24' r='10'/%3E%3Cpath d='m24 5 3 5.5 5.5-3 .500 6.3 6.3.500-3 5.5L42 24l-5.7 4.2 3 5.5-6.3.500-.500 6.3-5.5-3L24 43l-3-5.5-5.5 3-.500-6.3-6.3-.500 3-5.5L6 24l5.7-4.2-3-5.5 6.3-.500.5-6.3 5.5 3z'/%3E%3C/svg%3E");
	--ec-t-tools: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48' fill='none' stroke='%23242424' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 18h6v24h-6zM8 8h12l6 4v4l-6-2H8z'/%3E%3Cpath d='M30 42V22a8 8 0 0 1-2-14v8h8V8a8 8 0 0 1-2 14v20z'/%3E%3C/svg%3E");
}

body { font-weight: 300; color: var(--ec-ink); padding-top: var(--ec-head); }
.ec-wrap { width: min(var(--ec-max), 100% - 2 * var(--ec-gutter)); margin-inline: auto; }
strong, b { font-weight: 500; }
.wp-block-post-content strong { color: inherit; }
a { color: var(--ec-red); }
a:hover { color: var(--ec-blue); }

/* ------------------------------------------------------------ Buttons mit Symbol-Kästchen */
.es-btn,
.wp-block-button__link,
.wp-block-button.is-style-outline .wp-block-button__link {
	position: relative; display: inline-flex; align-items: center;
	font-family: inherit; font-weight: 500; font-size: 1rem; line-height: 1.3;
	min-height: 57px; box-sizing: border-box; padding: 14px 84px 14px 25px;
	background: var(--ec-blue); color: #fff; border: 0; border-radius: 0; text-decoration: none;
	transition: background-color .2s ease;
}
.es-btn::after,
.wp-block-button__link::after {
	content: ""; position: absolute; right: 0; top: 0; bottom: 0; width: 59px;
	background: var(--ec-red) var(--ec-i-plus) center / 22px no-repeat;
	transition: background-color .2s ease; transform: none;
}
.es-btn:hover, .wp-block-button__link:hover,
.wp-block-button.is-style-outline .wp-block-button__link:hover { background: var(--ec-navy); color: #fff; }
.es-btn:hover::after, .wp-block-button__link:hover::after { background-color: #7c1010; }
.ec-ico-termin::after { background-image: var(--ec-i-termin); }
.ec-ico-list::after { background-image: var(--ec-i-list); }
.ec-ico-file::after { background-image: var(--ec-i-file); }
.ec-ico-star::after { background-image: var(--ec-i-star); }
.es-form .es-btn { cursor: pointer; }

/* ------------------------------------------------------------ Kopfleiste */
.ec-top { position: fixed; inset: 0 0 auto 0; z-index: 60; }
.admin-bar .ec-top { top: 32px; }
.ec-bar { background: var(--ec-blue); }
.ec-bar .ec-wrap { display: flex; align-items: stretch; justify-content: space-between; min-height: 68px; }
.ec-brand { display: flex; align-items: center; color: #fff; text-decoration: none; font-weight: 900; font-size: 1.75rem; letter-spacing: -.005em; white-space: nowrap; }
.ec-brand:hover { color: #fff; }
.ec-nav ul { list-style: none; margin: 0; padding: 0; }
.ec-nav__list { display: flex; height: 100%; }
.ec-nav__list > li { position: relative; display: flex; }
.ec-nav a { display: flex; align-items: center; gap: .5rem; padding: 0 16px; color: var(--ec-grey); text-decoration: none; font-weight: 400; font-size: 1rem; }
.ec-nav__list > li:hover > a, .ec-nav__list > li.is-active > a, .ec-nav__list > li:focus-within > a { background: var(--ec-blue-light); color: #fff; }
.ec-nav__arrow { font-size: .8em; }
.ec-nav__sub { position: absolute; left: 0; top: 100%; min-width: 100%; background: var(--ec-blue); opacity: 0; visibility: hidden; transition: opacity .15s ease, visibility .15s; }
.ec-nav__list > li:hover > .ec-nav__sub, .ec-nav__list > li:focus-within > .ec-nav__sub { opacity: 1; visibility: visible; }
.ec-nav__sub a { padding: 14px 16px; white-space: nowrap; color: #fff; }
.ec-nav__sub li:hover > a, .ec-nav__sub li.is-active > a { background: var(--ec-blue-light); }
.ec-burger { display: none; }
.ec-subbar { background: var(--ec-blue-light); color: #fff; font-size: .95rem; }
.ec-subbar .ec-wrap { display: flex; justify-content: space-between; align-items: center; min-height: 46px; }
.ec-subbar__tag { letter-spacing: .38em; padding-left: 2.6rem; font-weight: 400; }
.ec-subbar__info { display: flex; gap: 1.4rem; }
.ec-subbar a { color: #fff; text-decoration: none; }

@media (max-width: 1020px) {
	:root { --ec-head: 100px; }
	.ec-bar .ec-wrap { min-height: 60px; position: relative; }
	.ec-brand { font-size: 1.45rem; }
	.ec-burger { display: inline-flex; align-items: center; gap: .5rem; background: none; border: 0; color: #fff; font: inherit; font-weight: 500; cursor: pointer; }
	.ec-nav { display: none; position: absolute; left: calc(-1 * var(--ec-gutter)); right: calc(-1 * var(--ec-gutter)); top: 100%; background: var(--ec-blue); max-height: calc(100vh - 60px); overflow: auto; }
	.ec-nav.is-open { display: block; }
	.ec-nav__list { flex-direction: column; height: auto; }
	.ec-nav__list > li { display: block; }
	.ec-nav a { padding: 14px var(--ec-gutter); border-top: 1px solid rgba(255, 255, 255, .15); }
	.ec-nav__arrow { display: none; }
	.ec-nav__sub { position: static; opacity: 1; visibility: visible; background: rgba(0, 0, 0, .12); }
	.ec-nav__sub a { padding-left: calc(var(--ec-gutter) + 1.2rem); }
	.ec-subbar .ec-wrap { min-height: 40px; }
	.ec-subbar__tag { padding-left: 0; letter-spacing: .25em; }
	.ec-subbar__info span { display: none; }
}

/* ------------------------------------------------------------ Kopfbild mit Claim */
.ec-hero { background: #eaebef var(--ec-hero-img, none) center right / cover no-repeat; }
.ec-hero__claim { max-width: 800px; padding: clamp(3rem, 9vw, 9rem) 0 clamp(2rem, 5vw, 4.5rem); }
.ec-hero__title { margin: 0; font-weight: 900; font-size: clamp(1.9rem, 3.2vw, 2.8rem); line-height: 1.12; color: var(--ec-blue); }
.ec-hero__title span { display: block; font-weight: 400; font-size: .89em; }
.ec-hero__sub { font-size: clamp(1.15rem, 1.7vw, 1.55rem); line-height: 1.4; font-weight: 300; margin: 1.5rem 0 0; max-width: 34em; }
.ec-hero__buttons { display: flex; flex-wrap: wrap; gap: 18px; margin: clamp(2rem, 4vw, 3.75rem) 0 clamp(2rem, 5vw, 5rem); }
.ec-hero__badges { display: flex; gap: clamp(1rem, 4vw, 4.2rem); align-items: center; min-height: 20px; }
.ec-hero__badges img { width: clamp(80px, 9vw, 125px); height: auto; }
@media (max-width: 760px) {
	.ec-hero { background-image: linear-gradient(rgba(234, 235, 239, .82), rgba(234, 235, 239, .82)), var(--ec-hero-img, none); }
}

/* ------------------------------------------------------------ Inhalt */
.es-content { padding-block: clamp(3rem, 8vw, 9.4rem) 0; }
.es-content > .wp-block-post-content > :last-child { margin-bottom: clamp(3rem, 8vw, 9.4rem); }
.wp-block-post-content h1 { margin-bottom: 0; line-height: 1; }
.wp-block-post-content h1 + .es-sub, .es-sub { font-family: inherit; font-weight: 300; font-size: 1.9rem; line-height: 1.3; color: var(--ec-blue); margin: 0 0 1.6rem; }
.wp-block-post-content h1:not(:has(+ .es-sub)) { margin-bottom: 1.6rem; }
.wp-block-post-content h2 { margin-top: 2.8rem; margin-bottom: 1.2rem; }
.wp-block-post-content p { margin-block: 0 1.6rem; }
.wp-block-post-content a:not(.wp-block-button__link) { color: var(--ec-red); }

/* Zweispaltige Reihen: Text 5/10, Abstand 1/10, Bild 4/10 */
.wp-block-post-content .wp-block-columns.alignwide { gap: 2rem 10%; }
.wp-block-post-content .wp-block-columns.alignwide + .wp-block-columns.alignwide { margin-top: clamp(3rem, 6vw, 6.25rem); }
@media (min-width: 782px) {
	.wp-block-columns.alignwide > .wp-block-column[style*="58%"] { flex-basis: 50% !important; }
	.wp-block-columns.alignwide > .wp-block-column:not([style]):not(.es-card) { flex-basis: 40%; }
}
.es-figure img { box-shadow: none; aspect-ratio: auto; border-radius: 0; }
.wp-block-image img, .wp-block-gallery img { border-radius: 0; }

/* Leistungs-Band mit Hintergrundbild */
.es-section { padding-block: clamp(3rem, 7vw, 6.25rem); }
.es-section--tint { background: none; border: 0; }
.es-section--navy { background: #cdd4dc var(--ec-teaser-img, none) center right / cover no-repeat; color: var(--ec-blue); padding-block: clamp(4rem, 9vw, 8.5rem); margin-block: clamp(3rem, 7vw, 6.25rem) 0 !important; }
.es-section--navy > * { max-width: 1350px !important; }
.es-section--navy h2 { color: var(--ec-blue); font-weight: 300; font-size: 1.75rem; line-height: 1.25; margin: 0 0 2.2rem; }
.es-section--navy h2 strong { display: block; font-weight: 900; font-size: .93em; color: var(--ec-blue); }
.es-section--navy :is(h3, p) { color: var(--ec-blue); }
.es-pills.wp-block-buttons { gap: 20px; max-width: 800px; margin-left: 0; }
.es-pills .wp-block-button__link { background: var(--ec-blue); border: 0; border-radius: 0; padding: 14px 84px 14px 25px; font-size: 1rem; color: #fff; }
.es-pills .wp-block-button__link::after { background-color: var(--ec-navy); background-image: var(--ec-i-thermo); }
.es-pills .wp-block-button__link:hover { background: var(--ec-navy); color: #fff; }
.es-pills .wp-block-button__link:hover::after { background-color: #131f3a; }

/* Listen mit Pfeil */
.wp-block-post-content h3 { font-weight: 300; font-size: 1.0625rem; color: var(--ec-ink); margin-bottom: 1.2rem; }
ul.es-check li { padding-left: 15px; margin-bottom: 7px; }
ul.es-check li::before { content: "→"; border: 0; transform: none; width: auto; height: auto; left: 0; top: 0; font-size: .75em; color: var(--ec-ink); }
ul.es-check a { font-weight: 300; text-decoration: underline; }

/* Leistungskacheln */
.es-cards.wp-block-columns { gap: 36px; max-width: var(--ec-max); }
.es-card { background: var(--ec-grey); border: 0; border-radius: 0; box-shadow: none; padding: 60px clamp(1.2rem, 3vw, 4rem); text-align: center; align-items: center; }
.es-card::before { content: ""; display: block; width: 100px; height: 100px; background: var(--ec-t-snow) center / 76px no-repeat; margin-bottom: 40px; }
.es-card:nth-child(2)::before { background-image: var(--ec-t-fan); }
.es-card:nth-child(3)::before { background-image: var(--ec-t-sun); }
.es-card:nth-child(4)::before { background-image: var(--ec-t-tools); }
.es-card h3 { font-weight: 900; font-size: 1.3rem; line-height: 1.4; color: var(--ec-blue); margin: 0 0 20px; }
.es-card p { color: var(--ec-ink); margin-bottom: 40px; }
.es-card .wp-block-buttons { justify-content: center; }
.es-card .wp-block-button__link { background: var(--ec-blue); color: #fff; padding: 14px 84px 14px 25px; font-size: 1rem; }
.es-card .wp-block-button__link::after { content: ""; transform: none; }
.es-card .wp-block-button__link:hover { background: var(--ec-navy); color: #fff; }
.es-card .wp-block-button__link:hover::after { transform: none; }

.es-callout { background: var(--ec-grey); border-left: 0; padding: 2rem 2.2rem; }
.es-callout p:last-child { margin-bottom: 0; }
.es-team li { background: var(--ec-grey); border: 0; }
.es-team__avatar { background: #fff; }
.es-team__name { font-weight: 900; color: var(--ec-blue); }
.es-facts dd { font-weight: 500; color: var(--ec-ink); }
.es-form legend { font-weight: 900; color: var(--ec-blue); }
.es-form label { font-weight: 500; }
.es-form input[type="text"], .es-form input[type="email"], .es-form input[type="tel"], .es-form textarea { border-radius: 0; }
.es-map { border-radius: 0; border: 0; background: var(--ec-grey); }
.es-map__inner { box-shadow: none; }
.es-map__inner .es-btn--light { background: var(--ec-blue); color: #fff; }

/* ------------------------------------------------------------ Fußbereich */
.ec-foot h2 { font-size: 1.5rem; font-weight: 900; color: var(--ec-blue); margin: 0 0 1.4rem; }
.ec-foot__top { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(2rem, 5vw, 5rem); align-items: start; padding-block: clamp(2rem, 5vw, 4rem) clamp(3rem, 8vw, 9rem); }
.ec-foot__btns { display: flex; flex-wrap: wrap; gap: 20px; }
.ec-foot__rating { background: var(--ec-grey); padding: clamp(1.5rem, 3vw, 2.8rem); }
.ec-foot__rating .es-btn { margin-top: 18px; }
.ec-foot__bottom { display: grid; grid-template-columns: 1fr 1fr; min-height: 420px; }
.ec-foot__map .es-map { height: 100%; min-height: 320px; background: #ededed; }
.ec-foot__map .es-map iframe { height: 100%; min-height: 420px; }
.ec-foot__info { background: var(--ec-blue); color: #fff; padding: clamp(2.5rem, 8vw, 8rem) clamp(1.2rem, 6vw, 8rem); display: flex; flex-direction: column; justify-content: center; gap: 2.2rem; }
.ec-foot__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
.ec-foot__head { font-weight: 500; font-size: 1.1rem; margin: 0 0 .8rem; }
.ec-foot__info ul { list-style: none; margin: 0; padding: 0; }
.ec-foot__info a { color: var(--ec-grey); text-decoration: none; }
.ec-foot__info a:hover { color: #fff; text-decoration: underline; }
.ec-foot__links { display: flex; flex-wrap: wrap; gap: 1.2rem; font-weight: 500; }
@media (max-width: 860px) {
	.ec-foot__top, .ec-foot__bottom, .ec-foot__cols { grid-template-columns: 1fr; }
}
@media print {
	.ec-top, .ec-hero, .ec-foot { display: none !important; }
	body { padding-top: 0; }
}

/* Feinschliff */
.es-btn, .wp-block-button__link { white-space: nowrap; }
.ec-foot__btns .es-btn { white-space: normal; }
.wp-block-post-content .es-cards.wp-block-columns.alignwide { gap: 36px; }
@media (max-width: 600px) { .es-btn, .wp-block-button__link { white-space: normal; } }
.es-content > .wp-block-post-content > :last-child { margin-bottom: clamp(2rem, 5vw, 5rem); }
.es-content > .wp-block-post-content > .es-section:last-child { padding-bottom: 0; }
