/* ==========================================================================
   Umbral — Homepage
   Tokens · base · componentes · secciones · responsive · motion
   ========================================================================== */

/* ---------- Fuentes autoalojadas (subconjunto latino, WOFF2; ver scripts/fonts.md) ---------- */
@font-face { font-family: 'Syne'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/syne-latin-500-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Syne'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/syne-latin-700-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Syne'; font-style: normal; font-weight: 800; font-display: swap; src: url('../fonts/syne-latin-800-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Geist'; font-style: normal; font-weight: 300; font-display: swap; src: url('../fonts/geist-sans-latin-300-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Geist'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/geist-sans-latin-400-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Geist'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/geist-sans-latin-500-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Geist'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/geist-sans-latin-600-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Geist Mono'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/geist-mono-latin-400-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: 'Geist Mono'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/geist-mono-latin-500-normal.woff2') format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }

/* ---------- Tokens ---------- */
:root {
  --acc: #C6F432;            /* acento único: CTA, estados activos y la luz de la puerta */
  --acc-2: #7FD7FF;          /* solo sintaxis del fragmento de código */
  --bg: #06080A;
  --surface: #0C1013;
  --text: #E9EEF0;
  --text-soft: #C9D1D5;
  --muted: #AEB8BE;
  --muted-2: #8F9AA1;
  --dim: #7E898F;            /* mínimo permitido para texto (≥4.5:1 sobre --bg) */
  --line: rgba(233, 238, 240, .09);
  --line-2: rgba(233, 238, 240, .16);
  --blur: 18px;

  --font-logo: 'Syne', 'Arial Black', sans-serif;  /* solo el wordmark */
  --font-display: 'Geist', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Geist', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;

  --wrap: 1240px;
  --gutter: clamp(20px, 5vw, 64px);
  --ease-out: cubic-bezier(.23, 1, .32, 1);        /* entradas y respuesta a la interacción */
  --ease-in-out: cubic-bezier(.77, 0, .175, 1);    /* movimiento dentro de la pantalla */
  --dur-press: 160ms;
  --dur-ui: 200ms;
  color-scheme: dark;
  interpolate-size: allow-keywords;                /* acordeón: permite animar hasta height: auto */
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth; scroll-padding-top: 88px;
  -webkit-tap-highlight-color: transparent;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--text); }
a, button, summary { touch-action: manipulation; }
img, svg { display: block; }
::selection { background: var(--acc); color: var(--bg); }
:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; border-radius: 6px; }
.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; padding: 12px 16px; border-radius: 10px; background: var(--acc); color: var(--bg); font-weight: 500; text-decoration: none; }
.skip-link:focus { top: 16px; color: var(--bg); }

.page { position: relative; overflow-x: clip; min-height: 100vh; container-type: inline-size; }
.container { max-width: var(--wrap); margin: 0 auto; }
.section { position: relative; padding: clamp(72px, 9vw, 128px) var(--gutter) 0; }

/* ---------- Tipografía ---------- */
.eyebrow { display: block; font: 400 13px/1 var(--font-mono); color: var(--dim); }
.mono-label { font: 400 12.5px/1 var(--font-mono); color: var(--dim); }
.h2 { margin: 0; font: 500 clamp(32px, 3.9vw, 54px)/1.08 var(--font-display); letter-spacing: -0.035em; text-wrap: balance; }
.lead { margin: 0; color: var(--muted); font-size: 17px; line-height: 1.6; text-wrap: pretty; }
.accent { color: var(--acc); }

/* ---------- Componentes ---------- */
.glass {
  background: rgba(10, 13, 15, .72);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(150%);
          backdrop-filter: blur(var(--blur)) saturate(150%);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass { background: rgba(18, 23, 27, .96); }
}

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 48px; padding: 0 22px; border-radius: 999px;
  font: 500 15px/1 var(--font-body); letter-spacing: -0.01em; text-decoration: none; cursor: pointer;
  -webkit-user-select: none; user-select: none;
  transition: transform var(--dur-press) var(--ease-out), background-color var(--dur-ui) ease, border-color var(--dur-ui) ease;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--acc); color: var(--bg); border: 0; }
.btn-ghost { color: var(--text); border: 1px solid var(--line-2); background: transparent; }
.btn-lg { justify-content: center; min-height: 54px; font-size: 16px; }
.btn .arr { transition: transform var(--dur-ui) var(--ease-out); }
.btn[disabled] { opacity: .6; cursor: progress; }

