* {
    margin: 0;
    padding: 0;
    font-family: 'Josefin Sans', sans-serif;
}

.hide {
    display: none;
}

.carGame {
    width: 100%;
    height: 100vh;
    background-image: url('assets/images/bg.jpg');
    background-repeat: no-repeat;
    background-size: 100% 100%;
}

.car, .enemyCar {
    width: 50px;
    height: 70px;
    background: red;
    position: absolute;
    bottom: 120px;
    background-image: url('assets/images/car.png');
    background-repeat: no-repeat;
    background-size: 100% 100%;
}

.roadLines {
    width: 10px;
    height: 100px;
    position: absolute;
    background: white;
    margin-left: 195px; /* show line in center = (gameArea.width / 2) - (roadLines.width / 2) */
}

.gameArea {
    width: 400px;
    height: 100vh;
    background: #2d3436;
    margin: auto;
    position: relative;
    overflow: hidden;
    border-right: 7px dashed #c8d6e5;
    border-left: 7px dashed #c8d6e5;
}

.score {
    position: absolute;
    top: 15px;
    left: 40px;
    background: #10ac84;
    width: 300px;
    line-height: 70px;
    text-align: center;
    color: white;
    font-size: 1.5em;
    box-shadow: 0 5px 5px #777;
}

.startScreen {
    position: absolute;
    background-color: #ee5253;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    color: white;
    z-index: 1;
    text-align: center;
    border: 1px solid #ff6b6b;
    padding: 15px;
    margin: auto;
    width: 50%;
    cursor: pointer;
    letter-spacing: 5;
    font-size: 20px;
    word-spacing: 3;
    line-height: 30px;
    text-transform: uppercase;
    box-shadow: 0 5px 5px #777;
}

.level button {
    padding: 7px;
    font-size: 14px;
    background: white;
    border: 1px solid orangered;
    border-radius: 10px;
    width: 80px;
    cursor: pointer;
    outline: none;
    box-shadow: 0 5px 5px #777777a6;
}

/* Control Buttons */
.controlButtons {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.controlButtons button {
    width: 60px;
    height: 60px;
    margin: 5px;
    font-size: 24px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid #333;
    border-radius: 30px;
    cursor: pointer;
    box-shadow: 0 5px 5px #777;
}

/* Back Button */
.backButton {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 10px 15px;
    font-size: 16px;
    cursor: pointer;
    background-color: #f44336; /* Red background */
    color: white; /* White text */
    border: none; /* No border */
    border-radius: 5px; /* Rounded corners */
    box-shadow: 0 5px 5px #777;
}

/* Mobile Styles */
@media (max-width: 600px) {
    .controlButtons {
        bottom: 10px; /* Adjust position for smaller screens */
    }
    .controlButtons button {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
    .backButton {
        font-size: 14px;
        padding: 8px 12px;
    }
}