/* ==========================================
   ANFACAR PREMIUM STYLING SYSTEM (VANILLA CSS)
   ========================================== */

/* Design Tokens & Theme Variables */
:root {
    /* Fonts */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;

    /* Theme: Dark (Default) */
    --bg-primary: #0b0f19;
    --bg-secondary: #131926;
    --bg-card: rgba(22, 30, 49, 0.7);
    --bg-card-hover: rgba(30, 41, 67, 0.9);
    --border-color: rgba(255, 255, 255, 0.08);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --shadow-premium: 0 10px 30px -10px rgba(0, 0, 0, 0.5), 0 1px 1px rgba(255, 255, 255, 0.05) inset;
    
    /* Institutional Brand Colors */
    --brand-blue: #0a3d82;
    --brand-blue-rgb: 10, 61, 130;
    --brand-blue-accent: #3b82f6; /* Lighter royal blue for dark mode contrast */
    --brand-yellow: #f1b312;
    --brand-yellow-rgb: 241, 179, 18;

    /* Branding Accent Colors (HSL based for easy opacity manipulation) */
    --c-electric: 38, 92%, 50%;     /* #f59e0b Amber / Maps to Yellow */
    --c-agricola: 142, 70%, 45%;    /* #10b981 Emerald */
    --c-construccion: 20, 90%, 48%; /* #e05c14 Rust Orange */
    --c-automotriz: 43, 90%, 51%;   /* #f1b312 Golden Yellow (Official brand yellow!) */
    
    --accent-electric: hsl(var(--c-electric));
    --accent-agricola: hsl(var(--c-agricola));
    --accent-construccion: hsl(var(--c-construccion));
    --accent-automotriz: hsl(var(--c-automotriz));

    /* UI Tones */
    --glass-blur: blur(12px);
    --transition-snappy: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    --transition-smooth: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Light Theme Variables */
[data-theme="light"] {
    --bg-primary: #f8fafc;
    --bg-secondary: #f1f5f9;
    --bg-card: rgba(255, 255, 255, 0.8);
    --bg-card-hover: rgba(255, 255, 255, 0.98);
    --border-color: rgba(15, 23, 42, 0.08);
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --shadow-premium: 0 15px 40px -12px rgba(15, 23, 42, 0.12), 0 1px 2px rgba(0, 0, 0, 0.05);
    
    /* Light Theme Brand adjustments */
    --brand-blue-accent: #0a3d82; /* Official deep royal blue for light mode */
}

/* Reset & Global Rules */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.4s ease, color 0.4s ease;
}

a {
    color: inherit;
    text-decoration: none;
}

button, input, select, textarea {
    font-family: inherit;
}

/* Smooth custom scrollbars */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
    background: var(--text-muted);
    border-radius: 5px;
    border: 3px solid var(--bg-primary);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

/* Glowing Ambient Backgrounds */
.glow-bg {
    position: absolute;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    filter: blur(160px);
    opacity: 0.15;
    pointer-events: none;
    z-index: -1;
    transition: opacity 0.5s ease;
}

.glow-primary {
    top: -100px;
    left: -100px;
    background: radial-gradient(circle, rgba(var(--brand-blue-rgb), 0.25) 0%, transparent 70%);
}

.glow-secondary {
    top: 600px;
    right: -100px;
    background: radial-gradient(circle, rgba(var(--brand-yellow-rgb), 0.15) 0%, transparent 70%);
}

/* General Layout Utilities */
.section {
    padding: 65px 5% 45px;
    max-width: 1300px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.section-header {
    margin-bottom: 35px;
    max-width: 700px;
}

.section-header.text-center {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-top: 15px;
    margin-bottom: 20px;
    letter-spacing: -0.03em;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-primary);
    text-transform: uppercase;
}

