/* ═══════════════════════════════════════════════════════════════
   Funguka AppLoader — matches mobile AppLoader.tsx
   Outer ring spins clockwise, inner ring spins opposite,
   brand-blue circle pulses with WiLDAF logo inside.
   ═══════════════════════════════════════════════════════════════ */

.fg-loader-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .42);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  transition: opacity .2s ease;
}
.fg-loader-overlay.is-visible {
  display: flex;
  opacity: 1;
}

.fg-loader {
  position: relative;
  width: 96px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Outer arc — clockwise, 1.1s/turn */
.fg-loader::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 5px solid #1D3F8F;
  border-top-color: transparent;
  border-right-color: rgba(29, 63, 143, .33);
  animation: fg-spin 1.1s linear infinite;
}

/* Inner arc — counter-clockwise, 1.7s/turn */
.fg-loader::after {
  content: "";
  position: absolute;
  width: 68px;
  height: 68px;
  border-radius: 50%;
  border: 4px solid transparent;
  border-bottom-color: rgba(29, 63, 143, .55);
  border-left-color: rgba(29, 63, 143, .27);
  animation: fg-spin-rev 1.7s linear infinite;
}

/* Pulsing brand circle with logo */
.fg-loader-core {
  position: relative;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: #1D3F8F;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .25);
  animation: fg-pulse 1.4s ease-in-out infinite;
  z-index: 1;
}
.fg-loader-core img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

/* Inline variant (no overlay) — drop inside cards while refreshing */
.fg-loader.fg-loader-sm { width: 56px; height: 56px; }
.fg-loader.fg-loader-sm::before { border-width: 3px; }
.fg-loader.fg-loader-sm::after { width: 38px; height: 38px; border-width: 2.5px; }
.fg-loader.fg-loader-sm .fg-loader-core { width: 28px; height: 28px; }
.fg-loader.fg-loader-sm .fg-loader-core img { width: 20px; height: 20px; }

@keyframes fg-spin {
  to { transform: rotate(360deg); }
}
@keyframes fg-spin-rev {
  to { transform: rotate(-360deg); }
}
@keyframes fg-pulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.08); }
}
