  /* ============================================
     SKELETON LOADER STYLES - Placeholder mientras carga
     ============================================ */

  /* Skeleton base - Posición absoluta desde el inicio para evitar CLS */
  .cm-slider-skeleton {
    position: absolute;  /* Siempre absoluto para no afectar layout */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 1;
    transition: opacity 0.3s ease;
    z-index: 10;  /* Por encima del contenido real */
    pointer-events: auto;
  }

  /* Estado: Ocultar skeleton cuando el slider está listo */
  .slider-skeleton.hidden {
    opacity: 0;
    pointer-events: none;
    z-index: -1;  /* Debajo del contenido real */
  }

  /* Eliminación completa después de la transición (evita reflow) */
  .slider-skeleton.removed {
    display: none;
  }

  /* Elementos skeleton individuales - Usar .skeleton-shimmer global de style.css */
  /* .skeleton {
    border-radius: var(--radius-md, 8px);
  } */

  /* Animación shimmer ahora es global en style.css */

  .declarations-s1 .card-title {
    height: 40px;
  }
  
  .declarations-s1.skeleton {
    background: var(--bg-primary); 
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
    height: 100%;
    border-radius: var(--radius-125);
    border: 2px solid var(--border-color);
  }

  .declarations-s1 .cm-skeleton-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-grow: 1;
    gap: 1rem;
    
  }
  /* Skeleton específicos para cada elemento del slider */
  .declarations-s1 .cm-skeleton-icon {
    background-color: var(--text-secondary);
    width: 78px;
    height: 78px;
    margin-bottom: 1.5rem;
    border-radius: 20px;
  }
  .declarations-s1 .cm-skeleton-title {
    height: 40px;
    width: 80%;
    background-color: var(--text-secondary);
    border-radius: var(--radius-md);
  }

  .declarations-s1 .cm-skeleton-description {
    width: 100%;
    height: 46px;
    background-color: var(--text-secondary);
    border-radius: var(--radius-md);
  }

  .cm-skeleton-button {
    height: 3rem;
    width: 150px;
  }

