/* --- Variables de Color y Tipografía --- */
:root {
    --primary: #1A538A;      /* Azul Profesional */
    --secondary: #42B4E6;    /* Azul Cyan */
    --dark: #1E293B;         /* Fondo Oscuro */
    --light: #F1F5F9;        /* Fondo Claro */
    --white: #ffffff;
    --gray: #64748B;
    --border: #E2E8F0;
    --font-main: 'Inter', sans-serif;
}

/* --- Estilos Globales --- */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

body {
    font-family: var(--font-main);
    color: var(--dark);
    line-height: 1.6;
    scroll-behavior: smooth;
    background-color: var(--white);
    overflow-x: hidden; /* Evita scroll horizontal innecesario */
}

.container { 
    width: 92%; 
    max-width: 1200px; 
    margin: auto; 
}

a { 
    text-decoration: none; 
    transition: 0.3s; 
    color: inherit; 
}

ul { list-style: none; }

h1, h2, h3, h4 { 
    font-weight: 700; 
    color: var(--primary); 
}

img { 
    max-width: 100%; 
    height: auto; 
    display: block; 
}

.text-center { text-align: center; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 3rem; }
.mx-auto { margin-left: auto; margin-right: auto; }
.section-padding { padding: 100px 0; }
.bg-light { background-color: var(--light); }
.bg-dark { background-color: var(--dark); color: var(--white); }
.text-white { color: var(--white); }

/* --- Componentes UI --- */
.card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 15px -3px rgba(0,0,0,0.05);
    border: 1px solid var(--border);
    transition: 0.3s;
}

.card:hover { 
    box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1); 
    transform: translateY(-5px);
}

.line { 
    width: 60px; 
    height: 4px; 
    background: var(--secondary); 
    margin: 15px 0 25px; 
    border-radius: 2px; 
}

.section-header h2 { font-size: 2.5rem; }
.section-header p { 
    color: var(--gray); 
    font-size: 1.1rem; 
    max-width: 700px; 
    margin: 10px auto 30px; 
}

/* --- Botones --- */
.btn-cta, .btn-primary, .btn-secondary, .btn-submit {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 6px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    border: none;
    transition: 0.3s;
}

.btn-primary { background: var(--secondary); color: var(--white); }
.btn-primary:hover { background: var(--primary); }

.btn-secondary { 
    background: transparent; 
    color: var(--white); 
    border: 2px solid var(--white); 
}
.btn-secondary:hover { 
    background: var(--white); 
    color: var(--primary); 
}

.btn-cta { 
    background: var(--primary); 
    color: var(--white); 
    padding: 10px 20px; 
    font-size: 0.95rem; 
}
.btn-cta:hover { background: var(--secondary); }

.btn-submit { 
    background: var(--secondary); 
    color: var(--white); 
    font-size: 1.1rem; 
    width: 100%; 
    margin-top: 15px; 
}
.btn-submit:hover { background: var(--primary); }

.btn-light-outline {
    display: inline-block;
    padding: 10px 25px;
    border-radius: 6px;
    border: 2px solid var(--white);
    color: var(--white);
    font-weight: 600;
    margin-top: 15px;
}
.btn-light-outline:hover { background: var(--white); color: var(--secondary); }

.badge {
    display: inline-block;
    padding: 5px 10px;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 4px;
    text-transform: uppercase;
    margin-bottom: 10px;
}
.badge-light { background-color: var(--white); color: var(--secondary); }

/* Etiqueta Silver Partner Premium */
.badge-silver {
    background: linear-gradient(135deg, #E2E8F0 0%, #94A3B8 100%);
    color: #0F172A;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* --- Navbar --- */
.navbar {
    background: var(--white);
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.navbar .container { display: flex; justify-content: space-between; align-items: center; }
.logo { display: flex; align-items: center; gap: 12px; font-weight: 700; color: var(--primary); font-size: 1.4rem; }
.logo img { height: 50px; width: auto; }

.nav-menu ul { display: flex; gap: 30px; align-items: center; }
.nav-menu a { font-weight: 500; color: var(--dark); }
.nav-menu a:not(.btn-cta):hover { color: var(--secondary); }
.menu-toggle { display: none; font-size: 1.5rem; cursor: pointer; color: var(--primary); }

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    background: linear-gradient(rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95)), url('https://via.placeholder.com/1600x900/1E293B/111111?text=IT+Background') no-repeat center center/cover;
    color: var(--white);
    display: flex;
    align-items: center;
    padding-top: 100px;
}

.hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center; }
.hero h1 { font-size: 3.2rem; color: var(--white); line-height: 1.2; margin-bottom: 20px; }
.hero p { font-size: 1.2rem; color: rgba(255,255,255,0.8); margin-bottom: 40px; }
.hero-btns { display: flex; gap: 20px; }

.hero-image img {
    width: 100%;
    max-width: 550px;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}

/* --- Liderazgo --- */
.mision-vision-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }
.info-card i { font-size: 3rem; margin-bottom: 20px; }
.info-card h3 { font-size: 1.8rem; margin-bottom: 15px; }
.info-card p { color: var(--gray); font-size: 1rem; }

.liderazgo-seccion h3 { font-size: 2rem; }
.liderazgo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }

.lider-item {
    display: flex;
    gap: 25px;
    align-items: center;
    padding: 2rem;
    border-left: 5px solid var(--secondary);
}