.badge-accent {
    display: inline-block;
    padding: 6px 18px;
    background: rgba(var(--c-electric), 0.1);
    border: 1px solid rgba(var(--c-electric), 0.2);
    border-radius: 100px;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent-electric);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-status {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    background: rgba(var(--c-agricola), 0.15);
    border: 1px solid rgba(var(--c-agricola), 0.3);
    color: var(--accent-agricola);
    font-size: 0.8rem;
    font-weight: 600;
    border-radius: 6px;
}

.badge-status.bg-yellow {
    background: rgba(var(--c-electric), 0.15);
    border: 1px solid rgba(var(--c-electric), 0.3);
    color: var(--accent-electric);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-snappy);
    border: none;
    text-align: center;
}

.btn-primary {
    background: var(--brand-blue-accent);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(var(--brand-blue-rgb), 0.3);
}

.btn-primary:hover {
    background: var(--brand-yellow);
    color: #0b0f19;
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(var(--brand-yellow-rgb), 0.4);
}

.btn-primary.bg-agricola {
    background: var(--accent-agricola);
    color: #fff;
    box-shadow: 0 4px 20px rgba(var(--c-agricola), 0.3);
}
.btn-primary.bg-agricola:hover {
    box-shadow: 0 8px 30px rgba(var(--c-agricola), 0.5);
}

.btn-primary.bg-construccion {
    background: var(--accent-construccion);
    color: #fff;
    box-shadow: 0 4px 20px rgba(var(--c-construccion), 0.3);
}
.btn-primary.bg-construccion:hover {
    box-shadow: 0 8px 30px rgba(var(--c-construccion), 0.5);
}

.btn-primary.bg-automotriz {
    background: var(--accent-automotriz);
    color: #0b0f19;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(var(--c-automotriz), 0.3);
}
.btn-primary.bg-automotriz:hover {
    background: var(--brand-blue-accent);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(var(--brand-blue-rgb), 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.btn-whatsapp {
    background: #25d366;
    color: #fff;
    font-weight: 700;
}
.btn-whatsapp:hover {
    background: #128c7e;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
}

.btn-facebook {
    background: #1877f2;
    color: #fff;
    font-weight: 700;
}
.btn-facebook:hover {
    background: #1565c0;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(24, 119, 242, 0.3);
}

.btn-whatsapp-secondary {
    background: rgba(37, 211, 102, 0.1);
    color: #25d366;
    border: 1px solid rgba(37, 211, 102, 0.3);
}
.btn-whatsapp-secondary:hover {
    background: #25d366;
    color: #fff;
}

/* Main Header & Navigation */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    background: rgba(11, 15, 25, 0.7);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition-snappy);
}

[data-theme="light"] .main-header {
    background: rgba(248, 250, 252, 0.8);
}

.header-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 20px 5%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-svg {
    flex-shrink: 0;
}

.logo-text-group {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.logo-title {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.5rem;
    letter-spacing: -0.04em;
    line-height: 1.1;
}

.blue-text {
    color: var(--brand-blue-accent);
    transition: var(--transition-snappy);
}

.yellow-text {
    color: var(--brand-yellow);
    transition: var(--transition-snappy);
}

.logo-subtitle {
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.15em;
    color: var(--text-muted);
    line-height: 1;
    margin-top: 2px;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-link {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-secondary);
    position: relative;
    padding: 6px 0;
    transition: var(--transition-snappy);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 2px;
    background: var(--accent-electric);
    transition: var(--transition-snappy);
}

.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
}

.nav-link.active::after {
    width: 100%;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.theme-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-snappy);
}

.theme-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* Light/Dark Icon states */
.sun-icon { display: none; }
.moon-icon { display: block; }

[data-theme="light"] .sun-icon { display: block; }
[data-theme="light"] .moon-icon { display: none; }

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

/* Hero Section */
.hero-section {
    padding: 110px 5% 45px;
    max-width: 1300px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.04em;
    margin-top: 12px;
    margin-bottom: 16px;
}

