/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    transition: all 0.3s ease-in-out;
}

body {
    background: linear-gradient(to right, #f3f9ff, #e6fff5);
    color: #333;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Container */
.container {
    max-width: 1200px;
    margin: auto;
    padding: 20px;
}

/* Header */
header {
    background: linear-gradient(135deg, #16a085, #1abc9c);
    color: white;
    padding: 20px 0;
    text-align: center;
    font-size: 26px;
    font-weight: bold;
    letter-spacing: 1px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Navigation */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 30px;
    background: #2ecc71;
    flex-wrap: wrap;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 0 0 12px 12px;
}

.navbar a {
    color: white;
    text-decoration: none;
    margin: 0 15px;
    font-size: 16px;
    font-weight: 500;
}

.navbar a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    padding: 8px 12px;
    border-radius: 5px;
}

/* Dashboard */
.dashboard {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    justify-content: center;
    padding: 40px 20px;
}

.card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    flex: 1;
    min-width: 280px;
    max-width: 350px;
    text-align: center;
    transition: transform 0.3s;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
}

.card h3 {
    font-size: 24px;
    margin-bottom: 12px;
    color: #27ae60;
}

.card p {
    font-size: 17px;
    color: #555;
}

/* Sidebar */
.sidebar {
    width: 250px;
    background: #1abc9c;
    color: white;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    padding: 25px 20px;
    overflow-y: auto;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
}

.sidebar h2 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 26px;
    font-weight: bold;
}

.sidebar ul {
    list-style: none;
    padding: 0;
}

.sidebar ul li {
    padding: 12px 18px;
    margin: 10px 0;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    transition: 0.3s;
}

.sidebar ul li a {
    color: white;
    text-decoration: none;
    display: block;
}

.sidebar ul li:hover {
    background: #16a085;
    transform: translateX(5px);
}

/* Buttons */
.button {
    display: inline-block;
    padding: 12px 24px;
    background: linear-gradient(to right, #27ae60, #2ecc71);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.button:hover {
    background: linear-gradient(to right, #2ecc71, #27ae60);
    transform: scale(1.05);
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 30px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
}

table, th, td {
    border: 1px solid #eee;
    padding: 14px;
    text-align: center;
}

th {
    background: #1abc9c;
    color: white;
    font-size: 16px;
}

td {
    background: #fff;
    color: #444;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    .dashboard {
        flex-direction: column;
        align-items: center;
    }

    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
        padding: 15px;
        text-align: center;
    }

    .sidebar ul {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
    }

    .sidebar ul li {
        display: inline-block;
        width: auto;
        margin: 5px;
        padding: 10px 14px;
    }

    .navbar {
        flex-direction: column;
        text-align: center;
    }

    .navbar a {
        margin: 10px 0;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    body {
        background: #111;
        color: #f4f7fc;
    }

    .card, .sidebar, .navbar, table {
        background: #222;
        color: #f4f7fc;
    }

    .navbar a, .sidebar ul li a {
        color: #f4f7fc;
    }

    th {
        background: #1abc9c;
    }

    td {
        background: #2a2a2a;
    }
}

.menu-toggle {
    display: none;
    font-size: 28px;
    color: white;
    cursor: pointer;
}

.nav-links {
    display: flex;
    list-style: none;
    flex-wrap: wrap;
    align-items: center;
}

.nav-links li {
    margin: 0 10px;
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        background-color: #34495e;
        width: 100%;
        position: absolute;
        top: 60px;
        left: 0;
        z-index: 1000;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        margin: 10px 0;
    }
}
