@import url('https://fonts.googleapis.com/css2?family=Fanwood+Text:ital@0;1&family=Raleway:wght@400;600;700&display=swap');

body {
  margin: 0;
  font-family: Arial, sans-serif;
  line-height: 1.7;
  background: #ecf7fd;
  color: #1f2d3d;
  position: relative;
  overflow-x: hidden;
}

#starfield {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  pointer-events: none;
  opacity: 0.2;
}

/* --- HEADER Y NAVEGACIÓN --- */
header {
  position: relative;
  overflow: visible;
  z-index: 1000; 
  background: #1a4a7a; /* Color sólido unificado con el footer */
  padding: 0.3rem 2rem; /* Barra más delgada */
  border-bottom: 3px solid #0d263d;
  color: #ffffff;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Estrellas titilantes en el header */
header::before,
header::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

header::before {
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.95) 1px, transparent 2px),
    radial-gradient(circle, rgba(255, 255, 255, 0.7) 1px, transparent 2px);
  background-size: 120px 120px, 170px 170px;
  background-position: 10px 20px, 50px 60px;
  animation: headerTwinkle 1.2s ease-in-out infinite;
}

header::after {
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.85) 1.2px, transparent 2.4px),
    radial-gradient(circle, rgba(255, 255, 255, 0.55) 1px, transparent 2px);
  background-size: 150px 150px, 210px 210px;
  background-position: 35px 40px, 90px 25px;
  animation: headerTwinkle 1.6s ease-in-out infinite reverse;
}

header > * {
  position: relative;
  z-index: 1;
}

@keyframes headerTwinkle {
  0%, 100% { opacity: 0.45; }
  50% { opacity: 0.95; }
}

.header-identity {
  display: flex;
  align-items: center;
}

/* Controla el tamaño del logo nuevo para que la barra sea delgada */
.header-logo-main {
  height: 50px; 
  width: auto;
  display: block;
}

nav {
  display: flex;
  align-items: center;
}

nav ul {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 2px; /* Reducido ligeramente para acomodar más botones */
}

nav li {
  position: relative;
}

nav a,
nav button {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  background: transparent;
  padding: 8px 12px; /* Ligeramente más delgado */
  border: none;
  border-bottom: 2px solid transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-weight: bold;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-family: 'Impact', 'Charcoal', 'Arial Black', sans-serif;
  font-size: 0.95rem; /* Ajustado para que entren todos los botones */
  cursor: pointer;
  min-height: 38px;
  box-sizing: border-box;
  transition: color 0.2s ease, border-color 0.2s ease;
}

nav a:hover,
nav a:focus,
nav button:hover,
nav button:focus {
  color: #ffffff;
  border-bottom-color: rgba(255, 255, 255, 0.7);
}

nav a[aria-current="page"] {
  color: #ffffff;
  border-bottom: 2px solid #ffffff;
}

nav a:focus,
nav button:focus {
  outline: 2px solid rgba(255, 255, 0, 0.7);
  outline-offset: 3px;
  border-radius: 2px;
}

/* Submenú Desplegable (Para Servicios) */
.submenu {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  min-width: 180px;
  list-style: none;
  margin: 0;
  padding: 8px;
  background: rgba(26, 74, 122, 0.98);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  z-index: 1001;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
  animation: submenuFadeIn 0.18s ease;
}

@keyframes submenuFadeIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.submenu li {
  margin: 2px 0;
}

.submenu a {
  display: flex;
  justify-content: flex-start;
  width: 100%;
  box-sizing: border-box;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  font-size: 0.85rem;
  font-family: 'Raleway', Arial, sans-serif;
  text-transform: none;
  padding: 8px 12px;
  transition: background 0.18s ease, padding-left 0.18s ease;
}

.submenu a:hover,
.submenu a:focus {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  padding-left: 18px;
}

.has-submenu:hover .submenu,
.has-submenu:focus-within .submenu,
.has-submenu.open .submenu {
  display: block;
}

/* --- SECCIÓN HERO (VIDEO FULL WIDTH HORIZONTAL) --- */
.hero-full-width {
  position: relative;
  width: 100%;
  height: 55vh;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1; 
}

