:root {
  --hintergrund: #f6f6f4;
  --flaeche: #ffffff;
  --text: #1c1c1a;
  --leise: #6b6b66;
  --linie: #e3e3de;
  --akzent: #d6332f;
  --akzent-text: #ffffff;
  --gruen: #1f7a46;
  --gruen-hell: #e3f3ea;
  --gelb: #8a5a00;
  --gelb-hell: #fbf0d9;
  --rot: #b3261e;
  --rot-hell: #fbe4e2;
  --blau: #1e5aa8;
  --blau-hell: #e3ecf8;
  --radius: 10px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --hintergrund: #141413;
    --flaeche: #1e1e1c;
    --text: #ececea;
    --leise: #a0a09a;
    --linie: #33332f;
    --akzent: #ef5350;
    --gruen: #6fcf97;
    --gruen-hell: #173325;
    --gelb: #f2c66d;
    --gelb-hell: #3a2f14;
    --rot: #ff8a80;
    --rot-hell: #3d1a18;
    --blau: #8ab4f8;
    --blau-hell: #182a45;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--hintergrund);
  color: var(--text);
  font: 15px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

a { color: var(--blau); }
h1 { font-size: 1.6rem; margin: 0 0 1rem; }
h2 { font-size: 1.15rem; margin: 0 0 .75rem; }
code { font-size: .9em; background: var(--linie); padding: 0 .3em; border-radius: 4px; }
small { color: var(--leise); }

.kopf {
  display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.25rem;
  padding: .75rem 1rem; background: var(--flaeche); border-bottom: 1px solid var(--linie);
}
.marke { font-weight: 700; color: var(--text); text-decoration: none; }
.navigation { display: flex; flex-wrap: wrap; gap: .25rem; flex: 1; }
.navigation a, .filter a {
  padding: .35rem .7rem; border-radius: 999px; color: var(--text); text-decoration: none;
}
.navigation a[aria-current], .filter a[aria-current] { background: var(--text); color: var(--hintergrund); }
.filter { display: flex; flex-wrap: wrap; gap: .25rem; margin-bottom: 1rem; }

.inhalt { max-width: 1100px; margin: 0 auto; padding: 1.25rem 1rem 3rem; }

.karte {
  background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--radius);
  padding: 1rem 1.25rem; margin-bottom: 1.25rem;
}
.karte.schmal { max-width: 360px; margin: 4rem auto; }

.formular { display: grid; gap: .75rem; }
.formular.reihe { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); align-items: end; }
label { display: grid; gap: .3rem; font-weight: 600; font-size: .9rem; }
label.haken { display: flex; align-items: center; gap: .5rem; }
input, select, textarea {
  font: inherit; color: var(--text); background: var(--hintergrund);
  border: 1px solid var(--linie); border-radius: 8px; padding: .5rem .6rem; width: 100%;
}
input[type=checkbox] { width: auto; }
textarea { resize: vertical; font-weight: 400; }

.knopf {
  display: inline-block; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none;
  background: var(--akzent); color: var(--akzent-text); border: 0; border-radius: 8px; padding: .55rem 1rem;
}
.knopf.leise { background: transparent; color: var(--text); border: 1px solid var(--linie); padding: .3rem .7rem; }
.knopf.gefahr { background: transparent; color: var(--rot); border: 1px solid var(--rot); }
form.gefahr { margin-top: 1rem; }
.knopfgruppe { display: flex; gap: .4rem; flex-wrap: wrap; }
.knopfgruppe form { margin: 0; }

.meldung { padding: .7rem 1rem; border-radius: var(--radius); margin: 0 0 1rem; }
.meldung.ok { background: var(--gruen-hell); color: var(--gruen); }
.meldung.fehler { background: var(--rot-hell); color: var(--rot); }
.meldung.hinweis { background: var(--blau-hell); color: var(--blau); }
.leise-text { color: var(--leise); font-size: .9rem; }
.warnung { color: var(--gelb); }
.fehlertext { color: var(--rot); }

.kacheln { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.kachel {
  background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--radius);
  padding: .9rem 1rem; display: grid; gap: .1rem; color: var(--leise); font-size: .9rem;
}
.kachel .zahl { font-size: 1.7rem; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; }
.kachel.rot .zahl { color: var(--rot); }

.tabelle-rahmen { overflow-x: auto; background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { text-align: left; vertical-align: top; padding: .6rem .75rem; border-bottom: 1px solid var(--linie); }
th { color: var(--leise); font-weight: 600; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
.titel-zelle { min-width: 220px; }

.status { display: inline-block; padding: .1rem .55rem; border-radius: 999px; font-size: .8rem; font-weight: 600; white-space: nowrap; }
.status-hochgeladen { background: var(--gruen-hell); color: var(--gruen); }
.status-fehler { background: var(--rot-hell); color: var(--rot); }
.status-wartet { background: var(--gelb-hell); color: var(--gelb); }
.status-bereit, .status-laedt_hoch, .status-neu { background: var(--blau-hell); color: var(--blau); }

.etikett { display: inline-block; font-size: .8rem; padding: .05rem .5rem; border: 1px solid var(--linie); border-radius: 999px; margin: 0 .2rem .2rem 0; }
.etikett.aus { opacity: .5; text-decoration: line-through; }

.liste { list-style: none; padding: 0; margin: 0 0 1rem; }
.liste li { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; padding: .5rem 0; border-bottom: 1px solid var(--linie); }

.karte.text { max-width: 720px; }
.karte.text h2 { margin-top: 1.25rem; }
.karte.text ul { padding-left: 1.2rem; }
.fuss { text-align: center; padding: 0 1rem 2rem; font-size: .85rem; color: var(--leise); }
.fuss a { color: var(--leise); }

.kanal-kopf { display: flex; gap: .75rem; align-items: center; margin-bottom: .75rem; }
.kanal-kopf h2 { margin: 0; }
.rund { border-radius: 50%; }
