/* Basic reset */
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  padding: 0;
  font-family:'Poppins', system-ui, -apple-system, sans-serif;
  color: #222;
}
img {
  max-width: 100%;
  display: block;
}
a {
  color: inherit;
  text-decoration: none;
}
ul.plain {
  list-style: none;
  padding: 0;
  margin: 0;
}

:root {
  --bg: #ffffff;
  --text: #1d1d1f;
  --muted: #6b7280;
  --primary: #1d4ed8; /* tweak as desired */
  --primary-contrast: #ffffff;
  --alt: #0f766e;
  --surface: #f6f7fb;
  --border: #e5e7eb;
}

body {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);

.top-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.4rem 0.75rem;
  background: #0b1020;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--muted);
}
.top-strip__social a {
  margin-left: 0.5rem;
  padding: 0.25rem 0.45rem;
  border-radius: 0.4rem;
  background: #fff;
  border: 1px solid var(--border);
}


.logo {
  font-weight: 800;
  letter-spacing: 0.5px;
}
.nav-toggle {
  font-size: 1.4rem;
  background: none;
  border: 1px solid var(--border);
  padding: 0.35rem 0.55rem;
  border-radius: 0.5rem;
  display: none;
}

/* --- Menú principal: SOLO el UL de primer nivel --- */
.site-nav > ul {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin: 0;
  padding: 0;
}

.site-nav a,
.sub-toggle {
  padding: 0.4rem 0.35rem;
  border-radius: 0.35rem;
}
.site-nav a:hover,
.sub-toggle:hover {
  background: var(--surface);
}
.has-sub {
  position: relative;
}
.sub-toggle {
  background: none;
  border: none;
  font: inherit;
  cursor: pointer;
}

/* --- SubmenÃºs: columna y no heredan el flex en fila --- */
.sub {
  position: absolute;
  left: 0;
  top: calc(100% + 0.3rem);
  min-width: 220px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 0.6rem;
  padding: 0.4rem;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
  list-style: none;
  display: none; /* oculto por defecto */
  flex-direction: column; /* apilar verticalmente */
  z-index: 1000; /* Asegurar que esté por encima */
}

/* Clase para submenús que deben abrirse hacia la izquierda */
.sub--right {
  left: auto;
  right: 0;
}

/* Detección automática para elementos cerca del borde derecho */
.has-sub:nth-last-child(-n + 2) .sub {
  left: auto;
  right: 0;
}

.has-sub:focus-within > .sub,
.has-sub:hover > .sub {
  display: block;
}

.sub li {
  display: block;
  margin: 0;
}
.sub li a {
  display: block;
  padding: 0.45rem 0.5rem;
  border-radius: 0.4rem;
  white-space: nowrap; /* evita cortes raros */
}
.sub li a:hover {
  background: var(--surface);
}

.hero {
  background: linear-gradient(
    120deg,
    rgba(29, 78, 216, 0.08),
    rgba(15, 118, 110, 0.08)
  );
  padding: 6rem 1rem;
}
.hero__content {
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}
.hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin: 0 0 0.5rem;
}
.hero__actions {
  margin-top: 26rem;
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}
.btn {
  background: var(--primary);
  color: var(--primary-contrast);
  padding: 0.75rem 1rem;
  border-radius: 0.65rem;
  font-weight: 600;
  display: inline-block;
}
.btn--alt {
  background: var(--alt);
}

.section {
  padding: 3rem 1rem;
  max-width: 1100px;
  margin: 0 auto;
}
.section__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.section--alt {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.carousel {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 0.85rem;
  background: #fff;
}
.carousel__track {
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
  transition: transform 0.4s ease;
}

.carousel__img {
  width: 100%;
  height: auto;
  max-height: 350px; /* Aumentar de 280px a 350px o más */
  min-height: 250px; /* Aumentar de 200px a 250px */
  object-fit: contain;
  border-radius: 0.6rem;
  border: 1px solid var(--border);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}
.carousel__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: #fff;
  border: 1px solid var(--border);
  padding: 0.5rem 0.7rem;
  border-radius: 0.6rem;
  cursor: pointer;
}
.carousel__btn.prev {
  left: 0.5rem;
}
.carousel__btn.next {
  right: 0.5rem;
}

