html {
  scroll-behavior: smooth;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--paper, #ECEAE1);
  color: var(--graphite, #1B1B18);
  line-height: 1.6;
}

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== HEADER BARRA SUPERIOR CUSTOM ===== */
.nav-bar-custom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  /* Sin wrap, entre 860px y ~1230px los tres grupos no caben en una línea y la
     página desbordaba en horizontal. Por encima de ~1230px no cambia nada. */
  flex-wrap: wrap;
  row-gap: 12px;
  width: 100%;
  padding: 15px 5%;
  background: var(--white, #FBFAF6);
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-grupo-izq {
  display: flex;
  align-items: center;
  gap: 30px;
}

.logo-daka {
  height: 55px;
  width: auto;
}

.nav-titulo {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: 28px;
  font-weight: 900;
  color: var(--ink, #1E1054);
  letter-spacing: 0.05em;
}

.nav-links {
  display: flex;
  gap: 24px;
  align-items: center;
  margin-left: 6vw;
}

.nav-links a {
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink, #1E1054);
  transition: color 0.3s ease;
}

.nav-links a:hover {
  color: var(--orange, #E2571C);
}

.nav-grupo-der {
  display: flex;
  align-items: center;
  gap: 24px;
}

.logo-actega {
  height: 40px;
  width: auto;
}

.btn-regresar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--steel, #2E5C8C);
  color: var(--ink, #1E1054);
  text-decoration: none;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  font-weight: 600;
  border-radius: 4px;
  transition: all 0.25s ease;
}

.btn-regresar:hover {
  background: var(--steel, #2E5C8C);
  color: var(--white, #FBFAF6);
}

.btn-regresar svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

@media (max-width: 860px) {
  .nav-bar-custom {
    flex-direction: column;
    justify-content: center;
    gap: 15px;
  }
  /* Mismo tratamiento que ya aplicaba especiales.css a esta misma cabecera:
     los dos grupos también deben apilarse, si no desbordan por debajo de 414px. */
  .nav-grupo-izq {
    flex-direction: column;
    text-align: center;
  }
  .nav-grupo-der {
    flex-direction: column;
    gap: 15px;
  }
  .nav-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-left: 0;
    margin-top: 10px;
    text-align: center;
  }
}

/* ===== CENEFA PRINCIPAL HERO (HERO INTACTO) ===== */
.hero-soluciones {
  width: 100%;
  border-bottom: 4px solid var(--steel, #2E5C8C);
}

.hero-soluciones-split {
  display: flex;
  align-items: stretch;
  width: 100%;
  min-height: 380px;
  background-color: var(--ink, #1E1054);
  overflow: hidden;
}

.hero-img-izq {
  width: 50%;
  position: relative;
}

.hero-img-izq img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-img-izq::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 35%;
  height: 100%;
  background: linear-gradient(to right, transparent, var(--ink, #1E1054));
  z-index: 2;
}

.hero-texto-der {
  width: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px 5%;
  text-align: left;
}

.hero-texto-der .hero-tag {
  /* Antes var(--steel): azul acero sobre el azul DAKA daba 2,4:1, muy por debajo
     del 4,5:1 de WCAG AA. Se unifica con el naranja que ya usan los rótulos
     equivalentes de index.html, actega.html y flexografia.html (4,46:1). */
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--orange, #E2571C);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 8px;
}

.hero-texto-der h1 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: 44px;
  font-weight: 900;
  color: var(--white, #FBFAF6);
  margin-bottom: 12px;
  line-height: 1.05;
}

.hero-texto-der p {
  font-size: 17px;
  color: var(--white, #FBFAF6);
  line-height: 1.6;
}

@media (max-width: 860px) {
  .hero-soluciones-split {
    flex-direction: column;
  }
  .hero-img-izq {
    width: 100%;
    min-height: 250px;
  }
  .hero-texto-der {
    width: 100%;
    padding: 40px 20px;
  }
}

/* ===== BANNER PANORÁMICO FULL WIDTH ===== */
.banner-full-width {
  width: 100%;
  height: 65vh;
  min-height: 450px;
  overflow: hidden;
  margin: 0 !important;
  padding: 0 !important;
  display: flex;
  border: none;
}

.banner-full-width img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  margin: 0 !important;
  padding: 0 !important;
}

@media (max-width: 860px) {
  .banner-full-width {
    height: 300px;
    min-height: auto;
  }
}

/* ===== MÓDULOS DE CONTENIDO ===== */
.modulo-seccion {
  padding: 80px 0;
  border-bottom: 1px solid var(--line, #C6C2AE);
}

.modulo-seccion:nth-child(even) {
  background: var(--paper-2, #DFDCCC);
}

.sec-head-modulo {
  margin-bottom: 44px;
  text-align: center;
}

.sec-subtitulo-tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--steel, #2E5C8C);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
}

.sec-titulo-modulo {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: 42px;
  font-weight: 900;
  color: var(--ink, #1E1054);
  line-height: 1.1;
  text-transform: uppercase;
}

/* Layout 2 Columnas (Módulos 1 y 4) */
.modulo-dos-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.caja-texto-estatica {
  background: var(--white, #FBFAF6);
  border-radius: 12px;
  padding: 40px;
  box-shadow: 0 10px 30px rgba(30, 16, 84, 0.06);
  border-left: 5px solid var(--orange, #E2571C);
  border-top: 1px solid var(--line, #C6C2AE);
}

.caja-texto-estatica h3 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: 32px;
  font-weight: 900;
  color: var(--ink, #1E1054);
  margin-bottom: 16px;
  line-height: 1.1;
}

.caja-texto-estatica p {
  font-size: 15.5px;
  color: #3A3A34;
  line-height: 1.65;
  margin-bottom: 16px;
}

.caja-texto-estatica p:last-child {
  margin-bottom: 0;
}

/* Carrusel Interactivo de Fotografías (Solo imágenes) */
.carrusel-contenedor {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(30, 16, 84, 0.14);
  height: 380px;
  width: 100%;
  background: var(--ink, #1E1054);
}

.carrusel-track {
  display: flex;
  height: 100%;
  transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
  will-change: transform;
}

.carrusel-slide {
  flex: 0 0 100%;
  min-width: 100%;
  height: 100%;
  position: relative;
}

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

/* Botones de navegación del carrusel */
.carrusel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(30, 16, 84, 0.75);
  color: var(--white, #FBFAF6);
  border: 1px solid rgba(255, 255, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
  backdrop-filter: blur(4px);
}

.carrusel-btn:hover {
  background: var(--orange, #E2571C);
  border-color: var(--orange, #E2571C);
  transform: translateY(-50%) scale(1.08);
}

.carrusel-btn svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.carrusel-prev {
  left: 16px;
}

.carrusel-next {
  right: 16px;
}

.carrusel-puntos {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.carrusel-punto {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.carrusel-punto.activo {
  background: var(--orange, #E2571C);
  width: 24px;
  border-radius: 6px;
}

/* Layout Grid para Módulos 2, 3 y 5 */
.grid-tres-tarjetas {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  width: 100%;
}

.grid-dos-tarjetas {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
  width: 100%;
}

.tarjeta-modulo {
  background: var(--white, #FBFAF6);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(30, 16, 84, 0.06);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
  border: 1px solid var(--line, #C6C2AE);
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

.tarjeta-modulo:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(30, 16, 84, 0.15);
  border-color: var(--orange, #E2571C);
}

.tarjeta-img-box {
  width: 100%;
  height: 220px;
  overflow: hidden;
  position: relative;
  background: var(--paper-2, #DFDCCC);
}

.tarjeta-img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.tarjeta-modulo:hover .tarjeta-img-box img {
  transform: scale(1.08);
}

.tarjeta-body {
  padding: 28px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.tarjeta-tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--steel, #2E5C8C);
  text-transform: uppercase;
  margin-bottom: 8px;
  font-weight: 600;
}

.tarjeta-body h3 {
  font-family: 'Big Shoulders Display', sans-serif;
  font-size: 24px;
  font-weight: 800;
  color: var(--ink, #1E1054);
  margin-bottom: 10px;
  line-height: 1.15;
}

.tarjeta-body p {
  font-size: 14.5px;
  color: #444;
  line-height: 1.6;
}

/* ===== RESPONSIVO MÓDULOS ===== */
@media (max-width: 992px) {
  .modulo-dos-col {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .grid-tres-tarjetas {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .sec-titulo-modulo {
    font-size: 32px;
  }
  .grid-tres-tarjetas,
  .grid-dos-tarjetas {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .carrusel-contenedor {
    height: 280px;
  }
  .caja-texto-estatica {
    padding: 28px 20px;
  }
}

/* ===== FOOTER INTACTO ===== */
footer {
  background: var(--ink, #1E1054);
  color: var(--paper-2, #DFDCCC);
  text-align: center;
  padding: 32px 0;
  font-size: 13px;
  border-top: 1px solid var(--line, #C6C2AE);
}