:root {
  /* BRAND */
  --brand: #051d40;

  /* BASE */
  --bg: #ffffff;
  --bg-soft: #f6f7f9;
  --panel: #ffffff;
  --border: #e4e7ec;

  /* TEXT */
  --text: #1f2933;
  --muted: #5f6c7b;
  --muted2: #8a94a6;

  /* PACKAGE COLORS */
  --green: #2f855a;
  --yellow: #b7791f;
  --blue: #2b6cb0;

  --radius: 16px;
  --radius2: 22px;
  --max: 1140px;
}

/* --- RESET & BASE --- */
* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px; /* Para que el menú sticky no tape títulos */
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
}

a { color: var(--brand); text-decoration: none; transition: all 0.3s ease; }
a:hover { text-decoration: underline; }

.container { width: min(var(--max), calc(100% - 40px)); margin: auto; }

/* Botones Generales */
.btn {
  padding: 10px 20px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  border: 1px solid var(--brand);
  color: var(--brand);
  background: #fff;
  cursor: pointer;
  display: inline-block;
  text-decoration: none !important;
  text-align: center;
  transition: all 0.3s ease;
}

.btn.primary {
  background: var(--brand);
  color: #fff;
}
.btn.primary:hover {
  background: #082d63;
  transform: translateY(-2px);
}

/* --- HEADER & NAV --- */
header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 1000;
  height: 70px;
  display: flex;
  align-items: center;
}

nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  font-size: 18px;
  color: var(--brand);
}
.brand img { height: 32px; width: auto; display: block; }

.navlinks { display: flex; gap: 32px; }
.navlinks a { font-weight: 600; font-size: 14px; color: var(--muted); }
.navlinks a:hover { color: var(--brand); text-decoration: none; }

.menu-toggle {
  display: none;
  background: none; border: none;
  font-size: 26px; color: var(--brand);
  cursor: pointer; padding: 0;
}

/* =========================================
   4. HERO SECTION (NUEVO DISEÑO)
   ========================================= */
.hero {
  position: relative;
  color: #fff; /* Texto blanco obligatorio por el fondo oscuro */
  padding: 120px 0; /* Más altura para mayor impacto */
  min-height: 80vh; /* Opcional: Que ocupe al menos el 80% de la pantalla */
  display: flex;
  align-items: center;

  /* --- FONDO CON IMAGEN Y OVERLAY --- */
  /* Capa 1: Degradado del color de marca con transparencia (0.85 a 0.75) */
  /* Capa 2: La imagen de fondo */
  background: 
    linear-gradient(to right, rgba(5, 29, 64, 0.9), rgba(5, 29, 64, 0.7)),
    url('https://images.unsplash.com/photo-1486406146926-c627a92ad1ab?auto=format&fit=crop&w=1920&q=80'); /* <--- REEMPLAZA CON TU IMAGEN LOCAL: url('../img/hero-bg.jpg'); */
  
  background-size: cover;      /* Cubre todo el espacio sin deformar */
  background-position: center; /* Centra la imagen */
  /* background-attachment: fixed; */ /* Descomenta si quieres efecto Parallax */
}

/* Layout de la cuadrícula */
.hero-grid {
  display: grid;
  /* Define las columnas: El logo toma espacio automático, el texto el resto */
  grid-template-columns: auto 1fr; 
  gap: 200px; /* Espacio grande entre logo y texto */
  align-items: center; /* Centrado vertical */
}

/* --- NUEVO: Logo Grande en el Hero --- */
.hero-brand-large {
  display: flex;
  flex-direction: column; /* Logo arriba, texto abajo */
  align-items: flex-start;
  gap: 20px;
}

.hero-brand-large img {
  height: 350px; /* Icono mucho más grande que en el header */
  width: auto;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3)); /* Sombra para que resalte */
}

