/* Branded first paint shell — shown before React hydrates #root */

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background: #fffaf0;
  color: #68766d;
  font-family: Outfit, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html.dark body {
  background: #121018;
  color: #b8c0bc;
}

#root {
  min-height: 100vh;
  min-height: 100dvh;
}

.he-initial-loader {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 2rem;
  text-align: center;
  box-sizing: border-box;
}

.he-initial-loader__mark {
  width: 88px;
  height: auto;
  animation: he-shell-float 1.8s ease-in-out infinite;
}

.he-initial-loader__brand {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #8c57f5;
}

html.dark .he-initial-loader__brand {
  color: #c4b5fd;
}

.he-initial-loader__message {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.5;
  max-width: 20rem;
}

.he-initial-loader__bar {
  width: min(220px, 70vw);
  height: 4px;
  border-radius: 999px;
  background: rgba(140, 87, 245, 0.16);
  overflow: hidden;
}

html.dark .he-initial-loader__bar {
  background: rgba(196, 181, 253, 0.18);
}

.he-initial-loader__bar span {
  display: block;
  width: 42%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #8c57f5, #c084fc);
  animation: he-shell-progress 1.2s ease-in-out infinite;
}

.he-initial-loader__hint {
  margin: 0.25rem 0 0;
  font-size: 0.75rem;
  opacity: 0.72;
}

@keyframes he-shell-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

@keyframes he-shell-progress {
  0% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(260%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .he-initial-loader__mark,
  .he-initial-loader__bar span {
    animation: none;
  }
}

.he-noscript-fallback {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
  background: #fffaf0;
  color: #4b5563;
}

html.dark .he-noscript-fallback {
  background: #121018;
  color: #d1d5db;
}
