/* === 1. VARIABLES Y ESTILOS BASE === */
:root {
    --color-dark-blue: #006792;
    --color-teal: #65CCCC;
    --color-header-dark: #142D3E; /* Nuevo color azul oscuro para header */
    --color-white: #FFFFFF;
    --color-light-gray: #f0f4f8;
    --color-text: #dfe3e7;
    --font-primary: 'Poppins', sans-serif;
    --header-height: 70px;
}

html { scroll-behavior: smooth; }

body {
    background-color: var(--color-dark-blue);
    color: var(--color-text);
    font-family: var(--font-primary);
    margin: 0;
    line-height: 1.7;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* === 2. ESTILOS GENERALES (Títulos, Botones, etc.) === */
.section-title {
    text-align: center;
    font-size: 2.2rem;
    color: var(--color-white);
    margin-bottom: 40px;
    font-weight: 600;
}

.cta-button {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.cta-button.primary {
    background: rgba(101, 204, 204, 0.1);
    color: var(--color-teal);
    border: 1px solid var(--color-teal);
}

.cta-button.primary:hover {
    background: var(--color-teal);
    color: var(--color-white);
    border-color: var(--color-teal);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(101, 204, 204, 0.4);
}

.cta-button.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-white);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.cta-button.secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    color: var(--color-teal);
    border-color: var(--color-teal);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(101, 204, 204, 0.2);
}

/* === 3. HEADER Y NAVEGACIÓN === */
.site-header {
    background: rgba(20, 45, 62, 0.95); /* #142D3E con transparencia */
    backdrop-filter: blur(15px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    height: var(--header-height);
    border-bottom: 1px solid rgba(101, 204, 204, 0.2);
    transition: all 0.3s ease;
}

.site-header.scrolled {
    background: rgba(20, 45, 62, 0.98); /* #142D3E más sólido al hacer scroll */
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* Solo en desktop: ocultar header al hacer scroll hacia abajo */
@media (min-width: 1024px) {
    .site-header.hide-header {
        transform: translateY(-100%);
    }
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: transform 0.3s ease;
}

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

.logo img { 
    height: 45px; 
    width: auto;
    border-radius: 4px;
}

/* Teléfono en header (solo desktop) */
.header-phone {
    display: none;
    align-items: center;
    gap: 8px;
    color: var(--color-white);
    text-decoration: none;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 25px;
    border: 1px solid rgba(255, 255, 255, 0.3); /* Marco siempre visible */
    background: rgba(255, 255, 255, 0.1); /* Fondo sutil */
    transition: all 0.3s ease;
}

.header-phone:hover {
    color: var(--color-teal);
    background: rgba(101, 204, 204, 0.2); /* Fondo más brillante al hover */
    border-color: var(--color-teal); /* Borde se ilumina al hover */
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(101, 204, 204, 0.2); /* Sombra sutil */
}

.header-phone svg {
    flex-shrink: 0;
}

/* Navegación Desktop - Oculta en móvil */
.main-nav {
    display: none;
}

.main-nav ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 25px;
    align-items: center;
}

.main-nav li {
    margin: 0;
}

.main-nav a {
    color: var(--color-white);
    text-decoration: none;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 25px;
    transition: all 0.3s ease;
    position: relative;
}

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

.main-nav a.nav-cta {
    background: rgba(101, 204, 204, 0.1);
    color: var(--color-teal);
    border: 1px solid var(--color-teal);
    font-weight: 500;
    padding: 10px 20px;
}

.main-nav a.nav-cta:hover {
    background: var(--color-teal);
    color: var(--color-white);
    border-color: var(--color-teal);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(101, 204, 204, 0.4);
}

/* Botón del menú móvil */
.nav-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    z-index: 1001;
    transition: transform 0.3s ease;
}

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

.nav-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background: var(--color-white);
    transition: all 0.3s ease;
    border-radius: 2px;
}