.hero-brand-large span {
  font-weight: 800;
  font-size: 28px; /* Texto de marca grande */
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

/* Estilos del Contenido (Derecha) */
.hero-content {
  /* Aseguramos que el texto se alinee a la izquierda dentro de su columna derecha */
  text-align: left; 
}

.hero h1 {
  font-size: 56px; /* Título más grande para este layout */
  line-height: 1.1;
  margin: 0 0 24px;
  color: #fff;
}

.hero p {
  font-size: 20px;
  color: #e2e8f0; /* Blanco hueso para leer mejor */
  max-width: 600px;
  margin-bottom: 40px;
}

.hero-ctas {
  display: flex;
  gap: 16px;
}

/* RESPONSIVIDAD DEL HERO (CORREGIDO) */
@media (max-width: 900px) {
  .hero { 
    padding: 80px 0; 
    min-height: auto; 
  }
  
  .hero-grid {
    grid-template-columns: 1fr; /* Una sola columna */
    text-align: center; /* IMPORTANTE: Centrar textos visualmente */
    gap: 40px;
  }
  
  /* 1. Ajuste del Logo y Marca */
  .hero-brand-large {
    width: 100%;
    align-items: center; /* Centra la imagen y el texto horizontalmente */
  }

  .hero-brand-large img { 
    height: 160px; /* 250px es excesivo para móvil, 160px es más equilibrado */
  }

  .hero-brand-large span { 
    font-size: 24px; 
    margin-top: 10px;
  }
  
  /* 2. Ajuste de Textos */
  .hero h1 { 
    font-size: 38px; /* Un poco más pequeño para evitar saltos de línea feos */
  }

  .hero p { 
    font-size: 18px; 
    /* Truco para centrar el bloque de texto que tiene max-width */
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 30px;
  }
  
  /* 3. Botones */
  .hero-ctas {
    flex-direction: column; /* Botones uno debajo del otro */
    gap: 15px;
    width: 100%;
  }

  .hero-ctas .btn { 
    width: 100%; /* Botones anchos para dedo fácil */
    text-align: center; 
  }
}
/* --- SECCIONES GENERALES --- */
section { padding: 80px 0; }

.eyebrow {
  font-size: 12px; letter-spacing: .14em;
  text-transform: uppercase; font-weight: 700;
  color: var(--muted2); margin-bottom: 8px;
}

h2 { font-size: 30px; margin: 0 0 12px; color: var(--brand); }
.lead { max-width: 820px; color: var(--muted); font-size: 16px; margin-bottom: 40px; }

/* --- TABLAS (PROGRAMAS) --- */
.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  padding: 22px;
  overflow: hidden; /* Para bordes redondeados */
}

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 18px 14px; border-bottom: 1px solid var(--border); text-align: left; }

th {
  background: var(--bg-soft);
  text-transform: uppercase; font-size: 12px;
  letter-spacing: .08em; color: var(--muted2);
}

/* Efecto Pop en Filas */
.card table tbody tr {
  transition: all 0.2s ease;
  position: relative; z-index: 1;
}
.card table tbody tr:hover {
  background: #fff;
  transform: scale(1.015);
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  z-index: 10;
  border-left: 4px solid var(--brand);
}

/* --- TARJETAS SOLUCIONES (GRID) --- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.card.solution {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  transition: transform 0.2s ease, border-color 0.2s ease;
  cursor: pointer;
}

.card.solution:hover {
  transform: translateY(-5px);
  border-color: var(--brand);
}

.card-icon {
  flex-shrink: 0;
  width: 48px; height: 48px;
  background: var(--bg-soft);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--brand);
  transition: all 0.3s ease;
}
.card.solution:hover .card-icon { background: var(--brand); color: #fff; }

.card-content { flex: 1; }
.solution h3 { margin: 0 0 6px; font-size: 18px; color: var(--brand); }
.solution p { margin: 0; color: var(--muted); font-size: 14px; }
.read-more { display: block; margin-top: 10px; font-size: 12px; font-weight: 700; color: var(--brand); }

/* --- CONTACTO (DARK) --- */
.cta-section {
  background-color: var(--brand); /* Fondo Azul Oscuro */
  color: #ffffff;
  padding: 80px 0;
  position: relative;
}

.cta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr; /* 50% Texto - 50% Tarjeta */
  gap: 60px;
  align-items: center;
}



/* Textos de la izquierda */
.cta-content h2 {
  color: #ffffff;
  font-size: 36px;
  margin-top: 0;
}

.cta-content p {
  color: #cbd5e0; /* Gris claro */
  font-size: 18px;
  margin-bottom: 30px;
}

/* Lista de iconos (Email, Ubicación) */
.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.contact-list li {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 15px;
  color: #e2e8f0;
  font-size: 16px;
}
.contact-list svg {
  width: 24px;
  height: 24px;
  color: #ffffff; /* Iconos blancos */
  flex-shrink: 0;
}

