/**
 * First AI Use Celebration Modal Styles
 */

/* Overlay */
.celebration-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.celebration-modal-overlay.is-visible {
    opacity: 1;
    visibility: visible;
}

/* Modal container */
.celebration-modal {
    position: relative;
    width: 90%;
    max-width: 440px;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: 1px solid rgba(0, 217, 255, 0.3);
    border-radius: 16px;
    box-shadow:
        0 0 60px rgba(0, 217, 255, 0.2),
        0 20px 60px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.celebration-modal-overlay.is-visible .celebration-modal {
    transform: scale(1) translateY(0);
}

/* Confetti container */
.celebration-confetti {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.confetti-particle {
    position: absolute;
    top: -10px;
    left: var(--x, 50%);
    width: 10px;
    height: 10px;
    background: var(--color, #00D9FF);
    opacity: 0;
    transform: rotate(var(--rotation, 0deg));
    animation: confetti-fall 3s ease-out var(--delay, 0s) forwards;
}

.confetti-particle:nth-child(odd) {
    width: 8px;
    height: 12px;
    border-radius: 2px;
}

.confetti-particle:nth-child(even) {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

@keyframes confetti-fall {
    0% {
        opacity: 1;
        transform: translateY(0) rotate(var(--rotation, 0deg));
    }
    100% {
        opacity: 0;
        transform: translateY(400px) rotate(calc(var(--rotation, 0deg) + 720deg));
    }
}

/* Content */
.celebration-content {
    position: relative;
    z-index: 1;
    padding: 32px;
    text-align: center;
}

/* Icon */
.celebration-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 96px;
    height: 96px;
    margin-bottom: 20px;
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.2) 0%, rgba(0, 255, 136, 0.1) 100%);
    border-radius: 50%;
    color: #00D9FF;
    animation: icon-pulse 2s ease-in-out infinite;
}

@keyframes icon-pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(0, 217, 255, 0.4);
    }
    50% {
        box-shadow: 0 0 0 20px rgba(0, 217, 255, 0);
    }
}

/* Title */
.celebration-title {
    margin: 0 0 12px;
    font-size: 1.75rem;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #00D9FF 0%, #00FF88 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Message */
.celebration-message {
    margin: 0 0 24px;
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
}

/* Tips */
.celebration-tips {
    text-align: left;
    padding: 16px 20px;
    margin-bottom: 24px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.celebration-tips h4 {
    margin: 0 0 12px;
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.celebration-tips ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.celebration-tips li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

.celebration-tips li:last-child {
    margin-bottom: 0;
}

.celebration-tips li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    color: #00FF88;
    font-weight: bold;
}

/* Dismiss button */
.celebration-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 32px;
    font-size: 1rem;
    font-weight: 600;
    color: #1a1a2e;
    background: linear-gradient(135deg, #00D9FF 0%, #00FF88 100%);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.celebration-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 217, 255, 0.3);
}

.celebration-btn:active {
    transform: translateY(0);
}

/* Credit badge highlight animation */
.credit-badge--highlight {
    animation: badge-highlight 0.6s ease-out 3;
}

@keyframes badge-highlight {
    0%, 100% {
        transform: scale(1);
        box-shadow: none;
    }
    50% {
        transform: scale(1.1);
        box-shadow: 0 0 20px rgba(0, 217, 255, 0.5);
    }
}

/* Responsive */
@media (max-width: 480px) {
    .celebration-content {
        padding: 24px 20px;
    }

    .celebration-icon {
        width: 72px;
        height: 72px;
    }

    .celebration-icon svg {
        width: 48px;
        height: 48px;
    }

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

    .celebration-tips {
        padding: 12px 16px;
    }

    .celebration-btn {
        width: 100%;
        padding: 12px 24px;
    }
}
