html, body {
    height: 100%; /* Ensure the page takes full height */
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

    /* General Reset & Body */
    body {
        font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
        background-color: #f5f7fa;
        margin: 0;
        height: 100vh;
        overflow-x: hidden;
    }

    /* Flex container for sidebar + main */
    .d-flex {
        display: flex;
        min-height: 100vh;
    }

.main-content {
    margin-left: 250px; /* Same as sidebar width */
    padding: 40px 50px;
    flex-grow: 1;
    background-color: #fff;
    min-height: 100vh;
    box-shadow: inset 0 0 20px rgb(0 0 0 / 0.05);
}

.sidebar {
    width: 250px;
    background-color: #2c3e50;
    color: white;
    padding: 30px 20px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
    position: fixed;
    height: 100vh;
}

.sidebar h3 {
    font-weight: 600;
    margin-bottom: 30px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.sidebar .nav-item {
    width: 100%;
}

.sidebar .nav-link {
    color: #bdc3c7;
    font-weight: 500;
    padding: 12px 15px;
    border-radius: 8px;
    transition: background-color 0.3s ease, color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.sidebar .nav-link i {
    margin-right: 10px;
    font-size: 1.65rem;
}

.sidebar .nav-link:hover,
.sidebar .nav-link.active {
    background-color: #e67e22;
    color: white;
}

/* Sidebar active link styles */
.sidebar .nav-link.active {
    background-color: #ffffff;
    height: 55px;
    color: #000000;
    font-weight: 700;
    font-size: 1.1rem; /* Slightly enlarge */
    border-radius: 10px;
    display: flex;
    align-items: center;
    margin-top: 10px;
    margin-bottom: 10px;
}

.sidebar .logout {
    margin-top: 200px;
    width: 100%;
}

.sidebar .logout .nav-link {
    color: #ffffff;
    font-size: 1rem;
    padding: 15px 20px;
    display: flex;
    align-items: center;
}

.sidebar .logout a {
    color: #e74c3c;
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 15px;
    border-radius: 8px;
    transition: background-color 0.3s ease;
}

.sidebar .logout a:hover {
    background-color: #c0392b;
    color: white;
}

/* Header Styles */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    margin-left: 30px; /*Offset to start next to the sidebar */
    background-color: #f8f9fa;
    border-bottom: 1px solid #ddd;
    width: calc(100%-250px); /* Adjust width to account for sidebar */
}

.header h1 {
    margin: 0;
}

.profile-photo {
    width: 40px;
    height: 40px;
    margin-left: 1540px;
    border-radius: 50%;
    object-fit: cover;
}

.dropdown-menu {
    right: 0;
    left: auto;
}

@media (max-width: 768px) {
    .container-fluid {
        margin-left: 0;
    }
    .sidebar {
        width: 100px;
        position: relative;
        height: auto;
    }

    .table {
        width: 100px;
    }

}