$novo-modal-z-index: 1000;

body.modal-open {
    overflow: hidden;
}

novo-modal-container {
    z-index: $novo-modal-z-index;
    position: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, .25);
}

novo-modal {
    & > header {
        border-top-left-radius: 3px;
        border-top-right-radius: 3px;

        h2 {
            padding: 0.75em;
        }
    }

    & > section {
        padding: 1em 3em;
        max-height: 500px;
        overflow: auto;
    }

    & > footer {
        display: flex;
        align-items: center;
        padding: 0.5em;

        button {
            width: 50%;

            &:first-of-type {
                margin: 0 0.5% 0 0;
            }

            &:last-of-type {
                margin: 0 0 0 0.5%;
            }
        }
    }
}

novo-notification {
    text-align: center;
    padding: 0.5em;

    & > section {
        text-align: center;
    }
}

novo-modal,
novo-notification {
    display: block;
    background-color: #fff;
    margin-bottom: 1em;
    border-radius: 4px;
    box-shadow: 0 1px 7px rgba(0, 0, 0, .09), 0 1px 3px rgba(0, 0, 0, .20);
    z-index: 1000;
    position: relative;
    min-width: 330px;
    max-width: 600px;

    & > button.modal-close {
        position: absolute;
        right: 10px;
        top: 10px;
    }

    & > header {
        padding: 1em;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;

        h1 {
            margin: 0;
            text-align: left;
        }
    }

    & > section {
        display: flex;
        flex-direction: column;

        & > img {
            width: 100%;
        }

        h1 {
            font-size: 1.8em;
            color: darken($light, 45%);
            margin: 0 auto;
        }

        h2,
        h4 {
            font-size: 1.3em;
            color: darken($light, 15%);
            margin: 0 auto;
            padding: 0;
        }

        i.indicator {
            color: darken($light, 10%);
            font-size: 1.7em;
            border-radius: 50%;
            padding: 7.5px;
            border: 2px solid darken($light, 10%);
            width: 50px;
            height: 50px;
            margin: 0 auto;
            align-self: center;
        }
    }

    & > footer {
        display: flex;
        flex-flow: row nowrap;

        button {
            height: 45px;
            flex: 1;

            .flex-wrapper {
                justify-content: center !important;
            }

            &[theme="primary"] {
                .flex-wrapper {
                    justify-content: center !important;
                }
            }
        }
    }

    &[type="success"] {
        & > section {
            i {
                color: $success;
                border-color: $success;
            }
        }

        button[theme="primary"] {
            width: 100%;

            .flex-wrapper {
                justify-content: center;
            }
        }
    }

    &[type="warning"] {
        footer {
            display: flex;

            .flex-wrapper {
                justify-content: center;
            }
        }

        button {
            width: 50%;
            justify-content: center;

            &:first-of-type {
                margin: 0 0.5% 0 0;
            }

            &:last-of-type {
                margin: 0 0 0 0.5%;
            }
        }
    }

    &[type="error"] {
        & > section {}

        button[theme="primary"].primary {
            width: 100%;

            .flex-wrapper {
                justify-content: center;
            }
        }
    }
}

novo-notification {
    & > section {
        padding: 0 20px;
        margin: 15px 0 55px;

        h1 {
            margin: 10px auto 0;
        }
    }
}