.contact-list { list-style: none; padding: 0; }
.contact-list li { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; color: #e2e8f0; }

@media (max-width: 900px) {
  /* Convierte los grids de 2 columnas en 1 sola */
  .cta-grid, 
  .contact-grid, 
  .form-row {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  /* Ajuste de padding en móvil */
  .cta-card, 
  .contact-form-wrapper {
    padding: 25px;
  }
}

/* Tarjeta de la derecha */
.cta-card {
  background: rgba(255, 255, 255, 0.05); /* Fondo transparente sutil */
  border: 1px solid rgba(255, 255, 255, 0.1); /* Borde fino */
  padding: 40px;
  border-radius: var(--radius2);
  text-align: center;
}

.cta-card h3 {
  color: #ffffff;
  margin-top: 0;
}

.cta-card p {
  color: #cbd5e0;
  font-size: 14px;
}

/* Botón blanco específico para esta sección */
.cta-card .btn.white {
  background: #ffffff;
  color: var(--brand);
  display: block;
  width: 100%;
}

/* --- PÁGINA CONTACTO.HTML --- */
.page-header { background: var(--bg-soft); padding: 80px 0 60px; text-align: center; border-bottom: 1px solid var(--border); }
.page-header h1 { color: var(--brand); margin: 10px 0; }

.contact-content { padding: 60px 0; }
.contact-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 60px; }

.contact-form-wrapper {
  background: #fff; padding: 40px;
  border-radius: var(--radius2);
  border: 1px solid var(--border);
  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.form-group { margin-bottom: 24px; }
label { display: block; font-weight: 700; color: var(--brand); margin-bottom: 8px; font-size: 14px; }

input, select, textarea {
  width: 100%; padding: 12px;
  border: 1px solid #cbd5e0; border-radius: 8px;
  font-family: inherit; font-size: 16px;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(5,29,64,0.1);
}
.full-width { width: 100%; }

/* --- FOOTER --- */
footer { background: var(--bg-soft); padding: 60px 0 30px; border-top: 1px solid var(--border); font-size: 14px; color: var(--muted); }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }

.footer-links h4 { color: var(--brand); margin: 0 0 20px; text-transform: uppercase; font-size: 12px; }
.footer-links ul { list-style: none; padding: 0; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: var(--muted); }
.footer-links a:hover { color: var(--brand); }

.footer-bottom { border-top: 1px solid var(--border); padding-top: 30px; display: flex; justify-content: space-between; }

/* --- MODAL --- */
.modal-overlay {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(5,29,64,0.6); backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex; justify-content: center; align-items: center;
  opacity: 0; visibility: hidden; transition: all 0.3s ease;
}
.modal-overlay.active { opacity: 1; visibility: visible; }

.modal-content {
  background: #fff; padding: 40px;
  border-radius: var(--radius2); width: 90%; max-width: 500px;
  position: relative; transform: translateY(20px); transition: transform 0.3s ease;
}
.modal-overlay.active .modal-content { transform: translateY(0); }
.modal-close { position: absolute; top: 15px; right: 20px; background: none; border: none; font-size: 28px; cursor: pointer; }
#modal-title { margin-top: 0; color: var(--brand); border-bottom: 1px solid var(--border); padding-bottom: 15px; }

/* --- RESPONSIVIDAD GLOBAL --- */
@media (max-width: 900px) {
  .hero-grid, .cta-grid, .grid-3 { grid-template-columns: 1fr; text-align: center; gap: 40px; }
  .hero-ctas { display: flex; flex-direction: column; gap: 15px; }
  .hero p, .cta-content p { margin-left: auto; margin-right: auto; }
  .hero-figure { order: -1; margin-bottom: 20px; } /* Imagen arriba en móvil */
  
  /* Footer y Contacto */
  .footer-grid, .contact-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 20px; text-align: center; }
}

