/* Brain Branding - Stylesheet Principal Premium */

:root {
  --bg-space: #06080c;
  --bg-card: rgba(11, 15, 25, 0.6);
  --bg-sidebar: #080a10;
  --border-color: rgba(255, 255, 255, 0.05);
  --border-hover: rgba(99, 102, 241, 0.25);
  --primary: #6366f1;
  --primary-rgb: 99, 102, 241;
  --secondary: #ec4899;
  --secondary-rgb: 236, 72, 153;
  --accent: #06b6d4;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --metallic-glow-start: rgba(229, 228, 226, 0.45);
  --metallic-glow-end: rgba(212, 175, 55, 0.85);
  
  --font-title: 'Outfit', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
  
  --glow-primary: 0 0 25px rgba(99, 102, 241, 0.35);
  --glow-secondary: 0 0 25px rgba(236, 72, 153, 0.35);
  --glow-accent: 0 0 25px rgba(6, 182, 212, 0.35);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-space);
  color: var(--text-main);
  font-family: var(--font-body);
  overflow-x: hidden;
  line-height: 1.6;
}

/* ════════════════ BACKGROUND EFFECTS ════════════════ */
.cyber-grid {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.007) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.007) 1px, transparent 1px);
  background-size: 50px 50px;
  background-position: center;
  z-index: -2;
  pointer-events: none;
}

.radial-glows {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(150px);
  opacity: 0.15;
  mix-blend-mode: screen;
  animation: floatOrb 25s infinite alternate ease-in-out;
}

.orb-1 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
  top: -200px;
  right: -100px;
}

.orb-2 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, var(--secondary) 0%, transparent 70%);
  bottom: -150px;
  left: -100px;
  animation-delay: -5s;
}

.orb-3 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
  top: 40%;
  left: 30%;
  opacity: 0.1;
  animation-duration: 35s;
}

@keyframes floatOrb {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(80px, 50px) scale(1.1); }
  100% { transform: translate(-40px, -80px) scale(0.9); }
}

/* ════════════════ HEADER / NAVIGATION ════════════════ */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  background: rgba(6, 8, 12, 0.65);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 5%;
  transition: all 0.3s ease;
}

header.scrolled {
  height: 70px;
  background: rgba(6, 8, 12, 0.85);
  box-shadow: 0 10px 30px -10px rgba(0,0,0,0.5);
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-main);
  perspective: 1000px; /* Enables 3D interactive rotation of logo brain img */
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-title);
  font-weight: 800;
  font-size: 18px;
  box-shadow: var(--glow-primary);
  position: relative;
}

.logo-text {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.5px;
  animation: logo-breathing 5s ease-in-out infinite;
  will-change: transform, filter;
}

@keyframes logo-breathing {
  0%, 100% {
    transform: scale(1);
    filter: drop-shadow(0 0 1px rgba(99, 102, 241, 0.1));
  }
  50% {
    transform: scale(1.015);
    filter: drop-shadow(0 0 5px var(--metallic-glow-end, rgba(212, 175, 55, 0.7)));
  }
}

/* Touch haptic pulse effect for mobile */
@keyframes touch-pulse-glow {
  0% {
    filter: drop-shadow(0 0 2px rgba(0, 229, 255, 0.45)) scale(1);
  }
  30% {
    filter: drop-shadow(0 0 15px rgba(0, 229, 255, 0.95)) scale(1.15);
  }
  100% {
    filter: drop-shadow(0 0 2px rgba(99, 102, 241, 0.3)) scale(1);
  }
}
.logo-area.touch-pulse img {
  animation: touch-pulse-glow 0.6s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
}

.logo-text span {
  background: linear-gradient(
    90deg,
    #cd7f32 0%,    /* Bronze */
    #d4af37 20%,   /* Gold */
    #f3e5ab 40%,   /* Light Gold/Platinum */
    #e5e4e2 60%,   /* Platinum */
    #d4af37 80%,   /* Gold */
    #cd7f32 100%   /* Bronze */
  );
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: metallic-shimmer 6s linear infinite;
  display: inline-block;
  will-change: background-position, filter;
}

