/* Inter, self-hosted. scaliento.com runs Inter and Archivo, so "no webfont" was
   never a brand rule - but it loads them from fonts.googleapis.com, which makes
   them consent-bound and renders an Arial fallback until someone agrees. Serving
   the files ourselves removes the CDN, the consent question and the flash.
   Variable font, weights 400 to 700 in one file per subset. SIL OFL 1.1. */

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url("fonts/inter-latin-ext.woff2") format("woff2");
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
        U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
        U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url("fonts/inter-latin.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
        U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191,
        U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* OPEN SANS FÜR LIAS BÜHNE (itm-722): die Schrift von Scaliento, damit Hub und Scaliento-Rahmen eine Familie sprechen. Ebenfalls
   selbst ausgeliefert (aus dem ISI-Bestand, Apache 2.0, fonts/open-sans/LICENSE.txt), nur die fünf Schnitte, die die Bühne
   braucht; die Konsole bleibt bei Inter. */
@font-face {
    font-family: "Open Sans";
    font-style: normal;
    font-weight: 300;
    font-display: swap;
    src: url("fonts/open-sans/OpenSans-Light.ttf") format("truetype");
}

@font-face {
    font-family: "Open Sans";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("fonts/open-sans/OpenSans-Regular.ttf") format("truetype");
}

@font-face {
    font-family: "Open Sans";
    font-style: italic;
    font-weight: 400;
    font-display: swap;
    src: url("fonts/open-sans/OpenSans-Italic.ttf") format("truetype");
}

@font-face {
    font-family: "Open Sans";
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url("fonts/open-sans/OpenSans-SemiBold.ttf") format("truetype");
}

@font-face {
    font-family: "Open Sans";
    font-style: normal;
    font-weight: 700 800;
    font-display: swap;
    src: url("fonts/open-sans/OpenSans-Bold.ttf") format("truetype");
}

/* Lukmann CI in an administration interface.
   Colours and the one-accent rule follow .claude/agents/cino.md. The measurements
   there describe lukmann.com - a marketing page - and are deliberately not used
   here: a 40px title for the word "Übersicht" costs half the first screen without
   carrying information, and em radii produce a different rounding in every element.
   What stays binding: navy leads, orange carries exactly one thing per view, no
   capitals, no letter-spacing. */

:root {
    color-scheme: light;

    /* DIE PALETTE DES WERKBANK-ENTWURFS (itm-174, docs/ui/ui-konsole.html).
       
       Sie ist jetzt die einzige. Die alten Namen stehen weiter unten als Aliase
       darauf - sonst hätte die Konsole während des Umbaus zwei Paletten
       nebeneinander, und der Übergang von einer umgestellten auf eine noch nicht
       umgestellte Seite sähe aus wie ein Fehler.
       
       Zwei Werte sind dabei bewusst anders als bisher: Das Orange ist von #F39313
       auf #E8870C gewandert und hat mit --accent-ink einen dunklen Partner für
       Text bekommen. cino hatte 2,3:1 auf Weiß bemängelt; auf farbigem Grund trägt
       jetzt --accent-ink die Schrift. Und der Seitengrund ist heller. */
    --paper: #F6F7FA;
    --surface: #FFFFFF;
    --surface-2: #EEF1F6;
    --surface-3: #E4E9F1;
    --line: #DCE1EA;
    --line-soft: #E9EDF3;
    --ink: #171B33;
    --ink-2: #545C74;
    --ink-3: #5E6780;
    --brand: #272B5B;
    --on-brand: #FFFFFF;
    --accent: #E8870C;
    --accent-soft: #FDF1DF;
    --accent-ink: #A65B00;

    /* SCHRIFT AUF DER ORANGEN FLÄCHE, und zwar in BEIDEN Modi dieselbe (itm-205).

       `--accent-ink` ist der dunkle Partner für Text NEBEN dem Akzent, auf hellem
       Grund. Auf dem Akzent selbst taugt er nur im Hellmodus: Im Dunkelmodus trägt
       er denselben Wert wie `--accent`, und der Knopf wurde dadurch zu einer
       orangefarbenen Fläche mit orangefarbener Schrift darauf - beim ersten Blick
       in den Dunkelmodus genau so aufgetreten.

       Der Akzent ist in beiden Modi ein helles Orange (#E8870C bzw. #F5A93C), also
       trägt ein dunkler Ton die Schrift in beiden. Deshalb steht dieser Wert
       ausdrücklich NICHT im Dunkelmodus-Block weiter unten. */
    --on-accent: #171B33;

    /* Vier Zustände, die es bisher nicht gab. Ohne sie hat jede Seite ihr eigenes
       Grün und ihr eigenes Rot erfunden - beim Roten waren es vier Töne für
       dieselbe Aussage. */
    --ok: #16764F;
    --ok-soft: #E4F3EC;

    /* NACHGERECHNET UND KORRIGIERT (itm-206). Der Warnton stand auf #A65B00 und
       erreichte auf seinem eigenen weichen Grund 4,43:1 - knapp unter den 4,5, die
       für Text dieser Größe gelten. Er trägt in der rechten Spalte die wichtigste
       Auskunft der Seite („1 Quelle wird nicht durchsucht"), also ist knapp daneben
       hier nicht gut genug.
       Jetzt 4,87:1 auf dem weichen Grund und 5,6:1 auf Weiß.

       SEIT itm-244 IST ES DERSELBE TON WIE `--accent-ink`, und zwar nicht mehr
       „ungefähr", sondern buchstäblich.

       BEFUND cino, 24.09.2026: zwei Orange auf einem Bildschirm. Nachgemessen war es
       enger als das — es waren ZWEI TOKEN MIT FAST DEMSELBEN WERT FÜR DIESELBE
       AUFGABE: hell #9C5600 gegen #A65B00, dunkel #E3A74E gegen #F5A93C, und die
       weichen Flächen unterschieden sich um zwei Stufen im Grün.

       Genau das liest sich als Fehler: Ein Unterschied, den man sieht und nicht
       benennen kann, wirkt wie eine Unachtsamkeit. Zwei klar verschiedene Töne wären
       eine Aussage gewesen, ein fast gleicher ist keine.

       DIE NAMEN BLEIBEN, weil sie verschiedene Rollen tragen: `--accent-ink` ist
       Schrift neben dem Akzent, `--warn` ist ein Zustand, der Aufmerksamkeit will.
       Dass beide denselben Wert haben, ist die Ein-Akzent-Regel aus itm-174 — Orange
       heisst „hier hinsehen", und dafür gibt es einen Orange. */
    --warn: var(--accent-ink);
    --warn-soft: var(--accent-soft);
    --stop: #A32017;
    --stop-soft: #FBE9E7;
    --draft: #4B4FA6;
    --draft-soft: #ECEDFA;


    /* ALTE NAMEN, auf die neuen gelegt. Sie bleiben, bis die letzte Ansicht
       umgestellt ist - eine Umbenennung in sechzehn Dateien gehörte nicht in
       denselben Schritt wie ein neues Muster. */
    --navy: var(--brand);
    --navy-soft: #33366F;
    --navy-hover: #17193F;
    --orange: var(--accent);
    --canvas: var(--paper);
    --surface-rail: var(--surface);
    --sunken: var(--surface-2);
    --hover: var(--surface-2);
    --border: var(--line);
    --border-strong: var(--ink-3);
    --ink-muted: var(--ink-2);
    --ink-faint: var(--ink-3);
    --danger: var(--stop);
    --danger-soft: var(--stop-soft);

    /* The same face the product uses, so the two look like one house. Arial stays
       only as the last fallback: it has 400 and 700 only, and every 600 would be
       rounded up to bold. */
    --font-ui: "Inter", system-ui, -apple-system, "Segoe UI", "Helvetica Neue",
        Arial, sans-serif;

    /* DIE SKALA DER KONSOLE (itm-191, entschieden von Martin am 22.09.2026).

       Sie ist die Skala aus docs/ui/ui-konsole.html: Grundtext 13,5 px statt der
       16 px, die hier vorher standen. Das ist eine bewusste Abweichung von der
       CI-Skala der Website, und der Grund ist Dichte - eine Tabelle auf CI-Mass
       braucht rund ein Fuenftel mehr Hoehe je Zeile, und die Konsole lebt von
       langen Listen in drei Spalten. Die CI-Skala gilt weiter fuer Marketing.

       ZWEI DINGE AUS DEM PROTOTYPEN WERDEN AUSDRUECKLICH NICHT UEBERNOMMEN:
       die Systemschrift (hier bleibt selbst ausgeliefertes Inter, sonst waere es
       einwilligungspflichtig) und die Versalien mit Sperrung. Das CI sieht beides
       nicht vor; der Prototyp setzt sie an fuenfzehn Stellen, wir an keiner.

       DARAUS FOLGT EINE ABWEICHUNG, die keine Nachlaessigkeit ist: Der Prototyp
       setzt Abschnittsueberschriften auf 11 px in Versalien. Ohne Versalien waere
       das eine Ueberschrift, die kleiner ist als ihr eigener Text - sie liest sich
       dann nicht mehr als Ueberschrift. Deshalb traegt --t-h2 hier 16 px und
       bezieht sein Gewicht aus Groesse statt aus Sperrung.

       Wer die Skala erneut aendert, aendert diese Zahlen und sonst nichts. Feste
       px-Werte fuer Schrift gehoeren ab hier nirgends mehr in diese Datei. */
    --t-h1: 21px;
    --lh-h1: 26px;
    --t-h2: 16px;
    --lh-h2: 22px;
    --t-h3: 14px;
    --lh-h3: 20px;
    --t-body: 13.5px;
    --lh-body: 20px;
    --t-ui: 13px;
    --lh-ui: 18px;
    --t-sm: 12.5px;
    --lh-sm: 17px;
    --t-xs: 11.5px;
    --lh-xs: 15px;
    --t-2xs: 11px;
    --lh-2xs: 14px;

    /* Eine Kennzahl in der Wirkungsspalte. Im Prototyp `.totals .v`. */
    --t-zahl: 19px;

    /* Bedienhoehen, ebenfalls aus dem Prototypen: Eingabefeld, Knopf, kleiner
       Knopf. Vorher 44 px fuer alles - das ist Website-Mass und kostet auf einer
       Maske mit zwoelf Feldern eine halbe Bildschirmhoehe. */
    --h-control: 34px;
    --h-btn: 32px;
    --h-btn-sm: 26px;

    /* 4px grid */
    --s1: 4px;
    --s2: 8px;
    --s3: 12px;
    --s4: 16px;
    --s6: 24px;
    --s8: 32px;
    --s12: 48px;
    --s16: 64px;

    /* Radii and shadows follow the house form: rounder than the CI note, and the
       shadow is navy-tinted with a negative spread rather than soft black. The
       border carries the shape, the shadow only adds depth. */
    --r-sm: 10px;
    --r-md: 12px;
    --r-lg: 18px;
    --r-full: 999px;

    --shadow-xs: 0 1px 2px rgba(39, 43, 91, .06);
    --shadow-sm: 0 1px 2px rgba(39, 43, 91, .06), 0 12px 34px -20px rgba(39, 43, 91, .35);
    --shadow-md: 0 2px 8px rgba(39, 43, 91, .05), 0 44px 88px -38px rgba(39, 43, 91, .42);

    --ease: cubic-bezier(.22, .85, .28, 1);

    --sidebar: 240px;

    /* Die rechte Spalte des Werkbank-Musters (itm-174). Breit genug für eine
       Kennzahl mit Veränderung und einen Satz dazu, schmal genug, dass die Mitte
       eine Tabelle trägt. */
    --wirkung: 336px;
    --topbar: 56px;

    /* Die Zeitachse hat eine feste Höhe (itm-215). Auf `auto` stehend wuchs sie
       mit ihrem Inhalt und nahm den Spalten die Höhe weg; als Token steht sie
       fest, und andere Stellen können mit ihr rechnen. */
    --timeline-h: 42px;
    --page-width: 1280px;

    /* DAS PRUEFFENSTER (itm-327). Breit genug fuer das Widget in seiner
       Auslieferungsgroesse - 380px plus die 20px Rand, die es selbst setzt -,
       schmal genug, dass die Werkbank daneben noch drei Spalten traegt.
       Die Buehne fasst das Fenster (520px) samt Rand. */
    /* DIE VORGABE, NICHT DIE WAHRHEIT (Befund von Martin, 26.09.2026).

       420 sind 380 Pixel Chatfenster plus zweimal 20 Pixel Rand — also die
       VORGABE aus `WidgetPanel.DefaultWidth`. Seit itm-301 laesst sich das Fenster
       je Bot zwischen 320 und 800 einstellen, und bei allem darueber ragte es links
       aus der Spalte quer ueber die Seite.

       `prueffenster.js` setzt die Zahl deshalb aus dem Bot, der gerade antwortet.
       Was hier steht, gilt nur, solange kein Fenster haengt. */
    --pruef-breite: 420px;
    --pruef-buehne: 560px;
}

/* DER DUNKELMODUS (itm-174). Durchgemessen im Entwurf, hier unverändert übernommen.
   
   Er hängt an den neuen Namen - und damit über die Aliase oben auch an den alten.
   Eine Seite, die noch var(--border) benutzt, wird also mitgenommen, ohne dass
   jemand sie anfasst.
   
   Zwei Regeln davon sind leicht zu übersehen und beide nötig: Die Abfrage steht
   unter :root:not([data-theme="light"]), damit eine ausdrückliche helle Wahl die
   Systemeinstellung schlägt. Und derselbe Satz steht noch einmal unter
   :root[data-theme="dark"], damit eine ausdrückliche dunkle Wahl auch auf einem
   hell eingestellten System greift. */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        color-scheme: dark;

        --paper: #0E1124;
        --surface: #171B30;
        --surface-2: #1F2440;
        --surface-3: #262C4C;
        --line: #2C3250;
        --line-soft: #242945;
        --ink: #E7EAF6;
        --ink-2: #A7B0CA;
        --ink-3: #9AA3BE;
        --brand: #C7CEE8;
        --on-brand: #0E1124;
        --accent: #F5A93C;
        --accent-soft: #33280F;
        --accent-ink: #F5A93C;
        --ok: #45C494;
        --ok-soft: #123326;
        --warn: var(--accent-ink);
        --warn-soft: var(--accent-soft);
        --stop: #F2837A;
        --stop-soft: #3A1815;
        --draft: #9AA0F0;
        --draft-soft: #1E2048;

        --navy-soft: #A7B0CA;
        --navy-hover: #E7EAF6;

        --shadow-xs: 0 1px 2px rgba(0, 0, 0, .45);
        --shadow-sm: 0 1px 2px rgba(0, 0, 0, .45), 0 12px 30px rgba(0, 0, 0, .4);
        --shadow-md: 0 2px 8px rgba(0, 0, 0, .5), 0 44px 88px -38px rgba(0, 0, 0, .6);
    }
}

:root[data-theme="dark"] {
    color-scheme: dark;

    --paper: #0E1124;
    --surface: #171B30;
    --surface-2: #1F2440;
    --surface-3: #262C4C;
    --line: #2C3250;
    --line-soft: #242945;
    --ink: #E7EAF6;
    --ink-2: #A7B0CA;
    --ink-3: #9AA3BE;
    --brand: #C7CEE8;
    --on-brand: #0E1124;
    --accent: #F5A93C;
    --accent-soft: #33280F;
    --accent-ink: #F5A93C;
    --ok: #45C494;
    --ok-soft: #123326;
    --warn: var(--accent-ink);
    --warn-soft: var(--accent-soft);
    --stop: #F2837A;
    --stop-soft: #3A1815;
    --draft: #9AA0F0;
    --draft-soft: #1E2048;

    --navy-soft: #A7B0CA;
    --navy-hover: #E7EAF6;

    --shadow-xs: 0 1px 2px rgba(0, 0, 0, .45);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .45), 0 12px 30px rgba(0, 0, 0, .4);
    --shadow-md: 0 2px 8px rgba(0, 0, 0, .5), 0 44px 88px -38px rgba(0, 0, 0, .6);
}

* {
    box-sizing: border-box;
}

/* DÜNNE, RUHIGE SCROLLBALKEN ÜBERALL (Martin, 08.10.2026: „die scrollbar bei unseren themen sollen viel dünner und moderner
   sein, dass es dazu passt. also generell"). Ganz vorn und ohne Gewicht: Wo eine Fläche den Balken eigens ausblendet
   (`scrollbar-width: none`), gilt weiter das. */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(120, 124, 150, .45) transparent;
}

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(120, 124, 150, .45); border-radius: 4px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: rgba(90, 94, 120, .7); }

html,
body {
    margin: 0;
    padding: 0;
    height: 100%;
}

/* DAS DOKUMENT SELBST SCROLLT NICHT, SOLANGE DER RAHMEN STEHT — nur die Spalten.
   Ohne das schob ein Sprung auf ein Ziel (`#bearbeiten` im Ablaufbild) das ganze
   Dokument mit: Die obere Leiste verschwand, und unten blieb ein leerer Streifen
   (Abnahme von Martin, 29.09.2026). `clip` und nicht `hidden`, weil sich ein
   `hidden`-Element weiterhin programmatisch scrollen lässt — und genau das tut der
   Sprung. Unter 900 Pixeln stapeln die Spalten, und dort scrollt das Dokument. */
@media (min-width: 901px) {
    html,
    body {
        overflow: clip;
    }
}

body {
    font-family: var(--font-ui);
    font-size: var(--t-body);
    line-height: var(--lh-body);
    color: var(--ink);
    background: var(--canvas);
    text-transform: none;
    letter-spacing: 0;
    -webkit-font-smoothing: antialiased;
}

/* ---- type ---- */

h1 {
    font-size: var(--t-h1);
    line-height: var(--lh-h1);
    font-weight: 650;
    letter-spacing: -.015em;
    margin: 0 0 var(--s2);
}

h2 {
    font-size: var(--t-h2);
    line-height: var(--lh-h2);
    font-weight: 600;
    margin: var(--s8) 0 var(--s3);
}

/* Der Abstand über einer Überschrift trennt sie vom Vorigen. Als erstes Kind einer
   Karte trennt er sie von nichts und erzeugt 56 Pixel Leere unter dem Kartenrand
   (itm-170). */
.card > h2:first-child {
    margin-top: 0;
}

h3 {
    font-size: var(--t-h3);
    line-height: var(--lh-h3);
    font-weight: 600;
    margin: var(--s6) 0 var(--s2);
}

p {
    margin: 0 0 var(--s4);
}

a {
    color: var(--navy);
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* Ein Link wird beim Überfahren BESSER lesbar, nicht schlechter (itm-185, cino).

   Hier stand Orange: #E8870C auf Weiß sind rund 2,4:1, also unter der Grenze von
   4,5:1 - jeder Link verlor beim Hinzeigen an Lesbarkeit. Und es nahm dem Orange
   seine eine Bedeutung, nämlich „hier ist Ihr nächster Schritt".

   Jetzt dunkleres Marineblau und eine kräftigere Unterstreichung: Die Änderung
   hängt damit nicht an der Farbe allein. */
a:hover {
    color: var(--navy-hover);
    text-decoration-thickness: 2px;
}

.lead {
    color: var(--ink-muted);
}

.meta {
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    font-weight: 600;
    color: var(--ink-muted);
}

/* DIE ZWEITE ZEILE IN EINER ZELLE: woher eine Angabe stammt, wozu sie dient, wer
   sie gesetzt hat. Sie steht UNTER dem, worauf sie sich bezieht, und tritt zurück —
   sonst liest man zwei gleichwertige Angaben und muss raten, welche die Sache ist.

   SIE HAT BIS ZUM 27.09.2026 GEFEHLT, und das ist der Grund, warum sie hier steht:
   Die Klasse wurde an zwanzig Stellen vergeben — Auswertung, Indizierung, Landkarte,
   Relevanz, Botprofil, Mandantenakte — und war nirgends definiert. Im Browser gesehen
   an den Zuständigkeiten der Mandantenakte, wo Person und Rolle als `<span>`
   nebeneinander lagen und zu „Datenschutz Partner Süd GmbHexterner
   Datenschutzbeauftragter" verschmolzen. Bei den `<div>`-Fällen fiel es weniger auf —
   dort stand die Zeile immerhin für sich, nur in voller Größe und Farbe.

   DESHALB `display: block`: Die Klasse wird sowohl an `<div>` als auch an `<span>`
   vergeben, und beide sollen dasselbe bedeuten. */
.origin {
    display: block;
    margin-top: 2px;
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    color: var(--ink-muted);
}


/* WAS PFLICHT IST, GEHÖRT GESAGT — UND TRITT TROTZDEM ZURÜCK.
   Dieselbe Erscheinung wie am Feld in der Dokumentansicht, nur ohne deren Bindung an
   `.field > label`: In der Ausgabe eines Vorgangs (itm-74) steht dasselbe Wort in einer
   Tabellenzelle. Zwei Abschriften desselben Kennzeichens liefen auseinander, und die
   zweite wäre die unauffällige. */
.pflicht {
    margin-left: var(--s2);
    font-size: var(--t-xs);
    font-weight: 400;
    color: var(--warn);
    text-transform: lowercase;
}

/* The sentence under a field that explains why it is asked the way it is.
   Begrenzt auf ein Lesemaß: Über die volle Inhaltsbreite gelesen sind das rund
   hundertzehn Zeichen je Zeile, und der Blick findet den Zeilenanfang nicht mehr. */
.help {
    margin: var(--s1) 0 0;
    max-width: 70ch;
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    color: var(--ink-muted);
}

/* ZWEI HILFEN HINTEREINANDER SIND ZWEI AUSKUENFTE. Unter einem Feld steht immer nur
   eine; am Fuss einer Karte stehen regelmaessig zwei, und mit --s1 lasen sie sich im
   Browser als ein Absatz mit Zeilenumbruch. Aufgefallen unter der Einsatzstellen-
   Tabelle der Zugaenge. */
.help + .help {
    margin-top: var(--s3);
}

/* Ein Dateifeld ist kein Textfeld: Der Knopf darin gehört dem Browser, und eine
   feste Höhe von 44px ohne senkrechten Innenabstand quetscht ihn an den Rand. */
input[type="file"] {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    background: var(--sunken);
    font: inherit;
    color: var(--ink-muted);
}

input[type="file"]::file-selector-button {
    margin-right: var(--s3);
    padding: 6px 12px;
    border: 1px solid var(--border);
    border-radius: var(--r-sm, 8px);
    background: var(--surface);
    font: inherit;
    font-weight: 600;
    color: var(--navy);
    cursor: pointer;
}

input[type="file"]::file-selector-button:hover {
    background: var(--sunken);
}

/* A card holding nothing but a short form. Full width would stretch three password
   fields across a desk. */
.card.narrow {
    max-width: 480px;
}

/* State by word, not by colour alone. */
.state {
    font-size: var(--t-sm);
    font-weight: 600;
}

.state.on {
    color: var(--navy);
}

.state.off {
    color: var(--ink-muted);
}

/* Confirmation after a form post. Quiet on purpose: the page already shows the
   result, so this only has to say that it went through. */
.saved {
    display: inline-block;
    padding: var(--s2) var(--s3);
    border-radius: var(--r-md);
    background: var(--sunken);
    font-weight: 600;
    font-size: var(--t-sm);
}

/* ---- focus ----
   One rule for every surface: the white inner ring carries on navy, the navy outer
   ring carries on white. Orange is not an option here - #F39313 on white reaches
   about 2.3:1, and WCAG asks for 3:1 on controls. */

:focus-visible {
    outline: 2px solid transparent;
    outline-offset: 2px;
    box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--navy);
}

/* ---- motion ---- */

button,
a,
input,
textarea,
select {
    transition: background-color .18s var(--ease), border-color .18s var(--ease),
        color .18s var(--ease), box-shadow .18s var(--ease);
}

@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
        animation: none !important;
    }
}

/* ---- forms ----
   The fill carries recognisability, so the border is only a contour. A 1px #D3DAE1
   border on white sits at about 1.4:1 and is effectively invisible to anyone with
   weak sight. */

/* Ein Label über einem Feld ist eine Beschriftung: klein, halbfett, gedämpft. */
label {
    display: block;
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    font-weight: 600;
    color: var(--ink-muted);
    margin-bottom: var(--s1);
}

/* Ein Label UM ein Kontrollkästchen ist keine Beschriftung, sondern der Text der
   Auswahl selbst - und liest sich wie normaler Text (itm-170).
   
   Vorher stand dieselbe Sache dreimal verschieden da: in der Arena und bei der
   Lizenzfrage klein und graumuted, weil sie das allgemeine Label erbte, und im
   Botprofil groß und in Tinte, weil dort eine eigene Regel stand. */
label:has(> input[type="checkbox"]) {
    display: flex;
    align-items: center;
    gap: var(--s2);
    font-size: var(--t-body);
    font-weight: 400;
    color: var(--ink);
    margin-bottom: 0;
}

label:has(> input[type="checkbox"]) input {
    width: auto;
    height: auto;
    margin: 0;
}

/* MEHRERE KAESTCHEN ZU EINER FRAGE (itm-411, erlaubte Dateitypen).

   NEBENEINANDER UND UMBRECHEND: Acht Dateitypen untereinander waeren acht Zeilen
   fuer eine einzige Entscheidung und schoeben alles darunter aus dem Bild. Sie
   gehoeren zusammen gelesen — „was nimmt er entgegen" ist EINE Frage.

   MIT EINER EIGENEN REGEL UND NICHT NUR MIT EINER KLASSE: Eine Klasse ohne Regel
   wird beim naechsten Umbau fuer die Regel gehalten, die es zu aendern gilt (Befund
   cino, 28.09.2026, zu `.check`). */
.wahlliste {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2) var(--s4);
    margin-top: var(--s2);
}

/* Volle Breite, aber nicht beliebig viel davon.
   
   Die Karte ist bis 1280px breit; ein Feld für "3. Auflage" oder "Wien" war damit
   1232px lang. Das ist kein Schönheitsfehler, sondern der erste Eindruck der
   Pflegeoberfläche - und es macht das Lesen eines langen Werts schwerer, weil das Auge
   nach dem Zeilenanfang suchen muss.
   
   680px ist ungefähr das, was ein Formularfeld an Text fasst, ohne dass man den Kopf
   bewegt. Ein Feld, das mehr braucht - der Systemprompt -, setzt .wide. */
input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):not([type="file"]),
textarea,
select {
    width: 100%;
    max-width: 680px;
    height: var(--h-control);
    padding: 0 var(--s4);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-md);
    background: var(--sunken);
    font-family: inherit;
    font-size: var(--t-body);
    color: var(--ink);
}

/* Wo der Inhalt die Breite wirklich braucht: der Systemprompt, ein Textbaustein. */
textarea.wide,
input.wide {
    max-width: none;
}

input::placeholder {
    color: var(--ink-faint);
}

input:focus {
    background: var(--surface);
}

textarea {
    height: auto;
    min-height: 92px;
    padding: var(--s2) var(--s3);
    line-height: var(--lh-body);
}

.field {
    margin-bottom: var(--s4);
}

/* Ein Satz, der warnt, ohne dass schon etwas schiefgegangen ist - der zweite Schritt
   beim Löschen etwa. Kein Kasten wie .form-error: es ist kein Fehler, sondern eine
   Ansage darüber, was gleich passiert. */
.warn {
    color: var(--danger);
    font-weight: 600;
}

/* Wo eine Angabe fehlt und das in Ordnung ist. Ein Strich sagt "hier steht nichts"
   deutlicher als eine leere Zelle, in der man einen Ladefehler vermutet. */
.muted {
    color: var(--ink-faint);
}

/* Gesagt, nicht nur eingefärbt: hier steht, warum etwas nicht funktioniert. Einmal
   hier statt dreimal in je einer Seite - dieselbe Aussage soll überall gleich
   aussehen. */
.broken {
    font-size: var(--t-sm);
    font-weight: 600;
    color: var(--danger);
}

/* Block und nicht flex.
   
   Als Flexbox wurde jeder Textknoten ein eigenes Element in einer Reihe: Ein Hinweis
   aus mehreren Sätzen mit einem <strong> und einem <code> darin stand als vier Spalten
   nebeneinander. Kein Element hier trägt ein Symbol, für das die Reihe gedacht war. */
.form-error {
    display: block;
    line-height: 1.5;
    padding: var(--s3);
    border-radius: var(--r-md);
    background: var(--danger-soft);
    color: var(--danger);
    font-size: var(--t-body);
    font-weight: 600;
    margin-bottom: var(--s4);
}


/* WAS GEDEUTET WURDE UND NOCH NIEMAND BESTÄTIGT HAT (itm-91).

   KEIN FEHLERKASTEN: Es ist nichts schiefgegangen — eine Eingabe wurde verstanden und
   wird einmal zurückgespiegelt. Rot gesetzt läse sich das als Zurückweisung, und der
   Leser tippt dann dasselbe noch einmal ein.

   ABER AUCH NICHT WIE DER REST DER KARTE: Der Streifen an der Seite ist der Punkt.
   Was hier steht, ist noch NICHT eingetragen, und diese Unterscheidung muss man sehen,
   ohne sie zu lesen. */
.rueckfrage {
    margin-top: var(--s4);
    padding: var(--s3) var(--s4);
    border-left: 3px solid var(--accent-ink);
    border-radius: var(--r-md);
    background: var(--accent-soft);
}

.rueckfrage h3 {
    margin-top: 0;
}

/* Dieselbe Zeilenbreite wie .help darunter: Die beiden stehen am selben Feld
   untereinander, und eine Meldung, die ueber die ganze Spalte laeuft, waehrend der
   Hinweis darunter bei 70 Zeichen umbricht, liest sich wie zwei verschiedene Dinge. */
.validation-message {
    display: block;
    margin-top: var(--s1);
    max-width: 70ch;
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    color: var(--danger);
}

/* ---- buttons ---- */

/* House geometry from scaliento.com: 44px, radius 12, 15.5px semibold. */
/* Ein Link, der wie ein Knopf aussieht. Kommt vor, wo die Handlung ein Seitenwechsel
   ist und kein Absenden - die Vorschau etwa. Ein <button> dafür zu nehmen hiesse,
   einen Seitenwechsel per Skript nachzubauen. */
a.button {
    text-decoration: none;
}

a.button:hover {
    color: var(--surface);
}

/* DIE GRUNDFORM IST DIE UMRANDETE (itm-205, Entscheidung von Martin am 22.09.2026).

   Bis hierher war gefüllt der Normalfall, und das Ergebnis war eine Konsole ohne
   Rangfolge: Die Freigabe-Warteschlange stellte je Eintrag einen gefüllten „Stand N
   freigeben" hin - bei fünf Vorlagen fünf gleich starke Knöpfe für fünf verschiedene
   unumkehrbare Dinge, plus den gefüllten nächsten Schritt daneben. Fünf gleich starke
   Knöpfe sind keine Hierarchie, sie laden zum schnellen Klicken ein. Wer freigibt,
   soll einen Moment innehalten.

   DIE VOREINSTELLUNG UMZUDREHEN ist der ganze Trick: Solange gefüllt der Default war,
   musste jede einzelne Stelle daran denken, `secondary` zu setzen - und zwanzig
   Stellen tun das nie zuverlässig. Jetzt muss umgekehrt jede Stelle, die Gewicht
   beansprucht, es ausdrücklich sagen, und ein Wächter-Test zählt nach, dass es je
   Bildschirm bei einer bleibt.

   `.secondary` BLIEB DAMALS als Alias auf die Grundform stehen, damit vorhandenes
   Markup nicht bricht. Am 24.09.2026 ist es entfallen: cino hat es als Fehler
   gemeldet, weil eine Regel, die Wert fuer Wert die Vorgabe wiederholt, von aussen
   nicht als Alias zu erkennen ist - wer sie schreibt, glaubt etwas zu waehlen. Die
   53 Stellen im Markup sind mitgeraeumt; optisch aendert sich nichts. */
button,
a.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--s2);
    height: var(--h-btn);
    padding: 0 20px;
    border: 1px solid var(--border-strong);
    border-radius: var(--r-md);
    font-family: inherit;
    font-size: var(--t-ui);
    font-weight: 600;
    background: var(--surface);
    color: var(--navy);
    cursor: pointer;
}

button:hover,
a.button:hover {
    background: var(--sunken);
    color: var(--navy);
}

/* `.secondary` IST ERSATZLOS ENTFALLEN (itm-244, Befund cino).

   Die Regel war Wert fuer Wert der Grundknopf - Hintergrund, Rahmen, Farbe, Hover.
   Wer `secondary` schrieb, glaubte eine leisere Fassung zu waehlen und bekam die
   Vorgabe; daneben stand ein Knopf ohne Klasse und sah gleich aus. Zwei
   Schreibweisen fuer dieselbe Sache laufen irgendwann auseinander.

   Der Grundknopf IST hier schon der leise: umrandet, ungefuellt. Gefuellt ist nur
   der eine `.primary` darunter, und `.ghost` ist die noch leisere Stufe. Es fehlte
   also keine Variante, es stand nur eine zuviel da. 53 Stellen im Markup sind
   mitgeraeumt - optisch aendert sich nichts, weil sich nie etwas geaendert hat. */

/* DER EINE GEFÜLLTE KNOPF, ausdrücklich verlangt.

   Für Seiten, die keinen „nächsten Schritt" haben und trotzdem eine eindeutige
   Handlung tragen: die Anmeldung, das Setzen eines Kennworts. Dort steht ein
   umrandeter Knopf allein auf einer leeren Fläche und sieht aus, als sei er
   abgeschaltet.

   Marineblau und NICHT orange: Orange trägt der nächste Schritt, und auf einer Seite
   ohne ihn gibt es auch keinen Akzent zu vergeben. */
button.primary,
a.button.primary {
    background: var(--navy);
    border-color: transparent;
    color: var(--surface);
}

button.primary:hover,
a.button.primary:hover {
    background: var(--navy-hover);
    color: var(--surface);
}

/* Filled rather than outlined - a 1px hairline on white would repeat the contrast
   defect the input borders had. */
button.ghost,
a.button.ghost {
    background: var(--sunken);
    border-color: transparent;
    color: var(--navy);
    font-weight: 500;
}

/* Die Farbe muss mit: a.button:hover färbt auf Weiß, und auf dem hellen
   Grund eines Geist-Knopfes bliebe davon nichts zu lesen. */
button.ghost:hover,
a.button.ghost:hover {
    background: var(--hover);
    color: var(--navy);
}

button.compact,
a.button.compact {
    height: var(--h-btn-sm);
    padding: 0 var(--s3);
    border-radius: var(--r-sm);
    font-size: var(--t-xs);
}

/* Löschen sieht nicht aus wie Speichern. Bis hierher trugen der endgültige Löschknopf
   und der Anlegen-Knopf dieselbe marineblaue Gestalt - die gefährlichste Handlung der
   Anwendung in der Form der harmlosesten. Gefüllt und nicht umrandet, damit sie sich
   auch dann unterscheidet, wenn jemand die Farbe nicht sieht: sie ist die einzige
   dunkle Fläche in einer Reihe heller Knöpfe. */
button.danger,
a.button.danger {
    background: var(--danger);
    border-color: transparent;
    color: var(--surface);
}

button.danger:hover,
a.button.danger:hover {
    background: color-mix(in srgb, var(--stop) 80%, black);
    color: var(--surface);
}

/* DIE STUFE ZWISCHEN GEWÖHNLICH UND ENDGÜLTIG (itm-205, Befund cino 8).

   „Ja, außer Kraft setzen" trug bis hierher `secondary` - nach der Umstellung oben
   also die Grundform, die leiseste Gestalt, die es gibt. Ausgerechnet die Handlung,
   die laut itm-187 SOFORT und in beide Richtungen wirkt, sah damit aus wie
   „Abbrechen".

   Sie gehört trotzdem nicht auf `danger`: Eine außer Kraft gesetzte Norm lässt sich
   wieder in Kraft setzen, ein gelöschtes Dokument nicht. Zwei Handlungen, die sich
   in der Umkehrbarkeit unterscheiden, dürfen nicht gleich aussehen - sonst ist die
   rote Fläche irgendwann nur noch „Achtung" und nicht mehr „endgültig".

   Umrandet und nicht gefüllt, damit der Unterschied zu `danger` auch ohne Farbe
   bleibt: die eine trägt eine Linie, die andere eine Fläche. */
button.caution,
a.button.caution {
    background: var(--warn-soft);
    border-color: var(--warn);
    color: var(--warn);
}

button.caution:hover,
a.button.caution:hover {
    background: color-mix(in srgb, var(--warn-soft) 80%, var(--warn));
    color: var(--warn);
}

button.ghost.danger,
a.button.ghost.danger {
    background: var(--sunken);
    color: var(--danger);
}

button.ghost.danger:hover,
a.button.ghost.danger:hover {
    background: var(--danger-soft);
    color: var(--danger);
}

/* Ein abgeschalteter Knopf ist leise, nicht leer.

   Hier standen Fläche und Schrift auf demselben Token: --border-strong IST --ink-3.
   Die Beschriftung war damit unsichtbar, und der Rückgängig-Knopf in der Kopfzeile -
   der meistens abgeschaltet ist - sah wie ein grauer Fleck aus. Gefunden am
   20.09.2026 beim Ansehen der Freigabe. */
button:disabled {
    background: var(--sunken);
    border-color: var(--border);
    color: var(--ink-3);
    cursor: not-allowed;
}

/* ---- tables ---- */

/* Eine Zelle bricht, statt die Seite zu schieben.
   
   Ohne das schob ein langer Dateiname oder eine lange Adresse die siebenspaltige
   Wissensbasis über den Seitenrand, und bei schmalem Fenster scrollte das ganze
   Dokument samt Navigation seitwärts.
   
   "break-word" und nicht "anywhere": anywhere erlaubt dem Tabellenlayout, jede Spalte
   bis auf ein Zeichen zu quetschen - dann stand in der Kopfzeile "Rechtsstatu/s" und
   "Dokumen/te", obwohl Platz da war. break-word bricht nur, was sich sonst gar nicht
   unterbringen lässt, also genau die lange Adresse.
   
   Hier und nicht in fünf Seitenstilen: Es gilt für jede Tabelle, und die nächste
   erbt es, ohne dass jemand daran denkt. */
th,
td {
    overflow-wrap: break-word;
}

/* Und die Tabelle bleibt in ihrer Karte. */
table {
    max-width: 100%;
}

/* EINE TABELLE LÄUFT QUER, STATT SPALTEN ABZUSCHNEIDEN (itm-184).

   Gemessen zwischen 1024 und 1366 Pixeln: Eine siebenspaltige Tabelle war breiter
   als ihr Rahmen, und der Rahmen schnitt ab - Autorität, Abschnitte und Zustand
   fehlten dann auf einem gewöhnlichen Laptop, ohne jede Möglichkeit, sie zu
   erreichen. Abschneiden ist die eine Antwort, die man nie geben darf: Der Benutzer
   sieht nicht, dass etwas fehlt.

   Ab JEDER Breite und nicht erst unter einer Schwelle. Wer eine Schwelle setzt, hat
   sie an der falschen Stelle, sobald jemand eine Spalte ergänzt. */
.card:has(> table),
.card:has(> form > table) {
    overflow-x: auto;
}

.table-scroll {
    overflow-x: auto;
    border-radius: var(--r-lg);
}

/* ---- surfaces ---- */

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-xs);
    padding: var(--s6);
}

/* An empty area is a designed state, not a construction site. A dashed box reads
   as unfinished code. */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: var(--s12) var(--s6);
}

.empty-state svg {
    width: 32px;
    height: 32px;
    fill: none;
    stroke: var(--ink-faint);
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    margin-bottom: var(--s4);
}

.empty-state h2 {
    margin: 0 0 var(--s2);
    font-size: var(--t-h2);
    line-height: var(--lh-h2);
}

.empty-state p {
    max-width: 44ch;
    margin: 0;
    color: var(--ink-muted);
}

/* Zwei Absaetze im Leerzustand brauchen eine Fuge; `margin: 0` oben laesst sie sonst
   aneinanderkleben. Aufgefallen am Leerzustand der Jev-Seite, dem einzigen mit zweien. */
.empty-state p + p {
    margin-top: var(--s2);
}

/* Die Bot-Auswahl. Global und nicht je Seite, seit sie an zwei Stellen steht:
   Qualitätsprüfung und Arena. Zwei Kopien wären zwei Stellen, an denen sie
   auseinanderlaufen. */
.picker {
    margin-bottom: var(--s8);
}

/* Der Auswahlstreifen über einer Seite, die je Bot etwas zeigt. Hieß bis itm-137-Nachlese
   .bots und kollidierte damit mit der Bot-TABELLE in Einstellungen: Die Tabelle erbte
   display:flex, und ihre Kopfzeile stand nicht mehr über ihren Spalten. */
.bot-picker {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
}

.bot-picker a {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: var(--s2) var(--s4);
    border: 1px solid var(--border-strong);
    border-radius: var(--r-md);
    background: var(--surface);
    text-decoration: none;
    color: var(--ink);
}

.bot-picker a:hover {
    background: var(--sunken);
    color: var(--ink);
}

/* Der gewählte Bot wird durch Gewicht und Fläche markiert, nicht durch den Akzent:
   Orange trägt in der Navigation bereits den aktiven Eintrag, und ein zweiter in
   derselben Ansicht nähme beiden die Bedeutung. */
.bot-picker a.current {
    border-color: var(--navy);
    background: var(--sunken);
}

.bot-picker .name {
    font-weight: 600;
}

.bot-picker .meta {
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

/* Kurze Merkmalsliste: Begriff und Wert nebeneinander statt untereinander. */
.facts {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: var(--s1) var(--s6);
    margin: 0 0 var(--s4);
}

.facts > div {
    display: contents;
}

.facts dt {
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

.facts dd {
    margin: 0;
}

/* ============================================================================
   BAUSTEINE DER RECHTEN SPALTE (itm-174)

   Sie stehen hier und nicht im Layout, weil die Inhalte aus den Seiten kommen:
   Die Hülle stellt die Spalte, die Ansicht füllt sie. Und sie stehen an einer
   Stelle, damit die Wirkung auf jeder Seite gleich aussieht - eine Spalte, die
   je Ansicht anders gebaut ist, liest sich nicht mehr nebenbei.
   ============================================================================ */

/* Ein Block in der rechten Spalte. Getrennt durch eine Linie und nicht durch
   Abstand: Bei schmaler Spalte verschwimmen Abstände zu einem Absatz. */
.wirkung {
    padding: var(--s4);
    border-bottom: 1px solid var(--line-soft);
}

.wirkung > h2 {
    margin: 0 0 var(--s1);
    font-size: var(--t-ui);
    font-weight: 700;
    color: var(--ink);
}

.wirkung p {
    margin: 0 0 var(--s2);
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    color: var(--ink-2);
}

.wirkung p:last-child {
    margin-bottom: 0;
}

/* Eine Zahl mit ihrer Bedeutung. Die Zahl groß, das Wort klein darunter - wer die
   Spalte überfliegt, liest die Zahlen, und wer stehenbleibt, liest wofür. */
.wirkung .zahlen {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(84px, 1fr));
    gap: var(--s3);
    margin: 0 0 var(--s3);
}

.wirkung .zahlen > div {
    min-width: 0;
}

.wirkung .zahl {
    font-size: var(--t-zahl);
    font-weight: 700;
    line-height: 1.1;
    color: var(--ink);
}

.wirkung .wofuer {
    font-size: var(--t-xs);
    line-height: var(--lh-xs);
    color: var(--ink-3);
}

/* Ein Zustand in einem Wort. Vier Ausprägungen, weil es vier Antworten gibt:
   in Ordnung, es fehlt etwas, es steht still, es ist neu. */
.zustand {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 2px 9px;
    border: 1px solid transparent;
    border-radius: var(--r-full);
    font-size: var(--t-xs);
    font-weight: 600;
    white-space: nowrap;
}

.zustand::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

/* EINE PILLE IST EIN ZUSTAND UND KEIN WEG (itm-388, Befund cino).

   Hier stand `a.zustand` — eine begehbare Pille, die sich von einer ruhenden ALLEIN
   im Ueberfahren unterschied. Auf einem Tastschirm gibt es kein Ueberfahren, und
   auf der Mandantenseite standen beide Formen zwanzig Pixel nebeneinander: drei
   begehbare Zahlen und „jeder Kunde hat einen Sitz", das nirgendwohin fuehrt.

   WAS EINE GEFILTERTE LISTE OEFFNET, IST SEITDEM EIN CHIP (`.chip`) — dieselbe
   Gestalt wie in der Filterkarte, an der man dieselbe Handlung schon kennt. Die
   Pille bleibt, was sie war: eine Auskunft ueber einen Zustand.

   Die beiden Regeln fuer `a.zustand` sind damit ersatzlos entfallen. Sie hier als
   tote Regeln stehen zu lassen waere die Einladung, die Form beim naechsten Mal
   wieder zu benutzen. */
.zustand.gut {
    color: var(--ok);
    background: var(--ok-soft);
    border-color: color-mix(in srgb, var(--ok) 30%, transparent);
}

.zustand.offen {
    color: var(--warn);
    background: var(--warn-soft);
    border-color: color-mix(in srgb, var(--warn) 30%, transparent);
}

/* `steht` UND `warn` SEHEN GLEICH AUS, WEIL SIE DASSELBE SAGEN: So geht es nicht
   hinaus. `warn` stand an elf Stellen — „nicht uebergabefaehig", „passt nicht",
   „kein Text", „verworfen" — und hatte KEINE Regel (Befund cino, 28.09.2026). Es
   griff die allgemeine `.warn { color: var(--danger) }` von weiter oben: rote
   Schrift ohne Flaeche, neben lauter gefuellten Pillen. Die wichtigste Auskunft der
   Vorgangsseite sah damit aus wie ein halb geladenes Element.

   OFFEN BLEIBT, OB DAS URTEIL UEBER DEN GANZEN LAUF DIESELBE GESTALT TRAGEN SOLL
   wie eine Zeilenauskunft daneben. Das ist eine Entscheidung und keine Reparatur —
   hier steht nur die fehlende Gestalt. */
.zustand.steht,
.zustand.warn {
    color: var(--stop);
    background: var(--stop-soft);
    border-color: color-mix(in srgb, var(--stop) 30%, transparent);
}

.zustand.neu {
    color: var(--draft);
    background: var(--draft-soft);
    border-color: color-mix(in srgb, var(--draft) 30%, transparent);
}

/* DER NÄCHSTE SCHRITT. Unten in der Spalte, in jeder Ansicht besetzt, mit GENAU
   EINEM gefüllten Knopf - zwei gleich starke heben sich gegenseitig auf.
   
   margin-top:auto drückt ihn ans untere Ende, auch wenn darüber wenig steht. Er
   soll dort sein, wo man ihn sucht, und nicht dort, wo der Text aufhört. */
.naechster-schritt {
    margin-top: auto;
    padding: var(--s3) var(--s4) calc(var(--s3) + env(safe-area-inset-bottom, 0px));
    background: var(--surface-2);
    border-top: 1px solid var(--line);
}

.naechster-schritt .l {
    margin-bottom: var(--s1);
    font-size: var(--t-2xs);
    font-weight: 700;
    color: var(--ink-3);
}

.naechster-schritt p {
    margin: 0 0 var(--s2);
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    color: var(--ink-2);
}

/* HIER UND NUR HIER SITZT DAS ORANGE (itm-205).

   Der Kommentar in dieser Datei behauptete es schon lange - „Orange trägt genau eine
   Sache je Bildschirm" -, und umgesetzt war es genau umgekehrt: Der Akzent lag auf
   dem Balken der Navigation und auf der Pille „jetzt" in der Zeitachse, also auf der
   Kulisse, während der nächste Schritt marineblau war und damit aussah wie der
   Avatar, jeder Speichern-Knopf und jede Tabellenzeile.

   SCHRIFT IST `--on-accent`, NICHT WEISS. Das helle Orange hat gegen Weiß 2,3:1 -
   ein weißes Etikett darauf wäre die schlechteste Lesbarkeit der ganzen Konsole
   ausgerechnet auf ihrem wichtigsten Knopf. `--on-accent` ist der dunkle Ton, der in
   BEIDEN Modi auf dem Akzent liegt - `--accent-ink` taugt dafuer nur im Hellmodus,
   weil er im Dunkelmodus denselben Wert traegt wie der Akzent selbst. */
.naechster-schritt > a.button,
.naechster-schritt > button {
    width: 100%;
    justify-content: center;
    background: var(--accent);
    border-color: transparent;
    color: var(--on-accent);
}

.naechster-schritt > a.button:hover,
.naechster-schritt > button:hover {
    background: color-mix(in srgb, var(--accent) 86%, var(--ink));
    color: var(--on-accent);
}

/* Rückgängig in der Kopfleiste (itm-175).

   Feste Breite: Der Knopf trägt den Namen der letzten Änderung, und ohne Grenze
   springt die halbe Kopfzeile, sobald jemand etwas mit längerem Namen ändert. */
.undo button {
    max-width: 260px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;

    /* ALS BLOCK UND LINKSBÜNDIG, sonst greift die Auslassung nicht: Knöpfe sind
       hier Flexboxen, und text-overflow wirkt nicht auf einer Flexbox. Der Text
       wurde stattdessen zentriert und an BEIDEN Enden abgeschnitten - sichtbar
       geworden mit den längeren Etiketten aus itm-176 („Stand 3 ohne zweites
       Augenpaar freigegeben"), die vorher niemand hatte. Der vollständige Text
       steht weiterhin im title. */
    display: block;
    text-align: left;
    line-height: 34px;
}

/* DAS SYMBOL BRAUCHT EINE GRÖSSE (Befund Martin, 30.09.2026). Seit itm-430 trägt der
   Knopf ein Symbol, und weil er hier ein Block ist und keine Flexbox, nahm das SVG ohne
   Angabe die ganze Knopfbreite ein — 169 px hoch in einem 26 px hohen Knopf. Der Text
   rutschte darunter weg, und über den Rand ragte nur ein Stück des Pfeils. */
.undo button svg {
    width: 14px;
    height: 14px;
    margin-right: 6px;
    vertical-align: -2px;
}

/* DIE SCHRITTE DIESER SITZUNG, im Menü neben dem Rückgängig-Knopf (itm-215).

   Sie lagen bis dahin in der Zeitachse, in derselben Pille wie die Geschichte des
   Objekts - und die eine davon ist folgenreich, die andere nicht. Hier oben sind
   sie das, was sie sind: meine Schritte, von jetzt, zurücknehmbar. */
.zuruecknehmen {
    display: inline-flex;
    align-items: center;
    gap: var(--s2);
}

.schritte > summary {
    list-style: none;
    cursor: pointer;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: var(--r-full);
    background: var(--surface-2);
    color: var(--ink-2);
    font-size: var(--t-xs);
    line-height: 32px;
    white-space: nowrap;
}

.schritte > summary::-webkit-details-marker {
    display: none;
}

.schritte > summary:hover {
    border-color: var(--ink-3);
    color: var(--ink);
}

/* Das Menü hängt unter dem Knopf und schiebt die Kopfzeile nicht auseinander. */
.schritte {
    position: relative;
}

.schritte > .liste {
    position: absolute;
    right: 0;
    top: calc(100% + 6px);
    z-index: 20;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 240px;
    max-height: 60vh;
    overflow-y: auto;
    padding: var(--s2);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface);
    box-shadow: var(--shadow-md);
}

/* NEUESTE OBEN. In der Zeitachse standen sie von links nach rechts, weil das die
   Leserichtung einer Achse ist; in einer Liste, die man aufklappt, sucht man den
   letzten Schritt, und der gehört nach oben. */
.schritte > .liste {
    flex-direction: column-reverse;
}

.schritte .schritt {
    display: block;
    width: 100%;
    padding: 6px 8px;
    border: 0;
    border-radius: var(--r-sm);
    background: none;
    color: var(--ink-2);
    font: inherit;
    font-size: var(--t-ui);
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

button.schritt {
    cursor: pointer;
}

button.schritt:hover {
    background: var(--surface-2);
    color: var(--ink);
}

/* Ein zurückgenommener Schritt bleibt stehen, ist aber kein Ziel mehr.
   Durchgestrichen und nicht entfernt: Eine Lücke könnte später niemand erklären. */
.schritte .schritt.undone {
    text-decoration: line-through;
    opacity: .6;
}

/* ---- Freigabe (itm-176, itm-177) ---- */

/* In app.css und nicht an einer Seite: Die Gegenüberstellung steht an der Quelle
   UND in der Warteschlange, und zwei Kopien desselben Stils laufen auseinander -
   ausgerechnet dort, wo beide dasselbe zeigen sollen. */

/* Die Gegenüberstellung vor einer Freigabe (itm-176). Drei Spalten mit festen
   Anteilen: Was sich ändert, liest man im Vergleich, und ungleich breite Spalten
   machen aus dem Vergleich eine Suche. */
.changes {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: var(--s4);
}

.changes th {
    text-align: left;
    font-size: var(--t-sm);
    font-weight: 600;
    color: var(--ink-muted);
    padding: 0 var(--s3) var(--s2) 0;
    border-bottom: 1px solid var(--border);
}

.changes td {
    padding: var(--s3) var(--s3) var(--s3) 0;
    border-top: 1px solid var(--border);
    vertical-align: top;
    word-break: break-word;
}

.changes th:first-child,
.changes td:first-child {
    width: 22%;
}

.changes th:nth-child(2),
.changes td:nth-child(2) {
    width: 39%;
}

/* Der alte Wert leiser als der neue: Gelesen wird, was kommt, nicht was geht. */
.changes .meta {
    color: var(--ink-muted);
}

/* Die drei Knöpfe der Freigabe stehen nebeneinander, nicht untereinander - sie
   gehören zu einer Entscheidung. */
.freigabe > form {
    display: inline-block;
    margin: 0 var(--s2) var(--s2) 0;
}

/* Das Zurückweisen trägt ein Feld und gehört deshalb unter die beiden Knöpfe, nicht
   zwischen sie: Ein Eingabefeld mitten in einer Knopfreihe sieht aus wie eine
   Beschriftung, die verrutscht ist. */
.freigabe > form.rueckweisung {
    display: block;
    margin-top: var(--s4);
}

/* DIE FILTERZEILE ÜBER EINER LISTE (itm-181).

   Ein Kasten und nicht eine freie Reihe über der Tabelle: Die Eingrenzung gehört
   sichtbar zur Liste darunter, sonst liest man die Trefferzahl als Aussage über den
   ganzen Bestand. Die Felder liegen in einer Reihe, weil sie zusammen EINE Frage
   stellen - untereinander sähen es vier aus. */
.card.filter > form {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: var(--s3);
}

.card.filter .field {
    margin-bottom: 0;
    flex: 0 1 190px;
}

/* Das Suchfeld bekommt den Rest: Es trägt die eigentliche Frage, die Auswahlfelder
   grenzen nur ein. */
.card.filter .field:first-child {
    flex: 1 1 280px;
}

/* DER HILFSTEXT HOB DAS SUCHFELD AN (itm-206). Die Reihe richtet sich unten aus,
   und mit dem Hilfstext unter dem Feld lag dessen Unterkante auf der Linie der
   Auswahlfelder — die Eingabezeile selbst also 20 Pixel höher. Vier Felder, die
   zusammen eine Frage stellen, standen auf zwei Grundlinien.

   Aus dem Fluss genommen: Er gilt der Suche, nicht dem Feldrahmen.

   ER HING ABER AM FELD UND NICHT AN DER REIHE, und das hielt nur, solange alle
   Felder in EINE Zeile passen. Beim Ansehen am 26.09.2026 fand sich auf der
   Wissensbasis der Fall, in dem sie es nicht tun: Mit offenem Prüffenster bricht die
   Reihe um, und `top: 100%` des Suchfeldes zeigt dann mitten auf die zweite Zeile —
   der Satz lag quer über der Beschriftung „Rechtsstatus".

   ER HÄNGT JETZT AM FORMULAR. Damit steht er unter der LETZTEN Zeile, egal wie oft
   umgebrochen wird, und bei einer einzigen Zeile sieht es aus wie vorher. */
.card.filter > form {
    position: relative;
}

.card.filter .field .help {
    position: absolute;
    bottom: 0;
    left: 0;
    margin: 0;
    font-size: var(--t-xs);
    white-space: nowrap;
}

/* Platz für den Hilfstext, damit er nicht in die Liste darunter ragt. */
.card.filter > form {
    padding-bottom: var(--s4);
}

/* Die Knopfhöhe an den Feldern ausrichten - ein Knopf auf der Grundlinie der
   Beschriftung statt auf der des Feldes steht sonst eine Zeile zu hoch. */
.card.filter > form > button {
    flex: 0 0 auto;
}

/* VORGEGEBENE FILTER ALS CHIPS. Sie sind Links und keine Knöpfe: Ein Chip führt auf
   eine Adresse, die man behalten und verschicken kann - das ist der Punkt. */
.chips {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
    margin-top: var(--s4);
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: var(--s2);
    padding: 5px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--ink-2);
    font-size: var(--t-ui);
    font-weight: 600;
    line-height: 20px;
    text-decoration: none;
}

.chip:hover {
    border-color: var(--brand);
    color: var(--ink);
    text-decoration: none;
}

.chip .n {
    color: var(--ink);
    font-variant-numeric: tabular-nums;
}

/* Der gesetzte Filter ist gefüllt, nicht nur umrandet: Man muss auf einen Blick
   sehen, dass die Liste darunter nicht der ganze Bestand ist. Marineblau und nicht
   Orange - Orange trägt je Ansicht genau eine Sache, und das ist der nächste
   Schritt in der rechten Spalte. */
.chip.on,
.chip.on:hover {
    background: var(--brand);
    border-color: var(--brand);
    color: var(--on-brand);
}

.chip.on .n {
    color: var(--on-brand);
}

/* „12 von 1.204" - die Zahl, die den Unterschied zwischen Auswahl und Bestand
   benennt. Ohne sie liest man eine gefilterte Liste als Inventar. */
.treffer {
    margin: var(--s4) 0 0;
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

.treffer strong {
    color: var(--ink);
    font-variant-numeric: tabular-nums;
}

.seiten {
    display: flex;
    align-items: center;
    gap: var(--s4);
    margin-top: var(--s4);
    font-size: var(--t-ui);
    color: var(--ink-muted);
}

/* DIE RESTLISTE OFFENER PUNKTE (itm-182).

   Eine Liste und keine Tabelle: Jeder Eintrag trägt drei ungleiche Dinge - was
   fehlt, was das bewirkt, was man dagegen tut. In Spalten gezwungen würde die
   mittlere Angabe zur Randnotiz, und sie ist der Grund, warum jemand hinsieht. */
.card.offen > ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* DIE KANTE BLEIBT GERADE (itm-206). Der sperrende Eintrag trägt einen roten Rand
   und dafür eine Einrückung; die übrigen hatten keine, und die Liste stand damit auf
   zwei Fluchten. Jetzt tragen alle denselben Abstand und einen durchsichtigen Rand -
   der farbige ersetzt ihn, statt daneben zu treten. */
.card.offen li {
    padding: var(--s3) 0 var(--s3) var(--s3);
    border-top: 1px solid var(--line-soft);
    border-left: 3px solid transparent;
}

.card.offen li:first-child {
    border-top: 0;
    padding-top: 0;
}

.card.offen li:last-child {
    padding-bottom: 0;
}

.card.offen .was {
    display: flex;
    align-items: center;
    gap: var(--s2);
}

/* Der Strich am Rand trägt dieselbe Aussage wie die Marke daneben. Farbe allein
   ist keine Auskunft - wer sie nicht unterscheidet, soll trotzdem sehen, dass hier
   etwas anderes steht. */
.card.offen li.blockiert {
    border-left-color: var(--stop);
}

.card.offen .marke {
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--stop-soft);
    color: var(--stop);
    font-size: var(--t-xs);
    font-weight: 600;
    line-height: var(--lh-xs);
}

/* DIE FOLGEN VOR DER BESTÄTIGUNG (itm-187).

   Abgesetzt und nicht als Fließtext: Das ist der zweite Schritt einer Handlung, die
   sofort wirkt, und er muss sich von der Beschreibung darüber unterscheiden - sonst
   liest man ihn als weitere Erklärung und drückt den Knopf ungelesen. */
.folgen {
    margin-top: var(--s4);
    padding: var(--s4);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--sunken);
}

.folgen h3 {
    margin: 0 0 var(--s3);
    font-size: var(--t-h3);
}

.folgen ul {
    margin: 0 0 var(--s4);
    padding-left: var(--s4);
    max-width: 70ch;
    line-height: var(--lh-body);
}

.folgen li + li {
    margin-top: var(--s2);
}

.folgen form {
    display: inline-block;
    margin: 0 var(--s4) 0 0;
}

.folgen > p:last-child {
    display: inline-block;
    margin: 0;
}

/* EIN LAUFENDER VORGANG ALS ZUSTAND (itm-183).

   Eine Meldung ist eine Quittung, kein Zustand: Sie sagt „angestoßen" und
   verschwindet. Hier steht, wie weit es ist, bis es fertig ist - die eine Auskunft,
   nach der man sonst alle zehn Sekunden neu lädt. */
.lauf {
    margin-top: var(--s4);
    padding: var(--s3);
    border-radius: var(--r-md);
    background: var(--sunken);
}

.lauf .l {
    display: flex;
    align-items: center;
    gap: var(--s2);
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

.lauf .l strong {
    color: var(--ink);
    font-variant-numeric: tabular-nums;
}

/* Der Balken trägt dieselbe Zahl noch einmal, als Form. Er ist die Auskunft, die
   man im Vorbeigehen liest; die Zahl daneben die, der man glaubt. */
.lauf .balken {
    height: 6px;
    margin: var(--s2) 0;
    border-radius: 999px;
    background: var(--line);
    overflow: hidden;
}

.lauf .balken span {
    display: block;
    height: 100%;
    background: var(--brand);
    border-radius: 999px;
}

.lauf .help {
    margin-top: 0;
}

/* Der Satz am Feld, das noch offen ist (itm-182).

   Eine Stufe lauter als .help und eine leiser als .form-error: Es ist kein Fehler -
   das Formular lässt sich so speichern - aber es ist auch kein Hinweis, den man
   überliest. Der Strich links trägt die Aussage mit, damit sie nicht allein an der
   Farbe hängt. */
.fehlt {
    margin: var(--s2) 0 0;
    padding-left: var(--s3);
    border-left: 3px solid var(--warn);
    max-width: 70ch;
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    color: var(--warn);
}

.card.offen .folge {
    margin: var(--s1) 0 var(--s2);
    max-width: 70ch;
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    color: var(--ink-muted);
}

/* EINE FILTERZEILE AUS AUSWAHLFELDERN (itm-401).

   NICHT `.card.filter`, obwohl hier gefiltert wird: Jene Klasse positioniert `.help`
   in einem Feld absolut (itm-206, itm-249), und darunter stehen hier Saetze, die
   gelesen werden sollen. Dieselbe Anordnung, ohne die Falle. */
.card .auswahl {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: var(--s2) var(--s3);
    margin: 0 0 var(--s2);
}

.card .auswahl .field {
    margin: 0;
    min-width: 170px;
}

/* STEHT SIE UNTER EINER CHIP-REIHE, BRAUCHT SIE ABSTAND. Beides sind Wege, dasselbe
   zu waehlen; ohne Luft dazwischen liest sich die Beschriftung des Feldes wie die
   Unterzeile des letzten Chips (im Browser gesehen, 27.09.2026). */
.card .chips + .auswahl {
    margin-top: var(--s3);
}

.card .auswahl button {
    flex: 0 0 auto;
}

/* EINE ZWISCHENUEBERSCHRIFT IN EINER KARTE. Mehrere Diagramme in einer Karte
   brauchen sie; ohne sie stehen drei Bilder untereinander und niemand weiss, welches
   was zeigt. */
.card > h3 {
    margin: var(--s4) 0 var(--s2);
    font-size: var(--t-h3);
    line-height: var(--lh-h3);
}

.card > h3:first-child {
    margin-top: 0;
}

/* DIESELBEN KENNZAHLEN IN EINER KARTE (itm-401).

   Die Wirkungsspalte ist schmal, eine Karte in der Mitte ist breit — deshalb eine
   eigene Regel statt `.wirkung .zahlen` mitzubenutzen: Dort sind 84 Pixel die
   kleinste sinnvolle Spalte, hier waeren es acht Zahlen nebeneinander, die keiner
   mehr auseinanderhaelt. `breit` sagt, dass hier Platz ist.

   DIE KLASSENNAMEN BLEIBEN DIESELBEN (`zahl`, `wofuer`). Zwei Vokabulare fuer
   dieselbe Sache waeren beim naechsten Umbau zwei Stellen. */
.card .zahlen {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: var(--s3);
    margin: 0 0 var(--s3);
}

.card .zahlen > div {
    min-width: 0;
}

.card .zahl {
    font-size: var(--t-zahl);
    font-weight: 700;
    line-height: 1.1;
    color: var(--ink);
}

.card .wofuer {
    font-size: var(--t-xs);
    line-height: var(--lh-xs);
    color: var(--ink-3);
}

/* WAS AUS DEM DOKUMENT GELESEN WURDE (itm-112).

   Dieselbe Form wie die Restliste offener Punkte: was, welche Folge, was man tut.
   Der Unterschied ist die Marke - sie sagt, wie sicher der Wert ist, und das ist
   hier die wichtigste Angabe auf der Karte. Ein maschineller Wert, der wie eine
   geprüfte Angabe aussieht, wird ein Jahr später zitiert, und dann weiß niemand
   mehr, dass ihn nie jemand angesehen hat (itm-116). */

/* DIE KOPFZEILE EINER QUELLE IN DER VORSCHLAGSLISTE. Titel, Zahl und der Weg zur
   Quelle in EINER Zeile — vorher waren es drei. */
.card.vorschlaege .quelle {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: var(--s1) var(--s2);
    margin-bottom: var(--s2);
    padding-bottom: var(--s2);
    border-bottom: 1px solid var(--line);
}

.card.vorschlaege .quelle h2 {
    margin: 0;
    font-size: var(--t-h3);
    line-height: var(--lh-h3);
    min-width: 0;
}

.card.vorschlaege .quelle .meta {
    flex: 1 1 auto;
}

/* EINE ZEILE JE VORSCHLAG (Befund von Martin, 27.09.2026: „so ist das nicht
   verwendbar. viel kompakter").

   Vorher stand jeder Vorschlag als Block uebereinander: Ueberschrift, Beleg, Feld
   mit eigener Beschriftung, zwei Knoepfe. Jetzt drei Spalten in einer Zeile, der
   Beleg darunter:

       was es ist + Marke  |  der Wert  |  Uebernehmen / Verwerfen
       der Beleg, geklemmt

   DIE KNOEPFE STEHEN RECHTS UND UNTEREINANDER AUSGERICHTET. Wer sechzig Vorschlaege
   abarbeitet, bewegt die Hand dann nicht mehr — das ist der ganze Gewinn der
   kompakten Form, nicht der gesparte Platz. */
.card.vorschlaege .vorschlag {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(160px, 260px) auto;
    grid-template-areas:
        "was wahl tun"
        "folge folge folge";
    align-items: center;
    column-gap: var(--s3);
    row-gap: var(--s1);
    padding: var(--s2) 0;
    border-top: 1px solid var(--line-soft);
}

.card.vorschlaege .vorschlag:first-of-type {
    border-top: 0;
}

.card.vorschlaege .was {
    grid-area: was;
    display: flex;
    align-items: center;
    gap: var(--s2);
    min-width: 0;
}

.card.vorschlaege .wahl {
    grid-area: wahl;
    min-width: 0;
}

.card.vorschlaege .wahl select,
.card.vorschlaege .wahl input {
    width: 100%;
}

/* Ein Wert, den dieses Thema nicht aendern laesst (itm-335). Er steht da, damit man
   sieht, worueber man entscheidet — und sagt in derselben Zeile, warum kein Feld. */
.card.vorschlaege .wahl .fest {
    display: flex;
    align-items: baseline;
    gap: var(--s2);
    font-size: var(--t-sm);
}

.card.vorschlaege .tun {
    grid-area: tun;
    display: flex;
    gap: var(--s2);
    justify-content: flex-end;
}

/* DER BELEG WIRD GEKLEMMT, NICHT GEKUERZT (itm-112). Zwei Zeilen reichen, um zu
   erkennen, worauf sich der Vorschlag stuetzt; wer genauer hinsehen will, faehrt
   darueber oder kommt mit der Tastatur in die Zeile, und er klappt auf.

   EIN SERVERSEITIG ABGESCHNITTENER TEXT WAERE WEG. Das Klemmen gehoert deshalb ins
   Stylesheet und nicht in die Komponente — ohne Stylesheet steht der ganze Beleg da,
   und das ist der richtige Rueckfall. */
.card.vorschlaege .folge {
    grid-area: folge;
    margin: 0;
    color: var(--ink-2);
    font-size: var(--t-sm);
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
}

.card.vorschlaege .vorschlag:hover .folge,
.card.vorschlaege .vorschlag:focus-within .folge {
    -webkit-line-clamp: unset;
    line-clamp: unset;
    overflow: visible;
}

/* AUF SCHMALEN SCHIRMEN UNTEREINANDER. Drei Spalten auf 400 Pixeln sind drei
   Spalten Brei — dann lieber wieder ein Block, aber ein knapper. */
@media (max-width: 760px) {
    .card.vorschlaege .vorschlag {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas:
            "was"
            "folge"
            "wahl"
            "tun";
        align-items: stretch;
        row-gap: var(--s2);
        padding: var(--s3) 0;
    }

    .card.vorschlaege .tun {
        justify-content: flex-start;
    }
}

/* Zwei Töne für zwei Arten von Sicherheit. „Abgelesen" steht wörtlich im Dokument,
   „geschlossen" ist aus einem Indiz gefolgert - wer beides gleich einfärbt, bringt
   jemanden dazu, das Zweite wie das Erste zu behandeln. */
.card.vorschlaege .marke {
    padding: 2px 8px;
    border-radius: 999px;
    font-size: var(--t-xs);
    font-weight: 600;
    line-height: var(--lh-xs);
    background: var(--warn-soft);
    color: var(--warn);
}

.card.vorschlaege .marke.gelesen {
    background: var(--draft-soft);
    color: var(--draft);
}

/* Der Anteil einer Stufe am Weg einer Anfrage (itm-242).

   DIESELBE BALKENSPRACHE WIE IM PRUEFLAUF, nur in einer Tabellenzelle - eine zweite
   zu erfinden hiesse, dass zwei Balken in derselben Konsole Verschiedenes bedeuten
   koennten. Die Zahl steht links daneben; der Balken ist die Auskunft, die man im
   Vorbeigehen liest. */
.anteil {
    display: block;
    width: 100%;
    min-width: 60px;
    height: 6px;
    border-radius: 999px;
    background: var(--line);
    overflow: hidden;
}

.anteil > span {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: var(--brand);
}

/* Die Regel, die fuer mehrere Felder eines Abschnitts gilt (itm-251). Sie steht EINMAL
   oben statt an jedem Feld - und braucht deshalb Abstand nach unten, sonst klebt sie
   am ersten Etikett und liest sich wie dessen Hilfetext. */
.card > .help:first-child {
    margin-bottom: var(--s6);
}

/* WAS DAS SYSTEM TUT, HINTER EINEM ZEICHEN ZUM AUFKLAPPEN (itm-251). Es ist
   Dokumentation und keine Ausfuellhilfe; dauerhaft unter dem Feld macht sie das
   Formular laenger, ohne jemandem beim Eintragen zu helfen. */
details.mehr {
    margin-top: var(--s1);
}

details.mehr > summary {
    cursor: pointer;
    font-size: var(--t-2xs);
    color: var(--ink-3);
}

details.mehr > summary:hover {
    color: var(--ink-2);
}

details.mehr > .help {
    margin-top: var(--s1);
}

/* DER REST EINER LISTE, ZUSAMMENGEFALTET. Was die Frage der Seite nicht beantwortet,
   steht trotzdem noch da — nur nicht vor dem, was sie beantwortet (im Browser gesehen
   an „Betrifft das meine Mandanten?", 27.09.2026: vierzig Zeilen „nichts" ueber dem
   Ergebnis).

   ANDERS ALS `details.mehr`: Dort steckt ein Satz dahinter, hier eine ganze Karte.
   Die Zusammenfassung traegt deshalb Lesegroesse und nicht Fussnotengroesse — sie
   nennt eine Zahl, die zum Ergebnis gehoert. */
details.rest {
    margin: 0 0 var(--s6);
}

details.rest > summary {
    cursor: pointer;
    padding: var(--s2) 0;
    font-size: var(--t-sm);
    color: var(--ink-2);
}

details.rest > summary:hover {
    color: var(--ink);
}

/* DIE LISTE: eine Tabelle, die aufzaehlt (Befund der Gestaltungspruefung 22.09.2026).
   
   `table class="liste"` stand an sieben Stellen - Analyse, Wissensbasis, CID - und war
   NIRGENDS definiert; es gab nur `.schritte > .liste` fuer das Rueckgaengig-Menue. Die
   Tabellen liefen also im Browser-Standard: keine Zellabstaende, Koepfe fett und
   zentriert. Direkt darunter stehen `.changes`-Tabellen mit ruhigen, linksbuendigen
   Koepfen, und dann sieht die obere aus, als sei sie nicht fertig.
   
   ZWEI TABELLENARTEN, BEIDE DEFINIERT: `.changes` fuer die Gegenueberstellung mit
   festen Spaltenbreiten, `.liste` fuers Aufzaehlen ohne Breitenvorgabe. */
table.liste {
    width: 100%;
    border-collapse: collapse;
}

table.liste th {
    padding: 0 var(--s3) var(--s2) 0;
    border-bottom: 1px solid var(--line);
    text-align: left;

    /* Ein umgebrochener Kopf neben einem einzeiligen sieht aus wie ein Satzfehler,
       und die Koepfe dieser Tabellen sind durchweg ein bis zwei Woerter. */
    white-space: nowrap;
    font-size: var(--t-2xs);
    font-weight: 600;
    color: var(--ink-3);
}

table.liste td {
    padding: var(--s2) var(--s3) var(--s2) 0;
    border-bottom: 1px solid var(--line-soft, var(--line));
    vertical-align: middle;
}

table.liste tr:last-child td {
    border-bottom: 0;
}

/* DIE AUFRUFE EINES LAUFS, aufgeklappt in seiner Zeile (itm-437): kleiner und enger,
   damit die aeussere Tabelle ihre Zeilenhoehe behaelt, solange nichts aufgeklappt ist. */
table.liste.eng {
    margin-top: var(--s2);
    font-size: var(--t-sm);
}

table.liste.eng td {
    padding: var(--s1) var(--s3) var(--s1) 0;
}

/* ZAHLEN UNTEREINANDER AUF DERSELBEN BREITE, sonst flimmert die Spalte.

   BIS ZUM 23.09.2026 STAND DAS AN `td:first-child` — und in keiner der elf
   `.liste`-Tabellen ist die erste Spalte eine Zahl. Die Regel gab damit Tabellenziffern
   an Text und `nowrap` an eine Spalte, die bei langen Namen die Karte breiter macht,
   waehrend Aufrufe, Median und Kosten proportional und linksbuendig standen und genau
   das Flimmern zeigten, das der Kommentar verhindern wollte. Die Spalte sagt jetzt
   selbst, dass sie eine Zahl traegt. */
table.liste td.num,
table.liste th.num {
    font-variant-numeric: tabular-nums;
    text-align: right;
    white-space: nowrap;
}

/* DER DRITTE ZUSTAND BRAUCHT EINE KLASSE (itm-251, Befund der Gestaltungspruefung).
   
   „aus der Konfiguration" bekam einen LEEREN Klassennamen - die Pille hatte dann weder
   Flaeche noch Rand und erbte die Textfarbe der Umgebung: in der rechten Spalte
   --ink-2, in der Tabelle --ink. Dieselbe Auskunft sah an zwei Stellen verschieden aus
   und an beiden wie ein Rest. Ein Zustand ohne Klasse ist keiner. */
.zustand.neutral {
    color: var(--ink-2);
    background: var(--surface-2);
    border-color: var(--line);
}

/* DIE VIER RECHTSSCHICHTEN ALS ZEICHEN (itm-246).

   A bis D, wie sie in den Bauplaenen und in jeder Besprechung heissen. Vier farbige
   Punkte waeren eine Farbe ohne Aussage; der Buchstabe sagt, WELCHE Schicht gemeint
   ist, die Farbe sagt, wie weit sie ist, und der Titel sagt beides in Worten. */
.schichten {
    display: inline-flex;
    gap: 3px;
    margin-right: var(--s2);
    vertical-align: middle;
}

.schicht {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 17px;
    height: 17px;
    border-radius: var(--r-sm);
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--ink-3);
    font-size: var(--t-2xs);
    font-weight: 700;
    line-height: 1;
}

.schicht.gut {
    border-color: color-mix(in srgb, var(--ok) 40%, transparent);
    background: var(--ok-soft);
    color: var(--ok);
}

/* Angefangen und nicht belegt: Es gibt Quellen, aber keine freigegebene mit
   auffindbaren Abschnitten. Der Unterschied ist der ganze Sinn der Spalte.

   `teil` UND NICHT `steht`: `.zustand.steht` ist rot. Dasselbe Klassenwort zweimal
   verschieden zu faerben hiess, dass in DERSELBEN Zeile „angefangen" als orangefarbenes
   Zeichen und als rote Pille stand. */
.schicht.teil {
    border-color: color-mix(in srgb, var(--warn) 40%, transparent);
    background: var(--warn-soft);
    color: var(--warn);
    border-style: dashed;
}

/* DREI FORMEN, NICHT DREI FARBEN (Gestaltungspruefung 23.09.2026).

   Die Abdeckung ist die Kernaussage der Themenseite und hing an einer Eigenschaft, die
   ein Teil der Nutzer nicht hat. Gefuellt heisst belegt, gestrichelt heisst angefangen,
   gepunktet heisst fehlt — lesbar auch dort, wo die Farben gleich aussehen. Der Zustand
   steht zusaetzlich als Wort im Zeichen, fuer die Vorlesesoftware. */
.schicht.leer {
    border-style: dotted;
    opacity: 0.75;
}

/* Was die drei Formen heissen. Ohne sie ist die Spalte eine Farbe ohne Aussage —
   dieselbe Auflage wie bei der Punktelegende der Navigation. */
.schichten-legende {
    display: flex;
    flex-wrap: wrap;

    /* Der waagrechte Abstand traegt die Trennung. Bei --s5 lasen sich die drei
       Eintraege im Browser als EIN Satz: „…auffindbar B angefangen…". */
    gap: var(--s2) var(--s8);
    margin-top: var(--s4);
    font-size: var(--t-2xs);
    color: var(--ink-3);
}

.schichten-legende > span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

/* Fuer Vorlesesoftware da, fuer das Auge nicht. `title` ist per Tastatur nicht
   erreichbar, auf Touch gar nicht und wird uneinheitlich vorgelesen. */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* EIN VERSTECKTES DATEIFELD BLEIBT VERSTECKT (07.10.2026). `input[type="file"]` weiter oben setzt `width: 100%` und
   schlägt `.sr-only` an Gewicht — das Feld hinter LIAs Ablegen-Knopf war damit fensterbreit, absolut gesetzt, und
   schob die Seite im KI Hub um bis zu 260 Pixel nach rechts (seitliches Scrollen ab 1100 Pixeln Breite). */
input[type="file"].sr-only {
    width: 1px;
    padding: 0;
    border: 0;
}

/* BEFUGNISSE ALS HAKENLISTE (itm-213).

   Gruppiert und nicht als eine Reihe von neun: „Wissen" und „Verwaltung" sind zwei
   verschiedene Fragen, und wer Rechte vergibt, entscheidet sie nacheinander.

   Der <fieldset> ist die richtige Klammer und nicht nur die bequeme: Vorlesesoftware
   nennt die <legend> vor jedem Haken darin, und ohne sie hiesse jeder Eintrag nur
   „Freigeben und zurueckweisen" - ohne den Bereich, in dem das gilt. */
.befugnisse {
    margin: 0 0 var(--s4);
    padding: var(--s3) var(--s4) var(--s2);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
}

/* OHNE VERSALIEN UND OHNE SPERRUNG (itm-244, Befund cino).

   Hier standen beide, drei Bildschirme unter dem Kommentar in dieser Datei, der sie
   ausdruecklich ausschliesst: „der Prototyp setzt sie an fuenfzehn Stellen, wir an
   keiner". Sichtbar waren sie auf der Rechteseite an zwoelf Legenden und auf der
   Benutzermaske an vier — und 11 px gesperrte Versalien sind ausgerechnet die
   schlechteste Groesse dafuer.

   Das Gewicht kommt jetzt aus Fettung und Farbe, genau die Begruendung, die auch
   --t-h2 traegt. */
.befugnisse > legend {
    padding: 0 var(--s2);
    font-size: var(--t-xs);
    font-weight: 700;
    color: var(--ink-3);
}

.haken {
    margin-bottom: var(--s3);
}

.haken > label {
    display: flex;
    align-items: center;
    gap: var(--s2);
    margin: 0;
    font-weight: 600;
    cursor: pointer;
}

.haken input[type="checkbox"] {
    width: auto;
    margin: 0;
    flex: none;
}

/* DER SATZ, DER SAGT, WAS DER HAKEN BEWIRKT. Eingerueckt auf die Hoehe des
   Beschriftungstextes, damit er zum Haken gehoert und nicht zum naechsten. */
.haken > .help {
    margin: 2px 0 0 calc(var(--s2) + 1.1em);
}

/* „zusaetzlich" und „entzogen" an einem Haken. Kursiv abgeschaltet: Das Zeichen ist
   eine Auszeichnung und kein Zitat, und <em> traegt hier nur die Bedeutung. */
.haken .zustand {
    font-style: normal;
}

/* EINE GEFILTERTE LISTE, DIE BEIM TIPPEN MITGEHT (itm-296).

   Der Knopf „Filtern" steht im Markup und verschwindet erst, wenn das Skript
   wirklich gelaufen ist - `lebt` setzt es selbst. Ohne JavaScript bleibt die Seite
   damit vollständig bedienbar, und das ist die Bedingung, unter der der Sofortfilter
   überhaupt gebaut ist. */
form.lebt > button[type="submit"] {
    display: none;
}

/* WÄHREND GELADEN WIRD, EIN RUHIGES ZEICHEN. Die alte Liste bleibt stehen, bis die
   neue da ist - eine leere Liste zwischendurch liest sich als „nichts gefunden", und
   zwar genau in dem Moment, in dem jemand noch tippt.

   Gedämpft und nicht animiert: Ein Kreisel bei jedem Tastendruck ist Unruhe an einer
   Stelle, an der jemand gerade liest. */
.filter.filtert .chips,
.filter.filtert + .treffer {
    opacity: .55;
    transition: opacity .12s ease-out;
}

/* DER TEXT EINES ABSCHNITTS, SO WIE DAS MODELL IHN SIEHT (itm-272).

   Als <pre> und nicht als Absatz: Der Umbruch gehört zum Abschnitt. Wer einen
   schlechten Schnitt sucht, sucht abgerissene Sätze und Kopfzeilen mitten im Text -
   und die verschwinden, sobald der Browser den Text neu umbricht.

   Trotzdem umbrechend, denn ein Abschnitt ist kein Quelltext: Waagrecht scrollen
   müsste man bei jeder Zeile, und gelesen wird hier. */
pre.chunk {
    margin: 0;
    padding: var(--s3);
    max-height: 22em;
    overflow-y: auto;
    white-space: pre-wrap;
    overflow-wrap: break-word;
    font-family: inherit;
    font-size: var(--t-sm);
    line-height: var(--lh-body);
    color: var(--ink-2);
    background: var(--surface-2, rgba(127, 127, 127, .07));
    border-radius: var(--r-md);
}

/* Der Abschnitt, den jemand aus der Analyse heraus gesucht hat. Ohne die Markierung
   führt der Verweis auf eine Seite mit zwanzig Kästen, und der gemeinte ist einer
   davon. */
.card.abschnitt.gesucht {
    border-color: var(--accent);
    box-shadow: 0 0 0 1px var(--accent);
    scroll-margin-top: var(--s6);
}

/* ===== ZUORDNUNG (itm-203, itm-297) =====

   HIER UND NICHT IN EINER SEITE, seit die Zuordnung an BEIDEN Enden steht: am Bot
   (viele Quellen auf einmal) und an der Quelle (die wenigen Bots, die sie erreichen).
   Bereichsbezogene Stile erreichen die andere Seite nicht - dort standen bis dahin
   Aufzaehlungspunkte statt einer Liste. *//* Zuordnung der Wissensquellen. Kästchen und Beschriftung nebeneinander, die
   Einordnung darunter - was eine Quelle ist, entscheidet sich an Thema und
   Eigentümer, nicht am Titel allein. */
.assign {
    list-style: none;
    margin: 0 0 var(--s4);
    padding: 0;
}

.assign li {
    display: flex;
    align-items: flex-start;
    gap: var(--s3);
    padding: var(--s2) 0;
    border-top: 1px solid var(--border);
}

.assign li:first-child {
    border-top: 0;
}

.assign input {
    width: auto;
    height: auto;
    margin-top: 3px;
}

.assign label {
    margin: 0;
    font-size: var(--t-body);
    font-weight: 400;
    color: var(--ink);
    text-transform: none;
    cursor: pointer;
}

.assign .meta {
    display: block;
    font-weight: 400;
}


/* Die Gruppen der Zuordnungsliste (itm-297). Eine flache Liste ueber sechsundsiebzig
   Quellen war der Befund; nach Thema gruppiert und zuklappbar ist sie zu ueberblicken. */
.zuordnung .gruppe {
    margin: 0 0 var(--s3);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    padding: var(--s3) var(--s4);
}

.zuordnung .gruppe > summary {
    cursor: pointer;
    font-weight: 600;
}

.zuordnung .gruppe > summary .meta {
    margin-left: var(--s2);
    font-weight: 400;
}

/* Eine Gruppe, die der Filter ganz wegblendet, nimmt keinen Platz - ihre Kaestchen
   bleiben aber im Formular (siehe zuordnung.js). */
.zuordnung .gruppe[hidden],
.zuordnung [data-zeile][hidden] {
    display: none;
}

.zuordnung .treffer {
    margin: 0 0 var(--s3);
    color: var(--ink-2);
}
/* ZWEI HANDGRIFFE IN EINER ZELLE (itm-300).

   Die Themenzeile trägt jetzt den Verweis auf die Schlagworte UND den Schalter. Ohne
   diese Regel stehen ein Link und ein <form> unmittelbar nebeneinander, und im
   Browser las sich das als ein Wort: "SchlagworteAbschalten". Das Formular ist ein
   Block, der Link ist es nicht - flex bringt beide auf eine Zeile mit Abstand.

   Rechtsbündig, weil die Spalte es ist: Die Aktionen stehen am Zeilenende, wo das
   Auge sie über alle Zeilen hinweg an derselben Stelle findet. */
.zeilen-aktionen {
    display: flex;
    gap: var(--s3);
    align-items: baseline;
    justify-content: flex-end;
}

.zeilen-aktionen form {
    margin: 0;
}

/* DIE THEMEN-TABELLE PASST IN DIE KARTE (Martin, 04.10.2026: „die zeilenumbrüche passen auch nicht.
   das fenster geht zuweit nach rechts"). Der Knopf „Nicht nach außen nennen" brach in vier Zeilen um,
   und die Aktionen schoben die Tabelle trotzdem über den Rand. Jetzt: kurze Wörter, keine Umbrüche in
   Zahlen, Zustand und Aktionen; umbrechen darf nur der Name. */
.themen-tabelle th,
.themen-tabelle td {
    white-space: nowrap;
    vertical-align: middle;
}

.themen-tabelle td:first-child,
.themen-tabelle tr.gruppe th,
.themen-tabelle tr.rueckfrage td {
    white-space: normal;
}

.themen-tabelle td:first-child {
    width: 100%;
}

.themen-tabelle .zeilen-aktionen {
    gap: var(--s2);
    align-items: center;
}

/* DIE RÜCKFRAGE HÄNGT AN IHRER ZEILE (itm-300), nicht am Seitenende: In einer Liste
   beantwortet eine Meldung am Ende nicht mehr die Frage, die in einer bestimmten
   Zeile gestellt wurde. Abgesetzt, damit sie nicht wie eine weitere Zeile der
   Tabelle aussieht. */
.liste tr.rueckfrage td {
    background: var(--sunken);
    border-left: 3px solid var(--warn);
}

.liste tr.rueckfrage p {
    margin: var(--s2) 0;
}

.liste tr.rueckfrage form {
    display: flex;
    gap: var(--s3);
    align-items: center;
    margin: 0;
}

/* DER DUBLETTENBEFUND AN EINER DOKUMENTZEILE (itm-63).

   Abzeichen, Titel des Zwillings und zwei Knöpfe auf einer Zeile. Ohne diese Regel
   stapeln sie sich: Jeder Knopf steckt in einem eigenen <form>, und ein <form> ist
   ein Block — derselbe Fall wie bei den Themen.

   Leise gehalten: Der Befund ist ein HINWEIS und keine Sperre. Beide Fassungen sind
   auffindbar, solange niemand entscheidet, und eine Zeile, die lauter ist als der
   Titel darüber, machte aus einem Hinweis eine Mahnung. */
.dublette {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: var(--s2) var(--s3);
    margin-top: var(--s2);
    font-size: var(--t-sm);
}

.dublette form {
    margin: 0;
}

/* DIE ZIELGRUPPE AN DER ZEILE (Befund mrkurator, 24.09.2026).

   Vier Quellen zur optischen Strahlung stehen nebeneinander, und was sie
   unterscheidet, ist `Audience` — Betriebe, Bund, Land- und Forstwirtschaft. Das
   Feld ist ein HARTER Filter im Retrieval: Wer die falsche zuordnet, bekommt eine
   Quelle, die der Bot nie findet, und sieht ihr das in keiner Spalte an.

   NEBEN DEM TITEL UND NICHT ALS ZEHNTE SPALTE. Die Tabelle läuft schon quer
   (itm-184); eine Spalte, die bei den meisten Zeilen leer bleibt, kostet Breite für
   alle und sagt nur dort etwas, wo Titel sich ähneln. Genau dort steht sie jetzt.

   Leise, weil es eine Einordnung ist und keine Warnung: Wer die Zielgruppe gesetzt
   hat, hat alles richtig gemacht. */
.fuer {
    display: inline-block;
    margin-left: var(--s2);
    padding: 1px var(--s2);
    border: 1px solid var(--line);
    border-radius: var(--r-sm);
    font-size: var(--t-2xs);
    font-weight: 500;
    color: var(--ink-3);
    white-space: nowrap;
}

/* DER LASCHENSTREIFEN DER ASSISTENTENSEITE (itm-244).

   BEFUND cino, 24.09.2026: Zehn Abschnitte und acht Formulare untereinander, und wer
   die Seite oeffnet, braucht genau eines davon. Zwoelf gleich schwere `h2` sind keine
   Gliederung, sondern eine Liste.

   ALS LINKS UND NICHT ALS KNOEPFE, weil es welche sind: Jede Lasche ist eine echte
   Adresse. Die Unterstreichung faellt weg, der Rest bleibt ein Link — mit
   Tastaturfokus, Mittelklick und Kontextmenue.

   DIE AKTIVE LASCHE TRAEGT EINE LINIE UND KEINE FLAECHE. Eine gefuellte Lasche neben
   drei leeren ist ein zweiter Akzent auf einem Bildschirm, auf dem der Knopf „Bot
   ausprobieren“ schon einer ist (itm-174, Ein-Akzent-Regel). Die Linie sagt dasselbe
   und nimmt nichts weg. */
.laschen {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s4);
    margin: var(--s4) 0 var(--s6);
    border-bottom: 1px solid var(--line);
}

.laschen > a {
    padding: var(--s2) 0;
    margin-bottom: -1px;
    border-bottom: 2px solid transparent;
    color: var(--ink-2);
    font-size: var(--t-ui);
    font-weight: 600;
    text-decoration: none;
}

.laschen > a:hover {
    color: var(--ink);
    border-bottom-color: var(--line);
    text-decoration: none;
}

.laschen > a.on {
    color: var(--ink);
    border-bottom-color: var(--brand);
}

/* EINE ZAHL AN EINER LASCHE (itm-405).

   Sie sagt, wie viel dahintersteht, BEVOR man klickt — bei einer Mandantenakte ist
   das der Unterschied zwischen „drei Vertraege" und „keiner". Gerechnet, nie
   eingetragen (itm-181), und eine Null erscheint gar nicht: Eine „0" an jeder Lasche
   liest nach einer Woche niemand mehr.

   GEDAEMPFT UND KLEIN. Die Lasche ist die Navigation, die Zahl ein Zusatz — faerbt
   man sie, hat der Bildschirm sechs Akzente statt einem (itm-205). */
.laschen > a .zahl {
    display: inline-block;
    margin-left: 6px;
    padding: 1px 6px;
    border-radius: var(--r-full);
    background: var(--sunken);
    color: var(--ink-3);
    font-size: var(--t-2xs);
    font-weight: 600;
    line-height: var(--lh-2xs);
}

.laschen > a.on .zahl {
    background: var(--brand);
    color: #fff;
}

/* DIE EINTRAEGE EINES BAUPLANS, DIE AUF EINE BESTAETIGUNG WARTEN (itm-315).

   Je Zeile Titel, Adresse und ein Knopf. Die Adresse steht ausgeschrieben und nicht
   hinter dem Titel versteckt: Wer sie pruefen soll, muss sie LESEN koennen, bevor er
   sie aufruft — die Nummer am Ende ist die ganze Frage. */
.pruefen {
    list-style: none;
    margin: var(--s3) 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: var(--s3);
}

.pruefen > li {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--s2) var(--s4);
    padding: var(--s3);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface-2);
    font-size: var(--t-sm);
}

/* Eine lange Adresse bricht um, statt die Zeile zu sprengen. */
.pruefen a {
    word-break: break-all;
}

.pruefen form {
    margin: 0;
}

/* ANGEFANGENES EINBRINGEN: Löschen und Weiter nebeneinander, die Rückfrage an derselben Stelle. */
.pruefen .aktionen,
.pruefen form.verwerfen {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--s2);
}

.pruefen > li > .form-error {
    flex-basis: 100%;
}

/* ===== EIN SPRUNGZIEL LANDET NIE BUENDIG AM RAND (itm-244, Nachtrag) =====

   BEFUND VON MARTIN am 24.09.2026, aus der Restliste heraus: „er springt soweit
   runter, dass ich den Titel der Box nicht sehe." Der Link „Kurzbezeichnung
   eintragen" zeigte auf das EINGABEFELD; der Browser schob es an die obere Kante, und
   Beschriftung wie Kartenueberschrift standen darueber und damit ausserhalb des
   Bildes. Man landete an einem Feld, ohne zu erfahren, welches.

   GLOBAL UND NICHT JE SEITE. Die Regel gab es zweimal — auf der Quellenseite und an
   der gesuchten Analysekarte — und damit ueberall dort nicht, wo sie niemand
   nachgetragen hat. Das ist cinos Prozessbefund vom selben Tag, hier als eine Zeile:
   Sie wirkt ab jetzt fuer jedes kuenftige Ziel mit. */
:target {
    scroll-margin-top: var(--s6);
}

/* DAS ZIEL IST DIE FELDGRUPPE, NICHT DAS FELD, und sie zeigt sich als getroffen.

   Das ist die eigentliche der beiden Regeln. Ohne die Markierung beantwortet der
   Sprung die Frage nicht, die er aufwirft: wo bin ich gelandet. Bei zwanzig Feldern
   untereinander sieht eines aus wie das andere — dasselbe Muster wie die
   hervorgehobene Zeile in itm-272.

   AM RAND UND NICHT ALS FLAECHE: Eine eingefaerbte Feldgruppe sieht aus wie ein
   Fehler. Sie ist keiner, sie ist nur die gemeinte.

   OHNE ZEITSCHALTUNG: Die Markierung verschwindet, sobald jemand ein anderes Ziel
   anspringt oder die Seite neu laedt — und solange er an diesem Feld arbeitet, soll
   sie stehenbleiben. Eine Hervorhebung, die nach drei Sekunden ausblendet, ist genau
   dann weg, wenn er vom Lesen zum Tippen kommt. */
.field:target {
    padding-left: var(--s3);
    border-left: 2px solid var(--accent);
}

/* ===== EIN FORMULAR IST EIN RASTER, KEINE SPALTE (itm-244) =====

   BEFUND cino, 24.09.2026: Vierundzwanzig Felder untereinander in einer Karte, die
   1280 Pixel breit ist. Zwei Drittel der Breite bleiben leer, und die Seite wird
   dreimal so lang wie noetig — man scrollt an Feldern vorbei, die nebeneinander
   Platz haetten.

   ENTSCHEIDUNG VON MARTIN am 24.09.2026: zwei Spalten, und was Platz braucht, bekommt
   die ganze Zeile. Strikt halbe Breite waere ruhiger und machte den Titel eines
   Gesetzes zu kurz zum Lesen.

   ALLES SPANNT, NUR EIN FELD NICHT. Die Regel steht herum, und das ist Absicht: In
   einem Formular stehen Ueberschriften, Hinweise, Pruefzusammenfassungen und Knoepfe
   zwischen den Feldern, und jedes davon einzeln zu nennen hiesse, das naechste zu
   vergessen. Was nicht ausdruecklich ein Feld ist, nimmt die ganze Zeile. */
.raster {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: var(--s6);
}

.raster > * {
    grid-column: 1 / -1;
}

.raster > .field {
    grid-column: auto;
}

/* Was eine ganze Zeile braucht: der Titel eines Gesetzes, eine Adresse, eine
   Fassungsangabe im RIS-Wortlaut (bis 250 Zeichen), ein Freitext. Halbiert waeren sie
   nicht mehr zu lesen, und ein Feld, dessen Inhalt man nicht sieht, prueft niemand. */
.raster > .field.weit {
    grid-column: 1 / -1;
}

/* UND WAS DIE GANZE ZEILE BEKOMMEN HAT, FUELLT SIE AUCH. Sonst ist `weit` eine Zusage
   ohne Wirkung: Das Feld spannt ueber beide Spalten, und die Eingabe darin bleibt bei
   den 680 Pixeln stehen, die fuer ein gewoehnliches Feld die Lesebreite sind. Genau
   diese Felder tragen das Lange. */
.raster > .field.weit input:not([type="checkbox"]):not([type="radio"]),
.raster > .field.weit textarea,
.raster > .field.weit select {
    max-width: none;
}

/* AB HIER IST NEBENEINANDER ENGER ALS UNTEREINANDER. Unter rund 900 Pixeln stehen
   zwei Eingaben so dicht, dass die Beschriftung der rechten an der linken klebt. */
@media (max-width: 900px) {
    .raster {
        grid-template-columns: 1fr;
    }
}

/* DIE GRUPPE IN EINER KARTE IST EINE h3 UND KEINE h2 (itm-244).

   BEFUND cino: `h2` trug drei Bedeutungen — die Ueberschrift der rechten Spalte, den
   Abschnitt ueber einer Karte, und die Gruppe darin. Zwoelf gleich schwere
   Ueberschriften sind keine Gliederung, sondern eine Liste.

   Leiser als die h2 darueber, aber deutlich schwerer als eine Feldbeschriftung: Sie
   muss beim Ueberfliegen als Trennung wirken, ohne mit dem Abschnittstitel zu
   konkurrieren. */
.card h3 {
    margin: var(--s6) 0 var(--s3);
    font-size: var(--t-h3);
    font-weight: 600;
    color: var(--ink);
}

/* Die erste Gruppe einer Karte braucht den Abstand nach oben nicht — darueber steht
   der Rand der Karte. */
.card h3:first-child,
.raster > h3:first-of-type {
    margin-top: 0;
}

/* Was in einer Gruppenueberschrift hintereinander steht — Kosten, „ohne Grundlage",
   „hier gekippt" — braucht Luft dazwischen. Blazor wirft den Leerraum zwischen den
   Elementen weg, und die Zeile lautete „0.0006 $ohne Grundlage". */
.card h3 > span + span {
    margin-left: var(--s2);
}

/* ===== DIE RECHTEMATRIX (itm-244) =====

   BEFUND cino, 24.09.2026; Entscheidung von Martin am selben Tag. Je Rolle eine Karte
   mit denselben neun Haken: Die Frage, die hier jemand stellt, ist fast nie „was darf
   der Kurator", sondern „worin unterscheiden sich Kurator und Freigeber" — und
   untereinander ist das ein Vergleich ueber drei Bildschirme.

   DIE ERSTE SPALTE TRAEGT DEN TEXT, die uebrigen tragen ein Zeichen. Deshalb bekommt
   sie die Breite und die anderen nur so viel, wie ein Haken braucht. */
.matrix {
    width: 100%;
    border-collapse: collapse;
}

.matrix th,
.matrix td {
    padding: var(--s3);
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

.matrix thead th {
    border-bottom: 1px solid var(--border-strong);
    font-size: var(--t-ui);
    font-weight: 600;
    white-space: nowrap;
}

/* Die Rollenspalten so schmal wie moeglich: Jede Breite, die sie nehmen, fehlt der
   Befugnis daneben — und die traegt den Satz, an dem man sie erkennt. */
.matrix thead th:not(:first-child),
.matrix tbody td {
    width: 1%;
    text-align: center;
}

.matrix tbody td {
    vertical-align: middle;
}

/* Die Zeile mit dem Namen der Befugnis. `scope="row"` macht sie zur Kopfzelle, und
   eine Kopfzelle steht sonst fett — hier ist sie der Inhalt und nicht die
   Ueberschrift. */
.matrix tbody th[scope="row"] {
    font-weight: 500;
    max-width: 34rem;
}

.matrix .meta {
    display: block;
    margin-top: 2px;
    font-size: var(--t-xs);
    font-weight: 400;
    color: var(--ink-3);
    white-space: normal;
}

/* Die Gruppe als eigene Zeile. Leise und gesperrt waere sie ein zweites Mal
   Versalien — geschrieben wird sie wie eine Zwischenueberschrift, nicht wie ein
   Etikett. */
.matrix tr.gruppe > th {
    padding-top: var(--s6);
    border-bottom: none;
    font-size: var(--t-h3);
    font-weight: 600;
    color: var(--ink);
}

.matrix tr.gruppe:first-child > th {
    padding-top: 0;
}

/* Das feste Haekchen des Administrators. Nicht als abgeschaltetes Kaestchen: Ein
   ausgegrautes Haekchen liest sich wie etwas, das man einschalten koennte. */
.matrix td.hat {
    color: var(--ink-3);
}

.matrix label {
    display: inline-flex;
    margin: 0;
    cursor: pointer;
}

/* ===== DIE SPUR EINER ANFRAGE (itm-242) =====

   ENTSCHEIDUNG VON MARTIN am 24.09.2026, nachdem er den Entwurf neben den gebauten
   Stand gelegt hat: "das Layout sieht einfach schoen aus, Farben, Tabellen,
   Aufteilung usw." Was den Entwurf gut aussehen laesst, ist benennbar, und es steht
   hier - Zahl und Erklaerung getrennt, genau ein Akzent, Balken mit Position statt
   nur Laenge, ein Untertitel je Zeile, der sie ERKLAERT.

   UEBERNOMMEN WIRD AUFBAU UND ANORDNUNG, NICHT DIE SKALA. Der Prototyp setzt 13,5 px
   Systemschrift und Versalien mit Sperrung; beides gilt hier ausdruecklich nicht
   (siehe die Skala weiter oben). Ein reines Abmalen waere stellenweise ein
   Rueckschritt gegenueber dem CI. */

/* ---- Der Weg als Wasserfall ---- */

.lanes {
    display: grid;
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    overflow: hidden;
    margin-bottom: var(--s4);
}

.lane {
    background: var(--surface);
    display: grid;
    grid-template-columns: var(--s6) minmax(0, 15rem) 1fr auto auto;
    gap: var(--s3);
    align-items: center;
    padding: var(--s2) var(--s4);
}

.lane .no {
    font-variant-numeric: tabular-nums;
    font-size: var(--t-xs);
    font-weight: 700;
    color: var(--ink-3);
}

.lane .nm {
    font-weight: 600;
    font-size: var(--t-ui);
}

/* DER UNTERTITEL ERKLAERT DIE ZEILE, STATT SIE ZU BENENNEN. Er steht unter dem Namen
   und nicht daneben: Nebeneinander liest er sich wie ein zweiter Name. */
.lane .nm em {
    display: block;
    font-style: normal;
    font-size: var(--t-xs);
    font-weight: 400;
    color: var(--ink-3);
}

/* EIN BALKEN, DER EINE POSITION ZEIGT UND NICHT NUR EINE LAENGE. Das ist der
   Unterschied zu `.anteil`, und beide bleiben nebeneinander bestehen: `.anteil` ist
   ein Anteil an einem Ganzen, dieser hier ist ein Zeitpunkt in einem Ablauf. Zwei
   Balken, die Verschiedenes bedeuten, muessen verschieden aussehen. */
.lane .spanne {
    position: relative;
    height: var(--s3);
    background: var(--surface-3);
    border-radius: var(--r-sm, 8px);
    overflow: hidden;
}

.lane .spanne i {
    position: absolute;
    top: 0;
    bottom: 0;
    display: block;
    background: var(--brand);
    border-radius: var(--r-sm, 8px);
}

.lane .ms,
.lane .ct {
    font-variant-numeric: tabular-nums;
    font-size: var(--t-sm);
    text-align: right;
    white-space: nowrap;
    color: var(--ink-2);
    min-width: var(--s16);
}

/* IM IMPORTVERLAUF steht die Wartezeit unter der Dauer, nicht daneben: Daneben drückt sie den Balken zusammen. */
.lanes.import .ms em {
    display: block;
    font-style: normal;
    font-size: var(--t-xs);
    color: var(--ink-3);
}

/* DIE LANGSAMSTEN UND DIE TEUERSTEN ABSCHNITTE (itm-663): ein Streifen links und eine Marke mit Wort. Zwei Töne, weil
   „lange gedauert" und „viel gekostet" verschiedene Fragen sind; trifft beides zu, stehen beide Streifen nebeneinander. */
.lanes.import .lane.langsam {
    box-shadow: inset 4px 0 0 var(--warn);
}

.lanes.import .lane.teuer {
    box-shadow: inset 4px 0 0 var(--draft);
}

.lanes.import .lane.langsam.teuer {
    box-shadow: inset 4px 0 0 var(--warn), inset 8px 0 0 var(--draft);
}

.lanes.import .lane.langsam .ms {
    color: var(--warn);
    font-weight: 700;
}

.lanes.import .lane.teuer .ct {
    color: var(--draft);
    font-weight: 700;
}

.spitze {
    display: inline-block;
    margin-left: var(--s2);
    padding: 0 var(--s2);
    border-radius: var(--r-sm, 8px);
    font-size: var(--t-xs);
    font-weight: 700;
    white-space: nowrap;
    vertical-align: middle;
}

.spitze.langsam {
    background: var(--warn-soft);
    color: var(--warn);
}

.spitze.teuer {
    background: var(--draft-soft);
    color: var(--draft);
}

.spitzen-legende .spitze {
    margin-left: 0;
}

/* DIE AUFRUFE EINES AUFGEKLAPPTEN ABSCHNITTS stehen im Wasserfall direkt unter ihrer Zeile, eingerückt wie ein Kind. */
.lanes .lane-aufrufe {
    background: var(--surface-2);
    padding: var(--s3) var(--s4) var(--s3) calc(var(--s6) + var(--s4) + var(--s3));
}

.lanes .lane-aufrufe .technik-zeile:last-child {
    margin-bottom: 0;
}

/* ---- Der Trichter ---- */

.funnel {
    display: grid;
    gap: var(--s2);
    margin-bottom: var(--s4);
}

.fl {
    display: grid;
    grid-template-columns: 1fr minmax(0, 22rem);
    gap: var(--s4);
    align-items: center;
}

/* DIE ZAHL STEHT IM BALKEN. Sie ist die Auskunft, der Balken ihr Mass - nebeneinander
   liest man zweimal dasselbe und einmal davon zu klein. */
.flbar {
    position: relative;
    height: var(--s8);
}

.flbar > span {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    padding-left: var(--s3);
    background: var(--surface-3);
    border: 1px solid var(--line);
    border-radius: var(--r-sm, 8px);
    font-size: var(--t-sm);
    font-weight: 650;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    color: var(--ink);
}

/* GENAU EIN AKZENT, UND ER MARKIERT IMMER DASSELBE: was in die Antwort gegangen ist.
   Hier die letzte Stufe des Trichters, weiter unten die mitgeschickten Abschnitte -
   und sonst nichts in dieser Ansicht. Ein Akzent, der an zwei Stellen Verschiedenes
   bedeutet, bedeutet nichts. */
.fl.keep .flbar > span {
    background: var(--accent-soft);
    border-color: var(--accent);
}

.fl .rule {
    font-size: var(--t-sm);
    color: var(--ink-2);
}

.fl .rule b {
    display: block;
    font-weight: 600;
    color: var(--ink);
}

/* ---- Was mitgegangen ist ---- */

.hits {
    display: grid;
    gap: var(--s2);
}

.hit {
    display: grid;
    grid-template-columns: var(--s6) 1fr auto;
    gap: var(--s3);
    align-items: start;
    padding: var(--s3) var(--s4);
    background: var(--accent-soft);
    border: 1px solid var(--line);
    border-left: 3px solid var(--accent);
    border-radius: var(--r-sm, 8px);
}

.hit .rk {
    font-variant-numeric: tabular-nums;
    font-size: var(--t-h3);
    font-weight: 700;
    color: var(--ink-3);
    text-align: center;
}

.hit .ds {
    font-variant-numeric: tabular-nums;
    font-size: var(--t-sm);
    white-space: nowrap;
    color: var(--ink-2);
}

/* SCHMALE FENSTER: Der Wasserfall traegt fuenf Spalten und der Trichter zwei - beides
   bricht unter rund 60 Zeichen Breite in Unlesbarkeit um. Dann untereinander, und der
   Balken behaelt seine Aussage, weil die Zahl daneben steht und nicht in ihm. */
@media (max-width: 720px) {
    .lane {
        grid-template-columns: var(--s6) 1fr auto;
        row-gap: var(--s2);
    }

    .lane .spanne {
        grid-column: 1 / -1;
    }

    .fl {
        grid-template-columns: 1fr;
        gap: var(--s2);
    }
}

/* Woher ein mitgeschickter Abschnitt kam, wenn es nicht die Aehnlichkeit war
   (itm-333). Unter dem Etikett und leiser: Es ist eine Auskunft ueber den Weg, nicht
   ueber die Stelle. */
.hit .woher {
    display: block;
    font-style: normal;
    font-size: var(--t-xs);
    color: var(--ink-3);
}

/* AUS WELCHEM STAND DIESES ABBILD GEBAUT IST (itm-349). Leise: Es ist eine
   Auskunft, die man sucht, und keine, die sich aufdraengen soll. */
nav .stand {
    padding: var(--s2) var(--s3) var(--s4);
    font-size: var(--t-2xs);
    color: var(--ink-3);
}

/* DER WEGWEISER DES GEFUEHRTEN WEGES (itm-364).

   EIGENE KLASSE UND NICHT `.schritte`: Die ist im Rahmen fuer das aufklappbare
   Rueckgaengig-Menue vergeben (`> summary`, `> .liste`). Eine `<ol class="schritte">`
   erbte davon nichts und stand als nackte Nummernliste im Seitenkopf - genau der
   Fehler, den die Gestaltungspruefung am 22.09.2026 schon einmal an `table.liste`
   gefunden hat: eine Klasse, die es woanders gibt und hier nicht meint, was sie sagt.

   WAAGRECHT UND MIT MARKE AM AKTUELLEN SCHRITT. Ein Weg, der nicht zeigt, wo man
   steht, ist eine Folge von Seiten und kein Weg: Wer nicht sieht, wie viele Schritte
   noch kommen, bricht beim ersten Zweifel ab. */
ol.wegweiser {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--s2) var(--s3);
    margin: 0 0 var(--s6);
    padding: 0;
    list-style: none;
    counter-reset: wegweiser;
}

ol.wegweiser li {
    display: flex;
    align-items: center;
    gap: var(--s2);
    counter-increment: wegweiser;
    font-size: var(--t-sm);
    color: var(--ink-3);
    white-space: nowrap;
}

/* Die Ziffer im Kreis. Sie traegt den Zustand, nicht die Schrift daneben - so bleibt
   die Zeile ruhig, auch wenn vier Schritte nebeneinander stehen. */
ol.wegweiser li::before {
    content: counter(wegweiser);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border: 1px solid var(--line);
    border-radius: var(--r-full);
    background: var(--surface-2);
    font-size: var(--t-2xs);
    font-variant-numeric: tabular-nums;
}

/* Der Trennstrich zwischen zwei Schritten. Am ersten nicht, sonst beginnt die Zeile
   mit einem Strich ins Nichts. */
ol.wegweiser li + li::after {
    content: "";
    order: -1;
    width: var(--s4);
    height: 1px;
    margin-right: var(--s1);
    background: var(--line);
}

ol.wegweiser li.erledigt {
    color: var(--ink-2);
}

/* ERLEDIGT TRAEGT EIN HAKERL UND KEINE ZIFFER. Die Ziffer beantwortet „der
   wievielte", das Hakerl „schon vorbei" - und auf einem Weg ist die zweite Frage die,
   die man im Vorbeigehen stellt. */
ol.wegweiser li.erledigt::before {
    content: "\2713";
    border-color: color-mix(in srgb, var(--ok) 35%, transparent);
    background: var(--ok-soft);
    color: var(--ok);
}

ol.wegweiser li.jetzt {
    color: var(--ink);
    font-weight: 600;
}

/* DER AKZENT ALS GEFUELLTE FLAECHE GEHOERT ALLEIN DEM NAECHSTEN SCHRITT (itm-205),
   und ein Waechter haelt das fest. Der aktuelle Schritt bekommt deshalb den Rand und
   den Ton, nicht die Flaeche - er ist eine Auskunft, keine Handlung. Die Handlung auf
   dieser Seite ist der Knopf darunter. */
ol.wegweiser li.jetzt::before {
    border-color: var(--accent);
    background: var(--accent-soft);
    color: var(--accent-ink);
}

/* Der Knopf im Fussbereich steht neben dem Zurueck-Link und darf die Zeile nicht
   auseinanderziehen: Das Formular ist nur der Traeger des Knopfes. */
.seiten form {
    display: contents;
}

/* HIER HINSEHEN (itm-80).

   Der Assistent in der Anwendung bringt den Fragenden an die Stelle und hebt sie
   hervor. `zeigen.js` setzt die Klasse, wenn die Adresse `?zeig=` trägt, und nimmt sie
   nach vier Sekunden wieder weg.

   DAS ORANGE IST HIER RICHTIG UND KEIN REGELBRUCH (itm-205). Die Regel lautet: Der
   Akzent markiert die Handlung, nicht die Kulisse, und genau eine Sache je Bildschirm.
   Das hier IST diese eine Sache — „hier hinsehen" ist die ganze Aussage —, und sie
   steht nur, solange jemand gerade hingeführt wurde. Eine Hervorhebung, die bleibt,
   wäre nach dem zweiten Mal genau die Kulisse, die die Regel ausschliesst.

   DER RING LIEGT AUSSERHALB DES FELDES (`outline` statt `border`): Ein Rahmen
   verschöbe das Feld um zwei Pixel, und die ganze Karte spränge beim Ankommen. */
.wird-gezeigt {
    /* DER RING TRAEGT `--accent-ink` UND NICHT `--accent` (Befund cino,
       nachgerechnet): Das helle Orange erreicht gegen den Seitengrund 2,48:1 und
       gegen Kartenweiss 2,66:1 - unter den 3:1, die fuer ein Element gelten, das
       eine Auskunft traegt. Ausgerechnet die Markierung waere damit die leiseste
       Stelle des Bildschirms gewesen. `--accent-ink` liegt bei 4,6:1 und ist im
       Dunkelmodus ohnehin derselbe Ton wie der Akzent. */
    outline: 3px solid var(--accent-ink);
    outline-offset: 4px;
    border-radius: var(--r-sm);
    background: var(--accent-soft);
}

/* DIE BESCHRIFTUNG UND DER SATZ DARUNTER GEHOEREN ZUR STELLE. Sie liegen IM Feld,
   seit `zeigen.js` den Umschlag markiert und nicht mehr das Eingabefeld (Befund
   cino) - vorher waren es Geschwister, und diese beiden Regeln liefen ins Leere. */
.wird-gezeigt .help,
.wird-gezeigt label {
    color: var(--accent-ink);
}

/* Aufblenden, damit die Markierung als Bewegung ankommt und nicht als Zustand, der
   schon immer da war. Wer `prefers-reduced-motion` gesetzt hat, bekommt sie ohne —
   die Auskunft bleibt, nur die Bewegung fällt weg. */
@media (prefers-reduced-motion: no-preference) {
    .wird-gezeigt {
        animation: gezeigt .45s var(--ease);
    }

    @keyframes gezeigt {
        from { outline-color: transparent; background: transparent; }
    }
}

/* EINE EINFACHE AUFZAEHLUNG MIT TRENNLINIEN (Befund cino, 26.09.2026).

   Die Regeln standen in `Mandanten.razor.css` und waren damit BEREICHSGEBUNDEN: Sechs
   Seiten benutzen die Klasse, auf fuenf davon griff keine Zeile. Sie standen dort als
   nackte Aufzaehlung mit Punkten und 40px Einzug — Wissensbasis, Wissensquelle,
   Quelle bearbeiten, Bot bearbeiten, und seit heute Nacht die Hilfeseite.

   Eine Klasse, die sechs Seiten benutzen, ist keine Seitenklasse. */
.listing {
    list-style: none;
    margin: 0 0 var(--s6);
    padding: 0;
}

.listing li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--s4);
    padding: var(--s2) 0;
    border-top: 1px solid var(--line);
}

.listing li:first-child {
    border-top: 0;
}

.listing .name {
    font-weight: 600;
}

/* ===== DIE DIENSTE-SEITE (itm-392) ===== */

/* GEGLIEDERT STATT TABELLIERT. Die Ueberschrift traegt die Kostenaussage fuer die
   ganze Gruppe; die Zahl daneben sagt, wie viel davon laeuft — gerechnet, nicht
   eingetragen. */
.gruppe {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--s3);
    margin: var(--s6) 0 var(--s2);
    font-size: var(--t-h3);
}

.gruppe:first-child {
    margin-top: 0;
}

.gruppe .n {
    font-size: var(--t-sm);
    font-weight: 400;
    color: var(--ink-3);
}

/* OBEN AUSGERICHTET UND NICHT AN DER GRUNDLINIE: Links stehen bis zu drei Zeilen,
   rechts Pille, Herkunft und Knopf. An der Grundlinie ausgerichtet haengte der Knopf
   irgendwo in der Mitte des Beschreibungstextes. */
.listing.dienste li {
    align-items: flex-start;
    gap: var(--s4);
    padding: var(--s3) 0;
}

.listing.dienste .was {
    min-width: 0;
}

/* DIE RECHTE SEITE HAT EINE FESTE BREITE UND EINE ZEILE.

   FEST, damit Pillen und Knoepfe untereinander auf zwei Fluchtlinien stehen: Ohne sie
   richtet sich jede Zeile nach der Laenge ihres eigenen Zustandsworts — „laeuft" gegen
   „abgeschaltet" sind 60 Pixel Unterschied, und die Spalte flimmert.

   EINE ZEILE, weil gestapelt jede Zeile ueber hundert Pixel hoch wurde und neun
   Dienste damit nicht mehr auf einen Bildschirm passten. Pille links, Knopf rechts —
   Zustand und Handlung dazu, in der Reihenfolge, in der man sie liest. */
.listing.dienste .wie {
    flex: 0 0 210px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--s3);
}

.listing.dienste .wie form {
    margin: 0;
}

.listing.dienste .wann {
    margin-top: var(--s1);
    font-size: var(--t-2xs);
}

/* DER GRIFF ZUR HILFE, ALS ORANGES SYMBOL (itm-80).

   Wunsch von Martin am 26.09.2026: kein Knopf mit der Aufschrift „Wie geht das?",
   sondern ein oranges Hilfesymbol.

   ZUR HAUSREGEL, WEIL ES SIE STREIFT: itm-205 gibt den Akzent als GEFUELLTE FLAECHE
   genau einer Sache je Bildschirm — dem naechsten Schritt rechts unten. Das hier ist
   ein GLYPH in `--accent-ink` ohne Platte; dieselbe Unterscheidung, die die Zahlen in
   der linken Spalte schon treffen. Der naechste Schritt behaelt seinen Rang, und die
   Farbe sagt hier dasselbe wie dort, wo der Assistent danach das Feld markiert:
   hier hinsehen. */
.hilfegriff {
    color: var(--accent-ink);
    padding-inline: var(--s2);
}

.hilfegriff svg {
    width: 18px;
    height: 18px;
    display: block;
}

/* Beim Ueberfahren kraeftiger und nicht anders: Die Farbe IST die Auskunft. */
.hilfegriff:hover {
    color: var(--accent-ink);
    border-color: var(--accent-ink);
}

/* AUFGEKLAPPT TRAEGT ER DIE FLAECHE — und zwar nur dann. Ein dauerhaft gefuellter
   oranger Knopf in der Leiste waere die zweite gefuellte Flaeche neben dem naechsten
   Schritt; einer, der nur im geoeffneten Zustand faerbt, sagt „dieses Fenster ist
   offen" und nimmt niemandem den Rang. */
.hilfegriff[aria-expanded="true"] {
    background: var(--accent-soft);
    border-color: var(--accent-ink);
}

/* ===== DIE MODELLSEITE (itm-248) ===== */

/* Dieselbe Zeilenform wie die Dienste: links, was es ist, rechts, was mit ihm ist.
   Etwas breiter, weil rechts Preise stehen und keine Pille. */
.listing.klassen .wie,
.listing.orte .wie {
    flex: 0 0 260px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: var(--s1);
    text-align: right;
}

.listing.klassen li,
.listing.orte li,
.listing.wege li {
    align-items: flex-start;
    gap: var(--s4);
    padding: var(--s3) 0;
}

/* Die Messung traegt drei Zeilen Zahlen und braucht mehr Platz als eine Pille. */
.listing.wege .wie.breit {
    flex: 0 0 300px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: var(--s1);
    text-align: right;
}

.listing.klassen .was,
.listing.orte .was,
.listing.wege .was {
    min-width: 0;
}

/* ===== BESCHRIFTUNGEN IN DIAGRAMMEN (itm-412) =====

   HIER UND NICHT IM BEREICHSGEBUNDENEN STYLESHEET DER KOMPONENTE, und das ist keine
   Nachlaessigkeit, sondern der einzige Ort, an dem diese Regeln greifen koennen.

   === DER BEFUND, 27.09.2026, im Browser ===

   In den Diagrammen standen die Namen SCHWARZ und LINKSBUENDIG ueber den Balken.
   Grund: `<text>` ist in Razor ein eigenes Element und nimmt keine Attribute, deshalb
   erzeugen `Saeulen`, `Tagesverlauf`, `Pruefverlauf` und `Landkarte` ihre
   Beschriftungen als fertiges Markup (`MarkupString`).

   BEREICHSGEBUNDENES CSS HAENGT AN EINEM ATTRIBUT, das Blazor beim Rendern an jedes
   Element schreibt — und was als fertiges Markup hereinkommt, bekommt es nicht. Im
   Browser nachgemessen: Das `<rect>` daneben trug `b-0m2dihidcq`, das `<text>` trug
   `x`, `y` und `class`. Die Regel `.saeulen .marke` wird zu `.saeulen .marke[b-…]`
   und trifft nie.

   ES FAELLT NICHT AUF, WEIL ES NICHT KAPUTT AUSSIEHT: Der Text steht da, nur in
   Schwarz und an der falschen Seite verankert — er lief quer ueber die Balken.

   === WARUM NICHT INLINE AM ERZEUGTEN MARKUP ===

   Ginge auch, und waere vier Stellen, an denen Farbe und Schriftgroesse stehen. Beim
   naechsten Diagramm waere es die fuenfte, und im Dunkelmodus muesste jede davon
   ihre eigene Variable kennen. Hier steht es einmal.

   JEDE KOMPONENTE ZEIGT MIT EINEM KOMMENTAR HIERHER, damit niemand die Regel neben
   ihr Diagramm schreibt und sich wundert. */

.saeulen .marke,
.tagesverlauf .marke,
.verlauf .marke {
    font-family: var(--font-ui);
}

/* Die Beschriftung an der Achse: rechtsbuendig, damit alle Balken an derselben
   Kante beginnen und die Namen eine Linie bilden statt einer Treppe. */
.saeulen .marke {
    fill: var(--ink-2);
    font-size: 12px;
    text-anchor: end;
}

.saeulen .wert {
    fill: var(--ink);
    font-size: 12px;
    font-weight: 600;
    font-family: var(--font-ui);
}

.tagesverlauf .marke {
    fill: var(--ink-3);
    font-size: 10px;
}

.tagesverlauf .marke.rechts {
    text-anchor: end;
}

.tagesverlauf .marke.mitte {
    text-anchor: middle;
}

/* DIE AEUSSEREN DATUMSMARKEN WERDEN NACH INNEN VERANKERT (itm-412). Mittig gesetzt
   ragte die letzte ueber den rechten Rand und stand als „27.(" da — ein
   abgeschnittenes Datum ist schlimmer als keines, denn man liest es trotzdem. */
.tagesverlauf .marke.links {
    text-anchor: start;
}

.tagesverlauf .marke.rechts {
    text-anchor: end;
}

.verlauf .marke {
    fill: var(--ink-faint);
    font-size: 10px;
}

.verlauf .marke.rechts {
    text-anchor: end;
}

.verlauf .marke.mitte {
    text-anchor: middle;
}

.verlauf .marke.schwach {
    opacity: .75;
}

/* IN DER DASHBOARD-KARTE GRÖSSER (Befund von Martin, 03.10.2026). Prüfverlauf und
   Bewegung zeichnen 640 Einheiten breit; in einer Karte von gut 400 Pixeln stand die
   Schrift bei 6 Pixeln. Tagesverlauf und Säulen bekommen dort eine schmale Bildbreite
   mit; diese beiden haben ihre Maße noch fest im Code, deshalb hier die Schrift. */
.dash-raster .verlauf .marke {
    font-size: 15px;
}

/* DIE ANTWORTZEITEN VON SCALIENTO (Martin, 09.10.2026) — dieselbe Regel wie oben: Die Beschriftung kommt als fertiges
   Markup und gehört deshalb hierher. Achse rechtsbündig, Zeiten an den Rändern nach innen verankert, die Schwellen in
   ihrer Zustandsfarbe. */
.antwortzeiten .marke {
    fill: var(--ink-faint);
    font-family: var(--font-ui);
    font-size: 10px;
}

.antwortzeiten .marke.rechts {
    text-anchor: end;
}

.antwortzeiten .marke.mitte {
    text-anchor: middle;
}

.antwortzeiten .marke.links {
    text-anchor: start;
}

.antwortzeiten .marke.langsam {
    fill: var(--warn);
    font-weight: 600;
}

.antwortzeiten .marke.kritisch {
    fill: var(--stop);
    font-weight: 600;
}

.dash-raster .bewegung .wert {
    font-size: 16px;
}

/* Die Kaesten der Landkarte. Sie kommen vollstaendig als Markup herein — Rahmen,
   Name und Zusatz —, deshalb steht hier auch das Rechteck. */
.landkarte .knoten rect {
    fill: var(--surface-2);
    stroke: var(--line);
    stroke-width: 1;
}

.landkarte .knoten .name {
    fill: var(--ink);
    font-size: 10.5px;
    font-weight: 600;
    font-family: var(--font-ui);
}

.landkarte .knoten .zusatz {
    fill: var(--ink-3);
    font-size: 9px;
    font-family: var(--font-ui);
}

/* EIN ASSISTENT, AN DEM ETWAS FEHLT. Nicht nur die Farbe: Der Rahmen wird kraeftiger
   UND der Mangel steht in der Tabelle darunter im Wortlaut. */
.landkarte .knoten.offen rect {
    stroke: var(--accent);
    stroke-width: 1.6;
}

/* ===== DIE ABLAGE FUER DATEIEN (itm-407, itm-364) =====

   SIE STEHT GLOBAL UND NICHT AN EINER SEITE: Sie wird an zwei Stellen gebraucht —
   „Dokument erkennen" nimmt eine Datei, „Wissen einbringen" einen Stapel. Zwei
   Kopien derselben Regeln gingen beim naechsten Umbau auseinander, und die zweite
   saehe niemand.

   SIE SIEHT ERST AUS WIE EINE ABLAGE, WENN SIE EINE IST: Die Klasse `bereit` setzt
   `ablage.js`, und zwar erst, nachdem es sich angebunden hat. Ein gestrichelter
   Rahmen ohne Funktion waere ein Versprechen, das die Seite nicht haelt.

   DAS `*/` NACH „saehe niemand" WAR ZU VIEL (Befund cino, 28.09.2026): Der Absatz
   darunter stand damit ausserhalb jedes Kommentars, der Parser las ihn als Beginn
   eines Selektors und verwarf die Regel darunter samt ihrem Ziel. Ausgerechnet die
   Regel, die dieser Absatz begruendet — der Ziehhinweis stand also immer da, auch
   ohne Skript und ohne Rahmen. Ein Versprechen, das die Seite nicht haelt. */
.ablage .ziehhinweis {
    display: none;
}

.ablage.bereit {
    padding: var(--s3);
    border: 1px dashed var(--line);
    border-radius: var(--r-md);
    transition: border-color .12s, background-color .12s;
}

.ablage.bereit .ziehhinweis {
    display: block;
    margin: var(--s2) 0 0;
    font-size: var(--t-sm);
    color: var(--ink-3);
}

/* WAEHREND ETWAS DARUEBER HAENGT. Ohne diese Rueckmeldung weiss niemand, ob die
   Ablage die Datei nimmt — man laesst los und hofft. */
.ablage.drueber {
    border-color: var(--brand);
    border-style: solid;
    background: var(--brand-soft, rgba(37, 56, 120, .05));
}

.ablage [data-ablage-name]:empty {
    display: none;
}

.ablage [data-ablage-name] {
    margin: var(--s2) 0 0;
    color: var(--ink);
}

/* EIN FELD, DAS NUR ETWAS SAGT (itm-72).

   Es steht in der Reihe der Formularfelder und ist keines: Der Wert ist nicht zu
   aendern, solange es nichts zu waehlen gibt. Er sieht deshalb aus wie ein
   ausgefuelltes Feld und nicht wie ein leeres — ein Rahmen, in dem nichts geschieht,
   laedt zum Klicken ein und tut dann nichts.

   NICHT ALS ABGESCHALTETES AUSWAHLFELD, obwohl das naheliegt: Ein `disabled`
   `<select>` mit einem Eintrag behauptet, es gaebe etwas zu waehlen. */
.field > .wert {
    margin: 0;
    padding: 10px 0;
    font-size: var(--t-ui);
    color: var(--ink);
    font-weight: 600;
}

/* ===== DAS ABLAUFBILD MIT SEINEM BEARBEITUNGSFELD (itm-459) =====

   Links das Bild, rechts das Feld, in dem bearbeitet wird — und das Feld bleibt beim
   Blättern stehen: Wer einen Schritt weit unten anklickt, soll nicht nach oben laufen
   müssen, um ihn zu ändern. Unter 1000 Pixeln steht beides untereinander. */
.ablauf-werkbank {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--s6);
    align-items: start;
    margin-bottom: var(--s8);
}

@media (min-width: 1000px) {
    .ablauf-werkbank {
        grid-template-columns: minmax(0, 1.25fr) minmax(300px, 1fr);
    }

    .ablauf-werkbank .ablauf-feld {
        position: sticky;
        top: var(--s6);
    }
}

.ablauf-feld h3 {
    margin-top: 0;
}

.ablauf-knoepfe {
    margin-top: var(--s4);
}

/* ===== DIE KARTE ALLER TEMPLATES (itm-459) ===== */
.template-karte {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--s4);
    margin-bottom: var(--s8);
}

.template-karte .card {
    margin: 0;
}

.template-karte .kopfzeile {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--s2);
    margin-bottom: var(--s2);
}

.template-karte .wer {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s1) var(--s3);
    margin-top: var(--s3);
    font-size: var(--t-sm);
    color: var(--ink-2);
}

/* ===== EIN TEXT ZUM KOPIEREN (Export für Claude, 29.09.2026) ===== */
.kopiertext .kopfzeile {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--s3);
}

.kopiertext textarea {
    width: 100%;
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-size: var(--t-xs);
}

/* EINE TABELLE DIREKT UNTER DEN FILTERCHIPS (Vorgänge, 29.09.2026) klebte an ihnen —
   die Chips sind Filter und nicht der Tabellenkopf. */
.chips + .table-scroll,
.chips + .treffer {
    margin-top: var(--s4);
}

/* DIE AUSWAHL DER BAUSTEINE ALS KARTEN (Entscheidung von Martin, 29.09.2026: „Auswahl
   mit Karten"). Je Baustein ein Verweis mit Name, dem, was dahinter arbeitet, und einem
   Satz. Ein Raster und keine Liste: Man vergleicht nebeneinander, womit ein Schritt
   arbeitet. */
.bausteinkarten {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: var(--s3);
    margin-top: var(--s3);
}

.bausteinkarte {
    display: flex;
    flex-direction: column;
    gap: var(--s2);
    padding: var(--s3);
    border: 1px solid var(--line);
    border-radius: var(--r-sm);
    background: var(--surface, transparent);
    color: inherit;
    text-decoration: none;
}

.bausteinkarte:hover,
.bausteinkarte:focus-visible {
    border-color: var(--accent-ink);
}

.baustein-kopf {
    margin-bottom: var(--s3);
}

/* WAS DAHINTER ARBEITET — als Marke, in Worten und nicht nur in Farbe: Wer Farben
   schlecht unterscheidet, liest den Namen. Die Maschine (Sprachmodell, Jev) hebt sich
   ab, weil dort geurteilt wird. */
.antriebe {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s1);
}

.antrieb {
    font-size: var(--t-2xs);
    padding: 1px 8px;
    border-radius: 999px;
    border: 1px solid var(--line);
    color: var(--ink-2, var(--ink));
}

.antrieb.sprachmodell,
.antrieb.jev {
    border-color: var(--accent-ink);
    color: var(--accent-ink);
}

/* ============================================================================
   DAS SEITENRASTER (itm-434)
   ============================================================================

   BEFUND VON MARTIN, 28.09.2026, für acht Seiten: „Man kennt sich einfach nicht aus."
   Die Seiten reihten alles untereinander, ohne Gewichtung, ohne Gruppen, ohne
   erkennbaren Einstieg. ENTSCHEIDUNG VON MARTIN, 29.09.2026: Das Raster wird hier
   festgelegt und auf alle Seiten gezogen.

   DIE HÜLLE BLEIBT, WIE SIE IST (itm-174): links die Navigation, rechts die
   Wirkungsspalte mit dem nächsten Schritt. Das Raster ordnet NUR die Mitte, und zwar
   in dieser Reihenfolge, von oben nach unten:

     1. KOPF        — `h1` und EIN Satz `.lead`: welche Frage diese Seite beantwortet.
     2. EINSTIEG    — `.einstieg`: höchstens vier Kacheln mit einer Zahl und einem Wort.
                      Jede ist ein Link, der die Seite auf genau das eingrenzt. Wer die
                      Seite öffnet, sieht zuerst, wo etwas liegt.
     3. LASCHEN     — `.laschen`, wenn die Seite mehr als eine Aufgabe hat (Anfragen und
                      Wissenslücken, Zuordnung und Preise). Eine Lasche ist eine Adresse.
     4. BLATT       — `.blatt`: links das, woran gearbeitet wird (`.blatt-haupt`), rechts,
                      was dazugehört (`.blatt-neben`: Eigenschaften, Zuordnungen, kleine
                      Formulare). Schmal stapelt es — das Hauptfeld zuerst.
     5. TEILE       — jeder Abschnitt ein `.teil`: Kopfzeile mit `h2`, Zahl und Handgriff
                      (`.teil-kopf`), ein Satz Hilfe darunter (DoD 6), dann der Inhalt.
                      Was selten gebraucht wird, steht in `details.teil-mehr` und ist zu.
     6. GEFAHRENZONE — `.gefahrenzone`, immer zuletzt: Löschen und was sich nicht
                      zurücknehmen lässt, mit derselben Rückfrage wie überall.

   GEWICHTUNG STATT GLEICHER KÄSTEN: Das Hauptfeld ist doppelt so breit wie das
   Nebenfeld, und nur der Einstieg trägt grosse Zahlen. Zwölf gleich schwere `h2`
   untereinander sind keine Gliederung, sondern eine Liste (itm-244, Befund cino). */

.einstieg {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: var(--s3);
    margin: var(--s4) 0 var(--s6);
}

.einstieg > a,
.einstieg > div {
    display: block;
    padding: var(--s3) var(--s4);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    background: var(--surface);
    color: var(--ink);
    text-decoration: none;
}

.einstieg > a:hover {
    border-color: var(--border-strong);
    text-decoration: none;
}

/* DIE GEWÄHLTE KACHEL TRÄGT EINE LINIE, KEINE FLÄCHE — dieselbe Regel wie bei den
   Laschen (Ein-Akzent-Regel, itm-174). */
.einstieg > a.on {
    border-color: var(--brand);
    box-shadow: inset 0 0 0 1px var(--brand);
}

.einstieg .zahl {
    font-size: var(--t-h2);
    font-weight: 600;
    line-height: 1.2;
}

.einstieg .wofuer {
    font-size: var(--t-sm);
    color: var(--ink-2);
}

/* EINE KACHEL, DIE AUF ARBEIT ZEIGT, sagt es mit der Zahl und nicht mit der Fläche. */
.einstieg .zahl.offen {
    color: var(--accent-ink);
}

.blatt {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr);
    gap: var(--s6);
    align-items: start;
}

.blatt-haupt,
.blatt-neben {
    min-width: 0;
}

.blatt-haupt > * + *,
.blatt-neben > * + * {
    margin-top: var(--s4);
}

@media (max-width: 1100px) {
    .blatt {
        grid-template-columns: minmax(0, 1fr);
    }
}

.teil-kopf {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--s3);
    margin-bottom: var(--s2);
}

.teil-kopf h2,
.teil-kopf h3 {
    margin: 0;
}

.teil-kopf .n {
    color: var(--ink-3);
    font-size: var(--t-sm);
    font-weight: 400;
}

.teil-kopf a {
    font-size: var(--t-sm);
    white-space: nowrap;
}

.teil > .help:first-of-type {
    margin-top: 0;
}

details.teil-mehr {
    margin-top: var(--s4);
}

details.teil-mehr > summary {
    cursor: pointer;
    color: var(--ink-2);
    font-size: var(--t-ui);
    font-weight: 600;
}

/* DIE GEFAHRENZONE STEHT ZULETZT und ist die einzige Karte mit roter Kante. Der Knopf
   darin führt auf dieselbe Rückfrage wie bisher — eine zweite Fassung des Löschens wäre
   eine zweite Stelle, an der es schiefgehen kann. */
.gefahrenzone {
    margin-top: var(--s8);
    border-color: var(--danger);
    background: var(--danger-soft);
}

.gefahrenzone h2 {
    margin-top: 0;
    font-size: var(--t-h3);
}

/* ===== DAS TESTEN DES CHATBOT-TESTERS (30.09.2026) =====
   Links das Gespraech, gross; rechts, was geschehen ist, je Antwort eine Karte mit der
   Rueckmeldung. Unter 1100 Pixeln untereinander. */
.testen { max-width: 1480px; }
.testen-kopf { display: flex; gap: 16px; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; }
.testen-kopf .lead { max-width: 70ch; }
.testen-werkzeuge { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.testen-werkzeuge form { display: flex; gap: 8px; align-items: center; }
.testen-flaeche { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 16px; margin: 12px 0 24px; }
.testen-gespraech iframe { width: 100%; height: max(560px, calc(100vh - 240px)); border: 1px solid var(--line); border-radius: 12px; background: var(--surface); display: block; }
/* EIN ASSISTENT IM TESTEN (01.10.2026): das Vorgangsfenster in voller Breite, darunter die Einschätzung. */
.testen-vorgang { display: flex; flex-direction: column; gap: 16px; margin: 12px 0 24px; }
.testen-gespraech.breit iframe { height: max(640px, calc(100vh - 220px)); }
.vorgang-rueckmeldung fieldset { display: flex; flex-wrap: wrap; gap: 6px 16px; border: 0; padding: 0; margin: 8px 0; }
.testen-spur { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; max-height: max(560px, calc(100vh - 240px)); overflow: auto; }
.testen-spur > h2 { margin-top: 0; }
.testerrunde { border-top: 1px solid var(--line-soft); padding: 12px 0; }
.testerrunde:first-child { border-top: 0; }
.testerrunde header { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.testerrunde h2 { font-size: 15px; margin: 0; }
.testerrunde h3 { font-size: 12.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-2); margin: 12px 0 4px; }
.testerrunde .antworttext { white-space: pre-wrap; margin: 0; }
.testerrunde .stellen { margin: 4px 0; padding-left: 18px; }
.testerrunde .ablauf { margin: 4px 0; padding-left: 20px; }
.testerrunde .rueckmeldung { margin-top: 12px; padding: 10px 12px; background: var(--paper); border-radius: 8px; }
.testerrunde .rueckmeldung fieldset { border: 0; padding: 0; margin: 0 0 8px; display: flex; flex-wrap: wrap; gap: 6px 14px; }
.testerrunde .rueckmeldung legend { font-weight: 600; margin-bottom: 4px; }
.testerrunde .rueckmeldung .wahl { display: inline-flex; gap: 6px; align-items: center; }
.testerrunde .rueckmeldung textarea { width: 100%; box-sizing: border-box; }
.testerrunde .knoepfe { display: flex; gap: 10px; align-items: center; margin-top: 6px; flex-wrap: wrap; }
.testerrunde .unsere-antwort { margin: 8px 0 0; }
@media (max-width: 1100px) {
    .testen-flaeche { grid-template-columns: 1fr; }
    .testen-spur { max-height: none; }
}

/* ===== KENNZAHLEN-KACHELN UND KOMPAKTE DIAGRAMME (Martin, 01.10.2026, M27/U29) =====

   „Die Charts sollen nicht so groß sein wie aktuell. eher kompakt und viele Infos." Kacheln in einem
   Raster, das sich der Breite anpasst; jede ist ein Link auf die Seite, aus der ihre Zahl stammt
   (itm-181: eine Zahl ohne die Liste dahinter ist keine Auskunft). Die Diagramme stehen in drei
   Spalten und wachsen mit ihrer Spalte, nicht mit der Seite. Global, weil Übersicht und Auswertung
   sie teilen. */
.kpi-raster {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: var(--s2);
    margin: var(--s3) 0 var(--s4);
}

.kpi {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: var(--s2) var(--s3);
    border: 1px solid var(--line);
    border-radius: var(--r-md, 8px);
    background: var(--surface);
    color: var(--ink);
    text-decoration: none;
    min-width: 0;
}

.kpi:hover {
    border-color: var(--ink-3);
}

.kpi .w {
    font-size: var(--t-lg, 1.25rem);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.kpi .l {
    font-size: var(--t-xs, 0.75rem);
    color: var(--ink-3);
    line-height: 1.3;
}

.kpi.warn {
    border-color: var(--accent);
}

.kpi.warn .w {
    color: var(--accent-ink);
}

.dash-raster {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: var(--s3);
    align-items: start;
}

.dash-raster > .card.dash {
    margin: 0;
    padding: var(--s3);
}

.dash-raster > .card.dash h3 {
    margin: 0 0 var(--s2);
    font-size: var(--t-sm);
}

.dash-raster figcaption {
    font-size: var(--t-xs, 0.75rem);
}

/* „SO LIEST MAN DIESE SEITE" (J19, 01.10.2026): eine aufklappbare Erklärung über einer Messseite. */
details.erklaerung > summary {
    cursor: pointer;
    font-weight: 600;
}

details.erklaerung dl {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: var(--s2) var(--s4);
    margin: var(--s3) 0 0;
    font-size: var(--t-sm);
}

details.erklaerung dt {
    font-weight: 600;
}

details.erklaerung dd {
    margin: 0;
}

td.urteil {
    white-space: nowrap;
}

td.urteil button.on {
    font-weight: 700;
}

/* DIE TESTSEITE DES LIVE-GERÜSTS (itm-505). */
.live-kopf {
    display: flex;
    justify-content: space-between;
    gap: var(--s3);
    margin-bottom: var(--s3);
}

.live-zustand {
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

.live-zustand[data-zustand="verbunden"] {
    color: var(--ok);
}

.live-zustand[data-zustand="unterbrochen"] {
    color: var(--accent-ink);
}

.live-knoepfe {
    display: flex;
    gap: var(--s2);
    margin-bottom: var(--s3);
}

.live-liste {
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: var(--t-sm);
}

.live-zeile {
    display: grid;
    grid-template-columns: 4em 6em 10em 1fr;
    gap: var(--s2);
    padding: var(--s1) var(--s2);
    border-radius: 4px;
}

.live-zeile.rueckblick {
    opacity: .7;
}

/* Was gerade ankommt, leuchtet kurz auf — das Rückblick-Ereignis nicht. */
.live-zeile.neu {
    animation: live-neu 1.6s ease-out;
}

@keyframes live-neu {
    from { background: var(--accent-soft); }
    to { background: transparent; }
}

@media (prefers-reduced-motion: reduce) {
    .live-zeile.neu {
        animation: none;
    }
}

/* DER UMSCHALTER DES ARBEITSBEREICHS IM KOPF (itm-486). */
.bereichswahl {
    display: inline-flex;
    border: 1px solid var(--line-soft);
    border-radius: 999px;
    padding: 2px;
    margin-right: var(--s3);
    background: var(--surface-2);
}

.bereichswahl form {
    margin: 0;
}

.bereichswahl a,
.bereichswahl button {
    text-decoration: none;
    white-space: nowrap;
    border: 0;
    border-radius: 999px;
    padding: var(--s1) var(--s3);
    font-size: var(--t-sm);
    background: transparent;
    color: var(--ink-muted);
    cursor: pointer;
    box-shadow: none;
}

.bereichswahl a:hover {
    color: var(--ink);
}

.bereichswahl a.on,
.bereichswahl button.on {
    background: var(--surface);
    color: var(--ink);
    font-weight: 600;
    box-shadow: var(--shadow-xs);
}

/* DER KALENDER VON LIA (itm-487). Eine Woche als Spalten, ein Termin als Karte. */


.kalender-aktionen {
    display: flex;
    gap: var(--s3);
    align-items: center;
}

.kalender-loeschen {
    margin-top: var(--s4);
}


.termin {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: var(--s2);
    padding: var(--s2);
    border-left: 3px solid var(--navy-soft, var(--ink-muted));
    border-radius: 4px;
    background: var(--surface-2);
    font-size: var(--t-sm);
}

/* Was LIA eingetragen hat, trägt den Akzent — dieselbe Farbe wie „hier hinsehen". */
.termin.lia {
    border-left-color: var(--accent);
    background: var(--accent-soft);
}

.termin .zeit {
    font-variant-numeric: tabular-nums;
    color: var(--ink-muted);
}

.termin form {
    margin: var(--s1) 0 0;
}

/* Ein Termin, der gerade erscheint (itm-493), leuchtet kurz auf. */
.termin.neu {
    animation: live-neu 1.6s ease-out;
}

/* DER KONTAKTVERLAUF EINER FIRMA (itm-487). */
.service-verlauf {
    list-style: none;
    margin: 0;
    padding: 0;
}

.service-verlauf li {
    display: grid;
    grid-template-columns: 9em 6em 1fr;
    gap: var(--s3);
    padding: var(--s2) 0;
    border-bottom: 1px solid var(--line-soft);
    font-size: var(--t-sm);
}

.service-verlauf .wann {
    font-variant-numeric: tabular-nums;
    color: var(--ink-muted);
}

/* DAS POSTFACH VON LIA (itm-488). */
.postfach-kopf {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--s3);
    margin-bottom: var(--s3);
}

.postfach-liste tr.erledigt {
    opacity: .6;
}

/* Die Stimmung als Farbe: ruhig grau, ungeduldig und verärgert im Akzent, panisch rot. */
.stimmung {
    display: inline-block;
    padding: 0 var(--s2);
    border-radius: 999px;
    font-size: var(--t-sm);
    background: var(--surface-2);
}

.stimmung.ungeduldig,
.stimmung.veraergert {
    background: var(--accent-soft);
    color: var(--accent-ink);
}

.stimmung.panisch {
    background: var(--stop-soft);
    color: var(--danger, #B42318);
    font-weight: 600;
}

.faden {
    list-style: none;
    margin: 0;
    padding: 0;
}

.faden .mail {
    padding: var(--s3);
    margin-bottom: var(--s3);
    border-radius: 8px;
    border: 1px solid var(--line-soft);
}

.faden .mail.aus {
    margin-left: var(--s8);
    background: var(--surface-2);
}

.mailtext {
    white-space: pre-wrap;
    font-family: inherit;
    margin: 0;
}

/* ===== DIE LIA-SEITE (itm-494, itm-493, itm-516) ===== */
.lia-heute {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s3);
    margin-bottom: var(--s4);
}

.lia-zahl {
    padding: var(--s2) var(--s4);
    border-radius: 999px;
    background: var(--surface);
    border: 1px solid var(--line-soft);
    color: var(--ink);
    text-decoration: none;
    font-size: 14px;
}

.lia-zahl.warn {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.lia-buehne {
    display: grid;
    grid-template-columns: minmax(340px, 7fr) minmax(280px, 5fr);
    gap: var(--s4);
    align-items: start;
}

@media (max-width: 1100px) {
    .lia-buehne {
        grid-template-columns: 1fr;
    }
}

.lia-gespraech {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 220px);
    min-height: 420px;
    padding: 0;
    overflow: hidden;
}

/* DAS GEGENÜBER (Martin, 02.10.2026): Man spricht mit LIA — das Logo steht gross in der Mitte,
   darunter ihr letzter Satz wie ein Untertitel. Der Chat tritt in den Hintergrund. */
.lia-gegenueber {
    position: relative;
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    align-items: center;

    /* „SAFE": Passt der Inhalt nicht, beginnt er oben statt über den Rand hinaus zu ragen —
       sonst lassen sich die obersten Zeilen nicht einmal mehr hinscrollen. */
    justify-content: safe center;
    gap: var(--s3);
    padding: var(--s4) var(--s5, 24px);
    overflow-y: auto;
    text-align: center;
}

.lia-neu {
    position: absolute;
    top: var(--s3);
    right: var(--s3);
}

/* LIAS GESICHT (itm-502): das Scaliento-Logo, umgeben von einer Leinwand für Ringe, Punkte und
   Leuchten. Masse, Schatten und Perspektive aus der Vorlage docs/ui/lia-zustaende.html. */
/* DAS LOGO GIBT PLATZ AB, WENN LIA VIEL SAGT (INT-Test 03.10.2026): Mit fester Größe schoben
   eine lange Frage und die Auswahlknöpfe darunter aus der Bühne hinaus — man musste scrollen,
   um „Nur Entwurf" überhaupt zu sehen. Jetzt schrumpft zuerst das Logo, bis 88 px; erst
   danach wird gescrollt. Die Höhe ist die Grundgröße, die Breite folgt dem Seitenverhältnis. */
.lia-logo {
    position: relative;
    flex: 0 1 min(300px, 38vh);
    min-height: 88px;
    max-width: 70%;
    display: grid;
    place-items: center;
    aspect-ratio: 1;
}

.lia-du {
    margin: 0;
    max-width: 46ch;
    color: var(--ink-muted);
    font-size: var(--t-sm);
    font-style: italic;
}

.lia-du:not(:empty)::before {
    content: "Du: ";
    font-style: normal;
}

.lia-du:empty {
    display: none;
}

.lia-untertitel {
    margin: 0;
    max-width: 46ch;
    font-size: 19px;
    line-height: 1.5;
    white-space: pre-wrap;
}

/* DER BÜHNENMODUS (itm-509): was LIA sagt und was man wählen kann, lesbar aus der letzten Reihe. */
.lia-buehne.gross .lia-untertitel {
    font-size: 28px;
}

.lia-buehne.gross .lia-optionen button,
.lia-buehne.gross .lia-eingabe textarea,
.lia-buehne.gross .lia-mitte {
    font-size: 18px;
}

.lia-untertitel.denkt {
    color: var(--ink-muted);
    animation: lia-denkt 1.2s ease-in-out infinite;
}

.lia-untertitel.fehler {
    color: var(--stop, #b42318);
}

.lia-untertitel .lia-verweis {
    margin: var(--s3) auto 0;
}

/* DER VERLAUF IM HINTERGRUND: eingeklappt, klein, gedämpft. */
.lia-verlauf {
    border-top: 1px solid var(--line-soft);
    font-size: var(--t-sm);
}

.lia-verlauf summary {
    padding: var(--s2) var(--s4);
    color: var(--ink-muted);
    cursor: pointer;
}

.lia-verlauf .lia-nachrichten {
    max-height: 30vh;
    opacity: .75;
}

.lia-verlauf .lia-nachricht {
    font-size: var(--t-sm);
    padding: var(--s2) var(--s3);
}

.lia-logo canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.lia-logo-rahmen {
    position: relative;
    width: 44%;
    aspect-ratio: 1;
    perspective: 700px;
}

.lia-logo img {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 22%;
    box-shadow: 0 0 calc(18px + var(--g, 0) * 60px) calc(var(--g, 0) * 14px) rgba(240, 130, 20, calc(.25 + var(--g, 0) * .55));
    transform: scale(var(--s, 1)) rotateY(var(--ry, 0deg));
    will-change: transform, box-shadow;
}

/* ----- DAS GESICHT (itm-661, lia-avatar.js) -----
   Steht das Gesicht von Anam, nimmt es den ganzen Platz des Logos ein — Logo, Vogel und Leuchten treten zurück. Die
   Kennzeichnung „KI-Avatar" liegt sichtbar auf dem Bild (AI Act: synthetische Gesichter als solche erkennbar). */
.lia-avatar[hidden] {
    display: none;
}

.lia-logo[data-avatar="an"] canvas,
.lia-logo[data-avatar="an"] [data-logo],
.lia-logo[data-avatar="an"] .lia-vogel {
    display: none;
}

.lia-logo[data-avatar="an"] .lia-logo-rahmen {
    width: 100%;
    perspective: none;
}

.lia-avatar {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 18px;
    overflow: hidden;
    background: #292d5b;
    box-shadow: 0 6px 24px rgba(0, 0, 0, .25);
}

.lia-avatar video {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* WARUM DAS GESICHT NICHT KOMMT (lia-avatar.js) — leise unter dem Logo, verschwindet nach 30 Sekunden. */
.lia-avatar-hinweis {
    margin: 8px auto 0;
    max-width: 320px;
    font-size: 12px;
    line-height: 1.4;
    text-align: center;
    opacity: .8;
}

.lia-avatar-hinweis:empty {
    display: none;
}

/* DAS STANDBILD (06.10.2026) an der Stelle des Logos: das Foto füllt den Platz, das Gesicht oben im Bild bleibt sichtbar. */
.lia-logo img.lia-standbild {
    object-fit: cover;
    object-position: center 20%;
    border-radius: 18px;
}

.lia-standbild-label {
    z-index: 1;
}

.lia-logo[data-avatar="an"] .lia-standbild-label {
    display: none;
}

.gs-standbild {
    display: block;
    width: 160px;
    aspect-ratio: 1;
    object-fit: cover;
    object-position: center 20%;
    border-radius: var(--r-md);
    margin-bottom: 8px;
}

.lia-avatar-label {
    position: absolute;
    left: 10px;
    bottom: 10px;
    padding: 2px 10px;
    border-radius: 999px;
    background: rgba(14, 16, 48, .72);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .02em;
}

/* ----- DER VOGEL (04.10.2026, lia-logo.js) -----
   Scalientos Rotkehlchen an der Stelle des Logos (`data-gestalt="vogel"`), gezeichnet in Teilen
   (brand/lia-vogel.svg). Zuerst steht es als <img> da; lia-logo.js setzt dieselbe Zeichnung als SVG in die
   Seite (`.gezeichnet`) und bewegt Kopf, Schnabel, Auge, Flügel, Schwanz und Beine einzeln. Der ganze Vogel
   (Hüpfen, Atmen, Hinbeugen) bewegt sich um die Füsse über die Variablen --v*; `will-change` hält ihn auf
   einer eigenen Ebene, damit Atmen und Hüpfen die Federn nicht neu zeichnen lassen. Kein Filter am Vogel:
   Der Schein liegt auf der Leinwand dahinter. Flügel und Schwanz dürfen beim Schlagen über den Rand. */
.lia-vogel { display: none; }

.lia-logo[data-gestalt="vogel"] [data-logo] { display: none; }

.lia-logo[data-gestalt="vogel"] .lia-logo-rahmen {
    width: 56%;
    perspective: none;
}

.lia-logo[data-gestalt="vogel"] .lia-vogel {
    display: block;
    position: relative;
    width: 100%;
    height: 100%;
    transform-origin: 50% 88%;
    transform: translate(var(--vx, 0%), var(--vy, 0%)) rotate(var(--vr, 0deg)) scale(var(--vsx, 1), var(--vsy, 1));
    will-change: transform;
}

.lia-logo .lia-vogel img {
    width: 100%;
    height: 100%;
    border-radius: 0;
    box-shadow: none;
    transform: none;
    object-fit: contain;
}

.lia-vogel.gezeichnet img { display: none; }

.lia-vogel svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
}

.lia-nachrichten {
    flex: 1;
    overflow-y: auto;
    list-style: none;
    margin: 0;
    padding: var(--s4);
    display: flex;
    flex-direction: column;
    gap: var(--s3);
}

.lia-nachricht {
    max-width: 85%;
    padding: var(--s3) var(--s4);
    border-radius: 14px;
    line-height: 1.45;
    white-space: pre-wrap;
    font-size: 15px;
}

.lia-nachricht.lia {
    align-self: flex-start;
    background: var(--surface-2);
    border-bottom-left-radius: 4px;
}

.lia-verweis {
    display: block;
    width: max-content;
    margin-top: var(--s2);
    padding: 4px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    font-size: var(--t-sm);
    font-weight: 600;
    text-decoration: none;
}

.lia-verweis::after {
    content: " →";
}

.lia-nachricht.nutzer {
    align-self: flex-end;
    background: var(--navy-soft, var(--ink));
    color: #fff;
    border-bottom-right-radius: 4px;
}

.lia-nachricht.denkt {
    animation: lia-denkt 1.2s ease-in-out infinite;
}

.lia-nachricht.fehler {
    background: var(--stop-soft);
}

@keyframes lia-denkt {
    50% { opacity: .4; }
}

.lia-optionen {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
    padding: 0 var(--s4);
}

.lia-optionen button {
    border-radius: 999px;
    border-color: var(--accent);
}

.lia-eingabe {
    display: flex;
    gap: var(--s2);
    padding: var(--s3) var(--s4);
    border-top: 1px solid var(--line-soft);
    margin: 0;
}

/* DIE GESPRÄCHSLEISTE (itm-654, Martin 05.10.2026; nachgezogen 06.10.2026: „das sollten wir schon sehr nah an dem
   umbauen. nur in unseren farben"). Wie die Vorlage aus Scaliento: eine dunkle Leiste, die IMMER steht — links ein runder
   Kreis mit dem Stand („LIA ist bereit", „Gespräch läuft" mit der Dauer), rechts runde Symbolknöpfe: Chat, Stumm, und
   der Anruf-Knopf, der im Gespräch zum roten Auflegen wird. Der Stand steht an der Leiste (`data-stand`, lia-stimme.js).

   UNSERE FARBEN: die Leiste in Lukmann-Navy, Anruf und aktive Knöpfe orange, Auflegen rot. Feste Werte statt Tokens,
   weil die Leiste in beiden Farbschemata dunkel bleibt — wie ein Telefon.

   EIN EIGENES ORANGE, NICHT DER AKZENT DER KONSOLE: Der gefüllte Akzent gehört in der Konsole allein dem nächsten Schritt
   (itm-205, AccentTests). Die Leiste ist LIAs Auftritt, und sie steht auch auf der Bühne, wo es keinen nächsten Schritt
   gibt. */
.lia-sprechen {
    --lia-orange: #F07A12;
    --lia-leiste: #292d5b;
    --lia-knopf: rgba(255, 255, 255, .14);
    --lia-knopf-hover: rgba(255, 255, 255, .24);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--s3);
    margin: 0 var(--s4) var(--s3);
}

.lia-anruf {
    background: var(--lia-leiste);
    color: #fff;
    border-radius: 16px;
    padding: 10px 12px;
}

.lia-anruf-status {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.lia-anruf-symbol {
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--lia-knopf);
    color: #fff;
}

/* IM GESPRÄCH leuchtet der Kreis — LIA hört zu. */
.lia-anruf[data-stand="an"] .lia-anruf-symbol {
    background: var(--lia-orange);
    color: #1a1206;
}

/* STUMM: Der Kreis verliert die Farbe — LIA hört gerade nicht zu. */
.lia-anruf:has(.lia-stumm[data-stumm="1"]) .lia-anruf-symbol {
    background: var(--lia-knopf);
    color: rgba(255, 255, 255, .55);
}

.lia-anruf-text strong {
    display: block;
    font-size: 16px;
    line-height: 1.2;
}

.lia-anruf-zeit {
    font-size: 13px;
    opacity: .75;
    font-variant-numeric: tabular-nums;
}

.lia-anruf-knoepfe {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
}

.lia-rund,
.lia-mikro {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    padding: 0;
    display: grid;
    place-items: center;
    border-color: transparent;
}

.lia-rund {
    background: var(--lia-knopf);
    color: #fff;
}

.lia-rund:hover {
    background: var(--lia-knopf-hover);
}

.lia-rund[hidden] {
    display: none;
}

.lia-stumm-strich {
    display: none;
}

.lia-anruf .lia-stumm[data-stumm="1"] {
    background: var(--lia-orange);
    color: #1a1206;
}

.lia-stumm[data-stumm="1"] .lia-stumm-strich {
    display: inline;
}

/* DER ANRUF-KNOPF: vor dem Gespräch orange mit Mikrofon, im Gespräch rot mit aufgelegtem Hörer. */
.lia-mikro {
    width: 48px;
    height: 48px;
    background: var(--lia-orange);
    color: #1a1206;
}

.lia-mikro-auflegen {
    display: none;
}

.lia-mikro[data-stand="verbinde"] {
    opacity: .7;
}

.lia-anruf[data-stand="an"] .lia-mikro {
    background: #d92d20;
    color: #fff;
}

.lia-anruf[data-stand="an"] .lia-mikro-an {
    display: none;
}

.lia-anruf[data-stand="an"] .lia-mikro-auflegen {
    display: block;
}

/* DER KNOPF TRÄGT NUR DAS SYMBOL; das Wort bleibt für Vorlesesoftware (aria-label), sichtbar sagt es der Satz links. */
.lia-mikro [data-text] {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.lia-anruf .help {
    flex-basis: 100%;
    color: #c9c9d6;
}

.lia-anruf .help:empty {
    display: none;
}

[data-stimme-hinweis][data-warn="1"] {
    color: var(--accent-ink);
}

/* LIA AUF DEM HANDY (itm-510): eine Spalte, die Seite scrollt als Ganzes statt der Karte
   in sich; die Heute-Leiste wird eine wischbare Reihe, Knöpfe sind daumengross, und der
   Sprechen-Knopf ist der grösste auf dem Schirm. */
@media (max-width: 760px) {
    .lia-heute {
        flex-wrap: nowrap;
        overflow-x: auto;
        gap: var(--s2);
        margin-bottom: var(--s3);
        scrollbar-width: none;
    }

    .lia-zahl {
        flex: none;
        font-size: 13px;
        padding: 6px 12px;
    }

    .lia-gespraech {
        height: auto;
        min-height: 0;
        overflow: visible;
    }

    .lia-gegenueber {
        padding: var(--s3);
        overflow: visible;
    }

    .lia-logo {
        width: min(220px, 62vw);
    }

    .lia-untertitel {
        font-size: 18px;
    }

    .lia-optionen button,
    .lia-eingabe button {
        min-height: 44px;
    }

}

/* DIE STIMMENWAHL unter Dienste (itm-521): je Stimme eine Zeile mit Hörprobe. */
.stimmenwahl .stimme {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) minmax(180px, 260px);
    align-items: center;
    gap: var(--s3);
    padding: var(--s2) 0;
    border-bottom: 1px solid var(--line-soft);
}

.stimmenwahl audio {
    width: 100%;
    height: 32px;
}

.lia-eingabe {
    align-items: center;
}

/* DIE EINGABE WIE IN DER VORLAGE (06.10.2026): eine Pille, daneben der runde Senden-Knopf in Navy. */
.lia-eingabe textarea {
    flex: 1;
    resize: none;
    font-size: 15px;
    min-height: 44px;
    border-radius: 22px;
    padding: 11px 18px;
    line-height: 1.4;
}

.lia-senden,
.lia-eingabe .lia-ablegen {
    flex: none;
    width: 44px;
    height: 44px;
    min-height: 44px;
    border-radius: 50%;
    padding: 0;
    display: grid;
    place-items: center;
}

.lia-senden {
    background: var(--brand);
    border-color: var(--brand);
    color: var(--on-brand);
}

.lia-mitte .chips {
    margin-bottom: var(--s3);
}

.lia-mitte-inhalt h3 {
    margin: 0 0 var(--s3);
}

.lia-liste {
    list-style: none;
    margin: 0;
    padding: 0;
}

.lia-liste li {
    padding: var(--s2) 0;
    border-bottom: 1px solid var(--line-soft);
}

.lia-liste li.erledigt {
    opacity: .55;
}

.lia-tag h4 {
    margin: var(--s3) 0 var(--s1);
    font-size: 14px;
}

.lia-produkt {
    padding: var(--s2) 0;
    border-bottom: 1px solid var(--line-soft);
}

.lia-staffeln {
    display: flex;
    gap: var(--s2);
    margin-top: var(--s1);
}

.lia-staffel {
    padding: 0 var(--s2);
    border-radius: 6px;
    background: var(--surface-2);
    font-size: var(--t-sm);
}

/* WAS LIA GERADE ANGEFASST HAT, LEUCHTET KURZ AUF. */
.lia-mitte-inhalt .neu {
    animation: live-neu 2.4s ease-out;
}

/* WAS LIA GELESEN HAT (itm-516): ein orangefarbener Rahmen, der langsam verblasst — gelesen
   ist nicht geändert, deshalb kein Aufblitzen der Fläche. Der geprüfte Tag und die gewählte
   Staffel bleiben markiert, bis die Ansicht neu lädt. */
.lia-mitte-inhalt .gelesen {
    border-radius: 6px;
    animation: lia-gelesen 3.2s ease-out;
}

.lia-mitte-inhalt .lia-tag.gelesen {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    animation: none;
}

.lia-staffel.gewaehlt {
    background: var(--accent-soft);
    box-shadow: inset 0 0 0 2px var(--accent);
    font-weight: 600;
}

@keyframes lia-gelesen {
    0%, 30% { box-shadow: 0 0 0 2px var(--accent); }
    100% { box-shadow: 0 0 0 2px transparent; }
}

/* DIE AKTIVITÄTSLEISTE (itm-493). */
.lia-aktivitaet h3 {
    margin: 0 0 var(--s1);
}

.lia-aktivitaet [data-zustand="verbunden"] {
    color: var(--ok);
}

.lia-zeitleiste {
    list-style: none;
    margin: var(--s3) 0 0;
    padding: 0;
}

.lia-ereignis {
    display: grid;
    grid-template-columns: 1.4em 1fr auto;
    gap: var(--s2);
    padding: var(--s2) 0;
    border-bottom: 1px solid var(--line-soft);
    font-size: var(--t-sm);
}

.lia-ereignis details {
    grid-column: 2 / 4;
    color: var(--ink-muted);
}

.lia-ereignis time {
    color: var(--ink-muted);
    font-variant-numeric: tabular-nums;
}

.lia-ereignis.rueckblick {
    opacity: .6;
}

.lia-ereignis.neu {
    animation: live-neu 1.6s ease-out;
}

.lia-ereignis.schritt-wartet {
    background: var(--accent-soft);
    border-radius: 6px;
    padding-left: var(--s2);
}

/* EINE ERINNERUNG (itm-519) weckt: hervorgehoben wie ein wartender Schritt, mit ihren Knöpfen. */
.lia-ereignis.erinnerung {
    background: var(--accent-soft);
    border-radius: 6px;
    padding-left: var(--s2);
    font-weight: 600;
}

.lia-erinnerung-knoepfe {
    grid-column: 2 / 4;
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
    font-weight: 400;
}

.lia-ereignis.schritt-fehlgeschlagen .zeichen {
    color: var(--danger, #B42318);
}

.lia-ereignis.schritt-fertig .zeichen,
.lia-ereignis.lauf-beendet .zeichen {
    color: var(--ok);
}

.lia-ereignis.schritt-begonnen .zeichen {
    animation: lia-denkt 1.2s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
    .lia-ereignis.neu,
    .lia-mitte-inhalt .neu,
    .lia-mitte-inhalt .gelesen,
    .lia-nachricht.denkt,
    .lia-ereignis.schritt-begonnen .zeichen {
        animation: none;
    }
}

/* ===== DER WORKFLOW-EDITOR (itm-492) =====

   DIE LEINWAND BEKOMMT DEN PLATZ (Martin, 03.10.2026: „die bausteine passen aber nicht so ganz in
   das fenster"). Die Seite nimmt die ganze Breite der Mitte statt der Lesebreite, Entwerfen und
   Probelauf sind zwei zugeklappte Zeilen, und die Fläche reicht bis an den unteren Rand. */
.pane.mid > div.wf-editor[data-insel] {
    max-width: none;
}

.wf-leiste {
    display: flex;
    align-items: center;
    gap: var(--s3);
    margin-bottom: var(--s2);
}

.wf-leiste input[data-name] {
    flex: 1;
    min-width: 0;
    font-size: var(--t-h2);
    font-weight: 600;
}

.wf-werkzeuge {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--s2);
    align-items: start;
    margin-bottom: var(--s2);
}

.wf-werkzeuge > details {
    border: 1px solid var(--line-soft);
    border-radius: 10px;
    background: var(--surface);
}

/* AUFGEKLAPPT ÜBER DIE GANZE BREITE — der Probelauf braucht zwei Spalten. */
.wf-werkzeuge > details[open] {
    grid-column: 1 / -1;
}

.wf-werkzeuge > details > summary {
    padding: 6px var(--s3);
    font-weight: 600;
    font-size: var(--t-ui);
    cursor: pointer;
}

.wf-werkzeuge > details[open] > summary {
    border-bottom: 1px solid var(--line-soft);
}

.wf-werkzeuge > details > .help {
    margin: var(--s2) var(--s3) 0;
}

/* BESCHREIBEN STATT ZEICHNEN (itm-513). */
.wf-beschreiben[open] {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: var(--s1) var(--s3);
    align-items: end;
    padding-bottom: var(--s3);
}

.wf-beschreiben > summary {
    grid-column: 1 / -1;
}

.wf-beschreiben label {
    grid-column: 1 / -1;
    margin: var(--s2) var(--s3) 0;
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

.wf-beschreiben textarea {
    margin-left: var(--s3);
    resize: vertical;
    min-height: 44px;
}

.wf-beschreiben [data-entwerfen] {
    margin-right: var(--s3);
}

.wf-beschreiben [data-bericht] {
    grid-column: 1 / -1;
    margin: 0 var(--s3);
    white-space: pre-wrap;
}

.wf-beschreiben [data-bericht]:empty {
    display: none;
}

/* DER PROBELAUF (itm-504): aufgeklappt Steuerung, Protokoll und der letzte Schritt nebeneinander —
   die Leinwand darunter leuchtet mit. */

.wf-ds-steuerung {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: var(--s2) var(--s3);
    padding: var(--s3);
}

.wf-ds-steuerung label {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

.wf-ds-steuerung label.check {
    flex-direction: row;
    align-items: center;
    gap: var(--s1);
    color: var(--ink);
}

.wf-ds-steuerung select {
    max-width: 420px;
}

.wf-ds-spalten {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--s4);
    padding: 0 var(--s3) var(--s3);
}

.wf-ds-spalten h3 {
    margin: 0 0 var(--s2);
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

.wf-ds-protokoll {
    max-height: 240px;
    overflow-y: auto;
    margin: 0;
    padding-left: var(--s5, 20px);
    font-size: var(--t-sm);
}

.wf-ds-protokoll li {
    margin-bottom: 2px;
}

.wf-ds-protokoll .wf-ds-fertig::marker { color: var(--ok); }
.wf-ds-protokoll .wf-ds-wartet { color: var(--warn); }
.wf-ds-protokoll .wf-ds-fehler { color: var(--danger); }
.wf-ds-protokoll .wf-ds-du { font-style: italic; }

.wf-ds-frage {
    margin-top: var(--s2);
    padding: var(--s2) var(--s3);
    border-left: 3px solid var(--accent);
    background: var(--accent-soft);
    border-radius: 6px;
}

.wf-ds-frage p {
    margin: 0 0 var(--s2);
}

.wf-ds-frage [data-ds-optionen] {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
}

.wf-ds-werte {
    display: grid;
    grid-template-columns: max-content minmax(0, 1fr);
    gap: 2px var(--s3);
    margin: 0 0 var(--s2);
    font-size: var(--t-sm);
}

.wf-ds-werte dt {
    color: var(--ink-muted);
}

.wf-ds-werte dd {
    margin: 0;
    overflow-wrap: anywhere;
    white-space: pre-wrap;
}

[data-ds-detail] h4 {
    margin: var(--s2) 0 var(--s1);
    font-size: var(--t-sm);
}

/* DIE KNOTEN LEUCHTEN MIT — dieselben Zustände wie auf der Bühne (itm-527): aktiv in der Akzentfarbe,
   erledigt grün, wartend orange mit Puls, gescheitert rot. */
.wf-leinwand .drawflow .drawflow-node.wf-ds-aktiv {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
}

.wf-leinwand .drawflow .drawflow-node.wf-ds-fertig {
    border-color: var(--ok);
    background: var(--ok-soft);
}

.wf-leinwand .drawflow .drawflow-node.wf-ds-wartet {
    border-color: var(--accent);
    background: var(--accent-soft);
    animation: wf-ds-puls 1.4s ease-in-out infinite;
}

.wf-leinwand .drawflow .drawflow-node.wf-ds-fehler {
    border-color: var(--danger);
    background: var(--danger-soft);
}

@keyframes wf-ds-puls {
    0%, 100% { box-shadow: 0 0 0 2px var(--accent-soft); }
    50% { box-shadow: 0 0 0 7px var(--accent-soft); }
}

@media (prefers-reduced-motion: reduce) {
    .wf-leinwand .drawflow .drawflow-node.wf-ds-wartet {
        animation: none;
    }
}

.wf-zustand {
    font-size: var(--t-sm);
    color: var(--ink-muted);
}

.wf-zustand[data-zustand="gut"] { color: var(--ok); }
.wf-zustand[data-zustand="warn"] { color: var(--accent-ink); }

/* DIE FLÄCHE REICHT BIS AN DEN UNTEREN RAND. Die Mitte gibt dafür ihren grossen Abstand unten her:
   Eine Leinwand, unter der noch eine halbe Bildschirmhöhe Leerraum zum Scrollen liegt, passt nicht
   ins Fenster, auch wenn sie es könnte. */
.pane.mid:has(> div.wf-editor[data-insel]) {
    padding-bottom: var(--s4);
}

.wf-flaeche {
    display: grid;
    grid-template-columns: 228px minmax(0, 1fr);
    gap: var(--s3);
    height: calc(100vh - var(--topbar) - 132px);
    min-height: 420px;
}

/* ===== DIE PALETTE: gruppiert, aufklappbar, durchsuchbar ===== */
.wf-palette {
    display: flex;
    flex-direction: column;
    min-height: 0;
    padding: var(--s2);
    background: var(--surface);
    border: 1px solid var(--line-soft);
    border-radius: 10px;
}

.wf-palette h3 {
    margin: 2px var(--s1) var(--s2);
    font-size: var(--t-h3);
}

.wf-palette input[data-suche] {
    width: 100%;
    margin-bottom: var(--s2);
}

.wf-palette-liste {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
}

.wf-gruppe + .wf-gruppe {
    margin-top: var(--s1);
}

.wf-gruppe > summary {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px var(--s1);
    border-radius: 6px;
    font-size: var(--t-xs);
    font-weight: 600;
    color: var(--ink-2);
    cursor: pointer;
    list-style: none;
}

.wf-gruppe > summary::-webkit-details-marker {
    display: none;
}

/* DER PFEIL ZUM AUFKLAPPEN, als Zeichen nach dem Namen — gedreht, wenn offen. */
.wf-gruppe > summary::before {
    content: "▸";
    width: 10px;
    color: var(--ink-3);
    transition: transform .12s ease;
}

.wf-gruppe[open] > summary::before {
    transform: rotate(90deg);
}

.wf-gruppe > summary:hover {
    background: var(--surface-2);
}

.wf-gruppe > summary .wf-anzahl {
    margin-left: auto;
    font-weight: 400;
    color: var(--ink-3);
}

.wf-gruppe-liste {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 2px 0 var(--s1);
}

.wf-baustein {
    display: flex;
    align-items: center;
    gap: var(--s2);
    width: 100%;
    min-height: 30px;
    padding: 3px var(--s2) 3px 4px;
    border: 1px solid transparent;
    border-radius: 6px;
    background: transparent;
    color: var(--ink);
    font: inherit;
    font-size: var(--t-ui);
    font-weight: 400;
    text-align: left;
    cursor: grab;
}

/* `display: flex` OBEN SCHLÄGT `hidden` — ohne diese Zeile fände die Suche, zeigte aber alles. */
.wf-baustein[hidden],
.wf-gruppe[hidden] {
    display: none;
}

.wf-baustein:hover,
.wf-baustein:focus-visible {
    border-color: var(--line-soft);
    background: var(--surface-2);
}

.wf-baustein:active {
    cursor: grabbing;
}

.wf-baustein > span:not(.wf-zeichen):not(.wf-schreibt) {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* FESTE HÖHE (Befund 04.10.2026: „wenn ich am unteren rand bin, und die erklärung erscheint springt
   die liste"). Mit min-height wuchs das Feld mit dem Text, die Liste darüber wurde kürzer und rutschte
   unter der Maus weg — und der nächste Eintrag darunter brachte den nächsten Text. Sechs Zeilen, der
   Rest steht im Tooltip. */
.wf-palette-info {
    flex: 0 0 auto;
    height: calc(6 * 1.4em + var(--s2));
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 6;
    line-height: 1.4;
    margin: var(--s2) 0 0;
    padding: var(--s2) var(--s1) 0;
    border-top: 1px solid var(--line-soft);
}

/* ===== DIE SYMBOLE (`Bausteinbild`) — dieselben in Palette, Knoten und Eigenschaften ===== */
.wf-zeichen {
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: var(--surface-3);
    color: var(--brand);
}

.wf-zeichen svg {
    width: 16px;
    height: 16px;
}

.wf-zeichen-gruppe {
    width: 18px;
    height: 18px;
    background: transparent;
    color: var(--ink-2);
}

.wf-zeichen-gruppe svg {
    width: 14px;
    height: 14px;
}

.wf-zeichen-gross {
    width: 32px;
    height: 32px;
    border-radius: 8px;
}

.wf-zeichen-gross svg {
    width: 20px;
    height: 20px;
}

/* KI-SCHRITTE IN DER FARBE DES MASCHINELLEN — dieselbe wie ein Entwurf, der noch nicht bestätigt
   ist. Der Rest bleibt in der Hausfarbe; Orange gehört dem, was etwas verändert (unten). */
.wf-gruppe-auswerten .wf-zeichen,
.wf-zeichen-gross.wf-gruppe-auswerten {
    background: var(--draft-soft);
    color: var(--draft);
}

.wf-knoten.wf-start .wf-zeichen {
    background: var(--ok-soft);
    color: var(--ok);
}

/* WAS EINTRÄGT ODER VERSCHICKT, trägt einen orangen Punkt — in der Palette und am Knoten. Als
   Zustand (`--warn`), nicht als Akzent: Die gefüllte Akzentfläche gehört dem nächsten Schritt
   (itm-205). */
.wf-schreibt {
    flex: 0 0 auto;
    width: 8px;
    height: 8px;
    border-radius: var(--r-full);
    background: var(--warn);
}

/* ===== DIE LEINWAND ===== */
.wf-buehne {
    position: relative;
    min-width: 0;
    min-height: 0;
}

.wf-leinwand {
    position: absolute;
    inset: 0;
    border: 1px solid var(--line-soft);
    border-radius: 10px;
    background-color: var(--surface);
    background-image: radial-gradient(var(--line-soft) 1px, transparent 1px);
    background-size: 20px 20px;
    overflow: hidden;
}

/* KOMPAKT: Symbol und Name, eine Zeile. Breite und Mindesthöhe rechnet die Anordnung in
   `workflow-editor.js` mit (KNOTEN_B, KNOTEN_H) — wer sie ändert, ändert beide. */
.wf-leinwand .drawflow .drawflow-node {
    width: 184px;
    min-height: 40px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow-xs);
    color: var(--ink);
}

.wf-leinwand .drawflow .drawflow-node:hover {
    border-color: var(--ink-3);
}

.wf-leinwand .drawflow .drawflow-node.selected {
    border-color: var(--accent);
    background: var(--surface);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.wf-leinwand .drawflow .drawflow-node.wf-fehler {
    border-color: var(--danger);
    box-shadow: 0 0 0 3px var(--stop-soft);
}

.wf-leinwand .drawflow .connection .main-path {
    stroke: var(--ink-3);
    stroke-width: 2px;
}

.wf-leinwand .drawflow .connection .main-path:hover,
.wf-leinwand .drawflow .connection .main-path.selected {
    stroke: var(--accent);
}

/* DIE KNICKPUNKTE der angeordneten Linien: unsichtbar, bis man über die Linie fährt — dann lassen sie
   sich ziehen. */
.wf-leinwand .drawflow .connection .point {
    fill: var(--surface);
    stroke: var(--ink-3);
    stroke-width: 1.5px;
    opacity: 0;
}

.wf-leinwand .drawflow .connection:hover .point,
.wf-leinwand .drawflow .connection .point.selected {
    opacity: 1;
}

/* DIE ANSCHLÜSSE SITZEN MITTIG AUF DEM RAND, links der Eingang, rechts die Ausgänge. */
.wf-leinwand .drawflow .drawflow-node .input,
.wf-leinwand .drawflow .drawflow-node .output {
    width: 12px;
    height: 12px;
    margin: 3px 0;
    border: 2px solid var(--ink-3);
    background: var(--surface);
}

.wf-leinwand .drawflow .drawflow-node .input {
    top: 0;
    left: -7px;
}

.wf-leinwand .drawflow .drawflow-node .output {
    top: 0;
    right: 7px;
}

.wf-leinwand .drawflow .drawflow-node .input:hover,
.wf-leinwand .drawflow .drawflow-node .output:hover {
    border-color: var(--accent);
}

.wf-knoten {
    display: flex;
    align-items: center;
    gap: var(--s2);
    min-height: 38px;
    padding: 6px var(--s3) 6px 7px;
    font-size: var(--t-ui);
    line-height: 1.2;
}

.wf-knoten-text {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
}

.wf-knoten-text b {
    overflow: hidden;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wf-knoten-text small {
    overflow: hidden;
    color: var(--ink-muted);
    font-size: var(--t-2xs);
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ===== ANSICHT: Zoom und Einpassen, unten rechts in der Leinwand ===== */
.wf-zoom {
    position: absolute;
    right: var(--s2);
    bottom: var(--s2);
    z-index: 3;
    display: flex;
    gap: 2px;
    padding: 2px;
    border: 1px solid var(--line-soft);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow-xs);
}

.wf-zoom button {
    min-width: 28px;
}

/* ===== WAS DIE PRÜFUNG NENNT, unten links in der Leinwand ===== */
.wf-fehlt {
    position: absolute;
    left: var(--s2);
    bottom: var(--s2);
    z-index: 3;
    max-width: min(560px, calc(100% - 200px));
    max-height: 30%;
    overflow-y: auto;
    margin: 0;
    padding: var(--s2) var(--s3) var(--s2) var(--s6);
    border: 1px solid var(--stop-soft);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow-xs);
    color: var(--danger);
    font-size: var(--t-sm);
}

/* ===== DIE EIGENSCHAFTEN: über der Leinwand, rechts, nur wenn ein Knoten gewählt ist ===== */
.wf-eigenschaften {
    position: absolute;
    top: var(--s2);
    right: var(--s2);
    bottom: var(--s2);
    z-index: 4;
    width: min(320px, calc(100% - 2 * var(--s2)));
    overflow-y: auto;
    padding: var(--s3);
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface);
    box-shadow: var(--shadow-md);
}

.wf-eigenschaften[hidden] {
    display: none;
}

.wf-eig-zu {
    position: absolute;
    top: var(--s2);
    right: var(--s2);
}

.wf-eig-kopf {
    display: flex;
    align-items: center;
    gap: var(--s2);
    margin: 0 var(--s6) var(--s2) 0;
}

.wf-eig-kopf h3 {
    margin: 0;
}

.wf-eig-kopf small {
    color: var(--ink-muted);
    font-size: var(--t-xs);
}

.wf-eig-was {
    margin: 0 0 var(--s2);
}

.wf-eig-dahinter {
    margin-bottom: var(--s3);
    font-size: var(--t-sm);
}

.wf-eig-dahinter > summary {
    color: var(--ink-2);
    cursor: pointer;
}

.wf-eig-dahinter > p {
    margin: var(--s1) 0 0;
}

.wf-ausgang {
    display: grid;
    grid-template-columns: 1.6em 1fr;
    gap: var(--s2);
    margin-bottom: var(--s2);
}

.wf-ausgang > button {
    grid-column: 2;
    justify-self: start;
}

.wf-ausgang-nr {
    display: grid;
    place-items: center;
    width: 1.4em;
    height: 1.4em;
    border-radius: 50%;
    background: var(--surface-2);
    font-size: var(--t-sm);
}

.wf-bedingung {
    display: flex;
    flex-direction: column;
    gap: var(--s1);
}

/* AUF EINEM SCHMALEN SCHIRM steht die Palette über der Leinwand. */
@media (max-width: 900px) {
    .wf-werkzeuge {
        grid-template-columns: minmax(0, 1fr);
    }

    .wf-flaeche {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: 200px minmax(360px, 1fr);
        height: auto;
    }
}

/* ===== DIE EINSTELLUNGEN VON LIA (03.10.2026) =====
   Martin: „die lia config seiten … gehören wirklich wesentlich besser gestaltet. es darf ruhig
   verspielt sein von den schaltflächen und werkzeugen. nutze grafiken, stellschrauben, regler usw…
   nicht immer alles in einer wurst runter."

   EIN WORTSCHATZ FÜR ALLE FÜNF SEITEN (Persönlichkeit, Demo-Stand, Verbindungen, Stimme, Postfach),
   Vorsilbe `es-`: ein Kopf mit Bild, Karten nebeneinander statt untereinander, Schalter statt
   Kästchen, Regler mit Anzeige statt Zahlenfeld, Kacheln statt Optionsknöpfen.

   ALLES BLEIBT EIN GEWÖHNLICHES FORMULARELEMENT. Der Schalter ist ein Kontrollkästchen, die Kachel
   ein Optionsknopf, der Regler ein `range` mit Namen — ohne Skript schickt jedes Formular dasselbe
   ab wie vorher. `einstellungen.js` ergänzt nur die Anzeige: die Zahl am Regler, die Füllung der
   Schiene, die Vorschau im Kopf. Was es per Stil setzt (`--fill`, `--wert`), hat hier einen
   Rückfallwert, damit die Seite ohne Skript nicht anders aussieht als mit. */

/* -- Der Kopf: Bild, Titel, ein Satz, rechts der Stand -- */
.es-kopf {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: var(--s4) var(--s6);
    margin: 0 0 var(--s6);
    padding: var(--s6);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background:
        radial-gradient(circle at 92% 10%, var(--accent-soft), transparent 42%),
        linear-gradient(135deg, var(--surface) 30%, var(--surface-2));
    box-shadow: var(--shadow-xs);
}

.es-kopf h1 { margin: 0 0 var(--s1); }
.es-kopf .lead { margin: 0; max-width: 72ch; }

.es-bild {
    width: 76px;
    height: 76px;
    flex: none;
}

.es-bild svg { width: 100%; height: 100%; display: block; }

/* Die Grafiken zeichnen mit den Token der Palette und folgen damit dem Dunkelmodus. */
.es-strich { fill: none; stroke: var(--brand); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.es-flaeche { fill: var(--surface-3); }
.es-akzent { fill: var(--accent); }
.es-akzent-strich { fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-linecap: round; }
.es-gut { fill: var(--ok); }

.es-stand {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: var(--s2);
}

/* -- Das Raster: Karten nebeneinander, auf dem Telefon untereinander -- */
.es-raster {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
    gap: var(--s4);
    align-items: start;
    margin-bottom: var(--s4);
}

.es-raster > .card { margin: 0; min-width: 0; }
.es-raster > .es-weit { grid-column: 1 / -1; }

/* Server und Port in einer Zeile: der Port braucht fünf Ziffern, nicht die halbe Karte. */
.es-paar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 7.5rem;
    gap: var(--s3);
}

.es-abstand { margin-top: var(--s3); }
.es-einleitung { margin: 0 0 var(--s4); }

/* Mehrere kleine Formulare mit je einem Knopf in einer Reihe (Verbindung testen, schalten, löschen). */
.es-knopfreihe {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
    margin-bottom: var(--s4);
}

.es-knopfreihe > form { margin: 0; }

.card.es-verbindung { margin-bottom: var(--s4); }
.card.es-verbindung h3 { display: flex; align-items: center; gap: var(--s2); }

@media (min-width: 1100px) {
    .es-raster.es-zwei { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
    .es-raster.es-drei-zwei { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); }
}

/* -- Der Kopf einer Karte: ein Symbol in einer Kachel, die Überschrift, ein Satz -- */
.es-karte-kopf {
    display: flex;
    align-items: flex-start;
    gap: var(--s3);
    margin-bottom: var(--s4);
}

.es-karte-kopf h2,
.es-karte-kopf h3 { margin: 0; }
.es-karte-kopf .help { margin-top: 2px; }

.es-symbol {
    flex: none;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: var(--r-md);
    background: var(--surface-2);
    border: 1px solid var(--line-soft);
}

.es-symbol svg { width: 22px; height: 22px; }

/* -- Der Schalter: ein Kontrollkästchen, das wie ein Kippschalter aussieht -- */
.es-schalter {
    display: flex;
    align-items: flex-start;
    gap: var(--s3);
    margin: 0 0 var(--s4);
    padding: var(--s3);
    border: 1px solid var(--line-soft);
    border-radius: var(--r-md);
    background: var(--surface-2);
    cursor: pointer;
    font-weight: 400;
    color: var(--ink);
}

.es-schalter:has(> input:checked) { border-color: var(--brand); }

.es-schalter > input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    position: relative;
    flex: none;
    width: 44px;
    height: 24px;
    margin: 0;
    border: 1px solid var(--border-strong);
    border-radius: var(--r-full);
    background: var(--surface-3);
    cursor: pointer;
    transition: background-color .18s var(--ease), border-color .18s var(--ease);
}

.es-schalter > input[type="checkbox"]::before {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--ink-2);
    transition: transform .2s var(--ease), background-color .18s var(--ease);
}

.es-schalter > input[type="checkbox"]:checked {
    background: var(--brand);
    border-color: var(--brand);
}

.es-schalter > input[type="checkbox"]:checked::before {
    transform: translateX(20px);
    background: var(--on-brand);
}

.es-schalter-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.es-schalter-text b { font-weight: 600; }
.es-schalter-text .help { display: block; margin: 0; }

.es-schalter .es-schalter-symbol { flex: none; width: 22px; height: 22px; margin-left: auto; opacity: .55; }
.es-schalter:has(> input:checked) .es-schalter-symbol { opacity: 1; }

/* Ein kleiner Schalter in einer Liste — ohne Kasten. */
.es-schalter.es-klein {
    padding: 0;
    border: 0;
    background: none;
    margin: 0;
    align-items: center;
    font-size: var(--t-sm);
}

/* -- Der Regler: Schiene mit Füllung, großer Griff, die Zahl daneben -- */
.es-regler { margin-bottom: var(--s4); }

.es-regler-zeile {
    display: flex;
    align-items: center;
    gap: var(--s3);
}

.es-regler-zeile > input { flex: 1 1 auto; min-width: 0; }
.es-regler-zeile > :not(input) { flex: none; }

.es-regler-zeile .es-ende {
    font-size: var(--t-xs);
    line-height: var(--lh-xs);
    color: var(--ink-2);
    display: inline-flex;
    align-items: center;
    gap: var(--s1);
    white-space: nowrap;
}

.es-regler-zeile .es-ende svg { width: 18px; height: 18px; }

.es-wert {
    min-width: 7.5em;
    padding: 2px var(--s2);
    border-radius: var(--r-full);
    background: var(--surface-2);
    border: 1px solid var(--line-soft);
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    font-weight: 600;
    text-align: center;
    font-variant-numeric: tabular-nums;
    color: var(--ink);
}

/* DIE ALLGEMEINE FELDREGEL (Rahmen, Fläche, Höhe, 680px) trifft auch ein `range` und wiegt mit ihren
   vier `:not()` mehr als jede Klasse hier — deshalb die wenigen `!important`, und nur für diese. */
input[type="range"].es-schiene {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    max-width: none !important;
    height: 28px !important;
    padding: 0 !important;
    margin: 0;
    border: 0 !important;
    background: transparent !important;
    cursor: pointer;
}

input[type="range"].es-schiene::-webkit-slider-runnable-track {
    height: 8px;
    border-radius: var(--r-full);
    background: linear-gradient(to right, var(--brand) var(--fill, 50%), var(--surface-3) var(--fill, 50%));
    border: 1px solid var(--line);
}

input[type="range"].es-schiene::-moz-range-track {
    height: 8px;
    border-radius: var(--r-full);
    background: var(--surface-3);
    border: 1px solid var(--line);
}

input[type="range"].es-schiene::-moz-range-progress {
    height: 8px;
    border-radius: var(--r-full);
    background: var(--brand);
}

input[type="range"].es-schiene::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    margin-top: -8px;
    border-radius: 50%;
    background: var(--surface);
    border: 3px solid var(--brand);
    box-shadow: var(--shadow-xs);
    transition: transform .15s var(--ease);
}

input[type="range"].es-schiene::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--surface);
    border: 3px solid var(--brand);
}

input[type="range"].es-schiene:hover::-webkit-slider-thumb { transform: scale(1.12); }

input[type="range"].es-schiene:focus-visible { box-shadow: none; }
input[type="range"].es-schiene:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--navy); }
input[type="range"].es-schiene:focus-visible::-moz-range-thumb { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--navy); }

/* Ein Regler mit einer Zahl daneben, die man auch tippen kann, braucht kein zweites Feld: Die
   Zahl kommt vom Regler. Wo es keine sinnvolle Spanne gibt (Ports), bleibt das Zahlenfeld. */

/* -- Die Wahl in wenigen Stufen: ein Segment aus Optionsknöpfen -- */
.es-segment {
    border: 0;
    padding: 0;
    margin: 0 0 var(--s4);
    min-width: 0;
}

.es-segment > legend,
.es-kacheln > legend {
    padding: 0;
    margin-bottom: var(--s1);
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    font-weight: 600;
    color: var(--ink-muted);
}

.es-segment-reihe {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 2px;
    padding: 3px;
    border-radius: var(--r-md);
    background: var(--surface-2);
    border: 1px solid var(--line);
    max-width: 100%;
}

.es-segment-reihe > label {
    position: relative;
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: var(--s1);
    padding: 5px var(--s3);
    border-radius: var(--r-sm);
    font-size: var(--t-ui);
    font-weight: 500;
    color: var(--ink-2);
    cursor: pointer;
}

.es-segment-reihe > label > input,
.es-kachel > input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    pointer-events: none;
}

.es-segment-reihe > label:hover { color: var(--ink); }

.es-segment-reihe > label:has(> input:checked) {
    background: var(--surface);
    color: var(--ink);
    font-weight: 600;
    box-shadow: var(--shadow-xs);
}

.es-segment-reihe > label:has(> input:focus-visible),
.es-kachel:has(> input:focus-visible) {
    box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--navy);
}

/* -- Kacheln: eine Wahl, die man sieht — Avatar, Versandweg, Stimme -- */
.es-kacheln {
    border: 0;
    padding: 0;
    margin: 0 0 var(--s4);
    min-width: 0;
}

.es-kachel-reihe {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 130px), 1fr));
    gap: var(--s3);
}

.es-kachel-reihe.es-breit { grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); }

/* VIELE STIMMEN laufen in einem eigenen Fenster, damit die Karte daneben nicht drei Bildschirme hoch wird. */
.es-kachel-reihe.es-rollen {
    max-height: 27rem;
    overflow-y: auto;
    padding: 3px;
    margin: -3px;
    overscroll-behavior: contain;
}

.es-kachel {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: var(--s2);
    margin: 0;
    padding: var(--s3);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface);
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
    font-weight: 400;
    color: var(--ink-2);
    cursor: pointer;
    transition: border-color .18s var(--ease), transform .18s var(--ease), box-shadow .18s var(--ease);
}

.es-kachel b { color: var(--ink); font-size: var(--t-ui); }
.es-kachel:hover { border-color: var(--border-strong); transform: translateY(-1px); }

.es-kachel:has(> input:checked) {
    border-color: var(--brand);
    box-shadow: inset 0 0 0 1px var(--brand), var(--shadow-xs);
    background: var(--surface-2);
}

/* Das Häkchen der gewählten Kachel. */
.es-kachel:has(> input:checked)::after {
    content: "✓";
    position: absolute;
    top: 8px;
    right: 8px;
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--brand);
    color: var(--on-brand);
    font-size: var(--t-2xs);
    font-weight: 700;
}

.es-vorschau-bild {
    display: grid;
    place-items: center;
    height: 92px;
    border-radius: var(--r-sm);
    background: var(--surface-2);
    overflow: hidden;
}

.es-vorschau-bild img { max-height: 72px; max-width: 72px; border-radius: var(--r-md); object-fit: cover; }
.es-vorschau-bild svg { height: 72px; width: 72px; }

/* DAS LOGO ATMET wie auf LIAs Seite — als Vorschau, nicht als Zustandsanzeige. */
@keyframes es-atmen {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.07); }
}

.es-atmet { animation: es-atmen 3.2s var(--ease) infinite; }

/* -- Die Leiste mit dem einen Speichern, am unteren Rand mitlaufend -- */
.es-leiste {
    position: sticky;
    bottom: 0;
    z-index: 5;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: var(--s3);
    margin: var(--s4) 0;
    padding: var(--s3) var(--s4);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.es-leiste .help { margin: 0 auto 0 0; }

/* -- LIAs Auftritt im Kopf der Persönlichkeit: Gesicht und Sprechblase -- */
.es-auftritt {
    display: flex;
    align-items: center;
    gap: var(--s4);
    min-width: 0;
}

.es-gesicht {
    flex: none;
    display: grid;
    place-items: center;
    width: 84px;
    height: 84px;
    border-radius: 24px;
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.es-gesicht img { width: 64px; height: 64px; object-fit: cover; border-radius: var(--r-md); }
.es-gesicht svg { width: 72px; height: 72px; }

/* Welches Gesicht zu sehen ist, sagt der Kopf (`data-avatar`); das Skript stellt es beim Wählen um. */
.es-gesicht > [data-zeige] { display: none; }
.es-gesicht[data-avatar="Logo"] > [data-zeige="Logo"],
.es-gesicht[data-avatar="Bild"] > [data-zeige="Bild"],
.es-gesicht[data-avatar="Figur"] > [data-zeige="Figur"],
.es-gesicht[data-avatar="Vogel"] > [data-zeige="Vogel"],
.es-gesicht[data-avatar="Gesicht"] > [data-zeige="Gesicht"] { display: block; }

/* DER VOGEL IN DER VORSCHAU: freigestellt, also ohne Ecken und ohne Beschnitt — und er wippt. */
.es-gesicht img.es-vogel,
.es-vorschau-bild img.es-vogel { object-fit: contain; border-radius: 0; animation: es-vogel 2.8s ease-in-out infinite; transform-origin: 50% 95%; }

@keyframes es-vogel {
    0%, 60%, 100% { transform: none; }
    70% { transform: rotate(-7deg); }
    80% { transform: rotate(4deg) translateY(-3%); }
    90% { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    .es-gesicht img.es-vogel,
    .es-vorschau-bild img.es-vogel { animation: none; }
}

.es-blase {
    position: relative;
    min-width: 0;
    padding: var(--s3) var(--s4);
    border-radius: var(--r-lg) var(--r-lg) var(--r-lg) 4px;
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-xs);
}

.es-blase b { display: block; font-size: var(--t-xs); color: var(--ink-2); font-weight: 600; }
.es-blase p { margin: 2px 0 0; overflow-wrap: anywhere; }
.es-blase + .es-schalter { margin-top: var(--s4); }

/* Drei kleine Säulen: Ton, Humor, Länge auf einen Blick — sie folgen den Reglern. */
.es-saeulen {
    display: flex;
    align-items: flex-end;
    gap: var(--s2);
    height: 72px;
}

.es-saeule {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    gap: 3px;
    height: 100%;
    font-size: var(--t-2xs);
    line-height: var(--lh-2xs);
    color: var(--ink-2);
}

.es-saeule i {
    display: block;
    width: 14px;
    height: calc(var(--wert, 50) * 0.5px + 6px);
    border-radius: 4px 4px 2px 2px;
    background: var(--brand);
    transition: height .2s var(--ease);
}

.es-saeule:nth-child(2) i { background: var(--draft); }

/* -- Das Mischpult der Persönlichkeit: Regler mit Symbol an beiden Enden -- */
.es-pult {
    display: grid;
    gap: var(--s2);
    padding: var(--s4);
    margin-bottom: var(--s4);
    border-radius: var(--r-md);
    background: var(--surface-2);
    border: 1px solid var(--line-soft);
}

.es-pult .es-regler { margin: 0; }
.es-pult .es-regler + .es-regler { padding-top: var(--s2); border-top: 1px dashed var(--line); }

/* -- Der Chat der Vorschau -- */
.es-chat {
    display: flex;
    flex-direction: column;
    gap: var(--s2);
    margin: var(--s3) 0;
}

.es-chat .es-frage,
.es-chat .es-antwort {
    max-width: 85%;
    padding: var(--s2) var(--s3);
    border-radius: var(--r-lg);
    overflow-wrap: anywhere;
}

.es-chat .es-frage { align-self: flex-end; background: var(--brand); color: var(--on-brand); border-bottom-right-radius: 4px; }
.es-chat .es-antwort { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--line-soft); border-bottom-left-radius: 4px; }
.es-chat p { margin: 0 0 var(--s1); }
.es-chat p:last-child { margin: 0; }

.es-frage-zeile {
    display: flex;
    gap: var(--s2);
    align-items: center;
}

.es-frage-zeile input { flex: 1 1 auto; min-width: 0; max-width: none !important; }
.es-frage-zeile button { flex: none; white-space: nowrap; }

/* -- Der Verlauf als Zeitleiste -- */
.es-zeitleiste {
    list-style: none;
    margin: 0;
    padding: 0;
}

.es-zeitleiste > li {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: var(--s1) var(--s3);
    padding: var(--s2) 0 var(--s2) var(--s6);
    border-left: 2px solid var(--line);
    margin-left: var(--s2);
}

.es-zeitleiste > li::before {
    content: "";
    position: absolute;
    left: -7px;
    top: 14px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--surface);
    border: 2px solid var(--border-strong);
}

.es-zeitleiste > li.es-gilt::before { background: var(--ok); border-color: var(--ok); }
.es-zeitleiste .es-mini { display: flex; gap: var(--s2); flex-wrap: wrap; }
.es-zeitleiste form { margin: 0; }

.es-marke {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 1px var(--s2);
    border-radius: var(--r-full);
    background: var(--surface-2);
    border: 1px solid var(--line-soft);
    font-size: var(--t-xs);
    line-height: var(--lh-xs);
    color: var(--ink-2);
    white-space: nowrap;
}

.es-marke i {
    display: inline-block;
    width: 28px;
    height: 5px;
    border-radius: 3px;
    background: linear-gradient(to right, var(--brand) calc(var(--wert, 50) * 1%), var(--surface-3) calc(var(--wert, 50) * 1%));
}

/* -- Zeilen mit Schalter: Wissensbots, Werkzeuge einer Verbindung -- */
.es-zeilen {
    display: grid;
    gap: var(--s2);
    margin: 0 0 var(--s4);
    padding: 0;
    list-style: none;
}

.es-zeile {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) minmax(0, 1.2fr);
    align-items: center;
    gap: var(--s2) var(--s4);
    padding: var(--s3);
    border: 1px solid var(--line-soft);
    border-radius: var(--r-md);
    background: var(--surface);
}

.es-zeile:has(input[type="checkbox"]:checked) { border-color: var(--line); background: var(--surface-2); }
.es-zeile input:not([type="checkbox"]) { max-width: none; }
.es-zeile .es-name { min-width: 0; overflow-wrap: anywhere; }
.es-zeile .es-name .help { margin: 0; }
.es-zeile details { margin-top: var(--s1); }
.es-zeile pre { white-space: pre-wrap; overflow-wrap: anywhere; margin: var(--s1) 0 0; }

.es-zeile.es-werkzeug { grid-template-columns: minmax(0, 1fr) auto auto; }

@media (max-width: 720px) {
    .es-zeile,
    .es-zeile.es-werkzeug { grid-template-columns: minmax(0, 1fr); }
}

/* -- Große Handlungen als Kacheln: Demo-Stand -- */
.es-aktion {
    display: flex;
    flex-direction: column;
    gap: var(--s3);
    height: 100%;
}

.es-aktion > p { margin: 0; }
.es-aktion > .es-karte-kopf { margin-bottom: 0; }
.es-aktion .es-knopf { align-self: flex-start; }
.es-aktion form,
.es-aktion .es-knopf { margin-top: auto; }
.es-aktion form { display: flex; gap: var(--s2); flex-wrap: wrap; }

.es-schritte {
    counter-reset: es-schritt;
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr));
    gap: var(--s3);
}

.es-schritte > li {
    counter-increment: es-schritt;
    position: relative;
    padding: var(--s3) var(--s3) var(--s3) 46px;
    border-radius: var(--r-md);
    background: var(--surface-2);
    border: 1px solid var(--line-soft);
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
}

.es-schritte > li::before {
    content: counter(es-schritt);
    position: absolute;
    left: var(--s3);
    top: var(--s3);
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--brand);
    color: var(--on-brand);
    font-size: var(--t-xs);
    font-weight: 700;
}

/* DIE WEICHE PRÜFEN (itm-587): die Sätze in voller Breite. */
.es-weiche-eingabe {
    width: 100%;
    font-family: inherit;
    margin-bottom: var(--s2);
}

/* BEREIT FÜR DIE SHOW? (itm-591): je Zeile Ampel, was, der Stand in einem Satz, der Weg zum Ändern. */
.es-bereit {
    list-style: none;
    margin: var(--s2) 0;
    padding: 0;
    display: grid;
    gap: var(--s2);
}

.es-bereit > li {
    display: grid;
    grid-template-columns: 5.5rem 9rem minmax(0, 1fr) auto;
    gap: var(--s2);
    align-items: baseline;
}

.es-bereit > li > .zustand {
    justify-self: start;
}

@media (max-width: 720px) {
    .es-bereit > li {
        grid-template-columns: 5.5rem minmax(0, 1fr);
    }

    .es-bereit > li > span:not(.zustand),
    .es-bereit > li > a {
        grid-column: 2;
    }
}

.es-haken {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: var(--s2);
}

.es-haken > li {
    position: relative;
    padding-left: 28px;
}

.es-haken > li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 5px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--brand);
    box-shadow: 0 0 0 4px var(--surface-3);
}

.es-saetze {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: var(--s2);
}

.es-saetze > li {
    padding: var(--s2) var(--s3);
    border-radius: var(--r-lg) var(--r-lg) var(--r-lg) 4px;
    background: var(--surface-2);
    border: 1px solid var(--line-soft);
    font-size: var(--t-sm);
    line-height: var(--lh-sm);
}

.es-saetze > li q { font-weight: 600; color: var(--ink); }

/* -- Stand-Kacheln: eingerichtet oder nicht, mit dem Weg dorthin -- */
.es-lage {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    gap: var(--s3);
}

.es-lage > a {
    display: flex;
    align-items: center;
    gap: var(--s3);
    padding: var(--s3);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: var(--surface-2);
    text-decoration: none;
    color: var(--ink);
}

.es-lage > a:hover { border-color: var(--border-strong); }
.es-lage .es-symbol { background: var(--surface); }
.es-lage b { display: block; }

/* Der Knopf zum Vorhören einer Stimme. */
.es-hoeren {
    display: inline-flex;
    align-items: center;
    gap: var(--s1);
    align-self: flex-start;
}

.es-hoeren svg { width: 14px; height: 14px; fill: currentColor; }
.es-hoeren[aria-pressed="true"] { background: var(--brand); color: var(--on-brand); }

@media (max-width: 720px) {
    .es-kopf {
        grid-template-columns: minmax(0, 1fr);
        padding: var(--s4);
    }

    .es-stand { align-items: flex-start; }
    .es-bild { width: 56px; height: 56px; }
    .es-auftritt { flex-wrap: wrap; }
    .es-leiste { justify-content: stretch; }
    .es-leiste > button { flex: 1 1 auto; }
    .es-regler-zeile .es-ende { display: none; }
    .es-wert { min-width: 5.5em; }
}
.card .knoepfe { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 10px; }

/* ===== DAS TICKETSYSTEM (02.10.2026) =====
   Oben im Gespräch und im Überblick drei Körbe nebeneinander: wichtig, zu tun, später. */
.koerbe { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 8px; }
.koerbe h3 { font-size: var(--t-sm); text-transform: uppercase; letter-spacing: .04em; color: var(--ink-2); margin: 0 0 4px; }
.koerbe ul { margin: 0; padding-left: 18px; }
.koerbe li { margin-bottom: 2px; }
.ueberblick { border-left: 3px solid var(--brand); background: var(--surface-2); padding: 10px 14px; margin: 10px 0 14px; }
.fadenkopf .kopfzeile { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.fadenkopf h2 { margin: 0; }
.postfach-kopf .knoepfe { display: flex; gap: 8px; }
form.filter { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 8px 0 12px; }
form.filter label { font-size: var(--t-sm); color: var(--ink-2); }
form.umschreiben { display: flex; align-items: flex-end; gap: 10px; margin-top: 14px; border-top: 1px solid var(--line-soft); padding-top: 12px; }
form.umschreiben .field { flex: 1 1 auto; margin: 0; }
@media (max-width: 720px) { .koerbe { grid-template-columns: 1fr; } form.umschreiben { flex-direction: column; align-items: stretch; } }

/* ===== DIE BÜHNE (itm-527) =====
   Für den Beamer: dunkel, gross, ohne Rahmen der Konsole. Links LIA, rechts ein bewegtes Bild dessen,
   was sie gerade tut, darunter in grosser Schrift die Tätigkeit und klein die Kette des Workflows.
   Eigene Farben, weil die Bühne immer dunkel ist — auch wenn die Konsole hell eingestellt ist.

   NICHTS LIEGT ÜBER ETWAS ANDEREM (Martin, 03.10.2026: „das darf nie passieren“). Die Regeln dazu:
   - Jede Fläche ist eine eigene Zeile eines Rasters oder einer Flexbox; nichts ist absolut über
     einer anderen Fläche positioniert. Die einzige Ausnahme sind die Szenen rechts, die beim
     Wechsel übereinander blenden — innerhalb ihres eigenen Kastens, in dem kein Text steht.
   - Die Figur links bekommt den Platz, der übrig bleibt (`flex: 1 1 0`), nie weniger als ihr
     Minimum, und ist immer quadratisch so gross, wie dieser Platz hergibt (Container-Einheiten).
   - Was zu lang werden kann — der Untertitel, die Auswahlknöpfe, der Verlauf, die Kette — rollt
     in seiner eigenen Zeile oder wird gekürzt, statt in die nächste zu ragen.
   - Die Seite selbst rollt nicht (`html, body { overflow: clip }` ab 901 px). Wird das Fenster
     zu niedrig, rollt deshalb die Bühne als Ganzes, statt unten abgeschnitten zu werden. */
/* DAS NAVY VON SCALIENTO (Martin 06.10.2026, LIA im Rahmen von Scaliento: „die lia farben … und die vom scaliento header,
   das sollte sich matchen"): Der Grund ist die Farbe der Scaliento-Kopfzeile (#292D5B), Flächen und Linien sind hellere
   Stufen davon. Bis dahin stand die Bühne in einem fast schwarzen Blau und wirkte unter der Kopfzeile wie ein Fremdkörper.
   Das Orange bleibt der Akzent. */
/* HELL STATT NAVY (itm-722, Entwurf „Arbeit 2030 im Scaliento-Rahmen“, 07.10.2026): Am Beamer war die dunkle Fläche schwer zu
   lesen. Jetzt bleibt nur die Leiste oben im Navy von Scaliento, darunter ist es hell (#F2F2F5, Karten weiß). Zwei Farben, zwei
   Rollen: Navy gehört dem System und dem Menschen — Struktur, Titel, Entscheidungen —, Orange gehört nur LIA. Grauer Text auf
   Weiß ist nie heller als #5A5F7A, orange Schrift steht im dunkleren `--b-glut-text`. Die Namen der Token bleiben, damit jede
   Regel der Bühne sie weiter findet; `--b-grund` ist jetzt der helle Grund. */
.hub,
.buehne {
    --b-grund: #f2f2f5;
    --b-flaeche: #ffffff;
    --b-flaeche-2: #f6f6fa;
    --b-flaeche-3: #eceef5;
    --b-linie: #d9dae2;
    --b-linie-2: #c6c8d4;
    --b-text: #1f2240;
    --b-text-2: #3e4360;
    --b-leise: #5a5f7a;
    --b-navy: #292d5b;
    --b-navy-2: #30356b;
    --b-glut: #f08a1c;
    --b-glut-text: #b65a06;
    --b-glut-flaeche: #fef3e7;
    --b-glut-rand: #f7c99a;
    --b-orange: #f08a1c;
    --b-gut: #1f9a3a;
    --b-halt: #e0251b;
    --b-schatten: rgba(31, 34, 64, 0.42);
    --b-schrift: "Open Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
    /* NICHTS FÄLLT AUF INTER ZURÜCK (itm-733): Regeln der Konsole, die `--font-ui` nehmen, schreiben im Hub Open Sans wie Scaliento. */
    --font-ui: var(--b-schrift);
}

.buehne {
    --b-rand: clamp(14px, 1.8vw, 40px);
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    grid-template-rows: minmax(0, 1fr);
    gap: clamp(16px, 2.2vw, 44px);
    height: 100vh;
    height: 100dvh;
    padding: var(--b-rand);
    overflow-x: hidden;
    overflow-y: auto;
    background: var(--b-grund);
    color: var(--b-text);
    scrollbar-color: var(--b-linie) transparent;
}

/* SCHMAL ODER HOCHKANT: LIA oben, die Szene darunter; die Bühne rollt. ERST UNTER 860 PX (itm-733): Bei 1000 × 725 im Rahmen
   standen die Hälften übereinander, die Szene lag unter dem Rand, und es rollte — zwei Spalten haben dort Platz. */
@media (max-width: 860px), (max-aspect-ratio: 1/1) {
    .buehne {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: minmax(520px, 62dvh) minmax(min-content, 80dvh);
    }
}

/* EIN HOCHKANT-BILDSCHIRM, DER HOCH GENUG IST, teilt sich ohne Rollen. */
@media (max-aspect-ratio: 1/1) and (min-height: 1100px) {
    .buehne {
        grid-template-rows: minmax(0, 1fr) minmax(min-content, 1fr);
    }
}

/* ----- LINKS: LIA UND DAS GESPRÄCH ----- */

.buehne .lia-gespraech.buehne-links {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto auto;
    height: auto;
    /* So hoch wie Leiste, Verlauf und Eingabe mindestens brauchen — LIA und ihr Satz rollen darin. */
    min-height: min-content;
    min-width: 0;
    overflow: hidden;
    background: transparent;
    border: 0;
    box-shadow: none;
    color: var(--b-text);
}

/* LINKSBÜNDIG WIE IM ENTWURF (itm-722): LIA oben in einer Zeile, darunter ihr Satz und die Kacheln. */
.buehne .lia-gegenueber {
    position: static;
    min-height: 0;
    align-items: stretch;
    justify-content: flex-start;
    text-align: left;
    gap: clamp(8px, 1.6vh, 18px);
    /* DER SCHEIN UM LIAS BILD RAGT IN DEN RAND: Der rollende Kasten reicht darum 28 px in den Rand hinein, sonst schnitte er
       den Schein gerade ab. */
    margin: 0 -28px;
    padding: 18px 28px 4px;
    scrollbar-color: var(--b-linie) transparent;
}

/* LIA OBEN UND IN DER MITTE, Name und Stand darunter (Martin 07.10.2026: „Der Vogel ist noch immer klein und links, und rechts
   daneben LIA bereit. Sollte das nicht unter ihr stehen? Also etwas größer Avatar bzw. Vogel."). Das Bild ragt mit seinem Schein in
   den Rand — der Platz um das Logo ist Leinwand für Ringe, kein Inhalt; darum ziehen die negativen Ränder es an Name und Satz heran. */
/* DAS BILD GIBT NACH, NICHT DER SATZ (07.10.2026, Martin: „der text der vom assistenten vorgelesen wird, ist sehr klein und nur
   mit scrollbalken"). Reicht die Höhe nicht, schrumpft zuerst der Platz des Bildes — bis `--platz-min`, Name und Stand bleiben
   ganz. Die Untergrenze steht hier als Rechnung, weil eine Spalte mit fester Bildhöhe sich sonst nicht kleiner rechnen lässt. */
.buehne .lia-gegenueber {
    --platz-min: 72px;
}

.buehne-praesenz {
    flex: 0 1 auto;
    /* DIE UNTERGRENZE: Bild plus Name und Stand (32 px), auch mit dem Abstand der Figur (8 px) — lieber etwas Luft als Name auf dem Satz. */
    min-height: calc(var(--platz-min, 72px) + 42px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    margin: -14px 0 0;
}

/* NAME UND STAND AUF EINER LINIE (07.10.2026, Martin: der Chip „denkt nach …“ saß versetzt): beide 32 px hoch und mittig
   zueinander. Der Name ist dafür selbst eine Flex-Zeile — der Abstand zwischen Name und Rolle steht darum als `gap`. */
.buehne-wer-ist {
    flex: none;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 6px 14px;
    min-height: 32px;
    margin-top: -8px;
}

.buehne-wer-ist .buehne-stand {
    flex: none;
    margin: 0;
}

/* DIE FIGUR UND DAS GESICHT reichen bis an den Rand ihres Platzes — dort kein Heranziehen. */
.buehne-praesenz:has(.buehne-figur:is([data-modus="figur"], [data-modus="gesicht"])) .buehne-wer-ist {
    margin-top: 8px;
}

/* DER PLATZ FÜR LIA: das Logo mit seinem Lichtring, der Vogel, die Figur oder das Gesicht — PROMINENT. Er wächst mit der Höhe:
   rund 300 px bei 790, 315 px bei 816, 265 px bei 720, nie unter 160 px. Spricht LIA lang (`data-laenge` lang / sehr lang),
   wird zuerst das Bild kleiner, damit ihr Satz Zeilen hat. Logo und Vogel füllen mehr von ihm als in der Konsole (64 % / 86 %). */
.buehne-figur {
    --platz: clamp(160px, calc(52vh - 110px), 360px);
    flex: 0 1 auto;
    width: var(--platz);
    height: var(--platz);
    min-height: var(--platz-min, 72px);
    display: grid;
    place-items: center;
    container-type: size;
}

/* JE LÄNGER DER SATZ, DESTO KLEINER DAS BILD — DEUTLICH (07.10.2026, Martin: „lieber den Vogel kleiner machen und dem Text den
   Platz geben"). Bis dahin nahm „lang“ dem Bild nur 30 px, und der Satz rollte in einem Kasten von zwei Zeilen. */
.buehne-links:has(.lia-untertitel[data-laenge="mittel"]) .buehne-figur {
    --platz: clamp(130px, calc(40vh - 100px), 280px);
}

.buehne-links:has(.lia-untertitel[data-laenge="lang"]) .buehne-figur {
    --platz: clamp(96px, calc(26vh - 50px), 200px);
}

.buehne-links:has(.lia-untertitel[data-laenge="sehr-lang"]) .buehne-figur {
    --platz: clamp(72px, calc(16vh - 20px), 140px);
}

/* EINSPALTIG (981 × 740, die Hälften stehen übereinander): dieselbe Ordnung, aber die linke Hälfte hat nur gut die halbe Höhe. */
@media (max-width: 860px), (max-aspect-ratio: 1/1) {
    .buehne-figur,
    .buehne-links:has(.lia-untertitel[data-laenge]) .buehne-figur {
        --platz: clamp(130px, 18vh, 180px);
    }

    .buehne-links:has(.lia-untertitel:is([data-laenge="lang"], [data-laenge="sehr-lang"])) .buehne-figur {
        --platz: clamp(72px, 12vh, 120px);
    }
}

.buehne-figur .lia-logo-rahmen {
    width: 64%;
}

.buehne-figur .lia-logo[data-gestalt="vogel"] .lia-logo-rahmen {
    width: 86%;
}

.buehne-figur .lia-logo[data-avatar="an"] .lia-logo-rahmen {
    width: 100%;
}

/* LIAS SATZ UNTER DEM BILD: ein Block in der Mitte der Spalte. Kurz steht er zentriert wie eine Bildunterschrift; lang wird er
   linksbündig — eine mittig gesetzte Absatzkante liest niemand im Saal ruhig mit. */
.buehne .lia-du,
.buehne .lia-untertitel {
    align-self: center;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.buehne .lia-du,
.buehne .lia-untertitel[data-laenge="kurz"] {
    text-align: center;
}

/* EINE ZEILE, NIE GETRENNT (itm-733): „deine KI-Kollegin“ brach bei schmaler Bühne mit Trennstrich um. */
.buehne-name {
    display: inline-flex;
    align-items: center;
    gap: 0.35em;
    height: 32px;
    margin: 0;
    font: 700 14px/1 var(--b-schrift);
    letter-spacing: 0.16em;
    color: var(--b-navy);
    white-space: nowrap;
    hyphens: none;
}

.buehne-name span {
    font-weight: 400;
    letter-spacing: 0;
    color: var(--b-leise);
}

/* DER STAND ALS CHIP (itm-722): was LIA gerade tut, aus dem Zustand ihres Bildes (`data-zustand`, lia-logo.js / lia-figur.js) —
   spricht mit Wellenform, hört zu mit Mikro, wartet auf dich, solange eine Frage mit Kacheln steht. */
.buehne-stand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0 0;
    height: 32px;
    padding: 0 14px 0 12px;
    border-radius: 3px;
    background: var(--b-glut-flaeche);
    border: 1px solid var(--b-glut-rand);
    color: var(--b-glut-text);
    font: 600 14px/1 var(--b-schrift);
}

.buehne-stand::after {
    content: "bereit";
}

.buehne-welle,
.buehne-stand-mikro {
    display: none;
}

.buehne-stand-punkt {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--b-glut);
    box-shadow: 0 0 0 4px rgba(240, 138, 28, 0.18);
}

.buehne-welle {
    align-items: center;
    gap: 3px;
    height: 18px;
}

.buehne-welle i {
    width: 3px;
    height: 18px;
    border-radius: 2px;
    background: var(--b-glut);
    animation: buehne-welle 1s ease-in-out infinite;
}

.buehne-welle i:nth-child(1) { height: 8px; }
.buehne-welle i:nth-child(2) { height: 16px; animation-delay: 0.15s; }
.buehne-welle i:nth-child(3) { height: 11px; animation-delay: 0.3s; }
.buehne-welle i:nth-child(4) { height: 18px; animation-delay: 0.45s; }
.buehne-welle i:nth-child(5) { height: 7px; animation-delay: 0.6s; }

@keyframes buehne-welle {
    50% { transform: scaleY(0.45); }
}

.buehne-stand-mikro {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
}

.buehne-links:has(.lia-optionen .lia-kachel-empfohlen) .buehne-stand::after { content: "wartet auf dich"; }
.buehne-links:has(.buehne-figur [data-zustand="denkt"]) .buehne-stand::after,
.buehne-links[data-beschaeftigt] .buehne-stand::after { content: "denkt nach …"; }
.buehne-links:has(.buehne-figur [data-zustand="hoert"]) .buehne-stand::after { content: "hört zu"; }
.buehne-links:has(.buehne-figur [data-zustand="spricht"]) .buehne-stand::after { content: "spricht"; }

.buehne-links:has(.buehne-figur [data-zustand="spricht"]) .buehne-welle { display: flex; }
.buehne-links:has(.buehne-figur [data-zustand="hoert"]) .buehne-stand-mikro { display: block; }
.buehne-links:has(.buehne-figur [data-zustand="spricht"]) .buehne-stand-punkt,
.buehne-links:has(.buehne-figur [data-zustand="hoert"]) .buehne-stand-punkt { display: none; }

@media (prefers-reduced-motion: reduce) {
    .buehne-welle i {
        animation: none;
    }
}

/* DAS ABZEICHEN AM LOGO: das Zeichen der Szene rechts, unten rechts am Bild des Logos.
   Die einzige absolute Lage links — und sie bleibt im Platz des Logos: `--l` ist die Kante des
   quadratischen Logos (wie oben), das Bild darin ist 44 % davon. Die Mitte des Abzeichens sitzt auf der
   Ecke des Bildes (±22 %), sein Halbmesser ist 10 % — also reicht es höchstens bis 32 % von der Mitte
   und bleibt im Quadrat; die Mitte des Logos deckt es nie, und Text steht ausserhalb dieses Platzes. */
.buehne-figur {
    position: relative;
}

/* AUF DER BÜHNE IST DAS BILD 60 % DES PLATZES (nicht 44 %): Die Ecke des Bildes liegt 30 % neben der Mitte. */
.buehne .buehne-abzeichen {
    left: calc(50% + var(--l) * 0.3 - var(--d) / 2);
    top: calc(50% + var(--l) * 0.3 - var(--d) / 2);
}

.buehne-abzeichen {
    --l: min(100cqw, 100cqh, 560px);
    position: absolute;
    left: calc(50% + var(--l) * 0.22 - var(--d) / 2);
    top: calc(50% + var(--l) * 0.22 - var(--d) / 2);
    /* NIE KLEINER ALS 40 PX, sonst ist es auf dem Beamer nur ein Punkt. Auch dann bleibt die Mitte frei:
       Das kleinste Logo misst 120 px, die Ecke des Bildes liegt 26 px neben der Mitte. */
    --d: max(calc(var(--l) * 0.2), 40px);
    width: var(--d);
    height: var(--d);
    display: grid;
    place-items: center;
    box-sizing: border-box;
    border-radius: 50%;
    border: max(2px, calc(var(--l) * 0.012)) solid var(--b-glut);
    background: var(--b-flaeche);
    box-shadow: 0 0 0 max(2px, calc(var(--l) * 0.01)) var(--b-flaeche), 0 6px 18px rgba(31, 34, 64, 0.22);
    color: var(--b-navy);
    opacity: 0;
    transform: scale(0.4);
    transition: opacity 0.35s, transform 0.35s ease-in;
    pointer-events: none;
}

.buehne-abzeichen.an {
    opacity: 1;
    transform: none;
}

.buehne-abzeichen.neu {
    animation: buehne-abzeichen 0.5s cubic-bezier(0.3, 1.5, 0.5, 1);
}

@keyframes buehne-abzeichen {
    0% { transform: scale(0.5); opacity: 0.2; }
    100% { transform: none; opacity: 1; }
}

.buehne-abzeichen svg {
    width: 60%;
    height: 60%;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.3;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.buehne-abzeichen svg .voll {
    fill: var(--b-glut);
    stroke: var(--b-glut);
}

.buehne-abzeichen svg .schrift,
.buehne-umlauf-zeichen svg .schrift {
    fill: var(--b-glut);
    stroke: none;
    font-family: var(--font-ui, sans-serif);
}

.buehne-abzeichen[data-zeichen="fertig"] {
    border-color: var(--b-gut);
    color: var(--b-gut);
}

.buehne-abzeichen[data-zeichen="fertig"] svg {
    stroke-width: 3;
}

.buehne-abzeichen[data-zeichen="fehler"] {
    border-color: var(--b-halt);
    color: var(--b-halt);
}

.buehne-abzeichen[data-zeichen="fehler"] svg {
    stroke-width: 3;
}

.buehne-abzeichen[data-zeichen="fehler"] svg .voll {
    fill: var(--b-halt);
    stroke: var(--b-halt);
}

@media (prefers-reduced-motion: reduce) {
    .buehne-abzeichen,
    .buehne-abzeichen.an {
        transform: none;
    }

    .buehne-abzeichen.neu {
        animation: bs-blende 0.4s ease-out;
    }
}

/* DER UMLAUF: bis zu drei vorige Tätigkeiten kreisen ums Logo, solange LIA arbeitet. Bahn 42 % der Kante,
   Zeichen 12 % — also bis 48 % von der Mitte, innerhalb des Quadrats und ausserhalb des Logobildes (dessen
   Ecke liegt bei 31 %). Das Abzeichen liegt darüber. */
.buehne-umlauf {
    --l: min(100cqw, 100cqh, 560px);
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.6s;
}

.buehne-umlauf.an {
    opacity: 1;
}

.buehne-umlauf-zeichen {
    --g: calc(var(--l) * 0.12);
    position: absolute;
    left: calc(50% - var(--g) / 2);
    top: calc(50% - var(--g) / 2);
    width: var(--g);
    height: var(--g);
    display: grid;
    place-items: center;
    box-sizing: border-box;
    border-radius: 50%;
    background: var(--b-flaeche);
    border: 2px solid var(--b-glut-rand);
    color: var(--b-glut-text);
    opacity: calc(0.9 - var(--i, 0) * 0.2);
    transform: rotate(calc(var(--i, 0) * 120deg - 60deg)) translateX(calc(var(--l) * 0.42)) rotate(calc(var(--i, 0) * -120deg + 60deg));
    animation: buehne-umlauf 18s linear infinite;
    animation-delay: calc(var(--i, 0) * -6s);
}

.buehne-umlauf-zeichen svg {
    width: 62%;
    height: 62%;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.4;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.buehne-umlauf-zeichen svg .voll {
    fill: currentColor;
}

@keyframes buehne-umlauf {
    from { transform: rotate(-60deg) translateX(calc(var(--l) * 0.42)) rotate(60deg); }
    to { transform: rotate(300deg) translateX(calc(var(--l) * 0.42)) rotate(-300deg); }
}

/* DER IMPULS ZUR SZENE: ein Lichtpunkt ab der Mitte des Abzeichens; die Bahn rechnet lia-buehne.js. */
.buehne-impuls {
    --l: min(100cqw, 100cqh, 560px);
    position: absolute;
    left: calc(50% + var(--l) * 0.22 - 9px);
    top: calc(50% + var(--l) * 0.22 - 9px);
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ffd9a8;
    box-shadow: 0 0 16px 6px rgba(245, 169, 60, 0.85), -22px 0 16px -2px rgba(245, 169, 60, 0.45), -44px 0 18px -6px rgba(245, 169, 60, 0.2);
    opacity: 0;
    pointer-events: none;
}

/* DER RING, WENN EIN SCHRITT FERTIG IST: einmal grün um das Abzeichen. */
.buehne-abzeichen.blitz::after {
    content: "";
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 3px solid var(--b-gut);
    animation: buehne-blitz 0.9s ease-out forwards;
}

@keyframes buehne-blitz {
    from { transform: scale(1); opacity: 1; }
    to { transform: scale(1.55); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .buehne-umlauf-zeichen {
        animation: none;
    }

    .buehne-abzeichen.blitz::after {
        animation: bs-blende 0.9s ease-out reverse forwards;
    }
}

.buehne .lia-logo {
    flex: none;
    width: min(100cqw, 100cqh, 560px);
    height: min(100cqw, 100cqh, 560px);
    min-height: 0;
    max-width: none;
    aspect-ratio: auto;
}

/* TEXT LIEGT ÜBER DEM SCHEIN DES LOGOS, NIE DARUNTER. Das Logo trägt eine Transformation und einen
   weichen Schatten; ohne eigene Ebene malte der Browser beides über den Text daneben. */
.buehne .lia-du,
.buehne .lia-untertitel,
.buehne .lia-optionen {
    position: relative;
    z-index: 1;
}

.buehne .lia-du {
    flex: none;
    max-width: 52ch;
    margin-top: clamp(4px, 1.4vh, 14px);
    font: italic 400 16px/1.4 var(--b-schrift);
    color: var(--b-leise);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.buehne .lia-du:empty {
    display: none;
}

/* DER UNTERTITEL wird kleiner, je mehr LIA sagt (lia-buehne.js setzt `data-laenge`) — aber er ROLLT NIE IN SICH
   (07.10.2026, Martin: „der text der vom assistenten vorgelesen wird, ist sehr klein und nur mit scrollbalken"). Bis dahin
   schrumpfte er auf zwei Zeilen mit eigenem Balken; jetzt steht er ganz, das Bild darüber gibt Platz ab (`.buehne-figur`), und
   reicht auch das nicht, rollt als letzter Ausweg der ganze obere Teil der Spalte (`.lia-gegenueber`). */
.buehne .lia-untertitel {
    flex: none;
    min-height: 0;
    max-width: 40ch;
    overflow: visible;
    /* LIAS SATZ IN SAALGRÖSSE (itm-722): bei 1600 × 900 gut 32 px, Regular, Navy-Tinte; lange Antworten werden kleiner. */
    font: 400 28px/1.4 var(--b-schrift);
    letter-spacing: -0.005em;
    color: var(--b-text);
    text-wrap: pretty;
    white-space: normal;
    scrollbar-width: thin;
    scrollbar-color: var(--b-linie-2) transparent;
}

/* DIE FRAGE IN EINER EIGENEN ZEILE (lia.js): kräftig und Navy — darauf antworten die Kacheln darunter. */
.buehne .lia-untertitel .lia-frage {
    display: block;
    margin-top: 0.4em;
    font-weight: 600;
    color: var(--b-navy);
}

/* DIE BEGRÜSSUNG, bevor LIA etwas gesagt hat: in Navy, so groß wie ihre Sätze — nicht mehr 38 px leicht (itm-733, Martin
   07.10.2026: „Die Schriften sind sehr groß"). */
.buehne .lia-untertitel[data-laenge="kurz"]:not(.lia) {
    font-size: 28px;
    font-weight: 400;
    line-height: 1.25;
    letter-spacing: -0.01em;
    color: var(--b-navy);
}

/* KURZ RAGT NICHTS ÜBER: Die Zeile schrumpft nicht, und die Unterlängen der letzten Zeile bekommen ihren Platz. */
.buehne .lia-untertitel[data-laenge="kurz"] {
    flex-shrink: 0;
    min-height: auto;
    padding-bottom: 0.1em;
}

/* LANG BLEIBT LESBAR (07.10.2026): 18 und 16 px waren am Beamer zu klein. Jetzt 22 und 20 px bei voller Höhe, bei 720 px gut
   18 und 17 — kleiner wird zuerst das Bild. */
.buehne .lia-untertitel[data-laenge="mittel"] {
    max-width: 46ch;
    font-size: 24px;
}

.buehne .lia-untertitel[data-laenge="lang"] {
    max-width: 54ch;
    font-size: clamp(18px, 2.6vh, 22px);
    line-height: 1.45;
}

.buehne .lia-untertitel[data-laenge="sehr-lang"] {
    max-width: 62ch;
    font-size: clamp(17px, 2.3vh, 20px);
    line-height: 1.45;
}

.buehne .lia-untertitel.denkt {
    color: var(--b-leise);
}

.buehne .lia-untertitel.fehler {
    color: #b01c14;
}

/* DIE KACHELN IN EINER EIGENEN, FESTEN ZEILE (itm-733): Bis dahin rollten sie mit LIAs Satz und wurden bei 816 px Höhe
   angeschnitten, bei 620 px waren sie weg. Jetzt stehen sie immer; nur wenn LIA sehr viele anbietet, rollen sie in sich. */

/* DER VERSTECKTE VERLAUF BLEIBT VERSTECKT (Befund Martin 07.10.2026, Scaliento-Rahmen 1426 × 790: „LIA ist abgeschnitten“). Die
   allgemeine Regel `.lia-nachrichten { display: flex }` wog mehr als `hidden`: Der Verlauf stand als vierte Zeile im Raster der
   linken Hälfte, nahm LIA die Höhe — die Zeile mit Bild und Name schrumpfte auf gut 20 px und rollte —, und die Kacheln lagen
   über dem Bild statt unter ihrem Satz. Ohne ihn sind es wieder drei Zeilen: LIA und ihr Satz, die Kacheln, die Eingabe. */
.buehne .lia-nachrichten[hidden] {
    display: none;
}

/* NUR IM ÄUSSERSTEN NOTFALL ROLLT DER OBERE TEIL GANZ (07.10.2026): Erst wird das Bild kleiner (bis `--platz-min`), dann rollt
   die ganze obere Spalte — Bild, Name und Satz zusammen —, nie der Satz allein in einem Kasten von zwei Zeilen. Kacheln und
   Eingabe stehen in eigenen Zeilen darunter und bleiben immer im Blick. */
.buehne .lia-gegenueber {
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
}

/* DIE SPALTE IST EIN CONTAINER: Die Kacheln richten sich nach ihrer Breite, nicht nach der des Fensters — im Rahmen von
   Scaliento ist die linke Hälfte schmaler, als das Fenster vermuten lässt. */
.buehne .buehne-links {
    container: buehne-links / inline-size;
}

.buehne .lia-optionen {
    flex: none;
    max-height: min(40vh, 330px);
    overflow-y: auto;
    padding: 2px 2px 4px;
    margin-top: 12px;
}

/* ALLE VORSCHLÄGE IN EINER ZEILE, FLACH (07.10.2026, Martin: „weiter muss nicht so groß sein, das kann ja alles in eine zeile
   was vorgeschlagen wird"). Bis dahin trug jede Kachel 140 px Mindestbreite und 76 px Höhe: Im Rahmen passten drei in die Zeile,
   und „Weiter“ stand allein und riesig in einer zweiten. Jetzt teilen sich alle die Zeile (Mindestbreite 0), Ziffer, Text und
   Zeichen stehen nebeneinander, und die empfohlene ist etwas breiter. Nur wenn die Spalte sehr schmal ist, werden es zwei je Zeile. */
.buehne .lia-optionen:has(.lia-kachel) {
    flex-wrap: wrap;
    gap: 8px;
}

.buehne button.lia-kachel {
    flex: 1 1 0;
    min-width: 0;
    min-height: 52px;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    font-size: 15px;
    line-height: 1.2;
}

.buehne button.lia-kachel.primaer {
    flex-grow: 1.5;
}

.buehne .lia-kachel-nr {
    position: static;
    flex: none;
    order: 0;
}

/* DER TEXT NIMMT, WAS ÜBRIG BLEIBT — höchstens zwei Zeilen, Wörter brechen nur, wenn sie allein nicht passen. */
.buehne .lia-kachel-text,
.buehne .lia-kachel:has(.lia-kachel-nr) .lia-kachel-text {
    order: 1;
    flex: 1 1 auto;
    padding-top: 0;
    overflow-wrap: break-word;
    hyphens: auto;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    /* NICHTS ABGESCHNITTEN (Martin, 08.10.2026, Bild: „da ist der Text bei den Buttons etwas abgeschnitten") — bei 1,2 fiel die
       Unterlänge der zweiten Zeile („planen", „zeigen") aus dem Kasten. Etwas mehr Zeilenhöhe und Luft unten. */
    line-height: 1.28;
    padding-bottom: 2px;
}

/* „✦ EMPFOHLEN“ HINTER DEM TEXT: in schmaler Spalte nur der Stern (das Wort bleibt für Vorlesesoftware), ab 760 px ganz. */
.buehne .lia-kachel-empfohlen {
    position: static;
    order: 2;
    flex: none;
    height: auto;
    gap: 0;
    font-size: 0;
}

.buehne .lia-kachel-empfohlen::before {
    font-size: 14px;
}

.buehne .lia-kachel-zeichen {
    position: static;
    order: 3;
    flex: none;
    width: 22px;
    height: 22px;
    stroke-width: 1.6;
}

@container buehne-links (min-width: 760px) {
    .buehne .lia-kachel-empfohlen {
        gap: 5px;
        font-size: 12px;
    }
}

@container buehne-links (max-width: 520px) {
    .buehne button.lia-kachel {
        flex-basis: calc(50% - 4px);
    }
}

/* DIE HINWEISZEILE UNTER DEN KACHELN hat eine feste Höhe: Dieselbe Zeile trägt auch den Hinweis der Stimme (siehe unten). */
.buehne .lia-kachel-hinweis {
    height: 20px;
    margin-top: 6px;
    overflow: hidden;
    font-size: 13px;
    line-height: 20px;
    white-space: nowrap;
}

.buehne .lia-nachricht.lia {
    background: var(--b-flaeche-2);
    color: var(--b-text);
}

/* EINGABE UND STAND IN EINER ZEILE (itm-733, Martin: „‚Schreib LIA‘ und darunter ‚LIA ist bereit‘ … das sollte eine Zeile sein").
   Ein weißes Feld mit feiner Linie wie Scaliento; darin vorn das ↺, das Ablegen, der Text, Senden — durch einen Strich getrennt
   die Anrufknöpfe. Der Stand steht als Punkt davor, im Gespräch mit der Dauer. */
.buehne-unten {
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 12px;
    padding: 6px 8px 6px 6px;
    border: 1px solid var(--b-linie-2);
    border-radius: 4px;
    background: var(--b-flaeche);
    box-shadow: 0 2px 8px rgba(31, 34, 64, 0.05);
}

.buehne .lia-eingabe {
    flex: 1 1 auto;
    min-width: 0;
    align-items: center;
    gap: 4px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.buehne .lia-eingabe textarea {
    min-width: 0;
    min-height: 0;
    height: 44px;
    padding: 12px 8px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: var(--b-text);
    font: 400 16px/1.3 var(--b-schrift);
}

/* DER PLATZHALTER IN EINER ZEILE (07.10.2026): „Schreib Gino … oder sprich mit ihm“ brach im Rahmen in zwei Zeilen um und wurde
   vom 44 px hohen Feld abgeschnitten. Passt er nicht, endet er mit „…“. */
.buehne .lia-eingabe textarea::placeholder {
    color: var(--b-leise);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.buehne .lia-eingabe .lia-ablegen {
    order: -1;
    width: 40px;
    height: 40px;
    min-height: 40px;
    border-radius: 50%;
    border-color: transparent;
    background: transparent;
    color: var(--b-navy);
}

.buehne .lia-eingabe .lia-ablegen:hover {
    background: var(--b-flaeche-2);
}

/* NEUES GESPRÄCH, CHARMANT KLEIN (itm-733): ein rundes ↺ ganz vorn, das sich beim Darüberfahren einmal dreht. Wer lieber
   spricht, sagt „Fang neu an“. */
.buehne .lia-eingabe .lia-neu {
    position: static;
    order: -2;
    flex: none;
    width: 36px;
    height: 36px;
    min-height: 0;
    display: grid;
    place-items: center;
    padding: 0;
    border-radius: 50%;
    border: 1px solid var(--b-linie);
    background: var(--b-flaeche-2);
    color: var(--b-leise);
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.buehne .lia-eingabe .lia-neu svg {
    transition: transform 0.5s cubic-bezier(0.3, 1.4, 0.5, 1);
}

.buehne .lia-eingabe .lia-neu:hover {
    color: var(--b-glut-text);
    border-color: var(--b-glut-rand);
    background: var(--b-glut-flaeche);
}

.buehne .lia-eingabe .lia-neu:hover svg {
    transform: rotate(-200deg);
}

.buehne .lia-eingabe .lia-neu:focus-visible {
    outline: 3px solid var(--b-glut);
    outline-offset: 1px;
}

/* DER SENDEN-KNOPF: rund und Navy wie der Mikroknopf. */
.buehne .lia-senden {
    width: 40px;
    height: 40px;
    min-height: 40px;
    background: var(--b-navy);
    border-color: var(--b-navy);
    color: #fff;
}

/* DIE ANRUFKNÖPFE HINTEN IN DERSELBEN ZEILE (itm-654 hell, itm-733 einzeilig): kein eigener Kasten mehr, ein Strich trennt sie
   vom Feld. Der Chat-Knopf entfällt auf der Bühne — das Feld steht ja daneben. */
.buehne .lia-sprechen {
    --lia-leiste: transparent;
    --lia-knopf: var(--b-flaeche-2);
    --lia-knopf-hover: var(--b-flaeche-3);
    --lia-orange: var(--b-glut);
    /* NICHT `relative`: Der Hinweis der Stimme richtet sich an der ganzen Zeile aus (`.buehne-unten`), nicht an den Knöpfen. */
    position: static;
    flex: none;
    flex-wrap: nowrap;
    gap: 8px;
    margin: 0;
}

.buehne .lia-anruf {
    padding: 0 0 0 10px;
    border-left: 1px solid var(--b-linie);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: var(--b-text);
}

.buehne .lia-anruf .lia-chat,
.buehne .lia-anruf-symbol {
    display: none;
}

.buehne .lia-anruf-knoepfe {
    gap: 6px;
}

.buehne .lia-rund {
    width: 40px;
    height: 40px;
    color: var(--b-navy);
}

.buehne .lia-mikro {
    width: 44px;
    height: 44px;
    background: var(--b-navy);
    color: #fff;
}

/* DER STAND ALS PUNKT: ruhig grün, wenn LIA bereit ist; orange und pulsierend im Gespräch, daneben die Dauer. Die Worte bleiben
   für Vorlesesoftware. */
.buehne .lia-anruf-status {
    gap: 8px;
}

.buehne .lia-anruf-status::before {
    content: "";
    flex: none;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--b-gut);
    box-shadow: 0 0 0 3px rgba(31, 154, 58, 0.14);
}

.buehne .lia-anruf[data-stand="verbinde"] .lia-anruf-status::before {
    background: var(--b-leise);
    box-shadow: none;
}

.buehne .lia-anruf[data-stand="an"] .lia-anruf-status::before {
    background: var(--b-glut);
    box-shadow: 0 0 0 0 rgba(240, 138, 28, 0.6);
    animation: hub-puls 1.8s infinite;
}

.buehne .lia-anruf-text strong,
.buehne .lia-anruf:not([data-stand="an"]) .lia-anruf-zeit {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.buehne .lia-anruf-zeit {
    font: 600 13px/1 var(--b-schrift);
    color: var(--b-glut-text);
    opacity: 1;
}

.buehne .lia-anruf[data-stand="an"] .lia-anruf-symbol {
    color: #fff;
}

/* EIN HINWEIS DER STIMME („Stumm — ich höre gerade nicht zu …“, „Mikrofon gesperrt …“) ERSETZT DEN HINWEIS DER KACHELN IN
   DERSELBEN ZEILE (07.10.2026, Martin: „texte überlappen"). Bis dahin schwebte er als Kästchen rechts über der Eingabe und lag
   genau auf „Kachel antippen – oder einfach ‚Senden‘ sagen“. Jetzt steht er links in der Hinweiszeile unter den Kacheln (20 px,
   16 px über der Eingabe: 4 px Polster der Kacheln + 12 px Abstand der Zeile), und der Kachelhinweis tritt so lange zurück. Gibt
   es keine Kacheln, macht die Eingabe ihm Platz. */
.buehne .lia-anruf .help {
    position: absolute;
    left: 2px;
    right: 0;
    bottom: calc(100% + 16px);
    height: 20px;
    margin: 0;
    max-width: none;
    padding: 0;
    overflow: hidden;
    background: var(--b-flaeche);
    color: var(--b-leise);
    font-size: 13px;
    line-height: 20px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.buehne .lia-anruf .help[data-warn="1"] {
    color: var(--b-glut-text);
}

.buehne-links:has([data-stimme-hinweis]:not(:empty)) .lia-kachel-hinweis {
    visibility: hidden;
}

.buehne-links:has([data-stimme-hinweis]:not(:empty)):not(:has(.lia-kachel-hinweis)) .buehne-unten {
    margin-top: 42px;
}

@media (prefers-reduced-motion: reduce) {
    .buehne .lia-anruf[data-stand="an"] .lia-anruf-status::before,
    .buehne .lia-eingabe .lia-neu svg {
        animation: none;
        transition: none;
    }
}


/* ----- DIE FIGUR (itm-515, lia-figur.js) -----
   Ersetzt das Logo auf der Bühne, sobald sie steht; bis dahin — oder wenn sie ausfällt — bleibt das Logo.
   Sie misst sich am Platz wie das Logo: quadratisch, so groß wie er hergibt, und ragt nie hinaus (das SVG
   schneidet ab, was über seinen Rand ginge). */
/* WELCHE DARSTELLUNG GILT, steht am Platz (`data-modus`, lia-buehne.js). Die Figur zählt erst, wenn sie
   steht (`mit-figur`); bis dahin — und im Modus Logo — ist sie nicht da, nimmt also auch keinen Platz. */
.buehne-figur[data-modus="figur"].mit-figur .lia-logo,
.buehne-figur[data-modus="figur"] .buehne-abzeichen,
.buehne-figur[data-modus="figur"] .buehne-umlauf,
.buehne-figur[data-modus="figur"] .buehne-impuls,
.buehne-figur:not([data-modus="figur"]) .lia-figur {
    display: none;
}

/* STEHT DAS GESICHT (itm-661), gilt es in jeder Darstellung — Figur, Abzeichen, Umlauf und Impuls treten zurück. */
.buehne-figur[data-modus="figur"].mit-figur .lia-logo[data-avatar="an"] {
    display: grid;
}

.buehne-figur:has(.lia-logo[data-avatar="an"]) :is(.lia-figur, .buehne-abzeichen, .buehne-umlauf, .buehne-impuls) {
    display: none;
}

.lia-figur {
    display: block;
    width: min(100cqw, 100cqh, 560px);
    height: min(100cqw, 100cqh, 560px);
    overflow: hidden;
    --lf-schein: #f5a93c;
}

.lia-figur[data-zustand="hoert"] { --lf-schein: #3ccf91; }
.lia-figur[data-zustand="denkt"] { --lf-schein: #7d8cff; }
.lia-figur[data-zustand="spricht"] { --lf-schein: #ffb35c; }
.lia-figur[data-zustand="freut"] { --lf-schein: #ff8fa3; }

.lia-figur .lf-schein-farbe {
    stop-color: var(--lf-schein);
    transition: stop-color 0.6s;
}

.lia-figur .lf-schein {
    animation: lf-schein 4s ease-in-out infinite;
}

.lia-figur[data-zustand="spricht"] .lf-schein,
.lia-figur[data-zustand="freut"] .lf-schein {
    animation-duration: 1.6s;
}

@keyframes lf-schein {
    50% { opacity: 0.7; }
}

.lia-figur .lf-haut { fill: #f6caa9; }
.lia-figur .lf-haut-schatten { fill: #e5a985; }
.lia-figur .lf-haar { fill: #3b2747; }
.lia-figur .lf-auge { fill: #241b33; }
.lia-figur .lf-wange { fill: #f2877a; opacity: 0.38; }
.lia-figur .lf-braue { fill: none; stroke: #3b2747; stroke-width: 5; stroke-linecap: round; }
.lia-figur .lf-lippe { fill: none; stroke: #9b3b3f; stroke-width: 4.5; stroke-linecap: round; }
.lia-figur .lf-mundraum { fill: #6b2235; }
.lia-figur .lf-ring { fill: none; stroke: #3ccf91; stroke-width: 4; opacity: 0; }

.lia-figur [data-teil="auge"] {
    transform-box: fill-box;
    transform-origin: center;
}

.lia-figur [data-teil="punkte"] {
    fill: #c9cff0;
    opacity: 0;
    transition: opacity 0.4s;
}

.lia-figur[data-zustand="denkt"] [data-teil="punkte"] {
    opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
    .lia-figur .lf-schein {
        animation: none;
    }
}

/* ----- RECHTS: WAS LIA TUT ----- */

.buehne-rechts {
    display: grid;
    /* DIE SZENE HAT IHR MINIMUM IN DER SPUR, nicht nur am Element: `min-height` an einem Element in einer
       Spur `minmax(0, 1fr)` liesse es über den Titel darunter wachsen (900 × 1200, 03.10.2026). */
    grid-template-rows: auto minmax(clamp(150px, 28vh, 420px), 1fr) auto auto auto auto;
    gap: clamp(6px, 1.3vh, 18px);
    min-width: 0;
    /* REICHT DIE HÖHE NICHT, wird die Spalte länger und die Bühne rollt — die Szene schrumpft nie unter
       ihr Minimum und schiebt sich nie unter den Titel. Die linke Spalte bleibt davon unberührt. */
    min-height: min-content;
    overflow: hidden;
}

/* DER KOPF (itm-722): oben klein und orange, wer am Werk ist; darunter groß und leicht der Fall, der Stand in Grau. */
.buehne-kopf {
    display: grid;
    gap: 10px;
    min-width: 0;
}

.buehne-auge {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font: 700 12px/1 var(--b-schrift);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--b-glut-text);
}

.buehne-auge-punkt {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--b-glut);
    box-shadow: 0 0 0 4px rgba(240, 138, 28, 0.18);
    animation: buehne-auge 2.4s ease-in-out infinite;
}

@keyframes buehne-auge {
    50% { box-shadow: 0 0 0 7px rgba(240, 138, 28, 0.06); }
}

.buehne-ueberschrift {
    margin: 0;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    /* 22 PX (itm-733): derselbe Titelgrad wie die Bereiche. */
    font: 400 22px/1.2 var(--b-schrift);
    letter-spacing: 0;
    color: var(--b-navy);
}

.buehne-workflow {
    color: var(--b-leise);
    font-size: 0.73em;
}

.buehne-unterzeile {
    margin: -2px 0 0;
    font: 400 16px/1.4 var(--b-schrift);
    color: var(--b-leise);
}

.buehne-unterzeile:empty {
    display: none;
}

@media (prefers-reduced-motion: reduce) {
    .buehne-auge-punkt {
        animation: none;
    }
}

/* DIE SZENE: ein eigener Kasten mit eigener Grösse — alles darin misst sich an ihm (cqw/cqh). Hell, mit einer ruhigen Scheibe
   hinter dem Bild (itm-722, im Bild selbst gezeichnet). */
.buehne-szene {
    position: relative;
    container-type: size;
    overflow: hidden;
    isolation: isolate;
    border-radius: 3px;
    background: var(--b-flaeche-2);
    border: 0;
}

.bs-vorrat {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}

.bs-bild {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    padding: clamp(8px, 3cqh, 28px);
}

/* DIE QR-KARTE FÜLLT DEN RAHMEN UND WÄCHST NICHT DARÜBER HINAUS (13.10.2026, viele Nachrichten): eine feste Zeile, sonst rechnet
   ihre Höhe von 100 % gegen den Inhalt. */
.bs-bild.mit-qk {
    grid-template: minmax(0, 1fr) / minmax(0, 1fr);
    place-items: stretch;
}

.bs-bild > svg {
    display: block;
    width: 100%;
    height: 100%;
}

.bs-bild.kommt {
    animation: bs-kommt 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.bs-bild.geht {
    animation: bs-geht 0.4s ease-in both;
}

@keyframes bs-kommt {
    from { opacity: 0; transform: scale(0.93) translateY(14px); }
}

@keyframes bs-geht {
    to { opacity: 0; transform: scale(1.05); }
}

@keyframes bs-blende {
    from { opacity: 0; }
}

/* DER HAKEN, WENN DER SCHRITT FERTIG IST: in der Ecke der Szene, nie über Text. */
.bs-marke {
    position: absolute;
    top: clamp(10px, 4cqh, 22px);
    right: clamp(10px, 3cqw, 22px);
    display: grid;
    place-items: center;
    width: clamp(34px, 11cqh, 60px);
    height: clamp(34px, 11cqh, 60px);
    border-radius: 50%;
    background: var(--b-gut);
    color: #fff;
    font-size: clamp(18px, 6cqh, 32px);
    font-weight: 800;
    opacity: 0;
    transform: scale(0);
    transition: opacity 0.3s, transform 0.45s cubic-bezier(0.3, 1.6, 0.5, 1);
}

.bs-bild.erledigt .bs-marke {
    opacity: 1;
    transform: scale(1);
}

.bs-bild[data-bild="diagramm"] .bs-marke {
    display: none;
}

/* DIE GROSSE ZEILE: was LIA tut, im Infinitiv. Höchstens zwei Zeilen — der Titel ist kurz gemeint. */
.buehne-titel {
    margin: 0;
    transform-origin: 0% 50%;
    font-family: var(--b-schrift);
    /* 28 PX STATT 38 PX LEICHT (itm-733) — die Stufe von LIAs Sätzen. */
    font-size: 28px;
    font-weight: 400;
    line-height: 1.18;
    letter-spacing: -0.01em;
    color: var(--b-navy);
    text-wrap: balance;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    padding-bottom: 0.06em;
}

.buehne-titel.neu {
    animation: buehne-auftritt 0.5s ease-out;
}

.buehne-titel[data-art="gelungen"] {
    color: var(--b-gut);
}

.buehne-titel[data-art="fehler"] {
    color: var(--b-halt);
}

/* WARTET: Navy wie jeder Titel (itm-722) — dass LIA wartet, sagen „JETZT“ und ihr Stand links. */
.buehne-titel[data-art="wartet"] {
    color: var(--b-navy);
}

/* NUR KLEINER, NIE VERSCHOBEN: Ein Titel, der von unten hereinfährt, läge kurz über dem Satz darunter. */
@keyframes buehne-auftritt {
    from { opacity: 0; transform: scale(0.96); }
    to { opacity: 1; transform: none; }
}

.buehne-satz {
    margin: 0;
    min-height: 1.3em;
    font-family: var(--b-schrift);
    font-size: 18px;
    line-height: 1.45;
    color: var(--b-text-2);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.buehne-ablauf {
    min-width: 0;
}

/* DIE KETTE: eine Zeile, die seitlich rollt (lia-buehne.js hält den aktiven Schritt in der Mitte).
   Die Verbindungslinien liegen im Kasten des eigenen Schritts — keine ragt in einen anderen. */
.buehne-kette {
    --punkt: clamp(26px, 2.2vw, 40px);
    display: flex;
    margin: 0;
    padding: 2px 0;
    list-style: none;
    overflow-x: auto;
    scrollbar-width: none;
    scroll-behavior: smooth;
}

.buehne-kette::-webkit-scrollbar {
    display: none;
}

.buehne-kette:empty {
    display: none;
}

.buehne-schritt {
    position: relative;
    flex: 0 0 clamp(92px, 8.5vw, 150px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-align: center;
    color: var(--b-leise);
    font-size: 13px;
}

.buehne-schritt::before,
.buehne-schritt::after {
    content: "";
    position: absolute;
    top: calc(var(--punkt) / 2 - 1px);
    width: calc(50% - var(--punkt) / 2 - 4px);
    height: 2px;
    background: var(--b-linie);
}

.buehne-schritt::before {
    left: 0;
}

.buehne-schritt::after {
    right: 0;
}

.buehne-schritt:first-child::before,
.buehne-schritt:last-child::after {
    display: none;
}

.buehne-schritt .punkt {
    display: grid;
    place-items: center;
    width: var(--punkt);
    height: var(--punkt);
    border-radius: 50%;
    border: 2px solid var(--b-linie);
    background: var(--b-flaeche);
    font-size: calc(var(--punkt) * 0.45);
    font-weight: 700;
    color: var(--b-text);
    transition: border-color 0.3s, box-shadow 0.3s;
}

.buehne-schritt .name {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    padding: 0 4px;
    line-height: 1.2;
}

.buehne-schritt.fertig {
    color: var(--b-text);
}

.buehne-schritt.fertig .punkt {
    border-color: var(--b-gut);
    color: var(--b-gut);
}

.buehne-schritt.aktiv {
    color: var(--b-text);
    font-weight: 600;
}

.buehne-schritt.aktiv .punkt {
    border-color: var(--b-glut);
    box-shadow: 0 0 0 4px rgba(245, 169, 60, 0.18), 0 0 18px rgba(245, 169, 60, 0.55);
    animation: buehne-puls 1.6s ease-in-out infinite;
}

.buehne-schritt.wartet .punkt {
    color: var(--b-glut);
}

.buehne-schritt.fehler .punkt {
    border-color: var(--b-halt);
    color: var(--b-halt);
}

.buehne-schritt.einschub .punkt {
    border-style: dashed;
}

@keyframes buehne-puls {
    50% { box-shadow: 0 0 0 7px rgba(245, 169, 60, 0.08), 0 0 26px rgba(245, 169, 60, 0.7); }
}

.buehne-weitere {
    margin: 4px 0 0;
    color: var(--b-leise);
    font-size: 14px;
}

.buehne-weitere:empty {
    display: none;
}

.buehne-fuss {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 8px 20px;
    font-size: 14px;
}

.buehne-fuss a {
    color: var(--b-leise);
}

.buehne-fuss button {
    background: transparent;
    color: var(--b-leise);
    border: 1px dashed var(--b-linie);
}

/* ----- DIE SZENEN (lia-buehne.js) -----
   Die Ruhelage jedes Teils ist sein Standbild; die Animation bewegt nur. `transform-box: fill-box`
   macht `transform-origin` zum Kasten des Teils statt zum ganzen Bild. */

.buehne-szene svg * {
    transform-box: fill-box;
    transform-origin: center;
}

/* DÜNNE NAVY-STRICHE AUF WEISS, EIN ORANGER AKZENT (itm-722): Was bis dahin eine helle Fläche auf dem Navy war, ist jetzt ein
   weißes Teil mit Navy-Rand; Zeilen sind Navy, halb durchsichtig. Orange bleibt LIAs Anteil — das, was sie gerade tut. */
.bs-flaeche { fill: var(--b-flaeche); stroke: var(--b-navy); stroke-width: 4; }
.bs-flaeche-hell { fill: var(--b-flaeche-3); stroke: var(--b-navy); stroke-width: 4; }
.bs-glut { fill: var(--b-glut); }
.bs-kopf { fill: var(--b-navy); }
.bs-hell, .bs-hell-fill, .bs-papier, .bs-linie-flaeche { fill: var(--b-flaeche); stroke: var(--b-navy); stroke-width: 4; }
.bs-zeile, .bs-zeile-fest { fill: rgba(41, 45, 91, 0.32); }
.bs-ring { fill: var(--b-navy); }
.bs-loch { fill: var(--b-flaeche); }
.bs-gut-fill { fill: var(--b-gut); }
.bs-halt-fill { fill: var(--b-halt); }
.bs-leiste { fill: var(--b-navy); }
.bs-linie { fill: none; stroke: var(--b-navy); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bs-frage-zeichen { fill: #fff; font: 700 26px var(--b-schrift); }

.bs-schrift {
    fill: var(--b-navy);
    font: 700 28px var(--b-schrift);
    text-anchor: middle;
}

.bs-schrift.dunkel { fill: #fff; }
.bs-schrift.glut { fill: var(--b-glut-text); }
.bs-schrift.gross { font-size: 50px; }
.bs-schrift.riesig { font-size: 160px; font-weight: 800; }

.bs-haken-strich {
    fill: none;
    stroke: #fff;
    stroke-width: 9;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 200;
}

.bs-haken-strich.klein { stroke-width: 6; }
.bs-haken-strich.gross { stroke: var(--b-gut); stroke-width: 22; }

/* gemeinsam */
.bs-atmen { animation: bs-atmen 2.2s ease-in-out infinite; }
@keyframes bs-atmen { 50% { transform: scale(1.05); } }

.bs-dreh { animation: bs-dreh 8s linear infinite; }
.bs-dreh.links { animation-duration: 5.4s; animation-direction: reverse; }
@keyframes bs-dreh { to { transform: rotate(360deg); } }

@keyframes bs-blinken { 50% { opacity: 0.25; } }

@keyframes bs-auftauchen {
    0% { opacity: 0; transform: scale(0.6); }
    12% { opacity: 1; transform: scale(1.06); }
    18%, 88% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(1); }
}

@keyframes bs-ziehen {
    0%, 45% { stroke-dashoffset: 200; }
    60%, 100% { stroke-dashoffset: 0; }
}

/* WO DER FILM STEHT, ZEIGT ER DIE RUHE (itm-777): Das Ruhebild blitzte beim Laden auf, bis lia-film.js übernahm. Jetzt
   steht es dort gar nicht erst — „Alles im Blick" mit dem Scanner ist die eine Ruhe. */
.buehne-rechts:has(.fm) .bs-bild[data-bild="bereit"] { visibility: hidden; }

/* bereit — die vier Bereiche und das Logo, das seine Runde dreht (itm-720). 12 s die Runde: je 2 s an einem Bereich, 1 s Weg. */
.bs-runde { fill: none; stroke: var(--b-linie-2); stroke-width: 3; stroke-dasharray: 4 12; stroke-linejoin: round; }
.bs-bereich-karte { fill: var(--b-flaeche-2); stroke: var(--b-linie-2); stroke-width: 2; transition: none; }
.bs-bereich-titel { fill: var(--b-leise); font: 700 19px var(--font-ui, sans-serif); text-anchor: middle; }
.bs-bereich-haken { fill: none; stroke: var(--b-gut); stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.bs-bereich-haken.dunkel { stroke: var(--b-grund); stroke-width: 5; }
.bs-bereich-schild { fill: var(--b-glut); }
.bs-bereich .bs-bereich-karte,
.bs-bereich .bs-bereich-titel { animation: bs-bereich-blick 12s ease-in-out infinite; animation-delay: calc(var(--i, 0) * 3s); }
@keyframes bs-bereich-blick {
    0%, 4% { stroke: var(--b-linie-2); fill: var(--b-flaeche-2); }
    8%, 20% { stroke: var(--b-glut); fill: var(--b-glut-flaeche); }
    28%, 100% { stroke: var(--b-linie-2); fill: var(--b-flaeche-2); }
}
.bs-bereich .bs-bereich-titel { animation-name: bs-bereich-titel; }
@keyframes bs-bereich-titel {
    0%, 4%, 28%, 100% { fill: var(--b-leise); }
    8%, 20% { fill: var(--b-text); }
}
.bs-spaeher { transform: translate(325px, 70px); animation: bs-spaeher 12s cubic-bezier(0.55, 0, 0.3, 1) infinite; }
.bs-spaeher image { animation: bs-spaeher-wippen 1.6s ease-in-out infinite alternate; }
.bs-spaeher-hof { fill: var(--b-glut); opacity: 0.18; animation: bs-spaeher-hof 2s ease-out infinite; transform-origin: 0 0; }
@keyframes bs-spaeher {
    0%, 16.6% { transform: translate(325px, 70px); }
    25%, 41.6% { transform: translate(685px, 70px); }
    50%, 66.6% { transform: translate(685px, 260px); }
    75%, 91.6% { transform: translate(325px, 260px); }
    100% { transform: translate(325px, 70px); }
}
@keyframes bs-spaeher-wippen { to { transform: translateY(-5px) rotate(-6deg); } }
@keyframes bs-spaeher-hof { from { transform: scale(0.6); opacity: 0.35; } to { transform: scale(1.5); opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
    .bs-spaeher, .bs-spaeher image, .bs-spaeher-hof, .bs-bereich .bs-bereich-karte, .bs-bereich .bs-bereich-titel { animation: none; }
}

.bs-bahn { fill: none; stroke: var(--b-linie-2); stroke-width: 3; stroke-dasharray: 6 14; animation: bs-dreh 60s linear infinite; }
.bs-kern { fill: var(--b-glut); opacity: 0.9; }
.bs-schweben { animation: bs-schweben 3.4s ease-in-out infinite alternate; animation-delay: calc(var(--i, 0) * -0.85s); }
@keyframes bs-schweben { to { transform: translateY(-16px); } }

/* postfach */
.bs-deckel { transform-origin: 0% 100%; transform: rotate(-22deg); animation: bs-deckel 3.6s ease-in-out infinite; }
@keyframes bs-deckel { 0% { transform: rotate(0); } 18%, 85% { transform: rotate(-22deg); } 100% { transform: rotate(0); } }
.bs-fach { fill: var(--b-navy); stroke: var(--b-glut); stroke-width: 4; }
.bs-schlitz { fill: var(--b-grund); }
.bs-flieg { animation: bs-heraus 3.6s cubic-bezier(0.2, 0.8, 0.2, 1) infinite both; animation-delay: calc(0.25s + var(--i, 0) * 0.22s); }
@keyframes bs-heraus {
    0%, 8% { transform: translate(var(--dx, 0px), var(--dy, 0px)) scale(0.35); opacity: 0; }
    14% { opacity: 1; }
    45%, 86% { transform: none; opacity: 1; }
    100% { transform: none; opacity: 0; }
}

/* lesen */
.bs-scanbalken { fill: rgba(245, 169, 60, 0.28); stroke: var(--b-glut); stroke-width: 2; animation: bs-scan 3s ease-in-out infinite alternate; }
@keyframes bs-scan { to { transform: translateY(216px); } }
.bs-pille { fill: var(--b-flaeche-2); stroke: var(--b-glut); stroke-width: 3; }
.bs-pille.glut { fill: var(--b-glut); }
.bs-etikett { animation: bs-auftauchen 3.6s infinite both; animation-delay: calc(0.3s + var(--i, 0) * 0.5s); }

/* zusammenfassen */
.bs-pfeil { fill: none; stroke: var(--b-glut); stroke-width: 8; stroke-linecap: round; stroke-linejoin: round; animation: bs-blinken 1.2s infinite; animation-delay: calc(var(--i, 0) * 0.3s); }
.bs-wachsen { transform-origin: 0% 50%; animation: bs-wachsen 3.6s cubic-bezier(0.2, 0.8, 0.2, 1) infinite both; animation-delay: calc(0.3s + var(--i, 0) * 0.35s); }
@keyframes bs-wachsen { 0% { transform: scaleX(0); } 18%, 88% { transform: scaleX(1); opacity: 1; } 100% { transform: scaleX(1); opacity: 0; } }

/* schreiben, angebot: die Zeilen bewegt lia-buehne.js, damit sie der Reihe nach entstehen */
.bs-zeile { transform-origin: 0% 50%; }
.bs-stift { animation: bs-stift 0.55s ease-in-out infinite alternate; }
@keyframes bs-stift { to { transform: translate(-14px, 8px) rotate(-8deg); } }
.bs-summe { fill: var(--b-flaeche-2); }
.bs-pdf { animation: bs-spaet 5s infinite both; }
@keyframes bs-spaet { 0%, 55% { opacity: 0; transform: scale(0.4); } 62% { opacity: 1; transform: scale(1.12); } 68%, 100% { opacity: 1; transform: scale(1); } }

/* freigabe */
.bs-stempelring { fill: rgba(245, 169, 60, 0.12); stroke: var(--b-glut); stroke-width: 6; stroke-dasharray: 18 12; animation: bs-dreh 14s linear infinite; }
.bs-stempel { animation: bs-atmen 2s ease-in-out infinite; }

/* senden */
.bs-spur { fill: none; stroke: var(--b-glut); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 2 18; animation: bs-spur 0.9s linear infinite; }
@keyframes bs-spur { to { stroke-dashoffset: -40; } }
.bs-zug { fill: var(--b-linie-2); transform-origin: 100% 50%; animation: bs-zug 0.9s ease-in-out infinite; animation-delay: calc(var(--i, 0) * 0.15s); }
@keyframes bs-zug { 0% { transform: scaleX(0.2); opacity: 0; } 50% { transform: scaleX(1); opacity: 1; } 100% { transform: translateX(-60px) scaleX(0.3); opacity: 0; } }
.bs-wegflug { animation: bs-wegflug 3.2s cubic-bezier(0.5, 0, 0.2, 1) infinite; }
@keyframes bs-wegflug {
    0%, 22% { transform: none; opacity: 1; }
    62% { transform: translate(340px, -190px) scale(0.22) rotate(-14deg); opacity: 0; }
    63% { transform: translate(-80px, 0) scale(0.9); opacity: 0; }
    80%, 100% { transform: none; opacity: 1; }
}

/* kalender, vorschlag, termin */
.bs-zelle { fill: var(--b-flaeche); stroke: var(--b-linie-2); stroke-width: 2; }
.bs-zelle.belegt { fill: #c9cce6; stroke: none; }
.bs-zelle.frei { fill: var(--b-flaeche-2); stroke: var(--b-gut); stroke-width: 3; animation: bs-frei 2.6s ease-in-out infinite; animation-delay: calc(var(--i, 0) * 0.08s); }
@keyframes bs-frei { 50% { fill: rgba(31, 154, 58, 0.22); } }
.bs-zelle.kandidat { fill: var(--b-glut); animation: bs-kandidat 1.4s ease-in-out infinite; animation-delay: calc(var(--i, 0) * 0.1s); }
@keyframes bs-kandidat { 50% { transform: scale(1.14); opacity: 0.7; } }
.bs-suchband { fill: rgba(245, 169, 60, 0.22); stroke: var(--b-glut); stroke-width: 2; animation: bs-band 3.2s ease-in-out infinite alternate; }
@keyframes bs-band { to { transform: translateX(256px); } }
.bs-umblaettern { transform-origin: 50% 0%; opacity: 0; animation: bs-blatt 4.4s ease-in infinite; }
@keyframes bs-blatt { 0%, 6% { opacity: 1; transform: scaleY(1); } 30% { opacity: 1; transform: scaleY(0); } 31%, 100% { opacity: 0; transform: scaleY(0); } }
.bs-eintrag { transform-origin: 0% 50%; animation: bs-eintrag 4.4s cubic-bezier(0.2, 0.8, 0.2, 1) infinite; }
@keyframes bs-eintrag { 0%, 30% { transform: scaleX(0); opacity: 0; } 45%, 100% { transform: scaleX(1); opacity: 1; } }
.bs-eintrag .bs-haken-strich { animation: bs-ziehen 4.4s infinite; }

/* aufgabe */
.bs-kaestchen { fill: none; stroke: var(--b-navy); stroke-width: 4; }
.bs-kaestchen.fertig { fill: var(--b-gut); stroke: var(--b-gut); }
.bs-markiert { fill: rgba(245, 169, 60, 0.16); stroke: var(--b-glut); stroke-width: 3; }
.bs-neuezeile { animation: bs-rein 4s cubic-bezier(0.2, 0.8, 0.2, 1) infinite; }
@keyframes bs-rein { 0% { transform: translateX(260px); opacity: 0; } 20%, 100% { transform: none; opacity: 1; } }
.bs-neuezeile .bs-haken-strich { stroke: var(--b-gut); animation: bs-ziehen 4s infinite; }

/* recherche, wissen */
.bs-fenster { fill: var(--b-glut); opacity: 0.35; animation: bs-fenster 3s ease-in-out infinite; animation-delay: calc(var(--i, 0) * 0.2s); }
@keyframes bs-fenster { 50% { opacity: 0.95; } }
.bs-globus { fill: none; stroke: var(--b-navy); stroke-width: 4; }
.bs-linse { fill: rgba(245, 169, 60, 0.2); }
.bs-rand { fill: none; stroke: var(--b-text); stroke-width: 12; }
.bs-griff { fill: var(--b-text); }
.bs-lupenfahrt { transform-box: view-box; transform: translate(330px, 230px); animation: bs-fahrt 6s ease-in-out infinite; }
@keyframes bs-fahrt {
    0%, 100% { transform: translate(330px, 230px); }
    25% { transform: translate(470px, 160px); }
    50% { transform: translate(600px, 230px); }
    75% { transform: translate(420px, 310px); }
}
.bs-lupenfahrt.klein .bs-rand { stroke: var(--b-navy); }
.bs-lupenfahrt.klein .bs-griff { fill: var(--b-navy); }
.bs-lupenfahrt.klein { transform: translate(300px, 220px); animation-name: bs-fahrt-buch; }
@keyframes bs-fahrt-buch {
    0%, 100% { transform: translate(300px, 220px); }
    33% { transform: translate(510px, 190px); }
    66% { transform: translate(430px, 300px); }
}

/* website */
.bs-strahl { fill: var(--b-glut); animation: bs-strahl 2.8s ease-in-out infinite alternate; }
@keyframes bs-strahl { to { transform: translateY(262px); } }
.bs-ampel { animation: bs-auftauchen 3.6s infinite both; animation-delay: calc(0.4s + var(--i, 0) * 0.5s); }
.bs-ampel.gut { fill: var(--b-gut); }
.bs-ampel.glut { fill: var(--b-glut); }
.bs-ampel.halt { fill: var(--b-halt); }

/* staffel */
.bs-stufe { fill: var(--b-flaeche-2); stroke: var(--b-navy); stroke-width: 3; transform-origin: 50% 100%; animation: bs-stufe 4s cubic-bezier(0.2, 0.8, 0.2, 1) infinite both; animation-delay: calc(var(--i, 0) * 0.15s); }
@keyframes bs-stufe { 0% { transform: scaleY(0); } 15%, 100% { transform: scaleY(1); } }
.bs-stufe.gewaehlt { fill: var(--b-glut); stroke: var(--b-glut-text); animation: bs-stufe 4s cubic-bezier(0.2, 0.8, 0.2, 1) infinite both, bs-gewaehlt 4s infinite; animation-delay: 0.15s, 0s; }
@keyframes bs-gewaehlt { 0%, 40% { fill: var(--b-flaeche-2); } 50%, 100% { fill: var(--b-glut); } }
.bs-wahl { animation: bs-spaet 4s infinite both; }

/* ansteht */
.bs-wehen { transform-origin: 0% 50%; animation: bs-wehen 2.4s ease-in-out infinite; }
@keyframes bs-wehen { 50% { transform: skewY(-6deg) scaleX(0.93); } }

/* akte */
.bs-mappe-hinten { fill: var(--b-flaeche-3); stroke: var(--b-navy); stroke-width: 4; }
.bs-mappe { transform-origin: 50% 100%; animation: bs-mappe 4s ease-in-out infinite; }
@keyframes bs-mappe { 0% { transform: scaleY(1); } 25%, 85% { transform: scaleY(0.82); } 100% { transform: scaleY(1); } }
.bs-steigen { animation: bs-steigen 4s cubic-bezier(0.2, 0.8, 0.2, 1) infinite both; animation-delay: calc(var(--i, 0) * 0.3s); }
@keyframes bs-steigen { 0% { transform: translateY(120px); opacity: 0; } 30%, 85% { transform: none; opacity: 1; } 100% { transform: none; opacity: 0; } }

/* frage */
.bs-welle { fill: none; stroke: var(--b-glut); stroke-width: 4; opacity: 0; animation: bs-welle 2.4s ease-out infinite; animation-delay: calc(var(--i, 0) * 1.2s); }
@keyframes bs-welle { 0% { transform: scale(0.7); opacity: 0.7; } 100% { transform: scale(1.3); opacity: 0; } }

/* glocke */
.bs-schwingen { transform-origin: 50% 0%; animation: bs-schwingen 1.6s ease-in-out infinite; }
@keyframes bs-schwingen { 0%, 100% { transform: rotate(-12deg); } 50% { transform: rotate(12deg); } }
.bs-schall { fill: none; stroke: var(--b-glut); stroke-width: 7; stroke-linecap: round; animation: bs-blinken 1.6s infinite; animation-delay: calc(var(--i, 0) * 0.3s); }

/* kette */
.bs-verbinder { fill: none; stroke: var(--b-navy); stroke-width: 8; stroke-linecap: round; }
.bs-knoten { fill: var(--b-flaeche-2); stroke: var(--b-glut); stroke-width: 5; animation: bs-knoten 3s infinite; animation-delay: calc(var(--i, 0) * 1s); }
@keyframes bs-knoten { 0%, 20% { fill: var(--b-glut); } 40%, 100% { fill: var(--b-flaeche-2); } }
.bs-impuls { fill: var(--b-glut); animation: bs-impuls 3s linear infinite; }
@keyframes bs-impuls { 0% { transform: none; opacity: 1; } 66% { transform: translateX(360px); opacity: 1; } 100% { transform: translateX(360px); opacity: 0; } }

/* werkzeug */
.bs-kabel { fill: none; stroke: var(--b-navy); stroke-width: 10; stroke-linecap: round; }
.bs-paket { fill: var(--b-glut); }
.bs-paket.hin { animation: bs-hin 1.8s linear infinite; }
.bs-paket.zurueck { fill: var(--b-gut); animation: bs-zurueck 1.8s linear 0.9s infinite; }
@keyframes bs-hin { to { transform: translateX(200px); } }
@keyframes bs-zurueck { to { transform: translateX(-200px); } }

/* warten */
.bs-sanduhr { animation: bs-sanduhr 3.2s ease-in-out infinite; }
@keyframes bs-sanduhr { 0%, 72% { transform: rotate(0); } 90%, 100% { transform: rotate(180deg); } }
.bs-glas { fill: var(--b-flaeche); stroke: var(--b-text); stroke-width: 5; }
.bs-sand { fill: var(--b-glut); }
.bs-sand.oben { transform-origin: 50% 100%; animation: bs-sand-oben 3.2s linear infinite; }
.bs-sand.unten { transform-origin: 50% 100%; animation: bs-sand-unten 3.2s linear infinite; }
@keyframes bs-sand-oben { 0% { transform: scaleY(1); } 70%, 100% { transform: scaleY(0.1); } }
@keyframes bs-sand-unten { 0% { transform: scaleY(0.1); } 70%, 100% { transform: scaleY(1); } }

/* fehler */
.bs-wackeln { transform-origin: 50% 100%; animation: bs-wackeln 3s ease-in-out infinite; }
@keyframes bs-wackeln {
    0%, 30%, 100% { transform: rotate(0); }
    5% { transform: rotate(-6deg); }
    10% { transform: rotate(6deg); }
    15% { transform: rotate(-4deg); }
    20% { transform: rotate(4deg); }
    25% { transform: rotate(-2deg); }
}

/* fertig */
.bs-kreis { fill: rgba(31, 154, 58, 0.08); stroke: var(--b-gut); stroke-width: 14; stroke-dasharray: 820; animation: bs-kreis 1s ease-out both; }
@keyframes bs-kreis { from { stroke-dashoffset: 820; } }
.bs-haken-strich.gross { animation: bs-ziehen-einmal 0.6s 0.7s ease-out both; }
@keyframes bs-ziehen-einmal { from { stroke-dashoffset: 200; } }
.bs-funke { fill: var(--b-glut); opacity: 0; animation: bs-funke 1.4s 0.6s ease-out both; animation-delay: calc(0.6s + var(--i, 0) * 0.03s); }
@keyframes bs-funke { from { transform: none; opacity: 1; } to { transform: translate(var(--fx, 0px), var(--fy, 0px)) scale(0.4); opacity: 0; } }

/* ----- DIE MAIL ZUR DURCHSICHT (Martin, 08.10.2026: „wenn gino fragt soll ich es so schicken, dass rechts dann das mail zur
   durchsicht offen ist … und es soll geil ausschauen“) -----
   Gesetzt wie eine Mail im Postfach: Kopf mit An und Betreff, darunter der Text, die Anhänge als Namen, die Antworten der Frage.
   Alles misst sich an der Szene (cqw/cqh); was auch klein nicht passt, läuft unten weich aus (`ueberlauf`) — kein Rollbalken. */
.bs-bild[data-bild="freigabe"]:has(.bs-mail) {
    padding: clamp(6px, 2.4cqh, 20px) clamp(8px, 3cqw, 32px);
}

.bs-bild:has(.bs-mail) .bs-marke {
    display: none;
}

.bs-mail {
    width: min(100%, 132cqh);
    height: 100%;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(31, 34, 64, .08), 0 14px 34px -18px rgba(31, 34, 64, .45);
    border-top: 4px solid var(--b-navy);
    overflow: hidden;
    color: var(--b-text);
    font-family: var(--b-schrift);
    animation: bs-mail-kommt .55s cubic-bezier(.2, .8, .2, 1) both;
}

@keyframes bs-mail-kommt {
    from { opacity: 0; transform: translateY(18px) scale(.98); }
}

.bs-mail-kopf {
    display: flex;
    align-items: center;
    gap: clamp(6px, 1.6cqw, 12px);
    padding: clamp(8px, 2.8cqh, 16px) clamp(12px, 3.4cqw, 26px) 0;
    color: var(--b-leise);
    font-size: clamp(11px, 3.2cqh, 16px);
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.bs-mail-marke {
    display: grid;
    place-items: center;
    width: clamp(22px, 6.4cqh, 34px);
    height: clamp(22px, 6.4cqh, 34px);
    border-radius: 50%;
    background: var(--b-flaeche-3);
    color: var(--b-navy);
}

.bs-mail-marke svg {
    width: 62%;
    height: 62%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linejoin: round;
}

.bs-mail-felder {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: clamp(2px, .8cqh, 6px) clamp(8px, 2cqw, 16px);
    margin: clamp(6px, 2cqh, 12px) 0 0;
    padding: 0 clamp(12px, 3.4cqw, 26px) clamp(8px, 2.6cqh, 14px);
    border-bottom: 1px solid #e6e7ee;
    font-size: clamp(13px, 4cqh, 21px);
    line-height: 1.35;
}

.bs-mail-felder dt {
    color: var(--b-leise);
}

.bs-mail-felder dd {
    margin: 0;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bs-mail-felder dd:last-child {
    color: var(--b-navy);
    font-weight: 600;
    white-space: normal;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.bs-mail-text {
    --mail-mass: 1;
    flex: 1;
    min-height: 0;
    overflow: hidden;
    padding: clamp(8px, 2.8cqh, 16px) clamp(12px, 3.4cqw, 26px) 0;
    font-size: calc(clamp(13px, 4.5cqh, 24px) * var(--mail-mass));
    line-height: 1.45;
}

.bs-mail-text p {
    margin: 0 0 .6em;
    white-space: pre-line;
}

.bs-mail-text.ueberlauf {
    -webkit-mask-image: linear-gradient(to bottom, #000 78%, transparent);
    mask-image: linear-gradient(to bottom, #000 78%, transparent);
}

.bs-mail-anhaenge,
.bs-mail-optionen {
    display: flex;
    flex-wrap: wrap;
    gap: clamp(6px, 1.4cqw, 10px);
    margin: 0;
    padding: clamp(6px, 2cqh, 12px) clamp(12px, 3.4cqw, 26px) 0;
    list-style: none;
}

.bs-mail-anhaenge li {
    display: inline-flex;
    align-items: center;
    gap: .45em;
    padding: .35em .8em .35em .55em;
    border: 1px solid #dcdfeb;
    border-radius: 6px;
    background: var(--b-flaeche-3);
    color: var(--b-navy);
    font-size: clamp(12px, 3.6cqh, 18px);
    font-weight: 600;
}

.bs-mail-anhaenge li::before {
    content: "";
    width: 1.1em;
    height: 1.3em;
    border-radius: 2px;
    background: var(--b-navy);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 24'%3E%3Cpath d='M2 1h11l5 5v17H2z'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 24'%3E%3Cpath d='M2 1h11l5 5v17H2z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.bs-mail-anhaenge li[data-art="pdf"]::before {
    background: #d3261d;
}

/* DAS ANGEBOT ZUM ANSEHEN (09.10.2026) — am Anhang ein Knopf in LIAs Orange; ein Klick legt das PDF über die rechte Hälfte. */
.bs-mail-ansehen {
    margin-left: .4em;
    padding: .2em .7em;
    border: 0;
    border-radius: 999px;
    background: var(--b-orange, #f07a12);
    color: #fff;
    font: inherit;
    font-size: .85em;
    cursor: pointer;
}

.buehne-rechts:has(> .bs-angebot) {
    position: relative;
}

.bs-angebot {
    position: fixed;
    inset: clamp(12px, 3vh, 40px) clamp(12px, 4vw, 80px);
    z-index: 60;
    display: flex;
    flex-direction: column;
    padding: clamp(8px, 1.4vh, 14px);
    border-radius: 14px;
    background: var(--b-flaeche-3, #f1f2f6);
    box-shadow: 0 12px 40px rgba(31, 34, 64, .25);
    animation: bs-angebot-auf .35s cubic-bezier(.2, .8, .2, 1) both;
}

.bs-angebot::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background: rgba(20, 22, 45, .45);
}

@keyframes bs-angebot-auf {
    from { opacity: 0; transform: translateY(12px); }
}

.bs-angebot iframe {
    flex: 1;
    width: 100%;
    border: 0;
    border-radius: 8px;
    background: #fff;
}

.bs-angebot-zu {
    align-self: flex-end;
    margin-bottom: 8px;
    padding: .35em 1em;
    border: 1px solid var(--b-navy, #2a2f5b);
    border-radius: 999px;
    background: #fff;
    color: var(--b-navy, #2a2f5b);
    font-weight: 600;
    cursor: pointer;
}

.bs-angebot-lade {
    margin: auto;
    color: var(--b-navy, #2a2f5b);
}

@media (prefers-reduced-motion: reduce) {
    .bs-angebot { animation: none; }
}

.bs-mail-optionen {
    padding-bottom: clamp(8px, 2.8cqh, 16px);
    border-top: 1px solid #eef0f5;
    margin-top: clamp(6px, 2cqh, 12px);
}

.bs-mail-optionen li {
    padding: .4em 1em;
    border: 1px solid var(--b-navy);
    border-radius: 999px;
    color: var(--b-navy);
    font-size: clamp(12px, 3.8cqh, 19px);
    font-weight: 600;
}

.bs-mail-optionen li.erste {
    background: var(--b-navy);
    color: #fff;
}

@media (prefers-reduced-motion: reduce) {
    .bs-mail { animation: none; }
}

/* ----- DIE DIAGRAMME (itm-541) -----
   Alles misst sich an der Szene (cqw/cqh): Auf dem Beamer ist sie gross, die Schrift wächst mit. */
.bs-diagramm {
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    gap: clamp(6px, 2.5cqh, 20px);
    padding: clamp(6px, 2cqh, 18px) clamp(8px, 2.5cqw, 30px);
    color: var(--b-text);
}

.bs-diagramm-kopf,
.bs-diagramm-fuss {
    margin: 0;
    color: var(--b-leise);
    font-size: clamp(13px, 4.2cqh, 24px);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bs-diagramm-fuss {
    text-align: right;
}

.bs-diagramm-flaeche {
    min-height: 0;
    min-width: 0;
}

@keyframes bs-einblenden {
    from { opacity: 0; transform: translateY(10px); }
}

/* DER QR-CODE DER SHOW (04.10.2026): links der Code, weiß hinterlegt, damit jedes Handy ihn liest; rechts die Nachrichten. */
.bs-qr {
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: clamp(10px, 3cqw, 36px);
    align-items: center;
    padding: clamp(6px, 2cqh, 18px) clamp(8px, 2.5cqw, 30px);
    color: var(--b-text);
}

.bs-qr-code {
    display: grid;
    justify-items: center;
    gap: clamp(4px, 1.5cqh, 12px);
    min-width: 0;
}

.bs-qr-code img {
    width: min(100%, 72cqh);
    aspect-ratio: 1;
    background: #fff;
    padding: clamp(6px, 2cqh, 16px);
    border-radius: 12px;
    box-shadow: 0 0 0 3px var(--b-glut);
}

.bs-qr-adresse {
    margin: 0;
    max-width: 100%;
    color: var(--b-leise);
    font-size: clamp(11px, 3.4cqh, 18px);
    overflow-wrap: anywhere;
    text-align: center;
}

.bs-qr-seite {
    min-width: 0;
    max-height: 100%;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: clamp(4px, 1.5cqh, 12px);
}

.bs-qr-kopf {
    margin: 0;
    color: var(--b-glut-text);
    font-size: clamp(13px, 4.2cqh, 24px);
    font-weight: 600;
}

.bs-qr-liste {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    align-content: start;
    gap: clamp(4px, 1.4cqh, 10px);
    overflow: hidden;
}

.bs-qr-liste li {
    padding: clamp(4px, 1.4cqh, 10px) clamp(8px, 1.6cqw, 14px);
    border-radius: 10px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    font-size: clamp(11px, 3.4cqh, 18px);
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.bs-qr-liste li strong {
    color: var(--b-glut-text);
    margin-right: 0.4em;
}

.bs-qr-liste li.leer {
    color: var(--b-leise);
    background: none;
    border-style: dashed;
}

.bs-qr-liste li.neu {
    animation: bs-qr-neu 2.4s ease-out;
}

@keyframes bs-qr-neu {
    0% { opacity: 0; transform: translateY(-8px); border-color: var(--b-glut); box-shadow: 0 0 0 3px var(--b-glut); }
    20% { opacity: 1; transform: none; }
    100% { border-color: var(--b-linie); box-shadow: none; }
}

/* DIE QR-KARTE (Martin, 10.10.2026): links der Code, davon ein Stamm, je Thema ein Ast mit den Nachrichten als Kärtchen —
   Vorname, wie es klingt, ein Lächeln in drei Stufen, in wenigen Worten der Inhalt. Linien Navy, der Code und das Neue Orange.
   Eine neue Nachricht zieht zuerst ihre Linie, dann erscheint das Kärtchen. */
.bs-qk {
    --qk-linie: rgba(41, 45, 91, 0.55);
    --qk-dicke: 2px;
    --qk-stamm: clamp(14px, 3cqw, 34px);
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: minmax(0, 0.42fr) minmax(0, 1.58fr);
    /* EINE ZEILE IN DER HÖHE DER FLÄCHE (13.10.2026): Sonst wuchs sie mit den Ästen, und der Code rutschte aus dem Bild. */
    grid-template-rows: minmax(0, 1fr);
    align-items: center;
    padding: clamp(6px, 2cqh, 18px) clamp(8px, 2.5cqw, 30px);
    color: var(--b-text);
}

.bs-qk-code {
    position: relative;
    display: grid;
    justify-items: center;
    gap: clamp(3px, 1cqh, 8px);
    min-width: 0;
}

.bs-qk-code img {
    width: min(100%, 46cqh);
    aspect-ratio: 1;
    background: #fff;
    padding: clamp(5px, 1.6cqh, 12px);
    border-radius: 14px;
    box-shadow: 0 0 0 3px var(--b-glut), 0 10px 28px rgba(240, 138, 28, 0.18);
}

/* DIE LINIE VOM CODE ZUM STAMM. */
.bs-qk-code::after {
    content: "";
    position: absolute;
    top: calc(min(100%, 46cqh) / 2);
    left: calc(50% + min(100%, 46cqh) / 2 + 3px);
    right: calc(-1 * var(--qk-stamm));
    height: var(--qk-dicke);
    background: var(--qk-linie);
}

.bs-qk-adresse,
.bs-qk-zahl {
    margin: 0;
    max-width: 100%;
    text-align: center;
    overflow-wrap: anywhere;
}

.bs-qk-adresse { color: var(--b-leise); font-size: clamp(10px, 2.8cqh, 15px); }
.bs-qk-zahl { color: var(--b-glut-text); font-size: clamp(12px, 3.6cqh, 20px); font-weight: 700; }

.bs-qk-aeste {
    position: relative;
    display: grid;
    align-content: center;
    gap: clamp(6px, 2.2cqh, 18px);
    max-height: 100%;
    margin-left: var(--qk-stamm);
    padding-left: var(--qk-stamm);
    border-left: var(--qk-dicke) solid var(--qk-linie);
    min-width: 0;
    overflow: hidden;
}

.bs-qk-aeste.leer { border-left-style: dashed; }

/* DIE ENGE STUFE (13.10.2026, viele Nachrichten auf schmaler Bühne): ein Kärtchen je Ast, „+N" daneben, der Inhalt einzeilig. */
.bs-qk-aeste.eng .bs-qk-karten { flex-wrap: nowrap; }
.bs-qk-aeste.eng .bs-qk-karte { flex: 0 1 auto; }
.bs-qk-aeste.eng .bs-qk-kurz { -webkit-line-clamp: 1; }
.bs-qk-aeste.eng .bs-qk-ast { grid-template-columns: minmax(0, max-content) minmax(10em, 1fr); }
.bs-qk-aeste.eng .bs-qk-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.bs-qk-aeste.eng .bs-qk-stimmung { display: none; }
.bs-qk-mehr { flex: none; }

.bs-qk-leer {
    margin: 0;
    color: var(--b-leise);
    font-size: clamp(12px, 3.6cqh, 20px);
}

.bs-qk-ast {
    position: relative;
    display: grid;
    grid-template-columns: minmax(7em, auto) minmax(0, 1fr);
    align-items: center;
    gap: clamp(8px, 1.6cqw, 18px);
    min-width: 0;
}

/* DER AST VOM STAMM ZUM THEMA. */
.bs-qk-ast::before {
    content: "";
    position: absolute;
    left: calc(-1 * var(--qk-stamm));
    width: var(--qk-stamm);
    top: 50%;
    height: var(--qk-dicke);
    background: var(--qk-linie);
    transform-origin: left center;
}

.bs-qk-name {
    position: relative;
    padding: 0.3em 0.8em;
    border-radius: 999px;
    background: var(--b-navy);
    color: #fff;
    font-size: clamp(11px, 3.2cqh, 17px);
    font-weight: 700;
    white-space: nowrap;
}

/* DIE LINIE VOM THEMA DURCH DIE KÄRTCHEN. */
.bs-qk-karten {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: clamp(6px, 1.2cqw, 14px);
    min-width: 0;
}

.bs-qk-karten::before {
    content: "";
    position: absolute;
    left: calc(-1 * clamp(8px, 1.6cqw, 18px));
    right: 0;
    top: 50%;
    height: var(--qk-dicke);
    background: var(--qk-linie);
    opacity: 0.6;
    z-index: 0;
}

.bs-qk-karte {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 0.2em;
    min-width: 0;
    max-width: clamp(140px, 30cqw, 280px);
    padding: clamp(5px, 1.4cqh, 10px) clamp(8px, 1.4cqw, 14px);
    border-radius: 12px;
    background: var(--b-flaeche, #fff);
    border: 1px solid var(--b-linie);
    box-shadow: 0 6px 18px rgba(31, 34, 64, 0.08);
}

.bs-qk-kopf {
    display: flex;
    align-items: center;
    gap: 0.45em;
    min-width: 0;
    font-size: clamp(12px, 3.4cqh, 18px);
}

.bs-qk-kopf strong {
    color: var(--b-navy);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bs-qk-stimmung {
    color: #5866d6;
    font-size: 0.72em;
    font-weight: 600;
}

.bs-qk-laune { display: inline-flex; margin-left: auto; }

.bs-qk-laune svg {
    width: 1.25em;
    height: 1.25em;
    fill: none;
    stroke: #2fae76;
    stroke-width: 1.8;
    stroke-linecap: round;
}

.bs-qk-laune .auge { fill: #2fae76; stroke: none; }
.bs-qk-laune[data-laune="3"] .mund { fill: rgba(47, 174, 118, 0.25); }

.bs-qk-kurz {
    margin: 0;
    color: var(--b-text);
    font-size: clamp(11px, 3cqh, 16px);
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.bs-qk-mehr {
    position: relative;
    z-index: 1;
    padding: 0.2em 0.6em;
    border-radius: 999px;
    background: var(--b-flaeche-3, #eef0f5);
    color: var(--b-leise);
    font-size: clamp(11px, 3cqh, 15px);
    font-weight: 700;
}

/* NEU: erst die Linie, dann das Kärtchen — und es leuchtet einmal orange. */
.bs-qk-ast.neu::before { animation: bs-qk-linie 0.7s ease-out both; }
.bs-qk-ast.neu .bs-qk-name { animation: bs-qk-auf 0.5s 0.5s ease-out both; }
.bs-qk-karte.neu { animation: bs-qk-auf 0.5s 0.7s ease-out both, bs-qk-glut 2.6s 1.2s ease-out both; }

@keyframes bs-qk-linie { from { transform: scaleX(0); } }
@keyframes bs-qk-auf { from { opacity: 0; transform: translateX(-10px) scale(0.96); } }
@keyframes bs-qk-glut {
    0% { border-color: var(--b-glut); box-shadow: 0 0 0 3px rgba(240, 138, 28, 0.35), 0 6px 18px rgba(31, 34, 64, 0.08); }
    100% { border-color: var(--b-linie); box-shadow: 0 6px 18px rgba(31, 34, 64, 0.08); }
}

@media (prefers-reduced-motion: reduce) {
    .bs-qk-ast.neu::before, .bs-qk-ast.neu .bs-qk-name, .bs-qk-karte.neu { animation: none; }
}

/* WAS LIA GERADE GEDACHT HAT (itm-589): der Satz, die Entscheidung groß, die Sicherheit als Balken mit der Schwelle als
   Strich, darunter wer entschied und warum. */
.bs-gd {
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr);
    align-content: center;
    gap: clamp(6px, 2.4cqh, 20px);
    padding: clamp(6px, 2cqh, 18px) clamp(10px, 3cqw, 36px);
    color: var(--b-text);
}

.bs-gd-satz {
    margin: 0;
    color: var(--b-leise);
    font-size: clamp(12px, 3.8cqh, 20px);
    font-style: italic;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.bs-gd-haupt {
    display: grid;
    gap: clamp(3px, 1.2cqh, 10px);
    padding: clamp(8px, 2.4cqh, 20px) clamp(10px, 2.4cqw, 24px);
    border-radius: 14px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    border-left: 5px solid var(--b-glut);
    animation: bs-einblenden 0.5s ease-out;
}

.bs-gd-haupt[data-entscheid="nachfragen"] { border-left-color: #e0a83a; }
.bs-gd-haupt[data-entscheid="keiner"],
.bs-gd-haupt[data-entscheid="gespraech"],
.bs-gd-haupt[data-entscheid="nachsehen"],
.bs-gd-haupt[data-entscheid="regel"] { border-left-color: var(--b-leise); }

.bs-gd-entscheid {
    margin: 0;
    font-size: clamp(16px, 6.4cqh, 38px);
    font-weight: 700;
    line-height: 1.1;
}

.bs-gd-ablauf {
    margin: 0;
    color: var(--b-glut-text);
    font-size: clamp(13px, 4.6cqh, 26px);
    font-weight: 600;
}

.bs-gd-zeile {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: clamp(6px, 1.6cqw, 16px);
}

.bs-gd-zahl {
    font-size: clamp(14px, 5cqh, 28px);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.bs-gd-balken {
    position: relative;
    height: clamp(8px, 2.6cqh, 16px);
    border-radius: 999px;
    background: var(--b-linie);
    overflow: visible;
}

.bs-gd-fuell {
    position: absolute;
    inset: 0 auto 0 0;
    border-radius: inherit;
    background: var(--b-glut);
    animation: bs-gd-fuellen 1.1s ease-out;
}

.bs-gd-haupt[data-entscheid="nachfragen"] .bs-gd-fuell { background: #e0a83a; }

.bs-gd-schwelle {
    position: absolute;
    top: -30%;
    bottom: -30%;
    width: 3px;
    margin-left: -1.5px;
    border-radius: 2px;
    background: var(--b-text);
}

@keyframes bs-gd-fuellen {
    from { width: 0; }
}

.bs-gd-leise {
    margin: 0;
    color: var(--b-leise);
    font-size: clamp(10px, 3cqh, 15px);
}

.bs-gd-fakten {
    margin: 0;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-content: start;
    gap: clamp(3px, 1cqh, 8px) clamp(8px, 1.6cqw, 16px);
    font-size: clamp(11px, 3.4cqh, 18px);
    line-height: 1.3;
    overflow: hidden;
}

.bs-gd-fakten dt {
    color: var(--b-leise);
}

.bs-gd-fakten dd {
    margin: 0;
}

@media (prefers-reduced-motion: reduce) {
    .bs-gd-haupt,
    .bs-gd-fuell { animation: none; }
}

@media (prefers-reduced-motion: reduce) {
    .bs-qr-liste li.neu {
        animation: none;
        border-color: var(--b-glut);
    }
}

/* kpi */
.kpi .bs-diagramm-flaeche {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-rows: minmax(0, 62cqh);
    align-content: center;
    gap: clamp(8px, 2.4cqw, 26px);
}

.kpi .bs-diagramm-flaeche[data-n="1"] { grid-template-columns: minmax(0, 1fr); }
.kpi .bs-diagramm-flaeche[data-n="2"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.kpi .bs-diagramm-flaeche[data-n="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kpi .bs-diagramm-flaeche[data-n="5"], .kpi .bs-diagramm-flaeche[data-n="6"] { --zahl-h: 11cqh; }

/* ZWEI REIHEN TEILEN SICH DIE HÖHE (itm-711, Martin 07.10.2026: „die Zahlen und Felder sind so groß, dass sie nicht alle auf den
   Bildschirm passen"). Jede Reihe war 62 % hoch — bei fünf Kacheln stand die zweite Reihe halb unter dem Rand. */
.kpi .bs-diagramm-flaeche[data-n="5"],
.kpi .bs-diagramm-flaeche[data-n="6"] {
    grid-auto-rows: minmax(0, 1fr);
    align-content: stretch;
    --zahl-h: 9cqh;
}

/* DIE KACHEL DER KONSOLE heisst auch `.kpi` — ihr weisser Grund, Rahmen und Innenabstand gehören nicht auf die Bühne. */
.bs-diagramm.kpi {
    background: none;
    border: 0;
    border-radius: 0;
}

.bs-diagramm.kpi:hover {
    border-color: transparent;
}

/* VIER KACHELN IN EINER SCHMALEN SZENE stehen zu zweit übereinander, statt ihre Beschriftung zu kürzen. */
@container (max-width: 760px) {
    .kpi .bs-diagramm-flaeche[data-n="4"] { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: minmax(0, 1fr); align-content: stretch; --zahl-h: 10cqh; }
}

.bs-kachel {
    display: grid;
    align-content: center;
    justify-items: center;
    gap: 0.2em;
    min-width: 0;
    min-height: 0;
    padding: clamp(8px, 3cqh, 24px) 10px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    text-align: center;
    animation: bs-einblenden 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) both;
    animation-delay: calc(var(--i, 0) * 120ms);
}

.bs-kachel-zahl {
    font-size: clamp(30px, min(var(--zahl-h, 16cqh), 8.5cqw), 128px);
    font-weight: 300;
    line-height: 1;
    color: var(--b-navy);
    font-variant-numeric: tabular-nums;
}

.bs-kachel-einheit {
    font-size: clamp(13px, 3.8cqh, 22px);
    color: var(--b-leise);
}

.bs-kachel-einheit:empty {
    display: none;
}

.bs-kachel-label {
    max-width: 100%;
    font-size: clamp(15px, min(5cqh, 2.3cqw), 30px);
    font-weight: 600;
    line-height: 1.2;
    hyphens: auto;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    overflow-wrap: anywhere;
}

/* balken */
.balken .bs-diagramm-flaeche {
    display: grid;
    grid-template-rows: repeat(var(--n, 1), minmax(0, 1fr));
    gap: clamp(4px, 1.4cqh, 12px);
}

.bs-zeile-balken {
    display: grid;
    grid-template-columns: minmax(0, 32%) minmax(0, 1fr) auto;
    align-items: center;
    gap: clamp(8px, 2cqw, 20px);
    min-height: 0;
    font-size: clamp(13px, min(var(--zeile-h, 6cqh), 3.2cqw), 30px);
    animation: bs-einblenden 0.5s ease-out both;
    animation-delay: calc(var(--i, 0) * 90ms);
}

.bs-zeile-balken .bs-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: right;
}

.bs-spur {
    height: 72%;
    max-height: 46px;
    min-height: 8px;
    border-radius: 999px;
    background: var(--b-flaeche-3);
    overflow: hidden;
}

.bs-balken {
    width: calc(var(--anteil, 0) * 100%);
    min-width: 4px;
    height: 100%;
    border-radius: 999px;
    background: var(--b-navy);
    transform-origin: 0% 50%;
    animation: bs-balken 1s cubic-bezier(0.2, 0.8, 0.2, 1) both;
    animation-delay: calc(0.15s + var(--i, 0) * 90ms);
}

.bs-balken.spitze,
.bs-saeule.spitze {
    background: var(--b-glut);
}

@keyframes bs-balken {
    from { transform: scaleX(0); }
}

.bs-wert {
    min-width: 2ch;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

/* verlauf */
.verlauf .bs-diagramm-flaeche {
    display: grid;
    grid-template-columns: repeat(var(--n, 1), minmax(0, 1fr));
    gap: clamp(3px, 1cqw, 14px);
    border-bottom: 2px solid var(--b-linie);
}

.bs-spalte {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr) auto;
    justify-items: center;
    gap: 4px;
    min-width: 0;
    min-height: 0;
}

.bs-spalte .bs-wert {
    font-size: clamp(12px, min(4.6cqh, 2.6cqw), 26px);
    white-space: nowrap;
    text-align: center;
}

.bs-spalte .bs-label {
    font-size: clamp(11px, min(3.8cqh, 2.1cqw), 20px);
    color: var(--b-leise);
    white-space: nowrap;
}

/* AUSGEDÜNNT, NICHT ÜBERLAGERT: Was keine Beschriftung trägt, hält trotzdem seinen Platz, und eine
   Beschriftung darf in die leeren Nachbarspalten ragen — lia-buehne.js sorgt dafür, dass dort keine
   andere steht. */
.bs-spalte .still {
    visibility: hidden;
}

.bs-saeulenplatz {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    width: 100%;
    min-height: 0;
}

.bs-saeule {
    width: min(100%, 64px);
    height: calc(var(--anteil, 0) * 100%);
    min-height: 3px;
    border-radius: 10px 10px 3px 3px;
    background: var(--b-navy);
    transform-origin: 50% 100%;
    animation: bs-saeule 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) both;
    animation-delay: calc(0.15s + var(--i, 0) * 45ms);
}

.bs-saeule.spitze {
    background: var(--b-glut);
}

@keyframes bs-saeule {
    from { transform: scaleY(0); }
}

/* WENIGER BEWEGUNG: dieselben Bilder, still; Szenen blenden nur über. Klar bleibt es trotzdem —
   jedes Bild zeigt in Ruhe, was es bedeutet, und der Titel darunter sagt es in Worten. */
@media (prefers-reduced-motion: reduce) {
    .buehne-szene *,
    .buehne-schritt.aktiv .punkt,
    .buehne-titel.neu {
        animation: none !important;
    }

    .buehne-szene .bs-bild.kommt {
        animation: bs-blende 0.5s ease-out both !important;
    }

    .buehne-szene .bs-bild.geht {
        animation: bs-geht 0.4s ease-in both !important;
    }

    .bs-funke {
        display: none;
    }

    .bs-marke {
        transition: opacity 0.3s;
    }
}

.lia-zur-buehne {
    position: absolute;
    top: var(--s3);
    left: var(--s3);
}

/* DIE GRUPPENZEILE DER THEMENSEITE (03.10.2026): Compliance-Themen und Allgemein. */
table.liste tr.gruppe th {
    padding-top: 18px;
    font-size: 13px;
    font-weight: 600;
    text-align: left;
    border-bottom: 1px solid var(--line, #e5e7eb);
}

table.liste tr.gruppe th .help {
    display: block;
    margin-top: 2px;
    font-weight: 400;
}

/* DIE KLAMMER DARÜBER FEHLTE seit dem Zusammenführen des technischen Mitschnitts (64a1646b7, gefunden am 05.10.2026):
   Alles danach — Mitschnitt, Modellvergleich, Ticketsystem — stand verschachtelt in dieser einen Regel und galt
   nirgends sonst. */

/* ===== DER TECHNISCHE MITSCHNITT (Wunsch von Martin, 03.10.2026) =====

   Je Aufruf eine zugeklappte Karte: oben die Zeile, nach der man sucht (wann, wohin, was,
   ob es ging), darunter Anfrage und Antwort. Die Zeile bricht um statt zu scrollen — auf einem
   schmalen Fenster ist der Vorgang wichtiger als eine gerade Kante. */
details.technik-zeile {
    margin-bottom: var(--s2);
}

details.technik-zeile > summary {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: var(--s2) var(--s3);
    cursor: pointer;
}

details.technik-zeile .richtung {
    font-size: var(--t-xs);
    color: var(--ink-3);
    white-space: nowrap;
}

details.technik-zeile .mono,
pre.chunk.json {
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}

dl.technik-angaben {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: var(--s1) var(--s3);
    margin: var(--s3) 0;
}

dl.technik-angaben dt {
    color: var(--ink-3);
}

dl.technik-angaben dd {
    margin: 0;
    overflow-wrap: anywhere;
}

.nutzdaten {
    margin-top: var(--s3);
}

.nutzdaten .kopfzeile {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: var(--s3);
}

.nutzdaten h3 {
    margin: 0;
}

pre.chunk.json {
    font-size: var(--t-xs);
    max-height: 32em;
}

/* MCP AUSGEPACKT (Wunsch von Martin, 05.10.2026): die Argumente in der Zeile, einzeilig und
   abgeschnitten — wer mehr will, klappt auf. */
details.technik-zeile .technik-kurz {
    font-size: var(--t-xs);
    color: var(--ink-3);
    max-width: 60ch;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nutzdaten.mcp h4 {
    margin: var(--s2) 0 0;
    font-size: var(--t-sm);
}

/* ----- DAS FINALE „FEIERABEND" (itm-557) -----
   Dieselbe Regel wie bei allen Szenen: Die Ruhelage ist ein sinnvolles Standbild, und wer
   „weniger Bewegung" eingestellt hat, sieht es still (`.buehne-szene *` oben). */
.bs-fe-flug { animation: bs-fe-flug 2.8s cubic-bezier(0.3, 0.7, 0.2, 1) infinite both; animation-delay: calc(var(--i, 0) * 0.45s); }
@keyframes bs-fe-flug {
    0% { transform: none; opacity: 0; }
    10% { opacity: 1; }
    70% { transform: translate(470px, -170px) rotate(-14deg) scale(0.55); opacity: 1; }
    100% { transform: translate(520px, -200px) rotate(-18deg) scale(0.4); opacity: 0; }
}

.bs-fe-null { font-size: 150px; fill: var(--b-gut, #3fb27f); animation: bs-auftauchen 3.4s ease-out infinite both; }
.bs-fe-funke { fill: var(--b-glut, #f07a12); animation: bs-fe-funke 1.6s ease-out infinite; animation-delay: calc(var(--i, 0) * 0.18s); }
@keyframes bs-fe-funke { 0% { transform: scale(0.2); opacity: 0; } 30% { opacity: 1; } 100% { transform: scale(1.6); opacity: 0; } }

.bs-fe-strasse { fill: #3a4478; }
.bs-fe-mittellinie { fill: var(--b-text, #f3f4fa); opacity: 0.35; stroke-dasharray: 30 24; }
.bs-fe-fenster { fill: #9fb4ff; opacity: 0.85; }
.bs-fe-reifen { fill: #1b2048; stroke: #3a4478; stroke-width: 4; }
.bs-fe-dutt { fill: none; stroke: var(--b-text, #f3f4fa); stroke-width: 6; stroke-linecap: round; }
.bs-fe-fahren { animation: bs-fe-fahren 3.4s ease-in-out infinite both; }
@keyframes bs-fe-fahren { 0% { transform: translateX(-420px); } 40%, 60% { transform: none; } 100% { transform: translateX(560px); } }
.bs-fe-rad { transform-box: fill-box; transform-origin: center; animation: bs-dreh 0.6s linear infinite; }

.bs-fe-stiel { fill: none; stroke: var(--b-gut, #3fb27f); stroke-width: 7; stroke-linecap: round; stroke-dasharray: 260; animation: bs-fe-wachsen 3.4s ease-out infinite both; }
@keyframes bs-fe-wachsen { 0% { stroke-dashoffset: 260; } 35%, 100% { stroke-dashoffset: 0; } }
.bs-fe-blatt { fill: #ff7aa8; }
.bs-fe-blatt.zwei { fill: #ffd166; }
.bs-fe-ploppen { animation: bs-fe-ploppen 3.4s ease-out infinite both; animation-delay: calc(0.6s + var(--i, 0) * 0.16s); }
@keyframes bs-fe-ploppen { 0% { transform: scale(0); } 20% { transform: scale(1.15); } 28%, 100% { transform: scale(1); } }

.bs-fe-wasser { fill: #4fa8ff; opacity: 0.75; }
.bs-fe-blase { fill: var(--b-text, #f3f4fa); opacity: 0.8; animation: bs-fe-blase 1.8s ease-in infinite; animation-delay: calc(var(--i, 0) * -0.23s); }
@keyframes bs-fe-blase { 0% { transform: none; opacity: 0.9; } 100% { transform: translateY(-46px) scale(0.5); opacity: 0; } }
.bs-fe-dampf { fill: none; stroke: var(--b-text, #f3f4fa); stroke-width: 6; stroke-linecap: round; opacity: 0.45; animation: bs-fe-dampf 3s ease-in-out infinite; animation-delay: calc(var(--i, 0) * -1s); }
@keyframes bs-fe-dampf { 0% { transform: translateY(20px); opacity: 0; } 40% { opacity: 0.5; } 100% { transform: translateY(-30px); opacity: 0; } }
.bs-fe-quecksilber { fill: var(--b-glut, #f07a12); transform-box: fill-box; transform-origin: 50% 100%; animation: bs-fe-steigen 3.4s ease-out infinite both; }
@keyframes bs-fe-steigen { 0% { transform: scaleY(0.12); } 60%, 100% { transform: scaleY(0.8); } }

.bs-fe-herz { fill: #ff7aa8; animation: bs-fe-herz 3s ease-out infinite; animation-delay: calc(var(--i, 0) * 0.35s); }
@keyframes bs-fe-herz { 0% { transform: translateY(40px) scale(0.6); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateY(-160px) scale(1.1); opacity: 0; } }

/* ----- AUFGABEN ALS BOARD (itm-554) — Spalten nach Fälligkeit, Karten mit Haken. ----- */
.auf-kopf { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--s4); flex-wrap: wrap; margin-bottom: var(--s4); }
.auf-kopf h1 { margin: 0; }
.auf-umschalter > a { padding: 6px 14px; border-radius: var(--r-sm); color: var(--ink-2); text-decoration: none; font-weight: 600; }
.auf-umschalter > a.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-xs); }

.auf-neu { display: flex; align-items: center; gap: var(--s3); flex-wrap: wrap; padding: var(--s3) var(--s4); }
.auf-neu .field { margin: 0; }
.auf-neu-titel { flex: 1 1 260px; }
.auf-neu-titel input { width: 100%; font-size: 1.05em; }

.auf-board { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s4); align-items: start; margin: var(--s4) 0; }
@media (max-width: 1100px) { .auf-board { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .auf-board { grid-template-columns: minmax(0, 1fr); } }

.auf-spalte { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s3); min-height: 120px; }
.auf-spalte h2 { display: flex; align-items: center; gap: var(--s2); font-size: 1rem; margin: 0 0 var(--s3); }
.auf-spalte.ueber h2 { color: var(--stop); }
.auf-spalte.heute h2 { color: var(--accent-ink); }
.auf-zahl { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: var(--r-full); background: var(--surface); color: var(--ink-2); font-size: 0.8rem; }
.auf-leer { margin: var(--s2) 0; }

.auf-karte { display: flex; gap: var(--s3); align-items: flex-start; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: var(--s3); margin-bottom: var(--s2); box-shadow: var(--shadow-xs); transition: transform 0.15s var(--ease), box-shadow 0.15s var(--ease); }
.auf-karte:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.auf-spalte.ueber .auf-karte { border-left: 4px solid var(--stop); }
.auf-spalte.heute .auf-karte { border-left: 4px solid var(--accent); }
.auf-karte form { margin: 0; }
.auf-inhalt { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.auf-inhalt b { overflow-wrap: anywhere; }
.auf-meta { display: flex; flex-wrap: wrap; gap: 6px; font-size: 0.82rem; }
.auf-datum, .auf-firma, .auf-herkunft { padding: 2px 8px; border-radius: var(--r-full); background: var(--surface-2); color: var(--ink-2); text-decoration: none; }
.auf-datum.warn { background: var(--stop-soft); color: var(--stop); }
.auf-datum.heute { background: var(--accent-soft); color: var(--accent-ink); }
.auf-firma:hover { background: var(--hover); }

.auf-haken { width: 24px; height: 24px; min-height: 0; padding: 0; flex: none; border-radius: var(--r-full); border: 2px solid var(--border-strong); background: var(--surface); cursor: pointer; position: relative; }
.auf-haken:hover, .auf-haken:focus-visible { border-color: var(--ok); }
.auf-haken:hover::after, .auf-haken.an::after { content: ""; position: absolute; left: 6px; top: 2px; width: 6px; height: 11px; border: solid var(--ok); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.auf-haken.an { background: var(--ok-soft); border-color: var(--ok); }

.auf-liste { list-style: none; padding: 0; margin: 0; }
.auf-karte.fertig { opacity: 0.7; box-shadow: none; }
.auf-erledigt summary { cursor: pointer; }

/* ----- POSTFACH DREISPALTIG (itm-554) — Ordner · Gespräche · Lesen, wie ein Mail-Programm. ----- */
.pf-app { display: grid; grid-template-columns: 220px minmax(280px, 380px) minmax(0, 1fr); gap: var(--s4); align-items: start; }
.pf-app > .card { margin: 0; }
@media (max-width: 1200px) { .pf-app { grid-template-columns: 200px minmax(0, 1fr); } .pf-lesen { grid-column: 1 / -1; } }
@media (max-width: 760px) {
    .pf-app { grid-template-columns: minmax(0, 1fr); }
    .pf-app.mit-faden .pf-liste, .pf-app.mit-faden .pf-ordner { display: none; }
}

.pf-ordner { position: sticky; top: var(--s4); display: flex; flex-direction: column; gap: var(--s4); }
.pf-ordnerliste { display: flex; flex-direction: column; gap: 2px; }
.pf-ordnerliste a { display: flex; align-items: center; gap: var(--s2); padding: 8px 10px; border-radius: var(--r-md); color: var(--ink-2); text-decoration: none; font-weight: 600; }
.pf-ordnerliste a:hover { background: var(--hover); }
.pf-ordnerliste a.on { background: var(--accent-soft); color: var(--accent-ink); }
.pf-ordnerliste .n { margin-left: auto; min-width: 22px; text-align: center; padding: 0 6px; border-radius: var(--r-full); background: var(--surface-2); font-size: 0.8rem; }
.pf-ordnerliste .es-symbol { width: 22px; height: 22px; }
.pf-aktionen { display: flex; flex-direction: column; gap: var(--s2); }
.pf-aktionen form, .pf-aktionen button { width: 100%; margin: 0; }
.pf-filter { display: grid; gap: 6px; }
.pf-stand { margin: 0; }

.pf-liste { padding: var(--s2); max-height: calc(100vh - 140px); overflow-y: auto; }
.pf-meldung, .pf-leer { padding: var(--s3); margin: 0; }
.pf-zeile { display: flex; gap: var(--s3); align-items: flex-start; padding: var(--s3); border-radius: var(--r-md); color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line-soft); }
.pf-zeile:hover { background: var(--hover); }
.pf-zeile.aktiv { background: var(--accent-soft); box-shadow: inset 3px 0 0 var(--accent); }
.pf-zeile.erledigt { opacity: 0.72; }
.pf-zeile.ungelesen .pf-betreff { font-weight: 700; }
.pf-avatar { flex: none; display: grid; place-items: center; width: 38px; height: 38px; border-radius: var(--r-full); background: var(--navy-soft); color: var(--navy); font-weight: 700; font-size: 0.85rem; }
.pf-avatar.dringend { background: var(--stop-soft); color: var(--stop); }
.pf-zeile-text { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 3px; }
.pf-zeile-oben { display: flex; justify-content: space-between; gap: var(--s2); }
.pf-zeile-oben b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pf-zeile-oben time { flex: none; font-size: 0.8rem; color: var(--ink-muted); }
.pf-betreff, .pf-vorschau { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pf-vorschau { font-size: 0.85rem; color: var(--ink-muted); }
.pf-marken { display: flex; flex-wrap: wrap; gap: 4px; font-size: 0.78rem; }

.pf-lesen { min-width: 0; display: flex; flex-direction: column; gap: var(--s4); }
.pf-lesen > .card { margin: 0; }
.pf-zurueck { display: none; align-self: flex-start; }
@media (max-width: 760px) { .pf-zurueck { display: inline-flex; } }
.pf-nichts { text-align: center; padding: var(--s12) var(--s6); }
.pf-nichts .es-symbol { width: 48px; height: 48px; margin: 0 auto var(--s3); }

.pf-faden { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: var(--s3); }
.pf-faden .mail { display: flex; }
.pf-faden .mail.aus { justify-content: flex-end; }
.pf-blase { max-width: 88%; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s3) var(--s4); box-shadow: var(--shadow-xs); }
.pf-faden .mail.aus .pf-blase { background: var(--accent-soft); border-color: transparent; }
.pf-blase .help { margin: 0 0 var(--s2); }
.pf-blase .mailtext { margin: 0; white-space: pre-wrap; font: inherit; }
.pf-antwort { position: relative; }

/* ----- VORSCHLÄGE ALS ARBEITSLISTE (itm-555) ----- */
.vs-filter { display: flex; flex-direction: column; gap: var(--s2); margin: var(--s3) 0 var(--s4); }
.vs-filter .chip.vs-abgelesen.on { background: var(--ok-soft); color: var(--ok); }
.vs-filter .chip.vs-vermutet.on { background: var(--stop-soft); color: var(--stop); }
.card.vorschlaege .quelle form { margin: 0 0 0 auto; }
.card.vorschlaege .vorschlag { border-left: 4px solid transparent; padding-left: var(--s3); border-radius: var(--r-sm); transition: background 0.15s var(--ease); }
.card.vorschlaege .vorschlag:hover { background: var(--hover); }
.card.vorschlaege .vorschlag.vs-abgelesen { border-left-color: var(--ok); }
.card.vorschlaege .vorschlag.vs-geschlossen { border-left-color: var(--accent); }
.card.vorschlaege .vorschlag.vs-vermutet { border-left-color: var(--stop); }
.card.vorschlaege .was { flex-wrap: wrap; }
.card.vorschlaege .bisher { font-size: var(--t-sm, 0.85rem); color: var(--ink-muted); text-decoration: line-through; text-decoration-color: var(--ink-faint); }
.card.vorschlaege .bisher.leer { text-decoration: none; color: var(--ink-faint); }
/* VORSCHLÄGE: beschriftete Filterzeilen und die Quelle als Link in der Ansicht nach Feld (29.10.2026). */
.vs-filter .vs-zeile { display: flex; align-items: center; gap: var(--s3); flex-wrap: wrap; }
.vs-filter .chips { margin: 0; }
.vs-filter .vs-titel { min-width: 6.5rem; font-size: var(--t-sm, 0.85rem); color: var(--ink-muted); }
.card.vorschlaege .quelle-link { color: inherit; text-decoration: none; }
.card.vorschlaege .quelle-link:hover strong { text-decoration: underline; }

/* ALTUNTERLAGEN ABLEGEN (itm-553): der Knopf neben „Senden", und das Fenster zeigt, wohin man zieht. */
.lia-ablegen {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    cursor: pointer;
    font-size: 17px;
}

.lia-ablegen:focus-within {
    outline: 2px solid var(--accent, #E8870C);
    outline-offset: 2px;
}

.lia-gespraech[data-ziehen] {
    outline: 2px dashed var(--accent, #E8870C);
    outline-offset: -6px;
}

/* DAS PROTOKOLL (itm-571) steht neben „Neu" — auf der Bühne in der Leiste, dort gilt `.buehne .lia-neu`. */
.lia-gegenueber .lia-protokoll {
    position: absolute;
    top: var(--s3);
    right: calc(var(--s3) + 64px);
}

/* AUF DER BÜHNE steht es in der Zeile mit LIA (itm-722), nicht über ihr. */
.buehne .lia-gegenueber .lia-protokoll {
    position: static;
}

/* DIE SHOW MIT PUBLIKUM (itm-578): QR-Code neben der Gästeadresse, die Nachrichten als Liste. */
.show-qr {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s3);
    align-items: flex-start;
    margin: var(--s2) 0;
}

.show-qr img {
    background: #fff;
    padding: 8px;
    border-radius: 8px;
    max-width: 100%;
    height: auto;
}

.show-qr code {
    word-break: break-all;
}

.show-liste {
    list-style: none;
    margin: 0 0 var(--s3);
    padding: 0;
}

.show-liste > li {
    border-top: 1px solid var(--line, #ddd);
    padding: var(--s2) 0;
}

.show-liste > li.neu {
    border-left: 3px solid var(--accent, #2f6fde);
    padding-left: var(--s2);
}

.show-liste p {
    margin: 4px 0;
}

.show-kopf {
    display: flex;
    gap: var(--s2);
    align-items: baseline;
    flex-wrap: wrap;
}

.show-kopf form {
    margin-left: auto;
}

.show-text {
    white-space: pre-wrap;
    max-height: 420px;
    overflow: auto;
}

/* DER MODELLVERGLEICH (itm-601): je Modell eine Karte — Trefferquote groß, darunter Zeit, alter Weg, Jev, Kosten. Das
   Modell, das LIA gerade nutzt, trägt den Akzent; der beste Wert in jeder Disziplin ist grün. */
.mv-laeuft {
    display: grid;
    gap: 6px;
    border-left: 4px solid var(--accent);
}

.mv-laeuft progress {
    width: 100%;
    height: 8px;
    accent-color: var(--accent);
}

.mv-karten {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 16px;
    margin-bottom: 16px;
}

.mv-karte {
    display: grid;
    gap: 12px;
    align-content: start;
    margin: 0;
}

.mv-karte header {
    display: grid;
    gap: 2px;
}

.mv-karte h2 {
    margin: 0;
    font-size: 1.05rem;
    overflow-wrap: anywhere;
}

.mv-aktiv {
    border-color: var(--accent);
    box-shadow: 0 0 0 2px var(--accent-soft);
}

.mv-zahl {
    display: grid;
    gap: 4px;
}

.mv-gross {
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.mv-gross small {
    font-size: 1rem;
    font-weight: 500;
    color: var(--ink-3);
}

.mv-bestes {
    color: var(--ok);
}

.mv-balken {
    height: 6px;
    border-radius: 999px;
    background: var(--surface-3);
    overflow: hidden;
}

.mv-balken span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--ok);
}

.mv-werte {
    margin: 0;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 4px 12px;
    font-size: 0.92rem;
}

.mv-werte dt {
    color: var(--ink-3);
}

.mv-werte dd {
    margin: 0;
    font-variant-numeric: tabular-nums;
}

.mv-matrix td .help {
    display: block;
    margin-top: 2px;
}

/* ===================== DAS TICKETSYSTEM (itm-595 bis 597) =====================
   Martin, 05.10.2026: „oberfläche, ui, bedienbarkeit, dashboards, reports … das soll wirklich toll werden".
   Nur Token der Konsole — so gilt der dunkle Modus von selbst. Rot heisst überfällig, Orange gefährdet; sonst trägt
   Orange wie überall genau eine Sache je Ansicht: den Knopf „Neues Ticket". */

.tk-kopf {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--s3);
    flex-wrap: wrap;
}

.tk-kopf .laschen {
    margin-bottom: 0;
}

.tk-titel {
    margin: 0;
}


.tk-kartenkopf {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--s2);
    margin-bottom: var(--s3);
}

.tk-kartenkopf h2 {
    margin: 0;
    font-size: var(--t-ui, 15px);
}


/* --- Verteilungen --- */
.tk-verteilung {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: var(--s2);
}

.tk-verteilung li {
    display: grid;
    grid-template-columns: minmax(0, 9rem) 1fr auto;
    gap: var(--s2);
    align-items: center;
    font-size: var(--t-sm);
}

.tk-verteilung .nm {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tk-spur {
    position: relative;
    height: 10px;
    background: var(--surface-3);
    border-radius: 5px;
    overflow: hidden;
}

.tk-spur i,
.tk-spur b {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    border-radius: 5px;
}

.tk-spur i {
    background: var(--brand);
}

.tk-spur b {
    background: var(--stop);
}

.tk-wert {
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    text-align: right;
    white-space: nowrap;
}

.tk-wert em {
    display: block;
    font-style: normal;
    font-weight: 400;
    font-size: var(--t-xs);
    color: var(--stop);
}

/* --- Ampel und Pillen --- */
.tk-ampel {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    vertical-align: middle;
    background: var(--surface-3);
}

.tk-ampel.gruen { background: var(--ok); }
.tk-ampel.gelb { background: var(--warn); }
.tk-ampel.rot { background: var(--stop); box-shadow: 0 0 0 3px var(--stop-soft); }

.tk-pille {
    display: inline-block;
    padding: 2px 9px;
    border-radius: 999px;
    font-size: var(--t-xs);
    font-weight: 600;
    white-space: nowrap;
    background: var(--surface-2);
    color: var(--ink-2);
}

.tk-pille.prio-dringend { background: var(--stop); color: #fff; }
.tk-pille.prio-hoch { background: var(--stop-soft); color: var(--stop); }
.tk-pille.prio-normal { background: var(--surface-2); color: var(--ink-2); }
.tk-pille.prio-niedrig { background: transparent; color: var(--ink-3); border: 1px solid var(--line); }

.tk-pille.status-neu { background: var(--draft-soft); color: var(--draft); }
.tk-pille.status-inarbeit { background: var(--accent-soft); color: var(--accent-ink); }
.tk-pille.status-wartetaufkunde { background: var(--surface-2); color: var(--ink-2); }
.tk-pille.status-erledigt { background: var(--ok-soft); color: var(--ok); }

.tk-frist.rot { color: var(--stop); font-weight: 600; }
.tk-frist.gelb { color: var(--accent-ink); font-weight: 600; }

/* --- Die Liste ---
   `.changes` gibt der ersten und zweiten Spalte feste Anteile (eine Gegenüberstellung alt/neu); eine Ticketliste hat
   schmale Spalten vorn und den Betreff in der Mitte — die Breite richtet sich nach dem Inhalt. */
.tk-tabelle th:first-child,
.tk-tabelle td:first-child,
.tk-tabelle th:nth-child(2),
.tk-tabelle td:nth-child(2) {
    width: auto;
}

.tk-tabelle td {
    vertical-align: middle;
    word-break: normal;
}

.tk-tabelle .mono,
.tk-tabelle .tk-frist,
.tk-tabelle td.meta {
    white-space: nowrap;
}


.tk-tabelle tr.tk-fokus td {
    background: var(--hover);
}

.tk-tabelle tr.tk-fokus td:first-child {
    box-shadow: inset 3px 0 0 var(--brand);
}


.tk-mit-auswahl [data-massen-zahl] {
    color: var(--ink);
    font-weight: 600;
}

/* --- Die Ticketmaske --- */
.tk-leiste {
    display: grid;
    gap: var(--s3);
}

.tk-leiste-werte {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s4) 32px;
}

.tk-leiste-werte > div {
    display: grid;
    gap: 4px;
}

.tk-leiste-werte .l {
    font-size: var(--t-xs);
    text-transform: uppercase;
    letter-spacing: .04em;
    color: var(--ink-3);
}

.tk-schnell {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
}

.tk-ki {
    border-left: 4px solid var(--draft);
}

.tk-ki form {
    display: flex;
    gap: var(--s3);
    align-items: center;
}

.tk-steckbrief {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 6px var(--s3);
    margin: 0;
    font-size: var(--t-sm);
}

.tk-steckbrief dt {
    color: var(--ink-3);
}

.tk-steckbrief dd {
    margin: 0;
}

.tk-zeitleiste {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: var(--s3);
}

.tk-mail {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    padding: var(--s3) var(--s4);
    max-width: 52rem;
}

.tk-mail.kunde {
    border-left: 4px solid var(--brand);
}

.tk-mail.wir {
    border-left: 4px solid var(--ok);
    margin-left: auto;
    background: var(--surface-2);
}

.tk-mail-kopf {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: var(--s2);
}

.tk-mail-betreff {
    font-weight: 600;
    margin: var(--s2) 0;
}

.tk-mail-text {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    line-height: 1.55;
}

.tk-ereignis {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
    padding: 0 var(--s4);
    font-size: var(--t-sm);
    color: var(--ink-2);
}

.tk-ereignis.notiz {
    background: var(--accent-soft);
    border-radius: var(--r-md);
    padding: var(--s2) var(--s4);
    color: var(--ink);
}

.tk-notiz,
.tk-hochladen {
    display: grid;
    gap: var(--s2);
}

.tk-notiz button,
.tk-hochladen button {
    justify-self: start;
}

.tk-antwort textarea {
    font-family: inherit;
    line-height: 1.5;
}

.tk-quellen {
    padding-left: 1.1rem;
    font-size: var(--t-sm);
}

/* --- Formulare: Neu, Bearbeiten, Einstellungen --- */
.tk-zwei {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--s4);
}

.tk-bearbeiten select,
.tk-neuform select {
    width: 100%;
}

.tk-einstellungen fieldset {
    border: 0;
    border-top: 1px solid var(--line-soft);
    padding: var(--s4) 0 0;
    margin: 0 0 var(--s4);
}

.tk-einstellungen legend {
    font-weight: 700;
    padding: 0 var(--s2) 0 0;
}

.tk-schalter {
    display: flex;
    gap: var(--s2);
    align-items: center;
    font-weight: 600;
}

.tk-fristen {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: var(--s3);
}

.tk-fristen input {
    width: 6rem;
}


@media (max-width: 760px) {
    .tk-raster,
    .tk-zwei {
        grid-template-columns: 1fr;
    }

    .tk-tabelle th:nth-child(7),
    .tk-tabelle td:nth-child(7),
    .tk-tabelle th:nth-child(10),
    .tk-tabelle td:nth-child(10) {
        display: none;
    }
}

/* ===== DIE STIMME: ANBIETER UND KLANG (itm-646) =====
   Martin 05.10.2026: „einen deutlicheren schalter zwischen elevenlabs und openai“. Zwei große Kacheln statt eines
   Kippschalters; was nur für ElevenLabs gilt, tritt zurück, sobald OpenAI gewählt ist — ohne Skript, über `:has`. */
.st-wahl { margin-bottom: var(--s4); }

.st-anbieter {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: var(--s3);
    margin-bottom: var(--s4);
}

.st-anbieter-wahl {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: var(--s4);
    padding-right: calc(var(--s4) + 72px);
    border: 2px solid var(--line-soft);
    border-radius: var(--r-lg);
    background: var(--surface-2);
    cursor: pointer;
    font-weight: 400;
    color: var(--ink);
    transition: border-color .18s var(--ease), background-color .18s var(--ease);
}

.st-anbieter-wahl > input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.st-anbieter-wahl:hover { border-color: var(--border-strong); }

.st-anbieter-wahl:has(> input:checked) {
    border-color: var(--brand);
    background: color-mix(in srgb, var(--brand) 7%, var(--surface-2));
}

.st-anbieter-wahl:has(> input:checked)::after {
    content: "spricht";
    position: absolute;
    top: var(--s3);
    right: var(--s3);
    padding: 1px var(--s2);
    border-radius: var(--r-full);
    background: var(--brand);
    color: var(--on-brand);
    font-size: var(--t-xs);
    font-weight: 600;
}

.st-anbieter-wahl:has(> input:focus-visible) {
    outline: 2px solid var(--brand);
    outline-offset: 2px;
}

.st-anbieter-name { font-size: var(--t-h3); font-weight: 700; }
.st-anbieter-text { color: var(--ink-2); font-size: var(--t-sm); }
.st-anbieter-hinweis { color: var(--warn); font-size: var(--t-xs); font-weight: 600; }

.st-stimme:has(input[name="Stimme.Anbieter"][value="openai"]:checked) .st-nur-eleven { display: none; }

.st-probe textarea { width: 100%; max-width: none; resize: vertical; }
.st-probe .es-knopfreihe { justify-content: flex-start; margin-top: var(--s2); }
.st-probe button[aria-pressed="true"] { border-color: var(--brand); }
.st-stimme #klang button svg { flex: none; width: 18px; height: 18px; }
.st-stimme #klang button { display: inline-flex; align-items: center; gap: var(--s2); }

/* ===== DIE BOTS IM PRÜFLAUF (itm-648) =====
   Je Bot ein Schalter, das Ergebnis des letzten Durchgangs, sechs Säulen Verlauf und die Kosten. Ein ausgeschlossener
   Bot tritt zurück, bleibt aber lesbar — man soll sehen, was man weggelassen hat. */
.pl-kopf {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: var(--s3);
    margin-bottom: var(--s3);
}

.pl-kopf h2 { margin: 0; }
.pl-kopf .help { max-width: 62ch; margin-top: 2px; }
.pl-kopf .chips { margin-top: 0; }

.pl-tabelle th[scope="row"] { font-weight: 600; }
.pl-tabelle th[scope="row"] a { color: var(--ink); }
.pl-kunde { display: block; font-weight: 400; font-size: var(--t-xs); }

.pl-tabelle tr.pl-aus > * { color: var(--ink-2); }
.pl-tabelle tr.pl-aus th[scope="row"] a { color: var(--ink-2); }
.pl-tabelle tr.pl-aus .pl-verlauf { opacity: .45; }

/* Der Schalter ist ein Knopf, der das Formular abschickt — ohne Skript, sofort gespeichert. */
.pl-schalter {
    display: inline-flex;
    align-items: center;
    gap: var(--s2);
    padding: 3px var(--s2) 3px 3px;
    border: 1px solid var(--line-soft);
    border-radius: var(--r-full);
    background: var(--surface-2);
    color: var(--ink);
    font-size: var(--t-xs);
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}

.pl-knopf {
    position: relative;
    flex: none;
    width: 34px;
    height: 20px;
    border-radius: var(--r-full);
    background: var(--surface-3);
    border: 1px solid var(--border-strong);
    transition: background-color .18s var(--ease);
}

.pl-knopf::before {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--ink-2);
    transition: transform .2s var(--ease);
}

.pl-schalter[aria-checked="true"] .pl-knopf { background: var(--brand); border-color: var(--brand); }
.pl-schalter[aria-checked="true"] .pl-knopf::before { transform: translateX(14px); background: var(--on-brand); }
.pl-schalter:hover { border-color: var(--brand); }
.pl-schalter:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

.pl-delta { margin-left: var(--s1); font-size: var(--t-xs); }

.pl-verlauf {
    display: inline-flex;
    align-items: flex-end;
    gap: 3px;
    height: 26px;
    padding: 2px 4px;
    border-radius: var(--r-md);
    background: var(--surface-2);
    vertical-align: middle;
}

.pl-saeule {
    width: 7px;
    height: max(2px, var(--h, 0%));
    border-radius: 2px 2px 0 0;
    background: var(--brand);
}

.pl-wann { margin-left: var(--s2); font-size: var(--t-xs); }

/* DIE ZEILENKÖPFE (Botname) sehen aus wie Zellen, nicht wie der Tabellenkopf. */
table.liste.pl-tabelle tbody th[scope="row"] {
    padding: var(--s2) var(--s3) var(--s2) 0;
    border-bottom: 1px solid var(--line-soft, var(--line));
    font-size: var(--t-sm);
    color: var(--ink);
    white-space: normal;
    vertical-align: middle;
}

table.liste.pl-tabelle tbody tr:last-child > * { border-bottom: 0; }

/* DIE ANSICHTEN DES PROTOKOLLS mit „Aktualisieren“ rechts daneben (itm-652). */
.proto-ansichten { align-items: center; }
.proto-stand {
    display: inline-flex;
    align-items: center;
    gap: var(--s2);
    margin-left: auto;
    font-size: var(--t-xs);
}

/* ===== LIAS GESPRÄCHE (itm-647) =====
   Liste wie die übrigen Listen; das Gespräch als Zeitlinie: Sätze als Blasen, was LIA dazwischen tut, als schmale
   Zeilen mit einer Marke davor — so liest man das Gespräch und sieht trotzdem, wo sie nachgesehen hat. */
.lg-suche {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2);
    align-items: center;
    margin: var(--s3) 0 var(--s4);
}

.lg-suche input { flex: 1 1 280px; max-width: 520px; }

.lg-tabelle .lg-wann { white-space: nowrap; }
.lg-tabelle .lg-wann .soft { display: block; font-size: var(--t-xs); }
.lg-tabelle .lg-satz a { color: var(--ink); }

.lg-zahlen {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: var(--s3);
    margin-bottom: var(--s4);
}

.lg-zahlen .card { margin: 0; padding: var(--s3) var(--s4); }
.lg-zahlen .zahl { font-size: var(--t-h2); font-weight: 700; font-variant-numeric: tabular-nums; }
.lg-zahlen .wofuer { color: var(--ink-2); font-size: var(--t-sm); }

.lg-auffaellig { border-left: 4px solid var(--warn); }
.lg-auffaellig h2 { margin-top: 0; }
.lg-auffaellig ul { margin: 0; padding-left: 1.2em; }

.lg-raster {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(240px, 1fr);
    gap: var(--s4);
    align-items: start;
}

@media (max-width: 1100px) {
    .lg-raster { grid-template-columns: minmax(0, 1fr); }
}

.lg-zeitlinie {
    list-style: none;
    margin: 0;
    padding: 0;
}

.lg-zeitlinie > li {
    display: grid;
    grid-template-columns: 5.2em minmax(0, 1fr);
    gap: var(--s3);
    padding: var(--s1) 0;
}

.lg-zeit {
    color: var(--ink-3);
    font-size: var(--t-xs);
    font-variant-numeric: tabular-nums;
    padding-top: 3px;
}

.lg-inhalt { min-width: 0; }

.lg-wer { display: block; font-size: var(--t-xs); font-weight: 600; color: var(--ink-2); margin-bottom: 2px; }

.lg-text {
    margin: 0;
    padding: var(--s2) var(--s3);
    border-radius: var(--r-md);
    background: var(--surface-2);
    border: 1px solid var(--line-soft);
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.lg-du .lg-text { background: color-mix(in srgb, var(--brand) 8%, var(--surface-2)); }
.lg-du, .lg-lia { padding-top: var(--s2) !important; }

.lg-marke {
    display: inline-block;
    margin-right: var(--s2);
    padding: 0 var(--s2);
    border-radius: var(--r-full);
    background: var(--surface-2);
    border: 1px solid var(--line-soft);
    font-size: var(--t-xs);
    font-weight: 600;
    color: var(--ink-2);
}

.lg-kurz { font-size: var(--t-sm); overflow-wrap: anywhere; }

.lg-workflow .lg-marke { border-color: var(--brand); color: var(--ink); }
.lg-problem .lg-marke { border-color: var(--warn); color: var(--warn); }

.lg-werkzeuge, .lg-laeufe { list-style: none; margin: 0; padding: 0; }
.lg-werkzeuge li { display: flex; justify-content: space-between; gap: var(--s2); padding: 2px 0; }
.lg-laeufe li { display: flex; flex-direction: column; gap: 2px; padding: var(--s2) 0; border-bottom: 1px solid var(--line-soft); }
.lg-laeufe li:last-child { border-bottom: 0; }
.lg-laeufe .zustand { align-self: flex-start; }
/* DIE WARTEFRAGE ALS ABSATZ — umbrechend, mit ihren Absätzen; nie eine Zeile, die nach rechts rollt (07.10.2026). */
.lg-laeufe .lg-wartet { margin: 4px 0 0; white-space: pre-line; overflow-wrap: anywhere; max-width: 72ch; }

/* ===== DER HUB DER BÜHNE (itm-691, itm-692, Martin 06.10.2026) =====
   „Die Bühne soll mehr ein zentraler Hub sein … es muss echt geil ausschauen." Oben eine Leiste mit LIA, den Bereichen
   (Tickets, Kalender, Aufgaben, Scaliento) und dem Zahnrad; darunter die Bühne wie bisher — rechts aber als Coverflow:
   links zugeklappt, was eben war, in der Mitte mit orangem Rahmen, was LIA gerade tut, rechts angeteasert, was kommt.
   Ein Bereich legt sich an die Stelle der Bühne, LIA sitzt dann rechts unten (lia-hub.js). Dieselben Farben wie die Bühne:
   das Navy der Scaliento-Kopfzeile, Orange als Akzent. */

/* DIE FARBEN stehen seit itm-722 bei `.hub, .buehne` oben (hell, Navy nur in der Leiste). */
.hub {
    --b-rand: clamp(14px, 1.6vw, 34px);
    /* EINE SCHLANKE ZEILE (itm-733): Im Rahmen steht Scalientos Topbar (42 px) schon darüber. */
    --hub-leiste: 46px;
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
    background: var(--b-grund);
    color: var(--b-text);
    font-family: var(--b-schrift);
    font-variant-numeric: tabular-nums;
    -webkit-font-smoothing: antialiased;
}

/* LINKS WEISS, RECHTS DER HELLE GRUND, dazwischen eine Linie — wie im Entwurf (720 : 880); jede Hälfte hat ihren eigenen Rand. */
.hub > .buehne {
    flex: 1 1 0;
    min-height: 0;
    height: auto;
    padding: 0;
    gap: 0;
    grid-template-columns: minmax(0, 9fr) minmax(0, 11fr);
    background: var(--b-grund);
}

.hub > .buehne > .buehne-links {
    padding: clamp(18px, 4.4vh, 40px) clamp(20px, 3.5vw, 56px) clamp(14px, 3.5vh, 32px);
    background: var(--b-flaeche);
    border-right: 1px solid var(--b-linie);
}

.hub > .buehne > .buehne-rechts {
    padding: clamp(18px, 4vh, 36px) clamp(18px, 3vw, 48px) clamp(14px, 3.5vh, 32px);
}

@media (max-width: 860px), (max-aspect-ratio: 1/1) {
    .hub > .buehne {
        grid-template-columns: minmax(0, 1fr);
    }

    .hub > .buehne > .buehne-links {
        border-right: 0;
        border-bottom: 1px solid var(--b-linie);
    }
}

.hub > .buehne[hidden],
.hub-panel[hidden],
.hub-dock[hidden] {
    display: none !important;
}

/* ----- DIE LEISTE ----- */
/* DIE KOPFLEISTE VON SCALIENTO (itm-722): Navy, links Logo und Wortmarke, ein Strich, „LIA“; die Reiter flach in voller Höhe, der
   gewählte weiß und fett auf einer helleren Navy-Stufe mit oranger Unterkante. Rechts der Showcase, das Zahnrad, die Person. Die
   Leiste bleibt dunkel — ihre Farben stehen deshalb fest und nicht in den hellen Token der Bühne. */

.hub-leiste {
    flex: none;
    display: flex;
    align-items: stretch;
    gap: clamp(12px, 2.4vw, 40px);
    height: var(--hub-leiste);
    padding: 0 clamp(12px, 1.5vw, 24px) 0 clamp(12px, 1.25vw, 20px);
    background: var(--b-navy);
    color: #fff;
    position: relative;
    z-index: 5;
}

.hub-marke {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: none;
}

/* KEIN ZWEITES LOGO (itm-733): Logo und „Built to comply“ zeigt Scaliento in seiner Topbar darüber — hier steht nur „AI Hub“. */
.hub-lia {
    font: 300 18px/1 var(--b-schrift);
    letter-spacing: 0.02em;
    white-space: nowrap;
}

/* DER NAME KOMMT AUS DER PERSONA (itm-755) — ein Element statt `content`, damit „Gino" statt „LIA" dasteht. */
.hub-hoert {
    display: none;
}

.hub.ansprechmodus .hub-hoert {
    display: inline-block;
    margin-left: 4px;
    padding: 4px 9px;
    border-radius: 3px;
    font: 700 12px/1 var(--b-schrift);
    letter-spacing: 0.02em;
    color: var(--b-navy);
    background: var(--b-glut);
}

.hub-reiter {
    display: flex;
    min-width: 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.hub-tab {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 100%;
    padding: 0 16px;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: rgba(255, 255, 255, 0.82);
    font: 400 14px/1 var(--b-schrift);
    white-space: nowrap;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

/* DIE ZEICHEN DER REITER stehen nur, wenn die Namen wegfallen (schmal, unten). */
.hub-tab svg {
    display: none;
}

.hub-tab svg,
.hub-icon svg,
.hub-dock svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex: none;
}

.hub-tab svg .voll,
.hub-icon svg .voll {
    fill: currentColor;
    stroke: none;
}

.hub-tab:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.06);
}

.hub-tab.an {
    color: #fff;
    font-weight: 600;
    background: var(--b-navy-2);
}

.hub-tab.an::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: var(--b-glut);
}

.hub-tab:focus-visible,
.hub-showcase:focus-visible,
.hub-dock button:focus-visible {
    outline: 3px solid var(--b-glut);
    outline-offset: -3px;
}

.hub-zahl {
    display: inline-grid;
    place-items: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 10px;
    background: #fff;
    color: var(--b-navy);
    font: 700 12px/1 var(--b-schrift);
}

.hub-rechts {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-left: auto;
    min-width: 0;
}

/* KEINE LIVE-VERBINDUNG (Befund 07.10.2026, live.js): ein hohler grauer Punkt und ein leises Wort — für den, der vorführt, nicht
   fürs Publikum. Kein Rot, kein Blinken: Die Leitung kommt von selbst wieder. */
.live-hinweis {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    line-height: 1;
    color: rgba(255, 255, 255, 0.55);
    white-space: nowrap;
    cursor: default;
}

.live-hinweis[hidden] {
    display: none;
}

.live-hinweis-punkt {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.55);
    box-sizing: border-box;
}

/* NUR DER PUNKT (itm-733, Martin: „würde ich nur das Blinken lassen, damit Daniel weiß, dass alles läuft"): orange und pulsierend,
   solange ein Showcase läuft, sonst ein ruhiger grauer Punkt. Der Name steht im Tooltip (lia-hub.js). */
.hub-showcase {
    display: grid;
    place-items: center;
    flex: none;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
    transition: background 0.2s;
}

.hub-showcase:hover {
    background: rgba(255, 255, 255, 0.1);
}

.hub-showcase-punkt {
    flex: none;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.45);
}

.hub-showcase.aktiv .hub-showcase-punkt {
    background: var(--b-glut);
    box-shadow: 0 0 0 0 rgba(240, 138, 28, 0.6);
    animation: hub-puls 2s infinite;
}

/* DER STAND NEBEN DEM PUNKT („3/11“, lia-hub.js): klein und hell, der Knopf wird dafür zur Pille. */
.hub-showcase-stand {
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0.02em;
    font-variant-numeric: tabular-nums;
    color: rgba(255, 255, 255, 0.86);
    white-space: nowrap;
}

.hub-showcase-stand:empty,
.hub-showcase-stand[hidden] {
    display: none;
}

.hub-showcase:has(.hub-showcase-stand:not(:empty):not([hidden])) {
    grid-auto-flow: column;
    gap: 8px;
    width: auto;
    padding: 0 10px 0 11px;
    border-radius: 16px;
}

@keyframes hub-puls {
    70% { box-shadow: 0 0 0 9px rgba(240, 138, 28, 0); }
    100% { box-shadow: 0 0 0 0 rgba(240, 138, 28, 0); }
}

.hub-zahnrad {
    width: 36px;
    height: 36px;
    padding: 0;
    justify-content: center;
    border-radius: 3px;
}

.hub-zahnrad svg {
    display: block;
    width: 22px;
    height: 22px;
    stroke-width: 1.6;
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.hub-zahnrad.an::after {
    left: 6px;
    right: 6px;
}

.hub-zahnrad:hover svg,
.hub-zahnrad.an svg {
    transform: rotate(90deg);
}

.hub-persona img {
    display: block;
    width: 22px;
    height: 22px;
    border-radius: 5px;
    opacity: 0.85;
    transition: opacity 0.2s, transform 0.2s;
}

.hub-persona:hover img,
.hub-persona.an img {
    opacity: 1;
    transform: scale(1.08);
}

.hub-person {
    display: grid;
    place-items: center;
    flex: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #fff;
    color: var(--b-navy);
    font: 700 12px/1 var(--b-schrift);
}

/* ----- RECHTS: DER COVERFLOW ----- */
/* WEISSE KARTEN AUF HELLEM GRUND (itm-722): Die Tiefe zeigt die Zeit — links gekippt, was erledigt ist, in der Mitte mit oranger
   Oberkante, was JETZT geschieht, rechts gekippt, was als Nächstes kommt. Sonst flach und eckig wie Scaliento. */

.hub .buehne-rechts {
    grid-template-rows: auto minmax(clamp(240px, 46vh, 820px), 1fr) auto auto auto;
    gap: clamp(10px, 2.4vh, 28px);
}

.cf {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 0.62fr) minmax(0, 1.12fr) minmax(0, 0.62fr);
    align-items: center;
    min-height: 0;
    height: 100%;
    perspective: 1500px;
    perspective-origin: 50% 45%;
}

/* DER QR-CODE GROSS (10.10.2026): die Mitte über die ganze Breite, die Kacheln daneben weg (lia-buehne.js setzt data-voll). */
.cf[data-voll] {
    grid-template-columns: 0 minmax(0, 1fr) 0;
}

.cf[data-voll] .cf-vorher,
.cf[data-voll] .cf-danach {
    visibility: hidden;
    border: 0;
}

.cf[data-voll] .buehne-satz {
    display: none;
}

/* UND DER CODE SELBST GROSS — scannbar aus dem Saal. */
.cf[data-voll] .bs-qk {
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
}

.cf[data-voll] .bs-qk-code img,
.cf[data-voll] .bs-qk-code::after {
    --qk-code: min(100%, 64cqh);
}

.cf[data-voll] .bs-qk-code img {
    width: var(--qk-code);
}

.cf[data-voll] .bs-qk-code::after {
    top: calc(var(--qk-code) / 2);
    left: calc(50% + var(--qk-code) / 2 + 3px);
}

.cf[data-voll] .bs-qk-adresse {
    font-size: clamp(12px, 3.4cqh, 20px);
}

/* DER SCHATTEN UNTER DER MITTE: ein weicher Fleck, die Karte schwebt. */
.cf::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -14px;
    width: min(440px, 50%);
    height: 30px;
    transform: translateX(-50%);
    background: radial-gradient(closest-side, rgba(31, 34, 64, 0.16), rgba(31, 34, 64, 0));
    pointer-events: none;
}

.cf-kachel {
    position: relative;
    min-width: 0;
    border-radius: 4px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    overflow: hidden;
    transition: transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.7s, filter 0.7s;
}

.cf-jetzt {
    z-index: 2;
    height: 100%;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto auto;
    gap: 0;
    padding: 0 0 clamp(12px, 2.2vh, 22px);
    border-top: 4px solid var(--b-glut);
    box-shadow: 0 34px 60px -28px var(--b-schatten), 0 2px 6px rgba(31, 34, 64, 0.07);
}

.cf-jetzt .buehne-szene {
    margin: 0 clamp(12px, 1.25vw, 20px);
    border-radius: 3px;
    background: var(--b-flaeche-2);
}

.cf-jetzt .buehne-titel {
    margin: clamp(10px, 2.2vh, 20px) clamp(12px, 1.25vw, 20px) 0;
    font-size: 28px;
    -webkit-line-clamp: 2;
    text-align: left;
    transform-origin: 0% 50%;
}

.cf-jetzt .buehne-satz {
    margin: clamp(4px, 0.9vh, 8px) clamp(12px, 1.25vw, 20px) 0;
    text-align: left;
    font-size: 16px;
    -webkit-line-clamp: 2;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* DIE ZEILE ÜBER DEM BILD: „● JETZT“ links, der Schritt rechts (lia-buehne.js). */
.cf-takt {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0;
    padding: clamp(10px, 1.6vh, 14px) clamp(12px, 1.25vw, 20px) clamp(8px, 1.4vh, 12px);
    min-width: 0;
    white-space: nowrap;
}

.cf-jetzt-wort {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font: 700 12px/1 var(--b-schrift);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--b-glut-text);
}

.cf-jetzt-wort::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--b-glut);
    box-shadow: 0 0 0 4px rgba(240, 138, 28, 0.18);
}

.cf-takt small {
    overflow: hidden;
    text-overflow: ellipsis;
    font: 400 13px/1 var(--b-schrift);
    color: var(--b-leise);
}

.cf-vorher,
.cf-danach {
    height: 68%;
    display: grid;
    grid-template-rows: auto minmax(0, 0.95fr) auto;
    align-content: start;
    gap: 0;
    padding: 0 0 clamp(10px, 2vh, 18px);
    box-shadow: 0 12px 30px -16px rgba(31, 34, 64, 0.3);
}

.cf-vorher {
    transform-origin: 0% 50%;
    transform: rotateY(20deg);
    margin-right: -2%;
}

.cf-danach {
    transform-origin: 100% 50%;
    transform: rotateY(-20deg);
    margin-left: -2%;
}

.cf-kachel.leer {
    visibility: hidden;
}

.cf-vorher *,
.cf-danach * {
    animation: none !important;
    transition: none !important;
}

/* „✓ ERLEDIGT“ in Grün, „→ ALS NÄCHSTES“ in Navy. */
.cf-wort {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    padding: clamp(10px, 1.6vh, 14px) clamp(10px, 1vw, 16px) clamp(8px, 1.2vh, 10px);
    font: 700 12px/1 var(--b-schrift);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--b-gut);
}

.cf-vorher .cf-wort::before {
    content: "✓";
    font-size: 1.3em;
    letter-spacing: 0;
}

.cf-danach .cf-wort {
    color: var(--b-navy);
}

.cf-danach .cf-wort::before {
    content: "→";
    font-size: 1.3em;
    letter-spacing: 0;
}

.cf-bild {
    min-height: 0;
    margin: 0 clamp(10px, 1vw, 16px);
    display: grid;
    place-items: center;
    border-radius: 3px;
    background: var(--b-flaeche-2);
}

.cf-bild svg {
    width: 100%;
    height: 100%;
}

.cf-titel {
    margin: clamp(10px, 1.6vh, 14px) clamp(10px, 1vw, 16px) 0;
    font: 600 14px/1.3 var(--b-schrift);
    color: var(--b-navy);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.cf-haken {
    position: absolute;
    top: clamp(34px, 5vh, 46px);
    right: clamp(16px, 1.6vw, 24px);
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--b-gut);
    color: #fff;
    font-weight: 700;
    font-size: 13px;
}

/* DAS WEITERRÜCKEN: Die Mitte kommt von rechts, die vorige klappt nach links weg, die nächste dreht herein. */
.cf.rueckt .cf-jetzt {
    animation: cf-mitte 0.75s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.cf.rueckt .cf-vorher {
    animation: cf-klappen 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.cf.rueckt .cf-danach {
    animation: cf-teaser 0.8s 0.12s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

@keyframes cf-mitte {
    from { transform: rotateY(-20deg) translateX(22%) scale(0.86); opacity: 0.35; }
}

@keyframes cf-klappen {
    from { transform: rotateY(0deg) translateX(70%) scale(1.25); opacity: 1; }
}

@keyframes cf-teaser {
    from { transform: rotateY(-70deg) translateX(-40%) scale(0.8); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .cf.rueckt .cf-jetzt,
    .cf.rueckt .cf-vorher,
    .cf.rueckt .cf-danach {
        animation: none;
    }
}

/* DER FORTSCHRITT: ein Balken aus Segmenten, darunter drei Namen (lia-buehne.js). */
.cf-fortschritt {
    min-width: 0;
}

.cf-fortschritt:has(.cf-punkte[hidden]) {
    display: none;
}

.cf-punkte {
    display: flex;
    align-items: center;
    gap: 4px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.cf-punkte[hidden] {
    display: none;
}

.cf-punkt {
    flex: 1 1 0;
    height: 6px;
    border-radius: 1px;
    background: #d5d7df;
    transition: background 0.5s, box-shadow 0.5s;
}

.cf-punkt.fertig {
    background: var(--b-navy);
}

.cf-punkt.jetzt {
    background: var(--b-glut);
    box-shadow: 0 0 0 3px rgba(240, 138, 28, 0.18);
}

.cf-punkt-name {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.cf-punkte-namen {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin: 12px 0 0;
    font: 400 13px/1.2 var(--b-schrift);
    color: var(--b-leise);
}

.cf-punkte-namen > * {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cf-punkte-namen b {
    font-weight: 600;
    color: var(--b-glut-text);
}

.cf.showcase ~ .buehne-ablauf {
    display: none;
}

/* SCHMAL: nur die Mitte, ohne die Seitenkacheln. */
@media (max-width: 1100px) {
    .cf {
        grid-template-columns: minmax(0, 1fr);
    }

    .cf-vorher,
    .cf-danach {
        display: none;
    }
}

/* ----- IN RUHE: ALLES IM BLICK (itm-720, als Scaliento-Kacheln itm-722) -----
   Keine Karten, kein Fortschritt: Die ganze Hälfte gehört den vier Bereichen. Das Bild füllt den Platz der Mitte; Titel und Satz
   der Karte stehen schon im Kopf. */
.buehne-rechts[data-ruhe] .cf {
    grid-template-columns: minmax(0, 1fr);
}

.buehne-rechts[data-ruhe] .cf::after,
.buehne-rechts[data-ruhe] .cf-vorher,
.buehne-rechts[data-ruhe] .cf-danach,
.buehne-rechts[data-ruhe] .cf-takt,
.buehne-rechts[data-ruhe] .buehne-titel,
.buehne-rechts[data-ruhe] .buehne-satz,
.buehne-rechts[data-ruhe] .cf-fortschritt {
    display: none;
}

/* ----- DIE MAIL ZUR DURCHSICHT FÜLLT DIE HÄLFTE (Martin, 08.10.2026: „dass es gut in den rechten bereich passt“) -----
   Keine Seitenkarten, kein Titel darunter — die Frage steht links und als Antworten unter der Mail; der Fortschritt bleibt. */
.buehne-rechts[data-mail] .cf {
    grid-template-columns: minmax(0, 1fr);
}

.buehne-rechts[data-mail] .cf::after,
.buehne-rechts[data-mail] .cf-vorher,
.buehne-rechts[data-mail] .cf-danach,
.buehne-rechts[data-mail] .cf-takt,
.buehne-rechts[data-mail] .buehne-titel,
.buehne-rechts[data-mail] .buehne-satz {
    display: none;
}

.buehne-rechts[data-mail] .cf-jetzt {
    grid-template-rows: minmax(0, 1fr);
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

.buehne-rechts[data-mail] .cf-jetzt .buehne-szene {
    margin: 0;
    background: transparent;
}

.buehne-rechts[data-mail] .bs-bild {
    padding: 0 0 4px;
}

/* IM SHOWCASE BLEIBT DER FORTSCHRITT, auch wenn die Bühne darunter ruht — vor der ersten Mail steht er bei 0, nach dem Fall voll. */
.buehne-rechts[data-ruhe][data-showcase] .cf-fortschritt {
    display: block;
}

.buehne-rechts[data-ruhe] .cf-jetzt {
    grid-template-rows: minmax(0, 1fr);
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    overflow: visible;
}

.buehne-rechts[data-ruhe] .cf-jetzt .buehne-szene {
    margin: 0;
    background: transparent;
    overflow: visible;
}

.buehne-rechts[data-ruhe] .bs-bild {
    padding: 0;
}

.bs-ruhe {
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    min-width: 0;
    /* NIE KLEINER ALS DIE KACHELN (itm-733): Reicht die Höhe nicht, wird die Spalte länger und die Bühne rollt. */
    grid-template-rows: minmax(min-content, 1fr) auto;
    gap: clamp(10px, 2.4vh, 24px);
}

/* DAS FELD: vier Kacheln an den Ecken, dazwischen Luft; die gestrichelte Runde läuft durch ihre Mitten und ist nur in der Luft zu
   sehen. Das Logo läuft auf ihr — hinter den Kacheln, also schaut es in jede hinein. */
/* EIN RASTER STATT ABSOLUTER ECKEN (itm-733): Bei 650 px Höhe oder 1000 px Breite lagen Zahl und Name übereinander, weil die
   Kacheln ihre Höhe in Prozent bekamen und der Inhalt absolut darin stand. Jetzt sind es zwei Spalten und zwei Zeilen mit Luft
   dazwischen — in denselben Anteilen wie vorher (41 : 18 : 41, 40 : 20 : 40), aber nie kleiner als ihr Inhalt. */
.bs-ruhe-feld {
    position: relative;
    min-height: 0;
    padding-top: 14px;
    display: grid;
    grid-template-columns: minmax(0, 41.2fr) minmax(16px, 17.6fr) minmax(0, 41.2fr);
    grid-template-rows: minmax(max-content, 40fr) minmax(16px, 20fr) minmax(max-content, 40fr);
}

.bs-ruhe-runde {
    position: absolute;
    left: 20.6%;
    right: 20.6%;
    top: calc(14px + (100% - 14px) * 0.2);
    bottom: 20%;
    border: 2px dashed var(--b-linie-2);
    border-radius: 40px;
}

.bs-ruhe-kachel {
    position: relative;
    z-index: 2;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 15px 64px 14px 18px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    box-shadow: 0 1px 2px rgba(31, 34, 64, 0.05);
    color: var(--b-navy);
    animation: bs-ruhe-blick 12s ease-in-out infinite;
    animation-delay: calc(var(--i, 0) * 3s - 1s);
}

.bs-ruhe-kachel[data-bereich="tickets"] { grid-area: 1 / 1; }
.bs-ruhe-kachel[data-bereich="kalender"] { grid-area: 1 / 3; }
.bs-ruhe-kachel[data-bereich="aufgaben"] { grid-area: 3 / 3; }
.bs-ruhe-kachel[data-bereich="scaliento"] { grid-area: 3 / 1; }

/* WAS NEU IST, STEHT IN NAVY — wie die hervorgehobene Kachel im Dashboard von Scaliento. */
.bs-ruhe-kachel.hervor {
    background: var(--b-navy);
    border-color: var(--b-navy);
    color: #fff;
}

.bs-ruhe-zahl {
    display: flex;
    align-items: baseline;
    gap: 6px;
    margin: 0;
    font: 300 38px/1 var(--b-schrift);
}

.bs-ruhe-zahl small {
    font: 400 14px/1 var(--b-schrift);
    color: var(--b-leise);
}

.bs-ruhe-zeichen {
    position: absolute;
    top: 15px;
    right: 16px;
}

.bs-ruhe-zeichen svg {
    display: block;
    width: 36px;
    height: 36px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.1;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* DER NAME STEHT UNTEN IM FLUSS — nicht mehr absolut, darum kann er die Zahl nie überdecken. */
.bs-ruhe-name {
    margin: auto -46px 0 0;
    min-width: 0;
    font: 400 18px/1.25 var(--b-schrift);
}

.bs-ruhe-name small {
    display: block;
    margin-top: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font: 400 13px/1.35 var(--b-schrift);
    color: var(--b-leise);
}

.bs-ruhe-kachel.hervor .bs-ruhe-zahl small,
.bs-ruhe-kachel.hervor .bs-ruhe-name small {
    color: #c9cce6;
}

/* „LIA SCHAUT NACH“ an der Kachel, in die das Logo gerade blickt — im selben Takt wie die Runde. */
.bs-ruhe-blick {
    position: absolute;
    left: clamp(14px, 1.4vw, 22px);
    top: -13px;
    display: flex;
    align-items: center;
    gap: 6px;
    height: 24px;
    padding: 0 9px;
    border-radius: 12px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-glut-rand);
    font: 600 12px/1 var(--b-schrift);
    color: var(--b-glut-text);
    white-space: nowrap;
    opacity: 0;
    animation: bs-ruhe-marke 12s ease-in-out infinite;
    animation-delay: inherit;
}

.bs-ruhe-blick::before {
    content: "✦";
    color: var(--b-glut);
}

@keyframes bs-ruhe-blick {
    0%, 2%, 18%, 100% { border-top-color: var(--b-linie); box-shadow: 0 1px 2px rgba(31, 34, 64, 0.05); }
    5%, 15% { border-top-color: var(--b-glut); box-shadow: inset 0 3px 0 var(--b-glut), 0 18px 36px -20px var(--b-schatten); }
}

@keyframes bs-ruhe-marke {
    0%, 2%, 18%, 100% { opacity: 0; }
    5%, 15% { opacity: 1; }
}

/* DAS LOGO AUF DER RUNDE: weiß gerahmt, mit orangem Schein; 12 s die Runde, je 3 s von Bereich zu Bereich. */
.bs-ruhe-spaeher {
    position: absolute;
    z-index: 1;
    left: 20.6%;
    top: calc(14px + (100% - 14px) * 0.2);
    width: 48px;
    height: 48px;
    margin: -24px 0 0 -24px;
    padding: 4px;
    border-radius: 12px;
    background: var(--b-flaeche);
    box-shadow: 0 8px 20px -6px rgba(240, 138, 28, 0.6), 0 0 0 6px rgba(240, 138, 28, 0.12);
    animation: bs-ruhe-runde 12s linear infinite;
}

.bs-ruhe-spaeher img {
    display: block;
    width: 40px;
    height: 40px;
    border-radius: 9px;
}

@keyframes bs-ruhe-runde {
    0% { left: 20.6%; top: calc(14px + (100% - 14px) * 0.2); }
    25% { left: 79.4%; top: calc(14px + (100% - 14px) * 0.2); }
    50% { left: 79.4%; top: 80%; }
    75% { left: 20.6%; top: 80%; }
    100% { left: 20.6%; top: calc(14px + (100% - 14px) * 0.2); }
}

/* WENIGER BEWEGUNG: Das Logo steht in der Luft zwischen den oberen Kacheln, der Kalender trägt „LIA schaut nach“. */
@media (prefers-reduced-motion: reduce) {
    .bs-ruhe-kachel,
    .bs-ruhe-blick,
    .bs-ruhe-spaeher {
        animation: none !important;
    }

    .bs-ruhe-spaeher {
        left: 53.6%;
    }

    .bs-ruhe-kachel[data-bereich="kalender"] {
        box-shadow: inset 0 3px 0 var(--b-glut), 0 18px 36px -20px var(--b-schatten);
    }

    .bs-ruhe-kachel[data-bereich="kalender"] .bs-ruhe-blick {
        opacity: 1;
    }
}

/* ZULETZT BEMERKT: drei Zeilen unter einer Linie — Uhrzeit, was, wo. */
.bs-ruhe-ticker {
    border-top: 1px solid var(--b-linie);
    padding-top: clamp(8px, 1.8vh, 16px);
}

/* NIEDRIG (itm-733): Unter 700 px Höhe gehört der Platz den vier Kacheln; was LIA zuletzt bemerkt hat, steht im Protokoll. */
@media (max-height: 700px) {
    .bs-ruhe-ticker {
        display: none !important;
    }
}

.bs-ruhe-ticker[hidden] {
    display: none;
}

.bs-ruhe-ticker-kopf {
    margin: 0;
    font: 700 12px/1 var(--b-schrift);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--b-leise);
}

.bs-ruhe-ticker ul {
    margin: 8px 0 0;
    padding: 0;
    list-style: none;
}

.bs-ruhe-ticker li {
    display: flex;
    align-items: center;
    gap: 14px;
    height: clamp(26px, 3.6vh, 32px);
    font: 400 14px/1 var(--b-schrift);
    color: var(--b-text-2);
}

.bs-ruhe-ticker li span {
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bs-ruhe-ticker time {
    flex: none;
    width: 44px;
    font-weight: 600;
    color: var(--b-navy);
}

.bs-ruhe-ticker em {
    flex: none;
    margin-left: auto;
    font-style: normal;
    font-size: 13px;
    color: var(--b-leise);
}

/* ----- EIN BEREICH ----- */
/* HELL WIE DIE BÜHNE (itm-722): weiße Karten mit feiner Linie auf dem hellen Grund, Titel groß und leicht, eckig wie Scaliento.
   Was LIA geschrieben hat, trägt eine orange linke Kante und „✦ LIA“ — sonst kein Orange. */

.hub-panel {
    flex: 1 1 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: clamp(10px, 1.6vh, 18px);
    padding: clamp(14px, 2.6vh, 26px) var(--b-rand) var(--b-rand);
    overflow: hidden;
    animation: hp-rein 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

/* KEIN GRAUER STREIFEN UNTER LIA (Martin 08.10.2026: „ist das so gewollt, dass da unten ein grauer Balken ist, auf dem der
   Assistent liegt?“ — nein). itm-733 hatte jeden Bereich über dem Dock enden lassen; unten blieb ein leerer Streifen so hoch wie
   das Dock. JETZT LÄUFT DER INHALT BIS UNTEN DURCH, und das Dock schwebt wieder darüber. Dauerhaft verdeckt bleibt trotzdem nichts:
   Was rollt, hat innen unten `--dock-platz` Luft — so weit lässt sich das Letzte über LIA hinaufrollen; was nicht rollt (die
   Spalte im Ticket, die Woche im Kalender), hält diesen Platz selbst frei. `--dock-platz` steht am Hub, wo lia-hub.js `--dock-h`
   misst: Dock plus 16 px Abstand zum Rand plus 12 px Luft, höchstens die halbe Höhe, falls jemand es aufgeklappt hat. */
.hub {
    --dock-platz: min(calc(var(--dock-h, 56px) + 28px), 50vh);
}

.hub-panel {
    padding-bottom: 0;
}

@keyframes hp-rein {
    from { opacity: 0; transform: translateY(12px); }
}

.hp-kopf {
    flex: none;
    display: flex;
    align-items: baseline;
    gap: 18px;
    flex-wrap: wrap;
}

/* 22 PX STATT 28 PX LEICHT (itm-733, Martin 07.10.2026: „Die Schriften sind sehr groß"). Dieselbe Stufe wie die Seiten im Rahmen
   und der Kopf der Bühne — ein Titelgrad für den ganzen Hub. */
.hp-titel {
    margin: 0;
    font: 400 22px/1.2 var(--b-schrift);
    color: var(--b-navy);
}

.hp-unter {
    margin: 0;
    color: var(--b-leise);
    font-size: 14px;
}

.hp-inhalt {
    flex: 1 1 0;
    min-height: 0;
    overflow: auto;
    scrollbar-color: var(--b-linie-2) transparent;
    /* BIS ZUM UNTEREN RAND (08.10.2026): Den Platz für LIA hält jeder Bereich innen selbst frei (`--dock-platz`). */
    padding-bottom: 0;
}

.hp-leer {
    color: var(--b-leise);
    font-size: 14px;
    margin: 18px 4px;
}

.hp-zeit {
    color: var(--b-leise);
    font-size: 13px;
    font-weight: 400;
}

/* DIE STATUS-PILLEN IN DEN FARBEN VON SCALIENTO: Neu Navy, In Bearbeitung Grün, Wartet Grau. */
.hp-chip {
    display: inline-flex;
    align-items: center;
    height: 22px;
    padding: 0 10px;
    border-radius: 11px;
    font: 600 12px/1 var(--b-schrift);
    background: #e3e4eb;
    color: var(--b-text-2);
    white-space: nowrap;
}

.hp-chip.status-Neu {
    background: var(--b-navy);
    color: #fff;
}

/* „IN ARBEIT“ WIE IN DER LISTE IM RAHMEN (itm-733): grün mit kleinem ▶ — `InArbeit` ist der Name im Ticketstatus. */
.hp-chip.status-InArbeit,
.hp-chip.status-InBearbeitung,
.hp-chip.status-Offen {
    gap: 5px;
    background: var(--b-gut);
    color: #fff;
}

.hp-chip.status-InArbeit::before {
    content: "";
    width: 0;
    height: 0;
    border-left: 6px solid currentColor;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
}

/* DIE PRIORITÄT WIE IM RAHMEN — nur, wenn sie drängt. */
.hp-chip.prio-Dringend {
    background: var(--b-halt);
    color: #fff;
}

.hp-chip.prio-Hoch {
    background: #f2b632;
    color: #3a2a00;
}

.hp-chip.status-WartetAufKunde {
    background: #6b7089;
    color: #fff;
}

.hp-chip.gut,
.hp-chip.status-Erledigt,
.hp-chip.status-Geschlossen {
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie-2);
    color: var(--b-leise);
}

/* „✦ LIA“ — LIAS SPUR (itm-722): wo sie etwas getan hat, steht dieses Abzeichen. */
.hp-lia-marke {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 20px;
    padding: 0 7px;
    border-radius: 2px;
    background: var(--b-glut-flaeche);
    border: 1px solid var(--b-glut-rand);
    color: var(--b-glut-text);
    font: 700 12px/1 var(--b-schrift);
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.hp-lia-marke::before {
    content: "✦";
    color: var(--b-glut);
    font-size: 12px;
}

.hp-lia-marke.klein {
    height: 18px;
    font-size: 12px;
    padding: 0 6px;
}

/* TICKETS: links die Liste, in der Mitte der Verlauf als Gespräch, rechts LIAs Spalte. */

/* ZWEISPALTIG BIS 900 PX (itm-733): links die Liste über die ganze Höhe, rechts oben der Verlauf, darunter LIAs Spalte. Bis
   dahin fiel unter 1180 px alles in eine Spalte, und die Liste war bei 981 px gut 100 px hoch. */
.hp-tickets {
    display: grid;
    grid-template-columns: minmax(240px, 0.36fr) minmax(0, 0.64fr);
    grid-template-rows: minmax(0, 1.15fr) minmax(0, 1fr);
    grid-template-areas: "liste detail" "liste lia";
    gap: 0;
    height: 100%;
    min-height: 0;
    border: 1px solid var(--b-linie);
    /* OFFEN NACH UNTEN (08.10.2026): Die drei Spalten laufen bis an den Rand des Fensters, LIA schwebt rechts darüber. */
    border-bottom: 0;
    border-radius: 3px 3px 0 0;
    background: var(--b-grund);
}

.hp-tickets > .hp-ticketliste { grid-area: liste; }
.hp-tickets > .hp-ticketdetail { grid-area: detail; border-bottom: 1px solid var(--b-linie); }
.hp-tickets > .hp-liaspalte { grid-area: lia; }

.hp-ticketdetail.laedt {
    opacity: 0.55;
    transition: opacity 0.2s 0.15s;
}

/* DIE LISTE WIE IN SCALIENTO: weiße Zeilen, durch Linien getrennt; die gewählte hellgrau mit Navy-Kante links. */
.hp-ticketliste {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    overflow: auto;
    min-height: 0;
    background: var(--b-flaeche);
    border-right: 1px solid var(--b-linie);
}

.hp-ticket-knopf {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 13px 18px 13px 16px;
    border: 0;
    border-left: 4px solid transparent;
    border-bottom: 1px solid #ecedf1;
    border-radius: 0;
    background: var(--b-flaeche);
    color: var(--b-text);
    font: inherit;
    text-align: left;
    cursor: pointer;
    transition: background 0.2s;
}

.hp-ticket-knopf:hover {
    background: var(--b-flaeche-2);
}

.hp-ticket.an .hp-ticket-knopf {
    background: #eef0f7;
    border-left-color: var(--b-navy);
}

.hp-ticket-zeile {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px 8px;
}

.hp-ticket-zeile .hp-zeit {
    margin-left: auto;
}

.hp-ticket-nr {
    color: var(--b-leise);
    font-size: 13px;
    font-weight: 600;
}

.hp-ticket-betreff {
    font-weight: 600;
    font-size: 16px;
    line-height: 1.35;
    color: var(--b-text);
}

.hp-ticket-wer {
    color: var(--b-leise);
    font-size: 14px;
}

.hp-ticket-knopf .hp-lia-marke {
    align-self: flex-start;
    margin-top: 2px;
}

.hp-ticketdetail {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.hp-detail-kopf {
    flex: none;
    padding: 18px 26px 16px;
    border-bottom: 1px solid var(--b-linie);
    background: var(--b-flaeche);
}

/* ZURÜCK ZUR LISTE (itm-733): klein über dem Titel, wie der Pfad in Scaliento. */
.hub-panel button.hp-zurueck {
    display: inline-flex;
    align-items: center;
    min-height: 0;
    margin: 0 0 8px -4px;
    padding: 2px 6px;
    border: 0;
    border-radius: 2px;
    background: transparent;
    color: var(--b-leise);
    font: 600 13px/1.4 var(--b-schrift);
    cursor: pointer;
}

.hub-panel button.hp-zurueck:hover {
    color: var(--b-navy);
    background: var(--b-flaeche-2);
}

.hp-ticket-knopf:focus-visible {
    outline: 2px solid var(--b-glut);
    outline-offset: -2px;
}

.hp-detail-titel {
    margin: 0 0 8px;
    font: 400 22px/1.3 var(--b-schrift);
    color: var(--b-navy);
}

.hp-detail-meta {
    margin: 0;
    color: var(--b-leise);
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.hp-detail-meta b {
    color: var(--b-leise);
    font-weight: 600;
}

.hp-verlauf {
    flex: 1 1 0;
    min-height: 0;
    margin: 0;
    padding: 20px 26px 22px;
    list-style: none;
    overflow: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.hp-nachricht {
    max-width: min(88%, 760px);
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 14px 18px 16px;
    border-radius: 4px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    animation: hp-blase 0.5s calc(var(--i, 0) * 70ms) cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

@keyframes hp-blase {
    from { opacity: 0; transform: translateY(10px) scale(0.98); }
}

.hp-nachricht.kunde {
    align-self: flex-start;
}

.hp-nachricht.lia,
.hp-nachricht.wir {
    align-self: flex-end;
}

.hp-nachricht.lia {
    border-left: 4px solid var(--b-glut);
}

.hp-nachricht-wer {
    margin: 0 0 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    flex-wrap: wrap;
    color: var(--b-text);
}

.hp-nachricht-wer b {
    font-weight: 600;
}

.hp-nachricht-wer .hp-zeit {
    order: 3;
    margin-left: auto;
}

.hp-nachricht-text {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    font-size: 16px;
    line-height: 1.5;
    color: var(--b-text);
}

.hp-anhang {
    margin: 10px 0 0;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px 4px 6px;
    border-radius: 3px;
    border: 1px solid var(--b-linie);
    background: var(--b-flaeche-2);
    font-size: 13px;
    color: var(--b-text-2);
    align-self: flex-start;
}

.hp-anhang-zeichen svg {
    display: block;
    width: 16px;
    height: 16px;
    fill: none;
    stroke: var(--b-navy);
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* LIAS SPALTE IM TICKET (itm-705/706): rechts, so breit wie LIA selbst, die unten in dieser Spalte sitzt. Was LIA vom Ticket
   hält und was sie antworten würde, steht über ihr; die Spalte endet dort, wo das Dock beginnt (`--dock-h`, vom Skript gemessen).
   DREI SPALTEN WIE IM ENTWURF (itm-722): Liste, Verlauf und LIA etwa 23 : 37 : 40. */

@media (min-width: 1181px) {
    .hp-tickets {
        grid-template-columns: minmax(240px, 0.23fr) minmax(0, 0.37fr) minmax(0, 0.4fr);
        grid-template-rows: minmax(0, 1fr);
        grid-template-areas: "liste detail lia";
    }

    .hp-tickets > .hp-ticketdetail {
        border-bottom: 0;
        border-right: 1px solid var(--b-linie);
    }
}

/* SCHMAL (unter 900 px): alles untereinander, und der Bereich rollt als Ganzes — die Liste mit eigener Höhe obenauf. */
@media (max-width: 900px) {
    .hp-tickets {
        display: flex;
        flex-direction: column;
        height: auto;
    }

    .hp-tickets > .hp-ticketliste {
        max-height: 300px;
        border-right: 0;
        border-bottom: 1px solid var(--b-linie);
    }

    .hp-tickets .hp-ticketdetail,
    .hp-tickets .hp-verlauf,
    .hp-tickets .hp-liaspalte {
        overflow: visible;
    }
}

/* DIE SPALTE PASST OHNE ROLLBALKEN IN DIE HÖHE (Martin 08.10.2026: „wenn wir rechts das alles darstellen, wäre es gut wenn da
   keine scrollbar kommt"). Bis dahin rollte die ganze Spalte, und das Textfeld (150 px bis 36vh) rollte noch einmal in sich. JETZT
   steht die Einschätzung knapp in ihrer eigenen Höhe, die Antwortkarte nimmt den Rest, und darin wächst und schrumpft das Textfeld
   (`flex: 1`, mindestens 90 px) — es rollt nur, wenn der Text länger ist. Knöpfe, Textbausteine und „Überarbeiten“ stehen darunter
   immer im Bild, unten bleibt Platz für LIA (`--dock-platz`). Erst wenn auch das Mindeste nicht hineinpasst, rollt die Spalte. */
.hp-liaspalte {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: 0;
    overflow: auto;
    padding: 14px 16px var(--dock-platz, 84px);
}

.hp-liaspalte > .hp-antwortkarte:has(> .hp-antwort-text) {
    flex: 1 0 auto;
}

.hp-liaspalte .hp-einschaetzung,
.hp-liaspalte .hp-antwortkarte {
    gap: 8px;
    padding: 12px 16px 14px;
}

.hp-liaspalte .hp-spalten-titel {
    margin: 0 -16px;
    padding: 0 16px 10px;
    font-size: 15px;
}

.hp-liaspalte .hp-korb {
    grid-template-columns: 84px minmax(0, 1fr);
}

.hp-liaspalte .hp-korb h4 {
    line-height: 21px;
}

.hp-liaspalte .hp-anliegen,
.hp-liaspalte .hp-korb ul {
    font-size: 15px;
    line-height: 1.4;
}

.hp-liaspalte .hp-korb ul {
    gap: 2px;
}

/* „AN …“ UND DER BETREFF IN EINER ZEILE — der Betreff endet mit „…“, ganz steht er im Verlauf. */
.hp-liaspalte .hp-antwort-an {
    flex-wrap: nowrap;
    white-space: nowrap;
}

.hp-liaspalte .hp-antwort-betreff {
    flex: 1 1 0;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hp-liaspalte .hp-antwort-betreff::before {
    content: "· ";
}

.hp-liaspalte .hp-antwortkarte > * {
    flex: none;
}

.hp-liaspalte .hp-antwortkarte > .hp-antwort-text {
    flex: 1 1 0;
    min-height: 90px;
    max-height: none;
    resize: none;
}

.hp-liaspalte .tb-waehler {
    margin: 0;
}

.hp-liaspalte .tb-waehler .tb-meldung:empty {
    display: none;
}

.hub-panel .hp-liaspalte .tb-waehler button.ghost {
    min-height: 32px;
    padding: 4px 12px;
}

.hub-panel .hp-liaspalte button.primaer:not(.gross),
.hub-panel .hp-liaspalte button.ghost {
    min-height: 40px;
    padding: 8px 14px;
}

.hub-panel .hp-liaspalte .hp-umschreiben input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]) {
    padding: 8px 12px;
}

.hp-liaspalte .hp-antwort-fuss {
    font-size: 12px;
}

/* ZWEISPALTIG (bis 1180 px) steht die Spalte unter dem Verlauf und hat nur gut die halbe Höhe — dort reicht der Platz nicht, und sie
   rollt. Dann wächst das Textfeld mit seinem Text, statt ein zweites Mal in sich zu rollen. */
@media (max-width: 1180px) {
    .hp-liaspalte > .hp-antwortkarte:has(> .hp-antwort-text) {
        flex: none;
    }

    .hp-liaspalte .hp-antwortkarte > .hp-antwort-text {
        flex: none;
        field-sizing: content;
    }
}

.hp-spalten-titel {
    margin: 0 -18px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 18px 14px;
    border-bottom: 1px solid #ecedf1;
    font: 600 16px/1 var(--b-schrift);
    color: var(--b-navy);
}

.hp-spalten-titel .hp-zeit {
    margin-left: auto;
}

/* DER FUNKE: LIAs Zeichen vor ihren Überschriften. */
.hp-lia-punkt {
    flex: none;
    width: 14px;
    height: 14px;
    background: var(--b-glut);
    clip-path: polygon(50% 0, 60% 40%, 100% 50%, 60% 60%, 50% 100%, 40% 60%, 0 50%, 40% 40%);
}

.hp-einschaetzung,
.hp-antwortkarte {
    flex: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px 18px 18px;
    border-radius: 4px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
}

/* DIE EINSCHÄTZUNG ALS TABELLE: links ANLIEGEN / WICHTIG / ZU TUN, rechts was LIA dazu sagt; „Wichtig“ in Rot. */
.hp-korb {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    column-gap: 8px;
    align-items: start;
}

.hp-anliegen {
    margin: 0;
    font-size: 16px;
    line-height: 1.4;
    color: var(--b-text);
    text-wrap: pretty;
}

.hp-korb h4 {
    margin: 0;
    font: 700 12px/22px var(--b-schrift);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--b-leise);
}

.hp-korb ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 3px;
    font-size: 16px;
    line-height: 1.4;
    color: var(--b-text);
}

/* „WICHTIG“ IST KEIN FEHLER (itm-733): Navy und fett, mit der orangen Kante, weil LIA es so eingeschätzt hat — Rot gehört nur
   zu dem, was schiefging. */
.hp-korb.wichtig ul {
    padding-left: 10px;
    border-left: 3px solid var(--b-glut);
    color: var(--b-navy);
    font-weight: 700;
}

.hp-korb li {
    animation: hp-blase 0.45s calc(var(--i, 0) * 60ms + 120ms) cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.hp-antwortkarte.bereit {
    animation: hp-blase 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.hp-antwortkarte.schreibt {
    border-color: var(--b-glut-rand);
    background: linear-gradient(110deg, var(--b-flaeche) 30%, var(--b-glut-flaeche) 50%, var(--b-flaeche) 70%);
    background-size: 260% 100%;
    animation: hp-schimmer 1.7s linear infinite;
}

@keyframes hp-schimmer {
    from { background-position: 100% 0; }
    to { background-position: -160% 0; }
}

.hp-schreibt {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 2px;
    font-weight: 600;
    color: var(--b-glut-text);
}

.hp-schreibt-punkte {
    flex: none;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--b-glut);
    box-shadow: 0 0 0 0 rgba(240, 138, 28, 0.6);
    animation: hub-puls 1.3s infinite;
}

.hp-antwort-an {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 2px 6px;
    font-size: 14px;
    color: var(--b-leise);
}

.hp-antwort-an b {
    color: var(--b-text);
}

.hp-antwort-betreff {
    flex-basis: 100%;
    font-size: 13px;
    overflow-wrap: anywhere;
}

.hp-antwort-wunsch {
    margin: 0;
    font-size: 13px;
    font-style: italic;
    color: var(--b-glut-text);
}

/* DER ENTWURF: hell mit oranger Kante — LIA hat ihn geschrieben. */
.hp-antwort-text {
    width: 100%;
    min-height: 150px;
    max-height: 36vh;
    resize: vertical;
    padding: 12px 16px;
    border-radius: 0;
    border: 1px solid var(--b-linie);
    border-left: 3px solid var(--b-glut);
    background: #fffcf8;
    color: var(--b-text);
    font: inherit;
    font-size: 16px;
    line-height: 1.5;
}

.hp-antwort-text:focus-visible,
.hp-umschreiben input:focus-visible,
.hp-antwort-los input:focus-visible {
    outline: 2px solid var(--b-navy);
    outline-offset: 1px;
}

.hp-antwortkarte.geaendert .hp-antwort-text {
    border-color: var(--b-navy);
    border-left-color: var(--b-glut);
}

/* ÜBERARBEITEN MIT EINEM KLICK (Martin, 09.10.2026): kleine Vorschläge unter dem Entwurf statt Textbausteinen. */
.hp-vorschlaege {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 8px 0 4px;
}

.hub-panel .hp-vorschlaege button.hp-vorschlag {
    min-height: 30px;
    padding: 4px 12px;
    border: 1px solid var(--b-linie);
    border-radius: 15px;
    background: #fff;
    color: var(--b-navy);
    font: 600 13px/1.2 var(--b-schrift);
    cursor: pointer;
}

.hub-panel .hp-vorschlaege button.hp-vorschlag:hover {
    border-color: var(--b-navy);
}

.hub-panel .hp-vorschlaege button.hp-vorschlag:focus-visible {
    outline: 2px solid var(--b-navy);
    outline-offset: 1px;
}

.hp-antwort-knoepfe,
.hp-umschreiben {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.hp-antwort-knoepfe > button {
    flex: 1 1 0;
}

.hp-antwort-knoepfe > button.primaer {
    flex-grow: 1.6;
}

.hp-antwort-los {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* GEGEN DIE EINGABEFELDER DER KONSOLE (`input:not(…)` wiegt vier Klassen). */
.hub-panel .hp-umschreiben input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
.hub-panel .hp-antwort-los input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]) {
    height: auto;
    box-shadow: none;
    flex: 1 1 160px;
    min-width: 0;
    padding: 10px 14px;
    border-radius: 3px;
    border: 1px solid var(--b-linie-2);
    background: var(--b-flaeche);
    color: var(--b-text);
    font: inherit;
    font-size: 14px;
}

/* UNTEREINANDER: die Grundlänge 160px wäre hier die Höhe. */
.hub-panel .hp-antwort-los input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]) {
    flex: none;
}

.hub-panel button.primaer.gross {
    justify-content: center;
    gap: 8px;
    min-height: 52px;
    padding: 12px 20px;
    font-size: 16px;
}

.hub-panel button.primaer.gross::before {
    content: "✦ ";
    color: var(--b-glut);
}

.hp-antwort-fuss {
    margin: 0;
    font-size: 13px;
    color: var(--b-leise);
}

.hp-antwort-problem {
    margin: 0;
    font-size: 14px;
    color: #b01c14;
}

.hp-antwort-meldung:empty {
    display: none;
}

.hp-leer.klein {
    margin: 0;
    font-size: 14px;
}

.hp-lia-marke.entwurf {
    animation: hp-glimmen 2.6s ease-in-out infinite;
}

@keyframes hp-glimmen {
    50% { box-shadow: 0 0 0 3px rgba(240, 138, 28, 0.18); }
}

@media (prefers-reduced-motion: reduce) {
    .hp-antwortkarte.schreibt,
    .hp-schreibt-punkte,
    .hp-lia-marke.entwurf,
    .hp-korb li,
    .hp-antwortkarte.bereit {
        animation: none;
    }
}

/* DAS PROTOKOLL (itm-708): der Recap für den Saal. Oben gezählt, darunter eine Zeitleiste; die gewählte Zeile steht groß, was davor
   liegt, tritt zurück. Rechts bleibt Platz für LIA im Dock. */

.hp-inhalt.hp-proto {
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow: hidden;
}

.hp-proto-zahlen {
    flex: none;
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 12px;
}

.hp-proto-zahl {
    display: grid;
    grid-template-columns: auto auto;
    grid-template-rows: auto auto;
    align-items: center;
    column-gap: 12px;
    padding: 14px 20px 14px 16px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    animation: hp-blase 0.5s calc(var(--i, 0) * 90ms) cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.hp-proto-zahl .hp-proto-zeichen {
    grid-row: span 2;
    width: 30px;
    height: 30px;
}

.hp-proto-zahl b {
    font-size: 38px;
    font-weight: 300;
    color: var(--b-navy);
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.hp-proto-zahl span {
    font-size: 13px;
    font-weight: 400;
    color: var(--b-leise);
}

.hp-proto-fragen {
    align-self: center;
    margin: 0 0 0 6px;
    font-size: 14px;
    font-weight: 700;
    color: var(--b-glut-text);
}

.hp-proto-liste {
    flex: 1 1 0;
    min-height: 0;
    margin: 0;
    /* BIS ÜBER LIA RECHTS UNTEN rollbar (itm-733): Unten bleibt so viel Platz, wie sie braucht (`--dock-platz`). */
    padding: 6px 0 var(--dock-platz, 24px) 0;
    list-style: none;
    overflow: auto;
    display: flex;
    flex-direction: column;
    position: relative;
}

.hp-proto-zeile {
    position: relative;
    display: grid;
    grid-template-columns: 52px 40px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding: 9px 14px 9px 6px;
    border-radius: 3px;
    cursor: pointer;
    transition: background 0.25s, transform 0.25s, opacity 0.25s;
    animation: hp-blase 0.45s calc(var(--i, 0) * 45ms) cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

/* DIE LINIE DER ZEIT läuft durch die Zeichen. */
.hp-proto-zeile::before {
    content: "";
    position: absolute;
    left: 83px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--b-linie);
}

.hp-proto-zeile:first-child::before {
    top: 50%;
}

.hp-proto-zeile:last-child::before {
    bottom: 50%;
}

.hp-proto-zeile:hover {
    background: var(--b-flaeche);
}

.hp-proto-zeile:focus-visible {
    outline: 2px solid var(--b-glut);
    outline-offset: 2px;
}

.hp-proto-zeile .hp-zeit {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.hp-proto-zeile .hp-proto-zeichen {
    position: relative;
    z-index: 1;
    width: 36px;
    height: 36px;
    padding: 7px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
}

.hp-proto-zeichen {
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    color: var(--b-leise);
}

.art-ticket .hp-proto-zeichen { color: var(--b-navy); }
.art-termin .hp-proto-zeichen { color: var(--b-gut); }
.art-scaliento .hp-proto-zeichen,
.art-aufgabe .hp-proto-zeichen,
.art-start .hp-proto-zeichen,
.art-fertig .hp-proto-zeichen { color: var(--b-glut-text); }
.art-frage .hp-proto-zeichen,
.art-entscheidung .hp-proto-zeichen { color: var(--b-navy); }

.hp-proto-text {
    font-size: 14px;
    line-height: 1.4;
    overflow-wrap: anywhere;
}

.hp-proto-zeile.art-start .hp-proto-text,
.hp-proto-zeile.art-fertig .hp-proto-text {
    font-weight: 600;
    color: var(--b-navy);
}

/* EINE RÜCKFRAGE IST KEIN FEHLER (itm-733): Navy und fett mit der orangen Kante von LIA, statt Rot. */
.hp-proto-zeile.art-frage,
.hp-proto-zeile.art-entscheidung {
    box-shadow: inset 3px 0 0 var(--b-glut);
}

.hp-proto-zeile.art-frage .hp-proto-text,
.hp-proto-zeile.art-entscheidung .hp-proto-text {
    font-weight: 600;
    color: var(--b-navy);
}

/* DIE GEWÄHLTE ZEILE: groß und orange gerahmt — was davor liegt, ist erledigt und tritt zurück. */
.hp-proto-zeile.an {
    background: var(--b-flaeche);
    box-shadow: inset 4px 0 0 var(--b-glut), 0 0 0 1px var(--b-linie), 0 18px 36px -22px var(--b-schatten);
}

.hp-proto-zeile.an .hp-proto-text {
    font-size: 18px;
    font-weight: 600;
    color: var(--b-navy);
}

.hp-proto-zeile.vorbei {
    opacity: 0.55;
}

@media (prefers-reduced-motion: reduce) {
    .hp-proto-zahl,
    .hp-proto-zeile {
        animation: none;
        transition: none;
    }
}

/* DER KALENDER steht seit itm-733 unten bei `.lk` — derselbe wie im Rahmen von Scaliento (lia-kalender.js). */

/* AUFGABEN */

.hp-aufgaben {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
    align-items: start;
    padding-bottom: var(--dock-platz, 24px);
}

.hp-gruppe-titel {
    margin: 0 0 10px;
    font: 700 12px/1.3 var(--b-schrift);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--b-leise);
}

/* ÜBERFÄLLIG IN NAVY, NICHT ROT (itm-733, Martin 07.10.2026: Rot nur für Fehler) — eine verpasste Frist ist Arbeit, kein Fehler. */
.hp-gruppe.rot .hp-gruppe-titel { color: var(--b-navy); }
.hp-gruppe.orange .hp-gruppe-titel { color: var(--b-glut-text); }
.hp-gruppe.leise { opacity: 0.7; }

.hp-aufgabenliste {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.hp-aufgabe {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    animation: hp-blase 0.45s calc(var(--i, 0) * 60ms) both;
}

.hp-aufgabe.lia {
    box-shadow: inset 3px 0 0 var(--b-glut);
}

.hp-aufgabe.erledigt .hp-aufgabe-text b {
    text-decoration: line-through;
    opacity: 0.7;
}

.hp-haken svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: var(--b-navy);
    stroke-width: 1.8;
}

.hp-aufgabe.erledigt .hp-haken svg {
    stroke: var(--b-gut);
}

.hp-aufgabe-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
    min-width: 0;
}

.hp-aufgabe-text b {
    font-size: 14px;
    font-weight: 600;
    color: var(--b-text);
}

.hp-aufgabe-text span {
    color: var(--b-leise);
    font-size: 13px;
}

/* SCALIENTO: je Eintrag eine Karte, wie er dort ankommt. */

.hp-scaliento {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 440px), 1fr));
    gap: 18px;
    padding-bottom: var(--dock-platz, 24px);
}

.hp-sc-karte {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 18px 20px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    box-shadow: 0 24px 50px -30px rgba(31, 34, 64, 0.25);
    animation: hp-blase 0.5s calc(var(--i, 0) * 80ms) both;
}

.hp-sc-kopf {
    display: flex;
    align-items: center;
    gap: 10px;
}

.hp-sc-zeichen {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: var(--b-glut-flaeche);
    color: var(--b-glut-text);
}

.hp-sc-zeichen svg {
    width: 22px;
    height: 22px;
}

.hp-sc-karte.art-datenpanne .hp-sc-zeichen {
    background: #fdecea;
    color: #b01c14;
}

.hp-sc-art {
    font-weight: 800;
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--b-leise);
    flex: 1;
}

.hp-sc-titel {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--b-navy);
    line-height: 1.25;
}

.hp-sc-angaben {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 6px 14px;
    margin: 0;
    font-size: 14px;
}

.hp-sc-angaben dt {
    color: var(--b-leise);
}

.hp-sc-angaben dd {
    margin: 0;
}

.hp-sc-fuss {
    margin: 4px 0 0;
    color: var(--b-leise);
    font-size: 13px;
}

/* EINSTELLUNGEN UND REGIE */

.hp-regie {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    gap: 18px;
    align-items: start;
    /* BIS ÜBER LIA RECHTS UNTEN scrollbar — die Hörprobe darf nicht unter ihr liegen. */
    padding-bottom: var(--dock-platz, 24px);
}

/* DIE EINSTELLUNGEN VOR PUBLIKUM (Martin 08.10.2026: „die seite einstellungen auf der bühne gehört auch noch behübscht, weil es
   wird einen kurzen moment geben, wo daniel die offen hat“). Karten wie in den Berichten — weiß, leicht schwebend, der Titel als
   kleine Großbuchstaben-Zeile —, links die Showcases, rechts eine eigene Spalte: „Im Saal“ (Zuhören und der Dank ans Publikum,
   ein Speichern für beides). Vorher streckten sich die rechten Karten an der Höhe der Showcases, und zwischen ihnen klafften
   Lücken. Die Fragen aus dem Publikum stehen darunter über die ganze Breite (12.10.2026) — in der Spalte waren sie gequetscht. */
.hp-regie-rechts {
    display: flex;
    flex-direction: column;
    gap: 18px;
    min-width: 0;
}

.hp-regie > .hp-freigabe {
    grid-column: 1 / -1;
}

.hp-regie .hp-freigabe-liste {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr));
    gap: 14px;
    align-items: start;
}

.hp-regie .hp-freigabe-liste > .hp-hinweis {
    grid-column: 1 / -1;
}

.hp-regie .hp-frei {
    padding: 16px 18px;
}

.hp-regie .hp-frei-frage {
    color: var(--b-text-2);
    font-size: 15px;
    line-height: 1.45;
}

.hub-panel .hp-regie .hp-frei textarea {
    width: 100%;
    max-width: none;
    min-height: 96px;
    resize: vertical;
}

.hp-regie .hp-block {
    gap: 12px;
    padding: 18px 20px 20px;
    border: 0;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(31, 34, 64, 0.06), 0 10px 28px -18px rgba(31, 34, 64, 0.35);
}

.hp-regie .hp-block-titel {
    font: 700 13px/18px var(--b-schrift);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--b-leise);
}

.hp-block-teil {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.hp-block-teil + .hp-block-teil {
    padding-top: 12px;
    border-top: 1px solid #ecedf1;
}

.hp-regie .hp-feld {
    margin: 0;
}

.hp-teil-titel {
    margin: 0;
    font: 600 16px/1.3 var(--b-schrift);
    color: var(--b-navy);
}

.hp-block-fuss {
    padding-top: 12px;
    border-top: 1px solid #ecedf1;
}

/* DER SCHALTER LESBAR AUCH BEI DUNKLEM SYSTEM: `label:has(> input[type="checkbox"])` der Konsole wiegt mehr als `.hp-schalter` und
   färbte den Text mit `--ink` — bei dunkel eingestelltem Rechner fast weiß auf weißer Karte. Die Bühne ist immer hell. */
.hub-panel label.hp-schalter {
    color: var(--b-text);
    font-size: 15px;
    font-weight: 600;
}

.hp-regie .hp-feld > span {
    font-weight: 400;
    color: var(--b-text-2);
}

/* EIN SHOWCASE IN EINER ZEILE: Nummer, Titel mit Satz, rechts der Knopf. Der aktive bekommt seine Knöpfe darunter — es sind bis
   zu drei. Schmal (Hub einspaltig unter 760 px) stehen sie immer darunter. */
.hp-regie .hp-showcase {
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 6px 16px;
    padding: 14px 16px;
}

.hp-regie .hp-showcase-nr {
    grid-row: 1;
}

.hp-regie .hp-showcase-knoepfe {
    grid-column: 3;
    grid-row: 1;
    justify-content: flex-end;
}

.hp-regie .hp-showcase.aktiv .hp-showcase-knoepfe {
    grid-column: 2 / -1;
    grid-row: 2;
    justify-content: flex-start;
}

/* DIE KNÖPFE UNTER DEN SHOWCASES (Martin, 12.10.2026: „schöner, und klarer"): zwei Gruppen — „Vorführung" ändert keine Daten,
   „Zurücksetzen" schon und steht deshalb mit roter Kante abgesetzt darunter. Je Zeile der Knopf in fester Breite, daneben ein
   Satz; die Knöpfe stehen bündig untereinander. Eine aufgeklappte Rückfrage nimmt die ganze Zeile. */
.hp-regie .hp-showcases > .hp-aktionen:first-of-type {
    margin-top: 6px;
    padding-top: 16px;
    border-top: 1px solid #ecedf1;
}

.hp-aktionen {
    gap: 10px;
}

.hp-aktion {
    display: grid;
    grid-template-columns: 236px minmax(0, 1fr);
    align-items: center;
    gap: 8px 16px;
}

.hp-aktion-hinweis {
    color: var(--b-leise);
    font-size: 14px;
    line-height: 1.4;
}

.hp-aktion-voll,
.hp-aktion > .hp-frei-frage-box {
    grid-column: 1 / -1;
}

.hub-panel .hp-aktion > .hp-aktion-knopf {
    width: 100%;
    min-height: 40px;
    padding: 8px 14px;
    justify-content: flex-start;
    font-size: 14px;
}

/* DER SYSTEMCHECK IST EIN LINK, sieht aber aus wie die Knöpfe daneben. */
.hub-panel a.hp-aktion-knopf {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--b-linie-2);
    border-radius: 3px;
    background: var(--b-flaeche);
    color: var(--b-navy);
    font: 600 14px/1.2 var(--b-schrift);
    text-decoration: none;
    transition: transform 0.15s, border-color 0.25s;
}

.hub-panel a.hp-aktion-knopf:hover {
    border-color: var(--b-navy);
    transform: translateY(-1px);
}

.hp-block-teil + .hp-aktionen.hp-gefahr {
    margin-top: 6px;
    padding-top: 14px;
    border-top: 1px solid #f3c9c6;
}

.hp-aktionen.hp-gefahr .hp-teil-titel {
    color: #a61b13;
}

.hub-panel button.ghost.gefahr {
    border-color: #e6a29d;
    color: #a61b13;
}

.hub-panel button.ghost.gefahr:hover:not(:disabled) {
    border-color: var(--b-halt);
    background: #fff;
}

.hub-panel button.primaer.gefahr {
    border-color: #b81d15;
    background: #b81d15;
}

@media (max-width: 560px) {
    .hp-aktion {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* DIE SEKUNDEN IN EINER ZEILE: Beschriftung links, das schmale Zahlenfeld rechts. */
.hp-saal .hp-feld:has(> input[type="number"]) {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin: 0;
}

.hub-panel .hp-regie .hp-saal .hp-feld input[type="number"]:not([type="checkbox"]):not([type="radio"]) {
    flex: none;
    width: 96px;
    text-align: right;
}

@media (max-width: 760px) {
    .hp-regie .hp-showcase-knoepfe {
        grid-column: 2 / -1;
        grid-row: 2;
        justify-content: flex-start;
    }
}

.hub-panel .hp-regie .hp-feld textarea {
    width: 100%;
    max-width: none;
    min-height: 64px;
}

.hp-block {
    padding: 18px 20px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.hp-block.leise {
    opacity: 0.85;
}

.hp-block-titel {
    margin: 0;
    font: 300 22px/1.2 var(--b-schrift);
    color: var(--b-navy);
}

.hp-hinweis {
    margin: 0;
    color: var(--b-leise);
    font-size: 14px;
}

.hp-hinweis a {
    color: var(--b-glut-text);
}

.hp-showcase {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 6px 16px;
    padding: 16px;
    border-radius: 3px;
    background: var(--b-flaeche-2);
    border: 1px solid var(--b-linie);
    transition: border-color 0.3s, background 0.3s;
}

.hp-showcase.aktiv {
    background: var(--b-flaeche);
    border-color: var(--b-linie);
    box-shadow: inset 4px 0 0 var(--b-glut), 0 12px 28px -18px var(--b-schatten);
}

.hp-showcase-nr {
    grid-row: span 2;
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie-2);
    font: 300 28px/1 var(--b-schrift);
    color: var(--b-navy);
}

.hp-showcase.aktiv .hp-showcase-nr {
    background: var(--b-navy);
    border-color: var(--b-navy);
    color: #fff;
}

.hp-showcase-text b {
    font-size: 16px;
    font-weight: 600;
    color: var(--b-navy);
}

.hp-showcase-text p {
    margin: 4px 0 0;
    color: var(--b-leise);
    font-size: 14px;
    line-height: 1.45;
}

.hp-showcase-knoepfe {
    grid-column: 2;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

/* DER NOTWEG, EINGEKLAPPT (Martin, 09.10.2026): „▶ Fall starten" steht erst nach einem Klick auf „Notfall" da. */
.hp-notweg summary {
    cursor: pointer;
    color: var(--ink-muted);
    font-size: var(--t-sm);
    list-style-position: inside;
}

.hp-notweg[open] {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

/* DIE KNÖPFE DER BEREICHE ALS KLEINE AKTIONSKACHELN (itm-725): der nächste Schritt Navy mit oranger Unterkante, die übrigen
   weiß mit Linie; ein dünnes Zeichen rechts, wo eines passt (lia-hub.js). */
.hub-panel button.primaer,
.hub-panel button.ghost {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 44px;
    padding: 10px 16px;
    border-radius: 3px;
    font: 600 14px/1.2 var(--b-schrift);
    text-align: left;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.25s, background 0.25s;
}

/* PRIMÄR WIE IN SCALIENTO (itm-733): Navy, eckig, ohne orange Unterkante — Orange gehört LIA. */
.hub-panel button.primaer {
    border: 1px solid var(--b-navy);
    color: #fff;
    background: var(--b-navy);
    box-shadow: none;
}

.hub-panel button.primaer.los {
    animation: hub-puls 2.2s infinite;
}

.hub-panel button.ghost {
    border: 1px solid var(--b-linie-2);
    background: var(--b-flaeche);
    color: var(--b-navy);
}

.hp-knopf-zeichen svg {
    display: block;
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.hub-panel button.nein .hp-knopf-zeichen {
    color: var(--b-halt);
}

.hub-panel button.ghost.klein {
    align-self: flex-start;
    font-size: 13px;
    padding: 6px 12px;
}

.hub-panel button:hover:not(:disabled) {
    transform: translateY(-1px);
}

.hub-panel button:disabled {
    opacity: 0.55;
    cursor: progress;
}

.hp-schalter {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    /* LESBAR (itm-733): Die Beschriftung erbte das blasse Grau der Konsole. */
    color: var(--b-text);
    cursor: pointer;
}

.hp-schalter input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
}

.hp-schalter-bahn {
    position: relative;
    flex: none;
    width: 46px;
    height: 26px;
    border-radius: 13px;
    background: var(--b-linie-2);
    transition: background 0.25s;
}

.hp-schalter-bahn::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    transition: transform 0.25s cubic-bezier(0.3, 1.4, 0.5, 1);
}

.hp-schalter input:checked + .hp-schalter-bahn {
    background: var(--b-navy);
}

.hp-schalter input:checked + .hp-schalter-bahn::after {
    transform: translateX(20px);
}

.hp-schalter input:focus-visible + .hp-schalter-bahn {
    outline: 3px solid var(--b-glut);
    outline-offset: 2px;
}

.hp-feld {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 14px;
    color: var(--b-leise);
}

.hp-feld input,
.hp-feld textarea {
    padding: 9px 12px;
    border-radius: 3px;
    border: 1px solid var(--b-linie-2);
    background: var(--b-flaeche);
    color: var(--b-text);
    font: inherit;
    font-size: 14px;
}

/* GEGEN DIE EINGABEFELDER DER KONSOLE: `input:not(…)` wiegt vier Klassen, `.hp-feld input` nur eine — ohne das stehen helle
   Felder auf der dunklen Bühne. */
.hub-panel .hp-feld input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):not([type="range"]),
.hub-panel .hp-probe input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):not([type="range"]) {
    height: auto;
    padding: 9px 12px;
    border-radius: 3px;
    border: 1px solid var(--b-linie-2);
    background: var(--b-flaeche);
    color: var(--b-text);
    box-shadow: none;
    font: inherit;
    font-size: 14px;
    width: 100%;
    max-width: none;
}

.hub-panel .hp-feld textarea {
    resize: vertical;
    line-height: 1.45;
}

/* PERSONA UND STIMME (itm-704, itm-664): über die ganze Breite, drei Spalten — wer LIA ist, wie sie spricht, wie sie klingt. */

.hp-regie .hp-persona {
    grid-column: 1 / -1;
}

/* VERSTECKT IST VERSTECKT — auch wo eine Regel display setzt. */
.hub-panel [hidden] {
    display: none !important;
}

.hp-persona-spalten {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.hp-persona-spalte {
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
}

.hp-persona-spalte h4 {
    margin: 0;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--b-leise);
}

.hp-regler {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 14px;
    color: var(--b-leise);
}

.hp-regler-kopf {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.hp-regler-kopf b {
    color: var(--b-text);
    font-weight: 700;
}

.hub .hub-panel .hp-regler input[type="range"]:not([hidden]):not([disabled]) {
    width: 100%;
    max-width: none;
    height: auto;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    accent-color: var(--b-navy);
}

.hp-wahl {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.hub-panel .hp-wahl-knopf {
    padding: 7px 14px;
    border-radius: 3px;
    border: 1px solid var(--b-linie-2);
    background: transparent;
    color: var(--b-text);
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}

.hub-panel .hp-wahl-knopf:hover {
    background: var(--b-flaeche);
}

.hub-panel .hp-wahl-knopf.an {
    background: var(--b-navy);
    border-color: var(--b-navy);
    color: #fff;
}

.hp-fein summary {
    cursor: pointer;
    color: var(--b-leise);
    font-size: 14px;
    font-weight: 700;
}

.hp-fein[open] {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hp-stimmen {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 230px;
    overflow: auto;
    padding-right: 4px;
}

.hp-stimme {
    display: flex;
    align-items: stretch;
    gap: 6px;
}

.hub-panel .hp-stimme-wahl {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    padding: 8px 12px;
    border-radius: 3px;
    border: 1px solid var(--b-linie-2);
    background: var(--b-flaeche);
    color: var(--b-text);
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.hp-stimme-wahl b {
    font-size: 14px;
}

.hp-stimme-wahl span {
    font-size: 12px;
    color: var(--b-leise);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

.hp-stimme.an .hp-stimme-wahl {
    background: #eef0f7;
    border-color: var(--b-navy);
    box-shadow: inset 3px 0 0 var(--b-navy);
}

.hub-panel .hp-stimme-hoeren {
    flex: none;
    width: 40px;
    border-radius: 3px;
    border: 1px solid var(--b-linie-2);
    background: transparent;
    color: var(--b-glut-text);
    font-size: 14px;
    cursor: pointer;
}

.hp-klang {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 16px;
}

.hp-probe {
    display: flex;
    gap: 8px;
}

.hp-probe input {
    flex: 1 1 auto;
    min-width: 0;
}

.hp-probe button {
    flex: none;
    white-space: nowrap;
}

.hp-hinweis.warnung {
    color: #b01c14;
}

@media (max-width: 1180px) {
    .hp-persona-spalten {
        grid-template-columns: minmax(0, 1fr);
    }
}

.hp-feld input[type="number"] {
    max-width: 120px;
}

.hp-reihe {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hp-meldung {
    color: var(--b-gut);
    font-size: 14px;
}

/* ----- LIA RECHTS UNTEN ----- */
/* LEICHT GLÄSERN UND SCHWEBEND (itm-722): Das Dock liegt über der Arbeit, darum als einziges mit Schatten und Glas; oben die
   orange Kante, weil es LIA ist. Ihr Satz groß genug für den Saal, ihre Kacheln wie auf der Bühne, nur kleiner. */

/* SCHMALER UND NIEDRIGER (itm-733): 420 statt 592 px breit, die Kacheln als eine Reihe kleiner Knöpfe. Was darunter liegt,
   rollt bis über sie (`--dock-h`, lia-hub.js misst ihre Höhe). */
.hub-dock {
    position: absolute;
    right: 20px;
    bottom: 16px;
    z-index: 20;
    width: min(420px, calc(100% - 32px));
    max-height: calc(100% - var(--hub-leiste) - 40px);
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px 14px 14px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid var(--b-linie);
    border-top: 3px solid var(--b-glut);
    box-shadow: 0 28px 56px -18px var(--b-schatten), 0 2px 6px rgba(31, 34, 64, 0.06);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    color: var(--b-text);
    animation: hub-dock-rein 0.55s cubic-bezier(0.2, 0.9, 0.2, 1.15) both;
}

@keyframes hub-dock-rein {
    from { opacity: 0; transform: translateY(30px) scale(0.96); }
}

.hub-dock-kopf {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--b-text);
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.hub-dock-oben {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hub-dock-oben .hub-dock-kopf {
    flex: 1 1 auto;
    min-width: 0;
    justify-content: flex-start;
}

.hub-dock-klappen {
    flex: none;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    padding: 0;
    border-radius: 3px;
    border: 1px solid var(--b-linie-2);
    background: var(--b-flaeche);
    color: var(--b-navy);
    cursor: pointer;
}

.hub-dock-klappen:hover {
    color: var(--b-navy);
    background: var(--b-flaeche-2);
}

.hub-dock-klappen svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 0.25s;
}

.hub-dock:not(.klein) .hub-dock-klappen svg {
    transform: rotate(180deg);
}

/* EINGEKLAPPT EINE PILLE IN DER ECKE (itm-712, itm-733, Martin: „Dass LIA zugeklappt noch kleiner ist, um uns nicht zu stören im
   Kalender und in den Tickets"): eine Zeile, gut 56 px hoch — Bild, Stand, ihr letzter Satz in einer Zeile, Mikro und Aufklappen.
   Die Kacheln einer Frage und das Eingabefeld kommen erst aufgeklappt; „wartet auf dich“ sagt der Stand. `--dock-h` misst diese
   Höhe, also rollt jeder Bereich nur so weit über sie hinaus. */
.hub-dock.klein {
    flex-direction: row;
    align-items: center;
    gap: 10px;
    width: auto;
    max-width: min(400px, calc(100% - 32px));
    min-height: 56px;
    padding: 8px 8px 8px 10px;
    border-radius: 28px;
    border-top-width: 1px;
    box-shadow: inset 0 3px 0 -1px var(--b-glut), 0 16px 32px -16px var(--b-schatten), 0 2px 6px rgba(31, 34, 64, 0.06);
}

.hub-dock.klein .hub-dock-oben {
    display: contents;
}

.hub-dock.klein .hub-dock-kopf { order: 0; flex: none; gap: 8px; }
.hub-dock.klein .hub-dock-text { order: 1; }
.hub-dock.klein .hub-dock-eingabe { order: 2; }
.hub-dock.klein .hub-dock-klappen { order: 3; border-radius: 50%; }

.hub-dock.klein .hub-dock-bild {
    width: 38px;
    height: 38px;
    border-radius: 50%;
}

/* DER NAME FÄLLT WEG, der Stand bleibt — er sagt, ob LIA wartet, spricht oder zuhört. */
.hub-dock.klein .hub-dock-name {
    font-size: 0;
    letter-spacing: 0;
    gap: 0;
}

.hub-dock.klein .hub-dock-du,
.hub-dock.klein .hub-dock-optionen,
.hub-dock.klein .hub-dock-eingabe input {
    display: none !important;
}

.hub-dock.klein .hub-dock-mikro {
    width: 38px;
    height: 38px;
}

.hub-dock.klein .hub-dock-text {
    flex: 1 1 auto;
    min-width: 0;
    max-height: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
    line-height: 1.3;
    color: var(--b-text-2);
    cursor: pointer;
}

.hub-dock.klein .hub-dock-text .lia-frage {
    display: inline;
}

/* IM RAHMEN VON SCALIENTO schwebt unten rechts dessen Menüknopf (56 px, 24 px vom Rand) — LIA hält 88 px Abstand. */
.hub.im-rahmen .hub-dock {
    right: 88px;
}

.hub-dock.klein .hub-dock-text:empty {
    display: none;
}

/* DAS BILD: das Logo im hellen Rahmen mit orangem Ring, eckig wie auf der Bühne. */
.hub-dock-bild {
    position: relative;
    flex: none;
    width: 36px;
    height: 36px;
    border-radius: 9px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 0 0 3px #fff, 0 0 0 5px rgba(240, 138, 28, 0.45);
}

.hub-dock-bild img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hub-dock[data-zustand="spricht"] .hub-dock-bild,
.hub-dock[data-zustand="hoert"] .hub-dock-bild {
    animation: hub-dock-ring 1.4s ease-in-out infinite;
}

.hub-dock[data-zustand="spricht"] .hub-dock-bild,
.hub-dock[data-zustand="hoert"] .hub-dock-bild {
    box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--b-glut);
}

@keyframes hub-dock-ring {
    50% { transform: scale(1.06); }
}

@media (prefers-reduced-motion: reduce) {
    .hub-dock[data-zustand] .hub-dock-bild {
        animation: none;
    }
}

/* DER STAND ALS CHIP wie auf der Bühne: „wartet auf dich“, „spricht“, „hört zu“. */
.hub-dock-name {
    display: flex;
    align-items: center;
    gap: 10px;
    font: 700 13px/1 var(--b-schrift);
    letter-spacing: 0.16em;
    color: var(--b-navy);
}

.hub-dock-name small {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 24px;
    padding: 0 10px 0 8px;
    border-radius: 3px;
    background: var(--b-glut-flaeche);
    border: 1px solid var(--b-glut-rand);
    color: var(--b-glut-text);
    font: 600 13px/1 var(--b-schrift);
    letter-spacing: 0;
}

.hub-dock-name small::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--b-glut);
    box-shadow: 0 0 0 3px rgba(240, 138, 28, 0.18);
}

.hub-dock-du {
    margin: 0;
    max-width: 88%;
    font: italic 400 14px/1.4 var(--b-schrift);
    color: var(--b-leise);
}

.hub-dock-du::before {
    content: "Du: ";
    font-style: normal;
}

.hub-dock-du[hidden] {
    display: none;
}

.hub-dock-text {
    margin: 0;
    max-height: 26vh;
    overflow: auto;
    padding: 0;
    font: 400 16px/1.45 var(--b-schrift);
    color: var(--b-text);
    white-space: pre-wrap;
}

.hub-dock-text .lia-frage {
    font-weight: 600;
    color: var(--b-navy);
}

.hub-dock-text:empty {
    display: none;
}

/* DIE KACHELN IM DOCK: eine Zeile, Wort links, Zeichen rechts; die Ziffer und „empfohlen“ fallen weg. */
.hub-dock-optionen {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hub-dock-optionen:empty {
    display: none;
}

.hub-dock .lia-kachel {
    flex: 1 1 auto;
    min-width: 0;
    height: 40px;
    min-height: 40px;
    padding: 0 12px;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.hub-dock .lia-kachel.primaer {
    flex-grow: 1.4;
}

.hub-dock .lia-kachel-nr,
.hub-dock .lia-kachel-empfohlen {
    display: none;
}

.hub-dock .lia-kachel .lia-kachel-text,
.hub-dock .lia-kachel:has(.lia-kachel-nr) .lia-kachel-text {
    padding-top: 0;
    white-space: nowrap;
}

.hub-dock .lia-kachel-zeichen {
    position: static;
    order: 2;
    margin-left: auto;
    width: 18px;
    height: 18px;
    stroke-width: 1.6;
}

.hub-dock .lia-kachel .lia-kachel-text {
    overflow: hidden;
    text-overflow: ellipsis;
}

.hub-dock.klein .lia-kachel {
    height: 34px;
    min-height: 34px;
    font-size: 13px;
}

.hub-dock .lia-kachel-hinweis {
    display: none;
}

.hub-dock-eingabe {
    display: flex;
    gap: 8px;
}

/* GEGEN DIE EINGABEFELDER DER KONSOLE (`input:not(…)` wiegt vier Klassen). */
.hub-dock .hub-dock-eingabe input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
.hub-dock-eingabe input {
    flex: 1;
    min-width: 0;
    padding: 10px 14px;
    border-radius: 3px;
    height: 44px;
    box-shadow: none;
    border: 1px solid var(--b-linie-2);
    background: var(--b-flaeche);
    color: var(--b-text);
    font: inherit;
    font-size: 14px;
}

.hub-dock-mikro {
    flex: none;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 0;
    background: var(--b-navy);
    color: #fff;
    cursor: pointer;
}

.hub-dock-mikro.an {
    background: var(--b-glut);
    color: #fff;
    box-shadow: 0 0 0 6px rgba(240, 138, 28, 0.2);
    animation: hub-puls 1.8s infinite;
}

/* STUMM: wie in der Anrufleiste — grau, kein Puls, das Mikrofon durchgestrichen. */
.hub-dock-mikro.stumm,
.hub-dock-mikro.stumm:hover {
    background: var(--b-navy);
    color: rgba(255, 255, 255, .55);
    box-shadow: none;
    animation: none;
}

.hub-dock-mikro.stumm .lia-stumm-strich {
    display: inline;
}

/* IM GESPRÄCH (Martin, 13.10.2026): wie die Anrufleiste der Bühne — der Knopf wird rot und zeigt den Hörer zum Auflegen, daneben
   steht Stumm als eigener Knopf. */
.hub-dock-auflegen {
    display: none;
}

.hub-dock-mikro.auflegen,
.hub-dock-mikro.auflegen:hover {
    background: #d92d20;
    color: #fff;
}

.hub-dock-mikro.auflegen .hub-dock-mikro-an {
    display: none;
}

.hub-dock-mikro.auflegen .hub-dock-auflegen {
    display: block;
    fill: currentColor;
    stroke: none;
}

.hub-dock-stumm {
    flex: none;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--b-linie, rgba(0, 0, 0, .15));
    background: var(--b-flaeche, #fff);
    color: var(--b-navy);
    cursor: pointer;
}

.hub-dock-stumm[hidden] {
    display: none;
}

.hub-dock-stumm:hover {
    background: var(--b-flaeche-2);
}

/* STUMM AN: wie in der Anrufleiste — das Mikrofon durchgestrichen, der Knopf hervorgehoben. */
.hub-dock-stumm.stumm,
.hub-dock-stumm.stumm:hover {
    background: var(--b-navy);
    color: #fff;
    border-color: var(--b-navy);
}

.hub-dock-stumm.stumm .lia-stumm-strich {
    display: inline;
}

.hub-dock.klein .hub-dock-stumm {
    width: 38px;
    height: 38px;
}

/* ----- DER LEISE HINWEIS ----- */

.hub-hinweis {
    position: absolute;
    top: calc(var(--hub-leiste) + 14px);
    left: 50%;
    z-index: 30;
    padding: 10px 18px;
    border-radius: 3px;
    background: var(--b-navy);
    border-bottom: 3px solid var(--b-glut);
    color: #fff;
    font: 600 14px/1.3 var(--b-schrift);
    box-shadow: 0 16px 40px -14px var(--b-schatten);
    transform: translate(-50%, -12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s, transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.hub-hinweis.an {
    opacity: 1;
    transform: translate(-50%, 0);
}

/* ENGER: Die Namen der Reiter bleiben bis 820 px (itm-733, Martin: „Reiter unter 1180 px nicht nur als Icons") — kleiner und
   dichter; erst darunter stehen nur noch die Zeichen. Sieben Reiter mit Namen brauchen gut 560 px, der Rest der Leiste 250 px.
   Das kleine Bild des Assistenten im ersten Reiter bleibt immer — vorher fiel es mit den Namen weg, und der Reiter war leer. */
@media (max-width: 1240px) {
    .hub-leiste {
        gap: 12px;
    }

    .hub-tab {
        padding: 0 11px;
        font-size: 13px;
    }

    .hp-regie {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 1060px) {
    .hub-leiste {
        gap: 8px;
    }

    .hub-tab {
        padding: 0 9px;
    }
}

@media (max-width: 820px) {
    .hub-tab span:not(.hub-reiter-avatar) {
        display: none;
    }

    .hub-tab svg {
        display: block;
    }

    .hub-tab {
        padding: 0 12px;
    }
}

/* DIE KNÖPFE DES HUBS gegen die Vorgaben der Konsole (`button` mit fester Höhe, Zentrierung und hellem Hover). `:where`
   hält die Regel so leicht wie `button`, damit die eigenen Klassen gewinnen. */
:where(.hub) button {
    height: auto;
}

.hub-zahl[hidden] {
    display: none;
}

.hp-ticket-knopf {
    justify-content: flex-start;
    align-items: stretch;
    height: auto;
}

.hub-dock-kopf:hover {
    background: transparent;
    color: var(--b-text);
}

.hub-dock-mikro:hover {
    background: var(--b-navy-2);
    color: #fff;
}

.hub-dock-mikro.an:hover {
    background: var(--b-glut);
    color: #fff;
}

.hub-panel button.ghost:hover:not(:disabled) {
    background: var(--b-flaeche-2);
    color: var(--b-navy);
}

.hub-panel button.primaer:hover:not(:disabled) {
    color: #fff;
    background: var(--b-navy-2);
}

/* ZUR FREIGABE (itm-702): die Antworten an Gäste, die LIA nicht selbst schicken wollte — ihr Entwurf mit oranger Kante. */
.hp-freigabe-liste {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hp-frei {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px 16px;
    border-radius: 3px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    border-left: 3px solid var(--b-glut);
}

.hp-frei.erledigt {
    opacity: 0.55;
}

.hp-frei-wer {
    margin: 0;
    font-weight: 600;
    color: var(--b-navy);
}

.hp-frei-frage {
    margin: 0;
    color: var(--b-leise);
    font-style: italic;
}

.hp-frei textarea {
    padding: 9px 12px;
    border-radius: 3px;
    border: 1px solid var(--b-linie-2);
    background: #fffcf8;
    color: var(--b-text);
    font: inherit;
    font-size: 14px;
    resize: vertical;
}

/* EIN SHOWCASE, DEN DAS PUBLIKUM NOCH NICHT KENNEN SOLL (itm-713): Die Überschrift steht da; statt des verschwommenen Texts — er
   wirkte wie ein Fehler beim Zeichnen — ein klarer Satz (itm-733). */
.hp-showcase .hp-showcase-geheim {
    display: flex;
    align-items: center;
    gap: 6px;
    font-style: italic;
    color: var(--b-leise);
}

.hp-showcase .hp-showcase-geheim::before {
    content: "✦";
    font-style: normal;
    color: var(--b-glut);
}

/* LÄDT (itm-733): drei leise Balken statt einer leeren Fläche. */
.hp-laedt {
    display: grid;
    gap: 10px;
    max-width: 520px;
    padding: 18px 4px;
}

.hp-laedt span {
    height: 14px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--b-flaeche-3) 25%, var(--b-flaeche-2) 50%, var(--b-flaeche-3) 75%);
    background-size: 300% 100%;
    animation: lk-schimmer 1.4s linear infinite;
}

.hp-laedt span:nth-child(2) { width: 82%; }
.hp-laedt span:nth-child(3) { width: 64%; }

.hp-laedt b {
    font-weight: 400;
    font-size: 13px;
    color: var(--b-leise);
}

@media (prefers-reduced-motion: reduce) {
    .hp-laedt span {
        animation: none;
    }
}

/* ===== DIE NÄCHSTEN SCHRITTE ALS AKTIONSKACHELN (itm-725) =====
   Die großen Kacheln aus den Assistenten von Scaliento, weiterentwickelt (lia.js): Text unten links, ein dünnes Zeichen oben
   rechts, die Ziffer oben links für Tastatur und Sprache. Die erste Kachel ist der empfohlene Schritt — Navy mit oranger Unterkante
   und „✦ empfohlen“; „Nein“ ist weiß mit rotem ✕, rote Flächen wären auf der Bühne zu laut. Die Farben stehen fest, weil dieselben
   Kacheln auf der Bühne, im Dock und in der Konsole stehen — in der Konsole auch im Dunkelmodus Navy auf Weiß, wie in Scaliento.
   Ein eigener Name statt `button.primary`: Der gefüllte Akzent der Konsole gehört dem nächsten Schritt (itm-205). */
.lia-optionen:has(.lia-kachel) {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* `button.` VORAN: Die alte Regel `.lia-optionen button` (runde Pille, oranger Rand) wiegt sonst mehr. */
button.lia-kachel {
    position: relative;
    flex: 1 1 0;
    justify-content: flex-start;
    min-width: min(150px, 100%);
    min-height: 96px;
    display: flex;
    align-items: flex-end;
    padding: 0 18px 16px;
    border: 1px solid #c6c8d4;
    border-radius: 3px;
    background: #fff;
    color: #292d5b;
    box-shadow: 0 1px 2px rgba(31, 34, 64, 0.06);
    font: 600 18px/1.2 "Open Sans", "Segoe UI", system-ui, sans-serif;
    text-align: left;
    white-space: normal;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.2s, background 0.2s;
}

/* OHNE ORANGE UNTERKANTE (itm-733, Martin 07.10.2026: orange Unterstriche an Knöpfen weg) — der empfohlene Schritt ist Navy wie
   der Primärknopf in Scaliento; „✦ empfohlen“ sagt, dass LIA ihn vorschlägt. */
button.lia-kachel.primaer {
    flex-grow: 1.8;
    background: #292d5b;
    border-color: #292d5b;
    color: #fff;
    box-shadow: 0 1px 2px rgba(31, 34, 64, 0.12);
}

.lia-kachel:hover {
    background: #f6f6fa;
    color: #292d5b;
    border-color: #292d5b;
    transform: translateY(-1px);
}

.lia-kachel.primaer:hover {
    background: #30356b;
    color: #fff;
}

.lia-kachel:focus-visible {
    outline: 3px solid #f08a1c;
    outline-offset: 2px;
}

.lia-kachel:disabled {
    opacity: 0.55;
    cursor: progress;
}

.lia-kachel-nr {
    position: absolute;
    left: 16px;
    top: 14px;
    width: 22px;
    height: 22px;
    border: 1px solid currentColor;
    border-radius: 3px;
    font: 600 12px/20px "Open Sans", "Segoe UI", system-ui, sans-serif;
    text-align: center;
    opacity: 0.6;
}

.lia-kachel-empfohlen {
    position: absolute;
    left: 46px;
    top: 14px;
    height: 22px;
    display: flex;
    align-items: center;
    gap: 5px;
    font: 600 12px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    letter-spacing: 0.02em;
    color: #ffc27f;
}

.lia-kachel-empfohlen::before {
    content: "✦";
    color: #f08a1c;
}

.lia-kachel-zeichen {
    position: absolute;
    right: 16px;
    top: 14px;
    width: 34px;
    height: 34px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.3;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ROT NUR DAS ✕ UND DER PAPIERKORB — „Später“ ist kein Nein. */
.lia-kachel-zeichen[data-zeichen="nein"],
.lia-kachel-zeichen[data-zeichen="verwerfen"] {
    stroke: #e0251b;
}

.lia-kachel-text {
    position: relative;
    min-width: 0;
    overflow-wrap: anywhere;
}

/* NEBEN DER ZIFFER UND DEM ZEICHEN braucht ein langer Text Luft: Er beginnt erst unter der Kopfzeile der Kachel. */
.lia-kachel:has(.lia-kachel-nr) .lia-kachel-text {
    padding-top: 30px;
}

.lia-kachel-hinweis {
    flex-basis: 100%;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 6px 0 0;
    font: 400 14px/1.3 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: #5a5f7a;
}

.lia-kachel-hinweis svg {
    flex: none;
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* IN DER KONSOLE kleiner: Das Gespräch steht dort neben der Arbeitsansicht, nicht auf dem Beamer. */
.lia-buehne .lia-optionen:has(.lia-kachel) {
    justify-content: center;
}

.lia-buehne button.lia-kachel {
    max-width: 280px;
}

.lia-buehne .lia-kachel {
    min-height: 72px;
    padding: 0 14px 12px;
    font-size: 16px;
}

.lia-buehne .lia-kachel-zeichen {
    top: 10px;
    right: 12px;
    width: 26px;
    height: 26px;
}

.lia-buehne .lia-kachel-nr {
    top: 10px;
    left: 12px;
}

.lia-buehne .lia-kachel-empfohlen {
    top: 10px;
    left: 42px;
}

.lia-buehne .lia-kachel:has(.lia-kachel-nr) .lia-kachel-text {
    padding-top: 24px;
}

.lia-buehne .lia-kachel-hinweis {
    font-size: 13px;
}

.lia-buehne.gross .lia-kachel {
    min-height: 88px;
    font-size: 18px;
}

@media (prefers-reduced-motion: reduce) {
    .lia-kachel {
        transition: none;
    }

    .lia-kachel:hover {
        transform: none;
    }
}

/* ===== DIE PERSONA ALS EIGENE SEITE (Martin, 07.10.2026: „viel aufgeräumter, untereinander … schön gestaltet … man soll Spaß
   daran haben"). Eine Spalte, oben die Vorschau, darunter die Bereiche nummeriert; der Knopf zum Speichern bleibt unten im Bild. */

.hp-persona-seite {
    max-width: 780px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding-bottom: var(--dock-platz, 24px);
}

.hp-persona-vorschau {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 22px;
    align-items: start;
    padding: 24px 26px;
    border-radius: 6px;
    background: linear-gradient(135deg, var(--b-glut-flaeche), var(--b-flaeche) 70%);
    border: 1px solid var(--b-glut-rand);
}

.hp-persona-avatar {
    position: relative;
    width: 92px;
    height: 92px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--b-flaeche);
    border: 2px solid var(--b-glut);
    color: var(--b-navy);
    box-shadow: 0 6px 18px rgba(240, 138, 28, 0.18);
}

.hp-persona-avatar svg {
    width: 52px;
    height: 52px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.hp-persona-avatar svg .voll,
.hp-avatar-bild svg .voll {
    fill: currentColor;
}

.hp-persona-initial {
    position: absolute;
    right: -4px;
    bottom: -4px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    background: var(--b-navy);
    border: 2px solid var(--b-flaeche);
}

.hp-persona-avatar.hops {
    animation: hp-persona-hops 0.45s cubic-bezier(.3, 1.6, .5, 1);
}

@keyframes hp-persona-hops {
    0% { transform: scale(0.86); }
    100% { transform: scale(1); }
}

.hp-persona-vtext {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.hp-persona-vname {
    font-size: 22px;
    font-weight: 600;
    color: var(--b-navy);
    line-height: 1.2;
}

.hp-persona-blase {
    margin: 0;
    padding: 10px 14px;
    border-radius: 4px 14px 14px 14px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    font-size: 14px;
    line-height: 1.5;
    color: var(--b-text);
    transition: background 0.2s;
}

.hp-persona-blase.leise {
    font-style: italic;
}

.hp-persona-vfrage {
    margin-top: 4px;
    font-size: 12px;
    color: var(--b-leise);
}

.hp-persona-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.hp-persona-chip {
    padding: 2px 10px;
    border-radius: 999px;
    font-size: 12px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-glut-rand);
    color: var(--b-glut-text);
}

.hp-persona-teil {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 20px 24px 22px;
    border-radius: 6px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
}

.hp-persona-teil-kopf {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 12px;
    align-items: center;
}

.hp-persona-teil-kopf h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--b-navy);
}

.hp-persona-teil-kopf p {
    grid-column: 2;
    margin: 2px 0 0;
    font-size: 13px;
    color: var(--b-leise);
}

.hp-persona-nr {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    background: var(--b-glut);
}

.hp-avatar-wahl {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
}

.hub-panel .hp-avatar-wahl .hp-wahl-knopf {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px 10px 12px;
    border-radius: 6px;
    font-size: 13px;
    transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s;
}

.hub-panel .hp-avatar-wahl .hp-wahl-knopf:hover {
    transform: translateY(-2px);
}

.hub-panel .hp-avatar-wahl .hp-wahl-knopf.an {
    box-shadow: 0 0 0 2px var(--b-glut);
}

.hp-avatar-bild svg {
    width: 40px;
    height: 40px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* DER VOGEL IN DER KACHEL SO GROSS WIE DIE ZEICHEN DANEBEN (Martin, 07.10.2026: „da siehst du, wie groß der Vogel ist") — das
   <img> hatte keine Größe und stand mit seinen 440 px über der ganzen Reihe. */
.hp-avatar-bild {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
}

.hp-avatar-bild img {
    width: 44px;
    height: 44px;
    object-fit: contain;
}

/* DER KNOPF BLEIBT UNTEN IM BILD — am unteren Rand, neben LIA (itm-733); über ihr schwebte er mitten über einem Feld. Nur wo
   die Spalte unter LIA reicht, steht er über ihr. */
/* DIE LEISTE ZUM SPEICHERN STEHT AM ENDE DER SEITE (Martin, 07.10.2026: „der Balken … ist mitten im Bild") — klebend lag sie über
   dem Dock und damit mitten im Bild. */
.hp-persona-seite .hp-persona-speichern {
    padding: 12px 16px;
    border-radius: 6px;
    background: var(--b-flaeche);
    border: 1px solid var(--b-linie);
    box-shadow: 0 6px 20px rgba(31, 34, 64, 0.08);
}


.hp-meldung.geklappt {
    animation: hp-persona-hops 0.45s cubic-bezier(.3, 1.6, .5, 1);
    color: var(--b-gut);
}

@media (max-width: 640px) {
    .hp-persona-vorschau {
        grid-template-columns: minmax(0, 1fr);
        justify-items: start;
    }
}


/* ===== DER KALENDER FÜR HUB UND RAHMEN (itm-733, lia-kalender.js) =====
   Martin 07.10.2026: „beim Kalender noch ein Vor- und Zurückblättern und eine Detailansicht für Termine, und eine Monatsansicht
   dazu bauen" — im Hub und unter /einbettung/lia/kalender gleich. Darum hier und nicht in scaliento-rahmen.css: app.css lädt auf
   beiden Seiten. Die Gestalt ist die von Scaliento — Navy-Kopf, weiße Fläche, feines Raster —, die Farben stehen fest, weil der
   Kalender im hellen Hub und im Rahmen gleich aussieht. Was LIA getan hat, ist orange: eingetragen voll, verschoben gestrichelt. */
.lk {
    --lk-navy: #292d5b;
    --lk-navy-2: #30356b;
    --lk-linie: #d9dae2;
    --lk-linie-2: #c6c8d4;
    --lk-raster: #e3e4ea;
    --lk-raster-2: #f2f2f5;
    --lk-ink: #1f2240;
    --lk-ink-2: #3e4360;
    --lk-ink-3: #5a5f7a;
    --lk-termin: #e8e9f3;
    --lk-lia: #f08a1c;
    --lk-lia-t: #b65a06;
    --lk-lia-f: #fef3e7;
    --lk-lia-r: #f7c99a;
    --lk-rot: #e0251b;

    position: relative;
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-width: 0;
    color: var(--lk-ink);
    font: 400 14px/1.4 "Open Sans", "Segoe UI", system-ui, sans-serif;
    font-variant-numeric: tabular-nums;
}

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

.lk[aria-busy="true"] .lk-blatt > :not(.lk-laedt) {
    opacity: 0.55;
    transition: opacity 0.2s 0.15s;
}

.lk-ic {
    width: 20px;
    height: 20px;
    flex: none;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ----- DIE LEISTE ----- */
.lk-leiste {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 12px;
}

.lk-blaettern {
    display: flex;
    gap: 6px;
}

.lk .lk-knopf {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 36px;
    min-height: 0;
    padding: 0 14px;
    border: 1px solid var(--lk-linie-2);
    border-radius: 2px;
    background: #fff;
    color: var(--lk-navy);
    font: 600 14px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    cursor: pointer;
    box-shadow: none;
    transform: none;
}

.lk .lk-knopf.q {
    width: 36px;
    padding: 0;
}

.lk .lk-knopf:hover:not(:disabled) {
    background: #f6f6fa;
    border-color: var(--lk-navy);
    color: var(--lk-navy);
}

.lk .lk-knopf:disabled {
    opacity: 0.5;
    cursor: default;
}

.lk button:focus-visible {
    outline: 2px solid var(--lk-lia);
    outline-offset: 2px;
}

.lk-titel {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin: 0 4px;
    font: 300 22px/1.2 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-navy);
    white-space: nowrap;
}

.lk-titel small {
    font: 400 13px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-ink-3);
}

/* WOCHE | MONAT wie die Segmente in Scaliento: eckig, das gewählte Navy. */
.lk-umschalter {
    display: flex;
    margin-left: auto;
    border: 1px solid var(--lk-linie-2);
    border-radius: 2px;
    overflow: hidden;
    background: #fff;
}

.lk .lk-umschalter button {
    height: 34px;
    min-height: 0;
    padding: 0 16px;
    border: 0;
    border-left: 1px solid var(--lk-linie-2);
    border-radius: 0;
    background: transparent;
    color: var(--lk-ink-3);
    font: 600 13px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    cursor: pointer;
    box-shadow: none;
}

.lk .lk-umschalter button:first-child {
    border-left: 0;
}

.lk .lk-umschalter button.an {
    background: var(--lk-navy);
    color: #fff;
}

.lk .lk-umschalter button:hover:not(.an) {
    background: #f6f6fa;
    color: var(--lk-navy);
}

.lk-legende {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    font: 400 13px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-ink-2);
}

.lk-legende span {
    display: flex;
    align-items: center;
    gap: 7px;
}

.lk-legende i {
    width: 20px;
    height: 13px;
    border-radius: 2px;
}

.lk-legende .t { background: var(--lk-termin); border-left: 3px solid var(--lk-navy); }
.lk-legende .e { background: var(--lk-lia-f); border-left: 4px solid var(--lk-lia); }
.lk-legende .v { background: #fff; border: 1.5px dashed var(--lk-lia); border-left: 4px solid var(--lk-lia); }

/* ----- DAS BLATT ----- */
.lk-blatt {
    position: relative;
    min-width: 0;
}

.lk-laedt {
    display: grid;
    gap: 10px;
    padding: 18px;
    background: #fff;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.12);
}

.lk-laedt span {
    height: 14px;
    border-radius: 2px;
    background: linear-gradient(90deg, #eceef5 25%, #f6f6fa 50%, #eceef5 75%);
    background-size: 300% 100%;
    animation: lk-schimmer 1.4s linear infinite;
}

.lk-laedt span:nth-child(2) { width: 82%; }
.lk-laedt span:nth-child(3) { width: 64%; }

.lk-laedt b {
    font-weight: 400;
    font-size: 13px;
    color: var(--lk-ink-3);
}

@keyframes lk-schimmer {
    from { background-position: 100% 0; }
    to { background-position: -200% 0; }
}

.lk-hinweis,
.lk-fehler {
    margin: 10px 0 0;
    font-size: 13px;
    color: var(--lk-ink-3);
}

.lk-fehler {
    padding: 14px 16px;
    background: #fff;
    border-left: 3px solid var(--lk-navy);
    color: var(--lk-ink-2);
}

/* ----- DIE WOCHE ----- */
.lk-woche {
    background: #fff;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.12);
}

/* DER KOPF BLEIBT STEHEN, wenn der Tag nach unten rollt. */
.lk-kopf {
    position: sticky;
    top: 0;
    z-index: 4;
    display: grid;
    grid-template-columns: 56px repeat(var(--lk-tage, 5), minmax(0, 1fr));
    height: 52px;
    background: var(--lk-navy);
    color: #fff;
}

.lk-ecke,
.lk-tagkopf {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 0 12px;
}

.lk-tagkopf {
    border-left: 1px solid rgba(255, 255, 255, 0.12);
}

.lk-tagkopf b {
    font: 600 13px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.lk-tagkopf span {
    font: 300 18px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    white-space: nowrap;
}

.lk-tagkopf.heute {
    background: var(--lk-navy-2);
    box-shadow: inset 0 -3px 0 #fff;
}

.lk-tagkopf em {
    margin-left: auto;
    padding: 4px 8px;
    border-radius: 10px;
    background: #fff;
    color: var(--lk-navy);
    font: 600 12px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    font-style: normal;
}

.lk-koerper {
    position: relative;
    display: grid;
    grid-template-columns: 56px repeat(var(--lk-tage, 5), minmax(0, 1fr));
}

/* DIE UHRZEIT STEHT UNTER IHRER LINIE, nicht mittig darauf — so wird „08:00“ unter dem Kopf nie abgeschnitten. */
.lk-zeiten {
    position: relative;
}

.lk-zeiten span {
    position: absolute;
    right: 8px;
    margin-top: 4px;
    font: 400 12px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-ink-3);
}

.lk-spalte {
    position: relative;
    min-width: 0;
    border-left: 1px solid var(--lk-raster);
    background:
        repeating-linear-gradient(to bottom, var(--lk-raster) 0, var(--lk-raster) 1px, transparent 1px, transparent var(--lk-stunde, 56px)),
        repeating-linear-gradient(to bottom, transparent 0, transparent calc(var(--lk-stunde, 56px) / 2), var(--lk-raster-2) calc(var(--lk-stunde, 56px) / 2), var(--lk-raster-2) calc(var(--lk-stunde, 56px) / 2 + 1px), transparent calc(var(--lk-stunde, 56px) / 2 + 1px), transparent var(--lk-stunde, 56px));
}

.lk-spalte.heute {
    background-color: #f8f8fc;
}

/* EIN TERMIN: ein Knopf — er öffnet die Detailansicht. Lange Titel enden mit „…“. */
.lk .lk-termin {
    position: absolute;
    left: 4px;
    right: 4px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 1px;
    min-height: 0;
    padding: 4px 8px;
    border: 0;
    border-left: 3px solid var(--lk-navy);
    border-radius: 2px;
    background: var(--lk-termin);
    box-shadow: 0 0 0 1px #fff;
    color: var(--lk-ink-2);
    font: 400 12px/1.3 "Open Sans", "Segoe UI", system-ui, sans-serif;
    text-align: left;
    overflow: hidden;
    cursor: pointer;
    transition: box-shadow 0.15s;
}

.lk .lk-termin:hover {
    box-shadow: 0 0 0 1px #fff, 0 6px 14px -6px rgba(31, 34, 64, 0.45);
    z-index: 3;
}

.lk .lk-termin > span,
.lk .lk-termin > b {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.lk-termin-titel {
    font: 600 13px/1.25 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-navy);
}

.lk-termin-lia {
    margin-top: 3px;
    font-weight: 700;
    color: var(--lk-lia-t);
}

.lk-termin-lia::before {
    content: "✦ ";
    color: var(--lk-lia);
}

.lk .lk-termin.eine {
    flex-direction: row;
    align-items: center;
    gap: 6px;
    padding-top: 0;
    padding-bottom: 0;
}

.lk .lk-termin.eine .lk-termin-titel {
    flex: 0 1 auto;
}

.lk .lk-termin.eine .lk-termin-zeit {
    flex: none;
}

.lk .lk-termin.lia {
    background: var(--lk-lia-f);
    border-left: 4px solid var(--lk-lia);
}

.lk .lk-termin.verschoben {
    background: #fff;
    border: 1.5px dashed var(--lk-lia);
    border-left: 4px solid var(--lk-lia);
}

/* ÜBERSCHNEIDUNGEN (itm-741, aus dem Kalender der Konsole): eine rote Kante rechts — die linke gehört weiter dem, der den
   Termin eingetragen hat (Navy oder LIA). Rot heisst hier dasselbe wie im ganzen Ticketsystem: hinsehen. */
.lk .lk-termin.konflikt,
.lk .lk-mtermin.konflikt {
    box-shadow: inset -3px 0 0 var(--lk-rot), 0 0 0 1px #fff;
}

.lk-legende .k { background: var(--lk-termin); border-left: 3px solid var(--lk-navy); box-shadow: inset -3px 0 0 var(--lk-rot); }

.lk-d-konflikt {
    padding: 10px 14px;
    border-left: 3px solid var(--lk-rot);
    background: #fce9e8;
    color: #9b1712;
    font-size: 14px;
}

/* SAMSTAG UND SONNTAG, wenn zugeschaltet: etwas grauer, wie im Monat. */
.lk-spalte.we {
    background-color: #f6f6f9;
}

/* Im Kopf eine hellere Stufe des Navy — die Schrift bleibt weiss. */
.lk-tagkopf.we {
    background-color: var(--lk-navy-2);
}

/* SIEBEN SPALTEN AUF SCHMALEM SCHIRM: das Abzeichen „Heute“ fällt weg, die Spalte ist ohnehin hervorgehoben. */
@media (max-width: 1280px) {
    .lk-woche[style*="--lk-tage: 7"] .lk-tagkopf em {
        display: none;
    }
}

/* EIN TAG: eine breite Spalte — die Termine bekommen Platz für Ort und Teilnehmer. */
.lk-eintag .lk-termin-ort {
    white-space: normal;
}

/* WER UND SA/SO zwischen Umschalter und Legende (itm-741). */
.lk-filter {
    display: flex;
    align-items: center;
    gap: 8px;
}

.lk-filter:empty {
    display: none;
}

.lk-wer-feld {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 36px;
    margin: 0;
    padding: 0 10px 0 12px;
    border: 1px solid var(--lk-linie-2);
    border-radius: 18px;
    background: #fff;
    font: 400 14px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-ink-2);
}

.lk .lk-wer {
    width: auto;
    min-width: 0;
    max-width: 180px;
    height: auto;
    min-height: 0;
    margin: 0;
    padding: 0 2px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    font: 600 14px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-navy);
    cursor: pointer;
}

.lk .lk-knopf.lk-we.an {
    background: var(--lk-navy);
    border-color: var(--lk-navy);
    color: #fff;
}

.lk-jetzt {
    position: absolute;
    left: 0;
    right: 0;
    z-index: 3;
    height: 2px;
    background: var(--lk-rot);
    pointer-events: none;
}

.lk-jetzt::before {
    content: "";
    position: absolute;
    left: -5px;
    top: -4px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--lk-rot);
}

/* ----- DER MONAT ----- */
.lk-monat {
    background: #fff;
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.12);
}

.lk-wtage,
.lk-mwoche {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
}

.lk-wtage {
    position: sticky;
    top: 0;
    z-index: 4;
    height: 40px;
    background: var(--lk-navy);
    color: #fff;
}

.lk-wtage span {
    display: flex;
    align-items: center;
    padding: 0 10px;
    border-left: 1px solid rgba(255, 255, 255, 0.12);
    font: 600 13px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.lk-wtage span:first-child {
    border-left: 0;
}

.lk-wtage span.we {
    color: #c9cce6;
}

.lk-mtag {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    min-height: 108px;
    padding: 6px 6px 8px;
    border-left: 1px solid var(--lk-raster);
    border-top: 1px solid var(--lk-raster);
}

.lk-mtag:first-child {
    border-left: 0;
}

.lk-mtag.we {
    background: #fafafc;
}

.lk-mtag.aus {
    background: #f6f6f8;
}

.lk-mtag.aus .lk-mzahl {
    color: #a3a6b8;
}

.lk-mzahl {
    align-self: flex-start;
    min-width: 26px;
    height: 26px;
    padding: 0 6px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    font: 400 14px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-ink-2);
}

.lk-mtag.heute .lk-mzahl {
    background: var(--lk-navy);
    color: #fff;
    font-weight: 600;
}

/* EIN TERMIN IM MONAT: eine Zeile — Uhrzeit, Titel mit „…“; was LIA tat, an der orangen Kante. */
.lk .lk-mtermin {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 6px;
    width: 100%;
    min-width: 0;
    min-height: 0;
    height: 24px;
    padding: 0 6px;
    border: 0;
    border-left: 3px solid var(--lk-navy);
    border-radius: 2px;
    background: var(--lk-termin);
    color: var(--lk-navy);
    font: 400 12px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    text-align: left;
    cursor: pointer;
    box-shadow: none;
}

.lk .lk-mtermin:hover {
    background: #dfe1ee;
}

.lk .lk-mtermin.lia {
    background: var(--lk-lia-f);
    border-left: 3px solid var(--lk-lia);
}

.lk .lk-mtermin.verschoben {
    background: #fff;
    border: 1px dashed var(--lk-lia);
    border-left: 3px solid var(--lk-lia);
}

.lk-mzeit {
    flex: none;
    color: var(--lk-ink-3);
}

.lk-mtitel {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
}

.lk .lk-mehr {
    align-self: flex-start;
    height: 22px;
    min-height: 0;
    padding: 0 6px;
    border: 0;
    border-radius: 2px;
    background: transparent;
    color: var(--lk-navy);
    font: 600 12px/1 "Open Sans", "Segoe UI", system-ui, sans-serif;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
    box-shadow: none;
}

.lk .lk-mehr:hover {
    background: #eef0f7;
}

/* ----- DIE DETAILANSICHT: ein Seitenpanel rechts, nur zum Lesen ----- */
.lk-detail {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 6;
    width: min(400px, 100%);
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 18px 22px var(--dock-platz, 22px);
    overflow: auto;
    background: #fff;
    border-top: 3px solid var(--lk-navy);
    box-shadow: -12px 0 32px -16px rgba(31, 34, 64, 0.35), 0 1px 1px rgba(0, 0, 0, 0.12);
}

.lk-detail[hidden] {
    display: none;
}

.lk-detail.rein {
    animation: lk-rein 0.28s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

@keyframes lk-rein {
    from { opacity: 0; transform: translateX(24px); }
}

.lk-d-kopf {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.lk-d-art {
    margin: 0;
    font: 700 12px/1.2 "Open Sans", "Segoe UI", system-ui, sans-serif;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--lk-ink-3);
}

.lk-d-titel {
    margin: 0;
    font: 400 22px/1.3 "Open Sans", "Segoe UI", system-ui, sans-serif;
    color: var(--lk-navy);
    overflow-wrap: anywhere;
}

.lk-d-felder {
    display: grid;
    gap: 10px;
    margin: 0;
}

.lk-d-feld {
    display: grid;
    grid-template-columns: 128px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    padding-bottom: 10px;
    border-bottom: 1px solid #ecedf1;
}

.lk-d-feld dt {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--lk-ink-3);
}

.lk-d-feld dt .lk-ic {
    width: 18px;
    height: 18px;
    color: var(--lk-navy);
}

.lk-d-feld dd {
    margin: 0;
    font-size: 14px;
    color: var(--lk-ink);
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.lk-d-lia {
    display: grid;
    gap: 6px;
    padding: 12px 14px;
    border-left: 3px solid var(--lk-lia);
    background: var(--lk-lia-f);
    color: var(--lk-ink);
}

.lk-d-lia b {
    color: var(--lk-navy);
}

.lk-d-lia b::before {
    content: "✦ ";
    color: var(--lk-lia);
}

.lk-d-lia p {
    margin: 0;
    font-size: 14px;
}

.lk-d-lia p.leise {
    font-size: 13px;
    color: var(--lk-ink-3);
}

.lk-d-tag {
    display: grid;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.lk-d-tag .lk-mtermin {
    height: 34px;
    font-size: 14px;
}

@media (max-width: 760px) {
    .lk-legende {
        display: none;
    }

    .lk-umschalter {
        margin-left: 0;
    }

    .lk-kopf,
    .lk-koerper {
        grid-template-columns: 46px repeat(var(--lk-tage, 5), minmax(0, 1fr));
    }

    .lk-tagkopf {
        padding: 0 8px;
    }

    .lk-tagkopf em {
        display: none;
    }

    .lk-mtag {
        min-height: 84px;
    }

    .lk .lk-mtermin .lk-mzeit {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .lk-laedt span,
    .lk-detail.rein {
        animation: none;
    }
}

/* IM HUB PASST DIE WOCHE IN DIE HÖHE (Martin 08.10.2026: „im kalender ist auch auf einmal auf der bühne eine scrollbar“). Seit
   itm-733 endete der Bereich über dem Dock; die neun Stunden zu je 56 px passten bei 768 px Höhe nicht mehr hinein, und das Blatt
   rollte. JETZT rechnet lia-kalender.js die Stunde so hoch, dass der Tag über LIA endet (`unten`, aus lia-hub.js); darunter läuft
   das weiße Blatt ohne Stundenlinien bis an den Rand. Erst unter 34 px je Stunde rollt das Blatt wieder. Der Monat rollt in sich,
   mit Platz für LIA. */
.hp-inhalt.hp-kal {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.hp-kal .lk {
    flex: 1 1 auto;
    min-height: 0;
}

.hp-kal .lk-blatt {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    padding-bottom: 0;
    scrollbar-color: var(--b-linie-2, #c6c8d4) transparent;
}

.hp-kal .lk[data-ansicht="monat"] .lk-blatt {
    padding-bottom: var(--dock-platz, 20px);
}

/* UNTER DEM LETZTEN TAGESABSCHNITT keine Stundenlinien mehr — die Fläche gehört nicht mehr zum Tag (`--lk-tag-h`). */
.lk-woche[style*="--lk-tag-h"] .lk-spalte {
    background-size: 100% var(--lk-tag-h, 100%);
    background-repeat: no-repeat;
}

.lk-woche[style*="--lk-tag-h"] .lk-koerper::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: var(--lk-tag-h, 100%);
    height: 1px;
    background: var(--lk-raster);
    pointer-events: none;
}

/* IM RAHMEN rollt die Seite; die Detailansicht steht am Fenster, damit sie auch weiter unten im Blick ist. */
.sr .lk-detail {
    position: fixed;
    padding-bottom: 22px;
}

/* DIE STIMMEN: ein Symbol aus der Beschreibung, der Name ohne englische Beiwörter (itm-738). */
.hp-stimme-wahl {
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
}

.hp-stimme-bild {
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--b-glut-flaeche);
    color: var(--b-glut-text);
}

.hp-stimme-bild svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.hp-stimme-texte {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.hp-stimmen-mehr,
.hp-klang-empfehlung {
    justify-self: start;
    align-self: flex-start;
    font-size: 13px;
}

.hp-persona-seite .hp-klang {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* WER ES WAR, im Protokoll (itm-739): KI orange, Kunde navy, Team grün. */
.hp-proto-wer {
    display: inline-block;
    margin-right: 8px;
    padding: 1px 8px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
    vertical-align: 1px;
    color: var(--b-glut-text);
    background: var(--b-glut-flaeche);
    border: 1px solid var(--b-glut-rand);
}

.hp-proto-zeile.wer-kunde .hp-proto-wer {
    color: var(--b-navy);
    background: var(--b-grund);
    border-color: var(--b-linie);
}

.hp-proto-zeile.wer-mensch .hp-proto-wer {
    color: var(--b-gut);
    background: var(--b-flaeche);
    border-color: var(--b-gut);
}

/* DER STAND DES IMPORT-ABLAUFS MIT „AKTUALISIEREN" (07.10.2026). */
.ablauf-stand {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.ablauf-stand .button {
    padding: 4px 12px;
    font-size: 13px;
}

/* WAS SCALIENTO ANBIETET (Protokoll › Importe, 08.10.2026): je Template eine Zeile zum Aufklappen, durch eine Linie
   getrennt statt je einer Karte — fünfzig Karten untereinander liest niemand. Was der Import nicht schreibt, hat
   ausser der roten Pille eine getönte Zeile, damit man es beim Überfliegen der Tabelle findet. */
details.paketbericht-template {
    margin: 0;
    border-top: 1px solid var(--line-soft);
}

tr.paketbericht-weg td {
    background: var(--stop-soft);
}

/* DER ABSTAND IN DER ZEILE ZUM AUFKLAPPEN kommt aus dem Stil: Razor wirft die Leerzeichen zwischen den Teilen weg, und
   „VerarbeitungVerarbeitungen in meiner Organisation" las sich wie ein Wort. */
details.paketbericht-template > summary > * + *,
.paketbericht > .card > .meta > .zustand {
    margin-left: var(--s2);
}

/* DER FREIE MODUS (itm-748, Martin 08.10.2026: „im freien Modus wird rechts oben dann ein grüner Punkt gezeigt, statt ein
   oranger") — ruhig, ohne Pulsieren: Es läuft keine Vorführung, es wird gearbeitet. */
.hub-showcase.frei .hub-showcase-punkt {
    background: var(--b-gut, #1f9a3a);
    box-shadow: 0 0 0 2px rgba(31, 154, 58, 0.28);
}

/* DER GRÜNE HAKEN AN EINEM DURCHGESPIELTEN SHOWCASE (Martin 08.10.2026: „wenn ich durch bin, wäre gut wenn ein grüner haken
   dort auch sichtbar ist für daniel") — klein hinter dem Titel. */
.hp-showcase-haken {
    display: inline-block;
    margin-left: 6px;
    color: var(--b-gut, #1f9a3a);
    font-weight: 700;
}

/* DER WECHSEL IN DEN FREIEN MODUS UND DAS AUFRÄUMEN fragen in der Seite nach, nicht mit einem Dialog des Browsers. */
.hp-aktion .hp-frei-frage-box {
    padding: 10px 12px;
    border: 1px solid var(--b-linie, #d9dae2);
    border-left: 3px solid var(--b-gut, #1f9a3a);
    border-radius: 3px;
    background: var(--b-flaeche, #fff);
}

.hp-gefahr .hp-aktion .hp-frei-frage-box {
    border-left-color: var(--b-halt);
}

.hp-aktion .hp-frei-frage-box p {
    margin: 0 0 8px;
}

/* DIE LÄUFE VON LC INSIGHTS UND LC PULSAR (Martin 26.10.2026: „es bricht alles um und man sieht die kosten nicht gescheit").
   Vorher eine Tabelle mit sechs Spalten, in der Bericht und Kostenaufstellung jede Zeile auf zwanzig Zeilen trieben. Jetzt
   EINE ZEILE JE LAUF mit festen Spalten — wann, Zustand, was, Ergebnis, Kosten rechtsbündig — und alles Weitere zum Aufklappen.
   Die Kopfzeile steht im selben Raster, damit die Spalten auch ohne Tabelle untereinander bleiben. */
.laeufe {
    --lauf-spalten: 8.5rem 6.5rem minmax(0, 1fr) minmax(0, 1.5fr) 5.5rem;
    margin: 0;
}

.laeufe-kopf,
.lauf > summary {
    display: grid;
    grid-template-columns: var(--lauf-spalten);
    gap: var(--s3);
    align-items: baseline;
    padding: var(--s2) var(--s2) var(--s2) var(--s4);
}

.laeufe-kopf {
    font-size: var(--t-xs);
    font-weight: 600;
    color: var(--ink-muted);
    border-bottom: 1px solid var(--border);
}

.lauf {
    border-bottom: 1px solid var(--border);
}

.lauf > summary {
    position: relative;
    cursor: pointer;
    list-style: none;
    font-size: var(--t-sm);
    font-variant-numeric: tabular-nums;
}

.lauf > summary::-webkit-details-marker {
    display: none;
}

/* DER PFEIL ZEIGT, DASS SICH DIE ZEILE ÖFFNEN LÄSST — ohne ihn sieht sie aus wie eine gewöhnliche Tabellenzeile. */
.lauf > summary::before {
    content: "";
    position: absolute;
    left: 2px;
    top: 50%;
    width: 6px;
    height: 6px;
    margin-top: -4px;
    border-right: 1.5px solid var(--ink-3);
    border-bottom: 1.5px solid var(--ink-3);
    transform: rotate(-45deg);
    transition: transform .15s;
}

.lauf[open] > summary::before {
    transform: rotate(45deg);
}

.lauf > summary:hover {
    background: var(--surface-2);
}

.lauf-zeit {
    white-space: nowrap;
}

.lauf-zeit small,
.lauf-was small {
    display: block;
    font-size: var(--t-2xs);
    color: var(--ink-3);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.lauf-ergebnis {
    color: var(--ink-2);
    min-width: 0;
}

.lauf-ergebnis .warn {
    display: block;
    font-size: var(--t-xs);
}

/* DIE KOSTEN SIND DIE ZAHL, DIE MAN SUCHT: rechtsbündig, nie umbrochen, kräftiger als der Rest. */
.lauf-kosten {
    text-align: right;
    font-weight: 600;
    white-space: nowrap;
}

.laeufe-kopf .lauf-kosten {
    font-weight: 600;
}

.lauf-mehr {
    padding: var(--s2) var(--s4) var(--s4);
    background: var(--surface-2);
    font-size: var(--t-sm);
}

.lauf-mehr h3 {
    margin: var(--s3) 0 var(--s2);
    font-size: var(--t-xs);
    font-weight: 600;
    color: var(--ink-muted);
}

.lauf-mehr h3:first-child {
    margin-top: var(--s2);
}

.lauf-mehr ul {
    margin: 0;
    padding-left: 1.1em;
}

.lauf-mehr li + li {
    margin-top: 2px;
}

/* EINE KLEINE ZAHLENTABELLE IM AUFGEKLAPPTEN LAUF — Zahlen rechtsbündig, damit man Stellen vergleichen kann. */
.lauf-zahlen {
    border-collapse: collapse;
    font-variant-numeric: tabular-nums;
}

.lauf-zahlen th,
.lauf-zahlen td {
    padding: 3px var(--s4) 3px 0;
    text-align: right;
    white-space: nowrap;
}

.lauf-zahlen th {
    font-size: var(--t-2xs);
    font-weight: 600;
    color: var(--ink-muted);
    border-bottom: 1px solid var(--border);
}

.lauf-zahlen th:first-child,
.lauf-zahlen td:first-child {
    text-align: left;
}

.lauf-zahlen tfoot td {
    border-top: 1px solid var(--border);
    font-weight: 600;
}

.lauf-zahlen-raster {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s2) var(--s8);
}

@media (max-width: 760px) {
    .laeufe {
        --lauf-spalten: minmax(0, 1fr) auto;
    }

    .laeufe-kopf {
        display: none;
    }

    .lauf-was,
    .lauf-ergebnis {
        grid-column: 1 / -1;
    }
}

/* MANDANTEN LÖSCHEN (29.10.2026): Die Rückfrage steht an der Zeile, um die es geht. */
.listing > li > .loeschen-frage,
.card > .loeschen-frage {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--s2);
    margin: var(--s2) 0 0;
}

.listing > li > .form-error {
    flex-basis: 100%;
}