/* Animación del botón hamburguesa */
.nav-toggle.is-active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.is-active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.is-active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Menú móvil desplegable */
.main-nav.is-active {
    display: block;
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background: linear-gradient(135deg, var(--color-dark-blue) 0%, #004d6b 100%);
    padding: 40px 20px;
    z-index: 1000;
    animation: slideDown 0.3s ease-out;
}

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

.main-nav.is-active ul {
    flex-direction: column;
    gap: 0;
    height: 100%;
    justify-content: flex-start;
    align-items: center;
    padding-top: 20px;
}

.main-nav.is-active li {
    margin: 15px 0;
    width: 100%;
    text-align: center;
}

.main-nav.is-active a {
    display: block;
    font-size: 1.2rem;
    padding: 15px 25px;
    color: var(--color-white);
    border: 2px solid transparent;
    border-radius: 50px;
    transition: all 0.3s ease;
    width: 80%;
    max-width: 250px;
    margin: 0 auto;
}

.main-nav.is-active a:hover {
    background: rgba(101, 204, 204, 0.1);
    border-color: var(--color-teal);
    transform: translateY(-3px);
}

.main-nav.is-active a.nav-cta {
    background: var(--color-teal);
    color: var(--color-dark-blue);
    font-weight: 600;
    margin-top: 20px;
}

.main-nav.is-active a.nav-cta:hover {
    background: var(--color-white);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(101, 204, 204, 0.3);
}

/* === 4. SECCIONES === */
main { padding-top: var(--header-height); }

.hero-section {
    min-height: calc(100vh - var(--header-height));
    display: flex;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Carrusel de imágenes del hero */
.hero-carousel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* Por defecto, mostrar carrusel móvil */
.desktop-carousel {
    display: none;
}

.mobile-carousel {
    display: block;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Overlay para legibilidad del texto */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(0, 103, 146, 0.8) 0%, 
        rgba(20, 45, 62, 0.7) 50%, 
        rgba(0, 103, 146, 0.8) 100%);
    z-index: 2;
}

/* Contenido del hero por encima del carrusel */
.hero-section .container {
    position: relative;
    z-index: 3;
}

.hero-title {
    font-size: 2.5rem;
    color: var(--color-white);
    font-weight: 700;
    line-height: 1.2;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: 1.1rem;
    max-width: 600px;
    margin: 20px auto 30px;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.3);
}
.hero-cta-group {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

.services-section, .about-section, .partners-section, .contact-section {
    padding: 60px 0;
}
.services-section { background: var(--color-light-gray); color: var(--color-dark-blue); }
.services-section .section-title { color: var(--color-dark-blue); }
.services-grid { display: grid; gap: 30px; }
.service-card {
    background: var(--color-white);
    padding: 40px 30px;
    border-radius: 16px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
    transition: all 0.4s ease;
    text-align: center;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--color-teal), var(--color-dark-blue));
    transition: left 0.4s ease;
}

.service-card:hover::before {
    left: 0;
}

.service-card:hover { 
    transform: translateY(-12px); 
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    border-color: var(--color-teal);
}

.service-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--color-teal), var(--color-dark-blue));
    border-radius: 50%;
    margin-bottom: 24px;
    color: var(--color-white);
    transition: all 0.3s ease;
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
}

.service-card h3 {
    color: var(--color-dark-blue);
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 16px;
    transition: color 0.3s ease;
}

.service-card:hover h3 {
    color: var(--color-teal);
}

.service-card p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 24px;
}

.service-features {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
}

.feature {
    color: var(--color-dark-blue);
    font-size: 0.9rem;
    font-weight: 500;
    padding: 4px 12px;
    background: rgba(101, 204, 204, 0.1);
    border-radius: 20px;
    transition: all 0.3s ease;
}

.service-card:hover .feature {
    background: rgba(101, 204, 204, 0.2);
    transform: translateX(5px);
}

.about-section { 
    background: var(--color-dark-blue); 
}

/* Estilos para la sección About con dos columnas */
.about-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    align-items: center;
}

/* Variante sin imagen */
.about-content.no-image {
    grid-template-columns: 1fr;
    max-width: 800px;
    margin: 0 auto;
}

.about-content.no-image .about-text {
    text-align: center;
}

/* Asegurar que el título también quede centrado en la variante sin imagen (sobrescribe la regla de desktop) */
.about-content.no-image .about-text h2 {
    text-align: center;
}

.about-content.no-image .about-image { display: none; }

