:root {
  --primary: #0066cc;
  --primary-dark: #004c99;
  --accent: #00d4ff;
  --dark: #1a1a1a;
  --light: #f8f9fa;
  --text: #333333;
  --text-light: #666666;
  --white: #ffffff;
  --shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  --radius: 12px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: "Poppins", sans-serif;
  color: var(--text);
  background-color: var(--white);
  line-height: 1.6;
}

/* --- NAVIGATION --- */
nav {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  padding: 0.8rem 5%;
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo img {
  height: 50px;
  width: auto;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;

  /* Flexbox para alinear icono y texto */
  display: flex;
  align-items: center;
  gap: 8px; /* Espacio entre el icono y el texto */

  transition: all 0.3s ease;
  position: relative;
}
.nav-links a i {
  font-size: 1.2rem; /* El icono un poco más grande que el texto */
  color: var(--primary); /* El icono siempre azul (opcional) */
  transition: transform 0.3s ease;
}

.nav-links a:hover {
  color: var(--primary);
}

.nav-links a:hover i {
  transform: translateY(-3px); /* El icono da un saltito al pasar el mouse */
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}
.mobile-menu-btn span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--primary);
  margin: 5px 0;
  transition: 0.3s;
}

/* --- HERO SECTION Y ANIMACIÓN --- */
.hero {
  height: 90vh;
  background-image: url("https://cavasinternet.com/Imagenes/imagen1.jpeg");
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: white;
  margin-top: 0;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    rgba(0, 102, 204, 0.7),
    rgba(0, 0, 0, 0.5)
  );
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 0 1rem;
  width: 100%;
  max-width: 900px; /* Ancho para que el logo quepa bien */
}

/* Estilos de la Animación del Logo */
#logo-container {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 2rem 0;
  margin-bottom: 2rem;
}

.logo-animation {
  width: 100%;
  height: auto;
  max-width: 800px; /* Tamaño máximo del logo */
}

.logo-path {
  fill: none;
  stroke: #ffffff;
  stroke-width: 3; /* Un poco más grueso para que se vea bien */
  stroke-dasharray: 7000;
  stroke-dashoffset: 7000;
  animation: drawLogo 18s ease forwards, fillLogo 2s 7s ease forwards;
}

