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

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    color: white;
}

#game-container {
    width: 100%;
    max-width: 1000px;
    position: relative;
}

.screen {
    text-align: center;
    padding: 20px;
}

.screen.hidden {
    display: none;
}

#menu-screen h1 {
    font-size: 4em;
    margin-bottom: 30px;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.5);
    color: #ffd700;
}

#level-select {
    background: rgba(0, 0, 0, 0.3);
    padding: 30px;
    border-radius: 15px;
    margin-bottom: 30px;
}

#level-select h2 {
    margin-bottom: 20px;
    font-size: 2em;
}

#level-buttons {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.level-btn {
    padding: 20px;
    font-size: 1.2em;
    font-weight: bold;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.level-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.level-btn:active {
    transform: translateY(0);
}

.instructions {
    background: rgba(0, 0, 0, 0.3);
    padding: 20px;
    border-radius: 15px;
    text-align: left;
    max-width: 500px;
    margin: 0 auto;
}

.instructions h3 {
    margin-bottom: 15px;
    font-size: 1.5em;
    text-align: center;
}

.instructions p {
    margin: 8px 0;
    font-size: 1.1em;
}

#game-screen {
    position: relative;
}

#hud {
    display: flex;
    justify-content: space-around;
    padding: 15px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 10px;
    margin-bottom: 10px;
    font-size: 1.2em;
    font-weight: bold;
}

#hud > div {
    display: flex;
    align-items: center;
    gap: 8px;
}

#boost-bar {
    display: inline-block;
    width: 100px;
    height: 20px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    position: relative;
    overflow: hidden;
}

#boost-bar::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: var(--boost-width, 0%);
    background: linear-gradient(90deg, #ffd700, #ff8c00);
    border-radius: 10px;
    transition: width 0.1s;
}

#game-canvas {
    display: block;
    background: #1a1a1a;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    margin: 0 auto;
}

#win-screen h1 {
    font-size: 4em;
    color: #00ff00;
    margin-bottom: 30px;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.5);
}

#lose-screen h1 {
    font-size: 4em;
    color: #ff0000;
    margin-bottom: 30px;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.5);
}

#win-screen p,
#lose-screen p {
    font-size: 1.5em;
    margin-bottom: 30px;
}

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

button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

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