/* IHK Veranstaltungsplattform. Work Sans als Hausschrift, lokal eingebunden.
   Keine externen Ressourcen, keine fremden Schriftdienste. */
@font-face {
  font-family: "Work Sans";
  src: url("fonts/WorkSans-Variable.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
:root {
  --blau: #0b2545;
  --blau-hell: #14406e;
  --text: #16202e;
  --text-leise: #5b6779;
  --linie: #e3e7ee;
  --linie-stark: #ccd3de;
  --flaeche: #f5f6f9;
  --karte: #ffffff;
  --akzent: #1b4ed8;
  --akzent-dunkel: #1440b4;
  --akzent-flaeche: #eef2ff;
  --gruen: #15633f;
  --gruen-flaeche: #dcf5e8;
  --rot: #9b1c1c;
  --rot-flaeche: #fdeaea;
  --gelb: #8a5200;
  --gelb-flaeche: #fdf1dc;
  --radius: 12px;
  --radius-klein: 8px;
  --schatten: 0 1px 2px rgba(16, 24, 40, .04), 0 1px 3px rgba(16, 24, 40, .06);
  --schatten-hoch: 0 4px 12px rgba(16, 24, 40, .08);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Work Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--text);
  background: var(--flaeche);
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: tabular-nums;
}
a { color: var(--akzent); text-underline-offset: 2px; }
a:hover { color: var(--akzent-dunkel); }
button:not(:disabled), [role="button"]:not([aria-disabled="true"]), a[href], label[for], select, input[type="checkbox"] { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .6; }

.kopf {
  background: var(--blau);
  color: #fff;
  padding: 12px 24px;
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, .08);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
}
.kopf .marke { font-weight: 600; font-size: 17px; letter-spacing: -.01em; color: #fff; text-decoration: none; margin-right: auto; }
.kopf nav { display: flex; flex-wrap: wrap; gap: 2px; min-width: 0; }
.kopf nav a { color: rgba(255, 255, 255, .82); font-size: 14.5px; text-decoration: none; padding: 7px 11px; border-radius: 8px; white-space: nowrap; }
.kopf nav a:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.kopf nav a[aria-current="page"] { background: rgba(255, 255, 255, .16); color: #fff; font-weight: 500; }
.kopf .konto { display: flex; align-items: center; gap: 10px; font-size: 14px; white-space: nowrap; }
.kopf .konto form { margin: 0; }
.kopf .konto a { color: #fff; text-decoration: none; padding: 6px 10px; border-radius: 6px; }
.kopf .konto a:hover, .kopf .konto a[aria-current="page"] { background: rgba(255, 255, 255, .15); }
.kopf .konto button { background: rgba(255, 255, 255, .15); color: #fff; border: 0; padding: 6px 12px; border-radius: 6px; font: inherit; }
.kopf .konto button:hover { background: rgba(255, 255, 255, .25); }
/* Protokoll, Einstellungen und Abmelden als Symbole: gleiche Fläche, Beschriftung über title und aria-label. */
.kopf .konto { gap: 4px; }
.kopf .konto > a:first-child { margin-right: 6px; }
.kopf .konto .symbol { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; padding: 0; border-radius: 8px; background: transparent; color: rgba(255, 255, 255, .82); line-height: 0; vertical-align: middle; }
.kopf .konto .symbol:hover { background: rgba(255, 255, 255, .15); color: #fff; }
.kopf .konto .symbol[aria-current="page"] { background: rgba(255, 255, 255, .16); color: #fff; }
.kopf .konto .symbol:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.kopf .konto .symbol svg { display: block; }
/* Hauslogo ganz rechts. Auf der Anmeldeseite rückt es an die Stelle der Navigation. */
.hauslogo { display: flex; align-items: center; margin-left: 18px; opacity: .85; flex: 0 0 auto; }
.hauslogo:hover { opacity: 1; }
.hauslogo img { display: block; height: 20px; width: auto; }
/* Ab Tablet bleibt die Kopfzeile eine Zeile, damit das Hauslogo rechts oben steht. */
@media (min-width: 860px) { .kopf { flex-wrap: nowrap; } }
.kopf .marke { margin-right: auto; }

.knopf-mitte { display: flex; justify-content: center; }
.knopf.breit { min-width: 240px; text-align: center; }

main { max-width: 1140px; margin: 0 auto; padding: 32px 20px 64px; }
h1 { font-size: 27px; margin: 0 0 20px; font-weight: 600; letter-spacing: -.02em; }
h2 { font-size: 17px; margin: 0 0 14px; font-weight: 600; letter-spacing: -.01em; }
p { margin: 0 0 12px; }
.leise { color: var(--text-leise); }
.klein { font-size: 13px; }

.karte { background: var(--karte); border: 1px solid var(--linie); border-radius: var(--radius); padding: 22px 24px; margin-bottom: 22px; box-shadow: var(--schatten); }
.raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 18px; }
.raster .karte { margin: 0; }
.karte-link { display: block; color: inherit; text-decoration: none; }
.kachel-kunde { margin: -6px 0 12px; font-size: 14px; color: var(--text); }
.karte-link:hover .karte { border-color: var(--linie-stark); box-shadow: var(--schatten-hoch); transform: translateY(-1px); }
.karte-link .karte { transition: box-shadow .15s ease, border-color .15s ease, transform .15s ease; }

.meldung { padding: 12px 16px; border-radius: var(--radius); margin-bottom: 16px; border: 1px solid transparent; }
.meldung.erfolg { background: var(--gruen-flaeche); color: var(--gruen); border-color: #bbf7d0; }
.meldung.fehler { background: var(--rot-flaeche); color: var(--rot); border-color: #fecaca; }
.meldung.hinweis { background: var(--gelb-flaeche); color: var(--gelb); border-color: #fde68a; }

form.stapel { display: grid; gap: 14px; max-width: 460px; }
/* Eine Zeile mit Kästchen und Beschriftung nebeneinander, statt übereinander wie sonst. */
label.reihe { display: flex; align-items: center; gap: 8px; }
label.reihe input { width: auto; }
/* Formulare, die aus mehreren Karten bestehen, dürfen die ganze Breite nutzen. */
form.stapel > .karte { max-width: none; }
form.stapel:has(> .karte) { max-width: 760px; }
textarea { min-height: 72px; resize: vertical; }
label { display: grid; gap: 4px; font-weight: 500; font-size: 14px; }
label.zeile { display: flex; align-items: center; gap: 8px; font-weight: 400; }
input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="search"],
input[type="url"], input[type="date"], input[type="tel"], select, textarea {
  font: inherit; padding: 10px 13px; border: 1px solid var(--linie-stark); border-radius: var(--radius-klein);
  background: #fff; width: 100%; color: var(--text);
}
input::placeholder, textarea::placeholder { color: #9aa4b2; }
input:disabled, select:disabled, textarea:disabled { background: var(--flaeche); color: var(--text-leise); cursor: not-allowed; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--akzent); box-shadow: 0 0 0 3px var(--akzent-flaeche); }
button:focus-visible, a:focus-visible { outline: 2px solid var(--akzent); outline-offset: 2px; }
/* Das Code-Feld steht mittig über dem ebenfalls mittigen Knopf. */
input.code { font-size: 22px; letter-spacing: 6px; text-align: center; max-width: 220px;
  font-variant-numeric: tabular-nums; margin: 6px auto 0; display: block; }
form.stapel label:has(input.code) { text-align: center; }

.knopf { display: inline-block; font: inherit; font-weight: 500; padding: 10px 18px; border-radius: var(--radius-klein);
  border: 1px solid transparent; background: var(--akzent); color: #fff; text-decoration: none;
  box-shadow: var(--schatten); transition: background .15s ease, border-color .15s ease; }
.knopf:hover { background: var(--akzent-dunkel); color: #fff; }
.knopf.zweit { background: #fff; color: var(--text); border-color: var(--linie-stark); }
.knopf.zweit:hover { background: var(--flaeche); border-color: #b9c2d0; color: var(--text); }
.knopf.gefahr { background: #fff; color: var(--rot); border-color: #fecaca; }
.knopf.gefahr:hover { background: var(--rot-flaeche); }
.knopfleiste { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 20px; }
.abstand-unten { margin-bottom: 20px; }
.knopfleiste form { margin: 0; }

.tabelle-rahmen { overflow-x: auto; }
td.rechts, th.rechts { text-align: right; }
td.nicht-umbrechen { white-space: nowrap; }

/* Kennzahlen im Kopf einer Projektseite */
.zahlenreihe { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 20px; }
.zahl { background: var(--karte); border: 1px solid var(--linie); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--schatten); }
.zahl-wert { display: block; font-size: 29px; font-weight: 600; line-height: 1.15; letter-spacing: -.02em; }
.zahl-name { display: block; font-size: 13px; color: var(--text-leise); margin-top: 2px; }

/* Suche und Filter über einer Liste */
/* Hinweise auf der Startseite */
.hinweisliste { list-style: none; padding: 0; margin: 0; }
.hinweisliste li { list-style: none; padding: 9px 0 9px 22px; border-bottom: 1px solid var(--linie); position: relative; font-size: 14.5px; }
.hinweisliste li:last-child { border-bottom: 0; padding-bottom: 0; }
.hinweisliste li::before { content: "●"; position: absolute; left: 2px; top: 8px; font-size: 11px; }
.hinweisliste li.hinweis-fehler::before { color: var(--rot); }
.hinweisliste li.hinweis-warnung::before { color: var(--gelb); }
.hinweisliste li.hinweis-info::before { color: var(--text-leise); }
.hinweisliste li a { color: var(--text); text-decoration: none; }
.hinweisliste li a:hover { color: var(--akzent); text-decoration: underline; }

/* Fortschritt eines laufenden Crawls */
.karte.laufend { border-color: #fde68a; background: #fffdf5; }
.balken { height: 8px; border-radius: 999px; background: var(--linie); overflow: hidden; margin: 6px 0 14px; }
.balken-fuellung { height: 100%; background: var(--akzent); border-radius: 999px; transition: width .4s ease; }

label.voll textarea { min-height: 200px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; }
details { margin-top: 10px; }
summary { cursor: pointer; color: var(--akzent); font-size: 14px; }
details[open] summary { margin-bottom: 8px; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; background: var(--flaeche);
       padding: 1px 5px; border-radius: 4px; }

.filterleiste { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.filterleiste input[type="search"] { flex: 1 1 260px; min-width: 200px; margin: 0; }
.filterleiste select { flex: 0 1 auto; width: auto; max-width: 320px; margin: 0; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--linie); vertical-align: top; }
th { background: transparent; font-weight: 600; color: var(--text-leise); font-size: 12.5px;
     text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid var(--linie-stark); }
tbody tr:last-child td { border-bottom: 0; }
tr:hover td { background: #fafbfd; }

.marke-klein { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 500; }
.marke-klein.gruen { background: var(--gruen-flaeche); color: var(--gruen); }
.marke-klein.grau { background: #f3f4f6; color: #6b7280; }
.marke-klein.blau { background: var(--akzent-flaeche); color: var(--akzent-dunkel); }
.marke-klein.gelb { background: var(--gelb-flaeche); color: var(--gelb); }

ul { padding-left: 20px; }
ul li { list-style-type: disc; }
ul li::marker { color: var(--akzent); }

.mitte { min-height: calc(100vh - 60px); display: grid; place-items: start center; padding-top: 8vh; }
.mitte .karte { width: 100%; max-width: 440px; }
.qr { display: block; width: 200px; height: 200px; image-rendering: pixelated; margin: 8px 0 12px; border: 1px solid var(--linie); border-radius: 6px; }
.secret { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 15px; letter-spacing: 1px; word-break: break-all; background: #f8fafc; border: 1px solid var(--linie); border-radius: 6px; padding: 8px 10px; }
.linkfeld { display: flex; gap: 8px; }
.linkfeld input { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; }
pre.details { margin: 0; white-space: pre-wrap; word-break: break-word; font-size: 12px; color: var(--text-leise); }

@media (max-width: 640px) {
  .kopf { padding: 12px 16px; }
  main { padding: 16px 16px 40px; }
  .karte { padding: 16px; }
  .linkfeld { display: inline-block;  flex-direction: column; }
}

.abstand-oben { margin-top: 16px; }
.raster-zwei { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; align-items: start; }
.raster-zwei .karte { margin: 0; }
.faktorliste { display: grid; gap: 12px; margin-bottom: 16px; }
.faktor { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; padding: 12px 14px; border: 1px solid var(--linie); border-radius: 6px; }
details.aufklapp { border: 1px solid var(--linie); border-radius: 6px; padding: 10px 14px; margin-top: 12px; }
details.aufklapp summary { cursor: pointer; font-weight: 500; }
details.aufklapp[open] summary { margin-bottom: 12px; }

.fuss {
  position: fixed;
  right: 14px;
  bottom: 10px;
  z-index: 5;
  font-size: 12px;
  color: var(--text-leise);
  /* Deckend genug, damit die Zeile auch über einer Tabelle lesbar bleibt. */
  background: rgba(255, 255, 255, .94);
  border: 1px solid var(--linie);
  box-shadow: 0 1px 3px rgba(15, 23, 42, .06);
  backdrop-filter: blur(3px);
  padding: 4px 10px;
  border-radius: 999px;
}
.fuss a { color: var(--text-leise); }
.fuss a:hover { color: var(--akzent); }
.fuss .fassung { margin-right: 8px; opacity: .85; }
.fuss .fassung::after { content: "·"; margin-left: 8px; }
main { padding-bottom: 56px; }
@media (max-width: 640px) {
  .fuss { position: static; text-align: right; background: none; border: 0; box-shadow: none; padding: 0 16px 16px; }
  .fuss .fassung { display: block; margin: 0 0 2px; }
  .fuss .fassung::after { content: none; }
  main { padding-bottom: 8px; }
}

/* Kategorienpflege: je Kategorie ein eigenes Formular, Name und Reihenfolge nebeneinander. */
.visuallyhidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.kategorie-zeile { display: grid; gap: 12px; max-width: 860px; }
.kategorie-zeile h2 { margin: 0; }
.kategorie-kopf { display: grid; grid-template-columns: minmax(0, 1fr) 130px auto; gap: 12px; align-items: end; }
.kategorie-kopf > span { padding-bottom: 10px; }
@media (max-width: 640px) {
  .kategorie-kopf { grid-template-columns: 1fr; }
  .kategorie-kopf > span { padding-bottom: 0; }
}

/* Landingpage-Pflege: Farbwähler neben dem Schalter „Vorgabe“, Kategorienauswahl als Raster. */
.farbzeile { display: flex; flex-wrap: wrap; gap: 16px; align-items: end; }
.farbzeile input[type="color"] { width: 64px; height: 38px; padding: 2px; border: 1px solid var(--linie); border-radius: 8px; background: #fff; cursor: pointer; }
.kategorien-wahl { border: 1px solid var(--linie); border-radius: var(--radius); padding: 10px 14px; margin: 0;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 6px 16px; }
.kategorien-wahl legend { padding: 0 6px; font-weight: 500; }
.kategorien-wahl label { font-weight: 400; }
.hinweis-lauf { background: var(--akzent-flaeche); border: 1px solid var(--linie); border-radius: var(--radius); padding: 12px 16px; margin-bottom: 18px; }
.vorschau { width: 100%; height: 720px; border: 1px solid var(--linie); border-radius: var(--radius); background: repeating-conic-gradient(#f3f4f6 0% 25%, #fff 0% 50%) 50% / 20px 20px; }
