/* BITL · Реестр инвесторов — дизайн по презентации BITL (сентябрь 2026):
   белый фон, тёмные плашки #1A171B, фирменный #EB3300, Unbounded для заголовков и цифр, Nunito Sans для текста */
@font-face { font-family: 'Unbounded'; font-weight: 400; src: url(/assets/fonts/Unbounded-Regular.ttf) format('truetype'); font-display: swap; }
@font-face { font-family: 'Unbounded'; font-weight: 500; src: url(/assets/fonts/Unbounded-Medium.ttf) format('truetype'); font-display: swap; }
@font-face { font-family: 'Unbounded'; font-weight: 600; src: url(/assets/fonts/Unbounded-SemiBold.ttf) format('truetype'); font-display: swap; }
@font-face { font-family: 'Unbounded'; font-weight: 700; src: url(/assets/fonts/Unbounded-Bold.ttf) format('truetype'); font-display: swap; }
@font-face { font-family: 'Nunito Sans'; font-weight: 400; src: url(/assets/fonts/NunitoSans-Regular.ttf) format('truetype'); font-display: swap; }
@font-face { font-family: 'Nunito Sans'; font-weight: 500; src: url(/assets/fonts/NunitoSans-Medium.ttf) format('truetype'); font-display: swap; }
@font-face { font-family: 'Nunito Sans'; font-weight: 600; src: url(/assets/fonts/NunitoSans-SemiBold.ttf) format('truetype'); font-display: swap; }
@font-face { font-family: 'Nunito Sans'; font-weight: 700; src: url(/assets/fonts/NunitoSans-Bold.ttf) format('truetype'); font-display: swap; }

:root {
  --bg: #ffffff; --bg2: #f4f4f5; --dark: #1a171b; --dark2: #2a272c; --text: #1a171b; --text2: #3a3d42;
  --muted: #8c8f98; --line: #d9dadb; --line2: #dedee0; --line3: #e7e7e7;
  --orange: #eb3300; --orange2: #e63312; --orange-tint: #ffe3db; --orange-tint2: #fff1ec;
  --green: #1f8a4c; --green-tint: #e3f4ea; --amber: #b7791f; --amber-tint: #fdf1d8; --red-tint: #fde3de;
  --head: 'Unbounded', 'Inter', -apple-system, sans-serif;
  --body: 'Nunito Sans', 'Inter', -apple-system, 'Segoe UI', sans-serif;
  --r: 24px; --r2: 16px; --r3: 12px;
  --shadow: 0 6px 24px rgba(26,23,27,.08);
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--body); font-size: 14px; line-height: 1.5; }
a { color: var(--orange); text-decoration: none; }
h1, h2, h3, .num, .head { font-family: var(--head); }
h1 { font-size: 28px; font-weight: 600; margin: 0; line-height: 1.2; letter-spacing: -.01em; }
h2 { font-size: 18px; font-weight: 600; margin: 0 0 14px; }
h3 { font-size: 14px; font-weight: 600; margin: 0; }
.eyebrow { font-family: var(--head); font-size: 9px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 400; }
.eyebrow.light { color: rgba(255,255,255,.75); }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.hidden { display: none !important; }
.nowrap { white-space: nowrap; }

