/* =========================================================
   BASE · reset, elementos, tipografía y utilidades
   ========================================================= */
/* Fuente display de marca: solo se descarga en las páginas que la usan (H1 de industria).
   Origen: font.ttf del sitio WordPress anterior de lynn.cx ("Eziear", © 2011 DMF).
   PENDIENTE: confirmar con el cliente la licencia de uso web de esta fuente. */
@font-face {
  font-family: "Eziear";
  src: url("../fonts/eziear.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body.is-locked { overflow: hidden; }

img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
h1, h2, h3, h4, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
main:focus { outline: none; }

h1, h2, h3, h4 {
  line-height: var(--lh-tight);
  letter-spacing: -0.025em;
  font-weight: 800;
  color: var(--navy-900);
  text-wrap: balance;
}
/* Escala única (tokens.css): cada nivel de título mide lo mismo en todo el sitio */
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
h4 { font-size: var(--fs-base); }
p { text-wrap: pretty; }

:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; border-radius: 6px; }
.on-dark :focus-visible { outline-color: #FFB59C; }

/* ---------- Tipografía utilitaria ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: var(--s-2);
  font-size: var(--fs-xs); font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--brand-700);
}
.eyebrow::before { content: ""; width: 24px; height: 2px; border-radius: 2px; background: var(--brand); }
.on-dark .eyebrow { color: var(--brand-300); }
.lead { font-size: var(--fs-base); color: var(--ink-600); line-height: var(--lh-body); }
.text-accent { color: var(--brand-700); }
.on-dark .text-accent { color: var(--brand-300); }

/* ---------- Utilidades ---------- */
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.nowrap { white-space: nowrap; }   /* nombres con guion que no deben cortarse (e-Contact) */

.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: var(--z-skip);
  background: var(--navy-900); color: #fff; padding: 12px 20px; border-radius: var(--r-md);
  font-weight: 600; transition: top var(--t) var(--ease);
}
.skip-link:focus { top: 16px; }

/* ---------- Animación de entrada (activada por reveal.js) ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(var(--reveal-shift));
  transition: opacity var(--t-reveal) var(--ease), transform var(--t-reveal) var(--ease);
}
.js .reveal.is-visible { opacity: 1; transform: none; }
.js .reveal.d-1 { transition-delay: 60ms; }
.js .reveal.d-2 { transition-delay: 120ms; }
.js .reveal.d-3 { transition-delay: 180ms; }
.js .reveal.d-4 { transition-delay: 240ms; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal, .js .reveal.d-1, .js .reveal.d-2, .js .reveal.d-3, .js .reveal.d-4 { opacity: 1; transform: none; transition-delay: 0ms; }
}
