/* mobile + salary/object usability */
.header-main{display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0}
header h1{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.mobile-menu-toggle{display:inline-flex;align-items:center;justify-content:center;min-width:42px;min-height:42px;font-size:20px;flex:0 0 auto}
.site-sidebar-overlay{position:fixed;inset:0;background:rgba(15,23,42,.34);z-index:84;opacity:0;pointer-events:none;transition:opacity .2s ease}
.site-sidebar-overlay.show{opacity:1;pointer-events:auto}
.site-sidebar{position:fixed;left:0;top:0;bottom:0;width:min(330px,88vw);background:#fff;z-index:85;box-shadow:10px 0 30px rgba(15,23,42,.18);transform:translateX(-105%);transition:transform .22s ease;display:flex;flex-direction:column}
.site-sidebar.show{transform:translateX(0)}
.site-sidebar-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:18px 16px;border-bottom:1px solid #e4e7eb;background:#0f3460;color:#fff}
.site-sidebar-head strong{font-size:18px;letter-spacing:.02em}
.site-sidebar-brand{display:flex;flex-direction:column;align-items:flex-start;gap:3px;min-width:0;line-height:1.15}
.site-sidebar-brand-name{display:block;font-size:20px;font-weight:800;letter-spacing:.05em}
.site-sidebar-brand-tagline{display:block;font-size:10px;font-weight:600;letter-spacing:.1em;white-space:nowrap}
.site-sidebar-close{border:0;background:rgba(255,255,255,.15);color:#fff;border-radius:7px;min-width:36px;min-height:36px;font-size:22px;cursor:pointer}
.site-sidebar-nav{padding:12px;overflow:auto;flex:1}
.sidebar-group{display:none;border-bottom:1px solid #eef0f3;padding:6px 0}
.sidebar-group.visible{display:block}
.sidebar-group-toggle{width:100%;border:0;background:transparent;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px 10px;border-radius:8px;color:#16213e;font-size:15px;font-weight:700;text-align:left;cursor:pointer}
.sidebar-group-toggle:hover{background:#f3f6fa}
.sidebar-group-toggle .arrow{transition:transform .18s ease;color:#667085}
.sidebar-group.open .sidebar-group-toggle .arrow{transform:rotate(90deg)}
.sidebar-submenu{display:none;padding:0 4px 8px 10px}
.sidebar-group.open .sidebar-submenu{display:grid;gap:4px}
.site-sidebar .tab-btn{display:block;width:100%;padding:10px 12px;border:0;border-radius:7px;background:transparent;text-align:left;color:#475467;font-size:14px;cursor:pointer}
.site-sidebar .tab-btn:hover{background:#f5f7fa;color:#0f3460}
.site-sidebar .tab-btn.active{background:#eaf2fb;color:#0f3460;font-weight:700}
.site-sidebar-foot{border-top:1px solid #e4e7eb;padding:12px 16px;background:#fafbfc}
.site-sidebar-user{font-size:12px;color:#475467;margin-bottom:8px}
.site-sidebar-actions{display:flex;gap:6px;flex-wrap:wrap}
.site-sidebar-actions button{border:0;border-radius:6px;padding:7px 9px;font-size:12px;cursor:pointer}
.site-sidebar-actions .logout{background:#fee4e2;color:#b42318}
.tabs{display:none!important}
.module-placeholder{min-height:260px;display:flex;align-items:center;justify-content:center}
.module-placeholder-inner{max-width:620px;text-align:center;padding:28px}
.module-placeholder-inner h2{margin-bottom:10px;color:#16213e}
.module-placeholder-inner p{color:#667085;line-height:1.5}
.deals-toolbar{display:flex;justify-content:space-between;gap:14px;align-items:flex-start;flex-wrap:wrap;margin-bottom:14px}
.deals-toolbar h2{margin:0 0 4px}
.deals-toolbar p{font-size:12px;color:#667085;max-width:760px;line-height:1.45}
.deals-actions{display:flex;gap:7px;flex-wrap:wrap;align-items:center}
.deals-import-org{min-width:190px;display:none}
.deals-filters{display:grid;grid-template-columns:minmax(280px,1.6fr) repeat(3,minmax(170px,.8fr));gap:10px;margin:12px 0}
.deals-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:12px 0}
.deals-summary-item{padding:12px;border:1px solid #e4e7eb;border-radius:9px;background:#fafbfc}
.deals-summary-item.emphasis{background:#fffdf5;border-color:#f3df9a}.deals-summary-item.result{background:#f4fbf7;border-color:#ccebd8}
.deals-summary-item label{display:block;font-size:11px;color:#667085;margin-bottom:4px}
.deals-summary-item b{font-size:17px;color:#16213e}
.deal-control-note{font-size:12px;color:#475467;line-height:1.5;padding:10px 12px;border:1px solid #e4e7eb;border-radius:9px;background:#f8fafc;margin:10px 0}
.deals-table-wrap{overflow:auto;border:1px solid #e4e7eb;border-radius:10px}
#dealsTable{min-width:1180px;margin:0}
#dealsTable th{position:sticky;top:0;z-index:2;background:#f8fafc;white-space:nowrap}
#dealsTable td{vertical-align:top;padding:11px 9px}
.deal-title{display:grid;gap:3px;min-width:190px}.deal-title>b{font-size:11px;color:#667085}.deal-title>strong{font-size:13px;color:#101828}.deal-title>span{font-size:11px;color:#667085;max-width:260px;white-space:normal}
.deal-money-main{font-size:13px;font-weight:800;color:#101828;white-space:nowrap}.deal-money-positive{color:#067647}.deal-money-negative{color:#b42318}
.deal-finance-badge{display:inline-flex;padding:3px 8px;border-radius:999px;font-size:10px;font-weight:800;white-space:nowrap}
.deal-finance-badge.good{background:#dcfce7;color:#166534}.deal-finance-badge.info{background:#eaf2ff;color:#175cd3}.deal-finance-badge.warning{background:#fef0c7;color:#b54708}.deal-finance-badge.danger{background:#fee4e2;color:#b42318}
.deal-progress{height:5px;border-radius:99px;background:#e4e7ec;overflow:hidden;margin-top:7px;min-width:115px}.deal-progress>span{display:block;height:100%;background:#12b76a;border-radius:99px}.deal-progress-label{font-size:9px;color:#667085;margin-top:3px}
.deal-row-actions{display:flex;gap:5px;flex-wrap:wrap;min-width:125px}
.deal-finance-snapshot{display:grid;grid-template-columns:repeat(6,minmax(120px,1fr));gap:8px;margin-bottom:10px}.deal-finance-snapshot>div{padding:9px;border:1px solid #e4e7ec;border-radius:8px;background:#fff}.deal-finance-snapshot label{display:block;font-size:10px;color:#667085;margin-bottom:3px}.deal-finance-snapshot b{font-size:12px;color:#101828}.deal-finance-snapshot b.negative{color:#b42318}
.deal-detail-quick{display:flex;gap:6px;flex-wrap:wrap;margin:8px 0 12px}
.deal-main-row.status-quiet td{background:#f8fafc}.deal-main-row.status-quiet td:first-child{border-left:5px solid #98a2b3}
.deal-main-row.status-current td{background:#ecfeff}.deal-main-row.status-current td:first-child{border-left:5px solid #06b6d4}
.deal-main-row.status-attention td{background:#fffbea}.deal-main-row.status-attention td:first-child{border-left:5px solid #facc15}
.deal-main-row.status-urgent td{background:#fff1f1}.deal-main-row.status-urgent td:first-child{border-left:5px solid #ef4444}
.deal-main-row.status-completed td{background:#eefcf2}.deal-main-row.status-completed td:first-child{border-left:5px solid #16a34a}
.deal-main-row:hover td{filter:brightness(.985)}
.deal-status{display:inline-flex;align-items:center;padding:3px 8px;border-radius:999px;font-size:11px;font-weight:700;white-space:nowrap}
.deal-status.quiet{background:#f2f4f7;color:#475467}.deal-status.current{background:#cffafe;color:#155e75}.deal-status.attention{background:#fef9c3;color:#854d0e}.deal-status.urgent{background:#fee2e2;color:#991b1b}.deal-status.completed{background:#dcfce7;color:#166534}
.deal-inline-status{min-width:150px;padding:6px 8px;border:1px solid rgba(71,84,103,.28);border-radius:6px;background:rgba(255,255,255,.78);font-size:12px}
.deal-inline-number{width:128px;padding:6px 7px;border:1px solid rgba(71,84,103,.28);border-radius:6px;background:rgba(255,255,255,.82);font-size:12px}
.deal-cell-stack{display:grid;gap:5px;min-width:125px}
.deal-cell-meta{font-size:11px;color:#475467}
.deal-cell-add{justify-self:start;padding:3px 7px!important;font-size:11px!important}
.counterparty-toolbar{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:14px}
.counterparty-toolbar h2{margin:0 0 4px}.counterparty-toolbar p{font-size:12px;color:#667085}
.counterparty-search{width:min(520px,100%);margin:0 0 12px}
.counterparty-table-wrap{overflow:auto;border:1px solid #e4e7eb;border-radius:10px}
#counterpartiesTable{min-width:1050px;margin:0}
.counterparty-type{display:inline-block;padding:3px 8px;border-radius:999px;background:#eef4ff;color:#3538cd;font-size:11px;font-weight:700}
.counterparty-card-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.counterparty-contact-row{display:grid;grid-template-columns:1.2fr 1fr 1fr 1.2fr auto;gap:7px;align-items:end;margin:7px 0;padding:9px;border:1px solid #eaecf0;border-radius:8px;background:#fafbfc}
.counterparty-contact-row .form-group{margin:0}
.object-customer-line{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:7px;align-items:center}
.kpss-toolbar{display:flex;gap:8px;align-items:end;flex-wrap:wrap;margin:12px 0}
.kpss-toolbar .form-group{margin:0;min-width:150px}
.kpss-health{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:14px 16px;border:1px solid #d0d5dd;border-left:5px solid #98a2b3;border-radius:10px;background:#f8fafc;margin:12px 0}.kpss-health>div{min-width:180px}.kpss-health span{display:block;font-size:10px;color:#667085;text-transform:uppercase;letter-spacing:.04em}.kpss-health b{display:block;font-size:20px;color:#344054;margin-top:3px}.kpss-health p{margin:0;font-size:12px;color:#475467;line-height:1.45}.kpss-health.good{border-left-color:#12b76a;background:#f2fbf6}.kpss-health.warning{border-left-color:#f79009;background:#fffaf0}.kpss-health.danger{border-left-color:#d92d20;background:#fff5f4}
.kpss-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:12px 0}
.kpss-summary-item{padding:12px;border:1px solid #dce4ef;border-radius:9px;background:#f8fafc}.kpss-summary-item.primary{background:#f2fbf6;border-color:#b7e5ca}
.kpss-summary-item label{display:block;font-size:11px;color:#667085;margin-bottom:4px}.kpss-summary-item b{font-size:18px;color:#16213e}.kpss-summary-item small{display:block;font-size:9px;color:#98a2b3;margin-top:4px}
.kpss-table-wrap{overflow:auto;border:1px solid #dfe5ec;border-radius:10px;background:#fff}
.kpss-table{min-width:1700px;margin:0;border-collapse:separate;border-spacing:0}
.kpss-table th,.kpss-table td{padding:8px 9px;border-right:1px solid #edf0f3;border-bottom:1px solid #edf0f3;text-align:right;white-space:nowrap;font-size:12px}
.kpss-table thead th{position:sticky;top:0;z-index:3;background:#16213e;color:#fff;text-align:center}
.kpss-table th:first-child,.kpss-table td:first-child{position:sticky;left:0;z-index:2;text-align:left;min-width:315px;max-width:315px;white-space:normal}
.kpss-table thead th:first-child{z-index:4;background:#16213e}
.kpss-table tbody td:first-child{background:#fff}
.kpss-table tr.kpss-section td{background:#eef4fb!important;color:#344054;font-weight:700;text-align:left;border-top:1px solid #cfd9e6}
.kpss-table tr.kpss-subtotal td{font-weight:700;background:#f8fafc}
.kpss-table tr.kpss-total td{font-weight:800;background:#f0fdf4}
.kpss-table tr.kpss-movement-total td{font-weight:800;background:#fff7ed}
.kpss-table td.negative{color:#b42318;font-weight:700}
.kpss-value-btn{display:block;width:100%;border:0;background:transparent;padding:0;margin:0;color:inherit;font:inherit;font-weight:inherit;text-align:right;cursor:pointer;border-radius:5px}
.kpss-value-btn:hover,.kpss-value-btn:focus-visible{background:#eef4ff;outline:2px solid #b2ccff;outline-offset:2px}
.kpss-detail-total{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 14px;margin:10px 0 12px;border:1px solid #d0d5dd;border-radius:9px;background:#f8fafc}
.kpss-detail-total span{font-size:12px;color:#667085}.kpss-detail-total b{font-size:20px;color:#16213e}
.kpss-detail-body{max-height:520px;overflow:auto;border:1px solid #e4e7ec;border-radius:9px;background:#fff}
.kpss-detail-row{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;padding:10px 12px;border-bottom:1px solid #eef0f3}
.kpss-detail-row:last-child{border-bottom:0}.kpss-detail-row b{font-size:12px;color:#344054}.kpss-detail-row strong{font-size:13px;white-space:nowrap;color:#101828}
.kpss-detail-row strong.negative{color:#b42318}.kpss-detail-meta{font-size:10px;color:#667085;margin-top:3px}.kpss-detail-empty{padding:18px;color:#667085;text-align:center;font-size:12px}
.kpss-row-label{display:flex;gap:7px;align-items:center;justify-content:space-between}
.kpss-source{font-size:9px;padding:2px 5px;border-radius:999px;background:#eef4ff;color:#3538cd;font-weight:700;flex:0 0 auto}
.kpss-source.manual{background:#fff4e5;color:#b54708}
.kpss-source.mixed{background:#ecfdf3;color:#067647}
.kpss-hint{font-size:12px;color:#667085;line-height:1.5;margin:8px 0 12px}
.kpss-edit-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.kpss-edit-section{grid-column:1/-1;margin-top:6px;padding:8px 10px;background:#f8fafc;border:1px solid #e4e7ec;border-radius:8px;font-size:12px;font-weight:700;color:#344054}
.kpss-auto-info{font-size:12px;line-height:1.5;padding:10px;background:#f0f7ff;border:1px solid #d8e8fb;border-radius:8px;margin-bottom:12px}
@media(max-width:1000px){.deals-filters{grid-template-columns:1fr 1fr}.deal-finance-snapshot{grid-template-columns:repeat(3,minmax(120px,1fr))}}
@media(max-width:768px){.kpss-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.kpss-edit-grid{grid-template-columns:1fr}.kpss-toolbar{align-items:stretch}.kpss-toolbar .form-group,.kpss-toolbar .btn{width:100%}.kpss-health{align-items:flex-start;flex-direction:column}.deals-filters{grid-template-columns:1fr}.deal-finance-snapshot{grid-template-columns:1fr 1fr}}
.loan-summary{display:grid;grid-template-columns:repeat(auto-fit,minmax(145px,1fr));gap:10px;margin:12px 0}
.loan-summary-item{padding:12px;border:1px solid #e4e7eb;border-radius:9px;background:#fafbfc}
.loan-summary-item label{display:block;font-size:11px;color:#667085;margin-bottom:4px}.loan-summary-item b{font-size:18px}
.loan-table-wrap{overflow:auto;border:1px solid #e4e7eb;border-radius:10px}#loansTable{min-width:1450px;margin:0}
.loan-lender-row{cursor:pointer}
.loan-lender-row td{background:#f8fafc;font-weight:600}
.loan-lender-row:hover td{background:#f1f5f9}
.loan-lender-toggle{border:0;background:transparent;color:#16213e;font:inherit;font-weight:700;cursor:pointer;display:flex;align-items:center;gap:8px;text-align:left;padding:0}
.loan-lender-arrow{display:inline-block;transition:transform .18s ease;color:#667085;font-size:18px}
.loan-lender-row.open .loan-lender-arrow{transform:rotate(90deg)}
.loan-lender-count{display:block;font-size:11px;color:#667085;font-weight:500;margin-top:3px}
.loan-lender-detail-row{display:none}
.loan-lender-detail-row.show{display:table-row}
.loan-lender-detail-cell{padding:0!important;background:#fff!important}
.loan-lender-inner{padding:12px 14px 16px 34px;overflow:auto}
.loan-lender-inner table{min-width:1300px;margin:0;border:1px solid #e4e7eb}
.loan-lender-inner th{background:#f8fafc;font-size:11px}
.loan-lender-inner td{background:#fff;font-weight:400}
.loan-attachments{display:flex;flex-direction:column;gap:7px;margin-top:10px}
.loan-attachment-item{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 10px;border:1px solid #e4e7eb;border-radius:8px;background:#fff}
.loan-attachment-main{min-width:0;display:flex;align-items:center;gap:8px}
.loan-attachment-name{font-size:12px;font-weight:600;color:#344054;word-break:break-word}
.loan-attachment-meta{font-size:10px;color:#667085;margin-top:2px}
.loan-attachment-actions{display:flex;gap:6px;flex:0 0 auto}
.loan-attachment-pending{background:#fffaeb;border-color:#fedf89}
.loan-file-help{font-size:11px;color:#667085;margin:6px 0}
.loan-repayment-row{display:grid;grid-template-columns:160px 180px minmax(220px,1fr) auto;gap:7px;align-items:end;margin:7px 0}
@media(max-width:700px){.counterparty-card-grid{grid-template-columns:1fr}.counterparty-contact-row,.loan-repayment-row{grid-template-columns:1fr}.loan-summary{grid-template-columns:1fr}}
.deal-detail-row{display:none}.deal-detail-row.show{display:table-row}
.deal-detail-panel{padding:14px;background:#fbfcfd}
.deal-detail-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.deal-detail-block{border:1px solid #e4e7eb;border-radius:8px;background:#fff;padding:10px;min-width:0}
.deal-detail-block h4{font-size:13px;margin-bottom:6px;color:#344054}
.deal-detail-block table{margin:0;min-width:520px}
.deal-detail-scroll{overflow:auto}
.deal-form-section{border:1px solid #e4e7eb;border-radius:9px;padding:12px;margin:12px 0;background:#fbfcfd}
.deal-form-section h3{font-size:14px;margin:0 0 9px;color:#16213e}
.deal-repeat-row{display:grid;gap:6px;align-items:end;margin:7px 0}
.deal-repeat-row.customer{grid-template-columns:minmax(120px,1fr) minmax(130px,1.2fr) minmax(120px,1fr) auto}
.deal-repeat-row.extra{grid-template-columns:minmax(150px,1.2fr) minmax(180px,1.5fr) minmax(120px,1fr) minmax(120px,1fr) auto}
.deal-repeat-row.supplier{grid-template-columns:repeat(3,minmax(120px,1fr)) repeat(3,minmax(110px,.9fr)) repeat(3,minmax(110px,.9fr)) auto;overflow:auto}
.deal-repeat-row input{min-width:0}
.deal-repeat-label{font-size:10px;color:#667085;margin-bottom:2px}
.deal-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:10px 0}
.deal-metric{padding:9px;background:#f8fafc;border-radius:7px;border:1px solid #eaecf0}
.deal-metric label{display:block;font-size:10px;color:#667085}.deal-metric b{font-size:13px}
@media(max-width:768px){.deals-filters,.deals-summary,.deal-detail-grid,.deal-metrics{grid-template-columns:1fr}.deal-repeat-row.customer,.deal-repeat-row.extra,.deal-repeat-row.supplier{grid-template-columns:1fr}.deal-repeat-row.supplier{overflow:visible}.deals-actions{width:100%}.deals-actions .btn,.deals-actions label,.deals-import-org{flex:1 1 150px}}
.salary-toolbar{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:12px}
.salary-toolbar-actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.salary-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:12px 0}
.salary-summary-item{padding:12px;border:1px solid #e4e7eb;border-radius:8px;background:#fafbfc}
.salary-summary-item label{display:block;font-size:12px;color:#666;margin-bottom:4px}
.salary-summary-item b{font-size:18px}
.dashboard-layout{display:grid;gap:18px}
.dashboard-section{border:1px solid #e4e7eb;border-radius:12px;padding:16px;background:#fff}
.dashboard-section-history{background:linear-gradient(180deg,#fbfcff 0%,#fff 100%)}
.dashboard-section-period{background:linear-gradient(180deg,#fbfffc 0%,#fff 100%)}
.dashboard-section-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-end;flex-wrap:wrap;margin-bottom:14px}
.dashboard-section-head h2{margin:0;font-size:20px}
.dashboard-section-subtitle{font-size:12px;color:#667085;margin-top:4px}
.dashboard-period-controls{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.dashboard-period-controls select,.dashboard-period-controls input{height:42px;min-height:42px;box-sizing:border-box}
.dashboard-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin-bottom:16px}
.dashboard-item{padding:14px;border:1px solid #e4e7eb;border-radius:9px;background:#fff}
.dashboard-item label{display:block;font-size:12px;color:#666;margin-bottom:5px}.dashboard-item b{font-size:20px}
.dashboard-payments-title{margin:12px 0 8px;font-size:15px}
.dashboard-payments-disclosure{margin-top:12px;border:1px solid #e4e7eb;border-radius:9px;background:#fafbfc;overflow:hidden}
.dashboard-payments-disclosure summary{cursor:pointer;padding:12px 14px;font-size:14px;font-weight:700;color:#344054;display:flex;justify-content:space-between;gap:10px;align-items:center;user-select:none}
.dashboard-payments-disclosure[open] summary{border-bottom:1px solid #e4e7eb;background:#f7f9fc}
.dashboard-payments-content{padding:4px 14px 10px}
.dashboard-trends{border:1px solid #e4e7eb;border-radius:12px;padding:16px;background:#fff}
.dashboard-trends-head{margin-bottom:14px}
.dashboard-trends-head h2{margin:0;font-size:20px}
.dashboard-trends-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.dashboard-trend-card{border:1px solid #e4e7eb;border-radius:10px;padding:14px;background:#fafbfc;min-width:0}
.dashboard-trend-title{font-size:14px;font-weight:700;color:#344054;margin-bottom:12px}
.dashboard-mini-chart{height:190px;display:flex;align-items:flex-end;justify-content:space-around;gap:12px;padding:26px 8px 6px;border-bottom:1px solid #d0d5dd;position:relative}
.dashboard-mini-bar-wrap{flex:1;min-width:0;height:100%;display:flex;flex-direction:column;justify-content:flex-end;align-items:center;gap:6px}
.dashboard-mini-value{font-size:11px;font-weight:700;color:#344054;text-align:center;white-space:nowrap}
.dashboard-mini-bar{width:min(54px,72%);min-height:3px;border-radius:7px 7px 2px 2px;background:#315a8a;transition:height .2s ease}
.dashboard-mini-label{font-size:11px;color:#667085;text-align:center;white-space:nowrap}
.dashboard-mini-bar.count{background:#18794e}
.dashboard-mini-bar.debt{background:#b54708}
.dashboard-mini-bar.paid{background:#027a48}
.period-bar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:10px 0 14px;padding:10px;background:#f8fafc;border:1px solid #e4e7eb;border-radius:8px}
.period-status{font-size:13px;font-weight:600}.period-closed{color:#b42318}.period-open{color:#18794e}
.archive-row{display:flex;justify-content:space-between;gap:10px;align-items:center;padding:9px 0;border-bottom:1px solid #eee;font-size:13px}
.backup-list{margin-top:10px;font-size:13px}.backup-list div{padding:5px 0;border-bottom:1px solid #eee}
#tab-salary .salary-toolbar{align-items:flex-end}
#tab-salary .salary-toolbar-actions{display:grid;grid-template-columns:minmax(190px,220px) minmax(220px,280px) minmax(320px,1fr);gap:12px;align-items:end;flex:1;max-width:900px}
.salary-filter-field{display:grid;gap:5px;min-width:0}
.salary-filter-field label{font-size:12px;font-weight:600;color:#475467}
#tab-salary .salary-filter-field select,#tab-salary .salary-filter-field input{height:46px;min-height:46px;padding:9px 12px;font-size:15px;line-height:1.2;border-radius:8px;box-sizing:border-box}
#salarySearch{width:100%;min-width:320px}
.salary-payment-actions{display:flex;gap:5px;align-items:center}
.salary-payment-row .btn{padding:3px 7px}
.backup-warning{font-size:12px;color:#777;margin-top:8px}
.salary-card{padding:0;overflow:hidden;cursor:default}
.salary-card-head{width:100%;display:block;text-align:left;border:0;background:transparent;cursor:pointer;padding:16px}
.salary-card.salary-reconciled{border:1px solid #86efac;box-shadow:0 2px 10px rgba(22,163,74,.14)}
.salary-card.salary-reconciled .salary-card-head{background:#ecfdf3}
.salary-card.salary-reconciled:hover{box-shadow:0 4px 14px rgba(22,163,74,.2)}
.salary-reconcile-badge{display:inline-flex;align-items:center;gap:4px;padding:3px 8px;border-radius:999px;background:#dcfce7;color:#166534;font-size:11px;font-weight:700;white-space:nowrap}
.salary-reconcile-bar{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 16px;border-top:1px solid #bbf7d0;background:#f0fdf4;font-size:12px;color:#166534}
.salary-reconcile-check{display:flex;align-items:center;gap:8px;font-weight:600;cursor:pointer}
.salary-reconcile-check input{width:18px;height:18px;min-height:0;accent-color:#16a34a}
.salary-reconcile-meta{font-size:11px;color:#667085;text-align:right}
.salary-card .name{display:flex;align-items:center;gap:8px}
.salary-card .chevron{transition:transform .2s}
.salary-card.open .chevron{transform:rotate(180deg)}
.salary-card .stats{display:flex;gap:20px;flex-wrap:wrap;margin-top:8px}
.salary-paid-link,.salary-balance-link{font-weight:600;color:#0f3460;text-decoration:underline;text-decoration-style:dotted;text-underline-offset:3px;cursor:pointer}
.salary-card .stat .salary-paid-link.needs-allocation{color:#d92d20;font-weight:700}
.salary-card .stat .salary-paid-link.needs-allocation:hover{color:#b42318}
.salary-balance-date{font-size:11px;color:#777;margin-left:4px}
.salary-balance-detail{display:none;border-top:1px solid #eef0f2;padding:10px 16px;background:#fffdf7}
.salary-balance-detail.show{display:block}
.balance-history-row{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:7px 0;border-bottom:1px solid #eceff2;font-size:13px}
.balance-history-row:last-child{border-bottom:0}
.balance-history-main{min-width:0}
.balance-history-comment{font-size:12px;color:#777;margin-top:2px}
.balance-history-actions{display:flex;gap:5px;flex:0 0 auto}
.balance-help{font-size:12px;color:#667085;margin:-4px 0 12px}
.salary-payment-detail{display:none;border-top:1px solid #eef0f2;padding:10px 16px;background:#f8fafc}
.salary-payment-detail.show{display:block}
.salary-payment-title{font-size:13px;font-weight:600;margin-bottom:7px;color:#16213e}
.salary-payment-row{display:flex;justify-content:space-between;gap:16px;padding:5px 0;border-bottom:1px solid #eceff2;font-size:13px}
.salary-payment-row:last-child{border-bottom:0}
.salary-payment-main{flex:1;min-width:0}
.bulk-payment-selector{display:flex;align-items:flex-start;padding-top:2px;cursor:pointer;flex:0 0 auto}
.bulk-payment-selector input{width:18px;height:18px;min-height:0;margin:0;accent-color:#0f3460}
.salary-bulk-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:9px 10px;margin:0 0 8px;border:1px solid #d8e2ef;border-radius:8px;background:#fff}
.salary-bulk-select-all{display:flex;align-items:center;gap:7px;font-size:12px;font-weight:600;cursor:pointer}
.salary-bulk-select-all input{width:17px;height:17px;min-height:0;margin:0;accent-color:#0f3460}
.salary-bulk-summary{font-size:12px;color:#667085;margin-right:auto}
.bulk-allocation-list{display:grid;gap:10px;max-height:470px;overflow:auto;padding-right:2px}
.bulk-allocation-row{border:1px solid #e4e7ec;border-radius:9px;padding:11px;background:#f8fafc}
.bulk-allocation-row-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-start;margin-bottom:9px;font-size:12px}
.bulk-allocation-row-head b{font-size:13px;color:#16213e}
.bulk-allocation-source{font-size:11px;color:#667085;margin-top:2px}
.bulk-allocation-common{display:grid;grid-template-columns:minmax(220px,1fr) auto;gap:8px;align-items:end;margin:10px 0}
.bulk-allocation-manual-common{display:flex;gap:8px;align-items:end;flex-wrap:wrap;padding:10px;border:1px solid #f5d9a8;background:#fffbeb;border-radius:8px;margin:10px 0}
.bulk-allocation-manual-common .form-group{margin:0;flex:1;min-width:220px}
.bulk-allocation-total{font-size:13px;font-weight:700;margin:12px 0;color:#344054}
.salary-payment-empty{font-size:13px;color:#777}
.salary-detail{border-top:1px solid #eee;padding:12px 16px 16px;margin-top:0}
.salary-records{display:grid;gap:10px}
.salary-entry{border:1px solid #e6e8eb;border-radius:8px;padding:12px;background:#fbfcfd}
.salary-entry-top{display:flex;justify-content:space-between;gap:10px;flex-wrap:wrap;margin-bottom:10px}
.salary-entry-date{font-weight:600}
.salary-entry-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.salary-entry-field label{display:block;font-size:11px;color:#777;margin-bottom:2px}
.salary-entry-field div{font-size:13px;word-break:break-word}
.salary-entry-totals,.salary-entry-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}
.salary-month-entry{border-color:#d7dde5;background:#fff}
.salary-month-entry .salary-entry-date{font-size:15px;color:#16213e}
.salary-month-source{margin-top:12px;border-top:1px solid #e6e8eb;padding-top:10px}
.salary-month-source summary{cursor:pointer;font-size:12px;font-weight:600;color:#0f3460;user-select:none}
.salary-source-list{display:grid;gap:8px;margin-top:9px}
.salary-source-row{padding:10px;border:1px solid #edf0f3;border-radius:7px;background:#f8fafc}
.salary-source-row-top{display:flex;justify-content:space-between;gap:8px;flex-wrap:wrap;font-size:12px;margin-bottom:7px}
.salary-source-row-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.salary-source-row-grid label{display:block;font-size:10px;color:#777;margin-bottom:2px}
.salary-source-row-grid div{font-size:12px;word-break:break-word}
.salary-source-row-totals{display:flex;gap:10px;flex-wrap:wrap;margin-top:8px;font-size:12px}
.salary-month-payments{margin-top:12px;padding:10px;border:1px solid #dce9e2;border-radius:8px;background:#f5fbf7}
.salary-month-payments-title{font-size:12px;font-weight:700;color:#18794e;margin-bottom:6px}
.salary-month-payment-row{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:7px 0;border-bottom:1px solid #e1eee6;font-size:12px}
.salary-month-payment-row:last-child{border-bottom:0}
.salary-export-actions{margin:12px 0}
.salary-export-launch{min-height:44px;padding:10px 18px}
.salary-export{margin:10px 0 0;padding:12px;border:1px solid #e4e7eb;border-radius:8px;background:#fafbfc}
.salary-export-title{font-weight:600;margin-bottom:8px}
.salary-export-grid{display:grid;grid-template-columns:minmax(210px,1.25fr) minmax(180px,1fr) repeat(2,minmax(145px,.85fr)) auto;gap:8px;align-items:end}
.salary-export-grid .form-group{margin-bottom:0}
.export-hint{font-size:12px;color:#666;margin-top:7px}
.responsible-picker{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;max-height:240px;overflow:auto;border:1px solid #ddd;border-radius:6px;padding:8px}
.responsible-item{display:flex;align-items:center;gap:8px;padding:7px 8px;border-radius:6px;background:#fafafa;cursor:pointer;font-size:13px}
.responsible-item input{width:18px;height:18px;min-height:0;flex:0 0 auto}
.responsible-chips{display:flex;gap:6px;flex-wrap:wrap;margin-top:8px}
.responsible-chip{display:inline-flex;align-items:center;gap:5px;background:#e8f0fe;color:#164e8a;border-radius:14px;padding:5px 9px;font-size:12px}
@media(max-width:768px){
  header{display:block;padding:10px 12px}
  header h1{font-size:16px;white-space:normal}
  .mobile-menu-toggle{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;background:rgba(255,255,255,.15);color:#fff;border:0;border-radius:6px;min-width:44px;min-height:44px;font-size:20px}
  header .user-info{display:none;width:100%;margin-top:8px;padding-top:8px;border-top:1px solid rgba(255,255,255,.18);flex-direction:column;align-items:stretch;gap:7px}
  header .user-info.mobile-open{display:flex}
  header .user-info button{width:100%;min-height:44px}
  .tabs{padding:0 6px;overflow-x:auto;white-space:nowrap;-webkit-overflow-scrolling:touch}
  .tab-btn{padding:11px 13px;min-height:48px}
  .tab-content{padding:12px}
  .card{padding:14px}
  .salary-toolbar-actions,.salary-export-grid{display:grid;grid-template-columns:1fr;width:100%}
  #tab-salary .salary-toolbar-actions{grid-template-columns:1fr;max-width:none}
  #salarySearch{min-width:0}
  .salary-entry-grid,.salary-source-row-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .salary-summary{grid-template-columns:1fr}
  .dashboard-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .dashboard-trends-grid{grid-template-columns:1fr}
  .responsible-picker{grid-template-columns:1fr}
  .form-row{display:grid;grid-template-columns:1fr;gap:0}
  .form-row .form-group{min-width:0}
  table{display:block;overflow-x:auto;white-space:nowrap;-webkit-overflow-scrolling:touch}
  .modal{width:calc(100vw - 24px);max-width:none;max-height:calc(100vh - 24px);padding:18px}
}
@media(max-width:420px){
  .salary-entry-grid,.salary-source-row-grid{grid-template-columns:1fr}
  .salary-card .stats{display:grid;grid-template-columns:1fr;gap:4px}
}




/* === KOVLEON estimate editor 2.0 === */
.estimate-editor-overlay{padding:10px}
.estimate-editor-modal{width:calc(100vw - 20px)!important;max-width:none!important;height:calc(100vh - 20px);max-height:none!important;display:flex;flex-direction:column;overflow:hidden;padding:16px 18px}
.estimate-editor-titlebar{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-right:30px}
.estimate-editor-titlebar h2{margin:0}.estimate-shortcuts{font-size:10px;color:#98a2b3;text-align:right;line-height:1.5}
.estimate-autosave-status{font-size:10px;color:#667085;margin-top:3px}.estimate-autosave-status[data-kind="saved"]{color:#067647}.estimate-autosave-status[data-kind="error"]{color:#b42318}
.estimate-meta-grid{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:8px;align-items:end;margin:10px 0}
.estimate-meta-grid .form-group{margin:0;min-width:0}.estimate-meta-grid label{font-size:10px}.estimate-meta-grid input,.estimate-meta-grid select{padding:7px 8px;font-size:12px;min-width:0;max-width:100%}
.estimate-meta-grid .form-group:nth-child(1){grid-column:span 2}
.estimate-meta-grid .form-group:nth-child(2){grid-column:span 2}
.estimate-meta-grid .form-group:nth-child(3){grid-column:span 2}
.estimate-meta-grid .form-group:nth-child(4){grid-column:span 2}
.estimate-meta-grid .form-group:nth-child(5){grid-column:span 4}
.estimate-meta-grid .form-group:nth-child(6){grid-column:span 3}
.estimate-meta-grid .form-group:nth-child(7){grid-column:span 3}
.estimate-meta-grid .form-group:nth-child(8){grid-column:span 2}
.estimate-meta-grid .form-group:nth-child(9){grid-column:span 2}
.estimate-meta-grid .form-group:nth-child(10){grid-column:span 2}
.estimate-meta-title{grid-column:span 4}
.estimate-editor-toolbar{display:block;padding:9px 0;border-top:1px solid #eaecf0;border-bottom:1px solid #eaecf0}
.estimate-editor-toolbar-main{display:flex;gap:6px;flex-wrap:wrap;align-items:center}.estimate-editor-help{font-size:10px;color:#667085;max-width:none;text-align:left;margin-top:6px}
.estimate-editor-sections{flex:1;min-height:220px;overflow:auto;padding:10px 2px 80px}
.estimate-section-block{border:1px solid #dfe3e8;border-radius:9px;background:#fff;margin-bottom:10px;overflow:hidden}
.estimate-section-block.active{box-shadow:0 0 0 2px rgba(21,94,239,.12);border-color:#b2ccff}
.estimate-section-head{display:flex;align-items:center;gap:8px;padding:8px 9px;background:#f8fafc;border-bottom:1px solid #e4e7ec;position:sticky;top:0;z-index:4}
.estimate-collapse{border:0;background:transparent;font-size:18px;color:#475467;cursor:pointer;min-width:26px}
.estimate-section-name{border:0!important;background:transparent!important;font-size:13px!important;font-weight:800!important;color:#16213e!important;min-width:180px;max-width:480px;box-shadow:none!important;padding:4px!important}
.estimate-section-name:focus{background:#fff!important;outline:1px solid #b2ccff!important}
.estimate-section-totals{margin-left:auto;display:flex;gap:14px;font-size:10px;color:#667085;white-space:nowrap}.estimate-section-totals b{display:block;color:#344054;font-size:11px;margin-top:2px}
.estimate-section-actions,.estimate-row-actions{display:flex;gap:3px}
.estimate-section-actions button,.estimate-row-actions button{width:27px;height:27px;border:1px solid #d0d5dd;border-radius:6px;background:#fff;color:#475467;cursor:pointer;font-size:12px;padding:0}
.estimate-section-actions button:hover,.estimate-row-actions button:hover{background:#f2f4f7}.estimate-section-actions button.danger,.estimate-row-actions button.danger{color:#b42318}
.estimate-section-table-wrap{overflow:auto}.estimate-section-block.collapsed .estimate-section-table-wrap{display:none}
.estimate-editor-table{width:100%;min-width:1340px;margin:0;border-collapse:separate;border-spacing:0}
.estimate-editor-table th{font-size:9px;text-transform:uppercase;letter-spacing:.02em;color:#667085;background:#fcfcfd;padding:6px 5px;position:static;white-space:nowrap}
.estimate-editor-table td{padding:4px 4px;vertical-align:middle;border-top:1px solid #f1f2f4}.estimate-editor-table .est-no{width:34px;text-align:center}.estimate-editor-table .est-name{min-width:290px}
.estimate-editor-table input,.estimate-editor-table select{width:100%;min-width:72px;border:1px solid transparent;background:transparent;border-radius:5px;padding:6px 6px;font-size:11px}
.estimate-editor-table input:hover,.estimate-editor-table select:hover{border-color:#d0d5dd;background:#fff}.estimate-editor-table input:focus,.estimate-editor-table select:focus{border-color:#84adff;background:#fff;outline:2px solid #d1e0ff}
.estimate-editor-table .estimate-name{min-width:280px}.estimate-editor-table .estimate-code{min-width:90px}.estimate-editor-table .estimate-item-type{min-width:105px}.estimate-editor-table .estimate-unit{min-width:60px}.estimate-editor-table .estimate-qty,.estimate-editor-table .estimate-cost,.estimate-editor-table .estimate-price{min-width:90px;text-align:right}
.estimate-row-no{font-size:10px;color:#98a2b3;text-align:center}.estimate-calc{font-size:11px;font-weight:700;text-align:right;white-space:nowrap;color:#344054}.estimate-calc.positive{color:#067647}.estimate-calc.negative{color:#b42318}
.estimate-summary-extended{display:grid;grid-template-columns:repeat(5,minmax(150px,1fr));gap:8px;margin:8px 0}
.estimate-summary-extended>div{padding:9px 10px;border:1px solid #e4e7ec;border-radius:8px;background:#f8fafc}.estimate-summary-extended>div.primary{background:#eefbf3;border-color:#b7e5ca}
.estimate-summary-extended label{display:block;font-size:9px;color:#667085}.estimate-summary-extended b{display:block;font-size:14px;color:#16213e;margin-top:2px}
.estimate-editor-footer{display:flex;justify-content:flex-end;gap:8px;position:sticky;bottom:0;background:#fff;padding-top:6px}
.estimate-catalog-results{max-height:55vh;overflow:auto;border:1px solid #e4e7ec;border-radius:8px}.estimate-catalog-row{width:100%;display:grid;grid-template-columns:minmax(260px,1fr) 140px 140px 90px;gap:10px;align-items:center;text-align:left;border:0;border-bottom:1px solid #eef0f2;background:#fff;padding:10px 12px;cursor:pointer;color:#344054}.estimate-catalog-row:hover{background:#f8fafc}.estimate-catalog-row:last-child{border-bottom:0}.estimate-catalog-row span{display:grid;gap:2px}.estimate-catalog-row small{font-size:9px;color:#667085}.estimate-catalog-row strong{color:#175cd3;font-size:11px;text-align:right}.estimate-empty{padding:20px;text-align:center;color:#667085;font-size:12px}
.estimate-import-mapping{display:grid;grid-template-columns:repeat(4,minmax(160px,1fr));gap:8px;margin:10px 0}.estimate-import-mapping .form-group{margin:0}
.estimate-import-preview{max-height:320px;overflow:auto;border:1px solid #e4e7ec;border-radius:8px}.estimate-import-preview table{min-width:900px;margin:0}.estimate-import-preview th,.estimate-import-preview td{font-size:10px;padding:6px 8px;white-space:nowrap}
@media(max-width:1300px){
  .estimate-meta-grid{grid-template-columns:repeat(6,minmax(0,1fr))}
  .estimate-meta-grid .form-group:nth-child(1),.estimate-meta-grid .form-group:nth-child(5),.estimate-meta-grid .form-group:nth-child(6),.estimate-meta-grid .form-group:nth-child(7){grid-column:span 3}
  .estimate-meta-grid .form-group:nth-child(2),.estimate-meta-grid .form-group:nth-child(3),.estimate-meta-grid .form-group:nth-child(4),.estimate-meta-grid .form-group:nth-child(8),.estimate-meta-grid .form-group:nth-child(9),.estimate-meta-grid .form-group:nth-child(10){grid-column:span 2}
  .estimate-editor-help{display:block}
}
@media(max-width:900px){
  .estimate-meta-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .estimate-meta-grid .form-group:nth-child(n){grid-column:span 1}
  .estimate-meta-grid .form-group:nth-child(1),.estimate-meta-grid .form-group:nth-child(5),.estimate-meta-grid .form-group:nth-child(6),.estimate-meta-grid .form-group:nth-child(7){grid-column:span 2}
  .estimate-shortcuts{display:none}.estimate-summary-extended{grid-template-columns:repeat(2,minmax(0,1fr))}.estimate-import-mapping{grid-template-columns:repeat(2,minmax(0,1fr))}.estimate-catalog-row{grid-template-columns:1fr 110px}.estimate-catalog-row span:nth-child(3),.estimate-catalog-row strong{display:none}
}

/* === KOVLEON navigation 2.0 === */
.sidebar-group-direct{padding:4px 0 8px}
.site-sidebar .sidebar-direct-link{
  display:flex!important;
  width:100%!important;
  align-items:center!important;
  justify-content:flex-start!important;
  padding:12px 10px!important;
  border-radius:8px!important;
  color:#16213e!important;
  font-size:15px!important;
  font-weight:800!important;
  background:transparent!important;
  border:0!important;
  border-bottom:0!important;
}
.site-sidebar .sidebar-direct-link:hover{background:#f3f6fa!important}
.site-sidebar .sidebar-direct-link.active{background:#eaf2fb!important;color:#0f3460!important}
.site-sidebar-nav .sidebar-group-toggle>span:first-child{letter-spacing:.005em}
.site-sidebar .sidebar-submenu .tab-btn{padding-left:14px}

/* === KOVLEON UX layer: global search, attention center, object workspace === */
.korvex-global-search{position:relative;flex:1 1 420px;max-width:620px;margin:0 18px}
.korvex-global-search>input{width:100%;height:38px;border:1px solid rgba(255,255,255,.35);border-radius:9px;background:rgba(255,255,255,.12);color:#fff;padding:8px 62px 8px 34px;font-size:13px}
.korvex-global-search>input::placeholder{color:rgba(255,255,255,.75)}.korvex-global-search>input:focus{outline:2px solid rgba(255,255,255,.28);background:#fff;color:#16213e}
.korvex-global-search-icon{position:absolute;left:11px;top:8px;color:rgba(255,255,255,.8);z-index:2}.korvex-global-search:focus-within .korvex-global-search-icon{color:#667085}
.korvex-global-search kbd{position:absolute;right:9px;top:8px;padding:2px 6px;border:1px solid rgba(255,255,255,.35);border-radius:5px;font-size:10px;color:#fff;background:rgba(255,255,255,.1)}.korvex-global-search:focus-within kbd{color:#667085;border-color:#d0d5dd;background:#f8fafc}
.korvex-global-search-results{display:none;position:absolute;left:0;right:0;top:44px;z-index:120;background:#fff;border:1px solid #d0d5dd;border-radius:10px;box-shadow:0 14px 35px rgba(15,23,42,.2);max-height:480px;overflow:auto}.korvex-global-search-results.show{display:block}
.global-search-result{width:100%;border:0;border-bottom:1px solid #eef0f3;background:#fff;display:grid;grid-template-columns:92px 1fr auto;gap:10px;align-items:center;text-align:left;padding:10px 12px;cursor:pointer}.global-search-result:hover{background:#f8fafc}.global-search-result:last-child{border-bottom:0}.global-search-result span:nth-child(2){display:grid;gap:2px;min-width:0}.global-search-result b{font-size:12px;color:#101828;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-search-result small{font-size:10px;color:#667085;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-search-result strong{font-size:10px;color:#175cd3}.global-search-kind{font-size:9px;font-weight:800;color:#475467;text-transform:uppercase}.global-search-hint{padding:14px;color:#667085;font-size:11px}
.dashboard-attention-section{border:1px solid #e4e7ec;border-radius:10px;padding:14px;margin-bottom:14px;background:#fff}.dashboard-attention-count{display:inline-flex;align-items:center;justify-content:center;min-width:28px;height:28px;border-radius:999px;background:#eef2f6;color:#344054;font-weight:800}.dashboard-attention-list{display:grid;gap:7px;margin-top:10px}.dashboard-attention-item{width:100%;border:1px solid #e4e7ec;border-left:4px solid #f79009;border-radius:8px;background:#fff;display:grid;grid-template-columns:10px 1fr auto;gap:10px;align-items:center;text-align:left;padding:9px 11px;cursor:pointer}.dashboard-attention-item.danger{border-left-color:#d92d20;background:#fff8f7}.dashboard-attention-item.warning{background:#fffdf7}.dashboard-attention-item span:nth-child(2){display:grid;gap:2px}.dashboard-attention-item b{font-size:12px;color:#101828}.dashboard-attention-item small{font-size:10px;color:#667085}.dashboard-attention-item strong{font-size:10px;color:#175cd3}.dashboard-attention-dot{width:7px;height:7px;border-radius:50%;background:#f79009}.dashboard-attention-item.danger .dashboard-attention-dot{background:#d92d20}.dashboard-attention-empty{font-size:12px;color:#067647;background:#f2fbf6;border:1px solid #b7e5ca;border-radius:8px;padding:10px 12px}
.korvex-empty-state{min-height:280px;border:1px dashed #cfd5dd;border-radius:12px;background:#fafbfc;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:28px}.korvex-empty-state h3{margin:7px 0}.korvex-empty-state p{max-width:520px;color:#667085;font-size:12px;line-height:1.5}.korvex-empty-icon{font-size:34px;color:#98a2b3}
.object-name-link{border:0;background:transparent;padding:0;color:#175cd3;font-weight:700;cursor:pointer;text-align:left}.object-name-link:hover{text-decoration:underline}.object-row-actions{display:flex;gap:5px;flex-wrap:wrap}
.object-workspace-modal{max-width:1120px!important;width:96%!important}.object-workspace-head{display:flex;justify-content:space-between;gap:16px;align-items:flex-start}.object-workspace-head h2{margin:2px 0}.object-workspace-eyebrow{font-size:9px;font-weight:800;color:#667085;text-transform:uppercase;letter-spacing:.06em}.object-workspace-meta{font-size:11px;color:#667085}.object-workspace-health span{display:inline-flex;padding:5px 10px;border-radius:999px;font-size:10px;font-weight:800}.object-workspace-health .good{background:#dcfae6;color:#067647}.object-workspace-health .warning{background:#fef0c7;color:#b54708}.object-workspace-health .danger{background:#fee4e2;color:#b42318}
.object-workspace-kpis{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px;margin:14px 0}.object-workspace-kpis>div{padding:10px;border:1px solid #e4e7ec;border-radius:8px;background:#f8fafc}.object-workspace-kpis label{display:block;font-size:9px;color:#667085}.object-workspace-kpis b{display:block;margin-top:3px;font-size:14px;color:#101828}.object-workspace-kpis b.negative{color:#b42318}.object-workspace-actions{display:flex;gap:7px;flex-wrap:wrap;margin-bottom:12px}
.object-workspace-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.object-workspace-grid>section{border:1px solid #e4e7ec;border-radius:9px;padding:10px;min-width:0}.object-workspace-grid h3{font-size:13px;margin:0 0 7px}.object-workspace-row{width:100%;border:0;border-bottom:1px solid #eef0f3;background:#fff;display:flex;align-items:center;justify-content:space-between;gap:12px;text-align:left;padding:8px 4px;cursor:pointer}.object-workspace-row:last-child{border-bottom:0}.object-workspace-row span{display:grid;gap:2px}.object-workspace-row small{font-size:9px;color:#667085}.object-workspace-row strong{font-size:11px;color:#344054;white-space:nowrap}.korvex-mini-empty{font-size:11px;color:#667085;padding:9px;background:#f8fafc;border-radius:7px}.korvex-mini-empty.good{color:#067647;background:#f2fbf6}.object-workspace-team{display:flex;gap:5px;flex-wrap:wrap;margin-bottom:8px}.object-workspace-salary{font-size:11px;color:#475467}.object-next-list{margin:0;padding-left:20px;font-size:11px;line-height:1.8;color:#344054}

/* === KOVLEON UX pass 2: unified working screens === */
.korvex-page-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;flex-wrap:wrap;margin-bottom:12px}
.korvex-page-head h2{margin:0 0 4px}.korvex-page-head p{margin:0;max-width:760px;color:#667085;font-size:12px;line-height:1.45}
.korvex-page-actions{display:flex;gap:7px;flex-wrap:wrap;align-items:center}
.korvex-control-bar{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:10px 0 12px}.korvex-control-bar>input,.korvex-control-bar>select{flex:1 1 260px;max-width:560px}.korvex-control-bar>.btn{flex:0 0 auto}
.korvex-table-wrap{overflow:auto;border:1px solid #e4e7ec;border-radius:10px;background:#fff}.korvex-table-wrap table{margin:0}
.dashboard-quick-section{border:1px solid #e4e7ec;border-radius:10px;padding:14px;margin-bottom:14px;background:#fff}
.dashboard-quick-actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:8px;margin-top:10px}
/* All six quick actions share the same deep navy as the main site header. */
.dashboard-quick-action{
  display:grid;
  align-content:center;
  justify-items:center;
  gap:6px;
  width:100%;
  min-height:80px;
  padding:14px 12px;
  border:1px solid #0f3460;
  border-radius:10px;
  background:#0f3460;
  color:#fff;
  text-align:center;
  cursor:pointer;
  transition:background-color .15s ease, border-color .15s ease;
}
.dashboard-quick-action:hover{background:#164779;border-color:#164779}
.dashboard-quick-action:active{background:#0c284b}
.dashboard-quick-action:focus-visible{outline:3px solid #84adff;outline-offset:3px}
.dashboard-quick-action b{display:block;color:#fff;font-size:18px;line-height:1.2;font-weight:800;overflow-wrap:anywhere}
.dashboard-quick-action small{display:block;color:#fff;font-size:12px;line-height:1.4;font-weight:400;overflow-wrap:anywhere}
@media(max-width:768px){
  .korvex-page-head{display:block}.korvex-page-actions{display:grid;grid-template-columns:1fr 1fr;margin-top:10px}.korvex-page-actions .btn,.korvex-page-actions label{width:100%}
  .korvex-control-bar{display:grid;grid-template-columns:1fr}.korvex-control-bar>input,.korvex-control-bar>select,.korvex-control-bar>.btn{width:100%;max-width:none}
  .dashboard-quick-actions{grid-template-columns:1fr 1fr}.dashboard-quick-action{min-height:84px}
}
@media(max-width:420px){
  .korvex-page-actions,.dashboard-quick-actions{grid-template-columns:1fr}
  .dashboard-quick-action b{font-size:20px}
}

/* Shared fast editing controls for employee, counterparty, loan and object tables */
.kv-fast-edit{display:inline-flex;align-items:center;justify-content:space-between;gap:7px;max-width:100%;min-height:30px;border:1px solid transparent;border-radius:7px;background:transparent;padding:4px 6px;color:#344054;font:inherit;cursor:pointer;text-align:left}
.kv-fast-edit:hover,.kv-fast-edit:focus-visible{background:#f0f6ff;border-color:#b2ccff;outline:none}
.kv-fast-edit>span:first-child{min-width:0;overflow-wrap:anywhere}.kv-fast-pencil{font-size:12px;color:#175cd3;opacity:.6}
.kv-fast-box{display:inline-flex;flex-wrap:wrap;gap:5px;align-items:center;min-width:170px;max-width:100%;padding:6px;border:1px solid #84adff;border-radius:8px;background:#f8fbff;box-shadow:0 2px 10px rgba(16,24,40,.1)}
.kv-fast-box label{width:100%;font-size:10px;color:#475467;font-weight:700}
.kv-fast-input{width:100%;min-width:0!important;min-height:36px!important;max-width:none!important;background:#fff;border:1px solid #cfd5dd;border-radius:6px;padding:6px 8px;font-size:13px!important}
.kv-fast-controls{display:flex;gap:5px;margin-left:auto}.kv-fast-controls button{border:0;border-radius:6px;min-width:34px;min-height:34px;font-size:17px;font-weight:800;cursor:pointer}
.kv-fast-save{background:#dcfae6;color:#067647}.kv-fast-cancel{background:#f2f4f7;color:#475467}.kv-fast-saving{opacity:.6;pointer-events:none}
@media(max-width:768px){.kv-fast-edit{min-height:42px;border-color:#e4e7ec;padding:7px}.kv-fast-box{display:flex;flex-direction:column;align-items:stretch;min-width:0;width:100%}.kv-fast-input{min-height:44px!important;font-size:16px!important}.kv-fast-controls{justify-content:flex-end}.kv-fast-controls button{min-width:44px;min-height:44px}}

/* Open counterparty details by clicking anywhere on its registry row. */
#counterpartiesTable{min-width:920px}
#counterpartiesTable tbody .counterparty-open-row{cursor:pointer;transition:background .15s ease,box-shadow .15s ease}
#counterpartiesTable tbody .counterparty-open-row:hover td{background:#eef6ff}
#counterpartiesTable tbody .counterparty-open-row:focus-visible{outline:3px solid #84adff;outline-offset:-3px;background:#eef6ff}
#counterpartiesTable tbody .counterparty-open-row:active td{background:#e4efff}
.counterparty-row-hint{font-size:11px;color:#667085;margin:-3px 0 9px}
.counterparty-empty-row{text-align:center;color:#667085;padding:24px!important}
@media(max-width:768px){#counterpartiesTable{min-width:800px}}

/* Counterparties registry UX: generous search, legible type and row-based details. */
#tab-counterparties .counterparty-search-toolbar{
  display:flex;
  flex-direction:column;
  align-items:stretch;
  gap:6px;
  width:100%;
  max-width:1100px;
  margin:17px 0 10px;
}
#tab-counterparties .counterparty-search-label{
  color:#344054;
  font-size:12px;
  font-weight:700;
}
#tab-counterparties #counterpartySearch{
  box-sizing:border-box;
  display:block;
  flex:0 0 auto;
  width:100%;
  max-width:none;
  min-width:0;
  min-height:48px;
  padding:12px 15px;
  border:1px solid #cbd5e1;
  border-radius:9px;
  background:#fff;
  color:#101828;
  font-size:15px;
  line-height:1.4;
}
#tab-counterparties #counterpartySearch:focus{
  outline:3px solid rgba(21,94,239,.15);
  border-color:#608df5;
}
#tab-counterparties .counterparty-row-hint{margin:0 0 12px}
#tab-counterparties .counterparty-registry-wrap{max-width:100%}
#tab-counterparties #counterpartiesTable{
  width:100%;
  min-width:760px;
  table-layout:fixed;
  border-collapse:collapse;
}
#tab-counterparties .counterparty-column-type{width:155px}
#tab-counterparties .counterparty-column-name{width:34%}
#tab-counterparties .counterparty-column-inn{width:170px}
#tab-counterparties .counterparty-column-contacts{width:auto}
#tab-counterparties #counterpartiesTable th,
#tab-counterparties #counterpartiesTable td{
  vertical-align:middle;
  padding:13px 14px;
  text-align:left;
}
#tab-counterparties #counterpartiesTable .counterparty-type{
  display:inline-flex;
  align-items:center;
  white-space:nowrap;
  overflow:visible;
  width:auto;
  max-width:none;
  font-size:12px;
  line-height:1.25;
  padding:6px 9px;
  border-radius:8px;
}
#tab-counterparties #counterpartiesTable td:nth-child(2),
#tab-counterparties #counterpartiesTable td:nth-child(4){overflow-wrap:anywhere}
#tab-counterparties .counterparty-full-name,
#tab-counterparties .counterparty-kpp{
  font-size:11px;
  line-height:1.35;
  margin-top:3px;
  color:#667085;
}
@media(max-width:768px){
  #tab-counterparties #counterpartySearch{width:100%;font-size:16px!important;min-height:48px}
  #tab-counterparties #counterpartiesTable{min-width:760px}
  #tab-counterparties #counterpartiesTable th,
  #tab-counterparties #counterpartiesTable td{padding:12px 10px}
}

/* On smartphones show contractor records as readable cards instead of an 760px-wide table. */
.counterparty-mobile-list{display:none}
@media(max-width:768px){
  #tab-counterparties .counterparty-registry-wrap{display:none}
  #tab-counterparties .counterparty-mobile-list{
    display:grid;
    grid-template-columns:minmax(0,1fr);
    gap:10px;
    width:100%;
    min-width:0;
    max-width:100%;
  }
  #tab-counterparties .counterparty-mobile-card{
    display:flex;
    flex-direction:column;
    align-items:stretch;
    gap:8px;
    width:100%;
    min-width:0;
    box-sizing:border-box;
    padding:14px;
    border:1px solid #dbe3ec;
    border-radius:12px;
    background:#fff;
    color:#16213e;
    text-align:left;
    font:inherit;
    box-shadow:0 2px 9px rgba(15,52,96,.06);
    cursor:pointer;
    overflow-wrap:anywhere;
    white-space:normal;
  }
  #tab-counterparties .counterparty-mobile-card:active{background:#f2f7fc}
  #tab-counterparties .counterparty-mobile-card:focus-visible{outline:3px solid #84adff;outline-offset:2px}
  #tab-counterparties .counterparty-mobile-top{display:flex;align-items:center;justify-content:space-between;gap:12px}
  #tab-counterparties .counterparty-mobile-top .counterparty-type{font-size:12px;padding:5px 9px;border-radius:8px;white-space:normal}
  #tab-counterparties .counterparty-mobile-arrow{font-size:26px;line-height:1;color:#8393a7}
  #tab-counterparties .counterparty-mobile-name{display:block;font-size:17px;line-height:1.3;font-weight:800;color:#16213e}
  #tab-counterparties .counterparty-mobile-full-name{display:block;font-size:12px;line-height:1.45;color:#667085}
  #tab-counterparties .counterparty-mobile-fields{display:flex;flex-wrap:wrap;gap:10px 22px;padding-top:9px;border-top:1px solid #edf1f5}
  #tab-counterparties .counterparty-mobile-field{display:flex;flex-direction:column;gap:3px;min-width:0}
  #tab-counterparties .counterparty-mobile-field b{font-size:13px;color:#344054;font-weight:700}
  #tab-counterparties .counterparty-mobile-label{display:block;font-size:11px;color:#667085;font-weight:600}
  #tab-counterparties .counterparty-mobile-contacts{display:block;padding-top:9px;border-top:1px solid #edf1f5}
  #tab-counterparties .counterparty-mobile-contact-data{display:block;margin-top:5px;font-size:12px;line-height:1.5;color:#344054;overflow-wrap:anywhere}
  #tab-counterparties .counterparty-mobile-contact-data>div+div{margin-top:7px}
  #tab-counterparties .counterparty-mobile-empty{padding:18px 14px;border:1px solid #e4e7ec;border-radius:12px;background:#fff;color:#667085;text-align:center;font-size:13px}
}

/* KOVLEON sidebar mark: keep the original full lockup on login and the recognizable icon in navigation. */
.site-sidebar-brand{flex-direction:row;align-items:center;gap:9px}
.site-sidebar-brand-text{display:flex;flex-direction:column;gap:3px;min-width:0}
.site-sidebar-brand-icon{width:32px;height:32px;object-fit:contain;flex-shrink:0}
@media(max-width:400px){.site-sidebar-brand-tagline{font-size:9px;letter-spacing:0}}


/* Deals: mode switch / stage kanban / preliminary financial analytics. */
.deals-view-switch{display:inline-flex;flex-wrap:wrap;gap:4px;margin:14px 0 12px;padding:4px;background:#eef3fa;border:1px solid #dae3ee;border-radius:11px}
.deals-view-btn{border:0;border-radius:8px;padding:10px 17px;background:transparent;color:#425d7b;cursor:pointer;font:inherit;font-size:13px;font-weight:800}
.deals-view-btn.is-active{background:#0f3460;color:#fff;box-shadow:0 2px 7px #102b4924}
.deals-view-btn:focus-visible{outline:3px solid #84adff;outline-offset:2px}
.deals-view-panel[hidden],#dealsRegistryView[hidden]{display:none!important}
.deal-kanban-board{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:13px;align-items:start}
.deal-kanban-column{min-width:0;background:#f3f6fa;border-radius:13px;border:1px solid #e1e8f0;padding:11px}
.deal-kanban-head{display:flex;flex-wrap:wrap;justify-content:space-between;gap:6px;margin-bottom:10px;color:#1c3b61}
.deal-kanban-head b{font-size:13px}.deal-kanban-head span{font-size:11px;color:#63758a}
.deal-kanban-empty{font-size:12px;color:#8794a6;margin:12px 4px}
.deal-kanban-card{padding:13px;border:1px solid #d9e2ec;border-radius:10px;background:#fff;margin-bottom:9px;box-shadow:0 3px 10px #12283a08}
.deal-kanban-card.finance-danger{border-left:4px solid #d92d20}.deal-kanban-card.finance-warning{border-left:4px solid #f6a72e}
.deal-kanban-title{display:block;font-size:13px;line-height:1.45;color:#142f57;font-weight:800;overflow-wrap:anywhere}
.deal-kanban-card p{color:#667085;font-size:12px;margin:7px 0}
.deal-kanban-values{display:grid;gap:6px;border-top:1px solid #edf1f5;padding-top:9px}
.deal-kanban-values>span{display:flex;justify-content:space-between;gap:9px;color:#67788d;font-size:11px}.deal-kanban-values b{color:#243650;text-align:right}
.deal-kanban-bottom{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;margin-top:12px}
.deal-kanban-bottom label{font-size:11px;color:#667085}.deal-kanban-bottom select{display:block;max-width:100%;padding:7px;border:1px solid #d0dbe8;border-radius:8px;background:#fff;color:#213a5a}
.deal-finance-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.deal-finance-tile{display:grid;gap:7px;padding:15px;border:1px solid #dfe6ef;border-radius:12px;background:#fff;min-width:0}
.deal-finance-tile span{font-size:12px;color:#667085}.deal-finance-tile strong{font-size:19px;color:#142f57;overflow-wrap:anywhere}.deal-finance-tile small{font-size:11px;color:#7f8a9a;line-height:1.4}
.deal-finance-detail{margin-top:12px;padding:18px;background:#fff;border:1px solid #dfe6ef;border-radius:12px}
.deal-finance-detail h3{margin:0 0 14px;font-size:17px}.deal-finance-line{display:grid;gap:7px;margin:15px 0}.deal-finance-line b{font-size:12px}.deal-finance-line small{color:#667085}
.deal-finance-track{height:9px;border-radius:6px;background:#edf2f7;overflow:hidden}
.deal-finance-track span{display:block;height:100%;background:#0f3460;border-radius:6px}
.deal-finance-track.actual span{background:#33a486}
.deal-finance-caution{margin-top:18px;border-top:1px solid #e4e9f0;padding-top:14px;font-size:12px;color:#667085;line-height:1.6}
@media(max-width:1050px){.deal-kanban-board{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:768px){.deal-kanban-board,.deal-finance-grid{grid-template-columns:minmax(0,1fr)}.deals-view-switch{display:flex;width:100%}.deals-view-btn{flex:1;padding:11px 6px}}