@keyframes metallic-shimmer {
  0% {
    background-position: 0% center;
    filter: drop-shadow(0 0 1px var(--metallic-glow-start, rgba(229, 228, 226, 0.45)));
  }
  50% {
    background-position: 100% center;
    filter: drop-shadow(0 0 5px var(--metallic-glow-end, rgba(212, 175, 55, 0.85)));
  }
  100% {
    background-position: 0% center;
    filter: drop-shadow(0 0 1px var(--metallic-glow-start, rgba(229, 228, 226, 0.45)));
  }
}

nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-link:hover {
  color: var(--text-main);
}

.header-btn {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 10px 20px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.header-btn:hover {
  background: var(--primary);
  border-color: var(--primary);
  box-shadow: var(--glow-primary);
  transform: translateY(-2px);
}

/* Menu móvil */
.menu-toggle {
  display: none;
  font-size: 24px;
  background: none;
  border: none;
  color: var(--text-main);
  cursor: pointer;
}

/* ════════════════ COMMON COMPONENTS ════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 30px;
  border-radius: 14px;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  border: none;
  box-shadow: var(--glow-primary);
}

.btn-primary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 0 35px rgba(99, 102, 241, 0.5), 0 0 35px rgba(236, 72, 153, 0.3);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  backdrop-filter: blur(10px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border-hover);
  transform: translateY(-3px);
}

.glass-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 24px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.section-tag {
  display: inline-block;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--primary);
  background: rgba(99, 102, 241, 0.08);
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid rgba(99, 102, 241, 0.15);
  margin-bottom: 20px;
}

.section-title {
  font-family: var(--font-title);
  font-size: 38px;
  font-weight: 800;
  letter-spacing: -1px;
  margin-bottom: 15px;
}

.section-title span {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 16px;
  max-width: 600px;
  margin-bottom: 50px;
}

/* ════════════════ HERO SECTION ════════════════ */
.hero {
  min-height: 75vh;
  padding: 140px 5% 30px 5%;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 50px;
  max-width: 1300px;
  margin: 0 auto;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.hero-title {
  font-family: var(--font-title);
  font-size: 64px;
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -2px;
  margin-bottom: 25px;
}

.hero-title span.accent {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: 18px;
  color: var(--text-muted);
  margin-bottom: 40px;
  max-width: 520px;
}

.hero-btns {
  display: flex;
  gap: 20px;
  width: 100%;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.brain-card {
  width: 100%;
  max-width: 460px;
  height: 480px;
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  border-color: rgba(99, 102, 241, 0.15);
  position: relative;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.brain-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 24px;
  background: radial-gradient(circle at 50% 50%, rgba(99, 102, 241, 0.05) 0%, transparent 70%);
  z-index: -1;
}

.brain-container {
  width: 260px;
  height: 260px;
  position: relative;
}

.brain-svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 15px rgba(99, 102, 241, 0.4));
  animation: pulseBrain 4s infinite alternate ease-in-out;
}

@keyframes pulseBrain {
  0% { transform: scale(1) rotate(0deg); filter: drop-shadow(0 0 15px rgba(99, 102, 241, 0.4)); }
  50% { transform: scale(1.05) rotate(2deg); filter: drop-shadow(0 0 25px rgba(236, 72, 153, 0.5)); }
  100% { transform: scale(0.98) rotate(-1deg); filter: drop-shadow(0 0 18px rgba(99, 102, 241, 0.4)); }
}

.brain-pulse-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 280px;
  height: 280px;
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 50%;
  animation: ripple 6s infinite linear;
  pointer-events: none;
}

@keyframes ripple {
  0% { width: 200px; height: 200px; opacity: 1; }
  100% { width: 450px; height: 450px; opacity: 0; }
}