.hero-full-width video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translate(-50%, -50%);
  z-index: -1; 
  object-fit: cover;
}

.video-overlay-box {
  position: relative;
  z-index: 10; 
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 2rem 4rem;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.video-overlay-box h2 {
  color: #ffffff;
  font-family: 'Impact', 'Charcoal', 'Arial Black', sans-serif;
  font-size: clamp(2rem, 4vw, 3.5rem);
  margin: 0;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.6);
  text-align: center;
  border: none;
  padding: 0;
  text-transform: uppercase;
  letter-spacing: 2px;
}

/* --- CONTENIDO PRINCIPAL --- */
main {
  max-width: 1000px;
  margin: 32px auto;
  padding: 10px 20px 50px 20px;
}

section {
  background: #ffffff;
  border: 1px solid #d1e9f6;
  border-top: 4px solid #4cb3df;
  border-radius: 10px;
  padding: 28px;
  box-shadow: 0 10px 24px rgba(15, 35, 54, 0.08);
}

h2 {
  border-bottom: 2px solid #4cb3df;
  padding-bottom: 8px;
  color: #217eab;
  margin-top: 0;
  font-family: 'Raleway', Arial, sans-serif;
}

.section-badge {
  display: inline-block;
  background: #2d97c9;
  color: #ffffff;
  font-family: Arial, sans-serif;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 6px 18px;
  border-radius: 6px;
  margin: 1.4rem 0 0.8rem 0;
  box-shadow: 0 2px 8px rgba(12, 60, 100, 0.18);
}

/* --- SERVICIOS GRID --- */
.servicios-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin: 1.2rem 0 1.6rem 0;
}

.servicio-card {
  display: block;
  background: #f7fbff;
  border: 1px solid #d1e9f6;
  border-radius: 12px;
  padding: 1.4rem 1.3rem;
  color: #0d3a5c;
  text-decoration: none;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.servicio-card:hover,
.servicio-card:focus {
  transform: translateY(-2px);
  box-shadow: 0 12px 22px rgba(15, 35, 54, 0.1);
  border-color: #4cb3df;
}

.servicio-card h3 {
  margin: 0 0 0.7rem 0;
  font-size: 1.15rem;
  color: #217eab;
}

.servicio-card p {
  margin: 0;
  line-height: 1.7;
}

img {
  max-width: 100%;
  height: auto;
}

p {
  text-align: justify;
}

/* --- FOOTER --- */
.site-footer {
  text-align: center;
  margin-top: 40px;
  padding: 20px 16px;
  background: #1a4a7a; /* Mismo color que el header */
  border-top: 3px solid #0d263d;
  color: #ffffff;
}

.footer-center-text {
  margin: 0;
  text-align: center;
  font-weight: 700;
  line-height: 1.5;
  font-size: 0.9rem;
}

.footer-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 10px;
}

.footer-text {
  flex: 1;
  text-align: center;
  margin: 1.2rem;
}

.footer-logos {
  display: flex;
  align-items: center;
  flex-direction: column;
}

.footer-left,
.footer-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.footer-social {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin: 10px 0 4px 0;
}

.social-link {
  color: #ffffff;
  font-size: 2rem;
  transition: color 0.2s ease, transform 0.2s ease;
  text-decoration: none;
}

.social-link:hover {
  color: #d0eeff;
  transform: scale(1.15);
}

.footer-ucr-logo,
.footer-cinespa-logo,
.footer-logo {
  max-height: 80px;
  width: auto;
}

/* --- ACCESIBILIDAD --- */
.skip-link {
  position: absolute;
  left: -999px;
  z-index: 100;
}

.skip-link:focus {
  left: 10px;
  top: 10px;
  background: #dff5ff;
  color: #14577a;
  padding: 5px;
}

/* Cursor por defecto */
body.cursor-star-enabled,
body.cursor-star-enabled * {
  cursor: auto !important;
}

