/* =============================================================
   PROCURE – Oberfläche
   Ein Gestaltungssystem, keine Sammlung von Einzelfällen:
   alle Farben als Token auf :root, Dunkelmodus eigens gesetzt.
   ============================================================= */

:root {
  color-scheme: light;

  /* Markenrampe (Blau, geprüfte Stufen) */
  --marke-900: #0d366b;
  --marke-800: #104281;
  --marke-700: #184f95;
  --marke-600: #1c5cab;
  --marke-500: #256abf;
  --marke-400: #2a78d6;
  --marke-300: #5598e7;
  --marke-200: #9ec5f4;
  --marke-100: #cde2fb;
  --marke-050: #eaf2fd;

  /* Flächen und Schrift */
  --flaeche:    #ffffff;
  --flaeche-2:  #f6f8fb;
  --flaeche-3:  #edf1f6;
  --flaeche-inv:#0f1a2b;
  --rand:       #dde3ea;
  --rand-stark: #c3ccd8;
  --text:       #0f1a2b;
  --text-2:     #4a5768;
  --text-3:     #76828f;
  --text-inv:   #ffffff;

  /* Zustandsfarben – fest, nie als Seriennfarbe missbraucht */
  --gut:      #0ca30c;
  --gut-bg:   #e8f6e8;
  --warn:     #fab219;
  --warn-bg:  #fdf4e0;
  --ernst:    #ec835a;
  --ernst-bg: #fdeee7;
  --kritisch: #d03b3b;
  --krit-bg:  #fbeaea;

  /* Diagrammfarben (kategorial, geprüfte Reihenfolge) */
  --serie-1: #2a78d6;
  --serie-2: #eb6834;
  --serie-3: #1baf7a;
  --serie-4: #eda100;
  --serie-5: #e87ba4;
  --serie-6: #008300;

  --radius:    10px;
  --radius-s:  7px;
  --radius-l:  16px;
  --schatten-1: 0 1px 2px rgba(15, 26, 43, .06), 0 1px 3px rgba(15, 26, 43, .04);
  --schatten-2: 0 2px 6px rgba(15, 26, 43, .07), 0 8px 24px rgba(15, 26, 43, .06);
  --schatten-3: 0 10px 40px rgba(15, 26, 43, .18);

  --kopf-h: 60px;
  --nav-h: 46px;
  --breite: 1240px;

  --schrift: -apple-system, BlinkMacSystemFont, "Segoe UI", "Segoe UI Variable Text",
             Roboto, "Helvetica Neue", Arial, sans-serif;
  --schrift-mono: ui-monospace, "Cascadia Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root:where(:not([data-theme="light"])) {
    color-scheme: dark;
    --marke-100: #17304f;
    --marke-050: #14263d;
    --marke-400: #3987e5;
    --marke-300: #6da7ec;
    --flaeche:    #141a23;
    --flaeche-2:  #1a212b;
    --flaeche-3:  #222b37;
    --flaeche-inv:#e7edf5;
    --rand:       #2c3644;
    --rand-stark: #3d4a5c;
    --text:       #eef2f7;
    --text-2:     #a9b5c3;
    --text-3:     #7e8b9a;
    --text-inv:   #0f1a2b;
    --gut-bg:   #12301a;
    --warn-bg:  #332a12;
    --ernst-bg: #33231c;
    --krit-bg:  #331a1a;
    --serie-1: #3987e5;
    --serie-2: #d95926;
    --serie-3: #199e70;
    --serie-4: #c98500;
    --serie-5: #d55181;
    --serie-6: #008300;
    --schatten-1: 0 1px 2px rgba(0,0,0,.4);
    --schatten-2: 0 2px 6px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);
    --schatten-3: 0 10px 40px rgba(0,0,0,.6);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --marke-100: #17304f;
  --marke-050: #14263d;
  --marke-400: #3987e5;
  --marke-300: #6da7ec;
  --flaeche:    #141a23;
  --flaeche-2:  #1a212b;
  --flaeche-3:  #222b37;
  --flaeche-inv:#e7edf5;
  --rand:       #2c3644;
  --rand-stark: #3d4a5c;
  --text:       #eef2f7;
  --text-2:     #a9b5c3;
  --text-3:     #7e8b9a;
  --text-inv:   #0f1a2b;
  --gut-bg:   #12301a;
  --warn-bg:  #332a12;
  --ernst-bg: #33231c;
  --krit-bg:  #331a1a;
  --serie-1: #3987e5;
  --serie-2: #d95926;
  --serie-3: #199e70;
  --serie-4: #c98500;
  --serie-5: #d55181;
  --serie-6: #008300;
  --schatten-1: 0 1px 2px rgba(0,0,0,.4);
  --schatten-2: 0 2px 6px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);
  --schatten-3: 0 10px 40px rgba(0,0,0,.6);
}

/* ---------------------------------------------------- Grundlagen */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--schrift);
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
  background: var(--flaeche-2);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { margin: 0; font-weight: 650; line-height: 1.25; letter-spacing: -.01em; }
h1 { font-size: 30px; }
h2 { font-size: 21px; }
h3 { font-size: 17px; }
h4 { font-size: 15px; }
p { margin: 0 0 12px; }
a { color: var(--marke-500); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; }
:focus-visible { outline: 2px solid var(--marke-400); outline-offset: 2px; border-radius: 4px; }

.huelle { max-width: var(--breite); margin: 0 auto; padding: 0 24px; }
.nur-lese { user-select: none; }
.verborgen { display: none !important; }

