/* =========================================================
   Sachverständigenbüro Fibiger – Stylesheet
   Mobile-first, ohne externe Abhängigkeiten.
   ========================================================= */

:root {
    --navy: #0b2440;
    --navy-dark: #071a30;
    --navy-light: #1c3f68;
    --gold: #b89750;
    --gold-dark: #8a6f33;
    --gold-light: #e2cc96;
    --text: #1f2937;
    --muted: #5b6472;
    --line: #dde3ea;
    --bg: #ffffff;
    --bg-alt: #f3f6fa;
    --error: #b42318;
    --error-bg: #fef3f2;
    --success: #067647;
    --success-bg: #ecfdf3;
    --info-bg: #eef4fb;
    --radius: 14px;
    --shadow: 0 10px 30px rgba(21, 43, 71, 0.08);
    --max: 72rem;
    --narrow: 46rem;
    --gutter: 1rem;
    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --header-h: 5rem;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-family: var(--font);
    font-size: 100%;
    line-height: 1.65;
    color: var(--text);
    background: var(--bg);
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 1rem);
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

img,
svg {
    max-width: 100%;
    height: auto;
}

h1,
h2,
h3 {
    line-height: 1.2;
    margin: 0 0 0.75rem;
    color: var(--navy);
    letter-spacing: -0.01em;
}

h1 {
    font-size: clamp(2rem, 1.2rem + 3.2vw, 3.25rem);
}

h2 {
    font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.25rem);
}

h3 {
    font-size: 1.2rem;
}

p {
    margin: 0 0 1rem;
}

a {
    color: var(--navy);
}

a:hover {
    color: var(--navy-light);
}

:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 2px;
}

.container {
    width: 100%;
    max-width: var(--max);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.container--narrow {
    max-width: var(--narrow);
}

.skip-link {
    position: absolute;
    left: 1rem;
    top: -4rem;
    background: var(--gold);
    color: var(--navy-dark);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    z-index: 100;
    font-weight: 600;
}

.skip-link:focus {
    top: 1rem;
}

.icon {
    width: 1.5rem;
    height: 1.5rem;
    flex: none;
}

/* ---------- Buttons ---------- */

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.4rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.2;
    text-decoration: none;
    border: 2px solid transparent;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.button--primary {
    background: var(--gold);
    border-color: var(--gold);
    color: var(--navy-dark);
}

.button--primary:hover {
    background: var(--gold-dark);
    border-color: var(--gold-dark);
    color: #fff;
}

.button--ghost {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.6);
    color: #fff;
}

.button--ghost:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: #fff;
    color: #fff;
}

.button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

/* ---------- Header ---------- */

.site-header {
    background: #fff;
    border-bottom: 1px solid var(--line);
}

.site-header__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 1.5rem;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

.brand {
    display: inline-flex;
    align-items: center;
}

.brand img {
    display: block;
    height: 2.75rem;
    width: auto;
}

.site-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 1.1rem;
    font-size: 0.95rem;
}

.site-nav a {
    color: var(--navy);
    text-decoration: none;
    font-weight: 500;
    padding: 0.25rem 0;
    border-bottom: 2px solid transparent;
}

.site-nav a:hover {
    color: var(--navy-light);
    border-bottom-color: var(--gold);
}

.site-nav__cta {
    color: var(--navy-dark) !important;
    background: var(--gold);
    padding: 0.5rem 0.95rem !important;
    border-radius: 6px;
    border-bottom: 0 !important;
    font-weight: 600 !important;
}

.site-nav__cta:hover {
    background: var(--gold-light);
}

/* ---------- Hero ---------- */

.hero {
    background:
        radial-gradient(60rem 30rem at 85% -10%, rgba(255, 255, 255, 0.10), transparent 60%),
        radial-gradient(40rem 25rem at -10% 110%, rgba(184, 151, 80, 0.28), transparent 60%),
        linear-gradient(160deg, var(--navy-dark), var(--navy) 55%, var(--navy-light));
    color: #fff;
    padding: clamp(3rem, 8vw, 6rem) 0 clamp(5rem, 10vw, 7.5rem);
}

.hero__inner {
    display: grid;
    gap: 2.5rem;
    align-items: center;
}

.hero h1 {
    color: #fff;
    margin-bottom: 1.25rem;
}

.hero .lead {
    font-size: 1.15rem;
    color: rgba(255, 255, 255, 0.92);
}

.hero p {
    color: rgba(255, 255, 255, 0.82);
    max-width: 38rem;
}

.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.75rem;
}

.hero__visual {
    display: none;
}

.eyebrow {
    display: inline-block;
    margin: 0 0 0.75rem;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--gold-dark);
}

.eyebrow--light {
    color: var(--gold-light);
}

/* ---------- Fakten-Leiste ---------- */

.facts {
    margin-top: -3.5rem;
    position: relative;
    z-index: 1;
}

