:root {
  --bg-dark: #050505;
  --bg-panel: #0f1012;
  --primary: #00f3ff; /* Cian Neón */
  --secondary: #bc13fe; /* Morado Neón */
  --text-main: #e0e0e0;
  --text-muted: #949494;
  --font-display: 'Orbitron', sans-serif;
  --font-body: 'Rajdhani', sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
}

/* === FONDO 3D (REEMPLAZA AL GRID) === */
#canvas-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -10; /* Se mantiene siempre al fondo */
  background: radial-gradient(circle at center, #0a0a10 0%, #000000 100%);
}

/* El fondo grid anterior se elimina o oculta */
.cyber-grid-bg { display: none; }

/* === HEADER === */
.header {
  background: rgba(0, 0, 0, 0.85); /* Más transparente para ver el 3D */
  backdrop-filter: blur(10px);
  padding: 20px 0; position: relative; z-index: 100;
  border-bottom: 2px solid var(--primary);
  box-shadow: 0 4px 20px rgba(0,0,0,0.8);
}
.header-content { display: flex; flex-direction: column; align-items: center; gap: 15px; }
.brand-center { text-align: center; }
.logo-main { height: 80px; filter: drop-shadow(0 0 8px var(--primary)); transition: 0.3s; }
.logo-main:hover { filter: drop-shadow(0 0 15px var(--secondary)); transform: scale(1.05); }

.brand-name {
  font-family: var(--font-display); font-size: 1.5rem; margin: 5px 0 0;
  letter-spacing: 2px; color: #fff;
}
.brand-name .highlight { color: var(--primary); }

.nav-bar {
  display: flex; gap: 20px; flex-wrap: wrap; justify-content: center;
  background: rgba(10, 10, 10, 0.8); padding: 10px 25px; border-radius: 30px;
  border: 1px solid #222; margin-top: 5px;
}
.nav-bar a {
  color: var(--text-main); text-decoration: none; font-weight: 600;
  text-transform: uppercase; font-size: 0.9rem; letter-spacing: 1px;
  transition: 0.3s; position: relative;
}
.nav-bar a:hover { color: var(--primary); text-shadow: 0 0 8px var(--primary); }
.nav-bar a::after {
  content: ''; position: absolute; width: 0; height: 2px;
  bottom: -4px; left: 0; background: var(--primary); transition: 0.3s;
}
.nav-bar a:hover::after { width: 100%; }

.header-controls { position: absolute; right: 20px; top: 30px; display: flex; gap: 10px; }

/* === BOTONES & ANIMACIONES === */
.btn-glow {
  background: transparent; border: 1px solid var(--primary); color: var(--primary);
  padding: 6px 14px; font-family: var(--font-display); cursor: pointer; transition: 0.3s;
}
.btn-glow:hover { background: var(--primary); color: #000; box-shadow: 0 0 20px var(--primary); }

.btn-whatsapp {
  background: #25D366; color: #000; text-decoration: none; padding: 6px 14px;
  font-weight: bold; border-radius: 4px; font-family: var(--font-body);
}

.pulse-anim { animation: pulse 2s infinite; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(0, 243, 255, 0.7); }
  70% { box-shadow: 0 0 0 15px rgba(0, 243, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 243, 255, 0); }
}

/* === HERO === */
.hero {
  min-height: 80vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center;
  position: relative; overflow: visible; padding: 50px 20px;
  z-index: 1;
}
/* Eliminamos fondo radial opaco para ver el 3D */
.hero-bg { display: none; }

