body {
    font-family: 'Space Mono', monospace;
    background-color: #050510;
    background-image: radial-gradient(circle at center, #101020, #050510);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    color: #f0f0f0; 
}

#game-container {
    position: relative;
    text-align: center;
    background-color: rgba(10, 10, 30, 0.5);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 0 40px rgba(0, 200, 255, 0.2), 0 0 10px rgba(0, 200, 255, 0.4);
    border: 1px solid rgba(0, 200, 255, 0.3);
}

#myCanvas {
    background: #000000;
    display: block;
    border: 1px solid #00c8ff;
    box-shadow: 0 0 10px #00c8ff;
    margin: 0 auto;
}

/* --- STATS PANEL UPDATED --- */
#stats-panel {
    display: flex;
    justify-content: space-between;
    align-items: center; /* Vertically center the button */
    padding: 8px 15px;
    margin-bottom: 15px;
    background-color: rgba(0, 200, 255, 0.1); 
    border-radius: 8px;
    border: 1px solid rgba(0, 200, 255, 0.2);
    width: 800px; /* Matched to canvas width */
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box; /* Ensures padding doesn't break width */
}

#stats-info {
    display: flex;
    gap: 20px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#score-display, #lives-display {
    font-size: 1.1em;
    color: #99ffff; 
    text-shadow: 0 0 5px #00c8ff; 
}

#high-score-display {
    font-size: 1.1em;
    color: #ff0077;
    text-shadow: 0 0 5px #ff0077;
}

/* --- NEW MENU BUTTON --- */
#menu-btn {
    background: transparent;
    border: 1px solid #00c8ff;
    color: #00c8ff;
    padding: 5px 15px;
    font-family: 'Space Mono', monospace;
    font-weight: bold;
    cursor: pointer;
    border-radius: 5px;
    transition: all 0.2s;
}

#menu-btn:hover {
    background: #00c8ff;
    color: #000;
    box-shadow: 0 0 10px #00c8ff;
}

/* --- DROPDOWN MENU --- */
#dropdown-menu {
    position: absolute;
    top: 65px; /* Positioned below stats panel */
    right: 20px; /* Aligned to right */
    width: 200px;
    background: rgba(10, 10, 20, 0.95);
    border: 1px solid #00c8ff;
    border-radius: 8px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    z-index: 200;
    box-shadow: 0 0 20px rgba(0, 200, 255, 0.3);
}

.hidden {
    display: none !important;
}

.dd-item {
    background: transparent;
    border: none;
    color: #fff;
    padding: 10px;
    text-align: left;
    font-family: 'Space Mono', monospace;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.2s;
    font-size: 1em;
}

.dd-item:hover {
    background: rgba(0, 200, 255, 0.2);
    color: #00c8ff;
}

.dd-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.2);
    margin: 8px 0;
}

.dd-label {
    font-size: 0.8em;
    color: #888;
    padding: 5px 10px;
    text-transform: uppercase;
}

/* --- OVERLAY MENU (Start/End) --- */
.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 15px;
    z-index: 100;
}

#menu-title {
    color: #00e5ff;
    font-size: 3.2em;
    font-weight: 800;
    margin-bottom: 10px;
    text-shadow: 0 0 15px #00e5ff;
}

#menu-subtitle {
    color: #b3e5fc;
    margin-bottom: 30px;
    font-size: 1em;
    max-width: 80%;
}

.overlay button {
    padding: 15px 40px;
    margin: 10px;
    font-size: 1.2em;
    font-weight: 700;
    color: #050510;
    background-color: #00e5ff;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 0 15px #00e5ff;
}

.overlay button:hover {
    background-color: #fff;
    box-shadow: 0 0 25px #00e5ff;
    transform: scale(1.05);
}

#touch-controls {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 15px;
}

#touch-controls button {
    width: 80px;
    height: 50px;
    font-size: 1.5em;
    background-color: rgba(0, 200, 255, 0.1);
    color: #00e5ff;
    border: 1px solid #00e5ff;
    border-radius: 8px;
}