.lider-img-container {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    border-radius: 50%; 
    overflow: hidden;
    border: 3px solid var(--border);
}
.lider-img-container img { width: 100%; height: 100%; object-fit: cover; }

.lider-info h4 { font-size: 1.5rem; margin-bottom: 8px; }
.lider-info p.puesto-desc { color: var(--gray); font-size: 0.95rem; }

/* --- Servicios --- */
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 25px; }
.service-item { transition: 0.3s; padding: 2.5rem; text-align: center; }
.service-item:hover { background-color: var(--primary); color: var(--white); }
.service-icon { font-size: 3rem; color: var(--secondary); margin-bottom: 20px; display: block; }
.service-item:hover .service-icon, .service-item:hover h4 { color: var(--white); }

/* --- Productos Destacados (AuditSide & Nakivo) --- */
.product-highlight {
    background-color: #2D3E50; 
    color: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 3rem;
    border-radius: 15px;
    gap: 40px;
    border: none;
}

/* Invierte el orden visualmente para NAKIVO */
.product-highlight.reverse-layout {
    flex-direction: row-reverse;
}

.product-content { flex: 1; }
.product-header { display: flex; align-items: center; gap: 15px; margin-bottom: 15px; }
.product-highlight h3 { color: var(--white); font-size: 2.2rem; margin: 0; }
.product-highlight p { 
    font-size: 1.05rem; 
    color: rgba(255,255,255,0.85); 
    text-align: justify; /* Texto perfectamente justificado */
}

.product-icon { 
    color: var(--secondary); 
    opacity: 0.9; 
    flex-shrink: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Ajuste específico para el logo de Nakivo grande */
.nakivo-featured-logo {
    width: 220px; 
    height: auto;
    filter: brightness(0) invert(1); /* Lo transforma a blanco puro */
}

/* --- FIX DEL CARRUSEL --- */
.logos-carrusel-container {
    overflow: hidden;
    padding: 50px 0;
    position: relative;
    background: rgba(255,255,255,0.03);
}

.logos-carrusel-container:before, .logos-carrusel-container:after {
    content: '';
    position: absolute;
    top: 0;
    width: 150px;
    height: 100%;
    z-index: 2;
}
.logos-carrusel-container:before { left: 0; background: linear-gradient(to right, var(--dark) 0%, rgba(30, 41, 59, 0) 100%); }
.logos-carrusel-container:after { right: 0; background: linear-gradient(to left, var(--dark) 0%, rgba(30, 41, 59, 0) 100%); }

.logos-slide {
    display: flex;
    width: max-content;
    animation: scroll 60s linear infinite; 
}

.logos-slide img {
    height: 50px;
    width: auto;
    margin: 0 50px;
    filter: brightness(0) invert(1); 
    opacity: 0.6;
    flex-shrink: 0; 
    transition: 0.3s;
}
.logos-slide img:hover { opacity: 1; transform: scale(1.05); }

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* --- Formulario --- */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 60px;
    background: var(--white);
    padding: 3rem;
    border-radius: 12px;
}

.contact-info h2 { font-size: 2.5rem; margin-bottom: 15px; }
.contact-intro { color: var(--gray); margin-bottom: 30px; font-size: 1.1rem; }
.info-details { display: flex; flex-direction: column; gap: 20px; }
.info-details p { display: flex; align-items: flex-start; gap: 15px; color: var(--dark); }
.info-details i { font-size: 1.2rem; margin-top: 5px; flex-shrink: 0; }
.info-details span { font-size: 0.95rem; }

.contact-form { display: flex; flex-direction: column; gap: 15px; }
.form-group.row { display: flex; gap: 15px; }

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border);
    border-radius: 6px;
    margin-bottom: 15px;
    font-family: inherit;
}

.form-control:focus { outline: none; border-color: var(--secondary); }
textarea.form-control { resize: vertical; }

/* --- Footer --- */
footer .developed-by small { opacity: 0.7; }

/* --- Botón WhatsApp Flotante --- */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 40px;
    right: 40px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 35px;
    box-shadow: 2px 4px 15px rgba(0,0,0,0.2);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.whatsapp-float:hover {
    background-color: #128C7E;
    transform: scale(1.1);
    color: white;
}

/* --- Responsivo --- */
@media (max-width: 1024px) {
    .hero h1 { font-size: 2.8rem; }
    .hero-grid { grid-template-columns: 1fr; text-align: center; }
    .hero-btns { justify-content: center; }
    .hero-image img { margin: auto; }
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .contact-wrapper { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .menu-toggle { display: block; }
    .nav-menu ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 70px;
        left: 0;
        width: 100%;
        background: var(--white);
        padding: 20px;
        box-shadow: 0 10px 10px rgba(0,0,0,0.1);
    }
    .nav-menu ul.active { display: flex; }
    .mision-vision-grid, .liderazgo-grid, .services-grid { grid-template-columns: 1fr; }
    .lider-item { flex-direction: column; text-align: center; }
    
    /* Ajustes móviles para productos destacados */
    .product-highlight, .product-highlight.reverse-layout { 
        flex-direction: column; 
        text-align: center; 
        gap: 25px;
    }
    .product-header {
        flex-direction: column;
        justify-content: center;
    }
    .nakivo-featured-logo {
        width: 150px;
    }

    .form-group.row { flex-direction: column; gap: 0; }
    .whatsapp-float { width: 50px; height: 50px; bottom: 20px; right: 20px; font-size: 28px; }
}