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

body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: #000;
    font-family: Arial, sans-serif;
}

.game-container {
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

canvas {
    max-width: 100%;
    height: auto;
    aspect-ratio: 800/600;
    display: block;
    background-color: #000;
    border: 2px solid #333;
}

.game-ui {
    position: fixed;
    top: 20px;
    left: 20px;
    color: #fff;
    font-family: Arial, sans-serif;
    z-index: 10;
    font-size: 24px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.score {
    font-size: 24px;
    font-weight: bold;
}

.game-over {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.8);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    color: #fff;
}

.game-over h2 {
    font-size: 36px;
    margin-bottom: 20px;
}

.game-over button {
    background: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    margin-top: 15px;
    transition: background-color 0.3s;
}

.game-over button:hover {
    background: #45a049;
}

.hidden {
    display: none;
}

@media (max-width: 800px) {
    .game-container {
        padding: 10px;
    }
    
    canvas {
        width: 100%;
        max-height: calc(100vh - 40px);
    }
    
    .game-ui {
        top: 10px;
        left: 10px;
    }
    
    .score {
        font-size: 20px;
    }
}
