/* ==========================================================================
   NetzwerkDesign G. Pemsel GbR – Designsystem
   Aufbau an aurelis.de orientiert: großzügiger Weißraum, klare Hierarchie,
   zurückhaltende Farbigkeit, Inhalt in ruhigen Bändern.
   Keine externen Ressourcen (Fonts, CDN) – DSGVO-konform und schnell.
   ========================================================================== */

:root {
    /* Markenfarben, aus der bisherigen Seite übernommen und ausgebaut */
    --ink:            #16182b;   /* Grundfarbe Text / dunkle Bänder */
    --ink-soft:       #2b2d42;   /* Bestandsfarbe, für Flächen */
    --accent:         #023e8a;   /* Bestandsblau, Primäraktion */
    --accent-bright:  #0a6ed1;   /* Hover, Akzentlinien */
    --accent-pale:    #e6f1ff;   /* Bestandston, zarte Flächen */

    --paper:          #ffffff;
    --paper-warm:     #f7f8fa;
    --line:           #e3e6ec;   /* nur dekorative Trennlinien */
    --line-ui:        #7f8899;   /* Rahmen von Bedienelementen: 3,57:1 auf Weiß */
    --muted:          #5c6270;
    /* Heller Rand auf dunklem Grund – 60 % ergeben 5,6:1, 35 % waren zu wenig */
    --line-on-dark:   rgba(255, 255, 255, .6);

    /* Typografie – Systemschriften, keine Ladezeit, überall verfügbar */
    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
            "Helvetica Neue", Arial, sans-serif;

    /* Vertikaler Rhythmus */
    --band:   clamp(4rem, 9vw, 7.5rem);
    --gutter: clamp(1.25rem, 4vw, 3rem);
    --max:    1240px;

    --radius: 3px;
    --shadow: 0 1px 2px rgba(22, 24, 43, .06), 0 8px 28px rgba(22, 24, 43, .07);
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font);
    font-size: clamp(1rem, .96rem + .2vw, 1.075rem);
    line-height: 1.65;
    color: var(--ink);
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-bright); }

h1, h2, h3, h4 {
    margin: 0 0 .6em;
    line-height: 1.15;
    letter-spacing: -.02em;
    font-weight: 650;
    text-wrap: balance;
}

h1 { font-size: clamp(2.1rem, 1.2rem + 3.6vw, 3.9rem); }
h2 { font-size: clamp(1.65rem, 1.1rem + 2.1vw, 2.6rem); }
h3 { font-size: clamp(1.15rem, 1rem + .7vw, 1.4rem); }

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

:focus-visible {
    outline: 3px solid var(--accent-bright);
    outline-offset: 3px;
}

/* --- Grundraster ---------------------------------------------------------- */

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

.band { padding-block: var(--band); }
.band--tight { padding-block: calc(var(--band) * .62); }
.band--paper { background: var(--paper-warm); }
.band--ink { background: var(--ink); color: #fff; }
.band--ink h2, .band--ink h3 { color: #fff; }

.skip-link {
    position: absolute;
    left: -9999px;
    background: var(--ink);
    color: #fff;
    padding: .75rem 1.25rem;
    z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; color: #fff; }

/* Kleines Label über einer Überschrift – gliedert die Bänder */
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    margin-bottom: 1.1rem;
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--accent);
}
.eyebrow::before {
    content: "";
    width: 2rem;
    height: 2px;
    background: currentColor;
}
.band--ink .eyebrow { color: #7fb4f5; }

.lead {
    font-size: clamp(1.1rem, 1rem + .55vw, 1.35rem);
    line-height: 1.55;
    color: var(--muted);
    max-width: 62ch;
}
.band--ink .lead { color: rgba(255, 255, 255, .8); }

/* --- Schaltflächen -------------------------------------------------------- */

.btn {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    padding: .85rem 1.6rem;
    border: 2px solid transparent;
    border-radius: var(--radius);
    font: inherit;
    font-weight: 650;
    line-height: 1.2;
    cursor: pointer;
    transition: background-color .18s ease, color .18s ease, border-color .18s ease, transform .18s ease;
}
.btn:hover { transform: translateY(-1px); }

.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-bright); color: #fff; }

.btn--ghost { border-color: var(--line-ui); color: var(--ink); background: transparent; }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }

/* Auf allen dunklen Flächen dreht sich die Schaltfläche um: heller Text und
   heller Rand. Gilt bewusst für Band, Hero und Seitenkopf gemeinsam – vorher
   war nur das Band abgedeckt, im Hero stand dunkler Text auf dunklem Grund. */
.band--ink .btn--ghost,
.hero .btn--ghost,
.page-hero .btn--ghost {
    border-color: var(--line-on-dark);
    color: #fff;
    background: transparent;
}
.band--ink .btn--ghost:hover,
.hero .btn--ghost:hover,
.page-hero .btn--ghost:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, .12);
    color: #fff;
}

.btn-row { display: flex; flex-wrap: wrap; gap: .85rem; margin-top: 2rem; }

/* Pfeil-Textlink, wie er in den Kacheln steht */
.arrow-link {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    font-weight: 650;
}
.arrow-link::after {
    content: "→";
    transition: transform .18s ease;
}
.arrow-link:hover::after { transform: translateX(4px); }

/* --- Kopfzeile ------------------------------------------------------------ */

.site-head {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--line);
}

.site-head__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    min-height: 74px;
}

.brand { display: flex; align-items: center; gap: .75rem; color: var(--ink); }
.brand img { width: 38px; height: auto; }
.brand__text { display: flex; flex-direction: column; line-height: 1.1; }
.brand__name { font-weight: 700; font-size: 1.02rem; letter-spacing: -.01em; }
.brand__sub { font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }

.nav { display: flex; align-items: center; gap: .35rem; }
.nav a {
    padding: .55rem .85rem;
    border-radius: var(--radius);
    color: var(--ink);
    font-weight: 550;
    font-size: .96rem;
}
.nav a:hover { background: var(--accent-pale); color: var(--accent); }
.nav a[aria-current="page"] { color: var(--accent); box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
/* ACHTUNG Kaskade: `.nav a` ist spezifischer als `.btn--primary` und würde
   dessen weiße Schrift mit der dunklen Grundfarbe überschreiben – schwarz auf
   Blau. Deshalb hier ausdrücklich mit `a.btn` nachziehen. */
.nav a.btn { margin-left: .5rem; padding: .6rem 1.15rem; }
.nav a.btn--primary,
.nav a.btn--primary:hover,
.nav a.btn--primary:focus { color: #fff; }
.nav a.btn--primary:hover { background: var(--accent-bright); }

.nav-toggle {
    display: none;
    padding: .55rem;
    background: transparent;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    cursor: pointer;
}
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 4px 0; }

@media (max-width: 900px) {
    .nav-toggle { display: block; }
    .nav {
        position: absolute;
        inset: 74px 0 auto;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: .75rem var(--gutter) 1.5rem;
        background: var(--paper);
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow);
    }
    .nav[data-open="true"] { display: flex; }
    .nav a { padding: .85rem .25rem; border-bottom: 1px solid var(--line); border-radius: 0; }
    .nav .btn { margin: 1rem 0 0; justify-content: center; }
}

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

