/* ==========================================================================
   viacolectiva — landing
   Tipografía de marca: Alte Haas Grotesk (freeware, licencia en assets/fonts)
   ========================================================================== */

@font-face {
  font-family: "Alte Haas Grotesk";
  src: url("../assets/fonts/AlteHaasGroteskRegular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Alte Haas Grotesk";
  src: url("../assets/fonts/AlteHaasGroteskBold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}

/* Registradas para que el cambio de tema entre secciones se anime */
@property --bg { syntax: "<color>"; inherits: true; initial-value: #ffffff; }
@property --fg { syntax: "<color>"; inherits: true; initial-value: #0b0b0b; }

:root {
  /* Marca */
  --ink: #0b0b0b;
  --paper: #ededea;
  --light: #ffffff;  /* fondo de la sección Servicios */
  --c-audio: #2c3e8e;   /* azul  — música & audio   */
  --c-imagen: #8b35a2;  /* violeta — foto & imagen  */
  --c-video: #ec173c;   /* rojo  — video            */
  --c-digital: #c5f82a; /* lima  — productos digitales */

  --bg: var(--light);
  --fg: var(--ink);
  --muted: color-mix(in srgb, var(--fg) 58%, transparent);
  --line: color-mix(in srgb, var(--fg) 22%, transparent);

  --sans: "Alte Haas Grotesk", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --gut: clamp(16px, 2.2vw, 32px);
  --ease: cubic-bezier(.7, 0, .2, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);

  --hero-fs: clamp(44px, min(12.2vw, 21vh), 300px);
}

html[data-theme="lime"] { --bg: var(--c-digital); --fg: var(--ink); }
html[data-theme="dark"] { --bg: var(--ink); --fg: var(--paper); }

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

html {
  background: var(--bg);
  color: var(--fg);
  transition: --bg .8s var(--ease), --fg .8s var(--ease);
  -webkit-text-size-adjust: 100%;
}
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: clip; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

h1, h2, h3, p, ol, ul, dl, dd, figure, fieldset { margin: 0; padding: 0; }
ol, ul { list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; }
svg { display: block; }
::selection { background: var(--c-digital); color: var(--ink); }

.mono {
  font-family: var(--mono);
  font-size: 11.5px;
  line-height: 1.5;
  letter-spacing: .02em;
  text-transform: uppercase;
}
.muted { color: var(--muted); }

.skip {
  position: fixed; left: var(--gut); top: -60px; z-index: 300;
  background: var(--ink); color: var(--paper); padding: 10px 14px;
  font: 500 12px var(--mono); text-transform: uppercase;
}
.skip:focus { top: 12px; }

:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px; }

/* ---------- Isotipo (SVG) ---------- */
.iso { overflow: visible; }
.iso circle, .iso path {
  fill: none;
  stroke: currentColor;
  stroke-width: 17;
}
.iso .dot { fill: currentColor; stroke: none; }

/* ---------- Grano + marcas de retícula ---------- */
.grain {
  position: fixed;
  inset: -50%;
  z-index: 90;
  pointer-events: none;
  opacity: .1;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1.2s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -3%); }
  60% { transform: translate(-2%, -1%); }
  80% { transform: translate(3%, 3%); }
  100% { transform: translate(0, 0); }
}

.marks i {
  position: fixed; z-index: 60; width: 11px; height: 11px; pointer-events: none;
  color: var(--fg);
}
.marks i::before, .marks i::after {
  content: ""; position: absolute; background: currentColor;
}
.marks i::before { left: 5px; top: 0; width: 1px; height: 11px; }
.marks i::after { top: 5px; left: 0; height: 1px; width: 11px; }
.marks i:nth-child(1) { left: 8px; top: 8px; }
.marks i:nth-child(2) { right: 8px; top: 8px; }
.marks i:nth-child(3) { left: 8px; bottom: 8px; }
.marks i:nth-child(4) { right: 8px; bottom: 8px; }

/* ---------- Cursor ---------- */
.cursor {
  position: fixed; left: 0; top: 0; z-index: 250;
  width: 12px; height: 12px; margin: -6px 0 0 -6px;
  border-radius: 50%;
  background: #fff;
  mix-blend-mode: difference;
  pointer-events: none;
  opacity: 0;
  transition: width .35s var(--ease-out), height .35s var(--ease-out), margin .35s var(--ease-out), opacity .3s;
}
.cursor.is-on { opacity: 1; }
.cursor.is-hover { width: 56px; height: 56px; margin: -28px 0 0 -28px; }
@media (pointer: fine) {
  html.has-cursor, html.has-cursor a, html.has-cursor button, html.has-cursor label { cursor: none; }
  html.has-cursor input, html.has-cursor textarea { cursor: text; }
}

/* ---------- Loader ---------- */
.loader { display: none; }
html.anim .loader {
  display: block;
  position: fixed; inset: 0; z-index: 200;
  background: var(--ink); color: var(--paper);
  clip-path: inset(0% 0% 0% 0%);
}
.loader-grid {
  position: absolute; inset: 0;
  display: grid; grid-template-columns: repeat(12, 1fr);
  padding: 0 var(--gut);
}
.loader-grid i { border-left: 1px solid rgba(237, 237, 234, .12); }
.loader-grid i:last-child { border-right: 1px solid rgba(237, 237, 234, .12); }
.loader-iso {
  position: absolute; left: 50%; top: 50%;
  width: clamp(120px, 18vmin, 200px);
  transform: translate(-50%, -50%);
}
.loader-iso .draw { stroke-dasharray: 1; stroke-dashoffset: 1; }
.loader-iso:not(.is-drawn) .dot { opacity: 0; }
.loader-meta {
  position: absolute; left: var(--gut); right: var(--gut); bottom: var(--gut);
  display: flex; justify-content: space-between; align-items: flex-end;
}
.loader-count { font-size: 44px; line-height: .8; letter-spacing: -.04em; }

/* ---------- Header ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 80;
  display: grid; grid-template-columns: 1fr auto; align-items: center;
  padding: 18px calc(var(--gut) + 8px);
  color: var(--fg);
  pointer-events: none;
}
.nav::before {
  content: ""; position: absolute; inset: 0 0 -28px; z-index: -1;
  background: linear-gradient(var(--bg) 45%, color-mix(in srgb, var(--bg) 0%, transparent));
  opacity: 0; transition: opacity .4s;
}
.nav.is-scrolled::before { opacity: 1; }
.nav > * { pointer-events: auto; }
.brand { display: block; justify-self: start; }
/* Imagotipo oficial (assets/img/imagotipo.png) usado como máscara: forma intacta, color según el fondo */
.logo, .footer-logo {
  display: block;
  aspect-ratio: 3200 / 666;
  background: currentColor;
  -webkit-mask: url("../assets/img/imagotipo.png") center / contain no-repeat;
  mask: url("../assets/img/imagotipo.png") center / contain no-repeat;
}
.brand .logo { width: 134px; }
.nav-right { justify-self: end; display: flex; align-items: center; gap: clamp(16px, 2.4vw, 36px); }
.nav-links { display: flex; align-items: center; gap: clamp(16px, 2.4vw, 36px); }

/* Selector de idioma */
.lang { display: inline-flex; align-items: center; gap: 6px; }
.lang button {
  font: inherit; letter-spacing: inherit; text-transform: inherit; color: inherit;
  padding: 6px 0; opacity: .45; transition: opacity .3s;
}
.lang button:hover { opacity: .8; }
.lang button[aria-pressed="true"] { opacity: 1; text-decoration: underline; text-underline-offset: 4px; }
.lang > span { opacity: .45; }
.nav .lang { padding-left: clamp(16px, 2.4vw, 36px); border-left: 1px solid var(--line); }

/* Cortina al cambiar de idioma */
.wipe {
  position: fixed; inset: 0; z-index: 195;
  display: grid; place-items: center;
  background: var(--ink); color: var(--paper);
  clip-path: inset(100% 0% 0% 0%);
  pointer-events: none;
}
.wipe-label { font-size: 13px; letter-spacing: .08em; }
.nav-links a { position: relative; }
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -3px; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform .5s var(--ease-out);
}
.nav-links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav-cta { display: inline-flex; align-items: center; gap: 8px; }
.sq {
  width: 9px; height: 9px; flex: none;
  background: var(--c-video);
  animation: sq 4.8s steps(1) infinite;
}
@keyframes sq {
  0% { background: var(--c-digital); }
  25% { background: var(--c-audio); }
  50% { background: var(--c-imagen); }
  75% { background: var(--c-video); }
}
html[data-theme="lime"] .sq { animation: none; background: var(--ink); }

/* ---------- Menú móvil ---------- */
.burger, .menu { display: none; }

/* ---------- Estructura común ---------- */
.section { position: relative; padding: clamp(96px, 16vh, 180px) var(--gut); }

.sec-head {
  position: relative;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: start;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  margin-bottom: clamp(48px, 9vh, 110px);
}
.sec-head > :last-child { justify-self: end; }
.sec-head::before, .sec-head::after {
  content: "+"; position: absolute; top: -9px;
  font: 400 14px/1 var(--mono);
}
.sec-head::before { left: -4px; }
.sec-head::after { right: -4px; }

.clip { display: block; overflow: hidden; padding: .12em 0 .16em; margin: -.12em 0 -.16em; }
[data-chars] { display: inline-block; white-space: nowrap; }
.ch { display: inline-block; will-change: transform; }

.fit-wrap { width: 100%; }
[data-fit] { width: max-content; white-space: nowrap; }

.giant {
  font-weight: 700;
  font-size: 22vw; /* main.js lo ajusta para llenar el ancho */
  line-height: .8;
  letter-spacing: -.045em;
}

.btn {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 16px 22px;
  background: var(--fg); color: var(--bg);
  font: 500 12.5px/1 var(--mono); text-transform: uppercase; letter-spacing: .02em;
  position: relative; overflow: hidden; isolation: isolate;
  transition: color .45s var(--ease-out);
}
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--c-video);
  transform: translateY(101%);
  transition: transform .45s var(--ease-out);
}
.btn:hover::before, .btn:focus-visible::before { transform: translateY(0); }
.btn:hover { color: #fff; }
.btn span { transition: transform .45s var(--ease-out); }
.btn:hover span { transform: translate(3px, -3px); }
.btn-lime { background: var(--c-digital); color: var(--ink); }
.btn-lime::before { background: var(--paper); }
.btn-lime:hover { color: var(--ink); }

/* ---------- HERO ---------- */
.hero { position: relative; height: 100vh; height: 100svh; min-height: 620px; overflow: hidden; }
.hero-title {
  position: absolute; inset: 70px var(--gut) var(--gut);
  display: flex; flex-direction: column; justify-content: space-between;
  font-weight: 700; font-size: var(--hero-fs); line-height: .8; letter-spacing: -.05em;
  pointer-events: none;
}
.hero-title .clip { width: max-content; }
.hero-title .clip-bottom { align-self: flex-end; }

.hero-iso {
  position: absolute; left: 50%; top: 50%;
  width: min(40vh, 52vw); aspect-ratio: 1;
  transform: translate(-50%, -50%);
}
.hero-iso svg { width: 100%; height: 100%; will-change: transform; }

.hero-meta {
  position: absolute; left: var(--gut); right: var(--gut);
  bottom: calc(var(--gut) + var(--hero-fs) * .8 + 28px);
  display: flex; justify-content: space-between; align-items: flex-end; gap: 32px;
}
.hero-intro { max-width: 350px; }
.hero-intro .label { margin-bottom: 10px; }
.hero-index li { display: flex; align-items: center; gap: 10px; padding: 3px 0; }
.hero-index i { width: 9px; height: 9px; background: var(--c); flex: none; }
.hero-index .muted { margin-top: 8px; padding-left: 19px; }

/* ---------- SERVICIOS ---------- */
.manifesto {
  display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 96px); align-items: end;
  margin-bottom: clamp(88px, 15vh, 170px);
}
.manifesto-title {
  font-weight: 700;
  font-size: clamp(48px, 8.6vw, 150px);
  line-height: .8; letter-spacing: -.05em;
}
.manifesto-title .clip { width: max-content; }
.manifesto-copy .label { margin-bottom: 18px; }
.manifesto-text {
  font-size: clamp(20px, 1.75vw, 28px); line-height: 1.28; letter-spacing: -.012em;
  margin-bottom: 28px;
}
.manifesto-note { color: var(--muted); max-width: 460px; }

