* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Arial, sans-serif;
}

body {
    background-color: #f4f4f4;
    color: #333;
}

.container {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    background-color: #004d40;
    color: white;
    padding: 20px;
    position: fixed;
    height: 100%;
}

.sidebar h2 {
    margin-bottom: 30px;
    font-size: 1.5em;
}

.sidebar ul {
    list-style: none;
}

.sidebar ul li {
    margin: 15px 0;
}

.sidebar ul li a {
    color: white;
    text-decoration: none;
    font-size: 1.1em;
    transition: color 0.3s;
}

.sidebar ul li a:hover {
    color: #d81b60;
}

.main-content {
    margin-left: 250px;
    padding: 20px;
    width: calc(100% - 250px);
}

h1 {
    font-size: 2em;
    margin-bottom: 20px;
    color: #004d40;
}

.kpi-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.kpi-card {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

.kpi-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.kpi-card h3 {
    font-size: 1.2em;
    margin-bottom: 10px;
    color: #004d40;
}

.kpi-card p {
    font-size: 1.5em;
    font-weight: bold;
    color: #d81b60;
}

.map {
    height: 400px;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.charts-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 

System: 1fr));
    gap: 20px;
}

.chart-card {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.chart-card h3 {
    font-size: 1.2em;
    margin-bottom: 10px;
    color: #004d40;
}

/* Ensure only active sections are visible */
.dashboard, .project-details, .project-list, .ministry-list, .sector-list, .add-project, .advanced-analytics, .mobile-view {
    display: none;
}

.active {
    display: block !important;
}

.project-info p {
    margin: 10px 0;
    font-size: 1.1em;
}

.progress-bar {
    width: 100%;
    height: 20px;
    background-color: #e0e0e0;
    border-radius: 10px;
    overflow: hidden;
    margin: 20px 0;
}

.progress-bar div {
    height: 100%;
    background-color: #d81b60;
    width: var(--progress-width);
    transition: width 0.5s ease-in-out;
}

table {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

th {
    background-color: #004d40;
    color: white;
}

tr:nth-child(even) {
    background-color: #f9f9f9;
}

input, select, textarea {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1em;
}

textarea {
    height: 100px;
    resize: vertical;
}

button {
    background-color: #d81b60;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #b01550;
}

.custom-marker.completed {
    background-color: #28a745;
    border-radius: 50%;
    width: 12px;
    height: 12px;
}

.custom-marker.in-progress {
    background-color: #ffc107;
    border-radius: 50%;
    width: 12px;
    height: 12px;
}

.custom-marker.delayed {
    background-color: #dc3545;
    border-radius: 50%;
    width: 12px;
    height: 12px;
}

@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        position: static;
        padding: 10px;
    }

    .main-content {
        margin-left: 0;
        width: 100%;
        padding: 10px;
    }

    .kpi-container, .charts-container {
        grid-template-columns: 1fr;
    }

    .map {
        height: 300px;
    }
}

.pivot-table th {
    background-color: #004d40;
    color: white;
}

.ministry-drill-down {
    margin-top: 20px;
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}