/* 
  Estilo Web Corporativo e Interactivo - Ingeniería JYC SPA
  Diseño Premium, Responsivo y Moderno
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Poppins:wght@400;500;600;700;800&display=swap');

:root {
  /* Paleta de Colores Curada (Corporativa, Seguridad e Ingeniería) */
  --primary: #0f2c59;          /* Azul Marino Profundo (Confianza y Estabilidad) */
  --primary-light: #1d4480;    /* Azul Claro */
  --secondary: #0084ff;        /* Azul Vibrante (Digital, Tech) */
  --secondary-rgb: 0, 132, 255;
  --accent: #10b981;           /* Verde Esmeralda (Seguridad, Salud) */
  --accent-orange: #f97316;    /* Naranja de Seguridad (Prevención, Alerta) */
  --accent-orange-light: #ffedd5;
  --brand-lime: #b8ff00;       /* Amarillo/Verde Lima de Seguridad */
  --dark: #0f172a;             /* Gris Pizarra Oscuro */
  --light: #f8fafc;            /* Fondo Claro */
  --white: #ffffff;
  --text-main: #334155;        /* Texto Principal */
  --text-muted: #64748b;       /* Texto Secundario/Suave */
  --border-color: #e2e8f0;
  
  /* Glassmorphism y Sombras */
  --glass-bg: rgba(255, 255, 255, 0.9);
  --glass-border: rgba(255, 255, 255, 0.5);
  --glass-shadow: 0 8px 32px 0 rgba(15, 44, 89, 0.06);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 10px 25px -5px rgba(15, 44, 89, 0.08), 0 8px 10px -6px rgba(15, 44, 89, 0.08);
  --shadow-lg: 0 20px 40px -10px rgba(15, 44, 89, 0.12);
  
  /* Tipografías */
  --font-title: 'Poppins', sans-serif;
  --font-body: 'Inter', sans-serif;
  
  /* Bordes y Transición */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-round: 50px;
  --transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 1. RESETS & ESTILOS BASE */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: var(--font-body);
  background-color: var(--light);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  color: var(--primary);
  font-weight: 700;
  line-height: 1.3;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  outline: none;
  border: none;
}

/* 2. CLASES DE UTILIDAD Y CONTENEDOR */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.section-padding {
  padding: 80px 0;
}

.text-center { text-align: center; }

.section-title-wrapper {
  max-width: 700px;
  margin: 0 auto 50px auto;
}

.section-subtitle {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--secondary);
  font-weight: 700;
  margin-bottom: 12px;
  display: inline-block;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 16px;
  position: relative;
  display: inline-block;
  padding-bottom: 12px;
  background: linear-gradient(135deg, var(--primary) 20%, var(--secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  cursor: default;
}

.section-title:hover {
  transform: scale(1.03);
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 50px;
  height: 5px;
  background: linear-gradient(90deg, var(--secondary), var(--accent), var(--accent-orange));
  border-radius: 10px;
  transition: width 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), filter 0.4s ease;
  filter: drop-shadow(0 2px 4px rgba(0, 132, 255, 0.2));
}

.section-title:hover::after {
  width: 110px;
  filter: drop-shadow(0 0 8px var(--secondary));
}

