@font-face {
    font-family: "Duera Bold";
    src: url('./fonts/Duera-ExpaBold-PERSONAL.ttf')
}

@font-face {
    font-family: "Duera";
    src: url('./fonts/Duera-ExpaMedi-PERSONAL.ttf')
}

*{
    margin: 0;
    padding: 0;
}

.body {
    box-sizing: border-box;
    overflow: hidden;
}

.container-all {
    background-image: url(./img/background.png);
    height: 100vh;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.container-elements {
    width: 1120px;
    display: flex;
    justify-content: space-between;
}

.hide {
    display: none;
}

/* GAME BOARD */

#game-board {
    display:grid;
    position: relative;
    grid-template-columns: repeat(10, 1fr);
    grid-template-rows: repeat(10, 1fr);
    width: 600px;
    height: 600px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.26);
    border-radius: 6px;
    background-image: url(./img/Game02background.svg);
    background-size: cover;
}

.cat {
    background-image: url(./img//Cat_Catch.svg);
    background-size: cover;
} 

.fish {
    background-image: url(./img/Fish_alive.svg);
    background-size: cover;
    transform: rotate(90deg);
}

.raindrop {
    background-image: url(./img/raindrop.svg);
    background-size: cover;
}

/* LEFT SIDE  */

.left-elements {
    min-width: 210px;
    position: relative;
    top: 10%;
    align-self: flex-start;
    width: 10%;
}

.left-elements a {
    display: inline-block;
    background-color: white;
    width: 60px;
    height: 60px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.12);
    border-radius: 12px;
}

.arrow-container {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.left-elements p {
    position: relative;
    top: 50px;
    writing-mode:vertical-rl;
    font-family: 'Duera Bold';
    font-size: 44px;
    line-height: 100%;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

/* RIGHT SIDE  */
.right-elements {
    min-width: 210px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.right-elements p:nth-child(2), .right-elements p:nth-child(4){
    text-align: end;
    font-family: 'Duera Bold';
    font-size: 56px;
    line-height: 90%;
    margin-bottom: 8px;
}

.right-elements p:nth-child(3), .right-elements p:nth-child(5){
    margin-bottom: 40px;
    text-align: end;
    font-family: 'Duera';
    font-size: 26px;
    line-height: 100%;
    text-transform: uppercase;
    color: rgba(0, 0, 0, 0.7);
}

/* AUDIO STYLE  */

.audio {
    margin-bottom: 40px;
}

#play, #pause {
    background-color: transparent;
    border: none;
    outline: none;
    cursor: pointer;
    opacity: 0.5;
}

#play:hover, #pause:hover {
    opacity: 1;
}

/* WIN-LOST STYLE  */

.lose-container {
    display: flex;
    flex-direction: column;
    justify-content:center;
    align-items: center;
    width: 100%;
    height: 100%;
    position: absolute;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
    border-radius: 6px;
    z-index: 1;
}

.lose-container p {
    margin-bottom: 64px;
    font-family: 'Duera Bold';
    font-size: 64px;
    line-height: 90%;
    text-align: center;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: white;
}

.link-style {
    display: block;
    padding: 32px 40px 24px;
    text-decoration: none;
    text-transform: uppercase;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.12);
    border-radius: 12px;
    line-height: 84%;
    letter-spacing: 0.02em;
    font-family: 'Duera Bold';
}

#lose-restart, #win-home, #start {
    margin-bottom: 32px;
    background-color: white;
    font-size: 28px;
    color: #1F180F;
}

#lose-home, #win-restart {
    background-color: #909090;
    font-size: 20px;
    color: white;
}

#lose-restart, #win-restart {
    border: none;
    cursor: pointer; 
}

#lose-restart:focus, #win-restart:focus {
    outline: none;
}

/* INTRO STYLE  */

.intro-game {
    position: absolute;
    display: flex;
    flex-direction: column;
    justify-content:center;
    align-items: center;
    width: 100%;
    height: 100%;
    z-index: 1;
    background-color: rgb(255, 255, 255, 0.5);
}

.intro-game p:nth-child(1) {
    margin-bottom: 55px;
    font-family: 'Duera Bold';
    font-size: 35px;
    line-height: 90%;
    text-align: center;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: rgba(0, 0, 0, 1);

}

.intro-game p:nth-child(3) {
    margin-top: 24px;
    margin-bottom: 80px;
    font-family: 'Duera Bold';
    font-size: 20px;
    line-height: 100%;
    text-align: center;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color : rgba(75, 75, 75, 1.0);
}

.intro-game .link-style {
    background-color: white;
    color: #1F180F;
    border: none;
    cursor: pointer; 
}

.intro-game .link-style:active {
    box-shadow: 0px 0px 0px rgba(0, 0, 0, 0.12);
    outline: 0;
}

#start {
    margin-bottom: 0;
}

/* FOR DIFFERENT ITEMS, USED IN JS */
.hide {
    display: none;
}

@keyframes appear {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

#pad-touch-container {
    display: none;
}

@media only screen and (max-width: 1010px) {
    .container-elements {
        width: 100%;
        justify-content: center;
    }

    #game-board {
        width: 400px;
        height: 400px;
    }

    /* INTRO  */
    .intro-game p:nth-child(1) {
        margin-bottom: 5%;
        font-size: 25px;
        line-height: 90%;
    
    }
    
    .intro-game p:nth-child(3) {
        display: none;
    }

    .link-style {
        padding: 20px 18px 12px;
        text-decoration: none;
    }

    .intro-game img {
        display: none;
    }

    /* PAD THING  */

    #pad-touch-container {
        position: absolute;
        bottom: 10px;
        display: flex;
        align-items: center;
    }

    #pad-touch-container img {
        width: 40px;
    }

    #left {
        transform: rotate(-90deg);
    }

    #right {
        transform: rotate(90deg);
        margin-left: 10px;
    }

    /* LEFT  */

    .left-elements p {
        display: none;
    }

    .left-elements {
        position: absolute;
        width: 0;
        top: 10px;
        left: 10px;
    }

    /* RIGHT  */

    .right-elements {
        position: absolute;
        width: 0;
        top: 10px;
        right: 10px;
    }

    .right-elements p:nth-child(2), .right-elements p:nth-child(4) {
        font-size: 22px;
        margin-bottom: 0;
    }
    
    .right-elements p:nth-child(3), .right-elements p:nth-child(5) {
        font-size: 10px;
        margin-bottom: 0;
    }

    .audio {
        margin-bottom: 2%;
    }

    /* WIN-LOST */

    .lose-container p {
        margin-bottom: 5%;
        font-size: 40px;
    }
}

@media only screen and (max-width: 550px) {
    #game-board {
        width: 310px;
        height: 310px;
    }

    #pad-touch-container img {
        width: 60px;
    }
}