.facts__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.fact {
    background: #fff;
    padding: 1.4rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.fact__value {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--navy);
    line-height: 1.1;
}

.fact__label {
    color: var(--muted);
    font-size: 0.95rem;
}

/* ---------- Abschnitte ---------- */

.section {
    padding: clamp(3.5rem, 8vw, 6rem) 0;
}

.section--alt {
    background: var(--bg-alt);
}

.section__head {
    max-width: 42rem;
    margin-bottom: 2.5rem;
}

.section__head h2 {
    margin-bottom: 0.5rem;
}

.section__intro {
    color: var(--muted);
    font-size: 1.05rem;
    margin-top: 0.75rem;
}

/* ---------- Leistungen ---------- */

.card-grid {
    display: grid;
    gap: 1.25rem;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr));
}

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.75rem 1.5rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
    border-color: transparent;
}

.card__icon {
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: rgba(184, 151, 80, 0.16);
    color: var(--gold-dark);
    margin-bottom: 1.1rem;
}

.card__icon .icon {
    width: 1.75rem;
    height: 1.75rem;
}

.card p {
    color: var(--muted);
    margin: 0;
}

/* ---------- Über mich ---------- */

.about {
    display: grid;
    gap: 2.5rem;
    align-items: start;
}

.about__card {
    background: var(--navy);
    color: #fff;
    border-radius: var(--radius);
    padding: 2rem 1.75rem;
    box-shadow: var(--shadow);
}

.about__name {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0;
}

.about__role {
    color: var(--gold-light);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.about__claim {
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 0.75rem;
}

.check-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.6rem;
}

.check-list li {
    display: flex;
    gap: 0.6rem;
    align-items: flex-start;
}

.check-list .icon {
    color: var(--gold-light);
    margin-top: 0.15rem;
}

/* ---------- Ablauf ---------- */

.steps {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 1.5rem;
    counter-reset: step;
}

.step {
    position: relative;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.75rem 1.5rem 1.5rem;
}

.step__number {
    display: inline-grid;
    place-items: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background: var(--navy);
    color: #fff;
    font-weight: 700;
    margin-bottom: 1rem;
}

.step h3 {
    font-size: 1.1rem;
}

.step p {
    color: var(--muted);
    margin: 0;
}

/* ---------- Kontakt ---------- */

.contact {
    display: grid;
    gap: 2rem;
    align-items: start;
}

.contact__card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.75rem 1.5rem;
}

.contact__logo {
    display: block;
    width: 100%;
    max-width: 22rem;
    height: auto;
    margin-bottom: 1.25rem;
}

.contact__name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--navy);
    margin: 0;
}

.contact__role {
    color: var(--muted);
    font-size: 0.95rem;
    margin-bottom: 1.25rem;
}

.contact__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.9rem;
}

.contact__list li {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
}

.contact__list .icon {
    color: var(--gold-dark);
    margin-top: 0.15rem;
}

.contact__list address {
    font-style: normal;
}

.contact__form {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.75rem 1.5rem;
}

.contact__form-title {
    margin-bottom: 1.25rem;
}

/* ---------- Formular ---------- */

.form__row {
    display: grid;
    gap: 1rem;
}

.field {
    margin-bottom: 1.1rem;
}

.field label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.35rem;
    font-size: 0.95rem;
}

.field__required {
    color: var(--gold-dark);
}

.field__optional {
    color: var(--muted);
    font-weight: 400;
}

.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field select,
.field textarea {
    width: 100%;
    font: inherit;
    color: var(--text);
    background: #fff;
    border: 1px solid #c3ccd6;
    border-radius: 8px;
    padding: 0.7rem 0.85rem;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field textarea {
    resize: vertical;
    min-height: 8rem;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.18);
}

.field [aria-invalid="true"] {
    border-color: var(--error);
}

.field__error {
    color: var(--error);
    font-size: 0.9rem;
    margin: 0.35rem 0 0;
}

.field--checkbox {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.25rem 0.6rem;
    align-items: start;
}

.field--checkbox input {
    width: 1.15rem;
    height: 1.15rem;
    margin: 0.2rem 0 0;
    accent-color: var(--navy);
}

.field--checkbox label {
    font-weight: 400;
    margin: 0;
}

.field--checkbox .field__error {
    grid-column: 1 / -1;
}

.form__hp {
    position: absolute;
    left: -10000px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.form__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    margin-top: 0.5rem;
}

