/* Modern Sidebar Styles for MacFlexMasterHub */

/* Notification and Message Badge Styles */
.nav-sidebar .nav-item .badge {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.nav-sidebar .nav-item:hover .badge {
    transform: translateY(-50%) scale(1.1);
}

/* Notification Badge */
.nav-sidebar .nav-item .badge-warning {
    background-color: #ff9800;
    color: #fff;
}

/* Message Badge */
.nav-sidebar .nav-item .badge-info {
    background-color: #03a9f4;
    color: #fff;
}

/* Notification Icon Animation */
@keyframes notification-pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

.nav-sidebar .nav-item .nav-link:has(+ .badge[data-count]:not([data-count="0"])) .fa-bell {
    animation: notification-pulse 2s infinite;
    color: #ff9800;
}

/* Message Icon Animation */
@keyframes message-pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

.nav-sidebar .nav-item .nav-link:has(+ .badge[data-count]:not([data-count="0"])) .fa-comments {
    animation: message-pulse 2s infinite;
    color: #03a9f4;
}

/* Hover Effects */
.nav-sidebar .nav-item .nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    transition: all 0.3s ease;
}

/* Active Item Styles */
.nav-sidebar .nav-item .nav-link.active {
    background-color: rgba(255, 255, 255, 0.2);
    border-left: 4px solid #fff;
    font-weight: 600;
}

/* Sidebar Item Spacing */
.nav-sidebar .nav-item {
    margin-bottom: 5px;
}

.nav-sidebar .nav-item .nav-link {
    padding: 12px 15px;
    border-radius: 5px;
    margin: 0 5px;
}

/* Sidebar Header Styling */
.sidebar .nav-header {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 1px;
    padding: 15px 15px 5px;
    margin-top: 10px;
}

/* Dropdown Menu Styling */
.nav-sidebar .nav-item .nav-treeview {
    margin-left: 10px;
    padding-left: 10px;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .nav-sidebar .nav-item .badge {
        right: 5px;
        min-width: 18px;
        font-size: 0.65rem;
    }
    
    .nav-sidebar .nav-item .nav-link {
        padding: 10px 12px;
    }
}

/* Dark Mode Adjustments */
.dark-mode .nav-sidebar .nav-item .badge-warning {
    background-color: #ff9800;
    color: #1a1a1a;
}

.dark-mode .nav-sidebar .nav-item .badge-info {
    background-color: #03a9f4;
    color: #1a1a1a;
}

/* Notification Dropdown Styling */
.dropdown-menu-notification {
    min-width: 280px;
    padding: 0;
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: none;
}

.dropdown-menu-notification .dropdown-header {
    background-color: #f8f9fa;
    padding: 10px 15px;
    font-weight: 600;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dropdown-menu-notification .dropdown-footer {
    background-color: #f8f9fa;
    padding: 10px 15px;
    text-align: center;
    border-top: 1px solid #e9ecef;
}

.dropdown-menu-notification .dropdown-item {
    padding: 12px 15px;
    border-bottom: 1px solid #f1f1f1;
    white-space: normal;
}

.dropdown-menu-notification .dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-menu-notification .dropdown-item:hover {
    background-color: #f8f9fa;
}

.dropdown-menu-notification .dropdown-item .notification-title {
    font-weight: 600;
    margin-bottom: 5px;
}

.dropdown-menu-notification .dropdown-item .notification-time {
    font-size: 0.75rem;
    color: #6c757d;
}

.dropdown-menu-notification .dropdown-item .notification-icon {
    margin-right: 10px;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.dropdown-menu-notification .dropdown-item.unread {
    background-color: #f0f7ff;
}

.dropdown-menu-notification .dropdown-item.unread .notification-title {
    font-weight: 700;
}

/* Message Dropdown Styling */
.dropdown-menu-message {
    min-width: 280px;
    padding: 0;
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: none;
}

.dropdown-menu-message .dropdown-header {
    background-color: #f8f9fa;
    padding: 10px 15px;
    font-weight: 600;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dropdown-menu-message .dropdown-footer {
    background-color: #f8f9fa;
    padding: 10px 15px;
    text-align: center;
    border-top: 1px solid #e9ecef;
}

.dropdown-menu-message .dropdown-item {
    padding: 12px 15px;
    border-bottom: 1px solid #f1f1f1;
    white-space: normal;
}

.dropdown-menu-message .dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-menu-message .dropdown-item:hover {
    background-color: #f8f9fa;
}

.dropdown-menu-message .dropdown-item .message-sender {
    font-weight: 600;
    margin-bottom: 5px;
}

.dropdown-menu-message .dropdown-item .message-preview {
    font-size: 0.85rem;
    color: #6c757d;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}

.dropdown-menu-message .dropdown-item .message-time {
    font-size: 0.75rem;
    color: #6c757d;
}

.dropdown-menu-message .dropdown-item .message-avatar {
    margin-right: 10px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
}

.dropdown-menu-message .dropdown-item.unread {
    background-color: #f0f7ff;
}

.dropdown-menu-message .dropdown-item.unread .message-sender {
    font-weight: 700;
}
