/* Branded working state for long-running provider/API operations. */
.working-overlay {
  position: fixed;
  inset: 0;
  z-index: 1400;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(247, 248, 250, .82);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.working-overlay[hidden] { display: none; }

.working-card {
  width: min(390px, calc(100vw - 40px));
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 28px 30px 26px;
  background: var(--cs-surface, #fff);
  border: 1px solid var(--cs-border, #E3E6EC);
  border-radius: var(--cs-radius-lg, 16px);
  box-shadow: 0 24px 70px rgba(21, 24, 34, .14);
  text-align: center;
}

.working-mark {
  position: relative;
  width: 70px;
  height: 70px;
  display: grid;
  place-items: center;
  margin-bottom: 2px;
}

.working-mark::before,
.working-mark::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 999px;
}

.working-mark::before {
  border: 2px solid rgba(91, 92, 226, .14);
  border-top-color: var(--cs-indigo, #5B5CE2);
  border-right-color: rgba(119, 120, 255, .55);
  animation: commonset-working-orbit 1.35s linear infinite;
}

.working-mark::after {
  inset: 8px;
  background: rgba(91, 92, 226, .07);
  animation: commonset-working-halo 1.8s ease-in-out infinite;
}

.working-mark img {
  position: relative;
  z-index: 1;
  width: 42px;
  height: 42px;
  object-fit: contain;
  animation: commonset-working-breathe 1.8s ease-in-out infinite;
}

.working-title {
  margin: 0;
  color: var(--cs-ink, #151822);
  font-size: 18px;
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: -.01em;
}

.working-detail {
  margin: 0;
  max-width: 310px;
  color: var(--cs-slate, #667085);
  font-size: 13px;
  line-height: 1.5;
}

.working-dots {
  display: inline-flex;
  gap: 5px;
  height: 8px;
  margin-top: 2px;
}

.working-dots span {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--cs-indigo, #5B5CE2);
  opacity: .22;
  animation: commonset-working-dot 1.2s ease-in-out infinite;
}

.working-dots span:nth-child(2) { animation-delay: .16s; }
.working-dots span:nth-child(3) { animation-delay: .32s; }

body.is-working { overflow: hidden; }

@keyframes commonset-working-orbit {
  to { transform: rotate(360deg); }
}

@keyframes commonset-working-breathe {
  0%, 100% { transform: scale(.94); opacity: .82; }
  50% { transform: scale(1.04); opacity: 1; }
}

@keyframes commonset-working-halo {
  0%, 100% { transform: scale(.9); opacity: .45; }
  50% { transform: scale(1.08); opacity: .9; }
}

@keyframes commonset-working-dot {
  0%, 70%, 100% { transform: translateY(0); opacity: .22; }
  35% { transform: translateY(-3px); opacity: .9; }
}

@media (prefers-reduced-motion: reduce) {
  .working-mark::before,
  .working-mark::after,
  .working-mark img,
  .working-dots span {
    animation: none;
  }

  .working-mark::before {
    border-color: rgba(91, 92, 226, .28);
    border-top-color: var(--cs-indigo, #5B5CE2);
  }

  .working-mark img { opacity: 1; }
  .working-dots span { opacity: .55; }
}
