/**
 * Billing (and future) async blocks: discrete dark skeleton + short content reveal.
 * Low-contrast shimmer; prefers-reduced-motion disables motion.
 */

.ml-skeleton-stack {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 0.1rem 0;
}

.ml-skeleton-line {
  height: 0.62rem;
  border-radius: var(--radius-sm, 8px);
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.04) 0%,
    rgba(255, 255, 255, 0.075) 48%,
    rgba(255, 255, 255, 0.04) 100%
  );
  background-size: 200% 100%;
  animation: ml-skeleton-shimmer 1.35s ease-in-out infinite;
}

.ml-skeleton-line--lg {
  width: 74%;
}
.ml-skeleton-line--md {
  width: 52%;
  height: 0.55rem;
}
.ml-skeleton-line--sm {
  width: 36%;
  height: 0.5rem;
  opacity: 0.88;
}

.ml-skeleton-plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(158px, 1fr));
  gap: 0.85rem;
}

.ml-skeleton-plan-card {
  min-height: 164px;
  border-radius: var(--radius-md, 12px);
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.035) 0%,
    rgba(255, 255, 255, 0.065) 50%,
    rgba(255, 255, 255, 0.035) 100%
  );
  background-size: 200% 200%;
  animation: ml-skeleton-shimmer 1.35s ease-in-out infinite;
}

.ml-skeleton-topups {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.ml-skeleton-topups__pill {
  height: 2.32rem;
  min-width: 8.5rem;
  border-radius: var(--radius-pill, 999px);
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.045) 0%,
    rgba(255, 255, 255, 0.08) 46%,
    rgba(255, 255, 255, 0.045) 100%
  );
  background-size: 200% 100%;
  animation: ml-skeleton-shimmer 1.35s ease-in-out infinite;
}

.ml-skeleton-tx {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.ml-skeleton-tx__row {
  display: grid;
  grid-template-columns: 1fr 1.35fr 0.72fr 1fr;
  gap: 0.5rem;
  align-items: center;
}

@media (max-width: 768px) {
  .ml-skeleton-tx__row {
    grid-template-columns: 1fr 1fr;
  }
}

.ml-skeleton-tx__cell {
  height: 0.6rem;
  border-radius: 6px;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.038) 0%,
    rgba(255, 255, 255, 0.078) 46%,
    rgba(255, 255, 255, 0.038) 100%
  );
  background-size: 200% 100%;
  animation: ml-skeleton-shimmer 1.35s ease-in-out infinite;
}

@keyframes ml-skeleton-shimmer {
  0% {
    background-position: 100% 50%;
  }
  100% {
    background-position: -100% 50%;
  }
}

@keyframes ml-content-fade-in {
  from {
    opacity: 0;
    transform: translateY(3px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.ml-content-fade-in {
  animation: ml-content-fade-in 0.19s ease-out forwards;
}

@media (prefers-reduced-motion: reduce) {
  .ml-skeleton-line,
  .ml-skeleton-plan-card,
  .ml-skeleton-topups__pill,
  .ml-skeleton-tx__cell {
    animation: none;
    background: rgba(255, 255, 255, 0.055);
    background-size: 100% 100%;
  }

  .ml-content-fade-in {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
