#game-container {
    width: 1024px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    padding-bottom: 120px;
}

#overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 10;
}

#start-button {
    font-size: 24px;
    padding: 15px 30px;
    cursor: pointer;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 5px;
}

#start-button:hover {
    background-color: #45a049;
}

#countdown {
    font-size: 48px;
    color: white;
    margin-top: 20px;
}

#gameCanvas {
    border: 1px solid black;
    background-color: #fff;
}

#score, #high-score {
    font-size: 24px;
    margin-top: 10px;
}

#game-over-msg {
    font-size: 72px;
    color: red;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

#touch-controls {
    position: sticky;
    bottom: 0;
    width: 100%;
    max-width: 1024px;
    height: 200px;
    background: rgba(0, 0, 0, 0.4);
    border-top: 8px solid #ffd700;
    border-bottom: 8px solid #ffd700;
    border-left: 8px solid #ffd700;
    border-right: 8px solid #ffd700;
    z-index: 1000;
    display: none;
    margin: 20px auto 0 auto;
}

.touch-area {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.touch-hint {
    color: #ffd700;
    font-size: 28px;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    pointer-events: none;
}

.touch-footer {
    height: 50px;
    width: 100%;
    max-width: 1024px;
    background: #333;
    margin: 20px auto 0 auto;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

/* Make game container responsive */
@media (max-width: 768px) {
    #game-container {
        width: 100%;
        max-width: 1024px;
        margin: 0 auto;
        padding: 0 15px;
    }

    #touch-controls {
        display: block !important;
        width: calc(100% - 30px);
        margin-left: 15px;
        margin-right: 15px;
    }

    #gameCanvas {
        max-width: 100%;
        height: auto;
    }

    .touch-footer {
        width: calc(100% - 30px);
        margin-left: 15px;
        margin-right: 15px;
    }

    /* Add responsive game over text */
    #game-over-msg {
        font-size: 48px; /* Smaller font size for mobile */
    }

    #game-over-msg span {
        font-size: 32px; /* Even smaller for the score text */
    }
}