/* Gestaltung von „Noch gut". Die Werte stammen aus dem Mockup vom 30.08.2026
   (SPEC.md Q2) und nicht aus dem Leadpeak-Design – Ansage Reemt, 13.09.2026:
   das Mockup-Bild passt besser zu einer Hilfsaktion als das Agentur-Blau.
   assets/design.css bleibt unveraendert im Repo liegen, wird aber nicht mehr
   eingebunden; damit entfaellt auch der Google-Fonts-Aufruf.

   Handy zuerst: alles auf 390 px entworfen, groessere Bildschirme bekommen
   dieselbe Spalte zentriert, hoechstens 480 px. */

:root {
  --ng-paper:       #FBF7F2;
  --ng-card:        #FFFFFF;
  --ng-ink:         #241E19;
  --ng-text:        #4A423B;
  --ng-muted:       #7C6F64;
  --ng-line:        #E6DCD1;
  --ng-accent:      #B25334;
  --ng-accent-line: #E2CFC6;
  --ng-good:        #3C7A57;
  --ng-good-soft:   #E4F0E9;
  --ng-good-ink:    #2F6446;
  --ng-good-line:   #CBE0D4;
  --ng-warn:        #C08A2E;
  --ng-warn-soft:   #FDF1DF;
  --ng-warn-ink:    #8A6316;
  --ng-grey:        #9C9086;
  --ng-grey-soft:   #EFEAE4;
  --ng-grey-ink:    #6E635A;
  --ng-no-soft:     #F7E5E0;
  --ng-no-ink:      #9A452A;
  --ng-strich:      #C9BCAF;
  --ng-strich-ink:  #A89A8D;
  --ng-radius:      14px;
  --ng-radius-s:    12px;
  --ng-font:        system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

/* Das hidden-Attribut muss jede eigene display-Regel schlagen. Ohne das bleibt
   ein per JavaScript ausgeblendeter Knopf sichtbar, weil .knopf display:block
   setzt und spezifischer ist. */
[hidden] { display: none !important; }

html, body { margin: 0; padding: 0; max-width: 100%; overflow-x: hidden; }

body {
  background: var(--ng-paper);
  color: var(--ng-ink);
  font-family: var(--ng-font);
  font-size: 15px;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}

.spalte { width: 100%; max-width: 480px; margin: 0 auto; padding: 14px 20px 32px; }

/* Kopfzeile: Name links, aktueller Ort rechts */
.kopf {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 10px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--ng-line);
}
.kopf .marke {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -.02em;
  color: var(--ng-ink);
  text-decoration: none;
}
.kopf .ort {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--ng-muted);
  text-align: right;
  min-width: 0;
}
.zurueck {
  display: inline-block;
  font-size: 13px;
  color: var(--ng-muted);
  text-decoration: none;
  margin: 0 0 10px;
}
.laufstreifen {
  display: block;
  background: var(--ng-grey-soft);
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ng-text);
  text-decoration: none;
  margin: 0 0 14px;
}

/* Visuell versteckt, aber bedienbar und fuer Vorleseprogramme da.
   Der Selektor nennt input ausdruecklich, weil die allgemeine Regel fuer
   input[type="file"] weiter unten sonst die Breite zurueckholt – das Feld
   nimmt dann volle Breite ein und schiebt die Seite ueber 390 px hinaus. */
