/* ==========================================================================
   HOJA DE ESTILOS - DATALÍTICA COLOMBIA SAS
   ========================================================================== */

/* 1. VARIABLES Y CONFIGURACIÓN GLOBAL */
:root {
    /* Paleta de Colores */
    --color-primary-dark: #001F3F;
    /* Azul Marino Profundo */
    --color-secondary-accent: #1DA1F2;
    /* Azul Eléctrico Brillante */
    --color-secondary-darker: #0c8ce0;
    /* Acento oscuro para hover */
    --color-neutral-light: #F2F2F2;
    /* Gris Claro */
    --color-text-dark: #333333;
    /* Texto Principal */
    --color-text-light: #FFFFFF;
    /* Texto Blanco */
    --color-border: #e0e0e0;
    /* Color de Bordes */

    /* Tipografía */
    --font-primary: 'Roboto', sans-serif;

    /* Espaciado y Sombras */
    --spacing-lg: 60px;
    --spacing-md: 30px;
    --spacing-sm: 15px;
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.12);
    --shadow-cta: 0 4px 15px rgba(29, 161, 242, 0.3);


/* 2. RESET Y ESTILOS BASE */
/* 2. RESET Y ESTILOS BASE */
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ======================================================= */
/* Liquid 3D - efecto sutil aplicado a tarjetas de servicio  */
/* ======================================================= */
/* Aplicado a `.service-card` y `.benefit-item`. Usa pseudo-elementos,
   gradientes y transform/opacity para mantener buen rendimiento. */
.service-card,
.benefit-item,
.team-role-card,
.step,
.contact-form-wrapper,
.case-study-visual,
.footer-logo {
    position: relative;
    overflow: hidden;
    border-radius: 15px; /* conservar radio existente */
    background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(248,249,250,0.96));
    box-shadow: 0 8px 20px rgba(2,6,23,0.06), inset 0 -6px 18px rgba(0,0,0,0.03);
    transition: transform 300ms cubic-bezier(.2,.9,.3,1), box-shadow 300ms, filter 300ms;
}

.service-card::before,
.benefit-item::before,
.team-role-card::before,
.step::before,
.contact-form-wrapper::before,
.case-study-visual::before,
.footer-logo::before {
    content: "";
    position: absolute;
    left: -20%;
    top: -40%;
    width: 140%;
    height: 120%;
    background: radial-gradient(60% 40% at 20% 20%, rgba(255,255,255,0.55), rgba(255,255,255,0) 35%);
    transform: rotate(-12deg);
    pointer-events: none;
    opacity: 0.7;
    mix-blend-mode: screen;
    transition: opacity 300ms, transform 400ms;
}

.service-card::after,
.benefit-item::after,
.team-role-card::after,
.step::after,
.contact-form-wrapper::after,
.case-study-visual::after,
.footer-logo::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255,255,255,0) 0%, rgba(0,0,0,0.02) 100%);
    pointer-events: none;
    transform: translateZ(0);
}

.service-card:hover,
.benefit-item:hover,
.team-role-card:hover,
.step:hover,
.contact-form-wrapper:hover,
.case-study-visual:hover,
.footer-logo:hover {
    transform: translateY(-8px) translateZ(0) scale(1.006);
    box-shadow: 0 22px 44px rgba(2,6,23,0.12), inset 0 -8px 26px rgba(0,0,0,0.05);
}

/* animación sutil opcional (activar con data-animate="true") */
@keyframes liquid-wave {
    0% { transform: translateY(0) translateX(0); }
    50% { transform: translateY(-4px) translateX(2px); }
    100% { transform: translateY(0) translateX(0); }
}
.service-card[data-animate="true"],
.benefit-item[data-animate="true"],
.team-role-card[data-animate="true"],
.step[data-animate="true"],
.contact-form-wrapper[data-animate="true"],
.case-study-visual[data-animate="true"],
.footer-logo[data-animate="true"] {
    will-change: transform;
    animation: liquid-wave 6s ease-in-out infinite;
}

