:root {
    --color-primary: #038345;
    --color-primary-dark: #025e31;
    --color-accent: #6CBE4B;
    --color-white: #FFFFFF;
    --color-text-heading: #1a1a1a;
    --color-text-body: #4a4a4a;
    --color-text-light: #6B7280;
    --color-bg: #f0f4f8;
    --color-bg-light: #F3F6F4;
    --color-card-bg: #FFFFFF;
    --shadow-soft: 0 10px 40px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 25px 50px rgba(0, 0, 0, 0.15);
    --radius-card: 16px;
    --font-main: 'Verdana', sans-serif;
    --font-alt: 'Poppins', sans-serif;
    --font-display: 'Inter', sans-serif;
    --transition-speed: 0.4s;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    /* Habilita el desplazamiento suave al hacer clic en enlaces de anclaje (ej. <a href="#seccion">). */
    scroll-behavior: smooth;
    /* Añade un espaciado superior al hacer scroll a una sección, para que no quede oculta debajo del header fijo. */
    scroll-padding-top: 80px;
}

body {
    /* Define la fuente principal para todo el documento. */
    font-family: var(--font-main);
    /* Mejora el renderizado de las fuentes en navegadores WebKit (Chrome, Safari). */
    -webkit-font-smoothing: antialiased;
    /* Color de fondo por defecto para la página. */
    background-color: var(--color-white);
    /* Color de texto por defecto para la página. */
    color: var(--color-text-body);
}

/*
  =====================================================================
  ENCABEZADO PRINCIPAL (HEADER)
  =====================================================================
  Estilos para la barra de navegación superior.
*/
.main-header {
    /* Fija el header en la parte superior de la ventana. */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    /* Un z-index alto asegura que el header esté por encima de otros elementos. */
    z-index: 10002;
    /* Fondo semi-transparente. */
    background-color: rgba(255, 255, 255, 0.85);
    /* Aplica un efecto de desenfoque al contenido que está detrás del header. */
    backdrop-filter: blur(10px);
    /* Sombra sutil para dar profundidad. */
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    /* Transición suave para todos los cambios de propiedades. */
    transition: all 0.3s ease;
}

.main-header.scrolled {
    background-color: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

/* Contenedor interno del header para centrar el contenido. */
.header-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Estilos del logo. */
.logo {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--color-primary);
    font-family: var(--font-alt);
}

/* Navegación principal (escritorio). */
.main-nav {
    display: none;
    gap: 30px;
}

/* Enlaces de la navegación. */
.main-nav a {
    text-decoration: none;
    color: var(--color-text-body);
    font-weight: 600;
    font-size: 1rem;
    position: relative;
    transition: color 0.3s ease;
}

.main-nav a:hover {
    color: var(--color-primary);
}

/* Línea animada debajo de los enlaces de navegación al pasar el mouse. */
.main-nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--color-accent);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.main-nav a:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Botón de "Llamada a la Acción" (Call to Action) en la navegación. */
.nav-cta-btn {
    background-color: var(--color-primary);
    color: #ffffff !important;
    padding: 10px 24px;
    border-radius: 50px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    transition: all 0.15s ease-out;
    /* Sombra que crea un efecto 3D. */
    box-shadow: 0 5px 0 var(--color-primary-dark);
    border: 1px solid var(--color-primary-dark);
    position: relative;
    top: 0;
}

.nav-cta-btn:hover {
    /* Al pasar el mouse, el botón se "hunde" ligeramente. */
    top: 2px;
    box-shadow: 0 3px 0 var(--color-primary-dark);
    background-color: var(--color-primary);
}

.nav-cta-btn:active {
    top: 5px;
    box-shadow: none;
}

.nav-cta-btn::after {
    /* Se asegura de que la línea animada de los otros enlaces no aparezca en este botón. */
    display: none !important;
}

.mobile-nav-toggle {
    /* Botón de menú hamburguesa para móviles. */
    display: block;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
}

/* La línea central de la hamburguesa. */
.mobile-nav-toggle .hamburger {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--color-primary);
    position: relative;
    transition: all 0.3s ease;
}

/* Las líneas superior e inferior de la hamburguesa, creadas con pseudo-elementos. */
.mobile-nav-toggle .hamburger::before,
.mobile-nav-toggle .hamburger::after {
    content: '';
    position: absolute;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--color-primary);
    transition: all 0.3s ease;
}

.mobile-nav-toggle .hamburger::before { top: -8px; }
.mobile-nav-toggle .hamburger::after { bottom: -8px; }

/* El menú desplegable para móviles. */
.mobile-menu {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    background-color: var(--color-white);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 30px 0;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    /* Inicialmente está oculto fuera de la pantalla. */
    transform: translateY(-150%);
    /* Transición suave con una curva de aceleración personalizada (cubic-bezier) para un efecto más natural. */
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    z-index: 10001;
}

/* Animación de la hamburguesa a una "X" cuando el menú está abierto. */
.mobile-nav-toggle.open .hamburger { background-color: transparent; }
.mobile-nav-toggle.open .hamburger::before { transform: translateY(8px) rotate(45deg); }
.mobile-nav-toggle.open .hamburger::after { transform: translateY(-8px) rotate(-45deg); }

/* Muestra el menú móvil cuando tiene la clase 'open'. */
.mobile-menu.open {
    transform: translateY(0);
}

.mobile-menu a {
    text-decoration: none;
    color: var(--color-primary);
    font-size: 1.5rem;
    font-weight: 700;
}

.mobile-menu .nav-cta-btn.mobile-btn {
    margin-top: 10px;
    width: 80%;
    justify-content: center;
}

/*
  =====================================================================
  MEDIA QUERIES (DISEÑO RESPONSIVO)
  =====================================================================
  Estos bloques aplican estilos solo cuando se cumplen ciertas condiciones de tamaño de pantalla.
*/
@media (min-width: 900px) {
    /* En pantallas de 900px o más (tabletas grandes, escritorios)... */
    .main-nav { display: flex; align-items: center; }
    .mobile-nav-toggle, .mobile-menu { display: none; }
}

/*
  =====================================================================
  SECCIÓN HERO (PRINCIPAL)
  =====================================================================
  La primera sección visible de la página, con el título y el formulario rápido.
*/
.hero-main {
    background-color: var(--color-bg-light);
    /* Imagen de fondo. */
    background-image: url('../images/background-hero.png');
    background-size: cover; /* La imagen cubre todo el contenedor. */
    background-position: center;
    background-repeat: no-repeat;
    padding: 120px 20px 80px 20px;
    min-height: 90vh;
    display: flex;
    justify-content: flex-end;
    text-align: right;
    align-items: center;
}

.hero-main-container {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    max-width: 850px;
    text-align: right;
}

