/**
 * Notification System Styles
 */

/* Notification Bell */
#notificationDropdown {
    cursor: pointer;
    transition: color 0.2s ease;
}

#notificationDropdown:hover {
    color: var(--primary-color, #ef7d00);
}

#notification-badge {
    font-size: 0.7rem;
    padding: 0.25em 0.5em;
    min-width: 20px;
}

/* Badge shake animation for new notifications */
@keyframes shake {
    0%, 100% { transform: translateX(0) translateY(-50%); }
    25% { transform: translateX(-5px) translateY(-50%); }
    75% { transform: translateX(5px) translateY(-50%); }
}

.notification-shake {
    animation: shake 0.5s ease-in-out;
}

/* Notification Dropdown */
.notification-dropdown {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.notification-dropdown .dropdown-header {
    padding: 12px 20px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

/* Notification Items */
.notification-item {
    border-bottom: 1px solid #dee2e6;
    transition: background-color 0.2s ease;
    cursor: pointer;
}

.notification-item:last-child {
    border-bottom: none;
}

.notification-item:hover {
    background-color: #f8f9fa !important;
}

.notification-item .notification-title {
    font-size: 0.95rem;
    display: block;
    margin-bottom: 4px;
}

.notification-item .notification-message {
    font-size: 0.85rem;
    line-height: 1.4;
    max-height: 3.6em;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.notification-item .notification-actions {
    display: flex;
    gap: 8px;
}

.notification-item .notification-actions .btn {
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
}

/* Delete button */
.delete-notification {
    opacity: 0.5;
    transition: opacity 0.2s ease;
}

.delete-notification:hover {
    opacity: 1;
    color: #dc3545 !important;
}

/* Unread indicator */
.notification-item.bg-light {
    background-color: #f0f8ff !important;
}

/* Dark Mode Support */
[data-theme="dark"] .notification-dropdown {
    background-color: var(--bg-primary);
    border-color: var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .notification-dropdown .dropdown-header {
    background-color: var(--bg-secondary);
    border-bottom-color: var(--border-color);
    color: var(--text-primary);
}

[data-theme="dark"] .notification-item {
    border-bottom-color: var(--border-color);
    color: var(--text-primary);
}

[data-theme="dark"] .notification-item:hover {
    background-color: var(--bg-secondary) !important;
}

[data-theme="dark"] .notification-item.bg-light {
    background-color: rgba(239, 125, 0, 0.1) !important;
}

[data-theme="dark"] .notification-item .text-muted {
    color: var(--text-muted) !important;
}

/* Mark all read button */
#mark-all-read {
    color: #6c757d;
    transition: color 0.2s ease;
}

#mark-all-read:hover {
    color: var(--primary-color, #ef7d00);
}

[data-theme="dark"] #mark-all-read {
    color: var(--text-muted);
}

[data-theme="dark"] #mark-all-read:hover {
    color: var(--primary-color, #ef7d00);
}

/* Empty state */
.notification-dropdown .text-center {
    padding: 2rem 1rem;
}

.notification-dropdown .text-center i.fa-2x {
    display: block;
    margin-bottom: 1rem;
    opacity: 0.3;
}

/* Scrollbar styling for notification dropdown */
.notification-dropdown::-webkit-scrollbar {
    width: 8px;
}

.notification-dropdown::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.notification-dropdown::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.notification-dropdown::-webkit-scrollbar-thumb:hover {
    background: #555;
}

[data-theme="dark"] .notification-dropdown::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

[data-theme="dark"] .notification-dropdown::-webkit-scrollbar-thumb {
    background: var(--border-color);
}

[data-theme="dark"] .notification-dropdown::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* Priority indicators (optional visual enhancement) */
.notification-item[data-priority="Urgent"] {
    border-left: 4px solid #dc3545 !important;
}

.notification-item[data-priority="High"] {
    border-left: 4px solid #fd7e14 !important;
}

/* Category badges */
.notification-item .badge {
    font-size: 0.7rem;
    padding: 0.25em 0.5em;
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .notification-dropdown {
        width: 100vw !important;
        max-width: none !important;
        left: 0 !important;
        right: 0 !important;
        margin: 0 !important;
        border-radius: 0 !important;
    }
}
