/********** Google fonts import link **********/
@import url('https://fonts.googleapis.com/css2?family=Andika&family=Permanent+Marker&display=swap');

/********** Remove default styles **********/
* {
    margin: 0;
    padding: 0;
    border: none;
}

/********** Base styles **********/
* {
    font-family: Andika, sans-serif;
    text-align: center;
    list-style: none;
}

body {
    background-image: url(../images/foodbackground.webp);
    background-repeat: repeat-y;
    background-size: cover;
    margin: 0;
}

h1 {
    font-family: "Permanent Marker", sans-serif;
    font-weight: lighter;
    font-size: 30px;
    margin: 5px 10px;
    padding-top: 10px
}

h2 {
    font-weight: lighter;
    font-size: 18px;
    padding-bottom: 5px;
}

p {
    font-size: 15px;
}

.container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 10px; 
}

.container * {
    margin: 10px;
}

.border {
    background-color: white;
}

.border {
    max-width: 480px;
    border: 1px solid #252525;
    border-radius: 35px;
    padding: 0 5px 10px 5px;
    margin: 0 5px 10px 5px;
    position: relative;
}

/* Shadow on main container across all pages, code adapted from https://neumorphism.io/#ffffff */
.shadow {
    border-radius: 35px;
    background: linear-gradient(225deg, #ffffff, #EFEFEF);
    box-shadow:  -5px 8px 28px #666666, 5px 2px 28px #ffffff;
}

/* Code for uniform <button> and <a> elements adapted from https://css-tricks.com/overriding-default-button-styles/ */
.buttons button, a {
    display: inline-block;
    width: 150px;
    border-radius: 20px;
    padding: 10px;
    margin: 10px;
    text-decoration: none;
    background: #FFAD3A;
    color: #252525;
    font-size: 15px;
    cursor: pointer;
    text-align: center;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.buttons button:hover, a {
    background: #FFEBCE;
}

/********** Nav bar & logo **********/
.nav-bar {
    flex-direction: row;
    justify-content: center;
    margin: 0 10px;
}

.image-container {
    margin: 0;
    padding: 0;
    height: 80px;
    width: auto;
    background: none;
}

.chef-hat {
    height: 80px;
    width: auto;
    margin-bottom: 0;
}

.link {
    width: 85px;
    background-color: #FFEBCE;
    border-radius: 10px;
    padding: 8px;
    font-size: 12px;
    margin: 10px 2px 0 2px; 
    font-weight: 600;
}

.link:hover {
    background-color: #FFAD3A;
    cursor: pointer;
}

#homepage {
    background-color: #FFAD3A;
}

#rulespage {
    background-color: #FFAD3A;
}

#gamepage {
    background-color: #FFAD3A;
}

/* Homepage styles */
.confused-chef {
    height: 280px;
    width: auto;
    border-radius: 35px;
}

.start-container {
    border-radius: 20px;
}

.go-button {
    min-width: 200px;
    font-size: 18px;
    margin: 0;
    padding: 8px 8px;
    font-weight: 550;
    background: #FFAD3A;
}

/********** Rules page styles **********/
.chef-image {
    height: 140px;
    width: auto;
    margin-bottom: 0;
    padding: 0;
}

li {
    max-width: 480px;
    font-size: 15px;
    text-align: left;
}

#rules {
    margin-bottom: 15px;
}

i {
    font-size: 25px;
    padding: 10px 5px 5px 5px;
}

/********** Game page styles **********/
#game-board {
    border-radius: 35px;
    height: auto;
    width: 460px;
}

.flex-container {
    display: flex;
    margin: 0 auto;
}

#display-level, #display-score, #display-attempts {
    margin: 0 auto;
}

#display-level p, #display-score p, #display-attempts p {
    background-color: #FFC87C;
    border-radius: 10px;
    padding: 2px 2px 2px 8px;
}

#display-score p {
    font-weight: bold;
}

#display-attempts p {
    padding-right: 0;
}

#icon-container {
    margin: 0;
}

#food-icon, #drink-icon, #methods-icon, #ten-letters {
    display: none;
    padding: 0;
    margin: 0 auto;
    font-size: 15px;
}

#food-icon i, #drink-icon i, #methods-icon i {
    font-size: 20px;
}

#the-word {
    text-transform: uppercase;
    letter-spacing: 20px;
    margin: 20px 10px;
    font-size: 25px;
}

#user-answer {
    min-width: 300px;
    height: 50px;
    text-transform: uppercase;
    border: 1px solid #8e8e8e;
    letter-spacing: 2px;
}

#display-clue {
    display: none;
}

/********** Clue toggle switch  **********/
/* Code adapted from Coding Power tutorial: https://www.youtube.com/watch?v=R6ODcr-MwKE */
.switch-clue * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.switch-clue {
    position: relative;
    margin-bottom: 25px;
}

.switch-text {
    position: absolute;
    top: -25px;
    left: 15px;
    width: 100px;
    font-size: 12px;
    text-transform: uppercase;
}

.switch-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Toggle slider that contains the circle switch */
.switch-container .switch-toggle {
    position: absolute;
    top: 0;
    left: 110px;
    width: 40px;
    height: 20px;
    background-color: black;
    border-radius: 30px;
    transition: 0.3s;
}

/* Inner circle switch */
.switch-container .switch-toggle #switch-circle {
    position: absolute;
    top: 2.25px;
    left: 2.25px;
    width: 15px;
    height: 15px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    transition: 0.3s;
}

.switch-container .switch-toggle.active {
    background: #BEE2A6;
}

.switch-container .switch-toggle.active #switch-circle {
    left: 21px;
}

#display-clue {
    font-size: 15px;
    padding: 0;
    margin: 0 auto;
}

#check-answer {
    font-weight: 600;
}

#back-home {
    height: 21px;
    width: 130px;
    background: #FFAD3A;
}

/********** Modal styles **********/
.modal-container {
    display: none;
    position: fixed;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-container div {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: #90CE67;
    margin: 0 auto;
    padding: 15px;
    border-radius: 10px;
    position: fixed;
    top: 30%;
    left: 50%;
    transform: translate(-50%, 0);
    min-width: 225px;
    height: 135px;
}

.modal-button {
    color: #252525;
    font-size: 15px;
    border-radius: 5px;
    margin: 10px 0;
    padding: 0 5px;
    background-color:#BEE2A6;
}

.modal-button:hover, .modal-button:focus {
    color: #252525;
    text-decoration: none;
    cursor: pointer;
}

/********** Smaller screen styles **********/
@media only screen and (max-width: 480px) {
    .nav-bar {
        margin-top: 5px;
        flex-direction: column;
    }

    .chef-hat {
        margin: 0;
    }

    .link {
        margin: 0 20px 10px 10px;
    }
    
    /* homepage */
    .confused-chef {
        height: 200px;
    }

    .go-button {
        font-size: 15px;
        padding: 8px 8px;
    }

    /* rules page */
    .chef-image {
        height: 120px;
    }

    li {
        max-width: 450px;
    }

    /* game page */
    #game-board {
        width: auto;
        min-width: 260px;
    }
    
    #the-word {
        letter-spacing: 5px;
    }

    #user-answer {
        min-width: 100px;
    }

    .switch-text {
        left: -45px;
    }

    .switch-container .switch-toggle {
        left: 50px;
    }

    .start-container {
        margin-top: 10px;
    }

    #end-buttons * {
        margin: 0 30px 30px 30px;
    }

    /* modals */
    .modal-container div {
        width: auto;
        height: auto;
    }
}

    




