/* for new subject form */
#cardCancelButton {
    border-radius: 5px;
    border: 1px solid grey;
    width: 20%;
    font-weight: 500;
}

#cardSaveButton {
    border: 1px solid grey;
    border-radius: 6px;
    width: 30%;
    font-weight: 500;
    background-color: #2169c6;
    color: white;
}

#formContainer {

    position: fixed;
    font-family: 'Libre Baskerville';
    top: 50%;
    left: 50%;
    transform: translateX(-50%) translateY(-50%);
    width: 50%;
    max-width: 680px;
    height: auto;
    z-index: 10;
    border-radius: 8px;
    display: none;
    flex-direction: column;
    gap: 2px;
    padding: 20px;
    justify-content: center;
    align-items: flex-start;
    background: #0b1020;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.6);
    border: #1e293b;
}

#formContainer h2 {
    color: rgb(255, 255, 255);
    font-family: 'Roboto Slab';
    font-weight: 600;
    text-shadow: 0 0 1px rgb(125, 125, 172);
    border-bottom: 0.5px solid rgb(98, 98, 108);
    width: 100%;
    text-align: center;
    margin: 0 0 8px 0;
    border-radius: 4px;

}

#formContainer span {
    font-weight: 500;
    margin-top: 15px;
    font-family: 'Inter';
}

#subject {
    width: 100%;
    min-height: 34px;
    background-color: #161e30;
    border-radius: 4px;
    border: 0.5px solid #4e6074;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);

}

.subjectInput {
    width: 100%;
    font-weight: 600;
    padding: 5px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 5px;

}

.subjectInput input {
    width: 90%;
    min-height: 28px;
    border-radius: 4px;
    background: #111827;
    border: 0.5px solid #4e6074;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);

}

.subjectInput select {
    width: 50%;
    min-height: 28px;
    border-radius: 6px;
    background: #111827;
    color: #8d8c8d;
    font-weight: 500;
    border: 0.5px solid #4e6074;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

#formButtons {
    width: 95%;
    height: 26%;
    display: flex;
    justify-content: space-around;
    padding: 15px 3px 15px 3px;
}

#formButtons button {
    width: 40%;
    height: 35px;
    padding: 3px;
    background: linear-gradient(160deg, #56aacd, #0c48b0);
    border: 1px solid white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    color: #eae8e8;
    border: none;
    font-weight: 700;
    font-size: 90%;
}

#formButtons button:hover {
    transition: all;
    transform: scale(1.05);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

h3 {
    margin: 0;
}

/* for  edit subject form */
#editSubject {
    position: fixed;
    width: 30%;
    z-index: 8;
    min-width: 260px;
    max-width: 320px;
    height: auto;
    padding-bottom: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
    top: 50%;
    left: 50%;
    transform: translateX(-50%) translateY(-50%);
    background: #0b1020;
    flex-direction: column;
    align-items: center;
    border-radius: 8px;
    gap: 6px;
}

#editSubject h3 {
    width: 100%;
    border-radius: 8px 8px 0 0;
    background: #0c132a;
    text-align: center;
    box-shadow: 0 1px 4px rgba(24, 42, 68, 0.3);
    font-family: 'Roboto Slab';
    color: #ffffff;
    padding: 3px;
}

.inputEditSubject {
    width: 100%;
    max-height: 40px;
    padding: 3px;
    display: flex;
    justify-content: center;
    gap: 5px;
}

.inputEditSubject input {
    width: 50%;
    border: 0.2px solid rgb(39, 52, 76);
    border-radius: 5px;
    height: 100%;
    padding: 2px;
    background: #111827;
}

#saveEditSubject {
    width: 30%;
    height: 25px;
    border: none;
    font-family: 'Roboto Slab';
    color: white;
    background: #2169c6;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* for edit category form */
#editCategory {
    position: fixed;
    width: 30%;
    z-index: 9;
    min-width: 280px;
    max-width: 320px;
    min-height: 150px;
    height: auto;
    padding-bottom: 10px;
    top: 50%;
    left: 50%;
    transform: translateX(-50%) translateY(-50%);
    background: #0b1020;
    flex-direction: column;
    align-items: center;
    border-radius: 8px;
    gap: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

#editCategory h3 {
    width: 100%;
    border-radius: 8px 8px 0 0;
    background: #0a0f22;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    min-height: 28px;
    font-family: 'Roboto Slab';
    color: #ffffff;
}

.inputEditCategory {
    width: 100%;
    max-height: 40px;
    padding: 5px;
    display: flex;
    justify-content: center;
    gap: 5px;
}

.newCategoryName {
    width: 50%;
    border: 0.2px solid rgb(39, 52, 76);
    border-radius: 5px;
    padding: 2px;
    background: #111827;
}

#selectCategoryNew {
    width: 50%;
    border: 0.2px solid rgb(39, 52, 76);
    border-radius: 5px;
    padding: 2px;
    background: #111827;
}

#saveEditCategory {
    width: 30%;
    height: 25px;
    border: none;
    font-family: 'Roboto Slab';
    color: white;
    background: #2169c6;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}


@media screen and (max-width:768px) {
    #formContainer {
        width: 75%;
        padding-top: 0px;
    }

    span {
        font-size: smaller;
    }

    #formContainer h2 {
        font-size: large;
        margin: 10px 0 8px 0;
    }

    #formButtons button {
        height: 14%;
        font-size: small;
    }

    #subject {
        min-height: 28px;
        padding: 3px;
        font-size: x-small;
    }

    .subjectInput input {
        min-height: 25px;
        padding: 3px;
        font-size: x-small;
    }

    .subjectInput select {
        min-height: 25px;
        white-space: nowrap;
        font-size: x-small;
    }
}

@media screen and (max-width:428px) {
    #formContainer {
        height: auto;
        width: 90vw;
        padding: 10px;
        padding-top: 0px;
    }

    #formContainer span {
        padding-top: 10px;
        font-size: smaller;
        margin-top: 0px;
    }

    #formContainer h2 {
        font-size: 18px;
    }

    #formButtons button {
        width: 45%;
        height: 14%;
        font-size: small;
    }

    #subject {
        min-height: 28px;
        padding: 3px;
        font-size: x-small;
    }

    .subjectInput input {
        min-height: 25px;
        padding: 3px;
        font-size: x-small;
    }

    .subjectInput select {
        min-height: 24px;
        white-space: nowrap;
        font-size: x-small;
    }
}