/* ==========================================================================
   SMG Comercial — sitio corporativo
   Estilo "claro y aireado": blanco dominante, tipografía azul grande,
   tarjetas redondeadas con sombras suaves, rojo solo en CTAs.
   Paleta y tipografía de marca según propuesta v1.1.
   ========================================================================== */

:root {
  --navy-deep: #14203C;
  --navy: #1C2E55;
  --red: #C8352E;
  --red-light: #E15B52;
  --paper: #F5F7FA;
  --fog: #E9EEF6;
  --steel: #56617A;
  --ink: #17223B;
  --line: #DFE5EE;
  --white: #FFFFFF;

  --font-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Source Sans 3", "Segoe UI", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;

  --container: 1180px;
  --radius: 18px;
  --radius-lg: 28px;

  --shadow-soft: 0 1px 2px rgba(20, 32, 60, .05), 0 12px 32px rgba(20, 32, 60, .07);
  --shadow-lift: 0 2px 6px rgba(20, 32, 60, .06), 0 22px 48px rgba(20, 32, 60, .12);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.65;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--navy);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; }

a { color: var(--red); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- utilidades tipográficas ---------- */

/* ---------- marca de tres barras ----------
   El mismo gesto del logo, antecediendo a los rótulos pequeños de cada
   bloque. Se dibuja con un degradado repetido y un sesgo de 13°, no con
   una imagen, y usa currentColor: así hereda el color del rótulo — rojo
   sobre fondo claro, azul claro sobre el panel navy.
   -------------------------------------------------------------------------- */

.eyebrow::before,
.product-block .p-eyebrow::before,
.quality-card .q-num::before,
.location-card .l-country::before,
.standard .s-tag::before,
.value-item .v-num::before {
  content: "";
  display: inline-block;
  vertical-align: -1px;
  background: repeating-linear-gradient(
    to right,
    currentColor 0 4px,
    transparent 4px 6px
  );
  transform: skewX(-13deg);
  width: 16px;
  height: 11px;
  margin-right: 11px;
}

/* Los rótulos de tarjeta son un punto más chicos que los de sección:
   la marca baja en la misma proporción para no pesar de más. */
.product-block .p-eyebrow::before,
.quality-card .q-num::before,
.location-card .l-country::before,
.standard .s-tag::before,
.value-item .v-num::before {
  width: 13px;
  height: 9px;
  margin-right: 9px;
  background: repeating-linear-gradient(
    to right,
    currentColor 0 3.2px,
    transparent 3.2px 5px
  );
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--red);
  display: block;
  margin-bottom: 16px;
}

.lead {
  font-size: 20px;
  color: var(--steel);
  max-width: 62ch;
}

/* ---------- botones ---------- */

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 16px;
  line-height: 1;
  padding: 17px 32px;
  border-radius: 999px;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease,
              transform .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary:hover { box-shadow: 0 8px 20px rgba(200, 53, 46, .3); }

.btn-primary {
  background: var(--red);
  color: #fff;
}
.btn-primary:hover { background: #A82A24; }

.btn-ghost {
  border-color: rgba(255,255,255,.7);
  color: #fff;
}
.btn-ghost:hover { border-color: #fff; background: rgba(255,255,255,.08); }

.btn-outline-navy {
  border-color: var(--navy);
  color: var(--navy);
}
.btn-outline-navy:hover { background: var(--navy); color: #fff; }

.btn:focus-visible,
a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 2px;
}

/* ---------- logo ---------- */

.logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}
.logo img {
  height: 52px;
  width: auto;
  display: block;
}
.site-header .logo img { height: 72px; }

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: box-shadow .25s ease;
}
.site-header.scrolled { box-shadow: 0 4px 24px rgba(20, 32, 60, .08); }

.header-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 18px 24px;
  max-width: var(--container);
  margin: 0 auto;
}

.main-nav {
  display: flex;
  gap: 28px;
  margin-left: 8px;
}

