h1:focus {
    outline: none;
}

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

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

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

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}
/* Anmeldeseiten (statisch gerendert, ohne MudBlazor-Komponenten) */
.ong-auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
    font-family: Roboto, Arial, sans-serif;
    padding: 16px;
    box-sizing: border-box;
}

.ong-auth-card {
    position: relative;
    width: 100%;
    max-width: 380px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    padding: 24px;
    box-sizing: border-box;
}

.ong-auth-title {
    color: #594ae2;
    font-weight: 500;
    margin-bottom: 8px;
}

.ong-auth-card h1 {
    font-size: 1.5rem;
    font-weight: 400;
    margin: 0 0 16px 0;
}

.ong-auth-card form {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ong-auth-card input {
    padding: 8px 10px;
    border: 1px solid #bdbdbd;
    border-radius: 4px;
    font-size: 1rem;
    margin-bottom: 8px;
}

.ong-auth-card button[type=submit]:not(.ong-link-button) {
    margin-top: 8px;
    padding: 10px;
    border: none;
    border-radius: 4px;
    background: #594ae2;
    color: #fff;
    font-size: 1rem;
    cursor: pointer;
}

.ong-auth-error {
    background: #fdecea;
    color: #b71c1c;
    border-radius: 4px;
    padding: 8px 10px;
    margin-bottom: 12px;
}

.ong-auth-secondary {
    margin-top: 16px;
    align-items: flex-end;
}

/* Erfolgsmeldung (z. B. „Mandant angelegt“ nach der Registrierung) und Feldhinweise der Konto-Seiten. */
.ong-auth-info {
    background: #e8f5e9;
    color: #1b5e20;
    border-radius: 4px;
    padding: 8px 10px;
    margin-bottom: 12px;
}

.ong-auth-hint {
    color: #757575;
    font-size: 0.8rem;
    margin: -6px 0 8px 0;
}

/* Warte-Animation beim Absenden der Konto-Formulare (AuthWaitOverlay.razor, login.js): Komet mit Kopf auf einem Ring, zwei
   gegenläufige Punkte, pulsierender Kern – wie der ActivitySpinner des Designers, in der Farbe des Orchestrators. Nach 3 s ohne
   Antwort (.ong-auth-wait-slow, Kaltstart der Service-API) ruhigere Gangart: langsamer, atmender Kern, Sonar-Ring. */
.ong-auth-wait {
    position: absolute;
    inset: 0;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 24px;
    box-sizing: border-box;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.94);
    text-align: center;
    animation: ong-auth-fade-in 0.2s ease-out;
}

.ong-auth-wait[hidden] {
    display: none;
}

.ong-auth-wait-text {
    color: #424242;
    max-width: 290px;
    line-height: 1.4;
}

.ong-auth-wait-seconds {
    color: #757575;
    font-size: 0.85rem;
    font-variant-numeric: tabular-nums;
    min-height: 1.2em;
}

.ong-spinner {
    position: relative;
    width: 56px;
    height: 56px;
}

.ong-spinner > span {
    position: absolute;
    border-radius: 50%;
    box-sizing: border-box;
}

.ong-spinner-track {
    inset: 4px;
    border: 4px solid rgba(89, 74, 226, 0.14);
}

/* Komet: Verlauf bis zum Kopf bei 120°, als Ring ausgestanzt */
.ong-spinner-comet {
    inset: 4px;
    background: conic-gradient(from 0deg, rgba(89, 74, 226, 0) 0deg, rgba(89, 74, 226, 0.25) 60deg, #594ae2 120deg, rgba(89, 74, 226, 0) 120.5deg);
    -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 4px));
    mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 4px));
    animation: ong-spin 1s linear infinite;
}

/* Kopf des Kometen: Mitte (24, 24), Radius 22, 120° im Uhrzeigersinn ab 12 Uhr */
.ong-spinner-head {
    inset: 4px;
    animation: ong-spin 1s linear infinite;
}

.ong-spinner-head::after {
    content: '';
    position: absolute;
    left: 39px;
    top: 31px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #594ae2;
    box-shadow: 0 0 8px rgba(89, 74, 226, 0.8);
}

.ong-spinner-orbit {
    inset: 14px;
    animation: ong-spin-reverse 1.6s linear infinite;
}

.ong-spinner-orbit i {
    position: absolute;
    left: 50%;
    width: 6px;
    height: 6px;
    margin-left: -3px;
    border-radius: 50%;
    background: #7b6ff0;
}

.ong-spinner-orbit i:first-child {
    top: 0;
    opacity: 0.9;
}

.ong-spinner-orbit i:last-child {
    bottom: 0;
    opacity: 0.45;
}

.ong-spinner-core {
    inset: 23px;
    background: #594ae2;
    animation: ong-pulse 1s ease-in-out infinite alternate;
}

.ong-spinner-halo {
    inset: 1px;
    border: 2px solid #594ae2;
    opacity: 0;
}

.ong-auth-wait-slow .ong-spinner-comet,
.ong-auth-wait-slow .ong-spinner-head {
    animation-duration: 2.4s;
}

.ong-auth-wait-slow .ong-spinner-orbit {
    animation-duration: 4.8s;
}

.ong-auth-wait-slow .ong-spinner-core {
    animation: ong-breathe 2.4s ease-in-out infinite alternate;
}

.ong-auth-wait-slow .ong-spinner-halo {
    animation: ong-sonar 2.4s cubic-bezier(0.2, 0.6, 0.4, 1) infinite;
}

@keyframes ong-spin {
    to { transform: rotate(360deg); }
}

@keyframes ong-spin-reverse {
    to { transform: rotate(-360deg); }
}

@keyframes ong-pulse {
    from { transform: scale(0.7); }
    to { transform: scale(1.15); }
}

@keyframes ong-breathe {
    from { transform: scale(0.55); opacity: 0.55; }
    to { transform: scale(1.5); opacity: 1; }
}

@keyframes ong-sonar {
    from { transform: scale(0.45); opacity: 0.7; }
    to { transform: scale(1.15); opacity: 0; }
}

@keyframes ong-auth-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
    .ong-spinner-comet,
    .ong-spinner-head,
    .ong-spinner-orbit,
    .ong-auth-wait-slow .ong-spinner-halo {
        animation: none;
    }
}

.ong-auth-card a {
    color: #594ae2;
    font-size: 0.9rem;
}

.ong-link-button {
    background: none;
    border: none;
    color: #594ae2;
    cursor: pointer;
    padding: 0;
    font-size: 0.9rem;
}

.ong-auth-card p {
    margin: 0 0 12px 0;
}

/* Mandanten-Wechsler in der Kopfzeile (TenantSwitcher): natives select, damit der Formular-POST ohne JS-Interop geht. */
.ong-tenant-switcher {
    display: inline-flex;
    align-items: center;
    margin-right: 16px;
}

.ong-tenant-switcher select {
    background: rgba(255, 255, 255, 0.15);
    color: inherit;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 4px;
    padding: 4px 8px;
    font: inherit;
}

.ong-tenant-switcher select option {
    color: #000;
}
