* {
    box-sizing: border-box;
    background-color: beige;
    border: none;
    padding: 0px;
}
body {
    margin: 0px;
    height: 100vh;
    touch-action: manipulation;
}
.page {
    width: 100vw;
    height: 100dvh;
    padding-top: 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
}

.WordGame {
    font-family: 'Courier New', Courier, monospace;
    margin-bottom: 5px;
}

.GetButtons {
    width: 35%;
    margin: 1% auto;
    display: flex;
    justify-content: space-around;
}
.GetWord {
    color: black;
    padding: 1px 5px;
    border-bottom: 1.5px solid black;
    border-radius: 20px;
    box-shadow: 15px 0px 15px 0px rgb(0 0 0/0.1);
    font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
}

.Loading {
    border-radius: 50%;
    animation: spin linear .5s infinite;
    background-color: transparent;
    height: 25px;
    width: 25px;
    visibility: hidden;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}
.AllLetters {
    width: fit-content;
    flex-wrap: wrap;
    justify-self: center;
    justify-content: space-around;
    margin: 0 auto;
}

.BoardOnly {
    display: flex;
    flex-direction: column;
    visibility: hidden;
}

.Row {
    display: flex;
    float: left;
    background-color: rgba(55, 55, 55, 0);
    visibility: visible;
}

.Box {
    height: 50px;
    width: 50px;
    margin: 2px;
    color: black;
    font-family: 'Gill Sans', 'Gill Sans MT', 'Calibri', 'Trebuchet MS', sans-serif;
    font-size: 40px;
    font-weight: 500;
    text-align: center;
    align-items: center;
    border: 1.5px solid black;
    border-radius: 10%;
    text-transform: uppercase;
    caret-color: transparent;
}


.LastOfRow,
.LastRow {
    margin-right: 0px;
    box-shadow: 15px 0px 15px 0px rgb(0 0 0/0.1);
}

.LastRow * {
    margin-bottom: 0px;
    box-shadow: 0px 15px 15px rgb(0 0 0/0.1);
}

.WordNotValid {
    animation: flash linear 1s 1;
}

@keyframes flash {
    0% {
        border: 2px solid black;
    }

    50% {
        border: 3px solid red;
    }

    100% {
        border: 2px solid black;
    }
}


.GreenCell {
    background-color: darkgreen;
    color: beige;
}

.YellowCell {
    background-color: goldenrod;
    color: beige;
}

.GrayCell {
    background-color: #888;
    color: beige;
}

.Winner * {
    animation: win linear 0.8s 2;
    background-color: darkgreen;
    color: beige;
}

@keyframes win {
    0% {
        background-color: darkgreen;
    }

    50% {
        background-color: rgb(22, 182, 22);
    }

    100% {
        background-color: darkgreen;
    }
}

.GameOver * {
    animation: GameOver linear .5s 1;
}

@keyframes GameOver {
    50% {
        background-color: rgb(182, 22, 22);
    }
}

.GiveUp {
    color: black;
    font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
    display: flex;
    display: none;
    justify-self: center;
    justify-content: center;
    padding: 0%;
    width: 100%;
    margin: 3% 0px;
    margin-bottom: 0px;
    text-transform: uppercase;
}
.GoodJob {
    color: black;
    font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
    display: flex;
    display: none;
    justify-self: center;
    justify-content: center;
    padding: 0%;
    width: 100%;
    margin: 3% 0px;
    margin-bottom: 0px;
    text-transform: uppercase;
}

.KeyTable {
    visibility: hidden;
}
.Show {
    display: flex;
    visibility: visible;
}

@media screen and (max-width: 600px) {

    .page {
        width: 100%;
    }

    .GetButtons {
        width: 47%;
        margin: 2% auto;
    }

    .GetWord {
        border-bottom: 1.3px solid black;
        padding-left: 7px;
    }

    .AllLetters {
        width: fit-content;
        flex-wrap: wrap;
        justify-self: center;
        justify-content: center;
        margin: 0 auto;
    }

    .Box {
        color: black;
        height: 40px;
        width: 40px;
        margin: 1.5px;
        font-size: 30px;
        font-weight: 400;
    }
    .GreenCell {
        background-color: darkgreen;
        color: beige;
    }

    .YellowCell {
        background-color: goldenrod;
        color: beige;
    }

    .GrayCell {
        background-color: #888;
        color: beige;
    }

    .WordNotValid {
        animation: flash linear 1s 1;
    }

    @keyframes flash {
        0% {
            border: 1px solid black;
        }

        50% {
            border: 2px solid red;
        }

        100% {
            border: 1px solid black;
        }
    }

    .KeyTable {
        visibility: visible;
        display: inline;
        justify-content: center;
        justify-items: center;
        width: 100%;
        height: fit-content;
        margin: 0 auto;
        position: absolute;
        bottom: 0;
        left: auto;
    }

    tbody {
        display: flex;
        flex-direction: column;
        justify-content: space-around;
    }
    .OnScreenLetters {
        bottom: 0;
        left: 0;
        display: flex;
        flex-direction: column;
        justify-content: space-around;
        width: 100%;
        height: 100%;
        border-collapse: collapse;
        border-left: 1px solid black;
        border-right: 1px solid black;

    }

    .KeyRow {
        width: 100vw;
        border-spacing: 0px;
        margin: 0px auto;
        border-left: none;
        border-right: none;

    }

    .A-L {
        width: 90%;
        margin: auto;
    } 
    
    .Key {
        width: 80px;
        height: 70px;
        border: 1px solid black;
        padding: 0px;
        font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
        font-size: 30px;
        font-weight: 400;
    } .Key:active {
        background-color: #999999;
    }
    .A-L * {
        border-top: none;
        border-bottom: none;
    }

    #Backspace, #Enter {
        font-weight: 1000;
        padding: 0px;
    }

}

@media screen and (max-width: 360px) {
    .GetButtons {
        width: 85%;
    }
    .Key {
        font-size: 25px;
        height: 60px;
        border: 2.5px solid black;
    }
}