.text-gradient {
    background: linear-gradient(135deg, var(--accent-electric) 0%, var(--accent-agricola) 50%, var(--accent-construccion) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
    max-width: 740px;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 30px;
    width: 100%;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
    width: 100%;
    max-width: 600px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-num {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--text-primary);
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Interactive Tabs Section */
.tabs-container {
    width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 30px;
    box-shadow: var(--shadow-premium);
}

.tab-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 16px;
}

.tab-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 28px;
    background: none;
    border: 1px solid transparent;
    color: var(--text-secondary);
    border-radius: 12px;
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition-snappy);
}

.tab-btn i {
    width: 22px;
    height: 22px;
}

.tab-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.02);
}

/* Dynamic active state colors for tabs */
.tab-btn.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
}

.tab-btn[data-target="tab-electricidad"].active {
    border-color: rgba(var(--c-electric), 0.3);
    color: var(--accent-electric);
    background: rgba(var(--c-electric), 0.06);
}

.tab-btn[data-target="tab-agricola"].active {
    border-color: rgba(var(--c-agricola), 0.3);
    color: var(--accent-agricola);
    background: rgba(var(--c-agricola), 0.06);
}

.tab-btn[data-target="tab-construccion"].active {
    border-color: rgba(var(--c-construccion), 0.3);
    color: var(--accent-construccion);
    background: rgba(var(--c-construccion), 0.06);
}

.tab-btn[data-target="tab-automotriz"].active {
    border-color: rgba(var(--c-automotriz), 0.3);
    color: var(--accent-automotriz);
    background: rgba(var(--c-automotriz), 0.06);
}

/* Tab panes rendering */
.tab-pane {
    display: none;
    animation: fadeIn 0.4s ease forwards;
}

.tab-pane.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.tab-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 50px;
    align-items: center;
}

.area-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.color-electric {
    background: rgba(var(--c-electric), 0.1);
    color: var(--accent-electric);
}

.color-agricola {
    background: rgba(var(--c-agricola), 0.1);
    color: var(--accent-agricola);
}

.color-construccion {
    background: rgba(var(--c-construccion), 0.1);
    color: var(--accent-construccion);
}

.color-automotriz {
    background: rgba(var(--c-automotriz), 0.1);
    color: var(--accent-automotriz);
}

.tab-info h3 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.2;
}

.tab-info > p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 20px;
}

.services-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 25px;
}

.service-bullet {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.service-bullet i {
    width: 24px;
    height: 24px;
    margin-top: 3px;
    flex-shrink: 0;
}

.service-bullet div {
    font-size: 0.98rem;
    color: var(--text-secondary);
}

.service-bullet strong {
    color: var(--text-primary);
    display: block;
    margin-bottom: 4px;
}

.text-electric { color: var(--accent-electric); }
.text-agricola { color: var(--accent-agricola); }
.text-construccion { color: var(--accent-construccion); }
.text-automotriz { color: var(--accent-automotriz); }

/* Tab Showcase Side */
.spec-card {
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 30px;
}

.spec-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.spec-header i {
    width: 28px;
    height: 28px;
}

.spec-header h4 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
}

.spec-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 24px;
}

.spec-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.spec-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 0.9rem;
}

.spec-features li i {
    width: 18px;
    height: 18px;
}

.agri-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.agri-item {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    font-weight: 700;
    font-size: 0.85rem;
}

.agri-item i {
    width: 24px;
    height: 24px;
}

/* Certificacion Section */
.cert-card-large {
    background: linear-gradient(135deg, rgba(var(--c-electric), 0.08) 0%, rgba(var(--bg-card), 0.8) 100%);
    border: 1px solid rgba(var(--c-electric), 0.2);
    border-radius: 32px;
    padding: 35px;
    box-shadow: var(--shadow-premium);
}

.cert-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 40px;
    align-items: center;
}

.cert-text h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    margin-top: 10px;
    margin-bottom: 15px;
}

.cert-text p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 24px;
}

.check-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.check-box {
    display: flex;
    gap: 16px;
}

