/* ============================
   PALETA / VARIABLES (Unificada)
   ============================ */
:root {
  /* Paleta "frozen" */
  --frozen-900: #1a1a1a;
  --frozen-800: #2b2b2b;
  --frozen-700: #3d3d3d;
  --frozen-600: #555555;
  --frozen-500: #777777;
  --frozen-400: #999999;
  --frozen-300: #bfbfbf;
  --frozen-200: #d9d9d9;
  --frozen-100: #f0f0f0;
  --frozen-050: #fafafa;
  --text-light: #333333;

  /* Paleta "g" (se usa dentro de noticias/listas) */
  --g-900:#1a1a1a; --g-800:#2b2b2b; --g-700:#3d3d3d; --g-600:#555;
  --g-500:#777; --g-400:#999; --g-300:#bfbfbf; --g-200:#d9d9d9;
  --g-100:#f0f0f0; --g-050:#fafafa;

  --hover-blue: #0b2e4f;

  /* Layout */
  --site-max: 1200px;
  --site-pad: 20px;
}

/* ============================
   NAVBAR
   ============================ */
header.navbar-frozen {
  background-color: #ffffff;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}
header.navbar-frozen .navbar-brand img {
  height: 48px;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.15));
}

header.navbar-frozen .nav-link {
  color: var(--frozen-800) !important;
  font-weight: 600;
  letter-spacing: .3px;
  padding: .5rem .9rem;
  margin: 0 .15rem;
  border-radius: 0;
  transition: all .25s ease;
  position: relative;
  z-index: 1;
}
header.navbar-frozen .nav-link:hover {
  color: #fff !important;
  background-color: var(--hover-blue);
  box-shadow: 0 0 10px rgba(11, 46, 79, 0.3);
  transform: translateY(-1px);
}
header.navbar-frozen .nav-link.active {
  background-color: var(--hover-blue);
  color: #fff !important;
  box-shadow: 0 0 6px rgba(11, 46, 79, 0.4);
  border-radius: 0;
}
.navbar-frozen .navbar-toggler {
  border: none;
  filter: invert(0.2) brightness(1.5);
}

/* ===== MENÚ DE ESCRITORIO (horizontal y limpio) ===== */
.main-menu {
  list-style: none;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* Ítems en línea */
.main-menu .nav-item {
  display: inline-block;
  margin: 0 4px;
}

/* Enlaces */
.main-menu .nav-link {
  color: var(--frozen-800) !important;
  font-weight: 600;
  text-decoration: none;
  padding: .5rem .8rem;
  transition: all .25s ease;
}

/* Hover y activo */
.main-menu .nav-link:hover {
  color: #fff !important;
  background-color: var(--hover-blue);
  box-shadow: 0 0 10px rgba(11, 46, 79, 0.3);
  border-radius: 4px;
}
.main-menu .nav-link.active {
  background-color: var(--hover-blue);
  color: #fff !important;
  border-radius: 4px;
  box-shadow: 0 0 6px rgba(11, 46, 79, 0.4);
}

/* Versión solo desktop */
@media (min-width: 992px) {
  /* Logo arriba, menú debajo y centrado */
  header.navbar-frozen .navbar .container {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  header.navbar-frozen .navbar-brand {
    margin-bottom: 12px;
  }

  .custom-toggler {
    display: none !important;  /* ocultar hamburguesa en desktop */
  }

  .menu-overlay {
    display: none !important;  /* overlay no se usa en desktop */
  }
}

/* ==========================================
   NOTICIAS DEL DÍA (base desktop)
   ========================================== */

/* CONTENEDOR SECCIÓN */
#noticias-del-dia {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  margin: 0 auto;
  padding: 2rem 1rem;
  background: transparent;
}

/* HEADER DEL TÍTULO (separado de la tarjeta) */
#noticias-del-dia .noticias-dia-header {
  width: 100%;
  text-align: center;
  margin-bottom: 1.25rem;
}
#noticias-del-dia .noticias-dia-header h2 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
  color: rgb(255, 255, 255)fff;
}

/* ==========================
   NUEVO DISEÑO DE TÍTULOS
   ========================== */