.svc { border-top: 1px solid var(--line); }
.svc:last-child { border-bottom: 1px solid var(--line); }
.svc-head {
  position: relative; isolation: isolate;
  width: 100%;
  display: grid;
  grid-template-columns: 64px 12px minmax(0, 1fr) minmax(0, 34%) 32px;
  align-items: center; gap: clamp(12px, 2vw, 28px);
  padding: clamp(18px, 2.6vh, 28px) 12px;
  text-align: left;
  transition: color .45s var(--ease-out);
}
.svc-head::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--c);
  transform: scaleY(0); transform-origin: bottom;
  transition: transform .5s var(--ease-out);
}
.svc-head:hover::before, .svc-head:focus-visible::before, .svc.is-open .svc-head::before { transform: scaleY(1); }
.svc-head:hover, .svc-head:focus-visible, .svc.is-open .svc-head { color: var(--on-c); }
.svc-head:focus-visible { outline-offset: -2px; }

.svc-dot { width: 12px; height: 12px; background: var(--c); transition: background .45s var(--ease-out); }
.svc[data-key="digital"] .svc-head:not(:hover) .svc-dot { box-shadow: inset 0 0 0 1px rgba(11, 11, 11, .35); }
.svc-head:hover .svc-dot, .svc-head:focus-visible .svc-dot, .svc.is-open .svc-dot { background: currentColor; }

