.create-form {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
    margin-top: 5vh;
    width: 75vw;
    min-width: 300px;
    flex-direction: column;
}

.create-form input,
.submit-form input {
    outline: none;
    padding: 5%;
    font-size: 125%;
    background-color: #f8f9fa;
    border: solid #ced4da 3px;
    border-radius: 15px;
    margin: 0.5vh 0;
    width: 100%;
}

.create-form input:focus,
.submit-form input:focus {
    border: solid #0046d5 3px !important;
}

.subnets-table {
    width: 100%;
}

.create-div {
    display: flex;
    align-items: center;
    justify-content: space-around;
    margin-bottom: 5vh;
    flex-wrap: wrap;
    width: 100%;

}

.create-input-group {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: 250px;
    padding: 0 5%;
}

#numOfSubnets {
    width: 50%;
}

.create-div label {
    font-size: 150%;
    font-weight: 600;
    text-align: center;
}

.create-form button[type="submit"],
.submit-form div.subnetting-submit,
.submit-form button[type="submit"] {
    font-size: 2vh;
    margin-top: 3vh;
    background: #0046d5;
    padding: 2vh 3vh;
    border-radius: 15px;
    color: #f8f9fa;
    box-shadow: 0px 4px 15px -5px #0046d5;
    font-weight: 700;
    border: none;
    cursor: pointer;
}

.levels {
    min-width: 300px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.levels-button {
    width: 100%;
    padding: 2vh 1vh;
    margin: 1vh;
    border: none;
    cursor: pointer;
    font-weight: 700;
    background-color: #f3f3f300;
    text-align: center;
}

.beginner {
    border: solid 1px #32cd32;

    border-top-left-radius: 15px;
    border-bottom-left-radius: 15px;
}

.beginner-clicked {
    background: rgba(50, 205, 50, 0.25);
}

.normal {
    border: solid 1px #ffdf00;
}

.normal-clicked {
    background: rgba(255, 223, 0, 0.25);
}

.advanced {
    border: solid 1px #ffa500;
}

.advanced-clicked {
    background-color: rgba(255, 165, 0, 0.25);
}

.expert {
    border: solid 1px #ff3131;
    border-top-right-radius: 15px;
    border-bottom-right-radius: 15px;
}

.expert-clicked {
    background-color: rgba(255, 49, 49, 0.25);
}

.submit-form {
    width: 80Vw;
    min-width: 300px;
    margin: 0 auto;
    margin-bottom: 2vh;
}

.submit-form table td {
    text-align: center;
}

.submit-form input {
    padding: 1% 3%;
    width: 10vw;
    font-size: 100%;
}

.ip-address {
    text-align: center;
    margin-bottom: 0;
    margin-top: 1vh;
}

.diagram {
    display: flex;
    justify-content: center;
    align-items: center;
}

input.invalid {
    border: 3px solid red;
}

input.valid {
    border: 3px solid lightgreen;
}

#fillInput:focus~.fillButton {
    border: solid #0046d5 3px;
}

.input-submit {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: end;
    margin-top: 2%;

}

.fillAllContanier {
    display: flex;
    flex-direction: column;
    width: fit-content;
    margin-top: -20vh;
    margin-bottom: 5%;
    margin-left: 10%;
}

.fillAllContanier h4 {
    margin-left: 1%;
    width: fit-content;
}

.fillAll {
    display: flex;
    align-items: center;
    margin: 0 auto;
    width: fit-content;
}

#fillInput {
    border-radius: 15px;
    border: solid #ced4da 3px;
    background-color: #f8f9fa;
    height: 4vh;
    padding: 0 1%;
    outline: none;
    width: 15vw;
}

.fillImg {
    cursor: pointer;
    margin-left: -11%;
}

.submit-form button[type="submit"] {
    margin-top: 0;
}

.subnetting-submit {
    margin: 0 10px;
}

.subnets-table {
    border-collapse: collapse;
}

.prev-next-ex {
    display: flex;
    align-items: center;
    justify-content: end;
    padding-top: 10px;
}

