:root {
  color-scheme: light dark;
  --bg: #f6f7f5;
  --karte: #ffffff;
  --text: #1d2321;
  --leise: #5c6663;
  --linie: #d9dedb;
  --akzent: #2f6f5e;
  --akzent-text: #ffffff;
  --fehler: #b3261e;
  --ok: #2f6f5e;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14181a;
    --karte: #1d2326;
    --text: #e8ecea;
    --leise: #9aa5a1;
    --linie: #333c3f;
    --akzent: #6fc2a8;
    --akzent-text: #0c1512;
    --fehler: #ff8a80;
    --ok: #6fc2a8;
  }
}
* { box-sizing: border-box; }
html { font-size: 17px; }
body { margin: 0; background: var(--bg); color: var(--text); line-height: 1.5; }
[hidden] { display: none !important; }
a { color: var(--akzent); }
h1 { font-size: 1.5rem; margin: 0 0 1rem; }
h2 { font-size: 1.15rem; margin: 0 0 .75rem; }

.kopf { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; padding: .5rem 1rem; background: var(--karte); border-bottom: 1px solid var(--linie); position: sticky; top: 0; z-index: 2; }
.marke { font-weight: 700; }
.nav { display: flex; gap: .25rem; overflow-x: auto; flex: 1; }
.nav a { display: inline-flex; align-items: center; min-height: 48px; padding: 0 1rem; border-radius: .6rem; color: var(--text); text-decoration: none; white-space: nowrap; }
.nav a[aria-current="page"] { background: var(--akzent); color: var(--akzent-text); }
.inhalt { max-width: 46rem; margin: 0 auto; padding: 1rem; }
.zentriert { max-width: 26rem; margin: 8vh auto 0; padding: 1rem; }

.karte { background: var(--karte); border: 1px solid var(--linie); border-radius: .9rem; padding: 1rem; margin-bottom: 1rem; }
.feld { display: flex; flex-direction: column; gap: .25rem; margin-bottom: .9rem; }
.feld label { font-weight: 600; }
input, select { font: inherit; color: inherit; background: var(--bg); border: 1px solid var(--linie); border-radius: .6rem; min-height: 48px; padding: 0 .8rem; width: 100%; }
input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible, button:focus-visible, a:focus-visible { outline: 3px solid var(--akzent); outline-offset: 2px; }
[tabindex="-1"]:focus, [tabindex="-1"]:focus-visible { outline: none; }
input[type="checkbox"] { width: 24px; min-height: 24px; height: 24px; }

.knopf { font: inherit; font-weight: 600; min-height: 48px; padding: 0 1.25rem; border: 0; border-radius: .6rem; background: var(--akzent); color: var(--akzent-text); cursor: pointer; }
.knopf.zweit { background: transparent; color: var(--akzent); border: 1px solid var(--akzent); }
.knopf.gefahr { background: transparent; color: var(--fehler); border: 1px solid var(--fehler); }
.knopf[disabled] { opacity: .6; cursor: default; }
.knopf.voll { width: 100%; }

.meldung { margin: .5rem 0 1rem; padding: .7rem .9rem; border-radius: .6rem; border: 1px solid var(--linie); }
.meldung.fehler { color: var(--fehler); border-color: var(--fehler); }
.meldung.ok { color: var(--ok); border-color: var(--ok); }
.leise { color: var(--leise); font-size: .9rem; }

.zeile { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; justify-content: space-between; }
.modulwahl { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; margin: .75rem 0; }
.modulwahl label { display: inline-flex; align-items: center; gap: .5rem; min-height: 48px; }
.aktionen { display: flex; flex-wrap: wrap; gap: .5rem; }
.plakette { display: inline-block; padding: 0 .6rem; border-radius: 1rem; border: 1px solid var(--linie); font-size: .85rem; color: var(--leise); }
pre.mail { white-space: pre-wrap; word-break: break-word; background: var(--bg); border: 1px solid var(--linie); border-radius: .6rem; padding: .8rem; overflow-x: auto; }

.kacheln { display: grid; grid-template-columns: 1fr; gap: 1rem; }
.kacheln .kachel { margin-bottom: 0; }
.kachel h3 { font-size: 1rem; margin: .75rem 0 .35rem; }
.terminliste { margin: 0 0 .75rem; padding-left: 1.1rem; }
.terminliste li { margin-bottom: .35rem; }
@media (min-width: 640px) { .kacheln { grid-template-columns: 1fr 1fr; } }
