/* ==========================================================================
   DIM – Theme-Styles
   --------------------------------------------------------------------------
   Die Grundfarbe (--accent), ihr barrierefreier Ton (--accent-ink) und die
   Hover-Farbe (--accent-dark) setzt das Template pro Seite direkt am
   <html>-Element; die Werte unten sind nur Rückfallwerte.
   --accent       Rahmen, Linien, große Flächen
   --accent-ink   Schrift in Grundfarbe, Buttons, farbige Kacheln (Kontrast ≥ 4,5:1)
   Eigene Ergänzungen bitte in custom.css.

   Inhalt
    1. Schrift
    2. Variablen
    3. Basis & Typografie
    4. Buttons
    5. Kopfbereich: Logo & Menü
    6. Headerbild (Unterseiten)
    7. Slideshow (Startseite)
    8. Sektionen & Seitenleiste
    9. Module
       9.1 Einstieg zweispaltig (intro)
       9.2 Kacheln farbig (cards)
       9.3 Text + Bild (text-image)
       9.4 Brennpunkt-Ausgaben (issues)
       9.5 Personen rund (team)
       9.6 Spalten (columns, z. B. Spenden)
       9.7 Kachel-Seite (tiles, z. B. Mitarbeiter, Ressourcen)
   10. Blog
   11. Formulare
   12. Footer
   13. Kleinteile (Kopier-Button, QR-Code)
   14. Responsiv
   15. Barrierefreiheit
   ========================================================================== */


/* ==========================================================================
   1. Schrift
   Catamaran 2.000 (SIL OFL 1.1, siehe fonts/OFL.txt) – variable Schrift,
   alle Stärken 100–900 in einer Datei
   ========================================================================== */

@font-face {
    font-family: Catamaran;
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url(../fonts/catamaran-variable.woff2) format("woff2");
}


/* ==========================================================================
   2. Variablen
   ========================================================================== */

:root {
    /* Farben */
    --accent: #00a3bf;            /* Rückfallwert, wird pro Seite gesetzt */
    --accent-ink: #008299;        /* Rückfallwert: Grundfarbe so dunkel, dass Schrift darauf/daneben ≥ 4,5:1 hat */
    --accent-dark: #045a69;       /* Rückfallwert, wird pro Seite gesetzt (Hover) */
    --on-accent: #ffffff;         /* Schriftfarbe auf der Grundfarbe (Menü), wird pro Seite gesetzt */
    --text: #605c72;
    --text-strong: #232529;
    --text-muted: #696969;
    --bg: #ffffff;
    --bg-light: #f2f2f2;
    --bg-dark: #545454;
    --footer-text: #d4d4d4;       /* 5,1:1 auf --bg-dark */
    --border: #e7e8ea;

    /* Abstände & Maße */
    --frame: 1.5rem;              /* farbiger Rand um die Seite */
    --pad-x: clamp(1.25rem, 4vw, 4rem);
    --pad-y: clamp(2.5rem, 6vw, 5rem);
    --content-max: 75rem;
    --radius-pill: 1rem;

    /* Effekte */
    --shadow-tile: 0 2px 6px rgba(0,0,0,.06), 0 8px 24px rgba(0,0,0,.08);
    --shadow-card: 0 2px 6px rgba(0,0,0,.15), 0 10px 28px rgba(0,0,0,.25);   /* kräftiger, auch auf dunklem Grund sichtbar */
    --slider-overlay: rgba(0,0,0,.5);

    /* Schrift */
    --font: Catamaran, Helvetica, Tahoma, Geneva, Arial, sans-serif;
}


/* ==========================================================================
   3. Basis & Typografie
   ========================================================================== */

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

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

body {
    margin: 0;
    background: var(--accent);
    color: var(--text);
    font: 400 1rem/1.6 var(--font);
}

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

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