.check-box i {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

.text-yellow { color: var(--accent-electric); }
.text-slate { color: #0b0f19; }

.check-box h5 {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.check-box p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0;
}

/* SEC Interactive Widget */
.cert-interactive-widget {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 30px;
}

.cert-interactive-widget h4 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 6px;
}

.text-muted { color: var(--text-muted); }
.text-sm { font-size: 0.85rem; }

.sec-calc-form {
    margin-top: 24px;
}

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

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-secondary);
}

.form-control {
    width: 100%;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px 16px;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: var(--transition-snappy);
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-electric);
    box-shadow: 0 0 10px rgba(var(--c-electric), 0.15);
}

.calc-result {
    background: rgba(0, 0, 0, 0.2);
    border-left: 4px solid var(--accent-electric);
    padding: 16px;
    border-radius: 4px 8px 8px 4px;
    margin-bottom: 24px;
}

.result-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.result-value {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--accent-electric);
    margin-bottom: 8px;
}

.result-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.w-full { width: 100%; }

/* Future Giros / Expansion Section */
.cards-interactive-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    max-width: 860px;
    margin: 50px auto 0;
    gap: 30px;
}

.future-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 30px;
    transition: var(--transition-snappy);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    box-shadow: var(--shadow-premium);
}

.future-card:hover {
    transform: translateY(-8px);
    background: var(--bg-card-hover);
    border-color: rgba(255, 255, 255, 0.15);
}

