/* Kommandozentrale: eigenes, neutrales Design. Dunkel, ruhig, datenbetont. */
:root {
  --grund: #0f1115;
  --karte: #171a21;
  --karte-hell: #1e222b;
  --linie: #2a2f3a;
  --text: #e6e9ee;
  --gedimmt: #9aa3b2;
  --akzent: #4fd1a5;
  --warn: #e0b45a;
  --fehler: #e07a6a;
  /* Bereichsfarben */
  --c-optikam: #5aa7e0;
  --c-fred: #b48ae0;
  --c-rolls: #7ed07e;
  --c-privat: #e0a45a;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--grund);
  color: var(--text);
  min-height: 100svh;
  font-size: 15px;
  line-height: 1.5;
}
a { color: var(--akzent); text-decoration: none; }
a:hover { text-decoration: underline; }

.kopf {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px clamp(16px, 4vw, 40px);
  border-bottom: 1px solid var(--linie);
  position: sticky;
  top: 0;
  background: rgba(15, 17, 21, 0.92);
  backdrop-filter: blur(8px);
  z-index: 10;
}
.kopf .logo {
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text);
  white-space: nowrap;
}
.kopf .logo b { color: var(--akzent); }
.kopf nav { display: flex; gap: 4px; flex-wrap: wrap; margin-left: auto; }
.kopf nav a {
  color: var(--gedimmt);
  padding: 6px 12px;
  border-radius: 7px;
  font-size: 0.93rem;
}
.kopf nav a:hover { background: var(--karte-hell); color: var(--text); text-decoration: none; }
.kopf nav a.aktiv { background: var(--karte-hell); color: var(--text); }

main { max-width: 1060px; margin: 0 auto; padding: 30px clamp(16px, 4vw, 40px) 70px; }
h1 { font-size: 1.5rem; letter-spacing: 0.01em; margin-bottom: 4px; }
.untertitel { color: var(--gedimmt); margin-bottom: 26px; }

.bereich-marke {
  display: inline-block;
  width: 10px; height: 10px;
  border-radius: 3px;
  margin-right: 8px;
}

/* Kartenraster */
.raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.karte {
  background: var(--karte);
  border: 1px solid var(--linie);
  border-radius: 12px;
  padding: 18px 20px;
}
.karte.klickbar { display: block; color: inherit; transition: border-color 120ms ease-out, transform 120ms ease-out; }
.karte.klickbar:hover { border-color: var(--akzent); text-decoration: none; transform: translateY(-2px); }
.karte h2 { font-size: 1.05rem; margin-bottom: 4px; display: flex; align-items: center; }
.karte h3 { font-size: 0.98rem; margin-bottom: 8px; }
.karte .beschreibung { color: var(--gedimmt); font-size: 0.9rem; margin-bottom: 12px; }
.karte .zahlen { display: flex; gap: 20px; flex-wrap: wrap; }
.zahl .wert { font-size: 1.5rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.zahl .label { font-size: 0.78rem; color: var(--gedimmt); text-transform: uppercase; letter-spacing: 0.05em; }
.badge {
  display: inline-block;
  font-size: 0.75rem;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--karte-hell);
  color: var(--gedimmt);
  border: 1px solid var(--linie);
}
.badge.geplant { opacity: 0.7; }
.badge.offen { background: rgba(224, 180, 90, 0.15); color: var(--warn); border-color: rgba(224, 180, 90, 0.4); }
.badge.ok { background: rgba(79, 209, 165, 0.12); color: var(--akzent); border-color: rgba(79, 209, 165, 0.35); }
.badge.fehler { background: rgba(224, 122, 106, 0.12); color: var(--fehler); border-color: rgba(224, 122, 106, 0.4); }

/* Briefing */
.briefing {
  background: var(--karte);
  border: 1px solid var(--linie);
  border-left: 3px solid var(--akzent);
  border-radius: 12px;
  padding: 20px 24px;
  margin-bottom: 26px;
}
.briefing .meta { color: var(--gedimmt); font-size: 0.82rem; margin-bottom: 10px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.briefing-inhalt { line-height: 1.65; }
.briefing-inhalt h2 { font-size: 1rem; margin: 14px 0 6px; color: var(--akzent); }
.briefing-inhalt h2:first-child { margin-top: 0; }
.briefing-inhalt ul { padding-left: 20px; }
.briefing-inhalt strong { color: var(--text); }
.briefing-inhalt p { margin-bottom: 8px; }

/* Agent-Leiste */
.agent-leiste { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.knopf {
  font: inherit;
  font-size: 0.9rem;
  background: var(--karte-hell);
  color: var(--text);
  border: 1px solid var(--linie);
  border-radius: 8px;
  padding: 7px 14px;
  cursor: pointer;
}
.knopf:hover { border-color: var(--akzent); }
.knopf.primaer { background: var(--akzent); color: #0c2018; border-color: var(--akzent); font-weight: 600; }
.knopf.primaer:hover { filter: brightness(1.1); }
.knopf[disabled] { opacity: 0.5; cursor: default; }

/* Tabellen */
.tabelle-halter { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
th {
  text-align: left;
  color: var(--gedimmt);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 8px 10px;
  border-bottom: 1px solid var(--linie);
  white-space: nowrap;
}
td { padding: 9px 10px; border-bottom: 1px solid var(--linie); vertical-align: top; }
tr:last-child td { border-bottom: none; }
td.num { font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Sektionen */
.sektion { margin-top: 34px; }
.sektion-kopf { display: flex; align-items: baseline; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.sektion-kopf h2 { font-size: 1.15rem; }
.sektion-kopf .hinweis { color: var(--gedimmt); font-size: 0.85rem; }

/* Notizen */
.notiz-form { display: flex; gap: 10px; margin-bottom: 14px; }
.notiz-form input {
  flex: 1;
  font: inherit;
  background: var(--karte);
  color: var(--text);
  border: 1px solid var(--linie);
  border-radius: 8px;
  padding: 9px 12px;
}
.notiz-form input:focus { outline: none; border-color: var(--akzent); }
.notiz { padding: 10px 2px; border-bottom: 1px solid var(--linie); display: flex; gap: 12px; justify-content: space-between; }
.notiz .wann { color: var(--gedimmt); font-size: 0.8rem; white-space: nowrap; }

.leer { color: var(--gedimmt); padding: 14px 0; }
.fehler-text { color: var(--fehler); }
