/* ==========================================================================
   ADBA Publicidad - Minimalismo Editorial, Orbes en Movimiento & Asesor ADBA
   Puntero Cyan Neón, Resplandor Cyan Suave, Totalmente Optimizado para Móvil
   Barra de Descuento con Cuenta Regresiva, Mapa 3D Oscuro & FAQ Interactivo
   Listo para Despliegue en Hostinger
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,300;1,400&family=Playfair+Display:ital,wght@0,500;0,600;1,400;1,500&family=Space+Grotesk:wght@400;500;600;700&display=swap');

:root {
  --adba-bg: #000000;
  --adba-surface: #07070a;
  --adba-card: #0c0d14;
  --adba-border: rgba(255, 255, 255, 0.08);
  --adba-cyan: #38bdf8;
  --adba-cyan-bright: #00f0ff;
  --adba-glow-cyan-soft: rgba(56, 189, 248, 0.28);
  --adba-glow-cyan-dim: rgba(0, 240, 255, 0.15);
}

* {
  box-sizing: border-box;
  scroll-behavior: smooth;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  background-color: #000000;
  color: #f1f5f9;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  overflow-x: hidden;
  letter-spacing: -0.015em;
  margin: 0;
  padding: 0;
  width: 100%;
  position: relative;
}

/* ==========================================================================
   0. Barra de Descuento Flash en Cabecera (Countdown Banner)
   ========================================================================== */

.top-discount-banner {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  background: linear-gradient(90deg, #031826 0%, #06283d 50%, #031826 100%);
  border-bottom: 1px solid rgba(56, 189, 248, 0.35);
  box-shadow: 0 4px 20px rgba(0, 240, 255, 0.15);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.top-discount-banner.is-hidden {
  max-height: 0 !important;
  opacity: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  border-bottom: 0 !important;
  pointer-events: none !important;
}

.validity-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 9999px;
  background: rgba(0, 240, 255, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.4);
  color: #38bdf8;
  font-family: 'Space Grotesk', monospace;
  font-weight: 700;
  font-size: 11px;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.25);
  letter-spacing: 0.02em;
}

/* ==========================================================================
   Puntero / Cursor Personalizado Cyan Neón (Solo en Escritorio con Mouse)
   ========================================================================== */

@media (pointer: fine) {
  body {
    cursor: default;
  }
}

.custom-cursor-dot {
  position: fixed;
  top: 0;
  left: 0;
  width: 8px;
  height: 8px;
  background: #38bdf8;
  border-radius: 50%;
  pointer-events: none;
  z-index: 999999;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 10px #38bdf8, 0 0 20px #00f0ff;
  transition: transform 0.06s ease-out, opacity 0.2s ease;
  mix-blend-mode: screen;
}

.custom-cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  width: 34px;
  height: 34px;
  border: 1.5px solid rgba(56, 189, 248, 0.65);
  background: rgba(56, 189, 248, 0.04);
  border-radius: 50%;
  pointer-events: none;
  z-index: 999998;
  transform: translate(-50%, -50%);
  transition: width 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              height 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              background 0.22s ease,
              border-color 0.22s ease,
              transform 0.12s cubic-bezier(0.16, 1, 0.3, 1);
  mix-blend-mode: screen;
}

.custom-cursor-ring.cursor-hover {
  width: 52px;
  height: 52px;
  background: rgba(56, 189, 248, 0.18);
  border-color: #38bdf8;
  box-shadow: 0 0 25px rgba(56, 189, 248, 0.45);
}

.custom-cursor-ring.cursor-click {
  transform: translate(-50%, -50%) scale(0.85);
  background: rgba(0, 240, 255, 0.3);
}

@media (pointer: coarse), (max-width: 1024px) {
  .custom-cursor-dot,
  .custom-cursor-ring {
    display: none !important;
  }
}

