/*
Theme Name: Mindful Engineering
Theme URI: https://mindful-engineering.org
Author: Phoenix Champions GmbH
Description: Block-Theme für Mindful Engineering – Human Leadership for Tomorrow. Farben, Schrift und Bausteine nach Markenhandbuch V 1.1.
Version: 1.2.0
Requires at least: 6.6
Tested up to: 6.8
Requires PHP: 8.0
License: Proprietary
Text Domain: mindful-engineering
*/

/* ---------- Grundlagen ---------- */
body { -webkit-font-smoothing: antialiased; }
:where(.wp-site-blocks) > * { margin-block-start: 0; }
a:focus-visible, .wp-element-button:focus-visible, summary:focus-visible {
	outline: 3px solid var(--wp--preset--color--ink);
	outline-offset: 3px;
}
.me-section { padding-top: var(--wp--preset--spacing--60); padding-bottom: var(--wp--preset--spacing--60); }
.me-section.has-ink-background-color :where(h1, h2, h3) { color: var(--wp--preset--color--white); }
.me-muted { color: var(--wp--preset--color--gray); }
.has-ink-background-color .me-muted { color: var(--wp--preset--color--sand); }
.me-lead { font-size: var(--wp--preset--font-size--large); font-weight: 600; line-height: 1.45; }

/* Kleine Überzeile mit türkisem Balken */
.me-eyebrow {
	display: flex; align-items: center; gap: 12px;
	font-size: 14px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
	color: var(--wp--preset--color--gray);
}
.me-eyebrow::before { content: ""; width: 4px; height: 20px; border-radius: 2px; background: var(--wp--preset--color--turquoise); flex: none; }
.has-ink-background-color .me-eyebrow { color: var(--wp--preset--color--sand); }

/* Türkise Unterstreichung, z. B. „wirkt.“ */
.me-mark {
	text-decoration: underline;
	text-decoration-color: var(--wp--preset--color--turquoise);
	text-decoration-thickness: .16em;
	text-underline-offset: .1em;
	text-decoration-skip-ink: none;
}
.me-turq { color: var(--wp--preset--color--turquoise); }

/* Buttons */
.wp-element-button { transition: transform .15s ease, background-color .15s ease; }
.wp-element-button:hover { transform: translateY(-2px); }
.wp-block-button.is-style-me-turquoise .wp-block-button__link {
	background: var(--wp--preset--color--turquoise); color: var(--wp--preset--color--ink);
}
.wp-block-button.is-style-me-turquoise .wp-block-button__link:hover { background: #4DEDFF; color: var(--wp--preset--color--ink); }
.me-textlink a { font-weight: 700; }

/* Raster, das auf kleineren Bildschirmen umbricht */
.wp-block-columns.me-grid { flex-wrap: wrap !important; }
.wp-block-columns.me-grid > .wp-block-column { flex: 1 1 240px; min-width: 0; }
.wp-block-columns.me-grid-wide > .wp-block-column { flex-basis: 300px; }

/* ---------- Kopfzeile ---------- */
.me-header { background: var(--wp--preset--color--ivory); }
.me-header .me-logo img { height: 52px; width: auto; display: block; }
.me-header .wp-block-navigation { font-weight: 600; font-size: 16px; }
.me-header .wp-block-navigation a { text-decoration: none; }
.me-header .wp-block-navigation a:hover { text-decoration: underline; }
.me-header .wp-block-button__link { padding: 11px 20px; font-size: 16px; }

/* ---------- Hero ---------- */
.me-hero .wp-block-columns { align-items: center; }
.me-hero h1 { hyphens: manual; overflow-wrap: break-word; }
.me-hero-media { position: relative; max-width: 460px; margin-inline: auto; }
.me-hero-media::before {
	content: ""; position: absolute; left: -20px; top: 40px; bottom: 40px; width: 8px;
	border-radius: 4px; background: var(--wp--preset--color--turquoise);
}
.me-hero-media .wp-block-image img { width: 100%; aspect-ratio: 5 / 6; object-fit: cover; object-position: center 20%; border-radius: 16px; }
.me-badge {
	position: absolute; left: 0; bottom: 32px; margin: 0 !important;
	background: #fff; border-radius: 12px; padding: 14px 18px 14px 66px;
	box-shadow: 0 12px 32px rgba(36,36,36,.14); font-size: 15px; line-height: 1.4;
	background-image: url(assets/images/mark.svg); background-repeat: no-repeat; background-size: 36px auto; background-position: 18px center;
}
.me-facts { list-style: none; padding: 24px 0 0; margin-top: 16px; border-top: 1px solid var(--wp--preset--color--sand); display: flex; flex-wrap: wrap; gap: 10px 28px; font-size: 15px; font-weight: 600; }
.me-facts li { display: flex; align-items: center; gap: 8px; }
.me-facts li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--wp--preset--color--turquoise); }
@media (max-width: 781px) { .me-badge { position: static; margin-top: -28px !important; } .me-hero-media::before { display: none; } }