h1, h2, h3, h4, h5, h6 {
    margin: 1.5em 0 .5em;
    color: var(--text-strong);
    font-family: var(--font);
    line-height: 1.2;
}
h1 { font-size: 2.2rem;  font-weight: 700; }
h2 { font-size: 1.75rem; font-weight: 700; }
h3 { font-size: 1.4rem;  font-weight: 600; }
h4 { font-size: 1.15rem; font-weight: 600; }
:is(h1, h2, h3, h4):first-child { margin-top: 0; }

hr { margin: 2rem 0; border: 0; border-bottom: 3px solid var(--border); }

.lead,
.g-lead { font-size: 1.25rem; font-weight: 300; }   /* .g-lead: aus alten Gantry-Inhalten */

.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* Seitenrahmen in der Grundfarbe */
.site { padding: 0 var(--frame) var(--frame); }


/* ==========================================================================
   4. Buttons
   ========================================================================== */

.button,
button.button,
input[type=submit].button {
    display: inline-block;
    padding: .5rem 2rem .45rem;
    border: 0;
    border-radius: var(--radius-pill);
    background: var(--accent-ink);
    color: #fff !important;
    font: 500 .95rem/1.4 var(--font);
    cursor: pointer;
    transition: background .2s;
}
.button:hover { background: var(--accent-dark); }

/* Varianten */
.button--light         { background: #fff; color: var(--accent-ink) !important; }
.button--light:hover   { background: rgba(255,255,255,.85); }
.button--outline       { background: transparent; color: var(--accent-ink) !important; box-shadow: inset 0 0 0 2px var(--accent-ink); }
.button--outline:hover { background: var(--accent-ink); color: #fff !important; }

/* Links im Fließtext zusätzlich unterstreichen (nicht nur über die Farbe erkennbar) */
:where(.page-content, .tile-text, .column-text, .aside-text, .section-intro, .text-image-text, .card-text, .blog-teaser-summary) a:not(.button) {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: .15em;
}

/* Sprungmarke „Zum Inhalt springen“ – erscheint nur bei Tastaturbedienung */
.skip-link {
    position: absolute; left: 1rem; top: -4rem; z-index: 100;
    padding: .6rem 1.2rem;
    border-radius: var(--radius-pill);
    background: #fff; color: var(--accent-ink);
    font-weight: 700;
    transition: top .15s;
}
.skip-link:focus { top: 1rem; }
main:focus { outline: none; }

/* Großer Schmuck-Text (z. B. „JESUS“), ohne Überschrift zu sein */
.display { margin: 0 0 .5rem; color: var(--accent-ink); font-size: 2.4rem; font-weight: 800; line-height: 1.1; }
.button--small         { padding: .3rem 1.25rem; font-size: .85rem; }


/* ==========================================================================
   5. Kopfbereich: Logo & Menü
   ========================================================================== */

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    min-height: 10rem;
    padding: 1.5rem var(--pad-x);
}

.site-logo { display: block; flex: none; line-height: 0; }
.site-logo svg,
.site-logo img { width: 150px; height: 80px; }

/* Hauptmenü (Desktop) */
.site-nav .menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: .25rem 1.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}
.menu-item { position: relative; }
.menu-item > a {
    display: block;
    padding: .4rem 0;
    color: var(--on-accent);
    font-size: 1.35rem;
    font-weight: 700;              /* fett ab 18,7 px = „große Schrift“ → Kontrast 3:1 genügt */
    border-bottom: 2px solid transparent;
}
.menu-item > a:hover,
.menu-item.is-active > a { border-bottom-color: currentColor; }

