body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ========================
   LAYOUT / BACKGROUND
   ======================== */

.bg-cyber-grid {
  background-size: 50px 50px;
  background-image:
    linear-gradient(to right, rgba(59, 130, 246, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(59, 130, 246, 0.03) 1px, transparent 1px);
  mask-image: radial-gradient(circle at center, black 60%, transparent 100%);
}

.glass-card {
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.glass-card:hover {
  border-color: rgba(59, 130, 246, 0.2);
  background: rgba(15, 23, 42, 0.6);
}

/* ========================
   SEPARATORS
   ======================== */

.cyber-separator {
  width: 100%;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(59, 130, 246, 0.15),
    transparent
  );
  position: relative;
  margin: 0 auto;
}
.cyber-separator::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 2px;
  background: #3b82f6;
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.8);
  border-radius: 99px;
}

/* ========================
   SCROLLBAR
   ======================== */

::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #020617;
}
::-webkit-scrollbar-thumb {
  background: #1e293b;
  border-radius: 4px;
  border: 2px solid #020617;
}
::-webkit-scrollbar-thumb:hover {
  background: #3b82f6;
}

/* ========================
   REVEAL ON SCROLL
   ======================== */

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

/* ========================
   ANIMATIONS
   ======================== */

.fade-in-up {
  animation: fadeInUp 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  opacity: 0;
  transform: translateY(30px);
}
.delay-100 {
  animation-delay: 0.15s;
}
.delay-200 {
  animation-delay: 0.3s;
}
.delay-300 {
  animation-delay: 0.45s;
}

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

@keyframes dashmove {
  to {
    stroke-dashoffset: -24;
  }
}
.edge {
  stroke-dasharray: 6 6;
  animation: dashmove 1.4s linear infinite;
}

/* Flow dots (how-it-works diagram) */
@keyframes flowx {
  0% {
    left: 0%;
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  90% {
    opacity: 1;
  }
  100% {
    left: 100%;
    opacity: 0;
  }
}
.flow-dot {
  position: absolute;
  top: 50%;
  margin-top: -3px;
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background: #3b82f6;
  box-shadow: 0 0 12px 2px #3b82f6;
  animation: flowx 2.5s linear infinite;
}
.flow-dot-out {
  background: #10b981;
  box-shadow: 0 0 12px 2px #10b981;
}

/* Engine diagram (how-it-works) */
@keyframes ringpulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.3;
  }
  50% {
    transform: scale(1.08);
    opacity: 0.8;
  }
}
.engine-ring {
  animation: ringpulse 4s ease-in-out infinite;
}

@keyframes corepulse {
  0%,
  100% {
    box-shadow: 0 0 40px rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.6);
  }
  50% {
    box-shadow: 0 0 70px rgba(59, 130, 246, 0.45);
    border-color: rgba(59, 130, 246, 1);
  }
}
.engine-core {
  animation: corepulse 3s ease-in-out infinite;
}

/* ========================
   REDUCED MOTION
   ======================== */

@media (prefers-reduced-motion: reduce) {
  .fade-in-up,
  .flow-dot,
  .engine-ring,
  .engine-core {
    animation: none !important;
    opacity: 1;
    transform: none;
  }
  .pulse-dot {
    animation: none !important;
    opacity: 1;
    transform: none;
  }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .animate-ping,
  .animate-pulse {
    animation: none !important;
  }
}

/* ========================
   INDEX PAGE
   ======================== */

@keyframes scan {
  0% {
    top: 0;
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  90% {
    opacity: 1;
  }
  100% {
    top: 100%;
    opacity: 0;
  }
}
@keyframes grow {
  from {
    transform: scaleY(0.15);
  }
  to {
    transform: scaleY(1);
  }
}
.bar {
  transform-origin: bottom;
  animation: grow 1.6s cubic-bezier(0.16, 1, 0.3, 1) infinite alternate;
}
@keyframes nodepulse {
  0%,
  100% {
    opacity: 0.5;
  }
  50% {
    opacity: 1;
  }
}
.node-pulse {
  animation: nodepulse 2.4s ease-in-out infinite;
}
@keyframes ping-slow {
  75%,
  100% {
    transform: scale(2);
    opacity: 0;
  }
}
@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
  100% {
    transform: translateY(0px);
  }
}

/* ========================
   DEVELOPERS + PRICING PAGE
   ======================== */

@keyframes rise {
  0% {
    bottom: 0;
    opacity: 0;
  }
  15% {
    opacity: 1;
  }
  85% {
    opacity: 1;
  }
  100% {
    bottom: 100%;
    opacity: 0;
  }
}
.pulse-dot {
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 9999px;
  background: #22d3ee;
  box-shadow: 0 0 10px #22d3ee;
  animation: rise 3.2s linear infinite;
}
