/* ==========================================================================
   SPINNER
   ========================================================================== */

/* #spinner
   ========================================================================== */

#spinner
{
    align-items: center;
    animation: var(--animation-gradient);
    background: radial-gradient(circle farthest-corner at 50% 50%, var(--color-accent-light), var(--color-accent-dark));
    bottom: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    left: 0;
    opacity: 1;
    pointer-events: auto;
    position: fixed;
    right: 0;
    top: 0;
    transform: scale3d(1.5, 1.5, 1.5);
    transition: all 2400ms var(--timing-function-ease-in-out-quad);
    z-index: var(--z-index-front);
}

#spinner.hide
{
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
}

#spinner.show
{
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
}

/* .spinner__icon
   ========================================================================== */

.spinner__icon
{
    animation: rotating 1500ms linear infinite;
    background-image: url("../../images/logo.png");
    background-size: 100% 100%;
    border-radius: 100%;
    height: 75px;
    opacity: 1;
    pointer-events: auto;
    position: relative;
    transform-style: preserve-3d;
    transition: all 600ms var(--timing-function-ease-in-out-quad);
    width: 75px;
}

.hide .spinner__icon
{
    opacity: 0;
    pointer-events: none;
}

.show .spinner__icon
{
    opacity: 1;
    pointer-events: auto;
}

.spinner__icon.background
{
    background: none;
    filter: brightness(50%) blur(4px);
    height: 200px;
    position: absolute;
    width: 200px;
}

.spinner__icon.background img
{
    bottom: 0;
    height: 100%;
    left: 0;
    position: absolute;
    right: 0;
    top: 0;
    width: 100%;
}

.spinner__icon.background:after
{
    left: 100px;
}

.spinner__icon.background:before
{
    height: 200px;
    width: 200px;
}

.spinner__icon:after
{
    background-color: var(--color-accent);
    background-image: linear-gradient(to bottom, var(--color-white-translucent-25) 0%, var(--color-black-translucent-25) 100%);
    bottom: 0;
    content: '';
    left: 35px;
    position: absolute;
    top: 0;
    transform-origin: 100% 50%;
    transform: rotateY(-90deg);
    width: 5px;
}

.spinner__icon:before
{
    background-color: var(--color-accent);
    background-image: linear-gradient(to bottom, var(--color-white-translucent-25) 0%, var(--color-black-translucent-25) 100%);
    border-radius: 100%;
    content: '';
    height: 75px;
    left: 0;
    position: absolute;
    top: 0;
    transform: translateZ(-5px);
    width: 75px;
}

/* #spinner__logo
   ========================================================================== */

#spinner__logo
{
    animation: var(--animation-pulsating);
    background-image: url("../../images/logo-text.png");
    background-position: center;
    background-repeat: no-repeat;
    background-size: 50% auto;
    height: 60px;
    margin-bottom: 1rem;
    opacity: 1;
    pointer-events: auto;
    transition: opacity 600ms var(--timing-function-ease-in-out-quad), margin 600ms var(--timing-function-ease-in-out-quad);
    width: 320px;
}

.hide #spinner__logo
{
    margin: 2% 2% 25% 2%;
    opacity: 0;
    pointer-events: none;
}

.show #spinner__logo
{
    margin: 2% 2% 2% 2%;
    opacity: 1;
    pointer-events: auto;
}

/* #spinner__text
   ========================================================================== */

#spinner__text
{
    animation: var(--animation-shaking);
    color: var(--color-white);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol" !important;
    font-size: 1.25rem;
    font-weight: 500;
    margin-top: 2rem;
    opacity: 1;
    pointer-events: auto;
    text-align: center;
    text-transform: uppercase;
    transition: opacity 600ms var(--timing-function-ease-in-out-quad), margin 2400ms var(--timing-function-ease-in-out-quad);
    -webkit-font-smoothing: antialiased;
}

.hide #spinner__text
{
    margin: 2% 2% 0 2%;
    opacity: 0;
    pointer-events: none;
}

.show #spinner__text
{
    margin: 2% 2% 2% 2%;
    opacity: 1;
    pointer-events: auto;
}