/* General Page Styling */
body {
    display: flex;
    min-height: 100vh;
    overflow-x: hidden;
    margin: 0;
}

/* Sidebar */
.sidebar {
    width: 250px;
    height: 100vh;
    background: #343a40;
    color: white;
    position: fixed;
    transition: all 0.3s;
    padding-top: 20px;
}

.sidebar h4 {
    text-align: center;
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 20px;
}

.sidebar a {
    color: white;
    text-decoration: none;
    padding: 15px;
    display: flex;
    align-items: center;
    transition: 0.3s;
}

.sidebar a:hover {
    background: #495057;
}

.sidebar i {
    margin-right: 10px;
}

/* Main Content */
.content {
    margin-left: 250px;
    padding: 20px;
    width: 100%;
    transition: margin-left 0.3s;
}

/* Toggle Button */
.toggle-btn {
    position: absolute;
    top: 15px;
    left: 270px;
    background: #343a40;
    color: white;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    transition: all 0.3s;
}

.toggle-btn:hover {
    background: #495057;
}

/* Hide sidebar when toggled */
.sidebar.hide {
    width: 0;
    padding: 0;
    overflow: hidden;
}

.content.expanded {
    margin-left: 0;
}

@media (max-width: 768px) {
    .sidebar {
        width: 80px;
    }
    .sidebar a span {
        display: none;
    }
    .content {
        margin-left: 80px;
    }
    .toggle-btn {
        left: 90px;
    }
}
/* Login Page Styling */
.login-body {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: linear-gradient(to right,  #4c5669, #0f1420);
}

.login-container {
    width: 100%;
    max-width: 400px;
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
    text-align: center;
}

.login-container h2 {
    margin-bottom: 20px;
    color: #182848;
}

.input-group-text {
    background: #4b6cb7;
    color: white;
    border: none;
}

.form-control {
    border-left: none;
}

.form-control:focus {
    box-shadow: none;
    border-color: #4b6cb7;
}

.btn-primary {
    background: #4b6cb7;
    border: none;
    transition: 0.3s;
}

.btn-primary:hover {
    background: #182848;
}

/* Style for dropdown container */

/* Sidebar: Fixed with Scroll (No Horizontal Scroll) */
.sidebar {
    position: fixed;
    width: 250px;
    height: 100vh;
    background: #343a40;
    color: white;
    padding-top: 20px;
    overflow-y: auto; /* Enables vertical scrolling */
    overflow-x: hidden; /* Prevents horizontal scrolling */
    scrollbar-width: thin; /* Firefox scrollbar */
    scrollbar-color: #888 #343a40; /* Scrollbar styling */
}

/* Custom scrollbar for Chrome, Edge, Safari */
.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: #343a40;
}

.sidebar::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Dropdown Wrapper */
.sidebar .dropdown-container {
    position: relative;
}

/* Dropdown (hidden by default) */
.sidebar .dropdown {
    display: none;
    position: absolute;
    left: 0;
    top: 100%; /* Positions dropdown directly below parent */
    background: white;
    min-width: 100%;
    border-radius: 5px;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 10; /* Ensures it's above other content */
}

/* Show dropdown when hovering over parent or dropdown itself */
.sidebar .dropdown-container:hover .dropdown {
    display: block;
}

/* Dropdown links */
.sidebar .dropdown a {
    display: block;
    color: black;
    padding: 10px 15px;
    text-decoration: none;
    transition: 0.3s;
    white-space: nowrap;
}

.sidebar .dropdown a:hover {
    background: #f1f1f1;
}
/* Add space for dropdown icon */
.sidebar .has-dropdown {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Style for dropdown arrow */
.sidebar .has-dropdown i.dropdown-arrow {
    margin-left: auto; /* Push arrow to the right */
    transition: transform 0.3s ease;
}

/* Rotate arrow when hovering */
.sidebar .dropdown-container:hover .has-dropdown i.dropdown-arrow {
    transform: rotate(180deg);
}

