/* === RESET Y GENERAL === */
html {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

header {
  flex: 0 0 auto;
}

article {
  flex: 1 0 auto;
  padding-bottom: 40px;
}

.text-section p {
  font-size: 24px !important;
  line-height: 1.4;
  color: #333;
}

/* MODIFICACIÓN */
article > br + p {
    font-size: 40px !important;
    text-align: center !important;
    margin-top: 20px !important;
    margin-bottom: 30px !important;
    font-style: italic;
    color: #333;
}

footer {
  flex: 0 0 auto;
  width: 100%;
}

/* === BARRA DE NAVEGACIÓN === */
.navbar {
  background-color: #154360 !important;
  border: none;
  border-radius: 0;
  margin-bottom: 0;
}

/* === BOTONES ICYTEM === */
.btn-aceptar, 
.btn-regresar, 
.btn-regresar-plan {
  background-color: #154360 !important;
  color: #ffffff !important;
  padding: 8px 25px !important;
  border-radius: 5px !important;
  border: 1px solid #154360 !important;
  display: inline-block !important;
  font-size: 14px !important;
  margin: 10px 5px !important;
  text-align: center;
  cursor: pointer;
  width: auto !important;
}

/* === CARRUSEL CON MARCO === */
.carousel-inner {
  background: linear-gradient(to right, #ffffff, #dcdcdc, #ffffff);
  height: 450px !important;
}

.carousel-inner > .item {
  height: 450px !important;
  text-align: center;
}

.carousel-inner > .item > img {
  height: 100% !important;
  width: auto !important;
  margin: 0 auto;
  object-fit: contain;
}

.carousel-caption {
  bottom: 60px !important; 
  background: none !important; 
  border-radius: 0; 
  padding: 10px !important;
  left: 20% !important;
  right: 20% !important;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
}

/* === PLAN DE ESTUDIOS === */
.plan-container {
  display: flex;
  justify-content: center;
  gap: 30px;
  flex-wrap: wrap;
  padding: 20px;
}

.semester {
  background: #154360;
  color: white;
  padding: 12px;
  margin-bottom: 8px;
  border-radius: 5px;
  cursor: pointer;
  text-align: center;
  font-weight: bold;
}

.display-area { width: 500px; min-height: 400px; }

.subject-card { 
  display: grid; 
  grid-template-columns: 1fr; 
  gap: 8px; 
}

.card-item {
  background: #f9f9f9;
  padding: 10px;
  border: 1px solid #154360;
  border-radius: 5px;
}

/* === ESTILOS DEL PIE DE PÁGINA (Footer) === */
.footer-bar {
  width: 100%;
  background-color: #154360;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}

.footer-bar a {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #f2f2f2;
  text-decoration: none !important;
  padding: 14px 18px;
  font-size: 15px;
  transition: 0.3s;
}

.footer-bar a:hover {
  background-color: #A9CCE3;
  color: black;
}

.footer-bar img {
  height: 18px;
}

/* === RESPONSIVE CELULAR === */
@media(max-width:768px) {
  .carousel-inner, .carousel-inner > .item {
    height: 250px !important;
  }
  
  .carousel-caption {
    left: 5% !important;
    right: 5% !important;
    bottom: 40px !important;
  }

  .footer-bar {
    flex-direction: column;
    text-align: center;
  }
  
  .footer-bar a {
    justify-content: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }

  .plan-container { flex-direction: column; align-items: center; }
  .display-area { width: 100% !important; }
}
/* === AJUSTE PANTALLAS GRANDES === */
@media (min-width: 769px) {
  .plan-container {
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
  }
}