.prev-next-ex a {
    color: white;
    display: inline-block;
    padding: 1vh 2vh;
    border-radius: 15px;
    background-color: #0046d5;
    cursor: pointer;
}

.prev-next-ex a::before {
    display: none;
}

.drag-handle {
    cursor: pointer;
}

.sortable-drag {
    opacity: 0;
}

.sortable-chosen>td {
    border-bottom: 2px solid #0046d599;
}

.chat-btn {
    position: fixed;
    left: 20px;
    bottom: 20px;
    cursor: pointer;
}

.chat-window {
    display: flex;
    position: fixed;
    flex-direction: column;
    right: 20px;
    bottom: 20px;
    width: 350px;
    height: 500px;
    border-radius: 5px;
    padding: 5px;
    box-shadow: 0 0 5px 3px rgba(0, 0, 0, .2);
    overflow: hidden;
}

.chat-window.ui-resizable {
    position: fixed;
}

.chat-window.dark-background {
    background-color: #2a3333;
}

.chat-window textarea {
    resize: vertical;
    border-radius: 5px;
    border: none;
    padding: 5px;
    margin: 2px 0;
    background-color: lightgray;
}

.chat-window textarea:focus {
    outline-color: #0046d5;
    outline-style: solid;
    outline-width: 3px;
}

.chat-window button {
    padding: 5px;
    border-radius: 5px;
    border: none;
    margin: 2px 0;
    cursor: pointer;
    transition: all 200ms ease-in-out;
}

.chat-window .send-message {
    background-color: #0046d5;
}

.chat-window .send-message:hover {
    background-color: #0055ff;
}

.chat-window .close-btn {
    outline: 2px solid red;
    outline-offset: -3px;
    background-color: transparent;
}

.chat-window .close-btn:hover {
    background-color: red;
}

.messages {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column-reverse;
    overflow-x: hidden;
    overflow-y: auto;
}

.message-wrap {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 5px 0;
}

.message-wrap.ai {
    justify-content: left;
}

.message-wrap.user {
    justify-content: right;
}

.message {
    padding: 5px;
    border-radius: 5px;
    max-width: 500px;
}

.message-wrap.ai .message {
    background-color: lightgray;
    color: black;
}

.message-wrap.user .message {
    background-color: blue;
    color: white;
}

.icon-color {
    color: white;
}

/*https://stackoverflow.com/questions/60091520/custom-checkbox-add-cross-icon-on-uncheck-using-css*/
.custom-checkbox {
    display: inline-block;
    position: relative;
    padding-right: 35px;
    margin-bottom: 12px;
    cursor: pointer;
    font-size: 22px;
    user-select: none;
}

.custom-checkbox input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 0;
    right: 0;
    height: 25px;
    width: 25px;
    background-color: #eee;
    border-radius: 4px;
    border: 2px solid #0046d5;
}

.custom-checkbox:hover input~.checkmark {
    background-color: #ccc;
}

.custom-checkbox input:checked~.checkmark {
    background-color: #0046d5;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.custom-checkbox input:checked~.checkmark:after {
    display: block;
}

.custom-checkbox .checkmark:after {
    left: 9px;
    top: 5px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 3px 3px 0;
    transform: rotate(45deg);
}

.checkbox-contanier {
    display: flex;
    justify-content: space-around;
    width: 75%;
}

.hidden {
    display: none;
}

.chat-form {
    display: flex;
    flex-direction: column;
}

.create-form input.dark-inputSubnetting {
    background-color: #232b2b;
    color: #ced4da;
}

a.back-button {
    position: fixed;
    left: 4%;
    bottom: 2%;
}

.answers {
    text-align: center;
}

.mods {
    width: 70vw;
    display: flex;
    justify-content: space-around;
    margin: 0 auto;
}

.mods h2 {
    cursor: pointer;
    text-align: center;
    padding: 3%;
    font-size: 150%;
}

.broadcast,
.sameSubnet {
    width: 40%;
    border: 2px solid #0046d5;
    border-radius: 15px;
    box-shadow: 0px 4px 15px -5px #0046d5;
    height: fit-content;
}

.mods form {
    width: 80%;
    margin: 0 auto;
}

