.modal {
    @include overlay;
    align-items: center;
    display: none;
    justify-content: center;
    overflow: hidden;
    position: fixed;
    z-index: 10000;

    .admin-bar & {
        top: 32px;
    }

    .delete-icon {
        @include delete;
    }

    // Modifiers
    &.is-active {
        display: flex;
    }

    &-background {
        @include overlay;
        background-color: rgba($black, 0.86);
    }

    &-content,
    &-card {
        margin: 0 20px;
        max-height: calc(100vh - 160px);
        overflow: auto;
        position: relative;
        width: 100%;
        // Responsiveness
        @media screen and (min-width: 769px), print {
            margin: 0 auto;
            max-height: calc(100vh - 40px);
            width: 640px;
        }
    }

    &-close {
        @include delete;
        background: none;
        height: 40px;
        position: fixed;
        right: 20px;
        top: 20px;
        width: 40px;
    }

    &-card {
        display: flex;
        flex-direction: column;
        max-height: calc(100vh - 40px);
        overflow: hidden;
    }

    &-card-head,
    &-card-foot {
        align-items: center;
        background-color: $background;
        display: flex;
        flex-shrink: 0;
        justify-content: flex-start;
        margin: 0;
        padding: 20px;
        position: relative;
    }

    &-card-head {
        border-bottom: 1px solid $border;
        border-top-left-radius: $radius-large;
        border-top-right-radius: $radius-large;
    }

    &-card-title {
        color: $text-strong;
        flex-grow: 1;
        flex-shrink: 0;
        font-size: $size-4;
        line-height: 1;
        margin: 0;
        padding: 0;
    }

    &-card-foot {
        border-bottom-left-radius: $radius-large;
        border-bottom-right-radius: $radius-large;
        border-top: 1px solid $border;
        .button {
            &:not(:last-child) {
                margin-right: 10px;
            }
        }
    }

    &-card-body {
        -webkit-overflow-scrolling: touch;
        background-color: $white;
        flex-grow: 1;
        flex-shrink: 1;
        overflow: auto;
        margin: 0;
        padding: 20px;
    }
}