.form__required-hint {
    margin: 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.form__note {
    margin: 1.25rem 0 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.alert {
    border-radius: 10px;
    padding: 0.9rem 1.1rem;
    margin-bottom: 1.25rem;
    border: 1px solid transparent;
}

.alert--success {
    background: var(--success-bg);
    border-color: #abefc6;
    color: var(--success);
}

.alert--error {
    background: var(--error-bg);
    border-color: #fecdca;
    color: var(--error);
}

.alert--info {
    background: var(--info-bg);
    border-color: #c9d9ee;
    color: var(--navy);
}

/* ---------- FAQ ---------- */

.faq {
    display: grid;
    gap: 0.75rem;
}

.faq__item {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 0 1.25rem;
}

.faq__item summary {
    cursor: pointer;
    list-style: none;
    padding: 1rem 2rem 1rem 0;
    font-weight: 600;
    color: var(--navy);
    position: relative;
}

.faq__item summary::-webkit-details-marker {
    display: none;
}

.faq__item summary::after {
    content: "+";
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    line-height: 1;
    color: var(--gold);
    transition: transform 0.2s ease;
}

.faq__item[open] summary::after {
    transform: translateY(-50%) rotate(45deg);
}

.faq__answer {
    padding-bottom: 1rem;
    color: var(--muted);
}

.faq__answer p {
    margin: 0;
}

/* ---------- Fließtext (Impressum, Datenschutz) ---------- */

.prose h1 {
    margin-bottom: 1.25rem;
}

.prose h2 {
    font-size: 1.3rem;
    margin-top: 2rem;
}

.prose p {
    color: var(--text);
}

/* ---------- Footer ---------- */

.site-footer {
    background: var(--navy-dark);
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.925rem;
    padding: 2.5rem 0 2rem;
}

.site-footer__inner {
    display: grid;
    gap: 1.5rem;
}

.site-footer__brand {
    color: #fff;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.site-footer__tagline {
    margin: 0;
    color: var(--gold-light);
}

.site-footer__nav {
    display: flex;
    gap: 1.25rem;
}

.site-footer a {
    color: rgba(255, 255, 255, 0.85);
}

.site-footer a:hover {
    color: #fff;
}

.site-footer__copy {
    margin: 0;
    color: rgba(255, 255, 255, 0.6);
}

/* ---------- Breakpoints ---------- */

@media (min-width: 40em) {
    .form__row {
        grid-template-columns: 1fr 1fr;
    }

    .steps {
        grid-template-columns: 1fr 1fr;
    }
}

@media (min-width: 48em) {
    :root {
        --gutter: 1.5rem;
    }

    .site-header {
        position: sticky;
        top: 0;
        z-index: 50;
    }

    .brand img {
        height: 3.25rem;
    }

    .facts__list {
        grid-template-columns: repeat(3, 1fr);
    }

    .site-footer__inner {
        grid-template-columns: 1fr auto;
        align-items: center;
    }

    .site-footer__copy {
        grid-column: 1 / -1;
        border-top: 1px solid rgba(255, 255, 255, 0.12);
        padding-top: 1rem;
    }
}

@media (min-width: 60em) {
    .hero__inner {
        grid-template-columns: 1.15fr 0.85fr;
        gap: 3rem;
    }

    .hero__visual {
        display: block;
    }

    .about {
        grid-template-columns: 1.2fr 0.8fr;
        gap: 3.5rem;
    }

    .steps {
        grid-template-columns: repeat(4, 1fr);
    }

    .step:not(:last-child)::after {
        content: "";
        position: absolute;
        top: 3rem;
        right: -1.5rem;
        width: 1.5rem;
        border-top: 2px dashed var(--line);
    }

    .contact {
        grid-template-columns: 0.8fr 1.2fr;
        gap: 2.5rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition: none !important;
    }
}

/* ---------- ALTCHA-Widget (Spamschutz) ---------- */

altcha-widget {
    display: block;
    max-width: 22rem;
    --altcha-border-width: 1px;
    --altcha-border-color: #c3ccd6;
    --altcha-border-radius: 8px;
    --altcha-color-base: #ffffff;
    --altcha-color-base-content: var(--text);
    --altcha-color-primary: var(--navy);
    --altcha-color-primary-content: #ffffff;
    --altcha-color-error: var(--error);
    --altcha-checkbox-border-color: #c3ccd6;
    --altcha-max-width: 100%;
}

/* ---------- Baustellenseite ---------- */

.construction {
    flex: 1;
    display: flex;
    align-items: center;
    background:
        radial-gradient(60rem 30rem at 85% -10%, rgba(255, 255, 255, 0.10), transparent 60%),
        radial-gradient(40rem 25rem at -10% 110%, rgba(184, 151, 80, 0.28), transparent 60%),
        linear-gradient(160deg, var(--navy-dark), var(--navy) 55%, var(--navy-light));
    padding: clamp(2.5rem, 8vw, 6rem) 0;
}

.construction__card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: clamp(1.75rem, 5vw, 3.5rem);
    max-width: 44rem;
    margin: 0 auto;
}

.construction__logo {
    display: block;
    width: 100%;
    max-width: 24rem;
    height: auto;
    margin: 0 0 2rem;
}

.construction h1 {
    margin-bottom: 1rem;
}

.construction .lead {
    font-size: 1.15rem;
    color: var(--muted);
}

.construction__contact {
    margin-top: 1.75rem;
    padding-top: 1.75rem;
    border-top: 1px solid var(--line);
}
