/* Enhanced Sidebar Styling with Cairo Font */
body {
    font-family: "Cairo", sans-serif !important;
}

/* Sidebar Enhancements */
.app-sidebar {
    background: linear-gradient(180deg, #1e1e2d 0%, #27293d 100%) !important;
    box-shadow: 0 0 28px 0 rgba(82, 63, 105, 0.13);
}

.app-sidebar-logo {
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.5rem 1.5rem !important;
}

/* Menu Items */
.app-sidebar .menu {
    font-family: "Cairo", sans-serif;
}

.app-sidebar .menu-item .menu-link {
    font-size: 0.92rem !important;
    font-weight: 500 !important;
    padding: 0.45rem 0.85rem !important;
    margin: 0.1rem 0.65rem !important;
    border-radius: 0.5rem !important;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    color: rgba(255, 255, 255, 0.65) !important;
}

.app-sidebar .menu-item .menu-link:hover {
    background-color: rgba(255, 255, 255, 0.08) !important;
    color: #ffffff !important;
    transform: translateX(-4px) !important;
}

.app-sidebar .menu-item .menu-link.active {
    background: linear-gradient(135deg, #4f46e5 0%, #3b82f6 100%) !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 15px rgba(79, 70, 229, 0.35) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    position: relative !important;
    overflow: hidden !important;
}

/* Add a subtle glow effect to active main menu items */
.app-sidebar .menu-item .menu-link.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent) !important;
    z-index: 1;
}

/* Menu Titles */
.app-sidebar .menu-title {
    font-family: "Cairo", sans-serif !important;
    font-weight: 600 !important;
    font-size: 0.92rem !important;
    letter-spacing: 0.2px !important;
}

/* Menu Section Headers */
.app-sidebar .menu-section {
    padding: 1rem 1rem 0.4rem !important;
}

.app-sidebar .menu-section .menu-heading {
    color: rgba(255, 255, 255, 0.5) !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    font-family: "Cairo", sans-serif !important;
}

/* Submenu Styling */
.app-sidebar .menu-sub {
    background-color: rgba(0, 0, 0, 0.18) !important;
    border-radius: 0.625rem !important;
    margin: 0.15rem 0.65rem !important;
    padding: 0.35rem 0 !important;
}

.app-sidebar .menu-sub .menu-item .menu-link {
    font-size: 0.85rem !important;
    padding: 0.4rem 0.8rem 0.4rem 1.5rem !important;
    margin: 0.1rem 0.4rem !important;
    border-radius: 0.4rem !important;
    color: rgba(255, 255, 255, 0.55) !important;
}

.app-sidebar .menu-sub .menu-item .menu-link:hover {
    background-color: rgba(255, 255, 255, 0.06) !important;
    color: #ffffff !important;
}

/* Stunning Active State for Sub Menu Item */
.app-sidebar .menu-sub .menu-item .menu-link.active {
    background: linear-gradient(to inline-start, rgba(79, 70, 229, 0.25) 0%, rgba(59, 130, 246, 0.05) 100%) !important;
    color: #ffffff !important;
    font-weight: 600 !important;
    border-inline-start: 3px solid #8b5cf6 !important;
    box-shadow: inset 0 0 10px rgba(79, 70, 229, 0.08) !important;
}

/* Menu Bullets */
.app-sidebar .menu-bullet {
    margin-left: 0.75rem;
}

.app-sidebar .menu-bullet .bullet {
    background-color: rgba(255, 255, 255, 0.3);
    width: 5px;
    height: 5px;
}

.app-sidebar .menu-item .menu-link.active .bullet {
    background-color: #ffffff;
}

/* Icons */
.app-sidebar .menu-icon {
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.25rem;
    margin-left: 0.75rem;
}

.app-sidebar .menu-item .menu-link.active .menu-icon {
    color: #ffffff;
}

.app-sidebar .menu-item .menu-link:hover .menu-icon {
    color: #ffffff;
}

/* Arrow Icons for Expandable Menus */
.app-sidebar .menu-arrow {
    color: rgba(255, 255, 255, 0.4);
    transition: transform 0.3s ease;
}

.app-sidebar .menu-item.show>.menu-link .menu-arrow {
    transform: rotate(90deg);
    color: #3699ff;
}

/* Scrollbar Styling */
.app-sidebar-wrapper::-webkit-scrollbar {
    width: 5px;
}

.app-sidebar-wrapper::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

.app-sidebar-wrapper::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
}

.app-sidebar-wrapper::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Toggle Button */
.app-sidebar-toggle {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.app-sidebar-toggle:hover {
    background: rgba(255, 255, 255, 0.15) !important;
}

/* Minimized Sidebar State */
.app-sidebar-minimize .app-sidebar .menu-title {
    opacity: 0;
}

/* Badge Styling in Sidebar */
.app-sidebar .badge {
    font-family: "Cairo", sans-serif;
    font-weight: 600;
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
}

/* Responsive Improvements */
@media (max-width: 991.98px) {
    .app-sidebar {
        box-shadow: 0 0 50px 0 rgba(82, 63, 105, 0.25);
    }
}

/* Header Improvements */
.app-header {
    font-family: "Cairo", sans-serif;
}

/* Card Headers */
.card-title {
    font-family: "Cairo", sans-serif;
    font-weight: 700;
}

/* Buttons */
.btn {
    font-family: "Cairo", sans-serif;
    font-weight: 600;
}

/* Form Labels */
.form-label {
    font-family: "Cairo", sans-serif;
    font-weight: 600;
}

/* Table Headers */
.table thead th {
    font-family: "Cairo", sans-serif;
    font-weight: 700;
}

/* Page Headings */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: "Cairo", sans-serif;
    font-weight: 700;
}

/* Breadcrumbs */
.breadcrumb {
    font-family: "Cairo", sans-serif;
}