/* gupp — schlichtes Grundlayout.
   Das visuelle Design ist laut Briefing eine eigene Aufgabe; hier steht nur,
   was für Lesbarkeit und Bedienbarkeit nötig ist. */

:root {
  --text: #1c1c1e;
  --gedaempft: #6b6b70;
  --linie: #dcdce0;
  --grund: #ffffff;
  --flaeche: #f6f6f7;
  --akzent: #1f4ed8;
  --fehler: #b42318;
  --fehler-flaeche: #fef3f2;
  --ok: #067647;
  --ok-flaeche: #ecfdf3;
  --warn-flaeche: #fffaeb;
  --warn: #b54708;
  --radius: 8px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--text);
  background: var(--flaeche);
}

.huelle { max-width: 760px; margin: 0 auto; padding: 32px 20px 64px; }
.schmal { max-width: 440px; }

header.kopf {
  display: flex; align-items: baseline; gap: 12px;
  padding: 16px 20px; background: var(--grund); border-bottom: 1px solid var(--linie);
}
header.kopf .marke { font-weight: 650; letter-spacing: -0.01em; }
header.kopf .rest { margin-left: auto; font-size: 14px; color: var(--gedaempft); }

h1 { font-size: 26px; letter-spacing: -0.02em; margin: 0 0 8px; }
h2 { font-size: 19px; letter-spacing: -0.01em; margin: 28px 0 10px; }
p.lead { color: var(--gedaempft); margin: 0 0 24px; }

.karte {
  background: var(--grund); border: 1px solid var(--linie);
  border-radius: var(--radius); padding: 20px; margin-bottom: 16px;
}

label { display: block; font-weight: 550; font-size: 14px; margin-bottom: 6px; }
input[type=text], input[type=email], input[type=password], textarea, select {
  width: 100%; padding: 10px 12px; font: inherit; color: inherit;
  border: 1px solid var(--linie); border-radius: 6px; background: var(--grund);
}
textarea { min-height: 200px; resize: vertical; font-size: 15px; }
input:focus, textarea:focus, select:focus { outline: 2px solid var(--akzent); outline-offset: -1px; }
.feld { margin-bottom: 16px; }
.hilfe { font-size: 13px; color: var(--gedaempft); margin-top: 6px; }

button {
  font: inherit; font-weight: 550; padding: 10px 18px; border-radius: 6px;
  border: 1px solid var(--akzent); background: var(--akzent); color: #fff; cursor: pointer;
}
button:hover:not(:disabled) { filter: brightness(1.08); }
button:disabled { opacity: 0.55; cursor: default; }
button.sekundaer { background: var(--grund); color: var(--text); border-color: var(--linie); }
button.knapp { padding: 5px 10px; font-size: 13px; font-weight: 500; }
button.gefahr { background: var(--grund); color: var(--fehler); border-color: var(--linie); }