.cursor-star, .cursor-trail { 
  display: none !important; 
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* --- MEDIA QUERIES (RESPONSIVE) --- */
@media (max-width: 950px) {
  nav ul {
    flex-wrap: wrap; /* Permite que los botones bajen si la pantalla es muy pequeña */
    justify-content: center;
  }
}

@media (max-width: 850px) {
  header {
    flex-direction: column;
    padding: 0.8rem;
    gap: 0.5rem;
  }
  
  .header-identity {
    align-items: center;
    text-align: center;
  }

  nav ul {
    justify-content: center;
  }
}

@media (max-width: 700px) {
  nav > ul {
    flex-direction: column;
    align-items: stretch;
    border-bottom: none;
  }

  nav > ul > li {
    width: 100%;
  }

  nav a,
  nav button {
    width: 100%;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 10px 4px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  }

  .submenu {
    position: static;
    top: auto;
    right: auto;
    min-width: 0;
    margin-top: 6px;
    box-shadow: none;
  }

  .servicios-grid {
    grid-template-columns: 1fr;
  }

  .footer-main {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer-left,
  .footer-right {
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin: 0.6rem 0;
  }

  .footer-logos img {
    max-height: 60px;
    width: auto;
  }
}

/* ==========================================================================
   AÑADIR ESTO AL FINAL PARA LA PÁGINA "ACERCA"
   ========================================================================== */

  /* 1. Título de Sección Centrado (Úsalo en acerca.html como <h2 class="centered-title">) */
.centered-title {
  text-align: center;
  margin: 2rem 0 3rem 0;
  font-size: 2.5rem;
  color: #1a4a7a;
  font-family: 'Raleway', sans-serif;
  text-transform: uppercase;
  letter-spacing: 2px;
  border: none; /* Quita la línea de abajo estándar de los h2 */
}

/* Definición de Celdas */
.cell-carousel {
  grid-column: 1;
  grid-row: 1;
}

.cell-history {
  grid-column: 2;
  grid-row: 1;
}

.cell-team {
  grid-column: 1 / span 2; /* Ocupa las dos columnas abajo */
  grid-row: 2;
}

/* 3. Estilos de las Tarjetas (Info Cards) */
.info-card {
  height: 100%;
  background: #ffffff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  border-top: 4px solid #1a4a7a;
  border-left: 1px solid #d1e9f6;
  border-right: 1px solid #d1e9f6;
  border-bottom: 1px solid #d1e9f6;
  box-sizing: border-box;
}

.info-card h3 {
  color: #1a4a7a;
  margin-top: 0;
  border-bottom: 2px solid #4cb3df;
  padding-bottom: 8px;
  margin-bottom: 1.2rem;
  font-family: 'Raleway', sans-serif;
}

/* 4. Grid del Equipo */
.team-grid-simple {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 1rem;
}

.team-member {
  background: #f7fbff;
  padding: 15px;
  border-radius: 8px;
  border: 1px solid #d1e9f6;
}

.team-member strong {
  display: block;
  color: #1a4a7a;
  font-size: 1.1rem;
  margin-bottom: 5px;
}

/* 5. Ajuste del Carrusel para que no se deforme */
.carousel {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 15px rgba(0,0,0,0.15);
  height: 100%; /* Para que llene la celda */
}

.slide img {
  width: 100%;
  height: 400px; /* Altura fija recomendada */
  object-fit: cover;
}

/* 6. Ajuste Responsive para este diseño */
@media (max-width: 900px) {
  .acerca-container {
  display: grid;
  /* 0.6fr para el mapa (pequeño) y 1.4fr para la historia (ancho) */
  grid-template-columns: 0.6fr 1.4fr; 
  grid-template-rows: auto auto;
  gap: 30px;
  max-width: 1100px;
  margin: 0 auto 4rem auto;
  }
  
  .cell-carousel { /* Esta es la celda del Mapa */
    grid-column: 1;
    grid-row: 1;
  }

  .cell-history { /* Esta es la celda de la Historia */
    grid-column: 2;
    grid-row: 1;
  }

  .cell-team { /* La parte de abajo que ocupa todo el ancho */
    grid-column: 1 / span 2;
    grid-row: 2;
  }

  .slide img {
    height: 300px;
  }
}


.cell-carousel { /* Esta es la celda del Mapa */
  grid-column: 1;
  grid-row: 1;
}

.cell-history { /* Esta es la celda de la Historia */
  grid-column: 2;
  grid-row: 1;
}

.cell-team { /* La parte de abajo que ocupa todo el ancho */
  grid-column: 1 / span 2;
  grid-row: 2;
}

.slide img {
  height: 300px;
}

/* Contenedor principal de la página Acerca */
/* ==========================================================================
   DISEÑO GLOBAL Y RESET (PÁGINA ACERCA)
   ========================================================================== */

.acerca-container {
  display: grid;
  grid-template-columns: 1fr 1fr; 
  grid-template-rows: auto;
  gap: 30px;
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 20px;
}

/* --- CONTROL DE CELDAS --- */

.cell-history {
  /* La historia abarca las dos columnas de la primera fila */
  grid-column: 1 / span 2;
  grid-row: 1;
}

.cell-location {
  /* Ubicación va en la primera columna de la segunda fila */
  grid-column: 1;
  grid-row: 2;
  min-width: 0; 
}

.cell-people {
  /* Equipo va en la segunda columna de la segunda fila */
  grid-column: 2;
  grid-row: 2;
  min-width: 0;
}

/* --- ESTILO DE LAS TARJETAS (INFO CARDS) --- */

.info-card {
  height: 100%;
  background: #ffffff;
  padding: 2rem;
  border-radius: 15px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  border-top: 5px solid #1a4a7a; /* Borde superior grueso azul */
  border-left: 1px solid #d1e9f6;
  border-right: 1px solid #d1e9f6;
  border-bottom: 1px solid #d1e9f6;
  box-sizing: border-box;
  color: #333;
}

.info-card h3 {
  color: #1a4a7a;
  text-align: center;
  margin-top: 0;
  margin-bottom: 1.5rem;
  font-family: 'Raleway', sans-serif;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 2px solid #4cb3df;
  padding-bottom: 10px;
}

/* --- DISEÑO DEL CARRUSEL DE PERSONAL --- */

.carousel-container {
  width: 100%;
  overflow: hidden; /* Ventana que recorta el contenido */
  position: relative;
  background: #fdfdfd;
  border-radius: 10px;
}

.carousel-track {
  display: flex;
  /* 5 secciones de 100% cada una = 500% de ancho */
  width: 500%; 
  transition: transform 0.8s cubic-bezier(0.45, 0.05, 0.55, 0.95);
}

.carousel-section {
  width: 20%; 
  flex-shrink: 0;
  padding: 20px;
  box-sizing: border-box;
}

.carousel-section h4 {
  color: #217eab;
  text-align: center;
  margin-top: 0;
  font-size: 1.1rem;
  margin-bottom: 15px;
}

/* --- GRID DE LAS FICHAS DE PERSONAL --- */

/* Contenedor de la lista de personal en la sección */
.staff-grid {
  display: flex;
  flex-direction: column; /* Apila las fichas una sobre otra */
  gap: 12px;
  justify-content: flex-start;
}

/* La ficha individual ahora es horizontal */
/* Ficha horizontal tipo lista */
.staff-card {
  display: flex;
  align-items: center;   /* Centra la imagen y el texto verticalmente entre sí */
  background: #f7fbff;
  padding: 10px 15px;
  border-radius: 10px;
  border: 1px solid #d1e9f6;
  gap: 15px;             /* Espacio entre foto y texto */
  transition: transform 0.3s ease;
} 

.staff-card:hover {
  transform: translateX(10px); /* Efecto de desplazamiento a la derecha */
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* Ajuste de la foto para el formato lista */
.staff-img {
  width: 55px;
  height: 55px;
  flex-shrink: 0;
  border-radius: 50%;
  background-color: #ccddec;
  border: 2px solid #ffffff;
  background-size: cover;
}

.staff-card p {
  margin: 0;
  text-align: left;      /* Alinea el texto a la izquierda del contenedor de texto */
  display: flex;
  flex-direction: column;
  justify-content: center; /* Asegura el centrado vertical del bloque de texto */
  line-height: 1.2;
}

.staff-card strong {
  color: #1a4a7a;
  font-size: 1rem;
  margin-bottom: 2px;
}

/* Ajuste para que el carrusel no se vea muy vacío */
.carousel-section h4 {
  color: #1a4a7a;
  text-align: center;    /* Centra el título de la categoría (Dirección, Asistentes, etc) */
  margin-bottom: 15px;
  font-size: 1.1rem;
  text-transform: uppercase;
  border-bottom: 1px solid #4cb3df;
  padding-bottom: 5px;
}

/* --- RESPONSIVE --- */
@media (max-width: 600px) {
  .staff-card {
    padding: 10px;
    gap: 15px;
  }
  
  .staff-img {
    width: 50px;
    height: 50px;
  }
  
  .staff-card strong {
    font-size: 0.95rem;
  }
}

/* --- ESTILOS PARA LOS BOTONES DEL CARRUSEL --- */

/* Contenedor de los botones */
.carousel-controls {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 15px;
  padding-bottom: 5px;
}

/* Botón individual circular */
.nav-btn {
  background: #1a4a7a;
  color: white;
  border: none;
  border-radius: 50%;
  width: 28px;
  height: 28px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Efecto al pasar el mouse */
.nav-btn:hover {
  background: #4cb3df;
  transform: scale(1.1);
}

/* Efecto al hacer clic */
.nav-btn:active {
  transform: scale(0.9);
}

/* Ajuste necesario en la tarjeta para que los botones queden abajo */
.cell-people .info-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between; /* Empuja los botones al fondo */
  min-height: 450px; /* Asegura un tamaño consistente */
}

/* Evita que el carrusel se deforme al añadir los botones */
.carousel-container {
  flex: 1; 
  min-width: 0;
}

/* --- CONFIGURACIÓN DE LA NUEVA CELDA --- */
.cell-gallery {
  grid-column: 1 / span 2; /* Ancho completo igual que historia */
}

.gallery-card {
  padding: 0 !important; /* Para que la imagen llegue a los bordes si lo deseas */
  overflow: hidden;
  position: relative;
  height: 450px; /* Ajusta la altura a tu gusto */
}

.gallery-container {
  width: 100%;
  height: 100%;
  position: relative;
}

.gallery-track {
  display: flex;
  height: 100%;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery-slide {
  min-width: 100%;
  height: 100%;
  position: relative;
}

.gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Mantiene la proporción cubriendo el área */
}

/* Subtexto descriptivo */
.gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(26, 74, 122, 0.85); /* Azul institucional con transparencia */
  color: white;
  padding: 15px;
  text-align: center;
  font-family: 'Raleway', sans-serif;
  font-size: 1.1rem;
}

/* Botones flotantes sobre la imagen */
.gallery-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  background: rgba(255, 255, 255, 0.3) !important;
}

.gallery-btn:hover {
  background: #1a4a7a !important;
}

#prev-gallery { left: 20px; }
#next-gallery { right: 20px; }


/* --- CONFIGURACIÓN DE LA CELDA DE TÍTULO --- */
.cell-title {
  grid-column: 1 / span 2; /* Ocupa todo el ancho */
  text-align: center;
  padding: 1rem 0;
}

.quienes-somos-title {
  color: #1a4a7a; /* Azul institucional */
  font-family: 'Raleway', sans-serif;
  font-size: 2.5rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin: 0;
  position: relative;
  display: inline-block;
}

/* Línea decorativa opcional debajo del título */
.quienes-somos-title::after {
  content: '';
  display: block;
  width: 60%;
  height: 4px;
  background-color: #4cb3df; /* Celeste de acento */
  margin: 10px auto 0;
  border-radius: 2px;
}

/* Ajuste para móviles */
@media (max-width: 850px) {
  .quienes-somos-title {
    font-size: 1.8rem;
  }
}

.cell-title, 
.cell-history, 
.cell-gallery {
  grid-column: 1 / span 2;
}

/* Ubicación y Equipo se acomodan solos (1 columna cada uno) */
.cell-location, 
.cell-people {
  grid-column: auto;
}

/* --- CONTENEDOR Y TÍTULO --- */
.proyecciones-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  max-width: 1200px;
  margin: auto;
}