/* override para títulos alineados a la izquierda */
.about-content .section-title {
  background: linear-gradient(135deg, var(--primary) 30%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.about-content .section-title::after {
  left: 0;
  transform: none;
}
.about-content .section-title:hover::after {
  width: 140px;
  filter: drop-shadow(0 0 8px var(--accent));
}

/* Clases de animación scroll reveal para títulos */
.reveal-title {
  opacity: 0;
  transform: translateY(30px) scale(0.95);
  transition: opacity 0.8s cubic-bezier(0.25, 1, 0.5, 1), transform 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

.reveal-title.revealed {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Botones Premium */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  gap: 8px;
  transition: var(--transition);
  font-size: 0.95rem;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  background: linear-gradient(135deg, var(--primary-light), var(--primary));
}

.btn-secondary {
  background: linear-gradient(135deg, var(--secondary), var(--primary-light));
  color: var(--white);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  opacity: 0.95;
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
  box-shadow: none;
}

.btn-outline:hover {
  background: var(--primary);
  color: var(--white);
  transform: translateY(-2px);
}

.btn-accent {
  background: linear-gradient(135deg, var(--accent-orange), #f97316e6);
  color: var(--white);
}

.btn-accent:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(249, 115, 22, 0.2);
}

/* 3. BARRA SUPERIOR (TOP BAR) */
.top-bar {
  background-color: var(--primary);
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.8rem;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.top-bar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.top-bar-contact {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.top-bar-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.top-bar-item i {
  color: var(--secondary);
}

.top-bar-socials {
  display: flex;
  gap: 15px;
  align-items: center;
}

.top-bar-socials a:hover {
  color: var(--secondary);
}

/* 4. CABECERA Y NAVEGACIÓN (HEADER) */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 5px solid var(--brand-lime);
  box-shadow: var(--glass-shadow);
  transition: var(--transition);
}

header.scrolled {
  padding: 5px 0;
  box-shadow: var(--shadow-md);
}

.nav-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 140px;
}

header.scrolled .nav-wrapper {
  height: 90px;
}

.logo img {
  height: 120px;
  width: auto;
  object-fit: contain;
  transition: var(--transition);
}

header.scrolled .logo img {
  height: 75px;
}

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

.nav-link {
  font-weight: 500;
  color: var(--primary);
  font-size: 0.95rem;
  padding: 8px 0;
  position: relative;
}

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

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

.nav-link:hover {
  color: var(--secondary);
}

.nav-cta {
  display: flex;
  align-items: center;
}

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

/* 5. SECCIÓN HERO */
.hero {
  position: relative;
  background: linear-gradient(135deg, rgba(15, 44, 89, 0.82) 0%, rgba(15, 23, 42, 0.88) 100%), url('../assets/images/hero_bg.png') no-repeat center center / cover;
  color: var(--white);
  padding: 120px 0 100px 0;
  overflow: hidden;
}

/* Efecto de cuadrícula y esferas de fondo */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(0, 132, 255, 0.1) 1.5px, transparent 1.5px);
  background-size: 30px 30px;
  opacity: 0.5;
  pointer-events: none;
}

.hero-glow-1 {
  position: absolute;
  top: -10%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(0, 132, 255, 0.25) 0%, transparent 70%);
  filter: blur(50px);
  pointer-events: none;
}

.hero-glow-2 {
  position: absolute;
  bottom: -10%;
  left: -10%;
  width: 350px;
  height: 350px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.15) 0%, transparent 70%);
  filter: blur(50px);
  pointer-events: none;
}

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

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: rgba(0, 132, 255, 0.15);
  border: 1px solid rgba(0, 132, 255, 0.25);
  color: #60a5fa;
  padding: 6px 16px;
  border-radius: var(--radius-round);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 24px;
  animation: fadeInUp 0.8s ease;
}

.hero-badge i {
  color: var(--accent);
}

.hero-title {
  font-size: 3rem;
  line-height: 1.2;
  color: var(--white);
  margin-bottom: 24px;
  animation: fadeInUp 1s ease;
}

.hero-title span {
  background: linear-gradient(90deg, #60a5fa, var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: 1.125rem;
  color: #cbd5e1;
  margin-bottom: 36px;
  max-width: 600px;
  animation: fadeInUp 1.2s ease;
}

.hero-ctas {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  animation: fadeInUp 1.4s ease;
}

.hero-visual {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-card {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 30px;
  border-radius: var(--radius-lg);
  box-shadow: 0 30px 60px rgba(0,0,0,0.3);
  text-align: center;
  max-width: 380px;
  position: relative;
  animation: float 6s ease-in-out infinite;
}

.hero-card-icon {
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, var(--secondary), var(--primary-light));
  color: var(--white);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 20px auto;
  box-shadow: 0 10px 20px rgba(0, 132, 255, 0.3);
}

.hero-card h3 {
  color: var(--white);
  margin-bottom: 12px;
  font-size: 1.35rem;
}

.hero-card p {
  font-size: 0.9rem;
  color: #94a3b8;
  margin-bottom: 20px;
}

.hero-stat-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 20px;
}

