:root{--navy:#112c45;--navy2:#183d59;--teal:#087f80;--teal-soft:#e3f5f1;--canvas:#f4f7fa;--white:#fff;--border:#e2e9ee;--text:#203748;--muted:#728698;--danger:#c54351;--warning:#c4872f;--ok:#128467;--shadow:0 5px 23px rgba(18,43,67,.06)}
*{box-sizing:border-box}body{margin:0;background:var(--canvas);font:14px/1.5 -apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;color:var(--text)}a{color:var(--teal)}button,input,select,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.5}.layout{display:flex;min-height:100vh}.sidebar{width:250px;background:var(--navy);color:#f4fbff;position:sticky;top:0;height:100vh;flex-shrink:0;overflow-y:auto;display:flex;flex-direction:column}.brand{display:flex;gap:12px;padding:27px 19px 22px;align-items:center;border-bottom:1px solid #ffffff17}.mark{background:#1d887f;color:white;width:39px;height:39px;border-radius:12px;font-size:24px;font-weight:700;display:grid;place-items:center}.brand-name{font-weight:750;letter-spacing:.2px}.brand small{display:block;font-size:11px;color:#a8c3d6}.nav{padding:16px 10px;flex:1}.nav-caption{font-size:10px;letter-spacing:1.2px;color:#8bb0c6;text-transform:uppercase;padding:14px 14px 7px}.nav button{display:flex;align-items:center;gap:11px;width:100%;padding:10px 13px;border:0;border-radius:9px;background:transparent;color:#c9dbe7;text-align:left;margin-bottom:2px}.nav button:hover{background:#ffffff12;color:white}.nav button.active{background:#1a5972;color:#fff;font-weight:650;box-shadow:inset 3px 0 0 #37c0aa}.nav-icon{font-size:16px;min-width:21px;text-align:center}.nav small{font-size:10px;margin-left:auto;color:#a2bacb}.sidefoot{font-size:11px;color:#a9c4d2;padding:16px 20px;border-top:1px solid #ffffff17}.main{min-width:0;flex:1;max-width:100%}.topbar{height:71px;background:#fff;border-bottom:1px solid var(--border);padding:0 32px;display:flex;align-items:center;justify-content:space-between;gap:12px}.location{font-size:12px;color:var(--muted)}.topright{display:flex;align-items:center;gap:13px}.avatar{height:33px;width:33px;border-radius:50%;display:grid;place-items:center;background:var(--teal-soft);color:var(--teal);font-weight:750}.demo-tag{padding:5px 10px;border-radius:7px;border:1px solid #facd93;color:#9b6315;background:#fff7e7;font-size:11px;font-weight:800;letter-spacing:.8px}.page{padding:29px 32px 45px;max-width:1500px;margin:auto}.page-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:24px}.page-head h1{font-size:27px;color:var(--navy);line-height:1.2;margin:0 0 8px;font-weight:800}.desc{font-size:13px;color:var(--muted);margin:0}.actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.btn{border:1px solid var(--border);color:var(--text);background:#fff;padding:9px 14px;border-radius:9px;font-weight:650;display:inline-flex;align-items:center;justify-content:center;gap:8px;white-space:nowrap;min-height:38px}.btn:hover{border-color:#9dbac8;background:#f8fbfd}.btn.primary{color:#fff;background:var(--teal);border-color:var(--teal)}.btn.primary:hover{background:#086e6b}.btn.danger{color:#b53949;border-color:#f0cdd3}.btn.small{padding:6px 10px;min-height:29px;font-size:12px}.btn.ghost{background:transparent;border-color:transparent}.btn:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:3px solid #9cd9ce;outline-offset:2px}.notice{border:1px solid #f3d7a0;color:#7a5725;background:#fffaf0;border-radius:11px;padding:12px 16px;margin:0 0 20px;display:flex;gap:12px;align-items:start;font-size:12px}.notice strong{color:#936115}.kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:20px}.kpi{background:#fff;border:1px solid var(--border);padding:17px 20px;border-radius:13px;box-shadow:var(--shadow)}.kpi small{display:block;color:var(--muted);font-size:12px}.kpi b{font-size:30px;line-height:1.3;display:block;margin:7px 0 3px;color:var(--navy)}.kpi .sub{font-size:11px;color:var(--muted)}.split{display:grid;grid-template-columns:1.45fr 1fr;gap:18px;align-items:start}.panel{background:#fff;border-radius:13px;border:1px solid var(--border);box-shadow:var(--shadow);margin-bottom:17px;min-width:0}.panel-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:17px 19px;border-bottom:1px solid var(--border)}.panel-head h2{margin:0;font-size:16px;color:var(--navy)}.panel-body{padding:19px}.panel-note{font-size:12px;color:var(--muted)}.tablewrap{overflow:auto;max-width:100%}table{border-collapse:collapse;width:100%;text-align:left;font-size:12px;min-width:650px}thead{background:#f7f9fb}th{font-size:11px;color:#728397;font-weight:750;white-space:nowrap;text-transform:none}th,td{padding:11px 13px;border-bottom:1px solid #edf0f3;vertical-align:middle}tbody tr:last-child td{border-bottom:0}tbody tr:hover{background:#f9fbfc}td.primarycell{font-weight:650;max-width:390px}.smallmuted{display:block;color:var(--muted);font-size:11px;font-weight:450;margin-top:3px}.num{font-variant-numeric:tabular-nums;text-align:right;white-space:nowrap}.tag{display:inline-block;border-radius:6px;padding:3px 7px;font-size:10px;font-weight:750;line-height:1.4;background:#eff3f6;color:#53697b;white-space:nowrap}.tag.red{background:#fff0f1;color:#b33d4b}.tag.green{background:#e7f7f0;color:#0b8260}.tag.amber{background:#fff4de;color:#a56f1b}.tag.blue{background:#e9f3fa;color:#2c779e}.pillpack{display:inline-block;background:#edf5f9;color:#2d6c85;border-radius:6px;padding:2px 5px;font-size:10px;margin:2px 2px 0 0}.filters{display:flex;gap:9px;padding:16px 19px;flex-wrap:wrap;align-items:center;border-bottom:1px solid var(--border)}.filters input,.filters select{min-height:38px;border-radius:8px;border:1px solid #dce6ec;padding:7px 10px;background:#fff;min-width:140px;color:var(--text)}.filters input{min-width:230px;flex:1;max-width:450px}.meter{height:7px;background:#e9f0f4;border-radius:20px;overflow:hidden;min-width:70px;flex:1}.meter span{height:100%;display:block;background:#119a8e;border-radius:20px}.measure{display:flex;align-items:center;gap:10px;min-width:140px}.measure strong{min-width:35px;text-align:right;font-size:11px}.deptgrid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:13px}.dept-card{background:white;border:1px solid var(--border);border-radius:12px;padding:18px;cursor:pointer;text-align:left;min-height:126px}.dept-card:hover{border-color:#81c6c0;box-shadow:var(--shadow)}.dept-card h3{margin:0 0 7px;font-size:14px;color:var(--navy)}.dept-card .metric{margin-top:14px;display:flex;justify-content:space-between;font-size:12px}.dept-card .metric b{font-size:16px}.empty{padding:30px;text-align:center;color:var(--muted);font-size:13px}.empty strong{display:block;color:var(--navy);margin-bottom:6px}.footnote{color:var(--muted);font-size:11px;padding:12px 19px;border-top:1px solid #edf0f3}.detail-title{font-size:18px;font-weight:800;color:var(--navy);line-height:1.35}.info-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:9px;margin:14px 0}.info-grid>div{padding:13px 10px;border:1px solid var(--border);border-radius:9px;text-align:center}.info-grid b{display:block;font-size:23px;color:var(--navy)}.info-grid small{color:var(--muted);font-size:10px}.info-grid .alert{border-color:#f0c5c9;background:#fff8f8}.alert b{color:var(--danger)}.kv{display:grid;grid-template-columns:145px 1fr;gap:9px 18px;padding:14px 0;border-bottom:1px solid #edf0f2}.kv dt{color:var(--muted);font-size:12px}.kv dd{margin:0;font-size:12px;word-break:break-word}.forms{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px}.field{display:flex;flex-direction:column;gap:5px}.field.full{grid-column:1/-1}.field label{font-size:11px;font-weight:750;color:#4b6374}.field input,.field textarea,.field select{background:#fff;border:1px solid #dbe4ea;border-radius:8px;padding:9px 11px;width:100%;min-height:39px;color:var(--text)}.field textarea{min-height:75px;resize:vertical}.field .help{font-size:10px;color:var(--muted)}.checkline{display:flex;gap:9px;align-items:flex-start;font-size:12px;margin:6px 0}.checkline input{margin-top:3px;accent-color:var(--teal)}.dialog-back{position:fixed;inset:0;background:#0c233bb0;display:flex;justify-content:center;align-items:center;padding:22px;z-index:10}.dialog{width:min(850px,100%);max-height:94vh;overflow:auto;background:#fff;border-radius:16px;box-shadow:0 24px 85px #0004}.dialog-head{padding:18px 22px;border-bottom:1px solid var(--border);display:flex;align-items:start;justify-content:space-between;gap:16px;position:sticky;top:0;background:#fff;z-index:1}.dialog-head h2{font-size:19px;color:var(--navy);margin:0 0 4px}.dialog-content{padding:18px 22px}.dialog-footer{padding:15px 22px;display:flex;justify-content:flex-end;gap:9px;border-top:1px solid var(--border);position:sticky;bottom:0;background:#fff}.status-bubble{font-size:12px;border-left:3px solid #f0c780;background:#fff8e9;padding:9px 11px;margin:12px 0}.subtabs{display:flex;gap:2px;flex-wrap:wrap;margin:0 0 16px;border-bottom:1px solid var(--border)}.subtabs button{border:0;background:transparent;padding:12px 13px;border-bottom:2px solid transparent;color:var(--muted);font-weight:650}.subtabs button.active{color:var(--teal);border-color:var(--teal)}.steps{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.step{border:1px solid var(--border);border-radius:10px;padding:14px}.step b{display:block;font-size:13px;margin-bottom:5px}.step small{font-size:11px;color:var(--muted)}.center-note{border:1px dashed #9dcac6;padding:14px;color:#356b74;background:#f5fcfb;border-radius:10px;margin:14px 0;font-size:12px}#toast{position:fixed;bottom:22px;right:24px;background:var(--navy);color:#fff;padding:12px 18px;border-radius:10px;box-shadow:0 8px 24px #0003;opacity:0;pointer-events:none;transform:translateY(10px);transition:all .18s;z-index:999;max-width:390px}#toast.show{opacity:1;transform:translateY(0)}.pt{padding:0 0 12px;margin:0;font-size:14px;color:var(--navy);font-weight:750}.sim{color:var(--teal);border:1px solid #b7d7d3;padding:11px;border-radius:10px;background:#f4fcfa}.banner-login{border-left:3px solid var(--teal);background:#f6fbfd;padding:13px 16px;border-radius:9px;font-size:12px}.count{font-variant-numeric:tabular-nums}.muted{color:var(--muted)}.dangertext{color:var(--danger)}.quickchips{display:flex;gap:7px;flex-wrap:wrap}.quickchips button{font-size:11px;padding:5px 9px;border:1px solid #d4e7e7;border-radius:7px;background:#f8fdfc;color:#22736e}.inline-flex{display:flex;align-items:center;gap:9px;flex-wrap:wrap}.progress-lines{display:grid;gap:11px}.progress-item{display:grid;grid-template-columns:1fr 155px 42px;gap:12px;align-items:center;font-size:12px}.heading-secondary{font-size:13px;color:var(--navy);font-weight:800;margin:0 0 12px}@media(max-width:1150px){.kpis{grid-template-columns:repeat(2,1fr)}.deptgrid{grid-template-columns:repeat(2,1fr)}.split{grid-template-columns:1fr}.sidebar{width:218px}.page{padding:22px 19px}.topbar{padding:0 19px}}@media(max-width:760px){.layout{display:block}.sidebar{width:100%;height:auto;position:relative}.brand{padding:12px 16px}.nav{display:flex;gap:4px;overflow:auto;padding:5px 10px}.nav-caption,.sidefoot{display:none}.nav button{white-space:nowrap;width:auto;flex-shrink:0}.main{width:100%}.topbar{height:58px}.location{display:none}.page-head{display:block}.page-head .actions{margin-top:15px}.deptgrid{grid-template-columns:1fr}.kpis{grid-template-columns:1fr 1fr}.info-grid{grid-template-columns:repeat(3,1fr)}.forms{grid-template-columns:1fr}.field.full{grid-column:auto}.steps{grid-template-columns:1fr}.progress-item{grid-template-columns:1fr}.filters input{min-width:100%}}
@media print{.sidebar,.topbar,.actions,.filters,.btn,.notice,#toast{display:none!important}.page{padding:0}.panel,.kpi{box-shadow:none}.main{width:100%}.dialog-back{display:none}body{background:#fff}}

/* Version 0.2: executive view and role simulation */
.role-label{font-size:11px;color:var(--muted);font-weight:650}.role-switch{border:1px solid #cfe0e7;border-radius:9px;background:#f7fbfd;color:var(--navy);font-weight:700;font-size:12px;padding:8px 10px;max-width:210px}.role-switch:focus{outline:2px solid #88cfc3}.navcounter{background:#248f8e;border-radius:9px;color:#fff!important;padding:1px 7px;font-weight:800}.lead-request{border-bottom:1px solid var(--border);padding:9px 0;display:grid;gap:2px;font-size:12px}.lead-request:last-child{border-bottom:0}.lead-request span{font-size:12px}.approval-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}.role-panel{border:1px solid var(--border);background:#fff;padding:18px;border-radius:12px}.role-panel h2{margin:0 0 6px}.reqcheck,#selectAllReq{accent-color:var(--teal);width:15px;height:15px}.role-notice{background:#eef8f8;border:1px solid #b8dedc;border-radius:8px;padding:12px}.topright{flex-wrap:wrap;justify-content:flex-end}@media(max-width:950px){.role-label{display:none}.role-switch{max-width:170px}}

/* Історія рішень у демоверсії 0.2.1 */
.decision-history{margin-top:8px;max-width:270px;font-size:12px;color:var(--muted,#667788)}
.decision-history summary{cursor:pointer;white-space:nowrap}
.decision-history small{display:block;padding:3px 0;white-space:normal}

/* Версія 0.2.2 — попередні нестачі окремо від підтверджених */
.preview-panel{border-color:#efcf9c} .preview-panel .panel-head{background:#fff8ec;border-radius:13px 13px 0 0} .preliminary-number{color:#9d6c16;font-weight:800;font-size:13px}.center-note{margin:12px 18px}

/* v0.2.3: заявки завідувача та технічний стан */
.return-reason{color:#a35f20;background:#fff6e8;padding:5px 7px;border-radius:5px;font-weight:650}
.panel .tablewrap td .btn + .btn{margin-left:4px}

/* v0.2.4 — інфраструктура й альтернативні варіанти оснащення */
.presence-card{border:1px solid var(--border);border-radius:12px;padding:17px 18px;margin:15px 0;background:#fbfdff}
.presence-card h3{font-size:15px;color:var(--navy);margin:0 0 12px}
.presence-card .inline-flex{margin:12px 0;align-items:center}
.presence-card .forms{margin:6px 0 14px}
.norm-source{padding:12px 0;color:var(--muted)}
.norm-source summary{cursor:pointer;color:#26766e;font-weight:700}
.review-hint{display:block;color:#a3701d;font-size:11px;margin-top:4px}

/* v0.2.5: прозора перевірка зарахування обладнання */
.asset-preview-actions{display:flex;flex-wrap:wrap;gap:8px;margin:14px 0 8px}
.asset-preview-actions .btn{white-space:normal;text-align:left}
#assetCountPreview{border-left-color:#d4a44f;background:#fff9ed}
#assetCountPreview.eligibility-good{border-left-color:#149476;background:#effaf5;color:#16664c}
/* Needs: selected department sets, departmental/detail views and export controls */
.need-quickrow{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.need-one{font-size:11px;color:var(--muted);display:flex;align-items:center;gap:6px}.need-one select{border:1px solid var(--border);border-radius:8px;padding:9px 10px;max-width:270px;background:white;color:var(--text)}.need-picker{border:1px solid #dfe9eb;border-radius:11px;margin:16px 0;background:#fafdfd}.need-picker summary{cursor:pointer;padding:11px 14px;font-size:12px;color:var(--navy);font-weight:650}.need-picker summary b{color:var(--teal)}.need-checkgrid{padding:10px 13px 14px;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;border-top:1px solid #e1ebee}.need-check{padding:9px 10px;background:#fff;border-radius:7px;border:1px solid #e4ebed;display:flex;align-items:start;gap:7px;font-size:12px;cursor:pointer}.need-check:hover{border-color:#80b8b6;background:#f6fbfa}.need-check input{margin-top:2px;accent-color:var(--teal);flex-shrink:0}.need-exportinfo{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}.need-exportinfo>span{font-size:11px;color:var(--muted);flex:1;min-width:230px}.need-tabs{display:flex;flex-wrap:wrap;border-bottom:1px solid var(--border);gap:4px;padding:0 14px}.need-tabs button{border:0;background:transparent;padding:12px 14px;font-weight:700;color:var(--muted);border-bottom:3px solid transparent;font-size:12px}.need-tabs button.active{color:var(--teal);border-color:var(--teal)}.need-table{min-width:950px}.need-table th,.need-table td{padding:11px 10px}.need-table td:nth-last-child(-n+6){font-variant-numeric:tabular-nums}.need-controls .panel-body{padding:16px 19px}@media(max-width:1150px){.need-checkgrid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:760px){.need-checkgrid{grid-template-columns:1fr}.need-one{width:100%;justify-content:space-between}.need-one select{width:65%}.need-exportinfo .btn{width:100%}}

/* v0.2.8: реєстр — структуровані кількісні дані та облік списання */
.registry-filter{padding:11px 18px;display:flex;align-items:center;gap:11px;flex-wrap:wrap;border-bottom:1px solid var(--border);background:#fafdfd}.registry-filter label{font-size:12px;font-weight:700;color:var(--navy)}.registry-filter select{border:1px solid #d8e4ea;border-radius:8px;padding:9px 10px;background:white;min-width:265px;color:var(--navy);font-size:12px}
.registry-wrap{max-width:100%;overflow-x:auto;scrollbar-gutter:stable}.registry-table{min-width:1550px;border-collapse:separate;border-spacing:0}.registry-table th,.registry-table td{padding:11px 9px;font-size:11px;vertical-align:middle}.registry-table th{white-space:normal;line-height:1.25;min-width:88px}.registry-table th.num{min-width:98px}.registry-table td.num{font-size:12px;font-variant-numeric:tabular-nums;white-space:nowrap}.registry-table .sticky-name{position:sticky;left:0;z-index:2;min-width:280px;max-width:325px;background:#fff;box-shadow:2px 0 4px #15344c0b}.registry-table thead .sticky-name{z-index:3;background:#f1f5f8}.registry-table tbody tr:nth-child(even) .sticky-name{background:#f8fafb}.registry-table .primarycell{white-space:normal;line-height:1.35}.registry-table .smallmuted{font-size:10px}.registry-table tr:hover .sticky-name{background:#f0f8f8}.numvalue{color:var(--navy);font-weight:650}
.asset-summary{grid-template-columns:repeat(5,1fr)}.asset-summary>div{min-width:0}.asset-summary small{overflow-wrap:anywhere}.asset-summary b{font-size:21px}
@media(max-width:1100px){.asset-summary{grid-template-columns:repeat(3,1fr)}}@media(max-width:650px){.asset-summary{grid-template-columns:repeat(2,1fr)}.registry-filter select{width:100%}}

/* Зведені таблиці потреби мають окрему прокрутку, без звуження числових колонок */
.need-table{min-width:1370px}.need-table td.num,.need-table th.num{white-space:nowrap}

/* v0.2.9 — реєстр без горизонтальної прокрутки; деталі залишаються в картках */
.registry-wrap{max-width:100%;overflow-x:hidden;overflow-y:visible;scrollbar-gutter:auto}
.registry-table{width:100%;min-width:0!important;table-layout:fixed;border-collapse:collapse}
.registry-table th,.registry-table td{min-width:0!important;max-width:none!important;padding:9px 4px;font-size:10.5px;line-height:1.3;overflow-wrap:anywhere;word-break:normal;vertical-align:middle}
.registry-table th{font-size:10px;white-space:normal;line-height:1.2;text-align:center}
.registry-table th:first-child{text-align:left;padding-left:13px}
.registry-table td.num{white-space:normal;font-size:12px;text-align:center;font-weight:700}
.registry-table .registry-name{position:static;min-width:0;max-width:none;padding-left:13px;box-shadow:none;text-align:left;white-space:normal}
.registry-table .registry-name .smallmuted{font-size:9.5px;line-height:1.35;overflow-wrap:break-word}
.registry-table .registry-meta{color:#75909c}
.registry-open{padding:0;border:0;background:transparent;color:var(--navy);font-weight:750;text-align:left;line-height:1.35;font-size:11px;white-space:normal;overflow-wrap:anywhere}
.registry-open span{color:var(--teal);font-weight:800;white-space:nowrap}
.registry-open:hover{text-decoration:underline;text-decoration-color:var(--teal)}
.registry-open:focus-visible{outline:3px solid #9cd9ce;outline-offset:3px;border-radius:3px}
.registry-check{text-align:center}
.registry-check .tag{white-space:normal;max-width:100%;padding:3px 4px;font-size:9px;line-height:1.2}
.registry-table tbody tr:nth-child(even){background:#fafcfd}
.registry-table tbody tr:hover{background:#eff8f7}
.registry-table tbody tr:nth-child(even) .registry-name{background:transparent}
.registry-table tbody tr:hover .registry-name{background:transparent}
.registry-table td[data-label]::before{display:none}
@media(max-width:1250px){
 .registry-table colgroup,.registry-table thead{display:none}
 .registry-table,.registry-table tbody{display:block;width:100%;min-width:0}
 .registry-table tr.registry-row{display:grid;grid-template-columns:repeat(9,minmax(0,1fr));margin:10px 12px;border:1px solid #dfe8ec;border-radius:10px;overflow:hidden;background:#fff!important}
 .registry-table tr.registry-row td{border:0;border-right:1px solid #edf1f4;padding:8px 3px;min-width:0;font-size:12px;text-align:center;align-self:stretch}
 .registry-table tr.registry-row td:last-child{border-right:0}
 .registry-table tr.registry-row .registry-name{grid-column:1/-1;text-align:left;padding:10px 13px;border-bottom:1px solid #eaf0f2;background:#f8fbfc!important}
 .registry-table .registry-open{font-size:12.5px}
 .registry-table .registry-name .smallmuted{display:inline;margin-right:12px;font-size:10px}
 .registry-table td[data-label]::before{content:attr(data-label);display:block;color:var(--muted);font-size:9px;font-weight:650;line-height:1.2;min-height:26px;margin-bottom:4px;overflow-wrap:anywhere}
 .registry-table td.num{white-space:normal}
 .registry-table .registry-check .tag{font-size:9px}
}
@media(max-width:900px){
 .registry-table tr.registry-row{grid-template-columns:repeat(3,minmax(0,1fr))}
 .registry-table tr.registry-row td:nth-child(3n+1){border-right:0}
 .registry-table td[data-label]::before{min-height:0}
 .registry-table .registry-check{grid-column:auto}
}
@media print{.registry-table{table-layout:fixed}.registry-wrap{overflow:visible}.registry-table tr{break-inside:avoid}}
/* Назва завжди окремим рядком, щоб довгі найменування не зливалися з метаданими. */
.registry-open{display:block;width:100%}
.kpi.clickable{width:100%;text-align:left;cursor:pointer;position:relative}
.kpi.clickable:hover{border-color:#8ebdc9;background:#f9fcff}
.kpi.clickable.active{border-color:#7ab7c6;background:#f7fbfd}
.kpi-more{display:inline-block;margin-top:10px;font-size:11px;color:#2e6f87;font-weight:700}
.kpi-info-panel{margin-top:-6px}

/* v0.3.4: узгоджене зведення дефіциту без підміни неперевірених даних нулями */
.deficit-summary-table{min-width:550px}
.deficit-totals{background:#f5fafb}
.deficit-totals td{border-top:2px solid #c9dce3}
.deficit-unentered{padding:0 19px 18px}
.deficit-unentered summary{cursor:pointer;font-weight:700;color:#1b6682;padding:10px 0}
.deficit-unentered-scroll{max-height:380px;overflow:auto;border:1px solid #e2eaf0;border-radius:9px}
.deficit-caution{margin:14px 19px}

.shortage-mini-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.shortage-mini-grid>div{padding:12px 14px;border-radius:9px;background:#f6fafb}
.shortage-mini-grid small{display:block;font-size:11px;color:#667e90}
.shortage-mini-grid strong{display:block;font-size:14px;color:#153951;margin-top:5px}
.shortage-mini-grid p{grid-column:1/-1;margin:0;color:#687d8c;font-size:12px}
@media(max-width:690px){.shortage-mini-grid{grid-template-columns:1fr}}

/* v0.3.5: distinguish calculated positions from positions with actual deficit. */
.deficit-position-count{display:flex;flex-direction:column;gap:3px;min-width:185px}
.deficit-position-count strong{font-size:12px;color:var(--navy)}
.deficit-position-count small{font-size:11px;color:var(--muted);line-height:1.45}
.deficit-summary-table th:last-child,.deficit-summary-table td:last-child{text-align:left}
@media(max-width:750px){.deficit-position-count{min-width:150px}}

/* v0.3.6: деталізація карток з кількістю нестачі. */
.deficit-breakdown{border-color:#b7d7df;margin-top:-5px}
.deficit-breakdown .panel-head h2{font-size:16px}
.breakdown-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;padding:13px 18px;border-bottom:1px solid var(--border)}
.breakdown-summary>div{background:#f4f9fb;border-radius:9px;padding:10px 14px}
.breakdown-summary small{display:block;font-size:11px;color:var(--muted)}
.breakdown-summary strong{display:block;margin-top:3px;font-size:20px;color:var(--navy)}
.breakdown-table{width:100%;min-width:850px}
.breakdown-table th,.breakdown-table td{padding:11px 9px}
.breakdown-table .shortage-highlight{font-weight:800;color:#a46113;font-size:15px}
.deficit-kpis .kpi-more{margin-top:7px}
@media(max-width:520px){.breakdown-summary{grid-template-columns:1fr}.breakdown-table{min-width:800px}}
