/* Beratungsoberfläche: Arbeitsplatz für Berater:innen und Redaktion. */

body.beratung {
  min-height: 100vh;
}

/* Testbetrieb: Achtung, also Zitrone mit Tintenkante */
.testband {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  padding: 0.45rem 1rem;
  background: var(--zitrone);
  border-bottom: 1.5px solid var(--tinte);
  color: var(--tinte);
  font-size: 0.875rem;
  font-weight: 500;
  text-align: center;
}

/* Kopfleiste: Tinte, Reiter als Pillen, der aktive in der Akzentfarbe */
.kopfleiste {
  display: flex;
  align-items: center;
  gap: 0.6rem 1rem;
  padding: 0.6rem 1.25rem;
  min-height: 3.75rem;
  flex-wrap: wrap;
}

.hauptnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem;
  flex: 1;
}

.hauptnav a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--kopf-links);
  text-decoration: none;
  padding: 0.45rem 0.75rem;
  border-radius: var(--pille);
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
}

.hauptnav a:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.hauptnav a[aria-current='page'] {
  background: var(--akzent);
  color: var(--auf-akzent);
  font-weight: 600;
}

.konto-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.8125rem;
  color: var(--kopf-leise);
  white-space: nowrap;
}

.konto-info a {
  color: #fff;
  font-weight: 500;
}

.konto-info a:hover {
  color: var(--akzent-hell);
}

.inhalt {
  max-width: 88rem;
  margin: 0 auto;
  padding: 1.75rem 1.25rem 3rem;
}

