/* livecut link – dunkles Design wie die livecut-Tools */
:root {
  --bg: #161618;
  --panel: #232326;
  --panel-2: #2c2c30;
  --line: #3a3a3f;
  --text: #f2f2f7;
  --muted: #9a9aa2;
  --accent: #0a84ff;
  --accent-hover: #3d9bff;
  --ok: #30d158;
  --warn: #ffd60a;
  --danger: #ff453a;
  --radius: 10px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { color-scheme: dark; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.5 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
h1 { font-size: 24px; margin: 0 0 12px; font-weight: 650; }
h2 { font-size: 17px; margin: 28px 0 10px; font-weight: 600; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.pre { white-space: pre-wrap; }
.right { text-align: right; }

/* Kopfzeile */
.top {
  display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
  padding: 12px 24px; border-bottom: 1px solid var(--line); background: #1c1c1f;
}
.brand { color: var(--text); font-weight: 700; letter-spacing: .2px; font-size: 16px; }
.brand:hover { color: var(--text); }
.nav { display: flex; gap: 4px; }
.nav a { color: var(--muted); padding: 6px 10px; border-radius: 7px; }
.nav a:hover { color: var(--text); background: var(--panel); }
.nav a.active { color: var(--text); background: var(--panel-2); }
.who { margin-left: auto; display: flex; gap: 10px; align-items: center; font-size: 13px; }
.linkbtn { background: none; border: 0; color: var(--accent); cursor: pointer; font: inherit; padding: 0; }

.page { max-width: 1080px; margin: 0 auto; padding: 28px 24px 64px; }

/* Bausteine */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.narrow { max-width: 560px; margin: 24px auto; }
.narrow-wide { max-width: 720px; margin: 0 auto; }
.center { text-align: center; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.grid2 { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 820px) { .grid2 { grid-template-columns: 1fr; } }
.head-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.head-row h1 { margin: 0; }
.spacer { flex: 1; }
.actions { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.actions form { margin: 0; }

label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--muted); }
input[type=text], input[type=email], input[type=password], input[type=search], textarea, select {
  background: var(--bg); color: var(--text); border: 1px solid var(--line); border-radius: 8px;
  padding: 9px 11px; font: inherit; font-size: 15px; width: 100%;
}
input:focus, textarea:focus, select:focus { outline: 2px solid var(--accent); outline-offset: -1px; border-color: transparent; }
textarea { resize: vertical; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  background: var(--panel-2); color: var(--text); border: 1px solid var(--line); border-radius: 8px;
  padding: 8px 14px; font: inherit; font-size: 14px; cursor: pointer; white-space: nowrap;
}
.btn:hover { background: #36363b; color: var(--text); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-hover); }
.btn.danger { color: var(--danger); }
.btn.small { padding: 4px 10px; font-size: 13px; }
.btn.big { padding: 12px 18px; font-size: 16px; font-weight: 600; }
.btn:disabled { opacity: .45; cursor: default; }

.notice { background: rgba(10,132,255,.12); border: 1px solid rgba(10,132,255,.4); border-radius: 8px; padding: 12px 14px; margin-bottom: 16px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.error { background: rgba(255,69,58,.12); border: 1px solid rgba(255,69,58,.45); color: #ff8a82; border-radius: 8px; padding: 10px 12px; }

.tabs { display: flex; gap: 2px; background: var(--panel); border-radius: 8px; padding: 2px; }
.tabs a { color: var(--muted); padding: 4px 12px; border-radius: 6px; font-size: 13px; }
.tabs a.active { background: var(--panel-2); color: var(--text); }

/* Tabellen */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table.list { width: 100%; border-collapse: collapse; background: var(--panel); }
table.list th { text-align: left; font-weight: 500; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .4px; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.list td { padding: 10px 12px; border-bottom: 1px solid #2f2f34; vertical-align: middle; }
table.list tr:last-child td { border-bottom: 0; }
table.list tbody tr[onclick] { cursor: pointer; }
table.list tbody tr:hover { background: #29292d; }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.list th.num { text-align: right; }
.actions-col { white-space: nowrap; text-align: right; }
.actions-col .btn + .btn, .actions-col .btn + form.inline, .actions-col form.inline + form.inline { margin-left: 4px; }
.filename { word-break: break-all; }

.kind, .status { display: inline-block; font-size: 12px; padding: 2px 8px; border-radius: 99px; white-space: nowrap; }
.kind.send { background: rgba(10,132,255,.15); color: #6cb4ff; }
.kind.request { background: rgba(191,90,242,.15); color: #d29bf5; }
.kind.sync { background: rgba(48,209,88,.15); color: #6fdc8c; }
.status { background: var(--panel-2); color: var(--muted); }
.s-ready, .s-open { background: rgba(48,209,88,.14); color: var(--ok); }
.s-uploading { background: rgba(255,214,10,.14); color: var(--warn); }
.s-expired, .s-closed, .s-deleted, .s-abandoned { color: var(--muted); }

.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; margin: 16px 0 0; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }
.copyrow { display: flex; gap: 8px; margin: 6px 0 4px; }
.copyrow input { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 13px; }
.inline-form { display: flex; gap: 10px; flex-wrap: wrap; }
.inline-form input, .inline-form select { width: auto; flex: 1 1 160px; }

/* Empfängerseite */
.downloads { list-style: none; padding: 0; margin: 16px 0; border-top: 1px solid var(--line); }
.downloads li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.dl-name { flex: 1; display: flex; flex-direction: column; min-width: 0; }

/* Uploader */
.drop {
  border: 2px dashed var(--line); border-radius: var(--radius); padding: 36px 20px; text-align: center;
  background: var(--panel); transition: border-color .15s, background .15s;
}
.drop.over { border-color: var(--accent); background: rgba(10,132,255,.08); }
.drop.locked { display: none; }
.drop-title { font-size: 17px; margin-bottom: 14px; }
.drop-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.filelist { list-style: none; padding: 0; margin: 12px 0 0; display: flex; flex-direction: column; gap: 6px; }
.fileitem { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 9px 12px; }
.fi-row { display: flex; align-items: center; gap: 10px; }
.fi-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fi-size { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.fi-state { font-size: 12px; color: var(--muted); min-width: 80px; text-align: right; }
.fi-remove { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 16px; padding: 0 2px; }
.fi-remove:hover { color: var(--danger); }
.fileitem.done .fi-state { color: var(--ok); }
.fileitem.error .fi-state { color: var(--danger); }
.fileitem.uploading .fi-state { color: var(--accent); }
.minibar { height: 3px; background: var(--panel-2); border-radius: 2px; margin-top: 7px; overflow: hidden; }
.minibar > div { height: 100%; width: 0; background: var(--accent); transition: width .3s; }
.fileitem.done .minibar > div { background: var(--ok); }
.summary { margin-top: 14px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 12px; }
.bar { height: 8px; background: var(--panel-2); border-radius: 4px; overflow: hidden; }
.bar-fill { height: 100%; width: 0; background: var(--accent); transition: width .3s; }
.summary-row { display: flex; justify-content: space-between; gap: 10px; margin-top: 8px; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; flex-wrap: wrap; }
.summary-actions { display: flex; gap: 8px; margin-top: 10px; }

/* Meldungen nach Aktionen */
.flash { border-radius: 8px; padding: 10px 12px; margin-bottom: 16px; }
.flash.ok { background: rgba(48,209,88,.12); border: 1px solid rgba(48,209,88,.4); color: #7ee29a; }
.flash.err { background: rgba(255,69,58,.12); border: 1px solid rgba(255,69,58,.45); color: #ff8a82; }

/* Admin-Portal */
.narrow-left { max-width: 560px; }
.grid-host { display: grid; grid-template-columns: 1fr 110px; gap: 12px; }
.test-mail { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 16px; }
label.check { flex-direction: row; align-items: center; gap: 8px; white-space: nowrap; color: var(--text); font-size: 14px; }
label.check input { width: auto; margin: 0; }
.inline-form label.check { flex: 0 0 auto; }
form.inline { display: inline; margin: 0; }
.row-form { margin: 0; }
.users td { padding-top: 6px; padding-bottom: 6px; }
.users input[type=text], .users select { padding: 5px 8px; font-size: 14px; }
.users input[type=text] { min-width: 140px; }
.users select { width: auto; min-width: 110px; }
.nowrap { white-space: nowrap; }
.nowrap .btn + .btn, .nowrap form.inline { margin-left: 4px; }

/* Geschwindigkeitsgrenze in der Benutzerliste */
.limits { display: flex; align-items: center; gap: 4px; }
.limits .arrow { color: var(--muted); margin-left: 6px; }
.limits .arrow:first-child { margin-left: 0; }
.users input.limit-value { min-width: 0; width: 52px; text-align: right; }
.users select.limit-unit { min-width: 0; width: auto; padding-right: 4px; }
.limit-summary { margin-top: 3px; }
label.check { white-space: normal; }

/* Usage */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-bottom: 24px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; }
.stat strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.meter { height: 8px; background: var(--panel-2); border-radius: 4px; overflow: hidden; margin: 6px 0 2px; }
.meter > div { height: 100%; background: var(--accent); }
.usage-head h2 { margin: 0; }
.usage-head select { width: auto; }
table.list tfoot th { border-top: 1px solid var(--line); border-bottom: 0; color: var(--text); font-size: 14px; text-transform: none; letter-spacing: 0; }

/* Einstellungen */
.card-title { margin: 0; font-size: 17px; }
.narrow-left.stack > .card { margin: 0; }
code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 12px; background: var(--panel-2); padding: 1px 5px; border-radius: 4px; }
.qr { display: flex; justify-content: center; }
.qr svg { width: 220px; height: auto; border-radius: 8px; }
.left { text-align: left; }
.center-actions { justify-content: center; }

/* Ordnerbaum */
.files-head { margin-top: 24px; margin-bottom: 8px; }
.files-head h2 { margin: 0; }
.tree-card { padding: 8px 16px; }
.tree { list-style: none; margin: 0; padding: 0; }
.tree .tree { padding-left: 18px; border-left: 1px solid var(--line); margin-left: 6px; }
.tree-root { margin: 12px 0; }
.tree-file, .tree-dir > details > summary { display: flex; align-items: center; gap: 12px; padding: 8px 0; border-bottom: 1px solid #2f2f34; }
.tree-file .filename { flex: 1; min-width: 0; }
.tree-dir > details > summary { cursor: pointer; list-style: none; }
.tree-dir > details > summary::-webkit-details-marker { display: none; }
.tree-dir > details > summary::before { content: "▸"; color: var(--muted); width: 10px; transition: transform .15s; }
.tree-dir > details[open] > summary::before { transform: rotate(90deg); }
.dir-name { flex: 1; min-width: 0; font-weight: 600; word-break: break-all; }
.dir-name::before { content: ""; display: inline-block; width: 14px; height: 11px; margin-right: 8px; border-radius: 2px;
  background: #5a8fd6; vertical-align: -1px; box-shadow: inset 0 2px 0 #7aa9ea; }
.tree-root > li:last-child > .tree-file, .tree-root > li:last-child > details > summary { border-bottom: 0; }

@media (max-width: 640px) {
  .grid2 { grid-template-columns: 1fr; }
  .tree-file { flex-wrap: wrap; }
  .tree .tree { padding-left: 10px; }
}
.grid-half { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: end; }
@media (max-width: 560px) { .grid-half { grid-template-columns: 1fr; } }

/* Firmen und Logos (Punkte 12–13) */
.brand-logo { display: inline-flex; align-items: center; background: #fff; border-radius: 8px; padding: 10px 14px; margin-bottom: 14px; }
.brand-logo img { display: block; height: 44px; width: auto; max-width: 240px; object-fit: contain; }
.brand-logo.empty { color: #8a8d93; font-size: 13px; height: 44px; padding: 10px 14px; min-width: 120px; justify-content: center; }
.company-list { display: grid; gap: 14px; margin-bottom: 24px; }
.company { display: flex; gap: 20px; align-items: flex-start; }
.company-logo .brand-logo { margin-bottom: 0; }
.company-main { flex: 1; min-width: 0; }
.company-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.logo-form input[type=file] { flex: 1 1 200px; font-size: 13px; }
.company-select { margin-top: 6px; font-size: 13px; }
@media (max-width: 640px) { .company { flex-direction: column; } }
.users input[name=name] { width: 100%; }
.users select.company-select { display: block; width: 100%; min-width: 0; max-width: 180px; margin-top: 6px; }
.users td.right.nowrap { white-space: normal; min-width: 150px; }
.users td.right.nowrap .btn, .users td.right.nowrap form.inline { margin: 2px 0 2px 4px; }

/* Transferlisten: Suchen, Filter, Sortieren, Seiten (Punkt 16) */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; align-items: center; }
.filters input[type=search] { flex: 1 1 260px; min-width: 0; }
.filters select { width: auto; max-width: 200px; }
.page.wide { max-width: none; }
/* Listen bis zum Fensterrand unten: eigener Scrollbereich, Spaltenköpfe bleiben stehen (Höhe setzt app.js) */
.table-wrap.fill { overflow: auto; }
.table-wrap.fill > table.list > thead th { position: sticky; top: 0; z-index: 1; background: var(--panel); box-shadow: inset 0 -1px 0 var(--line); }
table.list th a.sort { color: inherit; text-decoration: none; display: inline-flex; gap: 4px; align-items: center; }
table.list th a.sort:hover, table.list th a.sort.active { color: var(--text); }
table.list th a.sort .arrow { font-size: 10px; min-width: 8px; }
table.list th.num a.sort { justify-content: flex-end; }
table.list.transfers td .small { margin-top: 2px; }
table.list.transfers .ellipsis { max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
table.list tr.gone td { opacity: .55; }
.pager { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
form.resend { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
form.resend label { display: block; margin-bottom: 6px; }
form.resend textarea { width: 100%; }
@media (max-width: 640px) { .filters select { flex: 1 1 45%; max-width: none; } }

/* Send files / Upload-Portal: Gesamtbalken → Details → Balken pro Datei (Punkt 18) */
.send-wrap { max-width: 760px; margin: 0 auto; }
.send-page .summary, #portal-form .summary { margin-top: 12px; }
.files-title { margin: 6px 0 0; font-size: 15px; color: var(--muted); font-weight: 500; }
#upload-files .filelist { margin-top: 8px; }

/* Punkt 20: Dateien/Ordner löschen, Sammel-Löschen */
.x-form { display: inline; margin: 0; }
.x-btn { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 18px; line-height: 1; padding: 2px 6px; border-radius: 6px; }
.x-btn:hover { color: var(--danger); background: rgba(255,69,58,.12); }
.notice.error { background: rgba(255,69,58,.12); border-color: rgba(255,69,58,.45); color: #ff8a82; }
.bulk-bar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 0 0 10px; }
.bulk-bar .spacer { flex: 1; }
th.sel, td.sel { width: 32px; text-align: center; }
td.sel input, th.sel input { width: auto; }

/* Punkt 19: Adressvorschläge */
.suggest-wrap { position: relative; }
.suggest-list { position: absolute; left: 0; right: 0; top: 100%; z-index: 20; margin: 4px 0 0; padding: 4px; list-style: none;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.4); }
.suggest-list li { display: flex; align-items: center; border-radius: 6px; }
.suggest-list li.active, .suggest-list li:hover { background: rgba(10,132,255,.18); }
.suggest-pick { flex: 1; text-align: left; background: none; border: 0; color: var(--text); font: inherit; padding: 6px 8px; cursor: pointer;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.suggest-src { color: var(--muted); font-size: 12px; margin-left: 8px; }
.suggest-x { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 16px; padding: 4px 10px; }
.suggest-x:hover { color: var(--danger); }

/* Punkt 21.3: Choose folder */
.folder-choice { display: flex; flex-direction: column; gap: 6px; }
.folder-choice .label { font-size: 14px; }
.folder-current { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.folder-picker { background: var(--panel-2); }
.folder-list { list-style: none; margin: 0; padding: 0; max-height: 260px; overflow: auto; border: 1px solid var(--line); border-radius: 8px; }
.folder-list li { border-bottom: 1px solid var(--line); }
.folder-list li:last-child { border-bottom: 0; }
.folder-list li.muted { padding: 8px 10px; }
.folder-item { display: block; width: 100%; text-align: left; padding: 8px 10px; color: var(--text); }
.folder-item:hover { background: rgba(10,132,255,.12); }
.folder-path { display: flex; gap: 10px; align-items: center; }

/* Punkt 21.6: Kontingente, Firmen-Speicher */
.quota-input { width: 90px !important; }
.count-input { width: 60px !important; }
.sync-days { align-items: center; }
.sync-days .count-input { flex: none; }
.company-package { gap: 8px; align-items: center; flex-wrap: wrap; }
.user-disabled td { opacity: .55; }
.user-disabled td:last-child { opacity: 1; }
.company-storage { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.company-storage label { display: flex; flex-direction: column; gap: 2px; flex: 1 1 160px; }
.company-storage select, .company-storage input { width: 100%; }
.company-speed { display: flex; gap: 6px 12px; flex-wrap: wrap; align-items: center; }
.company-speed > .muted { flex: 1 0 100%; }
.company-speed .speed-row { display: inline-flex; gap: 4px; align-items: center; }
.company-speed .arrow { color: var(--muted); }
.company-speed input.limit-value { min-width: 0; width: 60px; text-align: right; }
.company-speed select.limit-unit { min-width: 0; width: auto; padding-right: 4px; }

/* Punkt 17: Admin → Current */
table.current td { vertical-align: middle; }
.cur-prog { display: flex; flex-direction: column; gap: 4px; min-width: 160px; align-items: stretch; text-align: right; }
tr.paused td { color: var(--muted); }
tr.paused .bar-fill { background: var(--warn); }

table.current { min-width: 680px; }
table.current td.filename { min-width: 140px; word-break: break-word; }

/* Admin → Storage: Share-Tabelle (Punkt 25) */
table.shares th.c, table.shares td.c { text-align: center; }
table.shares tr.muted td:first-child { color: var(--muted, #8a8f98); }

/* Prüfsumme pro Datei (Punkt 27) */
.check-ok { color: var(--ok, #3fb950); }
.check-bad { color: var(--danger, #f85149); font-weight: 500; }

/* Admin → Receivers (Punkt 23) */
.pair-code code { font-size: 26px; letter-spacing: 3px; padding: 6px 14px; }
.snippet { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 12px; background: var(--panel-2); padding: 12px 14px;
  border-radius: 6px; overflow-x: auto; white-space: pre; margin: 0; }
.receiver { border-top: 1px solid var(--line); padding-top: 14px; }
.receiver:first-of-type { border-top: 0; }

/* Admin → Log */
tr.alarm td { color: var(--danger); }

/* Send from the NAS (Stufe 5) */
.nas-row { display: flex; gap: 8px; align-items: center; padding: 4px 10px; }
.nas-row .folder-item { padding: 4px 0; }
.nas-list { max-height: 360px; }
.nas-picked { margin: 0; padding-left: 18px; max-height: 140px; overflow: auto; }
.nas-sends ul { margin: 4px 0 0; padding-left: 18px; }
.tree-file .media { white-space: nowrap; }
.tree-file .thumb { flex: none; display: block; width: 72px; height: 48px; border-radius: 4px; overflow: hidden; background: #000; }
.tree-file .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tree-file .thumb:hover { outline: 1px solid var(--accent); }
.tree-file .thumb + .filename { min-width: 120px; }
/* Admin → Receivers als Tabelle (Entwurf A) */
table.receivers > tbody > tr.rcv-row { cursor: pointer; }
table.receivers > tbody > tr.rcv-row.open > td { border-bottom: 0; background: var(--panel-2); }
table.receivers > tbody > tr.rcv-detail > td { background: var(--panel-2); padding: 4px 16px 18px; }
table.receivers > tbody > tr.rcv-detail:hover { background: transparent; }
table.receivers > tbody:not(:last-child) > tr.rcv-detail > td { border-bottom: 1px solid var(--line); }
table.receivers .rcv-toggle .chev { display: inline-block; transition: transform .15s; color: var(--muted); font-size: 20px; line-height: 1; padding: 2px 6px; }
table.receivers .rcv-toggle[aria-expanded="true"] .chev { transform: rotate(180deg); }
.rcv-meter { display: inline-block; width: 64px; height: 6px; background: var(--line); border-radius: 3px; overflow: hidden; vertical-align: middle; margin-right: 6px; }
.rcv-meter > span { display: block; height: 100%; background: var(--muted); }
.rcv-meter.low > span { background: var(--warn); }
.rcv-upd { color: var(--warn); font-weight: 500; }
.rcv-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 8px 18px; }
.rcv-facts > div > span.muted:first-child { display: block; }
.rcv-detail .table-wrap table.list { background: transparent; }
.rcv-edit > summary, .rcv-detail details.hotfolders > summary { cursor: pointer; }
@media (max-width: 640px) { table.receivers .opt { display: none; } }
.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; }

/* Support-Hinweis für Benutzer (nicht für livecut-Admins) */
footer.support { max-width: 1080px; margin: -40px auto 32px; padding: 0 24px; text-align: center; }
footer.support p { margin: 0 0 6px; }
footer.support .legal { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; }
footer.support .legal a { text-decoration: none; }
/* Punkt 81: Login-Seite mit Features, connector-Download */
.login-wrap { max-width: 980px; margin: 24px auto; display: grid; grid-template-columns: minmax(0, 400px) minmax(0, 1fr); gap: 40px; align-items: start; }
.login-card { margin: 0; }
.features h2 { margin: 4px 0 8px; font-size: 22px; }
.feature-list { list-style: none; margin: 20px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 18px 24px; }
.feature-list li { display: flex; flex-direction: column; gap: 2px; padding-left: 14px; border-left: 2px solid var(--accent); }
.feature-list span { color: var(--muted); font-size: 14px; }
@media (max-width: 820px) {
  .login-wrap { grid-template-columns: 1fr; gap: 28px; margin-top: 8px; }
  .feature-list { grid-template-columns: 1fr; }
}
.row-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.dl-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.dl-item { background: var(--panel-2); border-radius: var(--radius); padding: 16px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.dl-item .card-title, .dl-item p { margin: 0; }
.dl-item .hash { display: block; margin-top: 6px; word-break: break-all; font-size: 11px; }
ol.steps { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 10px; }
ol.steps ul { margin: 6px 0 0; padding-left: 18px; color: var(--muted); }
footer.support a { color: var(--muted); text-decoration: underline; }
footer.support a:hover { color: var(--text); }

/* Großansicht der Vorschaubilder (lightbox.js) */
html.lb-open { overflow: hidden; }
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(0,0,0,.86); display: flex; align-items: center; justify-content: center; gap: 8px; padding: 24px 8px; }
.lightbox[hidden] { display: none; }
.lightbox figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 8px; max-width: min(800px, calc(100vw - 112px)); }
.lightbox img { display: block; max-width: 100%; max-height: calc(100vh - 120px); width: auto; height: auto; border-radius: 4px; background: #000; }
.lightbox figcaption { display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; color: var(--text); }
.lightbox .lb-name { overflow-wrap: anywhere; }
.lightbox button { background: none; border: 0; color: #fff; font-size: 40px; line-height: 1; cursor: pointer; padding: 8px 12px; opacity: .75; }
.lightbox button:hover, .lightbox button:focus-visible { opacity: 1; }
.lightbox .lb-close { position: absolute; top: 8px; right: 12px; font-size: 36px; }
@media (max-width: 640px) { .lightbox figure { max-width: calc(100vw - 16px); } .lightbox .lb-prev, .lightbox .lb-next { position: absolute; bottom: 12px; } .lightbox .lb-prev { left: 16px; } .lightbox .lb-next { right: 16px; } }

/* Admin-Tabellen kompakt (Punkt 36): eine Zeile pro Eintrag, Bearbeiten aufklappbar */
.add-box { padding: 12px 16px; margin-bottom: 16px; }
.add-box > summary { list-style: none; cursor: pointer; display: inline-block; }
.add-box > summary::-webkit-details-marker { display: none; }
.add-box[open] > summary { margin-bottom: 12px; }
.add-form, .edit-grid { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: flex-end; }
.add-form label, .edit-grid label { flex: 0 1 200px; gap: 4px; }
.edit-grid label.wide { flex-basis: 320px; }
.add-form label.check { flex: 0 0 auto; padding-bottom: 8px; }
.add-form input, .add-form select, .edit-grid input[type=text], .edit-grid select { padding: 6px 9px; font-size: 14px; }
.edit-grid .field { display: flex; flex-direction: column; gap: 4px; }
.edit-grid .field-label { font-size: 13px; color: var(--muted); }
.edit-grid .field-hint { padding-bottom: 8px; }
.edit-grid .limits input.limit-value { width: 56px; text-align: right; }
.edit-grid .limits select.limit-unit { width: auto; padding-right: 4px; }
.edit-grid input.quota-input, .edit-grid input.count-input { flex: none; }
.edit-grid .logo-form { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.edit-grid .logo-form input[type=file] { flex: 1 1 200px; font-size: 13px; width: auto; }
.edit-sections { display: grid; gap: 14px; }
.edit-sections > * + * { padding-top: 14px; border-top: 1px solid var(--line); }
.edit-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.edit-actions form { margin: 0; }
.detail-note { margin: 0 0 12px; }
table.list.compact td { padding: 7px 12px; }
table.list.compact td.ellipsis { max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
table.list.compact th.num, table.list.compact td.num { text-align: right; font-variant-numeric: tabular-nums; }
table.list tr.detail > td { background: var(--panel-2); padding: 14px 16px 16px; }
table.list tbody tr.detail:hover { background: none; }
table.list tr.item.open > td { background: var(--panel-2); border-bottom-color: transparent; }
table.list th[data-sort] { cursor: pointer; user-select: none; }
table.list th[data-sort]:hover, table.list th.sorted { color: var(--text); }
table.list th[data-sort]::after { content: ""; display: inline-block; width: 10px; margin-left: 4px; font-size: 10px; }
table.list th.sorted[data-dir=asc]::after { content: "▲"; }
table.list th.sorted[data-dir=desc]::after { content: "▼"; }
.tag-bad { font-size: 11px; color: var(--danger); border: 1px solid currentColor; border-radius: 5px; padding: 0 5px; margin-left: 4px; }
.logo-cell { width: 1%; padding-right: 0 !important; }
.logo-thumb { display: inline-flex; align-items: center; background: #fff; border-radius: 5px; padding: 3px 6px; }
.logo-thumb img { display: block; height: 18px; width: auto; max-width: 90px; object-fit: contain; }
.logo-thumb.big img { height: 34px; max-width: 200px; }
@media (max-width: 640px) {
  .add-form label, .edit-grid label { flex-basis: 100%; }
}
p.warn { color: var(--warn); }
.narrow-field { max-width: 220px; }
