html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow: hidden; /* Prevent scrollbars from appearing */
    display: flex;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
    background-color: #ffffff;
    color:  #061928;
    position: relative; /* Relative positioning to contain absolute elements */
}

/* Ensure the container and game elements are centered and above the rain */
.container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative; 
    width: 100vw;
    max-width: 1200px; /* Adjust based on your desired layout */
    padding: 20px;
    box-sizing: border-box;
    z-index: 10; /* Keep the container above the rain */
}

/* Rain container should span the entire viewport */
.rain {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw; /* Ensure it's 100% of the container width */
    height: 100vh; /* Ensure it's 100% of the container height */
    pointer-events: none;
    z-index: 0;
}

/* The raindrops stay the same */
.raindrop {
    position: absolute;
    bottom: 100%;
    width: 2px;
    height: 80px;
    background: rgba(10, 10, 10, 0.6);
    animation: fall 1.5s linear infinite;
}

@keyframes fall {
    to {
        transform: translateY(100vh);
    }
}

/* For screens wider than 768px, display game elements in a row */
@media (min-width: 768px) {
    .container {
        flex-direction: row;
        justify-content: space-around;
    }
}

.instructions, .hud {
    width: 100vw;
    max-width: 300px; /* Set a maximum width for text sections */
    margin: 10px;
    box-sizing: border-box;
}

canvas {
    width: 100vw;
    max-width: 800px;
    height: auto;
    border: 10px solid rgb(97, 96, 96);
    background-color: #2e2e2e;
    z-index: 1; /* Keep the game above the rain */
}

.hud {
    width: 100%;
    max-width: 300px; /* Set a maximum width for text sections */
    margin: 10px;
    box-sizing: border-box;
}

#dweetcanvas {
    width: 100vw;
    max-width: 800px;
    height: auto;
    border: 10px solid rgb(5, 5, 5);
    background-color: #2e2e2e;
    z-index: 1; /* Keep the game above the rain */
}

#gameTitle {
    position: absolute;
    top: -10%;
    left: 0;
    width: 100%;
    text-align: center;
    font-size: 36px;
    color: #ff0000; /* You can change the color */
    background-color: #000; /* You can change the background */
    z-index: 100; /* Make sure it's above everything */
    padding: 10px;
}