.message {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 1.25rem;
  align-items: center;
}
.message__img {
  border-radius: 0.8rem;
  border: 1px solid var(--border);
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}
.video-card {
  background: #fff;
  border: 1px solid var(--border);
  padding: 1rem;
  border-radius: 0.8rem;
}
.video-card__media {
  height: 160px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--border);
  border-radius: 0.6rem;
  color: var(--muted);
}

.events-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 0.75rem;
  padding: 0;
  list-style: none;
}
.events-list li {
  background: #fff;
  border: 1px solid var(--border);
  padding: 0.9rem;
  border-radius: 0.8rem;
}
.events-list li time {
  display: block;
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 0.35rem;
}

.parallax {
  min-height: 500px;
  background-image: url("../../img/fondo2.jpg");
  background-attachment: fixed;
  background-position: center;
  background-size: cover;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 3rem 0;
}

.parallax__overlay {
  background: rgba(0, 0, 0, 0.3);
  color: #fff;
  padding: 3rem 2rem;
  border-radius: 1rem;
  text-align: center;
  max-width: 900px;
  width: 90%;
  animation: fadeInUp 1s ease-out;
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0.75rem;
  text-align: center;
}
.stat {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 0.8rem;
  padding: 1rem;
}
.stat strong {
  display: block;
  font-size: 1.6rem;
}