/* Mobile: reducir intensidad y desactivar animación por rendimiento */
@media (max-width: 768px) {
    .service-card::before,
    .benefit-item::before { opacity: 0.45; transform: rotate(-8deg); }
    .service-card:hover,
    .benefit-item:hover { transform: none; box-shadow: 0 10px 22px rgba(2,6,23,0.08); }
    .service-card[data-animate="true"],
    .benefit-item[data-animate="true"] { animation: none; }
}


html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--color-text-dark);
    background-color: var(--color-text-light);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

.section-spacing {
    padding: var(--spacing-lg) 0;
}

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

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

.mt-4 {
    margin-top: 2rem;
}

.mb-5 {
    margin-bottom: 3rem;
}

/* 3. TIPOGRAFÍA */
h1,
h2,
h3,
h4 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
    color: var(--color-primary-dark);
}

h1 {
    font-size: 3rem;
    max-width: 800px;
}

h2 {
    font-size: 2.2rem;
    text-align: center;
    margin-bottom: var(--spacing-md);
    color: var(--color-primary-dark);
}

.subtitle {
    font-size: 1.25rem;
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-md);
    max-width: 700px;
    opacity: 0.9;
}

/* Títulos en fondos oscuros */
/* Títulos en fondos oscuros */
.bg-dark h1,
.bg-dark h2,
.bg-dark h3,
.bg-dark h4,
.bg-dark p,
.bg-dark .subtitle {
    color: var(--color-text-light);
}


/* 4. HEADER Y NAVEGACIÓN (Sticky) */
.sticky-header {
    background-color: var(--color-text-light);
    border-bottom: 1px solid var(--color-border);
    padding: 8px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}

nav.container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    height: auto;
    /* Ajuste: permitir que el logo escale naturalmente */
    max-height: 140px;
    width: auto;
    object-fit: contain;
    /* Mantener proporción */
    transition: all 0.3s ease;
    display: block;
}


/* Centrado del logo en móvil y ajuste de header */
@media (max-width: 768px) {
    nav.container {
        justify-content: center;
        /* Centrar logo en móvil */
    }

    .menu-toggle {
        position: absolute;
        right: 20px;
        top: 50%;
        transform: translateY(-50%);
    }
}

@media (max-width: 768px) {
    .logo {
        height: 120px;
        max-height: 120px;
        /* Ajuste móvil: usar la altura fija que funcionó en Chrome devtools */
    }
}

/* Footer logo: un tamaño cómodo que no desborde la sección del pie */
.logo-footer {
    max-height: 100px;
    width: auto;
    object-fit: contain;
}

@media (max-width: 768px) {
    .logo-footer {
        max-height: 70px;
    }
}

.nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 25px;
}

.nav-links a {
    text-decoration: none;
    color: var(--color-primary-dark);
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--color-secondary-accent);
}

.menu-toggle {
    display: none;
    font-size: 1.8rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-primary-dark);
    padding: 5px;
}

/* 5. BOTONES Y CTAs */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    text-align: center;
    font-size: 0.9rem;
    border: 2px solid transparent;
    cursor: pointer;
}

/* CTA Primario (Azul Brillante) */
.btn-primary-cta,
.btn-huge-cta,
.btn-submit {
    background-color: var(--color-secondary-accent);
    color: var(--color-text-light);
    box-shadow: var(--shadow-cta);
}

.btn-primary-cta:hover,
.btn-huge-cta:hover,
.btn-submit:hover {
    background-color: var(--color-secondary-darker);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(29, 161, 242, 0.5);
}

/* CTA Secundario (Borde azul) */
.btn-secondary-cta {
    background-color: transparent;
    color: var(--color-secondary-accent);
    border-color: var(--color-secondary-accent);
}

.btn-secondary-cta:hover {
    background-color: var(--color-secondary-accent);
    color: var(--color-text-light);
}

.btn-header-cta {
    padding: 10px 22px;
    font-size: 0.85rem;
}

.btn-huge-cta {
    font-size: 1.2rem;
    padding: 18px 45px;
}

