@font-face {
    font-family: font;
    src: url(../../resources/fonts/darkforest.woff2);
}

body {
    background-color: black;
    display: grid;
    grid-template-rows: 1fr 6fr 0.4fr;
    justify-content: center;
    grid-gap: 10px;

    --max-content-height: calc(6 * (100vh - 2 * var(--margin)) / 7.4);
    --max-content-width: calc(100vw - 2 * var(--margin));
    --content-size: min(var(--max-content-height), var(--max-content-width));
    
    --margin: 20px;
    margin: var(--margin);
    width: calc(100vw - 2 * var(--margin));
    height: calc(100vh - 2 * var(--margin));
}

.title {
    font-family: font;
    font-size: min(10vh, 10vw);
    color: red;
    display: flex;
    align-items: center;
    justify-content: center;

    text-decoration: underline;
}

.title > .hand {
    width: calc(var(--content-size) / 10);
    height: calc(var(--content-size) / 10);
    padding-left: calc(var(--content-size) / 16);
}

.game-container {
    width: var(--content-size);
    height: var(--content-size);
    overflow: hidden;
    
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    grid-gap: 80px;
}

.hand {
    max-width: 100%;
    max-height: 100%;
    width: 100%;
    height: 100%;

    transition: transform 0.6s ease-in-out;
}

.hand.selected {
    transform: translateY(calc(-0.06 * var(--content-size)));
}

.hand > img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    
    filter:
        invert(100%)
        invert(17%)
        sepia(95%)
        saturate(7461%)
        hue-rotate(360deg)
        brightness(101%)
        contrast(105%);

    /* user-drag: none; */
    -webkit-user-drag: none;
    user-select: none;
    -moz-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
}

.hand > img.dead {
    filter:
        invert(100%)
        invert(17%)
        sepia(95%)
        saturate(7461%)
        hue-rotate(360deg)
        brightness(31%)
        contrast(105%);
}

.xflip {
    transform: scaleX(-1);
}

.yflip {
    transform: scaleY(-1);
}

.xflip.yflip {
    transform: scaleX(-1) scaleY(-1);
}


/* ############################################################ */
/* # sliders ################################################## */

/* https://www.w3schools.com/howto/howto_js_rangeslider.asp */

/* The slider itself */
.slider {
    -webkit-appearance: none;  /* Override default CSS styles */
    appearance: none;
    width: 100%;
    height: 100%; /* Specified height */
    background: black;
    /* outline: 1px solid red; */
    /* opacity: 0.7; */
    /*-webkit-transition: .2s; */
    /* transition: opacity .2s; */
    border-radius: 25px;

    border: 2px solid red;
    outline: none;
}

/* The slider handle (use -webkit- (Chrome, Opera, Safari, Edge) and -moz- (Firefox) to override default look) */
.slider::-webkit-slider-thumb {
    -webkit-appearance: none; /* Override default look */
    appearance: none;
    width: 25px; /* Set a specific slider handle width */
    height: 25px; /* Slider handle height */
    background: red; /* Green background */
    cursor: pointer; /* Cursor on hover */
    border-radius: 50%;
}

.slider::-moz-range-thumb {
    width: 25px; /* Set a specific slider handle width */
    height: 25px; /* Slider handle height */
    background: red; /* Green background */
    cursor: pointer; /* Cursor on hover */
    border: 1px solid red
}


/* ############################################################ */
/* # modals ################################################### */

.modal {
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    padding: 10%;
    overflow: hidden;

    -moz-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;

    position: absolute;
    top: 0;
    left: 0;

    background-color: rgba(0, 0, 0, 0.8);
    color: red;
    font-family: font;

    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;

    font-size: min(80vh, 32vw);
    display: none;

    opacity: 0;
    transition: opacity 2s;
}

#gg-bottom {
    font-size: min(20vh, 8vw);
}