/* ==========================================================================
   ÁREA DIGITAL LAB — hoja de estilos
   Concepto: papel y tinta, rejilla editorial amplia. El rojo del logotipo se
   reserva para acentos pequeños: la tilde como marcador e iconos puntuales.
   Los proyectos aportan el color con la atmósfera de cada marca cliente.
   ========================================================================== */

:root {
  /* Paleta (extraída del logotipo) */
  --paper: #FEFEFB;      /* fondo del logo */
  --paper-2: #F4F3EE;    /* superficies secundarias */
  --paper-3: #EAE8E1;    /* detalles y formas de fondo */
  --ink: #171717;        /* negro del logo */
  --red: #EA2630;        /* rojo del logo: solo acentos e iconos */
  --text: #2A2A27;
  --muted: #64635C;
  --line: #E1DFD7;
  --line-strong: #C9C6BC;
  --night: #141414;
  --night-2: #222221;
  --on-night: #F4F3EE;
  --on-night-muted: #A8A69E;

  /* Tipografía */
  --f-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Figtree", "Helvetica Neue", Arial, sans-serif;

  --fs-xs: .75rem;
  --fs-sm: .9rem;
  --fs-md: 1.0625rem;
  --fs-lg: 1.25rem;
  --fs-h3: clamp(1.15rem, 1.4vw, 1.35rem);
  --fs-h2: clamp(2rem, 4.2vw, 3.35rem);
  --fs-h1: clamp(2.4rem, 4.9vw, 4.4rem);

  /* Espaciado y medidas */
  --maxw: 1240px;
  --gutter-l: max(20px, env(safe-area-inset-left, 0px));
  --gutter-r: max(20px, env(safe-area-inset-right, 0px));
  --header-h: 84px;
  --radius-lg: 28px;
  --radius-md: 18px;
  --ease: cubic-bezier(.2, .7, .2, 1);

  color-scheme: light;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--f-body);
  font-size: var(--fs-md);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body::before {
  content: ""; position: fixed; inset: 0 0 auto; z-index: 60;
  height: env(safe-area-inset-top, 0px); background: var(--paper);
}
body.menu-open { overflow: hidden; }
[hidden] { display: none !important; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 {
  font-family: var(--f-display);
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
  font-stretch: 112%;
}
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button { font: inherit; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }
.section-contact :focus-visible, .pack-featured :focus-visible, .project-moirai :focus-visible { outline-color: var(--on-night); }
.contact-form :focus-visible { outline-color: var(--ink); }

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-left: var(--gutter-l);
  padding-right: var(--gutter-r);
}
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  background: var(--ink); color: var(--paper); padding: .7rem 1rem; border-radius: 10px;
  text-decoration: none; font-weight: 600;
}
.skip-link:focus { top: calc(12px + env(safe-area-inset-top, 0px)); }