.cta {
  padding: 3rem 1rem;
  text-align: center;
  background: linear-gradient(
    120deg,
    rgba(29, 78, 216, 0.06),
    rgba(15, 118, 110, 0.06)
  );
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.cta__buttons {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.site-footer {
  background: #0b1020;
  color: #eef2ff;
  padding: 2.5rem 1rem;
}
.foot-grid {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}
.site-footer a {
  color: #c7d2fe;
}
.powered {
  max-width: 1100px;
  margin: 1rem auto 0;
  color: #9aa1c6;
  font-size: 0.9rem;
  text-align:center;
}

/* Mobile */
@media (max-width: 920px) {
  .nav-toggle {
    display: block;
  }
  .site-nav {
    position: fixed;
    inset: 0 0 auto 0;
    top: 56px;
    background: #fff;
    padding: 0.75rem;
    border-bottom: 1px solid var(--border);
    transform: translateY(-120%);
    transition: transform 0.25s ease;
  }
  .site-nav.open {
    transform: translateY(0);
  }

  /* SOLO el UL de primer nivel baja a columna */
  .site-nav > ul {
    flex-direction: column;
  }

  /* Submenús en mobile: en flujo, sin borde/sombra (quedan debajo del padre) */
  .sub {
    position: static;
    border: none;
    box-shadow: none;
    padding: 0.25rem 0 0.5rem 1rem;
    display: none; /* el JS con .sub-toggle los muestra/oculta */
  }

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

/* ========== Calendar of Events (split) ========== */
.events-split {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2rem;
  align-items: stretch;
}

.events-left {
  align-self: center;
}
.events-right img {
  width: 100%;
  height: 100%;
  
  border-radius: 0.8rem;
}

/* Botones tipo "chip" */
.chip {
  display: inline-block;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  background: #a21caf; /* morado similar */
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
}
.chip--alt {
  background: #be26b6;
}

/* Lista en formato filas */
.events-list--rows {
  display: grid;
  gap: 1.2rem;
  padding: 0;
  list-style: none;
}

/* Fila de evento con dos columnas: fecha / contenido */
.event-row {
  display: grid;
  grid-template-columns: 84px 1fr;
  align-items: start;
  gap: 1rem;
}

/* Caja de fecha grande */
.event-row .date-box {
  text-align: center;
  line-height: 1;
  color: #0e7490; /* azul verdoso */
  padding-right: 0.6rem;
  border-right: 1px solid var(--border);
}
.date-box .day {
  font-size: 2.6rem;
  font-weight: 800;
  letter-spacing: -1px;
}
.date-box .mon {
  margin-top: 0.15rem;
  display: block;
  color: #475569;
  font-weight: 700;
  letter-spacing: 0.15em;
}

/* Texto del evento */
.event-row .event-body a {
  color: #0ea5e9; /* azul de enlace */
  font-weight: 700;
}
.event-row .meta {
  margin-top: 0.25rem;
  color: var(--text);
  font-weight: 600;
}
.event-row .subtle {
  color: var(--muted);
  font-weight: 500;
}

/* Espaciado general del bloque */
.events-left .section__head {
  margin-bottom: 1.25rem;
}

/* Responsive */
@media (max-width: 1100px) {
  .events-split {
    grid-template-columns: 1fr;
  }
  .events-right img {
    height: 320px;
  }
}

@media (max-width: 520px) {
  .event-row {
    grid-template-columns: 72px 1fr;
  }
  .date-box .day {
    font-size: 2.2rem;
  }
}

/* Header con altura fija */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 50%, #f1f5f9 100%);
  border-bottom: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 1rem; /* Reducir padding vertical */
  height: 80px; /* Altura fija del header */
  min-height: 80px; /* Asegurar altura mínima */
}

/* Logo independiente del tamaño del header */
.site-header .logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  height: 100%; /* Usar toda la altura disponible del header */
  max-height: 70px; /* Limitar altura máxima del contenedor del logo */
}

/* Logo con altura controlada */
.site-header .logo img {
  height: 100px; /* Altura específica del logo */
  width: auto;
  display: block;
  object-fit: contain; /* Mantener proporciones */
}

/* Navegación ajustada */
.site-nav {
  height: 100%;
  display: flex;
  align-items: center;
}

/* En responsive, ajustar la altura también */
@media (max-width: 920px) {
  .site-header {
    height: 60px; /* Altura más pequeña en móvil */
    min-height: 60px;
  }

  .site-header .logo {
    max-height: 50px;
  }

  .site-header .logo img {
    height: 40px; /* Logo más pequeño en móvil */
  }

  .site-nav {
    position: fixed;
    inset: 0 0 auto 0;
    top: 60px; /* Ajustar según la nueva altura del header */
    background: #fff;
    padding: 0.75rem;
    border-bottom: 1px solid var(--border);
    transform: translateY(-120%);
    transition: transform 0.25s ease;
  }
}

/* Fondo con imagen en el bloque de los botones (HERO) */
.hero {
  padding: 4rem 1rem; /* Menos padding */
  min-height: 600px; /* Más altura */
  background: url("../../img/FOTO1.jpg") center / cover no-repeat;
}

/* Asegura el contenido por encima (por si tienes overlays en otro lado) */
.hero__content {
  position: relative;
  z-index: 1;
}

/*-------------------------------------*/

/* Estilos para el enlace del carousel */
.carousel__link {
  display: grid;
  grid-template-columns: 380px 1fr; /* Cambiar de 280px a 380px */
  gap: 1rem;
  align-items: center;
  text-decoration: none;
  color: inherit;
  width: 100%;
  height: 100%;
  transition: opacity 0.2s ease;
}

.carousel__link:hover {
  opacity: 0.9;
}

/* Ajustar el item para que contenga el enlace correctamente */
.carousel__item {
  min-width: 100%;
  padding: 1.25rem;
  display: block;
  grid-template-columns: 450px 1fr; /* Cambiar de 350px a 450px o más */
  gap: 1rem;
  align-items: center;
}

/* Responsive para mobile */
@media (max-width: 920px) {
  .carousel__link {
    grid-template-columns: 1fr;
  }
}

/* Estilos corregidos para los videos */
.video-card__media {
  height: auto; /* Cambiar de altura fija a automática */
  min-height: 160px; /* Altura mínima */
  border: 1px solid var(--border);
  border-radius: 0.6rem;
  overflow: hidden;
  background: #f8f9fa;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Para videos HTML5 nativos */
.video-card__media video {
  width: 100%;
  height: auto; /* Altura automática para mantener proporciones */
  max-height: 550px; /* Altura máxima */
  display: block;
  border-radius: 0.5rem; /* Ligeramente menos que el contenedor */
}

/* Asegurar que los controles sean visibles */
.video-card__media video::-webkit-media-controls-panel {
  background-color: rgba(0, 0, 0, 0.8);
}

.video-card__media video::-webkit-media-controls {
  overflow: visible !important;
}

/* Para iframes de YouTube (si los usas después) */
.video-card__media iframe {
  width: 100%;
  height: 200px; /* Altura fija para iframes */
  display: block;
  border: none;
}

/* Efecto hover mejorado */
.video-card {
  background: #fff;
  border: 1px solid var(--border);
  padding: 1rem;
  border-radius: 0.8rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.video-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Responsive: En móviles */
@media (max-width: 768px) {
  .video-card__media {
    min-height: 180px;
  }

  .video-card__media video {
    max-height: 200px;
  }
}

@media (max-width: 480px) {
  .video-card__media {
    min-height: 200px;
  }

  .video-card__media video {
    max-height: 180px;
  }
}
/* Estilos adicionales para el mapa en el footer */
.foot-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.location-with-map {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.map-container {
  position: relative;
  width: 100%;
  height: 200px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.map-container:hover {
  transform: scale(1.02);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
}

.map-container iframe {
  width: 100%;
  height: 100%;
  border: none;
  pointer-events: none;
}

.map-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 2;
}

.map-container:hover .map-overlay {
  opacity: 1;
  background: rgba(0, 0, 0, 0.3);
}

.map-overlay span {
  background: rgba(255, 255, 255, 0.95);
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-weight: bold;
  color: #333;
  text-align: center;
  font-size: 0.9rem;
}

.location-info {
  text-align: left;
}

.location-info h3 {
  margin-bottom: 0.5rem;
  color: #fff;
}

.location-info p {
  margin: 0;
  line-height: 1.6;
}

.location-info a {
  color: #fff;
  text-decoration: none;
  transition: color 0.3s ease;
}

.location-info a:hover {
  color: #fff;
  text-decoration: underline;
}

/* Responsive design */
@media (max-width: 768px) {
  .foot-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .map-container {
    height: 180px;
  }

  .location-with-map {
    text-align: center;
  }

  .location-info {
    text-align: center;
  }
}

@media (max-width: 480px) {
  .map-container {
    height: 160px;
  }
}

/* Agregar estos estilos al final de tu styles.css */

/* Mobile: Mejorar comportamiento de submenús */
@media (max-width: 920px) {
  /* Botón toggle para submenús en móvil */
  .sub-toggle {
    width: 100%;
    text-align: left;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  
  .sub-toggle::after {
    content: '+';
    font-weight: bold;
    transition: transform 0.2s ease;
  }
  
  .sub-toggle.active::after {
    content: '−';
    transform: rotate(180deg);
  }
  
  /* Submenús en móvil: controlados por JS */
  .sub {
    display: none;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
  }
  
  .sub.show {
    display: block;
    opacity: 1;
    max-height: 500px;
  }
  
  /* Quitar hover/focus-within en móvil */
  .has-sub:hover > .sub,
  .has-sub:focus-within > .sub {
    display: none;
  }
}

/* Estilos mejorados para redes sociales */
.top-strip__social {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.top-strip__social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 6px;
  border-radius: 6px;
  background: #fff;
  border: 1px solid var(--border);
  color: #6b7280;
  transition: all 0.3s ease;
}

.top-strip__social a:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Colores específicos para cada red social */
.top-strip__social a:nth-child(1):hover {
  background: #E4405F;
  color: white;
  border-color: #E4405F;
}

.top-strip__social a:nth-child(2):hover {
  background: #1877F2;
  color: white;
  border-color: #1877F2;
}

.top-strip__social a:nth-child(3):hover {
  background: #25D366;
  color: white;
  border-color: #25D366;
}

.top-strip__social a:nth-child(4):hover {
  background: #0A66C2;
  color: white;
  border-color: #0A66C2;
}

.top-strip__social a svg {
  width: 18px;
  height: 18px;
  display: block;
}

/* Responsive para móvil */
@media (max-width: 768px) {
  .top-strip {
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
  }
  
  .top-strip__msg {
    font-size: 0.8rem;
  }
  
  .top-strip__social {
    justify-content: center;
  }
}

.sub-nested {
  position: absolute;
  left: 100%;
  top: 0;
  margin-left: 0.5rem;
}

/* Texto principal grande */
.parallax__overlay .main-text {
  font-family: 'Lilita One', cursive;
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 900;
  line-height: 1.1;
  margin: 0 0 1rem 0;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  letter-spacing: -1px;
  text-transform: uppercase;
}

/* Texto secundario amarillo */
.parallax__overlay .secondary-text {
   font-family: 'Gochi Hand', cursive;
  font-size: clamp(1.8rem, 6vw, 3.5rem);
  font-weight: 700;
  color: #FFD700;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
  margin: 0;
  letter-spacing: 1px;
}

/* Animación de entrada */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .parallax__overlay {
    padding: 2rem 1rem;
  }
}

@media (max-width: 480px) {
  .parallax__overlay .main-text {
    font-size: 2rem;
  }
  
  .parallax__overlay .secondary-text {
    font-size: 1.5rem;
  }
}
}

/* Estilos mejorados para el menú de navegación */

/* --- Menú principal con animaciones --- */
.site-nav > ul {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin: 0;
  padding: 0;
}

.site-nav a,
.sub-toggle {
  padding: 0.8rem 1rem;
  border-radius: 0.5rem;
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  font-weight: 500;
}

/* Efecto de subrayado animado */
.site-nav a::before,
.sub-toggle::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--alt));
  transform: translateX(-50%);
  transition: width 0.3s ease;
  border-radius: 2px;
}

