@import 'theme/variables.scss';

.modal-open {
    overflow: hidden !important;

    &::-webkit-scrollbar-track {
        background-color: rgba(0, 0, 0, 0.3);
    }

    &::-webkit-scrollbar-thumb {
        background-color: rgba(0, 0, 0, 0.3);
    }
}
.modal-date-logo {
    height: 26px;
    width: 26px;
    cursor: pointer !important;
    position: relative;
    svg {
        &:hover {
            cursor: pointer;
            path {
                fill: $muted;
            }
        }
    }
}
.modal-date-border {
    height: 18px;
    margin-right: 4px;
    border-right: 1px solid $ta-light-grey-6;
}
.modal-container {
    width: 480px;
    height: auto;
    overflow: hidden;
    position: relative;
    transition: width 300ms;

    .drop-zone-active {
        width: 100%;
        height: 100%;
        position: absolute;
        top: 0%;
        left: 0%;
        z-index: 99999999999;

        .drop-zone-title {
            position: absolute;
            z-index: 9999;
            top: 16px;
            left: 14px;
            color: $bw6-2;
            font-size: 18px;
            font-weight: 800;
            margin: 0;
        }

        .ta-modal-dropzone {
            position: absolute;
            top: 0;
            border: 4px dashed $ta-light-grey;
        }

        &-hovered {
            .ta-modal-dropzone {
                position: absolute;
                top: 0;
                border: 4px dashed $white;
                background-color: $bw2;

                .ta-modal-dropzone-label {
                    background-color: $bw2;
                }

                .ta-modal-dropzone-text {
                    color: $bw6-2;
                }
            }
        }

        // Upload Part Override
        .ta-modal-dropzone-area {
            transform: scale(2);
        }

        .ta-modal-dropzone-text {
            position: absolute !important;
            top: 84% !important;
            text-align: center;
            left: 50% !important;
            transform: translate(-50%, -50%);
        }
    }

    &.modal-container-load {
        width: 1280px;
        display: flex;

        .divider {
            width: 615px;
        }

        .modal-additional-part {
            width: 640px;

            &-load {
                background-color: $ta-light-grey-5;
                height: 650px;

                .divider {
                    background-color: $bw-9;
                    height: 1px;
                }

                &-modal {
                    max-width: 640px;
                    width: calc(100vw - 640px);
                }
            }
        }
    }

    // This class set up, because load modal has two parts (origin - additional)
    .load-modal-origin-part {
        width: 640px !important;
    }

    &.modal-container-XS {
        width: 390px;

        .divider {
            width: 366px;
        }

        .confirmation-modal-body {
            padding: 22px 6px;
        }
    }

    &.modal-container-S {
        width: 366px;

        .divider {
            width: 341px;
        }
    }

    &.modal-container-M {
        width: 640px;

        .divider {
            height: 1px;
            background-color: $bw-9;
            width: 616px;
            margin: 0 auto;
        }
    }

    &.modal-container-L {
        width: 710px;

        .divider {
            width: 685px;
        }
    }

    &.modal-container-XL {
        width: 860px;

        .divider {
            width: 836px;
        }
    }

    &.modal-container-XL-2 {
        width: 800px;

        .divider {
            width: 775px;
        }

        overflow: visible !important;
    }

    &.modal-container-full-screen {
        width: calc(100vw - 24px);
        height: calc(100vh - 24px);
        margin: 12px !important;

        .modal-original-part {
            height: 100%;
            display: flex;
            flex-direction: column;
        }
    }

    &.modal-container-import {
        width: 480px;

        &-invalid-list {
            max-width: 1280px;
            min-width: 960px;
            width: calc(100% - 40px);
            height: calc(100vh - 10vh);
            margin-block: 5vh !important;

            > .modal-original-part {
                height: 100%;
                display: flex;
                flex-direction: column;

                .modal-body {
                    height: 100%;
                    overflow: hidden;
                }
            }

            &-full-screen {
                width: calc(100% - 24px);
                height: calc(100% - 24px);
                margin: 12px !important;

                > .modal-original-part {
                    height: 100%;
                    display: flex;
                    flex-direction: column;

                    .modal-body {
                        height: 100%;
                        overflow: hidden;
                    }
                }
            }
        }
    }

    .divider-bottom {
        margin-bottom: 12px !important;
    }

    .card-divider {
        background-color: $bw-9 !important;
        height: 1px !important;
    }

    &.modal-container-sph-applicant {
        width: 940px;
        height: 960px;

        overflow-y: scroll;
        scrollbar-width: none !important; /* Firefox */

        &::-webkit-scrollbar {
            width: 2px;
        }

        &::-webkit-scrollbar-thumb {
            background-color: transparent;
            border: 6px solid transparent;
            border-radius: 1px;
        }

        &::-webkit-scrollbar-track {
            padding: 0;
            position: relative;
            right: 0;
            top: 0;
            background: transparent;
        }

        .divider {
            display: none;
        }
    }

    &.modal-container-file-manager {
        width: 960px;
    }

    .divider {
        width: 455px;
        height: 2px;
        content: '';
        border-radius: 1px;
        background-color: #f3f3f3;

        margin: 0 auto;
        //new design
        //margin-left: 12px;
    }

    .modal-spinner {
        position: absolute;
        bottom: 7px;
        right: 8px;
    }

    //   Ovveride global settings for row > columns
    .form-container {
        .row {
            & > * {
                &:nth-child(odd) {
                    padding-left: 12px;
                    padding-right: 12px;
                }

                &:nth-child(even) {
                    padding-left: 0px;
                    padding-right: 12px;
                }
            }
        }
    }
    .not-clickable {
        pointer-events: none;
        cursor: not-allowed;
        background: $ta-light-grey-5 !important;
        color: $ta-light-grey-6 !important;
    }

    .modal-footer {
        & > * {
            margin: 0px !important;
        }
        .ta-modal-footer-right-side {
            gap: 12px;
            padding-left: 1px;
        }
        .ta-modal-footer-left-side {
            gap: 12px;
            padding-left: 1px;
        }
    }
}

.modal-title {
    &:focus {
        outline: none !important;
    }

    &:focus-visible {
        outline: none !important;
    }
}
