/*=====================================
            RESET
=====================================*/

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background: #f4f7fc;
    color: #333;
    line-height: 1.6;
}

/*=====================================
            HEADER
=====================================*/

header {
    background: #0b1033;
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 60px;
    flex-wrap: wrap;
}

.logo h1 {
    font-size: 42px;
    font-weight: 700;
}

.logo span {
    color: #ffb400;
}

.logo p {
    margin-top: 5px;
    color: #ddd;
    font-size: 15px;
}

/*=====================================
        HEADER RIGHT
=====================================*/

.header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 15px;
}

.top-links {
    display: flex;
    gap: 20px;
}

.top-links a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    transition: .3s;
}

.top-links a:hover {
    color: #ffb400;
}

/*=====================================
            SEARCH
=====================================*/
.dashboard-search {
    display: flex;
    align-items: center;
}

.dashboard-search input {
    width: 250px;
    height: 42px;
    padding: 0 12px;
    border: none;
    outline: none;
    border-radius: 10px 0 0 10px;
}

.dashboard-search button {
    width: 95px;
    height: 42px;
    border: none;
    cursor: pointer;
    color: #fff;
    font-weight: 600;
    border-radius: 0 10px 10px 0;
    background: linear-gradient(135deg, #6d45ff, #ff4f7b, #ff8b3d);
}

/*=====================================
            NAVBAR
=====================================*/

.navbar {
    background: #16215f;
    display: flex;
    align-items: center;
    padding: 0 30px;
    gap: 10px;
}

.navbar a {
    color: #fff;
    text-decoration: none;
    padding: 16px 20px;
    font-size: 16px;
    /* Same size for all */
    font-weight: 500;
    /* Same weight for all */
    font-family: 'Poppins', sans-serif;
    line-height: 1;
    background: none;
    border: none;
    transition: .3s;
}

.navbar a:hover {
    color: #ffb400;
}

.navbar a.active {
    color: #ffb400;
    background: none;
}


/*=====================================
          PAGE TITLE
=====================================*/

.page-title {
    text-align: center;
    padding: 45px 20px;
}

.page-title h2 {
    color: #16215f;
    font-size: 42px;
    margin-bottom: 10px;
}

.page-title h2 i {
    color: #ff9800;
    margin-right: 10px;
}

.page-title p {
    color: #666;
    font-size: 18px;
}

/*=====================================
        FILTER SECTION
=====================================*/

.dashboard-filter {
    width: 94%;
    margin: auto;
    background: #fff;
    padding: 30px;
    border-radius: 18px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, .10);
    margin-bottom: 40px;
}

/*=====================================
        RADIO BUTTONS
=====================================*/

.radio-box {
    display: flex;
    gap: 35px;
    margin-bottom: 25px;
}

.radio-box label {
    font-size: 17px;
    font-weight: 600;
    color: #16215f;
}

.radio-box input {
    margin-right: 8px;
}

/*=====================================
        FILTER GRID
=====================================*/

.filter-box {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    align-items: end;
}

.filter-item {
    display: flex;
    flex-direction: column;
}

.filter-item label {
    margin-bottom: 8px;
    font-weight: 600;
    color: #16215f;
}

.filter-item input,
.filter-item select {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 10px;
    outline: none;
    font-size: 15px;
    transition: .3s;
}

.filter-item input:focus,
.filter-item select:focus {
    border-color: #6d45ff;
}

/*=====================================
        DASHBOARD CONTAINER
=====================================*/

.dashboard-container {
    width: 94%;
    margin: 0 auto 40px;
}

/*=====================================
        STATISTICS
=====================================*/

.statistics {
    width: 94%;
    margin: 40px auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 25px;
}

.stat-box {
    background: #fff;
    border-radius: 18px;
    text-align: center;
    padding: 30px 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, .08);
    transition: .3s;
}

.stat-box:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, .15);
}

.stat-box i {
    font-size: 42px;
    color: #6d45ff;
    margin-bottom: 15px;
}