.hero-main-title {
    font-family: var(--font-display);
    /* Tamaño de fuente responsivo: se ajusta entre 1.8rem y 2.8rem según el ancho de la ventana (viewport width). */
    font-size: clamp(1.8rem, 4.5vw, 2.8rem);
    font-weight: 800;
    color: var(--color-accent);
    line-height: 1.1;
    margin-bottom: 12px;
    /* Animación de entrada. */
    opacity: 0;
    animation: slideInLeft 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.hero-main-title .highlight {
    color: var(--color-accent);
}

/* Contenedor del formulario dentro de la sección Hero. */
.hero-form-wrapper {
    margin-top: 8px;
    width: 100%;
    max-width: 480px;
}

/* Estilos específicos para el formulario en la sección Hero. */
.hero-form {
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    max-width: 100%;
    margin: 0;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
}

/* Texto introductorio del formulario. */
.hero-form-intro {
    font-size: 0.9rem;
    color: #FFFFFF;
    margin-bottom: 24px;
    font-weight: 600;
    text-align: right;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    opacity: 0;
    animation: fadeInUp 0.8s ease-out forwards 0.3s;
}

/* Grid para los campos del formulario. */
.hero-form-inputs {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

/* Animación de entrada escalonada para cada campo del formulario. */
.hero-form-inputs > div {
    opacity: 0;
    animation: fadeInUp 0.6s ease-out forwards;
}
.hero-form-inputs > div:nth-child(1) { animation-delay: 0.4s; }
.hero-form-inputs > div:nth-child(2) { animation-delay: 0.5s; }
.hero-form-inputs > div:nth-child(3) { animation-delay: 0.6s; }
.hero-form-inputs > div:nth-child(4) { animation-delay: 0.7s; }
.hero-form-inputs > div:nth-child(5) { animation-delay: 0.8s; }
.hero-form-inputs > div:nth-child(6) { animation-delay: 0.9s; }

.hero-form .form-group {
    margin-bottom: 0;
}

/* Estilos para los campos de entrada (input, textarea). */
.hero-form .form-control {
    width: 100%;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    background-color: rgba(255, 255, 255, 0.95);
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    outline: none;
    color: #333;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.hero-form textarea.form-control {
    /* Permite al usuario redimensionar el textarea verticalmente. */
    resize: vertical;
    min-height: 80px;
    font-family: var(--font-main);
}

.hero-form .form-control::placeholder {
    color: var(--color-text-light);
}

.hero-form .form-control:focus {
    /* Efecto visual al hacer foco en un campo. */
    border-color: var(--color-accent);
    box-shadow: 0 8px 20px rgba(108, 190, 75, 0.25);
    transform: translateY(-2px);
    background-color: #FFFFFF;
}

.hero-form-submit {
    /* Botón de envío del formulario. */
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
    color: var(--color-white);
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    box-shadow: 0 8px 20px -5px rgba(108, 190, 75, 0.4);
    border: none;
    cursor: pointer;
    width: 100%;
    position: relative;
    overflow: hidden;
}

/* Efecto de brillo que se desliza sobre el botón. */
.hero-form-submit::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: 0.5s;
}

.hero-form-submit:hover:not(:disabled) {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px -5px rgba(108, 190, 75, 0.5);
}

.hero-form-submit:hover::after {
    left: 100%;
}

.hero-form-submit:disabled {
    background-color: #9CA3AF;
    box-shadow: none;
    cursor: not-allowed;
}

/*
  =====================================================================
  KEYFRAMES (ANIMACIONES)
  =====================================================================
  Definiciones de las animaciones usadas en el sitio.
*/
@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes fadeInUp {
    /* Animación que mueve un elemento hacia arriba y lo desvanece. */
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.section-ventajas {
    /* Sección de Beneficios. */
    position: relative;
    width: 100%;
    background: linear-gradient(135deg, #ffffff 0%, var(--color-bg) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 24px;
    overflow: hidden;
}

.section-ventajas .container {
    max-width: 1280px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

@media (min-width: 768px) {
    /* En pantallas de 768px o más... */
    .hero-main {
        justify-content: flex-start;
        text-align: left;
        background-size: contain;
    }
    .hero-main-container {
        align-items: flex-start;
        text-align: left;
        margin-left: 120px;
    }
    .hero-form-intro {
        text-align: left;
    }
    .hero-form-inputs {
        /* El formulario pasa a tener 2 columnas. */
        grid-template-columns: 1fr 1fr;
    }
    .hero-form .form-group.full-width {
        /* Los elementos con esta clase ocupan las 2 columnas. */
        grid-column: span 2;
    }
    .hero-form-submit {
        width: 100%;
    }
}

/* Estilos para la etiqueta del checkbox de términos y condiciones. */
.terms-label {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.85rem;
    color: #FFFFFF;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
    cursor: pointer;
    line-height: 1.4;
}

.terms-label input[type="checkbox"] {
    margin-top: 3px;
    width: 14px;
    height: 14px;
    accent-color: var(--color-primary);
    flex-shrink: 0;
}

/* Encabezado de la sección de ventajas. */
.section-ventajas .section-header {
    text-align: center;
    margin-bottom: 60px;
    opacity: 0;
    transform: translateY(30px);
    /* Transición que se activará con JavaScript cuando el elemento sea visible. */
    transition: all 1s cubic-bezier(0.22, 1, 0.36, 1);
}

.section-ventajas .section-header.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.section-ventajas .section-title {
    font-size: 2.5rem;
    color: var(--color-primary);
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.5px;
}

.section-ventajas .section-subtitle {
    font-size: 1.125rem;
    color: var(--color-text-body);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Grid para las tarjetas de ventajas. */
.section-ventajas .cards-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    width: 100%;
}

/* Estilo base para cada tarjeta. */
.section-ventajas .card {
    background-color: var(--color-card-bg);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
    display: flex;
    position: relative;
    flex-direction: column;
    /* Transición suave para el efecto hover. */
    transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.5s ease;
    opacity: 0;
    transform: translateY(50px);
}

.section-ventajas .card.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.section-ventajas .card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

/* Línea de acento que aparece en la parte inferior de la tarjeta al pasar el mouse. */
.section-ventajas .card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--color-primary);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}
.section-ventajas .card:hover::after {
    transform: scaleX(1);
}

/* Contenedor de la imagen de la tarjeta. */
.section-ventajas .card-image-container {
    width: 100%;
    height: 240px;
    overflow: hidden;
    background-color: #e9ecef;
    position: relative;
}

.section-ventajas .card-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

/* Efecto de brillo ("shine") que se desliza sobre la imagen al pasar el mouse. */
.section-ventajas .card-image-container::before {
    position: absolute;
    top: 0;
    left: -75%;
    z-index: 2;
    display: block;
    content: '';
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 100%);
    transform: skewX(-25deg);
}
.section-ventajas .card:hover .card-image-container::before {
    animation: shine 0.75s;
}
@keyframes shine {
    100% { left: 125%; }
}

.section-ventajas .card:hover .card-image-container img {
    /* Efecto de zoom suave en la imagen al pasar el mouse. */
    transform: scale(1.05);
}

/* Contenido de texto de la tarjeta. */
.section-ventajas .card-content {
    padding: 32px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.section-ventajas .card-title {
    font-size: 1.35rem;
    color: var(--color-primary);
    font-weight: 700;
    margin-bottom: 16px;
    line-height: 1.3;
    transition: color 0.3s ease;
}

.section-ventajas .card:hover .card-title {
    color: var(--color-accent);
}

.section-ventajas .card-text {
    font-size: 1rem;
    color: var(--color-text-body);
    line-height: 1.6;
    font-weight: 400;
}

@media (min-width: 768px) {
    /* En 768px, el grid de tarjetas pasa a 2 columnas. */
    .section-ventajas .cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .section-ventajas .section-title {
        font-size: 3rem;
    }
}

@media (min-width: 1024px) {
    /* En 1024px, el grid de tarjetas pasa a 3 columnas. */
    .section-ventajas .cards-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .section-ventajas {
        padding: 100px 40px;
    }
}

/*
  =====================================================================
  SECCIÓN "CÓMO FUNCIONA" (PASOS / TIMELINE)
  =====================================================================
*/
}

.steps-section {
    box-sizing: border-box;
    color: var(--text-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    position: relative;
    width: 100%;
    padding: 100px 20px;
    background: linear-gradient(180deg, #ffffff 0%, var(--bg-light) 100%);
    overflow: hidden;
}

.steps-section *,
.steps-section *::before,
.steps-section *::after {
    box-sizing: inherit;
    margin: 0;
    padding: 0;
}

.steps-section .container {
    max-width: 1100px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.steps-section .section-header {
    text-align: center;
    margin-bottom: 100px;
}

.steps-section .section-title {
    font-size: 3rem;
    font-weight: 800;
    color: #038345;
    margin-bottom: 20px;
    letter-spacing: -0.02em;
}

.steps-section .section-subtitle {
    font-size: 1.2rem;
    color: var(--text-gray);
    max-width: 600px;
    margin: 0 auto;
}

/* Línea de tiempo vertical que conecta los pasos. */
.steps-section .timeline {
    position: relative;
    width: 100%;
}

.steps-section .timeline::before {
    content: '';
    /* La línea en sí. */
    position: absolute;
    left: 50%;
    top: 0;
    height: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--brand-primary) 0%, var(--brand-accent) 100%);
    transform: translateX(-50%);
    z-index: 0;
    /* La altura se animará de 0 a 100% con JS. */
    transition: height 2.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.steps-section .timeline.active::before {
    height: 100%;
}

/* Fila para cada paso individual. */
.steps-section .step-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 120px;
    position: relative;
    z-index: 1;
}

.steps-section .step-row:last-child {
    margin-bottom: 0;
}

/* Bloques de contenido (texto e imagen) de cada paso. */
.steps-section .step-content-block, .steps-section .step-image-block {
    width: 45%;
    opacity: 0;
    filter: blur(10px);
    transition: all 1s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Marcador numérico circular en la línea de tiempo. */
.steps-section .step-marker {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 60px;
    height: 60px;
    background-color: var(--color-primary);
    border: 3px solid var(--color-primary);
    color: var(--color-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1.5rem;
    z-index: 2;
    box-shadow: 0 0 0 8px rgba(255, 255, 255, 1), 0 0 20px rgba(3, 131, 69, 0.2);
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Animación de pulso para el marcador del paso activo. */
@keyframes pulse-ring {
    0% { box-shadow: 0 0 0 0 rgba(3, 131, 69, 0.4); }
    70% { box-shadow: 0 0 0 15px rgba(3, 131, 69, 0); }
    100% { box-shadow: 0 0 0 0 rgba(3, 131, 69, 0); }
}

.steps-section .step-title {
    font-size: 2rem;
    color: #6CBE4B;
    margin-bottom: 20px;
    font-weight: 700;
    line-height: 1.2;
}

.steps-section .step-text {
    font-size: 1.1rem;
    color: var(--text-gray);
    line-height: 1.7;
}

.steps-section .step-image-block img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    transition: transform 0.5s ease;
}

.steps-section .step-row:hover .step-image-block img {
    transform: scale(1.03);
}

/* Estilos para los pasos impares (1, 3, 5...). */
.steps-section .step-row:nth-child(odd) .step-content-block {
    text-align: right;
    transform: translateX(-50px);
}
.steps-section .step-row:nth-child(odd) .step-image-block {
    transform: translateX(50px);
}

/* Estilos para los pasos pares (2, 4, 6...). */
.steps-section .step-row:nth-child(even) {
    flex-direction: row-reverse;
}
.steps-section .step-row:nth-child(even) .step-content-block {
    text-align: left;
    transform: translateX(50px);
}
.steps-section .step-row:nth-child(even) .step-image-block {
    transform: translateX(-50px);
}

/* Cuando un paso se activa (visible en pantalla), se aplican estas animaciones. */
.steps-section .step-row.active .step-content-block,
.steps-section .step-row.active .step-image-block {
    opacity: 1;
    filter: blur(0);
    transform: translateX(0);
}
.steps-section .step-row.active .step-marker {
    transform: translate(-50%, -50%) scale(1);
    animation: pulse-ring 2s infinite 0.5s;
}

@media (max-width: 900px) {
    /* Adaptación de la línea de tiempo para móviles. */
    .steps-section {
        padding: 60px 20px;
    }

    .steps-section .timeline::before {
        left: 30px;
    }

    /* Los pasos se apilan verticalmente. */
    .steps-section .step-row {
        flex-direction: column !important;
        align-items: flex-start;
        margin-bottom: 80px;
    }

    .steps-section .step-marker {
        left: 30px;
        top: 0;
        transform: translate(-50%, 0) scale(0);
    }
    
    .steps-section .step-row.active .step-marker {
        transform: translate(-50%, 0) scale(1);
    }

    .steps-section .step-content-block, .steps-section .step-image-block {
        width: 100%;
        padding-left: 70px;
        text-align: left !important;
    }

    .steps-section .step-image-block {
        margin-top: 30px;
    }

    .steps-section .step-row:nth-child(odd) .step-content-block,
    .steps-section .step-row:nth-child(even) .step-content-block {
        transform: translateY(30px);
    }
    .steps-section .step-row:nth-child(odd) .step-image-block,
    .steps-section .step-row:nth-child(even) .step-image-block {
        transform: translateY(30px);
    }

    .steps-section .step-row.active .step-content-block,
    .steps-section .step-row.active .step-image-block {
        transform: translateY(0);
    }

    .steps-section .section-title {
        font-size: 2rem;
        line-height: 1.2;
    }
}

/*
  =====================================================================
  SECCIÓN SIMULADOR DE CRÉDITO
  =====================================================================
*/
#hero-simulador-wrapper {
    --hero-primary: #038345;
    --hero-accent: #6CBE4B;
    --hero-text: #2E3A2F;
    --hero-bg-light: #F1FAF4;
    --hero-white: #FFFFFF;
    font-family: var(--font-display);
    background-color: var(--hero-white);
    -webkit-font-smoothing: antialiased;
    line-height: 1.6;
}

#hero-simulador-wrapper *,
#hero-simulador-wrapper *::before,
#hero-simulador-wrapper *::after {
    box-sizing: border-box;
}

/* Contenedor principal de la sección. */
#hero-simulador-wrapper .hero-section {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 40px 16px;
}

/* Contenedor de las dos columnas (texto/imagen y widget). */
#hero-simulador-wrapper .hero-container {
    width: 100%;
    max-width: 1200px;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

/* Columnas izquierda y derecha. */
#hero-simulador-wrapper .col-left,
#hero-simulador-wrapper .col-right {
    width: 100%;
    display: flex;
    flex-direction: column;
}

