#app-loader {
    position: fixed;
    inset: 0;
    z-index: 20000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.45);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.15s ease, visibility 0.15s ease;
}

#app-loader.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.app-loader-box {
    min-width: 220px;
    max-width: 90vw;
    padding: 1.5rem 1.75rem;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
    text-align: center;
}

.app-loader-spinner {
    width: 42px;
    height: 42px;
    margin: 0 auto 0.85rem;
    border: 4px solid #dbe4f0;
    border-top-color: #0d6efd;
    border-radius: 50%;
    animation: app-loader-spin 0.75s linear infinite;
}

.app-loader-title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 600;
    color: #1e293b;
}

.app-loader-text {
    margin: 0.35rem 0 0;
    font-size: 0.9rem;
    color: #64748b;
}

body.dark-mode .app-loader-box,
.dark-mode .app-loader-box {
    background: #1e293b;
}

body.dark-mode .app-loader-title,
.dark-mode .app-loader-title {
    color: #f8fafc;
}

body.dark-mode .app-loader-text,
.dark-mode .app-loader-text {
    color: #cbd5e1;
}

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