.svc-title {
  font-size: clamp(26px, 3.2vw, 48px); line-height: 1; letter-spacing: -.03em;
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
}
.svc-sum { color: inherit; opacity: .75; }
.svc-toggle { position: relative; width: 18px; height: 18px; justify-self: end; }
.svc-toggle::before, .svc-toggle::after {
  content: ""; position: absolute; left: 0; top: 50%; width: 100%; height: 1.5px;
  background: currentColor; transition: transform .45s var(--ease-out);
}
.svc-toggle::after { transform: rotate(90deg); }
.svc.is-open .svc-toggle::after { transform: rotate(0deg); }

.svc-body {
  display: grid; grid-template-rows: 0fr;
  transition: grid-template-rows .6s var(--ease-out);
}
.svc.is-open .svc-body { grid-template-rows: 1fr; }
.svc-body-inner {
  overflow: hidden; min-height: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 clamp(16px, 2vw, 32px);
  padding: 0 12px 0 calc(12px + 64px + 12px + 2 * clamp(12px, 2vw, 28px));
}
.svc.is-open .svc-body-inner { padding-block: 28px 36px; }
.svc-body-inner { transition: padding .6s var(--ease-out); }
.svc-item { border-top: 1px solid var(--line); padding-top: 12px; }
.svc-item h3 { font-weight: 700; font-size: 17px; letter-spacing: -.01em; margin-bottom: 8px; }
.svc-item p { font-size: 15px; line-height: 1.45; color: var(--muted); }
.svc-more { grid-column: 1 / -1; margin-top: 24px; justify-self: start; border-bottom: 1px solid currentColor; padding-bottom: 2px; }

