#app-splash {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  pointer-events: none;
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

#app-splash.app-splash--out {
  opacity: 0;
  visibility: hidden;
}

.app-splash__gradient {
  position: absolute;
  inset: 0;
  background: #ffffff;
}

.app-splash__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: max(1.5rem, env(safe-area-inset-top)) 1.5rem max(1.5rem, env(safe-area-inset-bottom));
}

.app-splash__logo-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 120px;
  animation: appSplashLogoIn 0.85s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.app-splash__logo-img {
  max-width: min(220px, 72vw);
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.08));
}

.app-splash__logo-fallback {
  display: none;
  width: 120px;
  height: 120px;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.08));
  animation: appSplashFloat 2.2s ease-in-out infinite;
}

.app-splash__logo-wrap--fallback .app-splash__logo-img {
  display: none;
}

.app-splash__logo-wrap--fallback .app-splash__logo-fallback {
  display: block;
}

.app-splash__brand {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #0f172a;
  opacity: 0;
  animation: appSplashFadeUp 0.6s ease 0.25s forwards;
}

.app-splash__pulse {
  width: 40px;
  height: 3px;
  border-radius: 999px;
  background: #f1f5f9;
  overflow: hidden;
  margin-top: 0.25rem;
}

.app-splash__pulse::after {
  content: "";
  display: block;
  height: 100%;
  width: 40%;
  border-radius: inherit;
  background: #ea580c;
  animation: appSplashPulse 1.1s ease-in-out infinite;
}

@keyframes appSplashLogoIn {
  from {
    opacity: 0;
    transform: scale(0.88) translateY(8px);
  }

  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@keyframes appSplashFadeUp {
  from {
    opacity: 0;
    transform: translateY(6px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes appSplashFloat {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-6px);
  }
}

@keyframes appSplashPulse {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(280%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .app-splash__logo-wrap,
  .app-splash__brand,
  .app-splash__logo-fallback,
  .app-splash__pulse::after {
    animation: none !important;
  }

  .app-splash__brand {
    opacity: 1;
  }
}