/* Noticias del día */
.titulo-noticias {
  background: linear-gradient(90deg, #0b2545 0%, #143d6b 100%);
  color: #fff;
  font-family: 'Merriweather', 'Georgia', serif;
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 14px 28px;
  border-radius: 6px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
  display: inline-block;
  position: relative;
  overflow: hidden;
}

/* Alinea el título con la tarjeta principal */
#noticias-del-dia .noticias-dia-header {
  text-align: left;
  max-width: 1100px;
  margin: 0 auto 1.25rem auto;
  padding-left: 1rem;
}

#noticias-del-dia .titulo-noticias {
  display: inline-block;
}

.titulo-noticias::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 20%;
  width: 60%;
  height: 3px;
  background-color: #ffcc00;
  border-radius: 2px;
}

/* Nuestra Voz */
.titulo-nuestra-voz {
  background: linear-gradient(90deg, #631515 0%, #a02c2c 100%);
  color: #fff;
  font-family: 'Merriweather', 'Georgia', serif;
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 14px 28px;
  border-radius: 6px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
  display: inline-block;
  position: relative;
  overflow: hidden;
}

.titulo-nuestra-voz::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 20%;
  width: 60%;
  height: 3px;
  background-color: #ffd700;
  border-radius: 2px;
}

/* Alineación para 'Nuestra Voz' */
#nuestra-voz .nuestra-voz__header {
  text-align: left;
  max-width: 1100px;
  margin: 0 auto 1.25rem auto;
  padding-left: 1rem;
}

#nuestra-voz .titulo-nuestra-voz {
  display: inline-block;
}

/* GRID PRINCIPAL DE LA SECCIÓN */
#noticias-del-dia .noticias-dia-grid {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: var(--site-max);
  margin: 0 auto;
  gap: 2rem;
}

/* TARJETA PRINCIPAL */
#noticias-del-dia .nd-main {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 0.5rem;
  background: #fff;
  border: 1px solid #eaeaea;
  box-shadow: 0 6px 20px rgba(0,0,0,.06);
  padding: 1rem;
}

/* Imagen principal */
#noticias-del-dia .nd-main figure,
#noticias-del-dia .nd-main .nd-main-thumb {
  margin: 0;
  padding: 0;
  width: 300px;
  height: 250px;
}

#noticias-del-dia .nd-main .nd-main-thumb img {
  width: 100%;
  height: 100%;
  height: auto;
  object-fit: cover;
}

/* Gap real entre columnas del grid principal */
#noticias-del-dia .nd-main {
  column-gap: 12px;
}

/* Por si algún heading trae márgenes laterales raros */
#noticias-del-dia .nd-main-content,
#noticias-del-dia .nd-main-content > * {
  margin-left: 0;
  padding-left: 0;
}

#noticias-del-dia .nd-main-content {
  text-align: left;
}

/* FIX ENLACES de la tarjeta principal */
#noticias-del-dia .nd-main-title a {
  color: var(--g-900);
  text-decoration: none;
}
#noticias-del-dia .nd-main-title a:hover {
  color: var(--hover-blue);
  text-decoration: none;
}

/* GRID INFERIOR (tarjetas) */
#noticias-del-dia .nd-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(240px, 1fr));
  justify-content: center;
  gap: 1rem;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
}
#noticias-del-dia .nd-item {
  background:#fff;
  border:1px solid #eee;
  padding:.75rem;
  display:grid;
  gap:.5rem;
  transition: transform .2s ease, box-shadow .2s ease;
}
#noticias-del-dia .nd-item:hover {
  transform: translateY(-2px);
  box-shadow:0 10px 24px rgba(11,46,79,.18);
}
#noticias-del-dia .nd-item-thumb img {
  width:100%;
  height:160px;
  object-fit:cover;
  display:block;
}
#noticias-del-dia .nd-item-content {
  text-align: left;
}

/* FIX ENLACES de cada tarjeta */
#noticias-del-dia .nd-item-title a {
  display: inline;
  color: var(--g-900);
  font-weight: 700;
  text-decoration: none;
  line-height: 1.25;
}
#noticias-del-dia .nd-item-title a:hover {
  color: var(--hover-blue);
  text-decoration: none;
}
#noticias-del-dia .nd-item-date {
  font-size:.8rem;
  color: var(--g-500);
}

