#game_window {
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
    min-width: 370px;
    margin: 0;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-60%, -55%);
    /*background-color: rgb(184, 184, 184);*/
    width: fit-content;
    z-index: 1;
    padding: 4px;
    box-shadow: inset 4px 4px 0 0 #b1b1b1, inset -4px -4px 0 0 #7e7e7e, inset 2px 2px 0 0 #f0f0f0, inset -2px -2px 0 0 #262626;
    background: #c3c3c3;
    /*max-height: calc(100vh - 160px);*/
    /*overflow: auto;*/
}

#game_window .windows-container__header{
    padding: 2px;
}

#game_window .windows-container__header-text{
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 18px;
    font-weight: 400;
    line-height: 111%;
}

#get_help {
    position: absolute;
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
    min-width: 200px;
    max-width: 300px;
    margin: auto;
    margin-top: 15px;
    background-color: rgb(233, 230, 211);
    width: fit-content;
    z-index: 1;
    top: 0;
    left: 0;
    padding: 4px;
    box-shadow: inset 4px 4px 0 0 #b1b1b1,
    inset -4px -4px 0 0 #7e7e7e,
    inset 2px 2px 0 0 #f0f0f0,
    inset -2px -2px 0 0 #262626;
}

#instructions {
    padding: 10px;
}

#instructions h3{
    font-size: 18px;
    font-weight: 700;
    line-height: 111%;
    margin: 10px 0 16px;
}

#instructions ul {
    padding-left: 20px;
    padding-right: 5px;
}

#instructions li {
    list-style-type: disc;
    font-size: 14px;
    cursor: normal;
    margin: 0 0 10px;
}

#window_top,
#help_top {
    background-image: url('/wp-content/themes/1IT/image/minesweeper/taskbar_middle.png');
    color: rgb(235, 232, 218);
    padding: 5px;
    height: 20px;
}

#icon {
    max-width: 20px;
    margin-right: 5px;
    margin-top: 1px;
    float: left;
}

.window_title {
    margin: 1px;
}

#window_menu {
    display: flex;
    align-items: center;
    position: relative;
    background: #c3c3c3;
    height: 38px;
    gap: 32px;
}

#window_menu > button {
    font-weight: 400;
    font-size: 26px;
    line-height: 100%;
    color: #000;
    border: none;
    background-color: transparent;
    float: left;
    padding-bottom: 0;
    max-width: fit-content;
    text-decoration-skip-ink: none;
}

#window_menu > button:hover {
    background-color: rgb(46, 95, 224);
    color: white;
}

.window_button {
    float: right;
    margin-top: -3px;
    height: 25px;
}

#cross,
#help_cross {
    margin-right: -3px;
}



#white_margin {
    border-top: solid white 4px;
    border-left: solid white 3px;
}

#game_panel {
    background-color: rgb(184, 184, 184);
    margin: 5px;
    margin-bottom: 0;
    padding-bottom: 5px;
}

#game_menu {
    display: flex;
    justify-content: center;
    align-items: center;
    border-top: solid rgb(117, 117, 117) 2px;
    border-left: solid rgb(117, 117, 117) 2px;
    border-bottom: solid white 2px;
    border-right: solid white 2px;
    padding: 6px 22px;
}

#flags_left {
    margin: auto auto auto 0;
}

#flags_left > img,
#timer-game > img {
    margin: -2px;
    height: 54px;
}

#face {
    text-align: center;
}

#face img{
    width: 37px;
}

#timer-game {
    margin: auto 0 auto auto;
}

#face>button {
    background-color: rgb(192, 192, 192);
    border-left: solid white 2px;
    border-top: solid white 2px;
    border-bottom: solid rgb(117, 117, 117) 2px;
    border-right: solid rgb(117, 117, 117) 2px;
    margin: 5px;
    padding: 2px;
}

#face>button:active {
    border-left: solid rgb(117, 117, 117) 2px;
    border-top: solid rgb(117, 117, 117) 2px;
    border-bottom: solid white 2px;
    border-right: solid white 2px;
    margin: 5px;
    padding: 2px;
}

#face>button:active>img {
    transform: translate(0.5px, 0.5px);
}

#grid {
    border-top: solid rgb(117, 117, 117) 2px;
    border-left: solid rgb(117, 117, 117) 2px;
    border-bottom: solid white 2px;
    border-right: solid white 2px;
    border-collapse: collapse;
    width: 100%;
    margin-top: 5px;
}

