/* ==========================================================================
   1. CONFIGURACIÓN GLOBAL Y CUERPO (BODY)
   ========================================================================== */
body {
  font-family: "Segoe UI", Arial, sans-serif;
  background-color: #f4f4f4;
  text-align: center;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Marca de Agua Polar al fondo */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-image: url("./imagenes/Logo/LogoNuevoPolarWeb.png");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  filter: none;
  z-index: -2;
  pointer-events: none;
  opacity: 0.2;
}

ul {
  list-style: none;
  padding: 0;
}

/* ==========================================================================
   2. CABECERA (HEADER)
   ========================================================================== */
header {
  background-color: transparent;
  padding: 40px 20px; /* Aumenté un poco para separar del borde superior */
  max-width: 1200px;
  margin: 0 auto 50px auto; /* El último valor separa el header de los planes */
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
}

header img {
  width: 200px;
  height: auto;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
}

header .text-container h1 {
  color: #660041;
  font-size: 3rem;
  margin: 0 0 10px 0;
  line-height: 1.2;
}

header .text-container p {
  color: #100f0f;
  font-size: 1.2rem;
  margin: 0;
}

/* ==========================================================================
   3. SECCIÓN DE PLANES
   ========================================================================== */
.planes-contenedor {
  max-width: 1200px;
  margin: 50px auto;
  padding: 40px 20px;
  background-color: rgba(197, 197, 197, 0.5);
  border-radius: 15px;
  text-align: center;
}

/* 🔥 ESTO SOLUCIONA TU PROBLEMA: Separa el título de las tarjetas */
.titulo-seccion {
  margin-bottom: 50px;
  color: #003366;
  font-size: 2.2rem;
}

.grid-planes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  justify-content: center;
  gap: 30px;
  margin: 0 auto;
}

/* Tarjetas individuales */
.tarjeta-plan {
  background: white;
  padding: 40px 30px;
  border-radius: 20px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  transition: 0.3s;
  position: relative;
  border: 1px solid #ddd;
}

.tarjeta-plan:hover {
  transform: translateY(-10px);
}

/* Plan Destacado (Tienda Virtual) */
.tarjeta-plan.destacado {
  border: 4px solid #ff914d;
  transform: scale(
    1.05
  ); /* Un poco menos agresivo que 1.08 para no romper el grid */
  z-index: 1;
}

.etiqueta-popular {
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  background: #ff914d;
  color: white;
  padding: 5px 15px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: bold;
}

/* Precios y listas */
.precio {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 20px 0;
  color: #333;
}

.precio span {
  display: block;
  font-size: 0.9rem;
  color: #003366;
  margin-top: 5px;
  font-weight: normal;
}

.tarjeta-plan ul li {
  text-align: left;
  margin-bottom: 15px;
  font-size: 0.95rem;
}

/* Botones de compra */
.btn-comprar {
  background: #003366;
  color: white;
  width: 100%;
  padding: 15px 0;
  border: none;
  border-radius: 10px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  display: block;
  text-align: center;
  text-decoration: none;
  box-sizing: border-box;
}

.destacado .btn-comprar {
  background: #ff914d;
}

.btn-comprar:hover {
  background: #00509d;
  transform: scale(1.02);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   4. PREGUNTAS FRECUENTES (FAQ)
   ========================================================================== */
.faq {
  max-width: 800px;
  margin: 80px auto;
  text-align: left;
  padding: 40px;
  background-color: rgba(197, 197, 197, 0.5);
  border-radius: 15px;
}

.faq h2 {
  text-align: center;
  color: #00509d;
  margin-bottom: 30px;
}

.faq-item {
  margin-bottom: 10px;
  border-bottom: 1px solid #ddd;
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 15px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  color: #000;
  display: flex;
  justify-content: space-between;
}

.faq-question:hover {
  color: #003366;
}

.faq-answer {
  padding: 0 15px 15px;
  color: #131111;
  line-height: 1.6;
}

/* ==========================================================================
   5. TECNOLOGÍAS
   ========================================================================== */
.tecnologias {
  padding: 50px 0;
  background: #e9e9e9;
  border-top: 1px solid #eee;
}

.tecnologias p {
  color: #010305;
  font-size: 0.9rem;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.iconos-tecnologias {
  display: flex;
  justify-content: center;
  gap: 40px;
  font-size: 2.5rem;
  color: #003366;
  opacity: 0.7;
}

.iconos-tecnologias i:hover {
  opacity: 1;
  transform: scale(1.2);
  transition: 0.3s;
}

/* ==========================================================================
   6. Footer
   ========================================================================== */
.contacto-seccion {
  padding: 60px 20px;
  background-color: rgba(197, 197, 197, 0.3); /* Transparente como el FAQ */
  margin: 50px auto;
  border-radius: 15px;
  max-width: 1000px;
}

.iconos-redes a {
  font-size: 2.5rem;
  color: #003366; /* Tu azul característico */
  margin: 0 15px;
  transition:
    transform 0.3s,
    color 0.3s;
  text-decoration: none;
  display: inline-block;
}

.iconos-redes a:hover {
  color: #ff914d; /* Naranja como el plan destacado */
  transform: translateY(-5px);
}

.btn-whatsapp {
  background-color: #25d366;
  color: white;
  padding: 12px 25px;
  border-radius: 50px;
  text-decoration: none;
  display: inline-block;
  margin-top: 20px;
  font-weight: bold;
}

/* ==========================================================================
   7. ADAPTABILIDAD MEDIA QUERIES
   ========================================================================== */

/* --- A. MÓVILES (Pantallas pequeñas hasta 600px) --- */
@media (max-width: 600px) {
  header {
    flex-direction: column;
    text-align: center;
    gap: 15px;
  }

  header img {
    width: 120px;
  }

  header .text-container h1 {
    font-size: 1.8rem;
  }

  .grid-planes,
  .grid-productos,
  .grid-mascotas {
    grid-template-columns: 1fr; /* Una sola columna en móvil */
    padding: 10px;
  }

  .faq {
    padding: 20px;
  }
}

/* --- B. TABLETS Y FOLD ABIERTO (601px hasta 1024px) --- */
@media (min-width: 601px) and (max-width: 1024px) {
  .grid-planes,
  .grid-productos,
  .grid-mascotas {
    grid-template-columns: repeat(2, 1fr); /* Dos columnas */
    gap: 20px;
    padding: 20px;
  }

  header .text-container h1,
  h1 {
    font-size: 2.5rem;
  }

  .hero-seccion {
    flex-direction: row;
    text-align: left;
    padding: 40px;
  }

  .tarjeta-producto img {
    height: 250px;
    object-fit: cover;
  }
}

/* --- C. PORTÁTILES Y PANTALLAS ESTÁNDAR (1025px hasta 1200px) --- */
@media (min-width: 1025px) and (max-width: 1200px) {
  .grid-planes {
    grid-template-columns: repeat(3, 1fr); /* Ya caben tres columnas */
  }
}

/* --- D. PANTALLAS GRANDES Y ALTA RESOLUCIÓN (Más de 1201px) --- */
@media (min-width: 1201px) {
  .planes-contenedor {
    max-width: 1300px;
  }

  .grid-planes {
    grid-template-columns: repeat(3, 1fr);
  }
}
