/* AI Consulting Style - Next-Gen Design */
:root {
  /* AI Consulting Color Palette */
  --primary-dark: #0a0015;
  --primary-purple: #1a0033;
  --primary-deep: #2d1b69;
  --accent-cyan: #00d4ff;
  --accent-blue: #0066ff;
  --accent-purple: #8b5cf6;
  --accent-pink: #ff0080;
  --accent-magenta: #ff00aa;

  /* AI Gradients */
  --gradient-primary: linear-gradient(135deg, #0a0015 0%, #1a0033 50%, #2d1b69 100%);
  --gradient-hero: radial-gradient(circle at center, #2d1b69 0%, #1a0033 50%, #0a0015 100%);
  --gradient-ai: linear-gradient(45deg, #00d4ff, #8b5cf6, #ff0080);
  --gradient-data: linear-gradient(135deg, #0066ff, #00d4ff, #8b5cf6);
}

/* Global Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: var(--gradient-primary);
  color: white;
  overflow-x: hidden;
  line-height: 1.6;
}

/* Neon Glass Variables */
:root {
  --neon-hue1: 200;
  --neon-hue2: 280;
  --glass-border: 1px;
  --glass-radius: 22px;
  --neon-ease: cubic-bezier(0.5, 1, 0.89, 1);
}

/* AI Hero Section */
.ai-hero {
  position: relative;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: linear-gradient(#e4e0ba, #f7d9aa);
}

.ai-hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: center;
  max-width: 1400px;
  width: 100%;
  padding: 0 3rem;
  z-index: 10;
  position: relative;
  pointer-events: none;
}

.ai-hero-container * {
  pointer-events: auto;
}

.ai-hero-content {
  z-index: 20;
  position: relative;
}

.ai-hero-title {
  font-size: clamp(1rem, 4vw, 7.5rem);
  font-weight: 600;
  line-height: 1.1;
  margin-bottom: 2rem;
  letter-spacing: -0.02em;
  color: #473813;
}

.ai-hero-title .highlight {
  background: var(--gradient-ai);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 600;
}

a.ai-nav-link {
  color: #473813;
}

.ai-hero-subtitle {
  font-size: 1.2rem;
  color: rgb(71 56 19);
  margin-bottom: 3rem;
  max-width: 500px;
  font-weight: 300;
}

.ai-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  background: var(--accent-cyan);

  border: 2px solid var(--accent-cyan);
  border-radius: 50px;
  color: white;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.ai-cta-btn:hover {
  background: transparent;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
  color: var(--accent-cyan);
}

.ai-cta-btn::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-cta-btn:hover::before {
  left: 100%;
}

/* 3D Visualization Container */
.ai-visualization {
  position: relative;
  width: 600px;
  height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 20px;
}

/* 3D World Container */
#world {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
}

#world canvas {
  width: 100% !important;
  height: 100% !important;
}

/* Alinear avión desde abajo en móvil */
@media (max-width: 768px) {
  #world {
    top: auto;
    bottom: 0;
    height: 60vh;
    display: flex;
    align-items: flex-end;
  }

  #world canvas {
    object-fit: cover;
    object-position: bottom center;
  }
}

@media (max-width: 480px) {
  #world {
    height: 50vh;
  }
}

.ai-visualization canvas {
  width: 100% !important;
  height: 100% !important;
  border-radius: 50%;
  background: transparent;
}

/* Stats Badge */
.ai-stats-badge {
  position: absolute;
  bottom: 2rem;
  right: 2rem;
  background: #00bcd48a;
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 25px;
  padding: 1.5rem 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  z-index: 30;
}

.stats-icon {
  width: 40px;
  height: 40px;
  background: var(--gradient-ai);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
}

.stats-text {
  color: white;
}

