/* === Fondo metálico animado con overlay === */
.bg-metallic {
  background: linear-gradient(135deg, #d7d7d7, #f0f0f0, #c0c0c0);
  background-size: 400% 400%;
  animation: metallicShift 15s ease infinite;
  position: relative;
  z-index: 0;
}

@keyframes metallicShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.bg-metallic::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('../images/metal-texture-overlay.png'); /* imagen con transparencia */
  background-repeat: repeat;
  background-size: 512px 512px;
  opacity: 0.15;
  z-index: -1;
  pointer-events: none;
}

/* === Animación de entrada global === */
body.fade-in {
  opacity: 0;
  transition: opacity 0.6s ease-in;
}
body.loaded {
  opacity: 1;
}

/* === Tarjetas con borde metálico oscuro === */
.card.border-metallic,
.card.border-dark {
  border: 2px solid #444;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
  border-radius: 8px;
}
.card.border-metallic:hover {
  border-color: #00509e;
  box-shadow: 0 0 12px rgba(0, 80, 158, 0.3);
}

/* === Tarjetas con animación al pasar el mouse === */
.hover-scale {
  transition: transform 0.3s ease;
}
.hover-scale:hover {
  transform: scale(1.03);
}

/* === Fondo azul grisáceo suave === */
.bg-azul-suave {
  background-color: #e6ecf2;
}

/* === Encabezados principales === */
h1, h2, h3, .display-4, .display-5 {
  font-family: 'Segoe UI', sans-serif;
  font-weight: 700;
}

/* === Secciones === */
section {
  padding-top: 2rem;
  padding-bottom: 2rem;
}

/* === Imagen del banner y secciones === */
.hero-banner img,
section img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
}

/* === Botones personalizados === */
.btn-primary {
  background-color: #003366;
  border-color: #003366;
}
.btn-primary:hover {
  background-color: #00509e;
  border-color: #004080;
}

/* === Footer institucional === */
footer {
  background-color: #222;
  color: #ccc;
  padding: 2rem 0;
  text-align: center;
}

/* === Menú de navegación === */
.navbar {
  background-color: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(6px);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}
.navbar .nav-link,
.navbar-brand {
  color: #222 !important;
  font-weight: 600;
}
.navbar .nav-link:hover,
.navbar-brand:hover {
  color: #00509e !important;
  text-decoration: underline;
}

/* === Ícono hamburguesa oscuro === */
.navbar-toggler {
  border-color: #333;
}
.navbar-toggler-icon {
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(34,34,34,1)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
}

/* === Responsive ajustes adicionales === */
@media (max-width: 768px) {
  .display-4 {
    font-size: 2rem;
  }
  .lead {
    font-size: 1rem;
  }
  .navbar .nav-link {
    font-size: 0.95rem;
  }
}

/* === Animaciones suaves por sección === */
.seccion-animada {
  opacity: 0;
  transition: opacity 0.5s ease;
}
.seccion-animada.animate__animated {
  opacity: 1;
}
.seccion-animada.animate__fadeInUp,
.seccion-animada.animate__fadeIn,
.seccion-animada.animate__fadeInLeft,
.seccion-animada.animate__fadeInRight,
.seccion-animada.animate__zoomIn,
.seccion-animada.animate__slideInUp,
.seccion-animada.animate__bounceInUp,
.seccion-animada.animate__fadeInDown {
  animation-duration: 1.6s;
  animation-timing-function: ease-out;
}

/* === Peón institucional === */
.peon-bg {
  width: 325px;
  max-width: 30%;
  opacity: 0.35;
  z-index: 0;
  pointer-events: none;
  animation: peonFade 2s ease-out;
}
@keyframes peonFade {
  0% { transform: scale(0.8) translate(-50%, -50%); opacity: 0; }
  100% { transform: scale(1) translate(-50%, -50%); opacity: 0.35; }
}

#contacto .container {
  position: relative;
  z-index: 1;
}