.about-text {
    text-align: center;
}

.about-text h2 {
    margin-bottom: 20px;
}

.about-text h3 {
    color: var(--color-teal);
    font-size: 1.5rem;
    margin-bottom: 20px;
    font-weight: 600;
}

.about-text p {
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--color-text);
}

.about-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.about-image img {
    width: 100%;
    max-width: 300px;
    height: auto;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.about-image img:hover {
    transform: scale(1.05);
}

.partners-section { background: var(--color-light-gray); text-align: center; }
.partners-section .section-title { color: var(--color-dark-blue); }

/* Carrusel de socios infinito */
.partners-carousel-container {
    overflow: hidden;
    width: 100%;
    position: relative;
}

.partners-carousel {
    display: flex;
    width: calc(200% * 5 / 3); /* 10 slides (duplicados), mostramos 3 */
    animation: infiniteScroll 20s linear infinite;
}

.partner-slide {
    flex: 0 0 calc(100% / 10); /* Cada slide ocupa 1/10 del carrusel */
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}

.partner-slide img {
    max-width: 120px;
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.3s ease;
    cursor: pointer;
}

.partner-slide img:hover {
    transform: scale(1.1);
}

/* Animación infinita CSS */
@keyframes infiniteScroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%); /* Mueve exactamente la mitad (5 slides) */
    }
}

/* Pausar animación al hover */
.partners-carousel-container:hover .partners-carousel {
    animation-play-state: paused;
}

.contact-section { text-align: center; }

/* === 5. BOTÓN WHATSAPP FLOTANTE === */
.whatsapp-float {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 60px;
    height: 60px;
    background: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); /* Transición más suave */
    animation: whatsappPulse 2s infinite;
    opacity: 0; /* Inicialmente oculto */
    transform: scale(0.8) translateY(20px); /* Posición inicial */
    pointer-events: none; /* Deshabilitado inicialmente */
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(37, 211, 102, 0.6);
    background: #128C7E;
}

.whatsapp-float svg {
    transition: transform 0.3s ease;
}

.whatsapp-float:hover svg {
    transform: scale(1.1);
}

@keyframes whatsappPulse {
    0% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4), 0 0 0 0 rgba(37, 211, 102, 0.4);
    }
    70% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4), 0 0 0 10px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4), 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

/* Responsivo para el botón de WhatsApp */
@media (max-width: 768px) {
    .whatsapp-float {
        width: 55px;
        height: 55px;
        bottom: 20px;
        right: 20px;
    }
    
    .whatsapp-float svg {
        width: 24px;
        height: 24px;
    }
    
    /* Footer móvil - botones más compactos */
    .footer-contact {
        gap: 8px;
    }
    
    .contact-item {
        padding: 5px 10px;
        font-size: 0.8rem;
    }
    
    .contact-item svg {
        width: 14px;
        height: 14px;
    }
    
    /* Servicios móvil */
    .service-card {
        padding: 30px 20px;
    }
    
    .service-icon {
        width: 70px;
        height: 70px;
        margin-bottom: 20px;
    }
    
    .service-features {
        gap: 6px;
    }
    
    .feature {
        font-size: 0.8rem;
        padding: 3px 10px;
    }
}

@media (max-width: 480px) {
    /* Hero carousel - optimización para móvil pequeño */
    .mobile-carousel .hero-slide img {
        object-position: center top; /* Mejor posicionamiento en móviles pequeños */
    }
    
    .hero-overlay {
        background: linear-gradient(135deg, 
            rgba(0, 103, 146, 0.85) 0%, 
            rgba(20, 45, 62, 0.75) 50%, 
            rgba(0, 103, 146, 0.85) 100%);
    }
    
    .whatsapp-float {
        width: 50px;
        height: 50px;
        bottom: 15px;
        right: 15px;
    }
    
    .whatsapp-float svg {
        width: 22px;
        height: 22px;
    }
    
    /* Footer muy pequeño - botones aún más compactos */
    .footer-contact {
        gap: 6px;
    }
    
    .contact-item {
        padding: 4px 8px;
        font-size: 0.75rem;
    }
    
    .contact-item svg {
        width: 12px;
        height: 12px;
    }
}