.hero-stat-val {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
}

.hero-stat-lbl {
  font-size: 0.75rem;
  color: #94a3b8;
}

/* 6. SECCIÓN QUIÉNES SOMOS */
.about {
  background-color: var(--white);
}

.about-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.15fr 0.95fr;
  gap: 40px;
  align-items: center;
}

.about-image-wrapper {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 4px solid var(--white);
  outline: 4px solid var(--brand-lime);
  height: 100%;
  min-height: 400px;
}

.about-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: var(--transition);
}

.about-image-wrapper:hover .about-img {
  transform: scale(1.05);
}

.about-content h3 {
  font-size: 1.8rem;
  margin-bottom: 20px;
  color: var(--primary);
}

.about-content p {
  color: var(--text-muted);
  margin-bottom: 24px;
}

.objective-box {
  background: linear-gradient(135deg, var(--light), #e2e8f0);
  border-left: 5px solid var(--secondary);
  padding: 24px;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin-bottom: 30px;
}

.objective-box h4 {
  font-size: 1.1rem;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--primary);
}

.objective-box h4 i {
  color: var(--secondary);
}

.objective-box p {
  color: var(--text-main);
  font-style: italic;
  margin-bottom: 0;
}

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

.pillar-card {
  background-color: var(--light);
  border: 1px solid var(--border-color);
  padding: 24px;
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.pillar-card:hover {
  transform: translateY(-5px);
  border-color: var(--secondary);
  box-shadow: var(--shadow-md);
}

.pillar-icon {
  font-size: 1.75rem;
  color: var(--secondary);
  margin-bottom: 12px;
}

.pillar-card h5 {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

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

/* 7. SECCIÓN SERVICIOS */
.services {
  background-color: var(--light);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 30px;
}

.service-card {
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 35px;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  transform: scaleX(0);
  transform-origin: left;
  transition: var(--transition);
}

.service-card:hover::before {
  transform: scaleX(1);
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.service-icon-box {
  width: 60px;
  height: 60px;
  background-color: rgba(0, 132, 255, 0.08);
  color: var(--secondary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin-bottom: 24px;
  transition: var(--transition);
}

.service-card:hover .service-icon-box {
  background-color: var(--secondary);
  color: var(--white);
  transform: rotateY(180deg);
}

.service-card h3 {
  font-size: 1.35rem;
  margin-bottom: 16px;
  color: var(--primary);
}

.service-card p {
  color: var(--text-muted);
  font-size: 0.925rem;
  margin-bottom: 24px;
  flex-grow: 1;
}

.service-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--secondary);
  cursor: pointer;
}

.service-link i {
  transition: var(--transition);
}

.service-card:hover .service-link i {
  transform: translateX(4px);
}

/* 7.5 SECCIÓN RUBROS */
.rubros {
  background-color: var(--white);
}

.rubros-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.rubro-card {
  background: var(--light);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  height: 200px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
  z-index: 1;
  cursor: pointer;
}

/* Fallback backgrounds for rubros */
.rubro-card::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(rgba(15, 44, 89, 0.42), rgba(15, 23, 42, 0.75));
  transition: var(--transition);
}

/* Individual card background photos */
.rubro-1::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro1.png') no-repeat center center / cover; }
.rubro-2::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro2.png') no-repeat center center / cover; }
.rubro-3::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro3.png') no-repeat center center / cover; }
.rubro-4::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro4.png') no-repeat center center / cover; }
.rubro-5::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro5.png') no-repeat center center / cover; }
.rubro-6::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro6.png') no-repeat center center / cover; }
.rubro-7::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro7.png') no-repeat center center / cover; }
.rubro-8::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro8.png') no-repeat center center / cover; }
.rubro-9::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro9.png') no-repeat center center / cover; }
.rubro-10::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro10.png') no-repeat center center / cover; }
.rubro-11::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro11.png') no-repeat center center / cover; }
.rubro-12::before { background: linear-gradient(rgba(15, 44, 89, 0.35), rgba(15, 23, 42, 0.65)), url('../assets/images/rubro12.png') no-repeat center center / cover; }

.rubro-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.rubro-card:hover::before {
  transform: scale(1.08);
  filter: brightness(0.9);
}

/* Translucent horizontal banner centered inside the card */
.rubro-banner {
  width: 100%;
  background-color: rgba(15, 44, 89, 0.78); /* Deep marine blue with transparency */
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  padding: 12px 15px;
  text-align: center;
  transition: var(--transition);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
}

.rubro-card:hover .rubro-banner {
  background-color: rgba(0, 132, 255, 0.85); /* Accent blue on hover */
  padding: 16px 15px;
}

.rubro-banner h3 {
  color: var(--white);
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 0;
  letter-spacing: 0.5px;
  line-height: 1.3;
}

/* 8. DETALLES DE SERVICIOS (MODAL SYSTEM) */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  padding: 20px;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-container {
  background: var(--white);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 700px;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  transform: scale(0.9);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 1px solid var(--border-color);
}

.modal-overlay.active .modal-container {
  transform: scale(1);
}

.modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-round);
  background-color: var(--light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  cursor: pointer;
  z-index: 10;
  transition: var(--transition);
  border: 1px solid var(--border-color);
}

