@font-face {
    font-family: 'OSRegular';
    src: url('/fonts/OuroSafraRegular.otf') format('otf');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'OSLight';
    src: url('/fonts/OuroSafraLightr.otf') format('otf');
    font-weight: normal;
    font-style: normal;
}


.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    color: white;
    background: #df5959;
    bottom: 0;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

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

#update-notif-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(3px);
}

.update-notif-modal {
    background-color: #FFFFFF;
    border-radius: 12px;
    padding: 30px;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    animation: slideUp 0.3s ease-out forwards;
}

.update-notif-modal h3 {
    margin: 15px 0 10px;
    color: #212121;
    font-size: 1.25rem;
    font-weight: bold;
}

.update-notif-modal p {
    color: #757575;
    font-size: 0.95rem;
    margin-bottom: 24px;
    line-height: 1.5;
}

.update-notif-modal button {
    background-color: #FFC20E;
    color: #212121;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
    width: 100%;
    transition: background-color 0.2s;
    font-weight: bold;
}

.update-notif-modal button:hover {
    background-color: #e5ad0c;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDki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jEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

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

/* Custom loading wrapper */
.loading-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: radial-gradient(circle at center, #1b1b1f 0%, #0d0d0f 100%);
    font-family: Helvetica, Arial, sans-serif;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.35s cubic-bezier(0.25, 1, 0.5, 1);
}

.loading-wrapper.fade-out {
    opacity: 0;
    pointer-events: none;
}

/* Glassmorphism Card container */
.loading-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: rgba(30, 30, 35, 0.45);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 28px;
    padding: 3rem 2.5rem;
    width: 320px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5), 
                inset 0 1px 1px rgba(255, 255, 255, 0.1);
    animation: loadingFadeIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Centralized logo and SVG progress */
.logo-container {
    position: relative;
    width: 180px;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.loading-logo {
    width: 80px;
    height: 80px;
    object-fit: contain;
    z-index: 2;
    animation: logoPulse 2.5s ease-in-out infinite;
}

/* SVG progress bar wrapper */
.loading-progress {
    position: absolute;
    top: 0;
    left: 0;
    width: 180px;
    height: 180px;
    z-index: 1;
}

.loading-progress circle {
    fill: none;
    stroke: rgba(255, 255, 255, 0.05);
    stroke-width: 5px;
    transform-origin: 50% 50%;
    transform: rotate(-90deg);
}

.loading-progress circle:last-child {
    stroke: #ffc20f;
    stroke-width: 5px;
    stroke-linecap: round;
    stroke-dasharray: calc(3.141 * var(--display-percentage, 0%) * 0.8), 500%;
    filter: drop-shadow(0 0 6px rgba(255, 194, 15, 0.5));
    transition: stroke-dasharray 0.1s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Info container below the progress */
.loading-info {
    text-align: center;
    color: #ffffff;
}

.loading-title {
    font-family: 'OSRegular';
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 4px 0;
    letter-spacing: 0.5px;
    color: #ffffff;
}

.loading-subtitle {
    font-family: 'OSLight';
    font-size: 0.9rem;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.6);
    margin: 0 0 1rem 0;
    letter-spacing: 0.5px;
}

/* Percentage text styling */
.loading-progress-text {
    position: relative;
    font-family: 'OSLight';
    font-size: 1.75rem;
    font-weight: 300;
    color: #ffc20f;
    text-shadow: 0 2px 10px rgba(255, 194, 15, 0.15);
}

/* File name container below percentage */
.loading-file-container {
    margin-top: 0.75rem;
    height: 1.5rem;
    overflow: hidden;
}

.loading-file-name {
    font-size: 0.72rem;
    color: rgba(255, 194, 15, 0.65);
    font-family:'OSLight';
    display: inline-block;
    white-space: nowrap;
    text-overflow: ellipsis;
    max-width: 240px;
    animation: fileFadeIn 0.3s ease-out;
    letter-spacing: -0.2px;
}

@keyframes fileFadeIn {
    from {
        opacity: 0;
        transform: translateY(4px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Error UI Styling */
.loading-error-container {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border-top: 1px solid rgba(255, 51, 51, 0.15);
    padding-top: 1.5rem;
    animation: loadingFadeIn 0.4s ease-out;
}

.loading-error-container .error-icon {
    font-size: 2.5rem;
    color: #ff3333;
    margin-bottom: 0.5rem;
    filter: drop-shadow(0 0 4px rgba(255, 51, 51, 0.4));
}

.loading-error-container h3 {
    font-family: 'OSLight';
    color: #ff3333;
    font-size: 0.95rem;
    margin: 0 0 0.5rem 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.loading-error-container p {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.4;
    margin: 0 0 1.25rem 0;
}

.error-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    width: 100%;
}

.loading-error-container .retry-button {
    background-color: #ff3333;
    color: #ffffff;
    border: none;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
    flex: 1;
}

.loading-error-container .retry-button:hover {
    background-color: #e62e2e;
}

.loading-error-container .retry-button:active,
.loading-error-container .clear-cache-button:active {
    transform: scale(0.97);
}

.loading-error-container .clear-cache-button {
    background-color: transparent;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s, transform 0.1s;
    flex: 1;
}

.loading-error-container .clear-cache-button:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.4);
}

/* Red error progress ring state */
.loading-card.error-state .loading-progress circle:last-child {
    stroke: #ff3333;
    filter: drop-shadow(0 0 6px rgba(255, 51, 51, 0.5));
}

.loading-card.error-state .loading-progress-text {
    color: #ff3333;
    text-shadow: 0 2px 10px rgba(255, 51, 51, 0.2);
}

/* Keyframes */
@keyframes loadingFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

@keyframes logoPulse {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 0 2px rgba(255, 194, 15, 0.1));
    }
    50% {
        transform: scale(1.04);
        filter: drop-shadow(0 0 8px rgba(255, 194, 15, 0.3));
    }
}

code {
    color: #c02d76;
}