.proyecciones-main-title {
  text-align: center;
  color: #1a4a7a;
  font-family: 'Raleway', sans-serif;
  font-size: 3rem;
  text-transform: uppercase;
  border-bottom: 4px solid #4cb3df;
  display: inline-block;
  margin-bottom: 20px;
}

/* --- PRIMERA CELDA: SPLIT 2/3 - 1/3 --- */
.horizontal-split {
  display: flex;
  padding: 0 !important;
  overflow: hidden;
  min-height: 400px;
}

.days-carousel-wrapper {
  flex: 2; /* Ocupa 2/3 */
  position: relative;
  background: #f7fbff;
  border-right: 1px solid #d1e9f6;
  overflow: hidden;
}

.cta-section {
  flex: 1; /* Ocupa 1/3 */
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  background: white;
}

.buy-btn {
  background: #1a4a7a;
  color: white;
  padding: 12px 25px;
  border-radius: 30px;
  text-decoration: none;
  font-weight: bold;
  margin-top: 20px;
  transition: background 0.3s;
}

.buy-btn:hover { background: #4cb3df; }

/* --- SEGUNDA CELDA: PROGRAMAS (TODO SE MUEVE) --- */
.program-carousel-container {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 15px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.1);
  background: white;
}

.program-slide {
  min-width: 100%;
  display: flex;
  height: 450px;
}

