/* ===== ESTILOS GENERALES ===== */
body {
  font-family: "Roboto", sans-serif;
  margin: 0;
  padding: 0;
  /* Texto principal más oscuro para mejor contraste */
  color: #1e293b; /* slate-800 */
  background: #f8f9fa;
  line-height: 1.7;
  transition: background 0.3s ease, color 0.3s ease;
}

/* ===== BANNER ===== */
#bannerUD {
  position: relative;
  width: 100%;
  height: 260px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.banner-overlay {
  background: linear-gradient(135deg, rgba(24, 40, 72, 0.85), rgba(204, 34, 34, 0.75));
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 1s ease-in-out;
}

.banner-overlay h1 {
  font-size: 2.5em;
  font-weight: bold;
  text-align: center;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 2px;
  animation: slideDown 1.2s ease-out;
}

/* ===== CONTENIDO ===== */
.page-content {
  max-width: 1100px;
  margin: 50px auto;
  padding: 0 20px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 6px 25px rgba(0, 0, 0, 0.1);
  animation: fadeUp 1.2s ease;
}

.page-content h2 {
  margin-top: 40px;
  font-size: 1.8em;
  /* Color de acento institucional */
  color: #b91c1c; /* rojo IEBS */
  border-left: 6px solid #b91c1c;
  padding-left: 12px;
  font-weight: 500;
}

.page-content p,
.page-content li {
  font-size: 1.05em;
  margin-bottom: 15px;
}

.page-content a {
  color: #0f172a; /* enlaces ligeramente más oscuros */
  text-decoration: none;
  transition: color 0.2s ease;
}

.page-content a:hover {
  color: #b91c1c;
  text-decoration: underline;
}

/* Asegurar que los enlaces dentro de listas y el texto de las listas sean legibles */
.page-content ul li {
  color: inherit;
}

.page-content ul li a {
  color: inherit;
  display: inline-block;
}

/* Color de los marcadores (bullets) para mejor contraste */
.page-content ul li::marker {
  color: #b91c1c;
}

.page-content ul {
  margin: 20px 0 25px 30px;
  padding-left: 10px;
  list-style: disc;
}

.page-content ul li {
  padding-left: 5px;
  transition: transform 0.2s ease;
}

.page-content ul li:hover {
  transform: translateX(5px);
  color: #b91c1c;
}

/* ===== FOOTER ===== */
footer {
  background: linear-gradient(135deg, #182848, #cc2222);
  color: #f5f5f5;
  padding: 30px 20px;
  text-align: center;
}

.footer-container {
  max-width: 1200px;
  margin: auto;
}

.footer-links {
  margin-bottom: 15px;
}

.footer-links a {
  color: #f5f5f5;
  margin: 0 12px;
  text-decoration: none;
  font-weight: 500;
  position: relative;
  transition: color 0.3s ease;
}

.footer-links a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  display: block;
  background: #fff;
  transition: width 0.3s ease;
  left: 0;
  bottom: -4px;
}

.footer-links a:hover {
  color: #ffd166;
}

.footer-links a:hover::after {
  width: 100%;
}

footer p {
  font-size: 0.9em;
  margin-top: 10px;
  opacity: 0.9;
}

/* ===== ANIMACIONES ===== */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideDown {
  from { transform: translateY(-50px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeUp {
  from { transform: translateY(50px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* ===== MODO OSCURO ===== */
@media (prefers-color-scheme: dark) {
  body {
    background: #121212;
    color: #e5e5e5;
  }

  .page-content {
    background: #1e1e1e;
    color: #f0f0f0;
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.6);
  }

  .page-content h2 {
    color: #ff4d4d;
    border-left: 6px solid #ff4d4d;
  }

  footer {
    background: linear-gradient(135deg, #0d1b2a, #6a040f);
  }

  .footer-links a {
    color: #f0f0f0;
  }

  .footer-links a:hover {
    color: #ffd166;
  }

  /* En modo oscuro, forzar enlaces y marcadores legibles */
  .page-content a {
    color: #e5e7eb;
  }

  .page-content a:hover {
    color: #ffd166;
  }

  .page-content ul li {
    color: #e5e7eb;
  }

  .page-content ul li a {
    color: #e5e7eb;
  }

  .page-content ul li::marker {
    color: #ff6b6b;
  }
}