@media (max-width: 768px) {
  /* Menú Hamburguesa */
  .menu-toggle { display: block; }
  .navlinks {
    display: none; position: absolute; top: 100%; left: 0; width: 100%;
    background: #fff; flex-direction: column; gap: 0;
    border-bottom: 1px solid var(--border); padding: 0;
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
  }
  .navlinks.active { display: flex; animation: slideDown 0.3s forwards; }
  .navlinks a { width: 100%; padding: 15px; text-align: center; border-top: 1px solid var(--bg-soft); }
  
  @keyframes slideDown { from {opacity:0; transform:translateY(-10px);} to {opacity:1; transform:translateY(0);} }

  /* Tablas Responsivas */
  table { display: block; overflow-x: auto; white-space: nowrap; }
  
  /* Formulario */
  .form-row { grid-template-columns: 1fr; gap: 0; }
  .page-header h1 { font-size: 32px; }
}

/* --- DIVIDERS SVG --- */

/* Contenedor general para olas y diagonales */
.wave-divider, 
.slant-divider {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  overflow: hidden;
  line-height: 0; /* Crucial para eliminar espacio blanco inferior */
  transform: rotate(180deg); /* A veces necesario según la dirección de la curva */
}

/* Ajuste específico para la ola */
.wave-divider svg {
  position: relative;
  display: block;
  width: calc(130% + 1.3px); /* Un poco más ancho para evitar huecos */
  height: 60px; /* Altura de la ola */
}

/* Ajuste específico para la diagonal */
.slant-divider svg {
  display: block;
  width: 100%;
  height: 80px;
}

/* Para la opción 1 (Línea elegante interna) */
.divider-elegant {
  margin: 40px 0;
  width: 100%;
  text-align: center;
  opacity: 0.5;
}

/* IMPORTANTE: Para usar olas/diagonales, la sección padre debe tener: */
section {
  position: relative; /* Para que el divider absolute se quede dentro */
}

/* Linea Divisora*/
/* Contenedor */
.industrial-separator {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 60px; /* Altura del área */
  overflow: hidden;
  margin: -1px 0;
}

/* Las líneas (izquierda y derecha) */
.separator-line {
  flex-grow: 1; /* Ocupa todo el espacio disponible */
  height: 6px; /* Grosor de la línea */
  background-color: var(--brand); /* Color visible */
}

/* Clase para ocultar la línea derecha pero ocupar espacio */
.separator-line.hidden {
  background-color: transparent; /* Invisible */
  /* Opcional: si quieres que la línea termine ANTES de la flecha, añade margin-right a la flecha */
}

/* La flecha */
.separator-arrow {
  width: 30px; /* Ancho de la flecha */
  height: 30px; /* Alto de la flecha */
  flex-shrink: 0;
  margin-left: -1px; /* Para que pegue perfecto con la línea */
}

/* --- CSS PARA EL SEPARADOR INVERTIDO --- */

/* Cuando el contenedor tiene la clase .inverted, rotamos la flecha dentro de él */
.industrial-separator.inverted .separator-arrow {
  transform: rotate(180deg); /* Gira la flecha para apuntar a la izquierda */

  /* Ajuste de margen para que pegue perfecto con la línea derecha */
  margin-left: 0;
  margin-right: -1px;
}

/* --- FONDOS DIVIDIDOS (SPLIT BACKGROUNDS) --- */

/* Opción A: Izquierda Blanca / Derecha Gris */
.bg-white-gray {
  background: linear-gradient(to right, #ffffff 50%, var(--bg-soft) 50%);
}

/* Opción B: Izquierda Gris / Derecha Blanca */
.bg-gray-white {
  background: linear-gradient(to right, var(--bg-soft) 50%, #ffffff 50%);
}

/* Opción C: Izquierda Oscura / Derecha Blanca */
.bg-brand-white {
  background: linear-gradient(to right, var(--brand) 50%, #ffffff 50%);
}

/* Opción D: Todo de un solo color (por si acaso) */
.bg-soft {
  background-color: var(--bg-soft);
}

/* --- SECCIÓN SOLUCIONES CON FONDO --- */
#soluciones {
  position: relative;
  /* Capa 1: Degradado azul oscuro semi-transparente (85% a 70% opacidad) */
  /* Capa 2: La imagen de fondo */
  background: 
    linear-gradient(rgba(5, 29, 64, 0.9), rgba(5, 29, 64, 0.7)),
    url('../img/soluciones.jpg'); /* <--- CAMBIA ESTO POR TU IMAGEN */
  
  background-size: cover;      /* Cubre todo el espacio */
  background-position: center; /* Centra la imagen */
  background-attachment: fixed; /* EFECTO PARALLAX (El fondo se queda quieto al hacer scroll) */
  
  padding: 100px 0;
}

/* Ajuste de colores de texto (ahora el fondo es oscuro) */
#soluciones h2 {
  color: #ffffff; /* Título blanco */
  margin-bottom: 20px;
}

#soluciones .eyebrow {
  color: rgba(255, 255, 255, 0.6); /* Eyebrow gris claro */
}