.corner { flex: none; color: var(--dim); }
.tag { padding: 7px 11px; border-radius: 999px; border: 1px solid var(--line-2); font: 400 12.5px/1 var(--font-mono); color: var(--text-soft); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.pill-acc { padding: 5px 9px; border-radius: 999px; background: var(--acc); color: var(--bg); font: 500 12px/1 var(--font-mono); }

/* Disposición común: título fijo a la izquierda, contenido a la derecha */
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.split-head { position: sticky; top: 104px; display: flex; flex-direction: column; align-items: flex-start; gap: 18px; }
.split-head .lead { max-width: 28rem; }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 24px; }
.section-head__title { display: flex; flex-direction: column; gap: 18px; max-width: 760px; }
.stack-lg { display: flex; flex-direction: column; gap: clamp(36px, 5vw, 56px); }

/* ---------- Header / nav ---------- */
.site-header { position: sticky; top: 0; z-index: 50; border-bottom: 1px solid var(--line); }
.nav {
  position: relative; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px max(var(--gutter), calc((100% - var(--wrap)) / 2));
}
.brand { display: flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; color: var(--text); }
.brand-name { font: 800 21px/1 var(--font-logo); letter-spacing: -0.02em; }
.brand-tag { font: 400 11px/1 var(--font-mono); color: var(--dim); padding-top: 4px; }
.nav-links { display: flex; align-items: center; gap: 2px; }
.navlink { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); text-decoration: none; font-size: 14px; padding: 0 14px; border-radius: 999px; transition: color var(--dur-ui) ease; }
.nav-actions { display: flex; align-items: center; gap: 8px; }
.nav-cta { min-height: 44px; padding: 0 18px; font-size: 14px; }
.menu-toggle {
  display: none; width: 44px; height: 44px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line-2); background: transparent; color: var(--text);
  align-items: center; justify-content: center;
  transition: transform var(--dur-press) var(--ease-out);
}
.menu-toggle:active { transform: scale(.95); }
.mobile-menu {
  position: absolute; left: 12px; right: 12px; top: calc(100% + 8px);
  display: flex; flex-direction: column; gap: 2px; padding: 8px; border-radius: 18px;
  border: 1px solid var(--line-2); background: rgba(12, 16, 19, .96);
  transform-origin: top right;
  transition: opacity var(--dur-ui) var(--ease-out), transform var(--dur-ui) var(--ease-out);
}
@starting-style { .mobile-menu { opacity: 0; transform: scale(.97) translateY(-4px); } }
.mobile-menu[hidden] { display: none; }
.mobile-menu .navlink { min-height: 48px; padding: 0 14px; font-size: 16px; border-radius: 12px; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: clamp(48px, 7vw, 88px) var(--gutter) clamp(56px, 7vw, 88px); }
.hero-grid {
  max-width: var(--wrap); margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 4vw, 64px); align-items: center;
}
.hero-copy { position: relative; z-index: 2; display: flex; flex-direction: column; gap: 26px; }
.hero-title { margin: 0; font: 500 clamp(44px, 6vw, 88px)/1 var(--font-display); letter-spacing: -0.045em; text-wrap: balance; }
.hero-kicker { display: block; margin-bottom: 22px; font: 400 clamp(13px, 1.05vw, 14.5px)/1.4 var(--font-mono); letter-spacing: 0; color: var(--muted); }
.hero-lead { margin: 0; max-width: 34rem; font-size: clamp(17px, 1.4vw, 19px); line-height: 1.55; color: var(--muted); text-wrap: pretty; }
.hero-ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 12px; }
.badge { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 0 10px; font: 400 12.5px/1.3 var(--font-mono); color: var(--muted); }
.badge-dot { flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--acc); }
.hero-points { list-style: none; margin: 8px 0 0; padding: 20px 0 0; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 10px 28px; font: 400 13px/1.3 var(--font-mono); color: var(--muted); }