.program-text {
  flex: 1; /* 1/3 */
  padding: 40px;
  background: #1a4a7a;
  color: white;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.program-images {
  flex: 2; /* 2/3 */
  display: flex;
}

.program-images img {
  width: 50%;
  height: 100%;
  object-fit: cover;
}

/* --- ESTILOS DE LISTA Y NAVEGACIÓN --- */
.day-slide {
  min-width: 100%;
  padding: 40px;
  box-sizing: border-box;
}

.schedule-list {
  list-style: none;
  padding: 0;
}

.schedule-list li {
  padding: 10px 0;
  border-bottom: 1px dashed #ccddec;
}

.floating-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(26, 74, 122, 0.7);
  color: white;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
}

.floating-nav.prev { left: 20px; }
.floating-nav.next { right: 20px; }

/* --- CONTENEDOR DE TARJETAS LIMPIAS --- */
.info-card-clean {
  background: #ffffff;
  border-radius: 20px; /* Esquinas redondeadas */
  display: flex;
  overflow: hidden; /* Corta el contenido que se salga de los bordes redondeados */
  min-height: 400px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.07);
  border: 1px solid #d1e9f6;
  margin-bottom: 40px;
}

/* Área de contenido (Ocupa 2/3) */
.content-area {
  flex: 2; 
  background: #f8fbfe; /* Un color muy suave para diferenciar el vacío */
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Área de texto (Ocupa 1/3) */
.text-sidebar {
  flex: 1;
  padding: 45px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: #ffffff;
  border-left: 1px solid #f0f7fb;
  border-right: 1px solid #f0f7fb;
}

/* Estética de los textos */
.text-sidebar h3 {
  color: #1a4a7a;
  font-family: 'Raleway', sans-serif;
  font-size: 1.8rem;
  margin-top: 0;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.text-sidebar p {
  color: #4a5a6a;
  line-height: 1.8;
  margin-bottom: 25px;
  text-align: left; /* Mejor legibilidad en columnas angostas */
}

/* Botón de enlace */
.placeholder-btn {
  display: inline-block;
  padding: 12px 25px;
  background: #1a4a7a;
  color: #ffffff;
  text-decoration: none;
  font-weight: bold;
  border-radius: 50px;
  text-align: center;
  transition: background 0.3s ease, transform 0.2s ease;
}

.placeholder-btn:hover {
  background: #4cb3df;
  transform: translateY(-2px);
}

/* Texto temporal en el centro del área vacía */
.placeholder-content {
  color: #ccddec;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 2px;
}

/* --- RESPONSIVE --- */
@media (max-width: 950px) {
  .info-card-clean {
    flex-direction: column; /* Se apilan en móvil */
    min-height: auto;
  }

  /* Invertimos el orden en la primera celda para que el contenido quede arriba del texto en móvil */
  .info-card-clean {
    display: flex;
    flex-direction: column;
  }
  
  /* En la primera celda, movemos el content-area arriba */
  .full-width-cell:first-of-type .info-card-clean {
    flex-direction: column; 
  }

  .content-area {
    height: 250px;
    flex: none;
  }
  
  .text-sidebar {
    padding: 30px;
    flex: none;
  }
}

/* Tarjeta blanca por día */
.day-table-card {
  background: #ffffff;
  width: 85%;
  max-width: 500px;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  border-top: 6px solid #1a4a7a; /* Detalle azul superior */
}

.day-table-title {
  color: #1a4a7a;
  font-family: 'Raleway', sans-serif;
  font-size: 1.8rem;
  margin-top: 0;
  margin-bottom: 20px;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Tabla de dos columnas */
.mini-schedule {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Raleway', sans-serif;
}

.mini-schedule thead th {
  text-align: left;
  color: #4cb3df; /* Azul claro para encabezados */
  font-size: 0.9rem;
  text-transform: uppercase;
  padding-bottom: 10px;
  border-bottom: 1px solid #eee;
}

.mini-schedule tbody td {
  padding: 12px 5px;
  border-bottom: 1px solid #f1f1f1;
  color: #333;
  font-size: 0.95rem;
  vertical-align: top;
}

/* Columna de la hora con énfasis azul */
.mini-schedule tbody td:first-child {
  font-weight: bold;
  color: #1a4a7a;
  width: 100px;
  white-space: nowrap;
}

/* Quitar borde a la última fila */
.mini-schedule tbody tr:last-child td {
  border-bottom: none;
}

.split-50 {
  display: flex;
  width: 100%;
  background: #ffffff;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  min-height: 500px;
}

.text-half {
  flex: 1; /* Ocupa exactamente el 50% */
  padding: 50px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: #ffffff;
}

.content-half {
  flex: 1; /* Ocupa el otro 50% */
  background: #f4f9fc; /* Azul muy pálido para el fondo del carrusel */
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

/* Ajustes del carrusel para que encaje en el 50% */
.day-table-card {
  background: #ffffff;
  width: 90%;
  padding: 25px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
  border-top: 5px solid #1a4a7a;
}

/* Iconos de features */
.features-mini {
  margin: 20px 0;
  display: flex;
  gap: 20px;
}

.feature-item {
  font-size: 0.9rem;
  color: #555;
  display: flex;
  align-items: center;
  gap: 8px;
}

.feature-item i {
  color: #4cb3df;
}

/* Responsivo para tablets/celulares */
@media (max-width: 992px) {
  .split-50 {
    flex-direction: column;
  }
  
  .text-half, .content-half {
    flex: none;
    width: 100%;
  }
  
  .content-half {
    height: 450px;
  }
}

/* --- RESPONSIVIDAD --- */

/* Para tablets y teléfonos (menos de 768px) */
@media (max-width: 768px) {
  
  /* El calendario ahora permitirá scroll lateral si es muy ancho */
  .carousel-container {
    padding: 10px !important;
    overflow-x: auto;
  }

  /* Reducimos el alto de las celdas en móvil para que no sea eterno */
  .calendar-slide tr {
    height: 50px !important;
  }

  .calendar-slide h3 {
    font-size: 1.5rem !important;
  }

  /* Las 3 columnas de abajo se apilan una sobre otra */
  main > div[style*="display: grid"] {
    grid-template-columns: 1fr !important;
    gap: 15px !important;
  }

  /* Ajustamos los botones de navegación */
  .nav-btn {
    width: 40px !important;
    height: 40px !important;
  }
}

/* Ajuste fino para teléfonos muy pequeños (menos de 480px) */
@media (max-width: 480px) {
  .calendar-slide table {
    font-size: 0.7rem !important; /* Letra más pequeña para que quepa el mes */
  }
  
  header {
    flex-direction: column;
    text-align: center;
    padding: 1rem;
  }
}

