/**
 * Loading indicator styles.
 *  - .style-coin-flip  : full-page loader (CoinSpinLoader)
 *  - .style-cloud-star : in-page loader (LoadingContainer)
 */

/* Logo sizing for both indicators */
.style-coin-flip img,
.style-cloud-star img {
  object-fit: contain;
  display: block;
  user-select: none;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .style-coin-flip *,
  .style-cloud-star,
  .style-cloud-star::after {
    animation-duration: 3s !important;
  }
}

/* ========================================================
   Style 1: Cloud Edge Orbit (Borderless - Star traces the cloud silhouette itself)
   ======================================================== */
.style-cloud-star {
  position: relative;
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 24px;
}

.style-cloud-star img {
  width: 38px !important;
  height: 24px !important;
  filter: drop-shadow(0 2px 8px rgba(37, 99, 235, 0.35));
}

/* The 4-point AI Star physically tracing the cloud curves & lobes */
.style-cloud-star::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 6.5px; /* orbiting star, 1/2 of the original 13px */
  height: 6.5px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2338bdf8'%3E%3Cpath d='M12 0L14.8 9.2L24 12L14.8 14.8L12 24L9.2 14.8L0 12L9.2 9.2z'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  filter: drop-shadow(0 0 6px #38bdf8) drop-shadow(0 0 2px #fff);
  /* Traces the exact pixel contour of the FileEazy cloud logo */
  offset-path: path("M 37.4 13.9 C 37.72 14.67, 37.85 15.48, 37.9 16.3 C 37.95 17.12, 37.92 18, 37.7 18.8 C 37.48 19.6, 37.08 20.43, 36.6 21.1 C 36.12 21.77, 35.52 22.35, 34.8 22.8 C 34.08 23.25, 33.2 23.62, 32.3 23.8 C 31.4 23.98, 30.27 23.88, 29.4 23.9 C 28.53 23.92, 27.8 23.9, 27.1 23.9 C 26.4 23.9, 25.78 23.9, 25.2 23.9 C 24.62 23.9, 24.12 23.9, 23.6 23.9 C 23.08 23.9, 22.58 23.9, 22.1 23.9 C 21.62 23.9, 21.15 23.9, 20.7 23.9 C 20.25 23.9, 19.83 23.9, 19.4 23.9 C 18.97 23.9, 18.55 23.9, 18.1 23.9 C 17.65 23.9, 17.17 23.9, 16.7 23.9 C 16.23 23.9, 15.82 23.9, 15.3 23.9 C 14.78 23.9, 14.2 23.9, 13.6 23.9 C 13 23.9, 12.4 23.9, 11.7 23.9 C 11 23.9, 10.27 23.9, 9.4 23.9 C 8.53 23.9, 7.47 24.03, 6.5 23.9 C 5.53 23.77, 4.43 23.53, 3.6 23.1 C 2.77 22.67, 2.05 21.98, 1.5 21.3 C 0.95 20.62, 0.55 19.82, 0.3 19 C 0.05 18.18, -0.1 17.25, 0 16.4 C 0.1 15.55, 0.45 14.7, 0.9 13.9 C 1.35 13.1, 1.9 12.23, 2.7 11.6 C 3.5 10.97, 5.2 10.68, 5.7 10.1 C 6.2 9.52, 5.55 8.72, 5.7 8.1 C 5.85 7.48, 6.2 6.9, 6.6 6.4 C 7 5.9, 7.52 5.43, 8.1 5.1 C 8.68 4.77, 9.4 4.48, 10.1 4.4 C 10.8 4.32, 11.62 4.53, 12.3 4.6 C 12.98 4.67, 13.73 5, 14.2 4.8 C 14.67 4.6, 14.75 3.82, 15.1 3.4 C 15.45 2.98, 15.85 2.65, 16.3 2.3 C 16.75 1.95, 17.28 1.58, 17.8 1.3 C 18.32 1.02, 18.83 0.8, 19.4 0.6 C 19.97 0.4, 20.58 0.2, 21.2 0.1 C 21.82 0, 22.47 -0.02, 23.1 0 C 23.73 0.02, 24.38 0.05, 25 0.2 C 25.62 0.35, 26.2 0.63, 26.8 0.9 C 27.4 1.17, 28.05 1.43, 28.6 1.8 C 29.15 2.17, 29.65 2.62, 30.1 3.1 C 30.55 3.58, 30.97 4.13, 31.3 4.7 C 31.63 5.27, 31.9 5.88, 32.1 6.5 C 32.3 7.12, 32.23 7.82, 32.5 8.4 C 32.77 8.98, 33.12 9.45, 33.7 10 C 34.28 10.55, 35.38 11.05, 36 11.7 C 36.62 12.35, 37.08 13.13, 37.4 13.9 Z");
  offset-rotate: 0deg;
  animation: fe-star-trace 2.4s linear infinite;
}

@keyframes fe-star-trace {
  0%   { offset-distance: 0%; }
  100% { offset-distance: 100%; }
}

/* ========================================================
   Style 3: Coin Spin (Thicker Ring, Butter-Smooth 3D Spin)
   ======================================================== */
.style-coin-flip {
  position: relative;
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 3.5px solid #3b82f6; /* Thicker, bolder coin ring */
  border-radius: 50%;
  box-sizing: border-box;
  box-shadow: 0 0 16px rgba(59, 130, 246, 0.45), inset 0 0 6px rgba(59, 130, 246, 0.3);
  background: rgba(9, 13, 22, 0.75);
  perspective: 500px; /* Natural 3D depth */
}

.style-coin-flip img {
  width: 27px !important;
  height: 17px !important;
  animation: fe-coin-spin-smooth 1.4s linear infinite; /* Seamless, continuous rotation */
  transform-style: preserve-3d;
  backface-visibility: visible;
  will-change: transform, filter;
}

@keyframes fe-coin-spin-smooth {
  0% {
    transform: rotateY(0deg);
    filter: brightness(1);
  }
  25% {
    transform: rotateY(90deg);
    filter: brightness(0.82);
  }
  50% {
    transform: rotateY(180deg);
    filter: brightness(1);
  }
  75% {
    transform: rotateY(270deg);
    filter: brightness(0.82);
  }
  100% {
    transform: rotateY(360deg);
    filter: brightness(1);
  }
}