/* Untermenü (Dropdown) */
.submenu {
    position: absolute; top: 100%; left: -1rem; z-index: 20;
    min-width: 14rem;
    margin: 0; padding: .5rem 0;
    list-style: none;
    background: #fff;
    box-shadow: 0 .5rem 1.5rem rgba(0,0,0,.15);
    opacity: 0; visibility: hidden; transform: translateY(.25rem);
    transition: .2s;
}
.has-children:hover > .submenu,
.has-children:focus-within > .submenu { opacity: 1; visibility: visible; transform: none; }
.submenu a { display: block; padding: .4rem 1rem; color: #5f6b78; font-size: 1rem; }
.submenu a:hover,
.submenu .is-active > a { color: #000; }

/* Menü-Button – nur mobil sichtbar (siehe 14. Responsiv) */
.nav-toggle { display: none; }


/* ==========================================================================
   6. Headerbild (Unterseiten)
   ========================================================================== */

.hero {
    position: relative;
    display: grid;
    place-items: center;
    min-height: clamp(14rem, 36vw, 350px);   /* max. 350 px in der breitesten Ansicht */
    padding: 3rem var(--pad-x);
    background: #333 var(--hero-image) center / cover no-repeat;
    text-align: center;
}
.hero::before { content: ""; position: absolute; inset: 0; background: rgba(0,0,0,.15); }
.hero-inner { position: relative; }

.hero-title,
.slide-title {
    margin: 0;
    color: #fff;
    font-size: clamp(2.25rem, 6vw, 5.5rem);
    font-weight: 800;
    line-height: 1.05;
    text-shadow: 0 .5rem 2.5rem rgba(0,0,0,.6);
}
.hero-text {
    margin: .75rem 0 0;
    color: #fff;
    font-size: 1.3rem;
    text-shadow: 0 .25rem 1rem rgba(0,0,0,.6);
}

/* Seiten ohne Headerbild: nur Titel auf hellem Grund */
.hero--plain { min-height: 0; padding-block: 3rem; background: var(--bg-light); }
.hero--plain::before { display: none; }
.hero--plain .hero-title { color: var(--accent-ink); text-shadow: none; font-size: clamp(2rem, 4vw, 3rem); }


/* ==========================================================================
   7. Slideshow (Startseite)
   ========================================================================== */

.slider { position: relative; overflow: hidden; background: #222; }
.slider-track { position: relative; aspect-ratio: 16 / 6; min-height: 18rem; }

.slide { position: absolute; inset: 0; opacity: 0; transition: opacity .8s ease; }
.slide.is-active { opacity: 1; z-index: 1; }
.slide-image { width: 100%; height: 100%; object-fit: cover; }

/* Abdunkelung über dem Bild – Stärke über --slider-overlay (Abschnitt 2) */
.slide::after {
    content: "";
    position: absolute; inset: 0;
    background: var(--slider-overlay);
    pointer-events: none;
}

.slide-caption {
    position: absolute; inset: 0; z-index: 1;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem;
    padding: 2rem var(--pad-x) 4rem;
    text-align: center;
}
.slide-text { margin: 0; color: #fff; font-size: 1.25rem; text-shadow: 0 .25rem 1rem rgba(0,0,0,.6); }

/* Vorschaubilder unten rechts */
.slider-thumbs {
    position: absolute; right: var(--pad-x); bottom: 1.25rem; z-index: 2;
    display: flex; gap: .75rem;
}
.slider-thumb {
    width: 5.5rem; aspect-ratio: 16 / 9;
    padding: 0; overflow: hidden;
    border: 2px solid transparent; border-radius: .25rem;
    background: none; cursor: pointer;
    opacity: .7; transition: .2s;
}
.slider-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* Pause-/Abspielen-Button (Pflicht bei automatisch wechselnden Inhalten) */
.slider-pause {
    align-self: center;
    display: grid; place-items: center;
    width: 2.25rem; height: 2.25rem;
    padding: 0; border: 2px solid #fff; border-radius: 50%;
    background: rgba(0,0,0,.35); cursor: pointer;
}
.slider-pause-icon { width: .7rem; height: .8rem; border-left: 3px solid #fff; border-right: 3px solid #fff; }
.slider-pause.is-paused .slider-pause-icon {          /* Dreieck „Abspielen“ */
    width: 0; height: 0; border: 0; margin-left: .2rem;
    border-left: .65rem solid #fff; border-top: .42rem solid transparent; border-bottom: .42rem solid transparent;
}
.slider-thumb:hover,
.slider-thumb.is-active { opacity: 1; border-color: #fff; }


/* ==========================================================================
   8. Sektionen & Seitenleiste
   ========================================================================== */

/* Hintergrund-Varianten: white (Standard) | light | dark */
.section        { padding: var(--pad-y) var(--pad-x); background: var(--bg); }
.section--light { background: var(--bg-light); color: var(--text-muted); }
.section--dark  { background: var(--bg-dark); color: #fff; }
.section--dark :is(h1, h2, h3, h4) { color: #fff; }
.section--accent { background: var(--accent-ink); color: #fff; }
.section--accent :is(h1, h2, h3, h4, p) { color: #fff !important; }
.section--accent .button { background: #fff; color: var(--accent-dark) !important; }
.section--accent .button:hover { background: rgba(255,255,255,.85); }

/* Hintergrundbild (z. B. Flammen) unten über die ganze Breite */
.section.has-bg-image { position: relative; isolation: isolate; }
.section.has-bg-image::before {                       /* eigene Ebene, damit die Deckkraft einstellbar ist */
    content: "";
    position: absolute; inset: 0; z-index: -1;
    background: var(--section-image) no-repeat center bottom / cover;
    opacity: var(--section-image-opacity, 1);
    pointer-events: none;
}

/* Eigene Farbe aus dem Backend (Feld „Eigene Hintergrundfarbe“); Schriftfarbe wird im Template berechnet */
.section--custom { background-color: var(--section-bg); color: var(--section-fg); }
.section--custom :is(h1, h2, h3, h4, p, .display) { color: var(--section-fg) !important; }
.section--custom .button { background: var(--section-fg); color: var(--section-bg) !important; }
.section--custom .button:hover { opacity: .85; }
.section--custom :focus-visible { outline-color: var(--section-fg); }

/* Anthrazit (z. B. Flammenbereich auf der Startseite) */
.section--anthracite { background-color: #2e3135; color: #fff; }
.section--anthracite :is(h1, h2, h3, h4, p, .display) { color: #fff !important; }
.section--anthracite .button { background: #fff; color: #2e3135 !important; }
.section--anthracite .button:hover { background: rgba(255,255,255,.85); }
.section > *    { max-width: var(--content-max); margin-inline: auto; }

.section-title { margin-bottom: 2.5rem; font-size: 1.6rem; text-align: center; }
.section-intro { margin-bottom: 2rem; text-align: center; }
.section-intro > :first-child { margin-top: 0; }     /* verhindert, dass der Abstand aus der Sektion „herausrutscht“ */
.section-intro > :last-child  { margin-bottom: 0; }

/* Inhalt, optional mit linker Spalte (aside) */
.main-grid { display: block; max-width: 50rem; }
.main-grid.has-aside {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
    gap: clamp(2rem, 5vw, 5rem);
    max-width: var(--content-max);
}

.page-aside  { padding-right: clamp(1rem, 3vw, 3rem); border-right: 1px solid var(--border); }
.aside-title { margin: 0 0 .75rem; font-size: clamp(1.5rem, 2.2vw, 1.9rem); font-weight: 700; }
.aside-lead  { margin: 0 0 1.5rem; font-size: 1.2rem; line-height: 1.5; }
.aside-image { display: block; margin: 0 0 1.5rem; }
.aside-text  { color: var(--accent-ink); }
.aside-text :is(h1, h2, h3, h4) { color: var(--accent-ink); }
.aside-text h1 { font-size: 2.4rem; font-weight: 800; }
.aside-list    { margin: 0 0 1.5rem; padding: 0; list-style: none; }
.aside-list li { padding: .4rem 0; border-bottom: 1px solid #eee; line-height: 1.35; }

/* Seiteninhalt */
.page-content > :first-child { margin-top: 0; }
.page-content h1  { color: var(--accent-ink); }
.page-content img { border-radius: .25rem; }
.page-content table { width: 100%; border-collapse: collapse; }
.page-content :is(td, th) { padding: .5rem; border-bottom: 1px solid var(--border); text-align: left; }
.page-form { margin: 2rem 0; }


/* ==========================================================================
   9. Module
   ========================================================================== */

/* ---------- 9.1 Einstieg zweispaltig (Startseite „Dafür brennen wir:“) ---------- */
.intro-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
    gap: 2rem 4rem;
    align-items: center;
}
.intro-label h2 { margin: 0; font-size: 1.4rem; }
.intro-content h1,
.intro-content .display { margin: 0 0 .5rem; color: var(--accent-ink); font-size: 2.2rem; }
.intro-content h3,
.intro-content p { color: var(--text-muted); font-size: 1.6rem; font-weight: 500; line-height: 1.45; }
.intro-content .button { margin-top: 1.5rem; }

/* ---------- 9.2 Kacheln farbig (Startseite „Interesse?“, Vision) ---------- */
.card-grid { display: grid; grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); gap: 1.5rem; }
.card {
    display: flex; flex-direction: column;
    padding: 1.75rem 1.5rem;
    background: var(--accent-ink);
    color: #fff;
    box-shadow: var(--shadow-card);
}
.card-icon  { display: block; width: 3rem; height: 3rem; margin: 0 auto 1rem; color: #fff; opacity: .9; }
.card-icon svg { display: block; width: 100%; height: 100%; }
.card-title { margin: 0 0 .5rem; color: #fff !important; font-size: 1.4rem; text-align: center; }
.card-lead  { margin: 0 0 1rem; color: #fff; font-size: 1.2rem; font-weight: 300; line-height: 1.35; }
.card-text  { flex: 1; font-size: .95rem; }
.card-text ul { padding-left: 1.1rem; }
.card-actions { margin-top: 1.5rem; }

/* ---------- 9.3 Text + Bild ---------- */
.text-image-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 2rem 4rem;
    align-items: center;
}
.text-image--left .text-image-media { order: -1; }
.text-image-media { margin: 0; }
.text-image-media img { display: block; width: 100%; }
.text-image-text h2 { font-size: 1.4rem; }

/* ---------- 9.4 Brennpunkt-Ausgaben (Startseite & Archiv) ---------- */
.issues .section-title { text-align: center; }
.issues-year { margin: 3rem 0 1.25rem; font-size: 1.75rem; text-align: center; }

.issue-grid {
    display: flex; flex-wrap: wrap; justify-content: center; gap: 2rem;
    margin: 0 auto; padding: 0;
    list-style: none;
}
.issue { flex: 0 1 17rem; }                    /* Startseite */
.issues--archive .issue { flex-basis: 14rem; } /* Archiv: etwas kleiner */

.issue a   { position: relative; display: block; overflow: hidden; color: var(--text); }
.issue img { display: block; width: 100%; transition: transform .3s; }
.issue a::after {                              /* Farbverlauf beim Überfahren */
    content: "";
    position: absolute; inset: 0 0 1.75rem;
    opacity: 0; transition: opacity .3s;
    background: linear-gradient(-45deg, color-mix(in srgb, var(--accent) 55%, transparent), rgba(230,230,230,.5));
}
.issue a:hover::after { opacity: 1; }
.issue a:hover img { transform: scale(1.03); }
.issue-title { display: block; padding-top: .35rem; font-size: .9rem; text-align: center; }

/* ---------- 9.5 Personen rund (Kontakt: Vorstand) ---------- */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
    gap: 2rem;
    margin: 0 auto; padding: 0;
    list-style: none;
    text-align: center;
}
.team-member img { width: 9rem; height: 9rem; border-radius: 50%; object-fit: cover; }
.team-member h3 { margin: .75rem 0 .1rem; font-size: 1.15rem; }
.team-role { margin: 0 0 .75rem; }

/* ---------- 9.6 Spalten (z. B. Spendenmöglichkeiten) ---------- */
.column-grid { display: grid; grid-template-columns: repeat(var(--cols, 3), minmax(0, 1fr)); gap: 1.5rem; }
.column-box {
    display: flex; flex-direction: column; align-items: center;
    padding: 2rem 1.5rem;
    background: #fff;
    border-top: 4px solid var(--accent);
    box-shadow: var(--shadow-tile);
    text-align: center;
}
.section--white .column-box { background: var(--bg-light); }
.section--dark  .column-box { background: rgba(255,255,255,.08); }
.column-title { margin: 0 0 1rem; color: var(--accent-ink) !important; font-size: 1.25rem; }
.column-text  { width: 100%; }
.column-text > :last-child { margin-bottom: 0; }
.column-text .qr-code { width: min(12rem, 100%); margin: 0 auto; }
.column-text form { margin: 1rem 0 0; }

/* ---------- 9.7 Kachel-Seite (Mitarbeiter, Ressourcen) ---------- */
/* Ohne Headerbild direkt unter dem blauen Titel weiter (beide hellgrau) */
.hero--plain ~ .tiles-page { padding-top: .5rem; }

/* Einleitungstext über den Kacheln: gut lesbare Zeilenlänge */
.tiles-page .section-intro { max-width: 48rem; margin: 0 auto 2.5rem; font-size: 1.15rem; line-height: 1.65; text-align: left; }

.tile-grid { display: grid; grid-template-columns: repeat(var(--cols, 3), minmax(0, 1fr)); gap: 1.5rem; }
.tile {
    display: flex; flex-direction: column;
    background: #fff;
    border-top: 4px solid var(--accent);
    box-shadow: var(--shadow-tile);
}

/* Bild: Seitenverhältnis kommt aus dem Frontmatter (image_ratio), Standard 4:3 */
.tile-media { aspect-ratio: var(--tile-ratio, 4 / 3); overflow: hidden; background: var(--bg-light); }
.tile-media img {
    display: block;
    width: 100%; height: 100%;
    object-fit: cover; object-position: center top;
    border-radius: 0;
}
.tile-media--contain { padding: 1.25rem; }          /* image_fit: contain */
.tile-media--contain img { object-fit: contain; object-position: center; }
.tile-placeholder {                                 /* Initialen, wenn kein Bild */
    display: grid; place-items: center;
    height: 100%;
    color: var(--accent-ink);
    font-size: 3rem; font-weight: 800;
    opacity: .85;
}

/* Text: Button sitzt immer unten bündig */
.tile-body    { display: flex; flex-direction: column; flex: 1; padding: 1.5rem 1.5rem 2rem; }
.tile-title   { margin: 0 0 .75rem; color: var(--accent-ink) !important; font-size: 1.25rem; }
.tile-text    { flex: 1; font-size: .95rem; }
.tile-text > :last-child { margin-bottom: 0; }
.tile-actions { margin-top: 2rem; }


/* ==========================================================================
   10. Blog
   ========================================================================== */

.blog-teaser { margin-bottom: 2.5rem; padding-bottom: 2.5rem; border-bottom: 1px solid var(--border); }
.blog-teaser-title { margin: 0 0 .25rem; font-size: 2rem; font-weight: 400; line-height: 1.3; }
.blog-teaser-title a { color: var(--text-strong); }
.blog-teaser-title a:hover { color: var(--accent-ink); }
.blog-teaser-summary img { display: block; margin-bottom: 1rem; }
.blog-date { margin: 0 0 1rem; color: #6b6b6b; font-size: .85rem; }
.blog-post-title { margin-bottom: .25rem; color: var(--text-strong) !important; font-size: 2.3rem; font-weight: 400; }

.pagination { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 1rem; }
.pagination > * { padding: .35rem .9rem; border-radius: var(--radius-pill); }
.pagination a { box-shadow: inset 0 0 0 2px var(--accent-ink); }
.pagination a:hover { background: var(--accent-ink); color: #fff; }
.pagination .is-current { background: var(--accent-ink); color: #fff; }

/* Übersicht aller Beiträge in der Seitenleiste */
.blog-archive { margin-top: 2rem; }
.blog-archive-title { margin: 0 0 .5rem; font-size: 1.2rem; }
.blog-archive-year { margin: 1.25rem 0 .25rem; color: var(--accent-ink); font-size: 1rem; }
.blog-archive .aside-list { margin-bottom: 0; font-size: .95rem; }
.blog-archive .is-current a { color: var(--text-strong); font-weight: 700; }
.page-aside > .button:first-child { margin-bottom: .5rem; }


/* ==========================================================================
   11. Formulare (Form-Plugin)
   ========================================================================== */

.form-field { padding-bottom: 1.25rem; }
.form-label label,
.form-field > label { display: block; margin-bottom: .3rem; color: var(--text-strong); font-weight: 500; }

.form-input,
.page-content input[type=text],
.page-content input[type=email],
.page-content textarea,
.page-content select {
    width: 100%;
    padding: .6rem .8rem;
    border: 1px solid #d7d7dc;
    border-radius: .25rem;
    background: #fff;
    color: var(--text-strong);
    font: inherit;
}
.form-input:focus { outline: 2px solid var(--accent-ink); outline-offset: 1px; border-color: transparent; }

/* Auswahlkästchen: jede Option in eigener Zeile, Abstand zum Text.
   Das Formular-Plugin versteckt das echte Kästchen und malt ein Ersatzkästchen
   (dann per Tastatur nicht bedienbar) – hier wird das echte Kästchen genutzt. */
.form-field .checkboxes { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: .5rem .6rem; }
.form-field .checkboxes input[type=checkbox] {
    display: block;
    width: 1.15rem; height: 1.15rem; margin: 0;
    accent-color: var(--accent-ink);
    cursor: pointer;
}
.form-field .checkboxes label { display: block !important; margin: 0; padding: 0; cursor: pointer; }
.form-field .checkboxes label::before,
.form-field .checkboxes input[type=checkbox]:checked + label::before { content: none; display: none; }

/* Meldungen */
.form-errors,
.notices.red   { padding: .75rem 1rem; border-radius: .25rem; background: #fdecec; color: #a12a2a; }
.notices.green { padding: .75rem 1rem; border-radius: .25rem; background: #e8f7ee; color: #1f6b3a; }


/* ==========================================================================
   12. Footer
   ========================================================================== */

.site-footer {
    padding: var(--pad-y) var(--pad-x) 2rem;
    background: var(--bg-dark);
    color: var(--footer-text);
    font-size: .95rem;
    font-weight: 300;
}
.footer-columns {
    display: grid;
    grid-template-columns: 2fr 2fr 1fr 1fr;
    gap: 2rem;
    max-width: var(--content-max);
    margin: 0 auto;
}
.site-footer .footer-title { margin: 0 0 1rem; color: #fff; font-size: .95rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.site-footer p { margin: 0 0 1rem; }
.site-footer a { color: var(--footer-text); }
.site-footer a:hover { color: #fff; }
.footer-links    { margin: 0; padding: 0; list-style: none; }
.footer-links li { margin-bottom: .5rem; }
.footer-copyright { margin: 3rem 0 0; font-size: .85rem; text-align: center; }


/* ==========================================================================
   13. Kleinteile
   ========================================================================== */

/* Kopier-Button neben der IBAN */
.copy-button {
    padding: 0 0 0 .3em;
    border: 0;
    background: none;
    color: inherit;
    cursor: pointer;
    vertical-align: middle;
}
.copy-button.is-copied { color: var(--accent-ink); }

/* QR-Code auf der Spendenseite */
.qr-code { display: block; width: min(16rem, 60%); margin: 0 auto; }


/* ==========================================================================
   14. Responsiv
   ========================================================================== */

/* ---------- Tablet (bis 1024 px) ---------- */
@media (max-width: 64rem) {
    .menu-item > a { font-size: 1.1rem; }
    .card-grid     { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .tile-grid     { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .footer-columns { grid-template-columns: 1fr 1fr; }
}

/* ---------- Mobil (bis 816 px) ---------- */
@media (max-width: 51rem) {
    :root { --frame: 0px; }

    /* Kopfbereich: Logo mittig, Menü-Button rechts */
    .site-header { position: relative; justify-content: center; min-height: 6.5rem; }
    .site-logo svg,
    .site-logo img { width: 120px; height: 64px; }

    .nav-toggle {
        display: block;
        position: absolute; right: 1rem; top: 50%; z-index: 60;
        transform: translateY(-50%);
        width: 2.75rem; height: 2.75rem;
        padding: 0; border: 0;
        background: none;
        cursor: pointer;
    }
    .nav-toggle-bars,
    .nav-toggle-bars::before,
    .nav-toggle-bars::after {
        content: "";
        display: block;
        width: 1.5rem; height: 3px;
        margin: auto;
        border-radius: 2px;
        background: #fff;
        transition: .2s;
    }
    .nav-toggle-bars::before { transform: translateY(-8px); }
    .nav-toggle-bars::after  { transform: translateY(5px); }
    .nav-open .nav-toggle-bars { background: transparent; }                       /* → X */
    .nav-open .nav-toggle-bars::before { transform: translateY(0) rotate(45deg); }
    .nav-open .nav-toggle-bars::after  { transform: translateY(-3px) rotate(-45deg); }

    /* Menü klappt von rechts herein */
    .site-nav {
        position: fixed; inset: 0 0 0 auto; z-index: 50;
        width: min(18rem, 85vw);
        padding: 5rem 1.5rem 2rem;
        overflow-y: auto;
        background: var(--accent-dark);
        transform: translateX(100%);
        transition: transform .25s ease;
    }
    .nav-open .site-nav { transform: none; box-shadow: 0 0 0 100vmax rgba(0,0,0,.4); }
    .site-nav .menu { flex-direction: column; gap: 0; }
    .menu-item > a  { padding: .7rem 0; font-size: 1.5rem; }
    .submenu {
        position: static;
        padding: 0 0 .5rem 1rem;
        background: none; box-shadow: none;
        opacity: 1; visibility: visible; transform: none;
    }
    .submenu a { color: rgba(255,255,255,.7); font-size: 1.2rem; }

    /* Slideshow */
    .slider-track  { aspect-ratio: 4 / 3; }
    .slider-thumbs { position: static; justify-content: center; padding: .75rem; background: #fff; }
    .slider-thumb  { width: 4.5rem; }

    /* Alles einspaltig */
    .main-grid.has-aside,
    .intro-grid,
    .text-image-grid,
    .card-grid,
    .column-grid,
    .footer-columns { grid-template-columns: 1fr; }

    /* Kachel-Seite: auf großen Handys / kleinen Tablets noch zwei Spalten */
    .tile-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
    .tile-body { padding: 1.25rem 1.25rem 1.5rem; }

    .page-aside { padding: 0 0 1.5rem; border-right: 0; border-bottom: 1px solid var(--border); }
    .intro-content h3,
    .intro-content p { font-size: 1.3rem; }

    /* Brennpunkt: zwei Cover nebeneinander */
    .issue-grid { gap: 1rem; }
    .issue,
    .issues--archive .issue { flex-basis: calc(50% - .5rem); }

    .footer-columns { text-align: center; }
}


/* ---------- Kleine Handys (bis 600 px) ---------- */
@media (max-width: 37.5rem) {
    .tile-grid { grid-template-columns: 1fr; }
}


/* ==========================================================================
   15. Barrierefreiheit
   ========================================================================== */

/* Sichtbarer Fokus bei Tastaturbedienung */
:focus-visible { outline: 3px solid var(--accent-ink); outline-offset: 2px; }
.site-header :focus-visible,
.site-footer :focus-visible,
.slider :focus-visible,
.card :focus-visible,
.section--accent :focus-visible,
.section--anthracite :focus-visible { outline-color: #fff; }

/* Weniger Bewegung, wenn im System so eingestellt */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; }
}