/* La puerta: el mismo arco de la intro, con las capas del proyecto delante */
.stage { --s: 1; display: grid; justify-content: center; height: calc(600px * var(--s)); }
.stage-box { position: relative; width: 460px; height: 600px; transform: scale(var(--s)); transform-origin: top center; }
.door { position: absolute; left: 50%; bottom: 0; width: 400px; height: 560px; margin-left: -200px; border: 1px solid var(--line-2); border-bottom: 0; border-radius: 200px 200px 0 0; background: var(--surface); overflow: hidden; }
.door::after { content: ''; position: absolute; left: 50%; bottom: 0; width: 2px; height: 86%; margin-left: -1px; border-radius: 2px 2px 0 0; background: var(--acc); box-shadow: 0 0 56px 12px color-mix(in oklab, var(--acc) 24%, transparent); }
.door-floor { position: absolute; left: -10px; right: -10px; bottom: 0; height: 1px; background: var(--muted-2); }

.pane { position: absolute; left: 50%; top: 50%; width: 320px; height: 204px; margin: -102px 0 0 -160px; border-radius: 14px; }
.pane--back { transform: translate(-48px, -64px); padding: 14px; display: flex; flex-direction: column; gap: 8px; border: 1px dashed var(--line-2); background: var(--bg); }
.pane--mid { transform: translate(4px, 36px); }
.pane--front { transform: translate(52px, 136px); box-shadow: 0 24px 48px -24px #000; }
.pane--code { padding: 14px 16px; display: flex; flex-direction: column; gap: 12px; border: 1px solid var(--line-2); background: var(--bg); }
.pane--ui { padding: 14px; display: flex; flex-direction: column; gap: 10px; border: 1px solid var(--line-2); background: #11161A; }
.pane-head { display: flex; justify-content: space-between; align-items: center; font: 400 11px/1 var(--font-mono); color: var(--muted); }
.pane--back .pane-head { color: var(--dim); }
.pane--code .pane-head span:last-child { color: var(--acc); }
.wf { border: 1px dashed var(--line-2); border-radius: 4px; }
.wf--bar { height: 14px; }
.wf--hero { flex: 1; border-radius: 6px; }
.wf-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; height: 40px; }
.win-dots { display: flex; gap: 5px; }
.win-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--line-2); }
.win-dots i:last-child { background: var(--acc); }
.ui-lines { display: flex; flex-direction: column; gap: 7px; padding-top: 6px; }
.ui-lines i { display: block; border-radius: 3px; }
.ui-h { height: 13px; background: rgba(233, 238, 240, .72); }
.ui-p { height: 6px; background: rgba(233, 238, 240, .22); }
.ui-btns { display: flex; gap: 8px; margin-top: 2px; }
.ui-btn { height: 22px; width: 84px; border-radius: 999px; background: var(--acc); }
.ui-btn--ghost { width: 66px; background: none; border: 1px solid rgba(233, 238, 240, .3); }
.code { margin: 0; font: 400 13px/1.6 var(--font-mono); white-space: pre; color: var(--text); }
.tok-kw { color: var(--acc-2); }
.tok-str { color: var(--acc); }
.tok-fn { font-weight: 500; }
.caret { display: inline-block; width: 7px; height: 14px; margin-left: 4px; vertical-align: -2px; background: var(--acc); animation: blink 1.1s steps(1) infinite; }

/* ---------- Prueba social ---------- */
.proof { padding: 0 var(--gutter); }
.proof .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 40px; padding: 28px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.proof-label { margin: 0; font: 400 12.5px/1.4 var(--font-mono); color: var(--dim); }
.logo-grid { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 20px 56px; }
.logo-grid li { display: flex; align-items: center; justify-content: center; }
.logo-grid img { display: block; height: 52px; width: auto; max-width: 100%; opacity: .8; }
.logo-grid img.is-wide { height: 34px; }
@media (max-width: 480px) { .logo-grid { gap: 20px 28px; } }

