/* kuder.swiss – ein Stylesheet, kein Framework */

:root {
    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
    --bg: #f5f7f9;
    --bg-elev: #ffffff;
    --bg-soft: #e9eef2;
    --bg-header: rgba(245, 247, 249, 0.86);
    --text: #182028;
    --text-muted: #5a6977;
    --line: #d9e0e6;
    --accent: #1b6f86;
    --accent-strong: #135464;
    --accent-soft: #dff0f5;
    --on-accent: #ffffff;
    --orange: #d9480f;
    --green: #1f8a4c;
    --radius: 14px;
    --radius-sm: 8px;
    --shadow: 0 1px 2px rgba(16, 24, 32, .05), 0 10px 30px -16px rgba(16, 24, 32, .25);
    --maxw: 1120px;
    color-scheme: light;
}

:root[data-theme="dark"] {
    --bg: #0f151b;
    --bg-elev: #161e26;
    --bg-soft: #1c2630;
    --bg-header: rgba(15, 21, 27, 0.82);
    --text: #e6ebf0;
    --text-muted: #9aa8b4;
    --line: #27333e;
    --accent: #4cc3dd;
    --accent-strong: #7fd6e8;
    --accent-soft: #163340;
    --on-accent: #06202a;
    --orange: #ff8a50;
    --green: #5fd38d;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 30px -16px rgba(0, 0, 0, .7);
    color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --bg: #0f151b;
        --bg-elev: #161e26;
        --bg-soft: #1c2630;
        --bg-header: rgba(15, 21, 27, 0.82);
        --text: #e6ebf0;
        --text-muted: #9aa8b4;
        --line: #27333e;
        --accent: #4cc3dd;
        --accent-strong: #7fd6e8;
        --accent-soft: #163340;
        --on-accent: #06202a;
        --orange: #ff8a50;
        --green: #5fd38d;
        --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 30px -16px rgba(0, 0, 0, .7);
        color-scheme: dark;
    }
}

/* ---------- Basis ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: var(--font);
    font-size: 1.0625rem;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}
main { flex: 1; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--accent-strong); }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; font-weight: 700; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 1.4rem + 2.5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2rem); }
h3 { font-size: 1.2rem; }
h4 { font-size: 1rem; }
p { margin: 0 0 1em; }
code, pre { font-family: var(--mono); font-size: .92em; }
code { background: var(--bg-soft); padding: .1em .4em; border-radius: 5px; }
pre { background: var(--bg-soft); padding: 1rem; border-radius: var(--radius-sm); overflow: auto; border: 1px solid var(--line); }
pre code { background: none; padding: 0; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }

.container { width: min(var(--maxw), 100% - 2rem); margin-inline: auto; }
.container-narrow { width: min(780px, 100% - 2rem); margin-inline: auto; }

.icon {
    width: 1.15em; height: 1.15em;
    vertical-align: -.2em;
    fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
    flex: none;
}
.skip-link { position: absolute; left: -999px; top: 0; background: var(--accent); color: var(--on-accent); padding: .5rem 1rem; z-index: 1000; border-radius: 0 0 8px 0; }
.skip-link:focus { left: 0; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

.muted { color: var(--text-muted); }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .78rem; font-weight: 700; color: var(--accent); margin: 0 0 .6rem; }
.lead { font-size: 1.15rem; color: var(--text-muted); max-width: 62ch; }
.small { font-size: .9rem; }

/* ---------- Kopfzeile ---------- */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: var(--bg-header);
    -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    border-bottom: 1px solid transparent;
    transition: border-color .2s, box-shadow .2s;
}
.site-header.is-scrolled { border-color: var(--line); box-shadow: 0 4px 20px -14px rgba(0, 0, 0, .35); }
.header-inner { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 64px; }
.brand { font-weight: 800; font-size: 1.2rem; text-decoration: none; color: var(--text); letter-spacing: -.02em; display: inline-flex; align-items: center; gap: .55rem; }
.brand:hover { color: var(--text); }
.brand-mark { width: 30px; height: 30px; border-radius: 8px; background: var(--accent); color: var(--on-accent); display: inline-grid; place-items: center; font-size: .95rem; font-weight: 800; }
.brand .tld { color: var(--accent); }
.nav { display: flex; align-items: center; gap: .15rem; }
.nav a { text-decoration: none; color: var(--text-muted); font-weight: 500; padding: .45rem .8rem; border-radius: 999px; font-size: .95rem; white-space: nowrap; }
.nav a:hover { color: var(--text); background: var(--bg-soft); }
.nav a[aria-current="page"] { color: var(--accent); background: var(--accent-soft); }
.header-tools { display: flex; align-items: center; gap: .25rem; }
.icon-btn { background: none; border: 1px solid transparent; color: var(--text-muted); width: 40px; height: 40px; border-radius: 999px; display: inline-grid; place-items: center; cursor: pointer; }
.icon-btn:hover { background: var(--bg-soft); color: var(--text); }
.icon-btn .icon { width: 1.3em; height: 1.3em; }
.nav-toggle { display: none; }
.theme-toggle .i-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .i-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .i-moon { display: none; }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .theme-toggle .i-sun { display: block; }
    :root:not([data-theme="light"]) .theme-toggle .i-moon { display: none; }
}
@media (max-width: 900px) {
    .nav-toggle { display: inline-grid; }
    .nav {
        position: absolute; left: 0; right: 0; top: 100%;
        flex-direction: column; align-items: stretch;
        background: var(--bg-elev); border-bottom: 1px solid var(--line);
        padding: .75rem 1rem 1rem; display: none; box-shadow: var(--shadow);
    }
    .nav.is-open { display: flex; }
    .nav a { padding: .75rem 1rem; border-radius: var(--radius-sm); }
}