.cm-skeleton-image {
    width: 100%;
    max-width: 600px;
    aspect-ratio: 2 / 1;
    border-radius: var(--radius-lg, 12px);
  }

  /* ============================================
     HERO SLIDER STYLES - Contenido real
     ============================================ */

  .cm-slider-container {
    max-width: 1920px;
    position: relative;
    overflow: hidden;
    /* padding: 2rem; */
    width: 100%;
    /* min-height eliminado para que se ajuste al contenido */
  }

  .cm-slider-wrapper {
    width: 100%;
    position: relative;
    user-select: none;
    cursor: grab;
    /* Transición sincronizada con skeleton (300ms) */
    transition: opacity 0.3s ease;
    /* Permitir scroll vertical pero capturar drag horizontal */
    touch-action: pan-y;
  }

  /* Estado inicial: invisible pero en el layout (evita CLS) */
  .cm-slider-wrapper[style*="opacity: 0"] {
    visibility: hidden;  /* Invisible pero ocupa espacio */
  }

  .cm-slider-wrapper.dragging {
    cursor: grabbing;
  }

  .cm-slider-track {
    width: 100%; 
    max-width: 1920px;
    margin: 0 auto;
    /* CSS Grid: todos los slides ocupan la misma celda (overlay automático) */
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 1fr;
  }

  /* Each individual slide - todos en la misma celda de grid */
  .cm-slider-slide {
    /* Todos los slides ocupan la misma celda = overlay automático */
    grid-column: 1;
    grid-row: 1;
    width: 100%;
    /* Valores por defecto - sobreescritos por estilos inline del EJS y JS */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 1;
  }

  /* Optimización: slides inactivos no se renderizan hasta que sean necesarios */
  .cm-slider-slide:not(.cm-active) {
    content-visibility: auto;
    contain-intrinsic-size: 1920px 478px;
  }

  /* El slide activo define la altura del grid (sin cambio de position) */
  .cm-slider-slide.cm-active {
    z-index: 2;
    /* Grid automáticamente ajusta altura al contenido del slide activo */
  }

  .cm-slider-content {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    height: 100%;
    min-height: 350px;  /* Reserve minimum height to prevent collapse */
    /* Prevent layout shifts from child animations */
    contain: layout;
}

  /* Left Content Block */
  .cm-content-left {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    padding-left: 6rem;
  }

  .cm-content-left .cm-skeleton-title {
    height: 158px;
    border-radius: var(--radius-lg);
    background-color: var(--text-secondary);
  }

  .cm-content-left .cm-skeleton-description {
    height: 68px;
    border-radius: var(--radius-lg);
    background-color: var(--text-secondary);
  }

  .cm-content-left .cm-skeleton-button {
    height: 58px;
    border-radius: var(--radius-lg);
    background-color: var(--text-secondary);
  }

  /* Elementos animados - Los estilos finales se mantienen en el HTML */
  /* Cuando un slide está activo, estos elementos tienen: */
  /* transform: translate(0px, 0px) scale(1) y opacity: 1 */

  .cm-slider-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.1;
    color: var(--text-primary);
    margin: 0;
    min-height: 3.3rem; /* Reserve space for title (1.1 line-height × 3rem) */
  }

  .cm-slider-description {
    font-size: 1.25rem;
    line-height: 1.7;
    color: var(--text-secondary);
    margin: 0;
    min-height: 2.125rem; /* Reserve space for description (1.7 line-height × 1.25rem) */
  }

  .cm-slider-button {
    display: inline-flex;
    align-items: center;
    padding: 1rem 2rem;
    background-color: var(--primary-color);
    color: white;
    text-decoration: none;
    font-weight: 600;
    border-radius: var(--radius-lg);
    align-self: flex-start;
    min-height: 3rem; /* Reserve space for button */
  }

  .cm-slider-button:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
  }

  /* Right Content Block */
  .cm-content-right {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    min-height: 300px;
  }

  .cm-slider-image {
    width: 100%;           /* Responsive width */
    max-width: 600px;      /* Maximum width */
    height: auto;          /* Altura automática según aspect ratio */
    aspect-ratio: 1 / 1;   /* Reserva espacio antes de cargar (previene CLS) */
    object-fit: contain;   /* No recorta, mantiene proporción */
    border-radius: var(--radius-lg);
    -webkit-user-drag: none;
    user-drag: none;
    /* Prevent layout shifts during animations */
    will-change: transform, opacity;
    contain: layout;
    /* Elemento animado - Los estilos finales se mantienen en el HTML */
    /* Cuando activo: transform: translate(0px, 0px) scale(1) y opacity: 1 */
  }

  /* ============================================
     FULL BANNER STYLES - Banners de imagen completa
     ============================================ */

  .cm-slider-content-full {
    width: 100%;
    display: flex;
    flex-direction: column;  /* Columna para imagen + botón */
    justify-content: center;
    align-items: center;
    padding: 0;
    /* min-height eliminado para que se ajuste al contenido */
  }

  .cm-slider-banner-full {
    width: 100%;
    max-width: 1920px;  /* Limita imagen 2000px a 1920px */
    height: auto;  /* Altura automática según aspect ratio */
    aspect-ratio: 1920 / 478;  /* Reserva espacio antes de cargar (previene CLS) */
    object-fit: contain;  /* No recorta, mantiene proporción completa */
    object-position: center;  /* Centrada en el contenedor */
    /* border-radius: var(--radius-lg); */
    -webkit-user-drag: none;
    user-drag: none;
    /* Prevent layout shifts during animations */
    will-change: transform, opacity;
    contain: layout;
    transition: opacity 0.3s ease;
  }

  /* Botón del banner (mismo estilo que slider-button estándar) */
  .cm-slider-button-banner {
    position: absolute;
    bottom: 5rem;  /* Separación del borde inferior */ 
    left: 50%;
    transform: translateX(-50%);  /* Centrado horizontal */
    z-index: 10;  /* Por encima de la imagen */
    /* Hereda estilos de .slider-button */
  }

  /* Navigation Buttons - Usar clase global .slide-nav-btn de style.css */

  /* ============================================
     RESPONSIVE STYLES - Adaptaciones móvil/tablet
     ============================================ */

  @media (max-width: 992px) {

    /* .cm-slider-container sin min-height fijo */

    /* Skeleton responsive - Tablet/Mobile */
    .cm-skeleton-title {
      height: 2.5rem;
      width: 90%;
    }

    .cm-skeleton-description {
      height: 1.87rem;
      width: 95%;
    }

    .cm-skeleton-image {
      max-width: 498px;
    }

    .cm-slider-content {
      grid-template-columns: 1fr;
      gap: 2rem;
      text-align: center;
      min-height: 500px;
    }

    .cm-content-left {
      padding-left: 0;
      order: 2;
      align-items: center;
      justify-content: center;
    }

    .cm-content-right {
      order: 1;
      min-height: 250px;
    }

    .cm-slider-image {
      width: 100%;
      max-width: 498px;
      height: auto;
    }

    .cm-slider-title {
      font-size: 2.5rem;
      min-height: 2.75rem;
    }

    .cm-slider-description {
      font-size: 1.1rem;
      min-height: 1.87rem;
    }

    .cm-slider-button {
      align-self: center;
    }

    .slider-btn {
      width: 50px;
      height: 50px;
    }

    .slider-btn-prev {
      left: 1rem;
    }

    .slider-btn-next {
      right: 1rem;
    }

    /* Full Banner - Tablet */
    /* .cm-slider-content-full sin min-height fijo */

    .cm-slider-banner-full {
      max-width: 840px;  /* Mobile usa imagen 840×498 */
      height: auto;  /* Altura automática según aspect ratio */ 
    }
  }

  @media (max-width: 768px) {
    .cm-slider-banner-full {
      width: 100%;           /* 🔥 ocupa todo el ancho del viewport */
      max-width: none;        /* 🔥 elimina el límite de 840px */
      height: auto;
      aspect-ratio: 840 / 498; /* mantiene proporción correcta */
      border-radius: var(--radius-md);
    }
  }

  @media (max-width: 480px) {
    /* Skeleton responsive - Móvil pequeño */
    .cm-skeleton-title {
      height: 2rem;
      width: 95%;
    }

    .cm-skeleton-description {
      height: 1.7rem;
      width: 100%;
    }

    .cm-skeleton-button {
      width: 120px;
      height: 2.5rem;
    }

    .cm-skeleton-image {
      max-width: 100%;
      width: 100%;
    }

    /* Slider real - Móvil pequeño */
    .cm-slider-container {
      padding: 1rem;
      /* min-height eliminado */
    }

    .cm-slider-content {
      /* min-height eliminado */
    }

    .cm-content-right {
      min-height: 200px;
    }

    .cm-slider-image {
      max-width: 100%;
      width: 100%;
    }

    .cm-slider-title {
      font-size: 2rem;
      min-height: 2.2rem;
    }

    .cm-slider-description {
      font-size: 1rem;
      min-height: 1.7rem;
    }

    .cm-slider-button {
      padding: 0.75rem 1.5rem;
    }

    .cm-slider-banner-full {
      width: 100%;  /* Mobile usa imagen 840×498 */
      height: auto;  /* Altura automática según aspect ratio */
      border-radius: var(--radius-md);
    }
  }

