.processing-overlay {
    position: absolute; inset: 0;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 1rem;
    background: rgba(10, 12, 15, 0.45);
    backdrop-filter: blur(2px);
    border-radius: 1rem;
    overflow: hidden;
    z-index: 5;
}

/* Balayage lumineux qui traverse l'image */
.processing-overlay::before {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(115deg, transparent 45%, rgba(130, 170, 255, 0.20) 50%, transparent 55%);
    background-repeat: no-repeat;
    background-size: 400% 100%;
    animation: ai-sweep 5s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}
@keyframes ai-sweep {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Anneau dégradé + cœur pulsant */
.ai-loader { position: relative; width: 76px; height: 76px; z-index: 2; }

.ai-ring {
    position: absolute; inset: 0; border-radius: 50%;
    background: conic-gradient(from 0deg, transparent 0deg, #0d6efd 130deg, #6610f2 250deg, transparent 360deg);
    -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 6px));
            mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 6px));
    animation: ai-spin 1s linear infinite;
    filter: drop-shadow(0 0 6px rgba(102, 16, 242, 0.5));
}
.ai-core {
    position: absolute; inset: 27px; border-radius: 50%;
    background: radial-gradient(circle, rgba(122, 168, 255, 0.95), rgba(102, 16, 242, 0.35));
    filter: blur(2px);
    animation: ai-pulse 1.4s ease-in-out infinite;
}
@keyframes ai-spin  { to { transform: rotate(360deg); } }
@keyframes ai-pulse { 0%, 100% { transform: scale(0.7); opacity: 0.55; } 50% { transform: scale(1.05); opacity: 1; } }

/* Label dégradé + points animés */
.ai-label {
    z-index: 2;
    font-weight: 600; font-size: 0.95rem; letter-spacing: 0.3px;
    background: linear-gradient(90deg, #7aa8ff, #b98cff);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.ai-dots::after {
    content: '';
    animation: ai-dots 1.4s steps(1, end) infinite;
}
@keyframes ai-dots {
    0% { content: ''; } 25% { content: '.'; } 50% { content: '..'; } 75% { content: '...'; }
}
