@import '../../styles/constants';

.LoadingIndicatorComponent {
    position: fixed;
    top: 0;
    left: 0;
    z-index: $z-index-loading-indicator;

    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;

    background-color: $secondary-color-gray;

    /* Credit: http://tobiasahlin.com/spinkit/ */
    &__spinner {
        position: relative;

        width: 40px;
        height: 40px;

        &--animation {
            position: absolute;
            top: 0;
            left: 0;

            width: 100%;
            height: 100%;

            background-color: $primary-color-white;
            border-radius: 50%;
            opacity: 0.6;

            animation: sk-bounce 2s infinite ease-in-out;

            &:last-of-type {
                animation-delay: -1s;
            }
        }

        @keyframes sk-bounce {
            0%,
            100% {
                transform: scale(0);
            }

            50% {
                transform: scale(1);
            }
        }
    }
}
