/* dash_kit.css - shared look for all dashboards (KPI tiles, panels, range bar, bars list) */
.dk-wrap { width: 100%; }
.dk-head { display:flex; align-items:flex-end; justify-content:space-between; gap:12px; flex-wrap:wrap; margin: 4px 0 16px; }
.dk-sub { color: var(--muted, #6b7a8c); font-size: 13px; margin-top: 2px; }

.dk-kpis { display:grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 18px; }
.dk-kpi { background: var(--surface, #fff); border: 1px solid var(--line, #dde4ec); border-radius: 12px; padding: 14px 16px 12px; position: relative; overflow: hidden; }
.dk-kpi::before { content:""; position:absolute; left:0; top:0; bottom:0; width:4px; background: var(--dk-accent, #1d5fb8); }
.dk-kpi.t-ok { --dk-accent:#0f9d8a; } .dk-kpi.t-warn { --dk-accent:#d99a1b; } .dk-kpi.t-bad { --dk-accent:#c2453a; } .dk-kpi.t-violet { --dk-accent:#6a52b3; }
.dk-kpi-label { font-size: 12.5px; color: var(--muted, #6b7a8c); font-weight: 600; }
.dk-kpi-value { font-size: 26px; font-weight: 800; color: var(--ink, #0e2238); font-variant-numeric: tabular-nums; margin-top: 4px; line-height: 1.15; }
.dk-kpi-foot { display:flex; align-items:center; justify-content:space-between; gap:8px; margin-top: 8px; min-height: 26px; }
.dk-delta { font-size: 12px; font-weight: 700; padding: 2px 7px; border-radius: 20px; white-space: nowrap; }
.dk-delta.up { background:#e3f5f1; color:#0b7a6a; } .dk-delta.down { background:#fbe9e7; color:#a8372d; } .dk-delta.flat { background:#eef1f5; color:#6b7a8c; }
.dk-delta.inv.up { background:#fbe9e7; color:#a8372d; } .dk-delta.inv.down { background:#e3f5f1; color:#0b7a6a; }
.dk-delta-note { font-size: 11.5px; color: var(--muted, #6b7a8c); }
.dk-spark { width: 86px; height: 26px; flex: none; }

.dk-grid { display:grid; gap: 14px; margin-bottom: 14px; }
.dk-grid.g2 { grid-template-columns: 2fr 1fr; } .dk-grid.g11 { grid-template-columns: 1fr 1fr; }
@media (max-width: 900px) { .dk-grid.g2, .dk-grid.g11 { grid-template-columns: 1fr; } }
.dk-panel { background: var(--surface, #fff); border: 1px solid var(--line, #dde4ec); border-radius: 12px; padding: 14px 16px; min-width: 0; }
.dk-panel-title { font-size: 14px; font-weight: 700; color: var(--ink, #0e2238); margin-bottom: 2px; }
.dk-panel-note { font-size: 12px; color: var(--muted, #6b7a8c); margin-bottom: 10px; }
.dk-chart-box { position: relative; height: 260px; }
.dk-chart-box.tall { height: 320px; }

.dk-range { display:flex; gap:6px; flex-wrap:wrap; align-items:center; }
.dk-range button { background: var(--surface, #fff); color: var(--text, #26323f); border:1px solid var(--line, #dde4ec); border-radius: 20px; padding: 5px 12px; font-size: 12.5px; font-weight:600; cursor:pointer; }
.dk-range button:hover { border-color: var(--sapphire, #1d5fb8); color: var(--sapphire, #1d5fb8); }
.dk-range button.on { background: var(--sapphire, #1d5fb8); border-color: var(--sapphire, #1d5fb8); color:#fff; }
.dk-range input[type=date] { padding: 4px 8px; font-size: 12.5px; }

.dk-bars { display:flex; flex-direction:column; gap: 9px; }
.dk-bar-row { display:grid; grid-template-columns: minmax(90px, 36%) 1fr auto; gap:10px; align-items:center; font-size: 13px; }
.dk-bar-name { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color: var(--text, #26323f); }
.dk-bar-track { background: var(--sapphire-soft, #e8f0fb); border-radius: 5px; height: 10px; overflow:hidden; }
.dk-bar-fill { height:100%; background: var(--dk-bar, #1d5fb8); border-radius: 5px; min-width: 2px; }
.dk-bar-val { font-variant-numeric: tabular-nums; font-weight:700; color: var(--ink, #0e2238); }

.dk-stack { display:flex; height: 14px; border-radius: 7px; overflow:hidden; background:#eef1f5; }
.dk-stack > span { display:block; height:100%; }
.dk-legend { display:flex; flex-wrap:wrap; gap: 6px 16px; margin-top: 10px; font-size: 12.5px; }
.dk-legend i { display:inline-block; width:10px; height:10px; border-radius:3px; margin-right:6px; vertical-align:-1px; }
.dk-legend b { font-variant-numeric: tabular-nums; }

.dk-num { text-align:right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dk-table th.dk-num { text-align:right; }
.dk-empty { color: var(--muted, #6b7a8c); font-size: 13px; padding: 18px 0; text-align:center; }
.dk-neg { color: #a8372d; } .dk-pos { color: #0b7a6a; }
@media print { .dk-range, .no-print { display:none !important; } .dk-panel, .dk-kpi { break-inside: avoid; } }