:root {
    /* Paleta Katreon (Light Theme base) */
    --azul-primario: #0057D9;
    --azul-secundario: #0086FF;
    --azul-brillante: #1E90FF; /* Para highlights del mockup */
    --bg-oscuro-principal: #FFFFFF; /* Fondo principal claro */
    --bg-oscuro-secundario: #F9FAFB; /* Fondo secundario gris claro */
    --bg-tarjeta: #FFFFFF; /* Fondo tarjetas blanco */
    --texto-blanco: #111827; /* Texto oscuro principal */
    --texto-gris: #4B5563; /* Texto gris secundario */
    --border-sutil: #D1D5DB; /* Borde más visible */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: #FAFAFA;
    background-image: radial-gradient(#D1D5DB 1px, transparent 1px);
    background-size: 30px 30px;
    color: var(--texto-blanco);
    line-height: 1.6;
}

.highlight {
    color: var(--azul-brillante);
}

/* Botones */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}
.btn-primary {
    background-color: var(--azul-brillante);
    color: var(--texto-blanco);
    border: none;
}
.btn-primary:hover {
    background-color: #187ce6;
    box-shadow: 0 5px 15px rgba(30, 144, 255, 0.3);
}
.btn-outline {
    background-color: transparent;
    color: var(--texto-blanco);
    border: 1px solid var(--border-sutil);
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}
.btn-outline:hover {
    background-color: var(--bg-oscuro-secundario);
    border-color: #D1D5DB;
}

.navbar {
    padding: 20px 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.3s ease;
}
.navbar.scrolled {
    padding: 15px 0;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}
.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.brand-logo { 
    max-height: 40px; 
    /* filter: brightness(0) invert(1); Removido para tema claro */
}
.fallback-logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--azul-primario);
}
.nav-links {
    list-style: none;
    display: flex;
    gap: 25px;
}
.nav-links a {
    text-decoration: none;
    color: var(--texto-gris);
    font-size: 0.9rem;
    font-weight: 600;
    transition: color 0.3s;
}
.nav-links a:hover {
    color: var(--azul-primario);
}
.btn-nav {
    padding: 8px 20px;
}
.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    z-index: 101;
}
.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--texto-blanco);
    border-radius: 3px;
    transition: all 0.3s ease;
}
.mobile-only {
    display: none;
}
.desktop-only {
    display: inline-block;
}

/* Hero Section */
.hero {
    position: relative;
    padding: 240px 0 160px;
    overflow: hidden;
    background: linear-gradient(135deg, #FAFAFA 0%, #EBF5FF 50%, #F0F9FF 100%);
    background-size: 400% 400%;
    animation: gradientMesh 12s ease infinite;
}
@keyframes gradientMesh {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
.hero-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1000px;
    height: 1000px;
    background: radial-gradient(circle, rgba(0, 134, 255, 0.08) 0%, rgba(255, 255, 255, 0) 70%);
    transform: translate(-50%, -50%);
    pointer-events: none;
    animation: pulse 6s infinite ease-in-out;
}
@keyframes pulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.1); }
}
.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 60px;
    text-align: left;
    position: relative;
    z-index: 2;
}
.hero-title {
    font-size: 4.2rem;
    font-weight: 800;
    line-height: 1.05;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: -1px;
}
.hero-title .highlight {
    background: linear-gradient(90deg, var(--azul-primario), var(--azul-brillante));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}
.hero-subtitle {
    font-size: 1.25rem;
    color: var(--texto-gris);
    margin-bottom: 45px;
    max-width: 800px;
    line-height: 1.8;
}
.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: flex-start;
}

.hero-image-container {
    position: relative;
    width: 100%;
    animation: float 6s ease-in-out infinite;
}

.hero-image-container img,
.hero-image-container video {
    width: 100%;
    height: auto;
    border-radius: 24px;
    box-shadow: 0 30px 60px -12px rgba(0, 87, 217, 0.25);
    position: relative;
    z-index: 2;
}

.hero-image-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(0, 134, 255, 0.15) 0%, transparent 60%);
    transform: translate(-50%, -50%);
    z-index: 1;
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

