/* SalesJorge · landing
   Formal y minimalista: blanco roto, tinta y el azul de la marca. Las piezas de producto
   (logo, wordmark, popup, herramientas, capturas) son las de la extensión. */

:root {
  --bg: #F7F7F5;
  --surface: #FFFFFF;
  --surface-2: #FBFBFA;
  --ink: #0E1116;
  --ink-2: #3F4654;
  --ink-3: #7A808C;
  --line: #E5E5E1;
  --line-2: #EFEFEC;
  --accent: #0176D3;
  --accent-d: #014486;
  --accent-l: #57A3FD;
  --accent-soft: #EAF3FC;
  --brand-grad: linear-gradient(120deg, #22c3f5, #0176d3 45%, #7c5cff);

  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
  --mono: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;
  --script: "Pacifico", "Segoe Script", "Brush Script MT", cursive;

  --sh-1: 0 1px 2px rgba(14, 17, 22, .04), 0 2px 6px rgba(14, 17, 22, .04);
  --sh-2: 0 1px 2px rgba(14, 17, 22, .05), 0 8px 24px rgba(14, 17, 22, .06), 0 24px 48px rgba(14, 17, 22, .05);
  --sh-3: 0 1px 2px rgba(14, 17, 22, .06), 0 12px 32px rgba(14, 17, 22, .08), 0 40px 80px rgba(14, 17, 22, .08);

  --top: 64px;
  /* Movimiento: una curva y tres duraciones para todas las transiciones */
  --ease: cubic-bezier(.2, .7, .2, 1);
  --t-fast: .2s;
  --t: .35s;
  --t-slow: .7s;
  /* Ritmo vertical: el mismo aire en todas las cabeceras de sección */
  --head-pad: calc(var(--top) + 28px);
  --head-gap: 28px;
  --eyebrow-gap: 12px;
  --gutter: max(16px, 4vw);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background-color: var(--bg);
  background-image: radial-gradient(rgba(14, 17, 22, .075) 1px, transparent 1.2px);
  background-size: 24px 24px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; }
img { display: block; }
.mono { font-family: var(--mono); }

em {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  color: var(--accent);
  letter-spacing: -0.01em;
}

.eyebrow {
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: var(--eyebrow-gap);
}
.display {
  font-size: clamp(40px, 5.4vw, 76px);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.04em;
}
.display em { font-size: 1.08em; letter-spacing: -0.015em; }
.display .w { display: inline-block; }
.display, .h2, .maze-title, .step h3, .note strong, .metric p { text-wrap: balance; }
.lead, .step p, .note span, .count-label { text-wrap: pretty; }
.h2 {
  font-size: clamp(30px, 3.6vw, 50px);
  font-weight: 600;
  line-height: 1.06;
  letter-spacing: -0.035em;
}
.h2 em { font-size: 1.08em; }
.lead {
  font-size: clamp(16px, 1.3vw, 19px);
  color: var(--ink-2);
  max-width: 540px;
  margin-top: 24px;
}

/* ---------- Marca ---------- */
.logo { width: 30px; height: 30px; object-fit: contain; }
.wordmark {
  font-family: var(--script);
  font-size: 20px;
  line-height: 2;
  padding-bottom: 3px;
  background: var(--brand-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.brand { display: inline-flex; align-items: center; gap: 10px; }

/* Icono de herramienta: trazo SVG en su color, sobre una pastilla tintada */
.ti {
  flex: none;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: var(--k);
  background: color-mix(in srgb, var(--k) 11%, #fff);
}
.ti svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Botones ---------- */
.pill {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
  white-space: nowrap;
}
.pill-dark { background: var(--ink); color: #fff; box-shadow: var(--sh-1); }
.pill-dark:hover { background: #22272F; }
.pill-ghost { border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
.pill-ghost:hover { border-color: #CFCFCA; }
.pill-sm { height: 36px; padding: 0 16px; font-size: 14px; }
.pill-lg { height: 60px; padding: 0 30px; font-size: 17px; }
.pill:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------- Barra superior ---------- */
.progress { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 60; pointer-events: none; }
.progress-bar { display: block; height: 100%; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }

.topbar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--top);
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 0 var(--gutter);
  background: rgba(247, 247, 245, .72);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid rgba(229, 229, 225, .8);
}
.nav { display: flex; gap: 28px; margin-left: auto; }
.nav a { font-size: 14px; color: var(--ink-2); transition: color var(--t-fast) var(--ease); }
.nav a:hover { color: var(--ink); }

/* Selector de idioma: dos banderas */
.lang { display: flex; align-items: center; gap: 4px; padding: 3px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.lang-btn { display: grid; place-items: center; width: 30px; height: 24px; border-radius: 999px; opacity: .45; transition: opacity var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease); }
.lang-btn:hover { opacity: .85; }
.lang-btn.is-on { opacity: 1; background: var(--accent-soft); }
.lang-btn svg { width: 20px; height: 13px; border-radius: 2px; box-shadow: 0 0 0 1px rgba(14, 17, 22, .12); }
.lang-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* En inglés no se pinta nada hasta que main.js ha traducido (máx. 5 s) */
.i18n-pending body { visibility: hidden; }

.caret {
  display: inline-block;
  width: 1.5px;
  height: 1.1em;
  margin-left: 1px;
  vertical-align: text-bottom;
  background: currentColor;
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ---------- Escenarios fijados ---------- */
.act { position: relative; }
.stage { position: relative; height: 100vh; overflow: hidden; padding-top: var(--top); }

.sk { display: block; height: 8px; border-radius: 4px; background: #EDEDEA; }
.sk.tall { height: 14px; }
.w30 { width: 30%; } .w40 { width: 40%; } .w50 { width: 50%; } .w60 { width: 60%; }
.w70 { width: 70%; } .w80 { width: 80%; } .w90 { width: 90%; }

/* ---------- Acto I · Hero ---------- */
.hero-stage { display: grid; place-items: center; --setup-w: min(1040px, 92vw); }

/* Ventanas de fondo que asoman por detrás del Setup: el resto del caos */
.ghost {
  position: absolute;
  z-index: 2;
  width: min(440px, 38vw);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--sh-2);
  overflow: hidden;
}
.ghost-a { left: calc(50% - var(--setup-w) / 2 - 44px); top: calc(var(--top) + 12px); transform: rotate(-2.5deg); }
.ghost-b { right: calc(50% - var(--setup-w) / 2 - 56px); top: calc(var(--top) + 30px); transform: rotate(2deg); }
.ghost-bar { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 12px; border-bottom: 1px solid var(--line-2); font-size: 12px; }
.ghost-bar b { font-weight: 600; }
.ghost-bar > span:last-child { margin-left: auto; color: var(--ink-3); font-size: 11px; }
.ghost-body { padding: 10px 12px; display: flex; flex-direction: column; gap: 4px; font-size: 10.5px; color: var(--ink-2); height: 150px; }
.ghost-body span:nth-child(3) { color: var(--bad); }
.ghost-flow { flex-direction: row; flex-wrap: wrap; align-content: flex-start; gap: 8px; }
.fn { font-style: normal; font-size: 11px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); }
.fn.warn { border-color: #F1C9C7; background: #FDF1F0; color: var(--bad); }

.setup {
  position: absolute;
  inset: calc(var(--top) + 24px) 0 48px;
  margin: auto;
  width: var(--setup-w);
  height: min(560px, calc(100vh - var(--top) - 110px));
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--sh-3);
  z-index: 3;
}
.setup-bar { display: flex; align-items: center; gap: 14px; height: 48px; padding: 0 16px; border-bottom: 1px solid var(--line-2); }
.setup-cloud { width: 30px; height: 18px; border-radius: 9px; background: var(--accent-soft); border: 1px solid #CFE3F7; flex: none; }
.setup-title { font-weight: 600; font-size: 14px; }
.setup-crumbs { flex: 1; min-width: 0; font-size: 12px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.setup-crumbs i { font-style: normal; color: #C9CBC6; margin: 0 4px; }
.setup-search {
  flex: none;
  width: 220px;
  height: 30px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid #BCD8F3;
  border-radius: 8px;
  box-shadow: 0 0 0 3px var(--accent-soft);
  font-size: 12px;
  color: var(--ink);
}
.setup-avatar { width: 26px; height: 26px; border-radius: 50%; background: #E4E6EA; flex: none; }
.setup-tabs {
  display: flex;
  gap: 4px;
  padding: 8px 10px 0;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
  position: relative;
  z-index: 2;
}
.tab {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 7px 7px 0 0;
  background: #F3F3F1;
  font-size: 11px;
  color: var(--ink-2);
  white-space: nowrap;
  will-change: transform;
}
.tab span { overflow: hidden; text-overflow: ellipsis; }
.tab::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 2px; background: #C9D3DE; }
.tab.is-current { background: var(--surface); color: var(--ink); }
.tab.is-current::before { background: var(--accent); }
.tab.is-loading::before {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: none;
  border: 1.5px solid #D5D8DD;
  border-top-color: var(--accent);
  animation: spin .9s linear infinite;
}
.tab-more {
  flex: none;
  align-self: center;
  margin: 0 2px 4px 4px;
  padding: 2px 7px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-size: 10.5px;
  font-weight: 600;
}
.setup-body { flex: 1; display: flex; min-height: 0; }
.setup-side { width: 21%; padding: 14px 10px; border-right: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 2px; overflow: hidden; }
.side-i { font-size: 11.5px; color: var(--ink-2); padding: 6px 10px; border-radius: 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-i.is-on { background: var(--accent-soft); color: var(--accent-d); font-weight: 600; }
.setup-main { flex: 1; padding: 18px 22px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.setup-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.setup-h b { display: block; font-size: 17px; font-weight: 600; letter-spacing: -0.02em; }
.setup-h small { font-size: 11.5px; color: var(--ink-3); }
.setup-btns { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.setup-btns span { font-size: 11px; padding: 5px 10px; border: 1px solid var(--line); border-radius: 7px; color: var(--accent-d); white-space: nowrap; }
.setup-table { flex: 1; display: flex; flex-direction: column; border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; min-height: 0; }
.setup-row {
  display: grid;
  grid-template-columns: 1.3fr 1.5fr 1fr .5fr;
  gap: 14px;
  align-items: center;
  padding: 0 14px;
  flex: 1;
  min-height: 0;
  border-bottom: 1px solid var(--line-2);
  font-size: 11.5px;
  color: var(--ink-2);
  white-space: nowrap;
}
.setup-row span { overflow: hidden; text-overflow: ellipsis; }
.setup-row:first-child { background: var(--surface-2); font-size: 10px; font-weight: 600; letter-spacing: .06em; color: var(--ink-3); }
.setup-row:last-child { border-bottom: 0; }
.setup-row .api { font-family: var(--mono); font-size: 11px; }
.setup-row.is-hit { background: var(--accent-soft); box-shadow: inset 3px 0 0 var(--accent); color: var(--ink); }
.setup-row.is-hit .api { color: var(--accent-d); font-weight: 500; }

/* Lo que delata el caos: notas pegadas y una búsqueda que no termina nunca */
.note-stick {
  position: absolute;
  z-index: 3;
  width: 200px;
  padding: 12px 14px 14px;
  background: #FFF7D6;
  border: 1px solid #EFE2A8;
  border-radius: 4px;
  box-shadow: var(--sh-2);
  font-family: var(--serif);
  font-style: italic;
  font-size: 17px;
  line-height: 1.2;
  color: #4A4330;
}
.note-1 { right: -26px; bottom: 54px; transform: rotate(3deg); }
.note-2 { left: -22px; bottom: 26px; transform: rotate(-4deg); width: 180px; }
.setup-loading {
  position: absolute;
  z-index: 3;
  right: 210px;
  top: 150px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--sh-2);
  font-size: 11px;
  color: var(--ink-2);
}
.setup-loading .spinner { width: 14px; height: 14px; border-width: 1.5px; border-top-color: var(--accent); }
.setup-foot { position: absolute; left: 0; right: 0; bottom: -34px; text-align: center; font-size: 13px; color: var(--ink-3); }

@media (max-width: 1100px), (max-height: 700px) {
  .ghost { display: none; }
}

.hero-grid {
  position: relative;
  z-index: 2;
  width: min(1200px, 92vw);
  display: grid;
  grid-template-columns: 1.02fr 1fr;
  gap: 56px;
  align-items: center;
}
.hero-grid > * { min-width: 0; }
.hero-copy .display { max-width: 640px; }
.hero-actions { display: flex; gap: 12px; margin-top: 34px; flex-wrap: wrap; }

.browser-wrap { position: relative; perspective: 1600px; }
/* Capa del giro del parallax: conserva el 3D del navegador con la perspectiva del contenedor */
.browser-tilt { transform-style: preserve-3d; }
/* Chispas alrededor del popup del hero, por encima del navegador y sin capturar el ratón */
.spark-hero { position: absolute; left: -60px; top: -60px; width: calc(100% + 120px); height: calc(100% + 120px); pointer-events: none; z-index: 2; }
.browser {
  position: relative;
  aspect-ratio: 1.12;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--sh-3);
  transform-style: preserve-3d;
}
.b-bar { display: flex; align-items: center; gap: 12px; height: 42px; padding: 0 12px; border-bottom: 1px solid var(--line-2); }
.b-dots { display: inline-flex; gap: 6px; }
.b-dots i { width: 9px; height: 9px; border-radius: 50%; background: #DADBD7; }
.b-url {
  flex: 1;
  min-width: 0;
  height: 26px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 7px;
  background: #F2F2EF;
  font-size: 11.5px;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.b-exts { display: inline-flex; align-items: center; gap: 8px; }
.b-ext { width: 14px; height: 14px; border-radius: 4px; background: #E3E4E1; }
.ext-icon { position: relative; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 7px; background: var(--accent-soft); }
.ext-icon img { width: 20px; height: 20px; object-fit: contain; }
.halo {
  position: absolute;
  inset: -1px;
  border-radius: 8px;
  border: 1.5px solid var(--accent);
  opacity: 0;
  animation: halo 2.2s var(--ease) infinite;
}
@keyframes halo { 0% { transform: scale(1); opacity: .7; } 100% { transform: scale(1.75); opacity: 0; } }
.b-body { padding: 26px 24px; display: flex; flex-direction: column; gap: 14px; }

/* Popup: captura real de la pantalla de inicio del popup (640×600), colgando del icono */
.popup {
  position: absolute;
  top: 48px;
  right: 12px;
  width: 80%;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--sh-3);
  overflow: hidden;
  background: #EEF3FB;
  transform-origin: 92% 0;
}
.popup-shot { width: 100%; height: auto; }

.scroll-hint {
  position: absolute;
  left: 0; right: 0; bottom: 18px;
  text-align: center;
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-3);
  z-index: 4;
}
.scroll-hint .arrow { display: inline-block; animation: nudge 1.8s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateY(4px); } }

/* Al cargar se ve SalesJorge (el hero); el Setup caótico solo aparece al bajar */
.js .setup,
.js .ghost { opacity: 0; }
.js .hero-copy,
.js .browser-wrap { animation: rise .9s cubic-bezier(.2, .7, .2, 1) both; }
.js .browser-wrap { animation-delay: .15s; }
/* Con `translate` (no `transform`) para no chocar con el giro del parallax del navegador */
@keyframes rise { from { opacity: 0; translate: 0 18px; } }

/* ---------- Acto II · El laberinto ---------- */
.maze-layers { position: absolute; inset: 0; }
.maze-back {
  position: absolute;
  left: 50%;
  top: 0;
  width: min(1240px, 116vw);
  margin-left: calc(min(1240px, 116vw) / -2);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
  opacity: .6;
}
.maze-card {
  height: 96px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--sh-1);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.maze-card b { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.maze-card .sk { height: 6px; }
.maze-front { position: absolute; inset: 0; pointer-events: none; }
.mk {
  position: absolute;
  width: 10px;
  height: 10px;
  margin: -5px 0 0 -5px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .9);
}
.mk::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 50%;
  border: 1.5px solid var(--accent);
  animation: wave 1.8s ease-out infinite;
  animation-delay: var(--d, 0s);
}
@keyframes wave { 0% { transform: scale(1); opacity: .8; } 100% { transform: scale(4); opacity: 0; } }

.maze-center {
  position: absolute;
  inset: var(--top) 0 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  z-index: 2;
}
.maze-center::before {
  content: "";
  position: absolute;
  inset: 18% -10%;
  background: radial-gradient(closest-side, rgba(247, 247, 245, .96), rgba(247, 247, 245, .85) 60%, rgba(247, 247, 245, 0));
  z-index: -1;
}
.maze-title { font-size: 18px; font-weight: 500; color: var(--ink-2); letter-spacing: -0.01em; }
.crumbs-view {
  width: 100%;
  overflow: hidden;
  margin: 34px 0 30px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.crumbs {
  display: inline-flex;
  align-items: baseline;
  gap: .32em;
  padding: .1em 10vw;
  white-space: nowrap;
  font-size: clamp(38px, 6.4vw, 96px);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 1.1;
  will-change: transform;
}
.crumb { color: #D3D4CF; transition: color var(--t) var(--ease); }
.crumb.lit { color: var(--ink); }
.crumb em { color: inherit; }
.crumb.lit em { color: var(--accent); }
.crumb-sep { color: #DEDFDA; font-weight: 400; }
.maze-count { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.count-num { font-size: clamp(40px, 4.4vw, 60px); font-weight: 600; letter-spacing: -0.04em; font-variant-numeric: tabular-nums; line-height: 1; }
.count-label { font-size: 14px; color: var(--ink-3); }
.maze-caption {
  position: absolute;
  left: 0; right: 0; bottom: 7vh;
  width: fit-content;
  max-width: calc(100% - 2 * var(--gutter));
  margin: 0 auto;
  padding: 6px 22px 8px;
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(22px, 2.2vw, 30px);
  color: var(--ink-2);
  background: rgba(255, 255, 255, .92);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--sh-1);
  z-index: 3;
}
.maze-dialog {
  position: absolute;
  inset: 0;
  margin: auto;
  width: min(460px, 88vw);
  height: fit-content;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--sh-3);
  z-index: 4;
}
.maze-dialog strong { display: block; font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
.maze-dialog span { font-size: 13.5px; color: var(--ink-3); }
.spinner { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line); border-top-color: var(--ink-2); animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.js .maze-caption, .js .maze-dialog { opacity: 0; }

/* ---------- Acto III · Herramientas ---------- */
.tools-stage {
  display: flex;
  flex-direction: column;
  gap: var(--head-gap);
  padding: var(--head-pad) var(--gutter) 28px;
}
.p-head { text-align: center; position: relative; z-index: 2; }

.p-line { position: absolute; left: 50%; top: 0; width: 1px; height: 100%; background: var(--accent); transform-origin: 50% 0; z-index: 1; }
.p-icon { position: absolute; left: 50%; top: 50%; --s: min(280px, 38vh, 62vw); width: var(--s); height: var(--s); margin: calc(var(--s) / -2) 0 0 calc(var(--s) / -2); object-fit: contain; z-index: 3; }

.fams {
  position: relative;
  z-index: 2;
  width: min(1240px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}
.fam {
  padding: 14px 12px 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--sh-1);
  transition: border-color var(--t) var(--ease);
}
.fam.is-on { border-color: #BCD8F3; }
.fam-h { display: flex; align-items: baseline; justify-content: space-between; padding: 0 4px 10px; border-bottom: 1px solid var(--line-2); margin-bottom: 6px; }
.fam-h b { font-size: 14px; font-weight: 600; letter-spacing: -0.01em; }
.fam-h span { font-family: var(--mono); font-size: 11.5px; color: var(--ink-3); }
.fam-list { display: flex; flex-direction: column; }
.tl { display: flex; align-items: center; gap: 10px; padding: 7px 4px; border-radius: 9px; min-width: 0; }
.tl div { min-width: 0; }
.tl b { display: block; font-size: 13px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tl small { display: block; font-size: 11.5px; color: var(--ink-3); line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.fam-caption {
  position: relative;
  z-index: 2;
  text-align: center;
  font-size: 15px;
  color: var(--ink-2);
  min-height: 1.6em;
}
.fam-caption strong { font-weight: 600; color: var(--ink); margin-right: 8px; }
.fam-caption span { font-family: var(--serif); font-style: italic; font-size: 20px; }
.js .fam-caption { opacity: 0; }

.p-dots { position: absolute; right: calc(var(--gutter) * .45); top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 12px; z-index: 4; }
.p-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--line); transition: background-color var(--t) var(--ease), transform var(--t) var(--ease); }
.p-dots i.on { background: var(--accent); transform: scale(1.3); }

/* ---------- Acto IV · Demo ---------- */
.demo-stage { display: flex; flex-direction: column; gap: var(--head-gap); padding: var(--head-pad) var(--gutter) 28px; }
.demo-head { width: min(1240px, 100%); margin: 0 auto; }

.demo-grid {
  flex: 1;
  min-height: 0;
  width: min(1240px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, .72fr) minmax(0, 1.75fr);
  grid-template-rows: minmax(0, 1fr);
  gap: 40px;
  align-items: center;
}
/* La columna de pasos es una ventana: el carril se desliza para dejar el paso activo arriba */
.steps-col {
  position: relative;
  align-self: stretch;
  min-height: 0;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(transparent, #000 16px, #000 80%, transparent);
  mask-image: linear-gradient(transparent, #000 16px, #000 80%, transparent);
}
.steps-track {
  position: relative;
  display: flex;
  flex-direction: column;
  padding-top: 6px;
  transition: transform var(--t-slow) var(--ease);
  will-change: transform;
}
.steps-group {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.steps-group .ti { width: 26px; height: 26px; border-radius: 7px; }
.steps-group .ti svg { width: 14px; height: 14px; }
.steps + .steps-group { margin-top: 22px; color: var(--ink-3); }
.steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.step {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 14px;
  padding: 9px 14px 9px 18px;
  border-left: 2px solid var(--line);
  opacity: .45;
  transition: opacity var(--t) var(--ease), border-color var(--t) var(--ease);
}
.step h3 { font-size: 16px; font-weight: 600; letter-spacing: -0.02em; }
.step p { font-size: 13.5px; color: var(--ink-2); margin-top: 3px; line-height: 1.45; }
.step-n {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 12.5px;
  transition: background-color var(--t) var(--ease), color var(--t) var(--ease), border-color var(--t) var(--ease);
}
.step.is-active { opacity: 1; border-left-color: var(--accent); }
.js .step { cursor: pointer; }
.js .step:not(.is-active):hover { opacity: .75; }
.step:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.step.is-active .step-n { background: var(--accent); border-color: var(--accent); color: #fff; }

.frame {
  margin: 0;
  width: 100%;
  max-width: calc((100vh - var(--top) - 190px) * 1.592);
  justify-self: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--sh-3);
  overflow: hidden;
}
.f-bar { display: flex; align-items: center; gap: 14px; height: 40px; padding: 0 14px; border-bottom: 1px solid var(--line-2); }
.f-title { font-size: 13px; font-weight: 600; letter-spacing: -0.01em; }
.f-org { margin-left: auto; font-size: 11px; color: var(--ink-3); }
.f-view { position: relative; aspect-ratio: 1560 / 980; overflow: hidden; background: #EEF2F8; }
.f-inner { position: absolute; inset: 0; will-change: transform; }
.shot { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.js .shot:not(:first-child) { opacity: 0; }
.spot {
  position: absolute;
  border: 2px solid var(--accent);
  border-radius: 10px;
  box-shadow: 0 0 0 9999px rgba(14, 17, 22, .46);
  opacity: 0;
  pointer-events: none;
}
/* Último paso: el resto de herramientas cae dentro del marco */
.f-rain {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-auto-rows: minmax(0, 1fr);
  gap: 2.4%;
  padding: 5% 4.5%;
  background: linear-gradient(180deg, #F6F8FC, #EAF0F8);
  opacity: 0;
  pointer-events: none;
  container-type: inline-size;
}
/* «Y mucho más…» en grande, por delante de las tarjetas que caen */
.rain-title {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  background: radial-gradient(closest-side, rgba(246, 248, 252, .94), rgba(246, 248, 252, .72) 55%, rgba(246, 248, 252, 0));
}
.rain-title p {
  margin: 0;
  font-size: clamp(30px, 10.5cqw, 120px);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 1;
  color: var(--ink);
  white-space: nowrap;
}
.rain-title em { font-size: 1.08em; letter-spacing: -0.015em; }
.rain-tile {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--sh-2);
  text-align: center;
  overflow: hidden;
}
.rain-tile .ti { flex: none; width: 42px; height: 42px; border-radius: 12px; }
.rain-tile .ti svg { width: 21px; height: 21px; }
/* El nombre va en una línea; el icono (también un span) no lleva estos estilos */
.rain-name {
  max-width: 100%;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--ink-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rain-total { background: var(--ink); border-color: var(--ink); }
.rain-total b { font-size: 34px; font-weight: 600; letter-spacing: -0.04em; line-height: 1; color: #fff; }
.rain-total .rain-name { color: #C9CDD4; font-weight: 500; white-space: normal; }

.note {
  position: absolute;
  left: 16px;
  bottom: 16px;
  max-width: min(380px, calc(100% - 32px));
  padding: 12px 16px 13px;
  background: var(--surface);
  border-radius: 12px;
  border: 1px solid var(--line);
  box-shadow: var(--sh-3);
  opacity: 0;
}
.note strong { display: block; font-size: 14px; font-weight: 600; letter-spacing: -0.01em; }
.note span { display: block; font-size: 13px; color: var(--ink-2); line-height: 1.45; margin-top: 2px; }

/* ---------- Acto V · Día a día ---------- */
.daily { padding: 140px 0 120px; }
.daily-head { width: min(1200px, calc(100% - 2 * var(--gutter))); margin: 0 auto 56px; }
.metrics {
  width: min(1200px, calc(100% - 2 * var(--gutter)));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.metric { padding: 44px 36px 40px; border-left: 1px solid var(--line); }
.metric:first-child { border-left: 0; padding-left: 0; }
.m-num {
  display: block;
  font-size: clamp(56px, 7vw, 108px);
  font-weight: 600;
  letter-spacing: -0.055em;
  line-height: .95;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.m-kbd { font-family: var(--mono); font-weight: 500; letter-spacing: -0.06em; }
.m-line { display: block; width: 72px; height: 2px; margin: 22px 0 16px; background: var(--accent); transform-origin: 0 50%; }
.js .m-line { transform: scaleX(0); }
.metric p { font-size: 15px; color: var(--ink-2); max-width: 280px; }

.marquee {
  margin-top: 96px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track { display: flex; gap: 14px; width: max-content; padding: 6px 0 14px; animation: marquee 90s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.tchip {
  flex: none;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px 12px 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--sh-1);
}
.tchip .ti { width: 36px; height: 36px; border-radius: 10px; }
.tchip .ti svg { width: 18px; height: 18px; }
.tchip b { display: block; font-size: 14px; font-weight: 600; letter-spacing: -0.01em; }
.tchip small { display: block; font-size: 12.5px; color: var(--ink-3); }

/* ---------- Acto VI · CTA ---------- */
.cta-stage { display: grid; place-items: center; }
.tags { position: absolute; inset: 0; pointer-events: none; }
.tag {
  position: absolute;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-2);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--sh-1);
  white-space: nowrap;
}
.cta-circle {
  position: absolute;
  inset: var(--top) 0 0;
  margin: auto;
  width: min(660px, 86vw);
  height: min(660px, 86vw);
  pointer-events: none;
}
.cta-circle circle { fill: none; stroke: var(--accent); stroke-width: .32; stroke-dasharray: 603.2; stroke-dashoffset: 603.2; }
.cta-copy { position: relative; z-index: 2; text-align: center; max-width: 780px; padding: 0 var(--gutter); }
.cta-logo { width: min(150px, 18vh); height: min(150px, 18vh); object-fit: contain; margin: 0 auto 18px; }
.cta-copy .lead { margin: 22px auto 0; }
.magnet { position: relative; display: inline-block; padding: 26px 40px; margin-top: 10px; }
.store-link { position: relative; z-index: 1; will-change: transform; }
/* Lienzo de las chispas: desborda el botón por todos lados y no captura el ratón */
.spark { position: absolute; left: -90px; top: -70px; width: calc(100% + 180px); height: calc(100% + 140px); pointer-events: none; z-index: 0; }
.badge { margin-left: 6px; padding: 3px 9px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 600; }
.pulse-ring { position: absolute; inset: -1px; border-radius: inherit; border: 1.5px solid var(--ink); opacity: 0; pointer-events: none; }
.store-link:hover .pulse-ring,
.store-link:focus-visible .pulse-ring { animation: ring 1.5s var(--ease) infinite; }
@keyframes ring { 0% { transform: scale(1); opacity: .45; } 100% { transform: scale(1.18, 1.45); opacity: 0; } }
.cta-note { font-size: 13.5px; color: var(--ink-3); }
.cta-note a { color: var(--accent); border-bottom: 1px solid #BCD8F3; }
.cta-note a:hover { border-bottom-color: var(--accent); }
.js .cta-logo, .js .cta-copy .w, .js .cta-copy .lead, .js .cta-copy .magnet, .js .cta-note { opacity: 0; }

/* ---------- Footer ---------- */
.footer {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  padding: 32px var(--gutter);
  border-top: 1px solid var(--line);
  background: var(--surface);
  font-size: 13.5px;
  color: var(--ink-2);
}
.footer .brand { margin-right: auto; }
.foot-links { display: flex; gap: 20px; flex-wrap: wrap; }
.foot-links a { color: var(--ink-2); border-bottom: 1px solid transparent; transition: border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease); }
.foot-links a:hover { color: var(--ink); border-bottom-color: var(--line); }
.foot-legal { flex-basis: 100%; font-size: 12.5px; color: var(--ink-3); }
.footer .logo { width: 26px; height: 26px; }
.muted { color: var(--ink-3); }

/* ---------- Sin JS / sin GSAP: layout estático legible ---------- */
html:not(.js) .js-only { display: none !important; }
/* overflow-x: clip recorta los lienzos de chispas, que desbordan el bloque, sin crear scroll */
html:not(.js) .stage { height: auto; overflow: visible; overflow-x: clip; padding: calc(var(--top) + 72px) var(--gutter) 72px; }
html:not(.js) .hero-grid { margin: 0 auto; }
html:not(.js) .maze-layers,
html:not(.js) .maze-center { position: static; }
html:not(.js) .maze-center::before { display: none; }
html:not(.js) .crumbs { white-space: normal; flex-wrap: wrap; justify-content: center; padding: 0; font-size: clamp(30px, 4.4vw, 60px); }
html:not(.js) .crumbs-view { -webkit-mask-image: none; mask-image: none; }
html:not(.js) .crumb { color: var(--ink); }
html:not(.js) .crumb em { color: var(--accent); }
html:not(.js) .maze-caption { position: static; margin-top: 40px; }
html:not(.js) .maze-dialog { position: relative; inset: auto; margin: 28px auto 0; }
html:not(.js) .demo-grid { align-items: start; grid-template-rows: none; }
html:not(.js) .steps-col { overflow: visible; -webkit-mask-image: none; mask-image: none; }
html:not(.js) .frame { max-width: none; }
html:not(.js) .f-view { aspect-ratio: auto; }
html:not(.js) .f-inner { position: static; display: flex; flex-direction: column; gap: 2px; aspect-ratio: auto; overflow: visible; }
html:not(.js) .shot { position: static; height: auto; }
html:not(.js) .cta-stage { min-height: 70vh; }

/* ---------- Móvil: layout estático con aparición al entrar en pantalla ---------- */
.m-static .stage { padding: calc(var(--top) + 36px) var(--gutter) 48px; }
.m-static .steps-col { display: none; }
.m-static .demo-grid { grid-template-columns: 1fr; }
.m-static .f-inner { gap: 0; }
.shot-cap { display: none; }
.m-static .shot-cap {
  display: grid;
  grid-template-columns: 26px 1fr;
  gap: 12px;
  padding: 14px 16px 18px;
  background: var(--surface);
  border-bottom: 1px solid var(--line-2);
}
.m-static .shot-cap .step-n { width: 26px; height: 26px; font-size: 11px; background: var(--accent); border-color: var(--accent); color: #fff; }
.m-static .shot-cap h3 { display: block; font-size: 15px; font-weight: 600; letter-spacing: -0.02em; }
.m-static .shot-cap p { display: block; font-size: 13.5px; color: var(--ink-2); margin-top: 3px; }
.m-static .shot-cap-more { border-bottom: 0; }
.m-static .rv { opacity: 0; transform: translateY(18px); transition: opacity var(--t-slow) var(--ease), transform var(--t-slow) var(--ease); }
.m-static .rv.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-height: 820px) and (min-width: 900px) {
  .tl small { display: none; }
  .tl { padding: 5px 4px; }
}

@media (max-width: 899px) {
  :root { --top: 56px; }
  .nav { display: none; }
  .topbar { gap: 12px; }
  .topbar .pill { margin-left: 0; }

  .hero-grid { grid-template-columns: 1fr; gap: 26px; }
  .hero-copy .display { font-size: clamp(34px, 9vw, 52px); }
  .lead { margin-top: 16px; font-size: 15.5px; }
  .hero-actions { margin-top: 20px; }
  .browser-wrap { width: min(440px, 100%); margin: 0 auto; }
  .b-body { padding: 18px; gap: 10px; }
  .popup { top: 44px; width: 76%; }
  .setup-side { display: none; }
  .setup-crumbs, .setup-btns, .setup-loading { display: none; }
  .setup-search { width: auto; flex: 1; }
  .setup-row { grid-template-columns: 1fr 1.3fr; font-size: 10.5px; }
  .setup-row span:nth-child(n+3) { display: none; }
  .note-stick { font-size: 14px; width: 150px; padding: 9px 11px; }
  .note-1 { right: -6px; bottom: 30px; }
  .note-2 { display: none; }
  .tab-more { display: none; }
  .lang { margin-left: auto; }
  .tab { font-size: 9.5px; padding: 0 5px; }
  .tab::before { display: none; }

  .crumbs { padding: .1em 6vw; }
  .maze-back { grid-template-columns: repeat(3, 1fr); width: 130vw; margin-left: -65vw; }

  /* Herramientas: una fila por familia, solo iconos */
  .tools-stage { gap: 18px; }
  .fams { grid-template-columns: 1fr; gap: 8px; }
  .fam { display: grid; grid-template-columns: 86px 1fr; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; }
  .fam-h { flex-direction: column; align-items: flex-start; gap: 2px; padding: 0; border: 0; margin: 0; }
  .fam-h b { font-size: 13px; }
  .fam-list { flex-direction: row; flex-wrap: wrap; gap: 5px; }
  .tl { padding: 0; }
  .tl div { display: none; }
  .fam-caption { font-size: 13px; }
  .fam-caption span { display: block; font-size: 17px; }
  .p-dots { right: 4px; }

  .demo-stage { gap: 16px; }
  .demo-grid { grid-template-columns: 1fr; grid-template-rows: auto auto; align-content: start; gap: 18px; }
  .steps-col { overflow: visible; -webkit-mask-image: none; mask-image: none; }
  .steps-track { flex-direction: row; align-items: flex-start; gap: 6px; padding-top: 0; transform: none !important; }
  .steps-group { display: none; }
  .steps { flex-direction: row; gap: 6px; }
  /* Cada lista ocupa en proporción a sus pasos: 4 · 2 · 3 */
  .steps:nth-of-type(1) { flex: 4; }
  .steps:nth-of-type(2) { flex: 2; }
  .steps:nth-of-type(3) { flex: 4; }
  .f-rain { gap: 2%; padding: 3%; }
  .rain-tile { padding: 2px; border-radius: 8px; gap: 2px; }
  .rain-tile .rain-name { display: none; }
  .rain-tile .ti { width: 26px; height: 26px; border-radius: 7px; }
  .rain-tile .ti svg { width: 14px; height: 14px; }
  .rain-total b { font-size: 18px; }
  .rain-total .rain-name { display: block; font-size: 8px; }
  .step { flex: 1; grid-template-columns: 1fr; gap: 6px; padding: 10px 0 0; border-left: 0; border-top: 2px solid var(--line); }
  .step.is-active { border-top-color: var(--accent); }
  .step p { display: none; }
  .step h3 { display: none; }
  .step-n { width: 24px; height: 24px; font-size: 11px; }
  .frame { max-width: none; }
  .f-org { display: none; }
  .f-view { overflow: visible; aspect-ratio: auto; background: var(--surface); }
  .f-inner { position: relative; inset: auto; aspect-ratio: 1560 / 980; overflow: hidden; background: #EEF2F8; }
  .note { position: static; max-width: none; border-radius: 0; box-shadow: none; border-top: 1px solid var(--line-2); }

  .daily { padding: 100px 0 80px; }
  .metrics { grid-template-columns: 1fr; }
  .metric, .metric:first-child { padding: 32px 0; border-left: 0; border-top: 1px solid var(--line); }
  .metric:first-child { border-top: 0; }
  .marquee { margin-top: 64px; }

  .tag { font-size: 11px; padding: 5px 10px; }
  .magnet { padding: 22px 0; }
  .pill-lg { height: 54px; padding: 0 22px; font-size: 15.5px; }
  .footer { flex-direction: column; align-items: flex-start; gap: 10px; }
}

/* ---------- Movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  .halo, .scroll-hint .arrow, .mk::after, .spinner, .tab.is-loading::before, .caret,
  .js .hero-copy, .js .browser-wrap,
  .store-link:hover .pulse-ring, .store-link:focus-visible .pulse-ring { animation: none !important; }
  .marquee { overflow-x: auto; -webkit-mask-image: none; mask-image: none; }
  .marquee-track { animation: none; padding-inline: var(--gutter); }
  .marquee-track [data-clone] { display: none; }
}