/* ════════════════ SERVICES SECTION ════════════════ */
.services {
  padding: 100px 5%;
  max-width: 1300px;
  margin: 0 auto;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.service-card {
  padding: 40px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.service-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at var(--glare-x, 50%) var(--glare-y, 50%),
    rgba(255, 255, 255, 0.12) 0%,
    rgba(255, 255, 255, 0) 65%
  );
  opacity: var(--glare-opacity, 0);
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 5;
}

#servicios .service-card {
  text-align: center !important;
}

#servicios .service-card:hover {
  border: 1px solid transparent !important;
  background: linear-gradient(var(--bg-card), var(--bg-card)) padding-box,
              radial-gradient(circle at var(--glare-x, 50%) var(--glare-y, 50%), rgba(0, 229, 255, 0.45) 0%, var(--border-color) 60%) border-box !important;
}

.service-bullet {
  display: block;
  margin-bottom: 12px;
}

.service-card:hover {
  transform: translateY(-8px);
  border-color: var(--border-hover);
  box-shadow: 0 15px 35px -10px rgba(99, 102, 241, 0.15);
}

.service-icon {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: var(--primary);
  margin-bottom: 30px;
  transition: all 0.3s ease;
}

.service-card:hover .service-icon {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-color: transparent;
  color: white;
  box-shadow: var(--glow-primary);
}

.service-card h3 {
  font-family: var(--font-title);
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 15px;
}

.service-card p {
  color: var(--text-muted);
  font-size: 14.5px;
}

/* ════════════════ DEMO SHOWCASE SECTION ════════════════ */
.showcase {
  padding: 100px 5%;
  max-width: 1300px;
  margin: 0 auto;
}

.showcase-container {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 60px;
  align-items: center;
}

.showcase-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.showcase-preview-card {
  width: 100%;
  border-color: rgba(236, 72, 153, 0.15);
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0,0,0,0.6);
}

