.level-up-animation {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 9999;
    background: rgba(0, 0, 0, 0.9);
    color: #fff;
    padding: 2rem 3rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.7);
    display: none;
    animation: levelUp 1.5s ease-out;
    border: 2px solid gold;
    max-width: 80%;
}

.level-up-title {
    font-size: 2.5rem;
    color: gold;
    margin-bottom: 1rem;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.7);
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.level-up-level {
    font-size: 4rem;
    font-weight: bold;
    color: white;
    margin: 1rem 0;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.8);
}

.level-up-progress {
    width: 100%;
    height: 20px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    margin-top: 1.5rem;
    overflow: hidden;
}

.level-up-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, gold, orange);
    width: 0;
    transition: width 1s ease;
}

@keyframes levelUp {
    0% { transform: translate(-50%, -50%) scale(0.1); opacity: 0; }
    50% { transform: translate(-50%, -50%) scale(1.1); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
}

.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    background-color: gold;
    opacity: 0;
    z-index: 9998;
}

@media (max-width: 768px) {
    .level-up-title {
        font-size: 1.8rem;
    }

    .level-up-level {
        font-size: 3rem;
    }
}
