.dashboard-page,
.dashboard-page * {
    box-sizing: border-box;
    font-family: "Segoe UI", Arial, sans-serif;
}

.dashboard-page {
    background: #f5f8fc;
    color: #1e293b;
    padding: 25px 0;
}

    .dashboard-page .container {
        width: 95%;
        margin: 0 auto;
    }

    /* ===========================
   HEADER
=========================== */

    .dashboard-page .toolbar {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 30px;
    }

    .dashboard-page .toolbar-left h2 {
        font-size: 28px;
        color: #334155;
    }

    .dashboard-page .toolbar-right {
        display: flex;
        align-items: center;
        gap: 18px;
    }

    .dashboard-page .toolbar select,
    .dashboard-page .toolbar input {
        height: 56px;
        min-width: 180px;
        border: 1px solid #d7dde6;
        border-radius: 14px;
        background: white;
        padding: 0 18px;
        font-size: 18px;
        outline: none;
        transition: .25s;
    }

        .dashboard-page .toolbar select:focus,
        .dashboard-page .toolbar input:focus {
            border-color: #3b82f6;
            box-shadow: 0 0 0 3px rgba(59, 130, 246, .12);
        }

    /* ===========================
   GRID
=========================== */

    .dashboard-page .kpi-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 28px;
    }

    /* ===========================
   CARD
=========================== */

    .dashboard-page .kpi-card {
        background: #fff;
        border-radius: 16px;
        border: 1px solid #e4eaf3;
        padding: 26px 30px;
        min-height: 130px;
        transition: .25s;
        box-shadow: 0 2px 8px rgba(0, 0, 0, .05);
    }

        .dashboard-page .kpi-card:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 18px rgba(0, 0, 0, .08);
        }

    .dashboard-page .kpi-title {
        font-size: 15px;
        font-weight: 600;
        color: #64748b;
        letter-spacing: 1px;
        margin-bottom: 12px;
    }

    .dashboard-page .kpi-value {
        font-size: 48px;
        font-weight: 700;
        color: #172033;
        line-height: 1;
    }

    .dashboard-page .kpi-change {
        margin-top: 12px;
        font-size: 14px;
        font-weight: 600;
    }

    .dashboard-page .positive {
        color: #16a34a;
    }

    .dashboard-page .negative {
        color: #ef4444;
    }

/* ===========================
   RESPONSIVE
=========================== */