.versteckt, input[type="file"].versteckt {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Karte, die zu etwas fuehrt */
.karte-verweis {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}
.karte-verweis .pfeil { color: var(--ng-muted); font-size: 20px; flex: 0 0 auto; }

/* Kiste aus dem Vorgang entfernen */
.entfernen { margin: 0; flex: 0 0 auto; }
.entfernen button {
  border: 1px solid var(--ng-line);
  background: var(--ng-card);
  color: var(--ng-muted);
  border-radius: 8px;
  width: 32px; height: 32px;
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
}

h1, h2, h3 { margin: 0 0 8px; letter-spacing: -.01em; overflow-wrap: anywhere; }
h1 { font-size: 26px; font-weight: 700; }
h2 { font-size: 19px; font-weight: 700; margin-top: 26px; }
h3 { font-size: 16px; font-weight: 600; margin-top: 18px; }

p { margin: 0 0 14px; overflow-wrap: anywhere; }
a { color: var(--ng-accent); }

.vorspann { color: var(--ng-text); font-size: 14px; margin-top: -2px; }
.zeile-zusatz { font-size: 12px; color: var(--ng-muted); }
.zeile-name { display: block; font-size: 14px; font-weight: 600; }

.karte {
  background: var(--ng-card);
  border: 1px solid var(--ng-line);
  border-radius: var(--ng-radius-s);
  padding: 14px;
  margin: 0 0 14px;
}
.karte-beige { background: var(--ng-grey-soft); border-color: transparent; }

/* Hervorgehobener Kasten fuer „dringend gesucht" – needstrip aus dem Mockup */
.karte-bedarf { background: var(--ng-good-soft); border-color: var(--ng-good-line); }
.karte-bedarf h2 {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--ng-good);
  font-weight: 700;
  margin: 0 0 6px;
}

/* Schaltflaechen: abgerundete Rechtecke, keine Pillen */
.knopf {
  display: block;
  width: 100%;
  border: 0;
  border-radius: var(--ng-radius-s);
  padding: 15px 16px;
  background: var(--ng-accent);
  color: #fff;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  margin: 0 0 10px;
}
.knopf-still {
  background: transparent;
  color: var(--ng-accent);
  border: 1.5px solid var(--ng-accent-line);
  padding: 13.5px 16px;
}
.knopf-leise { background: var(--ng-grey-soft); color: var(--ng-text); }

ul.liste { list-style: none; margin: 0; padding: 0; }
ul.liste li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 0;
  border-bottom: 1px solid var(--ng-line);
}
ul.liste li:last-child { border-bottom: none; }
ul.liste li > span:first-child { flex: 1; min-width: 0; }

/* Zustand je Gruppe als farbige Marke */
.tag {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 999px;
  white-space: nowrap;
  flex: 0 0 auto;
  align-self: flex-start;
  margin-top: 2px;
}
.tag-dringend { background: var(--ng-good-soft); color: var(--ng-good-ink); }
.tag-gebraucht { background: var(--ng-warn-soft); color: var(--ng-warn-ink); }
.tag-genug { background: var(--ng-grey-soft); color: var(--ng-grey-ink); }
.tag-nehmen_wir_nicht { background: var(--ng-no-soft); color: var(--ng-no-ink); }
.tag-unbekannt { background: var(--ng-grey-soft); color: var(--ng-grey-ink); }

/* Kopf einer Bewertung: farbiger Kreis mit Zeichen, daneben das Urteil */
.urteil { display: flex; gap: 10px; align-items: flex-start; margin: 0 0 14px; }
.urteil-zeichen {
  width: 28px; height: 28px; border-radius: 50%;
  flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; color: #fff;
  background: var(--ng-grey);
}
.urteil-brauchbar { background: var(--ng-good); }
.urteil-nicht_beurteilbar, .urteil-ohne_abgleich { background: var(--ng-warn); }
.urteil-kein_bedarf { background: var(--ng-grey); }
.urteil-vor_ort_zeigen { background: var(--ng-ink); }
.urteil h1 { font-size: 19px; margin: 1px 0 2px; }
.urteil p { margin: 0; font-size: 13px; color: var(--ng-text); }

/* Abgabenummer */
.nummernblock {
  background: var(--ng-ink);
  color: #fff;
  border-radius: var(--ng-radius);
  padding: 18px;
  text-align: center;
  margin: 0 0 12px;
}
.nummernblock .lbl { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; opacity: .6; }
.nummer {
  font-size: 38px; font-weight: 700; letter-spacing: .06em;
  margin-top: 4px; font-variant-numeric: tabular-nums; word-break: break-all;
}
.nummernblock .hinweis { font-size: 12px; opacity: .7; margin: 6px 0 0; }