.stats-number {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.stats-label {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Navigation Updates */
.ai-navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: transparent;
  backdrop-filter: none;
  border-bottom: 1px solid transparent;
  padding: 1.5rem 0;
  z-index: 1000;
  transition: all 0.3s ease;
}

.ai-navbar.scrolled {
  background: #000428;
  background: -webkit-linear-gradient(to right, #004e92, #000428);
  background: linear-gradient(to right, #004e92, #000428);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1rem 0;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.ai-nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 3rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ai-logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
  transition: all 0.3s ease;
}

.ai-logo svg.logocomunika {
  height: 45px;
  width: auto;
  transition: all 0.3s ease;
  filter: drop-shadow(0 0 10px rgba(0, 188, 212, 0.5));
}

.ai-navbar.scrolled .ai-logo svg.logocomunika {
  height: 40px;
  filter: drop-shadow(0 0 5px rgba(0, 188, 212, 0.3));
}

.ai-nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.ai-nav-link {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.ai-navbar.scrolled .ai-nav-link {
  color: rgba(255, 255, 255, 0.8);
  text-shadow: none;
}

.ai-nav-link:hover {
  color: var(--accent-cyan);
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

/* Estilos para enlaces activos con scroll spy */
.ai-nav-link.active,
.ai-nav-link.highlight {
  color: var(--accent-cyan);
  font-weight: 600;
  position: relative;
}

.ai-nav-link.active::after,
.ai-nav-link.highlight::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-cyan), var(--accent-blue));
  border-radius: 2px;
  box-shadow: 0 0 10px var(--accent-cyan);
  animation: highlightPulse 2s ease-in-out infinite;
}

@keyframes highlightPulse {

  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 10px var(--accent-cyan);
  }

  50% {
    opacity: 0.7;
    box-shadow: 0 0 20px var(--accent-cyan);
  }
}

/* Floating Elements */
.floating-element {
  position: absolute;
  opacity: 0.6;
  animation: float 6s ease-in-out infinite;
}

.floating-element:nth-child(1) {
  top: 20%;
  left: 10%;
  animation-delay: 0s;
}

.floating-element:nth-child(2) {
  top: 60%;
  right: 15%;
  animation-delay: 2s;
}

.floating-element:nth-child(3) {
  bottom: 30%;
  left: 20%;
  animation-delay: 4s;
}

@keyframes float {

  0%,
  100% {
    transform: translateY(0px) rotate(0deg);
  }

  50% {
    transform: translateY(-20px) rotate(5deg);
  }
}

/* Responsive Design */
@media (max-width: 1200px) {
  .ai-hero-container {
    gap: 4rem;
    padding: 0 2rem;
  }

  .ai-hero-title {
    font-size: clamp(2.8rem, 6vw, 4.5rem);
  }

  .ai-visualization {
    width: 500px;
    height: 500px;
  }
}

@media (max-width: 992px) {
  .ai-nav-container {
    padding: 0 2rem;
  }

  .ai-hero {
    height: auto;
    min-height: 100vh;
    padding: 120px 0 60px;
  }

  .ai-hero-container {
    grid-template-columns: 1fr;
    gap: 3rem;
    text-align: center;
    padding: 0 2rem;
  }

  .ai-hero-content {
    order: 1;
  }

  .ai-visualization {
    order: 2;
    width: 100%;
    max-width: 400px;
    height: 400px;
    margin: 0 auto;
  }

  #world {
    height: 400px;
  }

  .ai-hero-title {
    font-size: clamp(2.5rem, 7vw, 3.5rem);
  }

  .ai-hero-subtitle {
    max-width: 100%;
    margin: 0 auto 2rem auto;
  }

  .ai-stats-badge {
    position: relative;
    bottom: auto;
    right: auto;
    left: auto;
    margin: 2rem auto 0;
  }
}

@media (max-width: 768px) {
  .ai-hero {
    min-height: 100vh;
    height: 100vh;
    padding: 100px 0 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
  }

  .ai-hero-container {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
    padding: 0 1.5rem;
    height: auto;
    align-items: flex-start;
    padding-top: 2rem;
  }

  .ai-hero-title {
    font-size: clamp(1.8rem, 8vw, 2.8rem);
    line-height: 1.2;
    margin-bottom: 1.5rem;
    word-break: break-word;
  }

  .ai-hero-subtitle {
    font-size: 1rem;
    margin-bottom: 2rem;
    line-height: 1.6;
  }

  .ai-visualization {
    width: 100%;
    max-width: 100%;
    height: 350px;
    display: block;
    margin: 0 auto;
  }

  #world {
    height: 350px;
    width: 100%;
  }

  #world canvas {
    width: 100% !important;
    height: 100% !important;
    max-width: 100%;
  }

  .data-sphere {
    width: 100%;
    max-width: 300px;
    height: 300px;
  }

  .ai-stats-badge {
    position: relative;
    bottom: auto;
    right: auto;
    margin-top: 2rem;
    display: flex;
    width: fit-content;
    max-width: calc(100% - 2rem);
    margin: 2rem auto 0;
    display: none !important;
  }

  .social-links {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-content: center;
    justify-content: center;
    gap: 1rem;
  }

  .footer-links ul {
    list-style: none;
  }

  .ai-nav-container {
    padding: 0 1.5rem;
  }

  .ai-cta-btn {
    padding: 0.9rem 1.8rem;
    font-size: 0.95rem;
  }
}

@media (max-width: 480px) {
  .ai-hero {
    padding: 90px 0 30px;
    min-height: auto;
    height: auto;
  }

  .ai-hero-container {
    padding: 0 1rem;
    gap: 1.5rem;
  }

  .ai-hero-title {
    font-size: clamp(1.5rem, 9vw, 2.2rem);
    margin-bottom: 1rem;
    line-height: 1.3;
  }

  .ai-hero-subtitle {
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
  }

  .ai-cta-btn {
    padding: 0.8rem 1.5rem;
    font-size: 0.85rem;
  }

  .ai-visualization {
    max-width: 100%;
    height: 280px;
    width: 100%;
  }

  #world {
    height: 280px;
    width: 100%;
  }

  #world canvas {
    width: 100% !important;
    height: 100% !important;
    max-width: 100%;
  }

  .ai-stats-badge {
    padding: 1rem 1.2rem;
    min-width: auto;
    font-size: 0.85rem;
    max-width: calc(100% - 2rem);
    display: none !important;
  }

  .stats-number {
    font-size: 1.2rem;
  }

  .stats-label {
    font-size: 0.75rem;
  }

  .ai-nav-container {
    padding: 0 1rem;
  }

  .stats-icon {
    width: 35px;
    height: 35px;
    font-size: 1.2rem;
  }
}

@media (max-width: 375px) {
  .ai-hero {
    padding: 80px 0 20px;
  }

  .ai-hero-title {
    font-size: 1.4rem;
  }

  .ai-hero-subtitle {
    font-size: 0.85rem;
  }

  .ai-visualization {
    height: 240px;
  }

  #world {
    height: 240px;
  }
}