.modal-close-btn:hover {
  background-color: var(--primary);
  color: var(--white);
  transform: rotate(90deg);
}

.modal-header {
  padding: 35px 35px 20px 35px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  gap: 15px;
}

.modal-header i {
  font-size: 2.25rem;
  color: var(--secondary);
}

.modal-header h3 {
  font-size: 1.6rem;
  color: var(--primary);
}

.modal-body {
  padding: 30px 35px 35px 35px;
}

.modal-body p {
  margin-bottom: 24px;
  color: var(--text-main);
  font-size: 0.95rem;
}

.modal-body h4 {
  font-size: 1.15rem;
  margin-bottom: 15px;
  color: var(--primary);
  border-bottom: 2px solid var(--light);
  padding-bottom: 8px;
}

.modal-list {
  margin-bottom: 24px;
}

.modal-list-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 0.9rem;
  color: var(--text-main);
}

.modal-list-item i {
  color: var(--accent);
  margin-top: 4px;
  font-size: 0.95rem;
}

.modal-sublist {
  margin-left: 25px;
  margin-top: 6px;
  margin-bottom: 12px;
}

.modal-sublist-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.modal-sublist-item i {
  font-size: 0.5rem;
  color: var(--secondary);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  border-top: 1px solid var(--border-color);
  padding: 20px 35px;
  background-color: var(--light);
}

/* 9. SECCIÓN METODOLOGÍA */
.methodology {
  background-color: var(--white);
  position: relative;
}

.steps-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-top: 50px;
  position: relative;
}

/* Conectores en Desktop */
.steps-container::before {
  content: '';
  position: absolute;
  top: 65px;
  left: 15%;
  right: 15%;
  height: 4px;
  background: linear-gradient(90deg, var(--secondary), var(--accent));
  z-index: 1;
}

.step-card {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 20px;
}

.step-num {
  width: 90px;
  height: 90px;
  border-radius: var(--radius-round);
  background-color: var(--white);
  border: 4px solid var(--secondary);
  color: var(--secondary);
  font-size: 1.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px auto;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}

