/* ========= VARIABLES ========= */
:root {
  --azul-oscuro: #003366;        /* Azul oscuro principal */
  --azul-claro: #4A90E2;         /* Azul claro secundario */
  --verde-agua: #1ABC9C;         /* Verde agua suave */
  --gris-claro: #F5F7FA;         /* Fondo general */
  --gris-medio: #8A8D91;         /* Texto secundario y bordes */
  --blanco: #FFFFFF;
  --naranja: #f57c00;
  --texto-principal: #212529;
  --sombra-suave: rgba(0, 0, 0, 0.1);
  --fuente-principal: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  --azul-dropdown: #2c3e50;
  --azul-dropdown-hover: #34495e;
}

/* ========= BASE ========= */
body {
  font-family: var(--fuente-principal);
  line-height: 1.6;
  background-color: var(--gris-claro);
  color: var(--texto-principal);
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

a {
  text-decoration: none;
  color: var(--azul-oscuro);
}

a:hover {
  text-decoration: underline;
  color: var(--azul-claro);
}

/* ========= NAVBAR MEJORADO ========= */
.navbar {
  background-color: var(--azul-oscuro);
  padding: 1rem 2rem;
  box-shadow: 0 4px 14px rgba(0,0,0,0.15);
  position: sticky;
  top: 0;
  z-index: 1030;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.1);
  animation: fadeInDown 0.5s ease-out;
}

.navbar.scrolled {
  padding: 0.6rem 2rem;
  backdrop-filter: blur(8px);
  background-color: rgba(0, 40, 85, 0.95);
  box-shadow: 0 2px 12px rgba(0,0,0,0.18);
}

/* Logo */
.navbar-brand {
  font-weight: 800;
  font-size: 1.6rem;
  color: var(--blanco);
  display: flex;
  align-items: center;
  transition: transform 0.3s ease, color 0.3s ease;
}

.navbar-brand:hover {
  transform: scale(1.05);
  color: var(--naranja);
}

/* Nav Items */
.navbar-nav {
  align-items: center;
  margin-left: auto;
}

.nav-link {
  color: var(--blanco) !important;       /* siempre blanco al cargar */
  font-weight: 600;
  padding: 0.6rem 1.2rem;
  margin: 0 0.4rem;
  position: relative;
  display: flex;
  align-items: center;
  transition: all 0.3s ease;
}

/* Subrayado animado */
.nav-link::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background-color: var(--azul-claro); /* color del active/clic */
  border-radius: 2px;
  transition: width 0.3s ease;
}

/* Hover: naranja */
.nav-link:hover::before {
  width: 60%;
}

.nav-link:hover {
  color: var(--naranja) !important;
  transform: translateY(-2px);
}

/* Active: azul celeste */
.nav-link.active,
.nav-link:focus {
  color: var(--azul-claro) !important;
}

.nav-link.active::before,
.nav-link:focus::before {
  width: 60%;
}

/* Dropdown */
.dropdown-menu {
  background-color: var(--azul-dropdown);
  border-radius: 10px;
  border: none;
  box-shadow: 0 6px 20px rgba(0,0,0,0.2);
  margin-top: 0.5rem;
  min-width: 200px;
  transition: all 0.3s ease;
}

.dropdown-item {
  color: var(--blanco) !important; /* siempre blanco */
  padding: 0.6rem 1.2rem;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
  border-radius: 6px;
}

/* Hover en dropdown: naranja */
.dropdown-item:hover {
  background-color: var(--azul-dropdown-hover) !important;
  color: var(--naranja) !important;
}

/* Iconos dropdown */
.dropdown-item i {
  color: var(--naranja) !important;
}

/* Toggler (hamburguesa) */
.navbar-toggler {
  border: none;
  padding: 0.5rem;
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 2px var(--naranja);
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3e%3cpath stroke='rgba(255, 255, 255, 1)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
  transition: transform 0.3s ease;
}

.navbar-toggler:hover .navbar-toggler-icon {
  transform: rotate(90deg);
}

/* Responsive */
@media (max-width: 991.98px) {
  .navbar-collapse {
    background-color: var(--azul-oscuro);
    padding: 1rem;
    border-radius: 0 0 12px 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    margin-top: 0.5rem;
    transition: all 0.3s ease;
  }

  .nav-link {
    margin: 0.4rem 0;
    padding: 0.5rem 0;
    text-align: left; /* el texto queda a la izquierda */
  }

  .dropdown-menu {
    margin-left: 1rem;
    background-color: var(--azul-dropdown-hover);
  }
}

/* Animación navbar */
@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* ======================================== */
/* ESTADO DEL BOTÓN HAMBURGUESA */
/* ======================================== */