.future-icon-wrap {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.future-icon-wrap i {
    width: 24px;
    height: 24px;
    color: #fff;
}

.bg-purple { background: linear-gradient(135deg, #a855f7, #7c3aed); }
.bg-blue { background: linear-gradient(135deg, #3b82f6, #1d4ed8); }
.bg-teal { background: linear-gradient(135deg, #14b8a6, #0f766e); }

.future-card h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.future-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 24px;
    flex-grow: 1;
}

.future-tag {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-muted);
}

/* Contact Section & Form */
.contact-grid {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 40px;
    align-items: flex-start;
}

.contact-info-block {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.contact-info-block h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    margin-top: 10px;
    margin-bottom: 15px;
}

.contact-info-block p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 24px;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
}

.detail-item {
    display: flex;
    gap: 16px;
}

.detail-item i {
    width: 24px;
    height: 24px;
    color: var(--accent-electric);
    margin-top: 3px;
}

.detail-item h5 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.detail-item p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 0;
}

.social-links {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.social-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: var(--transition-snappy);
    cursor: pointer;
}

.social-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}

.social-btn.sb-wa:hover {
    background: rgba(37, 211, 102, 0.15);
    border-color: rgba(37, 211, 102, 0.3);
    color: #25d366;
}

/* Contact Card Form */
.contact-card-form {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 30px;
    border-radius: 24px;
    box-shadow: var(--shadow-premium);
}

.contact-card-form h4 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 8px;
}

.contact-form {
    margin-top: 20px;
}

.form-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.contact-form textarea.form-control {
    resize: none;
}

.contact-form .form-control {
    border-radius: 10px;
}

.contact-form .form-control:focus {
    border-color: var(--accent-electric);
}

.contact-form label {
    font-weight: 600;
}

.contact-actions-flex {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 10px;
}

.form-actions-flex {
    display: flex;
    gap: 16px;
    margin-top: 10px;
}

.btn-submit {
    flex-grow: 2;
}

/* Site Footer */
.site-footer {
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 50px 5% 30px;
}

.footer-container {
    max-width: 1300px;
    margin: 0 auto 30px;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 40px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
}

.logo-footer {
    font-size: 1.8rem;
}

.footer-brand p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

.footer-links, .footer-info {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.footer-links h5, .footer-info h5 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.footer-links a {
    font-size: 0.95rem;
    color: var(--text-secondary);
    transition: var(--transition-snappy);
}

.footer-links a:hover {
    color: var(--accent-electric);
    padding-left: 4px;
}

.footer-info p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 0;
}

.footer-info i {
    width: 16px;
    height: 16px;
    display: inline-block;
    vertical-align: middle;
    margin-right: 6px;
}

.footer-bottom {
    max-width: 1300px;
    margin: 0 auto;
    border-top: 1px solid var(--border-color);
    padding-top: 30px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* ==========================================
   RESPONSIVE STYLING (MEDIA QUERIES)
   ========================================== */

@media (max-width: 1024px) {
    html {
        font-size: 15px;
    }
    .hero-grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }
    .hero-content {
        text-align: center;
        align-items: center;
    }
    .hero-description {
        margin-left: auto;
        margin-right: auto;
    }
    .hero-buttons {
        justify-content: center;
    }
    .hero-stats {
        justify-content: center;
    }
    .tab-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .cert-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .cards-interactive-grid {
        grid-template-columns: 1fr 1fr;
    }
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 80px 4% 50px;
    }
    .section-title {
        font-size: 2.2rem;
    }
    .nav-menu {
        display: none; /* Handled by mobile toggle overlay */
    }
    .menu-toggle {
        display: block;
    }
    .hide-on-mobile {
        display: none;
    }
    
    /* Hero Adjustments */
    .hero-section {
        padding: 100px 4% 40px;
    }
    .hero-title {
        font-size: 2.5rem;
    }
    .hero-description {
        font-size: 1.1rem;
        margin-bottom: 20px;
    }
    .hero-buttons {
        flex-direction: column;
        width: 100%;
        max-width: 320px;
        margin-left: auto;
        margin-right: auto;
        gap: 12px;
    }
    .hero-buttons .btn {
        width: 100%;
    }
    .hero-stats {
        gap: 20px 30px;
        flex-wrap: wrap;
        padding-top: 15px;
    }
    .stat-num {
        font-size: 1.8rem;
    }
    .stat-label {
        font-size: 0.75rem;
    }

    /* Tabs Layout Adjustments */
    .tabs-container {
        padding: 20px;
        border-radius: 18px;
    }
    .tab-buttons {
        flex-direction: column;
        align-items: center;
        gap: 10px;
        padding-bottom: 12px;
    }
    .tab-btn {
        width: 100%;
        justify-content: center;
        padding: 12px;
        font-size: 1rem;
    }
    .tab-info h3 {
        font-size: 1.7rem;
    }
    .tab-info > p {
        font-size: 1rem;
    }

    /* Certificación SEC Adjustments */
    .cert-card-large {
        padding: 24px;
        border-radius: 24px;
    }
    .cert-text h2 {
        font-size: 1.8rem;
    }
    .cert-text p {
        font-size: 1rem;
    }
    .check-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    /* Forms & Grid adjustments */
    .form-row-2 {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    .form-actions-flex {
        flex-direction: column;
    }
    .btn-submit {
        width: 100%;
    }
    .btn-whatsapp-secondary {
        width: 100%;
    }
    .cards-interactive-grid {
        grid-template-columns: 1fr;
    }
    .footer-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    /* Header Adjustments on Mobile */
    .header-container {
        padding: 12px 4%;
    }
    
    /* Mobile nav overlay styles */
    .mobile-nav {
        display: none;
        position: fixed;
        top: 68px; /* Matches the reduced header height */
        left: 0;
        width: 100%;
        background: var(--bg-secondary);
        border-bottom: 1px solid var(--border-color);
        padding: 20px;
        flex-direction: column;
        gap: 16px;
        z-index: 99;
        box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    }
    .mobile-nav.active {
        display: flex;
    }
    .mobile-link {
        font-family: var(--font-heading);
        font-weight: 700;
        font-size: 1.1rem;
        padding: 8px 0;
        border-bottom: 1px solid var(--border-color);
        color: var(--text-primary);
    }
}

/* Extra small mobile screen adjustments */
@media (max-width: 480px) {
    .logo-title {
        font-size: 1.25rem;
    }
    .logo-subtitle {
        font-size: 0.55rem;
    }
    .logo-brand {
        gap: 8px;
    }
    .logo-svg {
        width: 36px;
        height: 30px;
    }
    .hero-title {
        font-size: 2.0rem;
    }
    .section-title {
        font-size: 1.8rem;
    }
    .section-subtitle {
        font-size: 0.95rem;
    }
    .tab-info h3 {
        font-size: 1.45rem;
    }
    .cert-text h2 {
        font-size: 1.5rem;
    }
    .cert-interactive-widget {
        padding: 20px 15px;
        border-radius: 16px;
    }
    .agri-grid {
        grid-template-columns: 1fr;
    }
    .spec-card {
        padding: 20px;
    }
}

/* ==========================================
   SHOWCASE GALLERY & LIGHTBOX STYLING
   ========================================== */

.showcase-gallery {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid var(--border-color);
}

.gallery-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.gallery-title i {
    width: 18px;
    height: 18px;
}

.gallery-grid {
    display: grid;
    gap: 12px;
}

.gallery-grid.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.gallery-grid.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

.gallery-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    text-align: center;
}