.step-card:hover .step-num {
  background-color: var(--secondary);
  color: var(--white);
  transform: scale(1.1);
  box-shadow: 0 10px 20px rgba(0, 132, 255, 0.2);
}

.step-card:nth-child(2) .step-num {
  border-color: var(--primary);
  color: var(--primary);
}
.step-card:nth-child(2):hover .step-num {
  background-color: var(--primary);
  color: var(--white);
}

.step-card:nth-child(3) .step-num {
  border-color: var(--accent);
  color: var(--accent);
}
.step-card:nth-child(3):hover .step-num {
  background-color: var(--accent);
  color: var(--white);
}

.step-card h4 {
  font-size: 1.25rem;
  margin-bottom: 12px;
}

.step-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* 10. FORMULARIO Y CONTACTO */
.contact {
  background-color: var(--light);
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 50px;
}

.contact-info-card {
  background: var(--primary);
  color: var(--white);
  padding: 40px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.contact-info-card::before {
  content: '';
  position: absolute;
  bottom: -50px;
  right: -50px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(0, 132, 255, 0.15) 0%, transparent 70%);
  border-radius: var(--radius-round);
}

.contact-info-card h3 {
  color: var(--white);
  font-size: 1.5rem;
  margin-bottom: 24px;
}

.contact-info-list {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.contact-info-icon {
  width: 44px;
  height: 44px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: var(--secondary);
  flex-shrink: 0;
}

.contact-info-text h4 {
  color: var(--white);
  font-size: 1rem;
  margin-bottom: 4px;
}

.contact-info-text p, .contact-info-text a {
  color: #cbd5e1;
  font-size: 0.9rem;
}
.contact-info-text a:hover {
  color: var(--secondary);
}

.contact-map-wrapper {
  margin-top: 30px;
  border-radius: var(--radius-md);
  overflow: hidden;
  height: 180px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(255,255,255,0.1);
}

.contact-form-wrapper {
  background: var(--white);
  padding: 40px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
}

.contact-form-wrapper h3 {
  margin-bottom: 24px;
  font-size: 1.5rem;
  color: var(--primary);
}

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

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

.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 8px;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background-color: var(--light);
  color: var(--dark);
  font-size: 0.95rem;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--secondary);
  background-color: var(--white);
  box-shadow: 0 0 0 4px rgba(0, 132, 255, 0.1);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

.form-feedback {
  padding: 15px;
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
  font-size: 0.9rem;
  font-weight: 500;
  display: none;
}

.form-feedback.success {
  display: block;
  background-color: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.form-feedback.error {
  display: block;
  background-color: #fef2f2;
  color: #991b1b;
  border: 1px solid #fca5a5;
}

/* 11. PIE DE PÁGINA (FOOTER) */
footer {
  background-color: var(--dark);
  color: #94a3b8;
  padding: 70px 0 30px 0;
  border-top: 5px solid var(--primary);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.6fr 0.6fr 0.8fr;
  gap: 40px;
  margin-bottom: 50px;
}

.footer-brand .logo img {
  height: 95px;
  margin-bottom: 20px;
}

.footer-brand p {
  font-size: 0.875rem;
  line-height: 1.6;
}

.footer-title {
  color: var(--white);
  font-size: 1.1rem;
  margin-bottom: 24px;
  position: relative;
  padding-bottom: 8px;
}

.footer-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background-color: var(--secondary);
  border-radius: 2px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  font-size: 0.875rem;
}

.footer-links a:hover {
  color: var(--white);
  transform: translateX(4px);
}

.footer-contact-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  font-size: 0.85rem;
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.footer-contact-item i {
  color: var(--secondary);
  margin-top: 3px;
}

.footer-contact-item a:hover {
  color: var(--white);
}

.footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
  font-size: 0.8rem;
}

.footer-bottom p {
  margin-bottom: 0;
}

/* 12. CHATBOT FLOATING WIDGET */
.chatbot-widget {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 999;
  font-family: var(--font-body);
}

