/* Kamera-Archiv · Leitstand-Optik, hell/dunkel */
:root {
  --bg: #f4f3ef; --bg2: #ebe9e3; --panel: #ffffff; --panel2: #f8f7f4;
  --line: #dcd9d0; --line2: #c9c5ba;
  --fg: #1b1d21; --fg2: #4a4e57; --mute: #7a7e87;
  --acc: #d9480f; --acc-fg: #ffffff; --acc-soft: #fbe3d6;
  --ok: #2b8a3e; --warn: #b7791f; --err: #c92a2a; --info: #1c6dd0;
  --rec: #e03131;
  --shadow: 0 1px 2px rgba(0,0,0,.06), 0 8px 24px rgba(0,0,0,.06);
  --r: 10px; --r-sm: 6px;
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", "Cascadia Code", Menlo, Consolas, monospace;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --side: 284px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1116; --bg2: #141820; --panel: #171b22; --panel2: #1d222b;
    --line: #262c36; --line2: #333a46;
    --fg: #e8eaed; --fg2: #b4bac4; --mute: #7d8592;
    --acc: #ff8a3d; --acc-fg: #1a0e05; --acc-soft: #3a2416;
    --ok: #51cf66; --warn: #fcc419; --err: #ff6b6b; --info: #4dabf7;
    --rec: #ff5a4e;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 10px 30px rgba(0,0,0,.35);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e1116; --bg2: #141820; --panel: #171b22; --panel2: #1d222b;
  --line: #262c36; --line2: #333a46;
  --fg: #e8eaed; --fg2: #b4bac4; --mute: #7d8592;
  --acc: #ff8a3d; --acc-fg: #1a0e05; --acc-soft: #3a2416;
  --ok: #51cf66; --warn: #fcc419; --err: #ff6b6b; --info: #4dabf7;
  --rec: #ff5a4e;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 10px 30px rgba(0,0,0,.35);
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--fg); font: 14px/1.45 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
h1, h2, h3 { margin: 0 0 .6em; line-height: 1.2; letter-spacing: -.01em; }
h1 { font-size: 22px; } h2 { font-size: 17px; } h3 { font-size: 14px; text-transform: uppercase; letter-spacing: .06em; color: var(--mute); }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--mute); } .tiny { font-size: 12px; } .hidden { display: none !important; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; } .spacer { flex: 1; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 520px) { .grid2 { grid-template-columns: 1fr; } }

/* Formulare */
label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--fg2); font-weight: 500; }
label.check { flex-direction: row; align-items: center; gap: 8px; font-size: 13px; color: var(--fg); font-weight: 400; cursor: pointer; }
input, select, textarea {
  font: inherit; color: var(--fg); background: var(--panel2); border: 1px solid var(--line);
  border-radius: var(--r-sm); padding: 7px 9px; min-height: 34px; width: 100%;
}
input[type=checkbox], input[type=radio] { width: auto; min-height: 0; accent-color: var(--acc); }
input[type=color] { padding: 2px; height: 34px; }
textarea { min-height: 70px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid color-mix(in srgb, var(--acc) 55%, transparent); outline-offset: 0; border-color: var(--acc); }

