/* ================= BASE ================= */
body{
  margin:0;
  background:#0b1220;
  color:#eaf0ff;
  font-family:Inter,sans-serif;
}

h1,h2,h3{
  font-family:Poppins,sans-serif;
}

.container{
  width:90%;
  max-width:1100px;
  margin:auto;
}

.narrow{max-width:800px}
.small{font-size:.9rem}
.muted{opacity:.7}

/* ================= HEADER ================= */
.header{
  position:sticky;
  top:0;
  background:#0f1a33;
  padding:10px 0;
  z-index:9999; /* 🔥 CLAVE */
}

.header-row{
  display:flex;
  justify-content:space-between;
  align-items:center;
}

.logo{height:42px}

/* ================= NAV ================= */
.nav-link{
  background:none;
  border:none;
  color:white;
  padding:8px 12px;
  cursor:pointer;
  font-size:1rem;
  position:relative;
  z-index:10000;
}

.nav-link:hover{
  color:#00bfa5;
}

.nav-link.active{
  color:#00bfa5;
  border-bottom:2px solid #00bfa5;
}

/* ================= SECTIONS ================= */
.view{
  display:none;
  padding:40px 0;
  position:relative;
  z-index:1;
}

.view.active{
  display:block;
}

/* ================= HERO ================= */
#inicio{
  min-height:100vh;
  padding:0;
}

.hero{
  background:url("assets/img/hero.jpg") center/cover no-repeat;
  position:relative;
}

/* 🔥 FIX CRÍTICO */
.overlay{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.6);
  pointer-events:none; /* 🔥 ESTO BLOQUEABA EL MENÚ */
}

.hero-inner{
  position:relative;
  z-index:2;
  padding:120px 0 80px;
  text-align:center;
}

.subtitle{opacity:.85}

/* ================= BOTONES ================= */
.hero-actions{margin:20px 0}

.btn{
  padding:10px 16px;
  border-radius:8px;
  cursor:pointer;
  border:none;
  font-size:1rem;
}

.primary{
  background:#00bfa5;
  color:#00251f;
}

.ghost{
  background:rgba(255,255,255,.1);
  color:white;
}

/* ================= STATS ================= */
.stats{
  display:flex;
  gap:20px;
  justify-content:center;
  margin-top:30px;
  flex-wrap:wrap;
}

.stat span{
  display:block;
  font-size:.9rem;
}

/* ================= TIMELINE ================= */
.timeline .item{
  background:#111b35;
  padding:16px;
  border-radius:12px;
  margin-bottom:16px;
}

.timeline img{
  width:100%;
  margin-top:10px;
  border-radius:10px;
}

/* ================= CONTACTO ================= */
.contact-container h2{
  margin-bottom:10px;
}

.contact-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(280px,1fr));
  gap:24px;
  margin-top:30px;
}

.contact-card{
  background:#111b35;
  border-radius:16px;
  padding:22px;
  box-shadow:0 8px 20px rgba(0,0,0,.35);
}

.contact-card h3{
  margin-bottom:16px;
  font-size:1.2rem;
}

.contact-item{
  display:flex;
  align-items:center;
  gap:16px;
  padding:14px;
  margin-bottom:12px;
  border-radius:12px;
  background:rgba(255,255,255,0.05);
  text-decoration:none;
  color:#eaf0ff;
  transition:background .3s,transform .3s;
  position:relative;
  z-index:5;
}

.contact-item:hover{
  background:rgba(0,191,165,0.15);
  transform:translateY(-2px);
}

.contact-item.whatsapp:hover{
  background:rgba(37,211,102,0.2);
}

.contact-item .icon{
  width:46px;
  height:46px;
  border-radius:12px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:rgba(255,255,255,0.08);
}

.icon i{
  font-size:1.8rem;
}

/* Colores */
.icon .fa-whatsapp{color:#25D366}
.icon.facebook i{color:#1877F2}
.icon.instagram i{
  background:linear-gradient(45deg,#f58529,#dd2a7b,#8134af,#515bd4);
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
}
.icon .fa-envelope{color:#f2f2f2}

/* Texto largo */
.contact-item div,
.contact-item strong{
  word-break:break-word;
  overflow-wrap:anywhere;
}

/* Autoridades */
.authority{
  margin-bottom:14px;
  padding-left:6px;
  line-height:1.5;
  border-left:3px solid #00bfa5;
}
/* =========================================
   FONDO HERO COMPARTIDO (SECCIONES)
========================================= */

.hero-bg {
  position: relative;
  background: url("assets/img/hero.jpg") center / cover no-repeat;
  padding: 80px 0;
}

/* Oscurece la imagen para mejor lectura */
.hero-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 0;
}

/* Asegura que el contenido esté encima */
.hero-bg > * {
  position: relative;
  z-index: 1;
}

/* =========================================
   SECCIONES SIN HERO
========================================= */

#brigadas,
#apoyos {
  background: #0b1220;
}

/* =========================================
   CORRECCIÓN DE ANCHO HERO
   (EXCLUYE INICIO)
========================================= */

.hero-bg:not(#inicio) .container,
.hero-bg:not(#inicio) .container.narrow {
  max-width: 900px;
  margin: auto;
  background: rgba(15, 26, 51, 0.78);
  padding: 40px 32px;
  border-radius: 16px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.45);
}

/* Ajustes específicos para móvil */
@media (max-width: 768px) {
  .hero-bg:not(#inicio) .container,
  .hero-bg:not(#inicio) .container.narrow {
    padding: 24px 18px;
    border-radius: 12px;
  }
}
