/* Modul Tickets: Statusquadrat, Endtermin-Badges, Hinweis-Farben, Ticketbaum, Nutzerauswahl. Farben über MDB-Variablen bzw. feste Statusfarben. */
.aqc-status-square {
    display: inline-block;
    width: 0.9rem;
    height: 0.9rem;
    border-radius: 0.15rem;
    vertical-align: middle;
}
.aqc-status-square.is-green { background-color: #00b74a; }
.aqc-status-square.is-red { background-color: #f93154; }
.aqc-status-square.is-orange { background-color: #ffa900; }

.aqc-due { font-weight: 500; padding: 0.15rem 0.5rem; border-radius: 0.25rem; white-space: nowrap; }
.aqc-due.is-overdue { background-color: #f93154; color: #fff; }
.aqc-due.is-due_soon { background-color: #ffa900; color: #212529; }
.aqc-due.is-ok { background-color: #00b74a; color: #fff; }

.aqc-hint { padding: 0.15rem 0.5rem; border-radius: 0.25rem; white-space: nowrap; font-size: 0.85rem; }
.aqc-hint.is-schedule { background-color: #ffe08a; }
.aqc-hint.is-sample { background-color: #b6e3ff; }
.aqc-hint.is-notice { background-color: #d1c4e9; }
.aqc-hint.is-interrupted { background-color: #f93154; color: #fff; font-weight: 600; }
.aqc-hint.is-other { background-color: #e0e0e0; }

/* Kürzel der Vorgangsart hinter der Bezeichnung (Vorgangsliste): kleiner und gedämpft, damit die Bezeichnung führt */
.aqc-type-code { margin-left: 0.3em; font-size: 0.75em; color: #6c757d; }

.aqc-draft-note { border-left: 4px solid #ffa900; background-color: rgba(255, 169, 0, 0.12); padding: 0.5rem 0.75rem; margin-bottom: 1rem; }

/* Ticketbaum: eingerückte Liste mit Verbindungslinien */
.aqc-tree, .aqc-tree ul { list-style: none; margin: 0; padding-left: 1.75rem; position: relative; }
.aqc-tree { padding-left: 0; }
.aqc-tree ul::before { content: ''; position: absolute; left: 0.6rem; top: 0; bottom: 1rem; border-left: 2px solid #b0b8c8; }
.aqc-tree li { position: relative; margin: 0.4rem 0; }
.aqc-tree ul > li::before { content: ''; position: absolute; left: -1.15rem; top: 1.1rem; width: 1rem; border-top: 2px solid #b0b8c8; }
.aqc-tree-node { display: inline-block; border: 1px solid #b0b8c8; border-radius: 0.35rem; padding: 0.4rem 0.7rem; background: #fff; cursor: pointer; text-align: left; }
.aqc-tree-node.is-current { border: 2px solid var(--mdb-primary, #003DFD); background-color: rgba(0, 61, 253, 0.06); }

/* Nutzerauswahl */
.aqc-point-list { max-height: 22rem; overflow-y: auto; border: 1px solid rgba(0, 0, 0, 0.12); border-radius: 0.35rem; padding: 0.5rem 0.75rem; }
.aqc-point-light { display: inline-block; width: 0.8rem; height: 0.8rem; margin-right: 0.5rem; border-radius: 50%; vertical-align: -0.1rem; }
.aqc-point-light-green { background-color: var(--mdb-success, #00b74a); }
.aqc-point-light-yellow { background-color: var(--mdb-warning, #ffa900); }
.aqc-point-light-red { background-color: var(--mdb-danger, #f93154); }
.aqc-point-light-none { background-color: transparent; border: 1px solid rgba(0, 0, 0, 0.3); }
.aqc-point-group { font-weight: 500; font-size: 1.05rem; margin-top: 0.75rem; color: var(--mdb-primary, #003DFD); }
/* Lage und Mietername in der Auswahlliste: deutlicher Abstand zwischen beiden */
.aqc-point-position { display: inline-block; min-width: 4rem; margin-right: 1rem; }

/* Ausgewählte Nutzer eines Vorgangs: elf schmale Spalten in der halben Seitenbreite, deshalb engere Zellen */
.aqc-units-table .datatable-header th,
.aqc-units-table .datatable-body td { padding-left: 0.35rem; padding-right: 0.35rem; }
.aqc-units-table .aqc-sort { margin-left: 0.2rem; }

/* Auswahl "Nutzer aus Vorgang" im Kartenkopf: ohne Label, feste Breite */
.aqc-unit-source { width: 14rem; }
.aqc-unit-source .form-select, .aqc-unit-source .select-input { width: 100%; }

/* Kontaminationsauswertung (contamination.js): Bewertungsstufen als Badge und als Markierung im Strukturbaum */
body .aqc-ctm-badge { font-weight: 600; }
body .badge.aqc-ctm-none { background-color: #eceff1; color: #546e7a; }
body .badge.aqc-ctm-clean { background-color: #dcf4e4; color: #14653a; }
body .badge.aqc-ctm-occasional { background-color: #fff0cc; color: #7a5300; }
body .badge.aqc-ctm-frequent { background-color: #fde7ec; color: #b3132f; }
body .badge.aqc-ctm-persistent { background-color: #b3132f; color: #fff; }
body .aqc-struct-mark { margin-left: 0.4rem; font-size: 0.8rem; }
body .aqc-struct-mark.aqc-ctm-occasional { color: #e4a11b; }
body .aqc-struct-mark.aqc-ctm-frequent { color: #dc3545; }
body .aqc-struct-mark.aqc-ctm-persistent { color: #8b0d23; }
body .aqc-struct-mark.aqc-ctm-parent { color: #dc3545; opacity: 0.45; }
body .aqc-struct-row.is-selected .aqc-struct-mark { opacity: 1; }
body .aqc-ctm-tile { border: 1px solid var(--mdb-border-color, #e0e0e0); border-radius: 0.5rem; padding: 0.6rem 0.8rem; height: 100%; }
body tr.aqc-ctm-row > td { background-color: #fff6f7; }
body tr.aqc-ctm-click { cursor: pointer; }

/* Widget „Tickets“ im Systemstatus (status-widget.js). Rot/Grün aus den Tönen der Systemstatus-Seite (--aqc-sd-*);
   Orange und Gelb sind eigene Stufen der Fälligkeit (14 bzw. 30 Tage) und dürfen nicht mit dem Hinweis-Gelb zusammenfallen. */
.aqc-sd { --aqc-tst-soon: 245, 124, 0; --aqc-tst-month: 240, 196, 25; }
.aqc-sd-metric.is-tst-overdue { border-left-color: rgb(var(--aqc-sd-error)); }
.aqc-sd-metric.is-tst-soon { border-left-color: rgb(var(--aqc-tst-soon)); }
.aqc-sd-metric.is-tst-month { border-left-color: rgb(var(--aqc-tst-month)); }
.aqc-sd-metric.is-tst-later { border-left-color: rgb(var(--aqc-sd-ok)); }
.aqc-tst-dot { width: 0.65rem; height: 0.65rem; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.aqc-tst-muted { color: var(--mdb-secondary-color, #757575); }
.aqc-tst-columns { margin-bottom: 0.5rem; }
/* Ringdiagramm: feste Höhe, Summe mittig darübergelegt (Klicks gehen an das Diagramm durch) */
.aqc-tst-chart { position: relative; height: 200px; margin-bottom: 0.75rem; }
.aqc-tst-chart-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; pointer-events: none; }
.aqc-tst-chart-center strong { font-size: 1.6rem; line-height: 1.1; }
.aqc-tst-chart-center span { font-size: 0.8rem; color: var(--mdb-secondary-color, #757575); }
.aqc-tst-counts { list-style: none; margin: 0 0 1rem; padding: 0; }
.aqc-tst-count-row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 0.3rem 0; font-size: 0.9rem; }
.aqc-tst-count-row + .aqc-tst-count-row { border-top: 1px solid var(--mdb-border-color, #eee); }
.aqc-tst-count-label { display: inline-flex; align-items: center; gap: 0.5rem; }
.aqc-tst-count-value { display: inline-flex; align-items: baseline; gap: 0.6rem; font-variant-numeric: tabular-nums; }
.aqc-tst-count-value .aqc-tst-muted { min-width: 5.5rem; text-align: right; font-size: 0.8rem; }
/* Querbalken der Ticketarten: Höhe setzt status-widget.js nach Anzahl der Arten */
.aqc-tst-bar-chart { position: relative; width: 100%; }
.aqc-tst-types .aqc-sd-list-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }

/* Register „Kontamination“: Umschalter Schwellenwert/Grenzwerte in der Wertzelle der Feldgruppe – randlos, volle Zellenhöhe, aktiv dunkel, inaktiv hell (Vorgabe Nutzer 15.11.2026) */
body .aqc-ctm-flow { align-self: stretch; }
body .aqc-ctm-flow > .btn {
    display: flex;
    align-items: center;
    padding: 0 0.875rem;
    min-height: 0;
    line-height: 1.2;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    font-size: 0.8125rem;
    font-weight: 500;
    text-transform: none;
    white-space: nowrap;
}
body .aqc-ctm-flow > .btn.btn-light { background-color: #fff; color: #546e7a; }
body .aqc-ctm-flow > .btn.btn-light:hover { background-color: #eceff1; color: #263238; }
body .aqc-ctm-flow > .btn + .btn { border-left: 1px solid #dee2e6; }
/* Checkbox mittig in der schmalen Wertzelle */
body .aqc-ctm-toolbar .aqc-field-group-value:has(> .form-check-input),
body .aqc-ctm-toolbar .aqc-field-group-value:has(.form-check-input) { justify-content: center; align-items: center; }
/* Leiste: Auswertung behält ihre Breite; die Filter füllen den Rest und stehen rechts. Verbundene Paare machen die Gruppe zum Container
   (container-type: inline-size, field-group.css) – ohne eigene Breite fiele sie auf 0. */
body .aqc-ctm-toolbar > .aqc-field-group-wrap { flex: 0 0 auto; }
body .aqc-ctm-toolbar > .aqc-ctm-filters { flex: 1 1 24rem; }
body .aqc-ctm-filters .aqc-field-group-inline { justify-content: flex-end; }