/* Botón flotante */
.chatbot-trigger {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-round);
  background: linear-gradient(135deg, #25d366, #128c7e); /* Colores WhatsApp */
  color: var(--white);
  box-shadow: 0 10px 25px rgba(37, 211, 102, 0.3);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  transition: var(--transition);
  position: relative;
}

.chatbot-trigger:hover {
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 12px 30px rgba(37, 211, 102, 0.4);
}

/* Anillos de pulso */
.chatbot-trigger::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: var(--radius-round);
  border: 2px solid #25d366;
  animation: pulse-ring 2s cubic-bezier(0.215, 0.610, 0.355, 1) infinite;
  opacity: 0;
}

.chatbot-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: var(--accent-orange);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: var(--radius-round);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
  border: 2px solid var(--white);
}

/* Caja de Chat */
.chatbot-box {
  position: absolute;
  bottom: 80px;
  right: 0;
  width: 380px;
  height: 520px;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  transform: translateY(20px) scale(0.95);
  pointer-events: none;
  transition: var(--transition);
}

.chatbot-widget.active .chatbot-box {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

/* Encabezado del Chat */
.chat-header {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: var(--white);
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.chat-header-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.chat-avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-round);
  background-color: rgba(255,255,255,0.15);
  border: 2px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: var(--white);
  position: relative;
}

.chat-avatar::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 10px;
  height: 10px;
  background-color: var(--accent);
  border-radius: var(--radius-round);
  border: 2px solid var(--primary);
}

.chat-status h4 {
  color: var(--white);
  font-size: 0.95rem;
  margin-bottom: 2px;
}

.chat-status p {
  font-size: 0.725rem;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 4px;
}

.chat-status p i {
  color: var(--accent);
}

.chat-close {
  background: transparent;
  color: rgba(255, 255, 255, 0.75);
  font-size: 1.25rem;
  cursor: pointer;
  transition: var(--transition);
}

.chat-close:hover {
  color: var(--white);
}

/* Historial de Mensajes */
.chat-body {
  flex-grow: 1;
  padding: 20px;
  overflow-y: auto;
  background-color: #f1f5f9;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.chat-msg {
  max-width: 80%;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  line-height: 1.4;
  word-wrap: break-word;
}

.chat-msg.bot {
  background-color: var(--white);
  color: var(--dark);
  align-self: flex-start;
  border-top-left-radius: 4px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.chat-msg.user {
  background-color: var(--secondary);
  color: var(--white);
  align-self: flex-end;
  border-top-right-radius: 4px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.chat-time {
  display: block;
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-top: 4px;
  text-align: right;
}

.chat-msg.user .chat-time {
  color: rgba(255, 255, 255, 0.75);
}

/* Indicador de Escritura */
.chat-typing {
  display: flex;
  align-self: flex-start;
  background-color: var(--white);
  padding: 12px 20px;
  border-radius: var(--radius-md);
  border-top-left-radius: 4px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.02);
  gap: 4px;
}

.chat-typing span {
  width: 6px;
  height: 6px;
  background-color: var(--text-muted);
  border-radius: var(--radius-round);
  animation: typing-bounce 1.4s infinite ease-in-out both;
}

.chat-typing span:nth-child(1) { animation-delay: -0.32s; }
.chat-typing span:nth-child(2) { animation-delay: -0.16s; }

/* Opciones de Respuesta Rápida (Quick Replies) */
.chat-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.chat-opt-btn {
  background-color: var(--white);
  border: 1px solid var(--secondary);
  color: var(--secondary);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.825rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-opt-btn:hover {
  background-color: var(--secondary);
  color: var(--white);
  transform: translateX(4px);
}

.chat-opt-btn i {
  font-size: 0.95rem;
}

/* Inputs de Envío */
.chat-footer {
  padding: 15px;
  border-top: 1px solid var(--border-color);
  background-color: var(--white);
  display: flex;
  gap: 10px;
  align-items: center;
}

.chat-input-wrapper {
  flex-grow: 1;
  position: relative;
}

.chat-input {
  width: 100%;
  padding: 10px 15px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-round);
  font-size: 0.875rem;
  background-color: var(--light);
  color: var(--dark);
  transition: var(--transition);
}

.chat-input:focus {
  border-color: var(--secondary);
  background-color: var(--white);
}

.chat-send-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-round);
  background-color: var(--secondary);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.1rem;
  transition: var(--transition);
}