/* Platzhalter sind sichtbar als solche beschriftet */
.platzhalter {
  display: inline-block;
  border: 1.5px dashed var(--ng-strich);
  border-radius: 10px;
  padding: 8px 12px;
  color: var(--ng-strich-ink);
  font-size: 13px;
}

label.wahl {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 0;
  border-bottom: 1px solid var(--ng-line);
  cursor: pointer;
}
label.wahl:last-of-type { border-bottom: none; }
label.wahl input { width: 22px; height: 22px; flex: 0 0 auto; accent-color: var(--ng-accent); }
label.wahl > span { flex: 1; min-width: 0; }

input[type="text"], input[type="password"], input[type="file"] {
  width: 100%;
  max-width: 100%;
  padding: 13px;
  border: 1px solid var(--ng-line);
  border-radius: 10px;
  font-family: var(--ng-font);
  font-size: 16px;
  background: var(--ng-card);
  color: var(--ng-text);
}
label { display: block; font-size: 12px; font-weight: 600; color: var(--ng-muted); margin-bottom: 5px; }

.zustandswahl { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.zustandswahl label {
  flex: 1 1 45%;
  min-width: 0;
  font-size: 11px;
  font-weight: 700;
  color: var(--ng-muted);
  padding: 8px 6px;
  border: 1px solid var(--ng-line);
  border-radius: 8px;
  text-align: center;
  cursor: pointer;
  background: var(--ng-card);
  margin: 0;
}
.zustandswahl input { margin-right: 4px; accent-color: var(--ng-accent); }

.meldung {
  border-left: 3px solid var(--ng-warn);
  background: var(--ng-warn-soft);
  border-radius: 10px;
  padding: 11px 13px;
  margin: 0 0 14px;
  font-size: 13.5px;
  color: var(--ng-text);
}
.meldung-fehler { border-left-color: var(--ng-accent); background: var(--ng-accent-soft, #F6E7E0); }

.notiz {
  border-left: 3px solid var(--ng-line);
  padding: 2px 0 2px 11px;
  font-size: 12px;
  color: var(--ng-muted);
  margin: 0 0 16px;
}

footer {
  margin-top: 28px;
  padding-top: 14px;
  border-top: 1px solid var(--ng-line);
  font-size: 12px;
  color: var(--ng-muted);
}
footer a { color: var(--ng-muted); }
footer img { height: 22px; width: auto; display: block; margin-bottom: 8px; }
footer .fuss-empfaenger { margin-bottom: 10px; }

/* Kleine Marke fuer die Bewertung einer Kiste in Listen */
.marke {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 999px;
  white-space: nowrap;
}
.marke-brauchbar { background: var(--ng-good-soft); color: var(--ng-good-ink); }
.marke-kein_bedarf { background: var(--ng-grey-soft); color: var(--ng-grey-ink); }
.marke-nicht_beurteilbar { background: var(--ng-warn-soft); color: var(--ng-warn-ink); }
.marke-ohne_abgleich { background: var(--ng-warn-soft); color: var(--ng-warn-ink); }
.marke-vor_ort_zeigen { background: var(--ng-accent-soft, #F6E7E0); color: var(--ng-no-ink); }

/* Katalogpflege in der Einrichtungsstrecke */
.gruppenkopf {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
.gruppenkopf > span:first-child { flex: 1; min-width: 0; }
.ausblenden {
  flex: 0 0 auto;
  width: 30px; height: 30px;
  border: 1px solid var(--ng-line);
  border-radius: 8px;
  color: var(--ng-muted);
  font-size: 17px;
  line-height: 28px;
  text-align: center;
  text-decoration: none;
}
.karte-rueckfrage {
  border-color: var(--ng-warn);
  background: var(--ng-warn-soft);
}
.karte-rueckfrage p { margin: 6px 0 12px; }
.wiederauf {
  border: 1px solid var(--ng-accent-line);
  background: var(--ng-card);
  color: var(--ng-accent);
  border-radius: 8px;
  padding: 7px 10px;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}
.karte-betroffen { border-color: var(--ng-warn); }
