/* prolife — Oberflaeche.
   Eine Spalte, grosse Trefferflaechen, lesbar auf dem Handy: Jonas schaut das
   unterwegs an, nicht am Schreibtisch. Keine Fremdschrift und kein Fremdskript
   — die CSP der Caddy-Konfiguration laesst nur eigene Dateien zu. */

:root {
  --grund: #fbfaf8;
  --karte: #ffffff;
  --linie: #e6e2dc;
  --text: #1e1c1a;
  --leise: #6f6a63;
  --akzent: #e07a1f;         /* PLE-Orange */
  --akzent-hell: #fdf2e5;
  --warm: #2e9e5b;
  --lau: #d69a1a;
  --kalt: #c8462f;
  --radius: 10px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --grund: #171614;
    --karte: #201e1b;
    --linie: #35322d;
    --text: #f0ece6;
    --leise: #a29c93;
    --akzent: #f59440;
    --akzent-hell: #322415;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--grund);
  color: var(--text);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-text-size-adjust: 100%;
}

/* ── Anmeldung ───────────────────────────────────────────────────────────── */

#tor { display: grid; place-items: center; min-height: 100vh; padding: 1.5rem; }
#anmelde-form {
  background: var(--karte); border: 1px solid var(--linie); border-radius: var(--radius);
  padding: 2rem; width: 100%; max-width: 22rem; text-align: center;
}
#anmelde-form h1 { margin: 0; font-size: 1.6rem; letter-spacing: -0.02em; }
#anmelde-form input {
  width: 100%; margin: 1.2rem 0 0.8rem; padding: 0.7rem 0.8rem; font-size: 1rem;
  border: 1px solid var(--linie); border-radius: 8px; background: var(--grund); color: var(--text);
}
#anmelde-form button {
  width: 100%; padding: 0.7rem; font-size: 1rem; font-weight: 600;
  background: var(--akzent); color: #fff; border: 0; border-radius: 8px; cursor: pointer;
}

/* ── Rahmen ──────────────────────────────────────────────────────────────── */

header {
  display: flex; align-items: center; gap: 1rem; flex-wrap: wrap;
  padding: 0.8rem 1rem; background: var(--karte); border-bottom: 1px solid var(--linie);
  position: sticky; top: 0; z-index: 10;
}
.marke { font-weight: 700; text-decoration: none; color: var(--text); letter-spacing: -0.02em; }
.marke span { color: var(--akzent); }
header nav { display: flex; gap: 0.2rem; flex-wrap: wrap; flex: 1; }
header nav a {
  padding: 0.35rem 0.6rem; border-radius: 6px; text-decoration: none;
  color: var(--leise); font-size: 0.92rem;
}
header nav a:hover { background: var(--akzent-hell); color: var(--akzent); }
header nav a.aktiv { background: var(--akzent-hell); color: var(--akzent); font-weight: 600; }

main { max-width: 62rem; margin: 0 auto; padding: 1.2rem 1rem 4rem; }

footer {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 0.6rem 1rem; border-top: 1px solid var(--linie); background: var(--karte);
  font-size: 0.85rem; flex-wrap: wrap;
}

/* ── Bausteine ───────────────────────────────────────────────────────────── */

h2 { font-size: 1.25rem; margin: 1.6rem 0 0.7rem; letter-spacing: -0.01em; }
h2:first-child { margin-top: 0; }
h3 { font-size: 1.05rem; margin: 1.2rem 0 0.5rem; }
a { color: var(--akzent); }
.leise { color: var(--leise); }
.fehler { color: var(--kalt); }
.klein { font-size: 0.85rem; }

.karte {
  background: var(--karte); border: 1px solid var(--linie); border-radius: var(--radius);
  padding: 0.9rem 1rem; margin-bottom: 0.7rem;
}
.karte-kopf { display: flex; align-items: baseline; gap: 0.6rem; flex-wrap: wrap; }
.karte-kopf h3 { margin: 0; }
.karte a.titel { text-decoration: none; font-weight: 600; color: var(--text); }
.karte a.titel:hover { color: var(--akzent); }

