*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #111;
  background: #f3f3f7;
}

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

.hero {
  position: relative;
  min-height: 80vh;
  color: #fff;
  overflow: hidden;
}

.hero__gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #ff8d3f, #ff4081);
  background-size: 300% 300%;
  animation: gradientShift 12s ease-in-out infinite;
  z-index: -2;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, rgba(255,255,255,0.15), transparent 60%);
  z-index: -1;
}

.hero__inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 1.5rem 1.5rem 4rem;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4rem;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.nav__logo img {
    width: 300px !important;
    height: auto !important;
}


.nav__links {
  list-style: none;
  display: flex;
  gap: 1.4rem;
  font-size: 0.95rem;
}

.nav__links a {
  position: relative;
}

.nav__links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.2rem;
  width: 0;
  height: 2px;
  background-color: #fff;
  transition: width 0.18s ease;
}

.nav__links a:hover::after {
  width: 100%;
}

.hero__content {
  max-width: 640px;
  padding-bottom: 2rem;
}

.hero__content h1 {
  font-size: clamp(2.1rem, 3vw + 1rem, 3rem);
  margin-bottom: 1rem;
}

.hero__content p {
  font-size: 1.05rem;
  line-height: 1.6;
  margin-bottom: 1.8rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.6rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
}

.btn--primary {
  background: #111;
  color: #fff;
  box-shadow: 0 12px 32px rgba(0,0,0,0.4);
}

.btn--primary:hover {
  box-shadow: 0 14px 40px rgba(0,0,0,0.5);
  transform: translateY(-1px);
}

.btn--ghost {
  background: transparent;
  border-color: rgba(255,255,255,0.9);
  color: #fff;
}

.btn--ghost:hover {
  background: rgba(255,255,255,0.13);
}

/* SECTIONS */

.section {
  padding: 4rem 1.5rem;
}

.section__header {
  max-width: 900px;
  margin: 0 auto 2.5rem;
  text-align: center;
}

.section__header h2 {
  font-size: 2rem;
  margin-bottom: 0.6rem;
}

.section__header p {
  color: #555;
}

/* UNIDADES */

.section--unidades {
  max-width: 1120px;
  margin: 0 auto;
}

.unidades {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.7rem;
}

.unidad {
  border-radius: 24px;
  padding: 1.5rem;
  color: #111;
  background: #fff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(15,23,42,0.08);
}

.unidad__titulo {
  margin-bottom: 0.8rem;
}

