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

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    min-height: 100vh;
    font-family: 'Arial', sans-serif;
    background-color: #1a1a2e;
    background-image: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 20px;
}

.game-container {
    background-color: #16213e;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    padding: 20px;
    width: 600px;
    text-align: center;
    border: 3px solid #0f3460;
    margin: 0 auto;
}

h1 {
    color: #fff;
    margin-bottom: 15px;
    font-size: 24px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    font-family: 'Courier New', monospace;
}

.game-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 12px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    backdrop-filter: blur(5px);
}

.score {
    font-size: 16px;
    font-weight: bold;
    color: #fff;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.controls {
    display: flex;
    gap: 8px;
}

button {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

#start-btn {
    background-color: #4CAF50;
    color: white;
}

#start-btn:hover {
    background-color: #45a049;
}

#pause-btn {
    background-color: #ff9800;
    color: white;
}

#pause-btn:hover {
    background-color: #f57c00;
}

#reset-btn {
    background-color: #f44336;
    color: white;
}

#reset-btn:hover {
    background-color: #da190b;
}

button:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

#gameCanvas {
    background-color: #0f3460;
    border-radius: 10px;
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.5);
    margin: 15px auto;
    display: block;
    border: 2px solid #16213e;
    width: 550px;
    height: 600px;
    cursor: none;
}

.instructions {
    margin-top: 15px;
    padding: 12px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    text-align: left;
    backdrop-filter: blur(5px);
}

.instructions h3 {
    color: #fff;
    margin-bottom: 6px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    font-size: 14px;
}

.instructions p {
    color: #f0f0f0;
    margin-bottom: 4px;
    font-size: 12px;
}

@media (max-width: 650px) {
    .game-container {
        width: 100%;
        max-width: 600px;
        padding: 15px;
    }
    
    #gameCanvas {
        width: 100%;
        max-width: 550px;
        height: auto;
        aspect-ratio: 11/12;
    }
    
    h1 {
        font-size: 20px;
    }
    
    button {
        padding: 6px 12px;
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .game-info {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }
    
    .controls {
        justify-content: center;
    }
}