/* ImmoBase – schlichtes, systemnahes Design ohne externe Abhängigkeiten. */
:root {
  --bg: #f6f7f9; --panel: #fff; --line: #e4e7ec; --line-strong: #d0d5dd;
  --text: #1a2233; --muted: #667085; --primary: #1d4ed8; --primary-dark: #1a40b0; --primary-soft: #eef3ff;
  --ok: #067647; --ok-soft: #ecfdf3; --warn: #b54708; --warn-soft: #fffaeb; --err: #b42318; --err-soft: #fef3f2;
  --radius: 10px; --shadow: 0 1px 2px rgba(16, 24, 40, .05);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html { font-size: 15px; }
body { margin: 0; color: var(--text); background: var(--bg); line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.45rem; margin: 0; font-weight: 650; letter-spacing: -.01em; }
h2 { font-size: 1.02rem; margin: 0; font-weight: 600; }
h3 { font-size: .95rem; margin: 1.2rem 0 .4rem; font-weight: 600; }
p { margin: .5rem 0; }
small, .muted { color: var(--muted); }
.icon { width: 18px; height: 18px; flex: none; vertical-align: -3px; }
.neg { color: var(--err); }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
[hidden] { display: none !important; }

/* Layout */
.app { display: flex; min-height: 100vh; }
.side { width: 224px; background: var(--panel); border-right: 1px solid var(--line); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; flex: none; }
.brand { display: block; padding: 18px 18px 14px; color: var(--text); }
.brand:hover { text-decoration: none; }
.logo { font-weight: 700; font-size: 1.1rem; letter-spacing: -.02em; display: inline-flex; align-items: center; gap: 8px; }
.logo-mark { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 7px; background: var(--primary); color: #fff; font-size: .9rem; }
.side nav { padding: 4px 10px; display: flex; flex-direction: column; gap: 2px; overflow-y: auto; flex: 1; }
.side nav a { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 8px; color: #344054; font-weight: 500; }
.side nav a:hover { background: var(--bg); text-decoration: none; }
.side nav a.active { background: var(--primary-soft); color: var(--primary); }
.side-foot { padding: 12px 18px 16px; border-top: 1px solid var(--line); font-size: .87rem; }
.side-foot .org { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-foot .plan { color: var(--muted); }
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.top { display: flex; align-items: center; gap: 12px; padding: 10px 28px; border-bottom: 1px solid var(--line); background: var(--panel); position: sticky; top: 0; z-index: 5; }
.crumbs { flex: 1; min-width: 0; color: var(--muted); font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crumbs a { color: var(--muted); }
.crumbs span { margin: 0 6px; color: var(--line-strong); }
.crumbs strong { color: var(--text); font-weight: 500; }
.top-right { display: flex; align-items: center; gap: 8px; }
.nav-toggle { display: none; }
.content { padding: 24px 28px 64px; max-width: 1280px; width: 100%; }
.content.narrow { max-width: 820px; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* Menü */
.menu { position: relative; }
.menu summary { list-style: none; cursor: pointer; padding: 6px 10px; border-radius: 8px; font-weight: 500; }
.menu summary::-webkit-details-marker { display: none; }
.menu summary:hover { background: var(--bg); }
.menu-items { position: absolute; right: 0; top: calc(100% + 4px); background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 8px 24px rgba(16, 24, 40, .12); min-width: 190px; padding: 6px; z-index: 20; }
.menu-items a, .menu-items button { display: block; width: 100%; text-align: left; padding: 7px 10px; border-radius: 6px; color: var(--text); background: none; border: 0; font: inherit; cursor: pointer; }
.menu-items a:hover, .menu-items button:hover { background: var(--bg); text-decoration: none; }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 13px; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--panel); color: var(--text); font: inherit; font-weight: 500; cursor: pointer; white-space: nowrap; box-shadow: var(--shadow); }
.btn:hover { background: #f9fafb; text-decoration: none; }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn.primary:hover { background: var(--primary-dark); }
.btn.danger { color: var(--err); border-color: #fda29b; }
.btn.danger:hover { background: var(--err-soft); }
.btn.ghost { border-color: transparent; box-shadow: none; background: none; }
.btn.ghost:hover { background: var(--bg); }
.btn.small { padding: 3px 9px; font-size: .87rem; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.icon-btn { background: none; border: 0; padding: 5px; border-radius: 6px; cursor: pointer; color: var(--muted); display: inline-grid; place-items: center; }
.icon-btn:hover { background: var(--bg); color: var(--text); }
button.link { background: none; border: 0; padding: 0; color: var(--primary); font: inherit; cursor: pointer; }
form.inline { display: inline; }

/* Karten, Kennzahlen */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; margin-bottom: 18px; box-shadow: var(--shadow); }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.card > .table-wrap { margin: 0 -20px; border: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); border-radius: 0; box-shadow: none; }
.card > .table-wrap:last-child { margin-bottom: -18px; border-bottom: 0; border-radius: 0 0 var(--radius) var(--radius); }
.card > .table-wrap + * { margin-top: 12px; }
.card > .empty { border: 0; padding: 12px 0 4px; }
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 18px; align-items: start; }
.cols > .card { margin-bottom: 0; }
.cols { margin-bottom: 18px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 18px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; color: var(--text); box-shadow: var(--shadow); display: block; }
a.stat:hover { border-color: var(--primary); text-decoration: none; }
.stat-label { color: var(--muted); font-size: .87rem; }
.stat-value { font-size: 1.45rem; font-weight: 650; letter-spacing: -.01em; }
.stat-sub { color: var(--muted); font-size: .85rem; min-height: 1.2em; }
.dl { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px 24px; margin: 0; }
.dl dt { color: var(--muted); font-size: .85rem; }
.dl dd { margin: 0; }

/* Tabellen */
.table-wrap { overflow-x: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 18px; box-shadow: var(--shadow); }
table { border-collapse: collapse; width: 100%; }
th, td { padding: 9px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .8rem; font-weight: 600; color: var(--muted); background: #fafbfc; white-space: nowrap; text-transform: uppercase; letter-spacing: .03em; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fafbfc; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
td.actions, th.actions { text-align: right; white-space: nowrap; }
td.actions > * { margin-left: 4px; }
tfoot td { font-weight: 600; border-top: 1px solid var(--line-strong); border-bottom: 0; background: #fafbfc; }
tr.struck td { color: var(--muted); text-decoration: line-through; }
table.compact th, table.compact td { padding: 6px 10px; font-size: .9rem; }
.empty { border: 1px dashed var(--line-strong); border-radius: var(--radius); padding: 28px; text-align: center; color: var(--muted); margin-bottom: 18px; }

/* Tabs, Schritte */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tabs a { padding: 8px 12px; color: var(--muted); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs a:hover { color: var(--text); text-decoration: none; }
.tabs a.active { color: var(--primary); border-color: var(--primary); }
.steps { list-style: none; display: flex; gap: 6px; padding: 0; margin: 0 0 18px; flex-wrap: wrap; }
.steps a { display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); color: var(--muted); font-weight: 500; }
.steps a:hover { text-decoration: none; border-color: var(--line-strong); }
.steps b { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--bg); font-size: .8rem; }
.steps .current a { border-color: var(--primary); color: var(--primary); }
.steps .current b { background: var(--primary); color: #fff; }
.steps .done b { background: var(--ok-soft); color: var(--ok); }

/* Formulare */
.form .grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 18px; }
.form.one .grid { grid-template-columns: 1fr; }
.form.three .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.field { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.field.wide, .check.wide { grid-column: 1 / -1; }
.field > span { font-weight: 500; font-size: .9rem; }
.field > span i { font-style: normal; font-weight: 400; color: #98a2b3; font-size: .8rem; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=month], input[type=number], input[type=search], input[type=time], select, textarea {
  width: 100%; padding: 7px 10px; border: 1px solid var(--line-strong); border-radius: 8px; font: inherit; color: var(--text); background: #fff; min-height: 36px;
}
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid #b2c8ff; outline-offset: 0; border-color: var(--primary); }
.affix { display: flex; }
.affix input { border-radius: 8px 0 0 8px; text-align: right; }
.affix span { display: grid; place-items: center; padding: 0 10px; border: 1px solid var(--line-strong); border-left: 0; border-radius: 0 8px 8px 0; background: #f9fafb; color: var(--muted); }
.check { display: flex; gap: 8px; align-items: flex-start; padding-top: 4px; }
.check input { margin-top: 4px; }
.check small { display: block; }
.has-error input, .has-error select, .has-error textarea { border-color: var(--err); }
small.err { color: var(--err); }
.form-actions { display: flex; gap: 8px; margin-top: 18px; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: end; margin-bottom: 16px; }
.filters label { display: flex; flex-direction: column; gap: 3px; font-size: .85rem; color: var(--muted); }
.filters select, .filters input { min-width: 150px; }
.rows .row { display: flex; gap: 10px; align-items: end; margin-bottom: 8px; }
.rows .row > label, .rows .row > .field { flex: 1; }
.rows .row .narrow { flex: 0 0 110px; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin: 16px 0 0; }
legend { font-weight: 600; padding: 0 6px; font-size: .92rem; }
.checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 4px 16px; }

/* Hinweise, Badges */
.alert { padding: 10px 14px; border-radius: 8px; margin-bottom: 16px; border: 1px solid; }
.alert.ok { background: var(--ok-soft); border-color: #abefc6; color: var(--ok); }
.alert.error { background: var(--err-soft); border-color: #fecdca; color: var(--err); }
.alert.warn { background: var(--warn-soft); border-color: #fedf89; color: var(--warn); }
.alert.info { background: var(--primary-soft); border-color: #c7d7fe; color: #1e3a8a; }
.badge { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: .78rem; font-weight: 600; background: #f2f4f7; color: #344054; white-space: nowrap; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.err { background: var(--err-soft); color: var(--err); }
.badge.info { background: var(--primary-soft); color: var(--primary); }
progress.meter { width: 100%; height: 8px; appearance: none; border: 0; border-radius: 99px; overflow: hidden; background: #eef0f3; }
progress.meter::-webkit-progress-bar { background: #eef0f3; }
progress.meter::-webkit-progress-value { background: var(--primary); }
progress.meter::-moz-progress-bar { background: var(--primary); }
progress.meter.warn::-webkit-progress-value { background: #f79009; }
progress.meter.warn::-moz-progress-bar { background: #f79009; }
progress.meter.full::-webkit-progress-value { background: var(--err); }
progress.meter.full::-moz-progress-bar { background: var(--err); }

/* Dialog */
.dialog { border: 0; border-radius: 14px; padding: 0; width: min(680px, calc(100vw - 24px)); box-shadow: 0 24px 64px rgba(16, 24, 40, .25); color: var(--text); }
.dialog::backdrop { background: rgba(16, 24, 40, .45); }
.dialog-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px 0; }
.dialog > form, .dialog > div:not(.dialog-head) { padding: 14px 20px 20px; }

/* KI-Assistent */
.ai { position: fixed; right: 0; top: 0; bottom: 0; width: min(430px, 100vw); background: var(--panel); border-left: 1px solid var(--line); box-shadow: -12px 0 40px rgba(16, 24, 40, .12); display: flex; flex-direction: column; z-index: 30; }
.ai header { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.ai-head-actions { display: flex; gap: 10px; align-items: center; font-size: .87rem; }
.ai-log { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.ai-msg { padding: 9px 12px; border-radius: 12px; max-width: 92%; white-space: pre-wrap; overflow-wrap: anywhere; }
.ai-msg.user { align-self: flex-end; background: var(--primary); color: #fff; }
.ai-msg.assistant { align-self: flex-start; background: var(--bg); }
.ai-msg.note { align-self: center; color: var(--muted); font-size: .85rem; background: none; padding: 0; text-align: center; }
.ai-msg.tool { align-self: flex-start; font-size: .82rem; color: var(--muted); background: none; padding: 0 4px; }
.ai-confirm { border: 1px solid #fedf89; background: var(--warn-soft); border-radius: 12px; padding: 10px 12px; }
.ai-confirm pre { margin: 6px 0; font-size: .8rem; white-space: pre-wrap; overflow-wrap: anywhere; }
.ai-confirm .btn { margin-right: 6px; }
.ai-form { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); align-items: flex-end; }

/* Öffentliche Seiten */
.public { display: flex; flex-direction: column; min-height: 100vh; background: #fff; }
.pub-top { display: flex; justify-content: space-between; align-items: center; padding: 8px 28px; border-bottom: 1px solid var(--line); }
.pub-top .brand { padding: 8px 0; }
.pub-top nav, .pub-foot nav { display: flex; gap: 18px; align-items: center; }
.pub-top nav a:not(.btn) { color: var(--text); font-weight: 500; }
.pub-main { flex: 1; width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 24px 64px; }
.pub-bare { flex: 1; display: grid; place-items: start center; padding: 48px 16px; background: var(--bg); }
.pub-foot { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 20px 28px; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
.pub-foot a { color: var(--muted); }
.auth-card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 28px; width: min(440px, 100%); box-shadow: var(--shadow); }
.auth-card h1 { margin-bottom: 6px; }
.auth-card .form .grid { grid-template-columns: 1fr; }
.auth-card .form-actions .btn { width: 100%; justify-content: center; padding: 9px; }
.auth-links { margin-top: 16px; font-size: .92rem; color: var(--muted); }
.hero { text-align: center; padding: 72px 0 48px; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.1rem); letter-spacing: -.03em; line-height: 1.12; max-width: 780px; margin: 0 auto 16px; }
.hero p { font-size: 1.15rem; color: var(--muted); max-width: 640px; margin: 0 auto 26px; }
.hero .btn { padding: 11px 20px; font-size: 1.02rem; }
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; margin: 24px 0 56px; }
.features > div { border: 1px solid var(--line); border-radius: 12px; padding: 18px; }
.features h3 { margin: 0 0 4px; }
.features p { color: var(--muted); margin: 0; }
.pricing { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; margin: 20px 0; }
.price { border: 1px solid var(--line); border-radius: 14px; padding: 24px; display: flex; flex-direction: column; background: #fff; }
.price.featured { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.price h3 { margin: 0; font-size: 1.1rem; }
.price .amount { font-size: 1.9rem; font-weight: 700; letter-spacing: -.02em; margin: 8px 0 2px; }
.price ul { padding: 0; margin: 14px 0 20px; list-style: none; flex: 1; }
.price li { padding: 5px 0 5px 24px; position: relative; }
.price li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }
.section-title { text-align: center; font-size: 1.6rem; letter-spacing: -.02em; margin: 40px 0 6px; }
.section-sub { text-align: center; color: var(--muted); margin: 0 auto 8px; max-width: 640px; }
.legal { max-width: 760px; margin: 40px auto; }
.legal h1 { margin-bottom: 16px; }
.legal h2 { margin: 24px 0 6px; }

/* Abrechnungs-Vorschau */
.calc { font-size: .9rem; color: var(--muted); }
.totals td { font-weight: 600; }
pre.box { background: #f9fafb; border: 1px solid var(--line); border-radius: 8px; padding: 12px; overflow-x: auto; font-size: .85rem; }
.thread { display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }
.comment { border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; background: var(--panel); }
.comment header { display: flex; justify-content: space-between; color: var(--muted); font-size: .85rem; margin-bottom: 4px; }

@media (max-width: 900px) {
  .side { position: fixed; left: 0; top: 0; transform: translateX(-100%); transition: transform .2s; z-index: 40; box-shadow: 12px 0 40px rgba(16, 24, 40, .2); }
  .side.open { transform: none; }
  .nav-toggle { display: inline-grid; }
  .top { padding: 8px 14px; }
  .content { padding: 16px 14px 48px; }
  .form .grid, .form.three .grid { grid-template-columns: 1fr; }
  .ai-open span { display: none; }
  .rows .row { flex-wrap: wrap; }
}
@media print {
  .side, .top, .ai, .page-actions, .tabs { display: none !important; }
  .content { padding: 0; max-width: none; }
}

/* ── Dokumente, Tickets, Serienbriefe (features/documents.js, tickets.js, letters.js) ── */
input[type=file] { font: inherit; max-width: 100%; }
.upload-inline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.upload-first { margin-bottom: 14px; }
.hash { overflow-wrap: anywhere; }
.attachments { list-style: none; padding: 0; margin: 8px 0 0; display: flex; flex-direction: column; gap: 2px; font-size: .92rem; }
.attachments li::before { content: "📎 "; }
.ticket-cols { grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr); }
.template-cols { grid-template-columns: minmax(0, 2fr) minmax(240px, 1fr); }
.filters.assign { margin: 12px 0 0; }
.placeholders p { margin: 0 0 8px; line-height: 1.9; }
.placeholders code, small code { background: #f2f4f7; border-radius: 5px; padding: 1px 5px; font-size: .85em; white-space: nowrap; }
select[multiple] { min-height: 180px; }
@media (max-width: 900px) { .ticket-cols, .template-cols { grid-template-columns: 1fr; } }

/* ── Einstellungen und öffentliche Seiten (settings.js, public.js) ── */
.hero-note { font-size: .92rem !important; margin-top: 14px !important; }
.business-note { max-width: 860px; margin: 18px auto 0; padding: 12px 16px; border: 1px solid #fedf89; background: var(--warn-soft); border-radius: 10px; color: #7a2e0e; font-size: .92rem; }
.price small { color: var(--muted); }
.price .amount small { font-size: .9rem; font-weight: 500; }
img.qr { margin: 10px 0; border: 1px solid var(--line); border-radius: 8px; }
ol.setup { padding-left: 20px; margin: 0 0 14px; }
ol.setup li { margin-bottom: 8px; }
pre.codes { font-size: 1.05rem; letter-spacing: .06em; column-count: 2; max-width: 360px; }
.pager { display: flex; gap: 10px; align-items: center; color: var(--muted); font-size: .9rem; margin-bottom: 18px; }
details.audit summary { cursor: pointer; color: var(--primary); white-space: nowrap; }
details.audit pre { max-width: 420px; margin: 6px 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.danger-zone .btn.primary { background: var(--err); border-color: var(--err); }
td form.inline select { width: auto; min-width: 0; }
td.user-actions { text-align: right; }
td.user-actions form { display: inline-block; margin: 0 0 4px 4px; }
p.archive-row { margin: 14px 0 0; padding-top: 14px; border-top: 1px solid var(--line); }
p.archive-row form { display: inline-block; margin-right: 8px; }
/* ── Ende Einstellungen ── */

/* ── Versammlungen (meetings.js) ── */
.tally { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; padding: 10px 12px; margin: 10px 0 14px; border: 1px solid var(--line); border-radius: 8px; background: #fafbfc; }
.vote-options { white-space: nowrap; }
.vote-options label { margin-right: 14px; cursor: pointer; }
/* ── Ende Versammlungen ── */

/* ── KI-Assistent (Ergänzungen) ── */
.ai-msg code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em; background: rgba(16, 24, 40, .07); padding: 0 4px; border-radius: 4px; }
.ai-msg.note a { color: var(--primary); font-weight: 500; }
.ai-form textarea { resize: none; }
.ai-form.busy { opacity: .6; pointer-events: none; }
/* ── Ende KI-Assistent ── */

/* ── Tarif & Verbrauch (features/billing.js) ── */
.usage { display: flex; flex-direction: column; gap: 14px; }
.usage-head { display: flex; justify-content: space-between; gap: 12px; font-size: .9rem; margin-bottom: 4px; }
.usage-head span:last-child { color: var(--muted); font-variant-numeric: tabular-nums; }
.section-gap { margin: 26px 0 4px; }
.price .alert { margin: 0 0 14px; font-size: .9rem; }
/* ── Ende Tarif ── */

/* ── Bankimport (features/bankimport.js) ── */
table.bank-inbox td { vertical-align: top; }
.bank-line small, .bank-suggest small { overflow-wrap: anywhere; }
.bank-line { min-width: 220px; max-width: 460px; }
.bank-suggest { min-width: 200px; max-width: 320px; }
.bank-pending { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.bank-pending > span, .bank-pending > :first-child { margin-right: auto; }
.bank-foot { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 0 18px; align-items: start; margin-top: 8px; }
.bank-map { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin-bottom: 14px; }
.bank-preview .table-wrap { margin-bottom: 10px; box-shadow: none; }
.bank-raw-wrap { margin: 8px 0 0; box-shadow: none; }
details.bank-skipped { margin-top: 10px; }
details.bank-skipped summary { cursor: pointer; color: var(--primary); }
details.bank-skipped ul { margin: 8px 0 0; padding-left: 20px; }
table.bank-raw th { width: 1%; color: var(--muted); font-weight: 500; }
table.bank-raw td { white-space: nowrap; max-width: 220px; overflow: hidden; text-overflow: ellipsis; }
table.bank-raw tr.is-header td { font-weight: 600; background: var(--primary-soft); }
.stat-sub form.inline .btn { margin-top: 2px; }
/* ── Ende Bankimport ── */

/* Abrechnungen (statements.js) */
.choices { display: grid; gap: 10px; }
.choice { display: block; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); background: var(--panel); }
.choice:hover { border-color: var(--primary); text-decoration: none; background: var(--primary-soft); }
.choice strong { display: block; margin-bottom: 2px; }
.choice span { color: var(--muted); font-size: .92rem; }
table.inputs input { width: 8.5rem; text-align: right; padding: 5px 8px; }
table.inputs td { vertical-align: middle; }

/* Startseite (dashboard.js) */
.todo { list-style: none; margin: 0; padding: 0; }
.todo li + li { border-top: 1px solid var(--line); }
.todo a { display: flex; gap: 12px; align-items: flex-start; padding: 11px 4px; color: var(--text); }
.todo a:hover { text-decoration: none; background: var(--bg); }
.todo strong { display: block; font-weight: 600; }
.todo small { display: block; }
.dot { flex: none; width: 9px; height: 9px; border-radius: 50%; margin-top: 7px; background: var(--primary); }
.dot.err { background: var(--err); }
.dot.warn { background: #f79009; }
.onboarding { padding-left: 1.2rem; display: grid; gap: 10px; }
.onboarding span { display: block; color: var(--muted); }
a.stat { color: var(--text); }
a.stat:hover { text-decoration: none; border-color: var(--primary); }
.sums { width: 100%; border-collapse: collapse; }
.sums td { padding: 7px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.sums tr:last-child td { border-bottom: 0; }
.sums td.num { text-align: right; white-space: nowrap; padding-left: 16px; font-variant-numeric: tabular-nums; }
.sums .strong td { font-weight: 600; }
