/* --- VARIABLES GLOBALES (Paleta Premium y Minimalista) --- */
:root {
    --bg-dark: #0a0c10;
    --bg-card: #12151e;
    --bg-card-hover: #181c28;
    --primary-blue: #2563eb;
    --primary-blue-hover: #1d4ed8;
    --accent-cyan: #06b6d4;
    --text-white: #ffffff;
    --text-muted: #94a3b8;
    --border-color: rgba(255, 255, 255, 0.08);
    --border-glow: rgba(37, 99, 235, 0.4);
    --font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-white);
    font-family: var(--font-family);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1150px;
    margin: 0 auto;
    padding: 70px 20px;
}

/* --- TITULOS DE SECCIÓN --- */
.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.sub-badge {
    color: var(--accent-cyan);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    display: block;
    margin-bottom: 8px;
}

.section-title h2 {
    font-size: 2.2rem;
    color: var(--text-white);
    letter-spacing: -0.5px;
    margin-bottom: 10px;
}

.section-title p {
    color: var(--text-muted);
    font-size: 1.05rem;
    max-width: 600px;
    margin: 0 auto;
}

/* --- NAVBAR --- */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 40px;
    background: rgba(10, 12, 16, 0.85);
    backdrop-filter: blur(12px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(to right, #60a5fa, var(--accent-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 2px;
}

.logo-badge {
    background: rgba(37, 99, 235, 0.2);
    color: #60a5fa;
    font-size: 0.65rem;
    padding: 3px 8px;
    border-radius: 6px;
    border: 1px solid rgba(37, 99, 235, 0.4);
    font-weight: bold;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 25px;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.3s;
    font-size: 0.95rem;
    font-weight: 500;
}

.nav-links a:hover {
    color: var(--text-white);
}

.btn-nav {
    background: var(--primary-blue);
    color: white;
    padding: 8px 18px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-nav:hover {
    background: var(--primary-blue-hover);
    box-shadow: 0 0 15px rgba(37, 99, 235, 0.5);
}

/* --- HERO SECTION & GRID RESPONSIVE --- */
.hero {
    padding: 130px 0 60px;
    position: relative;
    background: radial-gradient(circle at 70% 30%, rgba(37, 99, 235, 0.12) 0%, transparent 60%);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    align-items: center;
    gap: 40px;
}

.badge-container {
    margin-bottom: 20px;
}

.badge {
    background: rgba(6, 182, 212, 0.15);
    color: var(--accent-cyan);
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(6, 182, 212, 0.3);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.hero h1 {
    font-size: 3.2rem;
    line-height: 1.15;
    margin-bottom: 20px;
    font-weight: 800;
}

.hero h1 strong {
    color: #60a5fa;
}

.tagline {
    font-size: 1.15rem;
    color: var(--text-muted);
    margin-bottom: 35px;
    max-width: 500px;
}

.hero-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-blue), #1d4ed8);
    color: white;
    padding: 14px 28px;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-white);
    padding: 14px 28px;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    border: 1px solid var(--border-color);
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

/* --- CONTENEDOR PROTOTIPO & ANIMACIÓN DE BARRIDO --- */
.hero-image-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
}

.prototype-card {
    position: relative;
    width: 100%;
    max-width: 480px;
    border-radius: 20px;
    background: var(--bg-card);
    padding: 20px;
    border: 1px solid var(--border-glow);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7), 0 0 30px rgba(37, 99, 235, 0.2);
    overflow: hidden;
    animation: floating 6s ease-in-out infinite;
}