/* Efecto de fondo deslizante */
.site-nav a::after,
.sub-toggle::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, 
    rgba(29, 78, 216, 0.1), 
    rgba(15, 118, 110, 0.1)
  );
  transition: left 0.4s ease;
  z-index: -1;
  border-radius: 0.5rem;
}

/* Estados de hover */
.site-nav a:hover,
.sub-toggle:hover {
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(29, 78, 216, 0.15);
}

.site-nav a:hover::before,
.sub-toggle:hover::before {
  width: 80%;
}

.site-nav a:hover::after,
.sub-toggle:hover::after {
  left: 0;
}

/* Animación de pulso para botones activos */
.sub-toggle.active {
  background: rgba(29, 78, 216, 0.1);
  color: var(--primary);
  animation: pulseGlow 2s infinite;
}

@keyframes pulseGlow {
  0%, 100% {
    box-shadow: 0 0 5px rgba(29, 78, 216, 0.3);
  }
  50% {
    box-shadow: 0 0 20px rgba(29, 78, 216, 0.6);
  }
}

/* --- Submenús con animaciones mejoradas --- */
.sub {
  position: absolute;
  left: 0;
  top: calc(100% + 0.5rem);
  min-width: 240px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(229, 231, 235, 0.8);
  border-radius: 1rem;
  padding: 0.8rem;
  box-shadow: 
    0 20px 25px -5px rgba(0, 0, 0, 0.1),
    0 10px 10px -5px rgba(0, 0, 0, 0.04);
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px) scale(0.95);
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  z-index: 1000;
}