.stat-box h2 {
    color: #16215f;
    font-size: 32px;
    margin-bottom: 8px;
}

.stat-box p {
    color: #666;
    font-size: 16px;
}

/* Different icon colors */

.stat-box:nth-child(2) i {
    color: #ff4f7b;
}

.stat-box:nth-child(3) i {
    color: #00c853;
}

.stat-box:nth-child(4) i {
    color: #ff9800;
}

.stat-box:nth-child(5) i {
    color: #2979ff;
}

.stat-box:nth-child(6) i {
    color: #9c27b0;
}

/*=====================================
        DASHBOARD TABLE
=====================================*/

.dashboard-table {
    width: 94%;
    margin: 40px auto;
    background: #fff;
    border-radius: 18px;
    padding: 25px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, .08);
    overflow-x: auto;
}

.dashboard-table h2 {
    color: #16215f;
    margin-bottom: 20px;
    font-size: 28px;
}

.dashboard-table table {
    width: 100%;
    border-collapse: collapse;
}

.dashboard-table thead {
    background: #16215f;
}

.dashboard-table th {
    color: #fff;
    padding: 16px;
    text-align: left;
    font-size: 16px;
}

.dashboard-table td {
    padding: 16px;
    border-bottom: 1px solid #eee;
    font-size: 15px;
}

.dashboard-table tr:hover {
    background: #f7f9ff;
}

/*=====================================
        STATUS BADGES
=====================================*/

.pending,
.active,
.completed {
    color: #fff;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

.pending {
    background: #ff9800;
}

.active {
    background: #00c853;
}

.completed {
    background: #2979ff;
}

/*=====================================
        SUMMARY SECTION
=====================================*/

.summary-section {
    width: 94%;
    margin: 60px auto;
}

.summary-section h2 {
    text-align: center;
    color: #16215f;
    margin-bottom: 35px;
    font-size: 34px;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.summary-card {
    background: #fff;
    border-radius: 18px;
    text-align: center;
    padding: 35px 25px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, .08);
    transition: .3s;
}

.summary-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 18px 35px rgba(0, 0, 0, .15);
}

.summary-card i {
    font-size: 48px;
    color: #6d45ff;
    margin-bottom: 18px;
}

.summary-card:nth-child(2) i {
    color: #ff4f7b;
}

.summary-card:nth-child(3) i {
    color: #00c853;
}

.summary-card:nth-child(4) i {
    color: #ff9800;
}

.summary-card h3 {
    color: #16215f;
    margin-bottom: 10px;
}

.summary-card h1 {
    color: #ff4f7b;
    font-size: 42px;
    margin-bottom: 12px;
}

.summary-card p {
    color: #666;
    font-size: 15px;
    line-height: 1.7;
}

/*=====================================
        LATEST UPDATES
=====================================*/

.updates-section {
    width: 94%;
    margin: 60px auto;
}

.updates-section h2 {
    text-align: center;
    font-size: 34px;
    color: #16215f;
    margin-bottom: 35px;
}

.updates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.update-card {
    background: #fff;
    border-radius: 18px;
    padding: 20px; /* Reduced padding for tighter layout */
    box-shadow: 0 8px 20px rgba(0, 0, 0, .08);
    transition: .3s;
}

.update-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 18px 35px rgba(0, 0, 0, .15);
}

.update-card i {
    font-size: 42px;
    margin-bottom: 18px;
}

.update-card:nth-child(1) i {
    color: #45ff9f;
}

.update-card:nth-child(2) i {
    color: #ff4f7b;
}

.update-card:nth-child(3) i {
    color: #00c853;
}

.update-card h3 {
    color: #16215f;
    margin-bottom: 15px;
    font-size: 18px; /* Smaller heading for updates */
}

.update-card p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
    font-size: 13px; /* Adjusted paragraph size */
}

.update-card span {
    display: inline-block;
    padding: 8px 15px;
    background: #eef2ff;
    color: #16215f;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
}

/*=====================================
            VIEW BUTTON
=====================================*/