.chat-send-btn:hover {
  background-color: var(--primary);
  transform: scale(1.05);
}

.chat-send-btn:disabled {
  background-color: var(--border-color);
  color: var(--text-muted);
  cursor: not-allowed;
  transform: none;
}

/* 13.5 SECCIÓN NUESTROS CLIENTES */
.clients-logo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 20px;
  align-items: center;
  justify-items: center;
  margin-top: 40px;
}

.client-logo-card {
  background-color: var(--white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 15px;
  height: 90px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.client-logo-card img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.65;
  transition: var(--transition);
}

.client-logo-card:hover {
  transform: translateY(-3px);
  border-color: var(--secondary);
  box-shadow: var(--shadow-md);
}

.client-logo-card:hover img {
  filter: grayscale(0%);
  opacity: 1;
}

/* 13. ANIMACIONES */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes pulse-ring {
  0% {
    transform: scale(0.95);
    opacity: 0.8;
  }
  50% {
    opacity: 0.4;
  }
  100% {
    transform: scale(1.3);
    opacity: 0;
  }
}

@keyframes typing-bounce {
  0%, 80%, 100% { transform: scale(0); }
  40% { transform: scale(1); }
}

/* 14. RESPONSIVIDAD (MEDIA QUERIES) */

@media (max-width: 1024px) {
  .hero-title {
    font-size: 2.5rem;
  }
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .about-image-wrapper {
    min-height: 250px;
    height: 320px;
    max-width: 550px;
    margin: 0 auto;
  }
  .contact-grid {
    gap: 40px;
  }
}

@media (max-width: 768px) {
  /* Cabecera y Menú Móvil */
  .menu-toggle {
    display: block;
  }
  
  .nav-menu {
    position: fixed;
    top: 140px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 140px);
    background-color: var(--white);
    flex-direction: column;
    padding: 40px 24px;
    gap: 24px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
    transition: var(--transition);
    align-items: flex-start;
  }
  
  .nav-menu.active {
    left: 0;
  }
  
  header.scrolled .nav-menu {
    top: 90px;
    height: calc(100vh - 90px);
  }
  
  .nav-cta {
    width: 100%;
  }
  
  .nav-cta .btn {
    width: 100%;
  }
  
  /* Hero */
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 40px;
  }
  .hero-badge {
    justify-content: center;
  }
  .hero-desc {
    margin: 0 auto 30px auto;
  }
  .hero-ctas {
    justify-content: center;
  }
  .hero-card {
    margin: 0 auto;
  }
  
  /* Secciones generales */
  .about-grid, .contact-grid {
    grid-template-columns: 1fr;
  }
  
  .about-pillars {
    margin-top: 30px;
  }
  
  /* Metodología */
  .steps-container {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .steps-container::before {
    display: none; /* Ocultar conectores horizontales en móvil */
  }
  
  /* Formulario */
  .form-group-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
  
  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  
  /* Chatbot */
  .chatbot-widget {
    bottom: 20px;
    right: 20px;
  }
  
  .chatbot-box {
    width: calc(100vw - 40px);
    right: 0;
    height: 480px;
  }
}

@media (max-width: 480px) {
  .top-bar-contact {
    justify-content: center;
  }
  .top-bar-socials {
    display: none;
  }
  
  .footer-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
  
  .modal-header {
    padding: 25px 25px 15px 25px;
  }
  
  .modal-body {
    padding: 20px 25px 25px 25px;
  }
  
  .modal-footer {
    padding: 15px 25px;
  }
}
