/* Minimal, app-specific loader */

.loader-overlay {
  position: fixed;
  top: var(--header-height, 64px);
  left: 0;
  right: 0;
  bottom: var(--footer-height, 72px);
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(6px);
  z-index: 9999;
}

.loader {
  width: 110px;
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    conic-gradient(from 90deg at 50% 50%, rgba(79,70,229,0.25), rgba(14,165,233,0.65), rgba(79,70,229,0.25));
  mask: radial-gradient(circle 48% at 50% 50%, transparent 60%, #000 61%);
  animation: spin 1s linear infinite;
  position: relative;
  box-shadow: 0 12px 32px rgba(15,23,42,0.18);
}

.loader::after {
  content: "";
  position: absolute;
  inset: 18%;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(226,232,240,0.9);
}

.loader-text {
  position: absolute;
  bottom: -42px;
  width: 200px;
  text-align: center;
  left: 50%;
  transform: translateX(-50%);
  font-size: 14px;
  color: #334155;
  letter-spacing: 0.01em;
}

.loader-steps {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
}

.loader-steps span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e2e8f0;
  animation: pulse 1.2s ease-in-out infinite;
}

.loader-steps span:nth-child(2) { animation-delay: 0.15s; }
.loader-steps span:nth-child(3) { animation-delay: 0.3s; }

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

@keyframes pulse {
  0%, 100% { transform: scale(0.9); background: #cbd5e1; }
  50%      { transform: scale(1.15); background: #6366f1; }
}

@media (prefers-reduced-motion: reduce) {
  .loader { animation: none; }
  .loader-steps span { animation: none; background: #cbd5e1; }
}