/* 6. SECCIONES PRINCIPALES */
.bg-light {
    background-color: var(--color-neutral-light);
}

.bg-dark {
    background-color: var(--color-primary-dark);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--color-neutral-light) 0%, #ffffff 100%);
    min-height: 700px;
    display: flex;
    align-items: center;
    padding: 100px 0;
}

.hero-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-md);
}

.hero-content {
    flex: 1;
    z-index: 2;
}

.hero-visual {
    flex: 1;
    position: relative;
    z-index: 1;
    perspective: 1000px;
}

.hero-visual img {
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
    transform: rotateY(-10deg) rotateX(5deg);
    transition: transform 0.5s ease, box-shadow 0.5s ease;
}

.hero-visual img:hover {
    transform: rotateY(-2deg) rotateX(2deg) scale(1.02);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
}

/* Grids de Servicios y Beneficios */
.service-grid,
.benefits-grid {
    display: grid;
    /* permitir columnas más estrechas en móviles para evitar overflow */
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

/* Carousel Team */
.carousel-container {
    overflow: hidden;
    width: 100%;
    position: relative;
    padding: 20px 0;
}

.carousel-track {
    display: flex;
    gap: 30px;
    transition: transform 0.5s ease-in-out;
    width: max-content;
    /* Permitir que el track sea tan ancho como necesite */
}

.team-role-card {
    flex: 0 0 300px;
    /* Ancho fijo para las tarjetas en el carrusel */
    background: rgba(255, 255, 255, 0.05);
    /* Fondo sutil para legibilidad */
    padding: 30px;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.service-card,
.benefit-item {
    background-color: var(--color-text-light);
    padding: 40px 30px;
    border-radius: 15px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s, box-shadow 0.3s;
    border-top: 4px solid transparent;
}

.service-card:hover,
.benefit-item:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-md);
    border-top-color: var(--color-secondary-accent);
}

.card-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 25px;
    color: var(--color-secondary-accent);
}

.card-icon svg {
    width: 48px;
    height: 48px;
}

.service-card h3,
.benefit-item h4 {
    font-size: 1.5rem;
    margin-bottom: 15px;
}

/* Caso de Uso */
.case-study-container {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
}

.case-study-content {
    flex: 1;
}

.case-study-visual {
    flex: 1;
}

.case-study-visual img {
    border-radius: 15px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-border);
}

/* Proceso */
.process-steps {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    margin-top: var(--spacing-md);
}

.step {
    position: relative;
    flex: 1;
    padding: 40px 30px;
    background: #fff;
    border-radius: 15px;
    box-shadow: var(--shadow-sm);
    text-align: center;
    transition: transform 0.3s;
}

.step:hover {
    transform: translateY(-5px);
}

.step-number {
    display: inline-block;
    width: 50px;
    height: 50px;
    line-height: 50px;
    background: var(--color-secondary-accent);
    color: #fff;
    border-radius: 50%;
    font-weight: 800;
    font-size: 1.2rem;
    margin-bottom: 20px;
    box-shadow: var(--shadow-cta);
}

/* Equipo */
.team-visual img {
    border-radius: 20px;
    width: 100%;
    height: 450px;
    object-fit: cover;
    opacity: 0.9;
    mix-blend-mode: luminosity;
    transition: all 0.5s ease;
}

.team-visual img:hover {
    opacity: 1;
    mix-blend-mode: normal;
}

/* 7. FORMULARIO DE CONTACTO */
.contact-form-wrapper {
    max-width: 700px;
    margin: 0 auto;
    background: #fff;
    padding: 50px;
    border-radius: 20px;
    box-shadow: var(--shadow-md);
}

.form-group {
    margin-bottom: 25px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid var(--color-border);
    border-radius: 10px;
    font-family: var(--font-primary);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
    background-color: #f9f9f9;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--color-secondary-accent);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(29, 161, 242, 0.1);
}

.btn-submit {
    width: 100%;
    font-size: 1.1rem;
    padding: 15px;
}