/* ---------- Trabajo ---------- */
/* Carrusel con scroll nativo: la inercia y el arrastre del dedo son los del sistema. La tarjeta siguiente asoma para invitar a deslizar */
.work-grid {
  display: flex; gap: clamp(14px, 2.4vw, 28px);
  --sangria: max(var(--gutter), calc((100cqw - var(--wrap)) / 2)); /* llega al borde de la pantalla; cqw: .page es el contenedor y no cuenta la barra de scroll */
  margin-inline: calc(var(--sangria) * -1); padding-inline: var(--sangria); scroll-padding-inline: var(--sangria);
  overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none;
}
.work-grid::-webkit-scrollbar { display: none; }
.work-grid:focus-visible { outline-offset: -2px; }
.work-card { flex: 0 0 min(72%, 760px); display: flex; flex-direction: column; gap: 16px; min-width: 0; scroll-snap-align: start; }
.work-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.work-nav { display: none; gap: 8px; }
.work-nav-btn {
  display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; padding: 0;
  border: 1px solid var(--line-2); border-radius: 999px; background: transparent; color: var(--text); cursor: pointer;
  transition: transform var(--dur-press) var(--ease-out), border-color var(--dur-ui) ease, opacity var(--dur-ui) ease;
}
.work-nav-btn:active:not(:disabled) { transform: scale(.95); }
.work-nav-btn:disabled { opacity: .35; cursor: default; }
.work-progress { height: 2px; overflow: hidden; background: var(--line-2); }
.work-progress i { display: block; height: 100%; background: var(--acc); transform: scaleX(0); transform-origin: left; }
.work-media { position: relative; aspect-ratio: 16 / 10; border-radius: 14px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); }
.work-media picture { display: block; height: 100%; }
.work-media img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform 300ms var(--ease-out); }
.work-link { display: block; transition: border-color var(--dur-ui) ease; }
.work-link:focus-visible { border-radius: 14px; }
.work-link .corner { position: absolute; top: 12px; right: 12px; box-sizing: content-box; padding: 9px; border-radius: 999px; background: rgba(6, 8, 10, .78); color: var(--text); transition: transform var(--dur-ui) var(--ease-out), color var(--dur-ui) ease; }
.work-link:focus-visible .corner { color: var(--acc); }
.work-meta { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.work-meta > div { display: flex; flex-direction: column; gap: 6px; }
.work-title { margin: 0; font: 500 22px/1.15 var(--font-display); letter-spacing: -0.025em; }
.work-sub { margin: 0; font: 400 13px/1.4 var(--font-mono); color: var(--muted); }
.work-result { margin: 0; max-width: 38rem; color: var(--muted); font-size: 15.5px; line-height: 1.55; text-wrap: pretty; }
.work-quote { margin: 0; padding-top: 14px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.work-quote blockquote { margin: 0; }
.work-quote p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.6; }
.work-quote figcaption { font: 400 12.5px/1.4 var(--font-mono); color: var(--dim); }

/* ---------- Servicios ---------- */
.services { display: flex; flex-direction: column; border-bottom: 1px solid var(--line); }
.service { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 6px 12px; padding: 26px 0; border-top: 1px solid var(--line); }
.service-n { padding-top: 7px; font: 400 12.5px/1 var(--font-mono); color: var(--dim); }
.service-body { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.service-title { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 0; font: 500 clamp(21px, 2vw, 26px)/1.2 var(--font-display); letter-spacing: -0.025em; }
.service-text { margin: 0; max-width: 36rem; color: var(--muted); font-size: 16px; line-height: 1.55; text-wrap: pretty; }
.service .tags { margin-top: 6px; }

/* ---------- Franja de stack ---------- */
.stack-strip { display: flex; flex-direction: column; gap: 20px; }
.stack-label { margin: 0; font: 400 12.5px/1.4 var(--font-mono); color: var(--dim); }
.stack-list { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px 16px; }
.stack-list li { display: flex; align-items: center; gap: 10px; font: 400 13px/1.2 var(--font-mono); color: var(--muted); }
.stack-list img { display: block; flex: none; width: 20px; height: 20px; opacity: .8; }
@media (min-width: 720px) { .stack-list { grid-template-columns: repeat(6, auto); justify-content: space-between; } }

/* ---------- Proceso ---------- */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 clamp(12px, 2vw, 24px); }
.step {
  all: unset; box-sizing: border-box; cursor: pointer; -webkit-user-select: none; user-select: none;
  display: flex; flex-direction: column; gap: 10px; min-height: 44px; padding: 0 0 20px; border-radius: 4px;
}
.step:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }
.step .bar { display: block; height: 2px; margin-bottom: 8px; background: var(--line-2); overflow: hidden; }
.step .bar i { display: block; height: 100%; background: var(--acc); transform: scaleX(0); transform-origin: left; transition: transform 240ms var(--ease-out); }
.step[aria-selected="true"] .bar i { transform: scaleX(1); }
.step .num { font: 400 12.5px/1 var(--font-mono); color: var(--dim); }
.step[aria-selected="true"] .num { color: var(--acc); }
.step .title { font: 500 19px/1.2 var(--font-display); letter-spacing: -0.02em; color: var(--muted); transition: color var(--dur-ui) ease; }
.step[aria-selected="true"] .title { color: var(--text); }
.step .short { font-size: 14.5px; line-height: 1.45; color: var(--muted-2); }

