/* Neural Canvas */
#neuralCanvas {
  position: fixed;
  top: 1rem;
  left: 1rem;
  width: calc(100vw - 2rem);
  height: calc(100vh - 2rem);
  z-index: 1;
  pointer-events: none;
  opacity: 1;
}

/* Neural Flow Container */
.neural-flow {
  position: fixed;
  top: 1rem;
  left: 1rem;
  width: calc(100vw - 2rem);
  height: calc(100vh - 2rem);
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

/* Neural Indicator */
.neural-indicator {
  position: absolute;
  top: 2rem;
  left: 2rem;
  width: 40px;
  height: 40px;
  z-index: 100;
}

.neural-dot {
  width: 4px;
  height: 4px;
  background: #6B7280;
  border-radius: 50%;
  position: absolute;
  animation: pulse 2s infinite ease-in-out;
}

.neural-dot:nth-child(1) { 
  top: 5px; 
  left: 5px; 
  animation-delay: 0s; 
}

.neural-dot:nth-child(2) { 
  top: 5px; 
  right: 5px; 
  animation-delay: 0.3s; 
}

.neural-dot:nth-child(3) { 
  bottom: 5px; 
  left: 5px; 
  animation-delay: 0.6s; 
}

.neural-dot:nth-child(4) { 
  bottom: 5px; 
  right: 5px; 
  animation-delay: 0.9s; 
}

/* Data Streams */
.data-stream {
  position: absolute;
  width: 2px;
  background: linear-gradient(180deg, 
    transparent, 
    rgba(100, 116, 139, 0.4), 
    rgba(0, 153, 204, 0.6), 
    rgba(100, 116, 139, 0.5), 
    rgba(156, 163, 175, 0.3), 
    transparent);
  pointer-events: none;
  animation: stream-flow 6s linear infinite;
  box-shadow: 0 0 8px rgba(100, 116, 139, 0.3);
  border-radius: 1px;
  transform: translateY(-100px);
  opacity: 0;
}

.data-stream.warm-variant {
  background: linear-gradient(180deg, 
    transparent, 
    rgba(100, 116, 139, 0.5), 
    rgba(229, 231, 235, 0.7), 
    rgba(100, 116, 139, 0.6), 
    rgba(156, 163, 175, 0.4), 
    transparent);
  box-shadow: 0 0 10px rgba(100, 116, 139, 0.4);
}

.data-stream.golden-variant {
  background: linear-gradient(180deg, 
    transparent, 
    rgba(156, 163, 175, 0.4), 
    rgba(229, 231, 235, 0.6), 
    rgba(100, 116, 139, 0.5), 
    rgba(249, 250, 251, 0.3), 
    transparent);
  box-shadow: 0 0 12px rgba(100, 116, 139, 0.3);
}

/* Floating Nodes */
.neural-node.float-node {
  position: absolute;
  width: 4px;
  height: 4px;
  background: rgba(100, 116, 139, 0.15);
  border-radius: 50%;
  pointer-events: none;
  animation: float-node 12s ease-in-out infinite;
  box-shadow: 0 0 8px rgba(100, 116, 139, 0.2);
}

/* Pulse Waves */
.pulse-wave {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(100, 116, 139, 0.2);
  pointer-events: none;
  animation: pulse-expand 4s ease-out infinite;
  transform: scale(0);
  opacity: 1;
}

.pulse-wave::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(100, 116, 139, 0.1) 0%, transparent 70%);
  transform: translate(-50%, -50%);
  animation: pulse-glow 4s ease-out infinite;
}

/* Code Generation */
.code-snippet {
  position: absolute;
  font-family: 'Courier New', monospace;
  font-size: 10px;
  color: rgba(100, 116, 139, 0.8);
  pointer-events: none;
  white-space: nowrap;
  animation: code-type-out 3s ease-out forwards;
  background: rgba(249, 250, 251, 0.8);
  padding: 2px 4px;
  border-radius: 2px;
  border-left: 2px solid rgba(100, 116, 139, 0.4);
  opacity: 0;
  transform: scale(0.8) translateY(10px);
  max-width: 0;
  overflow: hidden;
}

.code-snippet.variant-1 {
  color: rgba(0, 153, 204, 0.8);
  border-left-color: rgba(0, 153, 204, 0.4);
}

.code-snippet.variant-2 {
  color: rgba(107, 114, 128, 0.8);
  border-left-color: rgba(107, 114, 128, 0.4);
}