/* ==========================================================================
   Títulos con Resplandor Cyan Suave al Pasar el Cursor
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  letter-spacing: -0.03em;
  font-weight: 700;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.title-highlight-hover:hover,
h1:hover, h2:hover, h3:hover {
  color: #ffffff !important;
  text-shadow: 0 0 14px rgba(56, 189, 248, 0.5), 0 0 28px rgba(0, 240, 255, 0.25);
  transform: translateX(3px);
}

@media (max-width: 640px) {
  .title-highlight-hover:hover,
  h1:hover, h2:hover, h3:hover {
    transform: none;
  }
}

.font-editorial {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-weight: 400;
}

.font-mono-tag {
  font-family: 'Space Grotesk', monospace;
}

/* ==========================================================================
   Carrusel de Palabras Dinámico en Título Hero
   ========================================================================== */

.hero-carousel-text,
.carousel-word-item {
  display: inline-block;
  transition: opacity 0.45s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.45s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform, filter;
}

.hero-carousel-text.carousel-fade-out,
.carousel-word-item.carousel-fade-out {
  opacity: 0;
  transform: translateY(14px);
  filter: blur(4px);
}

.hero-carousel-text.carousel-fade-in,
.carousel-word-item.carousel-fade-in {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* ==========================================================================
   Overlay de Transición de Páginas
   ========================================================================== */

.page-transition-overlay {
  position: fixed;
  inset: 0;
  background: #000000;
  z-index: 99999;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.page-transition-overlay.is-active {
  opacity: 1;
  pointer-events: all;
}

/* ==========================================================================
   Intro Sequence (Pantalla de Entrada de 3 Fases - Siempre Fixed y Aislada)
   ========================================================================== */

.intro-screen-container,
.intro-overlay,
#introContainer {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  background: #000000 !important;
  z-index: 99999 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.8s !important;
  cursor: pointer;
  overflow: hidden;
}

.intro-screen-container.intro-hidden,
.intro-overlay.intro-hidden,
#introContainer.intro-hidden {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  display: none !important;
}

.intro-step {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0.94) translateY(12px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
  padding: 1.5rem;
  text-align: center;
}

.intro-step.active {
  opacity: 1;
  transform: scale(1) translateY(0);
  pointer-events: auto;
}

.intro-logo-img {
  height: 52px;
  width: auto;
  max-width: 70vw;
  object-fit: contain;
  filter: drop-shadow(0 0 20px rgba(56, 189, 248, 0.35));
}

@media (min-width: 640px) {
  .intro-logo-img {
    height: 72px;
  }
}

.skip-intro-btn,
.intro-skip-btn,
#skipIntroBtn {
  position: absolute;
  bottom: 24px;
  right: 24px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #ffffff;
  padding: 8px 18px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  z-index: 100000;
  transition: all 0.25s ease;
  font-family: 'Space Grotesk', monospace;
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.15);
}

.skip-intro-btn:hover,
.intro-skip-btn:hover,
#skipIntroBtn:hover {
  background: rgba(56, 189, 248, 0.2);
  border-color: rgba(56, 189, 248, 0.7);
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.4);
}

/* ==========================================================================
   Filtro de Ruido Analógico Film Grain
   ========================================================================== */

.grain-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 40;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 300 300' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* ==========================================================================
   Orbes Luminosos Cyan en Movimiento Orgánico
   ========================================================================== */

.orb-container {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.luminous-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.38;
  mix-blend-mode: screen;
  pointer-events: none;
  will-change: transform;
}

.orb-1 {
  width: 440px;
  height: 440px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.5) 0%, rgba(56, 189, 248, 0.2) 50%, transparent 75%);
  top: 5%;
  left: -80px;
  animation: orbDrift1 18s ease-in-out infinite alternate;
}

.orb-2 {
  width: 460px;
  height: 460px;
  background: radial-gradient(circle, rgba(0, 240, 255, 0.38) 0%, rgba(0, 240, 255, 0.14) 50%, transparent 75%);
  top: 30%;
  right: -100px;
  animation: orbDrift2 22s ease-in-out infinite alternate;
}