/* Título de la sección. */
#hero-simulador-wrapper .hero-title {
    color: var(--hero-primary);
    font-weight: 800;
    font-size: clamp(24px, 7vw, 32px);
    line-height: 1.1;
    margin: 0 0 16px 0;
    opacity: 0;
    transform: translateY(20px);
    animation: slideUpFadeIn 0.8s 0.2s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

/* Descripción de la sección. */
#hero-simulador-wrapper .hero-desc {
    color: var(--hero-text);
    font-size: 16px;
    margin: 0 0 24px 0;
    opacity: 0;
    transform: translateY(20px);
    animation: slideUpFadeIn 0.8s 0.4s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

/* Tarjeta que contiene la imagen. */
#hero-simulador-wrapper .hero-image-card {
    width: 100%;
    background-color: var(--hero-bg-light);
    border-radius: 20px;
    padding: 16px;
    box-shadow: 0 10px 30px rgba(3, 131, 69, 0.08);
    margin: 0;
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    opacity: 0;
    transform: translateY(20px);
    animation: slideUpFadeIn 0.8s 0.6s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

#hero-simulador-wrapper .hero-image-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(3, 131, 69, 0.12);
}

#hero-simulador-wrapper .hero-image-card img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

#hero-simulador-wrapper .hero-image-card:hover img {
    transform: scale(1.1);
}

/* Columna derecha que contiene el widget del simulador. */
#hero-simulador-wrapper .col-right {
    background: var(--hero-white);
    border-radius: 20px;
    box-shadow: 0 12px 40px rgba(3,131,69,0.06);
    padding: 16px;
    min-height: auto;
    overflow: visible;
    opacity: 0;
    transform: translateY(20px);
    animation: slideUpFadeIn 0.8s 0.8s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@media (min-width: 768px) {
    #hero-simulador-wrapper .hero-section {
        align-items: center;
        padding: 60px 24px;
    }
    #hero-simulador-wrapper .hero-container {
        flex-direction: row;
        gap: 24px;
    }
    #hero-simulador-wrapper .col-left { flex: 1; }
    #hero-simulador-wrapper .col-right { flex: 1; padding: 24px; }
    #hero-simulador-wrapper .hero-image-card { padding: 20px; }
}

@media (min-width: 1200px) {
    #hero-simulador-wrapper .hero-container {
        gap: 40px;
    }
    #hero-simulador-wrapper .col-left { flex: 58; }
    #hero-simulador-wrapper .col-right { flex: 42; }
    #hero-simulador-wrapper .hero-title {
        font-size: clamp(36px, 5vw, 56px);
    }
    #hero-simulador-wrapper .hero-desc {
        font-size: 18px;
    }
}

/* Animación de entrada para los elementos de esta sección. */
@keyframes slideUpFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/*
  =====================================================================
  WIDGET SIMULADOR DE CRÉDITO (sim-widget-v4)
  =====================================================================
  Estilos encapsulados para el widget. `all: initial` resetea todos los estilos
  heredados para evitar conflictos si el widget se usa en otros sitios.
*/
#sim-widget-v4 {
    all: initial;
    font-family: 'Poppins', sans-serif !important;
    display: block !important;
    width: 100% !important;
    padding: 20px 10px !important;
    box-sizing: border-box !important;
    color: #333 !important;
    line-height: 1.5 !important;
    position: relative !important;
    z-index: 10 !important;
}

#sim-widget-v4 * {
    box-sizing: border-box;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Variables locales para el widget. */
#sim-widget-v4 {
    --color-primary: #038345;
    --color-accent: #6CBE4B;
    --color-white: #FFFFFF;
    --color-bg-card: #FFFFFF;
    --shadow-soft: 0 15px 35px rgba(3, 131, 69, 0.1);
    --shadow-hover: 0 20px 40px rgba(3, 131, 69, 0.2);
}

/* La tarjeta principal del widget. */
#sim-widget-v4 .sim-card {
    background: var(--color-bg-card);
    width: 100% !important;
    max-width: 500px !important;
    margin: 0 auto !important;
    border-radius: 30px !important;
    padding: 45px 40px !important;
    box-shadow: var(--shadow-soft);
    position: relative;
    overflow: hidden;
}

#sim-widget-v4 .sim-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-5px);
}

/* Animación de entrada escalonada para los elementos del widget. */
#sim-widget-v4 .sim-card > div, 
#sim-widget-v4 .sim-card > button {
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

#sim-widget-v4 .sim-header { animation-delay: 0.1s; }
#sim-widget-v4 .control-group:nth-of-type(2) { animation-delay: 0.2s; }
#sim-widget-v4 .control-group:nth-of-type(3) { animation-delay: 0.3s; }
#sim-widget-v4 .results-box { animation-delay: 0.4s; }
#sim-widget-v4 .btn-action { animation-delay: 0.5s; }

/* Encabezado del widget. */
#sim-widget-v4 .sim-header {
    text-align: center;
    margin-bottom: 30px !important;
}

#sim-widget-v4 .sim-header h2 {
    font-size: 28px !important;
    font-weight: 700 !important;
    color: var(--color-primary) !important;
    margin: 0 0 10px 0;
    letter-spacing: -0.5px;
}

#sim-widget-v4 .sim-header p {
    font-size: 14px;
    color: #888;
    margin: 0;
    font-weight: 300;
}

/* Grupo de control (etiqueta + slider). */
#sim-widget-v4 .control-group {
    margin-bottom: 30px !important;
}

/* Contenedor flex para alinear la etiqueta y el valor. */
#sim-widget-v4 .label-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

#sim-widget-v4 label {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: #444 !important;
}

/* "Badge" o etiqueta que muestra el valor seleccionado. */
#sim-widget-v4 .value-badge {
    background: rgba(108, 190, 75, 0.15);
    color: var(--color-primary);
    padding: 5px 15px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 16px;
}

/* Estilos para el control deslizante (slider). */
#sim-widget-v4 input[type=range] {
    -webkit-appearance: none;
    width: 100% !important;
    height: 10px !important;
    border-radius: 10px !important;
    background: #e0e0e0 !important;
    outline: none !important;
    margin: 0 !important;
    padding: 0 !important;
    cursor: pointer !important;
    position: relative !important;
    z-index: 2 !important;
}

/* Estilos para el "pulgar" o manejador del slider en navegadores WebKit. */
#sim-widget-v4 input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--color-white);
    border: 4px solid var(--color-accent);
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    transition: transform 0.2s ease;
}

#sim-widget-v4 input[type=range]::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

/* Estilos para el "pulgar" del slider en Firefox. */
#sim-widget-v4 input[type=range]::-moz-range-thumb {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--color-white);
    border: 4px solid var(--color-accent);
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

/* Caja que muestra los resultados del cálculo. */
#sim-widget-v4 .results-box {
    background: linear-gradient(135deg, rgba(3, 131, 69, 0.9) 0%, rgba(2, 99, 52, 0.95) 100%), 
                url('https://i.postimg.cc/L5920x5v/Gemini-Generated-Image-vcu5d5vcu5d5vcu5.png');
    background-size: cover;
    background-position: center;
    border-radius: 25px;
    padding: 30px 20px;
    color: var(--color-white);
    text-align: center;
    position: relative;
    overflow: hidden;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(3, 131, 69, 0.25);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

#sim-widget-v4 .results-box:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 40px rgba(3, 131, 69, 0.35);
}

/* Círculos decorativos animados en el fondo de la caja de resultados. */
#sim-widget-v4 .deco-circle {
    position: absolute;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    z-index: 1;
    animation: float 6s ease-in-out infinite;
}
#sim-widget-v4 .dc-1 { width: 150px; height: 150px; top: -50px; left: -50px; }
#sim-widget-v4 .dc-2 { width: 100px; height: 100px; bottom: -30px; right: -20px; animation-delay: 3s; }

/* Contenido real de los resultados. */
#sim-widget-v4 .result-content {
    position: relative;
    z-index: 2;
}

/* Título "Cuota Mensual Estimada". */
#sim-widget-v4 .res-title {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    opacity: 0.9;
    margin-bottom: 5px;
}

/* El monto de la cuota. */
#sim-widget-v4 .res-amount {
    font-size: 42px !important;
    font-weight: 700;
    margin: 10px 0;
    text-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Pie de la caja de resultados (Total a pagar, Tasa). */
#sim-widget-v4 .res-footer {
    display: flex;
    justify-content: space-around;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.2);
}

#sim-widget-v4 .rf-item {
    text-align: center;
    flex: 1;
    padding: 0 5px;
}

#sim-widget-v4 .rf-val {
    font-weight: 700;
    font-size: 18px;
    display: block;
}

#sim-widget-v4 .rf-lbl {
    font-size: 11px;
    opacity: 0.8;
    margin-top: 4px;
    display: block;
}

/* Botón de acción principal "SOLICITAR AHORA". */
#sim-widget-v4 .btn-action {
    width: 100%;
    padding: 20px;
    border: none;
    border-radius: 18px;
    background: var(--color-accent);
    color: var(--color-white);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(108, 190, 75, 0.3);
    transition: transform 0.2s, box-shadow 0.2s;
    animation: pulse-green 3s infinite 1s;
}