.preview-header {
  height: 50px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border-color);
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.dot-red { background: #ef4444; }
.dot-yellow { background: #f59e0b; }
.dot-green { background: #10b981; }

.preview-address {
  flex-grow: 1;
  margin-left: 20px;
  height: 28px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 6px;
  border: 1px solid var(--border-color);
  font-size: 11px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  padding: 0 12px;
  font-family: monospace;
}

.preview-body {
  height: 380px;
  padding: 25px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: relative;
}

/* Mock Dashboard Layout inside preview */
.mock-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
}

.mock-metric {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  padding: 15px;
  border-radius: 12px;
}

.mock-metric .label { font-size: 10px; color: var(--text-muted); text-transform: uppercase; }
.mock-metric .val { font-family: var(--font-title); font-size: 20px; font-weight: 700; color: #fff; margin-top: 4px; }
.mock-metric .change { font-size: 10px; color: #10b981; }

.mock-chart-container {
  flex-grow: 1;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.mock-chart-bars {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  height: 120px;
  padding-top: 10px;
}

.mock-bar {
  width: 12%;
  background: linear-gradient(to top, var(--primary), var(--secondary));
  border-radius: 4px 4px 0 0;
  animation: mockGrow 2s ease-out forwards;
}

@keyframes mockGrow {
  from { height: 0; }
}

.floating-cerebro-bubble {
  position: absolute;
  bottom: 25px;
  right: 25px;
  width: 230px;
  background: rgba(11, 15, 25, 0.85);
  border: 1px solid var(--primary);
  border-radius: 16px;
  padding: 15px;
  backdrop-filter: blur(10px);
  box-shadow: var(--glow-primary);
  display: flex;
  gap: 12px;
}

.cerebro-avatar-mini {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.5);
  animation: floatMini 2s infinite alternate ease-in-out;
}

@keyframes floatMini {
  from { transform: translateY(0); }
  to { transform: translateY(-4px); }
}

.cerebro-text-mini {
  font-size: 11.5px;
  line-height: 1.4;
  color: var(--text-main);
}

.cerebro-text-mini strong {
  color: var(--secondary);
}

/* ════════════════ TESTIMONIALS SECTION ════════════════ */
.testimonials {
  padding: 100px 5%;
  max-width: 1300px;
  margin: 0 auto;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 30px;
}

.testimonial-card {
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.testimonial-text {
  font-size: 15px;
  color: var(--text-muted);
  font-style: italic;
  line-height: 1.7;
  margin-bottom: 30px;
  position: relative;
}

.testimonial-text::before {
  content: '"';
  position: absolute;
  top: -20px;
  left: -15px;
  font-size: 60px;
  color: rgba(99, 102, 241, 0.1);
  font-family: serif;
}

.testimonial-user {
  display: flex;
  align-items: center;
  gap: 15px;
}

.user-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-title);
  font-weight: 700;
  color: var(--primary);
}

.user-info h4 {
  font-size: 15px;
  font-weight: 700;
}

.user-info p {
  font-size: 12px;
  color: var(--text-muted);
}

/* ════════════════ CONTACT / CTA SECTION ════════════════ */
.contact {
  padding: 100px 5% 140px 5%;
  max-width: 1300px;
  margin: 0 auto;
}

.contact-container {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 60px;
  align-items: center;
}

.contact-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.contact-card {
  padding: 45px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
  border-color: rgba(99, 102, 241, 0.1);
}

.form-group {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px 16px;
  color: white;
  font-family: var(--font-body);
  font-size: 14.5px;
  transition: all 0.3s ease;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 15px rgba(99, 102, 241, 0.15);
  background: rgba(0, 0, 0, 0.4);
}

/* ════════════════ FOOTER ════════════════ */
footer {
  border-top: 1px solid var(--border-color);
  padding: 60px 5% 40px 5%;
  background: #040508;
}

.footer-grid {
  max-width: 1300px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 30px;
}

.footer-left {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-left p {
  font-size: 12.5px;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 25px;
}

.footer-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13.5px;
  transition: color 0.2s ease;
}

.footer-link:hover {
  color: var(--text-main);
}

/* ════════════════ RESPONSIVENESS ════════════════ */
@media (max-width: 968px) {
  .hero {
    grid-template-columns: 1fr;
    text-align: center;
    padding-top: 120px;
    gap: 40px;
  }
  
  .hero-content {
    align-items: center;
  }
  
  .hero-title {
    font-size: 46px;
  }
  
  .hero-btns {
    justify-content: center;
  }
  
  .showcase-container, .contact-container, .calc-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  .showcase-content, .contact-info {
    align-items: center;
    text-align: center;
  }
  
  .section-title {
    font-size: 32px;
  }
  
  nav {
    display: none; /* Simplificado para móviles */
  }
}

/* ════════════════ LIGHT THEME OVERRIDES ════════════════ */
body.light-theme {
  --bg-space: #f8fafc;
  --bg-card: rgba(255, 255, 255, 0.7);
  --border-color: rgba(0, 0, 0, 0.06);
  --border-hover: rgba(99, 102, 241, 0.4);
  --text-main: #0f172a;
  --text-muted: #475569;
  --metallic-glow-start: rgba(15, 23, 42, 0.25);
  --metallic-glow-end: rgba(184, 115, 51, 0.75);
  background-color: var(--bg-space);
  color: var(--text-main);
}

body.light-theme header {
  background: rgba(248, 250, 252, 0.75);
}

body.light-theme .logo-text,
body.light-theme .logo-area,
body.light-theme h1,
body.light-theme h2,
body.light-theme h3,
body.light-theme h4 {
  color: #0f172a;
}

body.light-theme .nav-link {
  color: #475569;
}

body.light-theme .nav-link:hover {
  color: #0f172a;
}

body.light-theme .header-btn {
  color: #0f172a;
  background: rgba(0, 0, 0, 0.03);
}

body.light-theme .header-btn:hover {
  color: #fff;
  background: var(--primary);
}

body.light-theme .btn-secondary {
  background: rgba(0, 0, 0, 0.02);
  color: #0f172a;
}

body.light-theme .btn-secondary:hover {
  background: rgba(0, 0, 0, 0.05);
}

body.light-theme .mock-metric {
  background: rgba(0, 0, 0, 0.01);
}

body.light-theme .mock-metric .val {
  color: #0f172a;
}

body.light-theme .floating-cerebro-bubble {
  background: rgba(255, 255, 255, 0.95);
  color: #0f172a;
  box-shadow: 0 10px 25px rgba(99, 102, 241, 0.15);
}

body.light-theme .cerebro-text-mini {
  color: #475569;
}

body.light-theme .form-group input,
body.light-theme .form-group select,
body.light-theme .form-group textarea {
  background: rgba(255, 255, 255, 0.7);
  color: #0f172a;
  border-color: rgba(0, 0, 0, 0.1);
}

body.light-theme .form-group input:focus,
body.light-theme .form-group select:focus,
body.light-theme .form-group textarea:focus {
  background: #fff;
  border-color: var(--primary);
}

body.light-theme footer {
  background: #f1f5f9;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

body.light-theme footer .logo-text {
  color: #0f172a;
}

body.light-theme .cyber-grid {
  background-image: 
    linear-gradient(rgba(0, 0, 0, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 0, 0.02) 1px, transparent 1px);
}

body.light-theme .glow-orb {
  opacity: 0.07;
}

body.light-theme .mock-chart-container {
  background: rgba(0, 0, 0, 0.02);
}

body.light-theme .preview-header {
  background: rgba(0, 0, 0, 0.02);
}

body.light-theme .preview-address {
  background: rgba(255, 255, 255, 0.6);
  color: #475569;
}

body.light-theme .testimonial-card {
  box-shadow: 0 10px 30px rgba(0,0,0,0.02);
}

body.light-theme .user-avatar {
  background: rgba(0,0,0,0.03);
}

body.light-theme .title-main {
  background: linear-gradient(135deg, #0f172a 60%, rgba(15, 23, 42, 0.7) 100%) !important;
  -webkit-background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

body.light-theme #hero-more-info-btn {
  color: #0f172a !important;
  border-color: rgba(0, 0, 0, 0.15) !important;
  background: rgba(0, 0, 0, 0.03) !important;
}

body.light-theme #hero-more-info-btn:hover {
  background: rgba(0, 0, 0, 0.07) !important;
}

/* ════════════════ LIGHT THEME DRIFTING CLOUDS ════════════════ */
.cloud-bg-container {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  overflow: hidden;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  background: linear-gradient(180deg, #cbebfb 0%, #eef8fe 50%, #ffffff 100%);
}
body.light-theme .cloud-bg-container {
  opacity: 1;
}
.cloud {
  position: absolute;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 100px;
  box-shadow: 0 10px 40px rgba(255, 255, 255, 0.45);
  filter: blur(4px);
  will-change: transform;
}
.cloud::before, .cloud::after {
  content: '';
  position: absolute;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
}

.cloud-1 {
  width: 180px;
  height: 60px;
  top: 12%;
  animation: drift 50s linear infinite;
  opacity: 0.85;
}
.cloud-1::before {
  width: 80px;
  height: 80px;
  top: -40px;
  left: 25px;
}
.cloud-1::after {
  width: 100px;
  height: 100px;
  top: -55px;
  left: 65px;
}

.cloud-2 {
  width: 250px;
  height: 80px;
  top: 30%;
  animation: drift 75s linear infinite;
  animation-delay: -15s;
  opacity: 0.9;
  transform: scale(0.85);
}
.cloud-2::before {
  width: 110px;
  height: 110px;
  top: -55px;
  left: 35px;
}
.cloud-2::after {
  width: 130px;
  height: 130px;
  top: -75px;
  left: 90px;
}

.cloud-3 {
  width: 140px;
  height: 46px;
  top: 8%;
  animation: drift 38s linear infinite;
  animation-delay: -5s;
  opacity: 0.75;
  transform: scale(0.65);
}
.cloud-3::before {
  width: 66px;
  height: 66px;
  top: -33px;
  left: 18px;
}
.cloud-3::after {
  width: 80px;
  height: 80px;
  top: -42px;
  left: 50px;
}

.cloud-4 {
  width: 220px;
  height: 70px;
  top: 52%;
  animation: drift 90s linear infinite;
  animation-delay: -35s;
  opacity: 0.8;
  transform: scale(0.75);
}
.cloud-4::before {
  width: 95px;
  height: 95px;
  top: -45px;
  left: 30px;
}
.cloud-4::after {
  width: 115px;
  height: 115px;
  top: -65px;
  left: 80px;
}

.cloud-5 {
  width: 320px;
  height: 100px;
  top: 20%;
  animation: drift 130s linear infinite;
  animation-delay: -60s;
  opacity: 0.95;
  filter: blur(6px);
}
.cloud-5::before {
  width: 140px;
  height: 140px;
  top: -70px;
  left: 50px;
}
.cloud-5::after {
  width: 170px;
  height: 170px;
  top: -95px;
  left: 120px;
}

@keyframes drift {
  0% {
    transform: translateX(110vw);
  }
  100% {
    transform: translateX(-360px);
  }
}

/* ════════════════ CUSTOM CIBER CURSOR ════════════════ */
.custom-cursor {
  width: 8px;
  height: 8px;
  background: var(--primary);
  border-radius: 50%;
  position: fixed;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: width 0.2s, height 0.2s, background-color 0.2s;
  box-shadow: var(--glow-primary);
}

.custom-cursor-follower {
  width: 26px;
  height: 26px;
  border: 1px solid var(--secondary);
  border-radius: 50%;
  position: fixed;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: transform 0.08s ease-out, border-color 0.2s, width 0.2s, height 0.2s;
}

/* Ocultar en dispositivos móviles */
@media (max-width: 968px) {
  .custom-cursor,
  .custom-cursor-follower {
    display: none;
  }
}

/* ════════════════ SCROLL REVEAL ANIMATIONS ════════════════ */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* ════════════════ DYNAMIC HIGHLIGHT ANIMATION ════════════════ */
@keyframes pulseGlow {
  0% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4); }
  50% { box-shadow: 0 0 25px 6px rgba(236, 72, 153, 0.65); }
  100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4); }
}

.pulse-highlight {
  animation: pulseGlow 1.5s ease-in-out infinite alternate;
  border-color: var(--secondary) !important;
}

/* ════════════════ FLOATING WHATSAPP & TYPING ANIMATIONS ════════════════ */
.float-wa-btn {
  animation: waPulse 2.5s infinite;
  display: flex;
  align-items: center;
  justify-content: center;
}

.float-wa-btn:hover {
  transform: scale(1.12) rotate(8deg);
}

@keyframes waPulse {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.4); }
  70% { box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Typing Bubble loop animation */
@keyframes bubbleAppear {
  0%, 100% { transform: scale(0.8) translateX(-10px); opacity: 0; visibility: hidden; }
  5%, 35% { transform: scale(1) translateX(0); opacity: 1; visibility: visible; }
  40%, 95% { transform: scale(0.8) translateX(-10px); opacity: 0; visibility: hidden; }
}

.wa-typing-bubble {
  animation: bubbleAppear 10s infinite ease-in-out;
  transform-origin: left center;
}

/* Dots bouncing */
@keyframes typingBounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40% { transform: translateY(-4px); opacity: 1; }
}

