﻿/* ==================== Ritz Push Notification UI ==================== */

#ritz-push-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 420px;
    width: calc(100% - 40px);
    pointer-events: none;
}

.ritz-push-notification {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px 18px;
    background: #ffffff;
    border-radius: 16px;
    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.12),
        0 2px 10px rgba(0, 0, 0, 0.06),
        0 0 0 1px rgba(0, 0, 0, 0.04);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    pointer-events: all;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ritz-push-notification:hover {
    transform: translateY(-2px);
    box-shadow:
        0 14px 50px rgba(0, 0, 0, 0.16),
        0 4px 14px rgba(0, 0, 0, 0.08),
        0 0 0 1px rgba(0, 0, 0, 0.06);
}

/* Icon */
.ritz-push-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #ffffff;
    font-size: 18px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Content */
.ritz-push-content {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.ritz-push-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 4px;
}

.ritz-push-title {
    font-weight: 700;
    font-size: 14px;
    color: #1a1a2e;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: 'Inter', 'Montserrat', sans-serif;
}

.ritz-push-time {
    font-size: 11px;
    color: #9ca3af;
    white-space: nowrap;
    flex-shrink: 0;
    font-weight: 500;
}

.ritz-push-body {
    font-size: 13px;
    color: #6b7280;
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-family: 'Inter', 'Montserrat', sans-serif;
}

/* Close button */
.ritz-push-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: none;
    background: #f3f4f6;
    color: #9ca3af;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    transition: all 0.2s ease;
    padding: 0;
    box-shadow: none;
    margin: 0;
}

.ritz-push-close:hover {
    background: #e5e7eb;
    color: #374151;
    transform: none;
    box-shadow: none;
}

/* Progress bar (auto-dismiss indicator) */
.ritz-push-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary, #1a1f3a), #D4A84B);
    border-radius: 0 0 16px 16px;
    animation: ritz-push-progress 6s linear forwards;
}

@keyframes ritz-push-progress {
    from { width: 100%; }
    to { width: 0%; }
}

/* Slide-in animation */
.ritz-push-slide-in {
    animation: ritzPushSlideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes ritzPushSlideIn {
    from {
        opacity: 0;
        transform: translateX(100px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

/* Slide-out animation */
.ritz-push-slide-out {
    animation: ritzPushSlideOut 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes ritzPushSlideOut {
    from {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateX(100px) scale(0.9);
    }
}


@media (max-width: 480px) {
    #ritz-push-container {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
        width: auto;
    }

    .ritz-push-notification {
        padding: 12px 14px;
        border-radius: 14px;
        gap: 10px;
    }

    .ritz-push-icon {
        width: 38px;
        height: 38px;
        font-size: 16px;
        border-radius: 10px;
    }

    .ritz-push-title {
        font-size: 13px;
    }

    .ritz-push-body {
        font-size: 12px;
    }
}

/* ==================== Dark mode support ==================== */

@media (prefers-color-scheme: dark) {
    .ritz-push-notification {
        background: #1f2937;
        box-shadow:
            0 10px 40px rgba(0, 0, 0, 0.3),
            0 2px 10px rgba(0, 0, 0, 0.2),
            0 0 0 1px rgba(255, 255, 255, 0.06);
    }

    .ritz-push-title {
        color: #f9fafb;
    }

    .ritz-push-body {
        color: #9ca3af;
    }

    .ritz-push-close {
        background: #374151;
        color: #9ca3af;
    }

    .ritz-push-close:hover {
        background: #4b5563;
        color: #d1d5db;
    }
}