/* Animación de entrada del submenú */
.has-sub:hover > .sub,
.has-sub:focus-within > .sub {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

/* Delay escalonado para elementos del submenú */
.sub li {
  opacity: 0;
  transform: translateX(-20px);
  animation: slideInLeft 0.3s ease forwards;
}

.sub li:nth-child(1) { animation-delay: 0.1s; }
.sub li:nth-child(2) { animation-delay: 0.15s; }
.sub li:nth-child(3) { animation-delay: 0.2s; }
.sub li:nth-child(4) { animation-delay: 0.25s; }
.sub li:nth-child(5) { animation-delay: 0.3s; }
.sub li:nth-child(6) { animation-delay: 0.35s; }
.sub li:nth-child(7) { animation-delay: 0.4s; }
.sub li:nth-child(8) { animation-delay: 0.45s; }
.sub li:nth-child(9) { animation-delay: 0.5s; }
.sub li:nth-child(10) { animation-delay: 0.55s; }

@keyframes slideInLeft {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Reset animación cuando el submenú se oculta */
.has-sub:not(:hover):not(:focus-within) .sub li {
  animation: none;
  opacity: 0;
  transform: translateX(-20px);
}

/* Elementos del submenú */
.sub li a {
  display: block;
  padding: 0.75rem 1rem;
  border-radius: 0.6rem;
  white-space: nowrap;
  position: relative;
  transition: all 0.25s ease;
  overflow: hidden;
}

/* Efecto ripple en elementos del submenú */
.sub li a::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: radial-gradient(circle, rgba(29, 78, 216, 0.3) 0%, transparent 70%);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
  z-index: -1;
}

.sub li a:hover::before {
  width: 300px;
  height: 300px;
}

.sub li a:hover {
  background: linear-gradient(135deg, 
    rgba(29, 78, 216, 0.1), 
    rgba(15, 118, 110, 0.1)
  );
  color: var(--primary);
  transform: translateX(5px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Efecto de borde izquierdo en hover */
.sub li a:hover {
  border-left: 4px solid var(--primary);
  padding-left: calc(1rem - 4px);
}

/* Submenús que se abren hacia la derecha */
.sub--right {
  left: auto;
  right: 0;
  transform-origin: top right;
}

/* Detección automática para elementos cerca del borde derecho */
.has-sub:nth-last-child(-n + 2) .sub {
  left: auto;
  right: 0;
  transform-origin: top right;
}

/* Logo con efecto hover mejorado */
.site-header .logo {
  transition: transform 0.3s ease;
}

.site-header .logo:hover {
  transform: scale(1.05);
}

.site-header .logo img {
  transition: filter 0.3s ease;
}

.site-header .logo:hover img {
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

/* Botón hamburguesa con animación */
.nav-toggle {
  font-size: 1.4rem;
  background: none;
  border: 2px solid var(--primary);
  padding: 0.5rem 0.75rem;
  border-radius: 0.75rem;
  display: none;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.nav-toggle::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--primary);
  transition: left 0.3s ease;
  z-index: -1;
}

.nav-toggle:hover {
  color: white;
  transform: scale(1.1);
}

.nav-toggle:hover::before {
  left: 0;
}

/* Responsive: mantener animaciones en móvil */
@media (max-width: 920px) {
  .nav-toggle {
    display: block;
  }
  
  .site-nav {
    position: fixed;
    inset: 0 0 auto 0;
    top: 60px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem;
    border-bottom: 1px solid var(--border);
    transform: translateY(-120%);
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  }
  
  .site-nav.open {
    transform: translateY(0);
  }

  /* SOLO el UL de primer nivel baja a columna */
  .site-nav > ul {
    flex-direction: column;
    gap: 0.5rem;
  }

  /* SubmenÃºs en mobile: animaciones simplificadas */
  .sub {
    position: static;
    border: 1px solid rgba(229, 231, 235, 0.5);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 0.5rem 0 0.5rem 1.5rem;
    margin-top: 0.5rem;
    border-radius: 0.75rem;
    background: rgba(248, 250, 252, 0.8);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.3s ease;
  }
  
  .sub.show {
    max-height: 500px;
    opacity: 1;
  }
  
  /* Botón toggle mejorado para móvil */
  .sub-toggle {
    width: 100%;
    text-align: left;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(29, 78, 216, 0.05);
    border-radius: 0.75rem;
  }
  
  .sub-toggle::after {
    content: '+';
    font-weight: bold;
    font-size: 1.2rem;
    transition: transform 0.3s ease;
    color: var(--primary);
  }
  
  .sub-toggle.active::after {
    content: '−';
    transform: rotate(180deg);
  }
  
  /* Quitar hover/focus-within en móvil */
  .has-sub:hover > .sub,
  .has-sub:focus-within > .sub {
    opacity: 0;
    max-height: 0;
  }
}

/* AGREGAR SOLO ESTE CSS AL FINAL DE TU styles.css EXISTENTE */

/* Corrección específica para menú móvil - mantener funcionalidad original */
@media (max-width: 920px) {
  
  /* Asegurar que el botón hamburguesa se vea correctamente */
  .nav-toggle {
    display: block !important;
    font-size: 1.4rem;
    background: none;
    border: 2px solid #1d4ed8;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    cursor: pointer;
    color: #1d4ed8;
    z-index: 1001;
  }

  /* Mejorar el estilo de los botones de submenú */
  .sub-toggle {
    width: 100% !important;
    text-align: left !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 1rem !important;
    background: #f8fafc !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 0.5rem !important;
    font-weight: 500 !important;
  }
  
  .sub-toggle::after {
    content: '+' !important;
    font-weight: bold !important;
    font-size: 1.2rem !important;
    color: #1d4ed8 !important;
    transition: transform 0.2s ease !important;
  }
  
  .sub-toggle.active::after {
    content: '−' !important;
    transform: rotate(180deg) !important;
  }

  .sub-toggle.active {
    background: #e0f2fe !important;
    border-color: #1d4ed8 !important;
  }
  
  /* Mejorar estilo de submenús cuando están abiertos */
  .sub.show {
    display: block !important;
    opacity: 1 !important;
    max-height: 500px !important;
    padding: 0.5rem !important;
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 0.5rem !important;
    margin: 0.5rem 0 0 1rem !important;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1) !important;
  }

  /* Mejorar enlaces de submenú */
  .sub.show li a {
    display: block !important;
    padding: 0.75rem 1rem !important;
    color: #6b7280 !important;
    border-radius: 0.25rem !important;
    margin-bottom: 0.25rem !important;
    transition: all 0.2s ease !important;
  }

  .sub.show li a:hover {
    background: #f3f4f6 !important;
    color: #1d4ed8 !important;
  }
}

/* Reemplazar todo el bloque de .cta-buttons-section con esto */

.open-doors-section {
  padding: 2rem 1rem;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-bottom: 1px solid var(--border);
}

.open-doors-container {
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
}

.open-doors-background {
  position: relative;
  width: 100%;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}

.open-doors-img {
  width: 100%;
  height: auto;
  display: block;
  max-height: 600px;
  object-fit: cover;
}

.overlay-buttons {
  position: absolute;
  bottom: 20px;
  right: 20px;
  display: flex;
  gap: 15px;
  z-index: 10;
}

.overlay-button-link {
  display: inline-block;
  transition: all 0.3s ease;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.overlay-button-img {
  width: 100%;
  height: auto;
  max-width: 200px;
  min-width: 150px;
  display: block;
  transition: all 0.3s ease;
  border-radius: 12px;
}

.overlay-button-link:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.overlay-button-link:hover .overlay-button-img {
  filter: brightness(1.1) saturate(1.2);
}

@media (max-width: 768px) {
  .overlay-buttons {
    bottom: 15px;
    right: 15px;
    flex-direction: column;
    gap: 10px;
  }
  
  .overlay-button-img {
    max-width: 160px;
    min-width: 120px;
  }
}

/* CSS para la sección de botones CTA - Agregar al final de styles.css */

.cta-buttons-section {
  padding: 2rem 1rem;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-bottom: 1px solid var(--border);
}

.cta-buttons-container {
  max-width: 1400px; /* Aumentado de 1100px para imágenes panorámicas */
  margin: 0 auto;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.cta-button-link {
  display: inline-block;
  transition: all 0.3s ease;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.cta-button-img {
  width: 100%;
  height: auto;
  max-width: 1000px; /* Aumentado significativamente para imágenes panorámicas */
  min-width: 300px;
  display: block;
  transition: all 0.3s ease;
  border-radius: 12px;
  object-fit: contain; /* Mantiene la imagen completa sin recortar */
}

/* Efectos hover */
.cta-button-link:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.cta-button-link:hover .cta-button-img {
  filter: brightness(1.1) saturate(1.1);
}

/* Efecto de presionar */
.cta-button-link:active {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* Responsive design */
@media (max-width: 768px) {
  .cta-buttons-container {
    flex-direction: column;
    gap: 1.5rem;
  }
  
  .cta-button-img {
    max-width: 100%; /* Usar todo el ancho disponible en móviles */
    min-width: 250px;
  }
}

@media (max-width: 480px) {
  .cta-buttons-section {
    padding: 1.5rem 0.5rem;
  }
  
  .cta-buttons-container {
    gap: 1rem;
  }
  
  .cta-button-img {
    max-width: 100%; /* Usar todo el ancho disponible */
    min-width: 200px;
  }
}