/* Placeholder for 3D 'K' */
.k-placeholder {
    width: 100%;
    height: 400px;
    background: radial-gradient(circle at center, rgba(30, 144, 255, 0.05) 0%, rgba(255, 255, 255, 0.5) 100%);
    border: 1px dashed rgba(30, 144, 255, 0.2);
    border-radius: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: inset 0 0 50px rgba(30, 144, 255, 0.05);
}
.k-placeholder span {
    font-size: 15rem;
    font-weight: 800;
    color: rgba(30, 144, 255, 0.8);
    text-shadow: 0 10px 30px rgba(30, 144, 255, 0.2);
    font-style: italic;
}

/* Servicios Section */
.services-section {
    padding: 100px 0;
    border-top: 1px solid var(--border-sutil);
}
.services-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}
.section-header {
    text-align: center;
    margin-bottom: 60px;
}
.eyebrow {
    color: var(--azul-brillante);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    display: block;
    margin-bottom: 15px;
}
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    max-width: 1100px;
    margin: 0 auto;
}
.service-card {
    background: transparent;
    padding: 20px;
    border: none;
    box-shadow: none;
    transition: all 0.3s ease;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.service-card:hover {
    transform: translateY(-5px);
}
.service-card .icon-img {
    width: 100%;
    max-width: 220px;
    height: auto;
    margin-bottom: 25px;
    object-fit: contain;
}
.service-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 0;
}
.service-card p {
    display: none; /* Ocultamos el texto para que quede como el ejemplo */
}
.testimonial-card p {
    display: block; /* Forzamos mostrar texto en testimonios */
}
.learn-more {
    display: none; /* Ocultamos el botón para que quede como el ejemplo */
}
.learn-more:hover {
    text-decoration: underline;
}

/* Portfolio Grid */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}
.portfolio-card {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    aspect-ratio: 3/4;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}
.portfolio-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}
.placeholder-bg {
    background: #E5E7EB;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: #9CA3AF;
}
.portfolio-card:hover .portfolio-bg {
    transform: scale(1.1);
}
.portfolio-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    opacity: 0;
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 25px;
    text-align: center;
}
.portfolio-card:hover .portfolio-overlay {
    opacity: 1;
}
.portfolio-content {
    transform: translateY(20px) scale(0.95);
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    width: 100%;
}
.portfolio-card:hover .portfolio-content {
    transform: translateY(0) scale(1);
}
.portfolio-category {
    background: rgba(0, 134, 255, 0.2);
    border: 1px solid rgba(0, 134, 255, 0.5);
    color: #60A5FA;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 6px 14px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 16px;
}
.portfolio-title {
    color: #FFFFFF;
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 10px;
    line-height: 1.25;
    letter-spacing: -0.01em;
    text-wrap: balance;
}
.portfolio-desc {
    color: #CBD5E1;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}
.portfolio-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.btn-demo {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    color: var(--texto-blanco);
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: background 0.3s;
    width: fit-content;
}
.btn-demo:hover {
    background: #F3F4F6;
}
.portfolio-creds {
    font-size: 0.8rem;
    color: #9CA3AF;
    display: flex;
    gap: 15px;
}


/* Bottom Dashboard Section */
.bottom-dashboard {
    padding: 80px 0 40px;
}
.dashboard-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px 60px;
    display: grid;
    grid-template-columns: 1fr 1fr 350px;
    gap: 50px;
    border-bottom: 1px solid var(--border-sutil);
}

.dashboard-about h3 {
    font-size: 1.8rem;
    line-height: 1.3;
    margin-top: 10px;
    margin-bottom: 20px;
}
.dashboard-about p {
    color: var(--texto-gris);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.dashboard-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-content: center;
}
.stat-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
}
.stat-icon {
    font-size: 1.5rem;
    color: var(--azul-brillante);
}
.stat-info h4 {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 5px;
}
.stat-info span {
    font-size: 0.85rem;
    color: var(--texto-gris);
}

.dashboard-cta {
    align-self: center;
}
.cta-card {
    background: var(--bg-tarjeta);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid var(--border-sutil);
}
.cta-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}
.cta-card p {
    color: var(--texto-gris);
    font-size: 0.9rem;
    margin-bottom: 20px;
}
.cta-card .btn {
    width: 100%;
    text-align: center;
}