.hero-title {
  font-family: var(--font-display); font-size: 3rem; margin: 0;
  background: linear-gradient(90deg, #fff, var(--primary), var(--secondary));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  text-transform: uppercase; line-height: 1.2; transition: 0.3s;
}
.hover-glow:hover { text-shadow: 0 0 20px rgba(0, 243, 255, 0.6); transform: scale(1.02); }

.hero-subtitle { font-size: 1.2rem; color: var(--text-muted); max-width: 600px; margin: 20px auto 40px; }
.hero-cta-group { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; }

.btn-neon {
  background: var(--primary); color: #000; padding: 12px 30px; text-decoration: none;
  font-weight: 800; font-family: var(--font-display); border: none; cursor: pointer;
  transition: 0.3s; box-shadow: 0 0 20px rgba(0, 243, 255, 0.4);
}
.btn-neon:hover { transform: translateY(-3px); box-shadow: 0 0 40px rgba(0, 243, 255, 0.8); }

.btn-outline {
  border: 2px solid var(--secondary); color: var(--secondary); padding: 12px 30px;
  text-decoration: none; font-weight: 800; font-family: var(--font-display); transition: 0.3s;
}
.btn-outline:hover { background: var(--secondary); color: #fff; box-shadow: 0 0 30px rgba(188, 19, 254, 0.6); }

/* === GENERAL === */
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 20px; width: 100%; position: relative; z-index: 2; }
.section { padding: 80px 0; position: relative; z-index: 2; }

/* Nuevo fondo para secciones para que no se pierdan con el 3D */
/* Eliminamos la clase '.alt-bg' y unificamos con '.alt-bg-glass' */
.alt-bg-glass {
  background: rgba(8, 8, 10, 0.6);
  backdrop-filter: blur(5px);
  border-top: 1px solid rgba(255,255,255,0.05);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.section-title {
  font-family: var(--font-display); font-size: 2.5rem; text-align: center;
  margin-bottom: 40px; color: #fff; transition: 0.3s;
}
.section-title.left { text-align: left; }
.text-gradient { color: var(--primary); }

/* === CARDS === */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.card {
  background: rgba(20, 20, 25, 0.7); /* Más opacidad para legibilidad sobre 3D */
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 40px 30px; border-radius: 16px; transition: 0.4s; position: relative; overflow: hidden;
}
.card:hover {
  border-color: var(--primary);
  background: linear-gradient(180deg, rgba(0, 243, 255, 0.15) 0%, rgba(20,20,25,0.8) 100%);
  transform: translateY(-10px);
  box-shadow: 0 10px 40px rgba(0, 243, 255, 0.15);
}
.card-icon { font-size: 3rem; margin-bottom: 20px; text-shadow: 0 0 10px rgba(255,255,255,0.3); }
.card h3 { font-family: var(--font-display); font-size: 1.4rem; color: #fff; }
.card p { color: var(--text-muted); margin-bottom: 30px; }

.btn-card {
  background: transparent; border: 1px solid rgba(255,255,255,0.2); color: #fff;
  padding: 8px 20px; cursor: pointer; transition: 0.3s;
}
.btn-card:hover { border-color: var(--primary); color: var(--primary); box-shadow: 0 0 10px var(--primary); }

/* === GALERÍA === */
.gallery-container { display: flex; align-items: center; gap: 15px; justify-content: center; }
.g-track { display: flex; gap: 20px; overflow-x: auto; padding: 20px 10px; scroll-behavior: smooth; scrollbar-width: none; }
.g-track::-webkit-scrollbar { display: none; }
.gallery-item { position: relative; flex-shrink: 0; transition: 0.3s; }
.g-track img {
  height: 400px; width: auto; max-width: 80vw; border-radius: 12px;
  object-fit: contain; box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.1); cursor: zoom-in;
  background: #000;
}
.g-track img:hover { border-color: var(--secondary); transform: scale(1.02); box-shadow: 0 0 20px rgba(188, 19, 254, 0.4); }
.nav-arrow {
  background: rgba(255,255,255,0.1); border: none; color: #fff; width: 40px; height: 40px;
  border-radius: 50%; cursor: pointer; font-size: 1.2rem; transition: 0.3s;
}
.nav-arrow:hover { background: var(--primary); color: #000; box-shadow: 0 0 15px var(--primary); }
.note-center { text-align: center; color: var(--text-muted); font-size: 0.9rem; margin-top: 10px; }
.caption { 
    display: block; text-align: center; margin-top: 8px; font-size: 0.9rem; color: var(--text-main); 
    font-family: var(--font-display); letter-spacing: 1px;
}

/* === SECCIÓN NOSOTROS (Split) === */
.split-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
@media(max-width: 768px) { .split-layout { grid-template-columns: 1fr; } }
.feature-list { list-style: none; padding: 0; margin-top: 20px; }
.feature-list li { margin-bottom: 10px; font-size: 1.1rem; color: #fff; }

.neon-box {
    border: 4px solid var(--secondary); padding: 40px; text-align: center;
    box-shadow: 0 0 30px rgba(188, 19, 254, 0.3), inset 0 0 30px rgba(188, 19, 254, 0.3);
    border-radius: 10px; transform: rotate(-3deg); transition: 0.3s;
}
.neon-box:hover { transform: rotate(0deg) scale(1.05); }
.neon-text {
    font-family: var(--font-display); font-size: 2rem; font-weight: 900;
    color: #fff; text-shadow: 0 0 10px var(--secondary), 0 0 20px var(--secondary);
}

/* === CONTACTO === */
.contact-wrapper { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 20px; }
.contact-desc-center { text-align: center; color: var(--text-muted); font-size: 1.2rem; margin-bottom: 10px; }
.social-buttons-row { display: flex; gap: 15px; flex-wrap: wrap; justify-content: center; margin-bottom: 30px; }
.social-btn {
  display: flex; align-items: center; justify-content: center; padding: 10px 25px;
  border-radius: 50px; text-decoration: none; font-family: var(--font-display);
  font-weight: bold; font-size: 0.9rem; color: #fff; transition: transform 0.2s, box-shadow 0.2s;
  min-width: 120px; box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}
.social-btn:hover { transform: translateY(-3px); filter: brightness(1.2); box-shadow: 0 8px 25px rgba(0,0,0,0.7); }
.social-btn.instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.social-btn.facebook { background: #1877F2; }
.social-btn.tiktok { background: #000000; border: 1px solid #333; }
.social-btn.tiktok:hover { border-color: var(--primary); }
.social-btn.threads { background: #101010; border: 1px solid #333; }

/* FORMULARIO */
.styled-form {
  background: rgba(15, 16, 18, 0.8); backdrop-filter: blur(10px);
  padding: 40px; border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.1); max-width: 600px; width: 100%;
  box-shadow: 0 0 30px rgba(0,0,0,0.5);
}
.input-group { margin-bottom: 20px; }
.input-group label { display: block; margin-bottom: 8px; font-family: var(--font-display); font-size: 0.9rem; }
.input-group input, .input-group textarea {
  width: 100%; background: #000; border: 1px solid #333; padding: 12px;
  color: #fff; border-radius: 6px; font-family: var(--font-body); transition: 0.3s;
}
.input-group input:focus, .input-group textarea:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 15px rgba(0,243,255,0.25);
}
.full-width { width: 100%; margin-top: 10px; }

/* === BOTÓN FLOTANTE === */
#scrollTopBtn {
  position: fixed; bottom: 30px; right: 30px;
  background: #000; color: var(--primary);
  border: 2px solid var(--primary); border-radius: 50%;
  width: 50px; height: 50px; font-size: 24px;
  cursor: pointer; opacity: 0; pointer-events: none;
  transition: 0.4s; z-index: 2000;
  box-shadow: 0 0 15px rgba(0, 243, 255, 0.4);
}
#scrollTopBtn.show { opacity: 1; pointer-events: all; }
#scrollTopBtn:hover {
  background: var(--primary); color: #000;
  transform: translateY(-5px); box-shadow: 0 0 30px rgba(0, 243, 255, 0.8);
}

/* === FOOTER === */
.site-footer {
  text-align: center; padding: 40px 20px; background: #000;
  border-top: 1px solid #222; position: relative; z-index: 10;
}
.site-footer small { color: #666; font-size: 0.9rem; }

/* =========================================
   SOLUCIÓN DEL BUG VISUAL (MODAL)
========================================= */
.modal {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.85); z-index: 3000; /* Z-index alto para estar sobre todo */
  display: flex; justify-content: center; align-items: center;
  opacity: 0; pointer-events: none; transition: 0.3s;
  backdrop-filter: blur(5px);
}
.modal[aria-hidden="false"] { opacity: 1; pointer-events: all; }

.modal-content {
  background: #111;
  padding: 40px;
  border-radius: 15px;
  max-width: 500px;
  width: 90%;
  border: 1px solid var(--primary);
  box-shadow: 0 0 30px rgba(0, 243, 255, 0.3);
  
  /* --- AQUÍ ESTÁ LA CORRECCIÓN CLAVE --- */
  position: relative; 
  /* Esto asegura que la X (absolute) se posicione dentro de este cuadro 
     y no en la pantalla general */
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  transition: 0.3s;
  line-height: 1;
}
.modal-close:hover { color: var(--secondary); transform: rotate(90deg); }

#modal-body h3 {
    font-family: var(--font-display); color: var(--primary); margin-top: 0;
}
#modal-body ul { padding-left: 20px; line-height: 1.8; color: #ddd; }

/* Lightbox para imágenes */
.lightbox {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.95); z-index: 4000;
    display: flex; justify-content: center; align-items: center;
    cursor: zoom-out; animation: fadeIn 0.3s;
}
.lightbox-img { max-width: 90%; max-height: 90vh; border-radius: 5px; box-shadow: 0 0 30px rgba(255,255,255,0.2); }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* Clases de utilidad */
.hidden { opacity: 0; transform: translateY(30px); transition: 0.8s ease-out; }
.reveal { opacity: 1; transform: translateY(0); }

/* =========================================
   SOLUCIÓN DEL HEADER MÓVIL
========================================= */
@media (max-width: 768px) {
  .header-controls {
    position: relative; /* Deja de flotar sobre el logo */
    top: auto;
    right: auto;
    margin-top: 20px; /* Espacio para respirar */
    width: 100%;
    justify-content: center; /* Centra los botones */
  }
  
  /* Ajuste extra para que el Header no tape el contenido al crecer */
  .header {
    height: auto;
    padding-bottom: 30px;
  }
}


