:root {
  color-scheme: dark;
  --brand-primary: #0b66d0;
  --brand-secondary: #063a82;
  --glass-bg: rgba(8, 22, 48, 0.38);
  --glass-border: rgba(255, 255, 255, 0.12);
  --glow-color: rgba(31, 129, 255, 0.35);
}

body {
  background: radial-gradient(
      circle at top left,
      rgba(17, 102, 255, 0.12),
      transparent 45%
    ),
    #030b1a;
  min-height: 100vh;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: #f4fbff;
}

.animated-gradient {
  position: relative;
  overflow: hidden;
}

.animated-gradient::after {
  content: "";
  position: absolute;
  inset: -120%;
  background: radial-gradient(
      circle at 20% 20%,
      rgba(0, 253, 251, 0.25),
      transparent 60%
    ),
    radial-gradient(circle at 80% 30%, rgba(17, 101, 249, 0.2), transparent 55%),
    radial-gradient(circle at 50% 80%, rgba(13, 78, 200, 0.18), transparent 60%);
  animation: meshShift 22s ease-in-out infinite alternate;
  pointer-events: none;
  z-index: 0;
}

.glass {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 24px 40px -32px rgba(2, 15, 40, 0.75),
    0 0 0 1px rgba(255, 255, 255, 0.02);
}

.no-backdrop .glass {
  background: rgba(8, 22, 48, 0.72);
}

.glass-border {
  position: relative;
  border-radius: 1.2rem;
  overflow: hidden;
}

.glass-border::before {
  content: "";
  position: absolute;
  inset: 0;
  padding: 1px;
  border-radius: inherit;
  background: linear-gradient(
    135deg,
    rgba(0, 253, 251, 0.7),
    rgba(17, 101, 249, 0.6)
  );
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  /* Ensure the decorative border layer never blocks clicks/taps */
  pointer-events: none;
}

.card-tilt {
  transform-style: preserve-3d;
  transition: transform 240ms cubic-bezier(0.23, 1, 0.32, 1),
    box-shadow 240ms ease;
}

.card-tilt:hover {
  box-shadow: 0 24px 64px -32px rgba(11, 102, 208, 0.6);
}

.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 420ms ease, transform 420ms ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.btn-primary {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.75rem;
  border-radius: 9999px;
  font-weight: 600;
  color: #f0fbff;
  background: rgba(7, 39, 88, 0.6);
  border: 1px solid rgba(0, 253, 251, 0.35);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04),
    0 0 30px -12px rgba(0, 250, 255, 0.8);
  transition: transform 200ms ease, box-shadow 200ms ease, background 200ms ease;
}

.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(
    135deg,
    rgba(0, 253, 251, 0.35),
    rgba(17, 101, 249, 0.35)
  );
  opacity: 0;
  transition: opacity 200ms ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  background: rgba(9, 56, 122, 0.75);
}

.btn-primary:hover::after {
  opacity: 1;
}

.btn-primary:focus-visible {
  outline: 2px solid rgba(0, 253, 251, 0.75);
  outline-offset: 2px;
}

[data-lazy-scroll] {
  --lazy-y: 0;
  transform: translate3d(0, calc(var(--lazy-y) * 1px), 0);
  transition: transform 360ms ease-out;
  will-change: transform;
}

.scroll-progress {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 0;
  background: linear-gradient(
    90deg,
    rgba(0, 253, 251, 0.7),
    rgba(17, 101, 249, 0.85)
  );
  transition: width 120ms ease-out;
  pointer-events: none;
}

.spark {
  position: absolute;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 9999px;
  background: radial-gradient(circle, rgba(0, 253, 251, 0.85), transparent 65%);
  filter: drop-shadow(0 0 12px rgba(0, 253, 251, 0.55));
  opacity: 0.8;
  animation: sparkDrift 18s linear infinite;
  will-change: transform;
  z-index: 1;
}

.spark:nth-child(2) {
  animation-duration: 20s;
  animation-delay: -4s;
}
.spark:nth-child(3) {
  animation-duration: 24s;
  animation-delay: -9s;
}
.spark:nth-child(4) {
  animation-duration: 28s;
  animation-delay: -14s;
}

.marquee {
  position: relative;
  overflow: hidden;
}

.marquee-track {
  display: flex;
  gap: 2rem;
  width: max-content;
  animation: marqueeMove 24s linear infinite;
}

.marquee:hover .marquee-track {
  animation-play-state: paused;
}

.badge {
  background: rgba(8, 30, 66, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 9999px;
  padding: 0.4rem 1rem;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(206, 235, 255, 0.86);
  white-space: nowrap;
}

.orbit-group {
  position: relative;
  perspective: 1200px;
}

.orbit-item {
  animation: orbit 16s linear infinite;
  transform-style: preserve-3d;
}

.orbit-item:nth-child(2) {
  animation-duration: 18s;
  animation-delay: -6s;
}
.orbit-item:nth-child(3) {
  animation-duration: 20s;
  animation-delay: -10s;
}

.auto-glow {
  box-shadow: 0 0 0 1px rgba(0, 253, 251, 0.15),
    0 24px 64px -32px rgba(17, 101, 249, 0.65);
  animation: glowPulse 6s ease-in-out infinite;
}

@keyframes meshShift {
  0% {
    transform: translate3d(-4%, -3%, 0) scale(1.05);
  }
  50% {
    transform: translate3d(4%, 5%, 0) scale(1.1);
  }
  100% {
    transform: translate3d(-2%, 8%, 0) scale(1.04);
  }
}

@keyframes sparkDrift {
  0% {
    transform: translate3d(-5%, -10%, 0) scale(1);
    opacity: 0.7;
  }
  50% {
    transform: translate3d(105%, 30%, 0) scale(1.25);
    opacity: 1;
  }
  100% {
    transform: translate3d(205%, -20%, 0) scale(0.9);
    opacity: 0.65;
  }
}

@keyframes glowPulse {
  0%,
  100% {
    box-shadow: 0 0 0 1px rgba(0, 253, 251, 0.12),
      0 20px 60px -35px rgba(17, 101, 249, 0.55);
  }
  50% {
    box-shadow: 0 0 0 1px rgba(0, 253, 251, 0.22),
      0 30px 70px -30px rgba(0, 253, 251, 0.7);
  }
}

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

@keyframes orbit {
  0% {
    transform: rotateY(0deg) translateX(0);
  }
  50% {
    transform: rotateY(180deg) translateX(6px);
  }
  100% {
    transform: rotateY(360deg) translateX(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
