@import url('https://fonts.googleapis.com/css2?family=Koulen&display=swap');

/* ================
   Base Styles
=================== */
body {
    background-color: #FFE1BE;
    font-size: 3vh;
    font-family: 'Koulen', Impact, 'Arial Black', sans-serif;
    font-weight: 400;
    margin-left: 15%;
    margin-right: 15%;
}

button {
    border-radius: 10px;
    padding: 0.5rem;
    margin: 3px;
    background-color: #E9CDAB;
    cursor: pointer;
}

button:hover {
    background-color: #312d21;
    border-color: white;
    color: white;
    transform: scale(1.05);
    transition: all 0.2s ease-in-out;
}

.disabled {
    color: red;
    background-color: white;
    pointer-events: none;
}

.hidden {
    display: none;
}

/* ================
   Main Container
=================== */
#main-container {
    display: flex;
    justify-content: center;
    align-items: center;
}

/* ================
   Left Panel
=================== */
#left-container {
    margin: 5px;
    display: block;
    width: calc(50% - 10px);
    height: 70vh;
    padding: 20px;
    margin-top: 0;
}

#left-container #top-bar {
    display: flex;
    overflow: none;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    height: 10vh;
    margin-top: none;
}

#left-container #top-bar h1 {
    letter-spacing: 5px;
    margin: 10px;
    font-size: 50px;
    font-weight: 200;
}

#play-button {
    border-width: 4px;
    padding-left: 20px;
    padding-right: 20px;
    font-size: 15px;
    margin: 10px;
    border-radius: 20px;
}

#play-button.disabled {
    color: #bda78d;
    background-color: #E9CDAB;
}

/* ================
   Tile Area
=================== */
#left-container #left-center {
    height: 70vh;
    display: block;
    margin: 10px;
    position: relative;
}

.tile {
    position: absolute;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 9vh;
    width: 9vh;
    border-radius: 13px;
    aspect-ratio: 1;
    background-color: #C59763;
    margin: 10px;
    font-size: 6vh;
}

/* Tile Positions */
#tile-0 {
    top: 15px;
    transform: rotate(-20deg);
}

#tile-1 {
    top: 30px;
    right: 50px;
    transform: rotate(30deg);
}

#tile-2 {
    left: 110px;
    top: 110px;
    transform: rotate(-15deg);
}

#tile-3 {
    left: 10px;
    top: 190px;
    transform: rotate(30deg);
}

#tile-4 {
    right: 40px;
    top: 180px;
    transform: rotate(20deg);
}

#tile-5 {
    top: 330px;
    left: 30px;
    transform: rotate(-15deg);
}

#tile-6 {
    top: 300px;
    right: 60px;
    transform: rotate(35deg);
}

/* ================
   Right Panel
=================== */
#right-container {
    background-color: #E9CDAB;
    margin: 5px;
    margin-top: 25px;
    border: 5px solid black;
    width: calc(50% - 10px);
    height: 70vh;
    top: 0;
    left: 0;
    padding: 30px;
    font-size: 3.5vh;
    overflow: scroll;
    resize: none;
    flex-shrink: 0;
}

#right-container input {
    display: inline-block;
    margin-left: 10px;
    margin-right: 10px;
    border-radius: 40px;
    appearance: none;
}

#slider {
    width: 50%;
    background: linear-gradient(to right, red 0%, red 50%, white 50%, white 100%);
}

#distribution-toggle {
    font-size: 3vh;
}

#scrabble-uniform {
    width: 30px;
    margin-left: 5px;
    margin-right: 5px;
}

#timer {
    display: inline-block;
    align-items: center;
    justify-content: center;
    font-size: 5vh;
    width: 5ch;
    font-family: 'Koulen', monospace;
}

#played-words {
    display: inline-block;
    height: 30vh;
}

#played-words div {
    display: inline-block;
    font-size: 23px;
    margin-left: 10px;
    margin-right: 10px;
    color: rgb(94, 94, 94);
}

#played-words .correct {
    color: green;
}

#played-words .incorrect {
    color: red;
}

#played-words .submitted {
    color: black;
}

#score_box {
    display: inline-block;
    margin: 5px;
}

#accuracy_box {
    display: inline-block;
    margin: 5px;
}

#skill_box {
    display: inline-block;
    margin: 5px;
}

/* ================
   Lower Bar
=================== */
#lower-bar {
    height: 10vh;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 30px;
}

#lower-bar button {
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 2px;
    padding: 10px;
    padding-left: 20px;
    padding-right: 20px;
    margin: 10px;
    border-radius: 20px;
    text-transform: uppercase;
    border-width: 5px;
}

/* ================
   Popups
=================== */
#how-to-popup {
    position: absolute;
    left: 0;
    top: 0;
    background-color: white;
    margin: 30px;
    padding: 20px;
    border-radius: 20px;
    font-size: 18px;
    text-align: center;
    font-weight: thin;
    width: calc(100% - 80px);
    margin-bottom: 40px;
    /* transform: translateX(50%); */
}

#demo-video {
    margin: auto;
    margin-top: 10px;
}

#close-popup-button {
    font-size: 30px;
    margin: auto;
    margin-top: 45px;
}

#hint-popup {
    position: fixed;
    top: 45%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 30px;
    border-radius: 20px;
    font-size: 20px;
    text-align: center;
    font-weight: 200;
    width: 20%;
    max-width: 90%;
    z-index: 1000;
}

/* ================
   Media Queries
=================== */
@media (max-width: 780px) {
    #left-container #top-bar {
        display: block;
    }

    #left-container #top-bar h1 {
        font-size: 35px;
        font-weight: 200;
    }

    #play-button {
        display: block;
        border-width: 3px;
        padding-left: 20px;
        padding-right: 20px;
        border-radius: 15px;
        margin: 3px;
        margin-left: 1rem;
    }

    #lower-bar button {
        font-size: 15px;
        letter-spacing: 1px;
        margin: 5px;
        border-width: 3px;
        padding-left: 15px;
        padding-right: 15px;
    }

    #refresh {
        padding-top: 20px;
        padding-bottom: 20px;
    }

    /* Tile Positions on Small Screens */
    #tile-0 {
        top: 80px;
        left: 0px;
    }

    #tile-1 {
        top: 20px;
        left: 90px;
    }

    #tile-2 {
        left: 100px;
        top: 110px;
        transform: rotate(20deg);
    }

    #tile-3 {
        left: 0px;
        top: 180px;
        transform: rotate(-30deg);
    }

    #tile-4 {
        left: 90px;
        top: 230px;
        transform: rotate(15deg);
    }

    #tile-5 {
        top: 330px;
        left: 90px;
        transform: rotate(-15deg);
    }

    #tile-6 {
        top: 300px;
        right: 60px;
        transform: rotate(35deg);
    }

    /* Hint popup on small screens */
    #hint-popup {
        width: 35%;
    }
}

@media (max-width: 570px) {
    #left-container #top-bar {
        display: block;
    }

    #lower-bar button {
        font-size: 2vw;
        letter-spacing: 1px;
        margin: 5px;
        border-width: 3px;
    }

    #hint-popup {
        width: 40%;
    }
}