/* AI Consulting Specific Styles */

/* AI Neural Network Background */
.ai-neural-bg {
  background: linear-gradient(45deg, transparent 45%, rgba(135, 224, 253, 0.1) 50%, transparent 55%),
              linear-gradient(-45deg, transparent 45%, rgba(115, 249, 159, 0.1) 50%, transparent 55%),
              radial-gradient(circle at 20% 30%, rgba(135, 224, 253, 0.1) 0%, transparent 50%),
              radial-gradient(circle at 80% 70%, rgba(115, 249, 159, 0.1) 0%, transparent 50%);
  background-size: 60px 60px, 60px 60px, 200px 200px, 200px 200px;
  animation: neuralFlow 20s ease-in-out infinite;
}

@keyframes neuralFlow {
  0%, 100% { background-position: 0 0, 0 0, 0 0, 0 0; }
  50% { background-position: 30px 30px, -30px 30px, 100px 100px, -100px -100px; }
}

/* AI Particles */
.ai-particles {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.ai-particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: linear-gradient(45deg, #87E0FD, #73F99F);
  border-radius: 50%;
  animation: aiParticleFloat 15s linear infinite;
  opacity: 0;
}

@keyframes aiParticleFloat {
  0% {
    transform: translateY(100vh) translateX(0);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  90% {
    opacity: 1;
  }
  100% {
    transform: translateY(-100px) translateX(100px);
    opacity: 0;
  }
}

/* NEW Badge Animation */
.new-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #73F99F, #87E0FD);
  color: #013545;
  font-weight: 800;
  font-size: 0.75rem;
  padding: 8px 16px;
  border-radius: 20px;
  box-shadow: 0 4px 15px rgba(115, 249, 159, 0.4);
  animation: newBadgePulse 2s ease-in-out infinite;
}

.new-badge-text {
  position: relative;
  z-index: 2;
  letter-spacing: 1px;
}

.new-badge-glow {
  position: absolute;
  inset: -2px;
  background: linear-gradient(135deg, #73F99F, #87E0FD);
  border-radius: 22px;
  filter: blur(8px);
  opacity: 0.6;
  animation: newBadgeGlow 2s ease-in-out infinite;
}

@keyframes newBadgePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

@keyframes newBadgeGlow {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 0.9; }
}

/* AI CTA Buttons */
.ai-cta-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #87E0FD, #73F99F);
  color: #013545;
  font-weight: 700;
  font-size: 1rem;
  padding: 16px 32px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 25px rgba(135, 224, 253, 0.3);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.ai-cta-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 35px rgba(135, 224, 253, 0.4);
}

.ai-cta-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s ease;
}

.ai-cta-primary:hover::before {
  left: 100%;
}

.ai-cta-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: #87E0FD;
  border: 2px solid #87E0FD;
  font-weight: 700;
  font-size: 1rem;
  padding: 14px 30px;
  border-radius: 12px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.ai-cta-secondary:hover {
  background: #87E0FD;
  color: #013545;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(135, 224, 253, 0.3);
}

/* Dark mode adjustments for CTA buttons */
.dark .ai-cta-secondary {
  color: #87E0FD;
  border-color: #87E0FD;
}

.dark .ai-cta-secondary:hover {
  background: #87E0FD;
  color: #013545;
}

/* AI Service Cards */
.ai-service-card {
  background: #1f2937;
  border-radius: 20px;
  padding: 32px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(135, 224, 253, 0.3);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.dark .ai-service-card {
  background: #1f2937;
  border-color: rgba(135, 224, 253, 0.3);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.ai-service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #87E0FD, #73F99F, #013545);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.ai-service-card:hover::before {
  opacity: 1;
}

.ai-service-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(135, 224, 253, 0.2);
}

.ai-service-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  position: relative;
  overflow: hidden;
}

.ai-service-icon::before {
  content: '';
  position: absolute;
  inset: 0;
  background: inherit;
  filter: blur(10px);
  opacity: 0.3;
  transform: scale(1.1);
}

.ai-service-cta {
  background: linear-gradient(135deg, #013545, #87E0FD);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: auto;
  position: relative;
  overflow: hidden;
}

.ai-service-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(1, 53, 69, 0.3);
}

.ai-service-cta::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.ai-service-cta:hover::before {
  left: 100%;
}

/* AI Portfolio Carousel */
.ai-portfolio-carousel {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  overflow: hidden;
}

.ai-carousel-container {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  margin: 0 60px;
  mask: linear-gradient(90deg, 
    transparent 0%, 
    black 10%, 
    black 90%, 
    transparent 100%);
  -webkit-mask: linear-gradient(90deg, 
    transparent 0%, 
    black 10%, 
    black 90%, 
    transparent 100%);
}

.ai-carousel-track {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.ai-portfolio-item {
  flex: 0 0 33.333%;
  padding: 0 16px;
}

.ai-portfolio-card {
  background: #1f2937;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  height: 100%;
  border: 1px solid rgba(135, 224, 253, 0.3);
}

.dark .ai-portfolio-card {
  background: #1f2937;
  border-color: rgba(135, 224, 253, 0.3);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.ai-portfolio-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(135, 224, 253, 0.2);
}

.ai-portfolio-image {
  height: 200px;
  background: linear-gradient(135deg, #013545, #87E0FD);
  position: relative;
  overflow: hidden;
}

.ai-portfolio-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: white;
  position: relative;
}

.ai-animation-dots {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}

.ai-animation-dots span {
  width: 8px;
  height: 8px;
  background: #73F99F;
  border-radius: 50%;
  animation: aiDotPulse 1.5s ease-in-out infinite;
}

.ai-animation-dots span:nth-child(2) {
  animation-delay: 0.2s;
}

.ai-animation-dots span:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes aiDotPulse {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.2); }
}

