* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-family: "Roboto Slab", serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    font-variation-settings:
      "wdth" 100;
    background-color: #f5f7fa;
  }

.headerGame {
    display: flex;
    justify-content: space-between;
    width: 70dvw;
}

.hangmanProgress {
    max-width: 200px;
}

.categorySelectedTitle {
    font-family: "Luckiest Guy", cursive;
    text-align: left;
    margin-top: 12px;
    font-size: 3.8rem;
}

main {
    display: flex;
    flex-direction: column;
    justify-content:space-evenly;
    align-items: center;
    height: 90dvh;
}

.Home-Page {
    position: fixed;
    display: flex;
    flex-direction: column;
    border: 0px;
    padding: 24px;
    border-radius: 20px;
    color: #1d2530;
    background-color: #d1dbe6;
    display: block;
}

.Home-Page img {
    max-width: 100px;
    margin-left: -2px;
}

.Home-Page > div > h2 {
    font-family: "Luckiest Guy", cursive;
    font-weight: normal;
}

.Home-Page > p {
    font-size: 1.6rem;
}

.Home-Page > div {
    display: flex;
    align-items: center;
    font-size: 4.5rem;
    font-weight: bold;
    gap: 24px;
    margin-bottom: 12px;
}

.Categories-Buttons {
    margin-top: 8px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}

.Categories-Buttons button {
    background-color: #5a7c9d;
    font-size: 1.2rem;
    padding: 8px;
    border-radius: 8px;
    color: #f5f7fa;
    font-family: "Roboto Slab", serif;
    border: 0px;
    width: 120px;
    height: 120px;
}

.Categories-Buttons button:hover {
    background-color: #3a506a;
    cursor: pointer;
}

.ImageIco {
    width: 50px;
    height: auto;
}

.HiddenWord-Section {
    display: flex;
    gap: 56px;
    flex-wrap: wrap;
    padding: 4px;
    justify-content: center;
    row-gap: 12px;
}

.HiddenLetter {
    width: 100px;
    height: 100px;
    border: 1px solid #1d2530;
    border-radius: 12px;
    align-content: center;
    text-align: center;
    font-size: 5rem;
    font-family: "Luckiest Guy", cursive;
}

.HiddenWord {
    width: auto;
    height: auto;
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    justify-content: center;
}

.ShowedLetter {
    border: none;
    border-radius: 12px;
    align-content: center;
    text-align: center;
    font-size: 4rem;
    font-family: "Luckiest Guy", cursive;
    background-color: #1d2530;
    color: #eaeef4;
}

.Keyboard {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
    background-color:#d1dbe6;
    width: 70dvw;
    margin: 0px 24px;
    padding: 12px;
    border-radius: 12px;
    visibility: hidden;
}

.Keyboard-Buttons {
    font-size: 3.4rem;
    padding: 4px;
    width: 75px;
    height: 75px;
    border: none;
    border-radius: 12px;
    color: #3a506a;
    background-color: #f5f7fa;
    font-family: "Luckiest Guy", cursive;
}

.Keyboard-Buttons:hover {
    color: #f5f7fa;
    background-color: #3a506a;
    border: 1px solid #f5f7fa;
    cursor: pointer;
}

.gameover {
    /* position: fixed;
    left: 0;
    top: 0; */
    width: 100%;
    height: fit-content;
    /* z-index: 9999; */
    /* background-color: rgba(0,0,0,0.7); */
    color: #1d2530;
    letter-spacing: 12px;
    font-family: "Luckiest Guy", cursive;
    font-size: 5rem;
    text-align: center;
    align-content: center;
    row-gap: 12px;
    display: none;
}

.ImageButton, .homeButton {
    width: 25px;
    height: 25px;
    border: none;
    background-color: transparent;
    margin-bottom: 4px;
}

.homeButton {
    visibility: hidden;
}

.homeButton:hover {
    cursor: pointer;
}

.replayButton {
    background-color: #1d2530; 
    border: none;
    color:  #f5f7fa;
    border-radius: 8px;
    width: fit-content;
    height: fit-content;
    font-family: "Roboto Slab", serif;
    font-size: 1.4rem;
    padding: 8px;
    font-weight: bold;
}

.replayButton:hover {
    cursor: pointer;
}

footer {
    position: fixed;
    bottom: 0;
    text-align: center;
    width: 100%;
    font-size: 0.6rem;
    margin-bottom: 8px;
}

/* @keyframes cambioEscala {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

#gameoverText {
    animation: cambioEscala 2s infinite alternate; 
} */

@media (max-width: 640px) {
    .headerGame {
        width: 90dvw;
    }
    .hangmanProgress {
        max-width: 75px;
    }
    .categorySelectedTitle {
        margin-top: 4px;
        font-size: 1.6rem;
    }
    .Home-Page {
        width: 94dvw;
    }
    .Home-Page img {
        max-width: 60px;
    }
    .Home-Page > div {
        font-size: 1.6rem;
        gap: 8px;
    }
    .Home-Page > p {
        font-size: 1.2rem;
    }
    .Categories-Buttons button {
        margin-left: 12px;
        margin-right: 12px;
    }
    main {
        margin: 12px;
        height: 90dvh;
    }
    .HiddenWord-Section {
        column-gap: 22px;
        padding: 0px;
    }
    .HiddenLetter {
        width: 42px;
        height: 42px;
        font-size: 1.8rem;
    }
    .HiddenWord {
        column-gap: 2px;
    }
    .Keyboard {
        width: 90dvw;
        gap: 4px;
    }
    .Keyboard-Buttons {
        font-size: 1.2rem;
        padding: 4px;
        width: 35px;
        height: 35px;
    }
    .gameover {
        font-size: 2.4rem;
        letter-spacing: 4px;
    }
    .replayButton {
        font-size: 1rem;
        padding: 8px;
    }
}