.gallery-img-wrapper {
    width: 100%;
    aspect-ratio: 1.25;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: var(--transition-snappy);
    position: relative;
    background: rgba(0, 0, 0, 0.2);
}

.gallery-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.gallery-item:hover .gallery-img-wrapper {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* Light / Dark specific active colors for gallery border on hover */
#tab-electricidad .gallery-item:hover .gallery-img-wrapper {
    border-color: rgba(241, 179, 18, 0.5); /* Brand Yellow / Electric HSL */
    box-shadow: 0 8px 20px rgba(241, 179, 18, 0.15), 0 4px 12px rgba(0,0,0,0.15);
}
#tab-agricola .gallery-item:hover .gallery-img-wrapper {
    border-color: rgba(16, 185, 129, 0.5); /* Sprout Emerald */
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.15), 0 4px 12px rgba(0,0,0,0.15);
}
#tab-construccion .gallery-item:hover .gallery-img-wrapper {
    border-color: rgba(224, 92, 20, 0.5); /* Rust Orange */
    box-shadow: 0 8px 20px rgba(224, 92, 20, 0.15), 0 4px 12px rgba(0,0,0,0.15);
}
#tab-automotriz .gallery-item:hover .gallery-img-wrapper {
    border-color: rgba(241, 179, 18, 0.5); /* Brand Yellow */
    box-shadow: 0 8px 20px rgba(241, 179, 18, 0.15), 0 4px 12px rgba(0,0,0,0.15);
}

.gallery-item:hover .gallery-img-wrapper img {
    transform: scale(1.08);
}

.gallery-label {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-muted);
    margin-top: 8px;
    transition: var(--transition-snappy);
    line-height: 1.2;
}

.gallery-item:hover .gallery-label {
    color: var(--text-primary);
}

#tab-electricidad .gallery-item:hover .gallery-label { color: var(--accent-electric); }
#tab-agricola .gallery-item:hover .gallery-label { color: var(--accent-agricola); }
#tab-construccion .gallery-item:hover .gallery-label { color: var(--accent-construccion); }
#tab-automotriz .gallery-item:hover .gallery-label { color: var(--accent-automotriz); }

/* Premium Lightbox Modal Styles */
.lightbox-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(11, 15, 25, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox-modal.active {
    display: flex;
    opacity: 1;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 85%;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: zoomIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes zoomIn {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.lightbox-img {
    max-width: 100%;
    max-height: 70vh;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    object-fit: contain;
}

.lightbox-caption {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    margin-top: 16px;
    text-align: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 8px 24px;
    border-radius: 100px;
    backdrop-filter: blur(4px);
}

.lightbox-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.5rem;
    transition: var(--transition-snappy);
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .gallery-grid.grid-3, .gallery-grid.grid-4 {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