/* === 6. ANIMACIONES Y FOOTER === */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
    will-change: opacity, transform; /* Optimización para animaciones */
}

.animate-on-scroll.visible { 
    opacity: 1; 
    transform: translateY(0); 
}

/* Asegurar que los elementos mantengan su visibilidad inicial correcta */
.animate-on-scroll:not(.visible) {
    opacity: 0;
    transform: translateY(30px);
}

/* Clase para elementos que ya fueron animados una vez (si se usa la Opción B) */
.animate-on-scroll.animated-once.visible {
    opacity: 1;
    transform: translateY(0);
}

/* === 6. FOOTER === */
.site-footer {
    background: linear-gradient(135deg, var(--color-dark-blue) 0%, #004d6b 100%);
    color: var(--color-white);
    padding: 40px 0 20px;
    border-top: 3px solid var(--color-teal);
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 30px;
    text-align: center;
}

.footer-main h3 {
    color: var(--color-white);
    font-size: 1.4rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.footer-tagline {
    color: var(--color-text);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.footer-contact {
    display: flex;
    flex-direction: row;
    gap: 10px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(101, 204, 204, 0.1);
    border-radius: 20px;
    transition: all 0.3s ease;
    font-size: 0.85rem;
    white-space: nowrap;
}

.contact-item:hover {
    background: rgba(101, 204, 204, 0.2);
    transform: translateY(-2px);
}

.contact-item svg {
    color: var(--color-teal);
    flex-shrink: 0;
}

.contact-item a {
    color: var(--color-white);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.contact-item a:hover {
    color: var(--color-teal);
}

.footer-bottom {
    border-top: 1px solid rgba(101, 204, 204, 0.2);
    padding-top: 20px;
    text-align: center;
    font-size: 0.9rem;
}

.footer-bottom p {
    margin: 5px 0;
    color: var(--color-text);
}

.footer-credits {
    font-size: 0.8rem;
    opacity: 0.7;
}

.footer-credits a {
    color: var(--color-teal);
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
}

.footer-credits a:hover {
    color: var(--color-white);
    text-decoration: underline;
}

/* === 7. MEDIA QUERIES (TABLET Y ESCRITORIO) === */
@media (min-width: 768px) {
    .section-title { font-size: 2.8rem; margin-bottom: 60px; }
    
    /* Header y Navegación Desktop */
    .nav-toggle { display: none; }
    .header-phone { display: flex; } /* Mostrar teléfono en desktop */
    .main-nav { 
        display: block !important; 
        position: static;
        background: none;
        padding: 0;
        height: auto;
    }
    .main-nav ul { 
        display: flex; 
        list-style: none; 
        margin: 0; 
        padding: 0; 
        gap: 25px; 
        align-items: center;
        flex-direction: row;
    }
    .main-nav li { margin: 0; }
    
    .logo img { height: 50px; }
    
    /* Footer responsivo */
    .footer-content {
        grid-template-columns: 1fr 1fr;
        text-align: left;
        align-items: center;
    }
    
    .footer-contact {
        align-items: flex-start;
        justify-content: flex-start;
    }
    
    .footer-bottom {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    
    .footer-bottom p {
        margin: 0;
    }

    /* Hero */
    .hero-title { font-size: 3.5rem; }
    .hero-cta-group { flex-direction: row; justify-content: center; }
    
    /* About section - dos columnas en tablet */
    .about-content { grid-template-columns: 1fr 350px; gap: 80px; max-width: 1200px; }
    .about-content.no-image { grid-template-columns: 1fr; max-width: 900px; }
    
    .about-text {
        text-align: left;
    }
    
    .about-text h2 {
        text-align: left;
    }
    
    .about-image img {
        max-width: 300px;
    }
    
    /* Hero carousel - cambiar a desktop en tablets */
    .desktop-carousel {
        display: block;
    }
    
    .mobile-carousel {
        display: none;
    }
    
    /* Hero carousel - mejor visibilidad en tablets */
    .hero-overlay {
        background: linear-gradient(135deg, 
            rgba(0, 103, 146, 0.75) 0%, 
            rgba(20, 45, 62, 0.6) 50%, 
            rgba(0, 103, 146, 0.75) 100%);
    }

    /* Servicios */
    .services-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
    .services-section, .about-section, .partners-section, .contact-section { padding: 100px 0; }
    
    .service-features {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 12px;
    }
    
    /* Socios - Carrusel más ancho en desktop */
    .partners-carousel-container {
        max-width: 900px;
        margin: 0 auto;
    }
    
    /* About section - optimización para desktop */
    .about-content {
        grid-template-columns: 1fr 350px;
        gap: 80px;
        max-width: 1000px;
        margin: 0 auto;
    }
    
    .about-image img {
        max-width: 350px;
    }
}

@media (min-width: 1024px) {
    .logo img { height: 55px; }
    
    .main-nav ul { gap: 30px; }
    
    .hero-title { font-size: 4rem; }
    
    /* Hero carousel - overlay más sutil en desktop */
    .hero-overlay {
        background: linear-gradient(135deg, 
            rgba(0, 103, 146, 0.7) 0%, 
            rgba(20, 45, 62, 0.5) 50%, 
            rgba(0, 103, 146, 0.7) 100%);
    }
    
    .services-grid { grid-template-columns: repeat(2, 1fr); gap: 50px; }
    
    .service-card {
        padding: 50px 40px;
    }
    
    .service-icon {
        width: 90px;
        height: 90px;
        margin-bottom: 28px;
    }
    
    .service-features {
        gap: 15px;
    }
    
    /* About section - versión completa desktop */
    .about-content {
        grid-template-columns: 1fr 400px;
        gap: 100px;
        max-width: 1200px;
    }
    
    .about-text h3 {
        font-size: 1.8rem;
    }
    
    .about-text p {
        font-size: 1.2rem;
    }
    
    .about-image img {
        max-width: 400px;
        border-radius: 25px;
    }
    
    /* Footer en desktop */
    .footer-contact {
        flex-direction: row;
        gap: 20px;
        justify-content: flex-end;
    }
}

/* === ESTILOS PARA MODAL DE SERVICIOS === */
.service-learn-more {
    background: rgba(101, 204, 204, 0.1);
    color: var(--color-teal);
    border: 1px solid var(--color-teal);
    padding: 12px 24px;
    border-radius: 25px;
    font-weight: 500;
    cursor: pointer;
    margin-top: 20px;
    transition: all 0.3s ease;
    font-size: 0.95rem;
    width: 100%;
}

.service-learn-more:hover {
    background: var(--color-teal);
    color: var(--color-white);
    border-color: var(--color-teal);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(101, 204, 204, 0.4);
}

.service-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.service-modal.active {
    display: flex;
    opacity: 1;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    background: linear-gradient(135deg, var(--color-white), #f8fafc);
    border-radius: 20px;
    width: 100%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    border: 2px solid rgba(101, 204, 204, 0.3);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transform: translateY(50px);
    transition: transform 0.3s ease;
}

.service-modal.active .modal-content {
    transform: translateY(0);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px 30px 20px;
    border-bottom: 1px solid rgba(101, 204, 204, 0.2);
    background: var(--color-white);
}

.modal-header h2 {
    color: var(--color-dark-blue);
    font-size: 2rem;
    margin: 0;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: var(--color-dark-blue);
    font-size: 2rem;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 50%;
    transition: all 0.3s ease;
    line-height: 1;
}

.modal-close:hover {
    background: rgba(101, 204, 204, 0.1);
    color: var(--color-teal);
    transform: rotate(90deg);
}

.modal-body {
    padding: 30px;
    background: var(--color-white);
}

.modal-intro {
    text-align: center;
    margin-bottom: 40px;
    padding: 25px;
    background: linear-gradient(135deg, var(--color-light-gray), #f0f4f8);
    border-radius: 15px;
    border-left: 4px solid var(--color-teal);
}

.modal-intro p {
    font-size: 1.1rem;
    color: var(--color-dark-blue);
    line-height: 1.6;
    margin: 0;
}

.service-details {
    margin-bottom: 40px;
}

.service-detail {
    background: var(--color-white);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 25px;
    border: 1px solid rgba(101, 204, 204, 0.2);
    border-left: 4px solid var(--color-teal);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 103, 146, 0.1);
}

.service-detail:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(101, 204, 204, 0.3);
}

.service-detail-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.service-detail-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--color-teal), #4FADAD);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
}

.service-detail h3 {
    color: var(--color-dark-blue);
    font-size: 1.3rem;
    margin: 0;
    font-weight: 600;
}

.service-detail p {
    color: #4a5568;
    line-height: 1.7;
    margin: 0;
    font-size: 1rem;
}

.modal-cta {
    background: linear-gradient(135deg, var(--color-dark-blue), #0A4F68);
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    border: 1px solid rgba(101, 204, 204, 0.3);
}

.modal-cta h3 {
    color: var(--color-white);
    font-size: 1.5rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.modal-cta p {
    color: var(--color-text);
    margin-bottom: 25px;
    font-size: 1rem;
}

.modal-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
}

.modal-buttons .cta-button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-size: 0.95rem;
    min-width: 180px;
    flex: 1;
    max-width: 250px;
    box-sizing: border-box;
    text-align: center;
    white-space: nowrap;
    border-radius: 25px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}

.modal-buttons .cta-button.primary {
    background: rgba(101, 204, 204, 0.1);
    color: var(--color-teal);
    border: 1px solid var(--color-teal);
}

.modal-buttons .cta-button.primary:hover {
    background: var(--color-teal);
    color: var(--color-white);
    border-color: var(--color-teal);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(101, 204, 204, 0.4);
}

.modal-buttons .cta-button.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-white);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.modal-buttons .cta-button.secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    color: var(--color-teal);
    border-color: var(--color-teal);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(101, 204, 204, 0.2);
}

/* Responsive para tablet */
@media (max-width: 1024px) and (min-width: 769px) {
    .modal-content {
        max-width: 90%;
        margin: 0 auto;
    }
    
    .modal-buttons .cta-button {
        min-width: 200px;
        flex: none;
    }
}

/* Responsive para móvil */
@media (max-width: 768px) {
    .service-modal.active {
        padding: 0;
        align-items: stretch;
    }
    
    .modal-content {
        width: 100%;
        height: 100%;
        max-height: 100vh;
        border-radius: 0;
        border: none;
    }
    
    .modal-header {
        padding: 20px 20px 15px;
        position: sticky;
        top: 0;
        background: var(--color-white);
        z-index: 10;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    }
    
    .modal-header h2 {
        font-size: 1.5rem;
    }
    
    .modal-body {
        padding: 20px;
        padding-bottom: 30px;
        overflow-x: hidden;
    }
    
    .modal-intro {
        margin-bottom: 30px;
        padding: 20px;
        margin-left: -20px;
        margin-right: -20px;
    }
    
    .modal-intro p {
        font-size: 1rem;
    }
    
    .service-detail {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .service-detail-header {
        gap: 12px;
        margin-bottom: 12px;
    }
    
    .service-detail-icon {
        width: 35px;
        height: 35px;
    }
    
    .service-detail h3 {
        font-size: 1.2rem;
    }
    
    .service-detail p {
        font-size: 0.95rem;
    }
    
    .modal-cta {
        padding: 25px 20px;
        margin: 0 -20px;
        border-radius: 0;
    }
    
    .modal-cta h3 {
        font-size: 1.3rem;
    }
    
    .modal-buttons {
        flex-direction: column;
        gap: 12px;
        width: 100%;
        max-width: 100%;
    }
    
    .modal-buttons .cta-button {
        width: 100%;
        max-width: none;
        min-width: auto;
        padding: 16px 20px;
        font-size: 1rem;
        flex: none;
        margin: 0;
        box-sizing: border-box;
    }
    
    .modal-buttons .cta-button.primary {
        background: rgba(101, 204, 204, 0.15);
        color: var(--color-teal);
        border: 1px solid var(--color-teal);
    }
    
    .modal-buttons .cta-button.secondary {
        background: rgba(255, 255, 255, 0.15);
        color: var(--color-white);
        border: 1px solid rgba(255, 255, 255, 0.5);
    }
}

/* Evitar scroll en el body cuando modal está abierto */
body.modal-open {
    overflow: hidden;
    height: 100vh;
}