/*
 * Stylesheet für Malerbetrieb Kevin Vaupel.
 * Webdesign und technische Umsetzung: CEIS-IT.de
 * Enthält Layout, responsive Navigation, Kontaktbereich, Galerie und Barrierefreiheitszustände.
 */
:root {
    --ink: #18140f;
    --muted: #5d5146;
    --soft: #f5eee5;
    --cream: #fbf7f0;
    --white: #ffffff;
    --gold: #c48a38;
    --terracotta: #b75d32;
    --green: #3f5a45;
    --line: rgba(24, 20, 15, .12);
    --shadow: 0 26px 80px rgba(45, 31, 17, .18);
    --radius: 28px;
    --max: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; width: 100%; max-width: 100%; overflow-x: hidden; }
body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--ink);
    background: var(--cream);
    line-height: 1.6;
    overflow-x: hidden;
    max-width: 100%;
}
@supports (overflow: clip) {
    html, body { overflow-x: clip; }
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
.wrap { width: min(var(--max), calc(100% - 36px)); margin-inline: auto; max-width: 100%; }
.site-header, main, .site-footer, .section { max-width: 100%; }
.narrow { max-width: 820px; }
.skip-link { position: fixed; left: 16px; top: -80px; z-index: 99; padding: 12px 16px; background: var(--ink); color: var(--white); border-radius: 12px; }
.skip-link:focus { top: 16px; }

.site-header { position: sticky; top: 0; z-index: 2147483000; background: rgba(251, 247, 240, .76); backdrop-filter: blur(18px); border-bottom: 1px solid transparent; transition: border-color .25s, box-shadow .25s, background .25s; isolation: isolate; }
.site-header.is-scrolled { border-bottom-color: var(--line); box-shadow: 0 10px 30px rgba(24,20,15,.08); background: rgba(251, 247, 240, .94); }
.topline { background: var(--ink); color: var(--white); font-size: .88rem; }
.topline__inner { min-height: 36px; display: flex; align-items: center; justify-content: flex-end; gap: 22px; }
.topline a { color: var(--white); opacity: .92; }
.nav-shell { min-height: 86px; display: flex; align-items: center; justify-content: space-between; gap: 22px; position: relative; }
.brand { display: inline-flex; align-items: center; gap: 13px; min-width: 0; }
.brand img { width: 78px; height: auto; filter: drop-shadow(0 12px 20px rgba(24,20,15,.14)); }
.brand strong { display: block; font-size: .98rem; letter-spacing: -.02em; }
.brand small { display: block; color: var(--muted); font-size: .82rem; margin-top: 1px; }
.main-nav { display: flex; align-items: center; gap: 8px; }
.main-nav a { padding: 10px 13px; border-radius: 999px; color: rgba(24,20,15,.76); font-weight: 750; font-size: .95rem; }
.main-nav a:hover { background: rgba(196, 138, 56, .13); color: var(--ink); }
.main-nav .nav-cta { background: var(--ink); color: var(--white); padding-inline: 18px; }
.nav-cta--whatsapp { display: inline-flex; align-items: center; gap: 8px; }
.nav-cta__icon { flex: 0 0 auto; display: block; }
.nav-toggle { display: none; border: 0; background: var(--ink); color: var(--white); border-radius: 999px; padding: 10px 14px; align-items: center; gap: 9px; min-height: 44px; }
.nav-toggle__icon { width: 22px; height: 16px; display: inline-flex; flex-direction: column; justify-content: space-between; flex: 0 0 22px; }
.nav-toggle__icon span { width: 22px; height: 2px; background: currentColor; display: block; margin: 0; border-radius: 99px; }
.nav-toggle em { font-style: normal; font-size: .85rem; font-weight: 800; }

.section { padding: 96px 0; position: relative; }
.hero { min-height: auto; display: grid; align-items: center; padding: 54px 0 68px; overflow: hidden; background: radial-gradient(circle at 10% 10%, rgba(196,138,56,.24), transparent 28%), linear-gradient(135deg, #fbf7f0 0%, #efe1cf 100%); }
/* Animierte Hintergrundobjekte im Hero-Bereich.
   Die Bewegung bleibt bewusst ruhig, damit die Seite hochwertig wirkt und nicht vom Inhalt ablenkt. */
.paint-orb { position: absolute; width: 360px; height: 360px; border-radius: 42% 58% 70% 30% / 30% 35% 65% 70%; filter: blur(.2px); opacity: .55; animation: paintFloatOne 16s ease-in-out infinite alternate; pointer-events: none; will-change: transform, border-radius; }
.paint-orb--one { right: -140px; top: 120px; background: rgba(183, 93, 50, .28); }
.paint-orb--two { left: -150px; bottom: 40px; background: rgba(63, 90, 69, .22); animation-name: paintFloatTwo; animation-delay: -5s; animation-duration: 19s; }
@keyframes paintFloatOne {
    0% { transform: translate3d(0, 0, 0) rotate(0deg) scale(1); border-radius: 42% 58% 70% 30% / 30% 35% 65% 70%; }
    50% { transform: translate3d(-34px, 26px, 0) rotate(12deg) scale(1.05); border-radius: 58% 42% 46% 54% / 52% 40% 60% 48%; }
    100% { transform: translate3d(-72px, -18px, 0) rotate(22deg) scale(1.09); border-radius: 62% 38% 42% 58% / 55% 55% 45% 45%; }
}
@keyframes paintFloatTwo {
    0% { transform: translate3d(0, 0, 0) rotate(0deg) scale(1); border-radius: 42% 58% 70% 30% / 30% 35% 65% 70%; }
    50% { transform: translate3d(46px, -24px, 0) rotate(-10deg) scale(1.06); border-radius: 36% 64% 48% 52% / 58% 42% 58% 42%; }
    100% { transform: translate3d(88px, 20px, 0) rotate(-18deg) scale(1.1); border-radius: 62% 38% 42% 58% / 55% 55% 45% 45%; }
}
.hero-grid { display: grid; grid-template-columns: minmax(0, .98fr) minmax(330px, .9fr); align-items: center; gap: 42px; }
.eyebrow, .section-kicker { color: var(--terracotta); text-transform: uppercase; letter-spacing: .13em; font-size: .77rem; font-weight: 900; margin: 0 0 12px; }
h1, h2, h3 { line-height: 1.05; letter-spacing: -.055em; margin: 0; }
h1 { font-size: clamp(2.16rem, 5.28vw, 4.2rem); max-width: 660px; }
h2 { font-size: clamp(2.1rem, 4.5vw, 4.35rem); }
h3 { font-size: 1.35rem; letter-spacing: -.035em; }
.lead { font-size: clamp(1.08rem, 1.8vw, 1.32rem); color: var(--muted); max-width: 640px; margin: 24px 0 0; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.btn { display: inline-flex; min-height: 50px; align-items: center; justify-content: center; gap: 8px; border-radius: 999px; padding: 13px 21px; border: 1px solid transparent; font-weight: 900; cursor: pointer; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { color: var(--white); background: linear-gradient(135deg, var(--ink), #3b2b1a); box-shadow: 0 18px 38px rgba(24,20,15,.22); }
.btn-soft { color: var(--ink); background: rgba(255,255,255,.72); border-color: rgba(24,20,15,.1); }
.hero-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 34px 0 0; max-width: 520px; }
.hero-facts div { background: rgba(255,255,255,.52); border: 1px solid rgba(24,20,15,.08); border-radius: 22px; padding: 18px; }
.hero-facts dt { font-size: 2rem; line-height: 1; font-weight: 950; letter-spacing: -.06em; }
.hero-facts dd { margin: 6px 0 0; color: var(--muted); font-size: .9rem; }
.hero-media { position: relative; }
.hero-media::before { content: ""; position: absolute; inset: 7% -5% -6% 9%; border-radius: 34px; background: var(--green); transform: rotate(5deg); opacity: .22; }
.hero-media img { position: relative; aspect-ratio: 4 / 5; width: 100%; max-height: 560px; object-fit: cover; border-radius: 38px; box-shadow: var(--shadow); }
.glass-card { position: absolute; left: -22px; bottom: 36px; max-width: 270px; border: 1px solid rgba(255,255,255,.56); border-radius: 24px; padding: 18px; background: rgba(255,255,255,.75); box-shadow: 0 18px 55px rgba(24,20,15,.16); backdrop-filter: blur(16px); }
.glass-card strong { display: block; }
.glass-card span { display: block; color: var(--muted); font-size: .95rem; margin-top: 4px; }

.intro { background: var(--ink); color: var(--white); padding: 86px 0; }
.intro-grid { display: grid; grid-template-columns: .35fr 1.05fr .62fr; gap: 32px; align-items: start; }
.intro p { color: rgba(255,255,255,.74); font-size: 1.08rem; margin: 8px 0 0; }
.intro .section-kicker { color: #e5b16c; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 28px; margin-bottom: 34px; }
.section-head h2 { max-width: 820px; }
.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.service-card { position: relative; overflow: hidden; min-height: 440px; cursor: pointer; border-radius: var(--radius); background: var(--ink); color: var(--white); box-shadow: 0 18px 60px rgba(24,20,15,.12); }
.service-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .78; transition: transform .55s ease, opacity .35s ease; }
.service-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 15%, rgba(24,20,15,.84) 100%); }
.service-card:hover img { transform: scale(1.07); opacity: .92; }
.service-card__content { position: absolute; inset: auto 0 0; z-index: 2; padding: 26px; }
.service-card__number { display: inline-flex; width: 44px; height: 44px; align-items: center; justify-content: center; border-radius: 99px; background: rgba(255,255,255,.16); margin-bottom: 15px; font-weight: 900; }
.service-card p { color: rgba(255,255,255,.78); margin: 10px 0 0; }
.service-card__toggle { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; margin-top: 16px; padding: 10px 15px; border: 1px solid rgba(255,255,255,.36); border-radius: 999px; background: rgba(255,255,255,.14); color: var(--white); font-weight: 900; cursor: pointer; transition: background .2s ease, transform .2s ease, border-color .2s ease; }
.service-card__toggle::after { content: "+"; display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; margin-left: 9px; border-radius: 999px; background: rgba(255,255,255,.18); font-weight: 900; line-height: 1; }
.service-card__toggle:hover, .service-card__toggle:focus { background: rgba(255,255,255,.22); border-color: rgba(255,255,255,.58); transform: translateY(-1px); outline: none; }
.service-card__toggle:focus-visible { outline: 3px solid rgba(255,255,255,.58); outline-offset: 3px; }
.service-card__details { max-height: 0; overflow: hidden; opacity: 0; transform: translateY(8px); transition: max-height .32s ease, opacity .24s ease, transform .24s ease; }
.service-card__details p { font-size: .9rem; line-height: 1.42; color: rgba(255,255,255,.86); margin-top: 12px; }
.service-card.is-open { min-height: 500px; }
.service-card.is-open img { transform: scale(1.07); opacity: .58; }
.service-card.is-open::after { background: linear-gradient(180deg, rgba(24,20,15,.22) 0%, rgba(24,20,15,.93) 100%); }
.service-card.is-open .service-card__toggle::after { content: "−"; }
.service-card.is-open .service-card__details { max-height: 260px; opacity: 1; transform: translateY(0); }
.process { background: #efe4d5; }
.process-grid { display: grid; grid-template-columns: .8fr 1fr; gap: 48px; align-items: start; }
.process-copy { position: sticky; top: 140px; }
.process-copy p:not(.eyebrow) { color: var(--muted); font-size: 1.08rem; }
.steps { display: grid; gap: 16px; }
.step { border: 1px solid var(--line); border-radius: 26px; padding: 28px; background: rgba(255,255,255,.58); box-shadow: 0 18px 45px rgba(24,20,15,.07); }
.step span { display: inline-block; color: var(--terracotta); font-weight: 950; margin-bottom: 16px; }
.step p { margin-bottom: 0; color: var(--muted); }
.gallery { background: var(--cream); }
.gallery-grid { display: grid; grid-template-columns: 1.1fr .9fr; grid-auto-rows: 260px; gap: 18px; }
.gallery-grid img { width: 100%; height: 100%; object-fit: cover; border-radius: 28px; box-shadow: 0 20px 55px rgba(24,20,15,.12); }
.gallery-grid img:first-child { grid-row: span 2; }
.about { background: linear-gradient(135deg, var(--ink), #332719); color: var(--white); }
.about-grid { display: grid; grid-template-columns: 1.05fr .75fr; gap: 24px; align-items: stretch; }
.about-panel, .quote-card { border: 1px solid rgba(255,255,255,.14); border-radius: 32px; padding: 40px; background: rgba(255,255,255,.06); }
.about p { color: rgba(255,255,255,.74); }
.quote-card { display: flex; flex-direction: column; justify-content: space-between; min-height: 340px; background: #e7b66c; color: var(--ink); }
.quote-card span { font-size: 6rem; line-height: .7; font-weight: 950; }
.quote-card p { color: rgba(24,20,15,.76); font-size: 1.35rem; line-height: 1.35; }
.contact-grid { display: grid; grid-template-columns: .85fr 1fr; gap: 36px; align-items: start; }
.contact-copy p:not(.eyebrow) { color: var(--muted); font-size: 1.08rem; }
.contact-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 28px; }
.contact-list a, .contact-list span { display: block; background: var(--white); border: 1px solid var(--line); border-radius: 22px; padding: 18px; box-shadow: 0 12px 35px rgba(24,20,15,.06); }
.contact-list strong { display: block; }
.contact-list span span, .contact-list em { display: block; color: var(--muted); font-style: normal; margin-top: 4px; overflow-wrap: anywhere; }
.contact-box { background: var(--white); border: 1px solid var(--line); border-radius: 32px; padding: 30px; box-shadow: var(--shadow); }
.legal-page { padding-top: 70px; }
.legal-page .narrow { background: var(--white); border: 1px solid var(--line); border-radius: 32px; padding: clamp(24px, 5vw, 52px); box-shadow: 0 20px 60px rgba(24,20,15,.08); }
.legal-page h1 { font-size: clamp(2.4rem, 5vw, 4.4rem); margin-bottom: 30px; }
.legal-page h2 { font-size: 1.4rem; margin-top: 28px; letter-spacing: -.03em; }
.legal-page a { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.result-page ul { padding-left: 22px; }

/* FAQ-Seite: kompakte, suchmaschinenfreundliche Fragen im passenden Maler-Design. */
.faq-page .faq-intro { color: var(--muted); font-size: 1.08rem; max-width: 760px; }
.faq-list { display: grid; gap: 12px; margin-top: 30px; }
.faq-item { border: 1px solid var(--line); border-radius: 22px; background: rgba(255,255,255,.76); box-shadow: 0 14px 36px rgba(24,20,15,.06); overflow: hidden; }
.faq-item summary { cursor: pointer; list-style: none; padding: 18px 22px; font-weight: 850; color: var(--ink); position: relative; padding-right: 52px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); width: 26px; height: 26px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; background: var(--terracotta); color: var(--white); font-weight: 900; }
.faq-item[open] summary::after { content: "−"; }
.faq-item p { margin: 0; padding: 0 22px 20px; color: var(--muted); line-height: 1.62; }
.faq-contact-box { margin-top: 30px; border-radius: 26px; padding: 26px; background: linear-gradient(135deg, #fff7ed, #efe4d5); border: 1px solid var(--line); }
.faq-contact-box h2 { margin-top: 0; }
.faq-contact-box p:last-child { margin-bottom: 0; }
.site-footer { background: var(--ink); color: var(--white); padding: 54px 0 0; }
.footer-grid { display: grid; grid-template-columns: 1.1fr .9fr .6fr; gap: 30px; }
.footer-logo { width: 96px; background: rgba(255,255,255,.94); border-radius: 18px; padding: 8px; }
.site-footer h2 { font-size: 1rem; letter-spacing: 0; }
.site-footer p, .site-footer a { color: rgba(255,255,255,.72); }
.footer-social-link { display: inline-flex; align-items: center; gap: 8px; margin-top: 12px; color: rgba(255,255,255,.72); text-decoration: none; font-weight: 600; }
.footer-social-link svg { flex: 0 0 auto; }
.footer-social-link:hover { color: var(--white); text-decoration: underline; text-underline-offset: 3px; }
.footer-credit-ad { display: flex; justify-content: center; padding: 18px min(5vw, 46px) 0; margin-top: 34px; border-top: 1px solid rgba(255,255,255,.12); text-align: center; font-size: .86rem; }
.footer-credit-ad a { display: inline; max-width: 100%; padding: 0; border: 0; border-radius: 0; background: transparent; color: rgba(255,255,255,.62); font-weight: 500; box-shadow: none; text-decoration: none; }
.footer-credit-ad a:hover { color: var(--white); text-decoration: underline; text-underline-offset: 3px; }
.footer-bottom { display: flex; justify-content: center; gap: 18px; padding: 14px min(5vw, 46px) 18px; color: #bbb8b2; font-size: .92rem; text-align: center; }
.to-top { position: fixed; right: 18px; bottom: 18px; z-index: 20; width: 48px; height: 48px; border-radius: 999px; border: 0; background: var(--ink); color: var(--white); box-shadow: 0 12px 35px rgba(24,20,15,.22); opacity: 0; transform: translateY(14px); pointer-events: none; transition: .25s ease; cursor: pointer; }
.to-top.is-visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; transition-delay: var(--delay, 0ms); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@media (max-width: 980px) {
    .topline__inner { justify-content: center; flex-wrap: wrap; gap: 10px 18px; padding: 8px 0; }
    .hero-grid, .intro-grid, .process-grid, .about-grid, .contact-grid { grid-template-columns: 1fr; }
    .hero { min-height: auto; padding-top: 42px; }
    .hero-media img { aspect-ratio: 16 / 12; max-height: none; }
    .intro-grid { gap: 18px; }
    .section-head { display: block; }
    .service-grid { grid-template-columns: repeat(2, 1fr); }
    .process-copy { position: static; }
}

@media (max-width: 760px) {
    .wrap { width: min(100% - 26px, var(--max)); }
    .topline { display: none; }
    .site-header {
        overflow: visible;
        z-index: 2147483600;
        isolation: auto;
    }
    .nav-shell { min-height: 74px; position: relative; z-index: 2147483602; }
    .brand img { width: 58px; }
    .brand small { display: none; }
    .nav-toggle { display: inline-flex; position: relative; z-index: 2147483647; }

    /* Mobiles Menü: als feste Vordergrund-Ebene, ohne den Seiteninhalt zu überdecken.
       Dadurch bleibt die Referenzgalerie sichtbar, sobald das Menü geschlossen ist. */
    body.nav-open { overflow-x: hidden; }
    body.nav-open::before {
        content: "";
        position: fixed;
        inset: 74px 0 0;
        z-index: 2147483500;
        background: rgba(24,20,15,.34);
        pointer-events: none;
    }
    body.nav-open .site-header {
        z-index: 2147483600;
        background: rgba(251,247,240,.98);
        backdrop-filter: blur(18px);
        box-shadow: 0 18px 55px rgba(24,20,15,.18);
        border-bottom-color: rgba(24,20,15,.10);
    }
    .main-nav {
        position: fixed !important;
        left: 13px;
        right: 13px;
        top: 88px;
        z-index: 2147483646;
        display: grid;
        gap: 8px;
        max-height: calc(100dvh - 106px);
        overflow-y: auto;
        overscroll-behavior: contain;
        padding: 16px;
        border: 1px solid rgba(255,255,255,.13);
        border-radius: 24px;
        background: #18140f;
        color: var(--white);
        box-shadow: 0 24px 80px rgba(24,20,15,.55);
        transform: translateY(-10px);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
    }
    .main-nav.is-open, .nav-toggle[aria-expanded="true"] + .main-nav, body.nav-open .main-nav {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }
    .main-nav a { color: var(--white); padding: 14px 15px; border-radius: 16px; background: rgba(255,255,255,.05); }
    .main-nav a:hover, .main-nav a:focus { background: rgba(255,255,255,.12); }
    .main-nav .nav-cta { background: var(--gold); color: var(--ink); justify-content: center; text-align: center; }
    .section { padding: 70px 0; }
    .hero { padding: 30px 0 54px; }
    /* Mobil wird das Vaupel-Logo-Bild zuerst gezeigt, damit der erste Eindruck direkt über die Marke läuft. */
    .hero-media { order: -1; }
    .hero-copy { order: 1; }
    h1 { font-size: clamp(1.8rem, 9.2vw, 2.84rem); }
    .lead { font-size: 1.04rem; }
    .hero-actions .btn { width: 100%; }
    .hero-facts { grid-template-columns: 1fr; }
    .hero-media img { aspect-ratio: 1 / 1.12; border-radius: 28px; }
    .glass-card { left: 14px; right: 14px; bottom: 14px; max-width: none; }
    .service-grid { grid-template-columns: 1fr; }
    .service-card { min-height: 360px; }
    .service-card.is-open { min-height: 500px; }
    .gallery-grid { grid-template-columns: 1fr; grid-auto-rows: 220px; }
    .gallery-grid img:first-child { grid-row: auto; }
    .about-panel, .quote-card, .contact-box { padding: 24px; border-radius: 26px; }
    .contact-list { grid-template-columns: 1fr; }
    .footer-grid { display: block; }
    .footer-grid > div + div { margin-top: 24px; }
    .footer-credit-ad { margin-top: 28px; padding-inline: 13px; font-size: .82rem; }
    .footer-credit-ad a { width: auto; border-radius: 0; padding: 0; }
    .footer-bottom { display: block; }
    .footer-bottom span { display: block; margin-top: 8px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
    .reveal { opacity: 1; transform: none; }
}

.contact-box { overflow: hidden; }
.contact-box__logo { max-width: 220px; width: 72%; height: auto; margin: 0 auto 18px; filter: drop-shadow(0 12px 22px rgba(24,20,15,.12)); }
.contact-box h3 { margin-bottom: 16px; }
.contact-box p { color: var(--muted); margin-top: 0; }
.contact-box__actions { display: grid; gap: 12px; margin: 18px 0; }
.contact-box__actions .btn { width: 100%; }
.contact-box address { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-style: normal; overflow-wrap: anywhere; }
.contact-box address a { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }

.legal-note { color: var(--muted); font-size: .92rem; margin-top: 22px; }

/* Produktiver Kontaktbereich ohne Formular */
.contact { background: linear-gradient(135deg, #fbf7f0 0%, #efe1cf 100%); }
.contact-panel { display: grid; gap: 28px; }
.contact-intro { max-width: 850px; }
.contact-intro p:not(.eyebrow) { color: var(--muted); font-size: 1.1rem; margin-top: 20px; }
.contact-cards { display: grid; grid-template-columns: 1.1fr .9fr; gap: 18px; align-items: stretch; }
.contact-primary,
.contact-secondary,
.request-helper { border: 1px solid var(--line); border-radius: 32px; background: rgba(255,255,255,.82); box-shadow: 0 22px 60px rgba(24,20,15,.1); }
.contact-primary { padding: clamp(26px, 4vw, 42px); min-height: 360px; display: flex; flex-direction: column; justify-content: center; }
.contact-secondary { padding: clamp(24px, 3.2vw, 34px); display: flex; flex-direction: column; justify-content: space-between; }
.contact-badge { display: inline-flex; width: fit-content; align-items: center; border-radius: 999px; padding: 8px 13px; margin-bottom: 20px; background: rgba(196,138,56,.16); color: var(--terracotta); font-weight: 900; font-size: .82rem; letter-spacing: .08em; text-transform: uppercase; }
.contact-primary h3,
.contact-secondary h3,
.request-helper h3 { font-size: clamp(1.5rem, 2.6vw, 2.2rem); }
.contact-primary p { color: var(--muted); font-size: 1.08rem; max-width: 620px; margin: 18px 0 0; }
.contact-action-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.contact-logo { width: 150px; max-width: 56%; height: auto; margin-bottom: 20px; filter: drop-shadow(0 12px 24px rgba(24,20,15,.12)); }
.contact-secondary address { margin: 16px 0 22px; color: var(--muted); font-style: normal; font-size: 1.05rem; }
.opening-hours { margin: 0 0 22px; border: 1px solid rgba(24,20,15,.09); border-radius: 20px; background: rgba(255,255,255,.66); padding: 16px 17px; }
.opening-hours h4 { margin: 0 0 10px; font-size: .98rem; letter-spacing: .02em; }
.opening-hours ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; color: var(--muted); font-size: .94rem; line-height: 1.45; }
.contact-link-list { display: grid; gap: 10px; }
.contact-link-list a { display: flex; align-items: center; justify-content: space-between; gap: 18px; border: 1px solid var(--line); border-radius: 18px; background: var(--white); padding: 15px 17px; font-weight: 900; }
.contact-link-list a::after { content: "→"; }
.request-helper { padding: clamp(22px, 3vw, 30px); }
.request-helper h3 { font-size: 1.35rem; letter-spacing: -.035em; }
.request-helper ul { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; list-style: none; padding: 0; margin: 18px 0 0; }
.request-helper li { border: 1px solid rgba(24,20,15,.09); border-radius: 20px; background: rgba(255,255,255,.7); padding: 16px; color: var(--muted); }

@media (max-width: 980px) {
    .contact-cards { grid-template-columns: 1fr; }
    .request-helper ul { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
    .contact-primary,
    .contact-secondary,
    .request-helper { border-radius: 26px; }
    .contact-action-row .btn { width: 100%; }
    .request-helper ul { grid-template-columns: 1fr; }
}

/* Erweiterte Leistungsübersicht */
.service-grid--large { grid-template-columns: repeat(4, 1fr); }
.service-grid--large .service-card { min-height: 390px; }
.service-grid--large .service-card__content { padding: 23px; }
.service-grid--large .service-card h3 { font-size: 1.22rem; }
.service-grid--large .service-card > .service-card__content > p { font-size: .95rem; }


@media (max-width: 1180px) {
    .service-grid--large { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 980px) {
    .service-grid--large { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
    .service-grid--large { grid-template-columns: 1fr; }
}

/* Referenzgalerie mit vollständiger Bildansicht und Desktop-Klick-Vergrößerung */
.gallery-grid--references {
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 260px;
}
.gallery-grid--references img {
    object-fit: contain;
    background: #fffaf2;
    padding: 8px;
    cursor: zoom-in;
    transition: transform .2s ease, box-shadow .2s ease;
}
.gallery-grid--references img:hover,
.gallery-grid--references img:focus {
    transform: translateY(-3px);
    box-shadow: 0 24px 65px rgba(24,20,15,.18);
    outline: 3px solid rgba(183,104,49,.25);
    outline-offset: 3px;
}
.gallery-grid--references img:first-child {
    grid-row: span 2;
    grid-column: span 2;
}
.gallery-grid--references img:nth-child(8),
.gallery-grid--references img:nth-child(12) {
    grid-column: span 2;
}

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: clamp(18px, 4vw, 48px);
    background: rgba(24,20,15,.88);
}
.lightbox.is-open { display: flex; }
.lightbox__image {
    max-width: min(1180px, 94vw);
    max-height: 86vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 22px;
    background: #fffaf2;
    box-shadow: 0 30px 90px rgba(0,0,0,.42);
}
.lightbox__close {
    position: fixed;
    top: 18px;
    right: 18px;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    background: rgba(255,255,255,.94);
    color: var(--ink);
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 12px 35px rgba(0,0,0,.24);
}
.lightbox__close:focus {
    outline: 3px solid rgba(231,182,108,.72);
    outline-offset: 3px;
}

@media (max-width: 1180px) {
    .gallery-grid--references { grid-template-columns: repeat(3, 1fr); }
    .gallery-grid--references img:first-child { grid-column: span 2; }
}

@media (max-width: 760px) {
    /* Mobil bleiben die Referenzbilder sichtbar, aber ohne Vergrößerung/Lightbox. */
    .gallery-grid--references {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) !important;
        grid-auto-rows: auto !important;
        gap: 14px;
        width: 100%;
        max-width: 100%;
        overflow: hidden;
    }
    .gallery-grid--references img {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        max-height: none !important;
        aspect-ratio: auto !important;
        object-fit: contain !important;
        visibility: visible !important;
        opacity: 1 !important;
        transform: none !important;
        cursor: default;
        padding: 6px;
    }
    .gallery-grid--references img:hover,
    .gallery-grid--references img:focus {
        transform: none !important;
        box-shadow: 0 20px 55px rgba(24,20,15,.12);
        outline: 0;
    }
    .gallery-grid--references img:first-child,
    .gallery-grid--references img:nth-child(8),
    .gallery-grid--references img:nth-child(12) {
        grid-row: auto !important;
        grid-column: auto !important;
    }
    .lightbox { display: none !important; }
    /* Referenzen mobil immer sichtbar halten. Das mobile Menü darf diese Galerie nicht ausblenden. */
    body:not(.nav-open) .gallery-grid--references {
        display: grid !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    body:not(.nav-open) .gallery-grid--references img {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

}


/* Dekorative Inaktivitäts-Animation: Nach längerer Ruhe streicht ein Pinsel über die sichtbare Seite. */
.idle-painter {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: none;
    pointer-events: none;
    overflow: hidden;
}
.idle-painter.is-active { display: block; }
.idle-painter__brush {
    position: absolute;
    left: -90px;
    top: 28vh;
    width: 74px;
    height: 74px;
    filter: drop-shadow(0 16px 24px rgba(24,20,15,.28));
    transform-origin: 28% 28%;
    animation: idleBrushSweep 11.5s cubic-bezier(.45,.04,.22,.98) forwards;
}
.idle-painter__strokes span {
    position: absolute;
    left: -18vw;
    top: calc(24vh + (var(--stroke-index) * 9vh));
    width: 0;
    height: clamp(16px, 3vw, 34px);
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(231,182,108,.10), rgba(231,182,108,.34), rgba(183,93,50,.24), rgba(231,182,108,.07));
    box-shadow: 0 10px 24px rgba(183,93,50,.08);
    opacity: 0;
    transform: rotate(calc(-3deg + (var(--stroke-index) * 1.4deg)));
    animation: idlePaintStroke 8.2s ease-out forwards;
    animation-delay: calc(.32s + (var(--stroke-index) * .74s));
}

@keyframes idleBrushSweep {
    0% { transform: translate(-8vw, 0) rotate(-28deg); opacity: 0; }
    7% { opacity: 1; }
    20% { transform: translate(22vw, 8vh) rotate(-18deg); }
    39% { transform: translate(52vw, 1vh) rotate(-23deg); }
    58% { transform: translate(82vw, 18vh) rotate(-16deg); }
    77% { transform: translate(112vw, 10vh) rotate(-24deg); opacity: 1; }
    100% { transform: translate(128vw, 16vh) rotate(-24deg); opacity: 0; }
}

@keyframes idlePaintStroke {
    0% { width: 0; opacity: 0; }
    12% { opacity: .82; }
    72% { width: 134vw; opacity: .48; }
    100% { width: 134vw; opacity: 0; }
}

@media (max-width: 760px) {
    .idle-painter__brush { width: 58px; height: 58px; top: 30vh; }
    .idle-painter__strokes span { left: 0; max-width: 100vw; height: 18px; }
}

@media (prefers-reduced-motion: reduce) {
    .idle-painter { display: none !important; }
}


/* SEO-Leistungsseiten: Layout für regionale Detailseiten, erstellt durch CEIS-IT.de */
.service-card h3 a {
    color: inherit;
    text-decoration: none;
}

.service-card h3 a:hover,
.service-card h3 a:focus-visible,
.service-card__link:hover,
.service-card__link:focus-visible {
    text-decoration: underline;
}

.service-card__link {
    display: inline-flex;
    margin-top: .45rem;
    color: #fff;
    font-weight: 700;
    text-decoration: none;
}

.service-hero-detail {
    padding-top: clamp(4rem, 8vw, 7rem);
    background: radial-gradient(circle at 20% 20%, rgba(207, 146, 58, .22), transparent 34%), #f4efe5;
}

.service-hero-detail__grid,
.service-content-detail__grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(280px, .75fr);
    gap: clamp(1.5rem, 4vw, 4rem);
    align-items: center;
}

.service-hero-detail__copy .lead {
    max-width: 760px;
}

.service-hero-detail__image {
    margin: 0;
    border-radius: 2rem;
    overflow: hidden;
    box-shadow: 0 24px 70px rgba(24, 20, 15, .18);
}

.service-hero-detail__image img {
    width: 100%;
    height: 100%;
    min-height: 320px;
    object-fit: cover;
    display: block;
}

.service-text-block,
.service-benefit-box,
.service-region-detail__panel {
    border-radius: 1.7rem;
    background: rgba(255,255,255,.78);
    box-shadow: 0 18px 50px rgba(24,20,15,.1);
    padding: clamp(1.3rem, 3vw, 2.4rem);
}

.service-text-block h2,
.service-benefit-box h2,
.service-region-detail__panel h2 {
    margin-top: 0;
}

.service-text-block p {
    color: #40382d;
    line-height: 1.75;
}

.service-benefit-box ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: .8rem;
}

.service-benefit-box li {
    position: relative;
    padding-left: 1.6rem;
    color: #2c261f;
    font-weight: 700;
}

.service-benefit-box li::before {
    content: "";
    position: absolute;
    left: 0;
    top: .55rem;
    width: .55rem;
    height: .55rem;
    border-radius: 999px;
    background: currentColor;
}

.service-region-detail__panel {
    text-align: center;
    max-width: 920px;
    margin: 0 auto;
}

.service-region-detail__panel p {
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 860px) {
    .service-hero-detail__grid,
    .service-content-detail__grid {
        grid-template-columns: 1fr;
    }

    .service-hero-detail {
        padding-top: 3rem;
    }
}

/* Layout-Korrektur für SEO-Leistungsseiten:
   Überschriften in Karten dürfen nicht die globale H2-Größe der Startseite übernehmen. */
.service-text-block h2,
.service-benefit-box h2,
.service-region-detail__panel h2 {
    font-size: clamp(1.45rem, 2.4vw, 2.15rem);
    line-height: 1.14;
    letter-spacing: -.035em;
    max-width: 100%;
    overflow-wrap: anywhere;
}

.service-benefit-box {
    align-self: start;
}

.service-benefit-box li {
    font-size: clamp(.94rem, 1vw, 1.02rem);
    line-height: 1.45;
}

.service-hero-detail__copy h1 {
    overflow-wrap: anywhere;
}

@media (max-width: 620px) {
    .service-text-block,
    .service-benefit-box,
    .service-region-detail__panel {
        padding: 1.25rem;
        border-radius: 1.25rem;
    }

    .service-text-block h2,
    .service-benefit-box h2,
    .service-region-detail__panel h2 {
        font-size: clamp(1.35rem, 8vw, 1.85rem);
    }
}


/* 404-Seite: malerfreundliche Besucherführung mit dezenter CEIS-IT.de-Eigenwerbung */
.not-found-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(54px, 8vw, 100px) 0;
    background: radial-gradient(circle at 15% 18%, rgba(196,138,56,.22), transparent 28%), linear-gradient(135deg, #fbf7f0 0%, #efe1cf 100%);
}
.not-found-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, .75fr);
    gap: clamp(24px, 5vw, 58px);
    align-items: center;
}
.not-found-copy h1 {
    max-width: 760px;
}
.not-found-copy p:not(.eyebrow) {
    max-width: 680px;
    margin: 22px 0 0;
    color: var(--muted);
    font-size: clamp(1.02rem, 1.5vw, 1.18rem);
}
.not-found-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(24,20,15,.1);
    border-radius: 34px;
    padding: clamp(26px, 4vw, 38px);
    background: rgba(255,255,255,.8);
    box-shadow: var(--shadow);
}
.not-found-card::before {
    content: "";
    position: absolute;
    right: -44px;
    top: -40px;
    width: 170px;
    height: 170px;
    border-radius: 44% 56% 61% 39% / 42% 35% 65% 58%;
    background: rgba(196,138,56,.22);
}
.not-found-card__badge {
    display: inline-flex;
    width: fit-content;
    margin-bottom: 18px;
    border-radius: 999px;
    padding: 8px 13px;
    background: rgba(63,90,69,.12);
    color: var(--green);
    font-size: .8rem;
    font-weight: 950;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.not-found-card h2 {
    position: relative;
    font-size: clamp(1.58rem, 2.9vw, 2.45rem);
    letter-spacing: -.045em;
}
.not-found-card p {
    position: relative;
    color: var(--muted);
    margin: 18px 0 0;
}
.not-found-card__link {
    position: relative;
    display: inline-flex;
    margin-top: 22px;
    font-weight: 900;
    color: var(--terracotta);
    text-decoration: underline;
    text-underline-offset: 4px;
}
.not-found-links {
    padding-top: 74px;
}
.not-found-links h2 {
    font-size: clamp(1.8rem, 3vw, 3rem);
}
.not-found-link-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 28px;
}
.not-found-link-grid a {
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(255,255,255,.78);
    padding: 18px 20px;
    font-weight: 900;
    box-shadow: 0 18px 50px rgba(24,20,15,.08);
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.not-found-link-grid a:hover,
.not-found-link-grid a:focus-visible {
    transform: translateY(-2px);
    background: var(--white);
    box-shadow: 0 24px 60px rgba(24,20,15,.12);
    outline: none;
}

@media (max-width: 900px) {
    .not-found-grid { grid-template-columns: 1fr; }
    .not-found-card { max-width: 620px; }
    .not-found-link-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
    .not-found-hero { padding: 38px 0 62px; }
    .not-found-card { border-radius: 28px; }
    .not-found-link-grid { grid-template-columns: 1fr; }
}


/* Firefox Mobile: Zusätzlicher Schutz gegen seitliches Scrollen durch dekorative Elemente und Animationen. */
@media (max-width: 760px) {
    html, body {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden !important;
    }
    body {
        position: relative;
        min-width: 0;
        overscroll-behavior-x: none;
    }
    body > * {
        max-width: 100%;
    }
    .site-header, main, .site-footer, .section, .hero, .intro, .services, .process, .gallery, .about, .contact {
        max-width: 100%;
        overflow-x: hidden;
    }
    .wrap, .hero-grid, .intro-grid, .service-grid, .process-grid, .gallery-grid, .about-grid, .contact-grid, .contact-panel, .contact-cards {
        min-width: 0;
        max-width: 100%;
    }
    .paint-orb {
        display: none;
    }
    h1, h2, h3, p, li, a, span, strong, small {
        overflow-wrap: anywhere;
    }
    .idle-painter {
        width: 100%;
        max-width: 100%;
        overflow: hidden;
        contain: paint;
    }
    .idle-painter__brush {
        animation-name: idleBrushSweepMobile;
    }
    .idle-painter__strokes span {
        left: 0;
        max-width: 100%;
        animation-name: idlePaintStrokeMobile;
    }
    @keyframes idleBrushSweepMobile {
        0% { transform: translate(-90px, 0) rotate(-28deg); opacity: 0; }
        7% { opacity: 1; }
        25% { transform: translate(18vw, 8vh) rotate(-18deg); }
        50% { transform: translate(48vw, 1vh) rotate(-23deg); }
        75% { transform: translate(78vw, 12vh) rotate(-18deg); opacity: 1; }
        100% { transform: translate(calc(100vw + 20px), 16vh) rotate(-24deg); opacity: 0; }
    }
    @keyframes idlePaintStrokeMobile {
        0% { width: 0; opacity: 0; }
        12% { opacity: .82; }
        72% { width: 100%; opacity: .48; }
        100% { width: 100%; opacity: 0; }
    }
}

/* Finaler Mobile-Menü-Fix: Wenn JavaScript das Menü in den Body verschiebt, bleibt es garantiert vor allen Inhaltsbereichen. */
@media (max-width: 760px) {
    body > .main-nav {
        position: fixed !important;
        left: 13px !important;
        right: 13px !important;
        top: 88px !important;
        z-index: 2147483647 !important;
        max-width: calc(100vw - 26px) !important;
        max-height: calc(100dvh - 106px) !important;
    }
    body > .main-nav.is-open {
        display: grid !important;
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
        transform: translateY(0) !important;
    }
    body.nav-open .section,
    body.nav-open main,
    body.nav-open .site-footer {
        position: relative;
        z-index: 1;
    }
}