.main-nav a {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 16px;
  color: var(--ink);
  text-decoration: none;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color .2s ease, border-bottom-color .25s ease;
}
.main-nav a:hover { color: var(--navy); border-bottom-color: var(--red); }
.main-nav a[aria-current="page"] {
  color: var(--navy);
  font-weight: 600;
  border-bottom-color: var(--red);
}

/* En escritorio el contacto vive en el botón rojo; el enlace solo aparece
   dentro del menú móvil, donde el botón se oculta. */
.main-nav .nav-contact { display: none; }

.header-contact {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 20px;
}

.header-contact .btn { padding: 13px 26px; font-size: 15px; }

/* selector de idioma ES | EN */
.lang-switch {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.08em;
}
.lang-switch span { color: var(--line); }
.lang-switch a {
  color: var(--steel);
  text-decoration: none;
  padding: 4px 1px;
  border-bottom: 2px solid transparent;
  transition: color .2s ease, border-bottom-color .25s ease;
}
.lang-switch a:hover { color: var(--navy); }
.lang-switch a[aria-current="true"] {
  color: var(--navy);
  font-weight: 500;
  border-bottom-color: var(--red);
}

/* En escritorio el menú va centrado: logo a la izquierda, menú al centro y
   «Contáctenos» a la derecha. Las columnas 1fr iguales mantienen el menú en
   el centro exacto aunque el logo y el botón midan distinto. */
@media (min-width: 1021px) {
  .header-inner {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
  }
  .header-inner .logo { justify-self: start; }
  .main-nav { margin-left: 0; justify-self: center; }
  .header-contact { margin-left: 0; justify-self: end; }
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 9px 12px;
  cursor: pointer;
  margin-left: auto;
}
.nav-toggle .bar {
  display: block;
  width: 22px; height: 2px;
  background: var(--navy);
  margin: 5px 0;
}

/* ---------- hero claro (inicio) ---------- */

.hero-light {
  background: var(--white);
  padding: 92px 0 72px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}
.hero-light h1 {
  font-size: clamp(38px, 5vw, 62px);
  font-weight: 700;
  letter-spacing: -0.022em;
  max-width: 16ch;
}
.hero-light .hero-sub {
  margin-top: 24px;
  font-size: 20px;
  color: var(--steel);
  max-width: 52ch;
}
.hero-light .hero-ctas {
  display: flex;
  gap: 16px;
  margin-top: 38px;
  flex-wrap: wrap;
}
.hero-media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lift);
}
.hero-media img {
  width: 100%;
  height: 100%;
  min-height: 540px;
  object-fit: cover;
}

/* ---------- encabezado de páginas internas ---------- */

.page-head {
  background: var(--white);
  padding: 84px 0 0;
}
.page-head h1 {
  font-size: clamp(34px, 4.6vw, 54px);
  font-weight: 700;
  letter-spacing: -0.02em;
  max-width: 22ch;
}
.page-head .hero-sub {
  margin-top: 20px;
  font-size: 20px;
  color: var(--steel);
  max-width: 58ch;
}
.page-banner {
  margin-top: 52px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.page-banner img {
  width: 100%;
  height: clamp(260px, 40vw, 430px);
  object-fit: cover;
}

/* ---------- franja de cifras ---------- */

.stats-strip {
  background: var(--white);
  padding: 40px 0 8px;
}
.stats-grid {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 36px;
}
.stats-grid.three { grid-template-columns: repeat(3, 1fr); }
.stat {
  padding: 26px 0 30px;
  border-top: 2px solid var(--line);
}
.stat .stat-v {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(32px, 3.6vw, 46px);
  letter-spacing: -0.02em;
  color: var(--navy);
  font-variant-numeric: tabular-nums;
}
.stat .stat-k {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--steel);
  margin-top: 8px;
}

/* ---------- secciones ---------- */

.section { padding: 108px 0; }
.section.tinted { background: var(--paper); }
.section.white { background: var(--white); }

.section-head { max-width: 740px; margin-bottom: 56px; }
.section-head h2 { font-size: clamp(29px, 3.8vw, 42px); }
.section-head .lead { margin-top: 18px; }

/* ---------- bloque evolución (media row) ---------- */

