:root {
    --searchWidth--: 80vw;
    font-size: xx-large;
}

*,
*:before,
*:after {
    box-sizing: border-box;
}

/* Basic styling for demonstration purposes. Adjust as needed. */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    width: 100vw;
    height: 100vh;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
    overflow: hidden;
}

select {
    font-size: 1em;
}

#navbar {
    width: 100%;
    background-color: #333;
    color: #fff;
    padding: 10px;
    display: flex;
    gap: 10px;
}

#navbar button {
    background-color: #555;
    color: #fff;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
}

.full {
    width: 100%;
}

#mainMenu {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.levelBtn {
    font-size: 1em;
}

.hidden {
    display: none !important;
}

/* Modals */
.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #f4f4f4;
    padding: 20px;
    border: 2px solid #ccc;
    z-index: 100;
    width: 400px;
    max-width: 90%;
}

.modal-header {
    font-size: 18px;
    margin-bottom: 10px;
}

.modal button.close-btn {
    float: right;
    margin-top: -5px;
    cursor: pointer;
}

#modalOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99;
}

/* Game screen */
#gameScreen {
    padding: 20px;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
    grid-template-areas:
        "search"
        "results";
    overflow: hidden;
}

#search {
    grid-area: search;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    grid-template-rows: auto 1fr;
}

#results {
    overflow-y: scroll;
    grid-area: results;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    padding-left: 1em;
}

#results>div {
    display: grid;
    grid-template-columns: 1fr 5em;
}

.pred {
    height: auto;
    border: solid;
    border-width: 1px 0 0 0;
    width: var(--searchWidth--);
    padding: 5px 1em 5px 1em;
    margin-left: -2px;
}

#bar {
    grid-column: 2;
    border-radius: 1em;
    overflow: hidden;
    border: solid;
    border-width: 3px;
    padding: 0;
    width: var(--searchWidth--);
}

#guessInput {
    padding: 5px 1em 5px 1em;
    width: var(--searchWidth--);
    font-size: xx-large;
    border-width: 1px;
    margin-left: -2px;
    margin-top: -2px;
    margin-bottom: -2px;
    /* border-radius: 1em; */
}

#searchBar:focus {
    outline: none !important;
    border: 1px solid;
}

#clueArea {
    /* Adjust padding/margins to suit your design */
    padding: 10px;
    border: 1px solid #ccc;
    overflow-y: scroll;
}

/* Each clue row is displayed in a horizontal row 
     with text on the left and number on the right. */
.clueRow {
    width: 100%;
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    /* Spacing between rows */
}

/* Optional: style for the text part of the clue */
.clueText {
    text-align: left;
    font-weight: 500;
}

/* Optional: style for the number part of the clue */
.clueNumber {
    text-align: right;
    font-weight: bold;
    margin-left: 10px;
    /* A little gap from the text */
}

/* 
#win {
    position: absolute;
    width: 50vw;
    left: 25vw;
    height: 50vh;
    top: 25vh;
    background-color: lightblue;
    box-shadow: 10px 10px gray;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.hidden {
    display: none !important;
}
*/
@media (orientation: landscape) {
    :root {
        --searchWidth--: 40vw;
    }

    #results {
        padding-left: 3em;
        justify-content: center;
    }

    #gameScreen {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: 1fr;
        grid-template-areas:
            "search results";
    }
}