/* --- CSS VARIABLES & PALETA DE COLORES --- */
:root {
    --bg-dark: #0F172A;        /* Azul Marino Profundo (Dominante 60%) */
    --bg-light: #F8FAFC;       /* Gris Claro / Estructura (30%) */
    --primary-blue: #2563EB;   /* Azul Técnico (Acento B2B) */
    --accent-red: #DC2626;     /* Rojo Automotriz (Acento B2C) */
    --text-main: #1E293B;
    --text-muted: #64748B;
    --white: #FFFFFF;
    
    --font-heading: 'Inter', sans-serif;
    --font-body: 'Roboto', sans-serif;
}

/* --- RESET & GLOBAL --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    color: var(--text-main);
    background-color: var(--white);
    line-height: 1.6;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- NAVIGATION --- */
.navbar {
    background-color: var(--bg-dark);
    padding: 18px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.logo-image {
    height: 44px;
    width: auto;
    display: block;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.18));
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 25px;
    align-items: center;
}

.nav-links a {
    color: #94A3B8;
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--white);
}

.btn-nav {
    background-color: var(--primary-blue);
    color: var(--white) !important;
    padding: 8px 16px;
    border-radius: 4px;
}

/* --- SPLIT HERO SECTION --- */
.hero-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 80vh;
}

.hero-card {
    position: relative;
    display: flex;
    align-items: flex-end;
    padding: 60px 40px;
    background-size: cover;
    background-position: center;
    color: var(--white);
}

.hero-card.industrial {
    background-image: url('/img/materias_prima.png');
}

.hero-card.automotive {
    background-image: url('/img/refacciones.png');
}

.overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(180deg, rgba(15,23,42,0.3) 0%, rgba(15,23,42,0.95) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 500px;
}

.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 15px;
}

.badge.b2b { background-color: var(--primary-blue); }
.badge.b2c { background-color: var(--accent-red); }

.hero-content h1 {
    font-size: 2.2rem;
    line-height: 1.2;
    margin-bottom: 15px;
}

.hero-content p {
    color: #CBD5E1;
    margin-bottom: 25px;
}

/* --- BUTTONS --- */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 4px;
    font-weight: 700;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-primary { background-color: var(--primary-blue); color: var(--white); }
.btn-primary:hover { background-color: #1D4ED8; }

.btn-accent { background-color: var(--accent-red); color: var(--white); }
.btn-accent:hover { background-color: #B91C1C; }

.btn-block { width: 100%; text-align: center; }

/* --- SECTIONS --- */
.section { padding: 80px 0; }
.bg-light { background-color: var(--bg-light); }
.bg-dark { background-color: var(--bg-dark); color: var(--white); }

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.section-title p { color: var(--text-muted); }
.section-title.light p { color: #94A3B8; }

/* --- GRID & CARDS --- */
.grid { display: grid; gap: 30px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.card {
    background: var(--white);
    padding: 30px;
    border-radius: 6px;
    border: 1px solid #E2E8F0;
}

.card h3 { margin-bottom: 10px; }
.card p { color: var(--text-muted); margin-bottom: 20px; font-size: 0.95rem; }

.link-btn {
    color: var(--primary-blue);
    font-weight: 700;
    text-decoration: none;
}

/* --- COMPATIBILITY FILTER --- */
.filter-box {
    background-color: var(--bg-light);
    padding: 30px;
    border-radius: 6px;
    border: 1px solid #E2E8F0;
    max-width: 800px;
    margin: 0 auto;
}

.filter-form {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.filter-form .form-group:nth-child(4) {
    grid-column: span 3;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-main);
}

select, input, textarea {
    padding: 12px;
    border: 1px solid #CBD5E1;
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 0.95rem;
}

.search-results-message {
    margin-top: 15px;
    font-weight: 700;
    text-align: center;
    color: var(--primary-blue);
}

/* --- CONTACT FORM --- */
.contact-form {
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

footer {
    background-color: #090D16;
    color: #64748B;
    padding: 25px 0;
    font-size: 0.85rem;
}

/* --- RESPONSIVE MOBILE --- */
@media (max-width: 768px) {
    .hero-split { grid-template-columns: 1fr; }
    .grid-3 { grid-template-columns: 1fr; }
    .filter-form { grid-template-columns: 1fr; }
    .filter-form .form-group:nth-child(4) { grid-column: span 1; }
    .form-row { grid-template-columns: 1fr; }
}