.orb-3 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(14, 165, 233, 0.35) 0%, rgba(14, 165, 233, 0.12) 50%, transparent 75%);
  top: 60%;
  left: 5%;
  animation: orbDrift3 20s ease-in-out infinite alternate;
}

@keyframes orbDrift1 {
  0% { transform: translate(0px, 0px) scale(1); }
  50% { transform: translate(50px, 35px) scale(1.08); }
  100% { transform: translate(-30px, -25px) scale(0.95); }
}

@keyframes orbDrift2 {
  0% { transform: translate(0px, 0px) scale(1); }
  50% { transform: translate(-50px, 40px) scale(1.1); }
  100% { transform: translate(30px, -30px) scale(0.96); }
}

@keyframes orbDrift3 {
  0% { transform: translate(0px, 0px) scale(1); }
  50% { transform: translate(40px, -45px) scale(1.06); }
  100% { transform: translate(-25px, 30px) scale(0.94); }
}

/* ==========================================================================
   Cajas y Tarjetas con Resplandor Cyan Suave y Sofisticado
   ========================================================================== */

.glass-card {
  background: rgba(12, 13, 20, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.6);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.glass-card:hover {
  border-color: rgba(56, 189, 248, 0.42);
  background: rgba(14, 18, 28, 0.95);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px -10px rgba(0, 0, 0, 0.85),
              0 0 22px rgba(56, 189, 248, 0.25),
              0 0 35px rgba(0, 240, 255, 0.12);
}

@media (max-width: 640px) {
  .glass-card:hover {
    transform: none;
  }
}

/* ==========================================================================
   Google Maps Card & Localización en Modo Oscuro 3D
   ========================================================================== */

.map-3d-wrapper {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(56, 189, 248, 0.3);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9), 0 0 25px rgba(56, 189, 248, 0.2);
  background: #060912;
  transition: all 0.45s cubic-bezier(0.16, 1, 0.3, 1);
  perspective: 1000px;
}

.map-3d-wrapper:hover {
  border-color: rgba(0, 240, 255, 0.6);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.95), 0 0 35px rgba(56, 189, 248, 0.4);
  transform: translateY(-3px);
}

/* Filtro Inteligente de Modo Oscuro para Google Maps */
.map-3d-iframe {
  width: 100%;
  height: 390px;
  border: 0;
  display: block;
  filter: invert(90%) hue-rotate(180deg) contrast(115%) saturate(120%) brightness(95%);
  transition: filter 0.4s ease;
}

.map-3d-wrapper:hover .map-3d-iframe {
  filter: invert(88%) hue-rotate(180deg) contrast(120%) saturate(130%) brightness(100%);
}

@media (max-width: 640px) {
  .map-3d-iframe {
    height: 290px;
  }
}

/* ==========================================================================
   FAQ Accordion (Preguntas & Respuestas Interactivas)
   ========================================================================== */

