/* ===========================
   ESTILOS PARA noticias.php
   =========================== */

   body {
    font-family: system-ui, "Segoe UI", Roboto, Arial, sans-serif;
    background: #f3f4f6;
    color: #1f2937;
    margin: 0;
  }
  
  /* Contenedor general */
  .w {
    max-width: 1100px;
    margin: auto;
    padding: 0 1rem;
  }
  
  /* ====== Títulos ====== */
  h1.page-title {
    text-align: center;
    color: #0f2a6d;
    margin: 1.5rem 0 1rem;
    font-size: 1.8rem;
  }
  .intro {
    text-align: center;
    font-size: 1rem;
    color: #374151;
    margin-bottom: 2rem;
  }
  
  /* ====== Índice de meses ====== */
  .indice-meses {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
  }
  .indice-meses a {
    text-decoration: none;
    background: #e5e7eb;
    color: #1f2937;
    padding: 6px 12px;
    border-radius: 8px;
    font-weight: 600;
    transition: 0.25s;
  }
  .indice-meses a.active,
  .indice-meses a:hover {
    background: #0f2a6d;
    color: #fff;
  }
  
  /* ====== Avisos Urgentes ====== */
  .avisos-urgentes {
    background: #fffbea;
    border-left: 6px solid #facc15;
    padding: 1rem 1.2rem;
    border-radius: 10px;
    margin-bottom: 2.5rem;
  }
  .avisos-urgentes h2 {
    margin-top: 0;
    color: #92400e;
  }
  .avisos-urgentes ul {
    margin: 0;
    padding-left: 1.2rem;
  }
  .avisos-urgentes li {
    margin-bottom: 8px;
    line-height: 1.45;
  }
  
  /* ====== Noticias por mes ====== */
  .noticias-mes {
    margin-bottom: 3.5rem;
  }
  .mes-title {
    color: #0f2a6d;
    font-size: 1.3rem;
    margin-bottom: 1rem;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 4px;
  }
  
  /* ====== Grid de noticias ====== */
  .noticias-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
  }
  
  /* ====== Tarjeta de noticia ====== */
  .noticia-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: 0.3s ease;
  }
  .noticia-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.12);
  }
  
  /* ====== Imagen de noticia ====== */
  .noticia-img-frame {
    width: 100%;
    height: 220px; /* altura uniforme */
    overflow: hidden;
    background: #f3f4f6;
    display: flex;
    align-items: left;
    justify-content: center;
  }
  .noticia-img-frame img {
    width: 100%;
    height: 100%;
    object-fit: contain;     /* ✅ mantiene toda la imagen visible */
    object-position: left;
    background: #fff;        /* relleno blanco si hay espacio */
    transition: transform 0.5s ease;
  }  
  .noticia-card:hover img {
    transform: scale(1.05);
  }
  
  /* ====== Contenido ====== */
  .noticia-body {
    padding: 1rem 1.2rem 1.3rem;
  }
  .noticia-body h2 {
    margin-top: 0;
    color: #b91c1c;
    font-size: 1.15rem;
  }
  .noticia-body .date {
    font-size: 0.9rem;
    color: #6b7280;
    margin-bottom: 6px;
  }
  .noticia-body p {
    margin: 0;
    color: #374151;
    line-height: 1.45;
  }
  /* Para banners horizontales (como Día de Muertos) */
.noticia-card.banner .noticia-img-frame {
  height: 320px; /* más alto para mostrar todo el diseño */
  background: #fff;
}

  @media (max-width: 600px) {
    .noticia-img-frame {
      height: 180px;
    }
    h1.page-title {
      font-size: 1.5rem;
    }
  }
  