/* 8. FOOTER */
.footer {
    background-color: var(--color-primary-dark);
    padding-top: 80px;
    color: #aab2bd;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 50px;
    padding-bottom: 50px;
}

.logo-footer {
    max-height: 100px;
    height: auto;
    /* Colocar el logo del footer también en un contenedor blanco */
    background: #ffffff;
    padding: 6px 10px;
    border-radius: 8px;
    box-shadow: 0 6px 16px rgba(2,6,23,0.06);
    filter: brightness(0) invert(1);
    margin-bottom: 20px;
}

/* Footer-specific overrides: keep footer logo visible despite liquid styles */
.footer .footer-logo {
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
}
.footer .footer-logo::before,
.footer .footer-logo::after {
    display: none !important;
}
.footer .logo-footer {
    filter: none !important;
    max-height: 100px;
    height: auto;
    margin-bottom: 20px;
}

.footer h4 {
    color: var(--color-text-light);
    font-size: 1.1rem;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer ul {
    list-style: none;
}

.footer ul li {
    margin-bottom: 15px;
}

.footer a {
    color: #aab2bd;
    text-decoration: none;
    transition: color 0.3s;
}

.footer a:hover {
    color: var(--color-secondary-accent);
}

.copyright {
    text-align: center;
    padding: 25px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
}

/* 9. RESPONSIVIDAD (MEDIA QUERIES) */
@media (max-width: 992px) {
    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    .section-spacing {
        padding: var(--spacing-md) 0;
    }

    .hero {
        padding: 60px 0;
        min-height: auto;
    }

    .hero-container {
        flex-direction: column;
        text-align: center;
    }

    .hero-content,
    .hero-visual {
        width: 100%;
    }

    .hero-visual {
        order: -1;
        margin-bottom: 40px;
    }

    .hero-visual img {
        transform: none;
    }

    .subtitle {
        margin-left: auto;
        margin-right: auto;
    }

    .case-study-container {
        flex-direction: column;
    }

    .case-study-visual {
        width: 100%;
        margin-top: 30px;
    }

    .process-steps {
        flex-direction: column;
    }

    .step {
        margin-bottom: 20px;
    }

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

    /* Ajustes responsive adicionales para móviles */
    .service-card,
    .benefit-item {
        padding: 24px 18px;
    }

    /* Carousel: tarjetas más anchas en móvil para evitar que se salgan */
    .team-role-card {
        flex: 0 0 80%;
        padding: 20px;
    }

    .carousel-track {
        gap: 18px;
    }

    /* Ajuste de altura de imágenes de equipo en móviles para evitar overflow */
    .team-visual img {
        height: auto;
        max-height: 360px;
        object-fit: cover;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    /* Header más compacto en móvil para que el logo sea más prominente */
    .sticky-header {
        padding: 6px 0;
    }

}

/* Mobile: centrar el contenedor blanco del logo y ajustar tamaños para pantallas estrechas */
@media (max-width: 768px) {
    .logo-footer {
        display: inline-block;
        margin: 0 auto;
        background: #ffffff;
        padding: 10px 16px;
        border-radius: 12px;
        box-shadow: 0 10px 24px rgba(2,6,23,0.08);
        max-height: 120px;
        vertical-align: middle;
    }

    /* Asegurar que el contenedor del nav centre correctamente el logo en móviles */
    nav.container {
        justify-content: center;
    }
}

/* ======================================================= */
/* Hero: imagen horizontal de fondo con texto superpuesto  */
/* ======================================================= */
/* Usamos la imagen `assets/img/Mopckup.png` como fondo del hero.
   Implementamos un pseudo-elemento ::before que muestra la misma imagen
   pero con `filter: blur()` y un `clip-path` para que el lado izquierdo
   aparezca borroso. Un pseudo-elemento ::after añade un overlay degradado
   (blanco -> transparente) para asegurar legibilidad del texto sobre el
   lado borroso. En móviles el efecto se desactiva y se muestra la
   imagen inline (estructura apilada). */
.hero {
    position: relative;
    /* Preferir WebP cuando esté disponible, con fallback a PNG */
    background-image: image-set(url('../img/Mopckup.webp') type('image/webp') 1x, url('../img/Mopckup.png') type('image/png') 1x);
    background-repeat: no-repeat;
    background-position: right center;
    background-size: cover;
    min-height: 520px;
    padding: 80px 0;
    display: flex;
    align-items: center;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    /* Preferir WebP en pseudo-elemento también */
    background-image: image-set(url('../img/Mopckup.webp') type('image/webp') 1x, url('../img/Mopckup.png') type('image/png') 1x);
    background-repeat: no-repeat;
    background-position: right center;
    background-size: cover;
    filter: blur(10px) brightness(0.98);
    transform: scale(1.04);
    /* Mostrar solo el lado izquierdo borroso (ajusta 55% según prefieras)
       El polígono cubre desde la izquierda hasta aprox. 55% del ancho */
    clip-path: polygon(0 0, 55% 0, 55% 100%, 0% 100%);
    z-index: 1;
    pointer-events: none;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(255,255,255,0.90) 0%, rgba(255,255,255,0.45) 40%, rgba(255,255,255,0.0) 60%);
    z-index: 2;
    pointer-events: none;
}

.hero-container {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: var(--spacing-md);
    width: 100%;
    position: relative;
    z-index: 3; /* colocar el contenido por encima de los pseudo elementos */
}

.hero-content {
    flex: 0 0 55%;
}

.hero-visual {
    /* Mantener la imagen inline oculta en desktop (evita duplicados). */
    display: none;
}

.hero h1,
.hero .subtitle {
    color: var(--color-text-dark);
}

/* RESPONSIVE: mantener fondo + pseudo-elementos en móvil y ocultar la imagen inline
   para que el texto quede siempre encima de la imagen (más legible y profesional). */
@media (max-width: 992px) {
    /* Móvil: blur vertical (parte superior) para adaptar lectura en pantallas estrechas */
    .hero::before {
        display: block;
        /* menor blur en móviles */
        filter: blur(6px) brightness(0.95);
        /* clip-path vertical: cubrir la parte superior (45% de la altura) */
        clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
    }

    .hero::after {
        display: block;
        /* overlay vertical para garantizar contraste en la parte superior */
        background: linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.25) 45%, rgba(0,0,0,0.0) 60%);
    }

    .hero {
        /* mantener la imagen de fondo (la que esté indicada en .hero) */
        background-position: center center;
        background-size: cover;
        padding: 60px 0;
        min-height: 420px;
    }

    /* Ocultar la imagen inline para que no empuje ni tape el texto */
    .hero-visual {
        display: none;
    }

    .hero-container {
        flex-direction: column;
        text-align: center;
        width: 100%;
        position: relative;
        z-index: 3;
    }

    .hero-content {
        width: 100%;
        z-index: 3;
    }

    .hero h1,
    .hero .subtitle {
        color: #ffffff;
        text-shadow: 0 2px 8px rgba(0,0,0,0.45);
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 40px 0;
    }

    .hero h1 {
        font-size: 1.9rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--color-text-light);
        flex-direction: column;
        padding: 20px 0;
        box-shadow: var(--shadow-md);
        border-top: 1px solid var(--color-border);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        width: 100%;
        text-align: center;
    }

    .nav-links a {
        display: block;
        padding: 15px;
    }

    .btn-header-wrap {
        margin-top: 10px;
    }

    h1 {
        font-size: 2.2rem;
    }

    /* Solo ciertos CTAs deben ser full-width en móvil (ej. CTA grande o form submit). 
       Evitar que todos los botones ocupen todo el ancho y repitan espacio. */
    .hero .btn-primary-cta,
    .btn-huge-cta,
    .btn-submit {
        width: 100%;
        display: block;
    }

    .btn-huge-cta {
        font-size: 1.1rem;
        padding: 15px 20px;
    }

    .contact-form-wrapper {
        padding: 30px 20px;
    }

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