.view-btn {
    border: none;
    cursor: pointer;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    padding: 13px 28px;
    border-radius: 10px;
    background: linear-gradient(135deg, #6d45ff, #ff4f7b, #ff8b3d);
    transition: .3s;
}

.view-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, .18);
}

/*=====================================
            FOOTER
=====================================*/

footer {
    margin-top: 70px;
    background: #0b1033;
    color: #fff;
    text-align: center;
    padding: 40px 20px;
}

footer h3 {
    font-size: 32px;
    margin-bottom: 12px;
}

footer span {
    color: #ffb400;
}

footer p {
    color: #ddd;
    margin-top: 10px;
    font-size: 15px;
}


/*=====================================
        ACTIVITY FEED MODAL
=====================================*/

.feed-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(22, 33, 95, 0.6);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.feed-modal-content {
    background-color: #f8fafc;
    margin: 5% auto;
    padding: 30px;
    border-radius: 20px;
    width: 90%;
    max-width: 1000px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.feed-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 15px;
    margin-bottom: 25px;
}

.feed-modal-header h2 {
    color: #16215f;
    font-size: 28px;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.feed-modal-header h2 i {
    color: #6d45ff;
}

.feed-close-btn {
    color: #64748b;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s;
}

.feed-close-btn:hover {
    color: #ef4444;
}

.feed-modal-body {
    max-height: 60vh;
    overflow-y: auto;
    padding: 10px 5px;
}

/* Pagination container */
.feed-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 25px;
    padding-top: 15px;
    border-top: 2px solid #e2e8f0;
}

.feed-pagination-btn {
    border: none;
    background: #eef2ff;
    color: #16215f;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 5px;
}

.feed-pagination-btn:hover:not(:disabled) {
    background: #6d45ff;
    color: #fff;
}

.feed-pagination-btn:disabled {
    background: #f1f5f9;
    color: #cbd5e1;
    cursor: not-allowed;
}

.feed-page-info {
    font-weight: 600;
    color: #475569;
}

/*=====================================
        RESPONSIVE
=====================================*/

@media(max-width:992px) {

    header {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .header-right {
        align-items: center;
    }

    .search-box {
        width: 100%;
    }

    .search-box input {
        width: 100%;
    }

    .navbar {
        flex-wrap: wrap;
        justify-content: center;
    }

    .page-title h2 {
        font-size: 34px;
    }

    .filter-box {
        grid-template-columns: 1fr;
    }

    .radio-box {
        flex-direction: column;
        gap: 10px;
    }

    .statistics {
        grid-template-columns: repeat(2, 1fr);
    }

    .summary-grid {
        grid-template-columns: 1fr;
    }

    .updates-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-table {
        overflow-x: auto;
    }

}

@media(max-width:576px) {

    header {
        padding: 18px 16px;
    }

    .top-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 12px;
    }

    .statistics {
        grid-template-columns: 1fr;
    }

    .logo h1 {
        font-size: clamp(24px, 7vw, 32px);
    }

    .page-title h2 {
        font-size: 26px;
    }

    .dashboard-table h2,
    .summary-section h2,
    .updates-section h2 {
        font-size: 24px;
    }

    .search-box {
        flex-direction: column;
    }

    .search-box input {
        border-radius: 10px;
        margin-bottom: 10px;
    }

    .search-box button {
        border-radius: 10px;
    }

    .view-btn {
        width: 100%;
    }

    .dashboard-table {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .chart-card {
        padding: 16px 14px;
        height: auto;
        min-height: 320px;
    }

}


/* Chart grid layout */
.charts {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin: 15px;
    align-items: stretch;
}

/* Individual chart container */
.chart-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 22px 24px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    height: 380px;
    color: #ffb400;
}

/* Canvas sizing within card */
.charts canvas {
    width: 100%;
    height: 50%; /* Reduced height for better fit */
    object-fit: contain;
}

@media (max-width: 992px) {
    .charts { grid-template-columns: 1fr; }
}