:root {
    --black: rgb(0,0,0);
    --white: rgb(255,255,255);
    --alert-red: rgb(153,0,0);
    --alert-dk-red: rgb(98,0,0);
    --alert-box-shadow: rgba(0,0,0,.8);
}

.emergency-button.show-emergency,
.emergency-button.collapse-emergency,
.emergency-details {
    display: none;
}

.show-emergency {
    background: var(--alert-red);
    border: 2px solid var(--white);
    border-left: 0;
    border-bottom-right-radius: 50%;
    border-top-right-radius: 50%;
    box-shadow: 3px 3px 10px var(--alert-box-shadow);
    color: var(--white);
    cursor: pointer;
    font-size: 36px;
    height: 70px;
    line-height: 36px;
    padding: 15px 22px 15px 10px;
    position: fixed;
    top: calc(70vh - 80px);
    transition: all .3s ease 0s;
    width: 70px;
    z-index: 10000;

    &:active,
    &:hover,
    &:focus {
        background: var(--alert-dk-red);
    }

    /* &.active { display: block; } */
}

.emergency-bar {
    background-color: var(--alert-red);
    box-sizing: border-box;
    display: flex;
    justify-content: space-between;
    padding: 14px 10% 8px;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 9999;

    &.fixed {
        position: fixed;
        width: 100%;
    }

    & ~ header {
        -webkit-transition: all .3s ease 0s;
        -moz-transition: all .3s ease 0s;
        -ms-transition: all .3s ease 0s;
        -o-transition: all .3s ease 0s;
        transition: all .3s ease 0s;
    }

    @media(max-width: 992px) {
        padding: 8px;
    }

    @media(max-width: 650px) {
        flex-direction: column;
    }

    p,
    a,
    button {
        color: var(--white);
        font-size: 16px;
        font-weight: normal;
        line-height: 24px;
    }

    p {
        padding-left: 50px;
        padding-right: 50px;

        @media(max-width: 650px) {
            padding-right: 15px;
        }

        @media(max-width: 400px) {
            padding-left: 15px;
        }

        &.emergency-title {
            padding-left: 0;

            @media(max-width: 400px) {
                padding-left: 15px;
            }
        }
    }

    a {
        text-decoration: underline;
    }

    a.emergency-link,
    button {
        background: var(--alert-red);
        cursor: pointer;
        font-size: 20px;
        line-height: 20px;
        transition: all .3s ease 0s;
    }

    a.emergency-link {
        border: 2px solid var(--white);
        display: block;
        font-size: 18px;
        padding: 5px 20px;
        text-decoration: none;
        white-space: nowrap;
        width: max-content;
    }

    button {
        border: 2px solid var(--alert-red);
        height: 40px;
        width: 40px;

        &.dismiss-emergency {
            display: none;
            margin-left: 10px;
        }
    }

    a:active,
    a:hover,
    a:focus {
        font-weight: bold;
        text-decoration: underline;
    }

    button:active,
    button:hover,
    button:focus,
    a.emergency-link:active,
    a.emergency-link:hover,
    a.emergency-link:focus {
        color: var(--white);
        background: var(--alert-dk-red);
        border: 2px solid var(--white);
        font-weight: normal;
        text-decoration: none;
    }

    .emergency-btns {
        display: flex;
        flex-direction: row;
        justify-content: flex-end;
        min-width: 100px;
        order: 1;

        @media(max-width: 650px) {
            margin-bottom: 20px;
            order: 0;
            width: 100%;
        }
    }

    .emergency-title {
        align-items: center;
        display: flex;
        font-size: 20px;
        line-height: 26px;
        margin: 0;
        padding-bottom: 15px;

        i {
            font-size: 30px;
            padding-right: 20px;

            @media(max-width: 400px) {
                display: none;
            }
        }
    }

    .full-emergency-wrapper {
        flex-grow: 1;
        flex-shrink: 1;
        max-width: calc(100% - 100px);

        > .emergency-title {
            padding-bottom: 0;
        }

        @media(max-width: 650px) {
            max-width: 100%;
        }
    }

    .emergency-details {
        display: none;
        flex-direction: column;
    }

    &.expanded {
        align-items: flex-start;

        .full-emergency-wrapper {
            > .emergency-title {
                display: none;
            }
        }

        .emergency-details {
            display: flex;
        }

        button {
            &.expand-emergency {
                display: none;
            }

            &.collapse-emergency {
                display: block;
            }
        }
    }

    &.dismissed {
        display: none;
    }
}