/* SKELETONS */
.nd-skeleton {
  background: linear-gradient(90deg, var(--g-100), var(--g-050), var(--g-100));
  background-size: 200% 100%;
  animation: skel 1.2s infinite linear;
  border-radius: 6px;
}
.nd-skel-main { height: 220px; }
.nd-skel-item { height: 220px; }
@keyframes skel {
  0%{background-position:0% 0}
  100%{background-position:-200% 0}
}

/* ==========================================
   NUESTRA VOZ (base desktop)
   ========================================== */

.nuestra-voz {
  padding: 40px 0;
}

.nuestra-voz__header {
  display:flex;
  align-items:baseline;
  margin-bottom:20px;
}

/* TÍTULO AZUL */
.titulo-nuestra-voz,
#nuestra-voz .section-title,
#nuestra-voz .nuestra-voz__header h2 {
  background-color: #0b2545;
  color: #ffffff;
  font-family: 'Merriweather', 'Georgia', serif;
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 10px 20px;
  border-radius: 4px;
  display: inline-block;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  margin: 0 0 1.25rem 0;
}

/* GRID TARJETAS */
.nuestra-voz-grid {
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:1rem;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0;
}
.voz-card {
  background:#fff;
  border-radius:12px;
  overflow:hidden;
  box-shadow:0 1px 6px rgba(0,0,0,.06);
  transition:transform .25s ease, box-shadow .25s ease;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 0.75rem;
  display: grid;
  gap: 0.5rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.voz-card:hover {
  transform:translateY(-4px);
  box-shadow:0 8px 18px rgba(0,0,0,.10);
}
.voz-card.is-hidden { display:none; }
.voz-link {
  display:block;
  color:inherit;
  text-decoration:none;
  height:100%;
}
.voz-thumb img,
.voz-thumb__ph {
  width:100%;
  display:block;
  aspect-ratio:16/9;
  object-fit:cover;
  background:#f1f3f5;
}
.voz-title {
  font-size:1.1rem;
  line-height:1.35;
  padding:16px 14px 16px;
  text-align:center;
}
.nuestra-voz__actions {
  margin-top:20px;
  display:flex;
  justify-content:center;
}

/* ==========================================
   PIE DE PÁGINA (redes sociales con color)
   ========================================== */
.site-footer {
  background-color: #0b2545;
  color: #ffffff;
  padding: 40px 0;
  border-top: 4px solid #123860;
  font-family: 'Montserrat', sans-serif;
}

.footer-container {
  max-width: var(--site-max);
  margin: 0 auto;
  padding: 0 var(--site-pad);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

/* Redes sociales */
.footer-left {
  flex: 1 1 250px;
  display: flex;
  justify-content: flex-start;
}

.footer-social {
  display: flex;
  gap: 16px;
}

.social-link {
  color: var(--frozen-200);
  font-size: 1.7rem;
  transition: color 0.3s ease, transform 0.2s ease;
}

.social-link:hover {
  transform: translateY(-3px);
}

/* Colores oficiales */
.social-link.facebook:hover   { color: #1877F2; }
.social-link.instagram:hover  { color: #E4405F; }
.social-link.x-twitter:hover  { color: #1DA1F2; }
.social-link.youtube:hover    { color: #FF0000; }

/* Menú */
.footer-center {
  flex: 2 1 400px;
  text-align: center;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: inline-flex;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links a {
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--frozen-300);
}

/* Copyright */
.footer-right {
  flex: 1 1 250px;
  text-align: right;
}

.footer-copy {
  font-size: 0.9rem;
  color: var(--frozen-300);
  margin: 0;
}

/* ==== MENU OVERLAY – RESTRICCIÓN EN DESKTOP ==== */
@media (min-width: 992px) {
  .custom-toggler { display: none !important; }
  .menu-overlay { display: none !important; }
}

/* ===== Newsletter ===== */
:root{
  --newsletter-bg: #E1E6ED;
  --newsletter-blue: var(--hover-blue, #0b2e4f);
}

.newsletter-wrap{
  width: 100%;
  background: var(--newsletter-bg);
  padding: 64px 0;
}

.newsletter-inner{
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}

.newsletter-title{
  margin: 0 0 24px 0;
  font-weight: 700;
  color: var(--newsletter-blue);
  letter-spacing: .2px;
}

.newsletter-form{ margin: 0; }

.newsletter-fields{
  display: inline-flex;
  gap: 16px;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
}

.newsletter-fields input{
  width: 280px;
  height: 44px;
  background: #fff;
  border: 1px solid rgba(0,0,0,.12);
  border-radius: 6px;
  padding: 0 12px;
  font-size: 16px;
  outline: none;
  transition: box-shadow .2s ease, border-color .2s ease;
}

.newsletter-fields input:focus{
  border-color: rgba(11,46,79,.45);
  box-shadow: 0 0 0 3px rgba(11,46,79,.12);
}

.newsletter-btn{
  height: 44px;
  padding: 0 22px;
  border: 0;
  border-radius: 6px;
  background: var(--newsletter-blue);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}

.newsletter-btn:hover{
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(11,46,79,.22);
}

.newsletter-help{
  margin-top: 16px;
  color: #3b556e;
  font-size: 14px;
}

/* Accesibilidad: clase utilitaria para labels ocultos */
.visually-hidden{
  position: absolute !important;
  height: 1px; width: 1px;
  overflow: hidden; clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}

/* ===== Dropdown desktop ===== */

.main-menu .dropdown {
  position: relative;
}

.main-menu .dropdown-toggle .caret {
  font-size: 0.65rem;
  margin-left: 4px;
}

/* Caja del submenú */
.main-menu .dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  margin-top: 10px;
  padding: 8px 0;
  list-style: none;
  background-color: #ffffff;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
  z-index: 1000;
}

/* Mostrar submenú al pasar el mouse (versión hover clásica) */
.main-menu .dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* =============================
   DROPDOWNS DEL MENÚ DESKTOP
   ============================= */

.main-menu .nav-item {
  position: relative;
}

/* Flechita de los dropdowns */
.main-menu .dropdown-toggle .caret {
  font-size: 0.7rem;
  margin-left: 4px;
}

/* Caja del submenú (oculta por defecto) */
.main-menu .dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: #ffffff;
  list-style: none;
  margin: 8px 0 0;
  padding: 8px 0;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.16);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
  z-index: 1000;
}

/* Cuando el <li> tiene la clase .open (para JS desktop si lo usás) */
.main-menu .dropdown.open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* Links dentro del submenú */
.main-menu .dropdown-menu li a {
  display: block;
  padding: 8px 16px;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  color: #444;
  white-space: nowrap;
}

.main-menu .dropdown-menu li a:hover {
  background-color: #f3f3f3;
  color: #06d4e3;
}

/* Buscador en el menú */
.main-menu .search-item .nav-link i {
  font-size: 1.1rem;
}

/* Centrar menú en desktop */
@media (min-width: 992px) {
  header.navbar-frozen .navbar .container {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .main-menu {
    display: flex;
    gap: 8px;
  }
}

/* Ajustar estilos de dropdown al estilo del sitio */
.dropdown-menu {
  border-radius: 6px;
  box-shadow: 0 8px 18px rgba(0,0,0,0.15);
}

.dropdown-item:hover {
  background-color: #f2f2f2;
  color: #0066aa !important;
}

/* ===== Hover oscuro estilo periódico en menú desktop ===== */
@media (min-width: 992px) {
  header.navbar-frozen .navbar-nav.main-menu .nav-link {
    padding: 6px 8px;
    border-radius: 3px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .03em;
    color: #222 !important;
    transition: background .25s ease, color .25s ease;
  }

  header.navbar-frozen .navbar-nav.main-menu .nav-link:hover,
  header.navbar-frozen .navbar-nav.main-menu .nav-link:focus {
    background-color: #1f1f1f;
    color: #ffffff !important;
  }
}

/* Hover oscuro también dentro de los dropdown */
header.navbar-frozen .dropdown-menu .dropdown-item:hover,
header.navbar-frozen .dropdown-menu .dropdown-item:focus {
  background-color: #1f1f1f;
  color: #ffffff !important;
}