#sim-widget-v4 .btn-action:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(108, 190, 75, 0.4);
    background: #62b142;
}

#sim-widget-v4 .btn-action:active {
    transform: scale(0.98);
}

/* Efecto de brillo en el botón. */
#sim-widget-v4 .btn-action::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: 0.5s;
}

#sim-widget-v4 .btn-action:hover::after {
    left: 100%;
}

/* Texto legal del ejemplo representativo. */
#sim-widget-v4 .representative-example {
    margin-top: 25px;
    padding: 15px;
    background: #f8fcf9;
    border-left: 4px solid var(--color-primary);
    border-radius: 8px;
    font-size: 12px;
    color: #555;
    line-height: 1.6;
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards 0.6s;
}

/* Reutilización de la animación fadeInUp. */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Animación de flotación para los círculos decorativos. */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

/* Animación de pulso para el botón de acción. */
@keyframes pulse-green {
    0% { box-shadow: 0 0 0 0 rgba(108, 190, 75, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(108, 190, 75, 0); }
    100% { box-shadow: 0 0 0 0 rgba(108, 190, 75, 0); }
}

@media (max-width: 480px) {
    /* Ajustes del widget para pantallas muy pequeñas. */
    #sim-widget-v4 .sim-card {
        padding: 30px 20px !important;
        border-radius: 20px !important;
    }
    #sim-widget-v4 .res-amount {
        font-size: 34px !important;
    }
    #sim-widget-v4 .sim-header h2 {
        font-size: 24px !important;
    }
    #sim-widget-v4 .btn-action {
        font-size: 16px !important;
        padding: 18px !important;
    }
    #sim-widget-v4 .rf-val {
        font-size: 15px !important;
    }
    #sim-widget-v4 .rf-lbl {
        font-size: 10px !important;
    }
}

/*
  =====================================================================
  SECCIÓN REQUISITOS
  =====================================================================
*/
#requisitos-wrapper {
    --brand-green: #038345;
    --brand-lime: #6CBE4B;
    --brand-white: #FFFFFF;
    --bg-light: #F8FAF9;
    --text-main: #111827;
    --text-gray: #4b5563;
    --font-primary: 'Verdana', sans-serif;
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 20px 40px rgba(3, 131, 69, 0.12);
    font-family: var(--font-primary);
    background-color: var(--bg-light);
    color: var(--text-main);
    -webkit-font-smoothing: antialiased;
    line-height: 1.5;
    width: 100%;
}

#requisitos-wrapper *,
#requisitos-wrapper *::before,
#requisitos-wrapper *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Contenedor de la sección. */
#requisitos-wrapper .requirements-section {
    position: relative;
    width: 100%;
    padding: 80px 20px;
    overflow: hidden;
    background: linear-gradient(180deg, #FFFFFF 0%, #F0FDF4 100%);
}

/* Contenedor interno para centrar contenido. */
#requisitos-wrapper .req-container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

/* Encabezado de la sección. */
#requisitos-wrapper .section-header {
    text-align: center;
    margin-bottom: 60px;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}
#requisitos-wrapper .section-header.in-view {
    opacity: 1;
    transform: translateY(0);
}

#requisitos-wrapper .main-title {
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--brand-green);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

/* Línea decorativa debajo del título. */
#requisitos-wrapper .title-underline {
    width: 60px;
    height: 4px;
    background: var(--brand-lime);
    margin: 0 auto;
    border-radius: 2px;
}

/* Contenedor de las tarjetas de requisitos. */
#requisitos-wrapper .cards-container {
    display: flex;
    flex-direction: column;
    gap: 60px;
    width: 100%;
}

/* Estilo de cada tarjeta de requisito. */
#requisitos-wrapper .req-card {
    background: var(--brand-white);
    border-radius: 20px;
    box-shadow: var(--shadow-card);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    opacity: 0;
    transform: translateY(40px);
    border-left: 6px solid var(--brand-green);
    height: auto;
}

#requisitos-wrapper .req-card.in-view {
    opacity: 1;
    transform: translateY(0);
}

#requisitos-wrapper .req-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

/* Contenedor de la imagen de la tarjeta. */
#requisitos-wrapper .card-img-wrapper {
    height: 220px;
    width: 100%;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

#requisitos-wrapper .card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

#requisitos-wrapper .req-card:hover .card-img-wrapper img {
    transform: scale(1.1);
}

/* Sombra gradiente sobre la imagen para mejorar la legibilidad del texto si se superpusiera. */
#requisitos-wrapper .card-img-wrapper::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40%;
    background: linear-gradient(to top, rgba(0,0,0,0.4), transparent);
}

/* Contenido de texto de la tarjeta. */
#requisitos-wrapper .card-content {
    padding: 40px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

#requisitos-wrapper .card-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--brand-lime);
    margin-bottom: 25px;
    padding-bottom: 0;
    border-bottom: none;
}

/* Lista de requisitos. */
#requisitos-wrapper .req-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 12px;
}

/* Cada ítem de la lista. */
#requisitos-wrapper .req-list li {
    position: relative;
    padding: 16px 20px 16px 50px;
    font-size: 1rem;
    color: var(--text-main);
    line-height: 1.5;
    background-color: #F3F4F6;
    border-radius: 12px;
    transition: background-color 0.3s ease;
}

#requisitos-wrapper .req-list li:hover {
    background-color: #E6F4EA;
}

/* "Checkmark" personalizado para cada ítem de la lista, usando un SVG como fondo. */
#requisitos-wrapper .req-list li::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background-color: var(--brand-lime);
    border-radius: 50%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white' width='14px' height='14px'%3E%3Cpath d='M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
}

/* Estilos para listas anidadas (sub-requisitos). */
#requisitos-wrapper .req-list ul {
    list-style: none;
    margin-top: 12px;
    padding-left: 0;
    border-left: none;
    display: grid;
    gap: 8px;
}

#requisitos-wrapper .req-list ul li {
    font-size: 0.95rem;
    margin-bottom: 0;
    padding: 10px 15px 10px 30px;
    background-color: rgba(255,255,255,0.6);
    border: 1px solid rgba(0,0,0,0.05);
}

/* Punto personalizado para los sub-ítems. */
#requisitos-wrapper .req-list ul li::before {
    content: '';
    width: 6px;
    height: 6px;
    background-color: var(--brand-green);
    border-radius: 50%;
    top: 50%;
    left: 12px;
    transform: translateY(-50%);
    background-image: none;
}

@media (min-width: 900px) {
    /* En pantallas grandes, las tarjetas de requisitos se muestran en formato horizontal. */
    #requisitos-wrapper .req-card {
        flex-direction: row;
        align-items: stretch;
        min-height: 400px;
    }

    #requisitos-wrapper .card-img-wrapper {
        width: 40%;
        height: auto;
    }

    #requisitos-wrapper .card-content {
        width: 60%;
        padding: 50px;
    }

    /* Alterna la dirección de la tarjeta (imagen a la izquierda, luego a la derecha). */
    #requisitos-wrapper .req-card:nth-child(even) {
        flex-direction: row-reverse;
    }
    
    #requisitos-wrapper .req-card:nth-child(even) {
        border-left: none;
        border-right: 6px solid var(--brand-green);
    }
}

/*
  =====================================================================
  SECCIÓN TESTIMONIOS (CARRUSEL)
  =====================================================================
*/
#testimonios-wrapper {
    --color-star: #FFC761;
    --color-star-empty: #E5E7EB;
    --color-text-main: #1F2A37;
    --color-bg-section: #F8FAF9;
    --shadow-card: 0 10px 30px -5px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 20px 40px -5px rgba(3, 131, 69, 0.15);
    --transition-smooth: 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    font-family: var(--font-main);
    background-color: var(--color-bg-section);
    color: var(--color-text-main);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    width: 100%;
    box-sizing: border-box;
}

#testimonios-wrapper *, 
#testimonios-wrapper *::before, 
#testimonios-wrapper *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Contenedor de la sección. */
#testimonios-wrapper .testimonials-section {
    padding: 80px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

/* Patrón de puntos sutil en el fondo. */
#testimonios-wrapper .testimonials-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(#038345 0.5px, transparent 0.5px), radial-gradient(#038345 0.5px, #F8FAF9 0.5px);
    background-size: 20px 20px;
    background-position: 0 0, 10px 10px;
    opacity: 0.03;
    z-index: 0;
    pointer-events: none;
}

/* Contenedor interno. */
#testimonios-wrapper .container {
    max-width: 1280px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

/* Encabezado de la sección. */
#testimonios-wrapper .section-header {
    text-align: center;
    margin-bottom: 60px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

#testimonios-wrapper .section-title {
    font-size: 2.5rem;
    color: var(--color-primary);
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.5px;
}

#testimonios-wrapper .section-subtitle {
    font-size: 1.1rem;
    color: var(--color-text-light);
}

/* Contenedor principal del carrusel. */
#testimonios-wrapper .carousel-wrapper {
    position: relative;
    width: 100%;
    padding: 20px 0 60px 0;
}

#testimonios-wrapper .carousel-track-container {
    overflow: hidden;
    width: 100%;
    padding: 20px 5px;
    margin: -20px -5px;
    /* Habilita la perspectiva 3D para los slides. */
    perspective: 1200px;
}

/* El "track" que contiene todos los slides y se mueve horizontalmente. */
#testimonios-wrapper .carousel-track {
    display: flex;
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    gap: 0;
    will-change: transform;
    transform-style: preserve-3d;
}

/* Cada slide individual del carrusel. */
#testimonios-wrapper .carousel-slide {
    flex-shrink: 0;
    width: 100%;
    padding: 0 12px;
    opacity: 0.5;
    transform: scale(0.85);
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.7s ease;
}

/* Clase para el slide activo (puede ser usado por algunas lógicas de carrusel). */
#testimonios-wrapper .carousel-slide.is-active {
    opacity: 1;
}

/* El slide que está en el centro es más grande y opaco. */
#testimonios-wrapper .carousel-slide.is-center {
    opacity: 1;
    transform: scale(1);
    z-index: 10;
    position: relative;
}