.ai-portfolio-content {
  padding: 24px;
}

.ai-portfolio-tag {
  display: inline-block;
  background: linear-gradient(135deg, #87E0FD, #73F99F);
  color: #013545;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 12px;
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}

.ai-portfolio-stats {
  display: flex;
  gap: 24px;
  margin-top: 16px;
}

.stat {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 1.5rem;
  font-weight: 800;
  color: #87E0FD;
}

.dark .stat-number {
  color: #73F99F;
}

.stat-label {
  font-size: 0.75rem;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.dark .stat-label {
  color: #9ca3af;
}

/* Carousel Controls */
.ai-carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  background: #1f2937;
  border: 1px solid rgba(135, 224, 253, 0.5);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  font-size: 1.25rem;
  color: #87E0FD;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
}

.dark .ai-carousel-btn {
  background: #1f2937;
  color: #87E0FD;
  border-color: rgba(135, 224, 253, 0.5);
}

.ai-carousel-btn:hover {
  background: #87E0FD;
  color: white;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 6px 20px rgba(135, 224, 253, 0.3);
}

.ai-carousel-prev {
  left: -60px;
}

.ai-carousel-next {
  right: -60px;
}

/* Carousel Indicators */
.ai-carousel-indicators {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}

.ai-carousel-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #d1d5db;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.dark .ai-carousel-dot {
  background: #4b5563;
}

.ai-carousel-dot.active {
  background: #87E0FD;
  transform: scale(1.2);
}

.ai-carousel-dot:hover {
  background: #87E0FD;
  transform: scale(1.1);
}

/* Local AI Visual */
.ai-local-visual {
  position: relative;
  height: 400px;
  border-radius: 20px;
  overflow: hidden;
  background: linear-gradient(135deg, #013545, #1f2937);
}

.local-ai-backdrop {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.city-silhouette {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 40%;
}

.building {
  position: absolute;
  bottom: 0;
  width: 20px;
  background: linear-gradient(to top, #87E0FD, #73F99F);
  opacity: 0.8;
  animation: buildingGlow 3s ease-in-out infinite alternate;
}

@keyframes buildingGlow {
  0% { opacity: 0.6; }
  100% { opacity: 1; }
}

.ai-connections {
  position: absolute;
  inset: 0;
}

.connection-line {
  position: absolute;
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, transparent, #87E0FD, transparent);
  animation: connectionPulse 2s ease-in-out infinite;
}

@keyframes connectionPulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

.floating-ai-icons {
  position: absolute;
  inset: 0;
}

.ai-icon {
  position: absolute;
  width: 40px;
  height: 40px;
  background: rgba(135, 224, 253, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #87E0FD;
  font-size: 1.25rem;
  animation: aiIconFloat 4s ease-in-out infinite;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(135, 224, 253, 0.3);
}

@keyframes aiIconFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-10px) rotate(180deg); }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .ai-carousel-container {
    margin: 0 40px;
  }
  
  .ai-portfolio-item {
    flex: 0 0 90%;
  }
  
  .ai-carousel-prev {
    left: -40px;
  }
  
  .ai-carousel-next {
    right: -40px;
  }
  
  .ai-carousel-btn {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }
  
  .ai-service-card {
    padding: 24px;
  }
  
  .new-badge {
    font-size: 0.65rem;
    padding: 6px 12px;
  }
  
  .ai-cta-primary,
  .ai-cta-secondary {
    padding: 14px 24px;
    font-size: 0.9rem;
  }
}

@media (max-width: 640px) {
  .ai-portfolio-item {
    flex: 0 0 100%;
  }
  
  .ai-portfolio-stats {
    gap: 16px;
  }
  
  .stat-number {
    font-size: 1.25rem;
  }
  
  .ai-local-visual {
    height: 300px;
  }
  
  .building {
    width: 15px;
  }
  
  .ai-icon {
    width: 32px;
    height: 32px;
    font-size: 1rem;
  }
}

/* Additional animations and effects */
@keyframes blob {
  0% { transform: translate(0px, 0px) scale(1); }
  33% { transform: translate(30px, -50px) scale(1.1); }
  66% { transform: translate(-20px, 20px) scale(0.9); }
  100% { transform: translate(0px, 0px) scale(1); }
}

.animate-blob {
  animation: blob 7s infinite;
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Loading states */
.ai-service-card,
.ai-portfolio-card {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.ai-service-card.visible,
.ai-portfolio-card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Focus states for accessibility */
.ai-cta-primary:focus,
.ai-cta-secondary:focus,
.ai-service-cta:focus {
  outline: 2px solid #87E0FD;
  outline-offset: 2px;
}

.ai-carousel-btn:focus,
.ai-carousel-dot:focus {
  outline: 2px solid #87E0FD;
  outline-offset: 2px;
}

/* Print styles */
@media print {
  .ai-particles,
  .ai-carousel-btn,
  .ai-carousel-indicators {
    display: none;
  }
  
  .ai-service-card,
  .ai-portfolio-card {
    break-inside: avoid;
  }
}