/* === Aplicar efectos al hacer hover en el card === */
.cm-slider-content-full:hover .cm-effect-btn-gradient-shift::before {
  left: 100%;
}

/* ═══════════════════════════════════════════════════════════════
   NAVIGATION DOTS (Ventana Deslizante)
   ═══════════════════════════════════════════════════════════════ */

.cm-slider-dots {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 15;  /* Mayor que slides (z-index: 2-3) y botones (z-index: 10) */
  display: flex;
  gap: 0.5rem;
  align-items: center;
  padding: 0.5rem 1rem;
  background: var(--bg-primary-opacity-60);
  backdrop-filter: blur(8px);
  border-radius: 2rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid var(--border-color);
  pointer-events: auto;  /* Asegurar que los clicks lleguen */
  user-select: none;     /* Evitar selección como en botones prev/next */
  min-width: 130px;      /* Ancho mínimo para 4 dots (evita crecimiento visual) */
  justify-content: center; /* Centrar dots dentro del container */
  overflow: hidden;      /* Evitar desbordamiento durante animaciones */
}

.cm-slider-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--text-primary);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  outline: none;
  pointer-events: auto;  /* Asegurar que recibe clicks */
  user-select: none;     /* Evitar selección de texto */
  flex-shrink: 0;        /* Evitar compresión durante animaciones */
}

.cm-slider-dot:hover {
  background: var(--text-secondary);
  transform: scale(1.2);
}

.cm-slider-dot.cm-dot-active {
  background: var(--cm-btn-gradient-blue);
  width: 24px;
  border-radius: 5px;
}

/* Animación de entrada/salida de dots */
.cm-slider-dot.cm-dot-enter {
  animation: dotEnter 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.cm-slider-dot.cm-dot-exit {
  animation: dotExit 0.15s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  max-width: 0;        /* Colapsar inmediatamente */
  overflow: hidden;    /* Ocultar contenido */
  margin: 0;           /* Sin márgenes */
  padding: 0;          /* Sin padding */
}

@keyframes dotEnter {
  from {
    opacity: 0;
    transform: scale(0);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes dotExit {
  from {
    opacity: 1;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(0);
  }
}

/* Animación especial para dot activo que sale */
.cm-slider-dot.cm-dot-active.cm-dot-exit {
  animation: dotExitActive 0.15s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  max-width: 0;        /* Colapsar inmediatamente */
  overflow: hidden;    /* Ocultar contenido */
  margin: 0;           /* Sin márgenes */
  padding: 0;          /* Sin padding */
}

@keyframes dotExitActive {
  from {
    opacity: 1;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(0);
  }
}

/* Responsive: Mobile */
@media (max-width: 768px) {
  .cm-slider-dots {
    bottom: 1rem;
    padding: 0.4rem 0.8rem;
    gap: 0.4rem;
    min-width: 110px;  /* Ancho mínimo para 4 dots mobile (evita crecimiento) */
  }

  .cm-slider-dot {
    width: 8px;
    height: 8px;
  }

  .cm-slider-dot.cm-dot-active {
    width: 20px;
  }

  /* Animaciones mobile ajustadas (heredan de desktop, sin cambios) */
}

.cm-slider-content-full:hover .cm-effect-btn-gradient-shift::after {
  opacity: 1;
}

.cm-slider-content-full:hover .cm-effect-btn-gradient-shift {
  transform: translateY(-2px);
  box-shadow: var(--cm-btn-shadow-hover);
}