/* MyFin – paskolų portfelio valdymas
   Šviesus, dalykinis stilius. Akcentas – tamsiai mėlyna; raudona / oranžinė / žalia – tik būsenoms. */

:root {
  color-scheme: light;
  --page: #f2f4f7;
  --surface: #ffffff;
  --surface-2: #f7f9fb;
  --ink: #16202c;
  --ink-2: #44505e;
  --muted: #6f7b89;
  --line: #e0e5eb;
  --line-strong: #c9d1da;
  --accent: #1f4e79;
  --accent-ink: #163a5c;
  --accent-soft: #e5edf5;
  --accent-seg: #4a7fb5;      /* aktyvių paskolų atkarpos portfelio juostoje */
  --good: #0ca30c;
  --good-ink: #146c2e;
  --good-soft: #e7f5ea;
  --warning: #fab219;
  --serious: #ec835a;
  --serious-ink: #a4441b;
  --serious-soft: #fdf0ea;
  --critical: #d03b3b;
  --critical-ink: #a32121;
  --critical-soft: #fbeaea;
  --recovery: #7a1f1f;        /* laukia išieškojimo */
  --recovery-soft: #f3e3e3;
  --collect: #5b3a8c;         /* išieškoma */
  --collect-soft: #eee8f6;
  --radius: 8px;
  --radius-sm: 5px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --step--1: 0.8125rem;
  --step-0: 0.9375rem;
  --step-1: 1.0625rem;
  --step-2: 1.375rem;
  --step-3: 2rem;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font: var(--step-0)/1.5 var(--font);
  font-feature-settings: "tnum" 1;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 3px; }
