/* General Body Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    display: flex;
    flex-direction: column; /* Stack children vertically */
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    background-color: #282c34; /* Dark background for contrast */
    color: #e0e0e0; /* Light text color */
    line-height: 1.6;
    padding: 20px; /* Add some padding around the body content for small screens */
    box-sizing: border-box; /* Include padding in the element's total width and height */
}

/* Optional: Add a title style */
h1 {
    color: #61afef;
    margin-bottom: 30px;
    font-size: 2.5em;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    text-align: center; /* Ensure title is centered */
}

h2 {
    color: #9cdcfe; /* A lighter blue for subheadings */
    margin-top: 30px;
    margin-bottom: 15px;
    font-size: 1.8em;
    text-align: center; /* Ensure subheading is centered */
}


/* Container for centering content */
.container {
    text-align: center;
    padding: 20px;
    background-color: #3a3f47; /* Slightly lighter dark background for the container */
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    margin-bottom: 20px; /* Adjust as needed for spacing between containers */
    width: 100%; /* Make container take full width on smaller screens */
    max-width: 900px; /* Limit overall width for larger screens */
    box-sizing: border-box; /* Include padding in the element's total width and height */
}

/* Center div for buttons */
.center {
    display: flex;
    flex-wrap: wrap; /* Allows buttons to wrap to the next line */
    justify-content: center;
    gap: 15px; /* Space between buttons */
    /* max-width: 800px; /* Removed, let .container handle max-width */
    margin: 0 auto; /* Center the button group */
}

/* Button Styles */
button {
    background-color: #61afef; /* A vibrant blue */
    color: white;
    border: none;
    border-radius: 8px;
    padding: 15px 25px;
    font-size: 1.1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease; /* Smooth transitions for hover and active states */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    min-width: 180px; /* Ensure buttons have a minimum width */
    text-align: center;
    /* REMOVED: white-space: nowrap; overflow: hidden; text-overflow: ellipsis; */
    white-space: normal; /* ALLOW TEXT TO WRAP */
    word-wrap: break-word; /* Ensure long words break */
    flex: 1 1 auto; /* Allow buttons to grow and shrink, with an initial size based on content */
    max-width: 280px; /* Prevent buttons from becoming too wide on larger screens */
    box-sizing: border-box; /* Include padding and border in the element's total width and height */
}

button:hover {
    background-color: #529fdb; /* Slightly darker blue on hover */
    transform: translateY(-3px); /* Lift button slightly on hover */
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
}

button:active {
    background-color: #468ac7; /* Even darker blue when clicked */
    transform: translateY(0); /* Push button down when clicked */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* --- Media Queries for Mobile Responsiveness --- */

/* For screens smaller than 768px (common tablet portrait and mobile landscape) */
@media (max-width: 768px) {
    body {
        padding: 10px; /* Reduce body padding */
    }

    h1 {
        font-size: 2em; /* Slightly smaller heading */
        margin-bottom: 20px;
    }

    h2 {
        font-size: 1.5em; /* Slightly smaller subheading */
        margin-top: 20px;
    }

    .container {
        padding: 15px; /* Reduce container padding */
        margin-bottom: 15px;
    }

    .center {
        gap: 10px; /* Slightly smaller gap between buttons */
    }

    button {
        padding: 12px 18px; /* Slightly less padding for smaller buttons */
        font-size: 1em; /* Adjust font size */
        min-width: unset; /* Remove min-width to allow buttons to shrink more */
        flex-basis: 100%; /* Make each button take full width on smaller screens */
        max-width: 100%; /* Ensure it doesn't exceed container width */
    }
}

/* For very small screens (most mobile phones) */
@media (max-width: 480px) {
    h1 {
        font-size: 1.8em;
    }

    h2 {
        font-size: 1.3em;
    }

    button {
        font-size: 0.9em; /* Even smaller font for tiny screens */
        padding: 10px;
    }
}
