/* ---------- Tokens del sistema de diseño ---------- */
:root {
  --tela: #f6f3ee;
  --tela-alta: #ffffff;
  --linea: #ddd6cb;
  --linea-fuerte: #8c857a;
  --tinta: #161514;
  --tinta-suave: #5e5a55;
  --hilo: #b83a24;
  --hilo-hover: #8f2c1b;
  --hilo-claro: #ffffff;
  --denim: #2b4766;
  --denim-suave: #dfe6ef;

  --oscuro-texto: #f2eee8;
  --oscuro-suave: #a9a39a;
  --oscuro-linea: #6e685f;
  --oscuro-caja: #2a2724;

  --radius-s: 2px;
  --radius-m: 6px;
  --radius-l: 12px;

  --font-display: "Raleway", "Avenir Next", system-ui, sans-serif;
  --font-sans: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--tela);
  color: var(--tinta);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
p { margin: 0; }
a { color: var(--hilo); }
a:hover { color: var(--hilo-hover); }
:focus-visible { outline: 2px solid var(--hilo); outline-offset: 2px; }

.skip {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  padding: 10px 16px; background: var(--tinta); color: #fff; border-radius: var(--radius-m);
}
.skip:focus { top: 12px; color: #fff; }

.container { max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.section { padding-top: 96px; padding-bottom: 96px; }
.band { background: var(--tela-alta); border-top: 1px solid var(--linea); border-bottom: 1px solid var(--linea); }
.muted { color: var(--tinta-suave); font-size: 15px; line-height: 1.6; }
.grow { flex-grow: 1; }

.eyebrow {
  margin-bottom: 12px;
  font-family: var(--font-mono); font-size: 13px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--hilo);
}
.eyebrow--dark { color: var(--hilo-claro); }

.section__title {
  margin: 0 0 48px;
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(30px, 4vw, 44px); line-height: 1.1;
}
.section__title--tight { margin-bottom: 16px; max-width: 760px; }
.section__title--flush { margin: 0; }
.section__lead { margin-bottom: 48px; color: var(--tinta-suave); font-size: 17px; max-width: 640px; }

.num { font-family: var(--font-mono); font-size: 14px; font-weight: 500; color: var(--hilo); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding: 0 20px; border-radius: var(--radius-m);
  font: inherit; font-weight: 500; text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s;
}
.btn--lg { min-height: 48px; padding: 0 24px; }
.btn--primary { background: var(--hilo); color: #fff; border: 0; }
.btn--primary:hover { background: var(--hilo-hover); color: #fff; }
.btn--outline { border: 1px solid var(--linea-fuerte); color: var(--tinta); }
.btn--outline:hover { border-color: var(--tinta); color: var(--tinta); background: var(--tela-alta); }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 10;
  background: var(--tela); border-bottom: 2px dashed var(--linea);
}
.header__inner {
  padding-top: 14px; padding-bottom: 14px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
/* Logo: isotipo + nombre en Raleway */
.logo {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px;
  color: var(--tinta); text-decoration: none;
}
.logo:hover { color: var(--tinta); }
.logo__mark { width: 56px; height: 43px; flex: none; }
.logo__text { font-family: var(--font-display); font-weight: 600; font-size: 22px; letter-spacing: -0.01em; white-space: nowrap; }
.logo--dark { color: var(--oscuro-texto); }

.nav { display: flex; gap: 28px; align-items: center; font-size: 15px; font-weight: 500; }
.nav a:not(.btn) { color: var(--tinta); text-decoration: none; }
.nav a:not(.btn):hover { color: var(--hilo); }

.nav-toggle {
  display: none; width: 44px; height: 44px; padding: 0; border: 0; background: none; cursor: pointer;
  flex-direction: column; align-items: center; justify-content: center; gap: 5px;
}
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--tinta); transition: transform .2s, opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 820px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px 16px 20px; background: var(--tela); border-bottom: 2px dashed var(--linea);
  }
  .nav.is-open { display: flex; }
  .nav a:not(.btn) { padding: 12px 0; border-bottom: 1px solid var(--linea); }
  .nav .btn { margin-top: 16px; }
}