@media (min-width: 1024px) {
    /* En pantallas grandes, los slides a los lados del central tienen un efecto de rotación 3D. */
    #testimonios-wrapper .carousel-slide.is-left-of-center {
        transform: translateX(10%) rotateY(25deg) scale(0.9);
        opacity: 0.5;
    }
    #testimonios-wrapper .carousel-slide.is-right-of-center {
        transform: translateX(-10%) rotateY(-25deg) scale(0.9);
        opacity: 0.5;
    }
}

/* La tarjeta de testimonio. */
#testimonios-wrapper .review-card {
    background: var(--color-card-bg);
    border-radius: var(--radius-card);
    padding: 32px;
    box-shadow: var(--shadow-card);
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    border-top: 4px solid var(--color-accent);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

#testimonios-wrapper .review-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
}

/* Comillas decorativas gigantes en el fondo de la tarjeta. */
#testimonios-wrapper .review-card::after {
    content: '“';
    position: absolute;
    top: 20px;
    right: 24px;
    font-size: 5rem;
    line-height: 1;
    color: var(--color-primary);
    opacity: 0.08;
    font-family: serif;
    pointer-events: none;
}

/* Encabezado de la tarjeta (avatar e información del autor). */
#testimonios-wrapper .card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

/* Contenedor del avatar. */
#testimonios-wrapper .avatar-wrapper {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    overflow: hidden;
    background-color: #E5E7EB;
    flex-shrink: 0;
    border: 2px solid var(--color-accent);
}

#testimonios-wrapper .avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Información del autor (nombre y perfil). */
#testimonios-wrapper .author-info {
    display: flex;
    flex-direction: column;
}

#testimonios-wrapper .author-name {
    font-weight: 700;
    color: var(--color-text-main);
    font-size: 1.05rem;
}

#testimonios-wrapper .author-profile {
    font-size: 0.85rem;
    color: var(--color-text-light);
}

/* Contenedor de la calificación (estrellas y número). */
#testimonios-wrapper .rating-container {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}

/* Contenedor para las estrellas. JS llenará esto. */
#testimonios-wrapper .stars-wrapper {
    display: flex;
    gap: 2px;
}

/* Estilo para cada estrella SVG. */
#testimonios-wrapper .star-svg {
    width: 20px;
    height: 20px;
    display: block;
}

#testimonios-wrapper .rating-number {
    /* Número de la calificación. */
    font-weight: 700;
    color: var(--color-text-main);
    font-size: 0.9rem;
    background-color: #F3F4F6;
    padding: 2px 8px;
    border-radius: 12px;
}

/* Texto del testimonio. */
#testimonios-wrapper .review-text {
    font-size: 1rem;
    color: var(--color-text-main);
    line-height: 1.6;
    flex-grow: 1;
    font-style: italic;
}

/* Etiqueta "Cliente Verificado". */
#testimonios-wrapper .verified-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 16px;
    font-size: 0.75rem;
    color: var(--color-primary);
    font-weight: 600;
    opacity: 0.8;
}

#testimonios-wrapper .verified-icon {
    width: 14px;
    height: 14px;
}

/* Controles de navegación del carrusel (botones y puntos). */
#testimonios-wrapper .carousel-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 24px;
    margin-top: 32px;
}

/* Botones de Anterior/Siguiente. */
#testimonios-wrapper .nav-btn {
    background: var(--color-white);
    border: 1px solid #E5E7EB;
    color: var(--color-primary);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

#testimonios-wrapper .nav-btn:hover {
    background: var(--color-primary);
    color: var(--color-white);
    border-color: var(--color-primary);
    transform: scale(1.1);
}

#testimonios-wrapper .nav-btn:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

#testimonios-wrapper .nav-icon {
    width: 24px;
    height: 24px;
}

/* Contenedor de los puntos de navegación. */
#testimonios-wrapper .carousel-dots {
    display: flex;
    gap: 8px;
}

/* Cada punto de navegación. */
#testimonios-wrapper .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #D1D5DB;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

/* Estilo del punto activo, que se alarga. */
#testimonios-wrapper .dot[aria-current="true"] {
    background-color: var(--color-primary);
    transform: scale(1.2);
    width: 24px;
    border-radius: 6px;
}

#testimonios-wrapper .dot:hover {
    background-color: var(--color-accent);
}

@media (max-width: 767px) {
    /* Ajustes del carrusel para móviles. */
    #testimonios-wrapper .section-title {
        font-size: 2rem;
    }
    #testimonios-wrapper .testimonials-section {
        padding: 60px 16px;
    }
    #testimonios-wrapper .review-card {
        padding: 24px;
    }
    #testimonios-wrapper .review-card::after {
        font-size: 4rem;
        top: 16px;
        right: 16px;
    }
    #testimonios-wrapper .carousel-controls {
        gap: 16px;
    }
}

@media (min-width: 768px) {
    /* En tabletas, se muestran 2 slides a la vez. */
    #testimonios-wrapper .carousel-slide {
        width: 50%;
    }
    #testimonios-wrapper .section-title {
        font-size: 3rem;
    }
}

@media (min-width: 1024px) {
    /* En escritorio, se muestran 3 slides a la vez. */
    #testimonios-wrapper .carousel-slide {
        width: 33.333%;
    }
    #testimonios-wrapper .testimonials-section {
        padding: 100px 40px;
    }
}

/* Desactiva animaciones si el usuario prefiere movimiento reducido (accesibilidad). */
@media (prefers-reduced-motion: reduce) {
    #testimonios-wrapper .carousel-track, 
    #testimonios-wrapper .carousel-slide, 
    #testimonios-wrapper .review-card {
        transition: none !important;
        transform: none !important;
        animation: none !important;
    }
}

/*
  =====================================================================
  SECCIÓN PREGUNTAS FRECUENTES (FAQ)
  =====================================================================
*/
#faq-section-wrapper {
    --ease-elastic: cubic-bezier(0.34, 1.56, 0.64, 1);
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
    font-family: var(--font-main);
    background-color: var(--color-bg-light);
    color: var(--color-text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    width: 100%;
    overflow-x: hidden;
}

#faq-section-wrapper *,
#faq-section-wrapper *::before,
#faq-section-wrapper *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Contenedor principal de la sección FAQ. */
#faq-section-wrapper .faq-wrapper {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* Panel izquierdo (o superior en móvil) con el título. */
#faq-section-wrapper .faq-header-panel {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    color: var(--color-white);
    padding: 60px 24px;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-bottom-right-radius: 80px;
    box-shadow: 0 20px 40px -10px rgba(3, 131, 69, 0.3);
}

/* Efecto de fondo radial decorativo. */
#faq-section-wrapper .faq-header-panel::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(108, 190, 75, 0.15) 0%, rgba(3, 131, 69, 0) 70%);
    transform: rotate(45deg);
    pointer-events: none;
}

/* Título de la sección FAQ. */
#faq-section-wrapper .faq-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 16px;
    line-height: 1.1;
    letter-spacing: -0.5px;
    position: relative;
    z-index: 2;
}

#faq-section-wrapper .faq-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 500px;
    font-weight: 400;
    position: relative;
    z-index: 2;
}

/* Panel derecho (o inferior en móvil) con el acordeón. */
#faq-section-wrapper .faq-content-panel {
    padding: 40px 20px;
    background-color: var(--color-bg-light);
    flex-grow: 1;
}

/* Contenedor del acordeón. */
#faq-section-wrapper .faq-container {
    max-width: 800px;
    margin: 0 auto;
}

/* Grupo de preguntas (ej. "Documentos", "Proceso"). */
#faq-section-wrapper .faq-group {
    margin-bottom: 50px;
}

#faq-section-wrapper .faq-group-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(3, 131, 69, 0.1);
}

#faq-section-wrapper .faq-icon {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

#faq-section-wrapper .faq-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

#faq-section-wrapper .faq-group-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-primary);
}

/* Lista de ítems del acordeón. */
#faq-section-wrapper .accordion-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Cada ítem individual del acordeón (pregunta + respuesta). */
#faq-section-wrapper .accordion-item {
    background: var(--color-white);
    border-radius: 16px;
    border: 1px solid rgba(0,0,0,0.02);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    opacity: 0;
    transform: translateX(30px); 
}

#faq-section-wrapper .accordion-item.in-view {
    opacity: 1;
    transform: translateX(0);
}

#faq-section-wrapper .accordion-item:hover {
    box-shadow: 0 20px 40px -10px rgba(3, 131, 69, 0.1);
    transform: translateY(-2px);
}

/* El botón que contiene la pregunta y que se puede clickear. */
#faq-section-wrapper .accordion-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 28px 32px;
    background: none;
    border: none;
    text-align: left;
    cursor: pointer;
    color: var(--color-text-main);
    font-family: var(--font-main);
    font-size: 1.15rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

#faq-section-wrapper .accordion-trigger:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: -2px;
    background-color: rgba(108, 190, 75, 0.05);
}

#faq-section-wrapper .accordion-trigger[aria-expanded="true"] {
    color: var(--color-primary);
}

/* El ícono de la flecha (chevron). */
#faq-section-wrapper .icon-chevron {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    margin-left: 16px;
    transition: transform 0.4s var(--ease-elastic);
    color: var(--color-accent);
}

/* Rota la flecha cuando la pregunta está expandida. */
#faq-section-wrapper .accordion-trigger[aria-expanded="true"] .icon-chevron {
    transform: rotate(180deg);
    color: var(--color-primary);
}

/* El contenido (respuesta) que se muestra/oculta. */
#faq-section-wrapper .accordion-content {
    height: 0;
    overflow: hidden;
    transition: height 0.4s var(--ease-smooth), opacity 0.4s ease;
    opacity: 0.5;
}

/* Contenedor interno del contenido para el padding. */
#faq-section-wrapper .accordion-inner {
    padding: 0 32px 32px 32px;
    color: var(--color-text-light);
    font-size: 1rem;
    line-height: 1.7;
}

/* Cuando el trigger está expandido, el contenido se vuelve opaco. */
#faq-section-wrapper .accordion-trigger[aria-expanded="true"] + .accordion-content {
    opacity: 1;
}