.unidad__tag {
  display: inline-block;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.unidad__intro {
  font-size: 0.96rem;
  margin-bottom: 0.8rem;
}

.unidad ul {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.9rem;
}

.unidad li {
  margin-bottom: 0.35rem;
}

/* Colores por unidad */
.unidad--n1 { background: #ffefe4; }
.unidad--n1 .unidad__tag { color: #c85410; }

.unidad--n2 { background: #ffe5f1; }
.unidad--n2 .unidad__tag { color: #c71c6f; }

.unidad--n3 { background: #fff9d8; }
.unidad--n3 .unidad__tag { color: #b58a00; }

.unidad--n4 { background: #e1fff7; }
.unidad--n4 .unidad__tag { color: #007f68; }

.unidad--n5 { background: #f1f2ff; }
.unidad--n5 .unidad__tag { color: #27286b; }

/* EQUIPO */

.section--equipo {
  background: #111827;
  color: #f9fafb;
}

.section--equipo .section__header p {
  color: #d1d5db;
}

.equipo {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.8rem;
}

.persona {
  background: #020617;
  border-radius: 20px;
  padding: 1.6rem;
  box-shadow: 0 18px 40px rgba(0,0,0,0.55);
}

.persona h3 {
  margin-bottom: 0.3rem;
}

.persona__rol {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #a5b4fc;
  margin-bottom: 0.9rem;
}

.persona__desc {
  font-size: 0.92rem;
  color: #e5e7eb;
  margin-bottom: 0.7rem;
}

/* CONTACTO */

.section--contacto {
  background: #0b0b11;
  color: #f3f4f6;
}

.contacto {
  max-width: 900px;
  margin: 0 auto;
}

.contacto p {
  color: #e5e7eb;
}

.contacto__dato {
  margin-top: 0.7rem;
}

/* WHATSAPP FLOAT */

.whatsapp-float {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background-color: #25D366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 25px rgba(0,0,0,0.35);
  z-index: 50;
}

.whatsapp-float span {
  font-size: 32px;
}

/* FOOTER */

.footer {
  padding: 1.6rem 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: #6b7280;
  background: #020617;
}

/* ANIMACIONES */

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* RESPONSIVE */

@media (max-width: 768px) {
  .nav__links {
    display: none;
  }
  .hero__inner {
    padding-top: 1.2rem;
  }
  .hero__content {
    margin-top: 2rem;
  }
}


/* AJUSTE FINAL CRISIS EN BLOQUE COMPLETO */
.crisis-horizontal__inner {
  max-width: 1120px;
  margin: 0 auto;
  display: block !important;
}

.crisis-horizontal p {
  text-align: justify;
}

.crisis-horizontal ul {
  margin-top: 1rem;
}


.hero-layout { display:flex; justify-content:space-between; align-items:center; gap:2rem; }

.hero-icons--side { display:flex; flex-direction: row; align-items:center; gap:24px; opacity:0.2; }

.hero-icons--side img {
  width: 96px;
  height: auto;
}

@media (max-width: 992px) {
  .hero-layout { display:flex; justify-content:space-between; align-items:center; gap:2rem; }
  .hero-icons--side { display:flex; flex-direction: row; align-items:center; gap:24px; opacity:0.2; }
}

@media (max-width: 640px) {
  .hero-icons--side { display:flex; flex-direction: row; align-items:center; gap:24px; opacity:0.2; }
}


/* Logo 100% bigger */
.nav__logo img {
    width: 300px !important;
    height: auto !important;
}


/* Icons aligned right */
.hero-icons {
    position: absolute;
    right: 60px;
    top: 220px;
    display: flex;
    flex-direction: column;
    gap: 22px;
    opacity: 0.22;
}

.icon-svg { 
    font-size: 46px; 
}

/* Text justification inside blocks */
.unidad__body p, 
.unidad__body ul, 
.unidad-crisis p {
    text-align: justify;
}


/* EQUIPO: foto circular y header */
.persona__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-direction: row-reverse;
  gap: 0.9rem;
  margin-bottom: 0.9rem;
}

.persona__foto {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  overflow: hidden;
  flex-shrink: 0;
  background: #020617;
  box-shadow: 0 4px 12px rgba(0,0,0,0.45);
}

.persona__foto img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.persona__titles h3 {
  margin: 0 0 0.15rem 0;
}

.persona__titles .persona__rol {
  margin: 0;
}

/* CLIENTES CAROUSEL */
.section--clientes {
  background: transparent;
  padding: 3.5rem 1.5rem;
}

.clientes-track {
  display: flex;
  gap: 3rem;
  align-items: center;
  animation: scrollClientes 25s linear infinite;
}

.clientes-track img {
  max-height: 60px;
  width: auto;
  filter: grayscale(100%);
  opacity: 0.65;
}

.clientes-track img:hover {
  filter: grayscale(0%);
  opacity: 1;
  transform: scale(1.05);
}

.clientes-wrapper {
  overflow: hidden;
  max-width: 1120px;
  margin: 0 auto;
}

@keyframes scrollClientes {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}


/* NORMALIZACIÓN LOGOS CLIENTES */
.clientes-track img {
  height: 56px;
  max-width: 180px;
  object-fit: contain;
  background: transparent;
  padding: 0;
}


/* AJUSTE LOGO HERO */
.nav {
  margin-bottom: 1.5rem;
}

.hero__content {
  margin-top: -0.5rem;
}


/* COMUNICACIÓN & CRISIS */
.comunicacion-crisis {
  max-width: 900px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
  text-align: center;
}

.comunicacion-crisis p {
  margin-top: 1.2rem;
  line-height: 1.7;
}


/* LOGO A10 MÁS PEGADO AL TEXTO */
.nav {
  margin-bottom: 0.8rem;
}

.hero__content {
  margin-top: -1rem;
}


/* PAUSA CAROUSEL AL HOVER */


/* MICROAJUSTES TIPOGRÁFICOS */
.section__header h2 {
  letter-spacing: -0.02em;
}

.section__header p {
  font-size: 0.95rem;
}

.persona h3 {
  letter-spacing: -0.01em;
}

.persona__desc {
  line-height: 1.65;
}

.hero__content h1 {
  letter-spacing: -0.03em;
}


/* HEADER ESPACIADO IGUAL A CARRUSEL */
.section__header--tight {
  margin-bottom: 1.2rem;
}

/* AJUSTE TEXTO EQUIPO ENFOCADO */
.section--unidades .section__header {
  margin-top: 0;
}


/* RESTAURAR FONDO EQUIPO NÚCLEO */
.section--equipo {
  background: #111827;
  color: #f9fafb;
}
.section--equipo .section__header p {
  color: #d1d5db;
}


/* AJUSTE FINO CARRUSEL Y TEXTOS */
.section--clientes {
  padding-top: 2.2rem;
  padding-bottom: 2.2rem;
}

.section--clientes .section__header {
  margin-bottom: 1.4rem;
}

.section--clientes + .section--unidades .section__header {
  margin-top: 1.4rem;
}

.clientes-wrapper {
  display: flex;
  justify-content: center;
}

.clientes-track {
  justify-content: center;
}


/* NORMALIZAR RITMO VERTICAL CARRUSEL */
.section--clientes {
  padding: 2.5rem 1.5rem;
}

.section--clientes .section__header {
  margin: 0 0 1.5rem 0;
}

.section--clientes .section__header p {
  margin: 0;
}

.clientes-wrapper {
  margin: 0;
}

.section--clientes + .section--unidades {
  padding-top: 2.5rem;
}

.section--unidades .section__header {
  margin: 0 0 2rem 0;
}

.section--unidades .section__header p {
  margin: 0;
}


/* FIX DESALINEO HORIZONTAL CARRUSEL */
.section--clientes {
  max-width: 1120px;
  margin: 0 auto;
}

.clientes-wrapper {
  width: 100%;
  overflow: hidden;
}

.clientes-track {
  display: flex;
  align-items: center;
  gap: 3rem;
  /* NO justify-content aquí para evitar corrimientos */
}

.section--clientes .section__header {
  text-align: center;
}


/* === RITMO VERTICAL DETERMINÍSTICO (NO RELATIVO) === */
:root {
  --rythm-small: 1.25rem;
  --rythm-medium: 2.25rem;
}

/* Texto superior carrusel */
.section--clientes .section__header {
  margin: 0 0 var(--rythm-small) 0;
  text-align: center;
}

/* Carrusel */
.section--clientes .clientes-wrapper {
  margin: 0 0 var(--rythm-small) 0;
}

/* Texto inferior (Equipo enfocado) */
.section--unidades .section__header {
  margin: 0 0 var(--rythm-medium) 0;
  text-align: center;
}

/* Neutralizar márgenes heredados */
.section--clientes p,
.section--unidades p {
  margin: 0;
}

/* ===== CARRUSEL CLIENTES – EJE VISUAL FIJO (FINAL) ===== */

.section--clientes .section__header {
  margin: 0 0 1.5rem 0;
  text-align: center;
}

.clientes-wrapper {
  height: 104px;      /* eje visual fijo */
  display: flex;
  align-items: center;            /* centra verticalmente */
  margin: 1.5rem auto 1.5rem;     /* ritmo arriba / abajo */
  overflow: hidden;
}

.clientes-track {
  display: flex;
  align-items: center;
  animation: scrollClientes 22s linear infinite;
}

.cliente-logo {
  flex: 0 0 180px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cliente-logo img {
  max-height: 56px;
  max-width: 160px;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.65;
}

@media (max-width: 768px) {
  .clientes-wrapper {
    height: 88px;                 /* eje más compacto en móvil */
  }
  .clientes-track {
    animation-duration: 11s;      /* más rápido en móvil */
  }
}
/* === CORRECCIÓN EJE HORIZONTAL TEXTOS DESALINEADOS === */

/* Experiencia en distintos rubros */
.section--clientes .section__header,
.section--clientes .section__header p {
  max-width: 1120px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  transform: translateX(-1px); /* ← ajuste fino (~8 espacios) */
}

/* Textos de equipo */
.section--unidades .section__header,
.section--equipo .section__header {
  max-width: 1120px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  transform: translateX(-1px); /* ← mismo eje */
}
.nav__logo {
  padding-top: 2rem;
}
.nav__links {
  margin-top: -3rem;
}
/* ACERCAR UNIDADES AL CARRUSEL */
.section--clientes + .section--unidades {
  margin-top: -6rem;
}
/* MÁS ESPACIO ENTRE TEXTO Y BLOQUES DE UNIDADES */
.section--unidades .section__header {
  margin-bottom: 4rem;
}
.clientes-track {
  animation: scrollClientes 30s linear infinite;
  display: flex;
  width: max-content;
}
.clientes-wrapper {
  overflow: hidden;
}

.clientes-track {
  display: flex;
  width: max-content;
  animation: scrollClientes 30s linear infinite;
}
