:root {
  --grund: #f6f7f9; --flaeche: #ffffff; --text: #1d2330; --grau: #6b7280; --linie: #e3e6eb;
  --akzent: #2457c5; --akzent-hell: #e8eefb; --ok: #1b7f45; --fehler: #b42318; --warn: #8a5a00;
  --geloescht: #9aa1ab; --code: #f1f3f6;
}
@media (prefers-color-scheme: dark) {
  :root {
    --grund: #14171c; --flaeche: #1c2027; --text: #e6e8eb; --grau: #9aa1ab; --linie: #2e343d;
    --akzent: #7aa2ff; --akzent-hell: #222c42; --ok: #4fc483; --fehler: #ff7b72; --warn: #e3b341;
    --geloescht: #6b7280; --code: #232830;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--grund); color: var(--text);
  font: 15px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; }
a { color: var(--akzent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.5rem; margin: .2rem 0 .4rem; line-height: 1.25; overflow-wrap: anywhere; }
h2 { font-size: 1.15rem; margin: 0 0 .6rem; }
h3 { font-size: 1rem; margin: 1.2rem 0 .4rem; }
code, .hash { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85em; overflow-wrap: anywhere; }

.kopf { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1rem; padding: .6rem 1rem;
  background: var(--flaeche); border-bottom: 1px solid var(--linie); position: sticky; top: 0; z-index: 5; }
.kopf .marke { font-weight: 700; color: var(--text); }
.kopf nav { display: flex; gap: .9rem; align-items: center; margin-left: auto; flex-wrap: wrap; }
.suchfeld { flex: 1 1 14rem; max-width: 26rem; }
.suchfeld input { width: 100%; }
main { max-width: 1200px; margin: 0 auto; padding: 1rem; }
.fuss { max-width: 1200px; margin: 1rem auto 2rem; padding: 0 1rem; color: var(--grau); font-size: .8rem; }

input, textarea, select, button { font: inherit; color: inherit; }
input[type=search], input[type=text], input[type=password], input:not([type]), textarea {
  background: var(--flaeche); border: 1px solid var(--linie); border-radius: 6px; padding: .4rem .55rem; }
textarea { width: 100%; display: block; margin: .6rem 0 .4rem; }
button { background: var(--akzent); color: #fff; border: 0; border-radius: 6px; padding: .4rem .8rem; cursor: pointer; }
button.link { background: none; color: var(--akzent); padding: 0; }
form.inline { display: inline; }
form.neu { display: flex; gap: .5rem; margin-top: .6rem; }
form.neu input { flex: 1; min-width: 0; }

.pfad { color: var(--grau); font-size: .85rem; margin: 0; overflow-wrap: anywhere; }
.grau { color: var(--grau); }
.klein { font-size: .8rem; }
.ok { color: var(--ok); }
.fehler { color: var(--fehler); }
.herkunft { color: var(--grau); font-size: .8rem; margin: 0 0 .8rem; }
.herkunft.neu { color: var(--ok); }

.karte { background: var(--flaeche); border: 1px solid var(--linie); border-radius: 8px; padding: 1rem; margin: 0 0 1rem; min-width: 0; }
.zweispaltig { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: 1rem; align-items: start; }
@media (max-width: 860px) { .zweispaltig { grid-template-columns: 1fr; } }

.reiter { display: flex; flex-wrap: wrap; gap: .2rem; border-bottom: 1px solid var(--linie); margin: .8rem 0 1rem; }
.reiter a { padding: .45rem .75rem; border-radius: 6px 6px 0 0; color: var(--grau); }
.reiter a.an { background: var(--flaeche); color: var(--text); border: 1px solid var(--linie); border-bottom-color: var(--flaeche); margin-bottom: -1px; font-weight: 600; }
.reiter a.rechts { margin-left: auto; font-size: .85rem; }
.filter a { display: inline-block; padding: .2rem .6rem; border-radius: 999px; margin: 0 .2rem .3rem 0; }
.filter a.an { background: var(--akzent-hell); font-weight: 600; }

table.liste { width: 100%; border-collapse: collapse; background: var(--flaeche); }
.karte table.liste { background: transparent; }
table.liste th, table.liste td { text-align: left; padding: .45rem .5rem; border-bottom: 1px solid var(--linie); vertical-align: top; }
table.liste th { font-size: .8rem; color: var(--grau); font-weight: 600; white-space: nowrap; }
table.liste td { overflow-wrap: anywhere; }
.zahl { text-align: right !important; white-space: nowrap; }
tr.erledigt td:first-child a, li.erledigt a { text-decoration: line-through; color: var(--grau); }
.geloescht, tr.geloescht td, tr.geloescht a { color: var(--geloescht); }
h1.geloescht::after, tr.geloescht td:first-child::after, article.geloescht .meta::after { content: " (gelöscht)"; font-size: .8rem; }
@media (max-width: 700px) {
  table.liste thead { display: none; }
  table.liste tr { display: block; padding: .5rem 0; border-bottom: 1px solid var(--linie); }
  table.liste td { display: inline; border: 0; padding: 0 .5rem 0 0; }
  table.liste td:first-child { display: block; font-weight: 600; }
  table.liste td:empty { display: none; }
}

[class^="marke-"] { font-size: .75rem; font-weight: 600; padding: .1rem .45rem; border-radius: 999px; background: var(--code); color: var(--grau); vertical-align: middle; }

.beitrag { border-top: 1px solid var(--linie); padding: .6rem 0; }
.karte.beitrag { border-top: 1px solid var(--linie); padding: 1rem; }
.beitrag.antwort { margin-left: 1.5rem; }
@media (max-width: 700px) { .beitrag.antwort { margin-left: .5rem; } }
.beitrag .meta { color: var(--grau); font-size: .85rem; margin: 0 0 .3rem; }
.text { overflow-wrap: anywhere; }
.text img { max-width: 100%; height: auto; }
.text table { border-collapse: collapse; max-width: 100%; display: block; overflow-x: auto; }
.text td, .text th { border: 1px solid var(--linie); padding: .2rem .4rem; }
.anhaenge { font-size: .9rem; }

dl.felder { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: .3rem .8rem; margin: 0 0 1rem; }
dl.felder dt { color: var(--grau); font-size: .85rem; }
dl.felder dd { margin: 0; overflow-wrap: anywhere; }
@media (max-width: 500px) { dl.felder { grid-template-columns: 1fr; } dl.felder dd { margin-bottom: .4rem; } }

pre.json { background: var(--code); border-radius: 8px; padding: 1rem; overflow-x: auto; font-size: .8rem; max-height: 70vh; }
.meldungen { margin-bottom: 1rem; }
.meldung { padding: .55rem .8rem; border-radius: 6px; background: var(--akzent-hell); margin: 0 0 .4rem; }
.meldung.success { color: var(--ok); }
.meldung.error { color: var(--fehler); }
.meldung.warning { color: var(--warn); }

.anmelden { max-width: 22rem; margin: 3rem auto; }
.anmelden label { display: block; font-weight: 600; margin: .6rem 0 .2rem; font-size: .9rem; }
.anmelden input { width: 100%; }
.anmelden button { margin-top: 1rem; width: 100%; }