.btn {
  font: inherit; font-weight: 600; font-size: 13px; display: inline-flex; align-items: center; gap: 6px; justify-content: center;
  border: 1px solid var(--line2); background: var(--panel2); color: var(--fg); border-radius: var(--r-sm);
  padding: 7px 12px; min-height: 34px; cursor: pointer; text-decoration: none; white-space: nowrap;
}
.btn:hover { border-color: var(--fg2); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.primary { background: var(--acc); border-color: var(--acc); color: var(--acc-fg); }
.btn.primary:hover { filter: brightness(1.08); }
.btn.danger { color: var(--err); border-color: color-mix(in srgb, var(--err) 45%, var(--line)); }
.btn.danger:hover { background: var(--err); color: #fff; }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.ghost:hover { background: var(--panel2); border-color: var(--line); }
.btn.sm { padding: 4px 8px; min-height: 28px; font-size: 12px; }
.btn.wide { width: 100%; }
.btn.on { background: var(--acc-soft); border-color: var(--acc); color: var(--acc); }
.icon-btn { font: inherit; font-size: 16px; width: 34px; height: 34px; display: inline-grid; place-items: center; border-radius: var(--r-sm);
  border: 1px solid transparent; background: transparent; color: var(--fg2); cursor: pointer; }
.icon-btn:hover { background: var(--panel2); border-color: var(--line); color: var(--fg); }
.link { background: none; border: 0; padding: 0; color: var(--acc); font: inherit; cursor: pointer; text-decoration: underline; }
.msg { font-size: 13px; } .msg.err { color: var(--err); } .msg.ok { color: var(--ok); }
.pill { display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--line); border-radius: 99px; padding: 2px 9px; font-size: 12px; color: var(--fg2); background: var(--panel2); }
.badge { display: inline-block; font: 600 10px/1 var(--mono); letter-spacing: .04em; padding: 3px 5px; border-radius: 4px; background: rgba(0,0,0,.6); color: #fff; }
.badge.hevc { background: #7048e8; } .badge.warn { background: var(--warn); color: #000; } .badge.err { background: var(--err); }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; }
.chip { font: inherit; font-size: 12px; border: 1px solid var(--line); background: var(--panel2); color: var(--fg2); border-radius: 99px; padding: 3px 10px; cursor: pointer; }
.chip.on { background: var(--acc-soft); color: var(--acc); border-color: var(--acc); }
.chips { display: flex; flex-wrap: wrap; gap: 5px; }

/* Marke */
.brand { display: inline-flex; align-items: center; gap: 9px; font-weight: 700; letter-spacing: -.01em; text-decoration: none; font-size: 15px; }
.brand.big { font-size: 22px; }
.rec { width: 10px; height: 10px; border-radius: 50%; background: var(--rec); box-shadow: 0 0 0 3px color-mix(in srgb, var(--rec) 25%, transparent); animation: rec 2.4s ease-in-out infinite; }
@keyframes rec { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .rec { animation: none; } }

/* Kopfzeile */
.topbar { position: sticky; top: 0; z-index: 30; height: 56px; display: flex; align-items: center; gap: 10px; padding: 0 14px;
  padding-top: env(safe-area-inset-top); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line); }
.topbar .search { flex: 1; min-width: 140px; max-width: 460px; position: relative; }
.topbar .search input { padding-left: 30px; background: var(--panel); }
.topbar .search::before { content: "⌕"; position: absolute; left: 10px; top: 50%; transform: translateY(-52%); color: var(--mute); font-size: 15px; }
.crumb { color: var(--mute); font-family: var(--mono); }
.menu { position: relative; }
.menu-pop { position: absolute; right: 0; top: 40px; min-width: 210px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: var(--shadow); padding: 6px; z-index: 50; }
.menu-pop a, .menu-pop button { display: block; width: 100%; text-align: left; padding: 8px 10px; border-radius: var(--r-sm); background: none; border: 0; color: var(--fg); font: inherit; text-decoration: none; cursor: pointer; }
.menu-pop a:hover, .menu-pop button:hover { background: var(--panel2); }
.menu-pop hr { border: 0; border-top: 1px solid var(--line); margin: 5px 0; }

/* Grundlayout */
.layout { display: grid; grid-template-columns: var(--side) 1fr; min-height: calc(100vh - 56px); }
.side { border-right: 1px solid var(--line); padding: 14px; display: flex; flex-direction: column; gap: 18px;
  position: sticky; top: 56px; height: calc(100vh - 56px); overflow-y: auto; background: var(--bg); }
.side section { display: flex; flex-direction: column; gap: 7px; }
.side h3 { margin: 0; display: flex; justify-content: space-between; align-items: center; }
.cam-item { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: var(--r-sm); cursor: pointer; border: 1px solid transparent; user-select: none; }
.cam-item:hover { background: var(--panel2); }
.cam-item.on { background: var(--panel); border-color: var(--line2); }
.cam-item .n { margin-left: auto; font: 12px var(--mono); color: var(--mute); }
.cam-item .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cam-item .chk { width: 15px; height: 15px; border: 1.5px solid var(--line2); border-radius: 4px; flex: none; display: grid; place-items: center; font-size: 10px; color: transparent; }
.cam-item.on .chk { background: var(--acc); border-color: var(--acc); color: var(--acc-fg); }
.main { min-width: 0; padding: 14px 18px 120px; }
.backdrop { display: none; }
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
  .side { position: fixed; z-index: 60; left: 0; top: 0; height: 100%; width: min(320px, 88vw); transform: translateX(-102%);
    transition: transform .2s ease; box-shadow: var(--shadow); padding-top: calc(14px + env(safe-area-inset-top)); }
  .side.open { transform: none; }
  .backdrop.open { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 55; }
  .main { padding: 10px 10px 120px; }
  .topbar .hide-sm { display: none; }
}
@media (min-width: 901px) { .only-sm { display: none !important; } }

/* Ergebniskopf */
.summary { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.summary .stats { font-family: var(--mono); font-size: 13px; color: var(--fg2); }
.active-filters { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 10px; }

/* Tagesgruppen und Kacheln */
.day { margin-bottom: 18px; }
.day-head { position: sticky; top: 56px; z-index: 5; display: flex; align-items: baseline; gap: 10px; padding: 8px 0 6px;
  background: linear-gradient(var(--bg) 70%, transparent); }
.day-head b { font-size: 14px; } .day-head span { font: 12px var(--mono); color: var(--mute); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
@media (max-width: 520px) { .grid { grid-template-columns: repeat(2, 1fr); gap: 6px; } }
.tile { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; cursor: pointer;
  transition: border-color .12s, transform .12s; content-visibility: auto; contain-intrinsic-size: 220px 190px; }
.tile:hover { border-color: var(--line2); }
.tile.sel { border-color: var(--acc); box-shadow: 0 0 0 2px var(--acc); }
.tile .thumb { aspect-ratio: 16/9; background: var(--bg2) center/cover no-repeat; position: relative; display: grid; place-items: center; color: var(--mute); }
.tile .thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tile .tl { position: absolute; left: 6px; top: 6px; display: flex; gap: 4px; }
.tile .tr { position: absolute; right: 6px; top: 6px; display: flex; gap: 4px; }
.tile .br { position: absolute; right: 6px; bottom: 6px; }
.tile .flag { font-size: 13px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.6)); }
.tile .sel-box { width: 22px; height: 22px; border-radius: 6px; border: 2px solid rgba(255,255,255,.9); background: rgba(0,0,0,.35);
  display: grid; place-items: center; color: #fff; font-size: 13px; opacity: 0; transition: opacity .1s; }
.tile:hover .sel-box, .selecting .tile .sel-box, .tile.sel .sel-box { opacity: 1; }
.tile.sel .sel-box { background: var(--acc); border-color: var(--acc); color: var(--acc-fg); }
@media (hover: none) { .tile .sel-box { opacity: .85; } }
.tile .meta { padding: 7px 9px 8px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tile .meta .t1 { display: flex; align-items: center; gap: 6px; font: 600 13px var(--mono); }
.tile .meta .t2 { font-size: 12px; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile .meta .title { font-size: 12px; color: var(--fg2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list .grid { grid-template-columns: 1fr; gap: 4px; }
.list .tile { display: grid; grid-template-columns: 136px 1fr; contain-intrinsic-size: 400px 78px; }
.list .tile .meta { justify-content: center; }
.empty { padding: 60px 20px; text-align: center; color: var(--mute); border: 1px dashed var(--line2); border-radius: var(--r); }
.more { display: flex; justify-content: center; padding: 18px; }

/* Mehrfachauswahl */
.bulkbar { position: fixed; left: 50%; bottom: calc(16px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 40;
  display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: center;
  background: var(--panel); border: 1px solid var(--line2); border-radius: 14px; box-shadow: var(--shadow); padding: 8px 10px; max-width: calc(100vw - 20px); }
.bulkbar .count { font: 600 13px var(--mono); padding: 0 6px; }

/* Player */
.modal { position: fixed; inset: 0; z-index: 80; background: rgba(5,7,10,.82); display: flex; align-items: stretch; justify-content: center; }
.modal-box { background: var(--panel); width: 100%; max-width: 1500px; margin: 2vh 2vw; border-radius: 14px; overflow: hidden; display: grid;
  grid-template-columns: 1fr 360px; box-shadow: var(--shadow); border: 1px solid var(--line); }
.player { background: #000; display: flex; flex-direction: column; min-height: 0; position: relative; }
.player-top { display: flex; align-items: center; gap: 8px; padding: 8px 10px; background: #0a0c10; color: #e8eaed; }
.player-top .icon-btn { color: #c8ccd3; } .player-top .icon-btn:hover { background: #1b2028; border-color: #2a313c; color: #fff; }
.player-top .ttl { font: 600 13px var(--mono); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
.player-top .srcswitch { flex: none; }
.player video { flex: 1; width: 100%; min-height: 0; background: #000; max-height: calc(96vh - 140px); }
.player .notice { position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%); max-width: 420px; text-align: center; color: #e8eaed;
  background: rgba(15,18,24,.92); border: 1px solid #2a313c; border-radius: 12px; padding: 18px; }
.srcswitch { display: inline-flex; border: 1px solid #2a313c; border-radius: 8px; overflow: hidden; }
.srcswitch button { font: 600 12px var(--sans); background: transparent; color: #aab1bc; border: 0; padding: 5px 10px; cursor: pointer; }
.srcswitch button.on { background: #2a313c; color: #fff; } .srcswitch button:disabled { opacity: .35; cursor: not-allowed; }
.timeline { position: relative; height: 34px; margin: 0 10px 10px; background: #12161d; border-radius: 6px; cursor: pointer; border: 1px solid #222832; }
.timeline .range { position: absolute; top: 0; bottom: 0; background: color-mix(in srgb, var(--acc) 35%, transparent); border-left: 2px solid var(--acc); border-right: 2px solid var(--acc); }
.timeline .head { position: absolute; top: -3px; bottom: -3px; width: 2px; background: #fff; }
.timeline .lbl { position: absolute; bottom: 3px; font: 10px var(--mono); color: #8c95a3; }
.panel { overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 16px; border-left: 1px solid var(--line); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; font-size: 13px; }
.kv dt { color: var(--mute); } .kv dd { margin: 0; font-family: var(--mono); word-break: break-all; }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); }
.tabs button { font: 600 13px var(--sans); background: none; border: 0; color: var(--mute); padding: 8px 10px; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs button.on { color: var(--fg); border-color: var(--acc); }
.tagedit { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; border: 1px solid var(--line); background: var(--panel2); border-radius: var(--r-sm); padding: 5px; }
.tagedit input { border: 0; background: transparent; padding: 3px; min-height: 0; flex: 1; min-width: 90px; outline: none; }
.tag { display: inline-flex; gap: 4px; align-items: center; background: var(--acc-soft); color: var(--acc); border-radius: 99px; padding: 2px 8px; font-size: 12px; font-weight: 600; }
.tag button { background: none; border: 0; color: inherit; cursor: pointer; padding: 0; font-size: 13px; line-height: 1; }
@media (max-width: 1000px) {
  .modal-box { grid-template-columns: 1fr; margin: 0; border-radius: 0; overflow-y: auto; display: block; }
  .player video { max-height: 56vh; }
  .panel { border-left: 0; border-top: 1px solid var(--line); }
}

/* Karten, Tabellen, Admin */
.page { padding: 18px; max-width: 1280px; margin: 0 auto; }
.page.narrow { max-width: 1000px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; margin-bottom: 14px; }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: 13px; }
th { text-align: left; font-weight: 600; color: var(--mute); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid var(--line); padding: 8px; white-space: nowrap; }
td { border-bottom: 1px solid var(--line); padding: 8px; vertical-align: top; }
tr:last-child td { border-bottom: 0; }
.status { font: 600 11px var(--mono); padding: 2px 7px; border-radius: 99px; border: 1px solid; white-space: nowrap; }
.status.active, .status.done, .status.ready, .status.ok { color: var(--ok); border-color: currentColor; }
.status.failed, .status.rejected, .status.error { color: var(--err); border-color: currentColor; }
.status.activating, .status.running, .status.queued { color: var(--warn); border-color: currentColor; }
.status.superseded, .status.uploaded, .status.pruned, .status.skipped { color: var(--mute); border-color: currentColor; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.kpi { background: var(--panel2); border: 1px solid var(--line); border-radius: var(--r); padding: 12px; }
.kpi .v { font: 600 22px var(--mono); } .kpi .l { color: var(--mute); font-size: 12px; }
.admin-tabs { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 14px; }
.perm-grid td, .perm-grid th { text-align: center; } .perm-grid td:first-child, .perm-grid th:first-child { text-align: left; }
details summary { cursor: pointer; color: var(--fg2); }
pre { font: 12px var(--mono); white-space: pre-wrap; background: var(--panel2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px; margin: 6px 0 0; max-height: 260px; overflow: auto; }

/* Dialoge */
dialog { border: 1px solid var(--line2); border-radius: 14px; background: var(--panel); color: var(--fg); padding: 18px; width: min(560px, calc(100vw - 24px)); box-shadow: var(--shadow); }
dialog::backdrop { background: rgba(0,0,0,.5); }
dialog .actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }

/* Toasts */
.toasts { position: fixed; right: 14px; top: 66px; z-index: 100; display: flex; flex-direction: column; gap: 8px; max-width: min(380px, calc(100vw - 28px)); }
.toast { background: var(--panel); border: 1px solid var(--line2); border-left: 4px solid var(--info); border-radius: var(--r-sm); padding: 10px 12px; box-shadow: var(--shadow); font-size: 13px; animation: tin .18s ease; }
.toast.ok { border-left-color: var(--ok); } .toast.err { border-left-color: var(--err); }
@keyframes tin { from { opacity: 0; transform: translateY(-6px); } }

/* Anmeldung, Freigabe, Deploy */
body.auth, body.share { display: grid; place-items: center; min-height: 100vh; padding: 16px; }
.auth-box { width: min(380px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 28px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 22px; }
.share-box { width: min(960px, 100%); display: flex; flex-direction: column; gap: 12px; }
.share-box video, .share-box .share-img { width: 100%; border-radius: 12px; background: #000; max-height: 75vh; object-fit: contain; }
.placeholder { aspect-ratio: 16/9; display: grid; place-content: center; text-align: center; background: var(--panel); border: 1px dashed var(--line2); border-radius: 12px; }
.drop { border: 2px dashed var(--line2); border-radius: var(--r); padding: 22px; text-align: center; transition: border-color .12s, background .12s; }
.drop.over { border-color: var(--acc); background: var(--acc-soft); }
.drop p { margin: 4px 0; }
.hashcmp { min-height: 1.2em; word-break: break-all; }
.hashcmp .ok { color: var(--ok); } .hashcmp .bad { color: var(--err); }
.progress { height: 6px; background: var(--panel2); border-radius: 99px; overflow: hidden; border: 1px solid var(--line); }
.progress div { height: 100%; width: 0; background: var(--acc); transition: width .15s; }
.overlay { position: fixed; inset: 0; background: rgba(0,0,0,.6); display: grid; place-items: center; z-index: 90; }
.overlay-box { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 26px 30px; text-align: center; min-width: 260px; }
.spinner { width: 28px; height: 28px; border: 3px solid var(--line2); border-top-color: var(--acc); border-radius: 50%; margin: 0 auto 12px; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Bilder und Standorte */
.player .still { flex: 1; min-height: 0; width: 100%; object-fit: contain; background: #000; max-height: calc(96vh - 60px); }
.cam-group { font: 600 11px var(--mono); color: var(--mute); text-transform: uppercase; letter-spacing: .06em; padding: 8px 8px 2px; }
.badge.img { background: #1c7ed6; }
@media (max-width: 1000px) { .player .still { max-height: 60vh; } }

/* Filmstreifen beim Ueberfahren */
.tile .thumb[data-strip] { touch-action: pan-y; background-repeat: no-repeat; }
.tile .thumb.scrub img { opacity: 0; }
.tile .scrubbar { position: absolute; left: 0; bottom: 0; height: 3px; width: 0; background: var(--acc); pointer-events: none; }

/* Sammel-Freigabe */
body.coll .tile { text-decoration: none; color: inherit; display: block; }
.coll-head { display: flex; gap: 16px; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; margin-bottom: 8px; }
.coll-note { white-space: pre-wrap; max-width: 70ch; }
.coll-media { width: 100%; max-height: 75vh; border-radius: 12px; background: #000; object-fit: contain; }

/* Sortierbare Tabellen, Explorer */
th.sorthead { cursor: pointer; user-select: none; }
th.sorthead:hover { color: var(--fg); }
th.sorthead.asc::after { content: " ▲"; font-size: 9px; }
th.sorthead.desc::after { content: " ▼"; font-size: 9px; }
.crumbs { font-family: var(--mono); font-size: 13px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.crumbs a { text-decoration: none; color: var(--acc); }

/* Bucket */
.warnbox { border-color: color-mix(in srgb, var(--warn) 55%, var(--line)); background: color-mix(in srgb, var(--warn) 8%, var(--panel)); }
.warnbox p { margin: 4px 0; }
.agebars { display: grid; gap: 6px; margin: 10px 0 14px; max-width: 640px; }
.agebar { display: grid; grid-template-columns: 120px 1fr 80px; gap: 10px; align-items: center; font-size: 12px; }
.agebar div { height: 10px; background: var(--panel2); border-radius: 99px; overflow: hidden; border: 1px solid var(--line); }
.agebar i { display: block; height: 100%; background: var(--acc); }
.agebar b { text-align: right; font-weight: 500; }