.code-cursor {
  display: inline-block;
  width: 2px;
  height: 12px;
  background: rgba(100, 116, 139, 0.8);
  margin-left: 1px;
  animation: cursor-blink 0.8s infinite;
}

/* Flow particles */
.flow-particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: rgba(107, 114, 128, 0.15);
  border-radius: 50%;
  pointer-events: none;
  opacity: 0.3;
  transition: all 15s ease-in-out;
}

.flow-particle.warm {
  background: rgba(100, 116, 139, 0.3);
  box-shadow: 0 0 6px rgba(100, 116, 139, 0.4);
}

/* Automation Station Neural Accents */
.neural-accent {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 8px;
  height: 8px;
  background: rgba(100, 116, 139, 0.3);
  border-radius: 50%;
  animation: pulse-glow-accent 2s infinite ease-in-out;
  z-index: 10;
}

@keyframes pulse-glow-accent {
  0%, 100% {
    opacity: 0.3;
    transform: scale(1);
    box-shadow: 0 0 0 rgba(100, 116, 139, 0.4);
  }
  50% {
    opacity: 1;
    transform: scale(1.5);
    box-shadow: 0 0 20px rgba(100, 116, 139, 0.6);
  }
}

/* Enhanced neural effects for Automation Station */
.automation-station {
  position: relative;
  overflow: visible;
}

.automation-station::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(
    circle at 20% 30%, 
    rgba(100, 116, 139, 0.02) 0%, 
    transparent 50%
  ),
  radial-gradient(
    circle at 80% 70%, 
    rgba(229, 231, 235, 0.02) 0%, 
    transparent 50%
  );
  pointer-events: none;
  z-index: 1;
}

.automation-station .container {
  position: relative;
  z-index: 2;
}

/* Tool card neural integration */
.tool-card {
  position: relative;
}

.tool-card::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(135deg, 
    rgba(100, 116, 139, 0.1), 
    transparent 30%, 
    rgba(229, 231, 235, 0.05) 70%, 
    transparent);
  border-radius: 17px;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: -1;
}

.tool-card:hover::before {
  opacity: 1;
}

/* Neural data streams specific to Automation Station */
.automation-station .tools-carousel {
  position: relative;
  overflow-x: auto;
  overflow-y: visible;
}

.automation-station .tools-carousel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    linear-gradient(90deg, 
      rgba(100, 116, 139, 0.02) 0%, 
      transparent 20%, 
      transparent 80%, 
      rgba(100, 116, 139, 0.02) 100%);
  pointer-events: none;
  z-index: 0;
}

/* Mobile neural adjustments */
@media (max-width: 768px) {
  #neuralCanvas,
  .neural-flow {
    top: 0.5rem;
    left: 0.5rem;
    width: calc(100vw - 1rem);
    height: calc(100vh - 1rem);
  }
  
  .neural-indicator {
    top: 1rem;
    left: 1rem;
    width: 30px;
    height: 30px;
  }
  
  .neural-dot {
    width: 3px;
    height: 3px;
  }
  
  .data-stream {
    width: 1.5px;
    animation-duration: 4s;
  }
  
  .code-snippet {
    font-size: 8px;
    padding: 1px 3px;
  }
  
  .neural-node {
    width: 3px;
    height: 3px;
  }
  
  .pulse-wave {
    animation-duration: 3s;
  }
  
  .neural-accent {
    width: 6px;
    height: 6px;
    top: 0.8rem;
    right: 0.8rem;
  }
  
  .automation-station::before {
    background: radial-gradient(
      circle at 30% 20%, 
      rgba(100, 116, 139, 0.03) 0%, 
      transparent 40%
    ),
    radial-gradient(
      circle at 70% 80%, 
      rgba(229, 231, 235, 0.03) 0%, 
      transparent 40%
    );
  }
}

/* Performance optimizations */
@media (prefers-reduced-motion: reduce) {
  .data-stream,
  .neural-node,
  .pulse-wave,
  .code-snippet {
    animation: none;
    opacity: 0.3;
  }
  
  .neural-dot {
    animation: none;
    opacity: 0.5;
  }
  
  .neural-accent {
    animation: none;
    opacity: 0.4;
  }
  
  .tool-card::before {
    display: none;
  }
  
  .automation-station::before {
    display: none;
  }

  
}