/*
  workspace-bento-wissen-team.css — Gestaltung der Team-Sicht „Geteiltes Wissen" nach Abteilung (Entwurf A, 16.11.2026).
  Kurzbeschreibung: Übersicht in der Mitte (Überschrift, Filter-Pillen, Tabelle), Liste rechts (kommt vom Baustein BentoSpalte).
  Nur Variablen aus marke.css / marke-ui.css, keine eigenen Farben, keine Seitenstreifen.
*/
#bsBereich[data-bereich="wissen"] .bwt > .bwt-mitte { grid-column: 1; grid-row: 1; min-width: 0; min-height: 0; display: flex; flex-direction: column; gap: var(--marke-sp-3); }
#bsBereich[data-bereich="wissen"] .bwt > .bw-spalte { grid-column: 2; grid-row: 1; min-height: 0; }
#bsBereich[data-bereich="wissen"] .bwt-mitte.drauf { box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--marke-grafit) 35%, transparent); border-radius: var(--marke-r-l); }
.bwt-zurueck { align-self: flex-start; display: inline-flex; align-items: center; gap: 4px; height: 28px; padding: 0 var(--marke-sp-2) 0 0; border: 0; background: none; color: var(--wb-leise); font: 600 13px var(--marke-schrift); cursor: pointer; }
.bwt-zurueck:hover { color: var(--wb-text); }
.bwt-zurueck svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bwt-leer { margin: var(--marke-sp-4) 0; color: var(--wb-leise); font: 400 13px var(--marke-schrift); }

/* Tabelle: nur die Tabelle darf scrollen, wenn es viele Zeilen sind */
.bwt-scroll { min-height: 0; overflow-y: auto; scrollbar-width: thin; }
.bwt-tab { table-layout: fixed; }
.bwt-scroll { --a4h-tab-grund: var(--wb-karte, var(--marke-flaeche)); }   /* Kopf/Zeilen/Pfeil kommen aus .a4h-table (marke-ui.css) */
.bwt-tab th:nth-child(1) { width: auto; } .bwt-tab th:nth-child(2) { width: 168px; } .bwt-tab th:nth-child(3) { width: 150px; } .bwt-tab th:nth-child(4) { width: 96px; }
.bwt-ohne-bes th:nth-child(3) { width: 96px; }
.bwt-tab tbody tr { cursor: pointer; }
.bwt-tab tbody tr.an td { background: var(--ui-hover); }
.bwt-tab tbody tr:focus-visible { outline: 2px solid var(--marke-grafit); outline-offset: -2px; }
.bwt-name { display: flex; align-items: center; gap: var(--marke-sp-2); min-width: 0; }
.bwt-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.bwt-neu { flex: none; height: 16px; padding: 0 6px; display: inline-flex; align-items: center; border-radius: var(--marke-r-pill); background: var(--ui-nav-kachel); color: var(--ui-nav-ton); font: 700 10px var(--marke-schrift); }
.bwt-bes { display: flex; align-items: center; gap: 6px; min-width: 0; }
.bwt-bes > span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--wb-leise); }
.bwt-av { flex: none; width: 22px; height: 22px; border-radius: 999px; display: grid; place-items: center; background: var(--marke-flaeche-2); color: var(--marke-text-2); font: 700 10px var(--marke-schrift); }
.bwt-dat { color: var(--wb-leise); white-space: nowrap; }
.bwt-chip { display: inline-flex; align-items: center; max-width: 100%; height: 20px; padding: 0 8px; border-radius: var(--marke-r-pill); font: 600 11px var(--marke-schrift); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bwt-chip.team { background: var(--ui-nav-kachel); color: var(--ui-nav-ton); }
.bwt-chip.abt { background: var(--ui-ok-zart); color: var(--marke-ok); }
.bwt-chip.pers { background: var(--marke-akzent-zart); color: var(--marke-akzent); }
.bwt-chip.priv { background: var(--marke-flaeche-2); color: var(--marke-text-2); }

/* Kleines Vorschaubild der ersten Seite; ohne Bild das Art-Symbol */
#bsBereich[data-bereich="wissen"] .bwt-sym { position: relative; inset: auto; z-index: auto; flex: none; width: 22px; height: 28px; display: flex; align-items: center; justify-content: center; overflow: hidden; border-radius: var(--marke-r-s, 6px); background: var(--marke-flaeche-2); pointer-events: none; }
#bsBereich[data-bereich="wissen"] .bwt-sym img { width: 100%; height: 100%; object-fit: cover; object-position: left top; opacity: 1; border-radius: inherit; }
#bsBereich[data-bereich="wissen"] .bwt-sym .bw-gross { opacity: 1; }
#bsBereich[data-bereich="wissen"] .bwt-sym .bw-gross svg { width: 16px; height: 16px; }
:root[data-theme="dark"] #bsBereich[data-bereich="wissen"] .bwt-sym img { opacity: .85; filter: none; }

/* Blaue Zahl in der Liste, wenn Neues dabei ist */
.bsp-zahl.bwt-zahl-neu { color: var(--ui-nav-ton); font-weight: 700; }

/* Detail und Hochlade-Formular in der Mitte */
.bwt-detail, .bwt-hinzu { min-height: 0; overflow-y: auto; scrollbar-width: thin; border: 0; padding: 0; }

/* Dokument-Detail: Knöpfe (a4h-btn) und Art-Marke (a4h-pill) kommen aus der Stil-Basis marke-ui.css – hier nur Abstand; kein Fokus-Ring nach Mausklick (nur Tastatur) */
.bwt-detail .bs-d-aktion { display: flex; flex-wrap: wrap; align-items: center; gap: var(--marke-sp-2); }
.bwt-detail .bs-d-aktion .a4h-btn:focus:not(:focus-visible), .bwt-detail .wa-knoepfe .a4h-btn:focus:not(:focus-visible) { outline: none; box-shadow: none; }
.bwt-detail .bs-d-aktion .a4h-btn:focus-visible, .bwt-detail .wa-knoepfe .a4h-btn:focus-visible { outline: 2px solid var(--marke-grafit); outline-offset: 2px; }

@media (max-width: 900px) {
  #bsBereich[data-bereich="wissen"] .bwt > .bwt-mitte, #bsBereich[data-bereich="wissen"] .bwt > .bw-spalte { grid-column: 1; grid-row: auto; }
  .bwt-tab:not(.bwt-ohne-bes) th:nth-child(3), .bwt-tab:not(.bwt-ohne-bes) td:nth-child(3) { display: none; }
  .bwt-tab th:nth-child(2) { width: 130px; }
}
.bwt-detail .wa-teilen { margin-bottom: var(--marke-sp-3); }
