html {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

*,
*::after,
*::before {
    box-sizing: inherit;
    margin: 0;
    padding: 0;
}

table {
    border: rgb(0, 0, 0) 2px solid;
    border-collapse: separate;
    border-spacing: 2px 5px;
}

td {
    padding-left: 3px;
}

thead td {
    background-color: rgb(0, 140, 255)
}

tbody td {
    background-color: rgb(0, 183, 255);
}

body {
    display: grid;
    position: fixed;

    row-gap: 0;
    column-gap: 0;
}

@media screen and (min-height: 56.25em) {
    body {
        grid-template-columns: 50vw 35vw 15vw;
        grid-template-rows: 63px calc(50vh - 63px) calc(50vh - 63px) 63px;
    }

    h1 {
        height: 40px;
        margin-top: 11.5px;
        margin-bottom: 11.5px;
    }

    label[for="cb_settings"] {
        height: 40px;
        width: 40px;

        position: absolute;
        top: 11.5px;
        right: 11.5px;

        font-size: 2em
    }

    #start {
        height: 43px;
        width: 300px;

        margin-top: 10px;
        margin-bottom: 10px;

        font-size: 18pt;
    }

    .progress-bar {
        position: relative;
        width: 40vw;
        height: 30px;

        margin-top: 16.5px;
        margin-bottom: 16.5px;
        margin-left: 5vw;
        float: left;
    }

}

@media screen and (max-height: 56.25em) {
    body {
        grid-template-columns: 50vw 35vw 15vw;
        grid-template-rows: 6vh 44vh 44vh 6vh;
    }

    h1 {
        height: 4vh;
        margin-top: 1vh;
        margin-bottom: 1vh;
        font-size: 3.5vh;
    }

    label[for="cb_settings"] {
        height: 4vh;
        width: 4vh;

        position: absolute;
        top: 1vh;
        right: 1vh;
    }

    #start {
        height: 4vh;
        width: 200px;

        margin-top: 1vh;
        margin-bottom: 1vh;

        font-size: 2ex;
    }

    .progress-bar {
        height: 3vh;
        width: 40vw;
        position: relative;

        margin-top: 1.5vh;
        margin-bottom: 1.5vh;
        margin-left: 5vw;
        float: left;
    }
}

header {
    grid-column: 1/4;
    grid-row: 1/2;

    background-color: #0064ef;
}

#parameters {
    grid-column: 1/2;
    grid-row: 2/4;
}

#matrix {
    grid-column: 2/4;
    grid-row: 2/3;

    display: grid;
    position: relative;
}

#errorInformations {
    grid-column: 3/4;
    grid-row: 2/3;

    z-index: 2;
    visibility: hidden;

    border: black solid 1px;

    background-color: rgb(235, 235, 235);

    position: relative;

    user-select: none;
}

#graph {
    grid-column: 2/4;
    grid-row: 3/4;
}

footer {
    grid-column: 1/4;
    grid-row: 4/5;

    background-color: #0064ef;
    text-align: center;
}

.first-level {
    z-index: 1;

    border: solid 1px black;
}

h1 {
    color: #FFFFFF;
    text-align: left;
    margin-left: 5px;
}

/* Settings */
#setting {
    grid-column: 3/4;
    grid-row: 1/5;

    width: 15vw;
    height: 100vh;
    padding-top: 10vh;
    text-align: center;

    /* float: right; */
    background-color: rgb(235, 235, 235);
    border-left: rgb(0, 0, 0) 2px solid;

    z-index: 0;
    display: none;

}

#cb_settings {
    z-index: 0;
    display: none;
}

label[for="cb_settings"] {
    z-index: 4;

    text-align: center;
    font-weight: bold;

    background-color: rgb(0, 183, 255);
    border: black 3px solid;
    border-radius: 5px;
}

label[for="cb_settings"]:hover {
    background-color: rgb(0, 140, 255);
}

#cb_settings:checked+label[for="cb_settings"] {
    right: 12vw;
}


#cb_settings:checked~nav {
    display: block;
    z-index: 3;
}

#setting ul {
    width: 13vw;
    margin: 20px;
    margin-left: 1vw;
    margin-right: 0;

    padding: 0;
    border: none;

    position: absolute;
    bottom: 0;
    text-align: center;
    align-content: center;
}

#setting li {
    text-align: center;
    list-style-type: none;
}

