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

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

#gameContainer {
    width: 100%;
    max-width: 480px;
    height: 100vh;
    max-height: 800px;
    position: relative;
    background: #1a1a2e;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: linear-gradient(to bottom, #2a2a4e, #1a1a2e);
    color: white;
    padding: 20px;
}

#startScreen h1 {
    font-size: 2.5em;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    background: linear-gradient(45deg, #ffd700, #ffed4e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

#startScreen p {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: #aaa;
}

button {
    padding: 15px 40px;
    font-size: 1.2em;
    background: linear-gradient(45deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    margin: 10px;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

button:active {
    transform: translateY(0);
}

.controls-info {
    margin-top: 40px;
    text-align: center;
    background: rgba(0, 0, 0, 0.3);
    padding: 20px;
    border-radius: 10px;
}

.controls-info h3 {
    margin-bottom: 15px;
    color: #ffd700;
}

.controls-info p {
    margin: 8px 0;
    font-size: 0.9em;
    color: #ccc;
}

#gameScreen {
    padding: 0;
}

#gameCanvas {
    width: 100%;
    height: 100%;
    display: block;
    background: linear-gradient(to top, #87ceeb, #1e90ff);
}

#gameUI {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    pointer-events: none;
}

.score-display {
    display: flex;
    justify-content: space-between;
    font-size: 1.2em;
    font-weight: bold;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.score-display span {
    background: rgba(0, 0, 0, 0.3);
    padding: 8px 15px;
    border-radius: 20px;
}

.power-display {
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    padding: 5px 15px;
    background: rgba(255, 215, 0, 0.8);
    color: #333;
    border-radius: 15px;
    font-weight: bold;
    display: none;
}

.power-display.active {
    display: block;
    animation: pulse 0.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: translateX(-50%) scale(1); }
    50% { transform: translateX(-50%) scale(1.1); }
}

#gameOverScreen h2 {
    font-size: 2.5em;
    margin-bottom: 30px;
    color: #ff6b6b;
}

#gameOverScreen p {
    font-size: 1.3em;
    margin: 10px 0;
    color: #fff;
}

#highScore {
    color: #ffd700;
    font-weight: bold;
}

@media (max-width: 480px) {
    #gameContainer {
        max-width: 100%;
        max-height: 100%;
    }
    
    #startScreen h1 {
        font-size: 2em;
    }
    
    button {
        padding: 12px 30px;
        font-size: 1em;
    }
}