.mods input {
    outline: none;
    background-color: #f8f9fa;
    border: solid #ced4da 3px;
    border-radius: 15px;
    margin: 0.5vh 0;
    padding: 0.5vh;
    font-weight: 700;
    font-size: 125%;
    padding-right: 0;
    width: 100%;
    box-sizing: border-box;
}

.mods input:focus {
    border: solid #0046d5 3px;
}


/*https://stackoverflow.com/questions/60091520/custom-checkbox-add-cross-icon-on-uncheck-using-css*/
.custom-checkbox {
    display: flex;
    position: relative;
    padding-right: 35px;
    margin-bottom: 12px;
    cursor: pointer;
    font-size: 22px;
    user-select: none;
}

.checkmark {
    position: absolute;
    top: 0;
    right: 0;
    height: 25px;
    width: 25px;
    background-color: #eee;
    border-radius: 4px;
    border: 2px solid #0046d5;
}

.custom-checkbox:hover input~.checkmark {
    background-color: #ccc;
}

.custom-checkbox input:checked~.checkmark {
    background-color: #0046d5 !important;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.custom-checkbox input:checked~.checkmark:after {
    display: block;
}

.custom-checkbox .checkmark:after {
    left: 9px;
    top: 5px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 3px 3px 0;
    transform: rotate(45deg);
}

.custom-checkbox input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.mods button {
    font-size: 2vh;
    padding: 1vh 2vh;
    border-radius: 15px;
    color: #f8f9fa;
    font-weight: 700;
    border: none;
    cursor: pointer;
    margin: 1vh 0;
    width: 100%;
    box-shadow: 0px 4px 15px -5px #716969;
    background: #ced4da;
    cursor: auto;
}


.mods button[type="submit"]{
    box-shadow: 0px 4px 15px -5px #0046d5;
    background: #0046d5;
    cursor: pointer;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    /* color: #333333; */
}

input[type="checkbox"] {
    margin-right: 10px;
    transform: scale(1.2);
}

input[type="checkbox"]:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.mods-error {
    text-align: center;
    margin: 0 auto;
    margin-top: 3%;
    font-size: 125%;
}

h2.title{
    text-align: center;
    margin-top: 5%;
    margin-bottom: 1%;
}

@media screen and (width <=1200px) {
    .mods {
        flex-direction: column;
    }

    .mods div {
        width: 100%;
        margin-top: 5%;
    }
}


@media screen and (width <=1024px) {
    tbody {
        display: flex;
        flex-direction: column;
    }

    thead{
        display: none;
    }

    tr {
        display: flex;
        flex-direction: column;
    }

    .submit-form input {
        width: 90%;
    }

    .sortable-chosen>td {
        border-bottom: none;
    }

    .sortable-chosen>td:last-child {
        border-bottom: 2px solid #0046d599;
    }

    .fillAllContanier {
        margin-top: -30vh;
        width: 80%;
        align-items: center;
        margin-bottom: 17%;
    }

    #fillInput {
        width: 95%;
    }

    .prev-next-ex {
        justify-content: center;
        margin-bottom: 5%;
    }

    .subnets-table tr:last-child .drag-handle {
        margin-bottom: 10%;
    }
}

@media screen and (width <=850px) {
    .fillAllContanier {
        margin-top: -28vh;
        margin-bottom: 19%;
    }
}

@media screen and (width <=500px) {
    .fillAllContanier {
        margin-top: -33vh;
        margin-bottom: 45%;
    }

    #fillInput {
        width: 100%;
    }

    .fillImg {
        margin-left: -10%;
    }

    .input-submit {
        margin: 0 auto;
    }

    .chat-window {
        width: 310px;
    }

    .prev-next-ex {
        margin: 20% 0;
    }
}

@media screen and (width <=425px) {
    .levels {
        flex-wrap: wrap;
    }

    .create-form button[type="submit"] {
        margin-bottom: 5%;
    }

    .levels-button {
        border-radius: 15px;
    }

    .checkbox-contanier {
        width: 95%;
    }
}

foreignObject div {
    text-align: center;
    font-weight: 900;
    font-size: 20px;
}

foreignObject div:focus {
    border: none;
}
