/* Asegura que el texto sea visible mientras carga la fuente */
@font-face {
  font-family: 'Inter';
  font-display: swap;
  src: local('Inter');
}

/* Ocultar video en móviles y mostrar imagen optimizada */
.desktop-video { display: block; }
.mobile-hero-img { display: none; }

@media (max-width: 768px) {
  .desktop-video { display: none !important; }
  .mobile-hero-img { 
    display: block; 
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: url('../assets/img/poster-consultoria-grc-cumplimiento-global.webp') center/cover no-repeat;
    z-index: 1;
  }
}

/* ================= RESET & BASE ================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', sans-serif;
  color: #111;
  background-color: #fff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  scroll-behavior: smooth; 
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.container-narrow {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

/* ================= HEADER & LOGO ================= */
.main-header {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  padding: 20px 0;
  z-index: 999;
  background: transparent !important;
}

/* Alineación para el selector de países */
.header-flex {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  width: 100%;
}

.logo {
  display: flex;
  justify-content: flex-start;
  background: transparent;
}

.logo img {
  height: 160px;
  width: 160px; 
  display: block;
  object-fit: contain;
  filter: drop-shadow(0px 4px 6px rgba(0,0,0,0.3));
}

/* Selector de Países */
.country-selector { position: relative; }

.dropbtn { 
  background: rgba(255,255,255,0.1); 
  color: white; 
  border: 1px solid rgba(255,255,255,0.3); 
  padding: 8px 15px; 
  border-radius: 4px; 
  cursor: pointer; 
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem; 
  backdrop-filter: blur(5px);
}

.dropdown-content { 
  display: none; 
  position: absolute; 
  right: 0; 
  background-color: #fff; 
  min-width: 160px; 
  box-shadow: 0px 8px 16px rgba(0,0,0,0.2); 
  z-index: 1000; 
  border-radius: 4px;
}

.dropdown-content a { 
  color: #111; 
  padding: 12px 16px; 
  text-decoration: none; 
  display: block; 
  font-size: 0.85rem; 
  text-align: left;
}

.dropdown-content a:hover { background-color: #f1f1f1; }
.dropdown:hover .dropdown-content { display: block; }

/* AJUSTES PARA CELULAR */
@media (max-width: 768px) {
  .header-flex { flex-direction: column; gap: 15px; }
  .logo { justify-content: center; }
  .logo img {
    width: 120px !important; 
    height: 120px !important; 
    max-width: 70vw; 
    max-height: 70vw;
    object-fit: contain;
  }
}

/* ================= HERO ================= */
.hero {
  position: relative;
  height: 70vh;
  max-height: 720px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

.hero-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.3);
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 3;
  text-align: center;
  color: #fff;
  width: 90%;
}

.hero-content h1 {
  font-size: 3.5rem;
  font-weight: 300;
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-bottom: 1rem;
}