.step-panel { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(28px, 6vw, 96px); align-items: start; padding-top: clamp(20px, 3vw, 32px); border-top: 1px solid var(--line); }
.step-panel[hidden] { display: none; }
.step-panel__copy { display: flex; flex-direction: column; gap: 14px; }
.step-panel__title { margin: 0; font: 500 clamp(26px, 2.6vw, 34px)/1.12 var(--font-display); letter-spacing: -0.03em; }
.deliverables { display: flex; flex-direction: column; gap: 6px; }
.deliverables ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.deliverables li { display: flex; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 15.5px; color: var(--text-soft); }
.deliverables svg { flex: none; }

/* ---------- Por qué a la medida ---------- */
.cmp-wrap { overflow-x: auto; }
.cmp { width: 100%; border-collapse: collapse; font-size: 15.5px; line-height: 1.45; }
.cmp th, .cmp td { padding: 16px 16px 16px 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.cmp th:last-child, .cmp td:last-child { padding-right: 0; }
.cmp thead th { font: 400 12.5px/1.2 var(--font-mono); color: var(--dim); }
.cmp thead th.is-us { color: var(--acc); }
.cmp tbody th { font-weight: 500; }
.cmp td.them { color: var(--muted-2); }

/* ---------- Preguntas frecuentes ---------- */
.faq-list { display: flex; flex-direction: column; border-bottom: 1px solid var(--line); }
.faq-item { border-top: 1px solid var(--line); }
.faq-item::details-content {
  height: 0; overflow: clip; opacity: 0;
  transition: height var(--dur-ui) var(--ease-out), opacity var(--dur-ui) ease, content-visibility var(--dur-ui) allow-discrete;
}
.faq-item[open]::details-content { height: auto; opacity: 1; }
.faq-item summary { display: flex; align-items: center; gap: 16px; min-height: 64px; padding: 12px 0; cursor: pointer; list-style: none; border-radius: 6px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-n { display: none; }
.faq-q { flex: 1; font: 500 18px/1.3 var(--font-display); letter-spacing: -0.015em; color: var(--text); text-wrap: balance; }
.faq-icon { position: relative; flex: none; width: 14px; height: 14px; color: var(--muted); }
.faq-icon::before, .faq-icon::after { content: ""; position: absolute; left: 0; top: 6px; width: 14px; height: 1.5px; background: currentColor; border-radius: 2px; transition: transform var(--dur-ui) var(--ease-out); }
.faq-icon::after { transform: rotate(90deg); }
.faq-item[open] .faq-icon::after { transform: rotate(0deg); }
.faq-a { padding: 0 30px 22px 0; }
.faq-a p { margin: 0; color: var(--muted); font-size: 16px; line-height: 1.6; text-wrap: pretty; }

/* ---------- Contacto ---------- */
.contact { padding-bottom: clamp(72px, 9vw, 128px); }
.contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 6vw, 96px); }
.contact-copy { display: flex; flex-direction: column; gap: 20px; }
.contact-title { margin: 0; font: 500 clamp(40px, 5.2vw, 72px)/1.02 var(--font-display); letter-spacing: -0.04em; text-wrap: balance; }
.contact-copy .lead { font-size: 18px; max-width: 28rem; }
.contact-list { margin: 12px 0 0; border-top: 1px solid var(--line); }
.contact-list > div { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0 16px; padding: 4px 0; border-bottom: 1px solid var(--line); }
.contact-list dt { font: 400 13px/1.4 var(--font-mono); color: var(--dim); }
.contact-list dd { margin: 0; min-width: 0; }
.contact-list dd a { display: inline-flex; align-items: center; min-height: 44px; overflow-wrap: anywhere; text-underline-offset: 3px; }
.contact-list > div:not(:has(a)) { padding: 14px 0; }
.contact-wa { align-self: flex-start; }

