:root {
    --sidebar-width: 260px;
    --sidebar-collapsed: 0px;
    --topbar-height: 60px;
    --primary-color: #1a1d3a;
    --primary-dark: #12142a;
    --secondary-color: #6c757d;
    --success-color: #2ec4b6;
    --danger-color: #e63946;
    --warning-color: #f77f00;
    --info-color: #4cc9f0;
    --bg-light: #f8f9fa;
    --bg-dark-sidebar: #1a1d3a;
    --sidebar-hover: #252850;
    --sidebar-active: #1a1d3a;
    --text-muted: #6c757d;
    --border-color: #e9ecef;
    --shadow-sm: 0 0.125rem 0.25rem rgba(0,0,0,0.075);
    --shadow: 0 0.5rem 1rem rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
}

* { box-sizing: border-box; }

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-light);
    overflow-x: hidden;
}

.wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    min-height: 100vh;
    background: linear-gradient(180deg, var(--bg-dark-sidebar) 0%, #2d325a 100%);
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 1040;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.sidebar.collapsed {
    margin-left: calc(-1 * var(--sidebar-width));
}

.sidebar-header {
    padding: 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-header a {
    display: flex;
    align-items: center;
    gap: 18px;
}

.sidebar-logo {
    width: 36px;
    height: 36px;
    object-fit: contain;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.sidebar-logo:hover {
    transform: scale(1.14) rotate(5deg);
    filter: drop-shadow(0 0 8px rgba(161, 209, 58, 0.6));
}

.sidebar-header-text {
    text-align: left;
    line-height: 1.2;
}

.sidebar-header h4 {
    font-weight: 700;
    letter-spacing: 1px;
    font-size: 1.25rem;
}

.sidebar-header small {
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

.sidebar-nav {
    list-style: none;
    padding: 15px 0;
    margin: 0;
    flex: 1;
}

.sidebar-item {
    margin: 2px 10px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    border-radius: 8px;
    transition: var(--transition);
    font-size: 0.9rem;
}

.sidebar-link:hover {
    background: var(--sidebar-hover);
    color: #fff;
}

.sidebar-item.active .sidebar-link {
    background: var(--sidebar-hover);
    color: #fff;
    font-weight: 600;
    border-left: 3px solid #fff;
}

.sidebar-link i {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
}

.sidebar-footer {
    padding: 15px 20px;
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 5px;
}

/* Main Content */
.main-content {
    width: 100%;
    margin-left: var(--sidebar-width);
    transition: var(--transition);
    min-height: 100vh;
}

.main-content.expanded {
    margin-left: 0;
}

/* Top Navbar */
.top-navbar {
    height: var(--topbar-height);
    background: #fff;
    border-bottom: 1px solid var(--border-color);
    padding: 0 20px;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1030;
}

.sidebar-toggle {
    color: #333;
    font-size: 1.3rem;
    padding: 0;
    border: none;
}

.content-wrapper {
    padding: 25px;
}

/* Stat Cards */
.stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow-sm);
    border: none;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.stat-card .stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: #fff;
}

.stat-card .stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: #333;
}

.stat-card .stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-card::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    opacity: 0.05;
    transform: translate(30px, -30px);
}

/* Cards */
.card {
    border: none;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

.card-header {
    background: #fff;
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    padding: 15px 20px;
}

/* Tables */
.table th {
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    border-bottom: 2px solid var(--border-color);
    white-space: nowrap;
}

.table td {
    vertical-align: middle;
    font-size: 0.9rem;
    white-space: nowrap;
}

/* Badges */
.badge {
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
}

/* Buttons */
.btn-primary {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
}

/* Notification */
.notif-badge {
    font-size: 0.65rem;
    padding: 3px 6px;
}

.notification-menu .dropdown-item {
    padding: 10px 15px;
    border-bottom: 1px solid var(--border-color);
    white-space: normal;
}

.notification-menu .dropdown-item:hover {
    background: var(--bg-light);
}

.notification-menu .smaller {
    font-size: 0.7rem;
}

/* Login Page */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: url('../images/login-bg.jpg') no-repeat center center fixed;
    background-size: cover;
    position: relative;
}

.login-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
}

.login-container > * {
    position: relative;
    z-index: 1;
}

.login-card {
    width: 100%;
    max-width: 450px;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    border: none;
    overflow: hidden;
}