/* common for all buttons on the field */
.field_button {
    padding: 16px;
    width: 100%;
    border-top: solid white 2px;
    border-left: solid white 2px;
    border-bottom: solid rgb(117, 117, 117) 2px;
    border-right: solid rgb(117, 117, 117) 2px;
    background-color: rgb(192, 192, 192);
}

.field_button:active {
    border-top: solid rgb(117, 117, 117) 1px;
    border-left: solid rgb(117, 117, 117) 1px;
    border-bottom: solid transparent 3px;
    border-right: solid transparent 3px;
}

td {
    position: relative;
    padding: 0;
    text-align: center;
}

.field_button_mine,
.field_button_mine:active {
    background-image: url("/wp-content/themes/1IT/image/minesweeper/mine.svg");
    background-size: 28px;
    background-repeat: no-repeat;
    background-position: center;
    border: none;
    border-left: solid rgb(117, 117, 117) 1px;
    border-top: solid rgb(117, 117, 117) 1px;
}

.field_button_flagged {
    background-image: url("/wp-content/themes/1IT/image/minesweeper/flag.png");
    background-size: 24px;
    background-position: center;
    background-repeat: no-repeat;
}

.field_button_empty {
    background-color: rgb(192, 192, 192);
    border: none;
    border-left: solid rgb(117, 117, 117) 1px;
    border-top: solid rgb(117, 117, 117) 1px;
    padding: 16px 0;
    margin: 0;
    width: 100%;
    height: 100%;
    min-width: 22px;
}

.field_button_img {
    background-color: rgb(192, 192, 192);
    border: none;
    border-left: solid rgb(117, 117, 117) 1px;
    border-top: solid rgb(117, 117, 117) 1px;
    padding: 2px;
    background-repeat: no-repeat;
    background-position: center;
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    margin: auto;
}

#taskbar_right {
    float: right;
}

#clock {
    display: inline;
    position: relative;
    left: 110px;
    top: -10px;
    color: whitesmoke;
    cursor: default;
}

.hidden {
    display: none;
}

.difficulty {
    display: inline-block;
    border: none;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    background-color: white;
    border: solid gray 1px;
    box-shadow: 2px 2px 1px darkslategray;
    position: absolute;
    left: 0;
    top: 40px;
    overflow: auto;
    z-index: 2;
}

.show {
    display: block;
}

.dropdown-content button {
    font-size: 18px;
    cursor: pointer;
    border: none;
    background-color: transparent;
    display: block;
    min-width: 120px;
    text-align: left;
    font-family: Arial, Helvetica, sans-serif;
    margin: 2px;
    padding-top: 2px;
    padding-bottom: 2px;
    padding-left: 15px;
}

.dropdown-content button:enabled {
    color: black;
}

.checkmark {
    background-image: url('/wp-content/themes/1IT/image/minesweeper/checked.png');
    background-position-x: 3px;
    background-position-y: center;
    background-size: 7px;
    background-repeat: no-repeat;
}

.dropdown-content button:hover {
    background-color: rgb(46, 95, 224);
    color: white;
}

#unlucky {
    color: blue;
    cursor: pointer;
}

.clearfix {
    overflow: auto;
}

.clearfix::after {
    content: "";
    clear: both;
    display: table;
}

@media (max-width: 767px){
    #game_window {
        transform: translate(-45%, -55%);
    }
}

@media (max-width: 575px){
    #game_menu{
        padding: 6px 10px;
    }
    #game_window{
        min-width: 210px;
        width: 210px;
        overflow: hidden;
        transform: translate(-40%, -55%);
    }

    .field_button{
        padding: 9px;
    }

    .field_button_mine,
    .field_button_mine:active{
        background-size: 14px;
    }

    .field_button_empty{
        padding: 12px 0;
        min-width: 22px;
    }

    #flags_left > img,
    #timer-game > img{
        height: 30px;
    }

    #game_window .windows-container__header-text{
        font-size: 12px;
    }

    .windows-container__header-text img{
        width: 24px;
        height: 24px;
    }

}


@media (max-width: 340px){
    #game_window{
        width: 200px;
        min-width: 200px;
        transform: translate(-50%, -55%);
    }

    .field_button{
        padding: 8px;
    }
}