.typing-dot {
  animation: typingBounce 1.4s infinite ease-in-out both;
}
.typing-dot:nth-child(2) {
  animation-delay: 0.2s;
}
.typing-dot:nth-child(3) {
  animation-delay: 0.4s;
}

/* Service Card Perspective Tilt hover */
.service-card {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s;
  transform-style: preserve-3d;
  perspective: 1000px;
}

.service-card:hover {
  border-color: rgba(99, 102, 241, 0.35);
  box-shadow: 0 15px 35px rgba(99, 102, 241, 0.12);
}

/* ════════════════ PRINT MEDIA STYLES (PDF EXPORT) ════════════════ */
@media print {
  body *, html * {
    visibility: hidden;
  }
  
  #cotizador, #cotizador * {
    visibility: visible;
  }
  
  body, html {
    background: #ffffff !important;
    color: #000000 !important;
  }
  
  #cotizador {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    background: #ffffff !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
  }
  
  #calc-pdf-btn, #calc-submit-btn, .calc-check {
    display: none !important;
  }
  
  .glass-card {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: none !important;
    color: #000000 !important;
  }
  
  h2, h3, h4, span, div, p {
    color: #000000 !important;
    text-shadow: none !important;
  }
  
  .section-tag {
    background: #f1f5f9 !important;
    color: #0f172a !important;
    border: 1px solid #cbd5e1 !important;
  }
