/* Banka — uses tokens from base.css only. */

.bank .page-head p { overflow-wrap: anywhere; }

/* outcome sentence: the first thing read on the page */
.verdict { font-size: var(--f-26); line-height: 34px; font-weight: 450; letter-spacing: -0.01em; max-width: 34ch;
  margin: 0 0 var(--s-2); }
.verdict b { font-weight: 700; font-variant-numeric: tabular-nums; }
.verdict .late-n { color: var(--bad); }
.note { font-size: var(--f-13); margin-bottom: var(--s-6); }
@media (max-width: 767px) { .verdict { font-size: var(--f-21); line-height: 28px; } }

.block { border-top: 1px solid var(--rule); padding: var(--s-5) 0 var(--s-6); }
.block > h2, .block-head h2 { margin-bottom: var(--s-2); }
.block-head { display: flex; justify-content: space-between; align-items: center; gap: var(--s-3); flex-wrap: wrap;
  margin-bottom: var(--s-2); }
.block-head h2 { margin: 0; }
.all-clear { display: flex; align-items: center; gap: var(--s-2); color: var(--ok); font-weight: 550; margin: 0; }
.all-clear svg { width: 20px; height: 20px; }

/* ── statement slip: one bank movement ────────────────────────────────── */
.slip { background: var(--sheet); border: 1px solid var(--rule); border-left: 3px solid var(--ink-2);
  border-radius: 0 var(--r-ctl) var(--r-ctl) 0; padding: var(--s-3) var(--s-4); min-width: 0; }
.slip-top { display: flex; justify-content: space-between; align-items: baseline; gap: var(--s-3); }
.slip-date { color: var(--ink-2); font-size: var(--f-13); }
.slip-sum { font-size: var(--f-21); font-weight: 650; }
.slip-sum.out { color: var(--ink-2); }
.slip-meta { display: grid; gap: 2px; margin: var(--s-2) 0 0; font-size: var(--f-13); line-height: 20px; }
.slip-meta div { display: grid; grid-template-columns: 84px 1fr; gap: var(--s-2); }
.slip-meta dt { color: var(--ink-2); }
.slip-meta dd { margin: 0; overflow-wrap: anywhere; }

/* ── review queue: payment left, candidates right ─────────────────────── */
.decisions { list-style: none; margin: var(--s-4) 0 0; padding: 0; display: grid; gap: var(--s-4); counter-reset: d; }
.decision { display: grid; grid-template-columns: minmax(240px, 340px) 1fr; gap: var(--s-5); align-items: start;
  padding: var(--s-4); border-radius: var(--r-ctl); background: color-mix(in srgb, var(--warn-wash) 45%, transparent);
  border: 1px solid color-mix(in srgb, var(--warn) 22%, var(--rule)); }
.decision.done { background: transparent; border-color: var(--rule); }
.decision.done .slip { opacity: .7; }
.decide-why { display: flex; gap: var(--s-2); margin: 0 0 var(--s-3); color: var(--warn); font-size: var(--f-15); font-weight: 500; }
.decide-why svg { width: 18px; height: 18px; flex: none; margin-top: 3px; }
.decide-why span { color: var(--ink); }
.decision fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.cands { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-2); }
.cand { display: grid; grid-template-columns: 20px 1fr; gap: var(--s-3); padding: var(--s-3); cursor: pointer;
  background: var(--sheet); border: 1px solid var(--rule); border-radius: var(--r-ctl); }
.cand:hover { border-color: color-mix(in srgb, var(--stamp) 40%, var(--rule)); }
.cand:has(input:checked) { border-color: var(--stamp); box-shadow: inset 0 0 0 1px var(--stamp); }
.cand input { accent-color: var(--stamp); width: 18px; height: 18px; margin: 3px 0 0; }
.cand input:focus-visible { box-shadow: var(--focus); }
.cand-body { display: grid; gap: 2px; min-width: 0; }
.cand-head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2); }
.cand-why { color: var(--ink-2); font-size: var(--f-13); line-height: 20px; }
.decide-actions { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-top: var(--s-3); }
.decided { display: flex; align-items: center; gap: var(--s-2); margin: var(--s-3) 0 0; font-weight: 550; }
.decided svg { width: 18px; height: 18px; }
.decided.ok { color: var(--ok); } .decided.quiet { color: var(--ink-2); }
.decided button { margin-left: var(--s-2); font: inherit; font-weight: 500; color: var(--stamp); background: none;
  border: 0; padding: 0; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 900px) { .decision { grid-template-columns: 1fr; gap: var(--s-3); } }

/* ── invoices table ──────────────────────────────────────────────────── */
.chips { display: flex; flex-wrap: wrap; gap: var(--s-1); }
.chip { font: 500 var(--f-13)/1 "Onest", system-ui, sans-serif; color: var(--ink-2); background: transparent;
  border: 1px solid var(--rule); border-radius: 999px; padding: 7px 12px; cursor: pointer; }
.chip:hover { color: var(--ink); }
.chip[aria-pressed="true"] { color: var(--stamp); background: var(--stamp-wash); border-color: transparent; }
table.inv td.zero { color: var(--ink-2); }
table.inv td small { display: block; color: var(--ink-2); font-size: var(--f-13); }
table.inv .tags { display: flex; flex-wrap: wrap; gap: var(--s-1); }
table.inv td.why { color: var(--ink-2); font-size: var(--f-13); line-height: 20px; max-width: 46ch; }
table.inv tr[hidden] { display: none; }

