/* Splash / preloader — alineado con home & workspace-home (dark hero) */

.bondi-splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  overflow: hidden;
  min-height: 100dvh;
  height: 100dvh;
  box-sizing: border-box;
  font-family: 'Inter', 'DM Sans', system-ui, sans-serif;
  background: #0f172a;
  color: #f8fafc;
  transition: opacity 0.28s ease;
}

.bondi-splash--app {
  z-index: 9998;
}

.bondi-splash.fade-out {
  opacity: 0;
  pointer-events: none;
}

.bondi-splash__hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.bondi-splash__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(99, 102, 241, 0.06) 1px, transparent 1px),
    linear-gradient(to right, rgba(99, 102, 241, 0.06) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 30%, #000 10%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 90% 80% at 50% 30%, #000 10%, transparent 70%);
}

.bondi-splash__glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
}

.bondi-splash__glow--purple {
  width: min(900px, 120vw);
  height: min(900px, 120vw);
  top: -300px;
  right: -50px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.22) 0%, transparent 65%);
  animation: bondi-splash-orb 18s ease-in-out infinite;
}

.bondi-splash__glow--pink {
  width: min(600px, 90vw);
  height: min(600px, 90vw);
  bottom: -100px;
  left: -80px;
  background: radial-gradient(circle, rgba(255, 141, 161, 0.16) 0%, transparent 65%);
  animation: bondi-splash-orb 24s ease-in-out infinite reverse;
}

.bondi-splash__glow--blue {
  width: min(500px, 80vw);
  height: min(500px, 80vw);
  top: 40%;
  left: 20%;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.12) 0%, transparent 65%);
  animation: bondi-splash-orb 20s ease-in-out 4s infinite;
}

@keyframes bondi-splash-orb {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(20px, -24px) scale(1.04); }
  66% { transform: translate(-18px, 16px) scale(0.97); }
}

.bondi-splash__brand {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  animation: bondi-splash-logo-in 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.bondi-splash__mark {
  display: block;
  width: clamp(44px, 12vw, 56px);
  height: clamp(44px, 12vw, 56px);
  filter: drop-shadow(0 10px 32px rgba(99, 102, 241, 0.4));
}

.bondi-splash__word {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: clamp(22px, 5vw, 28px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1;
  color: #f8fafc;
}

.bondi-splash__logo {
  position: relative;
  z-index: 1;
  display: block;
  width: auto;
  height: clamp(28px, 7vw, 40px);
  max-width: min(148px, 42vw);
  animation: bondi-splash-logo-in 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
  filter: drop-shadow(0 8px 28px rgba(99, 102, 241, 0.35));
}

@keyframes bondi-splash-logo-in {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.96);
    filter: blur(6px) drop-shadow(0 8px 28px rgba(99, 102, 241, 0.35));
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0) drop-shadow(0 8px 28px rgba(99, 102, 241, 0.35));
  }
}

.bondi-splash__track {
  position: relative;
  z-index: 1;
  width: 180px;
  height: 3px;
  background: rgba(99, 102, 241, 0.18);
  border-radius: 999px;
  overflow: hidden;
}

.bondi-splash__bar {
  height: 100%;
  width: 45%;
  border-radius: 999px;
  background: linear-gradient(90deg, #6366f1, #ff8da1);
  animation: bondi-splash-bar 1.3s ease-in-out infinite;
}

@keyframes bondi-splash-bar {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(320%); }
}

.bondi-splash__text {
  position: relative;
  z-index: 1;
  margin: 0;
  min-height: 21px;
  line-height: 1.5;
  text-align: center;
  color: rgba(248, 250, 252, 0.62);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

@media (prefers-reduced-motion: reduce) {
  .bondi-splash__glow {
    animation: none;
  }

  .bondi-splash__logo {
    animation: none;
  }

  .bondi-splash__bar {
    animation: none;
    transform: translateX(0);
    width: 60%;
    margin: 0 auto;
  }
}