.faq-accordion-item {
  border-radius: 20px;
  background: rgba(12, 13, 20, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.faq-accordion-item:hover,
.faq-accordion-item.is-active {
  border-color: rgba(56, 189, 248, 0.4);
  background: rgba(14, 18, 28, 0.9);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 15px rgba(56, 189, 248, 0.15);
}

.faq-accordion-header {
  padding: 18px 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  user-select: none;
}

.faq-accordion-body {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease, padding 0.3s ease;
  padding: 0 22px;
}

.faq-accordion-item.is-active .faq-accordion-body {
  max-height: 400px;
  opacity: 1;
  padding: 0 22px 20px 22px;
}

.faq-icon-chevron {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.faq-accordion-item.is-active .faq-icon-chevron {
  transform: rotate(180deg);
  color: #38bdf8;
}

/* ==========================================================================
   Asesor ADBA Flotante (Floating Assistant Widget)
   ========================================================================== */

.floating-agent-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 999;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  border-radius: 9999px;
  background: linear-gradient(135deg, #09131e 0%, #102235 100%);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7),
              0 0 18px rgba(56, 189, 248, 0.25);
  transition: all 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.floating-agent-btn:hover {
  transform: translateY(-3px) scale(1.03);
  border-color: rgba(56, 189, 248, 0.65);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.85),
              0 0 25px rgba(56, 189, 248, 0.45);
}

@media (max-width: 640px) {
  .floating-agent-btn {
    bottom: 18px;
    right: 18px;
    padding: 8px 14px;
    font-size: 12px;
  }
}

.floating-agent-window {
  position: fixed;
  bottom: 84px;
  right: 24px;
  width: 380px;
  max-width: calc(100vw - 32px);
  height: 540px;
  max-height: calc(100vh - 110px);
  z-index: 1000;
  border-radius: 28px;
  background: rgba(10, 15, 24, 0.96);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(56, 189, 248, 0.25);
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.9),
              0 0 25px rgba(56, 189, 248, 0.2);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.92) translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.floating-agent-window.is-open {
  transform: scale(1) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

@media (max-width: 640px) {
  .floating-agent-window {
    bottom: 74px;
    right: 16px;
    width: calc(100vw - 32px);
    height: calc(100vh - 95px);
  }
}

.chat-bubble-agent {
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: 18px 18px 18px 4px;
}

.chat-bubble-user {
  background: #38bdf8;
  color: #000000;
  border-radius: 18px 18px 4px 18px;
  font-weight: 700;
}


/* ==========================================================================
   Transiciones de Revelado al Scroll
   ========================================================================== */

.reveal-on-scroll {
  opacity: 0;
  transform: translateY(24px);
  filter: blur(2px);
  transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.75s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.75s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal-on-scroll.is-revealed {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

.stagger-1 { transition-delay: 0.06s; }
.stagger-2 { transition-delay: 0.12s; }
.stagger-3 { transition-delay: 0.18s; }
.stagger-4 { transition-delay: 0.24s; }
.stagger-5 { transition-delay: 0.30s; }
.stagger-6 { transition-delay: 0.36s; }

/* ==========================================================================
   Video Background en Hero (Informática & Sistemas con Cyber Canvas Fallback)
   ========================================================================== */

.hero-video-container {
  position: relative;
  overflow: hidden;
  background: #000000;
}

#cyberMatrixCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.35;
}

.hero-video-bg {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translateX(-50%) translateY(-50%);
  object-fit: cover;
  z-index: 1;
  opacity: 0.45;
  filter: contrast(1.15) brightness(0.9);
  pointer-events: none;
}

.hero-video-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.25) 0%, rgba(0, 0, 0, 0.85) 75%, #000000 100%),
              linear-gradient(180deg, rgba(0, 0, 0, 0.1) 0%, #000000 100%);
  z-index: 2;
  pointer-events: none;
}

/* ==========================================================================
   Botones y Nav
   ========================================================================== */

.glass-nav {
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-primary-adba {
  background: #ffffff;
  color: #000000;
  font-weight: 700;
  border-radius: 9999px;
  box-shadow: 0 8px 25px rgba(56, 189, 248, 0.25);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-primary-adba:hover {
  background: #38bdf8;
  color: #000000;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(56, 189, 248, 0.45);
}

/* Badge del Contador */
.visit-counter-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(56, 189, 248, 0.25);
  backdrop-filter: blur(12px);
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.1);
  transition: all 0.3s ease;
}

.visit-counter-badge:hover {
  border-color: rgba(56, 189, 248, 0.45);
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.2);
}

.counter-pulse {
  animation: counterPulse 2s infinite ease-in-out;
}

@keyframes counterPulse {
  0% { transform: scale(1); opacity: 0.8; }
  50% { transform: scale(1.3); opacity: 1; filter: drop-shadow(0 0 6px #38bdf8); }
  100% { transform: scale(1); opacity: 0.8; }
}

/* Scrollbar personalizada */
.custom-scrollbar::-webkit-scrollbar {
  width: 5px;
}
.custom-scrollbar::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.02);
}
.custom-scrollbar::-webkit-scrollbar-thumb {
  background: rgba(56, 189, 248, 0.25);
  border-radius: 9999px;
}
