@keyframes rotate {
    from {
        transform: translate(-50%, -50%) rotate(0);
    }
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

html {
    overflow: hidden;
}

body {
    box-sizing: border-box;
    margin: 0;
    padding: 5px;
    width: 100vw;
    height: 100vh;
    background-color: #cdcca6;
}

h3 {
    margin: 0;
}

main {
    display: flex;
    flex-flow: row nowrap;
    width: 100%;
    height: 100%;
    justify-content: center;
}

.music-button {
    position: absolute;
    right: 0;
    bottom: 0;
    padding: 20px;
    opacity: 0.6;
}

.game-container {
    height: 100%;
    width: calc((100vh - 10px)*0.82);
    order: 1;
}

.game-container.loading {
    display: flex;
    flex-flow: column;
    justify-content: center;
    align-items: center;
}

.score-container {
    padding: 0 15px;
    order: 2;
    cursor: default;
}

.current,
.max {
    display: flex;
    flex-flow: row nowrap;
    align-items: baseline;
    justify-content: space-between;
}

.current {
    color: #d75c2b;
    margin: 0 0 15px;
}

.max {
    color: #723428;
}

.value {
    font-size: 1.5em;
    margin: 0 0 0 30px;
}

.loading-text {
    position: relative;
    font-size: 2.5vw;
    box-sizing: border-box;
    color: #2c2c2c;
}

.loading-text::before,
.loading-text::after {
    position: absolute;
    transform: translate(-50%, -50%);
}

.loading-text::before {
    padding: 6vw;
    content: "";
    border: 5px dashed #2c2c2c;
    border-radius: 50%;
    transform-origin: center;
    animation: 6s linear infinite rotate;
}

.loading-text::after {
    padding: 4.7vw 2.5vw;
    content: "Loading";

}

@media screen and (max-aspect-ratio: 6/5) {
    main {
        flex-flow: column nowrap;
        justify-content: flex-start;
        align-items: center;
    }

    .game-container {
        height: calc(100vh - 10px - 94px);
        width: calc((100vh - 10px - 94px)*0.82);
        order: 2;
    }

    .score-container {
        order: 1;
        margin: 0 0 15px;
    }

    .current,
    .max {
        width: 300px;
    }
}


@media screen and (min-width: 1250px) and (orientation: landscape) {
    body {
        padding: 50px;
    }

    .game-container {
        width: calc((100vh - 100px)*0.82);
    }

}

@media screen and (max-aspect-ratio: 4/5) {
    .game-container {
        height: calc((100vw - 10px)/0.82);
        width: 100%;
    }
}

@media screen and (max-width: 600px) {
    .current,
    .max {
        font-size: 1em;
    }
}

@media screen  and (max-width: 350px) {
    .current,
    .max {
        width: 280px;
    }
}