.bt_setting {
    width: 12vw;
    height: 40px;

    margin-top: 10px;
    margin-bottom: 10px;

    font-size: 16pt;
    background-color: #0064ef;

    border: rgb(0, 0, 0) 4px solid;
    border-radius: 8px;
}

.bt_setting:active {
    background-color: #0038ef;
}


/* Cotainers */
.tabbed figure {
    display: block;
    margin-left: 0;
    border-bottom: 1px solid silver;
    clear: both;
}

.tabbed>input,
.tabbed figure>div {
    display: none;
}

.tabbed figure>div {
    padding: 20px;
    width: 100%;
    border: 1px solid silver;
    background: #FFFFFF;
    line-height: 1.5em;
    letter-spacing: 0.3px;
    color: #444444
}

#network:checked~figure .network,
#simulation:checked~figure .simulation,
#stimulus:checked~figure .stimulus,
#cluster:checked~figure .cluster {
    display: block;
}

nav label {
    float: left;
    padding: 15px 15px;
    border-top: 1px solid silver;
    border-right: 1px solid silver;
    background: #0064ef;
    color: #eeeeee;
}

nav label:nth-child(1) {
    border-left: 1px solid silver;
}

nav label:hover {
    background: #388bff;
}

nav label:active {
    background: #FFFFFF;
}

#network:checked~nav label[for="network"],
#simulation:checked~nav label[for="simulation"],
#stimulus:checked~nav label[for="stimulus"],
#cluster:checked~nav label[for="cluster"] {
    background: white;
    color: #111111;
    position: relative;
    border-bottom: none;
}

#network:checked~nav label[for="network"]:after,
#simulation:checked~nav label[for="simulation"]:after,
#stimulus:checked~nav label[for="stimulus"]:after,
#cluster:checked~nav label[for="cluster"]:after {
    content: "";
    display: block;
    position: absolute;
    height: 2px;
    width: 100%;
    background: white;
    left: 0;
    bottom: -1px;
}

/* Cluster */
#matrix label {
    background-color: #00BB00;
    border: rgb(0, 0, 0) 2px solid;
    border-radius: 4px;
}

#matrix hr {
    position: absolute;
}

.connections {
    visibility: visible;
}

#errorInformations>table {
    width: 14vw;

    margin-left: 0.5vw;
    margin-right: 0.5vw;
    margin-top: 1vw;

    font-size: 1.2em;
}

#errorInformations button {
    position: absolute;
    bottom: 10px;
    left: 1.5vw;
}

/* Cluster Tooltip */
#matrix p {
    font-size: 15pt;
    font-weight: bold;

    padding: 10px;
    margin-right: 0.5vw;

    position: absolute;
    right: 5px;
    user-select: none;
}

.tooltiptext {
    visibility: hidden;

    font-size: 16pt;
    width: 30vw;
    z-index: 3;
    padding: 10px 3px;
    padding-left: 8px;

    position: absolute;
    right: 5px;
    top: 12vh;

    background-color: #34d6ffcb;
    border: #000 3px solid;
}

.tooltip:hover+.tooltiptext {
    visibility: visible;
}

/* Progress Bar */
.progress-bar {
    /* position:relative;
    width: 40vw;
    height: 2.5em;

    margin-top: calc(4vh - 1.25em);
    margin-bottom: calc(4vh - 1.5em);
    margin-left: 5vw;
    float: left; */

    background-color: rgb(61, 61, 61);
    color: rgb(61, 61, 61);
    border-radius: 1.5em;
    display: none;
}

.progress-bar::before {
    height: 1.75;
    content: attr(data-label);
    display: flex;
    align-items: center;

    position: absolute;
    left: .375em;
    top: .375em;
    bottom: .375em;

    width: calc(var(--width, 0) * 1%);
    min-width: 20px;
    max-width: calc(100% - 1em);
    background-color: #34d6ff;
    border-radius: 1em;
    padding: 0.2em;
}

/* Console output */
#console_output {
    display: none;

    background-color: rgb(255, 0, 0);
}

/* Start Button */
#start {
    text-align: center;

    border: 4px solid #000000;
    border-radius: 25px;
    box-shadow: 2px 2px black;

    position: relative;
    top: -2px;
    left: -2px;

    background-color: #34d6ff;
}

#start:hover {
    box-shadow: none;
    top: 0;
    left: 0;
    background-color: #34d6ff;
}