@font-face {
    font-family: 'zabars';
    src: url('./fonts/zabars.regular.ttf') format('truetype');
}

@font-face {
    font-family: 'inter';
    src: url('./fonts/inter.ttf') format('truetype');
}

body {
    font-family: 'inter', Arial, Helvetica, sans-serif;
    background: url('./imgs/website-background-img.jpg') no-repeat center center fixed;
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
    background-size: cover;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    min-height: 100vh;
    font-size: 2rem;
    font-weight: 500;
}

header {
    display: inline;
}

h1 {
    text-align: center;
    font-family: 'zabars';
    margin: 2rem 0 0 0;
    font-size: 6rem;
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

section {
    font-size: 20px;
    background: radial-gradient(circle, #EFA260 50%, rgba(239, 162, 96, 0.5) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    border-radius: 20px;
    margin: 2rem;
    padding: 1rem;
}

section a {
    color: black;
}

.canvas-position {
    display: flex;
    position: relative;
}

.icons img {
    width: 35px;
    aspect-ratio: 1/1;
    padding: 5px 5px;
    border-radius: 5px;
}

img:hover {
    cursor: pointer;
}

.img-wrapper {
    padding-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.phone-portrait {
    width: 100px;
}

.arrow-right {
    width: 50px;
}

.phone-landscape {
    width: 200px;
}

.instructions {
    color: white;
    display: none;
    position: absolute;
    top: 48px;
    right: 5%;
    background-color: #007cf8;
    z-index: 2;
    padding: 0.5rem 1rem;
    border-radius: 10px;
}

.instructions img {
    display: none;
    width: 40px;
}

.desktop-instructions {
    display: inline;
}

p {
    display: flex;
    margin: 0.5rem 0px;
    text-align: center;
    width: fit-content;
    gap: 10px;
}

.menu-btns {
    color: white;
    font-family: 'zabars';
    font-size: 2.5rem;
    background-color: #007cf8;
    border-radius: 10px;
    padding: 5px 10px;
    border: none;
}

.menu-btns:hover {
    background-color: #2492FF;
    cursor: pointer;
}

.select-difficulty {
    display: flex;
    flex-direction: row;
    position: absolute;
    gap: 20px;
    top: 12%;
    left: calc(50% - 220px);
}

.game-over-menu {
    display: none;
    flex-direction: row;
    position: absolute;
    gap: 20px;
    top: 20%;
    left: calc(50% - 130px);

}

.icons {
    display: flex;
    flex-direction: row;
    position: absolute;
    top: 2%;
    right: 2%;
}

.hidden {
    display: none;
}

canvas {
    background-color: black;
    display: block;
}

.link-wrapper {

    font-size: 20px;
    margin: 2rem 0;
    display: flex;
    flex-direction: row;
    gap: 2rem;
}

.link-wrapper a {
    color: white;
}

ul {
    display: flex;
    flex-wrap: wrap;
    flex-direction: column;
    gap: 0.5rem;
}

li {
    word-wrap: break-word;
    word-break: break-all;
    overflow-wrap: break-word;
}

li a {
    word-break: break-all;
    overflow-wrap: break-word;
}

.mobile-play-btns {
    width: 100%;
    position: absolute;
    bottom: 0;
    left: 0;
    display: none;
    flex-direction: row;
    justify-content: space-between;
    touch-action: none;
}

.mobile-play-btns img {
    width: 55px;
}

.mobile-play-btns div {
    display: flex;
    gap: 2rem;
    padding: 0 0.5rem;
}

.game-introduction {
    display: flex;
}


.turn-phone {
    display: none;
}

.personal-best-times {
    display: none;
    flex-direction: column;
    position: absolute;
    max-height: 300px;
    min-width: 280px;
    overflow-y: auto;
    font-size: 20px;
    scrollbar-width: thin;
}

h3 {
    margin: 0;
    text-decoration: underline;
    font-size: 25px;
}

.content-wrapper {
    max-width: 1920px;
}

@media (max-width: 1366px) and (pointer: coarse) and (orientation: landscape) {
    .mobile-play-btns {
        display: flex;
    }

    .desktop-instructions {
        display: none;
    }

    .instructions img {
        display: inline;
        width: 40px;
    }

    .game-introduction {
        display: none;
    }

    .canvas-position {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
    }

    footer {
        display: none;
    }
}

@media only screen and (orientation: portrait) and (max-width: 1024px) {
    section {
        font-size: 16px;
    }

    h1 {
        font-size: 5rem;
    }

    .canvas-position {
        display: none;
    }

    .turn-phone {
        display: flex;
    }
}


@media only screen and (max-height: 400px) and (orientation: landscape) {
    canvas {
        height: 100vh;
    }
}

@media (orientation: landscape) and (max-width: 1024px) {
    header {
        display: none;
    }

    .game-introduction {
        display: none;
    }

    .mobile-play-btns {
        display: flex;
    }

    .desktop-instructions {
        display: none;
    }

    .instructions img {
        display: inline;
        width: 40px;
    }

    #fullscreen {
        display: none;
    }
}

@media (orientation: landscape) {
    .turn-phone {
        display: none;
    }
}

@media only screen and (max-width: 500px) {
    .phone-portrait {
        width: 70px;
    }

    .arrow-right {
        width: 30px;
    }

    .phone-landscape {
        width: 140px;
    }

    section {
        margin: 0rem;
    }

}