.hero-sub {
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ================= SECTIONS & TYPO ================= */
.section { padding: 100px 0; }
.white { background: #fff; }
.dark { background: #111; color: #fff; }

.editorial {
  font-size: 2.4rem;
  font-weight: 300;
  line-height: 1.2;
  letter-spacing: -0.02em;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
}

.section h2 {
  font-size: 2.8rem;
  text-align: center;
  margin-bottom: 60px;
  font-weight: 700;
  letter-spacing: -0.03em;
}

/* ================= SERVICES ================= */
.services-grid {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}

.service-link {
  flex: 1;
  min-width: 220px;
  text-decoration: none; 
  color: inherit;         
  display: block;
  transition: transform 0.3s ease;
}

.service-link:hover { transform: translateY(-10px); }

.service { text-align: center; width: 100%; }

.service-icon {
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 30px;
}

.service-icon img {
  max-width: 90px;
  max-height: 100%;
  height: auto;
  object-fit: contain;
}

.service h3 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 15px;
  color: #000;
}

.service p {
  font-size: 0.95rem;
  color: #666;
  line-height: 1.6;
}

/* ================= AGENTES IA ================= */
.ai-agents { text-align: center; padding: 40px 0; }
.ai-logo-container { margin-bottom: 40px; }
.ai-shield { width: 120px; height: auto; display: block; margin: 0 auto; }
.ai-agents .editorial-septime {
  font-size: 1.6rem;
  line-height: 1.2;
  font-weight: 300;
  max-width: 700px;
  margin: 0 auto;
}

/* ================= CONTACTO & WHATSAPP ================= */
.contact { text-align: center; }
.whatsapp-link {
  color: #fff;
  text-decoration: none;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  transition: color 0.3s ease;
  margin-bottom: 20px;
}
.whatsapp-link svg { transition: transform 0.3s ease; }
.whatsapp-link:hover { color: #25D366; }
.whatsapp-link:hover svg { transform: scale(1.1); }

/* ================= FOOTER ================= */
.footer { padding: 60px 20px; text-align: center; font-size: 0.8rem; }

/* ================= RESPONSIVE GENERAL ================= */
@media (max-width: 1024px) {
  .hero-content h1 { font-size: 2.8rem; }
  .editorial { font-size: 1.8rem; }
  .section h2 { font-size: 2.2rem; }
}

@media (max-width: 768px) {
  .services-grid { flex-direction: column; align-items: center; }
  .service-link { width: 100%; margin-bottom: 40px; }
  .hero-content h1 { font-size: 2.2rem; }
  .editorial { font-size: 1.5rem; }
  .ai-shield { width: 80px; }
}

/* ================= SECCIONES ESPECIALES ADICIONALES ================= */
.section-with-bg { position: relative; overflow: hidden; }
.bg-media { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; z-index: 1; }
.bg-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.6); z-index: 2; }
.section-with-bg .container { position: relative; z-index: 3; }
.text-light { color: #fff !important; }
.text-light h2 { color: #fff !important; }

.iso-layout { background-color: #f9f9f9; display: flex; align-items: center; padding: 100px 0; }
.iso-grid { display: flex; align-items: center; justify-content: space-between; gap: 60px; }
.iso-content-left { flex: 1; text-align: left; }
.iso-content-left h2 { text-align: left; margin-bottom: 25px; font-size: 2.5rem; }
.iso-visual-right { flex: 1; display: flex; justify-content: center; position: relative; }
.floating-img { max-width: 100%; height: auto; filter: drop-shadow(0 20px 30px rgba(0,0,0,0.1)); border-radius: 20px; }

.powerbi-layout { background-color: #ffffff; padding: 100px 0; }
.powerbi-grid { display: flex; align-items: center; justify-content: space-between; gap: 60px; }
.powerbi-visual-left { flex: 1; display: flex; justify-content: center; }
.powerbi-content-right { flex: 1; text-align: left; }
.powerbi-content-right h2 { text-align: left; margin-bottom: 25px; }

.text-large { font-size: 1.25rem; line-height: 1.6; margin-top: 20px; font-weight: 300; }
.iso-layout .text-large, .powerbi-layout .text-large { color: #444; }

@media (max-width: 768px) {
  .iso-grid, .powerbi-grid { flex-direction: column; text-align: center; }
  .iso-content-left h2, .powerbi-content-right h2 { text-align: center; }
  .iso-visual-right { order: -1; margin-bottom: 40px; }
}

/* FAQ */
.faq-container { max-width: 900px; margin: 0 auto; padding-top: 40px; }
.faq-item { border-bottom: 1px solid #ddd; padding: 20px 0; }
.faq-header { display: flex; justify-content: space-between; align-items: center; cursor: pointer; width: 100%; text-align: left; }
.faq-header h3 { font-size: 1.2rem; color: #111; margin: 0; flex: 1; }
.faq-icon { font-size: 1.8rem; font-weight: 300; color: #000; margin-left: 20px; transition: transform 0.3s; }
.faq-content { max-height: 0; overflow: hidden; transition: max-height 0.4s ease; }
.faq-content p { padding: 15px 0 5px 0; color: #555; line-height: 1.6; font-size: 1rem; }
.faq-item.active .faq-icon { transform: rotate(45deg); }
.faq-item.active .faq-content { max-height: 500px; }

/* Forzar fuentes que soportan emojis en el selector de países */
.dropbtn, .dropdown-content a {
    font-family: 'Inter', "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji", sans-serif !important;
}

/* ACTIVAR MANTENIMIENTO GLOBAL */
/* MANTENIMIENTO PROFESIONAL - LOGO + VIDEO + TEXTO */
body > *:not(.hero):not(.main-header) {
    display: none !important; /* Oculta todo excepto el video y el logo */
}

/* 1. Forzamos que el Hero ocupe toda la pantalla y el video sea visible */
.hero {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9997 !important;
    display: flex !important;
}

/* 2. Forzamos que el Logo aparezca arriba sobre el video */
.main-header {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 9999 !important;
    background: transparent !important;
}

.logo img {
    display: block !important;
    opacity: 1 !important;
}

/* 3. El Selector de países lo ocultamos para que no distraiga */
.country-selector { display: none !important; }

/* 4. Cambiamos el texto del Hero dinámicamente */
.hero-content h1 {
    font-size: 0 !important; /* Ocultamos el H1 original */
}

.hero-content h1::after {
    content: "Nube VoIP";
    font-size: 3rem;
    display: block;
}

.hero-sub {
    font-size: 0 !important; /* Ocultamos el subtexto original */
}

.hero-sub::after {
    content: "Estamos en mantenimiento de nuestro portal";
    font-size: 1.5rem;
    color: #fff;
    display: block;
    margin-top: 15px;
    font-weight: bold;
}

/* ELIMINA O COMENTA ESTO EN TU ARCHIVO STYLE.CSS: */
/* body > *:not(.hero):not(.main-header) { display: none !important; } */