/* === НОВАЯ НАДЕЖНАЯ СИСТЕМА УВЕДОМЛЕНИЙ === */

/* Колокольчик уведомлений */
.notification-bell-corner {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #ec4899 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(79, 70, 229, 0.4);
    cursor: pointer;
    z-index: 2147483647;
    transition: all 0.3s ease;
    border: none;
    outline: none;
    user-select: none;
}

.notification-bell-corner:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 25px rgba(79, 70, 229, 0.6);
}

.notification-bell-corner:active {
    transform: scale(0.95);
}

.notification-bell-corner svg {
    width: 24px;
    height: 24px;
    fill: white;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));
}

/* Бейдж с количеством */
.notification-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    background: #ef4444;
    color: white;
    border-radius: 50%;
    min-width: 20px;
    height: 20px;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    border: 2px solid white;
    box-shadow: 0 1px 4px rgba(239, 68, 68, 0.4);
}

.notification-badge.show {
    display: flex;
}

/* Дропдаун меню */
.notification-dropdown-corner {
    position: fixed;
    bottom: 85px;
    right: 20px;
    width: 380px;
    max-width: calc(100vw - 40px);
    background: linear-gradient(135deg, #2a2a2a 0%, #1f1f1f 100%);
    border: 1px solid #3a3a3a;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    z-index: 2147483646;
    display: none !important;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px) scale(0.9);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    pointer-events: none;
    max-height: 500px;
}

.notification-dropdown-corner.active {
    display: block !important;
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

/* Заголовок */
.notification-header {
    padding: 18px 24px 14px;
    border-bottom: 1px solid #3a3a3a;
    background: linear-gradient(135deg, #333 0%, #2a2a2a 100%);
    border-radius: 16px 16px 0 0;
}

.notification-header h3 {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.notification-header .header-icon {
    width: 18px;
    height: 18px;
    fill: #4f46e5;
}

/* Список уведомлений */
.notification-list {
    max-height: 320px;
    overflow-y: auto;
}

.notification-list::-webkit-scrollbar {
    width: 4px;
}

.notification-list::-webkit-scrollbar-track {
    background: #1a1a1a;
}

.notification-list::-webkit-scrollbar-thumb {
    background: #4f46e5;
    border-radius: 2px;
}

/* Элемент уведомления */
.notification-item {
    padding: 16px 24px;
    border-bottom: 1px solid #2a2a2a;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.notification-item:hover {
    background: #252525;
}

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

.notification-item.unread {
    background: rgba(79, 70, 229, 0.05);
    border-left: 3px solid #4f46e5;
}

.notification-content {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.notification-icon {
    color: #4f46e5;
    font-size: 16px;
    margin-top: 2px;
    flex-shrink: 0;
}

.notification-text {
    flex: 1;
}

.notification-title {
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
    line-height: 1.3;
}

.notification-message {
    color: #bbb;
    font-size: 13px;
    margin-bottom: 6px;
    line-height: 1.4;
}

.notification-time {
    color: #888;
    font-size: 11px;
}

/* Пустое состояние */
.no-notifications {
    padding: 40px 20px;
    text-align: center;
    color: #888;
}

.empty-icon {
    width: 40px;
    height: 40px;
    fill: #555;
    margin: 0 auto 12px;
}

.empty-title {
    font-size: 15px;
    font-weight: 600;
    color: #bbb;
    margin-bottom: 4px;
}

.empty-subtitle {
    font-size: 13px;
    color: #888;
}

/* Футер */
.notification-footer {
    padding: 12px 20px;
    text-align: center;
    border-top: 1px solid #333;
    background: #252525;
}

.view-all-button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #fff;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    padding: 8px 16px;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    border-radius: 8px;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.view-all-button:hover {
    background: linear-gradient(135deg, #5b52ec 0%, #8b5cf6 100%);
    transform: translateY(-1px);
    text-decoration: none;
    color: #fff;
}

.view-all-button svg {
    width: 12px;
    height: 12px;
    fill: currentColor;
}

/* Анимация звонка */
.notification-bell-corner.ringing {
    animation: bellRing 0.6s ease-in-out;
}

@keyframes bellRing {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-15deg); }
    75% { transform: rotate(15deg); }
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .notification-bell-corner {
        width: 52px;
        height: 52px;
        bottom: 20px;
        right: 20px;
    }

    .notification-bell-corner svg {
        width: 22px;
        height: 22px;
    }

    .notification-dropdown-corner {
        width: calc(100vw - 40px);
        bottom: 80px;
        right: 20px;
        left: 20px;
        max-height: 70vh;
        border-radius: 12px;
    }

    .notification-header {
        padding: 16px 20px 12px;
        border-radius: 12px 12px 0 0;
    }

    .notification-item {
        padding: 14px 20px;
    }

    .notification-footer {
        padding: 12px 20px;
    }
}

@media (max-width: 480px) {
    .notification-bell-corner {
        width: 48px;
        height: 48px;
        bottom: 12px;
        right: 12px;
    }

    .notification-dropdown-corner {
        width: calc(100vw - 24px);
        bottom: 68px;
        right: 12px;
    }
}