.hero-subtitle {
  font-size: 1.5rem;
  margin-bottom: 2rem;
  font-weight: 300;
  opacity: 0.95;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.cta-button {
  display: inline-block;
  padding: 1rem 2.5rem;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s;
  cursor: pointer;
  border: none;
  font-size: 1rem;
}

.cta-button.primary {
  background: var(--white);
  color: var(--primary);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.cta-button.primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

/* --- SECTIONS GENERAL --- */
.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-header h2 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.section-header.white h2,
.section-header.white p {
  color: white;
}

.underline {
  width: 60px;
  height: 4px;
  background: var(--primary);
  margin: 0 auto;
  border-radius: 2px;
}

/* --- ABOUT US --- */
.about-us {
  padding: 5rem 5%;
  background-color: var(--white);
}

.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

.about-image img {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
  text-align: center;
}

.stat h3 {
  color: var(--primary);
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0;
}

/* --- FEATURES / PLANS --- */
.features {
  padding: 5rem 5%;
  position: relative;
  overflow: hidden;
  min-height: 100vh;
}

.background-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}

.features-overlay {
  position: relative;
  background: rgba(0, 0, 0, 0.6);
  padding: 5rem 0;
  min-height: 100vh;
}

.features-grid {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.feature-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  padding: 0;
  width: 300px;
  color: white;
  transition: transform 0.3s;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.feature-card:hover {
  transform: translateY(-10px);
  border-color: rgba(255, 255, 255, 0.5);
}

.feature-card.popular {
  background: rgba(0, 102, 204, 0.3);
  border: 1px solid var(--primary);
  transform: scale(1.05);
}

.feature-card.popular:hover {
  transform: scale(1.05) translateY(-10px);
}

.popular-tag {
  background: var(--primary);
  color: white;
  text-align: center;
  padding: 5px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
}

.card-header {
  padding: 2rem;
  text-align: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.card-header h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.price {
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1;
}

.currency {
  font-size: 1.5rem;
  vertical-align: top;
}
.period {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 400;
}

.card-body {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.feature-card ul {
  list-style: none;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.feature-card li {
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.check {
  color: #4ade80;
}

.cta-button.outline {
  background: transparent;
  border: 2px solid white;
  color: white;
  width: 100%;
}
.cta-button.outline:hover {
  background: white;
  color: var(--primary);
}

.cta-button.white-btn {
  background: white;
  color: var(--primary);
  width: 100%;
}

.disclaimer {
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  margin-top: 2rem;
  font-size: 0.9rem;
}

/* --- BENEFITS --- */
.benefits {
  padding: 5rem 5%;
  background-color: var(--light);
}

.tabs-container {
  max-width: 1000px;
  margin: 0 auto;
}

.tabs {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 3rem;
  flex-wrap: wrap; /* Para que en movil se ajusten */
}

.tab-button {
  padding: 0.8rem 2.5rem;
  border: 2px solid transparent;
  background: white;
  cursor: pointer;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-light);
  transition: all 0.3s;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.tab-button.active {
  background: var(--primary);
  color: white;
  box-shadow: 0 5px 15px rgba(0, 102, 204, 0.3);
}

.tab-panel {
  display: none;
  opacity: 0;
  transition: opacity 0.5s ease;
}
.tab-panel.active {
  display: block;
  opacity: 1;
}

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

.benefit-item {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.3s;
}

.benefit-item:hover {
  transform: translateY(-5px);
}

.benefit-item img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.benefit-content {
  padding: 1.5rem;
  text-align: center;
}

.benefit-content h3 {
  color: var(--primary);
  margin-bottom: 0.5rem;
}

/* --- COVERAGE (Grid de lugares) --- */
.coverage-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.map-container img {
  width: 100%;
  max-height: 400px;
  object-fit: contain;
}

/* Grid Inteligente para todos los nombres */
.locations-grid {
  display: grid;
  padding: 2rem;
  /* Esto crea columnas automáticas que se ajustan al espacio */
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
}

.loc-card {
  background: #a5a5a5;
  color: rgb(0, 0, 0);
  padding: 1rem;
  border-left: 4px solid var(--primary);
  border-radius: 4px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  font-size: 0.9rem;
  font-weight: 500;
  transition: 0.3s;
  /* Evita que el texto se rompa feo */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.loc-card:hover {
  background: var(--primary);
  color: white;
  transform: translateX(5px);
}

/* --- FOOTER --- */
.site-footer {
  background-color: var(--dark);
  color: #e0e0e0; /* Texto gris claro, no blanco puro para no cansar la vista */
  padding: 4rem 5% 1rem;
  margin-top: 4rem;
  font-size: 0.95rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-col h4 {
  color: var(--white);
  margin-bottom: 1.5rem;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  gap: 10px; /* Espacio entre icono de título y texto */
}

.footer-col h4 i {
  color: var(--primary); /* Iconos de título en azul */
}

/* Contact Items Styling */
.contact-item {
  display: flex;
  gap: 15px;
  margin-bottom: 1.2rem;
  align-items: flex-start;
}

.contact-item i {
  font-size: 1.4rem;
  color: var(--primary);
  margin-top: 3px;
}

.contact-item span {
  display: block;
  font-size: 0.8rem;
  color: #888;
  margin-bottom: 2px;
}

.contact-item a,
.contact-item p {
  color: white;
  text-decoration: none;
  margin: 0;
  line-height: 1.4;
}

/* Link Styling */
.footer-links {
  list-style: none;
  padding: 0;
}

.footer-links li {
  margin-bottom: 0.8rem;
}

.footer-links a {
  color: #ccc;
  text-decoration: none;
  transition: 0.3s;
  display: flex;
  align-items: center;
}

.footer-links a i {
  color: var(--primary);
  font-size: 1.2rem;
  transition: transform 0.3s;
}

.footer-links a:hover {
  color: white;
  padding-left: 5px;
}

.footer-links a:hover i {
  transform: translateX(3px); /* Mueve la flechita al pasar el mouse */
}

/* Social Media Icons Row */
.social-links {
  display: flex;
  gap: 1rem;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 45px;
  height: 45px;
  background: rgba(255, 255, 255, 0.1); /* Fondo semitransparente */
  border-radius: 50%; /* Círculos */
  color: white;
  font-size: 1.5rem;
  text-decoration: none;
  transition: all 0.3s ease;
}

.social-links a:hover {
  background: var(--primary); /* Se pone azul al pasar el mouse */
  transform: translateY(-5px); /* Flota hacia arriba */
  box-shadow: 0 5px 15px rgba(0, 102, 204, 0.4);
}

.footer-bottom {
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 3rem;
  padding-top: 2rem;
  color: #777;
  font-size: 0.9rem;
}
/* --- ANIMACIONES KEYFRAMES --- */
@keyframes drawLogo {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes fillLogo {
  from {
    fill: transparent;
    stroke-opacity: 1;
  }
  to {
    fill: #ffffff;
    stroke-opacity: 0; /* Opcional: si quieres que el borde desaparezca al llenarse */
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.fade-in {
  animation: fadeIn 0.8s ease forwards;
}

/* --- RESPONSIVE MOBILE --- */
@media (max-width: 768px) {
  .mobile-menu-btn {
    display: block;
    z-index: 1001;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    height: 100vh;
    background: white;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: 0.3s;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
  }

  .nav-links a {
    font-size: 1.2rem; /* Letra más grande en celular */
    width: 100%;
    justify-content: center; /* Centrar icono y texto en menú móvil */
    padding: 10px 0;
  }

  .nav-links.active {
    right: 0;
  }

  /* Ajustes para la animación en móvil */
  .logo-path {
    stroke-width: 5; /* Más grueso en móvil para visibilidad */
  }

  .about-content {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .about-image {
    order: -1;
  }

  .feature-card.popular {
    transform: scale(1);
  }
  .feature-card.popular:hover {
    transform: translateY(-10px);
  }

  .locations-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.locations-wrapper {
  position: relative;
  /* Altura inicial (aprox 4 o 5 filas) */
  max-height: 280px;
  overflow: hidden;
  /* Transición suave de la altura */
  transition: max-height 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.gradient-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100px;
  /* Gradiente de transparente a blanco para ocultar suavemente */
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0),
    rgb(230, 230, 230)
  );
  pointer-events: none;
  transition: opacity 1s ease;
}

/* Clase cuando está abierto */
.locations-wrapper.expanded {
  /* El max-height se sobrescribirá con JS, pero ponemos un valor alto por si acaso */
  max-height: 2000px;
}

.locations-wrapper.expanded .gradient-overlay {
  opacity: 0; /* Desaparece el gradiente al abrir */
}

.toggle-btn-container {
  text-align: center;
  margin-top: 1.5rem;
}

/* Estilo específico para este botón (texto oscuro) */
.cta-button.dark-text {
  color: var(--primary);
  border-color: var(--primary);
  background: transparent;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.cta-button.dark-text:hover {
  background: var(--primary);
  color: white;
}

.cta-button.dark-text i {
  font-size: 1.2rem;
  transition: transform 0.3s;
}

/* Rotar flecha al abrir */
.cta-button.dark-text.open i {
  transform: rotate(180deg);
}
