/* ============================================================
   WeidauerCats – zentrales Stylesheet
   Farben, Schriften und Abstände werden hier einmal definiert
   und gelten für alle Seiten.
   ============================================================ */

:root {
    --bg: #faf5ea;            /* Seitenhintergrund (creme) */
    --card: #fffdf7;          /* Kartenhintergrund */
    --text: #3d332a;          /* Textfarbe (dunkelbraun) */
    --muted: #79695a;         /* gedämpfte Textfarbe */
    --accent: #a3622f;        /* Akzentfarbe (terracotta) */
    --accent-dark: #7c4a22;   /* dunkle Akzentfarbe */
    --line: #e7dcc8;          /* Linien und Rahmen */
    --shadow: 0 2px 10px rgba(80, 60, 30, 0.08);
    --radius: 12px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.65;
    color: var(--text);
    background: var(--bg);
}

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

a { color: var(--accent-dark); }
a:hover { color: var(--accent); }

/* Nur für Screenreader sichtbar */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

/* ------------------------------------------------------------
   Kopfbereich und Navigation
   ------------------------------------------------------------ */

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: var(--card);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.header-inner {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0.6rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.brand { text-decoration: none; color: var(--text); }

.brand-name {
    display: block;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--accent-dark);
}

.brand-sub {
    display: block;
    font-size: 0.8rem;
    color: var(--muted);
}

.site-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.15rem;
}

.site-nav a {
    display: block;
    padding: 0.45rem 0.7rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text);
}

.site-nav a:hover {
    background: var(--bg);
    color: var(--accent-dark);
}

.site-nav a[aria-current="page"] {
    background: var(--accent);
    color: #fff;
}

/* Mobiles Menü: die Checkbox ist unsichtbar, das Label dient
   als Menü-Knopf. Ganz ohne JavaScript. */
.nav-toggle { position: absolute; opacity: 0; }

.nav-toggle-label {
    display: none;
    cursor: pointer;
    padding: 0.6rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--card);
}

.nav-toggle:focus-visible ~ .nav-toggle-label {
    outline: 2px solid var(--accent);
}

.burger {
    display: block;
    position: relative;
    width: 22px;
    height: 2px;
    background: var(--text);
}

.burger::before,
.burger::after {
    content: "";
    position: absolute;
    left: 0;
    width: 22px;
    height: 2px;
    background: var(--text);
}

.burger::before { top: -7px; }
.burger::after { top: 7px; }

@media (max-width: 920px) {
    .nav-toggle-label { display: block; }

    .site-nav {
        display: none;
        width: 100%;
    }

    .nav-toggle:checked ~ .site-nav { display: block; }

    .site-nav ul {
        flex-direction: column;
        padding: 0.3rem 0 0.6rem;
    }

    .site-nav a { padding: 0.6rem 0.7rem; }
}

/* ------------------------------------------------------------
   Inhaltsbereich
   ------------------------------------------------------------ */

main {
    max-width: 1080px;
    margin: 1.5rem auto;
    padding: 0 1rem;
}

h1, h2, h3 {
    font-family: Georgia, "Times New Roman", serif;
    line-height: 1.25;
    color: var(--accent-dark);
}

h1 { font-size: clamp(1.6rem, 4vw, 2.2rem); margin: 0.2em 0 0.6em; }
h2 { font-size: clamp(1.3rem, 3vw, 1.6rem); margin: 0.3em 0 0.5em; }
h3 { font-size: 1.15rem; margin: 0.8em 0 0.4em; }

.card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.2rem 1.4rem;
    margin-bottom: 1.5rem;
}

.card > :first-child { margin-top: 0; }
.card > :last-child { margin-bottom: 0; }

.hero { margin-bottom: 1.5rem; }

.hero img {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #f8efd0;
}

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

hr {
    border: 0;
    border-top: 1px solid var(--line);
    margin: 1.5rem 0;
}

/* ------------------------------------------------------------
   Bildergalerien
   Ein Klick auf ein Bild öffnet das Original.
   ------------------------------------------------------------ */

.galerie {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 0.8rem;
    margin: 0.8rem 0;
}

.galerie--gross {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.galerie a {
    display: block;
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}

.galerie img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    transition: transform 0.25s ease;
}

.galerie a:hover img,
.galerie a:focus-visible img { transform: scale(1.04); }

.galerie figure { margin: 0; }

.galerie figcaption {
    text-align: center;
    font-size: 0.9rem;
    color: var(--muted);
    padding-top: 0.3rem;
}

/* ------------------------------------------------------------
   Katzen-Steckbriefe
   ------------------------------------------------------------ */

.katze {
    display: grid;
    grid-template-columns: 300px 1fr;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.katze .foto a { display: block; height: 100%; }

.katze .foto img {
    width: 100%;
    height: 100%;
    min-height: 240px;
    object-fit: cover;
}

.katze .info { padding: 1.2rem 1.4rem; }
.katze .info > :first-child { margin-top: 0; }
.katze .info > :last-child { margin-bottom: 0; }

.steckbrief {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.15rem 1rem;
    margin: 0.6rem 0;
}

.steckbrief dt { font-weight: 700; color: var(--muted); }
.steckbrief dd { margin: 0; }

@media (max-width: 700px) {
    .katze { grid-template-columns: 1fr; }

    .katze .foto img {
        aspect-ratio: 4 / 3;
        height: auto;
        min-height: 0;
    }
}

/* ------------------------------------------------------------
   Teaser-Kacheln (Startseite)
   ------------------------------------------------------------ */

.teaser-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.teaser-grid .card { margin-bottom: 0; }

.button {
    display: inline-block;
    margin-top: 0.6rem;
    padding: 0.5rem 1rem;
    background: var(--accent);
    color: #fff;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
}

.button:hover,
.button:focus-visible {
    background: var(--accent-dark);
    color: #fff;
}

/* ------------------------------------------------------------
   Tabellen und Linklisten
   ------------------------------------------------------------ */

table {
    border-collapse: collapse;
    width: 100%;
    margin: 0.8rem 0;
}

th, td {
    padding: 0.5rem 0.7rem;
    border-bottom: 1px solid var(--line);
    text-align: left;
}

th { color: var(--accent-dark); }

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

.link-liste li {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 0.7rem 1rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.3rem 1rem;
}

.link-liste .inhaber { color: var(--muted); }

/* ------------------------------------------------------------
   Bild-Großansicht (Lightbox) mit Zurück-Knopf
   ------------------------------------------------------------ */

.lightbox[hidden] { display: none; }

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
    background: rgba(30, 22, 14, 0.92);
}

.lightbox__back {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1.1rem;
    font: inherit;
    font-weight: 600;
    color: #fff;
    background: var(--accent);
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.lightbox__back:hover,
.lightbox__back:focus-visible {
    background: var(--accent-dark);
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.lightbox__stage {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
}

.lightbox__img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0.5);
}

/* Seiteninhalt nicht scrollen, solange die Großansicht offen ist. */
body.lightbox-open { overflow: hidden; }

/* ------------------------------------------------------------
   Fußbereich
   ------------------------------------------------------------ */

.site-footer {
    background: #40352a;
    color: #e9ddca;
    margin-top: 2.5rem;
    padding: 1.5rem 1rem;
    text-align: center;
    font-size: 0.95rem;
}

.site-footer p { margin: 0.25rem 0; }

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