:root {
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: #f6f7fb;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue",
    "Segoe UI", sans-serif;
}

.loading-shell {
  width: min(420px, 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.emoji-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.emoji-card {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  border: 1px solid #d7dbe6;
  background: #eef2f8;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(31, 41, 55, 0.1);
  animation: float-card 1800ms ease-in-out infinite;
}

.emoji-card[data-index="1"] {
  animation-delay: 220ms;
}

.emoji-card[data-index="2"] {
  animation-delay: 440ms;
}

.emoji-card.switching {
  animation-name: float-card, switch-card;
  animation-duration: 1800ms, 560ms;
  animation-iteration-count: infinite, 1;
}

.emoji-card.switching[data-index="1"] {
  animation-delay: 220ms, 80ms;
}

.emoji-card.switching[data-index="2"] {
  animation-delay: 440ms, 160ms;
}

.emoji-text {
  font-size: 28px;
  line-height: 34px;
}

.loading-title {
  margin: 24px 0 0;
  font-size: 17px;
  line-height: 23px;
  font-weight: 700;
  color: #111827;
  text-align: center;
}

.loading-subtitle {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 18px;
  color: #6b7280;
  text-align: center;
}

.loading-fallback {
  margin: 14px 0 0;
  font-size: 12px;
  line-height: 18px;
  color: #9ca3af;
  text-align: center;
}

.loading-fallback a {
  color: #4b5563;
}

@keyframes float-card {
  0% {
    transform: translateY(4px) scale(0.94);
    opacity: 0.78;
  }
  50% {
    transform: translateY(-8px) scale(1.05);
    opacity: 1;
  }
  100% {
    transform: translateY(4px) scale(0.94);
    opacity: 0.78;
  }
}

@keyframes switch-card {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  39% {
    transform: scale(0.82);
    opacity: 0.24;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}