button, input, select, textarea { font-family: var(--body); font-size: 14px; color: var(--text); }
input, select, textarea { background: #fff; border: 1px solid var(--line); border-radius: var(--r3); padding: 9px 12px; outline: none; transition: border-color .15s, box-shadow .15s; width: 100%; }
input:focus, select:focus, textarea:focus { border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-tint); }
input[type=date] { color-scheme: light; }
textarea { resize: vertical; min-height: 60px; line-height: 1.4; }
select { appearance: none; -webkit-appearance: none; padding-right: 32px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238c8f98' stroke-width='2' fill='none'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; }
label { font-size: 11px; color: var(--muted); display: block; margin-bottom: 5px; letter-spacing: .04em; text-transform: uppercase; font-weight: 600; }

.btn { display: inline-flex; align-items: center; gap: 8px; border: 0; border-radius: 999px; padding: 11px 20px; font-family: var(--head); font-weight: 500; font-size: 12px; cursor: pointer; background: var(--orange); color: #fff; white-space: nowrap; transition: transform .1s, background .15s, opacity .15s; }
.btn:hover { background: var(--orange2); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn.dark { background: var(--dark); }
.btn.dark:hover { background: var(--dark2); }
.btn.sec { background: #fff; color: var(--text); border: 1px solid var(--line); }
.btn.sec:hover { border-color: var(--text2); background: #fff; }
.btn.light { background: #fff; color: var(--dark); }
.btn.light:hover { background: var(--bg2); }
.btn.ghost { background: transparent; color: var(--muted); padding: 8px 12px; font-family: var(--body); font-weight: 600; }
.btn.ghost:hover { color: var(--text); background: var(--bg2); }
.btn.sm { padding: 8px 14px; font-size: 11px; }
.btn.danger { background: transparent; color: var(--orange2); border: 1px solid var(--orange-tint); font-family: var(--body); font-weight: 600; }
.btn.danger:hover { background: var(--orange-tint2); }
.btn:disabled { opacity: .5; cursor: default; transform: none; }
.btn.tiny { padding: 4px 10px; font-size: 10px; }

/* --- шапка --- */
header.top { display: flex; align-items: center; gap: 28px; padding: 0 36px; height: 68px; background: var(--dark); color: #fff; position: sticky; top: 0; z-index: 20; }
header.top .logo { display: flex; align-items: center; gap: 16px; color: #fff; }
header.top .logo img { height: 24px; }
header.top .logo .app { font-family: var(--head); font-size: 11px; color: rgba(255,255,255,.7); border-left: 1px solid rgba(255,255,255,.2); padding-left: 16px; letter-spacing: .04em; }
header.top nav { display: flex; gap: 4px; }
header.top nav a { color: rgba(255,255,255,.7); font-family: var(--head); font-size: 11px; padding: 8px 14px; border-radius: 999px; transition: all .15s; }
header.top nav a:hover { color: #fff; }
header.top nav a.on { color: #fff; background: rgba(255,255,255,.1); }
header.top .spacer { flex: 1; }
header.top .tools { display: flex; gap: 8px; align-items: center; }
main { padding: 32px 36px 80px; max-width: 1600px; margin: 0 auto; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 24px; flex-wrap: wrap; }
.page-head .sub { color: var(--muted); margin-top: 6px; }
.page-head .actions { display: flex; gap: 8px; flex-wrap: wrap; }
.crumbs { font-size: 12px; color: var(--muted); margin-bottom: 10px; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--orange); }

/* --- KPI --- */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; margin-bottom: 28px; }
.kpi { border-radius: var(--r); padding: 22px 24px; background: #fff; border: 1px solid var(--line); min-height: 128px; display: flex; flex-direction: column; justify-content: space-between; gap: 10px; }
.kpi .v { font-family: var(--head); font-size: clamp(20px, 1.8vw, 26px); font-weight: 700; line-height: 1.1; letter-spacing: -.01em; }
.kpi .v small { font-size: 13px; font-weight: 400; color: var(--muted); margin-left: 4px; }
.kpi .d { font-size: 12px; color: var(--muted); }
.kpi.orange { background: var(--orange); border-color: var(--orange); color: #fff; }
.kpi.orange .d, .kpi.orange .v small { color: rgba(255,255,255,.8); }
.kpi.dark { background: var(--dark); border-color: var(--dark); color: #fff; }
.kpi.dark .d, .kpi.dark .v small { color: rgba(255,255,255,.65); }

/* --- карточки --- */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 22px 24px; }
.card + .card { margin-top: 16px; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.inv-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 22px 24px; cursor: pointer; transition: border-color .15s, transform .15s, box-shadow .15s; display: flex; flex-direction: column; gap: 6px; }
.inv-card:hover { border-color: var(--dark); transform: translateY(-2px); box-shadow: var(--shadow); }
.inv-card .name { font-family: var(--head); font-size: 15px; font-weight: 600; line-height: 1.3; }
.inv-card .kind { font-size: 12px; color: var(--muted); }
.inv-card .amt { font-family: var(--head); font-size: 20px; font-weight: 700; margin-top: 10px; }
.inv-card .meta { display: flex; gap: 14px; font-size: 12px; color: var(--text2); margin-top: 4px; flex-wrap: wrap; }
.inv-card .meta b { color: var(--text); font-weight: 700; }
.inv-card.dark { background: var(--dark); border-color: var(--dark); color: #fff; }
.inv-card.dark:hover { border-color: var(--orange); }
.inv-card.dark .kind, .inv-card.dark .meta { color: rgba(255,255,255,.7); }
.inv-card.dark .meta b { color: #fff; }
.inv-card.dark .amt { color: #fff; }
.inv-card .foot { margin-top: 12px; display: flex; gap: 6px; flex-wrap: wrap; }
.inv-card.add { border-style: dashed; align-items: center; justify-content: center; color: var(--muted); font-family: var(--head); font-size: 12px; min-height: 150px; }
.inv-card.add:hover { color: var(--orange); border-color: var(--orange); box-shadow: none; }

/* --- бейджи --- */
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: var(--bg2); color: var(--text2); border: 1px solid transparent; white-space: nowrap; }
.badge .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge.ok { background: var(--green-tint); color: var(--green); }
.badge.warn { background: var(--amber-tint); color: var(--amber); }
.badge.bad { background: var(--red-tint); color: var(--orange2); }
.badge.neutral { background: var(--line3); color: var(--muted); }
.badge.orange { background: var(--orange-tint); color: var(--orange2); }
.badge.dark { background: var(--dark); color: #fff; }
.badge.outline { background: transparent; border-color: var(--line); color: var(--text2); }

/* --- таблицы --- */
.tbl-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
table.tbl th { text-align: left; font-family: var(--head); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 400; padding: 10px 12px; border-bottom: 1px solid var(--dark); white-space: nowrap; }
table.tbl td { padding: 12px; border-bottom: 1px solid var(--line2); vertical-align: middle; }
table.tbl tr:last-child td { border-bottom: 0; }
table.tbl td.num, table.tbl th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.tbl td.num { font-family: var(--head); font-size: 12px; font-weight: 500; }
table.tbl tr.total td { border-top: 1px solid var(--dark); border-bottom: 0; background: var(--bg2); font-weight: 700; }
table.tbl tr.total td.num { font-weight: 700; }
table.tbl tr.click { cursor: pointer; }
table.tbl tr.click:hover td { background: var(--orange-tint2); }
table.tbl .cell-link { color: var(--text); font-weight: 700; }
table.tbl .cell-link:hover { color: var(--orange); }
table.tbl td .sub { font-size: 11px; color: var(--muted); display: block; margin-top: 2px; }
.matrix td.empty { color: var(--line); text-align: center; }
.matrix td.hcell { cursor: pointer; }
.matrix td.hcell:hover { background: var(--orange-tint2); }
.matrix td.hcell .flags { display: flex; gap: 4px; justify-content: flex-end; margin-top: 4px; }
.flag { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.flag.ok { background: var(--green); } .flag.warn { background: #e0a800; } .flag.bad { background: #e53935; } .flag.neutral { background: var(--line); } .flag.pay { background: #29a3e0; }
.legend { display: flex; gap: 16px; font-size: 11px; color: var(--muted); margin-top: 12px; flex-wrap: wrap; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }

/* --- вложение --- */
.holding { border: 1px solid var(--line); border-radius: var(--r); padding: 0; overflow: hidden; background: #fff; }
.holding + .holding { margin-top: 16px; }
.holding .h-head { display: flex; align-items: center; gap: 16px; padding: 18px 24px; background: var(--dark); color: #fff; flex-wrap: wrap; }
.holding .h-head .t { font-family: var(--head); font-size: 16px; font-weight: 600; }
.holding .h-head .t a { color: #fff; }
.holding .h-head .t a:hover { color: var(--orange-tint); }
.holding .h-head .amt { font-family: var(--head); font-size: 18px; font-weight: 700; margin-left: auto; }
.holding .h-head .amt small { font-size: 11px; font-weight: 400; color: rgba(255,255,255,.65); margin-left: 8px; }
.holding .h-body { padding: 20px 24px; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 18px 24px; }
.fact { border-top: 1px solid var(--line2); padding-top: 10px; }
.fact .k { font-family: var(--head); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.fact .v { font-size: 14px; font-weight: 600; }
.fact .v.num { font-size: 16px; font-weight: 700; }
.fact .n { font-size: 12px; color: var(--muted); margin-top: 3px; }
.h-payouts { margin-top: 22px; }
.h-payouts .ph { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.h-payouts .ph h3 { flex: 1; }
.h-actions { display: flex; gap: 8px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line2); flex-wrap: wrap; }
.h-actions .spacer { flex: 1; }
.note { background: var(--bg2); border-radius: var(--r3); padding: 10px 14px; font-size: 13px; color: var(--text2); margin-top: 14px; white-space: pre-wrap; }

/* --- контакты --- */
.contacts { display: flex; gap: 18px; flex-wrap: wrap; font-size: 13px; color: var(--text2); margin-top: 8px; }
.contacts span b { color: var(--muted); font-weight: 600; margin-right: 4px; }

/* --- внимание --- */
.attn { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 10px; }
.attn .it { display: flex; gap: 12px; align-items: center; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--r2); cursor: pointer; transition: border-color .15s; }
.attn .it:hover { border-color: var(--orange); }
.attn .it .ic { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-family: var(--head); font-size: 12px; font-weight: 700; flex-shrink: 0; }
.attn .it .ic.option { background: var(--amber-tint); color: var(--amber); }
.attn .it .ic.custody { background: var(--red-tint); color: var(--orange2); }
.attn .it .ic.date { background: var(--line3); color: var(--muted); }
.attn .it .ic.exp-6m { background: var(--amber-tint); color: var(--amber); font-size: 10px; }
.attn .it .ic.exp-1m { background: var(--red-tint); color: #e53935; font-size: 10px; }
.attn .it .ic.exp-expired { background: #e53935; color: #fff; }

/* --- уведомления о сроках опционов --- */
#notices { max-width: 1600px; margin: 0 auto; padding: 20px 36px 0; display: flex; flex-direction: column; gap: 10px; }
#notices:empty { display: none; }
.notice { border-radius: var(--r2); padding: 12px 18px; display: flex; gap: 18px; align-items: baseline; flex-wrap: wrap; border: 1px solid; }
.notice.warn { background: var(--amber-tint); border-color: #f1d99a; }
.notice.bad { background: var(--red-tint); border-color: #f5b5ad; }
.notice .nt { font-family: var(--head); font-size: 11px; font-weight: 600; display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.notice.warn .nt { color: var(--amber); } .notice.bad .nt { color: #c62828; }
.notice .nt .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.notice .nt .muted { font-family: var(--body); font-weight: 400; }
.notice .nl { display: flex; gap: 8px; flex-wrap: wrap; }
.notice .ni { background: #fff; border-radius: 999px; padding: 4px 12px; font-size: 12px; cursor: pointer; border: 1px solid rgba(0,0,0,.06); }
.notice .ni:hover { border-color: var(--orange); }
@media (max-width: 760px) { #notices { padding: 12px 16px 0; } }
.attn .it .tx { font-size: 13px; }
.attn .it .tx b { display: block; font-weight: 700; }
.attn .it .tx span { color: var(--muted); font-size: 12px; }

/* --- две колонки --- */
.cols { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 1100px) { .cols { grid-template-columns: 1fr; } }
.section { margin-top: 28px; }
.section-head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.section-head h2 { margin: 0; flex: 1; }

/* --- разбивка (дерево) --- */
.bd { display: flex; flex-direction: column; gap: 12px; }
.bd-inv { border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; background: #fff; }
.bd-row { display: grid; grid-template-columns: 22px minmax(140px, 1.2fr) 2fr auto; gap: 14px; align-items: center; cursor: pointer; user-select: none; }
.bd-row .sum, .bd-line .sum, .bd-pay .sum, .bd-grand .sum { font-family: var(--head); font-weight: 700; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.bd-row .tags { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; font-size: 12px; }
.bd-row.l1 { padding: 18px 24px; background: var(--dark); color: #fff; }
.bd-row.l1 .t { font-family: var(--head); font-size: 16px; font-weight: 600; }
.bd-row.l1 .tags { color: rgba(255,255,255,.65); }
.bd-row.l1 .sum { font-size: 18px; }
.bd-row.l1:hover { background: var(--dark2); }
.bd-children { padding: 6px 0 4px; }
.bd-asset { border-bottom: 1px solid var(--line2); }
.bd-row.l2 { padding: 14px 24px 14px 48px; }
.bd-row.l2 .t { font-family: var(--head); font-size: 13px; font-weight: 600; }
.bd-row.l2 .sum { font-size: 14px; }
.bd-row.l2:hover { background: var(--orange-tint2); }
.bd-asset.open > .bd-row.l2 { background: var(--bg2); }
.bd-row.l2.total { cursor: default; background: #fff; border-top: 1px solid var(--dark); margin: 0 24px 0 48px; padding: 12px 0; }
.bd-row.l2.total:hover { background: #fff; }
.bd-row.l2.total .t { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); font-weight: 400; }
.bd-row.l2.total .sum { font-size: 15px; color: var(--orange); }
.chev { width: 10px; height: 10px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); transition: transform .15s; display: inline-block; opacity: .7; justify-self: center; }
.chev.on { transform: rotate(45deg); }
.chev.none { visibility: hidden; }
.bd-detail { padding: 4px 24px 14px 84px; background: var(--bg2); }
.bd-line { display: grid; grid-template-columns: 190px 1fr auto; gap: 14px; align-items: center; padding: 11px 0; border-top: 1px solid var(--line2); }
.bd-line .k { font-family: var(--head); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); display: flex; align-items: center; gap: 10px; }
.bd-line .v { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 13px; }
.bd-line .sum { font-size: 13px; }
.bd-line.click { cursor: pointer; user-select: none; }
.bd-line.click:hover .k { color: var(--orange); }
.bd-payouts { margin-left: 204px; border-left: 2px solid var(--orange); padding-left: 16px; margin-bottom: 4px; }
.bd-pay { display: grid; grid-template-columns: 90px auto 1fr auto 130px; gap: 12px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line2); font-size: 13px; }
.bd-pay .d { font-weight: 700; }
.bd-pay .sum { font-size: 12px; font-weight: 500; }
.bd-pay .acts { opacity: 0; transition: opacity .15s; white-space: nowrap; }
.bd-pay:hover .acts { opacity: 1; }
.bd-pay.add { display: flex; gap: 8px; border-bottom: 0; padding-top: 12px; }
.bd-empty { padding: 10px 24px 10px 48px; display: flex; gap: 6px; font-size: 13px; }
.bd-grand { display: grid; grid-template-columns: minmax(140px, 1.2fr) 2fr auto; gap: 14px; align-items: center; padding: 20px 24px; border-radius: var(--r); background: var(--orange); color: #fff; }
.bd-grand .t { font-family: var(--head); font-size: 14px; font-weight: 600; }
.bd-grand .tags { font-size: 12px; color: rgba(255,255,255,.85); }
.bd-grand .sum { font-size: 20px; }
@media (max-width: 760px) {
  .bd-row { grid-template-columns: 18px 1fr auto; } .bd-row .tags { display: none; }
  .bd-row.l2 { padding-left: 28px; } .bd-detail { padding-left: 28px; } .bd-line { grid-template-columns: 1fr; gap: 4px; }
  .bd-payouts { margin-left: 0; } .bd-opt { grid-template-columns: 1fr; gap: 2px; } .bd-pay { grid-template-columns: 80px 1fr auto; } .bd-pay .c, .bd-pay .acts { display: none; }
  .bd-grand { grid-template-columns: 1fr auto; } .bd-grand .tags { display: none; }
}

.bd-opt { display: grid; grid-template-columns: 190px 1fr; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line2); font-size: 13px; align-items: start; }
.bd-opt .k { font-family: var(--head); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-top: 3px; }
.bd-opt .v { white-space: pre-wrap; font-weight: 600; }
.bd-line.sub { border-top: 0; padding: 2px 0 9px; align-items: start; }
.bd-line.sub .k { padding-left: 14px; font-size: 8px; padding-top: 3px; }
.bd-line.sub .v { white-space: pre-wrap; color: var(--text2); }
.opt-bad { color: #e53935; font-weight: 700; } .opt-warn { color: var(--amber); font-weight: 700; }
.fact .n b { color: var(--text2); font-weight: 700; }

.rate-input { display: flex; align-items: center; border: 1px solid var(--line); border-radius: var(--r3); background: #fff; overflow: hidden; }
.rate-input:focus-within { border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-tint); }
.rate-input input { border: 0; box-shadow: none !important; border-radius: 0; text-align: right; padding-right: 6px; min-width: 0; }
.rate-input .pre { padding-left: 12px; font-family: var(--head); font-size: 12px; font-weight: 600; color: var(--orange); white-space: nowrap; }
.rate-input .post { padding-right: 12px; color: var(--muted); font-size: 13px; white-space: nowrap; }

/* --- справочники --- */
.dict { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0 14px; }
.chip { display: inline-flex; align-items: center; gap: 8px; padding: 6px 8px 6px 14px; border-radius: 999px; border: 1px solid var(--line); font-size: 13px; background: #fff; }
.chip button { border: 0; background: var(--bg2); color: var(--muted); width: 20px; height: 20px; border-radius: 50%; cursor: pointer; font-size: 12px; line-height: 1; padding: 0; }
.chip button:hover { background: var(--orange-tint); color: var(--orange2); }
.chip-add { display: flex; gap: 8px; }
.chip-add input { flex: 1; }

/* --- модалки --- */
.modal-bg { position: fixed; inset: 0; background: rgba(26,23,27,.55); display: flex; align-items: center; justify-content: center; z-index: 50; padding: 20px; backdrop-filter: blur(2px); }
.modal { background: #fff; border-radius: var(--r); padding: 28px 30px; width: 620px; max-width: 100%; max-height: 92vh; overflow: auto; box-shadow: 0 30px 80px rgba(0,0,0,.25); }
.modal.wide { width: 780px; }
.modal h2 { margin-bottom: 4px; }
.modal .lead { color: var(--muted); font-size: 13px; margin-bottom: 18px; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.fields .full { grid-column: 1 / -1; }
.fields .c3 { grid-column: span 1; }
@media (max-width: 640px) { .fields { grid-template-columns: 1fr; } }
.fgroup { grid-column: 1 / -1; font-family: var(--head); font-size: 9px; letter-spacing: .12em; text-transform: uppercase; color: var(--orange); border-bottom: 1px solid var(--line2); padding-bottom: 6px; margin-top: 6px; }
.modal .actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 22px; align-items: center; }
.modal .actions .spacer { flex: 1; }
.err { color: var(--orange2); font-size: 12px; margin-top: 10px; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--dark); color: #fff; padding: 12px 20px; border-radius: 999px; font-size: 13px; z-index: 60; box-shadow: var(--shadow); font-family: var(--head); font-size: 11px; }
.empty { padding: 50px 20px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: var(--r); }
.login { max-width: 380px; margin: 80px auto; }

.search { max-width: 340px; }
.filters { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.filters select { width: auto; }
.money-input { position: relative; }
.money-input input { padding-right: 30px; }
.money-input:after { content: '₽'; position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 13px; }

.file-drop { border: 1px dashed var(--line); border-radius: var(--r2); padding: 18px; text-align: center; color: var(--muted); font-size: 13px; cursor: pointer; }
.file-drop:hover { border-color: var(--orange); color: var(--text); }
.file-drop input { display: none; }
.stat-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }

@media (max-width: 1100px) {
  header.top { gap: 16px; padding: 0 20px; }
  header.top .logo .app { display: none; }
  header.top nav a { padding: 8px 10px; font-size: 10px; }
  header.top .tools .btn { padding: 8px 12px; font-size: 10px; }
}
@media (max-width: 760px) {
  header.top { padding: 0 16px; gap: 12px; height: auto; flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; }
  header.top nav { order: 3; width: 100%; overflow-x: auto; }
  main { padding: 20px 16px 60px; }
  h1 { font-size: 22px; }
  .kpi .v { font-size: 22px; }
  .holding .h-head { padding: 14px 16px; }
  .holding .h-body { padding: 16px; }
  .modal { padding: 22px 18px; }
}
@media print {
  header.top, .btn, .h-actions, .modal-bg { display: none !important; }
  main { padding: 0; }
}
