/* Same loading structure as BI Full, using TicketFull theme tokens. */
.dashboard-refresh-region {
    position: relative;
}

.dashboard-refresh-region.is-refreshing {
    isolation: isolate;
    min-height: min(72vh, 48rem);
}

.dashboard-refresh-content {
    transition: opacity 180ms ease, filter 180ms ease;
}

.dashboard-refresh-region.is-refreshing .dashboard-refresh-content {
    opacity: 0.8;
    filter: blur(1px);
    pointer-events: none;
    user-select: none;
}

.dashboard-refresh-overlay {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    position: absolute;
    inset: 0;
    z-index: 12;
    padding: 0 20px 20px;
    background: color-mix(in srgb, var(--background-color) 35%, transparent);
    backdrop-filter: blur(2px);
}

.dashboard-refresh-status {
    display: flex;
    align-items: center;
    gap: 12px;
    position: sticky;
    top: calc(50vh - 32px);
    width: min(320px, 100%);
    min-height: 66px;
    margin-top: clamp(60px, 24vh, 190px);
    padding: 15px 20px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    color: var(--text-primary);
    background: var(--surface-color);
    box-shadow: var(--shadow-lg);
}

.dashboard-refresh-status > strong {
    font-size: 12px;
}

.dashboard-refresh-spinner {
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
    border: 2px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: dashboard-refresh-spin 0.75s linear infinite;
}

.dashboard-refresh-progress {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 3px;
    overflow: hidden;
    background: var(--muted-bg);
}

.dashboard-refresh-progress i {
    display: block;
    width: 42%;
    height: 100%;
    background: var(--primary-color);
    animation: dashboard-refresh-progress 1.2s ease-in-out infinite;
}

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

@keyframes dashboard-refresh-progress {
    from {
        transform: translateX(-115%);
    }
    to {
        transform: translateX(340%);
    }
}

@media (prefers-reduced-motion: reduce) {
    .dashboard-refresh-content {
        transition: none;
    }

    .dashboard-refresh-spinner,
    .dashboard-refresh-progress i {
        animation: none;
    }
}
