﻿/* Loading animation styles that don't need to be processed by Tailwind */
/* These are separate to ensure they're always available immediately */

#blazor-error-ui {
    display: none;
}

.loading-progress {
    position: relative;
    display: block;
    width: 8rem;
    height: 8rem;
    margin: 1.25rem auto;
}

    .loading-progress circle {
        fill: none;
        stroke-width: 0.3rem;
        stroke-linecap: round;
        transform-origin: 50% 50%;
    }

        .loading-progress circle:first-child {
            stroke: rgba(148, 0, 211, 0.15); /* Purple with low opacity */
        }

        .loading-progress circle:last-child {
            stroke: #9400D3; /* Primary purple */
            stroke-dasharray: 100;
            stroke-dashoffset: 0;
            transform: rotate(-90deg);
            animation: loading-progress-circle 1.5s ease-in-out infinite;
            transition: stroke-dashoffset 0.35s;
        }

@media (prefers-reduced-motion: reduce) {
    .loading-progress circle:last-child {
        animation: none;
        stroke-dashoffset: 0;
    }
}

@keyframes loading-progress-circle {
    0% {
        stroke-dashoffset: 100;
        transform: rotate(-90deg);
    }

    50% {
        stroke-dashoffset: 0;
        transform: rotate(90deg);
    }

    100% {
        stroke-dashoffset: 100;
        transform: rotate(270deg);
    }
}

.loading-progress-text {
    font-weight: bold;
    text-align: center;
    color: #9400D3;
    font-size: 1.25rem;
    line-height: 1.5rem;
    font-family: 'Arial', sans-serif;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "");
    }

/* Hide calendar emoji when loading is active */
.loading-active .calendar-emoji {
    display: none;
}

/* Show calendar emoji after loading is complete */
.loading-complete .calendar-emoji {
    display: inline-block;
    animation: calendar-appear 0.5s ease-in-out forwards;
}

@keyframes calendar-appear {
    0% {
        opacity: 0;
        transform: scale(0.5);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}