.hero {
    position: relative;
    overflow: hidden;
    background: var(--ink);
    color: #fff;
}
.hero__art {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: .55;
}
.hero__inner {
    position: relative;
    padding-block: clamp(4.5rem, 11vw, 9rem);
    max-width: 46rem;
}
.hero h1 { color: #fff; margin-bottom: .5em; }
.hero .lead { color: rgba(255, 255, 255, .82); }
.hero .eyebrow { color: #7fb4f5; }

/* Kennzahlenleiste unter dem Hero */
.facts-band { border-bottom: 1px solid var(--line); background: var(--paper); }
.facts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    column-gap: clamp(1.5rem, 4vw, 3rem);
}
.fact {
    padding-block: clamp(1.5rem, 3vw, 2.25rem);
    border-left: 1px solid var(--line);
    padding-left: clamp(1rem, 2vw, 1.75rem);
}
.fact:first-child { border-left: 0; padding-left: 0; }
@media (max-width: 640px) {
    .fact { border-left: 0; padding-left: 0; padding-block: 1.1rem; border-top: 1px solid var(--line); }
    .fact:first-child { border-top: 0; }
}
.fact__num {
    display: block;
    font-size: clamp(1.9rem, 1.3rem + 1.8vw, 2.6rem);
    font-weight: 700;
    letter-spacing: -.03em;
    color: var(--accent);
    line-height: 1;
}
.fact__label { display: block; margin-top: .5rem; font-size: .95rem; color: var(--muted); }

/* --- Kachelraster (Leistungen) -------------------------------------------- */

.section-head { max-width: 60ch; margin-bottom: clamp(2.5rem, 5vw, 3.5rem); }

.grid {
    display: grid;
    gap: clamp(1rem, 2vw, 1.5rem);
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
}

.card {
    display: flex;
    flex-direction: column;
    padding: clamp(1.5rem, 3vw, 2.1rem);
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.card:hover {
    border-color: transparent;
    box-shadow: var(--shadow);
    transform: translateY(-3px);
}
.card__icon {
    width: 46px;
    height: 46px;
    margin-bottom: 1.35rem;
    color: var(--accent);
}
.card h3 { margin-bottom: .45em; }
.card p { color: var(--muted); font-size: .98rem; }
.card .arrow-link { margin-top: auto; padding-top: 1.25rem; }

/* --- Spotlight (zweispaltig, Bild + Text) --------------------------------- */

.split {
    display: grid;
    gap: clamp(2rem, 5vw, 4.5rem);
    align-items: center;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}
.split__art {
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--ink-soft);
}
.split--reverse .split__art { order: 2; }

.checklist { margin: 1.5rem 0 0; padding: 0; list-style: none; }
.checklist li {
    position: relative;
    padding-left: 1.9rem;
    margin-bottom: .7rem;
}
.checklist li::before {
    content: "";
    position: absolute;
    left: 0;
    top: .55em;
    width: .95rem;
    height: .5rem;
    border-left: 2px solid var(--accent);
    border-bottom: 2px solid var(--accent);
    transform: rotate(-45deg);
}
.band--ink .checklist li::before { border-color: #7fb4f5; }

/* --- Prozess (nummerierte Schritte) --------------------------------------- */

.steps {
    display: grid;
    gap: clamp(1.5rem, 3vw, 2.5rem);
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    counter-reset: step;
}
.step { position: relative; padding-top: 2.75rem; border-top: 2px solid rgba(255, 255, 255, .18); }
.step::before {
    counter-increment: step;
    content: "0" counter(step);
    position: absolute;
    top: 1rem;
    left: 0;
    font-size: .95rem;
    font-weight: 700;
    letter-spacing: .1em;
    color: #7fb4f5;
}
.step h3 { font-size: 1.15rem; margin-bottom: .4em; }
.step p { color: rgba(255, 255, 255, .72); font-size: .96rem; }

/* --- Kontaktband ---------------------------------------------------------- */

.contact-grid {
    display: grid;
    gap: clamp(2rem, 5vw, 4rem);
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}
.contact-list { margin: 0; padding: 0; list-style: none; }
.contact-list dt {
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--muted);
    margin-top: 1.5rem;
}
.contact-list dd { margin: .25rem 0 0; font-size: 1.05rem; }
.contact-list dt:first-child { margin-top: 0; }

/* Vorsorge: Steht eine Kontaktliste in einem dunklen Band, muss auch das
   kleingedruckte Label hell werden – graues Muted wäre dort unlesbar. */
.band--ink .contact-list dt,
.hero .contact-list dt,
.page-hero .contact-list dt { color: rgba(255, 255, 255, .72); }
.band--ink .contact-list dd,
.band--ink .contact-list a,
.hero .contact-list dd,
.page-hero .contact-list dd { color: #fff; }
.band--ink .contact-list a:hover { color: #bcd9ff; }

/* --- Fußzeile ------------------------------------------------------------- */

.site-foot {
    background: var(--ink);
    color: rgba(255, 255, 255, .72);
    padding-block: clamp(3rem, 6vw, 4.5rem) 2rem;
    font-size: .95rem;
}
.foot-grid {
    display: grid;
    gap: 2.5rem;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    padding-bottom: 2.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, .14);
}
.site-foot h4 {
    color: #fff;
    font-size: .8rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    margin-bottom: 1.1rem;
}
.site-foot ul { margin: 0; padding: 0; list-style: none; }
.site-foot li { margin-bottom: .55rem; }
.site-foot a { color: rgba(255, 255, 255, .72); }
.site-foot a:hover { color: #fff; }
.foot-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 2rem;
    justify-content: space-between;
    padding-top: 1.75rem;
    font-size: .88rem;
    color: rgba(255, 255, 255, .55);
}

/* --- Bewegung nur, wenn gewünscht ----------------------------------------- */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: .01ms !important;
        transition-duration: .01ms !important;
    }
}