@keyframes floating {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.prototype-img {
    width: 100%;
    height: auto;
    max-height: 380px;
    object-fit: cover;
    border-radius: 12px;
    display: block;
}

/* --- ANIMACIÓN DE BARRIDO FUTURISTA (ESCÁNER CSS) --- */
.scanner-sweep {
    position: absolute;
    top: 0;
    left: -150%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(6, 182, 212, 0.1) 40%,
        rgba(96, 165, 250, 0.8) 50%,
        rgba(6, 182, 212, 0.1) 60%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: skewX(-25deg);
    animation: sweepAnimation 4.5s infinite ease-in-out;
    pointer-events: none;
    border-right: 2px solid #60a5fa;
    box-shadow: 0 0 15px #60a5fa;
}

@keyframes sweepAnimation {
    0% { left: -150%; }
    50% { left: 150%; }
    100% { left: 150%; }
}

.hud-overlay {
    position: absolute;
    bottom: 30px;
    left: 30px;
    right: 30px;
    display: flex;
    justify-content: space-between;
    pointer-events: none;
}

.hud-tag {
    background: rgba(10, 12, 16, 0.85);
    backdrop-filter: blur(8px);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-cyan);
    border: 1px solid rgba(6, 182, 212, 0.3);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* --- BARRA DE MÉTRICAS --- */
.metrics-bar {
    background: var(--bg-card);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: 10px 0;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 30px 20px;
}

.metric-item {
    text-align: center;
    border-right: 1px solid var(--border-color);
}

.metric-item:last-child {
    border-right: none;
}

.metric-item h3 {
    font-size: 2rem;
    color: #60a5fa;
    font-weight: 800;
    margin-bottom: 5px;
}

.metric-item p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* --- SIMULADOR IA (INTERACTIVO) --- */
.simulator-box {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

.sim-controls {
    display: flex;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid var(--border-color);
    padding: 15px;
    gap: 10px;
    flex-wrap: wrap;
}

.sim-btn {
    flex: 1;
    min-width: 180px;
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 12px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s;
}

.sim-btn.active, .sim-btn:hover {
    background: var(--primary-blue);
    color: white;
    border-color: var(--primary-blue);
}

.sim-display {
    display: grid;
    grid-template-columns: 1.3fr 0.7fr;
    min-height: 250px;
}

.sim-screen {
    padding: 25px;
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: #06080b;
    font-family: monospace;
}

.sim-header {
    display: flex;
    justify-content: space-between;
    color: var(--text-muted);
    font-size: 0.8rem;
    border-bottom: 1px dashed var(--border-color);
    padding-bottom: 10px;
}

.status-indicator {
    color: #34d399;
    animation: blink 1.5s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.sim-content {
    font-size: 1.1rem;
    color: #60a5fa;
    margin: auto 0;
    padding: 20px 0;
}

.sim-feedback {
    padding: 25px;
    background: var(--bg-card);
}

.sim-feedback h4 {
    margin-bottom: 20px;
    font-size: 0.95rem;
    color: var(--text-muted);
}

.feedback-item {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    align-items: flex-start;
}

.feedback-item i {
    color: var(--accent-cyan);
    margin-top: 3px;
}

.feedback-item strong {
    display: block;
    font-size: 0.9rem;
    color: var(--text-white);
}

.feedback-item p {
    font-size: 0.85rem;
    color: #34d399;
    margin-top: 2px;
}

/* --- VIDEO --- */
.video-wrapper {
    max-width: 850px;
    margin: 0 auto;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0,0,0,0.6);
    border: 1px solid var(--border-color);
}

.video-wrapper video {
    width: 100%;
    display: block;
}

/* --- PROBLEMA VS SOLUCION --- */
.interactive-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}

.card {
    background: var(--bg-card);
    padding: 35px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: transform 0.3s, border-color 0.3s;
}

.card:hover {
    transform: translateY(-5px);
}

.card-problem:hover { border-color: rgba(239, 68, 68, 0.4); }
.card-solution:hover { border-color: rgba(37, 99, 235, 0.5); }

.card-icon { margin-bottom: 20px; }
.card-problem .card-icon { color: #ef4444; }
.card-solution .card-icon { color: #3b82f6; }

.card h3 { margin-bottom: 20px; font-size: 1.4rem; }
.card ul { list-style: none; }
.card ul li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
    color: var(--text-muted);
}

.red-icon { color: #ef4444; min-width: 20px; }
.blue-icon { color: #3b82f6; min-width: 20px; }

/* --- TABS INTERACTIVAS --- */
.tabs-container {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 30px;
    border: 1px solid var(--border-color);
}

.tab-buttons {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.tab-btn {
    flex: 1;
    padding: 15px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s;
}

.tab-btn.active, .tab-btn:hover {
    background: var(--primary-blue);
    color: white;
    border-color: var(--primary-blue);
}

.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeIn 0.4s ease; }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.tab-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
}

.tab-item {
    background: rgba(255, 255, 255, 0.02);
    padding: 25px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    text-align: center;
}

.tab-item i {
    color: #60a5fa;
    width: 36px;
    height: 36px;
    margin-bottom: 15px;
}

.tab-item h4 { margin-bottom: 10px; }
.tab-item p { font-size: 0.9rem; color: var(--text-muted); }

/* --- GALERÍA DE IMÁGENES --- */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.gallery-card {
    background: var(--bg-card);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: all 0.3s;
}

.gallery-card:hover {
    transform: translateY(-6px);
    border-color: rgba(37, 99, 235, 0.4);
}

.gallery-img {
    height: 200px;
    overflow: hidden;
}

.gallery-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.gallery-card:hover .gallery-img img {
    transform: scale(1.08);
}

.gallery-info {
    padding: 22px;
}

.gallery-info h4 { margin-bottom: 8px; font-size: 1.1rem; }
.gallery-info p { font-size: 0.9rem; color: var(--text-muted); }

/* --- FLUJO DE TRABAJO --- */
.flow-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-card);
    padding: 40px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    gap: 15px;
}

.flow-step { text-align: center; flex: 1; }
.step-number {
    background: var(--primary-blue);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    margin: 0 auto 12px;
    font-size: 0.85rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
}

.flow-step i { color: #60a5fa; margin-bottom: 10px; width: 28px; height: 28px; }
.flow-arrow { color: var(--text-muted); }

/* --- IMPACTO --- */
.impact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.impact-card {
    background: var(--bg-card);
    padding: 30px;
    border-radius: 16px;
    border-left: 4px solid var(--accent-cyan);
    border-top: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.impact-card h3 { margin-bottom: 10px; }
.impact-card p { color: var(--text-muted); font-size: 0.95rem; }

/* --- FOOTER --- */
footer {
    border-top: 1px solid var(--border-color);
    padding: 40px 0;
    margin-top: 60px;
    background: rgba(10, 12, 16, 0.9);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    padding: 0 20px;
}

.footer-left h3 {
    color: #60a5fa;
    margin-bottom: 5px;
    letter-spacing: 2px;
}

.footer-right p { color: var(--text-muted); font-size: 0.9rem; }

/* --- MEDIA QUERIES (Súper Responsive / Resize Perfecto) --- */
@media (max-width: 968px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .hero h1 { font-size: 2.5rem; }
    .tagline { margin: 0 auto 30px; }
    .hero-actions { justify-content: center; }
    .prototype-card { margin: 0 auto; }
    .metrics-grid { grid-template-columns: repeat(2, 1fr); gap: 30px; }
    .metric-item:nth-child(2) { border-right: none; }
    .sim-display { grid-template-columns: 1fr; }
    .sim-screen { border-right: none; border-bottom: 1px solid var(--border-color); }
    .flow-container { flex-direction: column; gap: 25px; }
    .flow-arrow { transform: rotate(90deg); }
}

@media (max-width: 640px) {
    .navbar { padding: 15px 20px; }
    .nav-links { display: none; /* Simplificado para competir en móvil */ }
    .hero h1 { font-size: 2rem; }
    .metrics-grid { grid-template-columns: 1fr; }
    .metric-item { border-right: none; border-bottom: 1px solid var(--border-color); padding-bottom: 15px; }
    .metric-item:last-child { border-bottom: none; }
    .tab-buttons { flex-direction: column; }
}