.seitenkopf {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.seitenkopf h1 {
  margin: 0;
  font-size: 2.5rem;
  line-height: 1;
  letter-spacing: -0.035em;
}

.seitenkopf p {
  margin: 0.4rem 0 0;
  color: var(--text-leise);
}

.tafel {
  background: var(--flaeche);
  border-radius: var(--radius-karte);
  box-shadow: var(--schatten);
  padding: 1.25rem 1.4rem;
  margin-bottom: 1.25rem;
}

.tafel > h2 {
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.9rem;
}

/* Anmeldung */
.anmeldung {
  max-width: 27rem;
  margin: 8vh auto 2rem;
}

.anmeldung h1 {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

/* Tabellen */
.tabelle-huelle {
  overflow-x: auto;
}

table.liste {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

table.liste th,
table.liste td {
  text-align: start;
  vertical-align: top;
  padding: 0.75rem 0.6rem;
  border-bottom: 1px solid var(--linie);
}

table.liste th {
  font-family: var(--schriftart-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-leise);
  padding-top: 0.25rem;
}

/* Lange ungenutzte Zettel: zart hinterlegt, das Kennzeichen in der Zelle ist Zitrone */
table.liste tr.ungenutzt td {
  background: #fdffdb;
}

.code {
  font-family: var(--schriftart-mono);
  font-weight: 500;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.filterleiste {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  align-items: center;
  margin-bottom: 0.9rem;
}

.filterleiste h2 {
  margin: 0;
  font-size: 1.2rem;
}

.filterleiste .feld {
  margin: 0;
  min-width: 11rem;
}

/* Zettel-Editor */
.editor {
  display: grid;
  grid-template-columns: minmax(20rem, 2fr) minmax(24rem, 3fr);
  gap: 1.25rem;
  align-items: start;
}

@media (max-width: 64rem) {
  .editor {
    grid-template-columns: 1fr;
  }
}

.auswahl-karte {
  height: 18rem;
  border-radius: 20px;
  overflow: hidden;
  background: var(--karte-grund);
  margin-bottom: 0.9rem;
}

.auswahl-liste {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 32rem;
  overflow-y: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.5rem;
}

.auswahl-liste li {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  padding: 0.7rem 0.8rem;
  border-radius: 16px;
  background: var(--papier);
}

.auswahl-liste li.auf-zettel {
  background: var(--akzent-hell);
}

.auswahl-liste li.leer {
  background: transparent;
}

.auswahl-liste .text {
  flex: 1;
  min-width: 0;
}

.auswahl-liste .name {
  font-weight: 600;
}

.auswahl-liste .unter {
  font-size: 0.8125rem;
  color: var(--text-leise);
}

.auswahl-liste .knopfzeile:empty {
  display: none;
}

.symbolkreis {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--farbe, var(--tinte));
  color: var(--schrift, #fff);
  flex: none;
  font-weight: 600;
}

.gewaehlt-liste {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.75rem;
}

.gewaehlt {
  border: 1px solid var(--linie);
  border-radius: 20px;
  padding: 1rem 1.1rem;
  background: #fff;
}

.gewaehlt.papier {
  background: repeating-linear-gradient(-45deg, #fff, #fff 10px, var(--papier) 10px, var(--papier) 20px);
}

.gewaehlt-kopf {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}

.gewaehlt-kopf .titel {
  flex: 1;
  min-width: 0;
}

.gewaehlt-kopf .titel strong {
  display: block;
}

.raster-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

@media (max-width: 40rem) {
  .raster-2 {
    grid-template-columns: 1fr;
  }
}

.unterblock {
  margin-top: 0.9rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--linie);
}

.unterblock > .blocktitel {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  margin-bottom: 0.55rem;
}

/* Umschalter in Pillenform; die gewählte Möglichkeit in der Akzentfarbe */
.segment {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.15rem;
  padding: 0.25rem;
  border-radius: var(--pille);
  background: var(--papier);
  box-shadow: inset 0 0 0 1px var(--linie);
  margin-bottom: 0.7rem;
}

.segment button {
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 500;
  border: 0;
  border-radius: var(--pille);
  background: transparent;
  padding: 0.45rem 0.95rem;
  cursor: pointer;
  color: var(--tinte);
}

.segment button:hover {
  background: #fff;
}

.segment button[aria-pressed='true'] {
  background: var(--akzent);
  color: var(--auf-akzent);
  font-weight: 600;
}

.segment button:disabled {
  color: #8e9297;
  cursor: not-allowed;
  background: transparent;
}

.rueck {
  font-size: 0.875rem;
  background: var(--papier);
  border-radius: var(--radius-klein);
  padding: 0.55rem 0.75rem;
  margin-top: 0.5rem;
}

.aktionsleiste {
  position: sticky;
  bottom: 0;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  padding: 0.9rem 1.4rem;
  margin: 1.25rem -1.4rem -1.25rem;
  background: rgba(255, 255, 255, 0.97);
  border-top: 1px solid var(--linie);
  border-radius: 0 0 var(--radius-karte) var(--radius-karte);
}

.aktionsleiste .rechts {
  margin-inline-start: auto;
}

.digital-box {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.digital-box .qr {
  width: 7.5rem;
  height: 7.5rem;
  flex: none;
}

/* Dialoge */
dialog.dialog {
  border: 0;
  border-radius: var(--radius-karte);
  padding: 0;
  max-width: min(36rem, 94vw);
  width: 100%;
  box-shadow: var(--schatten-hoch);
}

dialog.dialog::backdrop {
  background: rgba(3, 5, 7, 0.45);
}

.dialog-kopf {
  padding: 1.2rem 1.4rem 0.4rem;
}

.dialog-kopf h2 {
  margin: 0;
  font-size: 1.25rem;
}

.dialog-inhalt {
  padding: 0.4rem 1.4rem 1rem;
}

.dialog-fuss {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  padding: 0.9rem 1.4rem 1.2rem;
  border-top: 1px solid var(--linie);
}

.scanner-video {
  width: 100%;
  border-radius: 16px;
  background: #000;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

/* Druckvorschau */
.druckbereich {
  position: fixed;
  inset: 0;
  z-index: 50;
  overflow: auto;
  background: #3a3e43;
  padding: 4.75rem 1rem 2rem;
}

.druckbereich .druckleiste {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 51;
  display: flex;
  gap: 0.6rem;
  align-items: center;
  padding: 0.75rem 1.25rem;
  background: var(--tinte);
  color: #fff;
}

.druckbereich .druckleiste .leise {
  color: var(--kopf-leise);
}

.druckbereich .druckleiste .knopf:not(.haupt) {
  background: transparent;
  color: #fff;
  border-color: var(--kopf-leise);
}

.druckbereich .druckleiste .knopf:not(.haupt):hover {
  background: rgba(255, 255, 255, 0.1);
}

@media print {
  .druckleiste {
    display: none !important;
  }
}

/* Stellen-Formular */
.formular-raster {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 0 1rem;
}

.pin-karte {
  height: 16rem;
  border-radius: 20px;
  overflow: hidden;
  background: var(--karte-grund);
  margin-bottom: 0.5rem;
}

.oz-tabelle {
  display: grid;
  gap: 0.4rem;
}

.oz-tabelle .oz-zeile {
  display: grid;
  grid-template-columns: 3rem 1fr auto;
  gap: 0.5rem;
  align-items: center;
}

.oz-spannen {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.oz-spanne {
  display: inline-flex;
  gap: 0.25rem;
  align-items: center;
}

.oz-spanne input {
  width: 7.2rem;
}

.pin {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--tinte);
  border: 3px solid #fff;
  box-shadow:
    0 0 0 2px var(--tinte),
    0 2px 6px rgba(0, 0, 0, 0.35);
  cursor: grab;
}

.uebersetzungen {
  border-radius: 16px;
  padding: 0.5rem 0.85rem;
  margin: -0.4rem 0 1rem;
  background: var(--papier);
  box-shadow: inset 0 0 0 1px var(--linie);
}

.uebersetzungen summary {
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.25rem 0;
}

.uebersetzung-zeile {
  display: grid;
  grid-template-columns: 7rem 1fr 9rem;
  gap: 0.5rem;
  align-items: start;
  margin: 0.45rem 0;
}

@media (max-width: 48rem) {
  .uebersetzung-zeile {
    grid-template-columns: 1fr;
  }
}

.quellen-liste {
  font-size: 0.875rem;
  padding-inline-start: 1.1rem;
}

.quellen-liste li {
  margin-bottom: 0.3rem;
  word-break: break-all;
}

.foto-vorschau {
  max-width: 18rem;
  max-height: 12rem;
  border-radius: 16px;
  display: block;
  margin-bottom: 0.5rem;
}

.leer {
  padding: 2rem 1rem;
  text-align: center;
  color: var(--text-leise);
}

.ladeanzeige {
  padding: 2rem;
  color: var(--text-leise);
}

/* Verwaltung: Erscheinungsbild ----------------------------------------
   Die Vorschau setzt die Farbvariablen am eigenen Container; alles darin rechnet mit denselben
   Variablen wie die echten Seiten (Kopfleiste, Akzentfläche, Schalter, Auswahl, Druckband). */

.eb-einleitung {
  max-width: 48rem;
  margin: 0 0 1.1rem;
  color: var(--text-leise);
}

.eb-raster {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.25rem 2rem;
}

@media (min-width: 60rem) {
  .eb-raster {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    align-items: start;
  }
}

.eb-eingabe {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

input.eb-hex {
  max-width: 9.5rem;
  font-family: var(--schriftart-mono);
  letter-spacing: 0.04em;
}

input.eb-hex[aria-invalid='true'] {
  border-color: var(--gefahr);
  box-shadow: inset 0 0 0 1px var(--gefahr);
}

.eb-feldname {
  font-weight: 600;
}

.eb-pruefung {
  margin: 0.2rem 0 1rem;
}

.eb-kontraste {
  list-style: none;
  margin: 0.45rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.3rem;
  font-size: 0.875rem;
}

.eb-kontraste li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto 5.5rem;
  gap: 0.5rem;
  align-items: center;
}

.eb-kontraste .symbol {
  color: var(--gut);
}

.eb-kontraste b {
  font-variant-numeric: tabular-nums;
}

.eb-hinweise:not(:empty) {
  display: grid;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.eb-hinweise .hinweisbox {
  margin: 0;
}

.eb-stand {
  font-size: 0.875rem;
  margin: 0 0 0.75rem;
}

.eb-vorschau {
  display: grid;
  gap: 0.75rem;
  min-width: 0;
  padding: 1rem;
  border-radius: var(--radius-karte);
  background: var(--papier);
}

.eb-vorschau > .etikett {
  margin: 0;
}

.eb-kopf {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1rem;
  padding: 0.55rem 0.9rem;
  border-radius: 18px;
}

.eb-kopf .hauptnav a {
  cursor: default;
}

.eb-flaeche {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 1.1rem 1.2rem 1.25rem;
  border-radius: 22px;
}

.eb-titel {
  margin: 0;
  font-size: 1.625rem;
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.eb-titel .zw > .de:not(.nur) {
  font-size: 0.5em;
  font-weight: 400;
  letter-spacing: 0;
  margin-top: 0.3rem;
}

.eb-aussteller {
  margin: 0;
  font-size: 0.875rem;
  color: var(--auf-akzent-leise);
}

.eb-flaeche .knopf {
  cursor: default;
}

.eb-teile {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 0.9rem;
}

.eb-auswahl,
.eb-gewaehlt {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.5rem;
  padding: 0.4rem 0.9rem;
  border-radius: var(--radius-klein);
  font-size: 0.875rem;
  font-weight: 500;
}

.eb-auswahl {
  background: var(--akzent-hell);
}

.eb-gewaehlt {
  background: var(--flaeche);
  outline: 3px solid var(--akzent-kontur);
  outline-offset: 0;
}

/* Druckband wie auf dem Zettel, aber in Spaltenbreite statt 186 mm */
.druckzettel.eb-druck {
  width: auto;
  background: transparent;
}

.eb-druck .dz-band {
  margin: 0;
}

.eb-fehler {
  margin: 0;
  color: var(--gefahr);
  font-size: 0.8125rem;
  font-weight: 500;
}
