/* Projekt-CRM – komplett lokal, keine externen Schriften oder CDNs */
:root {
  --navy: #1f3a5f;
  --navy-2: #2b4c77;
  --bg: #f4f6f9;
  --karte: #ffffff;
  --text: #1c2430;
  --grau: #6b7684;
  --linie: #e3e7ed;
  --akzent: #2563eb;
  --rot: #e5484d;
  --orange: #f08c00;
  --gelb: #e9c400;
  --gruen: #30a46c;
  --radius: 10px;
  --schatten: 0 1px 2px rgba(16, 24, 40, .06), 0 1px 3px rgba(16, 24, 40, .08);
}
* { box-sizing: border-box; }
html { font-size: 15px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.45; display: flex; min-height: 100vh;
}
a { color: var(--akzent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.6rem; margin: 0 0 .2rem; font-weight: 650; }
h2 { font-size: 1.02rem; margin: 0 0 .8rem; font-weight: 650; display: flex; align-items: center; gap: .5rem; }
.gedimmt { color: var(--grau); font-weight: normal; }
.klein { font-size: .85rem; }
.nowrap { white-space: nowrap; }
.rechts { text-align: right; }
.text-rot { color: var(--rot); }
.text-orange { color: var(--orange); }
.leer { color: var(--grau); font-style: italic; margin: .4rem 0; }
.inline { display: inline; }

/* ---------- Seitenleiste */
.seitenleiste {
  align-self: flex-start;
  width: 230px; flex-shrink: 0; background: var(--navy); color: #fff; padding: 1.1rem .9rem;
  display: flex; flex-direction: column; gap: 1rem; position: sticky; top: 0; height: 100vh;
}
.logo { color: inherit; font-weight: 700; font-size: 1.1rem; display: flex; align-items: center; gap: .5rem; }
.seitenleiste .logo { color: #fff; }
.logo:hover { text-decoration: none; }
.logo-punkt { width: 14px; height: 14px; border-radius: 50%; background: linear-gradient(135deg, var(--rot) 50%, var(--gruen) 50%); }
.suche input { width: 100%; background: rgba(255,255,255,.12); border: 1px solid transparent; color: #fff; }
.suche input::placeholder { color: rgba(255,255,255,.6); }
.seitenleiste nav { display: flex; flex-direction: column; gap: 2px; }
.seitenleiste nav a { color: rgba(255,255,255,.82); padding: .55rem .7rem; border-radius: 7px; display: flex; justify-content: space-between; }
.seitenleiste nav a:hover { background: rgba(255,255,255,.08); text-decoration: none; color: #fff; }
.seitenleiste nav a.aktiv { background: rgba(255,255,255,.16); color: #fff; font-weight: 600; }
.zaehler { background: var(--rot); color: #fff; border-radius: 10px; padding: 0 .45rem; font-size: .8rem; font-weight: 700; }
.nav-unten { margin-top: auto; display: flex; flex-direction: column; gap: .7rem; }
.ich { display: flex; align-items: center; gap: .5rem; font-size: .9rem; }
.ich-links { display: flex; gap: .8rem; font-size: .82rem; }
.ich-links a, .ich-links .link { color: rgba(255,255,255,.7); }
.mobil-kopf { display: none; }

main { flex: 1; padding: 1.6rem 2rem 3rem; min-width: 0; max-width: 1400px; }

/* ---------- Bausteine */
.kopfzeile { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: 1.2rem; flex-wrap: wrap; }
.knoepfe { display: flex; gap: .5rem; flex-wrap: wrap; }
.brotkrumen { font-size: .85rem; color: var(--grau); margin-bottom: .2rem; }
.karte { background: var(--karte); border-radius: var(--radius); box-shadow: var(--schatten); padding: 1.1rem 1.2rem; margin-bottom: 1.2rem; }
.karte.ohne-pad { padding: 0; }
.karte.hervor { border-left: 4px solid var(--akzent); }
.mehr { margin-left: auto; font-size: .85rem; font-weight: normal; }
.raster-2 { display: grid; grid-template-columns: 1.4fr 1fr; gap: 1.2rem; }
.raster-detail { display: grid; grid-template-columns: 1.6fr 1fr; gap: 1.2rem; }
.spalte { min-width: 0; }

.btn {
  display: inline-flex; align-items: center; gap: .3rem; background: var(--akzent); color: #fff; border: 0;
  border-radius: 7px; padding: .55rem 1rem; font: inherit; font-weight: 600; cursor: pointer; white-space: nowrap;
}
.btn:hover { filter: brightness(1.08); text-decoration: none; }
.btn-zweit { background: #fff; color: var(--text); border: 1px solid var(--linie); }
.btn-zweit:hover { background: #f7f8fa; }
.btn-aktiv { background: var(--navy); }
.btn-hell { background: rgba(255,255,255,.95); color: var(--navy); justify-content: center; }
.btn-klein { padding: .3rem .65rem; font-size: .85rem; }
.btn.voll { width: 100%; justify-content: center; padding: .7rem; }
.link { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; color: var(--akzent); }

input, select, textarea {
  font: inherit; color: inherit; padding: .5rem .65rem; border: 1px solid #cfd6df; border-radius: 7px; background: #fff; max-width: 100%;
}
input:focus, select:focus, textarea:focus { outline: 2px solid rgba(37,99,235,.35); border-color: var(--akzent); }
textarea { width: 100%; resize: vertical; }
input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--gruen); cursor: pointer; }

.meldungen { margin-bottom: 1rem; }
.meldung { padding: .7rem 1rem; border-radius: 8px; background: #e7f6ee; color: #155d3a; margin-bottom: .5rem; }
.meldung.error { background: #fdecec; color: #a01d22; }

.avatar {
  display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%;
  background: #dbe4f0; color: var(--navy); font-weight: 700; font-size: .8rem; flex-shrink: 0;
}
.seitenleiste .avatar { background: rgba(255,255,255,.2); color: #fff; }
.avatar.klein { width: 26px; height: 26px; font-size: .7rem; }
.marke { background: #eef2ff; color: #3730a3; border-radius: 5px; padding: .05rem .4rem; font-size: .75rem; font-weight: 600; }

/* ---------- Ampel */
.ampel { display: inline-block; width: 12px; height: 12px; border-radius: 50%; flex-shrink: 0; }
.ampel-rot { background: var(--rot); box-shadow: 0 0 0 3px rgba(229,72,77,.18); }
.ampel-orange { background: var(--orange); box-shadow: 0 0 0 3px rgba(240,140,0,.18); }
.ampel-gelb { background: var(--gelb); box-shadow: 0 0 0 3px rgba(233,196,0,.2); }
.ampel-gruen { background: var(--gruen); }
.ampel-grau { background: #b8c0cc; }
.ampeltext-rot { color: var(--rot); }
.ampeltext-orange { color: #c06f00; }
.ampeltext-gelb { color: #9a7d00; }
.ampeltext-gruen, .ampeltext-grau { color: var(--grau); }
.ampel-banner { display: inline-flex; align-items: center; gap: .5rem; padding: .25rem .7rem; border-radius: 20px; font-size: .88rem; font-weight: 600; margin-top: .3rem; }
.ampelbg-rot { background: #fdecec; color: #a01d22; }
.ampelbg-orange { background: #fff3e0; color: #a35d00; }
.ampelbg-gelb { background: #fdf8d8; color: #7d6500; }
.ampelbg-gruen { background: #e7f6ee; color: #155d3a; }
.ampelbg-grau { background: #eef0f3; color: var(--grau); }

/* ---------- Dashboard-Kacheln */
.kacheln { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-bottom: 1.2rem; }
.kachel { background: #fff; border-radius: var(--radius); box-shadow: var(--schatten); padding: 1rem 1.2rem; color: var(--text); border-top: 4px solid; }
.kachel:hover { text-decoration: none; transform: translateY(-1px); }
.kachel .zahl { font-size: 2rem; font-weight: 750; line-height: 1.1; }
.kachel-rot { border-color: var(--rot); } .kachel-rot .zahl { color: var(--rot); }
.kachel-orange { border-color: var(--orange); } .kachel-orange .zahl { color: var(--orange); }
.kachel-gelb { border-color: var(--gelb); } .kachel-gelb .zahl { color: #b39600; }
.kachel-gruen { border-color: var(--gruen); } .kachel-gruen .zahl { color: var(--gruen); }

/* ---------- Projektzeilen */
.pzeile { display: flex; align-items: flex-start; gap: .8rem; padding: .7rem .4rem; border-bottom: 1px solid var(--linie); color: var(--text); }
.pzeile:last-of-type { border-bottom: 0; }
.pzeile:hover { background: #f8fafc; text-decoration: none; }
.pzeile .ampel { margin-top: .35rem; }
.pzeile-haupt { flex: 1; min-width: 0; }
.pzeile-titel { font-weight: 600; }
.pzeile-info { display: flex; gap: .6rem; flex-wrap: wrap; font-size: .88rem; margin-top: .15rem; align-items: center; }
.pzeile-grund { font-size: .8rem; margin-top: .1rem; }

.phase { font-size: .76rem; font-weight: 600; padding: .1rem .5rem; border-radius: 5px; background: #eef1f5; color: #404a57; white-space: nowrap; }
.phase-anfrage { background: #eef2ff; color: #3b4bb5; }
.phase-erstbesuch { background: #e6f4ff; color: #0b5c99; }
.phase-bedarf { background: #e5f7f6; color: #0d6b66; }
.phase-labor { background: #f3ebff; color: #6a35b8; }
.phase-angebot { background: #fff3e0; color: #a35d00; }
.phase-versuch { background: #fff0f6; color: #a6246b; }
.phase-freigabe { background: #eaf7e5; color: #2f6b1b; }
.phase-gewonnen { background: #30a46c; color: #fff; }
.phase-verloren { background: #fdecec; color: #a01d22; }
.phase-pausiert { background: #eef0f3; color: var(--grau); }
.phase-bg-anfrage { background: #6b7cf2; } .phase-bg-erstbesuch { background: #3a8fd6; } .phase-bg-bedarf { background: #2aa39b; }
.phase-bg-labor { background: #8e5ad8; } .phase-bg-angebot { background: #f08c00; } .phase-bg-versuch { background: #d6458f; } .phase-bg-freigabe { background: #4f9a31; }

/* ---------- Aufgaben */
.aufgabe { display: flex; gap: .65rem; align-items: flex-start; padding: .5rem 0; border-bottom: 1px solid var(--linie); }
.aufgabe:last-child { border-bottom: 0; }
.aufgabe input { margin-top: .15rem; }
.aufgabe-titel { color: var(--text); font-weight: 500; }
.aufgabe-info { font-size: .82rem; color: var(--grau); display: flex; gap: .3rem; flex-wrap: wrap; }
.aufgabe.erledigt .aufgabe-titel { text-decoration: line-through; color: var(--grau); }
.aufgabe.ueberfaellig { background: linear-gradient(90deg, #fff5f5, transparent); }
.prio { color: var(--rot); font-weight: 800; }
.schnell-aufgabe { display: grid; grid-template-columns: 1fr 1fr 1fr auto; gap: .4rem; margin-top: .8rem; }
.schnell-aufgabe input[name=titel] { grid-column: 1 / -1; }
.schnell-aufgabe > * { min-width: 0; }
.erledigte summary { cursor: pointer; color: var(--grau); font-size: .88rem; margin-top: .8rem; }

/* ---------- Termine, Feed, Balken */
.termin, .feed { display: flex; gap: .7rem; padding: .5rem 0; border-bottom: 1px solid var(--linie); color: var(--text); font-size: .9rem; align-items: flex-start; }
.termin:last-child, .feed:last-child { border-bottom: 0; }
.termin:hover, .feed:hover { text-decoration: none; background: #f8fafc; }
.termin-datum { font-weight: 700; color: var(--navy); min-width: 72px; }
.balken-zeile { display: grid; grid-template-columns: 150px 1fr 110px; gap: .6rem; align-items: center; padding: .3rem 0; color: var(--text); font-size: .9rem; }
.balken-zeile:hover { text-decoration: none; background: #f8fafc; }
.balken { background: #eef1f5; border-radius: 4px; height: 14px; overflow: hidden; }
.balken-fuellung { display: block; height: 100%; border-radius: 4px; min-width: 2px; }
.balken-wert { text-align: right; color: var(--grau); font-size: .85rem; }

/* ---------- Projektdetail */
.phasen-leiste { display: flex; gap: 3px; margin-bottom: 1.2rem; overflow-x: auto; }
.phasen-schritt { flex: 1; text-align: center; background: #e5e9ef; color: var(--grau); padding: .45rem .4rem; font-size: .8rem; font-weight: 600; white-space: nowrap;
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 50%, calc(100% - 8px) 100%, 0 100%, 8px 50%); }
.phasen-schritt:first-child { clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 50%, calc(100% - 8px) 100%, 0 100%); border-radius: 6px 0 0 6px; }
.phasen-schritt.aktuell { background: var(--navy); color: #fff; }
.phasen-schritt.aktuell.rot { background: var(--rot); }
.schritt-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: .6rem; align-items: end; }
.schritt-form label { display: flex; flex-direction: column; gap: .25rem; font-size: .82rem; color: var(--grau); }
.schritt-form label.breit { grid-column: 1 / -1; }
.schritt-form input, .schritt-form select { color: var(--text); width: 100%; font-size: .95rem; }
.beitrag-form .zeile { display: flex; gap: .5rem; justify-content: flex-end; margin-top: .4rem; flex-wrap: wrap; align-items: center; }
.beitrag-form .zeile select { flex: 1 1 140px; max-width: 220px; }
@media (max-width: 800px) { .beitrag-form .zeile .btn { flex: 1 1 auto; justify-content: center; } }
.verlauf { margin-top: 1rem; }
.beitrag { display: flex; gap: .7rem; padding: .7rem 0; border-top: 1px solid var(--linie); }
.beitrag-inhalt { flex: 1; min-width: 0; }
.beitrag-kopf { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; font-size: .88rem; }
.beitrag-text { margin-top: .2rem; overflow-wrap: anywhere; }
.beitrag.system { opacity: .75; }
.beitrag.system .beitrag-text { font-size: .86rem; color: var(--grau); }
.beitrag.system .avatar { background: #eef0f3; color: var(--grau); }
.art { font-size: .72rem; font-weight: 600; padding: .05rem .45rem; border-radius: 5px; background: #eef1f5; }
.art-feedback { background: #e6f4ff; color: #0b5c99; }
.art-besuch { background: #eaf7e5; color: #2f6b1b; }
.art-labor { background: #f3ebff; color: #6a35b8; }
.art-telefonat, .art-email { background: #fff3e0; color: #a35d00; }
.daten { display: grid; grid-template-columns: 140px 1fr; gap: .45rem .8rem; margin: 0; font-size: .92rem; }
.daten dt { color: var(--grau); }
.daten dd { margin: 0; overflow-wrap: anywhere; }
.beschreibung { font-size: .93rem; white-space: normal; }
.datei { padding: .4rem 0; border-bottom: 1px solid var(--linie); display: flex; flex-direction: column; }
.datei-form { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .8rem; }
.datei-form input[type=file] { flex: 1 1 100%; }
.datei-form input[type=text] { flex: 1; }
.kontakt { padding: .5rem 0; border-bottom: 1px solid var(--linie); }
.kontakt:last-child { border-bottom: 0; }
.status { font-size: .75rem; font-weight: 600; padding: .1rem .5rem; border-radius: 5px; vertical-align: middle; }
.status-kunde { background: #e7f6ee; color: #155d3a; }
.status-interessent { background: #eef2ff; color: #3b4bb5; }
.status-inaktiv { background: #eef0f3; color: var(--grau); }

/* ---------- Board */
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(230px, 1fr); gap: .8rem; overflow-x: auto; padding-bottom: 1rem; }
.board-spalte { background: #e9edf2; border-radius: var(--radius); padding: .6rem; min-height: 200px; }
.board-kopf { display: flex; flex-direction: column; padding: .2rem .3rem .6rem; border-top: 4px solid; border-radius: 3px; margin-bottom: .2rem; font-size: .9rem; }
.phase-rand-anfrage { border-color: #6b7cf2; } .phase-rand-erstbesuch { border-color: #3a8fd6; } .phase-rand-bedarf { border-color: #2aa39b; }
.phase-rand-labor { border-color: #8e5ad8; } .phase-rand-angebot { border-color: #f08c00; } .phase-rand-versuch { border-color: #d6458f; } .phase-rand-freigabe { border-color: #4f9a31; }
.board-karte { display: block; background: #fff; border-radius: 8px; padding: .65rem .75rem; margin-bottom: .5rem; box-shadow: var(--schatten); color: var(--text); border-left: 4px solid; }
.board-karte:hover { text-decoration: none; transform: translateY(-1px); }
.rand-rot { border-left-color: var(--rot); } .rand-orange { border-left-color: var(--orange); } .rand-gelb { border-left-color: var(--gelb); } .rand-gruen { border-left-color: var(--gruen); }
.board-titel { font-weight: 600; font-size: .92rem; }
.board-schritt { font-size: .8rem; margin-top: .35rem; }
.board-fuss { display: flex; justify-content: space-between; align-items: center; margin-top: .45rem; font-size: .82rem; color: var(--grau); }

/* ---------- Tabellen & Filter */
.filter { display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: 1rem; }
.filter input { flex: 1; min-width: 200px; }
.tabelle-wrap { overflow-x: auto; }
.tabelle { width: 100%; border-collapse: collapse; font-size: .9rem; }
.tabelle th { text-align: left; font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; color: var(--grau); padding: .7rem .8rem; border-bottom: 1px solid var(--linie); background: #fafbfc; }
.tabelle td { padding: .65rem .8rem; border-bottom: 1px solid var(--linie); vertical-align: middle; }
.tabelle tbody tr { cursor: pointer; }
.tabelle tbody tr:hover { background: #f8fafc; }
.tabelle tr.inaktiv { opacity: .5; }

/* ---------- Formulare */
.formular { max-width: 900px; }
.felder { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem 1.2rem; }
.feld { display: flex; flex-direction: column; gap: .3rem; }
.feld.breit { grid-column: 1 / -1; }
.feld label { font-size: .85rem; font-weight: 600; color: #3b4552; }
.feld input:not([type=checkbox]), .feld select, .feld textarea { width: 100%; }
.feld-check { flex-direction: row-reverse; justify-content: flex-end; align-items: center; gap: .5rem; }
.feld.fehler input, .feld.fehler select { border-color: var(--rot); }
.formular-fuss { display: flex; gap: .6rem; margin-top: 1.3rem; align-items: center; }
.formular-fuss .link { margin-left: auto; }

/* ---------- Login */
.login-seite { align-items: center; justify-content: center; background: linear-gradient(160deg, var(--navy), #0f2340); }
.login-box { background: #fff; padding: 2rem; border-radius: 14px; width: min(380px, 92vw); display: flex; flex-direction: column; gap: .9rem; box-shadow: 0 20px 50px rgba(0,0,0,.3); }
.login-box h1 { font-size: 1.3rem; }
.login-box label { display: flex; flex-direction: column; gap: .3rem; font-size: .88rem; font-weight: 600; }
.login-box .logo { color: var(--navy); }
.hinweis { font-size: .8rem; color: var(--grau); margin: 0; text-align: center; }

/* ---------- Mobil / Tablet */
@media (max-width: 1100px) {
  .raster-2, .raster-detail { grid-template-columns: 1fr; }
}
@media (max-width: 800px) {
  body { flex-direction: column; }
  .seitenleiste { position: fixed; left: 0; top: 0; z-index: 20; transform: translateX(-100%); transition: transform .2s; box-shadow: 0 0 30px rgba(0,0,0,.3); }
  body.nav-offen .seitenleiste { transform: none; }
  .mobil-kopf { display: flex; align-items: center; gap: .8rem; background: var(--navy); color: #fff; padding: .6rem 1rem; position: sticky; top: 0; z-index: 10; }
  .mobil-kopf .logo { color: #fff; flex: 1; }
  .menue { background: none; border: 0; color: #fff; font-size: 1.4rem; cursor: pointer; }
  main { padding: 1rem; }
  .kacheln { grid-template-columns: 1fr 1fr; }
  .felder { grid-template-columns: 1fr; }
  .schritt-form { grid-template-columns: 1fr 1fr; }
  .schritt-form .btn { grid-column: 1 / -1; justify-content: center; }
  .schnell-aufgabe { grid-template-columns: 1fr 1fr; }
  .balken-zeile { grid-template-columns: 110px 1fr 90px; }
  .daten { grid-template-columns: 1fr; gap: .1rem; }
  .daten dd { margin-bottom: .5rem; }
  h1 { font-size: 1.35rem; }
}

/* ---------- KI & Schnellerfassung */
.ki-punkt { font-size: .62rem; font-weight: 800; padding: .05rem .35rem; border-radius: 4px; background: rgba(255,255,255,.15); color: rgba(255,255,255,.55); align-self: center; }
.ki-punkt.an { background: linear-gradient(135deg, #8b5cf6, #2563eb); color: #fff; }
.ki-karte { border-left: 4px solid #8b5cf6; }
.ki-karte .zeile { display: flex; gap: .5rem; justify-content: flex-end; margin-top: .4rem; }
.zf-box { background: #f5f3ff; border-radius: 8px; padding: .8rem 1rem; margin-bottom: .8rem; font-size: .93rem; }
.zf-box p { margin: 0 0 .5rem; }
.zf-box ul { margin: 0; padding-left: 1.2rem; color: #6b21a8; }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin-top: .4rem; }
.chip { background: #eef2ff; color: #3730a3; border-radius: 20px; padding: .15rem .7rem; font-size: .85rem; font-weight: 600; }
.frage-gross { display: flex; gap: .5rem; margin-bottom: 1.2rem; }
.frage-gross input { flex: 1; font-size: 1.05rem; padding: .7rem .9rem; }
.tipps ul { margin: 0; padding-left: 1.1rem; line-height: 1.8; }
.text-gruen { color: var(--gruen); }
.zeile-zwischen { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-top: .7rem; flex-wrap: wrap; }
.umschalter { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: .8rem; font-size: .92rem; }
.umschalter label, .check-label { display: inline-flex; gap: .4rem; align-items: center; cursor: pointer; font-weight: 500; }
.check-label { display: flex; margin: .3rem 0; font-size: .92rem; }
.voll-breit { width: 100%; }
.vorschlag-aufgabe { display: grid; grid-template-columns: auto 1fr 170px 150px; gap: .4rem; align-items: center; margin-bottom: .45rem; }
.vorschlag-aufgabe > * { min-width: 0; }
.original { white-space: pre-wrap; font-family: inherit; font-size: .85rem; color: var(--grau); margin: .6rem 0 0; }
.klebend { position: sticky; bottom: 0; background: var(--bg); padding: .8rem 0; border-top: 1px solid var(--linie); z-index: 5; }
.neu-marke { background: #8b5cf6; color: #fff; font-size: .68rem; padding: .05rem .35rem; border-radius: 4px; margin-left: .3rem; }
.bewertung { font-size: .75rem; font-weight: 700; padding: .1rem .5rem; border-radius: 5px; vertical-align: middle; }
.bewertung-heiss { background: #fdecec; color: #a01d22; } .bewertung-warm { background: #fff3e0; color: #a35d00; } .bewertung-kalt { background: #e6f4ff; color: #0b5c99; }
.kontakt.inaktiv { opacity: .55; }
.karte textarea + select, .karte select + textarea { margin-top: .5rem; }
@media (max-width: 800px) {
  .vorschlag-aufgabe { grid-template-columns: auto 1fr; }
  .vorschlag-aufgabe select, .vorschlag-aufgabe input[type=date] { grid-column: 2; }
}
.login-box.breit { width: min(440px, 94vw); }

/* ---------- Navigation: Verwaltung */
.seitenleiste { overflow-y: auto; }
.seitenleiste nav a { padding: .45rem .7rem; }
.nav-mehr summary { color: rgba(255,255,255,.6); padding: .45rem .7rem; cursor: pointer; font-size: .85rem; list-style: none; }
.nav-mehr summary::before { content: "▸ "; }
.nav-mehr[open] summary::before { content: "▾ "; }
.nav-mehr a { padding-left: 1.4rem; font-size: .92rem; }
.zaehler.blau { background: #3b82f6; }

/* ---------- Kalender */
.klein-abstand { margin-top: .4rem; }
.woche { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .5rem; margin-bottom: 1.2rem; }
.tag { background: #fff; border-radius: var(--radius); box-shadow: var(--schatten); padding: .5rem; min-height: 260px; }
.tag.heute { outline: 2px solid var(--akzent); }
.tag-kopf { display: flex; gap: .35rem; align-items: baseline; font-size: .9rem; margin-bottom: .4rem; color: var(--grau); }
.tag-kopf b { color: var(--text); }
.tag-plus { margin-left: auto; color: var(--grau); font-weight: 700; padding: 0 .3rem; border-radius: 4px; }
.tag-plus:hover { background: #eef2ff; text-decoration: none; }
.termin-karte { display: flex; flex-direction: column; gap: .1rem; background: #eef2ff; border-left: 3px solid var(--akzent); border-radius: 6px; padding: .35rem .45rem; margin-bottom: .35rem; color: var(--text); font-size: .85rem; }
.termin-karte:hover { text-decoration: none; filter: brightness(.97); }
.termin-karte .zeit { color: var(--grau); font-size: .78rem; }
.termin-karte.erledigt { opacity: .55; }
.termin-karte.art-besuch, .monat-termin.art-besuch { background: #eaf7e5; border-color: #4f9a31; }
.termin-karte.art-telefonat, .monat-termin.art-telefonat { background: #fff3e0; border-color: var(--orange); }
.termin-karte.art-messe, .monat-termin.art-messe { background: #f3ebff; border-color: #8e5ad8; }
.termin-karte.art-intern, .monat-termin.art-intern { background: #eef0f3; border-color: #9aa3af; }
.teilnehmer { display: flex; gap: 2px; margin-top: .15rem; }
.avatar.mini { width: 18px; height: 18px; font-size: .55rem; }
.monat-kopf, .monat-zeile { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.monat-kopf span { padding: .5rem; font-size: .8rem; color: var(--grau); font-weight: 600; border-bottom: 1px solid var(--linie); }
.monat-tag { min-height: 105px; border-right: 1px solid var(--linie); border-bottom: 1px solid var(--linie); padding: .3rem; display: flex; flex-direction: column; gap: 2px; overflow: hidden; }
.monat-tag.anders { background: #fafbfc; }
.monat-tag.anders .monat-datum { color: #b6bec9; }
.monat-tag.heute .monat-datum { background: var(--akzent); color: #fff; border-radius: 50%; width: 1.6rem; text-align: center; }
.monat-datum { font-weight: 700; font-size: .85rem; color: var(--text); }
.monat-termin { font-size: .75rem; background: #eef2ff; border-left: 3px solid var(--akzent); border-radius: 3px; padding: 1px 4px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.abo summary { cursor: pointer; }
.abo ol { padding-left: 1.2rem; }
.termin.vorbei { opacity: .6; }
.feld ul, .feld div[id^="id_teilnehmer"] { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .3rem 1rem; }
.feld div[id^="id_teilnehmer"] label { font-weight: 400; display: inline-flex; gap: .3rem; align-items: center; }

/* ---------- Muster / Labor */
.musterstatus, .angebotstatus { font-size: .72rem; font-weight: 700; padding: .12rem .5rem; border-radius: 5px; white-space: nowrap; background: #eef1f5; color: #404a57; align-self: flex-start; }
.st-angefragt { background: #eef2ff; color: #3b4bb5; } .st-unterwegs { background: #e6f4ff; color: #0b5c99; }
.st-eingegangen { background: #e5f7f6; color: #0d6b66; } .st-in_test { background: #f3ebff; color: #6a35b8; }
.st-ergebnis { background: #fff3e0; color: #a35d00; } .st-an_kunde { background: #eaf7e5; color: #2f6b1b; }
.st-abgeschlossen { background: #30a46c; color: #fff; } .st-abgebrochen { background: #fdecec; color: #a01d22; }
.status-rand-angefragt { border-color: #6b7cf2; }
.status-rand-in_test { border-color: #8e5ad8; } .status-rand-ergebnis { border-color: #f08c00; }
.status-knoepfe { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; margin-top: .6rem; }
.bewertung-positiv { color: var(--gruen); } .bewertung-teilweise { color: var(--orange); } .bewertung-negativ { color: var(--rot); }
.art-video, .art-messe, .art-intern, .art-sonstiges { background: #eef1f5; }

/* ---------- Angebote & Produkte */
.as-entwurf { background: #eef1f5; } .as-versendet { background: #e6f4ff; color: #0b5c99; }
.as-angenommen { background: #30a46c; color: #fff; } .as-abgelehnt { background: #fdecec; color: #a01d22; }
.as-ersetzt { background: #f5f5f5; color: #9aa3af; text-decoration: line-through; }
.position-form { display: flex; flex-direction: column; gap: .4rem; margin-top: .8rem; }
.position-form .zeile { display: grid; grid-template-columns: 1fr 70px 1fr auto; gap: .4rem; }
.position-form > *, .position-form .zeile > * { min-width: 0; width: 100%; }
.positionen-liste tr.summe td { border-top: 2px solid var(--linie); }
.tabelle.positionen td { padding: .35rem; vertical-align: top; }
.tabelle.positionen input, .tabelle.positionen select, .tabelle.positionen textarea { width: 100%; min-width: 70px; font-size: .88rem; padding: .35rem; }
.tabelle.positionen td:nth-child(3) { min-width: 220px; }
.tabelle.positionen textarea { margin-top: .25rem; }
.formular-breit { max-width: none; }
.fett { font-weight: 700; }
.tabelle tr.ohne-klick { cursor: default; }
.regeln input { width: 90px; }

/* ---------- Import */
.import-optionen { display: flex; gap: 1rem 1.5rem; flex-wrap: wrap; margin-bottom: .8rem; align-items: end; font-size: .88rem; }
.import-optionen label:not(.check-label) { display: flex; flex-direction: column; gap: .2rem; }
.zuordnung { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: .5rem .9rem; margin-bottom: 1rem; }
.zuordnung label { display: flex; flex-direction: column; gap: .2rem; font-size: .82rem; font-weight: 600; color: #3b4552; }
.zuordnung select.zugeordnet { border-color: var(--gruen); background: #f3fbf6; }

@media (max-width: 1000px) {
  .woche { grid-template-columns: 1fr; }
  .tag { min-height: 0; }
}
.link.text-rot { color: var(--rot); }

/* ---------- Rechte, Preise, Wettbewerb */
.meldung.nur-lesen { background: #eef2ff; color: #3730a3; }
.preis-form { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .7rem; align-items: center; }
.preis-form select { flex: 1 1 180px; min-width: 0; }
.preis-form input[name=preis] { width: 110px; }
.preis-form input[name=notiz] { flex: 1 1 140px; }
.preis-zeile { display: flex; gap: .6rem; align-items: baseline; flex-wrap: wrap; padding: .35rem 0; border-bottom: 1px solid var(--linie); font-size: .92rem; }
.preis-zeile form { margin-left: auto; }
.position-form .zeile { grid-template-columns: 1fr 1fr auto; }
.wb-form { display: flex; flex-direction: column; gap: .4rem; margin-top: .5rem; }
.wb-form .zeile2 { display: grid; grid-template-columns: 1fr 1fr; gap: .4rem; }
.wb-form .zeile2 > * { min-width: 0; width: 100%; }
.wb-form label { display: flex; flex-direction: column; gap: .2rem; }
.wb-erfassen summary { cursor: pointer; color: var(--akzent); margin-top: .5rem; }
.feld div[id^="id_team"] { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .3rem 1rem; }
.feld div[id^="id_team"] label { font-weight: 400; display: inline-flex; gap: .3rem; align-items: center; }
#positionen td:first-child { min-width: 200px; }

.version { font-size: .72rem; color: rgba(255,255,255,.4); }
.aenderungen-text { white-space: pre-wrap; font-family: inherit; font-size: .88rem; max-height: 420px; overflow: auto; background: #fafbfc; border-radius: 8px; padding: .8rem 1rem; margin: 0; }

/* ---------- KI-Assistent ---------- */
.chat { display: flex; flex-direction: column; height: calc(100vh - 190px); min-height: 420px; padding: 0; overflow: hidden; }
.chat-verlauf { flex: 1; overflow-y: auto; padding: 1.2rem; display: flex; flex-direction: column; gap: .9rem; }
.chat-start { margin: auto 0; }
.chat-beispiele { display: flex; flex-wrap: wrap; gap: .5rem; }
.chat-beispiele button { border: 1px solid var(--linie); background: var(--bg); border-radius: 999px; padding: .4rem .8rem;
  font: inherit; font-size: .9rem; cursor: pointer; color: var(--text); text-align: left; }
.chat-beispiele button:hover { border-color: var(--akzent); color: var(--akzent); }
.chat-nachricht { max-width: 82%; padding: .65rem .9rem; border-radius: 14px; }
.chat-nachricht p { margin: .25rem 0; }
.chat-nachricht ul { margin: .3rem 0; padding-left: 1.2rem; }
.chat-nachricht.nutzer { align-self: flex-end; background: var(--navy); color: #fff; border-bottom-right-radius: 4px; }
.chat-nachricht.ki { align-self: flex-start; background: var(--bg); border: 1px solid var(--linie); border-bottom-left-radius: 4px; }
.chat-denkt { animation: chat-puls 1.4s ease-in-out infinite; }
@keyframes chat-puls { 50% { opacity: .4; } }
.chat-quellen { margin-top: .6rem; padding-top: .5rem; border-top: 1px dashed var(--linie); display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; }
.chat-quellen a { font-size: .82rem; background: #fff; border: 1px solid var(--linie); border-radius: 6px; padding: .15rem .45rem; color: var(--text); }
.chat-quellen a:hover { border-color: var(--akzent); text-decoration: none; }
.chat-art { color: var(--grau); margin-right: .3rem; font-size: .75rem; text-transform: uppercase; letter-spacing: .02em; }
.chat-eingabe { display: flex; gap: .6rem; padding: .8rem; border-top: 1px solid var(--linie); background: #fff; }
.chat-eingabe textarea { flex: 1; resize: none; font: inherit; padding: .55rem .7rem; border: 1px solid var(--linie); border-radius: 8px; }
.chat-eingabe .btn { align-self: flex-end; }
@media (max-width: 800px) { .chat { height: calc(100vh - 150px); } .chat-nachricht { max-width: 95%; } }

/* ---------- Geräte einrichten / App ---------- */
.verbinden-seite { display: block; }
.verbinden { max-width: 720px; margin: 0 auto; padding: 1.5rem 1rem 3rem; }
.verbinden-kopf { display: flex; gap: 1rem; align-items: center; margin-bottom: 1rem; }
.verbinden-kopf img { border-radius: 12px; }
.verbinden .karte { margin-bottom: 1rem; }
.verbinden .einleitung { margin: .5rem 0 1rem; }
.schritt h2 { display: flex; align-items: center; gap: .5rem; }
.schritt .nr { display: inline-flex; width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--navy); color: #fff;
  align-items: center; justify-content: center; font-size: .9rem; flex: none; }
.schritt.erledigt { border-left: 4px solid var(--gruen); }
.schritt ol { padding-left: 1.2rem; } .schritt li { margin: .35rem 0; }
.geraete-wahl { display: flex; gap: .4rem; margin-bottom: 1rem; flex-wrap: wrap; }
.geraete-wahl a { padding: .35rem .8rem; border: 1px solid var(--linie); border-radius: 999px; background: #fff; color: var(--text); font-size: .9rem; }
.geraete-wahl a.aktiv { background: var(--navy); color: #fff; border-color: var(--navy); }
.qr-liste { display: flex; flex-wrap: wrap; gap: 1rem; }
.qr-liste figure { margin: 0; text-align: center; } .qr-liste svg { display: block; margin: 0 auto; }
.umbruch { word-break: break-all; }
.nav-app { color: rgba(255,255,255,.75); font-size: .85rem; }
.nav-app:hover { color: #fff; }

/* ---------- Spracheingabe ---------- */
.btn-mikro { display: inline-flex; align-items: center; gap: .45rem; border: 1px solid var(--linie); background: #fff; color: var(--text);
  border-radius: 999px; padding: .5rem 1rem; font: inherit; font-weight: 600; cursor: pointer; }
.btn-mikro:hover { border-color: var(--akzent); color: var(--akzent); }
.btn-mikro.aufnahme { background: var(--rot); border-color: var(--rot); color: #fff; }
.btn-mikro:disabled { opacity: .7; cursor: wait; }
.mikro-punkt { width: .7rem; height: .7rem; margin-right: .2rem; border-radius: 50%; background: #fff; display: inline-block; transition: transform .15s; }
.mikro-hinweis { margin-top: .4rem; color: var(--grau); }
.mikro-hinweis.warnung { color: #b45309; } .mikro-hinweis.ok { color: var(--gruen); }
.mikro-zeile { display: flex; gap: .6rem; align-items: flex-start; flex-wrap: wrap; margin: .6rem 0; }
.mikro-zeile .mikro-hinweis { flex-basis: 100%; margin-top: 0; }

/* ---------- Fehlende Angaben ---------- */
.fehlt-karte { border-left: 4px solid var(--orange); }
.fehlt-karte.komplett { border-left-color: var(--gruen); }
.fehlt-chips { display: flex; flex-wrap: wrap; gap: .35rem; margin: .4rem 0 .6rem; }
.fehlt-chips button { border: 1px solid #f3c98b; background: #fff7ed; color: #9a3412; border-radius: 999px; padding: .2rem .7rem;
  font: inherit; font-size: .85rem; cursor: pointer; }
.fehlt-chips button.wichtig { border-color: #f5a3a5; background: #fef2f2; color: #b91c1c; font-weight: 600; }
.feld-neu { animation: feld-neu 2.5s ease-out; }
@keyframes feld-neu { 0% { background: #dcfce7; box-shadow: 0 0 0 3px #86efac; } 100% { background: #fff; box-shadow: none; } }
@media (max-width: 800px) { .btn-mikro { padding: .7rem 1.1rem; } }
.chat-eingabe { flex-wrap: wrap; } .chat-eingabe .btn-mikro { align-self: flex-end; }
.chat-eingabe .mikro-hinweis { flex-basis: 100%; order: 5; }
#vpn .schritt h3 { display: flex; align-items: center; gap: .5rem; font-size: 1rem; margin: 1rem 0 .4rem; }
#vpn .schritt ol { padding-left: 1.2rem; } #vpn .schritt li { margin: .3rem 0; }
.hinweis-box { background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 8px; padding: .5rem .7rem; }
.blaettern { display: flex; gap: .8rem; align-items: center; justify-content: center; margin: 1rem 0; flex-wrap: wrap; }
.board-mehr { display: block; text-align: center; padding: .5rem; }
/* ---------- Suchfeld-Auswahl ---------- */
.such-auswahl { position: relative; }
.such-auswahl-text { width: 100%; }
.feld .such-auswahl-liste, .such-auswahl-liste { display: block; position: absolute; z-index: 30; left: 0; right: 0; top: 100%; margin: 2px 0 0; padding: .25rem 0; list-style: none;
  background: #fff; border: 1px solid var(--linie); border-radius: 8px; box-shadow: 0 6px 20px rgba(16,24,40,.12); max-height: 320px; overflow-y: auto; }
.feld .such-auswahl-liste li, .such-auswahl-liste li { display: block; width: auto; margin: 0; padding: .45rem .7rem; cursor: pointer; }
.such-auswahl-liste li.markiert, .such-auswahl-liste li:hover { background: #eef2ff; }
.such-auswahl-liste li.leer { color: var(--grau); cursor: default; background: none; }
.such-auswahl-liste[hidden] { display: none; }
.konflikt-box { border: 1px solid #f5a3a5; background: #fef2f2; border-radius: 10px; padding: .8rem 1rem; margin-bottom: 1rem; }
.konflikt-box table { background: #fff; margin: .5rem 0; }

/* ---------- Auswertungen (2.9) */
.kachel-blau { border-color: var(--akzent); } .kachel-blau .zahl { color: var(--akzent); }
.kachel .zahl { font-variant-numeric: tabular-nums; }
.legende { display: flex; flex-wrap: wrap; gap: 1rem; color: var(--grau); margin: -.3rem 0 .6rem; }
.legende .punkt { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: .35rem; vertical-align: -1px; }
.fc-commit { background: #1f7a4d; } .fc-best { background: #4fb486; } .fc-pipe { background: #b9e2cd; }
.fc-gewonnen { background: var(--gruen); } .fc-verloren { background: var(--rot); }
.tabelle.forecast td, .tabelle.forecast th { white-space: nowrap; font-variant-numeric: tabular-nums; }
.fc-balken-kopf { width: 34%; }
.fc-balken-zelle { min-width: 140px; }
.fc-balken { display: flex; height: 14px; background: #eef1f5; border-radius: 4px; overflow: hidden; }
.fc-balken span { display: block; height: 100%; }
.fc-balken span + span { border-left: 1px solid #fff; }
.tabelle tr.fc-warnung td:first-child { color: var(--rot); font-weight: 600; }
.tabelle tr.fc-rand td { color: var(--grau); }
.quartale { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: .8rem; }
.quartal { display: flex; flex-direction: column; gap: .1rem; background: #f8fafc; border: 1px solid var(--linie); border-radius: 8px; padding: .7rem .9rem; }
.zahl-gross { font-size: 1.4rem; font-weight: 750; font-variant-numeric: tabular-nums; }
.monatsbalken { display: grid; grid-template-columns: repeat(12, 1fr); gap: .35rem; align-items: end; height: 190px; padding-top: .5rem; }
.monat-saeule { display: flex; flex-direction: column; align-items: center; gap: .3rem; height: 100%; }
.saeulen { flex: 1; width: 100%; display: flex; align-items: flex-end; justify-content: center; gap: 2px; border-bottom: 1px solid var(--linie); }
.saeulen span { display: block; width: 42%; max-width: 16px; border-radius: 3px 3px 0 0; min-height: 0; }
.ziel { display: grid; grid-template-columns: 90px auto; gap: .5rem; align-items: center; }
@media (max-width: 800px) {
  .monatsbalken { height: 150px; gap: .15rem; }
  .fc-balken-zelle { min-width: 90px; }
}

/* ---------- Phasen-Board: Ziehen & Ablegen */
.board-karte[draggable="true"] { cursor: grab; }
.board-karte.zieht { opacity: .45; }
.board-spalte.ziel-aktiv { outline: 2px dashed var(--akzent); outline-offset: -4px; background: #e3ebf7; }
.board-spalte.ziel-gesperrt { opacity: .6; }
.board-karte.gespeichert { animation: board-ok 1.2s ease-out; }
@keyframes board-ok { from { box-shadow: 0 0 0 3px rgba(48,164,108,.6); } to { box-shadow: var(--schatten); } }
.board-hinweis { margin: -.6rem 0 .8rem; }

/* ===================================================================== 2.10: Laboranforderung */
.themen { display: grid; grid-template-columns: repeat(3, 1fr); gap: .7rem; }
.thema-kachel { position: relative; display: flex; flex-direction: column; gap: .25rem; padding: .9rem 1rem; border: 2px solid var(--linie);
  border-radius: var(--radius); cursor: pointer; background: #fff; transition: border-color .15s, box-shadow .15s; }
.thema-kachel input { position: absolute; opacity: 0; pointer-events: none; }
.thema-kachel b { font-size: 1rem; }
.thema-kachel::before { content: ""; width: 26px; height: 6px; border-radius: 3px; background: var(--thema, #9aa3af); margin-bottom: .2rem; }
.thema-kachel:hover { border-color: #b8c2d0; }
.thema-kachel.gewaehlt { border-color: var(--thema, var(--akzent)); box-shadow: 0 0 0 3px rgba(37, 99, 235, .12); background: #fbfcff; }
.thema-kachel:has(input:focus-visible) { outline: 2px solid var(--akzent); outline-offset: 2px; }
.thema-entlackung { --thema: #d9480f; } .thema-entfettung { --thema: #1c7ed6; } .thema-konversion { --thema: #2b8a3e; } .thema-entphosphatierung { --thema: #7048e8; }
.thema-abwasser { --thema: #0c8599; } .thema-oel { --thema: #b08800; }
.thema-marke { display: inline-block; font-size: .72rem; font-weight: 700; padding: .1rem .5rem; border-radius: 5px; color: #fff; background: var(--thema, #6b7684); vertical-align: middle; }
.filter-chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: 0 0 1rem; }
.filter-chips .chip { text-decoration: none; background: #fff; border: 1px solid var(--linie); color: var(--text); }
.filter-chips .chip[class*="thema-"] { border-left: 4px solid var(--thema); }
.filter-chips .chip.an { background: var(--navy); color: #fff; border-color: var(--navy); }
.laborform .karte { margin-bottom: 1rem; }
.felder-3 { grid-template-columns: repeat(3, 1fr); }
.ankreuzen { display: flex; flex-wrap: wrap; gap: .5rem; }
.ankreuz { display: inline-flex; align-items: center; gap: .45rem; padding: .5rem .8rem; border: 1px solid var(--linie); border-radius: 8px; cursor: pointer; font-size: .92rem; background: #fff; }
.ankreuz:has(input:checked) { border-color: var(--akzent); background: #eef4ff; }
.ankreuzen-anzeige { display: flex; flex-wrap: wrap; gap: .35rem; margin-bottom: .6rem; }
.daten-2 { grid-template-columns: 140px 1fr 140px 1fr; }
h3 { font-size: .9rem; margin: 1rem 0 .4rem; color: #3b4552; }

/* ===================================================================== 2.10: Kontakt, Berichte, Hinweise */
.kontakt-punkt { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: .4rem; vertical-align: 1px; flex: none; background: #c3cad4; }
.feed .kontakt-punkt { margin-top: .4rem; }
.kp-rot { background: var(--rot); } .kp-gruen { background: var(--gruen); } .kp-grau { background: #c3cad4; }
.kontakt-banner { display: inline-flex; align-items: center; font-size: .85rem; padding: .2rem .6rem; border-radius: 6px; background: #eef1f5; }
.kb-rot { background: #fdecec; color: #a01d22; } .kb-gruen { background: #e7f6ee; color: #155d3a; }
.schnell-kontakt { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .6rem; }
.bericht-offen { display: flex; align-items: center; gap: .5rem; border-bottom: 1px solid var(--linie); }
.bericht-offen:last-child { border-bottom: 0; }
.bericht-offen .termin { flex: 1; border-bottom: 0; }
.ziel-wahl { border: 1px solid var(--linie); border-radius: 8px; padding: .5rem .8rem; display: flex; flex-direction: column; gap: .3rem; margin: .4rem 0 .8rem; }
.glocke { position: relative; text-decoration: none; font-size: 1.1rem; margin-left: auto; }
.glocke:hover { text-decoration: none; }
.glocke .zaehler { position: absolute; top: -6px; right: -10px; font-size: .68rem; padding: 0 .35rem; }
.ich { display: flex; align-items: center; gap: .5rem; }
.hinweis.ungelesen { background: #f0f6ff; border-left: 3px solid var(--akzent); padding-left: .5rem; }
.erwaehnung-liste li.aktiv { background: #eef2ff; }
.offline-hinweis { position: fixed; left: 50%; transform: translateX(-50%); bottom: 1rem; z-index: 40; background: #1c2430; color: #fff;
  padding: .6rem 1rem; border-radius: 10px; font-size: .9rem; box-shadow: 0 4px 20px rgba(0,0,0,.25); max-width: min(560px, 92vw); }
.offline-hinweis.gesendet { background: var(--gruen); }
.entwurf-hinweis { margin-top: .2rem; }

/* + Neu-Menü */
.neu-menue { position: relative; }
.neu-menue summary { list-style: none; cursor: pointer; justify-content: center; }
.neu-menue summary::-webkit-details-marker { display: none; }
.neu-liste { position: absolute; bottom: calc(100% + 6px); left: 0; right: 0; background: #fff; border-radius: 10px; box-shadow: 0 8px 30px rgba(0,0,0,.25);
  padding: .3rem; z-index: 50; display: flex; flex-direction: column; min-width: 210px; }
.neu-liste a { color: var(--text); padding: .55rem .8rem; border-radius: 7px; font-size: .92rem; }
.neu-liste a:hover { background: #eef2ff; text-decoration: none; }

/* Untere Leiste – nur Handy */
.unten-leiste { display: none; }
@media (max-width: 800px) {
  main { padding-bottom: 5.5rem; }
  .unten-leiste { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    background: #fff; border-top: 1px solid var(--linie); padding: .25rem .2rem calc(.25rem + env(safe-area-inset-bottom)); box-shadow: 0 -2px 12px rgba(0,0,0,.06); }
  .unten-leiste > a { display: flex; flex-direction: column; align-items: center; gap: .05rem; font-size: .68rem; color: var(--grau); padding: .3rem 0; text-decoration: none; }
  .unten-leiste > a span { font-size: 1.25rem; line-height: 1.2; position: relative; }
  .unten-leiste > a.aktiv { color: var(--navy); font-weight: 700; }
  .unten-leiste .zaehler { position: absolute; top: -4px; right: -14px; font-size: .62rem; font-style: normal; padding: 0 .3rem; }
  .unten-neu summary { display: flex; align-items: center; background: var(--navy); color: #fff; border-radius: 50%; width: 48px; height: 48px;
    margin: -14px auto 0; font-size: 0; padding: 0; box-shadow: 0 4px 12px rgba(31,58,95,.35); }
  .unten-neu summary::before { content: "+"; font-size: 1.8rem; line-height: 1; margin: 0 auto; }
  .unten-neu .neu-liste { left: 50%; right: auto; transform: translateX(-50%); bottom: calc(100% + 10px); }
  .offline-hinweis { bottom: 5rem; }
  .mobil-kopf .glocke { color: #fff; margin-left: 0; }
  .themen { grid-template-columns: 1fr 1fr; }
  .felder-3, .daten-2 { grid-template-columns: 1fr; }
  /* Listen als Karten statt breiter Tabellen */
  .tabelle-wrap:has(table.karten-mobil) { overflow: visible; background: none; box-shadow: none; border: 0; }
  table.karten-mobil, table.karten-mobil tbody { display: block; }
  table.karten-mobil thead { display: none; }
  table.karten-mobil tr { display: grid; grid-template-columns: 1fr 1fr; gap: .15rem .8rem; background: #fff; border-radius: var(--radius);
    box-shadow: var(--schatten); padding: .75rem .9rem; margin-bottom: .6rem; }
  table.karten-mobil td { border: 0; padding: 0; font-size: .88rem; text-align: left; }
  table.karten-mobil td:first-child { grid-column: 1 / -1; font-size: 1rem; margin-bottom: .2rem; }
  table.karten-mobil td[data-label]:not(:first-child)::before { content: attr(data-label); display: block; font-size: .68rem; text-transform: uppercase;
    letter-spacing: .03em; color: var(--grau); }
  table.karten-mobil td.leer { grid-column: 1 / -1; }
  table.karten-mobil td:empty { display: none; }
}

/* ===================================================================== 2.10: Projektseite */
.reiter { display: flex; gap: .2rem; border-bottom: 1px solid var(--linie); margin: -.4rem 0 1.1rem; overflow-x: auto; scrollbar-width: none; }
.reiter button { border: 0; background: none; padding: .6rem .9rem; font: inherit; font-weight: 600; color: var(--grau); cursor: pointer;
  border-bottom: 3px solid transparent; white-space: nowrap; }
.reiter button:hover { color: var(--text); }
.reiter button.aktiv { color: var(--navy); border-bottom-color: var(--navy); }
.reiter-zahl { font-size: .72rem; background: #eef1f5; border-radius: 9px; padding: 0 .4rem; margin-left: .2rem; color: var(--grau); }
.mit-reitern .reiter-inhalt { display: none; }
.mit-reitern .reiter-inhalt.aktiv { display: block; }
.reiter-inhalt .karte { margin-bottom: 1.2rem; }
.verlauf-breit { max-width: 900px; }
.phasen-leiste.klickbar .phasen-schritt { border: 0; font: inherit; font-size: .8rem; font-weight: 600; cursor: pointer; }
.phasen-leiste.klickbar .phasen-schritt:not(.aktuell):hover { background: #cfd8e6; color: var(--navy); }
.phasen-leiste.klickbar .phasen-schritt:disabled { opacity: .6; cursor: wait; }
.phasen-extra { display: flex; gap: 1rem; justify-content: flex-end; margin: -.8rem 0 .8rem; }
.dialog { border: 0; border-radius: 14px; padding: 1.3rem 1.4rem; width: min(440px, 92vw); box-shadow: 0 20px 60px rgba(0,0,0,.3); }
.dialog::backdrop { background: rgba(16,24,40,.45); }
.dialog .feld { margin-bottom: .7rem; }
dl.direkt .direkt-feld { cursor: pointer; border-radius: 5px; padding: 0 .25rem; margin-left: -.25rem; }
dl.direkt .direkt-feld:hover, dl.direkt .direkt-feld:focus { background: #eef4ff; outline: 1px dashed #9db8f0; }
dl.direkt .direkt-feld::after { content: " \270E"; color: #b0b9c6; font-size: .8em; }
.direkt-eingabe { width: 100%; max-width: 260px; padding: .25rem .4rem; }
.speichert { opacity: .5; }
@media (max-width: 800px) {
  .reiter { position: sticky; top: 48px; background: var(--bg); z-index: 8; margin-left: -1rem; margin-right: -1rem; padding: 0 .6rem; }
  .phasen-extra { justify-content: flex-start; margin-top: -.6rem; }
}
@media print { .unten-leiste, .offline-hinweis { display: none !important; } }
@media (max-width: 800px) {
  table.karten-mobil tr { position: relative; }
  table.karten-mobil td.karte-ampel { position: absolute; right: .9rem; top: .85rem; margin: 0; }
  table.karten-mobil td.karte-ampel + td { grid-column: 1 / -1; font-size: 1rem; padding-right: 1.6rem; }
}
.filter label.nowrap { display: inline-flex; align-items: center; gap: .35rem; width: auto; }
.filter label.nowrap input { width: auto; margin: 0; }

/* ===================================================================== 2.10: Unterreiter (Liste/Board, Produkte, KI) */
.unterreiter { display: inline-flex; gap: .2rem; background: #e9edf3; border-radius: 9px; padding: .2rem; margin: 0 0 1rem; flex-wrap: wrap; }
.unterreiter a { padding: .35rem .9rem; border-radius: 7px; color: var(--grau); font-weight: 600; font-size: .9rem; }
.unterreiter a:hover { color: var(--text); text-decoration: none; }
.unterreiter a.aktiv { background: #fff; color: var(--navy); box-shadow: var(--schatten); }

.weitere-angaben { margin-top: 1rem; border-top: 1px solid var(--linie); padding-top: .8rem; }
.weitere-angaben > summary { cursor: pointer; font-weight: 600; color: var(--navy); margin-bottom: .8rem; }
.weitere-angaben > summary .gedimmt { font-weight: 400; margin-left: .4rem; }

/* ===================================================================== 2.11: Anmeldung mit Handy-Code */
.qr-bild { text-align: center; } .qr-bild svg { max-width: 220px; height: auto; }
.ersatzcodes { columns: 2; list-style: none; padding: 0; font-size: 1.05rem; line-height: 1.9; }
.login-seite { flex-direction: column; } .login-ab { margin-top: 1rem; }
.login-ab .link { color: #fff; }
.login-box form .btn.voll { margin-top: .8rem; }
.ohne-ki .btn-mikro { display: none; }

.thema-kachel { min-width: 0; } .thema-kachel b { overflow-wrap: anywhere; hyphens: auto; }
@media (max-width: 800px) { .bericht-offen .link, .phasen-extra .link { padding: .45rem .2rem; } .btn-klein { min-height: 36px; } }
@media (max-width: 800px) { .themen { gap: .5rem; } .thema-kachel { padding: .75rem .6rem; } .thema-kachel b { font-size: .82rem; } }

/* ===================================================================== 2.11: selbsterklärend und pflegeleicht */
.filter label.nowrap input[type=checkbox] { width: 18px; min-width: 18px; flex: none; }
.feld.auf-der-seite { display: none !important; }
.fehlt { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; background: #fff8e6; border: 1px solid #f3dfa8; border-radius: var(--radius); padding: .55rem .8rem; margin-bottom: 1rem; font-size: .9rem; }
.fehlt .chip, .fehlt-klein .chip { background: #fff; border: 1px solid #e8cf8a; color: #7a5600; text-decoration: none; }
.fehlt-klein { display: flex; flex-wrap: wrap; gap: .3rem; margin-top: .25rem; } .fehlt-klein .chip { font-size: .78rem; }
.luecke { padding: .5rem 0; border-bottom: 1px solid var(--linie); } .luecke:last-child { border-bottom: 0; } .luecke > a { color: var(--text); }
.folge { margin-top: .7rem; } .folge summary { cursor: pointer; color: var(--akzent); font-weight: 600; font-size: .92rem; }
.folge-felder { display: grid; grid-template-columns: 2fr 1fr; gap: .7rem; margin-top: .5rem; align-items: start; }
.folge-felder label, .schritt-fertig label { display: flex; flex-direction: column; gap: .25rem; font-size: .85rem; font-weight: 600; color: #3b4552; }
.schnell-datum { display: flex; flex-wrap: wrap; gap: .25rem; margin-top: .25rem; }
.schnell-datum button { border: 1px solid var(--linie); background: #fff; border-radius: 14px; padding: .15rem .55rem; font-size: .75rem; cursor: pointer; color: var(--grau); }
.schnell-datum button:hover { border-color: var(--akzent); color: var(--akzent); }
.schritt-jetzt { font-size: 1.05rem; margin: 0 0 .7rem; }
.schritt-knoepfe { display: flex; flex-wrap: wrap; gap: .5rem; align-items: flex-start; }
.schritt-auf summary { list-style: none; display: inline-flex; cursor: pointer; } .schritt-auf summary::-webkit-details-marker { display: none; }
.schritt-auf[open] { flex-basis: 100%; } .schritt-fertig, .schritt-auf .schritt-form { margin-top: .7rem; } .schritt-fertig { display: flex; flex-direction: column; gap: .6rem; }
.schritt-fertig .btn { align-self: flex-start; }
.hilfe { max-width: 760px; margin-bottom: 1rem; } .hilfe ol, .hilfe ul, .erste-schritte { line-height: 1.8; padding-left: 1.2rem; margin: 0; }
.such-auswahl-liste li.neu-anlegen { color: var(--akzent); font-weight: 600; border-top: 1px solid var(--linie); }
.person-neu { display: grid; grid-template-columns: 1fr 1fr; gap: .4rem; border: 1px solid var(--linie); border-radius: 8px; padding: .6rem; margin-top: .4rem; background: #fafbfc; }
.person-neu .btn { justify-content: center; }
@media (max-width: 800px) { .folge-felder { grid-template-columns: 1fr; } .schnell-datum button { padding: .4rem .7rem; font-size: .82rem; } }
[hidden] { display: none !important; }
.feld > .link { align-self: flex-start; }