@media (max-width: 991.98px) {

.navbar-toggler {
border: 2px solid transparent !important;
border-radius: 6px;
padding: 0.5rem;
background-color: transparent !important;
outline: none !important;
transition: border-color 0.3s ease, box-shadow 0.3s ease !important;
}

/* El botón NO tiene efecto al pasar el mouse */
.navbar-toggler:hover {
background-color: transparent !important;
transform: none !important;
}

/* MENÚ ABIERTO → BORDE NARANJA */
.navbar-toggler[aria-expanded="true"] {
border: 2px solid var(--naranja) !important;
box-shadow: 0 0 0 2px rgba(255, 165, 0, 0.15) !important;
}

/* Mantener naranja mientras el menú está abierto */
.navbar-toggler[aria-expanded="true"]:hover,
.navbar-toggler[aria-expanded="true"]:focus,
.navbar-toggler[aria-expanded="true"]:active {
border: 2px solid var(--naranja) !important;
box-shadow: 0 0 0 2px rgba(255, 165, 0, 0.15) !important;
background-color: transparent !important;
transform: none !important;
}

/* MENÚ CERRADO → SIN BORDE */
.navbar-toggler[aria-expanded="false"] {
border: 2px solid transparent !important;
box-shadow: none !important;
}

/* Evitar rotación del icono */
.navbar-toggler-icon,
.navbar-toggler:hover .navbar-toggler-icon {
transform: none !important;
transition: none !important;
}
}

/* ========= FOOTER ========= */
.footer-dark {
  background-color: #0a0a0a;
  color: #f5f5f5;
  font-size: 0.95rem;
}

.footer-dark h5 {
  margin-bottom: 15px;
  font-weight: 600;
}

.footer-dark ul {
  padding-left: 0;
  list-style: none;
}

.footer-dark ul li {
  margin-bottom: 8px;
}

.footer-dark ul li a {
  color: #f5f5f5;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-dark ul li a:hover {
  color: #0d6efd;
}

.footer-dark .footer-social-icons i {
  font-size: 1.5rem;
  transition: transform 0.3s, color 0.3s;
}

.footer-dark .footer-social-icons i:hover {
  color: #0d6efd;
  transform: scale(1.2);
}

/* ====== RESPONSIVE ====== */
@media (max-width: 991.98px) {
  .col-md-3 {
    margin-bottom: 2rem;
  }
}

/* ====== AJUSTES PARA MÓVIL ====== */
@media (max-width: 576px) {
  footer {
    padding: 2rem 1rem;
    text-align: center;
  }
  
  footer .row > div {
    margin-bottom: 1.5rem;
  }

  footer .footer-social-icons {
    flex-direction: row !important; /* horizontal */
    justify-content: center !important;
  }

  footer .footer-social-icons a {
    font-size: 1.5rem;
    margin: 0 10px; /* espacio entre botones */
  }

  footer a {
    font-size: 1rem;
    display: block;
    margin-bottom: 0.5rem;
  }

  footer p, footer h5 {
    font-size: 1.1rem;
  }
}

/* ====== LLAMADO A LA ACCIÓN ====== */
.itsa-call-to-action {
  background: linear-gradient(135deg, #1a3a5f 0%, #3d6b99 100%);
  color: var(--blanco);
  padding: 4rem 0;
  position: relative;
  overflow: hidden;
}

.itsa-call-to-action::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
  animation: pulse 15s infinite alternate;
}

@keyframes pulse {
  0% { transform: translate(0, 0); }
  100% { transform: translate(50px, 50px); }
}

.cta-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  position: relative;
  z-index: 2;
  text-align: center;
}

.cta-content {
  max-width: 800px;
  margin: 0 auto;
}

.cta-title {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 1.2rem;
  line-height: 1.3;
  text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.cta-subtitle {
  font-size: 1.2rem;
  opacity: 0.9;
  margin-bottom: 2rem;
  line-height: 1.6;
}

/* Botón mejorado */
.btn-inscribete {
  background: linear-gradient(to right, var(--naranja), #ff9d00);
  color: var(--blanco);
  font-weight: 700;
  padding: 14px 36px;
  border-radius: 50px;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 4px 15px rgba(245, 124, 0, 0.3);
  border: none;
  position: relative;
  overflow: hidden;
  font-size: 1.1rem;
  letter-spacing: 0.5px;
}

.btn-inscribete::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: 0.5s;
}

.btn-inscribete:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(245, 124, 0, 0.4);
}

.btn-inscribete:hover::before {
  left: 100%;
}