.form { display: flex; flex-direction: column; gap: 20px; padding: clamp(20px, 3vw, 32px); border-radius: 22px; border: 1px solid var(--line); background: var(--surface); }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 14px; }
.field-group { display: flex; flex-direction: column; gap: 8px; }
.label, .form legend { font: 400 12.5px/1 var(--font-mono); color: var(--muted); }
.form fieldset { border: 0; margin: 0; padding: 0; }
.form legend { padding: 0; margin-bottom: 10px; }
.field {
  width: 100%; min-height: 48px; padding: 12px 14px; border-radius: 10px;
  border: 1px solid var(--line-2); background: var(--bg); color: var(--text);
  font: 400 16px/1.4 var(--font-body); transition: border-color var(--dur-ui) ease;
}
.field::placeholder { color: var(--dim); }
.field:focus { outline: none; border-color: var(--acc); }
.field:user-invalid { border-color: #FF8A3D; }
textarea.field { resize: vertical; min-height: 120px; }
select.field {
  appearance: none; -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 22px) 21px, calc(100% - 16px) 21px; background-size: 6px 6px; background-repeat: no-repeat;
}
select.field option { background: var(--surface); color: var(--text); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  all: unset; box-sizing: border-box; cursor: pointer; -webkit-user-select: none; user-select: none;
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line-2); color: var(--text-soft); font: 400 14px/1 var(--font-body);
  transition: transform var(--dur-press) var(--ease-out), background-color var(--dur-ui) ease, border-color var(--dur-ui) ease, color var(--dur-ui) ease;
}
.chip:active { transform: scale(.96); }
.chip:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }
.chip[aria-pressed="true"] { background: var(--acc); border-color: var(--acc); color: var(--bg); font-weight: 500; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; } /* honeypot anti-spam */
.consent { display: flex; align-items: flex-start; gap: 12px; }
.consent input { flex: none; width: 22px; height: 22px; margin: 11px 0 0; accent-color: var(--acc); cursor: pointer; }
.consent input:user-invalid { outline: 2px solid #FF8A3D; outline-offset: 2px; }
.consent label { padding: 11px 0; color: var(--muted); font-size: 14px; line-height: 1.5; cursor: pointer; }
.consent label a { color: var(--text); text-underline-offset: 3px; }
.form-error { margin: 0; color: #FFB27D; font-size: 14px; }
.form-success { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; padding: 28px 0; transition: opacity 300ms var(--ease-out), transform 300ms var(--ease-out); }
@starting-style { .form-success { opacity: 0; transform: translateY(8px); } }
.form-success[hidden] { display: none; }
.form-success h3 { margin: 0; font: 500 28px/1.1 var(--font-display); letter-spacing: -0.03em; }
.form-success p { margin: 0; color: var(--muted); font-size: 16px; line-height: 1.6; }

/* ---------- Página legal ---------- */
.legal { padding-bottom: clamp(60px, 8vw, 100px); }
.legal-body { max-width: 720px; display: flex; flex-direction: column; gap: 40px; }
.legal-head { display: flex; flex-direction: column; gap: 18px; }
.legal-title { margin: 0; font: 500 clamp(34px, 4.6vw, 56px)/1.05 var(--font-display); letter-spacing: -0.04em; text-wrap: balance; }
.draft-note { padding: 16px 18px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--surface); color: var(--text-soft); font-size: 15px; line-height: 1.6; }
.draft-note strong { color: var(--acc); font-weight: 500; }
.legal-sec { display: flex; flex-direction: column; gap: 14px; padding-top: 28px; border-top: 1px solid var(--line); }
.legal-sec h2 { display: flex; align-items: baseline; gap: 14px; margin: 0; font: 500 clamp(21px, 2.2vw, 25px)/1.2 var(--font-display); letter-spacing: -0.025em; }
.legal-sec h2 span { font: 400 12.5px/1 var(--font-mono); color: var(--dim); }
.legal-sec p, .legal-sec li { color: var(--muted); font-size: 16px; line-height: 1.65; }
.legal-sec p { margin: 0; }
.legal-sec ul { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.legal-sec li::marker { color: var(--acc); }
.legal-sec strong { color: var(--text); font-weight: 500; }
.legal-sec a { text-underline-offset: 3px; }
.legal-facts { margin: 0; border-top: 1px solid var(--line); }
.legal-facts > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.legal-facts dt { font: 400 13px/1.4 var(--font-mono); color: var(--dim); }
.legal-facts dd { margin: 0; color: var(--text-soft); }
.legal-back { margin: 0; }

/* ---------- Intro: la puerta y el zoom hacia su centro ----------
   Línea de tiempo (2,25 s en total):
   0–0,5 s     el suelo se dispara desde el centro · 0,08–0,6 s  el arco sube por los dos lados y se cierra en la clave
   0,54–0,92 s la ranura sale del suelo con rebote y la puerta se ilumina: en 0,6 s hay impacto y retroceso (main.js)
   1,2–1,48 s  anticipación: la puerta se encoge mientras la ranura se abre hasta llenar el hueco
   1,48–2,2 s  zoom exponencial ×80 (main.js, con el reloj de .intro); la luz se apaga en el camino y por el hueco se ve la página
   2,25 s      el contenedor se oculta (main.js lo retira). Con reduced-motion, con ancla en la URL o si ya se vio en la sesión: no se muestra. */
.intro {
  --intro-size: clamp(150px, 42vmin, 340px);
  --ease-rebote: cubic-bezier(.34, 1.56, .64, 1);
  position: fixed; inset: 0; z-index: 9999;
  display: grid; place-items: center;
  cursor: pointer;
  transition: opacity .4s ease;
  animation: intro-fin .01s linear 2.25s forwards;
}
.intro--salida { opacity: 0; pointer-events: none; }
.sin-intro .intro { display: none; }
.intro-svg { width: var(--intro-size); height: var(--intro-size); overflow: visible; }
.intro-pared { fill: var(--bg); }
.intro-suelo { stroke: var(--text); stroke-width: 2; stroke-linecap: round; transform-origin: 16px 29px; transform: scaleX(0); animation: intro-suelo .5s cubic-bezier(.16, 1, .3, 1) forwards; }
/* El hueco del guion (120) es mayor que el trazo (100) y el desfase pasa del final: si no, el patrón se repite y asoma una raya en el otro extremo */
.intro-arco { stroke: var(--text); stroke-width: 2; stroke-dasharray: 100 120; stroke-dashoffset: 101; animation: intro-trazo .52s cubic-bezier(.76, 0, .24, 1) .08s forwards; }
.intro-ranura { stroke: var(--acc); stroke-width: 2.2; stroke-linecap: round; transform-origin: 16px 29px; transform: scaleY(0); animation: intro-ranura .38s var(--ease-rebote) .54s forwards, intro-ranura-fin .1s linear 1.38s forwards; }
.intro-fondo { fill: var(--bg); }
.intro-luz { fill: var(--acc); opacity: 0; animation: intro-luz .3s ease-out .58s forwards; }
.intro-apertura { fill: var(--acc); transform-origin: 16px 29px; transform: scale(0, .76); animation: intro-apertura .28s cubic-bezier(.7, 0, .2, 1) 1.2s forwards; }
.intro-interior { animation: intro-interior .38s ease-in 1.6s forwards; }
.intro-halo { opacity: 0; animation: intro-halo 1.17s linear .58s forwards; }
.intro-halo-a { stop-color: var(--acc); stop-opacity: .28; }
.intro-halo-b { stop-color: var(--acc); stop-opacity: 0; }
.intro-nota { position: absolute; left: 0; right: 0; bottom: max(28px, 7vh); margin: 0; text-align: center; font: 400 12.5px/1.4 var(--font-mono); color: var(--dim); opacity: 0; animation: intro-nota 1.1s linear .45s forwards; }

@keyframes intro-fin { to { visibility: hidden; } }
@keyframes intro-suelo { to { transform: scaleX(1); } }
@keyframes intro-trazo { to { stroke-dashoffset: 0; } }
@keyframes intro-ranura { to { transform: scaleY(1); } }
@keyframes intro-ranura-fin { to { opacity: 0; } }
/* .28: la misma opacidad del relleno de logo.svg */
@keyframes intro-luz { to { opacity: .28; } }
/* Nace dentro de la ranura (.76: la altura de esta) para que no asome por encima al ensancharse */
@keyframes intro-apertura { to { transform: scale(1); } }
@keyframes intro-interior { to { opacity: 0; } }
@keyframes intro-halo {
  0% { opacity: 0; }
  8% { opacity: 1; }
  50%, 53% { opacity: .45; }
  78% { opacity: 1; }
  100% { opacity: 0; }
}
@keyframes intro-nota {
  0% { opacity: 0; }
  20%, 70% { opacity: 1; }
  100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .intro { display: none; } }

/* ---------- Página 404 ---------- */
.notfound { padding-bottom: clamp(60px, 8vw, 100px); }
.notfound-body { max-width: 760px; display: flex; flex-direction: column; align-items: flex-start; gap: 22px; margin: 0 auto; }
.notfound-arch { max-width: 40vw; height: auto; margin-bottom: 4px; }
.notfound-title { margin: 0; font: 500 clamp(38px, 5.4vw, 68px)/1.04 var(--font-display); letter-spacing: -0.04em; text-wrap: balance; }
.notfound-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }

/* ---------- Footer ---------- */
.site-footer { padding: 0 var(--gutter) 32px; }
.site-footer .container { display: flex; flex-direction: column; gap: 40px; padding-top: 40px; border-top: 1px solid var(--line); }
.footer-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 32px; }
.footer-brand { display: flex; flex-direction: column; gap: 10px; max-width: 320px; }
.footer-brand p { margin: 0; color: var(--muted-2); font-size: 14.5px; line-height: 1.55; }
.footer-navs { display: flex; flex-wrap: wrap; gap: 56px; }
.footer-nav { display: flex; flex-direction: column; gap: 2px; }
.footer-nav .mono-label { margin-bottom: 8px; font-size: 12px; }
.flink { display: inline-flex; align-items: center; min-height: 36px; color: var(--muted); text-decoration: none; font-size: 14px; transition: color var(--dur-ui) ease; }
.footer-word {
  font: 800 clamp(80px, 19vw, 280px)/0.8 var(--font-logo); letter-spacing: -0.05em;
  color: transparent; -webkit-text-stroke: 1px rgba(233, 238, 240, .14);
  -webkit-user-select: none; user-select: none; white-space: nowrap; overflow: hidden;
}
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font: 400 12.5px/1.4 var(--font-mono); color: var(--dim); }

