/* ==========================================
  JARVIS: Estilos para la Asociación de Padres de Familia "Somos Celta"
  - Consolidación y mejora de estilos originales.
  - Se eliminan duplicados y se usan variables CSS de forma consistente.
  - Implementación de un diseño más robusto y accesible.
  ==========================================
*/

/* 1. Reset y Variables CSS */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;900&display=swap');

:root {
  --azul-celta: #0033A0;
  --verde-celta: #00B140;
  --verde-hover: #009E36;
  --fondo-claro: #f9f9f9;
  --gris-oscuro: #333333;
  --blanco: #ffffff;
  --azul-footer: #003366;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Montserrat', sans-serif;
  background-color: var(--fondo-claro);
  color: var(--gris-oscuro);
  line-height: 1.6;
}

.contenedor-centrado {
  max-width: 1024px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* 2. Encabezado y Navegación */
.hero-header {
  background-color: var(--azul-celta);
  color: var(--blanco);
  padding: 3rem 0 2rem;
  text-align: center;
  position: relative;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo {
  width: 140px;
  height: auto;
  transition: transform 0.3s ease;
}
.logo:hover {
  transform: scale(1.05);
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  margin: 0;
}

.nav-links li a {
  color: var(--blanco);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s;
}

.nav-links li a:hover {
  color: var(--verde-celta);
}

.hamburger {
  display: none;
  font-size: 2rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--blanco);
  z-index: 1001;
}

/* 3. Contenido Principal (Hero) */
.hero-content {
  padding: 2rem 0;
  animation: fadeIn 1s ease-out forwards;
}

.hero-content h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  margin: 0;
}

.hero-content .slogan {
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  font-weight: 600;
  margin: 0.5rem 0;
  text-transform: uppercase;
}

.hero-content .sub {
  font-size: clamp(1rem, 2vw, 1.1rem);
  max-width: 800px;
  margin: 1rem auto;
  opacity: 0.9;
}

/* 4. Secciones de Contenido */
.section {
  padding: 4rem 0;
}

.titulo-seccion {
  color: var(--azul-celta);
  font-size: clamp(2rem, 4vw, 2.5rem);
  margin-bottom: 2rem;
  font-weight: 700;
  text-align: center;
}

.section p {
  font-size: 1.1rem;
  line-height: 1.8;
  margin-bottom: 1.5rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* 5. Botones y Llamadas a la Acción */
.botonera {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 2rem;
}

.btn {
  background-color: var(--verde-celta);
  color: var(--blanco);
  text-decoration: none;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  font-weight: 700;
  transition: background-color 0.3s ease, transform 0.3s ease;
  white-space: nowrap;
}

.btn:hover {
  background-color: var(--verde-hover);
  transform: translateY(-3px);
}

/* 6. Pie de Página */
.site-footer {
  text-align: center;
  font-size: 0.9rem;
  background-color: var(--azul-footer);
  color: var(--blanco);
  padding: 2rem 1rem;
  margin-top: 3rem;
}

.site-footer a {
  color: var(--verde-celta);
  text-decoration: none;
  font-weight: bold;
}

.site-footer a:hover {
  text-decoration: underline;
}

/* 7. WhatsApp Flotante */
.whatsapp-float {
  position: fixed;
  width: 60px;
  height: 60px;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
  border-radius: 50%;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  transition: transform 0.3s ease;
}

.whatsapp-float:hover {
  transform: scale(1.1);
}

.whatsapp-float img {
  width: 100%;
  height: auto;
}

/* 8. Animaciones y Transiciones */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section-animated {
  opacity: 0;
  animation: fadeIn 1.2s ease-out forwards;
}

.delay-1 { animation-delay: 0.3s; }
.delay-2 { animation-delay: 0.6s; }

/* 9. Diseño Responsivo */
@media (max-width: 768px) {
  .navbar {
    flex-wrap: wrap;
    position: relative;
  }
  .nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    text-align: left;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: rgba(0, 51, 160, 0.95);
    z-index: 100;
    padding: 1rem 1.5rem;
    border-radius: 0 0 8px 8px;
    gap: 0.5rem;
  }
  .nav-links.active {
    display: flex;
  }
  .nav-links li a {
    padding: 0.5rem 0;
    display: block;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  .nav-links li:last-child a {
    border-bottom: none;
  }
  .hamburger {
    display: block;
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
  }
  .hero-content h1 {
    font-size: 2.5rem;
  }
  .hero-content .slogan {
    font-size: 1rem;
  }
  .hero-content .sub {
    font-size: 0.9rem;
    padding: 0 1rem;
  }
  .titulo-seccion {
    font-size: 2rem;
  }
  .section p {
    font-size: 1rem;
    text-align: left;
  }
  .botonera {
    flex-direction: column;
    align-items: center;
  }
  .btn {
    width: 100%;
    text-align: center;
    padding: 1rem;
  }
  .whatsapp-float {
    width: 50px;
    height: 50px;
  }
}