/* ---------- Hero ---------- */
.hero { position: relative; color: #fff; background: #10202a; isolation: isolate; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background-image: var(--hero-img, none); background-size: cover; background-position: center; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(8, 16, 22, .55) 0%, rgba(8, 16, 22, .8) 100%); }
.hero-inner { padding: clamp(4rem, 10vw, 8rem) 0 clamp(3rem, 8vw, 6rem); max-width: 780px; }
.hero .eyebrow { color: #9fe0ef; }
.hero h1 { color: #fff; margin-bottom: .4em; }
.hero .lead { color: rgba(255, 255, 255, .86); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.75rem 0 0; }
.hero-facts { list-style: none; padding: 0; margin: 2.5rem 0 0; display: flex; flex-wrap: wrap; gap: 1.25rem 2.5rem; color: rgba(255, 255, 255, .8); font-size: .92rem; }
.hero-facts strong { display: block; color: #fff; font-size: 1.45rem; font-weight: 800; line-height: 1.2; }
.hero-compact .hero-inner { padding: clamp(3rem, 7vw, 5rem) 0; }
.hero-plain { background: linear-gradient(135deg, #135464, #1b6f86); }
.hero-plain::after { background: none; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; gap: .5rem;
    padding: .7rem 1.2rem; border-radius: 999px;
    font-weight: 600; font-size: .97rem; line-height: 1.2;
    text-decoration: none; border: 1px solid transparent; cursor: pointer;
    transition: transform .15s, background .15s, color .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-strong); color: var(--on-accent); }
.btn-ghost { background: rgba(255, 255, 255, .12); color: #fff; border-color: rgba(255, 255, 255, .35); }
.btn-ghost:hover { background: rgba(255, 255, 255, .22); color: #fff; }
.btn-outline { background: transparent; color: var(--accent); border-color: var(--accent); }
.btn-outline:hover { background: var(--accent-soft); color: var(--accent); }
.btn-orange { background: #e55214; color: #fff; }
.btn-orange:hover { background: #c64510; color: #fff; }
.btn-sm { padding: .45rem .9rem; font-size: .88rem; }
.btn[aria-disabled="true"] { opacity: .55; pointer-events: none; }

/* ---------- Abschnitte ---------- */
.section { padding: clamp(3rem, 7vw, 5rem) 0; }
.section-alt { background: var(--bg-elev); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 2rem; }
.section-head h2 { margin: 0; }
.section-head p { margin: .35rem 0 0; color: var(--text-muted); max-width: 62ch; }
.section-head .more { white-space: nowrap; font-weight: 600; text-decoration: none; }

/* ---------- Raster & Karten ---------- */
.grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); }
.card {
    background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 1.5rem; box-shadow: var(--shadow);
    display: flex; flex-direction: column; gap: .5rem; position: relative;
}
.card-link { transition: transform .15s, border-color .15s; }
.card-link:hover { transform: translateY(-2px); border-color: var(--accent); }
.card h3 { margin: 0; }
.card h3 a { color: inherit; text-decoration: none; }
.card .card-cover::after { content: ""; position: absolute; inset: 0; }
.card p { margin: 0; color: var(--text-muted); }
.card .card-foot a, .card .tags, .card .link-list { position: relative; z-index: 1; }
.card-icon { width: 44px; height: 44px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; margin-bottom: .4rem; }
.card-icon .icon { width: 1.4em; height: 1.4em; }
.card-meta { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; font-size: .85rem; color: var(--text-muted); }
.card-foot { margin-top: auto; padding-top: .75rem; display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.card-img { aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-sm); margin: -.25rem 0 .5rem; width: 100%; }
.card-media { padding: 0; overflow: hidden; }
.card-media img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.card-media .card-body { padding: 1.25rem 1.5rem 1.5rem; display: flex; flex-direction: column; gap: .5rem; }
.card-body h3 { margin: 0; }
.card-body p { margin: 0; color: var(--text-muted); }

/* ---------- Tags & Badges ---------- */
.tags { display: flex; flex-wrap: wrap; gap: .4rem; list-style: none; padding: 0; margin: .25rem 0 0; }
.tag { font-size: .78rem; font-weight: 600; padding: .2rem .6rem; border-radius: 999px; background: var(--bg-soft); color: var(--text-muted); }
.badge { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: .2rem .55rem; border-radius: 6px; background: var(--bg-soft); color: var(--text-muted); vertical-align: middle; white-space: nowrap; }
.badge-live { background: rgba(31, 138, 76, .14); color: var(--green); }
.badge-beta { background: rgba(229, 82, 20, .14); color: var(--orange); }

/* ---------- Listen ---------- */
.list-clean { list-style: none; padding: 0; margin: 0; }
.link-list { list-style: none; padding: 0; margin: 0; }
.link-list li { padding: .55rem 0; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 1rem; align-items: center; flex-wrap: wrap; }
.link-list li:last-child { border-bottom: 0; }
.link-list a { text-decoration: none; font-weight: 500; display: inline-flex; align-items: center; gap: .45rem; }
.link-list a:hover { text-decoration: underline; }
.feature-list { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .5rem; }
.feature-list li { display: flex; gap: .6rem; align-items: flex-start; color: var(--text); }
.feature-list .icon { color: var(--accent); margin-top: .3em; }
.feature-list strong { font-weight: 600; }

/* ---------- Zeitstrahl ---------- */
.timeline { list-style: none; padding: 0; margin: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.timeline li { position: relative; padding: 0 0 2rem 2.25rem; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: 0; top: .4rem; width: 16px; height: 16px; border-radius: 50%; background: var(--accent); border: 3px solid var(--bg); box-shadow: 0 0 0 2px var(--accent); }
.timeline time { font-weight: 800; color: var(--accent); font-size: .95rem; letter-spacing: .04em; }
.timeline h3 { margin: .15rem 0 .25rem; font-size: 1.1rem; }
.timeline p { margin: 0; color: var(--text-muted); }
.timeline .logo { margin-top: .6rem; max-height: 48px; width: auto; background: #fff; padding: .35rem .6rem; border-radius: 8px; border: 1px solid var(--line); }

/* ---------- Artikel ---------- */
.entry-header { padding: clamp(2.5rem, 6vw, 4rem) 0 1.5rem; }
.entry-header .back { text-decoration: none; font-weight: 600; font-size: .9rem; display: inline-flex; gap: .3rem; align-items: center; margin-bottom: 1rem; }
.entry-header h1 { margin-bottom: .3em; }
.entry-meta { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; color: var(--text-muted); font-size: .92rem; margin: 0 0 1rem; }
.entry-body { padding-bottom: clamp(3rem, 7vw, 5rem); }
.prose { font-size: 1.05rem; }
.prose > :first-child { margin-top: 0; }
.prose h2 { margin-top: 2.4rem; }
.prose h3 { margin-top: 1.8rem; }
.prose ul, .prose ol { padding-left: 1.4rem; margin: 0 0 1em; }
.prose li { margin: .3rem 0; }
.prose blockquote { margin: 1.5rem 0; padding: .6rem 1.25rem; border-left: 4px solid var(--accent); background: var(--bg-elev); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; color: var(--text-muted); font-style: italic; }
.prose blockquote p:last-child { margin: 0; }
.prose img { border-radius: var(--radius-sm); }
.prose table { border-collapse: collapse; width: 100%; margin: 0 0 1em; }
.prose th, .prose td { text-align: left; padding: .5rem .6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose .grid { margin: 1.5rem 0; }
.prose .card { font-size: 1rem; }

.callout { background: var(--accent-soft); border-left: 4px solid var(--accent); padding: 1rem 1.25rem; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; margin: 1.5rem 0; }
.callout p:last-child { margin: 0; }

details.box { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--bg-elev); padding: 0 1rem; margin: 1rem 0; }
details.box summary { cursor: pointer; padding: .8rem 0; font-weight: 600; }
details.box[open] summary { border-bottom: 1px solid var(--line); margin-bottom: .75rem; }
details.box > :last-child { margin-bottom: .9rem; }

/* ---------- Diverses ---------- */
.quote-big { font-size: clamp(1.15rem, 1rem + .8vw, 1.45rem); font-weight: 500; max-width: 52ch; margin: 0; color: var(--text); }
.quote-big::before { content: "“"; color: var(--accent); font-size: 3rem; line-height: 0; vertical-align: -.35em; margin-right: .15rem; font-family: Georgia, serif; }

.kv { display: grid; grid-template-columns: auto 1fr; gap: .4rem 1rem; margin: 0; }
.kv dt { color: var(--text-muted); font-weight: 500; }
.kv dd { margin: 0; word-break: break-word; }

.cta { background: linear-gradient(135deg, #135464, #1b6f86); color: #fff; border-radius: var(--radius); padding: 2.5rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; }
.cta h2 { color: #fff; margin: 0 0 .25rem; }
.cta p { margin: 0; color: rgba(255, 255, 255, .85); max-width: 55ch; }

.stat-row { display: flex; flex-wrap: wrap; gap: 1rem 2.5rem; margin: 1.5rem 0 0; padding: 0; list-style: none; }
.stat-row strong { display: block; font-size: 1.6rem; font-weight: 800; color: var(--accent); line-height: 1.1; }
.stat-row span { color: var(--text-muted); font-size: .9rem; }

.not-found { text-align: center; padding: clamp(4rem, 12vw, 8rem) 0; }
.not-found h1 { font-size: clamp(3rem, 10vw, 6rem); color: var(--accent); margin: 0; }

/* ---------- Fusszeile ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--bg-elev); padding: 3rem 0 2rem; color: var(--text-muted); font-size: .93rem; }
.footer-grid { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.site-footer h4 { margin: 0 0 .6rem; font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--text); }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin: .3rem 0; }
.site-footer a { color: inherit; text-decoration: none; }
.site-footer a:hover { color: var(--accent); text-decoration: underline; }
.footer-bottom { margin-top: 2rem; padding-top: 1.25rem; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between; }

@media print {
    .site-header, .site-footer, .hero-actions, .skip-link { display: none; }
    body { background: #fff; color: #000; }
}
