@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');

body {


    font-weight: normal;
    font-style: normal;
}
* {
    box-sizing: border-box;
}

:root {
    --color-bg: #555555;
    --color-fg: #f1f2f6;
    --color-theme: #0e3768;
    --color-light: #b0d8e3;
    --color-hl: #efe897;

    --color-green: #80EF80;
    --color-red: #ff746c;

    font-family: "Inter", Arial, sans-serif;
    font-optical-sizing: auto;
    font-size: large;
}

a {
    color: var(--color-light);
}

button {
    border: none;
    outline: none;
    padding: 1rem;
    color: var(--color-fg);
    font-size: large;
    background-color: var(--color-theme);
    cursor: pointer;
}

details { border-left: 0.25rem solid var(--color-light); }
summary {
    font-size: larger;
    padding: 1rem;
    background-color: var(--color-light);
    font-weight: bold;
    cursor: pointer;;
}

hr { margin-top: 0; }

p { margin: 1rem; }

table {
    width: 100%;
    border-collapse: collapse;
    font-size: large;
    text-align: left;
}
td, th {
    border: 1px solid var(--color-fg);
    padding: 0.5rem;
}

body {
    margin: 0;
    background-color: var(--color-bg);
    color: var(--color-fg);
}

/* Menu display ------------------------------------------------------------- */
#menu div {
    display: flex;
    flex-wrap: wrap;
}

#menu details {
    flex: 1 1 40%;
    min-width: 15rem;
}
#menu summary { color: var(--color-bg); }

details button {
    width: 100%;
    text-align: left;
}

#setting {
    border-color: var(--color-red);
    background-color: var(--color-fg);
    color: var(--color-bg);
}
#setting summary { background-color: var(--color-red); }
#setting > *:not(summary) { padding: 0.5rem; }
#setting button {
    display: inline;
    text-align: center;
    width: max-content;
}
#setting * { margin: 0; }

label {
    width: 100%;
    display: flex;
    justify-content: space-around;
    align-items: center;
    gap: 0.5rem;
}
label > * { flex: 2 1 0; }
label input {
    flex: 3 1 0;
    appearance: none;
    width: 100%;
    height: 0.25rem;
    cursor: pointer;
    background: var(--color-bg);
    outline: none;
}
label span { max-width: 3rem; }

footer {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0.5rem;
}
footer a {
    width: 7rem;
}

/* Game display ------------------------------------------------------------- */
#game blockquote { display: none; }
#game.hint blockquote {
    display: block;
    margin: 0 0.5rem;
    padding-left: 0.5rem;
    border-left: 0.25rem solid var(--color-light);
}
#game > button { width: 100%; }
#game .r {
    background-color: var(--color-green);
    color: var(--color-bg);
}
#game .w { background-color: var(--color-red); }

#question {
    text-align: center;
    font-size: x-large;
    padding: 1rem;
    background-color: var(--color-theme);
    overflow-x: auto;
}
#question details {
    border: none;
    text-align: left;
}
#question summary { background-color: transparent; }
#question p,
#question ul,
#question ol {
    font-size: large;
    text-align: justify;
}
#question img {
    display: block;
    margin-left: auto;
    margin-right: auto;
    margin-top: 1rem;
    max-height: 50vh;
    max-width: 100%;
}

#answers {
    list-style-type: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    column-gap: 3rem;
    row-gap: 1rem;
    margin-bottom: 5rem; /* Controls height */
    padding: 0 2rem 2rem;
}

#answers[type="0"] li {
    flex: 1 0 40%;
    min-width: min(100%, 20rem);
    border: 0.5rem solid var(--color-light);
    border-radius: 0.5rem;
    padding: 1rem;
    cursor: pointer;
}
#answers[type="0"] li:hover {
    border-color: var(--color-hl);
}

#answers[type="1"] li {
    flex: 1 1 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
#answers[type="1"] button { border-radius: 0.5rem; }

#answers[type="2"] li {
    flex: 1 0 40%;
    min-width: min(100%, 15rem);
    height: 100%;
    border: 0.5rem solid var(--color-hl);
    border-radius: 0.5rem;
    padding: 1rem;
    cursor: pointer;
    text-align: center;
}
#answers[type="2"] li:hover {
    background-color: var(--color-hl);
    color: var(--color-bg);
}

/*
    Type 3: short answer
    Type 4: written response
*/
#answers input, #answers textarea {
    border: none;
    outline: none;
    font-size: large;
    min-height: 3rem;
    background-color: var(--color-theme);
    color: var(--color-fg);
}
#answers input:placeholder-shown {
    background-color: var(--color-red);
}

#answers textarea {
    width: 100%;
    resize: vertical;
}

#controls {
    position: fixed; bottom: 0; left: 0; right: 0;
    z-index: 10;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 5rem;
    background-color: var(--color-bg);
}

#progress {
    flex: 1 1 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}
#progress p {
    margin: 0;
}
#controls.r { background-color: var(--color-green); }
#controls.w { background-color: var(--color-red); }

#controls button {
    align-self: stretch;
}