@media (max-width: 767px) {
  table.inv thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  table.inv, table.inv tbody, table.inv tr, table.inv td { display: block; width: 100%; }
  table.inv tr { padding: var(--s-3) 0; border-bottom: 1px solid var(--rule); }
  table.inv tr[hidden] { display: none; }
  table.inv td { border: 0; padding: 2px 0; }
  table.inv td.num { display: flex; justify-content: space-between; text-align: left; }
  table.inv td.num::before { content: attr(data-l); color: var(--ink-2); font-size: var(--f-13); }
  table.inv td[data-l="Stav"] { padding: var(--s-2) 0; }
  table.inv td.why { max-width: none; }
  table.data tbody tr:hover { background: none; }
}

/* ── unmatched payments ──────────────────────────────────────────────── */
.slips { list-style: none; margin: var(--s-4) 0 0; padding: 0; display: grid; gap: var(--s-3);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.slip-why { margin: var(--s-2) 0 0; font-size: var(--f-13); line-height: 20px; color: var(--ink-2); }

/* ── upload ──────────────────────────────────────────────────────────── */
.upload { display: grid; gap: var(--s-4); }
.drop { position: relative; display: grid; justify-items: center; gap: var(--s-2); padding: var(--s-7) var(--s-4);
  text-align: center; border: 1.5px dashed color-mix(in srgb, var(--ink-2) 55%, var(--rule)); border-radius: var(--r-ctl);
  background: var(--sheet); cursor: pointer; color: var(--ink-2); }
.upload.compact .drop { padding: var(--s-5) var(--s-4); }
.drop svg { width: 32px; height: 32px; color: var(--stamp); }
.drop-text b { color: var(--ink); font-weight: 600; }
.drop-text u { color: var(--stamp); text-underline-offset: 3px; }
.drop:hover, .drop.over { border-color: var(--stamp); background: var(--stamp-wash); }
.drop:has(input:focus-visible) { box-shadow: var(--focus); border-color: var(--stamp); }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.drop-file:not(:empty) { display: inline-flex; align-items: center; gap: var(--s-2); color: var(--ink); font-weight: 600;
  padding: 4px 12px; border-radius: 999px; background: var(--ok-wash); }
.drop.has-file { border-style: solid; border-color: var(--ok); }

.dirs { border: 0; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-2); min-width: 0; }
.dirs legend { font-size: var(--f-13); font-weight: 500; color: var(--ink-2); margin-bottom: var(--s-2); padding: 0; }
.dir { display: grid; grid-template-columns: 20px 1fr; gap: var(--s-3); padding: var(--s-3) var(--s-4); cursor: pointer;
  background: var(--sheet); border: 1px solid var(--rule); border-radius: var(--r-ctl); }
.dir:has(input:checked) { border-color: var(--stamp); box-shadow: inset 0 0 0 1px var(--stamp); }
.dir input { accent-color: var(--stamp); width: 18px; height: 18px; margin: 3px 0 0; }
.dir b { display: block; font-weight: 600; }
.dir small { display: block; color: var(--ink-2); font-size: var(--f-13); line-height: 20px; }
@media (max-width: 600px) { .dirs { grid-template-columns: 1fr; } }
.upload-go { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-3); }
.upload-go .hint { margin: 0; }

/* empty state: upload is the hero, formats beside it */
.bank-empty { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: var(--s-6); align-items: start; }
.bank-empty > section { padding-top: var(--s-1); }
.bank-empty > section h2 { margin-bottom: var(--s-3); }
@media (max-width: 900px) { .bank-empty { grid-template-columns: 1fr; } }
.formats { margin: 0; display: grid; gap: var(--s-4); }
.formats dt { font-weight: 600; }
.formats dd { margin: 2px 0 0; color: var(--ink-2); font-size: var(--f-13); line-height: 20px; max-width: 52ch; }
.formats-more { margin-top: var(--s-4); }
.formats-more summary { cursor: pointer; color: var(--stamp); font-weight: 500; margin-bottom: var(--s-3); }

.bank [hidden] { display: none !important; }

/* ── decided payments, sample statement, paid note on the desk ───────── */
.decided { flex-wrap: wrap; margin: 0; }
.decided a { color: inherit; }
.decided small { color: var(--ink-2); font-weight: 400; }
.decision.done .decide-col { align-self: center; }
td small.partner { display: block; color: var(--ink); font-size: var(--f-13); line-height: 18px; }
.demo-try { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-3);
  margin-top: var(--s-5); padding-top: var(--s-4); border-top: 1px solid var(--rule); }
.demo-try p { margin: 0; color: var(--ink-2); font-size: var(--f-15); }
.demo-try p b { color: var(--ink); font-weight: 600; }
.notice { margin: 0 0 var(--s-5); padding: var(--s-3) var(--s-4); border-left: 3px solid var(--warn);
  background: var(--warn-wash); border-radius: 0 var(--r-ctl) var(--r-ctl) 0; }
.notice p { margin: 0; } .notice b { display: block; margin-bottom: 2px; }
.cand-partner { font-size: var(--f-13); line-height: 20px; color: var(--ink); }
.cand-dup { font-size: var(--f-13); line-height: 20px; color: var(--warn); font-weight: 550; }