/* ---------- Karten ---------- */
.me-card { border-radius: 16px; padding: 32px; height: 100%; box-sizing: border-box; }
.me-card-hover { transition: transform .2s ease, box-shadow .2s ease; }
.me-card-hover:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(36,36,36,.10); }
.me-card > * { margin-block: 0; }
.me-card > * + * { margin-top: 14px; }
.me-card .me-card-link { margin-top: auto; padding-top: 6px; }
.wp-block-group.me-card { display: flex; flex-direction: column; }
.me-card-outline { border: 1px solid var(--wp--preset--color--sand); background: #fff; }

/* Gedanken-Zitatkarten */
.me-thought { position: relative; padding-top: 52px; }
.me-thought::before { content: "“"; position: absolute; top: 18px; left: 32px; font-size: 56px; line-height: 1; font-weight: 800; color: var(--wp--preset--color--turquoise); }
.me-thought .me-thought-text { font-size: 21px; font-weight: 700; line-height: 1.35; }
.me-thought .me-thought-note { font-size: 15px; color: var(--wp--preset--color--gray); line-height: 1.5; }

/* Schritte mit türkiser Linie */
.me-step { border-top: 4px solid var(--wp--preset--color--turquoise); padding-top: 24px; }
.me-step > * { margin-block: 0; }
.me-step > * + * { margin-top: 12px; }
.me-step .me-step-no { font-size: 15px; font-weight: 700; color: var(--wp--preset--color--sand); }
.me-step .me-step-title { font-size: 30px; font-weight: 800; }
.me-approach { background: #2F2F2F; border: 1px solid #3A3A3A; border-radius: 16px; padding: clamp(28px, 4vw, 48px) !important; }

/* Nummernkreise */
.me-num { width: 48px; height: 48px; border-radius: 50%; background: var(--wp--preset--color--ink); color: var(--wp--preset--color--turquoise); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 20px; }

/* Vorher / Nachher */
.me-list-plain { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 16px; font-size: 18px; line-height: 1.5; }
.me-list-plain li { display: flex; gap: 14px; }
.me-list-minus li::before { content: "–"; font-weight: 700; }
.me-list-check li::before { content: "✓"; color: var(--wp--preset--color--turquoise); }
.me-list-check { font-weight: 600; }

/* Werte-Chips */
.me-chips { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.me-chips li { padding: 8px 16px; border-radius: 999px; background: var(--wp--preset--color--ivory); font-size: 15px; font-weight: 600; }

/* Porträts */
.me-portrait img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: center 15%; border-radius: 16px; }
.me-photo img { width: 100%; border-radius: 16px; object-fit: cover; }
.me-photo-accent { position: relative; }
.me-photo-accent::after { content: ""; position: absolute; right: -16px; top: 32px; bottom: 32px; width: 8px; border-radius: 4px; background: var(--wp--preset--color--turquoise); }
.me-photo-accent img { aspect-ratio: 4 / 5; object-position: center 10%; }
.me-name { font-size: 22px; font-weight: 800; margin-bottom: 0; }
.me-role { font-size: 15px; font-weight: 600; color: var(--wp--preset--color--gray); margin-top: 4px !important; }

/* Hintergrund-Zeichen im dunklen Block */
.me-insight { position: relative; overflow: hidden; }
.me-insight::after {
	content: ""; position: absolute; right: -80px; top: 50%; transform: translateY(-50%);
	width: 520px; height: 440px; opacity: .12; pointer-events: none;
	background: url(assets/images/mark.svg) no-repeat center / contain;
}
.me-insight > * { position: relative; z-index: 1; }
@media (max-width: 781px) { .me-insight::after { display: none; } }

/* FAQ */
.me-faq .wp-block-details { border-top: 1px solid var(--wp--preset--color--sand); margin: 0; }
.me-faq .wp-block-details:last-child { border-bottom: 1px solid var(--wp--preset--color--sand); }
.me-faq summary { cursor: pointer; list-style: none; padding: 24px 48px 24px 0; font-weight: 700; font-size: 19px; line-height: 1.4; position: relative; }
.me-faq summary::-webkit-details-marker { display: none; }
.me-faq summary::after { content: "+"; position: absolute; right: 8px; top: 20px; font-size: 28px; font-weight: 400; color: var(--wp--preset--color--gray); }
.me-faq details[open] summary::after { content: "–"; }
.me-faq details > p { margin: 0 0 24px; font-size: 17px; color: var(--wp--preset--color--gray); }

/* ---------- Fusszeile ---------- */
.me-footer { background: var(--wp--preset--color--ivory); font-size: 16px; }
.me-footer .me-logo img { height: 60px; width: auto; }
.me-footer .me-footer-title { font-weight: 700; margin-bottom: 4px; }
.me-footer p { margin-block: 6px; }
.me-footer .me-legal { border-top: 1px solid var(--wp--preset--color--sand); padding-top: 24px; font-size: 14px; color: var(--wp--preset--color--gray); }

/* ---------- Rechtstexte ---------- */
.me-legal-page h2 { font-size: 24px; margin-top: 48px; }

/* ---------- Feinschliff ---------- */
.me-approach, .me-card { box-sizing: border-box; }
.me-eyebrow.me-turq, .has-ink-background-color .me-eyebrow.me-turq { color: var(--wp--preset--color--turquoise); }
.me-header .wp-block-group { flex-wrap: wrap; }
.me-footer-cols { gap: 32px 48px; }
@media (max-width: 781px) {
	.me-badge { position: relative; z-index: 2; }
	.me-hero h1 { font-size: clamp(32px, 9vw, 44px); }
}
@media (max-width: 600px) {
	.me-header .wp-block-buttons { display: none; }
}

/* ---------- Kontakt & Formular ---------- */
.me-contact .me-contact-photo img { aspect-ratio: 16 / 10; object-position: center 15%; }
.me-contact-direct > * { margin-block: 0; }
.me-contact-direct > * + * { margin-top: 10px; }
.me-form-card { box-shadow: 0 16px 40px rgba(36,36,36,.08); padding: clamp(24px, 4vw, 44px); }
.me-form { display: flex; flex-direction: column; gap: 18px; }
.me-form p { margin: 0; }
.me-form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; }
.me-field label { display: block; font-size: 15px; font-weight: 700; margin-bottom: 6px; }
.me-req { color: var(--wp--preset--color--ink); }
.me-opt { font-weight: 400; color: var(--wp--preset--color--gray); }
.me-form input[type=text], .me-form input[type=email], .me-form input[type=tel], .me-form select, .me-form textarea {
	width: 100%; box-sizing: border-box; font: inherit; font-size: 17px; color: var(--wp--preset--color--ink);
	background: #fff; border: 1px solid var(--wp--preset--color--sand); border-radius: 8px; padding: 12px 14px; min-height: 48px;
	transition: border-color .15s ease, box-shadow .15s ease;
}
.me-form textarea { min-height: 150px; resize: vertical; line-height: 1.5; }
.me-form select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, #625D57 50%), linear-gradient(135deg, #625D57 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 40px; }
.me-form input:focus, .me-form select:focus, .me-form textarea:focus { outline: none; border-color: var(--wp--preset--color--ink); box-shadow: 0 0 0 3px rgba(9,227,251,.45); }
.me-form ::placeholder { color: #8A847D; }
.me-check { display: flex; gap: 12px; align-items: flex-start; }
.me-check input { width: 20px; height: 20px; margin-top: 3px; flex: none; accent-color: var(--wp--preset--color--ink); }
.me-check label { font-weight: 400; font-size: 15px; line-height: 1.5; margin: 0; }
.me-form-submit { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.me-form-submit .wp-element-button { border: 0; cursor: pointer; font-family: inherit; }
.me-form-submit .me-muted { font-size: 14px; }
.me-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.me-form-error { background: #FFF1F0; border-left: 4px solid #B42318; color: #7A1A12; padding: 12px 16px; border-radius: 6px; font-size: 16px; }
.me-form-success { padding: 8px 0; }
.me-form-success::before { content: "✓"; display: flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 50%; background: var(--wp--preset--color--turquoise); color: var(--wp--preset--color--ink); font-weight: 800; font-size: 26px; margin-bottom: 18px; }
.me-form-success-title { font-size: 26px; font-weight: 800; margin: 0 0 8px; }
.me-contact .me-contact-photo { margin-top: 8px !important; }
.me-contact-direct .me-footer-title { font-weight: 700; }
.me-form :user-invalid { border-color: #B42318; }
