/**
 * Notifications Dropdown Styles
 */

/* Notification Dropdown */
.notifications-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    width: 400px;
    max-height: 600px;
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
    margin-top: 8px;
    display: none;
    flex-direction: column;
    z-index: 1000;
}

.notifications-dropdown.show {
    display: flex;
}

.notifications-page-header {
    display: flex;
    justify-content: space-between;
}

.notifications-header {
    padding: 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.notifications-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.mark-all-read-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 4px 8px;
}

.mark-all-read-btn:hover {
    text-decoration: underline;
}

.notifications-list {
    overflow-y: auto;
    max-height: 500px;
}

.notification-item {
    padding: 12px 5px;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
    transition: background-color 0.2s;
    position: relative;
}

.notification-item:hover {
    background-color: var(--bg-hover);
}

.notification-item.unread {
    background-color: rgba(0, 121, 211, 0.05);
}

.notification-item.unread::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    background-color: var(--primary-color);
    border-radius: 50%;
}

.notification-content {
    display: flex;
    gap: 12px;
    padding-left: 8px;
    padding-top: 10px;
}

/* Avatar with Badge */
.notification-avatar-wrapper {
    position: relative;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
}

.notification-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.notification-badge {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg-primary);
}

.notification-badge img {
    width: 12px;
    height: 12px;
    filter: brightness(0) invert(1);
}

/* Legacy notification icon (fallback) */
.notification-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.notification-icon img {
    width: 16px;
    height: 16px;
}

.notification-body {
    flex: 1;
    min-width: 0;
}

.notification-text {
    font-size: 14px;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 4px;
}

.notification-text strong {
    font-weight: 600;
}

.notification-text strong::after {
    content: '✓';
    display: inline-block;
    margin-left: 3px;
    font-size: 12px;
    color: #fff;
    background: #ff0000;
    border-radius: 50%;
    width: 14px;
    height: 14px;
    text-align: center;
    line-height: 14px;
    vertical-align: middle;
}

.notification-time {
    font-size: 12px;
    color: var(--text-muted);
}

.notifications-empty {
    padding: 48px 24px;
    text-align: center;
}

.notifications-empty-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 16px;
    opacity: 0.3;
}

.notifications-empty-text {
    font-size: 14px;
    color: var(--text-secondary);
}

.notifications-footer {
    padding: 12px 16px;
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.view-all-notifications-btn {
    color: var(--primary-color);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

.view-all-notifications-btn:hover {
    text-decoration: underline;
}

/* Notification Badge */
.notification-badge {
    position: absolute;
    top: -4px;
    right: -8px;
    background-color: #ff4444;
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}

/* Responsive */
@media (max-width: 768px) {
    .notifications-dropdown {
        width: calc(100vw - 32px);
        right: 16px;
        left: 16px;
        margin: 8px auto 0;
    }
}
/* Notifications Page Styles */
.notifications-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.notifications-page .notification-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
    position: relative;
}

.notifications-page .notification-item:hover {
    background-color: var(--bg-hover);
}

.notifications-page .notification-item.unread {
    background-color: rgba(0, 121, 211, 0.05);
    border-left: 3px solid var(--primary-color);
}

.notification-type-icon {
    position: absolute;
    bottom: 20px;
    right: -5px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg-primary);
}

.notification-type-icon img {
    width: 12px;
    height: 12px;
}

.notification-type-upvote {
    background-color: #ff4500;
}

.notification-type-downvote {
    background-color: #7193ff;
}

.notification-type-comment,
.notification-type-reply {
    background-color: #0079d3;
}

.notification-type-award {
    background-color: #ffd700;
}

.notification-type-follow {
    background-color: #46d160;
}

.notification-type-mention {
    background-color: #ff6314;
}

.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-title {
    font-size: 15px;
    color: var(--text-primary);
    font-weight: 500;
    margin-bottom: 4px;
    line-height: 1.4;
}

.notification-meta {
    margin-top: -40px;
    margin-left: -50px;
}

.notification-indicator {
    position: absolute;
    top: 20px;
    right: 16px;
    width: 8px;
    height: 8px;
    background-color: var(--primary-color);
    border-radius: 50%;
}

.avatar-default {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
}