@media(max-width:1300px) {
    .dashboard-page .kpi-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media(max-width:768px) {
    .dashboard-page .toolbar {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .dashboard-page .toolbar-right {
        width: 100%;
        flex-wrap: wrap;
    }

    .dashboard-page .toolbar select,
    .dashboard-page .toolbar input {
        flex: 1;
        min-width: 180px;
    }

    .dashboard-page .kpi-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-page .kpi-value {
        font-size: 38px;
    }
}

/* ===========================================================
   CHART SECTION
=========================================================== */

.dashboard-page .chart-grid {
    margin-top: 32px;
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 28px;
}

.dashboard-page .chart-card {
    background: white;
    border: 1px solid #e5edf5;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,.05);
    padding: 24px;
    display: flex;
    flex-direction: column;
}

.dashboard-page .chart-card-tall {
    height: 720px;
}

.dashboard-page .chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}

.dashboard-page .chart-title {
    font-size: 18px;
    font-weight: 700;
    color: #1e293b;
}

.dashboard-page .chart-subtitle {
    margin-top: 4px;
    font-size: 14px;
    color: #64748b;
}

.dashboard-page .chart-header select {
    height: 40px;
    padding: 0 14px;
    border: 1px solid #dbe4ef;
    border-radius: 8px;
    background: #f8fafc;
    color: #475569;
    cursor: pointer;
}

/* =========================
      PIE
========================= */

.dashboard-page .pie-wrapper {
    width: 280px;
    margin: 0 auto;
    flex-shrink: 0;
}

.dashboard-page .pie-legend-wrapper {
    flex: 1;
    overflow-y: auto;
    margin-top: 20px;
    padding-right: 6px;
    min-height: 0;
}

.dashboard-page .pie-wrapper canvas {
    width: 280px !important;
    height: 280px !important;
}

.dashboard-page .pie-legend {
    margin-top: 0;
}

.dashboard-page .pie-legend-wrapper::-webkit-scrollbar {
    width: 6px;
}

.dashboard-page .pie-legend-wrapper::-webkit-scrollbar-thumb {
    background: #d0d7e2;
    border-radius: 20px;
}

.dashboard-page .pie-legend-wrapper::-webkit-scrollbar-track {
    background: transparent;
}

.dashboard-page .legend-item {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.dashboard-page .legend-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    margin-right: 12px;
}

.dashboard-page .legend-name {
    flex: 1;
    color: #475569;
    font-size: 16px;
}

.dashboard-page .legend-percent {
    width: 60px;
    text-align: right;
    font-weight: 600;
    color: #1e293b;
}

.dashboard-page .legend-value {
    width: 70px;
    text-align: right;
    font-weight: 700;
    color: #1e293b;
}

/* =========================
      BAR
========================= */

.dashboard-page .bar-wrapper {
    height: 420px;
    margin-top: 18px;
}

    .dashboard-page .bar-wrapper canvas {
        width: 100% !important;
        height: 100% !important;
    }

/* =========================
      RESPONSIVE
========================= */

@media (max-width:1200px) {
    .dashboard-page .chart-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width:768px) {
    .dashboard-page .pie-wrapper {
        width: 220px;
    }

        .dashboard-page .pie-wrapper canvas {
            width: 220px !important;
            height: 220px !important;
        }
}


.dashboard-page .revenue-pie-content {
    display: grid;
    grid-template-columns: 220px 1fr;
    align-items: center;
    gap: 36px;
    margin-top: 20px;
}

.dashboard-page .revenue-pie-wrapper {
    width: 220px;
    height: 220px;
    display: flex;
    justify-content: center;
    align-items: center;
}

    .dashboard-page .revenue-pie-wrapper canvas {
        width: 220px !important;
        height: 220px !important;
    }

.dashboard-page .revenue-legend {
    width: 100%;
}

.dashboard-page .revenue-item {
    display: grid;
    grid-template-columns: 1fr 60px 60px;
    gap: 20px;
    align-items: center;
    margin-bottom: 28px;
}

.dashboard-page .revenue-name {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.5;
}

.dashboard-page .revenue-percent {
    text-align: right;
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
}

.dashboard-page .revenue-value {
    text-align: right;
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
}

/* ===========================
   REVENUE DISTRIBUTION
=========================== */

.dashboard-page .revenue-grid {
    margin-top: 32px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
}

.dashboard-page .salary-chart {
    margin-top: 32px;
}

/* ===========================================================
   RECENT ACTIVITY
=========================================================== */

.dashboard-page .bottom-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 28px;
    margin-top: 32px;
}

.dashboard-page .activity-card,
.dashboard-page .warning-card {
    background: #fff;
    border: 1px solid #e5edf5;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .05);
}

/* =========================
      HEADER
========================= */

.dashboard-page .activity-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 26px 30px;
    border-bottom: 1px solid #eef2f7;
}

    .dashboard-page .activity-header h3 {
        font-size: 20px;
        font-weight: 700;
        color: #1e293b;
    }

    .dashboard-page .activity-header i {
        color: #64748b;
        cursor: pointer;
    }

/* =========================
      TABLE
========================= */

.dashboard-page .activity-table {
    width: 100%;
    border-collapse: collapse;
}

    .dashboard-page .activity-table th {
        padding: 18px 14px;
        font-size: 13px;
        font-weight: 700;
        color: #64748b;
        text-align: left;
        border-bottom: 1px solid #eef2f7;
        letter-spacing: .5px;
    }

    .dashboard-page .activity-table td {
        padding: 20px 14px;
        border-bottom: 1px solid #f1f5f9;
        vertical-align: middle;
        font-size: 14px;
        color: #334155;
    }

    .dashboard-page .activity-table tbody tr:hover {
        background: #fafcff;
    }

/* =========================
      COLUMN
========================= */

.dashboard-page .time {
    color: #94a3b8;
    line-height: 1.7;
    font-size: 13px;
}

.dashboard-page .employee strong {
    display: block;
    color: #1e293b;
    margin-bottom: 4px;
}

.dashboard-page .employee small {
    color: #94a3b8;
}

