/* ========================================
   SUCCESS MODAL STYLES
   ======================================== */

.success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease-out;
}

.success-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.success-card {
    position: relative;
    z-index: 2;
    background: var(--surface);
    border-radius: var(--radius-xl);
    padding: 3rem 2.5rem;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border);
    max-width: 480px;
    width: 90%;
    text-align: center;
    animation: slideUpFade 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

/* Celebration Animation Background */
.success-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
}

@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Success Icon */
.success-icon-wrapper {
    width: 80px;
    height: 80px;
    background: rgba(16, 185, 129, 0.1);
    /* Green tint */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: #10b981;
    /* Success Green */
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.2s backwards;
}

.success-icon {
    width: 40px;
    height: 40px;
    stroke-width: 3;
}

@keyframes popIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.success-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.success-subtitle {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 1rem;
}

/* Stats Grid */
.success-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 2.5rem;
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
}

.stat-box {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    position: relative;
}

.stat-box:not(:last-child)::after {
    content: '';
    position: absolute;
    right: -0.5rem;
    top: 15%;
    bottom: 15%;
    width: 1px;
    background: var(--border-light);
    opacity: 0.5;
}

.stat-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    font-weight: 600;
}

.stat-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-value.highlight {
    color: var(--primary);
}

/* Actions */
.success-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.success-actions .btn {
    width: 100%;
    justify-content: center;
}

.btn-secondary-outline {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-primary);
}

.btn-secondary-outline:hover {
    background: var(--bg-secondary);
    border-color: var(--border-hover);
}

/* Dark Mode Overrides */
body.dark-mode .success-icon-wrapper {
    background: rgba(16, 185, 129, 0.2);
}

body.dark-mode .success-stats {
    background: rgba(255, 255, 255, 0.03);
}

body.dark-mode .success-card {
    background: var(--glass-bg);
    border-color: var(--glass-border);
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
    .success-card {
        padding: 2rem 1.5rem;
        max-width: 95%;
    }

    .success-title {
        font-size: 1.5rem;
    }

    .success-stats {
        grid-template-columns: 1fr;
        gap: 0.75rem;
        padding: 1rem;
    }

    .stat-box::after {
        content: none;
    }

    .stat-box {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 0.5rem 0;
        border-bottom: 1px solid var(--border-light);
    }

    .stat-box:last-child {
        border-bottom: none;
    }

    .success-icon-wrapper {
        width: 64px;
        height: 64px;
        margin-bottom: 1rem;
    }

    .success-icon {
        width: 32px;
        height: 32px;
    }
}

@media (max-width: 480px) {
    .success-card {
        padding: 1.5rem 1rem;
        width: 100%;
        max-width: 100%;
        margin: 0.5rem;
    }

    .success-title {
        font-size: 1.25rem;
    }

    .success-subtitle {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }

    .success-stats {
        margin-bottom: 1.5rem;
    }

    .stat-label {
        font-size: 0.7rem;
    }

    .stat-value {
        font-size: 1rem;
    }

    .success-actions .btn {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
}