#faq-section-wrapper .cta-block {
    /* Bloque de llamada a la acción opcional al final del acordeón. */
    margin-top: 60px;
    padding: 40px;
    background-color: var(--color-white);
    border-radius: 16px;
    text-align: center;
    border: 1px solid rgba(3, 131, 69, 0.1);
    box-shadow: 0 20px 40px rgba(3, 131, 69, 0.05);
}

#faq-section-wrapper .cta-title {
    color: var(--color-primary);
    font-weight: 800;
    margin-bottom: 24px;
    font-size: 1.5rem;
}

#faq-section-wrapper .cta-buttons {
    display: flex;
    flex-direction: column;
    gap: 16px;
    justify-content: center;
}

#faq-section-wrapper .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    font-size: 1rem;
}

#faq-section-wrapper .btn:hover {
    transform: translateY(-2px);
}

#faq-section-wrapper .btn-primary {
    background-color: var(--color-primary);
    color: var(--color-white);
    box-shadow: 0 4px 15px rgba(3, 131, 69, 0.3);
}
#faq-section-wrapper .btn-primary:hover {
    background-color: var(--color-primary-dark);
    box-shadow: 0 8px 20px rgba(3, 131, 69, 0.4);
}

#faq-section-wrapper .btn-secondary {
    background-color: transparent;
    color: var(--color-primary);
    border: 2px solid var(--color-primary);
}
#faq-section-wrapper .btn-secondary:hover {
    background-color: rgba(3, 131, 69, 0.05);
}

@media (min-width: 1024px) {
    /* En escritorio, la sección FAQ se divide en dos columnas verticales. */
    #faq-section-wrapper .faq-wrapper {
        flex-direction: row;
    }

    #faq-section-wrapper .faq-header-panel {
        width: 35%;
        /* El panel del título se queda fijo (sticky) mientras se hace scroll en el contenido. */
        height: 100vh;
        position: sticky;
        top: 0;
        padding: 80px 60px;
        justify-content: flex-start;
        border-bottom-right-radius: 0;
        border-top-right-radius: 60px;
        border-bottom-right-radius: 60px;
    }

    #faq-section-wrapper .faq-title {
        font-size: 3.5rem;
        margin-top: 20vh;
    }

    #faq-section-wrapper .faq-content-panel {
        width: 65%;
        padding: 80px 60px;
    }

    #faq-section-wrapper .cta-buttons {
        flex-direction: row;
    }
}

@media (max-width: 768px) {
    /* Ajustes de la sección FAQ para móviles. */
    #faq-section-wrapper .faq-header-panel {
        padding: 40px 24px;
        border-bottom-right-radius: 40px;
    }

    #faq-section-wrapper .faq-title {
        font-size: 2rem;
    }

    #faq-section-wrapper .faq-content-panel {
        padding: 30px 16px;
    }

    #faq-section-wrapper .accordion-trigger {
        padding: 20px 24px;
        font-size: 1rem;
    }

    #faq-section-wrapper .accordion-inner {
        padding: 0 24px 24px 24px;
    }

    #faq-section-wrapper .faq-group-title {
        font-size: 1.3rem;
    }
}

/*
  =====================================================================
  SECCIÓN SOBRE NOSOTROS
  =====================================================================
*/
#nosotros-wrapper {
    --detail-accent: #FFC761;
    background-color: #F5F5F5;
    color: var(--text-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    width: 100%;
    overflow-x: hidden;
}

#nosotros-wrapper *,
#nosotros-wrapper *::before,
#nosotros-wrapper *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-main);
}

/* Contenedor de la sección. */
#nosotros-wrapper .nosotros-section {
    padding: 60px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Encabezado de la sección. */
#nosotros-wrapper .nosotros-header {
    text-align: center;
    margin-bottom: 60px;
}

#nosotros-wrapper .nosotros-header h2 {
    font-size: clamp(2rem, 5vw, 2.8rem);
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1.2;
    margin-bottom: 16px;
}

#nosotros-wrapper .nosotros-header p {
    font-size: 1.1rem;
    color: var(--text-gray);
    max-width: 700px;
    margin: 0 auto;
}

/* Grid para organizar las diferentes tarjetas de "Nosotros". */
#nosotros-wrapper .nosotros-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
}

/* Estilo base para las tarjetas de esta sección. */
#nosotros-wrapper .card-nosotros {
    background-color: var(--color-white);
    border-radius: var(--radius-card);
    padding: 32px;
    box-shadow: var(--shadow-soft);
    border: 1px solid #E5E7EB;
    transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
    opacity: 0;
    transform: scale(0.95);
    filter: blur(5px);
}

#nosotros-wrapper .card-nosotros.is-visible {
    opacity: 1;
    transform: scale(1);
    filter: blur(0);
}

#nosotros-wrapper .card-nosotros:hover {
    transform: scale(1.02);
    border-color: var(--color-primary);
    box-shadow: 0 12px 30px rgba(3, 131, 69, 0.1);
}

/* Título dentro de cada tarjeta. */
#nosotros-wrapper .card-nosotros h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-accent);
    margin-bottom: 16px;
}

/* Tarjeta específica "Quiénes Somos". */
#nosotros-wrapper .quienes-somos-card {
    display: flex;
    flex-direction: column;
    gap: 24px;
}
#nosotros-wrapper .quienes-somos-img {
    width: 100%;
    height: 250px;
    border-radius: 12px;
    object-fit: cover;
}

/* Tarjeta específica "Sellos". */
#nosotros-wrapper .sellos-card {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

#nosotros-wrapper .sellos-img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 12px;
}

/* Grid para las tarjetas de Visión y Misión. */
#nosotros-wrapper .vision-mision-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
}

/* Grid para los ítems de "Nuestros Valores". */
#nosotros-wrapper .valores-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-top: 16px;
}
#nosotros-wrapper .valor-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background-color: #F9FAFB;
    padding: 16px;
    border-radius: 10px;
    border: 1px solid #F3F4F6;
}
#nosotros-wrapper .valor-icon { font-size: 1.5rem; }
#nosotros-wrapper .valor-text strong { display: block; font-size: 1rem; color: var(--text-dark); }
#nosotros-wrapper .valor-text span { font-size: 0.85rem; color: var(--text-gray); }

/* Grid para los ítems de "Sellos". */
#nosotros-wrapper .sellos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-top: 16px;
}
#nosotros-wrapper .sello-item { text-align: center; }
#nosotros-wrapper .sello-icon {
    width: 50px;
    height: 50px;
    margin: 0 auto 12px;
    background-color: var(--color-accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    font-size: 1.5rem;
}
#nosotros-wrapper .sello-item strong { display: block; font-size: 1rem; }
#nosotros-wrapper .sello-item span { font-size: 0.85rem; color: var(--text-gray); }

@media (max-width: 480px) {
    #nosotros-wrapper .nosotros-header h2 {
        font-size: 1.8rem;
    }
    #nosotros-wrapper .card-nosotros {
        padding: 24px;
    }
}

@media (min-width: 768px) {
    /* En tabletas, el grid principal pasa a 2 columnas. */
    #nosotros-wrapper .nosotros-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    #nosotros-wrapper .quienes-somos-card, 
    #nosotros-wrapper .valores-card, 
    #nosotros-wrapper .sellos-card {
        grid-column: span 2;
    }
    #nosotros-wrapper .quienes-somos-card {
        flex-direction: row;
        align-items: center;
    }
    #nosotros-wrapper .quienes-somos-text { flex: 1; }
    #nosotros-wrapper .quienes-somos-img { flex: 1; height: 300px; }
    
    #nosotros-wrapper .sellos-card {
        flex-direction: row-reverse;
        align-items: center;
    }
    #nosotros-wrapper .sellos-content { flex: 1; }
    #nosotros-wrapper .sellos-img { 
        width: 35%; 
        height: 100%; 
        min-height: 280px; 
    }
}

@media (min-width: 1024px) {
    /* En escritorio, el layout se vuelve más complejo con 3 columnas. */
    #nosotros-wrapper .nosotros-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    #nosotros-wrapper .quienes-somos-card { grid-column: 1 / 3; }
    #nosotros-wrapper .vision-mision-grid { grid-column: 3 / 4; display: flex; flex-direction: column; }
    #nosotros-wrapper .valores-card { grid-column: 1 / 4; }
    #nosotros-wrapper .sellos-card { grid-column: 1 / 4; }
}

/*
  =====================================================================
  SECCIÓN DE CONTACTO
  =====================================================================
*/
#contacto-wrapper {
    --color-error: #EF4444;
    --color-success: #10B981;
    background-color: var(--color-bg-light);
    box-sizing: border-box;
    overflow: hidden;
}

#contacto-wrapper *, 
#contacto-wrapper *::before, 
#contacto-wrapper *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Estilos del encabezado del formulario (Movidos aquí para asegurar prioridad) */
#contacto-wrapper .contact-header-container { margin-bottom: 30px; }
#contacto-wrapper .contact-header-title {
    font-size: 2rem;
    color: var(--color-primary);
    margin-bottom: 8px;
    font-weight: 800;
}
#contacto-wrapper .contact-header-subtitle { 
    color: var(--color-text-light); 
    font-size: 1.1rem; 
}

/* Asegura que los elementos de formulario hereden la fuente correcta. */
#contacto-wrapper button, 
#contacto-wrapper input, 
#contacto-wrapper textarea {
    font-family: var(--font-main);
}

#contacto-wrapper .contact-section {
    padding: 20px 20px 80px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Círculos decorativos radiales en el fondo. */
#contacto-wrapper .contact-section::before {
    content: '';
    position: absolute;
    top: -10%;
    right: -5%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(108, 190, 75, 0.1) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
    z-index: 0;
}

#contacto-wrapper .contact-section::after {
    content: '';
    position: absolute;
    bottom: -10%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(3, 131, 69, 0.08) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
    z-index: 0;
}

/* Contenedor principal que agrupa las columnas de información y formulario. */
#contacto-wrapper .container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    background: var(--color-white);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    position: relative;
    z-index: 1;
}

/* Columna de información (dirección, teléfono, etc.). */
#contacto-wrapper .info-column {
    background-color: var(--color-primary);
    color: var(--color-white);
    padding: 60px 40px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    min-height: 500px;
}

/* Patrón de fondo sutil para la columna de información. */
#contacto-wrapper .info-column::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