/* --- Seitenkopf der Unterseiten ------------------------------------------- */

.page-hero {
    position: relative;
    overflow: hidden;
    background: var(--ink);
    color: #fff;
    padding-block: clamp(3rem, 7vw, 5.5rem);
}
.page-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(60% 120% at 85% 15%, rgba(47, 139, 255, .28), transparent 70%),
        linear-gradient(120deg, #0d1b3d 0%, #16182b 65%);
    z-index: 0;
}
.page-hero > * { position: relative; z-index: 1; }
.page-hero h1 { color: #fff; max-width: 20ch; }
.page-hero .lead { color: rgba(255, 255, 255, .8); }
.page-hero .eyebrow { color: #7fb4f5; }

/* Sprungmarken innerhalb einer Seite */
.jumpbar {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem 1.75rem;
    padding-block: 1.1rem;
    border-bottom: 1px solid var(--line);
    font-size: .95rem;
}
.jumpbar a { color: var(--muted); font-weight: 550; }
.jumpbar a:hover { color: var(--accent); }

/* Abschnitt mit Anker – Offset wegen der klebenden Kopfzeile */
.anchor { scroll-margin-top: 90px; }

/* --- Leistungsblöcke ------------------------------------------------------ */

.service + .service { margin-top: clamp(3rem, 7vw, 5rem); padding-top: clamp(3rem, 7vw, 5rem); border-top: 1px solid var(--line); }
.service__grid {
    display: grid;
    gap: clamp(1.5rem, 4vw, 3.5rem);
    grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 860px) {
    .service__grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
}
.service h2 { margin-bottom: .35em; }

.plainlist { margin: 0; padding: 0; list-style: none; }
.plainlist li { padding: .55rem 0; border-bottom: 1px solid var(--line); }
.plainlist li:first-child { border-top: 1px solid var(--line); }

.aside-box {
    padding: clamp(1.35rem, 3vw, 1.9rem);
    background: var(--paper-warm);
    border-left: 3px solid var(--accent);
    border-radius: 0 var(--radius) var(--radius) 0;
}
.aside-box h3 { font-size: 1.02rem; }
.aside-box p, .aside-box li { font-size: .96rem; color: var(--muted); }

/* --- Rechtstexte ---------------------------------------------------------- */

.legal { max-width: 78ch; }
.legal h2 { font-size: clamp(1.3rem, 1.05rem + 1vw, 1.75rem); margin-top: 2.5em; }
.legal h3 { font-size: 1.12rem; margin-top: 2em; }
.legal ul { padding-left: 1.2rem; }
.legal li { margin-bottom: .5rem; }
.legal p, .legal li { color: #33384a; }
.legal__back { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }

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

.form { display: grid; gap: 1.1rem; }
.field { display: grid; gap: .4rem; }
.field label { font-size: .92rem; font-weight: 600; }
.field input, .field textarea {
    width: 100%;
    padding: .8rem .95rem;
    font: inherit;
    color: var(--ink);
    background: var(--paper);
    border: 1px solid var(--line-ui);   /* Feldgrenze muss erkennbar sein */
    border-radius: var(--radius);
}
.field input:focus, .field textarea:focus { border-color: var(--accent); outline: 2px solid var(--accent-pale); }
.field textarea { min-height: 9rem; resize: vertical; }
.field--half { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.form__hint { font-size: .87rem; color: var(--muted); }
.form__status { padding: .9rem 1.1rem; border-radius: var(--radius); font-size: .95rem; display: none; }
.form__status[data-state="ok"] { display: block; background: #e7f6ec; border: 1px solid #b6e0c4; color: #17603a; }
.form__status[data-state="err"] { display: block; background: #fdeceb; border: 1px solid #f5c2be; color: #8f2019; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
