* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    background-color: #000000;
    background-image: url('chaosbackground.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

body.winner {
    background-image: linear-gradient(135deg, rgba(17, 153, 142, 0.9) 0%, rgba(56, 239, 125, 0.9) 100%), url('chaosbackground.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
    animation: winPulse 2s ease-in-out infinite;
}

body.loser {
    background-image: linear-gradient(135deg, rgba(44, 62, 80, 0.9) 0%, rgba(52, 73, 94, 0.9) 100%), url('chaosbackground.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

.container {
    max-width: 600px;
    padding: 40px;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

.result-title {
    font-size: 64px;
    font-weight: bold;
    margin-bottom: 20px;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.5);
    animation: titleBounce 1s ease-out;
}

.result-title.win {
    color: #ffff00;
}

.result-title.lose {
    color: #ff4444;
}

.result-message {
    font-size: 28px;
    margin-bottom: 40px;
    letter-spacing: 2px;
}

.stats {
    margin: 30px 0;
    padding: 20px;
    background: rgba(0,0,0,0.3);
    border-radius: 10px;
}

.stats p {
    font-size: 20px;
    letter-spacing: 1px;
}

.buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 40px;
}

.btn {
    display: inline-block;
    padding: 15px 40px;
    font-size: 20px;
    font-weight: bold;
    letter-spacing: 2px;
    text-decoration: none;
    color: white;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
}

.btn.play-again {
    background: linear-gradient(45deg, #f093fb 0%, #f5576c 100%);
}

.btn.home {
    background: linear-gradient(45deg, #667eea 0%, #764ba2 100%);
}

.btn:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

@keyframes titleBounce {
    0% {
        opacity: 0;
        transform: translateY(-50px) scale(0.5);
    }
    50% {
        transform: translateY(10px) scale(1.1);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes winPulse {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}
