/* ========================================================
   CSS Modul Báo Cáo - bao_cao.css
   ======================================================== */

.baocao-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    flex-wrap: wrap;
    background: #ffffff;
    padding: 12px 16px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.baocao-toolbar-label {
    font-size: 13px;
    font-weight: 600;
    color: #4b5563;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* -- KPI Cards -- */
.baocao-kpi-row {
    row-gap: 12px !important;
    margin-bottom: 16px;
}

.baocao-kpi-card {
    border-radius: 10px;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    transition: transform 0.2s, box-shadow 0.2s;
    height: 100%;
}

.baocao-kpi-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.baocao-kpi-card .kpi-icon {
    font-size: 26px;
    opacity: 0.45;
    position: absolute;
    right: 16px;
    top: 14px;
}

.baocao-kpi-card .kpi-label {
    font-size: 13px;
    font-weight: 600;
    opacity: 0.8;
}

.baocao-kpi-card .kpi-value {
    font-size: 28px;
    font-weight: 700;
    line-height: 1.1;
}

.baocao-kpi-card .kpi-sub {
    font-size: 12px;
    opacity: 0.7;
    margin-top: 2px;
}

.kpi-tong {
    background: #f0f9ff;
    color: #0369a1;
    border-left: 4px solid #0284c7;
}

.kpi-dangxuly {
    background: #eff6ff;
    color: #1d4ed8;
    border-left: 4px solid #2563eb;
}

.kpi-hoanthanh {
    background: #ecfdf5;
    color: #047857;
    border-left: 4px solid #10b981;
}

.kpi-vipham {
    background: #fef2f2;
    color: #b91c1c;
    border-left: 4px solid #ef4444;
}

/* -- Khung Biểu đồ -- */
.baocao-chart-card {
    background: #ffffff;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    padding: 14px 16px;
    margin-bottom: 16px;
    height: 380px;
}

.baocao-chart-header {
    font-size: 14px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.baocao-chart-hint {
    font-size: 12px;
    color: #6b7280;
    font-weight: normal;
}

/* -- Drill-down Active Filter Bar -- */
.drilldown-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f3f4f6;
    padding: 8px 14px;
    border-radius: 6px;
    margin-bottom: 12px;
    font-size: 13px;
    border-left: 4px solid #3b82f6;
}

.drilldown-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #3b82f6;
    color: #ffffff;
    padding: 3px 10px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 12px;
}

.drilldown-clear-btn {
    cursor: pointer;
    font-weight: bold;
    margin-left: 4px;
    color: #ffffff;
    opacity: 0.8;
}

.drilldown-clear-btn:hover {
    opacity: 1;
}

/* -- Badge trạng thái hồ sơ -- */
.badge-status {
    font-size: 12px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 6px;
    display: inline-block;
}

.gs-huy { background: #fee2e2; color: #991b1b; }
.gs-nhap { background: #f3f4f6; color: #374151; }
.gs-cho-tiepnhan { background: #fff4e5; color: #92400e; }
.gs-da-tiepnhan { background: #e0edff; color: #1e40af; }
.gs-cho-chi-dao { background: #fdf4ff; color: #6b21a8; }
.gs-da-phan-hoi { background: #fff7ed; color: #c2410c; }
.gs-hoan-thanh { background: #e6f9ef; color: #166534; }
.gs-default { background: #f3f4f6; color: #374151; }

.badge-vipham {
    background: #fee2e2;
    color: #991b1b;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
}

.badge-khongvipham {
    background: #e6f9ef;
    color: #166534;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 6px;
}

.badge-chuaketqua {
    background: #f3f4f6;
    color: #6b7280;
    padding: 3px 8px;
    border-radius: 6px;
}
