// Container that the modal scrolls within

.qor-modal {
    display: none;
    overflow: hidden;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: $zindex-modal;
    background-color: unquote('rgba(#{$color-black}, 0.26)');
    outline: 0;
    -webkit-overflow-scrolling: touch;

    .mdl-card {
        display: block;
        width: auto;
        min-height: 0;
        margin: 16px;

        .mdl-card__supporting-text {
            width: auto;
            word-wrap: break-word;
        }

        .mdl-card__actions {
            padding: 16px;
            @include clearfix();

            > .mdl-button {
                float: right;
                margin-left: 16px;
                min-width: 32px;
            }
        }
    }

    @media screen and (min-width: $layout-screen-size-threshold) {
        .mdl-card {
            max-width: 640px;
            margin: 128px auto;
        }
    }

    &.fade .mdl-card {
        transform: translate(0, -25%);
        transition: transform 0.3s ease-out;
    }

    &.in .mdl-card {
        transform: translate(0, 0);
    }
    .qor-modal-loading {
        position: absolute;
        z-index: 9999;
        background-color: rgba(0, 0, 0, 0.6);
        width: 100%;
        bottom: 0;
        top: 0;
        text-align: center;
        padding-top: 18px;
    }
}

.qor-modal-mini {
    .mdl-card {
        width: 400px;
    }
}

.qor-modal-open {
    // Kill the scroll on the body
    overflow: hidden;

    .qor-modal {
        overflow-x: hidden;
        overflow-y: auto;
    }
}

.qor-dialog {
    position: fixed;
    z-index: 9999;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: unquote('rgba(#{$color-black}, 0.54)');
    .qor-dialog-content {
        position: absolute;
        width: 50%;
        top: 100px;
        left: 0;
        right: 0;
        margin: auto;
        background-color: unquote('rgb(#{$color-white})');
        padding: 24px 48px;
        @include shadow-4dp();
        border-radius: 2px;
        .mdl-textfield {
            width: 100%;
        }
    }
}
