/* =============================================
   VICTORY MODAL - Estilo Valorant
   ============================================= */

/* Overlay */
#successModal.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
    backdrop-filter: blur(6px);
}

#successModal.modal-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* Modal box */
.success-modal {
    position: relative;
    width: 100%;
    max-width: 700px;
    padding: 0;
    background: transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    transform: translateY(30px) scale(0.95);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

#successModal.modal-overlay.active .success-modal {
    transform: translateY(0) scale(1);
}

/* VICTORY title */
.victory-title-wrap {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    position: relative;
}

.victory-score {
    font-family: 'Tungsten', sans-serif;
    font-size: 3rem;
    font-weight: 900;
    color: white;
    letter-spacing: -1px;
    opacity: 0;
    animation: fadeSlideIn 0.6s ease 0.2s forwards;
}

.victory-score.right {
    color: var(--valorant-red, #ff4655);
}

.victory-label {
    font-family: 'Tungsten', sans-serif;
    font-size: 6rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 8px;
    color: #00dfb6;
    text-shadow:
        0 0 30px rgba(0, 223, 182, 0.6),
        0 0 60px rgba(0, 223, 182, 0.3);
    opacity: 0;
    animation: victoryReveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0s forwards;
    line-height: 1;
}

/* Mode subtitle */
.victory-mode-label {
    font-family: 'Tungsten', sans-serif;
    font-size: 1.4rem;
    letter-spacing: 6px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
    opacity: 0;
    animation: fadeSlideIn 0.5s ease 0.5s forwards;
}

/* Image area */
.success-image-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    opacity: 0;
    animation: fadeSlideIn 0.6s ease 0.7s forwards;
}

.success-item-name {
    font-family: 'Tungsten', sans-serif;
    font-size: 2.2rem;
    letter-spacing: 4px;
    color: white;
    text-transform: uppercase;
    text-align: center;
    margin: 0;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
}

.success-item-image-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(0, 223, 182, 0.15);
    padding: 1.5rem 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 160px;
    min-width: 300px;
}

.success-item-image-box img {
    max-height: 180px;
    max-width: 100%;
    object-fit: contain;
    filter: drop-shadow(0 0 20px rgba(0, 0, 0, 0.6));
}

/* Cooldown */
.success-cooldown {
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    letter-spacing: 2px;
    color: rgba(255, 70, 85, 0.8);
    text-transform: uppercase;
    opacity: 0;
    animation: fadeSlideIn 0.5s ease 0.9s forwards;
}

/* Continue button */
.success-close-button {
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.25);
    padding: 0.8rem 4rem;
    font-family: 'Tungsten', sans-serif;
    font-size: 1.4rem;
    letter-spacing: 5px;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.25s ease;
    opacity: 0;
    animation: fadeSlideIn 0.5s ease 1s forwards;
}

.success-close-button:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.6);
}

/* Scan lines decoration */
.victory-scanlines {
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(0deg,
            transparent,
            transparent 2px,
            rgba(0, 223, 182, 0.015) 2px,
            rgba(0, 223, 182, 0.015) 4px);
    pointer-events: none;
    animation: scanlinePulse 4s ease-in-out infinite;
}

/* Keyframes */
@keyframes victoryReveal {
    0% {
        opacity: 0;
        transform: scaleX(0.5) scaleY(1.3);
        letter-spacing: 30px;
    }

    60% {
        opacity: 1;
        transform: scaleX(1.05) scaleY(0.95);
        letter-spacing: 6px;
    }

    100% {
        opacity: 1;
        transform: scale(1);
        letter-spacing: 8px;
    }
}

@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

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

@keyframes scanlinePulse {

    0%,
    100% {
        opacity: 0.5;
    }

    50% {
        opacity: 1;
    }
}

/* Mobile */
@media (max-width: 600px) {
    .victory-label {
        font-size: 4rem;
        letter-spacing: 5px;
    }

    .victory-score {
        font-size: 2rem;
    }

    .success-item-image-box {
        padding: 1rem;
        min-width: 200px;
    }
}