/* ---------- Hero ---------- */
.hero { padding-top: 96px; padding-bottom: 80px; }
.hero__grid { display: flex; flex-wrap: wrap; gap: 56px; align-items: center; }
.hero__text { flex: 1 1 520px; display: flex; flex-direction: column; gap: 24px; }
.hero__text .eyebrow { margin: 0; }
.hero__title {
  margin: 0; font-family: var(--font-display); font-weight: 600;
  font-size: clamp(40px, 6vw, 68px); line-height: 1.04; letter-spacing: -0.02em;
}
.hero__lead { font-size: 19px; line-height: 1.6; color: var(--tinta-suave); max-width: 560px; }
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero__art { flex: 1 1 380px; display: flex; justify-content: center; }
.hero__frame {
  width: 100%; max-width: 440px; aspect-ratio: 1 / 1;
  border: 2px dashed var(--linea-fuerte); border-radius: var(--radius-l);
  display: flex; align-items: center; justify-content: center; background: var(--tela-alta);
}
.hero__frame img { width: 70%; height: auto; }

.stats {
  margin-top: 72px; padding: 40px 32px; border-radius: var(--radius-l);
  background: #b83a24; color: var(--oscuro-texto);
  outline: 1.5px dashed var(--oscuro-linea); outline-offset: -10px;
  display: grid; grid-template-columns: 1fr 1fr 1.7fr; gap: 0;
}
.stats > div { padding: 4px 32px; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; }
.stats > div + div { border-left: 1.5px dashed var(--oscuro-linea); }
.stats__num { font-family: var(--font-display); font-weight: 700; font-size: 64px; line-height: 1; color: white; }
.stats__label { margin-top: 10px; color: white; font-size: 16px; }
.plataformas {
  list-style: none; margin: 0; padding: 0; min-height: 64px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px;
}
.plataformas li {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px; border: 1.5px dashed var(--oscuro-linea); border-radius: 999px;
  background: var(--oscuro-caja); font-weight: 500; font-size: 17px;
}
.plataformas svg {
  width: 22px; height: 22px; fill: none; stroke: var(--hilo-claro);
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}

/* ---------- Grillas y tarjetas ---------- */
.grid { display: grid; gap: 24px; }
.grid--gap-20 { gap: 20px; }
.grid--240 { grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); }
.grid--250 { grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); }
.grid--320 { grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); }
.grid--340 { grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); }

.card { border: 1px solid var(--linea); border-radius: var(--radius-l); display: flex; flex-direction: column; }
.card--tela { padding: 28px; background: var(--tela); gap: 12px; }
.card--rubro { padding: 24px 28px; background: var(--tela-alta); gap: 10px; }
.card__title { margin: 0; font-family: var(--font-display); font-weight: 600; font-size: 21px; line-height: 1.25; }
.card__title--l { font-size: 22px; }
.caso {
  padding-top: 12px; border-top: 2px dashed var(--linea);
  font-family: var(--font-mono); font-size: 12px; font-weight: 500;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--denim);
}

