/* HEFTER - gemeinsame Gestaltung | Technikstand v05, 17.11.2026
   Vier HTML-Beispiele: Startseite A / B, Fachgebiet, Projekt.
   Bilddateien kuenftig: 900 px fuer .bild-450, 276 x 276 px fuer .bild-138.
   Die angezeigten Masse bleiben unabhaengig von der Datei-Aufloesung. */

/* 01 - Grundwerte und Schrift */
:root { --gruen: #527d39; --text: #222; --grau: #777; --linie: #d8d8d4; --inhalt: 840px; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; color: var(--text); background: #fff; font: 14px/1.5 Arial, Helvetica, sans-serif; }
p { margin: 0 0 1em; }
img { display: block; max-width: 100%; height: auto; border: 0; }
a { color: var(--gruen); text-decoration: none; }
a:hover, a:focus-visible { color: #fff; background: #000; }

/* Normale Textlinks sind schwarz und fett; bei Hover invers. */
#inhalt a[href]:not(:where(nav a, .seitennavigation a, .bildbereich > a, .teaser :is(h2, h3) a)):not(:has(img)) { color: #000; font-weight: 700; }
#inhalt a[href]:not(:where(nav a, .seitennavigation a, .bildbereich > a, .teaser :is(h2, h3) a)):not(:has(img)):is(:hover, :focus-visible) { color: #fff; background: #000; }

/* 02 - Seitenrahmen / Bilder */
#seitenrahmen { width: calc(var(--inhalt) + 40px); max-width: 100%; margin: 0 auto; padding: 0 20px; }
#inhalt { width: 100%; min-width: 0; }

.bild-450 { width: 450px; max-width: 100%; height: auto; }
.bild-138 { width: 138px; max-width: 100%; height: 138px; object-fit: cover; }
.bild-start { width: 486px; max-width: 100%; height: auto; }

/* 03 - Kopf / Hauptnavigation */
#kopf { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 35px; margin: 20px 0; padding-bottom: 20px; border-bottom: 1px solid var(--linie); }

.marke { display: flex; align-items: center; flex: 0 0 auto; gap: 12px; white-space: nowrap; }
.marke strong { font-size: 29px; line-height: 1.2; }
.marke a { color: inherit; }
.marke a:hover, .marke a:focus-visible { color: #fff; background: #000; }
.marke span { font-size: 16px; line-height: 1.2; }

/* Hauptnavigation */
#navigation { flex: 1 1 auto; min-width: 0; font-size: 11px; line-height: 1.5; letter-spacing: .2px; }
#navigation ul { display: flex; justify-content: flex-end; align-items: center; flex-wrap: nowrap; gap: 16px; margin: 0; padding: 0; list-style: none; }
#navigation li { white-space: nowrap; text-transform: uppercase; }
#navigation a:hover, #navigation a:focus-visible { background: var(--gruen); }

.menu-toggle { display: none; flex: 0 0 34px; width: 34px; height: 30px; margin-left: auto; padding: 6px 5px; border: 0; background: transparent; color: var(--gruen); cursor: pointer; }
.menu-toggle span, .menu-toggle span::before, .menu-toggle span::after { position: relative; display: block; width: 23px; height: 2px; background: currentColor; content: ""; }
.menu-toggle span::before { position: absolute; top: -7px; }
.menu-toggle span::after { position: absolute; top: 7px; }

/* 04 - Fuss und Seitennavigation */
/* Fusszeile */
#fuss { display: flex; justify-content: space-between; align-items: center; gap: 18px; padding: 8px 0 18px; font-size: 11px; line-height: 1.5; }
.copyright { color: #666; }
.copyright strong { color: var(--text); }
.footer-nav { display: flex; flex: 0 1 auto; flex-wrap: wrap; justify-content: flex-end; gap: 6px 12px; text-align: right; letter-spacing: .2px; }
.footer-nav a:hover, .footer-nav a:focus-visible { background: var(--gruen); }

/* Seitennavigation */
.seitennavigation { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 10px 20px; margin: 0; padding: 10px 0; border-top: 1px solid var(--linie); color: #666; font-size: 11px; letter-spacing: 1.3px; text-align: right; }
.seitennavigation a { color: #666; }
.seitennavigation a:hover, .seitennavigation a:focus-visible { color: #fff; background: #000; }

/* 05 - Titelbereich: gleiche Typografie und Bildregeln */
.titelbereich { display: grid; grid-template-columns: minmax(0, 1fr) 450px; align-items: stretch; gap: 0; padding: 0 0 20px; }

.titelbereich-text { display: flex; flex-direction: column; justify-content: center; min-width: 0; padding: 4px 18px 4px 0; }
.titel-rubrik { margin: 0 0 8px; color: var(--gruen); font-size: 24px; font-weight: 400; line-height: 1.2; }
.titelbereich h1:not(.titel-rubrik), .titel-haupt { margin: 0 0 9px; color: #171717; font-size: 29px; font-weight: 400; line-height: 1.18; letter-spacing: -.6px; }
.titel-zusatz { margin: 0; color: var(--grau); font-size: 16px; font-weight: 400; line-height: 1.58; }

/* 06 - Wiederverwendete Inhaltszeile: Rubrik links, Text rechts */
.infozeile { display: grid; grid-template-columns: 30% minmax(0, 70%); margin: 0; padding: 0 0 20px; }
.abschnitt-label { margin: 0; padding: 3px 18px 0; font-size: 11px; font-weight: 700; line-height: 1.3; text-transform: uppercase; }

.infozeile-text { min-width: 0; padding-right: 18px; font-size: 14px; line-height: 1.35; }
.infozeile-text p { margin: 0 0 12px; }
.infozeile-text p:last-child { margin-bottom: 0; }
#zitat .infozeile-text strong { display: block; margin-bottom: 8px; }

/* 07 - Gemeinsamer Teaser (Bild + Uebertitel + Ueberschrift + Text) */
.bereichs-kicker { margin: 0 0 4px; color: var(--gruen); font-size: 10px; line-height: 1.58; letter-spacing: 1.3px; text-transform: uppercase; }

.teaser { display: grid; grid-template-columns: 138px minmax(0, 1fr); align-items: start; gap: 20px; margin: 0; padding: 0 0 20px; font-size: 15px; line-height: 1.58; scroll-margin-top: 20px; }
.teaser h2 { margin: 0 0 7px; font-size: 21px; font-weight: 400; line-height: 1.2; }
.teaser h3 { margin: 0 0 7px; font-size: 15px; font-weight: 700; line-height: 1.35; }
.teaser h2 a, .teaser h3 a { color: inherit; font-weight: inherit; }
.teaser h2 a:hover, .teaser h2 a:focus-visible, .teaser h3 a:hover, .teaser h3 a:focus-visible { color: var(--gruen); background: transparent; }
.teaser p { margin: 0; }
.teaser .bereichs-kicker { margin-bottom: 4px; }

/* 08 - Startseite A / B: gleicher Textstil, unterschiedliche Bildbreite */

.startseite-a .titelbereich { grid-template-columns: minmax(0, 1fr) 486px; }
.startseite .titelbereich-text .titel-rubrik { margin-bottom: 8px; }
.startseite .titelbereich-text .titel-haupt { margin-bottom: 6px; }
.startseite .titelbereich-text .titel-zusatz { margin-top: 9px; }

/* Bildbereiche */
.bildbereiche { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; margin: 20px 0; padding-bottom: 20px; }
.bildbereich img { width: 100%; margin-bottom: 6px; }
.bildbereich a { display: inline-block; font-size: 11px; font-weight: 700; text-transform: uppercase; }
.bildbereich p { margin: 5px 0 0; font-size: 11px; line-height: 1.45; }

/* 09 - Fachgebietsseite: Textspalten, Leistungen, Projektteaser */
.fachgebiet { color: #171717; font-size: 15px; line-height: 1.58; }
.fachgebiet .titelbereich { grid-template-columns: minmax(0, 1fr) minmax(0, 486px); padding: 12px 0 14px; }
.fachgebiet .titelbereich-text { padding: 4px 0; }

/* Inhaltsabschnitte */
.inhalt-abschnitt { margin: 0; padding: 0 0 20px; scroll-margin-top: 20px; }
.profil-qualifikation { font-size: 23px; }
.inhalt-abschnitt > h2 { margin: 0 0 18px; font-size: 23px; font-weight: 400; line-height: 1.2; letter-spacing: -.3px; }
.inhalt-abschnitt h3 { margin: 0 0 7px; font-size: 16px; font-weight: 700; line-height: 1.35; }
.inhalt-abschnitt p { margin-bottom: 12px; }

/* Text- und Listenspalten */
.textspalten, .listenspalten { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.textspalten { gap: 22px 28px; }
.listenspalten { gap: 24px 35px; }
.textblock { min-width: 0; }
.textblock p { margin-bottom: 0; }
.textblock .bild-138 { float: right; margin: 0 0 10px 15px; max-width: 42%; }
.listenblock ul { margin: 6px 0 0; padding-left: 19px; }
.listenblock li { padding: 2px 0; }
.listenblock ul ul { margin: 2px 0 5px; }
.inhalt-abschnitt > .teaser { margin: 0; padding: 20px 0; }
#projektbeispiele > p:not(.bereichs-kicker) { margin: -6px 0 18px; }
.inhalt-abschnitt > hr { height: 0; margin: 0 0 20px; border: 0; border-top: 1px solid var(--linie); }

/* Projektuebersicht */
.projektliste { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 24px; }
.projektteaser { min-width: 0; margin: 0; padding: 0; }
.projektteaser .teaser-text { padding-inline-end: 12px; hyphens: none; overflow-wrap: normal; word-break: normal; }
.projektteaser h3 { font-size: 18px; font-weight: 400; line-height: 1.25; }
.projektteaser .teaser-text > p:not(.bereichs-kicker) { color: var(--grau); font-size: 14px; line-height: 1.45; }
.projektliste .projektteaser:last-child { padding-bottom: 0; }

/* 10 - Projektseite: Titel, Beschreibung, Bild-/Textfolge */
.projektseite .titelbereich { grid-template-columns: 340px 50px 450px; }

.projektseite .titelbereich-text { grid-column: 1; padding: 4px 0; }
.projektseite .titelbereich > img { grid-column: 3; }
.projektseite .titel-rubrik { font-size: 10px; line-height: 1.58; letter-spacing: 1.3px; text-transform: uppercase; }
.projektseite .titel-zusatz { margin: 0 0 8px; }

/* Projektbeschreibung */
.projekt-meta { font-size: 14px; line-height: 1.5; }
.projekt-meta p { margin: 0 0 8px; }

.projektseite .infozeile { margin: 0; padding: 20px 0; }
.projektseite .infozeile-text { line-height: 1.55; }

/* Projektbilder */
.bild-text { display: grid; grid-template-columns: 340px 50px 450px; align-items: center; margin: 0; padding: 20px 0; }
.bild-text > iframe { grid-column: 3; grid-row: 1; justify-self: end; align-self: end; margin-block: auto; width: 100%; max-width: 450px; height: auto; aspect-ratio: 16 / 9; border: 0; }
.bild-text > img { grid-column: 3; grid-row: 1; }
.bild-text figcaption { grid-column: 1; grid-row: 1; min-width: 0; font-size: 14px; line-height: 1.55; }
.bild-text figcaption p { margin: 0; }
.figure-number { display: block; margin-bottom: 7px; color: var(--grau); font-size: 11px; font-weight: 400; line-height: 1.4; letter-spacing: 1.5px; }

.projektseite .bildfolge + .teaser { margin: 0; padding-bottom: 20px; }
.projektseite .teaser + .seitennavigation { margin-top: 0; }

/* 11 - Responsive Layouts und Mobilnavigation */
@media (max-width: 879px) {
    /* Mit JavaScript: aufklappbare Navigation. */
    #kopf.menu-ready .menu-toggle { display: block; }
    #kopf.menu-ready #navigation { display: none; position: absolute; z-index: 20; top: calc(100% + 1px); right: 0; width: 210px; padding: 18px 20px; background: #fff; border: 1px solid #e2e2e2; box-shadow: 0 8px 18px rgb(0 0 0 / 8%); }
    #kopf.menu-ready.menu-open #navigation { display: block; }
    /* Ohne JavaScript: Navigation sichtbar und mehrzeilig. */
    #kopf:not(.menu-ready) { flex-wrap: wrap; }
    #kopf:not(.menu-ready) #navigation { flex-basis: 100%; width: 100%; }
    #kopf:not(.menu-ready) #navigation ul { flex-wrap: wrap; justify-content: flex-start; gap: 8px 12px; }
    #kopf.menu-ready #navigation ul { flex-direction: column; align-items: flex-end; gap: 13px; }
    a, .teaser h2 a, .teaser h3 a { font-weight: 700; }
    #navigation, #fuss, .abschnitt-label, .bereichs-kicker, .projektseite .titel-rubrik, .figure-number, .bildbereich a, .bildbereich p, small, sub, sup { font-size: 14px; }
    .projektseite, .projektseite .infozeile-text, .projekt-meta, .bild-text figcaption { font-size: 16px; }
    .footer-nav a { padding: 7px 0; }
    #kopf #navigation a { display: inline-block; padding: 7px; }
    .seitennavigation { gap: 0 16px; padding: 4px 0; font-size: 14px; letter-spacing: .3px; }
    .seitennavigation a { display: inline-block; padding: 7px 0; color: #505050; }

    .startseite .titelbereich { grid-template-columns: minmax(0, 1fr) minmax(0, 450px); }
    .startseite-a .titelbereich { grid-template-columns: minmax(0, 1fr) minmax(0, 486px); }
    .projektseite .titelbereich, .bild-text { grid-template-columns: 40% 5% 55%; }
}

@media (max-width: 760px) {
    #seitenrahmen { padding: 16px; }
    #kopf { margin: 0 0 16px; padding-bottom: 16px; }
    #fuss { display: block; margin-top: 18px; padding-top: 12px; }
    .footer-nav { margin-top: 10px; }

    .startseite .titelbereich, .startseite-a .titelbereich { grid-template-columns: minmax(140px, .34fr) minmax(0, 1fr); gap: 22px; padding-bottom: 16px; }
    .bildbereiche { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; }
    .infozeile { grid-template-columns: minmax(0, 1fr); gap: 8px; margin: 0; padding-bottom: 16px; }
    .abschnitt-label { padding: 3px 0 0; }
    .projektseite .infozeile { padding: 20px 0; }
}

@media (max-width: 700px) {
    .fachgebiet .titelbereich { grid-template-columns: minmax(0, 1fr); gap: 12px; }
    .fachgebiet .titelbereich-text { order: 2; }
    .fachgebiet .titelbereich > img { order: 1; }

    .textspalten, .listenspalten, .projektliste { grid-template-columns: minmax(0, 1fr); }
    .textspalten { gap: 19px; }
    .listenspalten { gap: 18px; }

    .titel-rubrik { font-size: 21px; }
    .titelbereich h1:not(.titel-rubrik), .titel-haupt { font-size: 26px; }
}

@media (max-width: 640px) {
    .projektseite .titelbereich { display: flex; flex-direction: column; gap: 12px; }
    .projektseite .titelbereich > img { order: 1; width: 100%; max-width: 100%; margin-left: 0; }
    .projektseite .titelbereich-text { order: 2; padding: 0; }

    .bild-text { display: flex; flex-direction: column; align-items: stretch; gap: 12px; }
    .bild-text > img { order: 1; width: 100%; max-width: 100%; margin-left: 0; }
    .bild-text figcaption { order: 2; }
}

@media (max-width: 480px) {
    .startseite .titelbereich, .startseite-a .titelbereich { display: flex; flex-direction: column; gap: 0; margin-bottom: 0; }
    .startseite .titelbereich > img { order: 1; width: 100%; max-width: 100%; }
    .startseite .titelbereich-text { order: 2; margin-top: 9px; padding: 0; }

    .startseite .infozeile { gap: 4px; }
    .infozeile-text { line-height: 1.45; }
    .bildbereiche { margin-top: 10px; margin-bottom: 22px; }
    .bildbereich p { line-height: 1.5; }
}

@media (max-width: 420px) {
    .marke { gap: 7px; }
    .marke strong { font-size: 24px; }
    .marke span { font-size: 14px; }

    .teaser { grid-template-columns: 100px minmax(0, 1fr); gap: 14px; }
    .teaser .bild-138 { width: 100%; height: auto; aspect-ratio: 1; }
    .teaser h2 { font-size: 18px; }
}

/* Stammseiten: Lesespalten, Bilder und Abschnittsabschluesse */
.stammseite .titelbereich > img { align-self: center; height: auto; }
.stammseite .lesespalten { column-count: 2; column-gap: 28px; }
.stammseite .lesespalten h3 { break-after: avoid; }
.stammseite .lesespalten p { margin: 0 0 12px; }
.stammseite .lesespalten > :last-child { margin-bottom: 0; }
.stammseite .listenspalten:has(> :only-child) { display: block; }
.stammseite .inhalt-abschnitt > .teaser:last-child { margin-bottom: 0; padding-bottom: 0; }
.stammseite .abschluss { margin-bottom: 0; }
.stammseite .seitenende { margin-bottom: 0; }
.stammseite .leistungsblock > img { margin-top: 16px; }
.stammseite .teaser-text { min-width: 0; }
.stammseite .seitennavigation a { display: inline-block; }
@media (max-width: 700px) {
    .stammseite .lesespalten { column-count: 1; }
}
/* Abschnittslinien stehen nur am Anfang des folgenden Elements. */
#inhalt > :not(script) + :is(section, article, aside, div, .bildbereiche), #projektbeschreibung > :is(.infozeile, .teaser, .bildfolge) + :is(.infozeile, .teaser, .bildfolge), .bildfolge > .bild-text + .bild-text, .inhalt-abschnitt > .teaser + .teaser { border-top: 1px solid var(--linie); }
#inhalt > :not(script) + :is(.inhalt-abschnitt, .teaser, .infozeile), #projektbeschreibung > .teaser { padding-top: 22px; }
.startseite > .abschluss:last-child, #inhalt > .seitennavigation:last-child { border-bottom: 1px solid var(--linie); }
.inhalt-abschnitt > .listenspalten + .teaser, .inhalt-abschnitt > .teaser + :is(.listenspalten, .listenblock) { border-top: 1px solid var(--linie); padding-top: 20px; }
.inhalt-abschnitt > .listenspalten:has(+ .teaser) { padding-bottom: 20px; }
.leistungsblock > ul:last-child, .inhalt-abschnitt > :last-child, .teaser-text > p:last-child { margin-bottom: 0; }
.inhalt-abschnitt > h2 + .teaser { padding-top: 0; }
.stammseite .projektverweise { margin-top: 20px; }
.lebenslaeufe > .textblock + .textblock { margin-top: 24px; }
.pinterest-profil { width: 100%; max-width: var(--inhalt); }
.pinterest-profil > * { max-width: 100%; box-sizing: border-box; }
.titelbereich-text { overflow-wrap: break-word; }
@media (min-width: 701px) {
    .fachgebiet .titelbereich { column-gap: 32px; }
    .projektliste > .projektteaser:nth-child(n+3) { position: relative; padding-top: 20px; }
    .projektliste > .projektteaser:nth-child(odd):nth-child(n+3)::before { position: absolute; top: 0; left: 0; width: calc(200% + 24px); height: 1px; background: var(--linie); content: ""; }
}
@media (min-width: 761px) {
    .startseite .titelbereich { column-gap: 32px; }
    .startseite .titelbereich-text { padding-right: 0; }
}
@media (max-width: 700px) {
    .fachgebiet .titelbereich { row-gap: 18px; }
    .projektliste > .projektteaser + .projektteaser { padding-top: 20px; border-top: 1px solid var(--linie); }
}
@media (max-width: 640px) {
    .projektseite .titelbereich { row-gap: 18px; }
}
@media (max-width: 480px) {
    .startseite .titelbereich { row-gap: 18px; }
    .startseite .titelbereich-text { margin-top: 0; }
}

@media (min-width: 701px) and (max-width: 820px), (max-width: 380px) {
    .projektteaser { grid-template-columns: minmax(64px, 24%) minmax(0, 1fr); gap: 12px; }
    .projektteaser .bild-138 { width: 100%; height: auto; aspect-ratio: 1; }
}

.stammseite .inhalt-abschnitt:has(> .projektverweise:last-child) { padding-bottom: 0; }

@media (min-width: 880px) {
    .projektseite .titel-querformat { grid-template-columns: minmax(0, 1fr) 50px 486px; }
}
.projektseite .titel-querformat > img { align-self: center; width: 486px; max-width: 100%; height: auto; }