/* ---------- DIGITAL ---------- */
.digital .giant { margin-bottom: clamp(40px, 7vh, 88px); }
.digital-intro {
  display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 96px); align-items: end;
}
.digital-lead {
  font-weight: 700; font-size: clamp(28px, 3.6vw, 56px); line-height: .98; letter-spacing: -.035em;
}
.digital-copy p { font-size: clamp(17px, 1.35vw, 21px); line-height: 1.4; margin-bottom: 28px; max-width: 520px; }

.wave { margin: clamp(56px, 10vh, 120px) 0; }
.wave:has(+ .digital-more[hidden]) { margin-bottom: 0; }
.wave-meta { display: flex; justify-content: space-between; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.wave canvas { display: block; width: 100%; height: clamp(110px, 16vh, 170px); }

.block { margin-top: clamp(56px, 10vh, 120px); }
.block-title { padding-bottom: 12px; border-bottom: 1px solid var(--fg); margin-bottom: 0; }

.cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card {
  position: relative; isolation: isolate;
  padding: 20px 20px 28px; min-height: 280px;
  display: flex; flex-direction: column;
  border-right: 1px solid var(--line);
  transition: color .45s var(--ease-out);
}
.card:first-child { padding-left: 0; }
.card:last-child { border-right: 0; }
.card::before {
  content: ""; position: absolute; inset: 0; z-index: -1; background: var(--ink);
  transform: scaleY(0); transform-origin: top; transition: transform .5s var(--ease-out);
}
.card:hover { color: var(--c-digital); }
.card:hover::before { transform: scaleY(1); }
.card:first-child:hover { padding-left: 20px; }
.card { transition: color .45s var(--ease-out), padding .45s var(--ease-out); }
.card-num { margin-bottom: auto; }
.card h3 { font-weight: 700; font-size: clamp(22px, 2vw, 30px); line-height: 1; letter-spacing: -.03em; margin: 48px 0 12px; }
.card p { font-size: 15px; line-height: 1.45; opacity: .78; }

.process {
  position: relative;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(12px, 2vw, 28px);
  padding-top: 44px;
}
.process::before {
  content: ""; position: absolute; left: 0; right: 0; top: 22px; height: 1.5px; background: var(--fg);
  transform-origin: left; transform: scaleX(var(--p, 1));
}
.process li { position: relative; }
.process li::before {
  content: ""; position: absolute; top: -28px; left: 0; width: 13px; height: 13px; border-radius: 50%;
  background: var(--fg); box-shadow: 0 0 0 4px var(--bg);
}
.process span { display: block; margin-bottom: 14px; }
.process h3 { font-weight: 700; font-size: clamp(22px, 1.9vw, 28px); letter-spacing: -.03em; line-height: 1; margin-bottom: 10px; }
.process p { font-size: 15px; line-height: 1.45; opacity: .78; }

.marquee {
  margin: clamp(72px, 12vh, 140px) calc(var(--gut) * -1) calc(clamp(96px, 16vh, 180px) * -1);
  background: var(--ink); color: var(--c-digital);
  overflow: hidden; padding: 20px 0;
  font-size: clamp(13px, 1.1vw, 16px);
}
.marquee-track { display: flex; width: max-content; animation: marquee 38s linear infinite; }
.marquee span { display: inline-flex; align-items: center; white-space: nowrap; }
.marquee span::after { content: "✦"; margin: 0 28px; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- CONTACTO ---------- */
.contact .giant { margin-bottom: clamp(48px, 8vh, 100px); }
.contact-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(40px, 7vw, 140px);
}
.contact-lead {
  font-weight: 700; font-size: clamp(26px, 2.8vw, 44px); line-height: 1; letter-spacing: -.035em;
  margin-bottom: 48px; max-width: 560px;
}
.contact-list > div { display: grid; grid-template-columns: 90px 1fr; gap: 16px; padding: 14px 0; border-top: 1px solid var(--line); }
.contact-list dt { color: var(--muted); }
.contact-list a { border-bottom: 1px solid transparent; transition: border-color .3s; }
.contact-list .email { text-transform: none; font-size: 13px; }
.contact-list a:hover { border-color: currentColor; }
.socials { display: flex; flex-wrap: wrap; gap: 8px 22px; }

.form { display: grid; gap: 26px; }
.chips { border: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips legend { width: 100%; margin-bottom: 14px; color: var(--muted); padding: 0; }
.chips label { position: relative; }
.chips input { position: absolute; opacity: 0; inset: 0; margin: 0; }
.chips span {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 14px; border: 1px solid var(--line);
  font: 500 12px/1 var(--mono); text-transform: uppercase;
  transition: background .3s, color .3s, border-color .3s;
}
.chips span::before { content: ""; width: 8px; height: 8px; background: var(--c); }
.chips label:hover span { border-color: var(--fg); }
.chips input:checked + span { background: var(--c); color: var(--on-c); border-color: var(--c); }
.chips input:checked + span::before { background: currentColor; }
.chips input:focus-visible + span { outline: 2px solid var(--fg); outline-offset: 2px; }

.field { display: grid; gap: 8px; }
.field label { color: var(--muted); }
.field input, .field textarea {
  width: 100%; background: transparent; border: 0; border-bottom: 1px solid var(--line);
  padding: 8px 0 12px; font-size: clamp(19px, 1.6vw, 24px); letter-spacing: -.01em;
  border-radius: 0; resize: vertical;
  transition: border-color .3s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--c-digital); }
.field.is-invalid input, .field.is-invalid textarea { border-color: var(--c-video); }
.form-foot { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.form-status { color: var(--muted); min-height: 1.5em; }

/* ---------- FOOTER ---------- */
.footer { position: relative; padding: clamp(80px, 14vh, 160px) var(--gut) var(--gut); }
.footer-logo { width: 100%; color: var(--fg); }
.footer-row {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px 24px;
  margin-top: clamp(32px, 5vh, 56px); padding-top: 14px; border-top: 1px solid var(--line);
}
.footer-areas { display: inline-flex; align-items: center; gap: 8px; }
.footer-areas i { width: 8px; height: 8px; background: var(--c); margin-left: 6px; }

/* ---------- Estados iniciales de animación (sólo con html.anim) ---------- */
html.anim .hero-iso .draw { stroke-dasharray: 1; stroke-dashoffset: 1; }
html.anim .hero-iso:not(.is-drawn) .dot { opacity: 0; }
html.anim [data-reveal] { opacity: 0; transform: translateY(28px); }
html.anim [data-chars]:not(.is-in) .ch { transform: translateY(115%); }
html.anim .process { --p: 0; }
html.anim .process li { opacity: 0; transform: translateY(20px); }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .svc-head { grid-template-columns: 48px 12px minmax(0, 1fr) 24px; }
  .svc-sum { grid-column: 3 / 4; grid-row: 2; }
  .svc-body-inner { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 24px; padding-left: 12px; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .card { border-bottom: 1px solid var(--line); }
  .card:nth-child(2) { border-right: 0; }
  .card:nth-child(3) { padding-left: 0; }
  .process { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 56px; }
  .process::before { display: none; }
  .process li { border-top: 1.5px solid var(--fg); padding-top: 24px; }
  .process li::before { top: -7px; }
}

@media (max-width: 760px) {
  :root { --hero-fs: 14.6vw; }
  .mono { font-size: 11px; }
  .marks i:nth-child(1), .marks i:nth-child(2) { display: none; }
  .sec-head { display: flex; justify-content: space-between; gap: 12px; }
  .sec-head > :last-child { text-align: right; }
  .nav { grid-template-columns: 1fr auto; padding: 12px var(--gut); }
  .nav-right { gap: 12px; }
  .nav .lang { padding-left: 0; border-left: 0; gap: 4px; }
  .nav, .nav .logo { transition: color .4s var(--ease-out); }

  .burger {
    display: block; position: relative; width: 40px; height: 40px; margin-right: -9px;
  }
  .burger span {
    position: absolute; left: 9px; width: 22px; height: 1.5px; background: currentColor;
    transition: transform .5s var(--ease-out), top .5s var(--ease-out);
  }
  .burger span:first-child { top: 16px; }
  .burger span:last-child { top: 23px; }
  html.menu-open .burger span:first-child { top: 19.5px; transform: rotate(45deg); }
  html.menu-open .burger span:last-child { top: 19.5px; transform: rotate(-45deg); }

  html.menu-open { overflow: hidden; }
  html.menu-open .nav { color: var(--paper); }
  html.menu-open .nav::before { opacity: 0; }
  html.menu-open .nav-cta { opacity: 0; pointer-events: none; }
  .nav-cta { transition: opacity .3s; }

  .menu {
    display: block;
    position: fixed; inset: 0; z-index: 75;
    background: var(--ink); color: var(--paper);
    clip-path: inset(0% 0% 100% 0%);
    visibility: hidden;
    transition: clip-path .75s var(--ease), visibility 0s linear .75s;
  }
  html.menu-open .menu {
    clip-path: inset(0% 0% 0% 0%);
    visibility: visible;
    transition: clip-path .75s var(--ease), visibility 0s;
  }
  .menu-grid {
    position: absolute; inset: 0; padding: 0 var(--gut);
    display: grid; grid-template-columns: repeat(6, 1fr);
  }
  .menu-grid i { border-left: 1px solid rgba(237, 237, 234, .08); }
  .menu-grid i:last-child { border-right: 1px solid rgba(237, 237, 234, .08); }

  .menu-list { position: absolute; left: var(--gut); right: var(--gut); top: 92px; }
  .menu-link {
    position: relative;
    display: grid; grid-template-columns: 40px 1fr auto; align-items: end;
    padding: 14px 0 12px;
  }
  .menu-link::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
    background: rgba(237, 237, 234, .2);
    transform: scaleX(0); transform-origin: left;
    transition: transform .9s var(--ease-out);
    transition-delay: calc(.2s + var(--i) * .07s);
  }
  .menu-link > .mono { padding-bottom: 6px; color: rgba(237, 237, 234, .55); }
  /* el tamaño va en el .clip para que su margen (en em) no recorte descendentes como la "g" */
  .menu-link .clip { font-size: 16vw; }
  .menu-word {
    display: block;
    font-weight: 700; line-height: .82; letter-spacing: -.05em;
    transform: translateY(110%);
    transition: transform .9s var(--ease-out), color .3s;
    transition-delay: calc(.18s + var(--i) * .07s), 0s;
  }
  .menu-arrow { padding-bottom: 6px; font-size: 16px; opacity: 0; transition: opacity .6s; transition-delay: calc(.4s + var(--i) * .07s); }
  html.menu-open .menu-link::after { transform: scaleX(1); }
  html.menu-open .menu-word { transform: translateY(0); }
  html.menu-open .menu-arrow { opacity: 1; }
  .menu-link.is-active .menu-word, .menu-link:active .menu-word { color: var(--c-digital); }

  .menu-foot {
    position: absolute; left: var(--gut); right: var(--gut); bottom: calc(var(--gut) + 8px);
    display: flex; flex-direction: column; gap: 6px;
    color: rgba(237, 237, 234, .55);
    opacity: 0; transition: opacity .6s .45s;
  }
  .menu-foot .email { color: var(--paper); text-transform: none; font-size: 14px; }
  .menu-foot .lang { color: var(--paper); font-size: 14px; gap: 10px; margin-bottom: 14px; }
  html.menu-open .menu-foot { opacity: 1; }
  .nav-links a:not(.nav-cta) { display: none; }
  .brand .logo { width: 118px; }

  .hero-title { inset: 72px var(--gut) var(--gut); }
  .hero-iso { width: 58vw; top: 44%; }
  .hero-meta { bottom: calc(var(--gut) + var(--hero-fs) * .8 + 20px); }
  .hero-index { display: none; }
  .hero-intro { max-width: none; }

  .manifesto { grid-template-columns: 1fr; gap: 40px; }
  .manifesto-title { font-size: 15vw; }

  .svc-head { grid-template-columns: 30px minmax(0, 1fr) 20px; padding-inline: 6px; }
  .svc-dot { display: none; }
  .svc-sum { grid-column: 2 / 3; }
  .svc-title { font-size: 28px; gap: 10px; }
  .svc-body-inner { grid-template-columns: 1fr; padding-inline: 6px; }

  .digital-intro, .contact-grid { grid-template-columns: 1fr; }
  .wave-meta span:nth-child(2) { display: none; }
  .cards { grid-template-columns: 1fr; }
  .card, .card:nth-child(3) { padding: 20px 0 28px; min-height: 0; border-right: 0; }
  .card:hover, .card:first-child:hover { padding-inline: 16px; }
  .card h3 { margin-top: 28px; }
  .process { grid-template-columns: 1fr 1fr; }

  .contact-list > div { grid-template-columns: 70px 1fr; }
  .footer-row { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .grain { animation: none; }
}