/* Versión alternativa con icono */
.btn-inscribete.with-icon {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.btn-inscribete.with-icon i {
  transition: transform 0.3s ease;
}

.btn-inscribete.with-icon:hover i {
  transform: translateX(3px);
}

/* Responsive */
@media (max-width: 768px) {
  .itsa-call-to-action {
    padding: 3rem 0;
  }
  
  .cta-title {
    font-size: 1.8rem;
  }
  
  .cta-subtitle {
    font-size: 1.1rem;
  }
  
  .btn-inscribete {
    padding: 12px 28px;
    font-size: 1rem;
  }
}

@media (max-width: 576px) {
  .cta-title {
    font-size: 1.6rem;
  }
  
  .cta-subtitle {
    font-size: 1rem;
    margin-bottom: 1.5rem;
  }
}

/*======== BANNER ITSA ========*/
.banner-itsa {
  position: relative;
  height: 500px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.banner-itsa img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover; /* Mantiene proporción sin deformar */
  z-index: 0;
}

.banner-overlay {
  background: transparent; /* 🔹 Quitado el oscurecimiento */
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 1;
}

.banner-content {
  color: #fff;
  max-width: 700px;
  padding: 20px;
  text-align: center;
  position: relative;
  z-index: 2;
}

/* Animaciones por etapas */
.animate-title, .animate-text, .animate-btn {
  opacity: 0;
  transform: translateY(50px);
  animation-fill-mode: forwards;
}

.animate-title { animation: fadeInUp 1s ease 0.3s forwards; }
.animate-text { animation: fadeInUp 1s ease 0.8s forwards; }
.animate-btn  { animation: fadeInUp 1s ease 1.3s forwards; }

@keyframes fadeInUp {
  to { opacity: 1; transform: translateY(0); }
}

/* Textos */
.banner-content h1 { font-size: 2.5rem; font-weight: bold; margin-bottom: 20px; }
.banner-content p  { font-size: 1.2rem; margin-bottom: 25px; line-height: 1.6; }

/* Botón */
.banner-content .btn {
  padding: 12px 35px;
  font-size: 1.2rem;
  border-radius: 25px;
  text-transform: uppercase;
  transition: background 0.3s, transform 0.3s;
}
.banner-content .btn:hover {
  background-color: #e6c200;
  transform: translateY(-3px);
}

/* Responsivo */
@media (max-width: 768px) {
  .banner-itsa { height: 400px; }
  .banner-content h1 { font-size: 2rem; }
  .banner-content p  { font-size: 1rem; }
}

/* =========================
   Sección Convocatoria ITSA
   ========================= */

.itsa-convocatoria {
    background-color: #f8f9fa;
    color: #333;
    font-family: 'Segoe UI', sans-serif;
}

.itsa-convocatoria .row.align-items-stretch {
    align-items: stretch;
}

.itsa-convocatoria .card {
    border-radius: 12px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.itsa-convocatoria .card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}

/* Colores específicos de tarjetas */
.card-morning {
    border-left: 5px solid #0d6efd;
}
.card-night {
    border-left: 5px solid #6f42c1;
}
.card-bio {
    border-left: 5px solid #198754;
}

/* Iconos de carreras */
.itsa-convocatoria .bi {
    width: 1.5rem;
    height: 1.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Colores de iconos por carrera */
.card-morning .bi-heart-pulse-fill { color: #dc3545; }
.card-morning .bi-gear-fill { color: #ffc107; }
.card-morning .bi-basket-fill { color: #198754; }
.card-morning .bi-tree-fill { color: #20c997; }
.card-morning .bi-lightning-fill { color: #fd7e14; }

.card-night .bi-calculator-fill { color: #0dcaf0; }
.card-night .bi-building { color: #dc3545; }
.card-night .bi-laptop-fill { color: #0d6efd; }
.card-night .bi-person-badge-fill { color: #6c757d; }

/* Lista de carreras */
.itsa-convocatoria ul li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

/* Hover en iconos */
.itsa-convocatoria ul li i {
    transition: transform 0.3s;
}
.itsa-convocatoria ul li:hover i {
    transform: scale(1.2);
}

/* Titulos y textos */
.itsa-convocatoria .card-title {
    font-size: 1.2rem;
}
.itsa-convocatoria p {
    line-height: 1.6;
}
.itsa-convocatoria h3, .itsa-convocatoria h4 {
    color: #0d6efd;
}

/* Responsividad */
@media (max-width: 991px) {
    .itsa-convocatoria .card-body {
        padding: 1rem;
    }
    .itsa-convocatoria ul li {
        font-size: 0.95rem;
        gap: 0.6rem;
    }
}

@media (max-width: 575px) {
    .itsa-convocatoria .card-title {
        font-size: 1.1rem;
    }
    .itsa-convocatoria ul li {
        font-size: 0.9rem;
    }
    .itsa-convocatoria img.img-fluid {
        margin-bottom: 1rem;
    }
}

/* Tarjetas columna derecha */
.card-admission, .card-info {
    border-radius: 12px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.card-admission:hover, .card-info:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}

.card-admission {
    border-left: 5px solid #0d6efd; /* azul ITSA */
}

.card-info {
    border-left: 5px solid #6c757d; /* gris moderno */
}

.card-info img {
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
    object-fit: cover;
    height: 180px;
}

.card-admission i {
    margin-right: 0.5rem;
}

/* Responsividad */
@media (max-width: 991px) {
    .col-lg-5, .col-lg-7 {
        flex: 0 0 100%;
        max-width: 100%;
    }
    .card-info img {
        height: 150px;
    }
}
/* Justificar textos de la sección completa */
.itsa-convocatoria p,
.itsa-convocatoria li,
.itsa-convocatoria .card-body p,
.itsa-convocatoria .card-body li {
    text-align: justify;
    text-justify: inter-word;
}