.media-row {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 64px;
  align-items: center;
}
.media-row.reverse { grid-template-columns: 1fr 1.05fr; }
.media-row .media-img {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.media-row .media-img img {
  width: 100%;
  height: 100%;
  min-height: 400px;
  object-fit: cover;
}
.media-row .media-img.is-diagram { background: var(--paper); box-shadow: none; border: 1px solid var(--line); }
.media-row .media-img.is-diagram img { object-fit: contain; padding: 26px; }
.media-row h2 { font-size: clamp(27px, 3.4vw, 38px); }
.media-row .media-text p { margin-top: 18px; color: var(--steel); }
.media-row .media-text .btn { margin-top: 30px; }

/* ---------- tarjetas de industria / soluciones ---------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.card-grid.three { grid-template-columns: repeat(3, 1fr); }

.industry-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-soft);
  transition: box-shadow .2s ease, transform .2s ease;
}
.industry-card:hover {
  box-shadow: var(--shadow-lift);
  transform: translateY(-4px);
}
.industry-card .card-img { height: 200px; overflow: hidden; }
.industry-card .card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .45s ease;
}
.industry-card:hover .card-img img { transform: scale(1.045); }
.industry-card .card-body { padding: 24px 24px 26px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.industry-card h3 { font-size: 19px; font-weight: 600; }
.industry-card p { font-size: 15.5px; color: var(--steel); flex: 1; }
.industry-card .card-link {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  color: var(--red);
}

/* ---------- industrias que atendemos ---------- */

.sector-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.sector-grid.three { grid-template-columns: repeat(3, 1fr); }
.sector {
  background: var(--paper);
  border-radius: var(--radius);
  padding: 30px 14px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  transition: box-shadow .2s ease, transform .2s ease, background-color .2s ease;
}
.sector:hover {
  transform: translateY(-4px);
  background: var(--white);
  box-shadow: var(--shadow-lift);
}
.sector svg {
  width: 38px;
  height: 38px;
  stroke: var(--navy);
  stroke-width: 1.7;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.sector span {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15.5px;
  line-height: 1.3;
  color: var(--navy);
}

/* ---------- por qué SMG (propuestas de valor) ---------- */

.value-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.value-item {
  background: var(--paper);
  border-radius: var(--radius);
  padding: 32px 30px 34px;
}
.value-item .v-num {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--red);
  display: block;
  margin-bottom: 14px;
}
.value-item h3 { font-size: 19px; }
.value-item p { font-size: 16px; color: var(--steel); margin-top: 10px; }

/* ---------- banda de estándares (panel navy redondeado) ---------- */

.standards { padding: 0; }
.standards .container {
  background: var(--navy);
  border-radius: var(--radius-lg);
  padding: 80px 72px 72px;
  color: #fff;
}
.standards .eyebrow { color: var(--red-light); }
.standards h2 { color: #fff; font-size: clamp(27px, 3.5vw, 38px); }
.standards .lead { color: #C4CEE2; }
.standards .section-head { margin-bottom: 48px; }
.standards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.standard {
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .06);
  padding: 28px 26px 30px;
}
.standard .s-tag {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #8FA3CC;
  display: block;
  margin-bottom: 12px;
}
.standard h3 { color: #fff; font-size: 18px; }
.standard p { color: #B7C2DA; font-size: 15.5px; margin-top: 8px; }
.standards .standards-cta { margin-top: 44px; }

/* ---------- presencia regional ---------- */

.locations-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.location-card {
  background: var(--paper);
  border-radius: var(--radius);
  padding: 36px 38px;
}
.location-card .l-country {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--red);
  display: block;
  margin-bottom: 10px;
}
.location-card h3 { font-size: 22px; }
.location-card p { color: var(--steel); font-size: 16.5px; margin-top: 10px; max-width: 46ch; }
.location-card .l-phone {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 16px;
  color: var(--navy);
  text-decoration: none;
  margin-top: 18px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
}
.location-card .l-phone:hover { border-bottom-color: var(--red); }

/* ---------- banda CTA (panel navy redondeado) ---------- */

.cta-band {
  background: transparent;
  padding: 0 0 108px;
}
.cta-band .cta-inner {
  background: var(--navy-deep);
  border-radius: var(--radius-lg);
  padding: 64px 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.cta-band h2 { color: #fff; font-size: clamp(24px, 3vw, 32px); max-width: 24ch; }
.cta-band p { color: #C4CEE2; margin-top: 10px; max-width: 52ch; }
.cta-band .cta-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- timeline ---------- */

/* Línea de tiempo horizontal. Cada hito lleva su propio tramo de línea
   (border-top) y no hay gap entre columnas, así la línea es continua y
   también funciona dentro del carrusel con scroll de pantallas angostas. */
.timeline, .steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  padding-top: 14px;
}
.steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.timeline .t-item, .steps .step {
  position: relative;
  border-top: 2px solid var(--line);
  padding: 34px 28px 0 0;
}
/* El hito es también la marca de tres barras. Van dos capas: ::before es
   el bloque blanco que corta la línea y ::after dibuja las barras. */
.timeline .t-item::before, .steps .step::before {
  content: "";
  position: absolute;
  left: -4px;
  top: -12px;
  width: 24px;
  height: 21px;
  background: var(--white);
}
.timeline .t-item::after, .steps .step::after {
  content: "";
  position: absolute;
  left: 0;
  top: -7px;
  width: 16px;
  height: 11px;
  background: repeating-linear-gradient(
    to right,
    var(--red) 0 4px,
    transparent 4px 6px
  );
  transform: skewX(-13deg);
}
.timeline .t-year, .steps .step-n {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--red);
  text-transform: uppercase;
}
.timeline h3, .steps h3 { font-size: 19px; margin-top: 6px; }
.timeline p, .steps p { color: var(--steel); font-size: 16px; margin-top: 8px; }

/* ---------- bloques de infraestructura ---------- */

.infra-row.intro-row { padding-top: 0; }
.infra-row.intro-row h2 {
  font-size: clamp(26px, 3.4vw, 34px);
  margin-top: 4px;
}
.infra-row.intro-row .lead { margin-top: 14px; }

.infra-row {
  display: grid;
  grid-template-columns: 480px 1fr;
  gap: 48px;
  align-items: center;
  padding: 48px 0;
  border-top: 1px solid var(--line);
}
.infra-row:first-of-type { border-top: none; }
.infra-row.reverse { grid-template-columns: 1fr 480px; }
.infra-row .infra-img {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.infra-row .infra-img img { width: 100%; height: 340px; object-fit: cover; }
/* Los esquemas y diagramas se muestran completos, no recortados. */
.infra-row .infra-img.is-diagram { background: var(--paper); box-shadow: none; border: 1px solid var(--line); }
.infra-row .infra-img.is-diagram img { object-fit: contain; padding: 18px; }
.infra-row h3 { font-size: 24px; }
.infra-row .infra-text p { color: var(--steel); margin-top: 14px; max-width: 56ch; }

.spec-chips { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }
.chip {
  font-family: var(--font-mono);
  font-size: 13px;
  background: var(--paper);
  color: var(--navy);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 15px;
  white-space: nowrap;
}
.chip .was {
  color: var(--steel);
  text-decoration: line-through;
  text-decoration-color: rgba(86,97,122,.55);
  margin-right: 6px;
}
.chip strong { font-weight: 600; }

/* ---------- lista de productos (soluciones) ---------- */

.product-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.product-block {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  padding: 36px 38px;
}
.product-block h3 { font-size: 21px; }
.product-block .p-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--red);
  display: block;
  margin-bottom: 10px;
}
.product-block ul {
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.product-block li {
  padding-left: 22px;
  position: relative;
  color: var(--steel);
  font-size: 16.5px;
}
.product-block li::before {
  content: "";
  position: absolute;
  left: 0; top: 9px;
  width: 8px; height: 8px;
  background: var(--red);
  transform: skewX(-18deg);
}
.product-block .block-link {
  display: inline-block;
  margin-top: 20px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  color: var(--red);
  text-decoration: none;
}
.product-block .block-link:hover { text-decoration: underline; }

/* ---------- proceso I+D ---------- */

/* Las etapas usan el mismo diseño horizontal que la línea de tiempo
   (ver «timeline»); aquí solo queda lo propio del rótulo «Etapa N». */
.step .step-n { white-space: nowrap; }

/* ---------- calidad ---------- */

.quality-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.quality-card {
  background: var(--paper);
  border-radius: var(--radius);
  padding: 32px 30px 34px;
}
/* Con cinco tarjetas, las dos de la última fila se reparten el ancho
   en lugar de dejar un hueco a la derecha. */
@media (min-width: 861px) {
  .quality-grid { grid-template-columns: repeat(6, 1fr); }
  .quality-card { grid-column: span 2; }
  .quality-card:nth-child(4):nth-last-child(2),
  .quality-card:nth-child(5):nth-last-child(1) { grid-column: span 3; }
}
.quality-card h3 { font-size: 19px; }
.quality-card p { font-size: 16px; color: var(--steel); margin-top: 10px; }
.quality-card .q-num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--red);
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 12px;
}

/* ---------- contacto ---------- */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 56px;
  align-items: start;
}

.contact-form {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  padding: 44px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  color: var(--navy);
  margin-bottom: 6px;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 16.5px;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 13px 16px;
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid var(--navy);
  outline-offset: 0;
  border-color: var(--navy);
  background: var(--white);
}
.field textarea { resize: vertical; min-height: 130px; }
.form-note { font-size: 14.5px; color: var(--steel); margin-top: 14px; }
.form-success {
  display: none;
  background: var(--fog);
  border-radius: 12px;
  padding: 16px 18px;
  margin-top: 18px;
  color: var(--navy);
  font-weight: 600;
}
.form-error {
  display: none;
  background: #FDECEC;
  border-radius: 12px;
  padding: 16px 18px;
  margin-top: 18px;
  color: #8A1C1C;
  font-weight: 600;
}
.form-error a { color: inherit; }
.contact-form button[disabled] { opacity: .6; cursor: progress; }
/* Campo trampa contra robots: fuera de la vista y del teclado. */
.field-trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.contact-card {
  background: var(--paper);
  border-radius: var(--radius);
  padding: 32px 34px;
  margin-bottom: 20px;
}
.contact-card h3 { font-size: 18px; }
.contact-card .c-country {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--red);
  display: block;
  margin-bottom: 8px;
}
.contact-card p { color: var(--steel); font-size: 16px; margin-top: 6px; }
.contact-card .c-phone {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 17px;
  color: var(--navy);
  text-decoration: none;
  margin-top: 10px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
}
.contact-card .c-phone:hover { border-bottom-color: var(--red); }