/* Proyectos */
.project {
  background: var(--tela); border: 1px solid var(--linea); border-radius: var(--radius-l);
  overflow: hidden; display: flex; flex-direction: column;
}
.project__shot {
  height: 140px; background: var(--denim-suave); border-bottom: 1px solid var(--linea);
  display: flex; align-items: center; justify-content: center; padding: 16px; text-align: center;
}
.project__shot span {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--denim);
}
.project__shot img { width: 100%; height: 100%; object-fit: cover; }
.project__shot:has(img) { padding: 0; }
.project__shot.project__shot--logo { background: #fff; padding: 16px; }
.project__shot--logo img { object-fit: contain; }
.project__shot.project__shot--oscuro { background: #1a1a1a; }
.project__body { padding: 24px; display: flex; flex-direction: column; gap: 12px; flex-grow: 1; }
.project__type { font-family: var(--font-mono); font-size: 12px; color: var(--denim); }
.project__foot {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  min-height: 44px; padding-top: 12px; border-top: 2px dashed var(--linea);
  font-size: 13px; color: var(--tinta-suave);
}
.project__foot a {
  font-weight: 500; font-size: 15px; text-decoration: none;
  min-height: 44px; display: inline-flex; align-items: center;
}
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags span {
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  padding: 4px 8px; border-radius: var(--radius-s);
  background: var(--tela-alta); border: 1px solid var(--linea); color: var(--tinta-suave);
}

/* Pasos */
.step { display: flex; flex-direction: column; gap: 12px; padding-top: 20px; border-top: 2px dashed var(--hilo); }
.step .card__title { font-size: 20px; }

/* ---------- Equipo (fondo oscuro) ---------- */
.dark { background: var(--tinta); color: var(--oscuro-texto); }
.person {
  padding: 32px; border: 2px dashed var(--oscuro-linea); border-radius: var(--radius-l);
  display: flex; flex-direction: column; gap: 14px;
}
.person__photo {
  width: 88px; height: 88px; border-radius: var(--radius-l); background: var(--oscuro-caja); overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-size: 11px; color: var(--oscuro-suave);
}
.person__photo img { width: 100%; height: 100%; object-fit: cover; }
.person__name { margin: 0; font-family: var(--font-display); font-weight: 600; font-size: 26px; }
.person__role { color: var(--hilo-claro); font-weight: 500; }
.person__bio { color: var(--oscuro-suave); line-height: 1.6; }
.person__stack { font-family: var(--font-mono); font-size: 13px; color: var(--oscuro-suave); }
.person__links { display: flex; gap: 20px; flex-wrap: wrap; }
.person__links a { color: var(--oscuro-texto); font-weight: 500; min-height: 44px; display: inline-flex; align-items: center; }
.person__links a:hover { color: var(--hilo-claro); }

/* ---------- Contacto ---------- */
.contact { display: flex; flex-wrap: wrap; gap: 56px; align-items: center; justify-content: space-between; }
.contact__info { flex: 1 1 420px; max-width: 620px; display: flex; flex-direction: column; gap: 20px; }
.contact__info .eyebrow { margin: 0; }
.contact__lead { font-size: 17px; color: var(--tinta-suave); line-height: 1.6; }
.contact__seal { width: 220px; height: 220px; flex: none; }

/* Botón único de contacto: abre WhatsApp con un saludo ya escrito */
.btn.contact__wa {
  align-self: flex-start; gap: 12px; margin-top: 8px;
  min-height: 60px; padding: 0 32px; font-size: 18px;
  box-shadow: 0 6px 18px -8px rgba(184, 58, 36, .7);
  transition: background-color .15s, transform .15s, box-shadow .15s;
}
.btn.contact__wa:hover { transform: translateY(-2px); box-shadow: 0 10px 22px -8px rgba(184, 58, 36, .75); }
.contact__wa svg { width: 22px; height: 22px; fill: currentColor; }

/* ---------- Probalo: demos interactivas ---------- */
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.btn--blanco { background: #fff; color: var(--hilo); border: 0; }
.btn--blanco:hover { background: var(--tela); color: var(--hilo-hover); }

.demos__tabs { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; }
.demos__tab {
  display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 20px;
  border: 1.5px dashed var(--linea-fuerte); border-radius: 999px; background: var(--tela-alta);
  font: inherit; font-weight: 500; color: var(--tinta); cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s;
}
.demos__tab:hover { border-color: var(--hilo); }
.demos__tab[aria-selected="true"] { background: var(--tinta); border-color: var(--tinta); color: var(--tela); }
.demos__tab[aria-selected="true"] .num { color: #fff; }

.demo {
  padding: 40px; background: var(--tela-alta); border: 1px solid var(--linea); border-radius: var(--radius-l);
  outline: 1.5px dashed var(--linea); outline-offset: -10px;
}
.demo__grid { display: grid; grid-template-columns: 1fr 1.25fr; gap: 48px; align-items: start; }
.demo__intro, .demo__controles { display: flex; flex-direction: column; gap: 20px; }
.demo__controles .btn { align-self: flex-start; }

/* Campos de formulario */
.campo { display: flex; flex-direction: column; gap: 8px; margin: 0; padding: 0; border: 0; min-width: 0; }
.campo label, .campo legend { padding: 0; font-weight: 500; font-size: 15px; }
.campo legend { margin-bottom: 8px; }
.campo output { font-family: var(--font-mono); color: var(--hilo); }
.campo__opcional { color: var(--tinta-suave); font-weight: 400; }
.campo input[type="text"], .campo input[type="number"], .campo select {
  min-height: 48px; padding: 0 14px; border: 1px solid var(--linea-fuerte); border-radius: var(--radius-m);
  background: var(--tela); color: var(--tinta); font: inherit;
}
.campo input[type="range"] { width: 100%; accent-color: var(--hilo); min-height: 32px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip input, .color input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chip span {
  display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; cursor: pointer;
  border: 1px solid var(--linea-fuerte); border-radius: 999px; background: var(--tela); font-size: 15px;
}
.chip input:checked + span { background: var(--tinta); border-color: var(--tinta); color: var(--tela); }
.chip input:focus-visible + span, .color:has(input:focus-visible) { outline: 2px solid var(--hilo); outline-offset: 2px; }
.colores { display: flex; gap: 12px; }
.color {
  width: 40px; height: 40px; border-radius: 50%; background: var(--muestra); cursor: pointer;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.35);
}
.color:has(input:checked) { box-shadow: 0 0 0 3px var(--tela-alta), 0 0 0 5px var(--muestra); }

/* 01 · Cotizador */
.progreso { display: flex; gap: 6px; margin-bottom: 16px; }
.progreso span { flex: 1; height: 4px; border-radius: 2px; background: var(--linea); }
.progreso span.is-hecho { background: var(--hilo); }
.cotizador__paso { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--tinta-suave); }
.cotizador__pregunta { margin: 6px 0 20px; font-family: var(--font-display); font-weight: 600; font-size: 26px; line-height: 1.2; }
.opciones { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 10px; }
.opcion {
  min-height: 56px; padding: 12px 16px; text-align: left; cursor: pointer;
  border: 1px solid var(--linea-fuerte); border-radius: var(--radius-m); background: var(--tela);
  font: inherit; font-weight: 500; color: var(--tinta);
  transition: border-color .15s, background-color .15s, transform .15s;
}
.opcion:hover { border-color: var(--hilo); background: var(--tela-alta); transform: translateY(-1px); }
.cotizador__volver {
  margin-top: 16px; min-height: 44px; padding: 0; border: 0; background: none; cursor: pointer;
  font: inherit; color: var(--tinta-suave);
}
.cotizador__volver:hover { color: var(--hilo); }

.ficha { padding: 28px; border: 2px dashed var(--hilo); border-radius: var(--radius-l); background: var(--tela); }
.ficha__titulo {
  margin-bottom: 16px; font-family: var(--font-mono); font-size: 13px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--hilo);
}
.ficha__datos { margin: 0; display: flex; flex-direction: column; }
.ficha__datos > div { display: grid; grid-template-columns: 170px 1fr; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--linea); }
.ficha__datos dt { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--tinta-suave); padding-top: 3px; }
.ficha__datos dd { margin: 0; font-weight: 500; }
.ficha__datos ul { margin: 0; padding-left: 18px; font-weight: 400; }
.ficha__solucion { font-family: var(--font-display); font-size: 22px; font-weight: 700 !important; color: var(--hilo); }
.ficha__nota { margin-top: 16px; font-size: 14px; color: var(--tinta-suave); }
.ficha__acciones { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }

