.game_instructions_wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;

    width: min(80vw, 1280px);
    gap: 6px;
}

.game_instructions {
    display: grid;
    grid-template-columns: 1fr 1.15fr 1.7fr 1.6fr;
    align-items: stretch;

    position: relative;
    overflow: hidden;

    width: 100%;
    gap: 18px;
    padding: 18px 22px;

    color: white;
    background:
        linear-gradient(135deg, rgba(109, 255, 238, 0.42), rgba(0, 91, 161, 0.55)),
        url("../../img/3. Background/Layers/5. Water/D1.png");

    background-size: cover;
    background-position: center;
    border: 2px solid rgba(255, 255, 255, 0.48);
    border-radius: 24px;
    box-shadow:
        0 18px 38px rgba(7, 41, 84, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.42),
        inset 0 -24px 42px rgba(0, 34, 86, 0.28);
    backdrop-filter: blur(8px);
}

.game_instructions::before {
    content: "";
    position: absolute;
    inset: 0;

    background:
        radial-gradient(circle at 12% 18%, rgba(255, 255, 255, 0.38), transparent 14rem),
        linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.14) 28%, transparent 48%);

    pointer-events: none;
}

.game_instructions>* {
    position: relative;
    z-index: 1;
}

.game_instructions h2 {
    font-family: "Luckiest Guy", Arial, sans-serif;
    font-size: 26px;
    font-weight: 400;
    letter-spacing: 1px;
    text-transform: uppercase;

    margin-right: 8px;
}

.instruction_row {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    min-height: 78px;
    gap: 7px;
    padding: 10px 12px;

    background:
        linear-gradient(180deg, rgba(7, 62, 95, 0.48), rgba(5, 33, 63, 0.52));
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 18px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.16),
        0 10px 18px rgba(0, 0, 0, 0.16);
}

.instruction_row span {
    font-size: 15px;
    font-weight: 400;
    letter-spacing: 0.7px;
    text-align: center;
    text-shadow:
        0 2px 0 rgba(0, 0, 0, 0.28),
        0 0 10px rgba(75, 255, 241, 0.45);

    color: #ffffff;
}

.keys_image {
    width: 64px;
}

.d_key_image {
    width: 36px;
}

.space_key_image {
    width: 164px;
}

.arrow_keys {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.arrow_keys div {
    display: flex;
    gap: 4px;
}

.image_button {
    padding: 0;

    background: transparent;
    border: none;
    outline: none;

    cursor: pointer;
    transition:
        transform 100ms ease,
        filter 100ms ease;
}

.image_button:hover {
    filter:
        brightness(1.08) drop-shadow(0 0 10px rgba(117, 255, 239, 0.45));
}

.image_button:active {
    transform: scale(0.92) translateY(3px);
    filter: brightness(0.85);
}

.image_button img {
    width: 120px;
}

@media (min-width: 901px) {

    .game_instructions_wrapper {
        width: min(80vw, 1280px, calc((100vh - 250px) * 16 / 9 + 120px));
        flex: 0 0 auto;
    }
}

@media (min-width: 901px) and (min-height: 571px) and (max-height: 800px) {

    .game_instructions_wrapper {
        width: min(64vw, 1050px, calc((100vh - 260px) * 16 / 9));
        gap: 2px;
    }

    .game_instructions_wrapper h2 {
        font-size: 18px;
        line-height: 1;
        margin: 0;
    }

    .game_instructions {
        gap: 6px;
        padding: 6px 10px;
        border-radius: 14px;
    }

    .instruction_row {
        min-height: 42px;
        gap: 2px;
        padding: 4px 6px;
        border-radius: 12px;
    }

    .instruction_row span {
        font-size: 10px;
        line-height: 1;
    }

    .keys_image {
        width: 38px;
    }

    .d_key_image {
        width: 24px;
    }

    .space_key_image {
        width: 100px;
    }

    .image_button img {
        width: 72px;
    }
}