/* Marcador: la tilde del logo, en tinta */
.kicker {
  display: inline-flex; align-items: center; gap: .7rem;
  font-family: var(--f-display); font-stretch: 125%;
  font-size: var(--fs-xs); font-weight: 600;
  letter-spacing: .22em; text-transform: uppercase;
  color: var(--ink);
}
.kicker::before, .dash {
  content: ""; display: inline-block; flex: none;
  width: 22px; height: 8px; background: var(--red);
  clip-path: polygon(34% 0, 100% 0, 66% 100%, 0 100%);
}
.kicker-light { color: var(--on-night); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  min-height: 48px; padding: .8rem 1.35rem;
  border-radius: 999px; border: 1.5px solid transparent;
  font-family: var(--f-body); font-size: .98rem; font-weight: 600; line-height: 1.1;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease);
}
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: #000; transform: translateY(-2px); }
.btn-line { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-line:hover { background: var(--ink); color: var(--paper); }
.btn-paper { background: var(--paper); color: var(--ink); }
.btn-paper:hover { background: #fff; transform: translateY(-2px); }
.btn-block { width: 100%; }
.btn-arrow { display: inline-block; transition: transform .25s var(--ease); }
.btn:hover .btn-arrow { transform: translateX(4px); }
a[target="_blank"].btn:hover .btn-arrow { transform: translate(3px, -3px); }

.text-link {
  display: inline-flex; gap: .4rem; align-items: center;
  font-weight: 600; color: var(--ink); text-decoration: underline;
  text-underline-offset: 5px; text-decoration-thickness: 1.5px;
}
.text-link span { transition: transform .25s var(--ease); }
.text-link:hover span { transform: translateX(4px); }
.inline-link {
  background: none; border: 0; padding: 0; color: inherit; cursor: pointer;
  text-decoration: underline; text-underline-offset: 3px;
}

/* ---------- Cabecera ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: rgba(254, 254, 251, .92);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), box-shadow .3s var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.header-inner {
  height: var(--header-h);
  display: flex; align-items: center; gap: 2rem;
}
.brand { display: block; flex: none; border-radius: 6px; }
.brand img { height: 56px; width: auto; }
.main-nav { margin-left: auto; }
.main-nav ul { display: flex; gap: 1.6rem; }
.main-nav a {
  position: relative; display: inline-block; padding-block: .4rem;
  text-decoration: none; font-size: .95rem; font-weight: 500; color: var(--text);
}
.main-nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px;
  background: var(--ink); transform: scaleX(0); transform-origin: left;
  transition: transform .3s var(--ease);
}
.main-nav a:hover::after, .main-nav a[aria-current="page"]::after { transform: scaleX(1); }
.main-nav a[aria-current="page"] { color: var(--ink); }
.header-cta { flex: none; }

.menu-toggle {
  display: none; align-items: center; gap: .6rem;
  margin-left: auto; min-height: 44px; padding: .5rem .9rem;
  background: transparent; border: 1.5px solid var(--ink); border-radius: 999px;
  color: var(--ink); font-weight: 600; font-size: .92rem; cursor: pointer;
}
.menu-toggle-icon { position: relative; width: 18px; height: 12px; }
.menu-toggle-icon span {
  position: absolute; left: 0; width: 100%; height: 2px; background: currentColor; border-radius: 2px;
  transition: transform .3s var(--ease), top .3s var(--ease);
}
.menu-toggle-icon span:nth-child(1) { top: 0; }
.menu-toggle-icon span:nth-child(2) { top: 5px; width: 70%; left: 30%; background: var(--red); }
.menu-toggle-icon span:nth-child(3) { top: 10px; }
.menu-toggle:hover { background: var(--ink); color: var(--paper); }
.menu-toggle:hover .menu-toggle-icon span:nth-child(2) { background: var(--red); }

/* Panel del menú */
.menu-overlay { position: fixed; inset: 0; z-index: 90; }
.menu-backdrop {
  position: absolute; inset: 0; background: rgba(20, 20, 20, .5);
  opacity: 0; transition: opacity .35s var(--ease);
}
.menu-panel {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: min(440px, 100%);
  background: var(--paper); color: var(--text);
  display: flex; flex-direction: column;
  padding: calc(env(safe-area-inset-top, 0px) + 14px) max(24px, env(safe-area-inset-right, 0px)) calc(env(safe-area-inset-bottom, 0px) + 24px) 24px;
  box-shadow: -30px 0 60px -30px rgba(0, 0, 0, .35);
  transform: translateX(100%); transition: transform .45s var(--ease);
  overflow-y: auto; overscroll-behavior: contain;
}
.menu-overlay.is-open .menu-backdrop { opacity: 1; }
.menu-overlay.is-open .menu-panel { transform: none; }
.menu-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 58px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.menu-panel-head img { height: 44px; width: auto; }
.menu-close {
  display: inline-flex; align-items: center; gap: .5rem; min-height: 44px; padding: .5rem .9rem;
  background: transparent; border: 1.5px solid var(--ink); border-radius: 999px; color: var(--ink);
  font-weight: 600; font-size: .92rem; cursor: pointer; transition: background-color .25s var(--ease), color .25s var(--ease);
}
.menu-close svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.menu-close:hover { background: var(--ink); color: var(--paper); }
.menu-nav { padding-block: 1rem 2rem; }
.menu-nav li { border-bottom: 1px solid var(--line); }
.menu-nav a {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding-block: 1.05rem;
  font-family: var(--f-display); font-stretch: 115%; font-weight: 600;
  font-size: clamp(1.35rem, 5.4vw, 1.6rem); line-height: 1.15; color: var(--ink); text-decoration: none;
}
.menu-nav a span { color: var(--muted); font-family: var(--f-body); font-size: 1.1rem; transition: transform .3s var(--ease), color .3s var(--ease); }
.menu-nav a:hover span, .menu-nav a[aria-current="page"] span { color: var(--red); transform: translateX(4px); }
.menu-nav a[aria-current="page"]::before {
  content: ""; width: 16px; height: 6px; background: var(--red); flex: none; margin-right: -.4rem;
  clip-path: polygon(34% 0, 100% 0, 66% 100%, 0 100%);
}
.menu-nav a[aria-current="page"] { justify-content: flex-start; }
.menu-nav a[aria-current="page"] span { margin-left: auto; }
.menu-panel-foot { margin-top: auto; display: grid; gap: 1.25rem; padding-top: 1rem; }
.menu-contact { display: grid; gap: .3rem; }
.menu-contact a { color: var(--ink); font-weight: 600; text-underline-offset: 4px; overflow-wrap: anywhere; }

/* ---------- Animaciones ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.anim { animation: rise .9s var(--ease) both; animation-delay: calc(var(--d, 0) * 110ms); }
.js .reveal { transform: translateY(22px); transition: transform .9s var(--ease); }
.js .reveal.is-in { transform: none; }

/* ---------- Hero ----------
   Portada de declaración, como las agencias consolidadas (Wieden+Kennedy, &Walsh):
   la marca encabeza la línea superior, el titular ocupa todo el ancho a gran tamaño
   y cierra con la tilde roja del logotipo como punto final. Debajo, los trabajos a
   sangre con el color de cada marca, al estilo de Pentagram o Clay. */
.hero { padding-block: clamp(24px, 3.6vw, 52px) 0; overflow: hidden; }
.hero-statement { display: grid; gap: clamp(22px, 2.6vw, 36px); padding-top: clamp(8px, 2vw, 28px); }
/* Titular corto en mayúsculas, con anchura normal: «destaque» es la palabra que destaca */
.hero h1 {
  font-size: clamp(2.4rem, 5.5vw, 5.4rem); line-height: .96; letter-spacing: -.03em;
  font-weight: 800; font-stretch: 100%; text-transform: uppercase;
}
.h1-soft { color: #8E8C84; }
/* La tilde del logotipo hace de punto final del titular */
.brand-stop {
  display: inline-block; width: .4em; height: .17em; margin-left: .06em;
  background: var(--red); clip-path: polygon(34% 0, 100% 0, 66% 100%, 0 100%);
  transform-origin: 0 100%; animation: stop-in .9s var(--ease) .9s both;
}
@keyframes stop-in { from { transform: scaleX(0); } to { transform: none; } }
.hero-foot {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 1.6rem 3rem;
}
.hero-foot-copy { display: grid; gap: 1.1rem; min-width: 0; }
.hero-lede { font-size: clamp(1.08rem, 1.4vw, 1.25rem); color: var(--muted); max-width: 60ch; }
/* Precios de partida a la vista, como hacen las agencias estadounidenses */
.hero-prices { display: flex; flex-wrap: wrap; gap: .5rem; }
.hero-prices a {
  display: inline-flex; align-items: baseline; gap: .3em; min-height: 40px; padding: .55rem .95rem;
  border: 1px solid var(--line-strong); border-radius: 999px;
  font-size: .9rem; font-weight: 500; color: var(--text); text-decoration: none;
  transition: border-color .25s var(--ease), background-color .25s var(--ease);
}
.hero-prices a span { color: var(--muted); }
.hero-prices a strong { font-family: var(--f-display); font-stretch: 110%; font-weight: 700; color: var(--ink); }
.hero-prices a:hover { border-color: var(--ink); background: var(--paper-2); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; }
.hero-actions .btn { min-height: 56px; padding: 1rem 1.6rem; font-size: 1.02rem; }
/* Botón principal en el rojo de la marca (tono que cumple el contraste con texto blanco) */
.btn-red { background: #D7192A; color: #FFFFFF; }
.btn-red:hover { background: #B8111F; transform: translateY(-2px); }

/* Trabajos a sangre: un panel por marca, con su color y el móvil asomando desde abajo */
.hero-work {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(12px, 1.6vw, 20px);
  margin-top: clamp(32px, 4vw, 56px);
}
.work-tile {
  position: relative; display: block; overflow: hidden; isolation: isolate;
  aspect-ratio: 5 / 4; border-radius: var(--radius-lg);
  text-decoration: none; color: inherit;
}
.work-lumitix { background: #EFE8DD; color: #13204D; }
.work-moirai { background: #151215; color: #F3EDEE; }
.work-meta {
  position: absolute; z-index: 2; left: clamp(20px, 2.4vw, 32px); top: clamp(18px, 2.2vw, 28px);
  display: grid; gap: .1rem; line-height: 1.25;
}
.work-meta { gap: .55rem; }
.work-logo { display: block; height: clamp(18px, 1.9vw, 24px); width: auto; }
.work-logo-moirai { height: clamp(30px, 3.2vw, 40px); margin-block: -6px; }
.work-meta > span { font-size: .92rem; opacity: .75; }
.work-go {
  position: absolute; z-index: 2; right: clamp(20px, 2.4vw, 32px); top: clamp(18px, 2.2vw, 28px);
  min-height: 40px; padding: .5rem 1rem; border-radius: 999px; border: 1px solid currentColor;
  display: inline-flex; align-items: center; gap: .45rem; font-size: .85rem; font-weight: 600; opacity: .7;
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
/* Dos móviles por marca, escalonados y asomando desde abajo */
.work-device { position: absolute; width: 31%; transition: transform .8s var(--ease); }
.wd-back { left: 19%; bottom: -36%; }
.wd-front { left: 50%; bottom: -19%; }
.work-device .phone, .work-device .phone-screen { display: block; }
.work-moirai .phone { --rim: #4A4A4D; box-shadow: 0 0 0 1.5px var(--rim), inset 0 0 0 1px rgba(255, 255, 255, .08), 0 40px 70px -30px rgba(0, 0, 0, .8); }
.work-tile:hover .wd-front { transform: translateY(-14px); }
.work-tile:hover .wd-back { transform: translateY(-7px); }
.work-go span { transition: transform .35s var(--ease); }
.work-tile:hover .work-go { opacity: 1; }
.work-tile:hover .work-go span { transform: translateX(3px); }
.work-tile:focus-visible { outline-offset: 4px; }

@media (max-width: 960px) {
  .hero-foot { grid-template-columns: minmax(0, 1fr); align-items: start; }
}
@media (max-width: 720px) {
  .hero-work { grid-template-columns: minmax(0, 1fr); }
  .work-tile { aspect-ratio: 1 / 1; }
  .work-device { width: 40%; }
  .wd-back { left: 7%; bottom: -46%; }
  .wd-front { left: 51%; bottom: -24%; }
  .h1-br { display: none; }
}
@media (max-width: 560px) {
  .hero-prices { gap: .4rem; }
  .hero-prices a { min-height: 36px; padding: .4rem .75rem; font-size: .8rem; }
}
@media (prefers-reduced-motion: reduce) {
  .brand-stop { animation: none; }
  .work-device, .work-go { transition: none; }
}

/* Mockup de móvil (proporciones de un iPhone actual): marco fino, esquinas
   continuas, Dynamic Island y botones laterales. La barra de estado aloja la
   cámara, así la captura y el nombre de cada marca empiezan justo debajo. */
.phone {
  --rim: #3A3A3C;
  position: relative;
  container-type: inline-size;
  background: #050505;
  padding: 1.7%;
  border-radius: 14.5% / 6.4%;
  box-shadow:
    0 0 0 1.5px var(--rim),
    inset 0 0 0 1px rgba(255, 255, 255, .07),
    0 2px 4px rgba(23, 23, 23, .08),
    0 36px 60px -28px rgba(23, 23, 23, .45);
}
/* botones de volumen (izquierda) y de encendido (derecha) */
.phone::before, .phone::after {
  content: ""; position: absolute; width: 1.1%; border-radius: 2px;
}
.phone::before {
  left: -1.6%; top: 19%; height: 13%;
  background: linear-gradient(var(--rim) 0 44%, transparent 44% 56%, var(--rim) 56% 100%);
}
.phone::after { right: -1.6%; top: 25%; height: 9%; background: var(--rim); }
.phone-screen {
  position: relative; overflow: hidden;
  border-radius: 13.3% / 5.9%;
  background: var(--sb, #FFFFFF);
}
.phone-status {
  position: relative; aspect-ratio: 469 / 64;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 8% 0 10.5%;
  color: var(--sb-ink, #111111);
  font-family: var(--f-body); font-weight: 600; font-size: 4.3cqw; line-height: 1;
}
.phone-status svg { width: 14%; height: auto; }
.phone-status::after {
  content: ""; position: absolute; left: 50%; top: 20%;
  width: 32%; height: 64%; transform: translateX(-50%);
  background: #050505; border-radius: 99px;
}
.phone-screen img { width: 100%; height: auto; display: block; }

/* Cinta de servicios: se desplaza hacia la izquierda como un panel.
   Trazo fino, separadores verticales y la tilde roja como único acento. */
.ticker {
  margin-top: clamp(40px, 6vw, 72px);
  background: var(--ink); color: var(--paper);
  overflow: hidden; position: relative;
}
.ticker-track { display: flex; width: max-content; will-change: transform; }
.ticker.is-css .ticker-track { animation: ticker 38s linear infinite; }
.ticker.is-css:hover .ticker-track, .ticker.is-css:focus-within .ticker-track, .ticker.is-css.is-paused .ticker-track { animation-play-state: paused; }
.ticker-toggle {
  position: absolute; right: 0; top: 0; bottom: 0; z-index: 2;
  display: grid; place-items: center;
  width: 64px; padding: 0 0 0 16px; border: 0; cursor: pointer;
  background: linear-gradient(90deg, rgba(23, 23, 23, 0), var(--ink) 35%);
  color: rgba(254, 254, 251, .75);
}
.ticker-toggle svg { width: 26px; height: 26px; padding: 5px; border: 1px solid rgba(254, 254, 251, .3); border-radius: 50%; fill: currentColor; transition: border-color .25s var(--ease), color .25s var(--ease); }
.ticker-toggle:hover svg, .ticker-toggle:focus-visible svg { border-color: var(--paper); color: var(--paper); }
.ticker-toggle:focus-visible { outline: none; }
.ticker-toggle:focus-visible svg { outline: 2px solid var(--paper); outline-offset: 2px; }
.ticker-toggle .i-play { display: none; }
.ticker-toggle[aria-pressed="true"] .i-play { display: block; }
.ticker-toggle[aria-pressed="true"] .i-pause { display: none; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.ticker-group { display: flex; flex: none; min-width: 100vw; }
.ticker-group li {
  flex: 1 0 auto; display: flex; justify-content: center;
  border-left: 1px solid rgba(254, 254, 251, .16);
}
.ticker a {
  display: inline-flex; align-items: center; gap: .85rem;
  padding: 1.05rem clamp(1.75rem, 3.2vw, 3rem);
  font-family: var(--f-display); font-stretch: 112%; font-weight: 400;
  font-size: clamp(.8rem, 1.05vw, .92rem); letter-spacing: .24em; text-transform: uppercase;
  color: rgba(254, 254, 251, .82); text-decoration: none; white-space: nowrap;
  transition: color .3s var(--ease);
}
.ticker a .dash { width: 16px; height: 4px; transition: transform .3s var(--ease), width .3s var(--ease); }
.ticker a:hover, .ticker a:focus-visible { color: var(--paper); }
.ticker a:hover .dash { width: 22px; }
.ticker a:focus-visible { outline: 1px solid var(--paper); outline-offset: -8px; }

/* ---------- Secciones ---------- */
.section { padding-block: clamp(72px, 10vw, 136px); scroll-margin-top: var(--header-h); }
#inicio { scroll-margin-top: var(--header-h); }
.section-head {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  column-gap: clamp(24px, 5vw, 80px); row-gap: 1.25rem; align-items: end;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.section-head .kicker { grid-column: 1 / -1; }
.section-head h2 { font-size: var(--fs-h2); line-height: 1.06; letter-spacing: -.02em; font-weight: 650; max-width: 18ch; }
.section-intro { color: var(--muted); max-width: 48ch; font-size: 1.08rem; }

/* Servicios */
.services { border-bottom: 1px solid var(--line); }
.service {
  display: grid;
  grid-template-columns: 52px minmax(0, 4fr) minmax(0, 5fr) minmax(0, 3fr);
  gap: 1.25rem clamp(20px, 3vw, 48px);
  align-items: start;
  padding: 2rem 0;
  border-top: 1px solid var(--line);
  transition: background-color .35s var(--ease), padding .35s var(--ease);
}
.service:hover { background: var(--paper-2); padding-inline: 1.25rem; }
.service-icon { width: 40px; height: 40px; color: var(--ink); }
.service-icon svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.service-icon .ac { stroke: var(--red); stroke-width: 1.9; }
.service-icon .ac-fill { fill: var(--red); }
.service { scroll-margin-top: calc(var(--header-h) + 24px); }
.service:target { background: var(--paper-2); padding-inline: 1.25rem; box-shadow: inset 3px 0 0 var(--red); animation: target-in 1.4s var(--ease) both; }
@keyframes target-in { from { background: #FBE4E5; } to { background: var(--paper-2); } }
.service-side { display: grid; gap: .9rem; justify-items: start; align-content: start; }
.text-link-sm { font-size: .9rem; }
.service h3 { font-size: var(--fs-h3); line-height: 1.25; font-weight: 650; padding-top: .35rem; }
.service > p { color: var(--muted); }
.service-tags { display: flex; flex-wrap: wrap; gap: .4rem; padding-top: .2rem; }
.service-tags li {
  font-size: .78rem; font-weight: 500; color: var(--text);
  border: 1px solid var(--line-strong); border-radius: 999px; padding: .25rem .65rem;
}

/* Proyectos */
.section-projects { background: var(--paper-2); }
.project {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(32px, 5vw, 72px); align-items: center;
  padding: clamp(28px, 5vw, 64px);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.project + .project { margin-top: clamp(20px, 3vw, 32px); }
.project-copy { display: grid; gap: 1.25rem; justify-items: start; min-width: 0; }
.project-meta { font-size: var(--fs-xs); letter-spacing: .16em; text-transform: uppercase; font-weight: 600; }
.project-name {
  font-size: clamp(2.6rem, 6vw, 4.6rem); line-height: .95; letter-spacing: -.03em;
  font-weight: 700; font-stretch: 120%; color: inherit;
}
.project-desc { max-width: 46ch; }
.project-points { display: grid; gap: .55rem; padding-block: .25rem .5rem; }
.project-points li { display: grid; grid-template-columns: 18px 1fr; gap: .7rem; align-items: baseline; font-size: .97rem; }
.project-points li::before {
  content: ""; width: 14px; height: 5px; background: currentColor; transform: translateY(-2px);
  clip-path: polygon(34% 0, 100% 0, 66% 100%, 0 100%);
}
.project-media { min-width: 0; }
.device-pair { position: relative; aspect-ratio: 1.08 / 1; max-width: 560px; margin-inline: auto; }
.device-pair .phone { position: absolute; width: 42%; transition: rotate .7s var(--ease), translate .7s var(--ease); }
.device-pair .phone-back { left: 10%; top: 9%; rotate: -4deg; }
.device-pair .phone-front { right: 10%; top: 0; rotate: 2deg; }
.project:hover .phone-back { rotate: -6deg; translate: -8px 6px; }
.project:hover .phone-front { rotate: 1deg; translate: 0 -10px; }

.project-moirai { background: #151215; color: #F3EDEE; }
.project-moirai .project-meta { color: #D9B3B8; }
.project-moirai .project-desc, .project-moirai .project-points { color: #C7BDC0; }
.project-moirai .project-points li::before { background: #D9B3B8; }
.project-moirai .phone { --rim: #4A4A4D; box-shadow: 0 0 0 1.5px var(--rim), inset 0 0 0 1px rgba(255, 255, 255, .08), 0 40px 70px -30px rgba(0, 0, 0, .8); }

.project-lumitix { background: #F4EFE7; color: #13204D; }
.project-lumitix .project-meta { color: #5D6178; }
.project-lumitix .project-desc, .project-lumitix .project-points { color: #3C4363; }
.project-moirai .project-copy { order: 2; }
.project-moirai { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); }

/* Cómo trabajamos */
.steps {
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(20px, 2.4vw, 32px);
  counter-reset: step;
}
.step { display: grid; gap: .8rem; align-content: start; padding-top: 1.4rem; border-top: 1px solid var(--line-strong); position: relative; min-width: 0; }
.step::before {
  content: ""; position: absolute; top: -4px; left: 0; width: 22px; height: 8px; background: var(--red);
  clip-path: polygon(34% 0, 100% 0, 66% 100%, 0 100%);
}
.step-num {
  font-family: var(--f-display); font-stretch: 125%; font-weight: 600;
  font-size: clamp(2rem, 3.2vw, 2.8rem); line-height: 1; color: var(--ink); letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}
.step h3 { font-size: 1.12rem; line-height: 1.3; font-weight: 650; }
.step p { color: var(--muted); font-size: .98rem; }
.steps-note {
  margin-top: clamp(32px, 4vw, 48px); padding: 1.1rem 1.4rem; border-radius: var(--radius-md);
  background: var(--paper-2); color: var(--text); font-size: .97rem; max-width: 72ch;
}

/* Packs */
.section-packs { background: var(--paper-2); }
.packs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2vw, 24px); align-items: stretch; }
.pack {
  display: flex; flex-direction: column; gap: 1rem;
  background: var(--paper); border: 1px solid var(--line);
  border-radius: 24px; padding: clamp(24px, 3vw, 36px);
  transition: transform .45s var(--ease), box-shadow .45s var(--ease);
  min-width: 0;
}
.pack:hover { transform: translateY(-4px); box-shadow: 0 24px 48px -32px rgba(23, 23, 23, .35); }
.pack-for { font-size: var(--fs-xs); font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.pack h3 { font-size: clamp(1.6rem, 2.4vw, 2rem); line-height: 1.05; font-weight: 700; font-stretch: 118%; letter-spacing: -.02em; }
.pack-desc { color: var(--muted); }
.pack-list { display: grid; gap: .65rem; padding-block: .75rem; border-top: 1px solid var(--line); margin-top: .25rem; padding-top: 1.25rem; }
.pack-list li { display: grid; grid-template-columns: 18px 1fr; gap: .7rem; font-size: .97rem; align-items: baseline; }
.pack-list li { grid-template-columns: 20px 1fr; }
.pack-list li::before {
  content: ""; width: 16px; height: 16px; transform: translateY(3px);
  border: 1.5px solid var(--red); border-radius: 3px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 8.5l3 3 6-7' fill='none' stroke='%23EA2630' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px no-repeat;
}
.pack-foot { margin-top: auto; display: grid; gap: 1rem; padding-top: 1rem; }
.pack-price { font-family: var(--f-display); font-stretch: 112%; font-weight: 600; font-size: 1.05rem; color: var(--ink); }
.pack-featured { background: var(--night); border-color: var(--night); color: var(--on-night); }
.pack-featured h3, .pack-featured .pack-price { color: var(--on-night); }
.pack-featured .pack-for, .pack-featured .pack-desc { color: var(--on-night-muted); }
.pack-featured .pack-list { border-top-color: #333331; }
.packs-note { margin-top: clamp(24px, 3vw, 36px); color: var(--text); max-width: 64ch; }

/* Packs con precio (catálogo de servicios): grupos, importe, plazo y resumen */
.pack-tabs { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: clamp(32px, 4vw, 48px); }
.pack-tabs a {
  display: inline-flex; align-items: center; min-height: 44px; padding: .55rem 1.1rem;
  border: 1px solid var(--line-strong); border-radius: 999px;
  font-weight: 600; font-size: .92rem; color: var(--ink); text-decoration: none;
  transition: background-color .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease);
}
.pack-tabs a:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.pack-group { scroll-margin-top: calc(var(--header-h) + 24px); }
.pack-group + .pack-group { margin-top: clamp(56px, 7vw, 96px); }
.pack-group-title {
  display: flex; align-items: center; gap: .9rem; margin-bottom: clamp(20px, 3vw, 32px);
  font-size: .95rem; font-weight: 700; font-stretch: 125%; letter-spacing: .2em; text-transform: uppercase;
}
.pack-group-title::before {
  content: ""; flex: none; width: 28px; height: 10px; background: var(--red);
  clip-path: polygon(34% 0, 100% 0, 66% 100%, 0 100%);
}
.pack-group-title::after { content: ""; flex: 1; height: 1px; background: var(--line-strong); }
.packs-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pack-badge {
  display: inline-block; padding: .35rem .8rem; border-radius: 999px;
  background: var(--red); color: #FFFFFF; font-weight: 700; letter-spacing: .14em;
}
.pack-amount {
  display: flex; align-items: baseline; gap: .3rem; margin: 0;
  font-family: var(--f-display); font-stretch: 112%; font-weight: 800; line-height: 1;
  letter-spacing: -.035em; color: var(--ink); font-variant-numeric: tabular-nums;
}
.pack-num { font-size: clamp(2.9rem, 4.6vw, 3.7rem); }
.pack-cur { font-size: 1.55rem; font-weight: 700; letter-spacing: 0; }
.pack-amount-text .pack-num { font-size: clamp(2.3rem, 3.8vw, 3.1rem); letter-spacing: -.025em; }
.pack-price-block { display: grid; gap: .55rem; }
.pack-term { color: var(--muted); font-size: .95rem; }
.pack-foot .pack-desc { font-size: .95rem; }
.pack-total {
  display: grid; gap: .3rem; padding: 1rem 1.15rem; border-radius: 14px; background: var(--paper-2);
}
.pack-total span { font-size: var(--fs-xs); font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.pack-total strong { font-family: var(--f-display); font-stretch: 112%; font-weight: 700; font-size: 1.1rem; line-height: 1.25; color: var(--ink); }
.pack-featured .pack-amount, .pack-featured .pack-total strong { color: var(--on-night); }
.pack-featured .pack-term, .pack-featured .pack-total span { color: var(--on-night-muted); }
.pack-featured .pack-total { background: #262625; }
.pack-featured .pack-for { line-height: 1; }

/* Agencia */
.about { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(32px, 6vw, 96px); align-items: center; }
.team { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(14px, 2vw, 24px); align-items: start; padding-bottom: 56px; }
.person { margin: 0; display: grid; gap: .9rem; min-width: 0; }
.person-offset { transform: translateY(56px); }
.js .person-offset.reveal { transform: translateY(78px); }
.js .person-offset.reveal.is-in { transform: translateY(56px); }
.person-photo {
  position: relative; overflow: hidden; border-radius: 20px;
  aspect-ratio: 4 / 5; background: var(--paper-2);
}
.person-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.person:hover .person-photo img { transform: scale(1.03); }
.person figcaption { display: grid; gap: .1rem; }
.person figcaption strong { font-family: var(--f-display); font-stretch: 115%; font-weight: 650; font-size: 1.15rem; color: var(--ink); display: inline-flex; align-items: center; gap: .55rem; }
.person figcaption strong::before { content: ""; width: 16px; height: 6px; background: var(--red); clip-path: polygon(34% 0, 100% 0, 66% 100%, 0 100%); }
.person figcaption span { color: var(--muted); font-size: .92rem; padding-left: calc(16px + .55rem); }
.about-copy { display: grid; gap: 1.4rem; min-width: 0; }
.about-copy h2 { font-size: var(--fs-h2); line-height: 1.06; letter-spacing: -.02em; font-weight: 650; }
.about-lede { font-size: 1.15rem; color: var(--text); max-width: 52ch; }
.values { margin: .5rem 0 0; display: grid; }
.values > div { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 1rem; padding-block: 1.1rem; border-top: 1px solid var(--line); }
.values dt { font-family: var(--f-display); font-stretch: 112%; font-weight: 650; color: var(--ink); }
.values dd { margin: 0; color: var(--muted); }

/* Preguntas frecuentes */
.section-faq { border-top: 1px solid var(--line); }
.faq-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.faq-head { grid-template-columns: minmax(0, 1fr); position: sticky; top: calc(var(--header-h) + 32px); margin-bottom: 0; }
.faq { border-top: 1px solid var(--ink); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 1.5rem;
  padding: 1.35rem 0; cursor: pointer; list-style: none;
  font-family: var(--f-display); font-stretch: 108%; font-weight: 600; font-size: 1.12rem; color: var(--ink); line-height: 1.35;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 14px; height: 14px;
  background:
    linear-gradient(currentColor, currentColor) center / 100% 1.75px no-repeat,
    linear-gradient(currentColor, currentColor) center / 1.75px 100% no-repeat;
  transition: transform .35s var(--ease);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: #000; }
.faq-body { padding: 0 2.5rem 1.5rem 0; color: var(--muted); max-width: 64ch; }
.faq details[open] .faq-body { animation: rise .45s var(--ease) both; }
.faq-body a { color: var(--ink); text-underline-offset: 3px; }

/* Contacto */
.section-contact { background: var(--night); color: var(--on-night); }
.contact-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(36px, 6vw, 96px); align-items: start; }
.contact-copy { display: grid; gap: 1.4rem; min-width: 0; }
.contact-copy h1 { color: var(--on-night); font-size: clamp(2.2rem, 4.6vw, 3.8rem); line-height: 1.02; letter-spacing: -.025em; font-weight: 700; font-stretch: 118%; }
.contact-lede { font-size: 1.2rem; color: var(--on-night-muted); max-width: 32ch; }
.contact-mail { display: grid; gap: .6rem; justify-items: start; margin-top: 1rem; padding-top: 1.6rem; border-top: 1px solid #333331; }
.contact-mail-label { font-size: var(--fs-xs); letter-spacing: .16em; text-transform: uppercase; color: var(--on-night-muted); font-weight: 600; }
.contact-mail-link {
  font-family: var(--f-display); font-stretch: 110%; font-weight: 600;
  font-size: clamp(1.25rem, 2.4vw, 1.7rem); color: var(--on-night);
  text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 6px;
  overflow-wrap: anywhere;
}
.contact-mail-link:hover { text-decoration-thickness: 3px; }
.contact-phone { margin-top: 0; }
.copy-btn {
  background: transparent; color: var(--on-night); border: 1px solid #4A4A47; border-radius: 999px;
  padding: .5rem .95rem; font-size: .85rem; font-weight: 600; cursor: pointer; min-height: 40px;
  transition: border-color .25s var(--ease);
}
.copy-btn:hover { border-color: var(--on-night); }

.contact-form {
  background: var(--paper); color: var(--text);
  border-radius: var(--radius-lg); padding: clamp(24px, 4vw, 44px);
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem 1.25rem;
  min-width: 0;
}
.field { display: grid; gap: .45rem; align-content: start; min-width: 0; }
.field-full { grid-column: 1 / -1; }
.field label { font-size: .92rem; font-weight: 600; color: var(--ink); }
.field input[type="text"], .field input[type="email"], .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink);
  background: #FFFFFF; border: 1px solid var(--line-strong); border-radius: 12px;
  padding: .85rem .95rem; min-height: 50px;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.field textarea { resize: vertical; min-height: 140px; line-height: 1.55; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #9D9A90; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(23, 23, 23, .14);
}
.select-wrap { position: relative; }
.select-wrap::after {
  content: ""; position: absolute; right: 1rem; top: 50%; width: 8px; height: 8px;
  border-right: 1.75px solid var(--ink); border-bottom: 1.75px solid var(--ink);
  transform: translateY(-70%) rotate(45deg); pointer-events: none;
}
.field select { appearance: none; -webkit-appearance: none; padding-right: 2.5rem; cursor: pointer; }
.field-hint { font-size: .85rem; color: var(--muted); }
.field-error { font-size: .86rem; font-weight: 600; color: var(--ink); display: none; gap: .45rem; align-items: start; }
.field-error:not(:empty) { display: flex; }
.field-error::before {
  content: "!"; flex: none; display: inline-grid; place-items: center;
  width: 18px; height: 18px; border-radius: 50%; background: var(--ink); color: var(--paper);
  font-size: .72rem; font-weight: 700; margin-top: .1rem;
}
.field [aria-invalid="true"] { border-color: var(--ink); border-width: 2px; background: var(--paper-2); }
.field-check { grid-template-columns: 22px 1fr; column-gap: .75rem; align-items: start; }
.field-check input { width: 20px; height: 20px; margin: .15rem 0 0; accent-color: var(--ink); cursor: pointer; }
.field-check label { font-weight: 500; font-size: .95rem; color: var(--text); }
.field-check .field-error { grid-column: 1 / -1; }
.field-check input[aria-invalid="true"] { outline: 2px solid var(--ink); outline-offset: 2px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; padding-top: .25rem; }
.btn-submit[disabled] { opacity: .6; cursor: progress; }

.form-status:empty { display: none; }
.form-status {
  border-radius: 16px; padding: 1.1rem 1.2rem; border: 1px solid var(--line-strong);
  background: var(--paper-2); color: var(--text); display: grid; gap: .8rem; font-size: .96rem;
}
.form-status:focus { outline: 2px solid var(--ink); outline-offset: 2px; }
.form-status strong { color: var(--ink); font-family: var(--f-display); font-stretch: 108%; font-size: 1.02rem; }
.form-status .status-actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.form-status .btn { min-height: 42px; padding: .6rem 1.05rem; font-size: .9rem; }
.form-status.is-success { border-color: var(--ink); background: #FFFFFF; }

/* Pie */
.site-footer { background: var(--paper); border-top: 1px solid var(--line); padding-block: clamp(48px, 6vw, 72px) 28px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 4fr) minmax(0, 3fr); gap: 2.5rem; align-items: start; }
.footer-brand { display: grid; gap: .45rem; }
.footer-brand p { color: var(--muted); max-width: 32ch; font-size: .95rem; }
/* Firma: el logotipo a todo el ancho cierra cada página, como en los estudios consolidados */
.footer-mark { margin-top: clamp(48px, 7vw, 96px); }
.footer-logo { display: block; width: 100%; height: auto; }
.footer-logo .logo-ink { fill: var(--ink); }
.footer-logo .logo-accent { fill: var(--red); }
.footer-nav ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .55rem 1.5rem; }
.footer-nav a { text-decoration: none; color: var(--text); font-size: .95rem; }
.footer-nav a:hover { text-decoration: underline; text-underline-offset: 4px; }
.footer-contact { display: grid; gap: .45rem; }
.footer-label { font-size: var(--fs-xs); letter-spacing: .16em; text-transform: uppercase; font-weight: 600; color: var(--muted); }
.footer-contact a { color: var(--ink); font-weight: 600; text-underline-offset: 4px; overflow-wrap: anywhere; }
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem;
  margin-top: clamp(28px, 4vw, 48px); padding-top: 1.5rem; border-top: 1px solid var(--line);
  font-size: .88rem; color: var(--muted);
}
.legal-links { display: flex; flex-wrap: wrap; gap: 1.25rem; }
.legal-links .inline-link { color: var(--muted); font-size: .88rem; }
.legal-links .inline-link:hover { color: var(--ink); }

/* Diálogos legales */
.legal-dialog {
  width: min(560px, calc(100% - 32px)); max-height: calc(100% - 48px);
  border: 0; border-radius: 22px; padding: 0;
  background: var(--paper); color: var(--text);
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .5);
}
.legal-dialog::backdrop { background: rgba(20, 20, 20, .55); }
.dialog-inner { padding: clamp(24px, 4vw, 36px); display: grid; gap: 1rem; justify-items: start; }
.dialog-inner h2 { font-size: 1.6rem; font-weight: 700; letter-spacing: -.01em; }
.dialog-inner ul { display: grid; gap: .4rem; padding-left: 1.1rem; list-style: disc; color: var(--muted); }
.pending {
  font-size: var(--fs-xs); font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  border: 1px solid var(--line-strong); border-radius: 999px; padding: .3rem .7rem; color: var(--ink);
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .main-nav { display: none; }
  .menu-toggle { display: inline-flex; }
  .header-cta { margin-left: 0; }
  .header-inner { gap: 1rem; }
  .menu-toggle { order: 3; margin-left: 0; }
  .header-cta { order: 2; margin-left: auto; }
}
@media (max-width: 1024px) {
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 2.5rem; }
  .service { grid-template-columns: 52px minmax(0, 1fr) minmax(0, 1.3fr); }
  .service-side { grid-column: 2 / -1; }
}
@media (max-width: 960px) {
  :root { --header-h: 72px; }
  .brand img { height: 46px; }
  .section-head { grid-template-columns: minmax(0, 1fr); }
  .project, .project-moirai { grid-template-columns: minmax(0, 1fr); }
  .project-moirai .project-copy { order: 0; }
  .packs { grid-template-columns: minmax(0, 1fr); max-width: 560px; }
  .about { grid-template-columns: minmax(0, 1fr); }
  .team { max-width: 620px; }
  .faq-grid { grid-template-columns: minmax(0, 1fr); }
  .faq-head { position: static; }
  .contact-grid { grid-template-columns: minmax(0, 1fr); }
  .footer-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .service { grid-template-columns: 40px minmax(0, 1fr); gap: .75rem 1rem; padding: 1.6rem 0; }
  .service:hover { padding-inline: 0; background: transparent; }
  .service-icon { width: 32px; height: 32px; }
  .service > p, .service-side { grid-column: 1 / -1; }
  .service:target { padding-inline: .9rem; }
  .service h3 { padding-top: .15rem; }
  .steps { grid-template-columns: minmax(0, 1fr); row-gap: 0; }
  .step { grid-template-columns: 64px minmax(0, 1fr); column-gap: 1rem; padding-block: 1.4rem; }
  .step-num { grid-row: 1 / span 2; font-size: 1.9rem; }
  .values > div { grid-template-columns: minmax(0, 1fr); gap: .3rem; }
  .contact-form { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .header-cta { display: none; }
  .menu-toggle { margin-left: auto; }
  .brand img { height: 42px; }
  .hero-actions .btn { width: 100%; }
  .device-pair { aspect-ratio: 1 / 1.05; }
  .device-pair .phone { width: 46%; }
  .device-pair .phone-back { left: 4%; }
  .device-pair .phone-front { right: 4%; }
  .project-copy .btn { width: 100%; }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .footer-bottom { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .anim, .faq details[open] .faq-body, .service:target { animation: none; }
  .js .person-offset.reveal, .js .person-offset.reveal.is-in { transform: translateY(56px); }
  .menu-panel, .menu-backdrop { transition: none; }
  .js .reveal { transform: none; transition: none; }
  .project:hover .phone-back { rotate: -4deg; translate: none; }
  .project:hover .phone-front { rotate: 2deg; translate: none; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}

/* ==========================================================================
   Páginas: cada sección se muestra como una página propia
   ========================================================================== */
.js .page.is-entering { animation: page-in .55s var(--ease) both; }
@keyframes page-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.page-title:focus { outline: none; }


/* Cabecera de página */
.page-head { padding-block: clamp(48px, 7vw, 96px) clamp(36px, 5vw, 64px); border-bottom: 1px solid var(--line); }
.page-head-grid {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  column-gap: clamp(24px, 5vw, 80px); row-gap: 1.25rem; align-items: end;
}
.page-head .crumbs { grid-column: 1 / -1; }
.page-head h1 {
  font-size: clamp(2.3rem, 4.8vw, 4rem); line-height: 1.04; letter-spacing: -.025em;
  font-weight: 700; font-stretch: 112%; max-width: 16ch;
}
.page-intro { color: var(--muted); font-size: 1.1rem; max-width: 46ch; }
.crumbs {
  display: flex; flex-wrap: wrap; align-items: center; gap: .6rem;
  font-size: .78rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted);
}
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.crumbs [aria-current="page"] { color: var(--ink); display: inline-flex; align-items: center; gap: .55rem; }
.crumbs [aria-current="page"]::before { content: ""; width: 16px; height: 6px; background: var(--red); clip-path: polygon(34% 0, 100% 0, 66% 100%, 0 100%); }
.crumbs-light, .crumbs-light a { color: var(--on-night-muted); }
.crumbs-light a:hover, .crumbs-light [aria-current="page"] { color: var(--on-night); }

.section-tight { padding-block: clamp(40px, 6vw, 80px) clamp(64px, 8vw, 112px); }
.section-alt { background: var(--paper-2); }
.section-projects.section-tight, .section-packs.section-tight { background: var(--paper); }
.section-contact { padding-block: clamp(56px, 8vw, 112px); }

/* Inicio: tarjetas de servicios */
.svc-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(12px, 1.6vw, 20px); }
.svc-card {
  height: 100%; display: grid; grid-template-rows: auto auto 1fr auto; gap: .8rem;
  padding: clamp(22px, 2.4vw, 30px);
  border: 1px solid var(--line); border-radius: 22px; background: var(--paper);
  color: inherit; text-decoration: none;
  transition: border-color .35s var(--ease), transform .35s var(--ease), box-shadow .35s var(--ease);
}
.svc-card:hover { border-color: var(--ink); transform: translateY(-4px); box-shadow: 0 24px 40px -32px rgba(23, 23, 23, .45); }
.svc-card .service-icon { width: 36px; height: 36px; }
.svc-card h3 { font-size: 1.2rem; font-weight: 650; line-height: 1.2; }
.svc-card p { color: var(--muted); font-size: .97rem; }
.svc-more { font-weight: 600; font-size: .92rem; color: var(--ink); display: inline-flex; gap: .4rem; padding-top: .4rem; }
.svc-more span { transition: transform .3s var(--ease); }
.svc-card:hover .svc-more span { transform: translateX(4px); }

/* Imagen + texto */
.split { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.split-reverse .photo { order: 2; }
.photo { margin: 0; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 4 / 3; background: var(--paper-3); }
.photo img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.4s var(--ease); }
.photo:hover img { transform: scale(1.025); }
.split-copy { display: grid; gap: 1.3rem; justify-items: start; min-width: 0; }
.split-copy h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); line-height: 1.08; letter-spacing: -.02em; font-weight: 650; }
.split-lede { color: var(--muted); font-size: 1.08rem; max-width: 46ch; }
.check-list { display: grid; gap: .7rem; }
.check-list li { display: grid; grid-template-columns: 20px 1fr; gap: .7rem; align-items: baseline; }
.check-list li::before {
  content: ""; width: 16px; height: 16px; transform: translateY(3px);
  border: 1.5px solid var(--red); border-radius: 3px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 8.5l3 3 6-7' fill='none' stroke='%23EA2630' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px no-repeat;
}
.split-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.5rem; padding-top: .4rem; }

/* Cómo trabajamos: lista vertical en su página */
.steps-list { grid-template-columns: minmax(0, 1fr); gap: 0; }
.steps-list .step {
  grid-template-columns: clamp(72px, 10vw, 140px) minmax(0, 4fr) minmax(0, 6fr);
  column-gap: clamp(20px, 4vw, 56px); align-items: baseline;
  padding-block: clamp(24px, 3vw, 36px);
}
.steps-list .step-num { font-size: clamp(2.4rem, 4.4vw, 3.6rem); font-weight: 500; }
.steps-list .step h3 { font-size: clamp(1.25rem, 2vw, 1.6rem); }
.steps-list .step p { font-size: 1.05rem; max-width: 52ch; }
.steps-list .step:last-child { border-bottom: 1px solid var(--line-strong); }

/* Paginación entre páginas */
.pager { border-top: 1px solid var(--line); }
.pager-inner { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pager-link { display: grid; gap: .35rem; padding-block: clamp(28px, 4vw, 44px); color: inherit; text-decoration: none; }
.pager-next { text-align: right; border-left: 1px solid var(--line); padding-left: 1.5rem; grid-column: 2; }
.pager-prev { padding-right: 1.5rem; }
.pager-label { font-size: .75rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.pager-title {
  font-family: var(--f-display); font-stretch: 115%; font-weight: 650; color: var(--ink);
  font-size: clamp(1.4rem, 3vw, 2.2rem); letter-spacing: -.015em; line-height: 1.1;
  transition: transform .4s var(--ease);
}
.pager-next:hover .pager-title { transform: translateX(-6px); }
.pager-prev:hover .pager-title { transform: translateX(6px); }

/* Banda final de llamada a la acción */
.cta-band { background: var(--ink); color: var(--on-night); }
body[data-page="contacto"] .cta-band { display: none; }
.cta-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 2rem 3rem; padding-block: clamp(48px, 7vw, 88px);
}
.cta-copy { display: grid; gap: 1rem; }
.cta-band h2 { color: var(--on-night); font-size: clamp(1.9rem, 4vw, 3.2rem); line-height: 1.05; letter-spacing: -.02em; font-weight: 700; font-stretch: 115%; max-width: 18ch; }
.cta-actions { display: grid; gap: .9rem; justify-items: start; }
.cta-phone { color: var(--on-night-muted); font-size: .95rem; text-underline-offset: 4px; }
.cta-phone:hover { color: var(--on-night); }

@media (max-width: 1024px) {
  .svc-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .page-head-grid { grid-template-columns: minmax(0, 1fr); }
  .split, .split-reverse { grid-template-columns: minmax(0, 1fr); }
  .split-reverse .photo { order: 0; }
  .steps-list .step { grid-template-columns: 64px minmax(0, 1fr); row-gap: .5rem; }
  .steps-list .step-num { grid-row: 1 / span 2; font-size: 2.2rem; }
  .steps-list .step p { grid-column: 2; }
}
@media (max-width: 560px) {
  .svc-cards { grid-template-columns: minmax(0, 1fr); }
  .pager-next { padding-left: 1rem; }
  .pager-prev { padding-right: 1rem; }
  .cta-actions, .cta-actions .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .js .page.is-entering { animation: none; }
}
.contact-form, #preguntas { scroll-margin-top: calc(var(--header-h) + 24px); }
.split-reverse { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
@media (max-width: 960px) { .split-reverse { grid-template-columns: minmax(0, 1fr); } }

/* Inicio: bloque de contacto al final */
body[data-page="inicio"] .cta-band { display: none; }
.home-contact { background: var(--ink); color: var(--on-night); }
.home-contact-grid {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(32px, 6vw, 96px); align-items: center;
  padding-block: clamp(56px, 8vw, 104px);
}
.home-contact-copy { display: grid; gap: 1.1rem; }
.home-contact-copy h2 {
  color: var(--on-night); font-size: clamp(2rem, 4.2vw, 3.4rem); line-height: 1.04;
  letter-spacing: -.025em; font-weight: 700; font-stretch: 115%;
}
.home-contact-copy p { color: var(--on-night-muted); font-size: 1.1rem; max-width: 40ch; }
.home-contact-list { display: grid; }
.home-contact-list li {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 1rem; row-gap: .35rem;
  padding-block: 1.25rem; border-top: 1px solid #333331;
}
.home-contact-list li .contact-mail-label { grid-column: 1 / -1; }
.home-contact-link {
  font-family: var(--f-display); font-stretch: 110%; font-weight: 600;
  font-size: clamp(1.2rem, 2.2vw, 1.6rem); color: var(--on-night);
  text-decoration: none; overflow-wrap: anywhere;
}
.home-contact-link:hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 1.5px; }
.home-contact-list .home-contact-cta { grid-template-columns: minmax(0, 1fr); padding-top: 1.5rem; }
.home-contact :focus-visible { outline-color: var(--on-night); }
@media (max-width: 960px) {
  .home-contact-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .home-contact-cta .btn { width: 100%; }
}

/* ==========================================================================
   Plugins: Lenis (desplazamiento suave), GSAP ScrollTrigger + SplitText,
   WhatsApp y reserva de llamadas
   ========================================================================== */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: clip; }
.lenis.lenis-smooth iframe { pointer-events: none; }

/* Con GSAP activo, las apariciones las controla ScrollTrigger */
html.fx .reveal, html.fx .reveal.is-in { transform: none; transition: none; }
html.fx .js-split { visibility: visible; }
.split-line { padding-bottom: .04em; }

/* Botón de contorno sobre fondo oscuro */
.btn-line-light { border-color: rgba(254, 254, 251, .55); color: var(--on-night); background: transparent; }
.btn-line-light:hover { border-color: var(--on-night); background: var(--on-night); color: var(--ink); }

.contact-extra { margin-top: 0; }
.contact-extra-actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.home-contact-arrow { color: var(--on-night-muted); font-size: 1.2rem; }
.home-contact-cta { display: flex !important; flex-wrap: wrap; gap: .75rem; }

/* Botón flotante de WhatsApp */
.wa-float {
  position: fixed; z-index: 70;
  right: calc(20px + env(safe-area-inset-right, 0px));
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  display: inline-flex; align-items: center; gap: 0;
  height: 56px; padding: 0 16px; border-radius: 999px;
  background: var(--ink); color: var(--paper); text-decoration: none;
  box-shadow: 0 0 0 1px rgba(254, 254, 251, .12), 0 18px 36px -14px rgba(0, 0, 0, .45);
  transition: gap .35s var(--ease), padding .35s var(--ease), transform .35s var(--ease);
}
.wa-float svg { width: 24px; height: 24px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linejoin: round; }
.wa-float .wa-dot { fill: var(--red); stroke: none; }
.wa-label {
  max-width: 0; overflow: hidden; white-space: nowrap;
  font-weight: 600; font-size: .95rem;
  transition: max-width .4s var(--ease);
}
.wa-float:hover, .wa-float:focus-visible { gap: .6rem; padding-right: 20px; transform: translateY(-2px); }
.wa-float:hover .wa-label, .wa-float:focus-visible .wa-label { max-width: 120px; }
.wa-float:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
body.menu-open .wa-float { opacity: 0; pointer-events: none; }
@media (max-width: 560px) {
  .wa-float { height: 52px; padding: 0 14px; right: calc(14px + env(safe-area-inset-right, 0px)); bottom: calc(14px + env(safe-area-inset-bottom, 0px)); }
}
