/* Blazor's own built-in furniture only. Everything else the editor draws comes from the shared
   stylesheet (_content/AbioticEditor.Web.Shared/parity.css), which is what keeps the browser
   build looking identical to the desktop app.

   This file must stay linked from index.html. Without it #blazor-error-ui has no rule hiding it,
   so the "an unhandled error has occurred" bar - which is plain markup that is always in the
   page and only meant to be revealed by Blazor when something actually fails - flashes up on
   every single load. */

#blazor-error-ui {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 0.6rem 1.25rem;
    background: #2a1410;
    color: #ffd9c9;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.5);
    color-scheme: dark only;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    padding: 1rem;
    background: #b32121;
    color: #fff;
}

    .blazor-error-boundary::after {
        content: "An error has occurred.";
    }

/* Startup spinner, shown until the runtime has booted. */
.loading-progress {
    position: absolute;
    display: block;
    width: 8rem;
    height: 8rem;
    inset: 20vh 0 auto 0;
    margin: 0 auto;
}

    .loading-progress circle {
        fill: none;
        stroke: #1d3a49;
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: #f0862c;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
    color: #90a9b7;
    font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }
