* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.game-container {
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    max-width: 900px;
    width: 100%;
}

.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    text-align: center;
}

.header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.stats {
    display: flex;
    justify-content: center;
    gap: 30px;
    font-size: 1.1em;
}

.stat {
    display: flex;
    gap: 8px;
    align-items: center;
}

.stat .label {
    opacity: 0.9;
}

.stat .value {
    font-weight: bold;
    min-width: 60px;
}

.game-board {
    background: linear-gradient(180deg, #87ceeb 0%, #e0f6ff 100%);
    position: relative;
    height: 400px;
    overflow: hidden;
    border: 3px solid #667eea;
}

.player {
    position: absolute;
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, #ff6b6b 0%, #ff8e72 100%);
    left: 50px;
    bottom: 60px;
    border-radius: 3px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 10;
    transition: transform 0.05s ease;
}

.player.jumping {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.ground {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 50px;
    background: linear-gradient(180deg, #90EE90 0%, #228B22 100%);
    border-top: 3px solid #1a6b1a;
}

.obstacle {
    position: absolute;
    bottom: 50px;
    background: linear-gradient(135deg, #ff4757 0%, #ffa502 100%);
    border-radius: 2px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.obstacle.spike {
    clip-path: polygon(50% 0%, 100% 100%, 0% 100%);
    height: 30px;
    width: 30px;
}

.obstacle.block {
    height: 50px;
    width: 40px;
    border: 2px solid #d32f2f;
}

.obstacle.tall-spike {
    clip-path: polygon(50% 0%, 100% 100%, 0% 100%);
    height: 50px;
    width: 40px;
}

.game-over-screen {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 100;
    justify-content: center;
    align-items: center;
}

.game-over-screen.show {
    display: flex;
}

.game-over-content {
    background: white;
    padding: 40px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    animation: popIn 0.3s ease;
}

@keyframes popIn {
    0% {
        transform: scale(0.5);
        opacity: 0;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.game-over-content h2 {
    font-size: 2.5em;
    color: #ff6b6b;
    margin-bottom: 20px;
}

.game-over-content p {
    font-size: 1.5em;
    color: #333;
    margin-bottom: 30px;
    font-weight: bold;
}

#restartBtn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.1em;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    font-weight: bold;
}

#restartBtn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

#restartBtn:active {
    transform: translateY(0);
}

.controls {
    background: #f5f5f5;
    padding: 15px;
    text-align: center;
    color: #666;
    border-top: 1px solid #ddd;
    font-size: 0.9em;
}

@media (max-width: 600px) {
    .header h1 {
        font-size: 2em;
    }

    .stats {
        gap: 20px;
        font-size: 0.9em;
    }

    .game-board {
        height: 300px;
    }

    .player {
        width: 25px;
        height: 25px;
        left: 30px;
        bottom: 50px;
    }
}