.dashboard-page .badge {
    display: inline-block;
    padding: 7px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

    .dashboard-page .badge.green {
        background: #DCFCE7;
        color: #15803D;
    }

    .dashboard-page .badge.blue {
        background: #DBEAFE;
        color: #2563EB;
    }

    .dashboard-page .badge.orange {
        background: #FEF3C7;
        color: #D97706;
    }

.dashboard-page .action-user {
    color: #94a3b8;
}

/* =========================
      FOOTER
========================= */

.dashboard-page .activity-footer {
    text-align: center;
    padding: 22px;
}

    .dashboard-page .activity-footer a {
        color: #2563EB;
        font-weight: 700;
        text-decoration: none;
    }

        .dashboard-page .activity-footer a:hover {
            text-decoration: underline;
        }

/* ===========================================================
   WARNING
=========================================================== */

.dashboard-page .warning-card {
    padding: 28px;
}

.dashboard-page .warning-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 28px;
}

.dashboard-page .warning-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    border-radius: 12px;
    padding: 18px;
    margin-bottom: 18px;
    border-left: 4px solid;
}

    .dashboard-page .warning-item.red {
        background: #FEF2F2;
        border-color: #EF4444;
    }

    .dashboard-page .warning-item.blue {
        background: #EFF6FF;
        border-color: #3B82F6;
    }

    .dashboard-page .warning-item.orange {
        background: #FFF7ED;
        border-color: #F59E0B;
    }

    .dashboard-page .warning-item i {
        margin-top: 4px;
        font-size: 18px;
    }

    .dashboard-page .warning-item.red i {
        color: #EF4444;
    }

    .dashboard-page .warning-item.blue i {
        color: #2563EB;
    }

    .dashboard-page .warning-item.orange i {
        color: #D97706;
    }

.dashboard-page .warning-content {
    flex: 1;
}

    .dashboard-page .warning-content h4 {
        font-size: 16px;
        font-weight: 700;
        margin-bottom: 6px;
        color: #1e293b;
    }

    .dashboard-page .warning-content p {
        color: #64748b;
        font-size: 14px;
        line-height: 1.5;
    }

.dashboard-page .warning-btn {
    width: 100%;
    height: 48px;
    margin-top: 20px;
    background: #fff;
    border: 1px solid #dbe4ef;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 700;
    color: #475569;
    cursor: pointer;
    transition: .25s;
}

    .dashboard-page .warning-btn:hover {
        background: #f8fafc;
    }

/* =========================
      RESPONSIVE
========================= */

@media(max-width:1200px) {
    .dashboard-page .bottom-grid {
        grid-template-columns: 1fr;
    }
}

/* =========================
      TABLE WIDTH
========================= */
.dashboard-page .activity-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

    .dashboard-page .activity-table th:nth-child(1),
    .dashboard-page .activity-table td:nth-child(1) {
        width: 140px;
    }

    .dashboard-page .activity-table th:nth-child(2),
    .dashboard-page .activity-table td:nth-child(2) {
        width: 170px;
    }

    .dashboard-page .activity-table th:nth-child(3),
    .dashboard-page .activity-table td:nth-child(3) {
        width: 180px;
    }

    .dashboard-page .activity-table th:nth-child(4),
    .dashboard-page .activity-table td:nth-child(4) {
        width: 380px;
    }

    .dashboard-page .activity-table th:nth-child(5),
    .dashboard-page .activity-table td:nth-child(5) {
        width: 180px;
    }

.dashboard-page .kpi-value-small {
    font-size: 36px;
    font-weight: 700;
    line-height: 1.2;
}

.dashboard-page .warning-item {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 18px;
    margin-bottom: 16px;
    border-radius: 12px;
    background: #fafafa;
    position: relative;
}

.dashboard-page .warning-left {
    width: 5px;
    align-self: stretch;
    border-radius: 8px;
}

.dashboard-page .warning-icon {
    width: 42px;
    text-align: center;
    font-size: 28px;
}

.dashboard-page .warning-content {
    flex: 1;
}

.dashboard-page .warning-name {
    font-size: 17px;
    font-weight: 700;
    color: #1e293b;
}

.dashboard-page .warning-desc {
    margin-top: 4px;
    color: #64748b;
    font-size: 15px;
}