:root {
    --bg-color: #f7f7f7;
    --text-color: #535353;
    --accent-color: #202124;
}

body {
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background-color: var(--bg-color);
    font-family: 'Press Start 2P', monospace;
    /* Pixel font */
    overflow: hidden;
    user-select: none;
}

#game-container {
    position: relative;
    width: 900px;
    height: 400px;
    background-color: #fff;
    border-bottom: 2px solid var(--text-color);
    overflow: hidden;
}

#gameCanvas {
    display: block;
    width: 100%;
    height: 100%;
}

#cheat-code {
    position: absolute;
    bottom: 10px;
    left: 10px;
    color: var(--text-color);
    font-size: 8px;
    opacity: 0.6;
    z-index: 5;
    pointer-events: none;
}

#instructions {
    position: absolute;
    top: 10px;
    left: 10px;
    color: var(--text-color);
    opacity: 0.5;
    font-size: 10px;
    line-height: 1.5;
    z-index: 10;
    pointer-events: none;
}

#score {
    position: absolute;
    top: 10px;
    right: 10px;
    color: var(--text-color);
    font-size: 16px;
    z-index: 10;
}

#game-over {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: var(--text-color);
    z-index: 20;
}

/* Start Menu Styling */
#start-menu {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #f7f7f7;
    /* Light bg to match game */
    z-index: 30;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

#start-menu .title {
    font-size: 48px;
    line-height: 1.2;
    margin: 0 0 20px 0;
    color: #535353;
    /* Dark Gray text */
    text-shadow: 4px 4px 0px #d0d0d0;
    /* Light Gray shadow */
    letter-spacing: 2px;
    animation: float 3s ease-in-out infinite;
}

#start-menu .subtitle {
    font-size: 16px;
    color: #535353;
    margin-bottom: 50px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

#start-btn {
    font-family: 'Press Start 2P', monospace;
    font-size: 20px;
    padding: 15px 30px;
    background-color: #535353;
    /* Dark button */
    color: #f7f7f7;
    /* Light text */
    border: none;
    box-shadow: 0px 6px 0px #202020;
    /* Darker shadow */
    cursor: pointer;
    transition: transform 0.1s, box-shadow 0.1s;
    animation: blink 1.2s infinite;
}

#start-btn:active {
    transform: translateY(4px);
    box-shadow: 0px 2px 0px #202020;
}

.hidden {
    display: none !important;
}

.small {
    font-size: 12px;
    margin-top: 10px;
    color: #888;
}

/* Scanline effect for slight retro feel (optional) */
#game-container::before {
    content: " ";
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.05) 50%);
    background-size: 100% 4px;
    z-index: 2;
    pointer-events: none;
    /* Ensure it doesn't block clicks on the start button */
}

/* Animations */
@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0px);
    }
}

@keyframes blink {

    0%,
    50%,
    100% {
        opacity: 1;
    }

    25%,
    75% {
        opacity: 0.8;
    }
}