/* ФИСКОР — светлосива тема по подразбиране; тъмна по избор (бутонът горе) */
@font-face { font-family: "Golos Text"; font-style: normal; font-weight: 400 700; font-display: swap; src: url(../fonts/golos-cyrillic.woff2) format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Golos Text"; font-style: normal; font-weight: 400 700; font-display: swap; src: url(../fonts/golos-latin.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  color-scheme: light;
  --bg: #eef0f3; --surface: #ffffff; --surface-2: #f6f7f9; --surface-3: #eceef1;
  --side: #e4e7eb; --side-2: #f1f3f5; --side-ink: #2e353d; --side-mute: #78818c; --side-line: #d6dae0;
  --side-hover: rgba(30, 40, 52, .06); --side-on: #ffffff; --side-strong: #15191e;
  --ink: #1a1e23; --ink-2: #474f59; --ink-3: #727b86; --line: #d8dce2; --line-2: #e7eaee;
  --pri: #23282e; --pri-2: #343b43; --pri-ink: #ffffff;
  --acc: #3d8fdc; --acc-2: #5aa7e8; --acc-soft: #e6f1fb; --acc-ink: #1d5f9c;
  --s1: #a9c9e8; --s2: #3d8fdc; --s3: #23282e; --s4: #6b7682; --sf: #d9534f; --sq: #a8b0b9;
  --ok: #18794e; --ok-bg: #e5f4ec; --err: #b42323; --err-bg: #fbeaea; --warn: #8a5a00; --warn-bg: #fff4dc; --info: #1d5f9c; --info-bg: #e6f1fb;
  --neg: #b42323; --pos: #18794e;
  --shadow: 0 1px 2px rgba(15, 18, 22, .05), 0 6px 20px rgba(15, 18, 22, .05);
  --shadow-l: 0 20px 50px rgba(15, 18, 22, .18);
  --r: 12px; --sans: "Golos Text", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0f1114; --surface: #171a1e; --surface-2: #1c2025; --surface-3: #22272d; --side: #0b0d0f; --side-2: #121519;
  --side-ink: #d5dae0; --side-mute: #7f8893; --side-line: rgba(255, 255, 255, .07); --side-hover: rgba(255, 255, 255, .05); --side-on: rgba(90, 167, 232, .16); --side-strong: #ffffff;
  --ink: #e7eaee; --ink-2: #b5bdc6; --ink-3: #848d98; --line: #2b3037; --line-2: #22272d;
  --pri: #e3e7ec; --pri-2: #ffffff; --pri-ink: #111418; --acc: #5aa7e8; --acc-2: #86c0f2; --acc-soft: #16283a; --acc-ink: #9ccbf3;
  --s1: #24425f; --s2: #5aa7e8; --s3: #d5dae0; --s4: #6b7682; --sf: #ef7a76; --sq: #4a525c;
  --ok: #63d197; --ok-bg: #12291e; --err: #ff8a8a; --err-bg: #3a1c1c; --warn: #f4c063; --warn-bg: #352a12; --info: #86c0f2; --info-bg: #16283a;
  --neg: #ff8a8a; --pos: #63d197; --shadow: 0 1px 2px rgba(0, 0, 0, .4); --shadow-l: 0 20px 50px rgba(0, 0, 0, .55);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 14.5px/1.55 var(--sans); color: var(--ink); background: var(--bg); }
a { color: var(--acc-ink); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: .18em; }
:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { margin: 0 0 .6em; line-height: 1.25; letter-spacing: -.01em; }
h2 { font-size: 1.02rem; display: flex; align-items: center; gap: 8px; }
h3 { font-size: .78rem; color: var(--ink-3); text-transform: uppercase; letter-spacing: .07em; }
p { margin: 0 0 .8em; }
code, .mono, pre { font-family: var(--mono); font-size: .86em; }
small, .small { font-size: .82rem; }
.muted { color: var(--ink-3); }
.center { text-align: center; } .r { text-align: right; }
.mt { margin-top: 18px; } .mt-s { margin-top: 8px; } .mb { margin-bottom: 16px; } .pad { padding: 12px 16px; }
.nowrap { white-space: nowrap; }
.dim { opacity: .5; }
.ico { width: 18px; height: 18px; flex: none; vertical-align: -3px; }
.ico.big { width: 38px; height: 38px; }
[hidden] { display: none !important; }
kbd { font: 600 .68rem/1 var(--mono); padding: 3px 5px; border-radius: 5px; border: 1px solid var(--line); border-bottom-width: 2px; background: var(--surface-2); color: var(--ink-2); white-space: nowrap; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.num.neg, .neg { color: var(--neg); } .pos { color: var(--pos); }

/* ---------- Оформление ---------- */
.adm { display: grid; grid-template-columns: 264px 1fr; min-height: 100vh; }
.side { background: linear-gradient(180deg, var(--side-2), var(--side)); color: var(--side-ink); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; overflow-y: auto; border-right: 1px solid var(--side-line); scrollbar-width: thin; scrollbar-color: #c3c9d0 transparent; }
.side-logo { display: block; padding: 18px 16px 14px; }
.side-logo:hover { text-decoration: none; }
.brand { display: flex; align-items: center; gap: 11px; color: inherit; }
.brand img { flex: none; border-radius: 10px; box-shadow: 0 2px 8px rgba(20, 30, 40, .12); }
.brand-t { display: flex; flex-direction: column; line-height: 1.15; }
.brand-t b { font-size: 1.12rem; color: var(--side-strong); letter-spacing: .04em; }
.brand-t b em { font-style: normal; font-weight: 800; color: var(--side-strong); }
.brand-t small { font-size: .66rem; letter-spacing: .12em; text-transform: uppercase; color: var(--side-mute); margin-top: 3px; }
.side-office { margin: 0 12px 6px; padding: 10px 12px; border-radius: 10px; background: var(--side-on); border: 1px solid var(--side-line); display: flex; flex-direction: column; gap: 3px; }
.side-office small { font-size: .64rem; text-transform: uppercase; letter-spacing: .12em; color: var(--side-mute); }
.side-office b { color: var(--side-strong); font-size: .88rem; line-height: 1.25; }
.side-office .tag { align-self: flex-start; }
.side nav { padding: 4px 10px 16px; flex: 1; }
.side .grp { display: block; font-size: .64rem; letter-spacing: .16em; text-transform: uppercase; color: var(--side-mute); padding: 16px 10px 6px; }
.side nav a, .side-foot a { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 8px; color: var(--side-ink); font-size: .88rem; position: relative; }
.side nav a:hover, .side-foot a:hover { background: var(--side-hover); text-decoration: none; color: var(--side-strong); }
.side nav a.on { background: var(--side-on); color: var(--side-strong); font-weight: 600; box-shadow: 0 1px 2px rgba(20, 30, 40, .08); }
.side nav a.on::before { content: ""; position: absolute; left: -10px; top: 7px; bottom: 7px; width: 3px; border-radius: 0 3px 3px 0; background: var(--acc); }
.side nav a .ico { opacity: .85; }
.side nav a > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side nav kbd { margin-left: auto; background: transparent; border-color: var(--side-line); color: var(--side-mute); font-size: .6rem; padding: 2px 4px; }
.side .cnt { margin-left: auto; font-style: normal; font-size: .7rem; font-weight: 700; background: #3d8fdc; color: #fff; border-radius: 99px; padding: 1px 8px; }
.side-foot { padding: 10px 10px 14px; border-top: 1px solid var(--side-line); }
.side-foot small { display: block; padding: 6px 10px 0; color: var(--side-mute); }
.me { display: flex; gap: 10px; align-items: center; padding: 6px 10px 10px; }
.me span { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.me b { color: var(--side-strong); font-size: .88rem; overflow: hidden; text-overflow: ellipsis; } .me small { color: var(--side-mute); font-size: .72rem; }
.main { min-width: 0; display: flex; flex-direction: column; }
.top { display: flex; align-items: center; gap: 14px; padding: 12px 26px; background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.top h1 { font-size: 1.18rem; margin: 0; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-act { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; justify-content: flex-end; }
.co-switch { display: flex; align-items: center; gap: 8px; padding: 4px 6px 4px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); max-width: 340px; }
.co-switch select { border: 0; background: transparent; padding: 6px 4px; font-weight: 600; box-shadow: none !important; min-width: 0; max-width: 290px; }
.burger { display: none; background: none; border: 0; color: var(--ink); padding: 6px; cursor: pointer; }
.content { padding: 22px 26px 40px; flex: 1; width: 100%; max-width: 1680px; }
.afoot { padding: 14px 26px; font-size: .76rem; color: var(--ink-3); border-top: 1px solid var(--line); display: flex; gap: 10px; flex-wrap: wrap; justify-content: space-between; }
.credits a { color: inherit; text-decoration: underline; text-decoration-color: var(--line); }
.banner { display: flex; align-items: center; gap: 12px; padding: 10px 26px; font-size: .88rem; border-bottom: 1px solid var(--line); }
.banner span { flex: 1; } .banner.info { background: var(--info-bg); color: var(--info); } .banner.warn { background: var(--warn-bg); color: var(--warn); } .banner.err { background: var(--err-bg); color: var(--err); }

/* ---------- Карти и решетки ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px 20px; margin-bottom: 18px; box-shadow: var(--shadow); min-width: 0; container-type: inline-size; }
.card.np { padding: 0; overflow: hidden; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.card-h h2 { margin: 0; }
.card.np > .card-h { padding: 12px 16px; border-bottom: 1px solid var(--line-2); }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.grid21 { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.grid12 { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(0, 2fr); gap: 18px; align-items: start; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 16px; }
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 14px; }
.grid2 > *, .grid21 > *, .grid3 > *, .grid4 > *, .grid12 > * { min-width: 0; }
.span2 { grid-column: span 2; } .span4 { grid-column: 1 / -1; }
.card .grid2 { gap: 0 14px; }
.sticky { position: sticky; top: 76px; }
.row-act { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.search { display: flex; gap: 6px; flex: 1 1 260px; max-width: 460px; }

/* ---------- Плочки ---------- */
.kpis { display: grid; gap: 14px; margin-bottom: 18px; }
.kpis.k3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .kpis.k4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kpi { display: flex; gap: 12px; align-items: flex-start; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; box-shadow: var(--shadow); min-width: 0; }
.kpi-i { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--surface-3); color: var(--ink-2); flex: none; }
.kpi div { min-width: 0; display: flex; flex-direction: column; }
.kpi small { color: var(--ink-3); font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; }
.kpi b { font-size: 1.42rem; line-height: 1.2; font-variant-numeric: tabular-nums; letter-spacing: -.02em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kpi em { font-style: normal; font-size: .74rem; color: var(--ink-3); }
.kpi.ok .kpi-i { background: var(--ok-bg); color: var(--ok); } .kpi.warn .kpi-i { background: var(--warn-bg); color: var(--warn); }
.statlist { list-style: none; margin: 0; padding: 0; }
.statlist li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line-2); }
.statlist li:last-child { border: 0; } .statlist span { display: flex; gap: 8px; align-items: center; color: var(--ink-2); }

/* ---------- Графики ---------- */
.chart { position: relative; width: 100%; min-height: 120px; }
.chart svg { display: block; width: 100%; overflow: visible; }
.chart .gl { stroke: var(--line-2); } .chart .ax { fill: var(--ink-3); font: 11px var(--sans); }
.chart .ln { fill: none; stroke-width: 2.4; stroke-linejoin: round; } .chart .hit { fill: transparent; }
.chart .cross { stroke: var(--ink-3); stroke-dasharray: 3 3; } .chart .dot { stroke: var(--surface); stroke-width: 2; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: .8rem; color: var(--ink-2); margin-top: 8px; }
.legend span { display: flex; align-items: center; gap: 6px; } .legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.tip { position: absolute; pointer-events: none; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; font-size: .8rem; box-shadow: var(--shadow-l); min-width: 140px; z-index: 5; }
.tip div { display: flex; justify-content: space-between; gap: 12px; } .tip div span { display: flex; gap: 6px; align-items: center; } .tip i { width: 8px; height: 8px; border-radius: 2px; }
.chart-table summary { font-size: .76rem; color: var(--ink-3); cursor: pointer; margin-top: 6px; }

/* ---------- Таблици ---------- */
.tbl-wrap { overflow-x: auto; } .tbl-wrap.tall { max-height: calc(100vh - 220px); overflow-y: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: .875rem; }
.tbl th { text-align: left; font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); font-weight: 600; padding: 9px 12px; border-bottom: 1px solid var(--line); background: var(--surface-2); white-space: nowrap; position: sticky; top: 0; z-index: 1; }
.tbl th a { color: inherit; }
.tbl td { padding: 9px 12px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.tbl tbody tr:hover td { background: color-mix(in srgb, var(--acc) 5%, transparent); }
.tbl tbody tr.sel td { background: var(--acc-soft); }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tfoot td { font-weight: 700; background: var(--surface-2); border-top: 1px solid var(--line); }
.tbl .r, .tbl th.r { text-align: right; } .tbl th.c { text-align: center; }
.tbl .w1 { width: 1%; }
.tbl.kv td:first-child { color: var(--ink-3); width: 34%; }
.card:not(.np) .tbl th { background: none; position: static; }
.rowlink { cursor: pointer; }
.tbl.report td { padding: 7px 12px; }
.tbl.journal .accs div { white-space: nowrap; font-size: .82rem; }
.tbl.acctree tr.lvl0 td { font-weight: 600; background: color-mix(in srgb, var(--surface-2) 60%, transparent); }
.tbl.banktx tr.done td { opacity: .65; }
.tbl.banktx select, .tbl.quick select, .tbl.quick input, .tbl.ob input, .lines-ed input, .lines-ed select { padding: 6px 8px; font-size: .84rem; }
.tbl.keys td { padding: 6px 8px; }
.w-s { width: 70px !important; } .w-m { width: 110px !important; } .w-l { min-width: 170px; }

/* ---------- Етикети ---------- */
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: .72rem; font-weight: 600; padding: 2px 9px; border-radius: 99px; white-space: nowrap; line-height: 1.6; text-decoration: none !important; }
.tag .ico { width: 13px; height: 13px; }
.tag.ok { background: var(--ok-bg); color: var(--ok); } .tag.err { background: var(--err-bg); color: var(--err); } .tag.warn { background: var(--warn-bg); color: var(--warn); }
.tag.info { background: var(--info-bg); color: var(--info); } .tag.off { background: var(--surface-3); color: var(--ink-3); }
.conf { display: inline-flex; align-items: center; gap: 6px; font-size: .74rem; font-weight: 600; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.conf i { width: 40px; height: 6px; border-radius: 99px; background: linear-gradient(90deg, var(--acc) calc(var(--c) * 1%), var(--line) 0); }

/* ---------- Бутони и полета ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; font: 600 .875rem/1 var(--sans); padding: 10px 15px; border-radius: 9px; border: 1px solid var(--pri); background: var(--pri); color: var(--pri-ink); cursor: pointer; text-decoration: none !important; white-space: nowrap; transition: background .15s, box-shadow .15s, transform .05s; }
.btn:hover { background: var(--pri-2); box-shadow: 0 4px 14px rgba(15, 18, 22, .18); }
.btn:active { transform: translateY(1px); }
.btn kbd { background: rgba(255, 255, 255, .14); border-color: rgba(255, 255, 255, .2); color: inherit; }
.btn.ghost { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { background: var(--surface-2); border-color: var(--ink-3); box-shadow: none; }
.btn.ghost kbd { background: var(--surface-2); border-color: var(--line); }
.btn.danger { color: var(--err); } .btn.danger:hover { border-color: var(--err); background: var(--err-bg); }
.btn.sm { padding: 6px 10px; font-size: .8rem; border-radius: 7px; } .btn.lg { padding: 13px 20px; font-size: .95rem; }
.btn.w100 { width: 100%; } .btn.icon-only { padding: 8px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; } .btn.busy { opacity: .7; pointer-events: none; }
.fld { display: flex; flex-direction: column; gap: 5px; margin-bottom: 14px; min-width: 0; }
.fld > span { font-size: .76rem; font-weight: 600; color: var(--ink-2); }
.fld .inl { display: flex; gap: 6px; }
input[type=text], input[type=email], input[type=password], input[type=search], input[type=number], input[type=url], input[type=tel], input[type=date], input[type=month], input[type=datetime-local], input:not([type]), select, textarea {
  font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; width: 100%; min-width: 0; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--acc); box-shadow: 0 0 0 3px color-mix(in srgb, var(--acc) 22%, transparent); }
input.r { text-align: right; font-variant-numeric: tabular-nums; }
input[type=checkbox], input[type=radio] { accent-color: var(--acc); width: 16px; height: 16px; flex: none; }
.chk { display: flex; gap: 9px; align-items: flex-start; margin-bottom: 12px; cursor: pointer; } .chk span { line-height: 1.35; }
.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 12px; }
.filters .fld, .filters .chk { margin: 0; } .filters.card { padding: 12px 16px; }
.inline { display: inline-flex; gap: 6px; align-items: center; margin: 0 2px; }
.inline select { width: auto; padding: 5px 8px; font-size: .8rem; }
.tgl { width: 40px; height: 22px; border-radius: 99px; border: 0; background: var(--line); position: relative; cursor: pointer; }
.tgl::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: left .15s; }
.tgl.on { background: var(--acc); } .tgl.on::after { left: 21px; }
.inline-menu { position: relative; display: inline-block; }
.inline-menu summary { list-style: none; } .inline-menu summary::-webkit-details-marker { display: none; }
.im-box { position: absolute; right: 0; top: 110%; z-index: 30; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px; box-shadow: var(--shadow-l); display: flex; flex-direction: column; gap: 10px; min-width: 250px; text-align: left; }
.im-box.wide { min-width: 320px; } .im-box form { display: flex; flex-direction: column; gap: 6px; }

.flash { padding: 11px 15px; border-radius: 10px; margin-bottom: 12px; border: 1px solid; display: block; font-size: .9rem; }
.flash .ico { margin-right: 4px; }
.flash.ok { background: var(--ok-bg); color: var(--ok); border-color: color-mix(in srgb, var(--ok) 25%, transparent); }
.flash.err { background: var(--err-bg); color: var(--err); border-color: color-mix(in srgb, var(--err) 25%, transparent); }
.flash.warn { background: var(--warn-bg); color: var(--warn); border-color: color-mix(in srgb, var(--warn) 25%, transparent); }
.flash.info { background: var(--info-bg); color: var(--info); border-color: color-mix(in srgb, var(--info) 25%, transparent); }
.flash.q { background: var(--surface-2); color: var(--ink); border-color: var(--acc); border-left-width: 4px; }
.empty { text-align: center; padding: 38px 20px; color: var(--ink-3); }
.empty .ico { width: 40px; height: 40px; opacity: .45; margin-bottom: 8px; } .empty .btn { margin: 4px; }
.tabs { display: flex; gap: 2px; margin-bottom: 14px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tabs a { padding: 9px 14px; color: var(--ink-2); border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; display: flex; gap: 6px; align-items: center; }
.tabs a.on { color: var(--ink); border-color: var(--acc); font-weight: 600; } .tabs a:hover { text-decoration: none; color: var(--ink); }
.tabs .cnt { font-style: normal; font-size: .68rem; background: var(--acc); color: #fff; border-radius: 99px; padding: 0 6px; }
.seg { display: inline-flex; background: var(--surface-3); border-radius: 10px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg a, .seg button { padding: 6px 12px; border-radius: 8px; color: var(--ink-2); font: 500 .82rem var(--sans); border: 0; background: none; cursor: pointer; display: flex; gap: 6px; align-items: center; }
.seg a i { font-style: normal; font-size: .7rem; color: var(--ink-3); }
.seg .on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); font-weight: 600; } .seg a:hover { text-decoration: none; }
.pager { display: flex; gap: 4px; flex-wrap: wrap; justify-content: center; margin: 10px 0 20px; }
.pager a, .pager b, .pager span { min-width: 34px; text-align: center; padding: 6px 10px; border-radius: 7px; border: 1px solid var(--line); background: var(--surface); }
.pager b { background: var(--pri); color: var(--pri-ink); border-color: var(--pri); }
.bulk { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 10px 16px; border-top: 1px solid var(--line); background: var(--surface-2); }
.hello { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.hello h2 { font-size: 1.4rem; margin: 0; letter-spacing: -.02em; }
.eyebrow { font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--acc-ink); margin: 0 0 6px; display: block; }
.toast { position: fixed; bottom: 20px; right: 20px; background: #1b1f24; color: #fff; padding: 12px 18px; border-radius: 10px; box-shadow: var(--shadow-l); z-index: 100; max-width: 420px; white-space: pre-line; }
.toast.err { background: #8f1d1d; }
.log { background: var(--surface-2); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; white-space: pre-wrap; font-size: .78rem; max-height: 340px; overflow: auto; }
.steps-list { padding-left: 20px; } .steps-list li { margin-bottom: 4px; }
.meter { margin-bottom: 12px; } .mt-h { display: flex; justify-content: space-between; font-size: .84rem; margin-bottom: 4px; }
.bar { height: 8px; background: var(--surface-3); border-radius: 99px; overflow: hidden; } .bar i { display: block; height: 100%; background: var(--acc); border-radius: 99px; } .bar i.hot { background: var(--warn); }

/* ---------- Табло ---------- */
.hero-card { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 24px; padding: 26px; border-radius: 16px; background: radial-gradient(600px 300px at 0% 0%, rgba(90, 167, 232, .16), transparent 60%), linear-gradient(135deg, var(--surface), var(--surface-2)); color: var(--ink); border: 1px solid var(--line); margin-bottom: 18px; box-shadow: var(--shadow); }
.hero-card h2 { font-size: 1.5rem; color: var(--ink); } .hero-card .muted { color: var(--ink-3); }
 .hero-card.ok { grid-template-columns: 1fr; }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.steps li { display: flex; flex-direction: column; padding: 10px 12px 10px 44px; position: relative; background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px; }
.steps li::before { counter-increment: s; content: counter(s); position: absolute; left: 12px; top: 11px; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: #5aa7e8; color: #08131d; font-weight: 700; font-size: .78rem; }
.steps li span { color: var(--ink-3); font-size: .84rem; }

/* ---------- Качване и опашка ---------- */
.drop { display: flex; align-items: center; gap: 18px; border: 2px dashed var(--line); border-radius: 16px; padding: 22px 24px; background: var(--surface); cursor: pointer; margin-bottom: 14px; transition: border-color .15s, background .15s, transform .15s; position: relative; overflow: hidden; }
.drop:hover { border-color: var(--acc); }
.drop.over { border-color: var(--acc); background: var(--acc-soft); transform: scale(1.005); }
.drop > div:nth-child(3) { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.drop-i { width: 60px; height: 60px; border-radius: 16px; display: grid; place-items: center; background: linear-gradient(135deg, #ffffff, #e3e7ec); border: 1px solid var(--line); color: var(--acc); flex: none; box-shadow: 0 8px 20px rgba(0, 0, 0, .18); }
.drop .cam { flex: none; }
.queue { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 14px; overflow: hidden; box-shadow: var(--shadow); }
.q-h { display: flex; justify-content: space-between; padding: 10px 16px; border-bottom: 1px solid var(--line-2); background: var(--surface-2); }
.q-list { max-height: 320px; overflow-y: auto; }
.q-item { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 16px; border-bottom: 1px solid var(--line-2); font-size: .86rem; }
.q-item:last-child { border: 0; }
.q-item .q-n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .q-item small { color: var(--ink-3); }
.q-item .spin { width: 16px; height: 16px; border: 2px solid var(--line); border-top-color: var(--acc); border-radius: 50%; animation: spin .8s linear infinite; }
.q-item.ok .spin { border: 0; background: var(--ok); mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z"/></svg>') center/contain no-repeat; animation: none; }
.q-item.err .spin { border: 0; background: var(--err); border-radius: 3px; animation: none; }
.q-item .qb { height: 3px; grid-column: 1 / -1; background: var(--surface-3); border-radius: 99px; overflow: hidden; } .q-item .qb i { display: block; height: 100%; width: 0; background: var(--acc); transition: width .2s; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Преглед на документ ---------- */
.review { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 18px; align-items: start; }
.viewer { position: sticky; top: 72px; height: calc(100vh - 96px); display: flex; }
.viewer iframe { width: 100%; height: 100%; border: 0; background: #525659; }
.imgview { width: 100%; height: 100%; overflow: auto; background: repeating-conic-gradient(var(--surface-2) 0 25%, var(--surface) 0 50%) 0 0 / 20px 20px; display: grid; place-items: start center; }
.imgview img { max-width: 100%; cursor: zoom-in; } .imgview.zoom img { max-width: none; cursor: zoom-out; }
.txtview { width: 100%; height: 100%; overflow: auto; } .txtview pre, pre.ocr { white-space: pre-wrap; padding: 14px; margin: 0; font-size: .78rem; max-height: 70vh; overflow: auto; }
.doc-head .dh-top { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
.doc-head .dh-top .btn { margin-left: auto; }
.doc-head .flash { margin-bottom: 8px; }
.entry-ed { border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px 12px; margin: 0 0 14px; background: var(--surface); box-shadow: var(--shadow); min-width: 0; }
.entry-ed { container-type: inline-size; }
@container (max-width: 860px) { .entry-ed .dc { grid-template-columns: 1fr; } .entry-ed .eh { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.entry-ed legend { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-3); padding: 0 6px; }
.entry-ed[data-role="payment"] { border-style: dashed; }
.entry-ed .eh .fld { margin-bottom: 10px; }
.entry-ed .eh input, .entry-ed .eh select { padding: 7px 9px; font-size: .86rem; }
.dc { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.side-t { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.side-t th { position: static; } .side-t[data-side="D"] th:first-child { color: var(--acc-ink); } .side-t[data-side="C"] th:first-child { color: var(--ink); }
.side-t td { padding: 5px 6px; vertical-align: middle; }
.side-t input { padding: 6px 7px; font-size: .86rem; } .side-t input.amt { width: 110px; }
.side-t .acc-name { color: var(--ink-2); line-height: 1.25; font-size: .78rem; }
.side-t .x { border: 0; background: none; color: var(--ink-3); font-size: 1.1rem; cursor: pointer; padding: 2px 6px; border-radius: 6px; } .side-t .x:hover { background: var(--err-bg); color: var(--err); }
.diff { margin-top: 8px; font-size: .82rem; min-height: 1em; } .diff.bad { color: var(--err); font-weight: 600; } .diff.ok { color: var(--ok); }
.ica { margin-top: 10px; padding: 9px 12px; border-radius: 9px; background: var(--acc-soft); color: var(--acc-ink); font-size: .84rem; }
.post-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; position: sticky; bottom: 0; padding: 12px 0; background: linear-gradient(transparent, var(--bg) 30%); z-index: 2; }
.card .post-bar, .quickform .post-bar { position: static; background: none; }
.talk .msgs { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; max-height: 420px; overflow-y: auto; }
.msg { max-width: 86%; padding: 10px 13px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-2); }
.msg.me { align-self: flex-end; background: var(--acc-soft); border-color: transparent; }
.msg small { display: block; color: var(--ink-3); font-size: .7rem; margin-bottom: 3px; } .msg p { margin: 0; }
.talk-form textarea { margin-bottom: 8px; }
.docform h3 { margin-top: 10px; }
.entry-page { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 18px; align-items: start; }
.entry-num { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; color: var(--ink-3); }
.entry-num b { color: var(--ink); font-family: var(--mono); letter-spacing: .04em; }
.help-panel { position: sticky; top: 76px; } .help-panel .cmd { list-style: none; padding: 0; margin: 0 0 14px; font-size: .84rem; } .help-panel .cmd li { padding: 4px 0; display: flex; gap: 8px; align-items: center; }
.help-panel .messages { font-size: .82rem; }
.how ol { padding-left: 18px; } .how li { margin-bottom: 6px; }

/* ---------- Фирми ---------- */
.cgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.ccard { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 12px; transition: transform .15s, box-shadow .15s; }
.ccard:hover { transform: translateY(-2px); box-shadow: var(--shadow-l); }
.ccard.on { border-color: var(--acc); box-shadow: 0 0 0 3px color-mix(in srgb, var(--acc) 18%, transparent); }
.cc-h { display: flex; gap: 12px; align-items: center; } .cc-h div { display: flex; flex-direction: column; min-width: 0; } .cc-h b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cc-av { width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center; font-weight: 700; background: linear-gradient(135deg, #ffffff, #e3e7ec); border: 1px solid var(--line); color: var(--ink); flex: none; }
.cc-s { display: flex; gap: 12px; flex-wrap: wrap; font-size: .8rem; color: var(--ink-3); } .cc-s b { color: var(--ink); }
.cc-a { display: flex; gap: 8px; align-items: center; }
.yrow { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 8px 0; border-bottom: 1px solid var(--line-2); } .yrow b { min-width: 60px; }
.gl-acc .dc { padding: 12px; }

/* ---------- Планове ---------- */
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin-bottom: 10px; }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 8px; position: relative; box-shadow: var(--shadow); }
.plan.pop { border-color: var(--acc); box-shadow: 0 0 0 3px color-mix(in srgb, var(--acc) 15%, transparent), var(--shadow-l); }
.plan.current { outline: 2px dashed var(--ok); outline-offset: 3px; }
.plan h3 { font-size: 1.05rem; color: var(--ink); text-transform: none; letter-spacing: 0; margin: 0; }
.plan .price b { font-size: 1.9rem; letter-spacing: -.03em; } .plan .price span { color: var(--ink-3); margin-left: 4px; }
.plan ul { list-style: none; padding: 0; margin: 4px 0 8px; flex: 1; font-size: .86rem; } .plan li { display: flex; gap: 8px; padding: 3px 0; } .plan li .ico { color: var(--ok); width: 16px; height: 16px; margin-top: 2px; }
.ribbon { position: absolute; top: -11px; right: 16px; background: var(--acc); color: #fff; font-size: .7rem; font-weight: 700; padding: 3px 10px; border-radius: 99px; }

/* ---------- Вход и инсталация ---------- */
.login-body { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: radial-gradient(900px 500px at 15% -10%, rgba(90, 167, 232, .18), transparent 60%), radial-gradient(700px 500px at 110% 110%, rgba(42, 48, 56, .08), transparent 60%), linear-gradient(160deg, #f4f6f8, #e2e6eb); }
.login-wrap { width: min(420px, 100%); }
.login { background: var(--surface); border-radius: 18px; padding: 30px; border: 1px solid var(--line); box-shadow: 0 24px 60px rgba(20, 30, 40, .14); }
.login-logo { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; margin-bottom: 22px; color: var(--ink); text-decoration: none !important; }
.login-logo img { border-radius: 14px; box-shadow: 0 10px 26px rgba(0, 0, 0, .3); }
.login-logo b { font-size: 1.5rem; letter-spacing: .06em; font-weight: 800; } .login-logo b em { font-style: normal; }
.login-logo span { font-size: .78rem; color: var(--ink-3); }
.login-note { display: flex; gap: 8px; align-items: center; justify-content: center; font-size: .76rem; color: var(--ink-3); margin: 16px 0 6px; }
.login-foot { text-align: center; color: var(--ink-3); font-size: .72rem; margin-top: 18px; } .login-foot a { color: var(--ink-2); }
.ins { width: min(760px, 100%); margin: 30px auto; } .ins > .login-logo b { color: var(--ink); } .ins > .login-logo span { color: var(--ink-3); }
.req { list-style: none; padding: 0; margin: 0; } .req li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line-2); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.zip-drop { border: 2px dashed var(--line); border-radius: 12px; padding: 26px; text-align: center; } .zip-drop.over { border-color: var(--acc); background: var(--acc-soft); }
.up-progress { display: flex; align-items: center; gap: 10px; margin-top: 12px; } .up-progress .bar { flex: 1; }
.lnk { color: var(--acc-ink); text-decoration: underline; cursor: pointer; }
.totp-key { display: block; font-size: 1.1rem; letter-spacing: .1em; background: var(--surface-2); border: 1px solid var(--line); padding: 10px; border-radius: 8px; text-align: center; margin: 8px 0; word-break: break-all; }
.otp { font-size: 1.4rem !important; letter-spacing: .3em; text-align: center; font-family: var(--mono) !important; }
.print-head { display: none; }
.diag summary { cursor: pointer; }

/* ---------- Мобилни ---------- */
@media (max-width: 1280px) { .review { grid-template-columns: 1fr; } .viewer { position: static; height: 70vh; } .entry-page { grid-template-columns: 1fr; } .help-panel { display: none; } }
@media (max-width: 1100px) { .grid21, .grid2, .grid12, .hero-card { grid-template-columns: 1fr; } .kpis.k4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sticky { position: static; } }
@media (max-width: 900px) {
  .adm { grid-template-columns: 1fr; }
  .side { position: fixed; inset: 0 auto 0 0; width: 280px; z-index: 40; transform: translateX(-100%); transition: transform .2s; }
  .side.open { transform: none; box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .5); }
  .burger { display: block; }
  .top { padding: 10px 14px; flex-wrap: wrap; } .top h1 { order: 3; width: 100%; font-size: 1.05rem; } .co-switch { flex: 1; max-width: none; }
  .content { padding: 14px; } .afoot, .banner { padding: 12px 14px; }
  .grid3, .grid4, .dc, .row2 { grid-template-columns: 1fr; } .span2 { grid-column: auto; }
  .kpis.k3 { grid-template-columns: 1fr; }
  .drop { flex-wrap: wrap; } .drop-i { width: 46px; height: 46px; }
}
@media (max-width: 480px) { .kpis.k4 { grid-template-columns: 1fr; } .kpi b { font-size: 1.2rem; } }

/* ---------- Печат ---------- */
@media print {
  :root { --bg: #fff; --surface: #fff; --surface-2: #fff; --ink: #000; --ink-2: #222; --ink-3: #444; --line: #bbb; --line-2: #ddd; --shadow: none; }
  @page { size: A4 landscape; margin: 12mm 10mm; }
  body { font-size: 9.5pt; background: #fff; }
  .adm { display: block; }
  .side, .top, .afoot, .noprint, .burger, .bulk, .pager, .filters, .tabs, .seg, .flash, .banner, .btn, .toast, .chart-table { display: none !important; }
  .content { padding: 0; max-width: none; }
  .card, .kpi { box-shadow: none; break-inside: avoid; border-color: #bbb; }
  .card.np { overflow: visible; } .tbl-wrap { overflow: visible; max-height: none !important; }
  .tbl { font-size: 8.5pt; } .tbl th { background: #eee !important; position: static; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .tbl tr { break-inside: avoid; }
  .print-head { display: flex; border-bottom: 2px solid #23282e; padding-bottom: 8px; margin-bottom: 12px; }
  .print-head h1 { font-size: 14pt; margin: 2px 0; } .print-head p { margin: 0; } .print-head small { color: #444; }
  a { color: #000; }
}

/* ── ДМА ── */
.grow { flex: 1 1 auto; }
.tbl tr.tot td { font-weight: 700; background: var(--surface-2); border-top: 1px solid var(--line); }
.tbl tr.sub td { color: var(--ink-3); font-style: italic; }
.asset-form h3 { font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); margin: 18px 0 8px; }
.asset-form details summary { cursor: pointer; color: var(--ink-2); font-weight: 600; margin-bottom: 8px; }
.tbl td.r .tag, .tbl td .tag { white-space: nowrap; }
/* ГФО */
.tbl.gfo tr.h td { background: var(--surface-2); font-weight: 700; letter-spacing: .02em; }
.tbl.gfo tr.sub td { font-weight: 600; font-style: normal; color: var(--ink); }
.tbl.gfo tr.memo td { color: var(--ink-3); font-size: .92em; }
.tbl.gfo td.r { white-space: nowrap; width: 160px; }
.print-sign { display: none; }
@media print { .print-sign { display: flex; justify-content: space-between; margin-top: 48px; } .print-sign span { border-top: 1px solid #999; padding-top: 4px; min-width: 220px; } }
/* Шаблони */
dl.kv { display: grid; grid-template-columns: max-content 1fr; gap: 4px 14px; margin: 0 0 14px; font-size: .88rem; } dl.kv dt { color: var(--ink-3); } dl.kv dd { margin: 0; }
.chk-row { display: flex; flex-wrap: wrap; gap: 4px 14px; } .chk-row .chk { margin: 0; }
/* Валута × курс в контирането */
.fxbox { display: flex; align-items: center; gap: 4px; margin-top: 4px; color: var(--ink-3); } .fxbox input { width: 88px; padding: 4px 6px; font-size: .8rem; } .fxbox .rate { width: 78px; }
/* Касови ордери и платежно нареждане */
.cash-order { padding: 18px 22px; } .co-head { display: flex; justify-content: space-between; gap: 16px; border-bottom: 2px solid var(--ink); padding-bottom: 8px; margin-bottom: 10px; } .co-head h2 { margin: 0 0 2px; font-size: 1rem; letter-spacing: .04em; }
.co-body { width: 100%; border-collapse: collapse; font-size: .9rem; } .co-body th { text-align: left; width: 170px; color: var(--ink-3); font-weight: 500; padding: 5px 8px 5px 0; vertical-align: top; } .co-body td { padding: 5px 0; border-bottom: 1px dotted var(--line); }
.co-sign { display: flex; justify-content: space-between; gap: 16px; margin-top: 28px; font-size: .85rem; } .co-sign span { flex: 1; border-top: 1px solid var(--ink-3); padding-top: 4px; } .co-sign i { font-style: normal; font-weight: 600; }
.payorder .po-title { text-align: center; font-size: 1.05rem; } .payorder .po-title small { display: block; font-weight: 400; color: var(--ink-3); font-size: .8rem; }
table.po { width: 100%; border-collapse: collapse; font-size: .85rem; } table.po th { text-align: left; font-weight: 500; color: var(--ink-3); width: 210px; padding: 6px 8px; border: 1px solid var(--line); background: var(--surface-2); } table.po td { border: 1px solid var(--line); padding: 4px 6px; }
.po-in { width: 100%; border: 0; background: transparent; font: inherit; padding: 3px 2px; } .po-in.mono { font-family: ui-monospace, monospace; letter-spacing: .03em; } .po-in:focus { outline: 2px solid var(--accent, #6b7c93); }
.po-sign { display: flex; justify-content: space-between; margin-top: 40px; font-size: .85rem; } .po-sign span { border-top: 1px solid var(--ink-3); padding-top: 4px; min-width: 220px; }
@media print { .cash-order { break-inside: avoid; page-break-inside: avoid; margin-bottom: 18mm; box-shadow: none; border: 1px solid #999; } .payorder { box-shadow: none; } .po-in { color: #000; } table.po th { background: #f2f2f2 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; } }
/* Потвърдително писмо */
.letter { padding: 22px 28px; } .lt-head { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 14px; } .lt-title { text-align: center; letter-spacing: .06em; font-size: 1.05rem; margin: 10px 0 14px; }
.lt-t { margin: 10px 0; } .lt-cut { color: var(--ink-3); margin: 26px 0 10px; white-space: nowrap; overflow: hidden; } .lt-sign2 { display: flex; justify-content: space-between; margin-top: 30px; } .lt-sign2 span { min-width: 220px; border-top: 1px solid var(--ink-3); padding-top: 4px; }
@media print { .letter { break-after: page; page-break-after: always; box-shadow: none; border: 0; } .letter:last-child { break-after: auto; } }
/* Стока × количество в контирането */
.qtybox { display: flex; align-items: center; gap: 4px; margin-top: 4px; } .qtybox .item { flex: 1; min-width: 90px; padding: 4px 6px; font-size: .8rem; } .qtybox .qty { width: 70px; padding: 4px 6px; font-size: .8rem; }
tr.bad td { background: var(--err-bg); }

/* ГФО – отчет за собствения капитал: широка таблица */
.tbl.eq td:first-child{min-width:240px}
.tbl.eq th{white-space:normal;min-width:90px}

/* Платформа → Система */
.tbl.kv th { color: var(--ink-3); width: 38%; font-weight: 500; text-align: left; }
pre.log { max-height: 420px; overflow: auto; background: var(--bg-2, #f4f5f7); padding: 10px 12px; border-radius: 8px; white-space: pre-wrap; word-break: break-word; }
.kpi.err .kpi-i { background: var(--err-bg); color: var(--err); }

/* ---------- Меню: отляво групирано / горе ---------- */
.side nav.grouped { padding-top: 8px; }
.ngrp { margin: 2px 0; border-radius: 10px; }
.ngrp > summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; cursor: pointer; color: var(--side-strong); font-weight: 600; font-size: .86rem; user-select: none; }
.ngrp > summary::-webkit-details-marker { display: none; }
.ngrp > summary::after { content: ""; margin-left: auto; width: 7px; height: 7px; border-right: 2px solid var(--side-mute); border-bottom: 2px solid var(--side-mute); transform: rotate(-45deg); transition: transform .15s; }
.ngrp[open] > summary::after { transform: rotate(45deg); }
.ngrp > summary .cnt { margin-left: auto; margin-right: 6px; }
.ngrp > summary:hover { background: var(--side-hover); }
.ngrp-items { padding: 2px 0 6px 12px; border-left: 1px solid var(--side-line); margin-left: 18px; }
.ngrp-items a { font-size: .85rem; padding: 6px 10px; }
.menu-mode { position: relative; }
.menu-mode > summary { list-style: none; } .menu-mode > summary::-webkit-details-marker { display: none; }
.mm-box { position: absolute; right: 0; top: calc(100% + 6px); z-index: 60; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 30px rgba(0, 0, 0, .14); padding: 8px; min-width: 230px; display: flex; flex-direction: column; gap: 2px; }
.mm-box b { font-size: .7rem; text-transform: uppercase; letter-spacing: .12em; color: var(--ink-3); padding: 4px 8px; }
.mm-box a { display: flex; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 8px; color: var(--ink); font-size: .88rem; }
.mm-box a:hover { background: var(--surface-2); text-decoration: none; } .mm-box a.on { font-weight: 600; color: var(--acc-ink, var(--acc)); }
.top-logo { display: none; } .topnav { display: none; }
.powered { color: inherit; font-size: .68rem; }
@media (min-width: 901px) {
  .adm.menu-top { grid-template-columns: 1fr; }
  .adm.menu-top .side { display: none; }
  .menu-top .top { flex-wrap: wrap; row-gap: 8px; }
  .menu-top .top-logo { display: block; } .menu-top .top-logo:hover { text-decoration: none; }
  .menu-top .topnav { display: flex; order: 10; width: 100%; gap: 2px; align-items: center; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 6px; margin: 0 -6px; }
  .tgrp { position: relative; }
  .tgrp > summary { list-style: none; display: flex; align-items: center; gap: 7px; padding: 7px 11px; border-radius: 8px; cursor: pointer; font-size: .86rem; font-weight: 600; color: var(--ink-2); user-select: none; }
  .tgrp > summary::-webkit-details-marker { display: none; }
  .tgrp > summary:hover, .tgrp[open] > summary { background: var(--surface-2); color: var(--ink); }
  .tgrp.on > summary { color: var(--acc-ink, var(--acc)); box-shadow: inset 0 -2px 0 var(--acc); }
  .tgrp > summary .cnt { font-style: normal; font-size: .68rem; font-weight: 700; background: #3d8fdc; color: #fff; border-radius: 99px; padding: 1px 7px; }
  .tgrp-box { position: absolute; left: 0; top: calc(100% + 4px); z-index: 60; min-width: 270px; max-height: 70vh; overflow-y: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 14px 34px rgba(0, 0, 0, .16); padding: 6px; display: flex; flex-direction: column; }
  .tgrp-box a { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 8px; color: var(--ink); font-size: .88rem; }
  .tgrp-box a:hover { background: var(--surface-2); text-decoration: none; } .tgrp-box a.on { background: var(--surface-2); font-weight: 600; }
  .tgrp-box a > span { flex: 1; } .tgrp-box kbd { margin-left: auto; font-size: .6rem; }
  .tgrp-box .cnt { font-style: normal; font-size: .7rem; font-weight: 700; background: #3d8fdc; color: #fff; border-radius: 99px; padding: 1px 8px; }
  .tn-me { display: flex; align-items: center; gap: 6px; font-size: .84rem; color: var(--ink-2); padding: 0 6px; }
  .tn-out { display: flex; padding: 6px 8px; border-radius: 8px; color: var(--ink-2); } .tn-out:hover { background: var(--surface-2); }
}.ngrp-items kbd { display: none; }
.side-foot a.powered { display: inline; padding: 0; border-radius: 0; font-size: .68rem; white-space: nowrap; color: var(--side-mute); }
.side-foot a.powered:hover { background: none; text-decoration: underline; }

/* Цял екран – съдържанието заема цялата ширина при всеки мащаб */
@media (min-width: 901px) { .adm { grid-template-columns: 236px 1fr; } }
.content { max-width: none; padding: 16px 18px 28px; }
.top { padding: 10px 18px; } .banner { padding: 9px 18px; } .afoot { padding: 12px 18px; }
.side-logo { padding: 14px 14px 10px; }
@media (min-width: 1800px) { .adm { grid-template-columns: 250px 1fr; } }
.inline-row { display: flex; gap: 6px; align-items: center; } .inline-row input { flex: 1; min-width: 180px; }

/* ---------- Цветови схеми (светла и тъмна за всяка) ---------- */
:root[data-palette="olive"] { --acc: #6b7f2a; --acc-2: #869c3c; --acc-soft: #eef2df; --acc-ink: #4c5c18; --info: #4c5c18; --info-bg: #eef2df; --s2: #6b7f2a; --s1: #869c3c; --side: #e3e6d4; --side-2: #f1f3e8; --bg: #eef0e6; }
:root[data-theme="dark"][data-palette="olive"] { --acc: #a3b85a; --acc-2: #bfd27a; --acc-soft: #232914; --acc-ink: #c5d68d; --info: #c5d68d; --info-bg: #232914; --s2: #a3b85a; --s1: #232914; --side: #0d0f08; --side-2: #14170d; --bg: #101209; --side-on: color-mix(in srgb, #a3b85a 18%, transparent); }
:root[data-palette="blue"] { --acc: #2f7de1; --acc-2: #5b9bea; --acc-soft: #e5f0fd; --acc-ink: #1d5bb0; --info: #1d5bb0; --info-bg: #e5f0fd; --s2: #2f7de1; --s1: #5b9bea; --side: #dfe8f4; --side-2: #eef4fb; --bg: #ecf1f8; }
:root[data-theme="dark"][data-palette="blue"] { --acc: #6aa8f5; --acc-2: #94c1f8; --acc-soft: #14243b; --acc-ink: #a9cdfa; --info: #a9cdfa; --info-bg: #14243b; --s2: #6aa8f5; --s1: #14243b; --side: #0a0e15; --side-2: #10161f; --bg: #0d1219; --side-on: color-mix(in srgb, #6aa8f5 18%, transparent); }
:root[data-palette="orange"] { --acc: #e07a1f; --acc-2: #ef9645; --acc-soft: #fdf0e3; --acc-ink: #a5530c; --info: #a5530c; --info-bg: #fdf0e3; --s2: #e07a1f; --s1: #ef9645; --side: #f1e6db; --side-2: #f8f1ea; --bg: #f5efe8; }
:root[data-theme="dark"][data-palette="orange"] { --acc: #f3a05a; --acc-2: #f7bb84; --acc-soft: #3a2412; --acc-ink: #f8c99c; --info: #f8c99c; --info-bg: #3a2412; --s2: #f3a05a; --s1: #3a2412; --side: #120c07; --side-2: #1a120b; --bg: #150f0a; --side-on: color-mix(in srgb, #f3a05a 18%, transparent); }
:root[data-palette="violet"] { --acc: #7a4fd1; --acc-2: #946ee0; --acc-soft: #efe8fb; --acc-ink: #5631a6; --info: #5631a6; --info-bg: #efe8fb; --s2: #7a4fd1; --s1: #946ee0; --side: #e7e1f2; --side-2: #f3eff9; --bg: #f0edf6; }
:root[data-theme="dark"][data-palette="violet"] { --acc: #a888f0; --acc-2: #c1a8f5; --acc-soft: #251a3c; --acc-ink: #cbb6f7; --info: #cbb6f7; --info-bg: #251a3c; --s2: #a888f0; --s1: #251a3c; --side: #0d0a14; --side-2: #14101d; --bg: #110e18; --side-on: color-mix(in srgb, #a888f0 18%, transparent); }
:root[data-palette="teal"] { --acc: #139a8f; --acc-2: #33b3a8; --acc-soft: #e0f4f2; --acc-ink: #0b6d65; --info: #0b6d65; --info-bg: #e0f4f2; --s2: #139a8f; --s1: #33b3a8; --side: #dbebe9; --side-2: #ecf5f4; --bg: #e9f2f1; }
:root[data-theme="dark"][data-palette="teal"] { --acc: #4fd0c4; --acc-2: #7fdfd6; --acc-soft: #10302d; --acc-ink: #94e5dd; --info: #94e5dd; --info-bg: #10302d; --s2: #4fd0c4; --s1: #10302d; --side: #071110; --side-2: #0c1817; --bg: #091413; --side-on: color-mix(in srgb, #4fd0c4 18%, transparent); }
:root[data-palette="ruby"] { --acc: #b3304a; --acc-2: #c95369; --acc-soft: #f9e5e9; --acc-ink: #86203a; --info: #86203a; --info-bg: #f9e5e9; --s2: #b3304a; --s1: #c95369; --side: #efdfe3; --side-2: #f7eef0; --bg: #f4ecee; }
:root[data-theme="dark"][data-palette="ruby"] { --acc: #e8728a; --acc-2: #f096a8; --acc-soft: #3a1620; --acc-ink: #f4aebc; --info: #f4aebc; --info-bg: #3a1620; --s2: #e8728a; --s1: #3a1620; --side: #13090c; --side-2: #1b0e12; --bg: #160b0e; --side-on: color-mix(in srgb, #e8728a 18%, transparent); }
.side .cnt, .tgrp > summary .cnt, .tgrp-box .cnt { background: var(--acc); }
.pal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; padding: 4px 8px 6px; }
.pal button { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--surface); box-shadow: 0 0 0 1px var(--line); cursor: pointer; padding: 0; }
.pal button.on { box-shadow: 0 0 0 2px var(--ink); }
.mm-box .sep { border-top: 1px solid var(--line-2); margin: 6px 0 2px; }
.statlist li a { display: flex; gap: 8px; align-items: center; color: var(--ink-2); }
@media (max-width: 1100px) { .dash3 { grid-template-columns: 1fr; } }

/* ---------- Съветник за нова кантора ---------- */
.wiz { max-width: 980px; margin: 0 auto; }
.wiz-steps { list-style: none; display: flex; gap: 8px; padding: 0; margin: 4px 0 18px; counter-reset: s; }
.wiz-steps li { flex: 1; display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); color: var(--ink-3); font-size: .86rem; }
.wiz-steps li i { font-style: normal; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-3); font-weight: 700; font-size: .78rem; flex: none; }
.wiz-steps li.on { border-color: var(--acc); color: var(--ink); font-weight: 600; } .wiz-steps li.on i { background: var(--acc); color: #fff; }
.wiz-steps li.done i { background: var(--ok-bg); color: var(--ok); }
.wiz-card { padding: 26px 28px; } .wiz-card h2 { font-size: 1.3rem; }
.wiz-bar { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; align-items: center; } .wiz-bar .btn.ghost:first-child { margin-right: auto; }
.wiz-opts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.wiz-opt { display: flex; flex-direction: column; gap: 4px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.wiz-opt:has(input:checked) { border-color: var(--acc); background: var(--acc-soft); } .wiz-opt input { margin: 0 0 4px; }
.wiz-pal { justify-content: start; grid-template-columns: repeat(7, 34px); } .wiz-pal button { width: 32px; height: 32px; }
.wiz-next { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.wiz-next a { display: flex; flex-direction: column; gap: 4px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); }
.wiz-next a:hover { border-color: var(--acc); text-decoration: none; background: var(--acc-soft); } .wiz-next a .ico { width: 24px; height: 24px; color: var(--acc); }
@media (max-width: 760px) { .wiz-steps span { display: none; } .wiz-opts, .wiz-next { grid-template-columns: 1fr; } }
/* ---------- Помощ ---------- */
.help-g { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 18px; align-items: start; }
.help-toc { position: sticky; top: 80px; padding: 12px; } .help-toc input { width: 100%; margin-bottom: 8px; }
.help-toc nav { display: flex; flex-direction: column; } .help-toc nav a { display: flex; gap: 8px; align-items: center; padding: 6px 8px; border-radius: 8px; color: var(--ink-2); font-size: .88rem; }
.help-toc nav a:hover { background: var(--surface-2); text-decoration: none; }
.help-body { display: flex; flex-direction: column; gap: 14px; } .help-sec { scroll-margin-top: 80px; line-height: 1.65; } .help-sec h2 { font-size: 1.15rem; }
.help-sec ul, .help-sec ol { padding-left: 20px; } .help-sec li { margin: 4px 0; } .help-sec:target { box-shadow: 0 0 0 2px var(--acc); }
.help-sec mark { background: var(--warn-bg); color: inherit; border-radius: 3px; }
@media (max-width: 900px) { .help-g { grid-template-columns: 1fr; } .help-toc { position: static; } }
/* ---------- Потребителски справки ---------- */
.split-l { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 16px; align-items: start; }
.list-nav { display: flex; flex-direction: column; padding: 4px 8px 8px; } .list-nav a { display: flex; gap: 8px; align-items: center; padding: 7px 9px; border-radius: 8px; color: var(--ink-2); }
.list-nav a span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .list-nav a:hover { background: var(--surface-2); text-decoration: none; } .list-nav a.on { background: var(--surface-2); color: var(--ink); font-weight: 600; }
.cr-out .cr-h td { font-weight: 700; background: var(--surface-2); text-transform: uppercase; font-size: .78rem; letter-spacing: .05em; } .cr-out .cr-b td { font-weight: 700; border-top: 1px solid var(--line); }
.cr-out .pos { color: var(--ok, #2f8f4e); } .cr-out .neg { color: var(--err, #c0392b); } .cr-edit input.w-full { width: 100%; } form.inline { display: inline; }
@media (max-width: 900px) { .split-l { grid-template-columns: 1fr; } }
@media print { .split-l { display: block; } .split-l > aside, .split-l .filters { display: none; } }
/* ---------- Аналитичен регистър ---------- */
.an-tbl .an-h td { background: var(--surface-2); padding-top: 10px; } .an-tbl .an-o td, .an-tbl .an-t td { color: var(--ink-2); font-style: italic; }
.an-tbl .an-c td { font-weight: 700; border-bottom: 2px solid var(--line); } .row-gap { display: inline-flex; gap: 6px; }
/* ---------- Въпроси към клиента ---------- */
.msg.msg-client { border-left: 3px solid #f0a92b; } .ask-form { border-top: 1px dashed var(--line); padding-top: 10px; margin-bottom: 10px; }
/* ---------- Контролно табло на кантората ---------- */
.office-kpis { grid-template-columns: repeat(6, minmax(0, 1fr)); } .office-kpis .kpi { flex-direction: column; gap: 4px; } .office-kpis .kpi b { font-size: 1.5rem; }
.office-tbl td { vertical-align: middle; } .office-tbl .tag { white-space: nowrap; margin: 1px; } .office-tbl tr.done td { opacity: .75; }
@media (max-width: 1100px) { .office-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } } @media (max-width: 600px) { .office-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- Проверка на счетоводството ---------- */
.checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 14px; }
.checks .card { border-left: 4px solid var(--line); } .checks .chk-err { border-left-color: #c0392b; } .checks .chk-warn { border-left-color: #e0a12b; } .checks .chk-ok { border-left-color: #2f8f4e; }
.chk-h { display: flex; align-items: center; gap: 10px; } .chk-h b { flex: 1; } .chk-ic { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; }
.chk-err .chk-ic { background: #fbeaea; color: #c0392b; } .chk-warn .chk-ic { background: #fdf3e1; color: #9a5b00; } .chk-ok .chk-ic { background: #e7f5ee; color: #2f8f4e; }
.checks ul { margin: 10px 0 0; padding-left: 18px; } .checks li { margin: 3px 0; }
@media (max-width: 600px) { .checks { grid-template-columns: 1fr; } }

/* ---------- Издаване на фактури ---------- */
.inv-lines input, .inv-lines select { min-width: 0; } .inv-lines td { vertical-align: middle; } .inv-view { padding: 28px; }
body.inv-print { background: #fff; padding: 24px; } @media print { body.inv-print { padding: 0; } }
@media (max-width: 900px) { .inv-form .grid4 { grid-template-columns: 1fr 1fr; } }

/* ---------- Режим на поддръжка (администратор в кантора) ---------- */
.impersonate-bar { position: sticky; top: 0; z-index: 60; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 14px; padding: 9px 14px; border-radius: 12px;
  background: linear-gradient(90deg, #1a0b4c, #3a2490); color: #fff; box-shadow: 0 6px 18px rgba(26, 11, 76, .25); }
.impersonate-bar span { flex: 1; min-width: 220px; } .impersonate-bar .ico { width: 18px; height: 18px; }
.impersonate-bar .btn.ghost { color: #fff; border-color: rgba(255,255,255,.35); } .impersonate-bar .btn:not(.ghost) { background: #b04c28; border-color: #b04c28; color: #fff; }.impersonate-bar .btn.ghost { background: rgba(255,255,255,.12) !important; color: #fff !important; }

/* ---------- Глобално търсене ---------- */
.top-search { display: flex; align-items: center; gap: 6px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 0 10px; height: 36px; min-width: 0; flex: 0 1 260px; }
.top-search input { border: 0; background: transparent; outline: none; width: 100%; min-width: 0; font: inherit; color: inherit; padding: 0; height: 34px; box-shadow: none; }
.top-search .ico { width: 16px; height: 16px; opacity: .6; flex: none; } .top-search:focus-within { border-color: var(--acc); }
.search-res { display: grid; grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)); gap: 14px; }
.sr-list { list-style: none; margin: 0; padding: 0 0 6px; } .sr-list a { display: flex; flex-direction: column; padding: 8px 16px; color: inherit; border-top: 1px solid var(--line); }
.sr-list a:hover { background: var(--surface-2); text-decoration: none; }
@media (max-width: 900px) { .top-search { display: none; } .search-res { grid-template-columns: 1fr; } }
/* ---------- Известия ---------- */
.bell { position: relative; } .bell > summary { list-style: none; position: relative; } .bell > summary::-webkit-details-marker { display: none; }
.bell-n { position: absolute; top: 2px; right: 2px; min-width: 17px; height: 17px; border-radius: 9px; background: #c0392b; color: #fff; font: 700 10px/17px var(--sans, sans-serif); text-align: center; font-style: normal; padding: 0 4px; }
.bell-pop { position: absolute; right: 0; top: calc(100% + 6px); width: min(380px, 92vw); max-height: 70vh; overflow: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 14px 40px rgba(0,0,0,.18); z-index: 80; }
.bell-h { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line); font-size: .9rem; }
.bell-i { display: flex; gap: 10px; align-items: flex-start; padding: 9px 14px; color: var(--ink); font-size: .88rem; border-bottom: 1px solid var(--line); } .bell-i:hover { background: var(--surface-2); text-decoration: none; }
.bell-i .dot { flex: none; width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; background: #3b6fe0; } .bell-err .dot { background: #c0392b; } .bell-warn .dot { background: #e0a12b; }.bell-pop { position: fixed; top: 60px; right: 12px; left: auto; }
.bell-pop { z-index: 1000; } .impersonate-bar { z-index: 5; }
.fc-tbl tr.fc-neg td { background: color-mix(in srgb, #c0392b 8%, transparent); } .fc-tbl .pos { color: #2f8f4e; } .fc-tbl .neg { color: #c0392b; }

.c-ok { color: var(--ok); } .c-err { color: var(--err); }
.c-warn { color: var(--warn, #b26a00); }

/* ---------- Дървовидно меню (v1.23) ---------- */
.side nav.tree { padding-top: 6px; font-size: .86rem; }
.tsec { margin: 4px 0 10px; } .tsec > b { display: block; font-size: .68rem; text-transform: uppercase; letter-spacing: .12em; color: var(--side-mute); padding: 8px 10px 4px; }
.side nav.tree a.tl { padding: 5px 10px; font-size: .85rem; }
.tb { margin: 1px 0; } .tb > summary { list-style: none; display: flex; align-items: center; gap: 8px; padding: 5px 10px; border-radius: 8px; cursor: pointer; color: var(--side-ink); user-select: none; }
.tb > summary::-webkit-details-marker { display: none; }
.tb > summary::before { content: ""; width: 6px; height: 6px; flex: none; border-right: 2px solid var(--side-mute); border-bottom: 2px solid var(--side-mute); transform: rotate(-45deg); transition: transform .15s; margin-right: 2px; }
.tb[open] > summary::before { transform: rotate(45deg); }
.tb > summary > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tb > summary:hover { background: var(--side-hover); color: var(--side-strong); }
.tb > summary .ico { width: 16px; height: 16px; opacity: .85; }
.tk { margin-left: 15px; padding-left: 6px; border-left: 1px dashed var(--side-line); }
.tco > summary { font-weight: 600; color: var(--side-strong); } .tco.cur > summary { background: var(--side-on); box-shadow: 0 1px 2px rgba(20, 30, 40, .08); }
.tco > summary .ico { color: var(--acc); opacity: 1; }
/* ---------- Досие на фирмата (v1.23) ---------- */
.dos-dl { display: grid; grid-template-columns: 110px 1fr; gap: 6px 12px; margin: 10px 0; font-size: .9rem; } .dos-dl dt { color: var(--ink-3); } .dos-dl dd { margin: 0; }
.dos-svc { display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 4px 0 8px; }
.dos-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 14px; }
.dos-sec { padding: 16px; scroll-margin-top: 80px; } .dos-sec-h { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; } .dos-sec-h b { flex: 1; }
.dos-ic { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: color-mix(in srgb, var(--acc) 14%, transparent); color: var(--acc); }
.dos-list { list-style: none; margin: 0; padding: 0; } .dos-list li { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.dos-list li a { flex: 1; min-width: 0; color: var(--ink); } .dos-list li small { flex-basis: 100%; }
.dos-add { background: color-mix(in srgb, var(--ok, #18794e) 14%, transparent); color: var(--ok, #18794e); border-color: transparent; }
.dos-edit { border-color: var(--acc); }
@media (max-width: 1100px) { .dos-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 700px) { .dos-grid { grid-template-columns: 1fr; } }
/* Завършеност на месеца в таблото на кантората (v1.23) */
.done-bar { display: flex; align-items: center; gap: 8px; margin: 4px 0 2px; } .done-bar .trk { width: 110px; height: 6px; border-radius: 6px; background: var(--line); overflow: hidden; } .done-bar i { display: block; height: 100%; background: #b42323; } .done-bar i.mid { background: #d99a00; } .done-bar i.ok { background: #18794e; } .done-bar b { font-size: .72rem; color: var(--ink-3); font-weight: 600; }

/* ---------- Табло на платформата (v1.23) ---------- */
.pd-bars { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; align-items: end; margin: 10px 0; }
.pd-col { display: flex; flex-direction: column; align-items: center; gap: 4px; } .pd-col small { color: var(--ink-3); } .pd-col b { font-size: .7rem; color: var(--ink-2); font-weight: 600; text-align: center; }
.pd-b { display: flex; gap: 4px; align-items: flex-end; height: 140px; width: 100%; justify-content: center; }
.pd-b i { display: block; width: 14px; border-radius: 4px 4px 0 0; min-height: 2px; } .pd-b i.r, .pd-dot.r { background: var(--acc); } .pd-b i.p, .pd-dot.p { background: #18794e; }
.pd-dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; vertical-align: -1px; margin: 0 4px 0 10px; }
/* ---------- Маркери и история на документа (v1.23) ---------- */
.mk-pick { display: inline-flex; gap: 5px; margin-left: auto; } .mk-pick .mk { width: 18px; height: 18px; border-radius: 50%; border: 2px solid transparent; background: var(--mk); cursor: pointer; padding: 0; opacity: .45; }
.mk-pick .mk:hover { opacity: .85; } .mk-pick .mk.on { opacity: 1; border-color: var(--surface); box-shadow: 0 0 0 2px var(--mk); }
.mk-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--mk); margin-right: 6px; vertical-align: 0; flex: none; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 14px; border-left: 2px solid var(--line); } .timeline li { position: relative; padding: 6px 0 6px 10px; font-size: .88rem; }
.timeline li::before { content: ""; position: absolute; left: -20px; top: 12px; width: 10px; height: 10px; border-radius: 50%; background: var(--acc); }

/* Банка: няколко фактури на ред (v1.31) */
.bank-multi { margin-top: 4px; font-size: .82rem; } .bank-multi summary { cursor: pointer; color: var(--acc); } .bank-multi > div { display: flex; flex-direction: column; gap: 3px; max-height: 180px; overflow: auto; padding: 6px 0; }