/* Encabezado dentro de la columna de información. */
#contacto-wrapper .info-header h2 {
    font-size: 2.2rem;
    margin-bottom: 20px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

#contacto-wrapper .info-header p {
    opacity: 0.9;
    margin-bottom: 40px;
    font-size: 1.1rem;
    line-height: 1.2;
}

/* Contenedor de los detalles de contacto. */
#contacto-wrapper .contact-details {
    display: flex;
    flex-direction: column;
    gap: 30px;
    margin-bottom: 40px;
}

/* Cada ítem de detalle (ícono + texto). */
#contacto-wrapper .detail-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

#contacto-wrapper .detail-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    fill: var(--color-accent);
    margin-top: 2px;
}

#contacto-wrapper .detail-text strong {
    display: block;
    font-size: 0.9rem;
    margin-bottom: 4px;
    color: var(--color-accent);
}

#contacto-wrapper .detail-text span {
    font-size: 1rem;
    opacity: 0.95;
}

/* Contenedor del mapa de Google. */
#contacto-wrapper .map-container {
    width: 100%;
    height: 200px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    margin-top: auto;
    background-color: #025e31;
    border: 2px solid rgba(255,255,255,0.1);
}

#contacto-wrapper iframe {
    width: 100%;
    height: 100%;
    border: 0;
    filter: grayscale(20%) contrast(1.1);
}

/* Columna del formulario. */
#contacto-wrapper .form-column {
    padding: 60px;
    background-color: var(--color-white);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Grupo de formulario (input + label + error). */
#contacto-wrapper .form-group {
    margin-bottom: 35px;
    position: relative;
}

#contacto-wrapper .form-group:nth-of-type(3) {
    margin-bottom: 0;
    z-index: 5;
}
#contacto-wrapper .form-group:nth-of-type(4) {
    margin-top: -60px;
}

/* Estilo de los campos de entrada con solo una línea inferior. */
#contacto-wrapper .form-control {
    width: 100%;
    padding: 12px 0;
    border: none;
    border-bottom: 2px solid #E5E7EB;
    background-color: transparent;
    font-size: 1.1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    color: var(--color-text-main);
    border-radius: 0;
}

/* Etiqueta del campo. */
#contacto-wrapper label {
    position: absolute;
    top: 12px;
    left: 0;
    font-size: 1.1rem;
    color: var(--color-text-light);
    pointer-events: none;
    transition: all 0.3s ease;
}

#contacto-wrapper .form-control:focus {
    border-bottom-color: var(--color-primary);
}

/* Efecto "etiqueta flotante": la etiqueta se mueve hacia arriba cuando el campo tiene foco o contenido. */
#contacto-wrapper .form-control:focus ~ label,
#contacto-wrapper .form-control:not(:placeholder-shown) ~ label {
    top: -20px;
    font-size: 0.85rem;
    color: var(--color-primary);
    font-weight: 700;
}

/* Estilos para validación (campo válido). */
#contacto-wrapper .form-control.is-valid {
    border-bottom-color: var(--color-success);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2310B981'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 13l4 4L19 7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0 center;
    background-size: 24px;
}

/* Estilos para validación (campo inválido). */
#contacto-wrapper .form-control.is-invalid {
    border-bottom-color: var(--color-error);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23EF4444'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M6 18L18 6M6 6l12 12'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0 center;
    background-size: 24px;
}

/* Mensaje de error, oculto por defecto. */
#contacto-wrapper .error-message {
    display: none;
    color: var(--color-error);
    font-size: 0.85rem;
    margin-top: 8px;
}

/* Muestra el mensaje de error cuando el campo es inválido. */
#contacto-wrapper .form-control.is-invalid + .error-message {
    display: block;
}

/* Ajustes específicos para el textarea. */
#contacto-wrapper textarea.form-control {
    resize: vertical;
    min-height: 80px;
    margin-top: 0;
    padding-top: 130px;
    padding-bottom: 12px;
}

#contacto-wrapper textarea.form-control ~ label {
    top: 140px;
}
#contacto-wrapper textarea.form-control:focus ~ label,
#contacto-wrapper textarea.form-control:not(:placeholder-shown) ~ label {
    top: -15px;
}

/* Botón de envío del formulario. */
#contacto-wrapper .submit-btn {
    background-color: var(--color-primary);
    color: var(--color-white);
    border: none;
    padding: 18px 32px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
    box-shadow: 0 10px 20px -5px rgba(3, 131, 69, 0.3);
}

#contacto-wrapper .submit-btn:hover {
    background-color: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -5px rgba(3, 131, 69, 0.5);
}

@media (min-width: 900px) {
    /* En escritorio, las columnas de información y formulario se ponen una al lado de la otra. */
    #contacto-wrapper .container {
        flex-direction: row;
        min-height: 650px;
    }
    
    #contacto-wrapper .form-column {
        flex: 1.4;
        order: 1;
    }
    
    #contacto-wrapper .info-column {
        flex: 1;
        order: 2;
    }
}

@media (max-width: 899px) {
    #contacto-wrapper .info-column {
        padding: 50px 24px;
        order: 2;
    }
    #contacto-wrapper .form-column {
        padding: 50px 24px;
        order: 1;
    }
    #contacto-wrapper .map-container {
        height: 200px;
    }
}

/*
  =====================================================================
  SECCIÓN DE CIERRE (CALL TO ACTION FINAL)
  =====================================================================
*/
#cierre-wrapper {
    font-family: var(--font-main);
    width: 100%;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

#cierre-wrapper *, 
#cierre-wrapper *::before, 
#cierre-wrapper *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Contenedor de la sección. */
#cierre-wrapper .cta-section {
    background: linear-gradient(135deg, var(--color-primary) 0%, #025e31 100%);
    padding: 60px 20px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 450px;
}

/* Círculo decorativo de fondo. */
#cierre-wrapper .cta-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(108, 190, 75, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

/* Contenedor interno que alinea el texto y la imagen. */
#cierre-wrapper .cta-container {
    max-width: 1100px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    z-index: 2;
    gap: 40px;
}

@media (min-width: 900px) {
    #cierre-wrapper .cta-container {
        flex-direction: row;
        text-align: left;
        justify-content: space-between;
    }
    #cierre-wrapper .cta-section {
        padding: 80px 40px;
    }
}

/* Contenido de texto del CTA. */
#cierre-wrapper .cta-content {
    flex: 1;
    color: var(--color-white);
}

/* Título del CTA. */
#cierre-wrapper .cta-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.1;
}

/* Texto del CTA. */
#cierre-wrapper .cta-text {
    font-size: 1.1rem;
    margin-bottom: 32px;
    opacity: 0.95;
    max-width: 500px;
}

/* Botón de CTA (estilo simple, no usado actualmente). */
#cierre-wrapper .cta-btn {
    display: inline-block;
    background-color: var(--color-accent);
    color: var(--color-white);
    padding: 18px 36px;
    border-radius: 50px;
    font-weight: 700;
    text-decoration: none;
    font-size: 1.1rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

#cierre-wrapper .cta-btn:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
    background-color: #5da840;
}

/* Contenedor de la imagen del CTA. */
#cierre-wrapper .cta-image-wrapper {
    flex: 0.8;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Imagen del CTA con animación de flotación. */
#cierre-wrapper .cta-img {
    max-width: 100%;
    height: auto;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
    animation: float-img 6s ease-in-out infinite;
    border: 4px solid rgba(255,255,255,0.1);
}

/* Animación de flotación para la imagen. */
@keyframes float-img {
    0% { transform: translateY(0px) rotate(-2deg); }
    50% { transform: translateY(-15px) rotate(-1deg); }
    100% { transform: translateY(0px) rotate(-2deg); }
}

#cierre-wrapper .cta-img:hover { animation-play-state: paused; }

/* Contenedor del botón animado especial. */
#cierre-wrapper #boton-9-container-unico {
    margin-top: 0%;
    text-align: inherit;
    font-family: var(--font-main);
}

/* Animación compleja para el botón "neo-pop". Cambia de color, sombra y posición. */
@keyframes neo-pop-cycle {
    0%, 45% {
        background-color: #ffffff;
        color: #000000;
        box-shadow: 6px 6px 0px var(--color-primary);
        transform: translate(0, 0);
        border-color: #000000;
    }
    50% {
        transform: translate(-4px, -4px) rotate(-1deg);
        box-shadow: 10px 10px 0px #000000;
    }
    55%, 95% {
        background-color: #005c4b;
        color: #ffffff;
        box-shadow: 8px 8px 0px var(--color-primary);
        transform: translate(-2px, -2px);
        border-color: #000000;
    }
    100% {
        background-color: #ffffff;
        color: #000000;
        box-shadow: 6px 6px 0px #005c4b;
        transform: translate(0, 0);
    }
}

/* El botón animado. */
#cierre-wrapper #boton-9-container-unico .boton-neo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 800;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 60px;
    border: 3px solid #000000;
    transition: none; 
    position: relative;
		z-index: 1;
    animation: neo-pop-cycle 6s infinite cubic-bezier(0.68, -0.55, 0.265, 1.55);
    max-width: 100%;
}

/* Estado activo (al hacer clic). */
#cierre-wrapper #boton-9-container-unico .boton-neo:active {
		animation: none;
    box-shadow: 0px 0px 0px var(--color-primary);
    transform: translate(6px, 6px);
    background-color: #005c4b;
    color: #ffffff;
}
		
#cierre-wrapper #boton-9-container-unico .boton-neo svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

/* Animación de rebote para el estado hover. */
@keyframes neo-bounce-hover {
    0% { transform: translate(-2px, -2px) scale(1); }
    100% { transform: translate(-2px, -6px) scale(1.05); }
}

/* Estado hover del botón. */
#cierre-wrapper #boton-9-container-unico .boton-neo:hover {
    animation: neo-bounce-hover 0.4s infinite alternate cubic-bezier(0.25, 0.8, 0.25, 1);
		background-color: var(--color-primary-dark);
    color: #ffffff;
    box-shadow: 8px 8px 0px #000000;
    border-color: var(--color-primary);
}

/* Partículas (no implementado en el HTML, pero el estilo está aquí). */
.neo-particle {
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    will-change: transform, opacity;
}