/* Client Logos */
.clients-section {
    max-width: 1400px;
    margin: 0 auto;
    padding: 60px 40px 0;
    text-align: center;
}
.clients-title {
    color: var(--texto-gris);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 30px;
}
.clients-strip {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}
.client-logo {
    color: var(--texto-gris);
    font-weight: 700;
    font-size: 1.1rem;
    opacity: 1;
    transition: transform 0.3s;
}
.client-logo:hover {
    transform: scale(1.1);
}

/* Animated Carousel */
.carousel-animated {
    display: inline-flex !important;
    white-space: nowrap;
    animation: marquee 30s linear infinite;
    width: max-content;
}
.carousel-animated:hover {
    animation-play-state: paused;
}
@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-50% - 40px)); } /* 40px is half of the 80px gap to ensure seamless loop */
}

/* SaaS Carousel Classes */
.saas-carousel-wrapper {
    position: relative;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 60px;
}
.saas-slides-container {
    display: flex;
    transition: transform 0.6s cubic-bezier(0.77,0,0.175,1);
}
.saas-slide {
    flex: 0 0 100%;
    display: flex;
    min-height: 400px;
}
.saas-slide-visual {
    flex: 0 0 45%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 40px;
    position: relative;
}
.saas-slide-content {
    flex: 1;
    background: white;
    padding: 55px 55px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.saas-bg-assetflow { background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 50%, #0086FF 100%); }
.saas-bg-retailflow { background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 50%, #4338CA 100%); }
.saas-bg-humioza { background: linear-gradient(135deg, #1e293b 0%, #334155 60%, #475569 100%); }
.saas-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: white;
    border: none;
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}
.saas-nav-prev { left: 0; }
.saas-nav-next { right: 0; }
.saas-dots-container {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

/* Contact Form Classes */
.contact-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

/* Responsive */
@media (max-width: 1200px) {
    .dashboard-container {
        grid-template-columns: 1fr 1fr;
    }
    .dashboard-cta {
        grid-column: 1 / -1;
    }
}
@media (max-width: 992px) {
    .hero-container { grid-template-columns: 1fr; text-align: center; gap: 40px; }
    .hero-buttons { justify-content: center; }
    .hero-glow { right: 50%; transform: translate(50%, -50%); }
    .dashboard-container { grid-template-columns: 1fr; }
    
    .desktop-only { display: none !important; }
    .mobile-only { display: inline-block; }
    .mobile-menu-toggle { display: flex; }
    .nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        padding: 30px 40px;
        transform: translateY(-20px);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 100;
        text-align: center;
        border-radius: 0 0 20px 20px;
        gap: 15px;
    }
    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    .mobile-menu-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 8px); }
    .mobile-menu-toggle.active span:nth-child(2) { opacity: 0; }
    .mobile-menu-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -8px); }

    .services-grid { grid-template-columns: repeat(2, 1fr); gap: 30px; }
    .portfolio-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    
    .saas-carousel-wrapper { padding: 0 40px; }
}
@media (max-width: 768px) {
    .hero { padding: 180px 0 100px; }
    .hero-title { font-size: 2.5rem; }
    .hero-subtitle { font-size: 1.1rem; }
    
    .clients-strip { justify-content: center; }
    .services-grid { grid-template-columns: 1fr; }
    .portfolio-grid { grid-template-columns: 1fr; }
    
    .saas-carousel-wrapper { padding: 0 20px; }
    .saas-slide { flex-direction: column; min-height: auto; }
    .saas-slide-visual, .saas-slide-content { flex: none; width: 100%; }
    .saas-slide-visual { padding: 40px 20px; min-height: 250px; }
    .saas-slide-content { padding: 40px 30px; text-align: center; align-items: center; }
    .order-first-mobile { order: -1; }
    .saas-nav-btn { width: 40px; height: 40px; }
    
    .contact-form-grid { grid-template-columns: 1fr; gap: 15px; }
    .contact-form-container { padding: 30px !important; }
}