/* ---------- footer ---------- */

.site-footer {
  background: var(--navy-deep);
  color: #B7C2DA;
  margin-top: 0;
}
.footer-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 76px 24px 0;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.1fr;
  gap: 44px;
}
.site-footer .logo img { height: 58px; }
.site-footer p { font-size: 16px; margin-top: 16px; max-width: 40ch; }
.site-footer .f-social {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  color: #B7C2DA;
  font-size: 16px;
  text-decoration: none;
}
.site-footer .f-social:hover { color: #fff; }
.site-footer .f-social svg { flex: none; }
.site-footer h4 {
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.site-footer ul a { color: #B7C2DA; text-decoration: none; font-size: 16px; }
.site-footer ul a:hover { color: #fff; }
.site-footer .f-phone { font-family: var(--font-mono); font-size: 15px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12);
  margin-top: 60px;
}
.footer-bottom .container {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 22px;
  padding-bottom: 22px;
  font-size: 14px;
  color: #8E9CBC;
}

/* ---------- movimiento sutil ---------- */

@keyframes hero-rise {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}
.hero-light .eyebrow,
.hero-light h1,
.hero-light .hero-sub,
.hero-light .hero-ctas,
.hero-light .hero-media,
.page-head .eyebrow,
.page-head h1,
.page-head .hero-sub,
.page-banner {
  animation: hero-rise .6s ease-out backwards;
}
.hero-light h1, .page-head h1 { animation-delay: .08s; }
.hero-light .hero-sub, .page-head .hero-sub { animation-delay: .16s; }
.hero-light .hero-ctas { animation-delay: .24s; }
.hero-light .hero-media, .page-banner { animation-delay: .2s; }

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .55s ease-out, transform .55s ease-out;
  transition-delay: var(--reveal-delay, 0s);
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ---------- responsive ---------- */

@media (max-width: 1020px) {
  .card-grid, .card-grid.three { grid-template-columns: repeat(2, 1fr); }
  .card-grid.three .industry-card:last-child { grid-column: 1 / -1; }
  .infra-row, .infra-row.reverse { grid-template-columns: 1fr; gap: 24px; }
  .infra-row .infra-img img { height: 280px; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .sector-grid { grid-template-columns: repeat(2, 1fr); }
  .sector-grid.three { grid-template-columns: repeat(3, 1fr); }
  .value-grid, .standards-grid { grid-template-columns: repeat(2, 1fr); }
  .timeline, .steps {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: 280px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 16px;
  }
  .timeline .t-item, .steps .step { scroll-snap-align: start; }
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .hero-media img { min-height: 320px; }
  .standards .container { padding: 56px 40px 52px; }
}

/* Con cinco secciones el menú ya no cabe junto al logo y al botón por debajo
   de ~1020px, así que desde ahí pasa a la hamburguesa. */
@media (max-width: 1020px) {
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    gap: 0;
    padding: 8px 0;
    margin: 0;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 14px 24px; border-bottom: none; font-size: 17px; }
  /* Logo a la izquierda y, a la derecha, ES | EN, Contáctenos y la hamburguesa. */
  .header-inner { gap: 18px; }
  .nav-toggle { display: block; margin-left: 0; order: 2; }
  .header-contact { margin-left: auto; order: 1; }
}

@media (max-width: 860px) {
  /* En el teléfono el botón rojo se oculta y Contáctenos pasa al menú. */
  .header-contact .btn { display: none; }
  .main-nav .nav-contact { display: block; color: var(--red); font-weight: 600; }
  .site-header .logo img { height: 58px; }

  .hero-light { padding: 56px 0 48px; }
  .hero-media img { min-height: 240px; }
  .page-head { padding: 56px 0 0; }
  .page-banner { margin-top: 36px; }

  .stats-strip { padding: 28px 0 0; }
  .stats-grid, .stats-grid.three { grid-template-columns: 1fr 1fr; gap: 20px; }
  .stats-grid.three .stat:last-child { grid-column: 1 / -1; }
  .stat { padding: 18px 0 22px; }

  .section { padding: 68px 0; }
  .media-row, .media-row.reverse { grid-template-columns: 1fr; gap: 28px; }
  .media-row .media-img img { min-height: 260px; }
  .product-cols { grid-template-columns: 1fr; }
  .quality-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; gap: 0; }
  .card-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; gap: 36px; }
  .sector-grid, .sector-grid.three { grid-template-columns: repeat(2, 1fr); }
  .sector-grid.three .sector:last-child { grid-column: 1 / -1; }
  .timeline, .steps { grid-auto-columns: 78%; }
  .value-grid, .standards-grid { grid-template-columns: 1fr; }
  .locations-grid { grid-template-columns: 1fr; }
  .standards .container { border-radius: var(--radius); padding: 44px 26px 42px; }
  .cta-band { padding: 0 0 68px; }
  .cta-band .cta-inner { padding: 40px 30px; border-radius: var(--radius); }
  .contact-form { padding: 30px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .industry-card, .btn, .industry-card .card-img img, .main-nav a, .site-header,
  .sector { transition: none; }
  .hero-light .eyebrow, .hero-light h1, .hero-light .hero-sub, .hero-light .hero-ctas,
  .hero-light .hero-media, .page-head .eyebrow, .page-head h1, .page-head .hero-sub,
  .page-banner { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn:hover { transform: none; }
  .industry-card:hover .card-img img { transform: none; }
}