h1, h2, h3 { line-height: 1.25; margin: 0; font-weight: 650; letter-spacing: -0.01em; }
h1 { font-size: var(--step-2); }
h2 { font-size: var(--step-1); }
h3 { font-size: var(--step-0); }
.num, td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.muted { color: var(--muted); }
.small { font-size: var(--step--1); }
.nowrap { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- viršutinė juosta ---------- */
.topbar {
  background: var(--accent-ink);
  color: #fff;
  position: sticky; top: 0; z-index: 20;
}
.topbar-in {
  max-width: none; width: 80%; margin: 0 auto; padding: 0;
  display: flex; align-items: center; gap: 24px; min-height: 56px;
}
.brand { color: #fff; font-weight: 700; font-size: var(--step-1); letter-spacing: -0.02em; display: flex; align-items: center; gap: 9px; }
.brand:hover { text-decoration: none; }
.brand svg { display: block; }
.nav { display: flex; gap: 2px; flex: 1; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav a {
  color: #c9d8e8; padding: 8px 12px; border-radius: var(--radius-sm); white-space: nowrap; font-size: var(--step--1);
  font-weight: 550;
}
.nav a:hover { background: rgba(255, 255, 255, 0.08); color: #fff; text-decoration: none; }
.nav a[aria-current="page"] { background: rgba(255, 255, 255, 0.14); color: #fff; }
.topbar .who { display: flex; align-items: center; gap: 10px; font-size: var(--step--1); color: #c9d8e8; }
.topbar .who form { margin: 0; }
.linkbtn { background: none; border: 0; color: inherit; font: inherit; cursor: pointer; padding: 6px 8px; border-radius: var(--radius-sm); }
.linkbtn:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }

main { width: 80%; margin: 0 auto; padding: 24px 0 64px; }
@media (max-width: 1100px) { main { width: auto; padding: 24px 20px 64px; } .topbar-in { width: auto; padding: 0 20px; } }

/* ---------- mygtukai ir formos ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 38px; padding: 0 16px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink);
  font: 600 var(--step--1)/1 var(--font); cursor: pointer; white-space: nowrap;
}
.btn:hover { border-color: var(--accent); text-decoration: none; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-ink); }
.btn-new { background: #fff; color: var(--accent-ink); border-color: #fff; }
.btn-danger { color: var(--critical-ink); }
.btn-danger:hover { border-color: var(--critical); }
.btn-sm { min-height: 30px; padding: 0 10px; }

label { display: block; font-size: var(--step--1); color: var(--ink-2); font-weight: 550; margin-bottom: 4px; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number], select, textarea {
  width: 100%; min-height: 40px; padding: 8px 10px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  background: #fff; color: var(--ink); font: var(--step-0) var(--font);
}
textarea { min-height: 80px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: var(--accent); }
.field { margin-bottom: 14px; }
.hint { font-size: var(--step--1); color: var(--muted); margin-top: 4px; }
.grid-form { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 0 16px; }
.check { display: flex; gap: 8px; align-items: flex-start; font-weight: 450; color: var(--ink); font-size: var(--step-0); }
.check input { margin-top: 4px; }
.inline-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.inline-form .field { margin: 0; min-width: 140px; flex: 1; }
.inline-form .field.grow { flex: 2; }
.inline-form .field.fixed { flex: 0 1 220px; }
.grid-form.pairs { grid-template-columns: repeat(2, minmax(140px, 240px)); }

/* ---------- pranešimai ---------- */
.flash { padding: 10px 14px; border-radius: var(--radius-sm); margin-bottom: 12px; border: 1px solid; font-size: var(--step--1); }
.flash.ok { background: var(--good-soft); border-color: #b9e0c3; color: var(--good-ink); }
.flash.klaida { background: var(--critical-soft); border-color: #efc2c2; color: var(--critical-ink); }
.flash.ispejimas { background: var(--serious-soft); border-color: #f3cdbb; color: var(--serious-ink); }
.errors { background: var(--critical-soft); border: 1px solid #efc2c2; color: var(--critical-ink); padding: 10px 14px 10px 32px; border-radius: var(--radius-sm); }

/* ---------- puslapio antraštė ---------- */
.pagehead { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; margin-bottom: 20px; }
.pagehead p { margin: 4px 0 0; color: var(--muted); }
.asof { display: flex; gap: 8px; align-items: center; margin: 0; }
.asof input { width: auto; min-height: 34px; padding: 4px 8px; }
.asof label { margin: 0; }

/* ---------- skydeliai ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.panel-pad { padding: 18px 20px; }
.panel-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.panel-head .small { color: var(--muted); }
.section { margin-top: 28px; }
.section > h2 { margin-bottom: 12px; }

/* ---------- rodiklių knyga (Visas portfelis / Nuosavos lėšos) ---------- */
.ledger {
  display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 0;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
}
.ledger-col { padding: 18px 22px 20px; }
.ledger-col + .ledger-col { border-left: 1px solid var(--line); background: var(--surface-2); }
.ledger-col h2 { font-size: var(--step--1); color: var(--ink-2); font-weight: 600; margin-bottom: 10px; }
.figure-main { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.big { font-size: var(--step-3); font-weight: 700; letter-spacing: -0.03em; line-height: 1.05; font-variant-numeric: tabular-nums; }
.big .cur { font-size: var(--step-1); font-weight: 600; color: var(--muted); margin-left: 3px; letter-spacing: 0; }
.figure-label { font-size: var(--step--1); color: var(--muted); margin-top: 4px; }
.figs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 18px; margin-top: 18px; padding-top: 14px; border-top: 1px dashed var(--line-strong); }
.fig .v { font-weight: 650; font-size: var(--step-1); font-variant-numeric: tabular-nums; }
.fig .l { font-size: var(--step--1); color: var(--muted); }
.spark { flex: none; }
.spark .area { fill: var(--accent-soft); }
.spark .line { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.spark .dot { fill: var(--accent); stroke: #fff; stroke-width: 2; }
.spark .hit { fill: transparent; }
.spark-wrap { position: relative; }
.spark-cap { font-size: 11px; color: var(--muted); text-align: right; }

/* ---------- portfelio juosta ---------- */
.strip-panel { margin-top: 16px; padding: 16px 22px 14px; }
.strip-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 10px; flex-wrap: wrap; }
.strip-head h2 { font-size: var(--step--1); color: var(--ink-2); font-weight: 600; }
.strip { display: block; width: 100%; height: 34px; border-radius: 4px; overflow: hidden; }
/* juostos spalvos = paskolos statuso ženkliuko fono spalvos (Manto sprendimas 2026-10-14) */
.strip rect { fill: var(--accent-seg); stroke: #3d6e9f; stroke-width: 1; }
.strip rect.s-veluoja { fill: #ffd43b; stroke: #f0bf1a; }
.strip rect.s-probleminė { fill: var(--critical-soft); stroke: #efc2c2; }
.strip rect.s-laukia_isieskojimo { fill: var(--recovery-soft); stroke: #e2c2c2; }
.strip rect.s-isieskoma { fill: var(--critical); stroke: #b83030; }
.strip a:hover rect, .strip a:focus rect { fill-opacity: 0.8; }
.strip a:focus { outline: none; }
.strip a:focus rect { stroke: var(--ink); stroke-width: 2; }
.strip-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; font-size: var(--step--1); color: var(--ink-2); }
.strip-legend .sw { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; background: var(--accent-seg); border: 1px solid #3d6e9f; }
.strip-legend .sw.veluoja { background: #ffd43b; border-color: #f0bf1a; }
.strip-legend .sw.probleminė { background: var(--critical-soft); border-color: #efc2c2; }
.strip-legend .sw.laukia_isieskojimo { background: var(--recovery-soft); border-color: #e2c2c2; }
.strip-legend .sw.isieskoma { background: var(--critical); border-color: #b83030; }
.conc { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-top: 6px; font-size: var(--step--1); color: var(--muted); }
.conc b { color: var(--ink); font-weight: 600; }

.tip {
  position: fixed; z-index: 50; pointer-events: none; background: var(--ink); color: #fff; padding: 7px 10px;
  border-radius: var(--radius-sm); font-size: var(--step--1); line-height: 1.4; max-width: 260px;
  box-shadow: 0 4px 14px rgba(22, 32, 44, 0.25); opacity: 0; transition: opacity 0.08s;
}
.tip.on { opacity: 1; }
.tip b { font-weight: 650; }

/* ---------- reikia dėmesio ---------- */
.attention { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.att { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); display: flex; flex-direction: column; }
.att.hot { border-top: 3px solid var(--serious); }
.att-head { display: flex; justify-content: space-between; align-items: baseline; padding: 14px 18px 10px; gap: 8px; }
.att-head h2 { font-size: var(--step-0); }
.att-head.att-sub { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 14px; }
.att-head .sum { font-weight: 650; font-variant-numeric: tabular-nums; }
.att ul { list-style: none; margin: 0; padding: 0 0 6px; }
.att li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 18px; border-top: 1px solid var(--line); font-size: var(--step--1); }
.att li a { color: var(--ink); font-weight: 550; }
.att li .meta { color: var(--muted); font-size: 12px; }
.att .empty { padding: 4px 18px 16px; color: var(--muted); font-size: var(--step--1); }
.att li .r { text-align: right; white-space: nowrap; }

/* ---------- būsenos ženkleliai ---------- */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px 2px 7px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; border: 1px solid transparent; }
.badge svg { flex: none; }
.badge.aktyvi { background: var(--accent-soft); color: var(--accent-ink); }
.badge.veluoja { background: #ffd43b; color: #6b4300; border-color: #f0bf1a; }
.badge.probleminė { background: var(--critical-soft); color: var(--critical-ink); border-color: #efc2c2; }
.badge.laukia_isieskojimo { background: var(--recovery-soft); color: var(--recovery); border-color: #e2c2c2; }
.badge.isieskoma { background: var(--critical); color: #000; border-color: #b83030; }
.badge.grazinta { background: var(--good-soft); color: var(--good-ink); }
.badge.neisduota { background: #eef1f4; color: var(--ink-2); }
.badge.neivyko { background: #eef1f4; color: var(--muted); text-decoration: line-through; }
.awaiting { border-left: 3px solid var(--accent-seg); }
.badge.sutampa { background: var(--good-soft); color: var(--good-ink); }
.badge.skola { background: var(--serious-soft); color: var(--serious-ink); }
.badge.nesutampa { background: var(--critical-soft); color: var(--critical-ink); }
.chip { display: inline-block; font-size: 11px; font-weight: 650; padding: 1px 6px; border-radius: 4px; background: #eef1f4; color: var(--ink-2); letter-spacing: 0.02em; }

/* ---------- lentelės ---------- */
.tablebar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 12px 20px; border-bottom: 1px solid var(--line); }
.tablebar input[type=search] { width: 240px; min-height: 36px; padding: 6px 10px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); font: var(--step--1) var(--font); }
.seg { display: inline-flex; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); overflow: hidden; }
.seg button { border: 0; background: #fff; padding: 7px 12px; font: 600 12px var(--font); color: var(--ink-2); cursor: pointer; }
.seg button + button { border-left: 1px solid var(--line-strong); }
.seg a { padding: 7px 14px; font: 600 12px var(--font); color: var(--ink-2); background: #fff; text-decoration: none; }
.seg a + a { border-left: 1px solid var(--line-strong); }
.seg a[aria-current="page"] { background: var(--accent); color: #fff; }
.seg button[aria-pressed="true"] { background: var(--accent); color: #fff; }
.tablebar select { width: auto; min-height: 34px; padding: 4px 8px; font-size: var(--step--1); }
.tablewrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 9px 12px; text-align: left; vertical-align: top; }
th { font-size: 12px; font-weight: 600; color: var(--muted); border-bottom: 1px solid var(--line-strong); white-space: nowrap; background: var(--surface); }
td { border-bottom: 1px solid var(--line); font-size: var(--step--1); }
tbody tr:hover td { background: #fafbfc; }
tr.dim td { color: var(--muted); }
tr.is-past td { background: #fcfcfd; }
tr.row-now td { box-shadow: inset 0 2px 0 var(--accent); }
td .sub { display: block; color: var(--muted); font-size: 12px; }
th:first-child, td:first-child { padding-left: 20px; }
th:last-child, td:last-child { padding-right: 20px; }
.share { display: inline-block; vertical-align: middle; margin-right: 6px; }
.share .bg { fill: #eef1f4; }
.share .fg { fill: var(--accent-seg); }
.term { min-width: 130px; }
.term-top { display: block; white-space: nowrap; }
.timeline { display: block; margin: 5px 0 3px; max-width: 100%; }
.timeline .bg { fill: #eef1f4; }
.timeline .fg { fill: var(--accent-seg); }
.timeline.done .fg { fill: #9aa5b1; }
.timeline.expired .fg { fill: var(--critical); }
.rowstat { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; white-space: nowrap; }
.rowstat::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--line-strong); }
.rowstat.apmoketa::before { background: var(--good); }
.rowstat.is_dalies::before { background: var(--warning); }
.rowstat.nesumoketa::before { background: var(--critical); }
.rowstat.isdestyta::before { background: var(--accent); border-radius: 2px; }
.rowstat.nereikia::before { background: transparent; border: 1px solid var(--line-strong); }
.rowstat.atideta::before { background: transparent; border: 1px dashed var(--accent); }
tfoot td { font-weight: 650; border-top: 1px solid var(--line-strong); border-bottom: 0; }

/* ---------- paskolos kortelė ---------- */
.loanhead { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: flex-start; margin-bottom: 18px; }
.titlerow { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 6px; }
.titlerow h1 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0; }
.loanhead h1 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.facts { display: flex; flex-wrap: wrap; gap: 4px 20px; margin-top: 6px; color: var(--ink-2); font-size: var(--step--1); }
.facts span { white-space: nowrap; }
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.kpi { padding: 16px 20px; }
.kpi + .kpi { border-left: 1px solid var(--line); }
.kpis.five { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.kpis.six { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.kpi .l { font-size: var(--step--1); color: var(--muted); }
.kpi .v { font-size: var(--step-2); font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.kpi .s { font-size: 12px; color: var(--muted); margin-top: 2px; }
.kpi.alert .v { color: var(--critical-ink); }
.progress { display: block; width: 100%; height: 8px; margin-top: 10px; border-radius: 4px; overflow: hidden; }
.progress .bg { fill: #eef1f4; }
.progress .paid { fill: var(--accent-seg); }
.progress .due { fill: var(--serious); }
.two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
.breakdown { display: grid; grid-template-columns: auto auto; gap: 6px 18px; font-size: var(--step--1); }
.breakdown dt { color: var(--muted); }
.breakdown dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
details.more { border-top: 1px solid var(--line); }
details.more > summary { cursor: pointer; padding: 12px 20px; font-weight: 600; font-size: var(--step--1); color: var(--accent); list-style: none; }
details.more > summary::-webkit-details-marker { display: none; }
details.more > summary::before { content: "+ "; }
details.more[open] > summary::before { content: "− "; }
details.more .inner { padding: 0 20px 16px; }
.notes { white-space: pre-line; font-size: var(--step--1); color: var(--ink-2); }
.danger-zone { border-color: #efc2c2; }

/* ---------- prisijungimas ---------- */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: var(--accent-ink); }
.auth-card { width: 100%; max-width: 400px; background: var(--surface); border-radius: 12px; padding: 28px 28px 24px; }
.auth-card .brand { color: var(--accent-ink); margin-bottom: 18px; }
.auth-card h1 { margin-bottom: 6px; }
.auth-card p { color: var(--ink-2); margin: 0 0 16px; font-size: var(--step--1); }
.qr { display: flex; justify-content: center; margin: 8px 0 12px; }
.qr svg { width: 200px; height: 200px; }
.secret { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; background: var(--surface-2); padding: 8px; border-radius: var(--radius-sm); word-break: break-all; text-align: center; }
.code-input { font-size: 1.5rem !important; letter-spacing: 0.3em; text-align: center; font-variant-numeric: tabular-nums; }

/* ---------- mobilusis ---------- */
@media (max-width: 960px) {
  .attention { grid-template-columns: 1fr; }
  .ledger { grid-template-columns: 1fr; }
  .ledger-col + .ledger-col { border-left: 0; border-top: 1px solid var(--line); }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpis.five { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpis.six { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpi:nth-child(3), .kpi:nth-child(5) { border-left: 0; }
  .kpis.five .kpi:nth-child(5) { grid-column: 1 / -1; }
  .kpi:nth-child(n+3) { border-top: 1px solid var(--line); }
  .two { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  main { padding: 16px 16px 48px; }
  .topbar-in { padding: 0 16px; gap: 12px; flex-wrap: wrap; }
  .nav { order: 3; flex-basis: 100%; padding-bottom: 8px; }
  .topbar .who .email { display: none; }
  .big { font-size: 1.75rem; }
  .figs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .spark { width: 140px; height: 48px; }
  .tablebar input[type=search] { width: 100%; }
  /* lentelės virsta kortelėmis */
  table.cards thead { display: none; }
  table.cards, table.cards tbody, table.cards tr, table.cards td { display: block; width: 100%; }
  table.cards tr { padding: 10px 16px; border-bottom: 1px solid var(--line); }
  table.cards td { border: 0; padding: 3px 0 !important; display: flex; justify-content: space-between; gap: 12px; text-align: right; }
  table.cards td::before { content: attr(data-label); color: var(--muted); font-size: 12px; text-align: left; flex: none; }
  table.cards td.title { display: block; text-align: left; font-size: var(--step-0); padding-bottom: 6px !important; }
  table.cards td.title::before { content: none; }
  table.cards td.term .timeline { margin-left: auto; }
  table.cards tfoot { display: block; }
  table.cards td.hide-m { display: none; }
  table.cards tr.later { display: none; }
  .kpi .v { font-size: var(--step-1); }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media print {
  .topbar, .tablebar, .no-print, form { display: none !important; }
  body { background: #fff; }
  .panel, .ledger, .kpis { border-color: #bbb; }
}
.w-full { width: 100%; }
.mt { margin-top: 16px; }
.narrow { max-width: 620px; }
.mt-s { margin-top: 6px; }
table td:not(.title):not(.small):not(.wrap) { white-space: nowrap; }
@media (max-width: 720px) {
  .att li { padding: 8px 16px; }
  .figure-main { flex-wrap: wrap; }
}
tr.later { display: none; }
.toggle-all:checked ~ .tablewrap tr.later { display: table-row; }
.toggle-label { display: inline-block; margin: 10px 20px 0; color: var(--accent); font-weight: 600; font-size: var(--step--1); cursor: pointer; }
.toggle-all:checked + .toggle-label { display: none; }
.toggle-all:focus-visible + .toggle-label { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (max-width: 720px) { .toggle-all:checked ~ .tablewrap table.cards tr.later { display: block; } }
.review-note { width: 150px !important; min-height: 32px !important; padding: 4px 8px !important; font-size: var(--step--1) !important; margin-top: 4px; }
.notes-cell { min-width: 260px; max-width: 360px; }
@media (max-width: 720px) { .review-note { width: 100% !important; } .notes-cell { min-width: 0; max-width: none; text-align: left !important; display: block !important; } }
.debt { color: var(--critical-ink); }
.navlink { color: #c9d8e8; } .navlink:hover { color: #fff; }
.mx { margin: 12px 20px 0; }
.rowedit summary { cursor: pointer; color: var(--accent); }
.rowedit-form { display: grid; gap: 6px; min-width: 220px; padding: 8px 0; white-space: normal; }
.rowedit-form label { margin: 0; font-weight: 500; }
.rowedit-form input { min-height: 32px; padding: 4px 8px; }
.viol { padding: 14px 20px; border-bottom: 1px solid var(--line); }
.viol-head { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.viol .breakdown { max-width: 520px; }
.attention.four, .attention.five { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 1200px) { .attention.four { grid-template-columns: repeat(4, minmax(0, 1fr)); } .attention.five { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (max-width: 960px) { .attention.four, .attention.five { grid-template-columns: 1fr; } }
.docpanel { border-left: 3px solid var(--accent); }
.amend { padding: 14px 20px; border-top: 1px solid var(--line); }
.amend-new { background: var(--surface-2); }
.busy-note { margin-top: 10px; font-size: var(--step--1); color: var(--accent-ink); font-weight: 600; }

/* datos laukas: metai/mėnuo/diena + kalendoriaus mygtukas */
.datewrap { position: relative; display: flex; align-items: stretch; gap: 0; width: 100%; }
.datewrap input[data-date] { flex: 1; min-width: 0; border-top-right-radius: 0; border-bottom-right-radius: 0; }
.datebtn { flex: none; display: inline-flex; align-items: center; justify-content: center; padding: 0 10px; border: 1px solid var(--line-strong); border-left: 0; background: var(--surface-2); color: var(--ink-2); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; cursor: pointer; }
.datebtn:hover { background: var(--accent-soft); color: var(--accent-ink); }
.date-native { position: absolute; right: 0; bottom: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; border: 0; padding: 0; }

/* praėjęs mėnuo – „Nuosavos lėšos“ stulpelio apačioje */
.month-box { margin-top: 18px; padding: 14px 16px 6px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--accent-seg); }
.month-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.month-head h3 { display: flex; align-items: center; gap: 8px; font-size: var(--step--1); font-weight: 600; color: var(--ink-2); margin: 0; }
.month-tag { font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-ink); }
.month-pct { font-size: var(--step-1); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--accent-ink); }
.month-bar { display: block; width: 100%; height: 4px; margin: 10px 0 0; }
.month-bar .bg { fill: #eef1f4; }
.month-bar .fg { fill: var(--accent-seg); }
.month-bar.full .fg { fill: var(--good); }
.month-bar.low .fg { fill: var(--serious); }
.month-box .figs { margin-top: 12px; padding-top: 10px; }
.sub-inline { font-size: 11px; color: var(--muted); font-weight: 400; }
.ledger-col:nth-child(2) .figs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fig .v { white-space: nowrap; }

/* ---------- išieškojimo eiga ---------- */
.rtrack { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.rtrack li { display: flex; flex-direction: column; gap: 6px; font-size: 12px; color: var(--muted); }
.rtrack .bar { height: 10px; border-radius: 5px; background: var(--line); }
.rtrack li.done .bar { background: var(--collect); }
.rtrack li.next .bar { background: repeating-linear-gradient(45deg, var(--collect-soft), var(--collect-soft) 6px, #ddd2ee 6px, #ddd2ee 12px); }
.rtrack li.done .nm { color: var(--ink); font-weight: 600; }
.rtrack .dt { font-variant-numeric: tabular-nums; }
@media (max-width: 760px) { .rtrack { grid-template-columns: 1fr; } .rtrack li { flex-direction: row; align-items: center; } .rtrack .bar { width: 40px; flex: none; } }

th.ctr, td.ctr { text-align: center; font-variant-numeric: tabular-nums; }
a.badge-link { text-decoration: none; cursor: pointer; }
a.badge-link:hover { filter: brightness(0.95); text-decoration: underline; }

.rtable th, .rtable td { text-align: center; }
.minitrack { display: inline-flex; gap: 2px; vertical-align: middle; }
.minitrack i { width: 12px; height: 8px; border-radius: 2px; background: var(--line); }
.minitrack i.on { background: var(--collect); }
.stages .stage { border-top: 1px solid var(--line); }
.stages .stage summary { display: grid; grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr) minmax(0, 2fr) auto; gap: 12px; align-items: center; padding: 12px 18px; cursor: pointer; list-style: none; }
.stages .stage summary::-webkit-details-marker { display: none; }
.stages .stage .st-act { color: var(--accent); }
.stages .stage[open] .st-act { color: var(--muted); }
.stages .stage-body { padding: 4px 18px 16px; background: var(--surface-2); border-top: 1px dashed var(--line); }
.doc-line { display: flex; gap: 8px; align-items: center; padding: 2px 0; }
form.inline { display: inline; }
@media (max-width: 760px) { .stages .stage summary { grid-template-columns: 1fr auto; } .stages .st-note { grid-column: 1 / -1; } }
.doc-line .linkbtn { color: var(--critical-ink); padding: 0 4px; }
.doc-line .linkbtn:hover { background: var(--critical-soft); color: var(--critical-ink); }

.badge.isieskota { background: var(--good-soft); color: var(--good-ink); border-color: #b9e0c3; }
.badge.uzdaryta { background: #eef0f3; color: var(--ink-2); border-color: var(--line-strong); }

.att li .r .what { display: block; white-space: normal; }

/* užtikrinimas: išskleidžiamas medis (hipoteka → NT / Kita → objektai) */
table.tree { width: 100%; border-collapse: collapse; font-size: var(--step--1); }
table.tree th { text-align: left; font-weight: 600; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.tree > tbody > tr > td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.tree th.num, table.tree td.num, table.subtable .num { text-align: right; font-variant-numeric: tabular-nums; }
tr.toggle { cursor: pointer; }
tr.toggle:hover > td { background: var(--surface-2); }
tr.toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.caret { display: inline-block; width: 0; height: 0; margin-right: 8px; border-left: 5px solid var(--muted); border-top: 4px solid transparent; border-bottom: 4px solid transparent; transition: transform .15s; vertical-align: 1px; }
tr[aria-expanded="true"] > td .caret { transform: rotate(90deg); border-left-color: var(--accent); }
tr[aria-expanded="true"] > td { background: #f4f7fb; }
table.tree tr.lvl1 > td { padding-left: 36px; background: #fafbfc; }
table.tree tr.lvl2 > td { padding: 4px 12px 12px 56px; background: #fafbfc; }
table.subtable { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); }
table.subtable th { text-align: left; font-weight: 600; color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.subtable td { padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.subtable.mini { border: 0; }
table.subtable.mini td { padding: 4px 8px 4px 0; }
tr.detail > td, tr.editrow > td { background: var(--surface-2); padding: 14px 16px 16px !important; }
tr.detail h3, tr.editrow h3 { font-size: var(--step-0); margin: 0 0 8px; }
td.act { width: 1%; text-align: right; white-space: nowrap; }
.iconbtn { border: 1px solid transparent; background: transparent; color: var(--ink-2); border-radius: var(--radius-sm); padding: 4px 6px; cursor: pointer; line-height: 0; }
.iconbtn:hover, .iconbtn[aria-expanded="true"] { border-color: var(--line-strong); background: #fff; color: var(--accent); }
.two-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }
.two-cols .breakdown { max-width: 520px; }
details.danger > summary { cursor: pointer; color: var(--critical-ink); font-size: var(--step--1); font-weight: 600; }
details.danger > form { margin-top: 8px; }
@media (max-width: 760px) { .two-cols { grid-template-columns: 1fr; } table.tree tr.lvl2 > td { padding-left: 12px; } }
#uztikrinimas .panel-head, #laidavimas .panel-head { flex-wrap: wrap; gap: 8px; }
table.tree th:first-child, table.tree > tbody > tr.lvl0 > td:first-child, table.tree > tbody > tr > td.title { padding-left: 20px; }
table.regcmp tr.conflict > td { background: var(--critical-soft); }
table.regcmp input, table.regcmp select { min-width: 180px; }
.chip-on { background: var(--accent); color: #fff; }
a.chip { text-decoration: none; }
.editsec + .editsec { border-top: 1px solid var(--line); margin-top: 20px; padding-top: 18px; }
.editsec h3 { margin: 0 0 12px; }
.editsec form > .btn, .editsec form > button { margin-top: 6px; }
.sechead { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.editrow .sechead h3 { margin: 0; }
.fig.rowstart { grid-column: 1; }
/* LTV paskolos kortelėje: < 50 % žalia, 50–60 % geltona, ≥ 60 % raudona (statusų ženkliukų spalvos) */
.kpi .v .ltv { display: inline-block; padding: 0 10px; border-radius: 999px; border: 1px solid transparent; }
.ltv.ok { background: var(--good-soft); color: var(--good-ink); border-color: #b9e0c3; }
.ltv.mid { background: #ffd43b; color: #6b4300; border-color: #f0bf1a; }
.ltv.high { background: var(--critical-soft); color: var(--critical-ink); border-color: #efc2c2; }
.fig .v .v-sub { font-weight: 500; color: var(--muted); }
/* „Artėjantys terminai“ – „Vėluoja“ būsenos spalvos; „Suėję terminai“ – „Probleminė“ būsenos spalvos */
.att.warn { border-top: 3px solid #ffd43b; }
.att.warn > .att-head:first-child h2 { color: #6b4300; }
.att-head.att-sub.crit { border-top: 3px solid var(--critical); }
.att-head.att-sub.crit h2 { color: var(--critical-ink); }
.bailiff-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; max-width: 760px; }
.bailiff-cols p { margin: 2px 0; }
.bailiff-form h3 { font-size: var(--step-0); margin: 0 0 8px; }
@media (max-width: 760px) { .bailiff-cols { grid-template-columns: 1fr; } }
tr.defer-row td { color: #6b4300; }
tr.defer-row { background: #fffbea; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.collapse-head { cursor: pointer; align-items: center; }
.collapse-head:hover { background: var(--surface-2); }
.collapse-head[aria-expanded="true"] .caret { transform: rotate(90deg); border-left-color: var(--accent); }
.collapse-head h2 { display: flex; align-items: center; }
.offer-form h3 { font-size: var(--step-0); margin: 0 0 8px; }
.offer-form { border-top: 1px solid var(--line); }
.row-acts { display: inline-flex; gap: 6px; align-items: center; justify-content: flex-end; }

/* Sutartys (2026-10-15) */
.contract-form h3 { font-size: .95rem; border-bottom: 1px solid var(--border, #e3e6ea); padding-bottom: .3rem; }
.contract-form textarea { width: 100%; font: inherit; }
.contract-form .field input[type="text"]#k-purpose { width: 100%; }
.pay-rows { width: 100%; border-collapse: collapse; }
.pay-rows th { text-align: left; font-weight: 500; font-size: .8rem; color: var(--muted, #667); padding: .2rem .3rem; }
.pay-rows td { padding: .2rem .3rem; }
.pay-rows input { width: 100%; }
.inline-upload { display: inline-flex; gap: .3rem; align-items: center; }
.inline-upload input[type="file"] { max-width: 210px; font-size: .8rem; }
.markers td { white-space: normal; }
.markers td:first-child { white-space: nowrap; }
/* NT vertinimų pastabos – po vertinimo eilute (2026-10-15) */
table.subtable.mini tr.has-note td { border-bottom: 0; padding-bottom: 0; }
table.subtable.mini tr.vnote td { padding-top: 2px; white-space: normal; }
.detail .breakdown dd, .detail p { overflow-wrap: anywhere; }
.vals-narrow { max-width: 640px; }
/* Išieškojimo pastabos – laiko juosta (2026-10-19) */
.notes-block { border-top: 1px solid var(--line); }
.note-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.note-form .field.fixed { flex: 0 0 160px; }
.note-form .field.grow { flex: 1 1 320px; }
.note-form textarea { width: 100%; font: inherit; resize: vertical; }
.timeline { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--line); }
.timeline li { display: flex; gap: 14px; padding: 8px 0 12px 14px; position: relative; }
.timeline li::before { content: ""; position: absolute; left: -6px; top: 13px; width: 10px; height: 10px; border-radius: 50%; background: var(--surface); border: 2px solid #4a7fb5; }
.timeline .tl-date { flex: 0 0 90px; font-weight: 600; font-variant-numeric: tabular-nums; }
.timeline .tl-body { flex: 1; min-width: 0; }
.timeline .tl-text { white-space: pre-line; overflow-wrap: anywhere; }
.timeline .tl-acts { display: flex; gap: 10px; align-items: center; margin-top: 2px; }
.timeline .tl-acts form { display: inline; }
.note-form[hidden] { display: none; }
/* pastabos: data, pastaba ir mygtukas vienoje eilutėje, vienodo aukščio (2026-10-19) */
.note-form .field { margin: 0; }
.note-form textarea { min-height: 40px; height: 40px; resize: none; overflow: hidden; line-height: 1.45; padding-top: 8px; padding-bottom: 8px; }
.note-form .btn { min-height: 40px; }
/* teksto laukas – blokinis (be eilutės apačios tarpo), visi trys elementai vienodo 40 px aukščio */
.note-form textarea { display: block; margin: 0; box-sizing: border-box; }
.note-form .datewrap input[data-date] { height: 40px; box-sizing: border-box; }
.note-form .btn { height: 40px; box-sizing: border-box; }

/* ===== Pranešimai (2026-10-19) ===== */
:root {
  --n-priminimas: #4a7fb5; --n-priminimas-soft: #e8f0f8;
  --n-veluoja: #d99a00;    --n-veluoja-soft: #fff4d1;
  --n-palukanos: #e0662f;  --n-palukanos-soft: #fdebe2;
  --n-draudimas: #168a7a;  --n-draudimas-soft: #e0f3f0;
  --n-vki: #6a4a9c;        --n-vki-soft: #efe9f7;
  --n-ispejimas: #c62f2f;  --n-ispejimas-soft: #fbe7e7;
}
.navbadge { display: inline-block; min-width: 18px; margin-left: 6px; padding: 0 5px; border-radius: 9px; background: #4a7fb5; color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.navbadge.fail { background: var(--critical); }
.nchip { display: inline-block; font-size: 11.5px; font-weight: 650; padding: 2px 8px; border-radius: 999px; white-space: nowrap; border: 1px solid transparent; }
.n-priminimas .nchip, .nchip.n-priminimas { background: var(--n-priminimas-soft); color: #23527f; border-color: #c9dbee; }
.nchip.n-veluoja { background: var(--n-veluoja-soft); color: #6b4300; border-color: #f3dc8e; }
.nchip.n-palukanos { background: var(--n-palukanos-soft); color: #9a3a12; border-color: #f6cdb9; }
.nchip.n-draudimas { background: var(--n-draudimas-soft); color: #0e5f54; border-color: #b8e2db; }
.nchip.n-vki { background: var(--n-vki-soft); color: #4b2f78; border-color: #d8cdea; }
.nchip.n-ispejimas { background: var(--n-ispejimas-soft); color: #a32121; border-color: #efc2c2; }

.nbanner { padding: 12px 16px; border-radius: var(--radius); border: 1px solid #efc2c2; background: var(--critical-soft); color: var(--critical-ink); }
.nsenders { display: flex; flex-wrap: wrap; gap: 8px; }
.nsender { font-size: 12.5px; padding: 5px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); }
.nsender::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 7px; vertical-align: 0; background: #b8c1cc; }
.nsender.on::before { background: var(--good); }
.nsender.on { border-color: #bfe3c6; }

.nkpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.nkpi { display: block; padding: 14px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); border-top: 4px solid var(--line-strong); color: var(--ink); text-decoration: none; }
.nkpi:hover { box-shadow: 0 2px 8px rgba(22, 32, 44, .06); }
.nkpi .l { display: block; font-size: var(--step--1); color: var(--muted); }
.nkpi .v { display: block; font-size: var(--step-3); font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.nkpi.k-wait { border-top-color: #4a7fb5; }
.nkpi.k-plan { border-top-color: var(--n-draudimas); }
.nkpi.k-sent { border-top-color: var(--good); }
.nkpi.k-fail { border-top-color: var(--line-strong); }
.nkpi.k-fail.alert { border-top-color: var(--critical); background: var(--critical-soft); }
.nkpi.k-fail.alert .v { color: var(--critical-ink); }
.nnav a { padding: 6px 14px; }

.nlist { display: grid; gap: 12px; padding: 14px 16px 16px; }
.nitem { border: 1px solid var(--line); border-left: 4px solid var(--line-strong); border-radius: var(--radius); background: var(--surface); padding: 12px 14px; }
.nitem.n-priminimas { border-left-color: var(--n-priminimas); }
.nitem.n-veluoja { border-left-color: var(--n-veluoja); }
.nitem.n-palukanos { border-left-color: var(--n-palukanos); }
.nitem.n-draudimas { border-left-color: var(--n-draudimas); }
.nitem.n-vki { border-left-color: var(--n-vki); }
.nitem.n-ispejimas { border-left-color: var(--n-ispejimas); }
.nhead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.nwho { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; min-width: 0; }
.nacts { display: flex; align-items: center; gap: 8px; }
.nacts form { display: inline; }
.nwarn { margin: 8px 0 0; font-size: 12.5px; color: var(--critical-ink); }
.nmail { margin-top: 10px; padding: 10px 12px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.nmail.flat { margin-top: 0; }
.nsubj { font-weight: 650; margin-bottom: 6px; overflow-wrap: anywhere; }
.nbody { white-space: pre-line; font-size: var(--step--1); color: var(--ink-2); line-height: 1.5; overflow-wrap: anywhere; }
.nedit { margin-top: 12px; }
.nedit[hidden] { display: none; }
.nedit textarea, .ntpl textarea { width: 100%; font: inherit; resize: none; overflow: hidden; line-height: 1.5; }
.nempty { color: var(--muted); font-size: var(--step--1); }
.nempty.ok::before { content: "✓ "; color: var(--good); font-weight: 700; }
.nfail-panel { border-color: #efc2c2; }
.nfail-panel .panel-head { background: var(--critical-soft); }
.ntable td.wrap { white-space: normal; overflow-wrap: anywhere; }
.nstat { font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; background: #eef1f4; color: var(--ink-2); }
.nstat.s-issiusta { background: var(--good-soft); color: var(--good-ink); }
.nstat.s-atmesta { background: #eef1f4; color: var(--muted); }
.nstat.s-nebeaktualu { background: #eef1f4; color: var(--muted); font-style: italic; }
.nfilter { border-bottom: 1px solid var(--line); }
.modeseg { display: inline-flex; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); overflow: hidden; }
.modeseg label { margin: 0; cursor: pointer; }
.modeseg input { position: absolute; opacity: 0; pointer-events: none; }
.modeseg span { display: inline-block; padding: 7px 12px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); background: var(--surface); border-left: 1px solid var(--line); }
.modeseg label:first-child span { border-left: 0; }
.modeseg .m-auto input:checked + span { background: var(--good-soft); color: var(--good-ink); }
.modeseg .m-patvirtinti input:checked + span { background: var(--accent-soft); color: var(--accent-ink); }
.modeseg .m-isjungta input:checked + span { background: #eef1f4; color: var(--muted); text-decoration: line-through; }
.modeseg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: -2px; }
.ndays { display: inline-flex; align-items: center; gap: 6px; margin-right: 14px; white-space: nowrap; }
.ndays input { width: 70px; min-height: 34px; }
.nset td { vertical-align: middle; }
.npaused { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.npaused li { display: inline-flex; align-items: center; gap: 8px; padding: 4px 10px; border-radius: 999px; background: var(--n-veluoja-soft); border: 1px solid #f3dc8e; font-size: 13px; }
.npaused form { display: inline; }
.ntpl { border-top: 1px solid var(--line); border-left: 4px solid var(--line-strong); }
.ntpl.n-priminimas { border-left-color: var(--n-priminimas); }
.ntpl.n-veluoja { border-left-color: var(--n-veluoja); }
.ntpl.n-palukanos { border-left-color: var(--n-palukanos); }
.ntpl.n-draudimas { border-left-color: var(--n-draudimas); }
.ntpl.n-vki { border-left-color: var(--n-vki); }
.ntpl.n-ispejimas { border-left-color: var(--n-ispejimas); }
.ntpl-head { display: flex; align-items: center; gap: 10px; padding: 12px 16px; cursor: pointer; }
.ntpl-subj { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
.ntpl-body { padding: 0 16px 16px; }
.nmarkers { display: flex; flex-wrap: wrap; gap: 6px; }
.nmarker { font: 600 12px var(--font); padding: 3px 8px; border-radius: 4px; border: 1px dashed var(--line-strong); background: var(--surface-2); color: var(--ink-2); cursor: pointer; }
.nmarker:hover { border-style: solid; border-color: var(--accent); color: var(--accent-ink); }
.loan-notify { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
@media (max-width: 860px) {
  .nkpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.nmail.clamp { position: relative; cursor: pointer; }
.nmail.clamp .nbody { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.nmail.clamp.open .nbody { display: block; -webkit-line-clamp: unset; }
.nmail .nmore { display: inline-block; margin-top: 6px; font-size: 12px; font-weight: 600; color: var(--accent); }
.nmail.clamp.open .nmore { display: none; }
.nmail.clamp:focus-visible { outline: 2px solid var(--accent); }
.nwarn-i { color: var(--critical-ink); }
:root { --n-pazeidimas: #8a5a00; --n-pazeidimas-soft: #f6ead2; --n-pasekme: #b03a5b; --n-pasekme-soft: #f9e4ea; }
.nchip.n-pazeidimas { background: var(--n-pazeidimas-soft); color: #6b4300; border-color: #e6cf9f; }
.nchip.n-pasekme { background: var(--n-pasekme-soft); color: #8a2442; border-color: #eec2cf; }
.nitem.n-pazeidimas, .ntpl.n-pazeidimas { border-left-color: var(--n-pazeidimas); }
.nitem.n-pasekme, .ntpl.n-pasekme { border-left-color: var(--n-pasekme); }
/* Atsarginės kopijos (2026-10-20) */
.bk-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.nkpi .s { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.nkpi.k-warn { border-top-color: var(--warning); background: #fff8e1; }
.bk-v { font-size: var(--step-2) !important; }
.bk-help { border-top: 1px solid var(--line); }
.bk-cmd { margin: 6px 0; padding: 10px 12px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 12.5px; white-space: pre-wrap; overflow-wrap: anywhere; }

/* Apžvalga: išieškojimo pastabos (2026-10-20) */
.att.rec { border-top: 3px solid var(--critical); }
.att-notes li { display: block; }
.att-notes .an-top { display: flex; justify-content: space-between; gap: 12px; }
.att-notes .an-loan { display: block; }
.att-notes .an-note { margin-top: 6px; padding: 6px 10px; border-left: 3px solid var(--line); background: var(--surface-2, rgba(0,0,0,.03)); border-radius: 4px; font-size: 12.5px; color: var(--ink); white-space: pre-line; overflow-wrap: anywhere; }
.att-notes .an-note.muted { color: var(--muted); }
.att-notes .an-date { font-weight: 600; color: var(--muted); margin-right: 8px; font-variant-numeric: tabular-nums; }
.att li .meta.what { display: block; }
.att-head .sum { white-space: nowrap; }

/* Kopijų instrukcija (2026-10-20) */
.bk-steps { margin: 0; padding-left: 40px; display: grid; gap: 12px; counter-reset: none; }
.bk-steps li { padding-left: 4px; line-height: 1.55; }
.bk-steps li::marker { color: var(--accent, #2563eb); font-weight: 700; }
.bk-cmdrow { display: flex; gap: 8px; align-items: stretch; margin-top: 6px; }
.bk-cmdrow .bk-cmd { flex: 1; margin: 0; display: flex; align-items: center; }
.bk-cmdrow .btn { white-space: nowrap; }
kbd { display: inline-block; padding: 1px 6px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; background: var(--surface-2); font-size: 12px; font-family: inherit; }
@media (max-width: 640px) { .bk-cmdrow { flex-direction: column; } }
.bk-which { display: grid; gap: 8px; }
.bk-case { padding: 10px 14px; border-radius: var(--radius-sm); border-left: 4px solid var(--line); background: var(--surface-2); font-size: var(--step--1); line-height: 1.5; }
.bk-case span { display: block; color: var(--muted); }
.bk-case.c-srv, .bk-details.c-srv .bk-tag { border-color: #0f8a6a; }
.bk-case.c-new, .bk-details.c-new .bk-tag { border-color: #c47f00; }
.bk-case.c-mac, .bk-details.c-mac .bk-tag { border-color: #2f6db5; }
.bk-details { border-top: 1px solid var(--line); }
.bk-details > summary { cursor: pointer; list-style: none; display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; justify-content: space-between; padding: 14px 20px; }
.bk-details > summary::-webkit-details-marker { display: none; }
.bk-details > summary h3 { margin: 0; font-size: var(--step-0); display: flex; align-items: center; gap: 10px; }
.bk-details > summary h3::before { content: "▸"; color: var(--accent); transition: transform .15s; display: inline-block; }
.bk-details[open] > summary h3::before { transform: rotate(90deg); }
.bk-details > summary:hover h3 { color: var(--accent); }
.bk-details[open] > summary { background: var(--surface-2); }
.bk-tag { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; border: 2px solid; font-size: 12px; font-weight: 700; }
.bk-details.c-srv .bk-tag { color: #0f8a6a; } .bk-details.c-new .bk-tag { color: #c47f00; } .bk-details.c-mac .bk-tag { color: #2f6db5; }
.nsender form { display: inline; margin-left: 8px; } .nsender .linkbtn { font-size: 12px; }
