/* ===== Navigation Styles - Bootstrap Theme Compatible ===== */
.sidebar-container {
    width: 280px;
    height: 100vh;
    background: linear-gradient(180deg, #2c3e50 0%, #34495e 100%);
    box-shadow: 4px 0 8px rgba(0, 0, 0, 0.1);
    position: fixed;
    left: 0;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
    overflow-y: auto;
    color: #ffffff !important;
}

.sidebar-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.1);
}

.brand {
    display: flex;
    align-items: center;
}

.brand .navbar-brand {
    color: white !important;
    font-size: 1.75rem !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    font-family: 'Source Sans Pro', sans-serif !important;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.brand .navbar-brand:hover {
    color: #18bc9c !important;
    transform: scale(1.05);
}

.brand .navbar-brand i {
    color: #18bc9c !important;
    font-size: 2rem;
    margin-right: 0.75rem;
}

.navbar-toggler {
    background: none !important;
    border: 2px solid rgba(255, 255, 255, 0.2) !important;
    color: white !important;
    padding: 0.5rem !important;
    border-radius: 0.5rem !important;
    transition: all 0.3s ease !important;
}

.navbar-toggler:hover {
    border-color: #18bc9c !important;
    background: rgba(24, 188, 156, 0.1) !important;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

.sidebar-content {
    padding: 1rem 0;
    height: calc(100vh - 100px);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.nav-menu {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.nav-section {
    padding: 0 1rem;
}

.nav-item {
    margin-bottom: 0.5rem;
    animation: slideInLeft 0.3s ease-out;
    animation-fill-mode: both;
}

.nav-item:nth-child(1) { animation-delay: 0.1s; }
.nav-item:nth-child(2) { animation-delay: 0.2s; }
.nav-item:nth-child(3) { animation-delay: 0.3s; }
.nav-item:nth-child(4) { animation-delay: 0.4s; }

.nav-link {
    display: flex !important;
    align-items: center !important;
    padding: 0.875rem 1rem !important;
    text-decoration: none !important;
    border-radius: 0.75rem !important;
    transition: all 0.3s ease !important;
    font-weight: 500 !important;
    font-size: 0.95rem !important;
    margin: 0 !important;
    border: 2px solid transparent !important;
    position: relative;
    overflow: hidden;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.nav-link:hover::before {
    left: 100%;
}

.nav-link:hover {
    color: black !important;
    background: linear-gradient(135deg, rgba(24, 188, 156, 0.2), rgba(24, 188, 156, 0.3)) !important;
    border-color: rgba(24, 188, 156, 0.3) !important;
    transform: translateX(8px) !important;
    box-shadow: 0 4px 8px rgba(24, 188, 156, 0.2) !important;
}

.nav-link:hover i {
    color: #18bc9c !important;
    transform: scale(1.1) !important;
}

.nav-link.active {
    background: linear-gradient(135deg, #18bc9c, #16a085) !important;
    color: white !important;
    border-color: #18bc9c !important;
    box-shadow: 0 4px 12px rgba(24, 188, 156, 0.3) !important;
    transform: translateX(4px) !important;
}

.nav-link.active i {
    color: white !important;
    transform: scale(1.1) !important;
}

.nav-link.active span {
    font-weight: 600 !important;
}

.nav-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1rem;
    margin-top: 1rem;
}

.user-info {
    display: flex;
    align-items: center;
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 0.75rem;
    margin-left: 1rem;
    margin-right: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.user-avatar {
    margin-right: 0.75rem;
    width: 2.5rem;
    height: 2.5rem;
    background: linear-gradient(135deg, #18bc9c, #16a085);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff !important;
    font-size: 1.25rem;
}

.user-avatar i {
    font-size: 2rem;
    color: #18bc9c;
}

.user-details {
    flex: 1;
}

.user-name {
    color: white;
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
}

.user-name {
    color: #ffffff !important;
}

.user-role {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.user-role {
    color: rgba(255, 255, 255, 0.7) !important;
}

.logout-btn {
    background: none !important;
    border: none !important;
    width: 100% !important;
    text-align: left !important;
    color: rgba(255, 255, 255, 0.9) !important;
    padding: 0.875rem 1rem;
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logout-btn:hover {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.2), rgba(231, 76, 60, 0.3)) !important;
    border-color: rgba(231, 76, 60, 0.3) !important;
    color: #e74c3c !important;
    transform: translateX(5px);
}

.logout-btn:hover i {
    color: #e74c3c !important;
}

/* ===== Collapsed State ===== */
.sidebar-content.collapse {
    display: none !important;
}

.sidebar-content.collapse.show {
    display: flex !important;
}

/* ===== Mobile Responsive ===== */
@media (max-width: 991.98px) {
    .sidebar-container {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .sidebar-container.show {
        transform: translateX(0);
    }
    
    .sidebar-container {
        z-index: 1050;
    }
}

@media (max-width: 576px) {
    .sidebar-container {
        width: 100%;
    }
    
    .nav-link {
        padding: 0.875rem 1rem !important;
        font-size: 0.9rem !important;
    }
    
    .nav-link i {
        font-size: 1.1rem !important;
        margin-right: 0.5rem !important;
    }
    
    .brand .navbar-brand {
        font-size: 1.5rem !important;
    }
    
    .brand .navbar-brand i {
        font-size: 1.75rem !important;
        margin-right: 0.5rem !important;
    }
    
    .user-info {
        padding: 0.875rem 1rem;
    }
    
    .user-avatar i {
        font-size: 1.75rem;
    }
    
    .user-name {
        font-size: 0.9rem;
    }
    
    .user-role {
        font-size: 0.75rem;
    }
}

/* ===== Animations ===== */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.nav-item {
    animation: slideInLeft 0.3s ease-out;
    animation-fill-mode: both;
}

.nav-item:nth-child(1) { animation-delay: 0.1s; }
.nav-item:nth-child(2) { animation-delay: 0.2s; }
.nav-item:nth-child(3) { animation-delay: 0.3s; }
.nav-item:nth-child(4) { animation-delay: 0.4s; }

/* ===== Accessibility ===== */
.nav-link:focus {
    outline: 2px solid #18bc9c !important;
    outline-offset: 2px !important;
}

.logout-btn:focus {
    outline: 2px solid #e74c3c !important;
    outline-offset: 2px !important;
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .sidebar-container {
        background: linear-gradient(180deg, #1a252f 0%, #2c3e50 100%);
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .nav-link {
        border: 1px solid rgba(255, 255, 255, 0.3);
    }
    
    .nav-link.active {
        border: 2px solid #18bc9c;
    }
}

/* Ensure all navigation text is visible */
.sidebar-container * {
    color: inherit !important;
}

.nav-link,
.nav-link * {

}

.nav-link:hover,
.nav-link:hover * {
    color: black !important;
}

.nav-link.active,
.nav-link.active * {
    color: #ffffff !important;
}

.user-name {
    color: #ffffff !important;
}

.user-role {
    color: rgba(255, 255, 255, 0.7) !important;
}

.logout-btn,
.logout-btn * {
    color: rgba(255, 255, 255, 0.8) !important;
}

.logout-btn:hover,
.logout-btn:hover * {
    color: #ffffff !important;
}