/* /css/menu.css */
#intro-screen {
    background-image: url('../img/other/startscreen.webp');
    background-repeat: no-repeat;
    background-position: center center;
    background-size: contain; /* Scale image to fit within container, maintain aspect ratio */
    z-index: 2000; /* Ensure it's above game container */
    cursor: pointer; /* Keep the pointer cursor */
    transition: opacity 0.5s ease-out;
    /* Ensure the div itself takes full viewport height/width */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

#intro-screen h1 {
    font-size: 4em;
    margin-bottom: 30px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

/* Style the container for the menu buttons */
#opening-menu {
    position: fixed; /* Keep it centered */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex; /* Use flexbox */
    flex-direction: column; /* Stack items vertically */
    justify-content: center; /* Center vertically */
    align-items: center; /* Center horizontally */
    z-index: 2000; /* Ensure it's above game, below intro if needed */
    opacity: 0; /* Start hidden */
    transition: opacity 0.5s ease-out;
    overflow: hidden; /* Ensure image doesn't overflow */
}

.menu-button {
    padding: 15px 40px;
    font-size: 1.8em;
    font-weight: bold;
    cursor: pointer;
    border: 2px solid white;
    border-radius: 8px;
    background-color: rgba(0, 0, 0, 0.3);
    color: white;
    margin: 15px;
    margin-top: 10px; /* Adjusted margin for closer buttons */
    transition: background-color 0.3s ease, transform 0.2s ease;
    min-width: 200px;
}

.menu-button:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.menu-button:active {
    transform: scale(1.02);
}

/* Class to hide elements */
.hidden {
    display: none !important;
    opacity: 0;
    pointer-events: none; /* Prevent interaction when hidden */
}

/* Style for the new background image */
.menu-background-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Cover the container, may crop */
    z-index: -1; /* Place behind the buttons */
    pointer-events: none; /* Prevent image from blocking button clicks */
}