/* 02 · Tu web en 30 segundos: un celular con la web adentro */
.telefono {
  --marca: var(--hilo);
  width: min(290px, 100%); aspect-ratio: 290 / 560; margin: 0 auto; padding: 10px;
  background: var(--tinta); border-radius: 40px; box-shadow: 0 24px 48px -24px rgba(0,0,0,.45);
}
.sitio {
  height: 100%; overflow: hidden; border-radius: 30px; background: #fff;
  font-size: 13px; line-height: 1.4; color: #222;
}
.sitio__barra { display: flex; align-items: center; gap: 8px; padding: 26px 16px 12px; border-bottom: 1px solid #eee; }
.sitio__logo {
  width: 28px; height: 28px; border-radius: 8px; flex: none; background: var(--marca); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700;
}
.sitio__nombre { flex: 1; font-weight: 700; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sitio__menu { width: 16px; height: 10px; border-top: 2px solid #222; border-bottom: 2px solid #222; position: relative; }
.sitio__menu::after { content: ""; position: absolute; left: 0; right: 0; top: 2px; border-top: 2px solid #222; }
.sitio__hero { padding: 22px 16px; background: var(--marca); color: #fff; transition: background-color .2s; }
.sitio__titulo { font-family: var(--font-display); font-weight: 700; font-size: 22px; line-height: 1.15; }
.sitio__bajada { margin-top: 6px; opacity: .9; }
.sitio__wa {
  display: inline-block; margin-top: 14px; padding: 8px 14px; border-radius: 999px;
  background: #25d366; color: #fff; font-weight: 700; font-size: 12px;
}
.sitio__seccion { padding: 16px 16px 8px; font-weight: 700; font-size: 15px; }
.sitio__items { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 0 16px; }
.sitio__item { display: flex; flex-direction: column; gap: 2px; }
.sitio__foto {
  width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: 8px; margin-bottom: 4px;
  background: color-mix(in srgb, var(--marca) 15%, #fff);
}
.sitio__item-titulo { font-weight: 700; font-size: 11px; line-height: 1.2; }
.sitio__item-detalle { font-size: 10px; color: #777; overflow-wrap: anywhere; hyphens: auto; }
.sitio__info {
  display: flex; justify-content: space-between; gap: 8px; margin: 16px; padding: 12px;
  border-radius: 10px; background: #f4f4f4; font-size: 11px;
}
.sitio__info span:last-child { color: var(--marca); font-weight: 700; white-space: nowrap; }

/* 03 · Horas que perdés: mismo panel rojo que las estadísticas */
.calculo {
  padding: 36px 32px; border-radius: var(--radius-l); background: var(--hilo); color: #fff;
  outline: 1.5px dashed rgba(255,255,255,.45); outline-offset: -10px;
  display: flex; flex-direction: column; gap: 16px;
}
.calculo__titulo { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; opacity: .85; }
.calculo__num { font-family: var(--font-display); font-weight: 700; font-size: 72px; line-height: 1; }
.calculo__num small { display: block; margin-top: 6px; font-size: 20px; font-weight: 600; }
.calculo__datos { margin: 0; display: flex; flex-direction: column; }
.calculo__datos > div[hidden] { display: none; }
.calculo__datos > div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-top: 1.5px dashed rgba(255,255,255,.4); }
.calculo__datos dt { opacity: .85; }
.calculo__datos dd { margin: 0; font-weight: 700; }
.calculo .btn { align-self: flex-start; margin-top: 8px; text-align: center; }

@media (max-width: 820px) {
  .demo { padding: 28px 24px; }
  .demo__grid { grid-template-columns: 1fr; gap: 32px; }
}

/* ---------- Footer ---------- */
.footer { background: var(--tinta); color: var(--oscuro-suave); }
.footer__inner {
  padding-top: 40px; padding-bottom: 40px;
  display: flex; flex-wrap: wrap; gap: 24px; justify-content: space-between; align-items: center;
}
.footer p { font-size: 14px; }

/* ---------- Costura: una aguja cose las líneas punteadas al aparecer ---------- */
.step, .project__foot { position: relative; }
/* Cada puntada: hilo con puntas redondeadas, brillo arriba, vueltas del hilo,
   sombra abajo y los agujeritos donde entró la aguja. Una versión por color de hilo. */
:root {
  --puntada-clara: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cg stroke-linecap='round'%3E%3Ccircle cx='2' cy='4.4' r='.7' fill='%23000' fill-opacity='.22'/%3E%3Ccircle cx='10' cy='4.4' r='.7' fill='%23000' fill-opacity='.22'/%3E%3Cline x1='4' y1='4.9' x2='8.3' y2='4.9' stroke='%23000' stroke-opacity='.18' stroke-width='2.6'/%3E%3Cline x1='4' y1='4' x2='8' y2='4' stroke='%23d3cabb' stroke-width='2.6'/%3E%3Cpath d='M4.6 5L5.4 3M5.8 5L6.6 3M7 5L7.8 3' stroke='%23000' stroke-opacity='.16' stroke-width='.5'/%3E%3Cline x1='4.2' y1='3.3' x2='7.8' y2='3.3' stroke='%23fff' stroke-opacity='.6' stroke-width='.6'/%3E%3C/g%3E%3C/svg%3E");
  --puntada-roja: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cg stroke-linecap='round'%3E%3Ccircle cx='2' cy='4.4' r='.7' fill='%23000' fill-opacity='.22'/%3E%3Ccircle cx='10' cy='4.4' r='.7' fill='%23000' fill-opacity='.22'/%3E%3Cline x1='4' y1='4.9' x2='8.3' y2='4.9' stroke='%23000' stroke-opacity='.18' stroke-width='2.6'/%3E%3Cline x1='4' y1='4' x2='8' y2='4' stroke='%23b83a24' stroke-width='2.6'/%3E%3Cpath d='M4.6 5L5.4 3M5.8 5L6.6 3M7 5L7.8 3' stroke='%23000' stroke-opacity='.22' stroke-width='.5'/%3E%3Cline x1='4.2' y1='3.3' x2='7.8' y2='3.3' stroke='%23fff' stroke-opacity='.4' stroke-width='.6'/%3E%3C/g%3E%3C/svg%3E");
}
.header { --costura-img: var(--puntada-clara); --aguja-color: var(--linea-fuerte); }
.step { --costura-img: var(--puntada-roja); }
.project__foot { --costura-img: var(--puntada-clara); }

/* La clase js-costura la pone el <head> solo si hay animaciones permitidas */
.js-costura .costura { border-color: transparent; }
.js-costura .costura::before,
.js-costura .costura::after { content: ""; position: absolute; pointer-events: none; }

/* El hilo: la línea punteada, que se va revelando de izquierda a derecha */
.js-costura .costura::before {
  left: 0; top: -5px; width: 100%; height: 8px;
  background: var(--costura-img) left center / 12px 8px repeat-x;
  clip-path: inset(0 100% 0 0);
}
.js-costura .costura--abajo::before { top: auto; bottom: -5px; }

/* La aguja: la punta (abajo a la derecha) va pegada al frente del hilo */
.js-costura .costura::after {
  left: 0; top: -18px; width: 26px; height: 18px; margin-left: -26px; opacity: 0;
  background: var(--aguja-color, var(--tinta-suave));
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 18'%3E%3Cpath fill-rule='evenodd' transform='translate(2 3) rotate(32)' d='M0 0C0-1.6 1-1.6 1.6-1.6L20-1 26 0 20 1 1.6 1.6C1 1.6 0 1.6 0 0ZM2.2-.6H6.4V.6H2.2Z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 18'%3E%3Cpath fill-rule='evenodd' transform='translate(2 3) rotate(32)' d='M0 0C0-1.6 1-1.6 1.6-1.6L20-1 26 0 20 1 1.6 1.6C1 1.6 0 1.6 0 0ZM2.2-.6H6.4V.6H2.2Z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.js-costura .costura--abajo::after { top: auto; bottom: -2px; }

.js-costura .costura.is-cosida::before {
  animation: costura-hilo var(--costura-dur, 4s) ease-in-out var(--costura-delay, 0s) forwards;
}
.js-costura .costura.is-cosida::after {
  animation:
    costura-aguja var(--costura-dur, 4s) ease-in-out var(--costura-delay, 0s) forwards,
    costura-puntada .25s ease-in-out var(--costura-delay, 0s) var(--costura-puntadas, 16) alternate;
}
/* El header es mucho más ancho: más tiempo para que la aguja vaya al mismo ritmo */
.js-costura .header.costura { --costura-dur: 10s; --costura-puntadas: 40;
}
/* Marco de la imagen principal: el borde lo dibuja un SVG que arma main.js */
.hero__frame { position: relative; }
.js-costura .costura-marco { border-color: transparent; }
.marco-costura {
  position: absolute; left: -2px; top: -2px; width: calc(100% + 4px); height: calc(100% + 4px);
  overflow: visible; pointer-events: none;
}
/* Mismas capas que las puntadas de las líneas: agujeros, sombra, hilo, vueltas y brillo */
.marco-costura .hilo path { fill: none; stroke-linecap: round; stroke-dasharray: 4 8; }
.marco-costura .hilo .agujeros { stroke: rgba(0,0,0,.25); stroke-width: 1.4; stroke-dasharray: 0 4 0 8; stroke-dashoffset: 6; }
.marco-costura .hilo .sombra { stroke: rgba(0,0,0,.18); stroke-width: 2.6; transform: translate(.3px, .9px); }
.marco-costura .hilo .base { stroke: var(--linea-fuerte); stroke-width: 2.6; }
.marco-costura .hilo .vueltas { stroke: rgba(0,0,0,.18); stroke-width: 2.2; stroke-linecap: butt; stroke-dasharray: 0 .6 .5 .6 .5 .6 .5 8.7; }
.marco-costura .hilo .brillo { stroke: rgba(255,255,255,.45); stroke-width: .6; stroke-dasharray: 3.6 8.4; stroke-dashoffset: -.2; transform: translateY(-.6px); }
.marco-costura .aguja { fill: var(--linea-fuerte); }

@keyframes costura-hilo { to { clip-path: inset(0 0 0 0); } }
@keyframes costura-aguja {
  0%   { left: 0;    opacity: 0; }
  6%   {             opacity: 1; }
  90%  {             opacity: 1; }
  100% { left: 100%; opacity: 0; }
}
@keyframes costura-puntada { to { transform: translateY(4px); } }

/* ---------- Celular ---------- */
@media (max-width: 600px) {
  .container { padding-left: 16px; padding-right: 16px; }
  .section { padding-top: 64px; padding-bottom: 64px; }
  .hero { padding-top: 48px; padding-bottom: 56px; }
  .hero__grid { gap: 40px; }
  .hero__text, .hero__art, .contact__info { flex-basis: 100%; }
  .hero__lead { font-size: 17px; }
  .hero__actions .btn { flex: 1 1 100%; }
  .stats { margin-top: 48px; padding: 16px 24px; grid-template-columns: 1fr; }
  .stats > div { padding: 24px 4px; }
  .stats > div + div { border-left: 0; border-top: 1.5px dashed var(--oscuro-linea); }
  .stats__num { font-size: 52px; }
  .plataformas { min-height: 0; }
  .person { padding: 24px; }
  .btn.contact__wa { align-self: stretch; }
  .contact__seal { width: 160px; height: 160px; margin: 0 auto; }
  .card--tela, .card--rubro { padding: 24px; }
  .demos__tab { flex: 1 1 100%; }
  .demo { padding: 24px 16px; outline-offset: -6px; }
  .cotizador__pregunta { font-size: 22px; }
  .ficha { padding: 20px 16px; }
  .ficha__datos > div { grid-template-columns: 1fr; gap: 4px; }
  .ficha__acciones .btn, .demo__controles .btn, .calculo .btn { align-self: stretch; flex: 1 1 100%; }
  .calculo { padding: 28px 20px; }
  .calculo__num { font-size: 56px; }
}