@media (max-width: 480px) {
    #cierre-wrapper #boton-9-container-unico .boton-neo {
        padding: 14px 24px;
        font-size: 14px;
    }
}

/*
  =====================================================================
  BOTÓN Y POPUP DEL CHATBOT
  =====================================================================
*/
.chat-bot-button {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 110px;
  height: 110px;
  background-color: transparent;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  z-index: 10000;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  animation: popIn 1s cubic-bezier(0.68, -0.55, 0.265, 1.55) backwards;
}

/* Animación de entrada para el botón del chat. */
@keyframes popIn {
  0% { transform: scale(0) rotate(-180deg); opacity: 0; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

/* Efecto de ondas expansivas para llamar la atención. */
.chat-bot-button::before,
.chat-bot-button::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid #6CBE4B;
  opacity: 0;
  z-index: -1;
  animation: gold-ripple 2s infinite linear;
}

.chat-bot-button::after {
  animation-delay: 1s;
}

/* Animación de la onda. */
@keyframes gold-ripple {
  0% { width: 80%; height: 80%; opacity: 0.8; border-width: 2px; }
  100% { width: 160%; height: 160%; opacity: 0; border-width: 0px; }
}

.chat-bot-button:hover {
  transform: scale(1.1) rotate(5deg);
}

/* Imagen del botón del chat con sombra y animación de flotación. */
.chat-bot-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 4px 8px rgba(3, 131, 69, 0.4));
  animation: float-img-chatbot 3s ease-in-out infinite;
}

/* Animación de flotación para la imagen del chat. */
@keyframes float-img-chatbot {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

/* El popup del chat, inicialmente oculto y escalado a 0. */
.chat-popup {
  position: fixed;
  bottom: 160px;
  right: 30px;
  width: 320px;
  background-color: #ffffff;
  border-radius: 20px;
  box-shadow: 0 20px 50px rgba(3, 131, 69, 0.25);
  padding: 0;
  z-index: 999;
  overflow: hidden;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  transform-origin: bottom right;
  transform: scale(0);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.19, 1, 0.22, 1);
  border: 1px solid rgba(108, 190, 75, 0.3);
}

@media (max-width: 600px) {
  .chat-bot-button {
    width: 70px;
    height: 70px;
    bottom: 20px;
    right: 20px;
  }
  .chat-popup {
    bottom: 100px;
    right: 20px;
    width: 280px;
    max-height: 70vh;
  }
}

/* Muestra el popup cuando tiene la clase 'visible'. */
.chat-popup.visible {
  transform: scale(1);
  opacity: 1;
}

/* Encabezado del popup. */
.chat-header {
  background: linear-gradient(135deg, #038345 0%, #026b38 100%);
  color: #ffffff;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.chat-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: #6CBE4B;
}

.chat-header h3 {
  margin: 0;
  font-weight: 600;
  font-size: 17px;
  line-height: 1.4;
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-header .chat-header-icon {
  width: 24px;
  filter: brightness(0) invert(1);
}

.chat-header h3 img {
  animation: wave 2s ease-in-out infinite;
  transform-origin: 70% 70%;
}

/* Animación de saludo para el ícono del asesor. */
@keyframes wave {
  0%, 100% { transform: rotate(0deg); }
  20% { transform: rotate(-15deg); }
  40% { transform: rotate(10deg); }
  60% { transform: rotate(-5deg); }
  80% { transform: rotate(5deg); }
}

/* Botón para cerrar el popup. */
.close-btn {
  background: none;
  border: none;
  color: #ffffff;
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  opacity: 0.8;
  transition: opacity 0.2s;
  line-height: 1;
}

.close-btn:hover {
  opacity: 1;
  transform: rotate(90deg);
  transition: transform 0.3s;
}

/* Cuerpo del popup. */
.chat-body {
  padding: 25px 20px;
  text-align: center;
  background-color: #ffffff;
  background-image: radial-gradient(#6CBE4B 0.5px, transparent 0.5px);
  background-size: 15px 15px;
  animation: bgMove 30s linear infinite;
}

/* Animación sutil para el patrón de fondo. */
@keyframes bgMove {
  0% { background-position: 0 0; }
  100% { background-position: 30px 30px; }
}

/* Mensaje de bienvenida en el chat. */
.chat-message {
  background-color: #f4f6f9;
  padding: 15px 18px;
  border-radius: 15px;
  border-top-left-radius: 2px;
  text-align: left;
  margin-bottom: 20px;
  font-size: 14px;
  color: #038345;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  border-left: 3px solid #6CBE4B;
  line-height: 1.5;
  position: relative;
}

/* Botón para iniciar la conversación en WhatsApp. */
.start-chat-btn {
  background: linear-gradient(90deg, #6CBE4B, #85d466);
  color: #038345;
  border: none;
  padding: 15px 25px;
  border-radius: 50px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 10px;
  transition: all 0.3s;
  width: 100%;
  font-size: 16px;
  box-shadow: 0 4px 15px rgba(108, 190, 75, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-transform: uppercase;
  position: relative;
  overflow: hidden;
}

/* Animación de brillo para el botón de WhatsApp. */
.start-chat-btn::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
  animation: shimmer 3s infinite;
}

@keyframes shimmer {
  0% { left: -100%; }
  20% { left: 100%; }
  100% { left: 100%; }
}

.start-chat-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(108, 190, 75, 0.6);
  background: linear-gradient(90deg, #85d466, #6CBE4B);
}

.start-chat-btn:active {
  transform: translateY(0);
}

/* Mensaje "Chat seguro y confidencial". */
.bank-secure {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 20px;
  font-size: 13px;
  color: #555;
  opacity: 0; /* Oculto inicialmente */
}

.bank-secure svg {
  width: 16px;
  height: 16px;
  fill: #038345;
  margin-right: 6px;
}

/* Animación de entrada para el mensaje del chat. */
@keyframes slideIn {
  from { opacity: 0; transform: translateY(10px) scale(0.95); filter: blur(4px); }
  to { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

/* Animación de desvanecimiento simple. */
@keyframes fadeIn {
  to { opacity: 1; }
}

.chat-popup.visible .chat-message {
  animation: slideIn 0.5s ease-out 0.2s forwards;
  opacity: 0; /* Inicialmente oculto para la animación */
}

.chat-popup.visible .bank-secure {
  animation: fadeIn 0.8s ease forwards 0.6s;
}

/* =========================================
   ESTILOS DEL FOOTER (PIE DE PÁGINA)
   ========================================= */
.site-footer {
    /* Estilos para el pie de página final del sitio. */
    background-color: #FFFFFF; /* Fondo blanco limpio */
    padding: 80px 20px; /* Márgenes amplios y aireados */
    border-top: 1px solid #E5E7EB; /* Separación sutil */
    font-family: 'Poppins', sans-serif; /* Tipografía moderna */
    width: 100%;
}

/* Contenedor del footer para centrar y alinear las columnas. */
.footer-container {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 80px;
    flex-wrap: wrap;
}

/* Cada columna del footer. */
.footer-column {
    flex: 1;
    min-width: 280px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Título de cada columna del footer. */
.footer-title {
    font-family: 'Inter', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 24px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
}

/* Línea decorativa debajo del título del footer. */
.footer-title::after {
    content: '';
    display: block;
    width: 40px;
    height: 3px;
    background-color: var(--color-accent);
    margin: 10px auto 0;
    border-radius: 2px;
}

/* Navegación del footer. */
.footer-nav {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Enlaces de la navegación del footer. */
.footer-nav a {
    color: var(--color-primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: color 0.3s ease, transform 0.2s ease;
}

.footer-nav a:hover {
    color: var(--color-accent);
    transform: translateY(-2px);
}

/* Texto legal y descriptivo en el footer. */
.footer-text {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--color-text-body);
    max-width: 350px;
}

@media (max-width: 768px) {
    .site-footer {
        padding: 60px 20px;
    }
    .footer-container {
        flex-direction: column;
        gap: 50px;
    }
    .footer-column {
        width: 100%;
    }
}

/*
  =====================================================================
  RETRASOS DE TRANSICIÓN (ANIMACIONES ESCALONADAS)
  =====================================================================
  Estos selectores añaden un pequeño retraso a la animación de cada tarjeta
  para que no aparezcan todas a la vez, creando un efecto más dinámico.
*/
.section-ventajas .card:nth-child(1) { transition-delay: 100ms; }
.section-ventajas .card:nth-child(2) { transition-delay: 200ms; }
.section-ventajas .card:nth-child(3) { transition-delay: 300ms; }

#requisitos-wrapper .req-card:nth-child(1) { transition-delay: 100ms; }
#requisitos-wrapper .req-card:nth-child(2) { transition-delay: 250ms; }
#requisitos-wrapper .req-card:nth-child(3) { transition-delay: 400ms; }

/*
  =====================================================================
  MODAL DE ESTADO (ÉXITO/ERROR)
  =====================================================================
  Estilos para el popup que aparece después de enviar un formulario.
*/
.status-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: 11000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

/* Muestra el modal. */
.status-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Contenido del modal. */
.status-modal-content {
    background: #FFFFFF;
    width: 90%;
    max-width: 400px;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0,0,0,0.2);
    transform: scale(0.8);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.status-modal-overlay.active .status-modal-content {
    transform: scale(1);
}

/* Contenedor del ícono (check o cruz). */
.status-icon-wrapper {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Estilo para el ícono de éxito. */
.status-icon-wrapper.success {
    background-color: #DEF7EC;
    color: #038345;
}

/* Estilo para el ícono de error. */
.status-icon-wrapper.error {
    background-color: #FDE8E8;
    color: #EF4444;
}

.status-icon-wrapper svg {
    width: 40px;
    height: 40px;
    fill: currentColor;
}

/* Título del modal. */
.status-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1F2A37;
    margin-bottom: 10px;
}

/* Mensaje del modal. */
.status-message {
    font-size: 1rem;
    color: #6B7280;
    margin-bottom: 30px;
    line-height: 1.5;
}

/* Botón para cerrar el modal. */
.status-close-btn {
    background-color: #038345;
    color: #FFFFFF;
    border: none;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
}

.status-close-btn:hover {
    background-color: #025e31;
}