
.modal {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    padding: 2rem;
    position: fixed;
    top: 0;
    width: 100%;
    visibility: hidden;
    opacity: 0;
    transition: all 0.3s ease;
}

.modal .modal-backdrop {
    background: rgba(0, 0, 0, 0.5);
    height: 100%;
    width: 100%;
    position: fixed;
}

.modal .modal-content {
    background: #fff;
    border-radius: 5px;
    width: auto;
    max-width: 100vw;
    max-height: 100vh;
    position: fixed;
    top: -100%;
    transition: all 0.6s ease;
    z-index: 9999;
    overflow: auto;

    scrollbar-color: whitesmoke;
    scrollbar-width: thin;
}

.modal .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #ccc;
    padding: 1.5rem;
}

.modal .modal-content .modal-head {
    display: flex;
    justify-content: space-between;
    padding: 16px 16px 0 16px;
}

.modal .modal-body {
    padding: 1.5rem;
    overflow: auto;
}

.modal.visible {
    opacity: 1;
    visibility: visible;
}

.modal.visible .modal-content {
    top: auto;
}

@media screen and (max-width: 600px) {

    .modal .modal-content {
        width: 100vw !important;
        max-width: 100vw;
    }
}