/* FLOATING ACTION BUTTONS (WHATSAPP & TELEGRAM) */
@keyframes fab-radar {
  0% { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(1.6); opacity: 0; }
}

#whatsapp-fab, #telegram-fab {
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
}

@media (max-width: 768px) {
  #whatsapp-fab {
    bottom: 20px !important;
    right: 18px !important;
    width: 52px !important;
    height: 52px !important;
  }
  #telegram-fab {
    bottom: 20px !important;
    right: 78px !important;
    width: 52px !important;
    height: 52px !important;
  }
}

/* ════════════════ SIMULATOR ENHANCEMENTS & SMOOTH SPACING ════════════════ */
.asistente-ia-section {
  scroll-margin-top: 90px !important;
  padding-top: 60px !important;
}

#asistente-ia, #simulador-pos, #simulador-web, #inclusiones {
  scroll-margin-top: 90px !important;
}

.asistente-ia-grid {
  margin-top: 35px !important;
}

.asistente-ia-section .section-title span {
  background: linear-gradient(135deg, #00e5ff 0%, #a855f7 100%) !important;
  -webkit-background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  filter: drop-shadow(0 0 14px rgba(0, 229, 255, 0.5)) !important;
  text-shadow: 0 0 25px rgba(0, 229, 255, 0.35) !important;
}

/* ════════════════ UNIVERSAL MOBILE OVERFLOW PROTECTION ════════════════ */
html, body {
  max-width: 100vw !important;
  overflow-x: hidden !important;
}

.smartphone-container,
.tablet-container,
.browser-container,
.telegram-mockup,
.telegram-messages-container,
.telegram-bubble,
.simulador-card,
.pos-container,
.erp-container {
  max-width: 100% !important;
  box-sizing: border-box !important;
  overflow-wrap: anywhere !important;
  word-break: break-word !important;
}

/* ════════════════ PRINT STYLES FOR SAAS CONTRACT PDF (ZERO BLANK PAGES) ════════════════ */
@page {
  size: auto;
  margin: 10mm 12mm 10mm 12mm;
}

@media print {
  /* Hide all top-level elements except the contract viewer modal when printing contract */
  body > *:not(#contract-viewer-modal) {
    display: none !important;
  }

  html, body {
    background: #ffffff !important;
    color: #000000 !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  #contract-viewer-modal {
    position: static !important;
    display: block !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    background: #ffffff !important;
    color: #000000 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
    box-shadow: none !important;
    border: none !important;
  }

  #printable-contract-card,
  #printable-contract-card:hover {
    transform: none !important;
    transition: none !important;
    animation: none !important;
    perspective: none !important;
  }

  #printable-contract-card {
    background: #ffffff !important;
    color: #000000 !important;
    border: none !important;
    box-shadow: none !important;
    margin: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 10px 0 !important;
  }

  /* Universal dark text override for all elements inside contract card */
  #printable-contract-card * {
    color: #0f172a !important;
    text-shadow: none !important;
    box-shadow: none !important;
    opacity: 1 !important;
    filter: none !important;
  }

  /* Expand legal clauses box to flow naturally into pages without inner scrollbar or overflow height */
  #printable-contract-card div[style*="overflow-y: auto"],
  #printable-contract-card div[style*="max-height"] {
    max-height: none !important;
    height: auto !important;
    overflow: visible !important;
    background: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    color: #0f172a !important;
    padding: 16px !important;
    margin-bottom: 18px !important;
  }

  #printable-contract-card h1,
  #printable-contract-card h2,
  #printable-contract-card h3,
  #printable-contract-card h4,
  #printable-contract-card strong,
  #printable-contract-card b {
    color: #020617 !important;
    font-weight: 800 !important;
  }

  #printable-contract-card p,
  #printable-contract-card span,
  #printable-contract-card div,
  #printable-contract-card td,
  #printable-contract-card th,
  #printable-contract-card label,
  #printable-contract-card li {
    color: #0f172a !important;
  }

  #contract-sha256-seal-box {
    background: #f1f5f9 !important;
    border: 1px solid #94a3b8 !important;
    color: #0f172a !important;
    margin-bottom: 0 !important;
  }

  #contract-sha256-hash-value {
    color: #0284c7 !important;
    font-weight: 800 !important;
  }

  .no-print,
  .no-print * {
    display: none !important;
  }
}

