/* ================================================
   УВЕДОМЛЕНИЯ ПЛАТФОРМЫ КОЛЬЦО
   Единый стиль для всех типов уведомлений
   ================================================ */

/* Базовое уведомление — вылетает справа */
.antispam-notification,
.xp-notification,
.platform-notification {
    position: fixed;
    top: 90px;
    right: -420px;
    width: 360px;
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
    transition: right 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 10000;
    overflow: hidden;
}

.antispam-notification.show,
.xp-notification.show,
.platform-notification.show {
    right: 20px;
}

/* ---- Антиспам / Ошибка ---- */
.antispam-notification {
    background: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
    color: white;
    padding: 1.25rem 1.5rem;
}

.antispam-notification-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.antispam-icon {
    font-size: 2rem;
    flex-shrink: 0;
    animation: shake 0.4s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0) rotate(0deg); }
    25% { transform: translateX(-4px) rotate(-8deg); }
    75% { transform: translateX(4px) rotate(8deg); }
}

.antispam-text strong {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}

.antispam-text p {
    margin: 0;
    font-size: 0.875rem;
    opacity: 0.92;
    line-height: 1.4;
}

/* Прогресс-бар автозакрытия */
.antispam-notification::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    background: rgba(255, 255, 255, 0.5);
    animation: countdown 4s linear forwards;
}

@keyframes countdown {
    from { width: 100%; }
    to { width: 0%; }
}

/* ---- XP Уведомление ---- */
.xp-notification {
    background: white;
    border: 1px solid #e2e8f0;
    padding: 1.25rem 1.5rem;
}

.xp-notification::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #667eea, #764ba2);
    border-radius: 16px 0 0 16px;
}

.xp-notification-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.xp-icon {
    font-size: 2rem;
    flex-shrink: 0;
    animation: sparkle 0.6s ease-in-out;
}

@keyframes sparkle {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.3) rotate(180deg); }
}

.xp-text strong {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.2rem;
}

.xp-text p {
    margin: 0 0 0.15rem 0;
    font-size: 0.8rem;
    color: #64748b;
}

.xp-text small {
    font-size: 0.75rem;
    color: #94a3b8;
}

.xp-notification::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    animation: countdown 3s linear forwards;
}

/* ---- Level Up — по центру экрана ---- */
.level-up-notification {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 380px;
    background: white;
    border-radius: 24px;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.2);
    transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 10001;
    overflow: hidden;
    text-align: center;
}

.level-up-notification.show {
    transform: translate(-50%, -50%) scale(1);
}

.level-up-notification::before {
    content: '';
    display: block;
    height: 6px;
    background: linear-gradient(90deg, #f093fb, #f5576c, #f093fb);
    background-size: 200% 100%;
    animation: shimmer 2s linear infinite;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.level-up-content {
    padding: 2.5rem 2rem;
}

.level-up-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    animation: bounce 0.8s ease-in-out;
    display: block;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0) scale(1); }
    40% { transform: translateY(-20px) scale(1.1); }
    60% { transform: translateY(-10px) scale(1.05); }
}

.level-up-content h3 {
    font-size: 1.75rem;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.level-up-content p {
    font-size: 1.1rem;
    color: #64748b;
}

.level-up-content strong {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #f093fb, #f5576c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Конфетти-эффект (декоративные точки) */
.level-up-notification::after {
    content: '🎊 🎉 ✨ 🎊 🎉';
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.5rem;
    letter-spacing: 4px;
    opacity: 0.6;
}

/* Оверлей для level-up */
.level-up-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(4px);
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.level-up-overlay.show {
    opacity: 1;
}

/* ---- Успех (зелёное) ---- */
.platform-notification.success {
    background: white;
    border: 1px solid #e2e8f0;
    padding: 1.25rem 1.5rem;
}
.platform-notification.success::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 4px; height: 100%;
    background: linear-gradient(180deg, #10b981, #059669);
    border-radius: 16px 0 0 16px;
}
.platform-notification.success .notif-icon { color: #10b981; font-size: 1.75rem; }
.platform-notification.success .notif-title { color: #065f46; font-weight: 700; }
.platform-notification.success .notif-msg { color: #64748b; }
.platform-notification.success::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0;
    height: 3px; width: 100%;
    background: linear-gradient(90deg, #10b981, #059669);
    animation: countdown 3.5s linear forwards;
}

/* Общий контент для platform-notification */
.platform-notification .notif-content {
    display: flex;
    align-items: center;
    gap: 0.875rem;
}
.platform-notification .notif-icon { flex-shrink: 0; }
.platform-notification .notif-title {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
}
.platform-notification .notif-msg {
    font-size: 0.8rem;
    margin: 0;
    line-height: 1.4;
}

/* Адаптив */
@media (max-width: 480px) {
    .antispam-notification,
    .xp-notification,
    .platform-notification {
        width: calc(100vw - 32px);
        right: -110%;
    }
    .antispam-notification.show,
    .xp-notification.show,
    .platform-notification.show {
        right: 16px;
    }
    .level-up-notification {
        width: calc(100vw - 48px);
    }
}