.login-card .card-body {
    padding: 40px;
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header h2 {
    font-weight: 700;
    color: #333;
}

.login-header p {
    color: var(--text-muted);
}

.login-card .btn-primary {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

.login-card .btn-primary:hover {
    background-color: var(--primary-dark) !important;
    border-color: var(--primary-dark) !important;
}

/* Portal Selector */
.portal-selector {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.portal-btn {
    flex: 1;
    padding: 15px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background: #fff;
    text-decoration: none;
    color: #333;
}

.portal-btn:hover, .portal-btn.active {
    border-color: var(--primary-color);
    background: rgba(26, 29, 58, 0.05);
    color: var(--primary-color);
}

.portal-btn i {
    font-size: 2rem;
    display: block;
    margin-bottom: 8px;
}

/* Ticket Detail */
.ticket-detail-header {
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
}

.comment-card {
    background: var(--bg-light);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 10px;
}

.comment-card.own-comment {
    background: rgba(26, 29, 58, 0.05);
    border-left: 3px solid var(--primary-color);
}

/* Search & Filter */
.search-filter-bar {
    background: #fff;
    border-radius: 12px;
    padding: 15px 20px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
}

/* Charts */
.chart-container {
    position: relative;
    height: 300px;
    width: 100%;
}

/* Responsive */
@media (max-width: 992px) {
    .sidebar {
        margin-left: calc(-1 * var(--sidebar-width));
    }
    .sidebar.show {
        margin-left: 0;
    }
    .main-content {
        margin-left: 0;
    }
}

@media (max-width: 576px) {
    .content-wrapper {
        padding: 15px;
    }
    .stat-card .stat-value {
        font-size: 1.4rem;
    }
    .portal-selector {
        flex-direction: column;
    }
}

/* Overlay for mobile sidebar */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1035;
}

.sidebar-overlay.show {
    display: block;
}

/* Print styles */
@media print {
    .sidebar, .top-navbar, .sidebar-toggle, .btn, .search-filter-bar {
        display: none !important;
    }
    .main-content {
        margin-left: 0 !important;
    }
    .content-wrapper {
        padding: 0 !important;
    }
}

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

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

/* Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.3s ease-in;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 15px;
    opacity: 0.3;
}

/* Timeline */
.timeline-item {
    position: relative;
    padding-left: 30px;
    padding-bottom: 20px;
    border-left: 2px solid var(--border-color);
}

.timeline-item:last-child {
    border-left: 2px solid transparent;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -6px;
    top: 5px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--primary-color);
}

/* Form styles */
.form-label {
    font-weight: 500;
    font-size: 0.9rem;
    color: #495057;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(26, 29, 58, 0.15);
}

/* Status Badge Colors */
.bg-primary {
    background-color: var(--primary-color) !important;
}

.bg-info {
    background-color: var(--info-color) !important;
}

.bg-warning {
    background-color: var(--warning-color) !important;
    color: #fff !important;
}

.bg-success {
    background-color: var(--success-color) !important;
}

.bg-danger {
    background-color: var(--danger-color) !important;
}

.bg-dark {
    background-color: var(--bg-dark-sidebar) !important;
}

.bg-secondary {
    background-color: var(--secondary-color) !important;
}

/* Button consistency */
.btn-primary {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: #fff !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    background-color: var(--primary-dark) !important;
    border-color: var(--primary-dark) !important;
    color: #fff !important;
}

.btn-outline-primary {
    color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: #fff !important;
}

.btn-info {
    background-color: var(--info-color) !important;
    border-color: var(--info-color) !important;
    color: #fff !important;
}

.btn-info:hover,
.btn-info:focus,
.btn-info:active {
    background-color: #3ab5d9 !important;
    border-color: #3ab5d9 !important;
    color: #fff !important;
}

.btn-success {
    background-color: var(--success-color) !important;
    border-color: var(--success-color) !important;
    color: #fff !important;
}

.btn-success:hover,
.btn-success:focus,
.btn-success:active {
    background-color: #28b0a3 !important;
    border-color: #28b0a3 !important;
    color: #fff !important;
}

.btn-warning {
    background-color: var(--warning-color) !important;
    border-color: var(--warning-color) !important;
    color: #fff !important;
}

.btn-warning:hover,
.btn-warning:focus,
.btn-warning:active {
    background-color: #e07200 !important;
    border-color: #e07200 !important;
    color: #fff !important;
}

.btn-danger {
    background-color: var(--danger-color) !important;
    border-color: var(--danger-color) !important;
    color: #fff !important;
}

.btn-danger:hover,
.btn-danger:focus,
.btn-danger:active {
    background-color: #d32f3f !important;
    border-color: #d32f3f !important;
    color: #fff !important;
}

/* Secondary button override - change gray to green */
.btn-secondary {
    --bs-btn-color: #a1d13a !important;
    --bs-btn-border-color: #a1d13a !important;
    --bs-btn-hover-color: #fff !important;
    --bs-btn-hover-bg: #a1d13a !important;
    --bs-btn-hover-border-color: #a1d13a !important;
    --bs-btn-active-color: #fff !important;
    --bs-btn-active-bg: #a1d13a !important;
    --bs-btn-active-border-color: #a1d13a !important;
    color: #a1d13a !important;
    border-color: #a1d13a !important;
    background-color: transparent !important;
}

.btn-secondary:hover,
.btn-secondary:focus,
.btn-secondary:active {
    color: #fff !important;
    background-color: #a1d13a !important;
    border-color: #a1d13a !important;
}

.btn-outline-secondary {
    --bs-btn-color: #a1d13a !important;
    --bs-btn-border-color: #a1d13a !important;
    --bs-btn-hover-color: #fff !important;
    --bs-btn-hover-bg: #a1d13a !important;
    --bs-btn-hover-border-color: #a1d13a !important;
    color: #a1d13a !important;
    border-color: #a1d13a !important;
}

.btn-outline-secondary:hover,
.btn-outline-secondary:focus,
.btn-outline-secondary:active {
    color: #fff !important;
    background-color: #a1d13a !important;
    border-color: #a1d13a !important;
}

/* ============================================
   COOL HOVER EFFECTS FOR BUTTONS & NAV
   ============================================ */

/* Global Button Hover Effects */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* Primary Button Special Effect */
.btn-primary {
    position: relative;
    overflow: hidden;
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.6s;
    opacity: 0;
}

.btn-primary:hover::after {
    animation: shine 0.6s ease-in-out;
}

@keyframes shine {
    0% {
        left: -50%;
        opacity: 1;
    }
    100% {
        left: 150%;
        opacity: 0;
    }
}

/* Sidebar Navigation Hover Effects */
.sidebar-link {
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: #a1d13a;
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.sidebar-link:hover::before {
    transform: scaleY(1);
}

.sidebar-link:hover {
    padding-left: 25px;
    background: rgba(161, 209, 58, 0.1);
}

.sidebar-link:hover i {
    transform: scale(1.2) rotate(5deg);
    color: #a1d13a;
    transition: all 0.3s ease;
}

.sidebar-link i {
    transition: all 0.3s ease;
}

.sidebar-item.active .sidebar-link::before {
    transform: scaleY(1);
    background: #a1d13a;
}

.sidebar-item.active .sidebar-link {
    background: rgba(161, 209, 58, 0.15);
    border-left: none;
}

.sidebar-item.active .sidebar-link i {
    color: #a1d13a;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* Top Navbar Hover Effects */
.top-navbar .btn-link,
.top-navbar .dropdown-toggle {
    transition: all 0.3s ease;
    position: relative;
}

.top-navbar .btn-link:hover,
.top-navbar .dropdown-toggle:hover {
    transform: scale(1.05);
}

.top-navbar .btn-link::after,
.top-navbar .dropdown-toggle::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #a1d13a;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.top-navbar .btn-link:hover::after,
.top-navbar .dropdown-toggle:hover::after {
    width: 80%;
}

/* Notification Bell Animation */
.top-navbar .bi-bell {
    transition: all 0.3s ease;
}

.top-navbar .btn-link:hover .bi-bell {
    animation: ring 0.5s ease;
}

@keyframes ring {
    0%, 100% {
        transform: rotate(0);
    }
    20%, 60% {
        transform: rotate(-15deg);
    }
    40%, 80% {
        transform: rotate(15deg);
    }
}

/* Dropdown Menu Hover Effects */
.dropdown-menu {
    transition: all 0.3s ease;
    transform: translateY(-10px);
    opacity: 0;
    visibility: hidden;
}

.dropdown-menu.show {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.dropdown-item {
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.dropdown-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: #a1d13a;
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.dropdown-item:hover::before {
    transform: scaleY(1);
}

.dropdown-item:hover {
    padding-left: 20px;
    background: rgba(161, 209, 58, 0.1);
}

/* Card Hover Effects */
.card {
    transition: all 0.3s ease;
}

.card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* Table Row Hover Effects */
.table-hover tbody tr {
    transition: all 0.2s ease;
}

.card-body.p-0 {
    padding: 0 8px 0 16px !important;
}

.table > :not(caption) > * > *:first-child,
.table > thead > tr > th:first-child,
.table > tbody > tr > td:first-child {
    padding-left: 24px !important;
}

.table-hover tbody tr:hover {
    transform: scale(1.01);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* Badge Hover Effects */
.badge {
    transition: all 0.2s ease;
}

.badge:hover {
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Sidebar Header Hover */
.sidebar-header {
    transition: all 0.3s ease;
}

.sidebar-header:hover {
    background: rgba(161, 209, 58, 0.05);
}

.sidebar-header:hover h4 {
    color: #a1d13a;
    transition: color 0.3s ease;
}

/* Smooth Scroll for Sidebar */
.sidebar {
    scroll-behavior: smooth;
}

/* Button Group Hover */
.btn-group .btn {
    transition: all 0.2s ease;
}

.btn-group .btn:hover {
    z-index: 1;
    transform: scale(1.05);
}

/* Icon Button Special Effects */
.btn i {
    transition: all 0.3s ease;
}

.btn:hover i {
    transform: scale(1.2);
}

/* Primary Button Ripple Effect */
.btn-primary {
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-primary:active::before {
    width: 300px;
    height: 300px;
    transition: width 0s, height 0s;
}

/* Sidebar Toggle Button */
.sidebar-toggle {
    transition: all 0.3s ease;
}

.sidebar-toggle:hover {
    transform: rotate(90deg);
    color: #a1d13a;
}

/* Portal Button Hover Effects */
.portal-btn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.portal-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(26, 29, 58, 0.2);
}

.portal-btn:hover i {
    transform: scale(1.2) rotate(10deg);
    transition: all 0.3s ease;
}

.portal-btn i {
    transition: all 0.3s ease;
}

/* Login Card Hover */
.login-card {
    transition: all 0.3s ease;
}

.login-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.4);
}

/* Search Filter Bar Hover */
.search-filter-bar {
    transition: all 0.3s ease;
}

.search-filter-bar:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

/* Form Control Focus Animation */
.form-control,
.form-select {
    transition: all 0.3s ease;
}

.form-control:focus,
.form-select:focus {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(26, 29, 58, 0.15);
}

/* Stat Card Enhanced Hover */
.stat-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
}

.stat-card:hover .stat-icon {
    transform: rotate(10deg) scale(1.1);
    transition: all 0.3s ease;
}

.stat-card .stat-icon {
    transition: all 0.3s ease;
}

/* Comment Card Hover */
.comment-card {
    transition: all 0.3s ease;
}

.comment-card:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Timeline Item Hover */
.timeline-item {
    transition: all 0.3s ease;
}

.timeline-item:hover {
    padding-left: 35px;
}

.timeline-item:hover::before {
    transform: scale(1.5);
    box-shadow: 0 0 10px rgba(26, 29, 58, 0.3);
}

.timeline-item::before {
    transition: all 0.3s ease;
}

/* Smooth Page Transitions */
.content-wrapper {
    animation: fadeInUp 0.5s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading Spinner for Buttons */
.btn:disabled {
    position: relative;
}

.btn:disabled::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Status Distribution Chart Legend */
.chart-container canvas + div,
.chart-container .chartjs-legend,
.chartjs-render-monitor + .chartjs-legend {
    font-size: 0.7rem !important;
}

/* Reduce Chart.js legend font size */
.chartjs-legend li {
    font-size: 0.7rem !important;
}

.chartjs-legend li span {
    width: 10px !important;
    height: 10px !important;
}

/* Notification Badge Styling */
.bell-icon-wrapper {
    position: relative;
    display: inline-block;
}

.notif-badge-top {
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.6rem !important;
    padding: 2px 6px !important;
    background-color: #e63946 !important;
    color: #fff !important;
    border: 2px solid #fff !important;
    font-weight: 700 !important;
    box-shadow: 0 2px 6px rgba(230, 57, 70, 0.5) !important;
    animation: pulse 2s infinite;
    min-width: 18px;
    height: 18px;
    line-height: 14px;
    text-align: center;
    border-radius: 50% !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notif-badge {
    font-size: 0.65rem !important;
    padding: 2px 6px !important;
    background-color: #e63946 !important;
    color: #fff !important;
    border: 2px solid #fff !important;
    font-weight: 700 !important;
    box-shadow: 0 2px 6px rgba(230, 57, 70, 0.5) !important;
    animation: pulse 2s infinite;
    min-width: 18px;
    text-align: center;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* Notification dropdown styling */
.notification-menu .dropdown-item {
    padding: 10px 15px;
    border-bottom: 1px solid var(--border-color);
    white-space: normal;
    transition: all 0.2s ease;
}

.notification-menu .dropdown-item:hover {
    background: rgba(161, 209, 58, 0.1);
    padding-left: 20px;
}

.notification-menu .dropdown-header {
    background: var(--primary-color);
    color: #fff;
    padding: 10px 15px;
}

.notification-menu .mark-all-read {
    color: #a1d13a !important;
    font-weight: 600;
}

/* Default user avatar styling */
.user-avatar-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-color);
    color: #fff;
    border-radius: 50%;
    font-size: 1rem;
}