/* ════════════════ LUXURY TECH 3D PARALLAX & CYBERPUNK AMBIENT MESH ════════════════ */
:root {
  --cyan-neon: #00f2fe;
  --violet-neon: #7928ca;
  --magenta-neon: #ff0080;
  --gold-neon: #ffb703;
  --glass-bg-heavy: rgba(10, 15, 28, 0.75);
}

/* Apple & Cyberpunk Ambient Glow Mesh Animation */
.ambient-glow-mesh {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
  background: 
    radial-gradient(circle at 15% 20%, rgba(0, 242, 254, 0.16) 0%, transparent 45%),
    radial-gradient(circle at 85% 80%, rgba(121, 40, 202, 0.18) 0%, transparent 50%),
    radial-gradient(circle at 50% 50%, rgba(255, 0, 128, 0.10) 0%, transparent 60%);
  filter: blur(90px);
  animation: meshBreathing 20s ease-in-out infinite alternate;
}

@keyframes meshBreathing {
  0% { transform: scale(1) rotate(0deg); opacity: 0.8; }
  50% { transform: scale(1.12) rotate(3deg); opacity: 1; }
  100% { transform: scale(1.05) rotate(-2deg); opacity: 0.85; }
}

/* 3D Floating Glass Parallax Deck */
.glass-card, .service-card, .brain-card, .testimonial-card, .simulador-card {
  perspective: 1000px;
  transform-style: preserve-3d;
  background: var(--glass-bg-heavy) !important;
  border: 1px solid rgba(255, 255, 255, 0.09) !important;
  backdrop-filter: blur(28px) saturate(190%) !important;
  -webkit-backdrop-filter: blur(28px) saturate(190%) !important;
  border-radius: 24px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  transition: transform 0.18s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease, border-color 0.35s ease;
  will-change: transform;
  position: relative;
  overflow: hidden;
}

/* Interactive Refractive Border Glow */
.glass-card:hover, .service-card:hover, .brain-card:hover, .testimonial-card:hover {
  border-color: rgba(0, 242, 254, 0.45) !important;
  box-shadow: 
    0 25px 65px -10px rgba(0, 242, 254, 0.28),
    0 0 35px rgba(121, 40, 202, 0.22),
    inset 0 1px 1px rgba(255, 255, 255, 0.35) !important;
}

/* Dynamic Reflective Glare Overlay */
.glass-card::before, .service-card::before, .brain-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    circle at var(--glare-x, 50%) var(--glare-y, 50%),
    rgba(255, 255, 255, 0.22) 0%,
    rgba(0, 242, 254, 0.10) 35%,
    transparent 70%
  );
  opacity: var(--glare-opacity, 0);
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 10;
}

/* Ensure Contract Card is 100% Flat without 3D animation or tilt */
#printable-contract-card,
#printable-contract-card:hover {
  transform: none !important;
  transition: none !important;
  animation: none !important;
  perspective: none !important;
  will-change: auto !important;
}

