/* Große, kontrastreiche Schrift: die Zielgruppe sind überwiegend Frauen ab 60.
   Heller Modus ist Standard; der Schalter oben rechts setzt data-theme="dark" auf <html>. */
:root {
    --text: #1d1d1f;
    --muted: #55555e;
    --bg: #ebe8e1;          /* warmes Hellgrau statt reinem Weiß - weniger grell */
    --surface: #ffffff;     /* Karten heben sich davon ab */
    --border: #dcdce2;
    --accent: #2a5d8f;      /* ruhiges Vertrauensblau für Buttons, Links, Rahmen */
    --accent-text: #ffffff; /* Schrift auf --accent */
    --choice-checked: #eaf1f8;
    --notice-bg: #fffbea;
    --notice-border: #f0dc8a;
    --tile: #F5F5F5;        /* Kacheln laut Vorgabe in beiden Modi */
    --tile-text: #1d1d1f;
    --tile-muted: #55555e;
    --radius: 14px;
    color-scheme: light;
}

:root[data-theme="dark"] {
    --text: #e8e6e3;
    --muted: #a9a6a1;
    --bg: #18191b;          /* warmes Anthrazit statt reinem Schwarz */
    --surface: #222326;
    --border: #36383d;
    --accent: #7fb3d5;      /* gedämpftes Stahlblau, auf Dunkel gut lesbar */
    --accent-text: #18191b;
    --choice-checked: #1f2a33;
    --notice-bg: #262316;
    --notice-border: #5a4f22;
    color-scheme: dark;
}

* { box-sizing: border-box; }

html { font-size: 18px; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 24px; }

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

.site-header { border-bottom: 1px solid var(--border); background: var(--surface); }
.site-header .wrap { padding-top: 14px; padding-bottom: 14px; display: flex; align-items: center; justify-content: space-between; }
.brand { font-weight: 800; font-size: 1.1rem; color: var(--text); text-decoration: none; }
.brand span { color: var(--accent); }

.theme-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px; border-radius: 50%;
    border: 2px solid var(--border); background: transparent; color: var(--text); cursor: pointer;
}
.theme-toggle:hover, .theme-toggle:focus-visible { border-color: var(--accent); color: var(--accent); }
.theme-toggle svg { width: 22px; height: 22px; }
/* Zeigt das Ziel: im Dark Mode die Sonne (-> hell), im hellen Modus den Mond (-> dunkel) */
.theme-toggle .icon-moon { display: none; }
:root:not([data-theme="dark"]) .theme-toggle .icon-moon { display: block; }
:root:not([data-theme="dark"]) .theme-toggle .icon-sun { display: none; }

.hero { padding: 36px 0 12px; }
h1 { font-size: 2.1rem; line-height: 1.2; margin: 0 0 12px; }
h2 { font-size: 1.35rem; line-height: 1.3; margin: 34px 0 10px; }
.lead { font-size: 1.15rem; color: var(--muted); margin: 0; }

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
    margin: 24px 0;
}
.card h2 { margin-top: 0; }

.calculator { border-color: var(--accent); }

.field { margin: 0 0 22px; border: 0; padding: 0; }
.field label, .field legend { display: block; font-weight: 700; margin-bottom: 6px; }
.hint { margin: 0 0 10px; color: var(--muted); font-size: 0.92rem; }

.stepper { display: flex; align-items: stretch; gap: 8px; max-width: 260px; }
.stepper input {
    width: 100%; text-align: center; font-size: 1.4rem; font-weight: 700;
    border: 2px solid var(--border); border-radius: 10px; padding: 8px;
    background: var(--surface); color: var(--text);
}
.step {
    min-width: 56px; font-size: 1.6rem; font-weight: 700; line-height: 1;
    border: 2px solid var(--accent); background: transparent; color: var(--accent);
    border-radius: 10px; cursor: pointer;
}
.step:hover, .step:focus-visible { background: var(--accent); color: var(--accent-text); }

.choice {
    display: flex !important; align-items: center; gap: 12px; font-weight: 500 !important;
    padding: 12px 14px; margin: 0 0 8px; border: 2px solid var(--border); border-radius: 10px; cursor: pointer;
}
.choice input { width: 22px; height: 22px; accent-color: var(--accent); flex-shrink: 0; }
.choice:has(input:checked) { border-color: var(--accent); background: var(--choice-checked); }

select {
    font-size: 1.05rem; padding: 10px 12px; border: 2px solid var(--border); border-radius: 10px;
    background: var(--surface); color: var(--text); max-width: 100%;
}

input:focus-visible, select:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Four tiles side by side on wide screens, 2x2 / stacked below */
.results { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; margin-top: 8px; }
.tile { background: var(--tile); color: var(--tile-text); border-radius: 12px; padding: 16px; }
.tile:first-child { border-left: 6px solid var(--accent); }
.tile-label { font-size: 0.92rem; color: var(--tile-muted); font-weight: 600; }
.tile-value { font-size: 1.9rem; font-weight: 800; line-height: 1.2; margin: 4px 0; }
.tile-note { font-size: 0.8rem; color: var(--tile-muted); line-height: 1.4; }

.calc-footnote { font-size: 0.85rem; color: var(--muted); margin: 16px 0 0; }

.content ul { padding-left: 1.2em; }
.content li { margin-bottom: 8px; }

.disclaimer { background: var(--notice-bg); border-color: var(--notice-border); }

.sources { font-size: 0.92rem; }
.updated { color: var(--muted); font-size: 0.85rem; }

.site-footer { border-top: 1px solid var(--border); margin-top: 40px; background: var(--surface); }
.site-footer .wrap { padding-top: 18px; padding-bottom: 28px; display: flex; gap: 22px; }
.site-footer a { color: var(--muted); }

.legal h1 { font-size: 1.8rem; }

@media (max-width: 560px) {
    html { font-size: 17px; }
    h1 { font-size: 1.7rem; }
    .wrap { padding: 0 16px; }
    .card { padding: 20px; }
}