/* ------------------------------------------------------- Kopfteil */
.kopf {
  position: sticky; top: 0; z-index: 60;
  background: var(--flaeche);
  border-bottom: 1px solid var(--rand);
}
.kopf-reihe {
  height: var(--kopf-h);
  display: flex; align-items: center; gap: 20px;
  max-width: var(--breite); margin: 0 auto; padding: 0 24px;
}
.marke { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; cursor: pointer; background: none; border: 0; padding: 0; color: inherit; }
.marke-zeichen {
  width: 30px; height: 30px; border-radius: 8px; flex: 0 0 auto;
  background: linear-gradient(135deg, var(--marke-400), var(--marke-700));
  display: grid; place-items: center;
}
.marke-zeichen svg { width: 17px; height: 17px; fill: #fff; }
.marke-text { font-weight: 700; font-size: 17px; letter-spacing: .04em; }
.marke-text span { font-weight: 400; color: var(--text-3); letter-spacing: 0; margin-left: 7px; font-size: 12px; }

.kopf-suche { flex: 1 1 auto; max-width: 560px; position: relative; }
.kopf-aktionen { margin-left: auto; display: flex; align-items: center; gap: 8px; }

/* -------------------------------------------------- Navigationsreihe */
.nav {
  background: var(--flaeche);
  border-bottom: 1px solid var(--rand);
  position: sticky; top: var(--kopf-h); z-index: 55;
}
.nav-reihe {
  display: flex; gap: 2px; max-width: var(--breite); margin: 0 auto; padding: 0 24px;
  height: var(--nav-h); align-items: stretch; overflow-x: auto; scrollbar-width: none;
}
.nav-reihe::-webkit-scrollbar { display: none; }
.nav-knopf {
  border: 0; background: none; color: var(--text-2); cursor: pointer;
  padding: 0 14px; font-size: 14px; font-weight: 550; white-space: nowrap;
  border-bottom: 2px solid transparent; display: flex; align-items: center; gap: 7px;
}
.nav-knopf:hover { color: var(--text); background: var(--flaeche-2); }
.nav-knopf[aria-current="page"] { color: var(--marke-500); border-bottom-color: var(--marke-500); }
.nav-zahl {
  background: var(--kritisch); color: #fff; border-radius: 9px; font-size: 11px;
  font-weight: 700; padding: 1px 6px; line-height: 1.5;
}

/* ------------------------------------------------------ Steuerelemente */
.feld, .waehler {
  width: 100%; padding: 9px 12px; border: 1px solid var(--rand-stark);
  border-radius: var(--radius-s); background: var(--flaeche); color: var(--text);
  font-size: 14px; font-family: inherit;
}
.feld:focus, .waehler:focus { border-color: var(--marke-400); outline: 2px solid var(--marke-100); outline-offset: 0; }
.feld::placeholder { color: var(--text-3); }
.feld[aria-invalid="true"] { border-color: var(--kritisch); background: var(--krit-bg); }
.feld-marke { display: block; font-size: 12.5px; font-weight: 600; color: var(--text-2); margin-bottom: 5px; }
.feld-hilfe { font-size: 12px; color: var(--text-3); margin-top: 4px; }
.feld-fehler { font-size: 12px; color: var(--kritisch); margin-top: 4px; font-weight: 550; }
textarea.feld { resize: vertical; min-height: 68px; }

.knopf {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 9px 16px; border-radius: var(--radius-s); border: 1px solid transparent;
  font-size: 14px; font-weight: 600; cursor: pointer; white-space: nowrap;
  background: var(--marke-500); color: #fff; transition: background .12s, border-color .12s;
}
.knopf:hover { background: var(--marke-600); }
.knopf:active { background: var(--marke-700); }
.knopf:disabled { opacity: .45; cursor: not-allowed; }
.knopf-2 { background: var(--flaeche); color: var(--text); border-color: var(--rand-stark); }
.knopf-2:hover { background: var(--flaeche-3); border-color: var(--rand-stark); }
.knopf-3 { background: transparent; color: var(--marke-500); border-color: transparent; padding: 6px 10px; }
.knopf-3:hover { background: var(--marke-050); }
.knopf-gut { background: var(--gut); }
.knopf-gut:hover { background: #0a8a0a; }
.knopf-gefahr { background: var(--flaeche); color: var(--kritisch); border-color: var(--rand-stark); }
.knopf-gefahr:hover { background: var(--krit-bg); border-color: var(--kritisch); }
.knopf-klein { padding: 6px 11px; font-size: 13px; }
.knopf-breit { width: 100%; }
.knopf svg { width: 15px; height: 15px; flex: 0 0 auto; }

.symbolknopf {
  width: 36px; height: 36px; border-radius: var(--radius-s); border: 1px solid transparent;
  background: none; color: var(--text-2); cursor: pointer; display: grid; place-items: center; position: relative;
}
.symbolknopf:hover { background: var(--flaeche-3); color: var(--text); }
.symbolknopf svg { width: 19px; height: 19px; }
.symbolknopf .punkt {
  position: absolute; top: 2px; right: 2px; min-width: 17px; height: 17px; padding: 0 4px;
  background: var(--kritisch); color: #fff; border-radius: 9px; font-size: 11px; font-weight: 700;
  display: grid; place-items: center; line-height: 1;
}

/* ------------------------------------------------------------ Karten */
.karte {
  background: var(--flaeche); border: 1px solid var(--rand);
  border-radius: var(--radius); box-shadow: var(--schatten-1);
}
.karte-kopf { padding: 16px 20px; border-bottom: 1px solid var(--rand); display: flex; align-items: center; gap: 12px; }
.karte-kopf h3 { flex: 1 1 auto; }
.karte-leib { padding: 20px; }
.karte-fuss { padding: 14px 20px; border-top: 1px solid var(--rand); background: var(--flaeche-2); border-radius: 0 0 var(--radius) var(--radius); }

/* ----------------------------------------------------------- Marken */
.mkn {
  display: inline-flex; align-items: center; gap: 5px; padding: 2px 8px;
  border-radius: 20px; font-size: 11.5px; font-weight: 650; line-height: 1.6;
  border: 1px solid transparent; white-space: nowrap;
}
.mkn svg { width: 12px; height: 12px; flex: 0 0 auto; }
.mkn-vertrag  { background: var(--gut-bg);  color: #096b09; border-color: rgba(12,163,12,.3); }
.mkn-preferred{ background: var(--marke-050); color: var(--marke-700); border-color: var(--marke-200); }
.mkn-guenstig { background: var(--flaeche-3); color: var(--text-2); border-color: var(--rand); }
.mkn-warn     { background: var(--warn-bg);  color: #8a5d00; border-color: rgba(250,178,25,.4); }
.mkn-ernst    { background: var(--ernst-bg); color: #9c4218; border-color: rgba(236,131,90,.4); }
.mkn-krit     { background: var(--krit-bg);  color: #a02525; border-color: rgba(208,59,59,.35); }
.mkn-neutral  { background: var(--flaeche-3); color: var(--text-2); border-color: var(--rand); }
:root[data-theme="dark"] .mkn-vertrag, :root[data-theme="dark"] .mkn-warn,
:root[data-theme="dark"] .mkn-ernst, :root[data-theme="dark"] .mkn-krit { color: #fff; }
@media (prefers-color-scheme: dark) {
  :root:where(:not([data-theme="light"])) .mkn-vertrag,
  :root:where(:not([data-theme="light"])) .mkn-warn,
  :root:where(:not([data-theme="light"])) .mkn-ernst,
  :root:where(:not([data-theme="light"])) .mkn-krit { color: #fff; }
}

/* ------------------------------------------------------ Anmeldeseite */
.anmeldung { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.anmeldung-links {
  background: linear-gradient(155deg, #0d1e38 0%, #143a6b 55%, #1c5cab 100%);
  color: #fff; padding: 56px 56px; display: flex; flex-direction: column; justify-content: center;
  position: relative; overflow: hidden;
}
.anmeldung-links::after {
  content: ''; position: absolute; inset: auto -120px -180px auto; width: 460px; height: 460px;
  border-radius: 50%; background: radial-gradient(circle, rgba(85,152,231,.35), transparent 65%);
}
.anmeldung-links > * { position: relative; z-index: 1; }
.anmeldung-marke { display: flex; align-items: center; gap: 11px; margin-bottom: 44px; }
.anmeldung-marke .marke-zeichen { background: rgba(255,255,255,.16); width: 34px; height: 34px; }
.anmeldung-marke .marke-text { color: #fff; font-size: 19px; }
.anmeldung-links h1 { font-size: 36px; line-height: 1.18; margin-bottom: 16px; color: #fff; }
.anmeldung-links .unterzeile { font-size: 16.5px; color: rgba(255,255,255,.8); max-width: 34em; margin-bottom: 36px; }
.merkmal { display: flex; gap: 13px; margin-bottom: 20px; align-items: flex-start; }
.merkmal-zeichen {
  width: 30px; height: 30px; border-radius: 8px; background: rgba(255,255,255,.14);
  display: grid; place-items: center; flex: 0 0 auto; margin-top: 1px;
}
.merkmal-zeichen svg { width: 16px; height: 16px; fill: #fff; }
.merkmal b { display: block; font-size: 14.5px; font-weight: 650; }
.merkmal span { font-size: 13.5px; color: rgba(255,255,255,.72); line-height: 1.5; }
.anmeldung-fuss { margin-top: 40px; font-size: 12.5px; color: rgba(255,255,255,.55); }
.anmeldung-fuss a { color: rgba(255,255,255,.8); text-decoration: underline; }

.anmeldung-rechts {
  background: var(--flaeche); padding: 56px 48px; display: flex; flex-direction: column;
  justify-content: center; overflow-y: auto;
}
.anmeldung-rechts .innen { width: 100%; max-width: 440px; margin: 0 auto; }
.rollenkarte {
  width: 100%; text-align: left; display: flex; gap: 14px; align-items: center;
  padding: 15px 16px; border: 1px solid var(--rand-stark); border-radius: var(--radius);
  background: var(--flaeche); cursor: pointer; margin-bottom: 11px; transition: border-color .12s, box-shadow .12s, transform .08s;
  color: inherit;
}
.rollenkarte:hover { border-color: var(--marke-400); box-shadow: var(--schatten-2); transform: translateY(-1px); }
.kreis {
  width: 42px; height: 42px; border-radius: 50%; flex: 0 0 auto; display: grid; place-items: center;
  font-weight: 700; font-size: 15px; color: #fff; background: var(--marke-600); letter-spacing: .02em;
}
.kreis-klein { width: 30px; height: 30px; font-size: 12px; }
.rollenkarte b { display: block; font-size: 15px; }
.rollenkarte .rolle { font-size: 13px; color: var(--marke-500); font-weight: 600; }
.rollenkarte .wozu { font-size: 12.5px; color: var(--text-3); margin-top: 3px; line-height: 1.45; }
.rollenkarte .pfeil { margin-left: auto; color: var(--text-3); flex: 0 0 auto; }

.trenner { display: flex; align-items: center; gap: 14px; margin: 22px 0; color: var(--text-3); font-size: 12.5px; }
.trenner::before, .trenner::after { content: ''; flex: 1; height: 1px; background: var(--rand); }

/* -------------------------------------------------------- Startseite */
.held {
  background: linear-gradient(160deg, #0d1e38, #164379 70%, #1c5cab);
  color: #fff; padding: 46px 0 54px; margin-bottom: -34px;
}
.held h1 { color: #fff; font-size: 27px; margin-bottom: 6px; }
.held .unterzeile { color: rgba(255,255,255,.76); font-size: 15px; margin-bottom: 26px; }

.suchleiste { position: relative; }
.suchleiste input {
  width: 100%; padding: 15px 128px 15px 46px; font-size: 16px; border-radius: 12px;
  border: 1px solid transparent; background: var(--flaeche); color: var(--text); font-family: inherit;
  box-shadow: var(--schatten-2);
}
.suchleiste input:focus { outline: 3px solid rgba(85,152,231,.45); }
.suchleiste .lupe { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--text-3); pointer-events: none; }
.suchleiste .lupe svg { width: 19px; height: 19px; display: block; }
.suchleiste .absenden { position: absolute; right: 7px; top: 50%; transform: translateY(-50%); }
.kopf-suche input { padding: 8px 12px 8px 36px; font-size: 14px; border-radius: var(--radius-s); border: 1px solid var(--rand-stark); background: var(--flaeche-2); color: var(--text); width: 100%; font-family: inherit; }
.kopf-suche .lupe { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--text-3); pointer-events: none; }
.kopf-suche .lupe svg { width: 16px; height: 16px; display: block; }

.schnellzeile { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; align-items: center; }
.schnellzeile .titel { font-size: 12.5px; color: rgba(255,255,255,.6); margin-right: 2px; }
.pille {
  border: 1px solid rgba(255,255,255,.28); background: rgba(255,255,255,.1); color: #fff;
  padding: 5px 12px; border-radius: 20px; font-size: 13px; cursor: pointer; font-family: inherit;
}
.pille:hover { background: rgba(255,255,255,.2); }

.kachelgitter { display: grid; grid-template-columns: repeat(auto-fill, minmax(178px, 1fr)); gap: 14px; }
.kachel {
  background: var(--flaeche); border: 1px solid var(--rand); border-radius: var(--radius);
  padding: 18px 16px; cursor: pointer; text-align: left; transition: border-color .12s, box-shadow .12s, transform .08s;
  box-shadow: var(--schatten-1); color: inherit; font-family: inherit;
}
.kachel:hover { border-color: var(--marke-400); box-shadow: var(--schatten-2); transform: translateY(-2px); }
.kachel-zeichen {
  width: 40px; height: 40px; border-radius: 10px; background: var(--marke-050);
  color: var(--marke-500); display: grid; place-items: center; margin-bottom: 12px;
}
.kachel-zeichen svg { width: 21px; height: 21px; }
.kachel b { display: block; font-size: 14.5px; }
.kachel span { font-size: 12.5px; color: var(--text-3); }

.abschnitt { padding: 34px 0; }
.abschnitt-kopf { display: flex; align-items: baseline; gap: 12px; margin-bottom: 16px; }
.abschnitt-kopf h2 { flex: 0 0 auto; }
.abschnitt-kopf .hinweis { font-size: 13.5px; color: var(--text-3); }
.abschnitt-kopf .rechts { margin-left: auto; }

/* --------------------------------------------------------- Assistent */
.assistent {
  background: var(--flaeche); border: 1px solid var(--marke-200); border-radius: var(--radius-l);
  padding: 20px; box-shadow: var(--schatten-1);
}
.assistent-kopf { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.assistent-kopf .zeichen { width: 30px; height: 30px; border-radius: 8px; background: var(--marke-050); color: var(--marke-500); display: grid; place-items: center; }
.assistent-kopf .zeichen svg { width: 17px; height: 17px; }
.assistent-kopf b { font-size: 15px; }
.assistent-kopf .mkn { margin-left: auto; }
.assistent-eingabe { display: flex; gap: 10px; }
.assistent-eingabe .feld { flex: 1; }
.assistent-beispiele { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 11px; }
.assistent-beispiele button {
  border: 1px dashed var(--rand-stark); background: var(--flaeche-2); color: var(--text-2);
  padding: 4px 11px; border-radius: 20px; font-size: 12.5px; cursor: pointer; font-family: inherit;
}
.assistent-beispiele button:hover { border-color: var(--marke-400); color: var(--marke-500); border-style: solid; }

.deutung { margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--rand); }
.deutung-zeile { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; }
.deutung-marke { font-size: 12.5px; color: var(--text-3); margin-right: 3px; }
.deutung-wert {
  background: var(--marke-050); color: var(--marke-700); border: 1px solid var(--marke-200);
  padding: 3px 10px; border-radius: 6px; font-size: 12.5px; font-weight: 600;
}
.deutung-wert i { font-style: normal; color: var(--marke-500); opacity: .75; font-weight: 500; }

/* ----------------------------------------------------- Suchergebnis */
.such-layout { display: grid; grid-template-columns: 236px 1fr; gap: 26px; align-items: start; }
.filter { position: sticky; top: calc(var(--kopf-h) + var(--nav-h) + 16px); }
.filter-block { margin-bottom: 22px; }
.filter-block h4 { font-size: 12.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--text-3); margin-bottom: 9px; }
.filter-zeile { display: flex; align-items: center; gap: 9px; padding: 4px 0; font-size: 13.5px; cursor: pointer; color: var(--text-2); }
.filter-zeile:hover { color: var(--text); }
.filter-zeile input { width: 15px; height: 15px; accent-color: var(--marke-500); flex: 0 0 auto; margin: 0; }
.filter-zeile .zahl { margin-left: auto; color: var(--text-3); font-size: 12px; }

.hinweisbalken {
  display: flex; gap: 13px; align-items: flex-start; padding: 14px 16px; border-radius: var(--radius);
  border: 1px solid var(--marke-200); background: var(--marke-050); margin-bottom: 18px;
}
.hinweisbalken .zeichen { color: var(--marke-500); flex: 0 0 auto; margin-top: 1px; }
.hinweisbalken .zeichen svg { width: 19px; height: 19px; display: block; }
.hinweisbalken b { display: block; font-size: 14px; margin-bottom: 2px; }
.hinweisbalken p { margin: 0; font-size: 13.5px; color: var(--text-2); }

.treffer { margin-bottom: 18px; overflow: hidden; }
.treffer-kopf { display: flex; gap: 16px; padding: 18px 20px; align-items: flex-start; }
.artikelbild {
  width: 76px; height: 76px; border-radius: var(--radius-s); background: var(--flaeche-3);
  display: grid; place-items: center; flex: 0 0 auto; color: var(--text-3); border: 1px solid var(--rand);
}
.artikelbild svg { width: 34px; height: 34px; }
.artikelbild-gross { width: 150px; height: 150px; }
.artikelbild-gross svg { width: 62px; height: 62px; }
.artikelbild-klein { width: 46px; height: 46px; }
.artikelbild-klein svg { width: 22px; height: 22px; }
.treffer-kopf .titel { flex: 1 1 auto; min-width: 0; }
.treffer-kopf .titel h3 { margin-bottom: 3px; }
.treffer-kopf .titel h3 button { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-align: left; }
.treffer-kopf .titel h3 button:hover { color: var(--marke-500); }
.marke-zeile { font-size: 13px; color: var(--text-2); margin-bottom: 7px; }
.meta-zeile { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12.5px; color: var(--text-3); }
.meta-zeile b { color: var(--text-2); font-weight: 600; }

.quellen { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.quellen thead th {
  text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em;
  color: var(--text-3); font-weight: 650; padding: 9px 14px; background: var(--flaeche-2);
  border-top: 1px solid var(--rand); border-bottom: 1px solid var(--rand); white-space: nowrap;
}
.quellen tbody td { padding: 12px 14px; border-bottom: 1px solid var(--rand); vertical-align: middle; }
.quellen tbody tr:last-child td { border-bottom: 0; }
.quellen tbody tr.empfohlen { background: var(--gut-bg); }
.quellen tbody tr:hover { background: var(--flaeche-2); }
.quellen tbody tr.empfohlen:hover { background: var(--gut-bg); filter: brightness(.985); }
.quellen .lieferant b { display: block; font-weight: 600; }
.quellen .lieferant span { font-size: 12px; color: var(--text-3); }
.preis { font-size: 16px; font-weight: 680; white-space: nowrap; font-variant-numeric: tabular-nums; }
.preis small { font-size: 11.5px; font-weight: 500; color: var(--text-3); display: block; }
.preis-durch { text-decoration: line-through; color: var(--text-3); font-weight: 500; font-size: 12.5px; }
.td-rechts { text-align: right; }
.td-eng { width: 1%; white-space: nowrap; }

.alternativen { margin-top: 26px; }
.alt-gitter { display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr)); gap: 14px; }
.alt-karte { display: flex; gap: 13px; padding: 15px; align-items: flex-start; }
.alt-karte .titel { flex: 1; min-width: 0; }
.alt-karte b { font-size: 14px; display: block; line-height: 1.35; }
.alt-karte .marke-zeile { margin-bottom: 6px; font-size: 12.5px; }

/* ------------------------------------------------------ Artikelseite */
.artikel-layout { display: grid; grid-template-columns: 1fr 320px; gap: 26px; align-items: start; }
.reiter { display: flex; gap: 2px; border-bottom: 1px solid var(--rand); margin-bottom: 18px; overflow-x: auto; scrollbar-width: none; }
.reiter::-webkit-scrollbar { display: none; }
.reiter button {
  border: 0; background: none; color: var(--text-2); cursor: pointer; padding: 9px 14px;
  font-size: 14px; font-weight: 550; border-bottom: 2px solid transparent; white-space: nowrap; font-family: inherit;
}
.reiter button:hover { color: var(--text); }
.reiter button[aria-selected="true"] { color: var(--marke-500); border-bottom-color: var(--marke-500); }

.daten { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.daten td { padding: 9px 0; border-bottom: 1px solid var(--rand); vertical-align: top; }
.daten td:first-child { color: var(--text-3); width: 44%; padding-right: 16px; }
.daten tr:last-child td { border-bottom: 0; }

.preisbox { position: sticky; top: calc(var(--kopf-h) + var(--nav-h) + 16px); }
.preis-gross { font-size: 27px; font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums; }
.mengenwahl { display: flex; align-items: center; gap: 0; border: 1px solid var(--rand-stark); border-radius: var(--radius-s); overflow: hidden; width: fit-content; }
.mengenwahl button { width: 34px; height: 36px; border: 0; background: var(--flaeche-2); color: var(--text-2); cursor: pointer; font-size: 17px; line-height: 1; }
.mengenwahl button:hover { background: var(--flaeche-3); color: var(--text); }
.mengenwahl input { width: 58px; height: 36px; border: 0; border-left: 1px solid var(--rand); border-right: 1px solid var(--rand); text-align: center; font-size: 14px; background: var(--flaeche); color: var(--text); font-family: inherit; }
.mengenwahl input::-webkit-outer-spin-button, .mengenwahl input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.mengenwahl input { -moz-appearance: textfield; appearance: textfield; }

/* ------------------------------------------------------- Warenkorb */
.korb-layout { display: grid; grid-template-columns: 1fr 320px; gap: 26px; align-items: start; }
.korb-zeile { display: flex; gap: 15px; padding: 17px 20px; border-bottom: 1px solid var(--rand); align-items: flex-start; }
.korb-zeile:last-child { border-bottom: 0; }
.korb-zeile .titel { flex: 1 1 auto; min-width: 0; }
.korb-zeile .titel b { font-size: 14.5px; display: block; line-height: 1.35; }
.korb-summe { position: sticky; top: calc(var(--kopf-h) + var(--nav-h) + 16px); }
.summenzeile { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; padding: 6px 0; }
.summenzeile.gesamt { font-size: 18px; font-weight: 700; border-top: 1px solid var(--rand); margin-top: 8px; padding-top: 13px; }
.summenzeile .wert { font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ------------------------------------------------------ Schrittleiste */
.schritte { display: flex; gap: 0; margin-bottom: 26px; overflow-x: auto; scrollbar-width: none; }
.schritte::-webkit-scrollbar { display: none; }
.schritt { display: flex; align-items: center; gap: 9px; padding: 0 20px 0 0; white-space: nowrap; }
.schritt + .schritt { padding-left: 20px; }
.schritt + .schritt::before { content: ''; width: 22px; height: 1px; background: var(--rand-stark); margin-left: -20px; margin-right: 18px; }
.schritt .nr {
  width: 25px; height: 25px; border-radius: 50%; display: grid; place-items: center;
  font-size: 12.5px; font-weight: 700; background: var(--flaeche-3); color: var(--text-3); flex: 0 0 auto;
}
.schritt .txt { font-size: 13.5px; color: var(--text-3); font-weight: 550; }
.schritt.aktiv .nr { background: var(--marke-500); color: #fff; }
.schritt.aktiv .txt { color: var(--text); }
.schritt.erledigt .nr { background: var(--gut); color: #fff; }
.schritt.erledigt .txt { color: var(--text-2); }

/* ------------------------------------------------------- Kontierung */
.kont-position { border-bottom: 1px solid var(--rand); padding: 18px 20px; }
.kont-position:last-child { border-bottom: 0; }
.kont-kopf { display: flex; gap: 13px; align-items: flex-start; margin-bottom: 15px; }
.kont-gitter { display: grid; grid-template-columns: repeat(auto-fit, minmax(178px, 1fr)); gap: 14px; }
.kont-gitter .voll { grid-column: 1 / -1; }

/* ------------------------------------------------------ Prüfergebnis */
.pruefung { display: flex; gap: 14px; padding: 16px 18px; border-bottom: 1px solid var(--rand); align-items: flex-start; }
.pruefung:last-child { border-bottom: 0; }
.pruef-zeichen { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; flex: 0 0 auto; margin-top: 1px; }
.pruef-zeichen svg { width: 15px; height: 15px; }
.pruef-gut  { background: var(--gut-bg);  color: #096b09; }
.pruef-warn { background: var(--warn-bg); color: #8a5d00; }
.pruef-krit { background: var(--krit-bg); color: #a02525; }
:root[data-theme="dark"] .pruef-gut, :root[data-theme="dark"] .pruef-warn, :root[data-theme="dark"] .pruef-krit { color: #fff; }
@media (prefers-color-scheme: dark) {
  :root:where(:not([data-theme="light"])) .pruef-gut,
  :root:where(:not([data-theme="light"])) .pruef-warn,
  :root:where(:not([data-theme="light"])) .pruef-krit { color: #fff; }
}
.pruefung .inhalt { flex: 1 1 auto; min-width: 0; }
.pruefung b { font-size: 14px; display: block; }
.pruefung p { font-size: 13.5px; color: var(--text-2); margin: 3px 0 0; }
.pruefung .tat { margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; }

.balken { height: 7px; border-radius: 4px; background: var(--flaeche-3); overflow: hidden; }
.balken > i { display: block; height: 100%; border-radius: 4px; background: var(--marke-500); }
.balken.warnend > i { background: var(--warn); }
.balken.kritisch > i { background: var(--kritisch); }

/* ------------------------------------------------------- Freigabekette */
.kette { display: flex; flex-direction: column; gap: 0; }
.kette-glied { display: flex; gap: 14px; position: relative; padding-bottom: 20px; }
.kette-glied:last-child { padding-bottom: 0; }
.kette-glied::before {
  content: ''; position: absolute; left: 14px; top: 32px; bottom: 0; width: 2px; background: var(--rand);
}
.kette-glied:last-child::before { display: none; }
.kette-punkt {
  width: 30px; height: 30px; border-radius: 50%; flex: 0 0 auto; display: grid; place-items: center;
  background: var(--flaeche-3); color: var(--text-3); font-size: 12px; font-weight: 700; z-index: 1;
  border: 2px solid var(--flaeche);
}
.kette-punkt.erledigt { background: var(--gut); color: #fff; }
.kette-punkt.aktiv { background: var(--marke-500); color: #fff; }
.kette-glied .inhalt { flex: 1; padding-top: 3px; }
.kette-glied b { font-size: 14px; }
.kette-glied span { font-size: 12.5px; color: var(--text-3); display: block; }

/* ---------------------------------------------------------- Tabelle */
.tabelle { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tabelle thead th {
  text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em;
  color: var(--text-3); font-weight: 650; padding: 11px 16px; border-bottom: 1px solid var(--rand); white-space: nowrap;
}
.tabelle tbody td { padding: 13px 16px; border-bottom: 1px solid var(--rand); vertical-align: middle; }
.tabelle tbody tr:last-child td { border-bottom: 0; }
.tabelle tbody tr.klickbar { cursor: pointer; }
.tabelle tbody tr.klickbar:hover { background: var(--flaeche-2); }
.mono { font-family: var(--schrift-mono); font-size: 12.5px; }

/* -------------------------------------------------------- Kennzahlen */
.kpi-gitter { display: grid; grid-template-columns: repeat(auto-fit, minmax(196px, 1fr)); gap: 14px; }
.kpi { padding: 17px 18px; }
.kpi .marke { font-size: 12.5px; color: var(--text-3); margin-bottom: 6px; display: block; }
.kpi .wert { font-size: 27px; font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums; }
.kpi .fuss { font-size: 12.5px; color: var(--text-3); margin-top: 5px; }
.kpi .fuss b { color: var(--gut); }
.kpi .fuss b.schlecht { color: var(--kritisch); }

.diagramm-gitter { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 18px; }
.diagramm { position: relative; }
.diagramm svg { display: block; width: 100%; height: auto; overflow: visible; }
.achse-text { font-size: 11px; fill: var(--text-3); font-family: var(--schrift); }
.wert-text { font-size: 11.5px; fill: var(--text-2); font-family: var(--schrift); font-weight: 600; }
.gitternetz { stroke: var(--rand); stroke-width: 1; }
.legende { display: flex; flex-wrap: wrap; gap: 7px 16px; font-size: 12.5px; color: var(--text-2); margin-top: 12px; }
.legende span { display: inline-flex; align-items: center; gap: 6px; }
.legende i { width: 11px; height: 11px; border-radius: 3px; display: inline-block; flex: 0 0 auto; }

.diagramm-wolke {
  position: absolute; pointer-events: none; background: var(--flaeche-inv); color: var(--flaeche);
  padding: 7px 10px; border-radius: 6px; font-size: 12.5px; line-height: 1.45; box-shadow: var(--schatten-2);
  opacity: 0; transition: opacity .1s; z-index: 5; white-space: nowrap; transform: translate(-50%, -100%); margin-top: -8px;
}
.diagramm-wolke.sichtbar { opacity: 1; }
.diagramm-wolke b { color: var(--flaeche); }

/* -------------------------------------------------------- Schnittstellen */
.schnitt-gitter { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.schnitt-karte { padding: 17px 18px; cursor: pointer; text-align: left; font-family: inherit; color: inherit; display: flex; flex-direction: column; gap: 9px; transition: border-color .12s, box-shadow .12s, transform .08s; }
.schnitt-karte:hover { border-color: var(--marke-400); box-shadow: var(--schatten-2); transform: translateY(-2px); }
.schnitt-karte .oben { display: flex; align-items: center; gap: 9px; }
.schnitt-karte .oben b { font-size: 14.5px; flex: 1; line-height: 1.35; }
.schnitt-karte p { font-size: 13px; color: var(--text-2); margin: 0; }
.schnitt-karte .richtung { font-size: 12px; color: var(--text-3); font-family: var(--schrift-mono); }

/* -------------------------------------------------------- Überlagerung */
.ueberlagerung {
  position: fixed; inset: 0; z-index: 200; background: rgba(9, 17, 30, .55);
  display: flex; align-items: center; justify-content: center; padding: 24px;
  opacity: 0; pointer-events: none; transition: opacity .15s;
  backdrop-filter: blur(2px);
}
.ueberlagerung.offen { opacity: 1; pointer-events: auto; }
.dialog {
  background: var(--flaeche); border-radius: var(--radius-l); box-shadow: var(--schatten-3);
  width: 100%; max-width: 620px; max-height: calc(100vh - 48px); display: flex; flex-direction: column;
  transform: translateY(8px) scale(.99); transition: transform .15s;
}
.ueberlagerung.offen .dialog { transform: none; }
.dialog-breit { max-width: 860px; }
.dialog-kopf { padding: 20px 24px 16px; display: flex; gap: 14px; align-items: flex-start; border-bottom: 1px solid var(--rand); }
.dialog-kopf .zeichen { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; flex: 0 0 auto; background: var(--marke-050); color: var(--marke-500); }
.dialog-kopf .zeichen svg { width: 20px; height: 20px; }
.dialog-kopf .zeichen.gut { background: var(--gut-bg); color: #096b09; }
.dialog-kopf .zeichen.warn { background: var(--warn-bg); color: #8a5d00; }
:root[data-theme="dark"] .dialog-kopf .zeichen.gut, :root[data-theme="dark"] .dialog-kopf .zeichen.warn { color: #fff; }
@media (prefers-color-scheme: dark) {
  :root:where(:not([data-theme="light"])) .dialog-kopf .zeichen.gut,
  :root:where(:not([data-theme="light"])) .dialog-kopf .zeichen.warn { color: #fff; }
}
.dialog-kopf .titel { flex: 1; min-width: 0; }
.dialog-kopf h3 { font-size: 17px; margin-bottom: 2px; }
.dialog-kopf .unter { font-size: 13px; color: var(--text-3); }
.dialog-leib { padding: 20px 24px; overflow-y: auto; }
.dialog-fuss { padding: 15px 24px; border-top: 1px solid var(--rand); display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; background: var(--flaeche-2); border-radius: 0 0 var(--radius-l) var(--radius-l); }
.dialog-fuss .links { margin-right: auto; }

.attrappe-fahne {
  display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius-s);
  background: var(--warn-bg); border: 1px solid rgba(250,178,25,.45); margin-bottom: 16px; font-size: 13.5px;
}
.attrappe-fahne svg { width: 17px; height: 17px; flex: 0 0 auto; color: #8a5d00; margin-top: 2px; }
:root[data-theme="dark"] .attrappe-fahne svg { color: var(--warn); }
@media (prefers-color-scheme: dark) { :root:where(:not([data-theme="light"])) .attrappe-fahne svg { color: var(--warn); } }
.attrappe-fahne b { display: block; }

.nutzlast {
  background: var(--flaeche-inv); color: #cfe3ff; border-radius: var(--radius-s); padding: 14px 16px;
  font-family: var(--schrift-mono); font-size: 12px; line-height: 1.65; overflow-x: auto;
  white-space: pre; margin: 0;
}
:root[data-theme="dark"] .nutzlast { background: #0a1018; }
@media (prefers-color-scheme: dark) { :root:where(:not([data-theme="light"])) .nutzlast { background: #0a1018; } }

.merkliste { list-style: none; margin: 0; padding: 0; }
.merkliste li { position: relative; padding-left: 22px; margin-bottom: 9px; font-size: 13.5px; color: var(--text-2); line-height: 1.5; }
.merkliste li::before {
  content: ''; position: absolute; left: 4px; top: 8px; width: 6px; height: 6px; border-radius: 50%;
  background: var(--marke-400);
}

.faktenliste { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 18px; }
.fakt { background: var(--flaeche-2); border: 1px solid var(--rand); border-radius: var(--radius-s); padding: 11px 13px; }
.fakt .marke { display: block; font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--text-3); margin-bottom: 3px; }
.fakt .wert { font-size: 13.5px; font-weight: 600; word-break: break-word; }

/* ---------------------------------------------------------- Meldung */
.meldungen { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 300; display: flex; flex-direction: column; gap: 9px; align-items: center; pointer-events: none; }
.meldung {
  background: var(--flaeche-inv); color: var(--flaeche); padding: 11px 17px; border-radius: 30px;
  font-size: 13.5px; font-weight: 550; box-shadow: var(--schatten-2); display: flex; align-items: center; gap: 9px;
  animation: hoch .22s ease-out;
}
.meldung svg { width: 16px; height: 16px; flex: 0 0 auto; }
@keyframes hoch { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* ------------------------------------------------------------- Leer */
.leer { text-align: center; padding: 56px 24px; color: var(--text-3); }
.leer svg { width: 44px; height: 44px; margin-bottom: 14px; opacity: .45; }
.leer b { display: block; font-size: 16px; color: var(--text-2); margin-bottom: 5px; }
.leer p { font-size: 13.5px; max-width: 34em; margin: 0 auto 16px; }

/* --------------------------------------------------------- Fußzeile */
.fuss { border-top: 1px solid var(--rand); background: var(--flaeche); margin-top: 44px; padding: 22px 0; }
.fuss-reihe { display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center; font-size: 12.5px; color: var(--text-3); }
.fuss-reihe .rechts { margin-left: auto; display: flex; gap: 16px; align-items: center; }

/* ------------------------------------------------------ Hilfsklassen */
.reihe { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.reihe-eng { gap: 6px; }
.spalte { display: flex; flex-direction: column; gap: 10px; }
.wachs { flex: 1 1 auto; min-width: 0; }
.rechts { margin-left: auto; }
.mini { font-size: 12.5px; color: var(--text-3); }
.stumm { color: var(--text-3); }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: 8px; } .mb-2 { margin-bottom: 16px; } .mb-3 { margin-bottom: 24px; }
.zentriert { text-align: center; }

/* ----------------------------------------------------- Kleine Geräte */
@media (max-width: 980px) {
  .anmeldung { grid-template-columns: 1fr; }
  .anmeldung-links { padding: 36px 24px 30px; }
  .anmeldung-links h1 { font-size: 27px; }
  .anmeldung-links .merkmal:nth-child(n+4) { display: none; }
  .anmeldung-rechts { padding: 32px 24px 48px; }
  .such-layout, .artikel-layout, .korb-layout { grid-template-columns: 1fr; }
  .filter, .preisbox, .korb-summe { position: static; }
  .kopf-suche { display: none; }
}
@media (max-width: 680px) {
  body { font-size: 14.5px; }
  .huelle, .kopf-reihe, .nav-reihe { padding-left: 16px; padding-right: 16px; }
  h1 { font-size: 24px; }
  .held { padding: 28px 0 40px; }
  .held h1 { font-size: 22px; }
  .suchleiste input { padding: 13px 14px 13px 42px; font-size: 15px; }
  .suchleiste .absenden { display: none; }
  .treffer-kopf { flex-wrap: wrap; }
  .quellen thead { display: none; }
  .quellen tbody tr { display: block; border-bottom: 1px solid var(--rand); padding: 12px 14px; }
  .quellen tbody td { display: block; border: 0; padding: 3px 0; }
  .quellen tbody td.td-rechts { text-align: left; }
  .quellen tbody td[data-marke]::before {
    content: attr(data-marke) ': '; font-size: 11.5px; text-transform: uppercase;
    letter-spacing: .04em; color: var(--text-3); font-weight: 650;
  }
  .quellen tbody td.ohne-marke::before { content: none; }
  .dialog-fuss { flex-direction: column-reverse; }
  .dialog-fuss .knopf { width: 100%; }
  .dialog-fuss .links { margin-right: 0; }
  .kachelgitter { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .fuss-reihe .rechts { margin-left: 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

@media print {
  .kopf, .nav, .fuss, .knopf, .meldungen { display: none !important; }
}

/* ------------------------------------------------ Diagramme (HTML-Balken) */
.balkenliste { display: flex; flex-direction: column; gap: 3px; }
.bz {
  display: grid; grid-template-columns: minmax(84px, 172px) 1fr auto;
  align-items: center; gap: 12px; padding: 5px 6px; border-radius: 6px;
}
.bz:hover { background: var(--flaeche-2); }
.bz-marke { font-size: 13px; color: var(--text-2); line-height: 1.3; }
.bz-bahn { display: block; height: 16px; min-width: 20px; }
.bz-bahn > i { display: block; height: 100%; border-radius: 4px; background: var(--serie-1); }
.bz-bahn > i.serie-2 { background: var(--serie-2); }
.bz-wert { font-size: 13px; font-weight: 650; color: var(--text); white-space: nowrap; font-variant-numeric: tabular-nums; }
.bz-wert small { display: block; font-weight: 400; font-size: 11.5px; color: var(--text-3); }

.verlauf { position: relative; padding-left: 44px; }
.vl-y {
  position: absolute; left: 0; top: 0; height: 132px; width: 40px;
  display: flex; flex-direction: column; justify-content: space-between;
  text-align: right; font-size: 11.5px; color: var(--text-3); font-variant-numeric: tabular-nums;
}
.vl-y span { line-height: 1; }
.vl-plot { position: relative; height: 132px; }
.vl-plot svg { display: block; width: 100%; height: 132px; }
.vl-treffer { position: absolute; inset: 0; display: flex; }
.vl-treffer .vl-feld { flex: 1; }
.vl-x { display: flex; margin-top: 7px; }
.vl-x span { flex: 1; text-align: center; font-size: 11.5px; color: var(--text-3); }
.vl-letzter { margin-top: 10px; font-size: 12.5px; color: var(--text-3); }
.vl-letzter b { color: var(--text); }

@media (max-width: 680px) {
  .bz { grid-template-columns: 1fr auto; gap: 4px 10px; padding: 7px 4px; }
  .bz-marke { grid-column: 1; }
  .bz-wert { grid-column: 2; text-align: right; }
  .bz-bahn { grid-column: 1 / -1; }
  .vl-x span:nth-child(even) { visibility: hidden; }
}

/* ------------------------------------- Nachbesserungen für kleine Geräte */
.abschnitt-kopf { flex-wrap: wrap; }
@media (max-width: 760px) {
  /* Der Rollen-Chip bricht sonst dreizeilig um und schiebt sich über die Navigation. */
  .kopf-aktionen .rollenkarte { padding: 3px !important; gap: 0 !important; }
  .kopf-aktionen .rollenkarte > span:not(.kreis) { display: none; }
  .kopf-reihe { gap: 10px; }
  .marke-text span { display: none; }
}
@media (max-width: 400px) {
  .marke-text { font-size: 15px; }
  .abschnitt-kopf .hinweis, .abschnitt-kopf .mini { flex-basis: 100%; }
}

/* Breite Tabellen dürfen auf schmalen Geräten rollen – aber nur sie,
   nicht die ganze Seite. Sonst wandert die Navigation aus dem Bild. */
@media (max-width: 860px) {
  .karte { overflow-x: auto; }
  .karte.diagramm, .karte.preisbox, .karte.korb-summe { overflow: visible; }
  .tabelle { min-width: 100%; }
  .daten td:first-child { width: auto; min-width: 9em; }
}

/* Rasterkinder dürfen nie breiter werden als ihre Spalte – sonst schiebt
   ein einzelner langer Text die ganze Seite auf. Der klassische Grid-Fallstrick. */
.such-layout > *, .artikel-layout > *, .korb-layout > *,
.kachelgitter > *, .alt-gitter > *, .schnitt-gitter > *,
.kpi-gitter > *, .diagramm-gitter > *, .kont-gitter > *, .faktenliste > * { min-width: 0; }
.karte-leib, .karte-kopf, .karte-fuss { min-width: 0; }
.wachs, .titel, .inhalt { min-width: 0; }

/* Überschriften in Abschnittsköpfen müssen umbrechen dürfen. */
.abschnitt-kopf h2, .abschnitt-kopf h1 { flex: 1 1 auto; min-width: 0; overflow-wrap: break-word; }