/* ---------- Entrada al hacer scroll (una sola vez; main.js añade .revelado). Sin JS todo se ve ---------- */
.con-revelado [data-reveal]:not(.revelado) { opacity: 0; transform: translateY(14px); }
.con-revelado [data-reveal] { transition: opacity 500ms var(--ease-out), transform 500ms var(--ease-out); }
.con-revelado .service:nth-child(2) { transition-delay: 40ms; }
.con-revelado .service:nth-child(3) { transition-delay: 80ms; }

/* ---------- Animaciones ---------- */
@keyframes blink { 50% { opacity: 0; } }

/* ---------- Hover: solo con mouse (en táctil se quedaría pegado tras el toque) ---------- */
@media (hover: hover) and (pointer: fine) {
  a:hover { color: #fff; }
  .btn-primary:hover { color: var(--bg); background: #D2F95C; }
  .btn-ghost:hover { border-color: var(--muted-2); }
  .btn:hover .arr { transform: translateX(3px); }
  .navlink:hover { color: #fff; }
  .flink:hover { color: var(--acc); }
  .consent label a:hover { color: var(--acc); }
  .step:hover .title { color: var(--text); }
  .chip:hover { border-color: var(--muted-2); }
  .chip[aria-pressed="true"]:hover { border-color: var(--acc); color: var(--bg); }
  .faq-item summary:hover .faq-icon { color: var(--text); }
  .work-nav { display: flex; } /* con el dedo se desliza; con mouse hacen falta flechas */
  .work-nav-btn:hover:not(:disabled) { border-color: var(--muted-2); }
  .work-link:hover { border-color: var(--line-2); }
  .work-link:hover .corner { color: var(--acc); transform: translate(2px, -2px); }
  .work-link:hover img { transform: scale(1.04); }
}

/* ---------- Responsive ---------- */
@media (max-width: 1040px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .stage { --s: .86; }
}
@media (max-width: 860px) {
  /* Menos blur en móvil: el vidrio es lo más caro de pintar */
  :root { --blur: 10px; }
  .nav-links { display: none; }
  .menu-toggle { display: inline-flex; }
  .split, .contact-grid, .step-panel { grid-template-columns: minmax(0, 1fr); }
  .split-head { position: static; }
  .work-card { flex-basis: 86%; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; }
}
@media (max-width: 520px) {
  .stage { --s: .72; }
  .nav-cta-text { display: none; }
  .nav-cta { width: 44px; padding: 0; justify-content: center; }
  .badge { margin-left: 0; }
  .steps { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .step { padding-bottom: 12px; }
  .step .short { display: none; }
  .cmp { font-size: 14.5px; }
  .cmp th, .cmp td { padding: 14px 10px 14px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