.zeile { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.zeile.ende { justify-content: flex-end; }

.meldung { display: none; margin: 16px 0; padding: 12px 14px; border-radius: 6px; font-size: 15px; }
.meldung p { margin: 0 0 8px; }
.meldung p:last-child { margin-bottom: 0; }
.meldung.fehler { background: var(--fehler-flaeche); color: var(--fehler); border: 1px solid #fecdca; }
.meldung.ok { background: var(--ok-flaeche); color: var(--ok); border: 1px solid #abefc6; }
.meldung.warnung { background: var(--warn-flaeche); color: var(--warn); border: 1px solid #fedf89; }
.meldung .hinweis { font-size: 14px; opacity: 0.85; }
.meldung button { margin-top: 8px; }

.zustimmung {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 14px; background: var(--flaeche); border: 1px solid var(--linie); border-radius: 6px;
}
.zustimmung input { margin-top: 3px; flex: none; width: 18px; height: 18px; }
.zustimmung label { font-weight: 400; font-size: 14.5px; margin: 0; }

.eintrag { border: 1px solid var(--linie); border-radius: 6px; padding: 14px; margin-bottom: 10px; background: var(--grund); }
.eintrag .kopfzeile { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; }
.eintrag .art {
  font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--gedaempft); background: var(--flaeche); padding: 2px 8px; border-radius: 4px;
}
.eintrag .zeitraum { font-size: 13px; color: var(--gedaempft); margin-left: auto; }
.eintrag textarea { min-height: 76px; }
.eintrag .feld { margin-bottom: 10px; }
.eintrag.entfernt { opacity: 0.45; }

.lade { display: none; color: var(--gedaempft); font-size: 15px; margin: 16px 0; }
.lade.an { display: block; }

.fuss { margin-top: 32px; font-size: 13px; color: var(--gedaempft); }

/* ---- Dashboard und Bewerbungs-Flow ---------------------------------- */

.zeile.zwischen { justify-content: space-between; align-items: flex-start; }
.ohne-abstand { margin-top: 0; margin-bottom: 4px; }
header.kopf .marke a { color: inherit; text-decoration: none; }

/* Kurzlabel für Status und Eigenschaften */
.marker {
  display: inline-block; margin-left: 8px; padding: 2px 8px; border-radius: 4px;
  font-size: 12px; font-weight: 600; letter-spacing: 0.02em; white-space: nowrap;
  color: var(--gedaempft); background: var(--flaeche); border: 1px solid var(--linie);
}
.marker.gut    { color: var(--ok);      background: var(--ok-flaeche);    border-color: #abefc6; }
.marker.teil   { color: var(--warn);    background: var(--warn-flaeche);  border-color: #fedf89; }
.marker.luecke { color: var(--fehler);  background: var(--fehler-flaeche); border-color: #fecdca; }
.marker.grau   { color: var(--gedaempft); }

/* Fit-Score */
.score { font-size: 20px; font-weight: 650; letter-spacing: -0.02em; white-space: nowrap; }
.score.gross { font-size: 34px; }

.balken {
  margin-top: 14px; height: 8px; border-radius: 999px;
  background: var(--flaeche); border: 1px solid var(--linie); overflow: hidden;
}
.balken-fuell {
  height: 100%; width: 0; background: var(--akzent);
  transition: width 240ms ease-out;
}

/* Anforderungsliste: der farbige Rand macht Lücken auf einen Blick sichtbar,
   ohne dass Farbe die einzige Information ist — der Status steht als Text daneben. */
.anforderung { border-left-width: 3px; }
.anforderung.match      { border-left-color: var(--ok); }
.anforderung.weak_match { border-left-color: var(--warn); }
.anforderung.gap        { border-left-color: var(--fehler); }

/* Generierte Unterlagen */
.ausgabe {
  margin: 12px 0 0; padding: 16px; max-height: 460px; overflow: auto;
  background: var(--flaeche); border: 1px solid var(--linie); border-radius: 6px;
  font: 14px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace;
  white-space: pre-wrap; word-break: break-word;
}

/* ---- Fit-Check ------------------------------------------------------- */

.fortschritt { margin: 0 0 20px; font-size: 14px; color: var(--gedaempft); }
.fortschritt .balken { margin-top: 8px; }

fieldset.frage {
  margin: 0 0 14px; padding: 16px; border: 1px solid var(--linie);
  border-radius: var(--radius); background: var(--grund);
}
/* legend sitzt normalerweise AUF der Rahmenlinie und bricht bei mehrzeiligen
   Fragen aus dem Kasten aus. float+100% zieht es in den normalen Fluss zurueck;
   .skala raeumt den Float mit clear wieder auf. */
fieldset.frage legend {
  float: left; width: 100%; padding: 0; margin-bottom: 2px;
  font-size: 15.5px; line-height: 1.5; font-weight: 500;
}
.frage-nr { color: var(--gedaempft); font-variant-numeric: tabular-nums; }

/* 5er-Skala: als Reihe, auf schmalen Displays untereinander. Die Zahl bleibt
   immer sichtbar, die Textanker nur an den Enden — sonst wird es unlesbar. */
/* Feste 5 Spalten statt Umbruch — sonst entsteht auf schmalen Displays eine
   ungleiche 3+2-Reihe, die die Skala optisch verzerrt. */
.skala {
  clear: both; display: grid; grid-template-columns: repeat(5, 1fr);
  gap: 8px; margin-top: 14px;
}
.stufe {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  margin: 0; padding: 10px 6px; font-weight: 400; font-size: 12px; text-align: center;
  border: 1px solid var(--linie); border-radius: 6px; background: var(--grund); cursor: pointer;
}
.stufe:hover { border-color: var(--akzent); }
.stufe input { margin: 0; width: 16px; height: 16px; accent-color: var(--akzent); }
.stufe-zahl { font-size: 15px; font-weight: 600; }
.stufe-text { color: var(--gedaempft); line-height: 1.3; }
.stufe:has(input:checked) { border-color: var(--akzent); background: #f5f8ff; }
.stufe:has(input:focus-visible) { outline: 2px solid var(--akzent); outline-offset: 1px; }

.dimension { margin-bottom: 16px; }
.dimension:last-child { margin-bottom: 0; }
.dimension .balken { margin-top: 6px; }

/* Auf schmalen Displays reichen die Zahlen: die Bedeutung der Endpunkte steht
   bereits im Einleitungstext ueber dem Fragebogen. */
@media (max-width: 560px) {
  .stufe { padding: 10px 2px; }
  .stufe-text { display: none; }
}