.gitter { display: grid; gap: 0.7rem; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); }

.pille {
  display: inline-block; padding: 0.1rem 0.5rem; border-radius: 999px;
  font-size: 0.75rem; font-weight: 600; background: var(--akzent-hell); color: var(--akzent);
  white-space: nowrap;
}
.pille.grau { background: var(--linie); color: var(--leise); }
.pille.warm { background: #e4f5ea; color: var(--warm); }
.pille.lau  { background: #fbf1d8; color: var(--lau); }
.pille.kalt { background: #fbe6e2; color: var(--kalt); }
.pille.ja   { background: #e4f5ea; color: var(--warm); }
.pille.nein { background: #fbe6e2; color: var(--kalt); }

@media (prefers-color-scheme: dark) {
  .pille.warm { background: #16301f; } .pille.lau { background: #322a12; }
  .pille.kalt { background: #351a15; } .pille.ja { background: #16301f; }
  .pille.nein { background: #351a15; }
}

/* Balken fuer Ziele */
.balken { height: 6px; background: var(--linie); border-radius: 999px; overflow: hidden; margin-top: 0.4rem; }
.balken > i { display: block; height: 100%; background: var(--akzent); }

/* Leiter der Onboarding-Stufen */
.leiter { display: flex; gap: 2px; margin: 0.4rem 0; }
.leiter > i {
  flex: 1; height: 5px; background: var(--linie); border-radius: 2px;
}
.leiter > i.voll { background: var(--akzent); }

table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
th, td { text-align: left; padding: 0.45rem 0.5rem; border-bottom: 1px solid var(--linie); vertical-align: top; }
th { color: var(--leise); font-weight: 600; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.03em; }
td.rechts, th.rechts { text-align: right; }
.tabellen-huelle { overflow-x: auto; }

button, .knopf {
  font: inherit; padding: 0.4rem 0.75rem; border-radius: 7px; border: 1px solid var(--linie);
  background: var(--karte); color: var(--text); cursor: pointer;
}
button:hover { border-color: var(--akzent); color: var(--akzent); }
button.haupt { background: var(--akzent); color: #fff; border-color: var(--akzent); font-weight: 600; }
button.haupt:hover { filter: brightness(1.08); color: #fff; }
.leise-knopf { border: 0; background: none; color: var(--leise); padding: 0.3rem 0.4rem; }

input, select, textarea {
  font: inherit; padding: 0.45rem 0.55rem; border: 1px solid var(--linie); border-radius: 7px;
  background: var(--grund); color: var(--text); width: 100%; max-width: 100%;
}
textarea { min-height: 4.5rem; resize: vertical; }
label { display: block; margin-bottom: 0.6rem; }
label > span { display: block; font-size: 0.8rem; color: var(--leise); margin-bottom: 0.15rem; }
.feld-reihe { display: grid; gap: 0.6rem; grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); }

.werkzeuge { display: flex; gap: 0.5rem; flex-wrap: wrap; align-items: center; margin-bottom: 0.9rem; }

.hinweis {
  border-left: 3px solid var(--akzent); background: var(--akzent-hell);
  padding: 0.6rem 0.8rem; border-radius: 0 var(--radius) var(--radius) 0; margin-bottom: 0.7rem;
  font-size: 0.92rem;
}
.hinweis.warn { border-color: var(--kalt); background: #fbe6e2; }
@media (prefers-color-scheme: dark) { .hinweis.warn { background: #351a15; } }

.zurueck { display: inline-block; margin-bottom: 0.8rem; font-size: 0.9rem; text-decoration: none; }

.rollen-wahl { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.rollen-wahl label {
  display: inline-flex; align-items: center; gap: 0.35rem; margin: 0;
  border: 1px solid var(--linie); border-radius: 999px; padding: 0.25rem 0.6rem;
  font-size: 0.85rem; cursor: pointer; width: auto;
}
.rollen-wahl input { width: auto; }
.rollen-wahl label:has(input:checked) { border-color: var(--akzent); color: var(--akzent); background: var(--akzent-hell); }