/* Opcional: Hacemos que las tarjetas tengan una sombra más fuerte para separarlas del fondo */
#soluciones .card {
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
  border: none; /* Quitamos el borde gris, ya no es necesario con el contraste */
}

/* --- TABS (PESTAÑAS) --- */
.tabs-container {
  background: #fff;
  border-radius: var(--radius2);
  border: 1px solid var(--border);
  overflow: hidden; /* Para que nada se salga de los bordes redondos */
  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

/* Cabecera de botones */
.tabs-header {
  display: flex;
  background: #f8fafc; /* Gris muy suave */
  border-bottom: 1px solid var(--border);
}

.tab-btn {
  flex: 1; /* Todos del mismo ancho */
  padding: 20px;
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent; /* Línea invisible */
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  letter-spacing: 0.05em;
}

.tab-btn:hover {
  color: var(--brand);
  background: rgba(5, 29, 64, 0.03);
}

/* Botón Activo */
.tab-btn.active {
  background-color: var(--brand); /* Fondo Azul Marca (#051d40) */
  color: #ffffff;                 /* Texto Blanco */
  border-bottom-color: var(--brand); /* El borde se funde con el fondo */
  font-weight: 800;               /* Texto más grueso */
  transform: translateY(-2px);    /* Un pequeño "pop" hacia arriba */
  box-shadow: 0 4px 10px rgba(5, 29, 64, 0.2); /* Sombra suave */
}

.tab-btn:not(.active):hover {
  background-color: rgba(5, 29, 64, 0.05); /* Azul muy clarito al pasar el mouse */
  color: var(--brand);
}

/* Contenido de las pestañas */
.tabs-content {
  padding: 40px;
  min-height: 250px; /* Evita saltos de altura bruscos */
}

.tab-pane {
  display: none; /* Ocultos por defecto */
  animation: fadeIn 0.4s ease forwards;
}

.tab-pane.active {
  display: block; /* Solo el activo se ve */
}

/* Layout interno de cada pestaña */
.tab-grid {
  display: grid;
  grid-template-columns: 2fr 1fr; /* Info ancha, Botón angosto */
  gap: 40px;
  align-items: center;
}

.tab-info h3 {
  color: var(--brand);
  margin-top: 0;
  font-size: 24px;
}

.tab-info p {
  font-size: 16px;
  color: var(--muted);
  line-height: 1.6;
}

.check-list {
  list-style: none;
  padding: 0;
  margin-top: 20px;
}
.check-list li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 10px;
  color: var(--text);
}
.check-list li::before {
  content: "✔"; /* O puedes usar un SVG */
  position: absolute; left: 0; top: 0;
  color: var(--green); /* Usa tu variable verde */
  font-weight: bold;
}

/* Responsividad para Tabs */
@media (max-width: 768px) {
  .tab-grid {
    grid-template-columns: 1fr; /* Todo en una columna */
    text-align: center;
  }
  .check-list li { text-align: left; display: inline-block; }
  .tabs-header { flex-direction: column; } /* Botones apilados en móvil muy pequeño si quieres, o déjalos flex */
  .tab-btn { padding: 15px 10px; font-size: 12px; }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* --- SCROLL REVEAL ANIMATION --- */

.reveal {
  opacity: 0;
  transform: translateY(30px); /* Empieza 30px más abajo */
  transition: all 0.8s ease-out; /* Duración suave */
  will-change: opacity, transform; /* Optimización de rendimiento */
}

.reveal.active {
  opacity: 1;
  transform: translateY(0); /* Regresa a su posición original */
}

/* Retrasos para elementos en grupo (ej. tarjetas) */
.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }

/* --- BARRA LATERAL (ESTILO OUTLINE) --- */
.sticky-sidebar {
  /* ... tus propiedades anteriores ... */
  position: fixed;
  left: 0;
  top: 50%;
  
  /* IMPORTANTE: El transform se controla ahora en la animación, 
     pero lo dejamos aquí como estado final por seguridad */
  transform: translate(0, -50%); 
  
  z-index: 1100;
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 2px solid var(--brand);
  border-left: none;
  border-top-right-radius: 12px;
  border-bottom-right-radius: 12px;
  overflow: visible;
  box-shadow: 4px 4px 15px rgba(5, 29, 64, 0.15);
  padding: 10px 0;

  /* --- NUEVO: ANIMACIÓN DE ENTRADA --- */
  opacity: 0; /* Empieza invisible */
  /* Nombre | Duración | Curva de velocidad (Efecto rebote suave) | Mantiene estado final */
  animation: slideInLeft 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  animation-delay: 0.5s; /* Espera medio segundo antes de entrar */
}

.sidebar-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px; 
  height: 48px;
  
  /* CAMBIOS AQUÍ: Iconos azules por defecto */
  color: var(--brand); 
  transition: all 0.2s ease;
}

.sidebar-btn:hover {
  /* Al pasar el mouse: Fondo azul suave */
  background: rgba(5, 29, 64, 0.08); 
  color: var(--blue); /* Azul más brillante */
  transform: translateX(3px); /* Pequeño movimiento a la derecha */
}

/* --- TOOLTIPS (Etiquetas) --- */
/* Mantenemos fondo oscuro para contraste máximo sobre la web blanca */
.sidebar-btn::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 100%;
  top: 50%;
  transform: translateY(-50%) translateX(15px); /* Un poco más separado */
  
  background: var(--brand); /* Fondo Azul */
  color: #fff;              /* Texto Blanco */
  
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
  pointer-events: none;
  box-shadow: 2px 2px 8px rgba(0,0,0,0.2);
}

/* Triángulo del tooltip */
.sidebar-btn::before {
  content: "";
  position: absolute;
  left: 100%;
  top: 50%;
  margin-top: -6px; /* Centrado fino */
  margin-left: 3px; /* Pegado al borde */
  
  border-width: 6px;
  border-style: solid;
  /* La flecha apunta a la izquierda, color azul */
  border-color: transparent var(--brand) transparent transparent;
  
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
}

.sidebar-btn:hover::after,
.sidebar-btn:hover::before {
  opacity: 1;
  visibility: visible;
  /* Animación de entrada */
  transform: translateY(-50%) translateX(10px); 
}

/* --- RESPONSIVIDAD --- */
@media (max-width: 900px) {
  .sticky-sidebar { display: none; }
}

/* --- KEYFRAMES PARA BARRA LATERAL --- */
@keyframes slideInLeft {
  0% {
    opacity: 0;
    /* Empieza 100px a la izquierda (oculta) y mantenemos el centrado vertical */
    transform: translate(-100px, -50%);
  }
  100% {
    opacity: 1;
    /* Termina en su posición original (0 en X) y mantenemos el centrado vertical */
    transform: translate(0, -50%);
  }
}

/* =========================================
   IMÁGENES EN PESTAÑAS DE PROGRAMAS
   ========================================= */

.tab-image {
  width: 100%;           /* Ocupa el ancho disponible de su columna */
  height: 200px;         /* Altura fija para consistencia entre pestañas */
  object-fit: cover;     /* Recorta la imagen para llenar el espacio sin deformar */
  border-radius: var(--radius); /* Bordes redondeados consistentes con el sitio */
  margin-bottom: 20px;   /* Espacio entre la imagen y el botón de cotizar */
  box-shadow: 0 4px 12px rgba(0,0,0,0.08); /* Sombra suave para dar profundidad */
  display: block;        /* Asegura que se comporte como bloque */
}

/* Ajuste opcional para el contenedor de acción */
.tab-action {
    display: flex;
    flex-direction: column;
    /* Centra el contenido (imagen y botón) verticalmente si la columna de texto es muy alta */
    justify-content: center; 
}

/* Ajuste para móviles: que la imagen no sea tan alta */
@media (max-width: 768px) {
    .tab-image {
        height: 160px;
    }
}

/* --- AJUSTE MÓVIL PARA IMÁGENES DE PROGRAMAS --- */
@media (max-width: 768px) {
  .tab-image {
    height: 200px;       /* Mucho más bajitas (antes eran de 200px o 160px) */
    margin-bottom: 12px; /* Menos espacio entre la imagen y el botón */
  }
}