/* =========================================================
   letsgodrop · base
   Sistema visual propio, sobrio y luminoso: blanco o negro de fondo, materiales de cristal
   (cabecera, pie, globos y menús translúcidos), Inter con titulares apretados, un color por fase
   y la explicación en iconos, diagramas, maquetas y gráficos antes que en texto.
   Un solo paradigma por cosa:
   - Botón azul = la acción de la pantalla. ↗ abre otra web; → avanza aquí.
   - Botón gris = lo secundario (volver, saltar, ver un tutorial).
   - Halo azul que late = lo siguiente que toca. Verde = hecho.
   - Palabra con subrayado de puntos o icono (i) = tiene definición: el mismo globo para todo.
   - Campo con candado = sale de tus datos; campo con lápiz = lo puedes cambiar.
   - Cada fase tiene su color: su icono, su tramo de la barra, sus números y sus acentos.
   ========================================================= */

:root {
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --font-display: var(--font-sans);
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --ease-out-quint: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-soft: cubic-bezier(0.4, 0, 0.2, 1);

  --radius: 24px;
  --radius-sm: 14px;
  --top-h: 76px;
  --pie-h: 100px;
  --gut: 28px;
  --maxw: 1240px;

  /* Colores con nombre (iconos y gráficos): los mismos en los dos modos */
  --claude: #d97757;
  --c-blue: #0a84ff;
  --c-violet: #8e5cf7;
  --c-pink: #ff375f;
  --c-green: #28c76f;
  --c-orange: #ff9f0a;
  --c-teal: #32ade6;
  --c-yellow: #ffcc00;
  --c-red: #ff453a;
  --c-gray: #8e8e93;
  --grad-brand: linear-gradient(135deg, #4cc2ff 0%, #2f6bff 52%, #7c5cff 100%);
  --grad-ai: linear-gradient(90deg, #3fb5ff 0%, #7c5cff 30%, #ff5fa2 62%, #ff9f0a 84%, #3fb5ff 100%);

  /* Modo claro (por defecto): blanco */
  color-scheme: light;
  --bg: #ffffff;
  --bg-soft: #f5f5f7;
  --card: #ffffff;
  --card-2: #f9f9fb;
  --fill: rgba(118, 118, 128, 0.12);
  --fill-2: rgba(118, 118, 128, 0.07);
  --line: rgba(0, 0, 0, 0.08);
  --line-2: rgba(0, 0, 0, 0.055);
  --line-strong: rgba(0, 0, 0, 0.14);
  --ink: #1d1d1f;
  --ink-2: #3a3a3c;
  --ink-soft: #6e6e73;
  --ink-muted: #8e8e93;
  --brand: #2f6bff;
  --brand-hover: #1f5ef5;
  --brand-ink: #1f5ef5;
  --brand-soft: rgba(47, 107, 255, 0.1);
  --brand-rgb: 47, 107, 255;
  --on-brand: #ffffff;
  --ok: #1e9b52;
  --ok-fill: #34c759;
  --ok-soft: rgba(52, 199, 89, 0.12);
  --danger: #e0352b;
  --danger-fill: #ff3b30;
  --danger-soft: rgba(255, 59, 48, 0.09);
  --danger-text: #d1281e;
  --warn: #c76a00;
  --warn-fill: #ff9f0a;
  --warn-soft: rgba(255, 159, 10, 0.13);
  --glass: rgba(255, 255, 255, 0.64);
  --glass-strong: rgba(255, 255, 255, 0.86);
  --glass-rim: rgba(255, 255, 255, 0.9);
  --glass-edge: rgba(0, 0, 0, 0.07);
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.04), 0 4px 16px -8px rgba(16, 24, 40, 0.1);
  --shadow-md: 0 2px 6px rgba(16, 24, 40, 0.04), 0 18px 44px -18px rgba(16, 24, 64, 0.2);
  --shadow-lg: 0 6px 16px rgba(16, 24, 40, 0.05), 0 44px 90px -34px rgba(16, 24, 64, 0.32);
  --shadow-card: var(--shadow-md);
  --overlay: rgba(20, 20, 28, 0.22);
  --tip-bg: rgba(255, 255, 255, 0.9);
  --tip-ink: #1d1d1f;
  --tip-soft: #6e6e73;
  --tip-line: rgba(0, 0, 0, 0.08);
  --code: #f7f7f9;
  --mk-line: rgba(0, 0, 0, 0.08);
  --logo-filter: none;
  --amb: 0.2;

  /* Los nombres de antes, para las maquetas */
  --accent: var(--brand-ink);
  --gold: var(--brand);
  --surface: var(--card);
  --surface-2: var(--card-2);
  --c: 29, 29, 31;
  --w: 0, 0, 0;
  --g: var(--brand-rgb);

  /* El color de cada fase (sin fase: el de la marca) */
  --h1: #6fb6ff;
  --h2: #2f6bff;
  --hc: var(--brand-ink);
}

/* Modo oscuro: negro */
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #000000;
  --bg-soft: #0c0c0e;
  --card: #121214;
  --card-2: #18181b;
  --fill: rgba(118, 118, 128, 0.26);
  --fill-2: rgba(118, 118, 128, 0.15);
  --line: rgba(255, 255, 255, 0.1);
  --line-2: rgba(255, 255, 255, 0.065);
  --line-strong: rgba(255, 255, 255, 0.18);
  --ink: #f5f5f7;
  --ink-2: #d1d1d6;
  --ink-soft: #a1a1a6;
  --ink-muted: #6e6e73;
  --brand: #3d7bff;
  --brand-hover: #5a8eff;
  --brand-ink: #74a0ff;
  --brand-soft: rgba(61, 123, 255, 0.17);
  --brand-rgb: 61, 123, 255;
  --ok: #32d74b;
  --ok-fill: #30d158;
  --ok-soft: rgba(48, 209, 88, 0.15);
  --danger: #ff453a;
  --danger-fill: #ff453a;
  --danger-soft: rgba(255, 69, 58, 0.15);
  --danger-text: #ff6961;
  --warn: #ffb340;
  --warn-soft: rgba(255, 159, 10, 0.16);
  --c-green: #30d158;
  --glass: rgba(30, 30, 34, 0.56);
  --glass-strong: rgba(32, 32, 36, 0.86);
  --glass-rim: rgba(255, 255, 255, 0.14);
  --glass-edge: rgba(255, 255, 255, 0.07);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 20px 44px -20px rgba(0, 0, 0, 0.75);
  --shadow-lg: 0 44px 100px -34px rgba(0, 0, 0, 0.9);
  --overlay: rgba(0, 0, 0, 0.55);
  --tip-bg: rgba(44, 44, 50, 0.9);
  --tip-ink: #f5f5f7;
  --tip-soft: #a1a1a6;
  --tip-line: rgba(255, 255, 255, 0.1);
  --code: #0e0e10;
  --mk-line: rgba(255, 255, 255, 0.1);
  --logo-filter: invert(1);
  --amb: 0.55;
  --c: 245, 245, 247;
  --w: 255, 255, 255;
  --h1: #6fb6ff;
  --h2: #3d7bff;
}

/* Una fase, un color: su icono, su tramo de la barra y sus acentos */
[data-f="1"], [data-fase="1"] { --h1: #5ac8fa; --h2: #0a7cff; --hc: #0a6fe8; }
[data-f="2"], [data-fase="2"] { --h1: #b99bff; --h2: #7b4dff; --hc: #6b3cf0; }
[data-f="3"], [data-fase="3"] { --h1: #ff8db0; --h2: #ef2f6a; --hc: #e81f5e; }
[data-f="4"], [data-fase="4"] { --h1: #6fe3a5; --h2: #12a15a; --hc: #0f9a53; }
[data-f="5"], [data-fase="5"] { --h1: #ffc96b; --h2: #f2721a; --hc: #e07400; }
[data-f="6"], [data-fase="6"] { --h1: #6ee0f2; --h2: #0897bc; --hc: #078fb1; }
[data-f="7"], [data-fase="7"] { --h1: #ffd95a; --h2: #cf8b00; --hc: #b97c00; }
:root[data-theme="dark"] [data-f="1"], :root[data-theme="dark"] [data-fase="1"] { --hc: #5aaeff; }
:root[data-theme="dark"] [data-f="2"], :root[data-theme="dark"] [data-fase="2"] { --hc: #a98bff; }
:root[data-theme="dark"] [data-f="3"], :root[data-theme="dark"] [data-fase="3"] { --hc: #ff6b97; }
:root[data-theme="dark"] [data-f="4"], :root[data-theme="dark"] [data-fase="4"] { --hc: #3ddc84; }
:root[data-theme="dark"] [data-f="5"], :root[data-theme="dark"] [data-fase="5"] { --hc: #ffad33; }
:root[data-theme="dark"] [data-f="6"], :root[data-theme="dark"] [data-fase="6"] { --hc: #3fd0ea; }
:root[data-theme="dark"] [data-f="7"], :root[data-theme="dark"] [data-fase="7"] { --hc: #ffcc33; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--top-h) + 16px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-optical-sizing: auto;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: -0.011em;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .5s var(--ease-soft), color .5s var(--ease-soft);
}
img { max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
input, textarea, select { font-size: 16px; }
a { color: inherit; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
::selection { background: rgba(var(--brand-rgb), 0.22); }

/* ====== Fondo: luz de color que se mueve muy despacio (se ve a través del cristal) ====== */
.ambient { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; opacity: var(--amb); transition: opacity 1s var(--ease-soft); }
.ambient i { position: absolute; border-radius: 50%; will-change: transform; }
.ambient__a { width: 64vmax; height: 64vmax; left: -22vmax; top: -34vmax; background: radial-gradient(closest-side, rgba(76, 194, 255, 0.55), rgba(76, 194, 255, 0) 72%); animation: amb1 30s ease-in-out infinite alternate; }
.ambient__b { width: 58vmax; height: 58vmax; right: -22vmax; top: -28vmax; background: radial-gradient(closest-side, rgba(124, 92, 255, 0.46), rgba(124, 92, 255, 0) 72%); animation: amb2 36s ease-in-out infinite alternate; }
.ambient__c { width: 52vmax; height: 52vmax; left: 26%; bottom: -40vmax; background: radial-gradient(closest-side, rgba(255, 95, 162, 0.3), rgba(255, 95, 162, 0) 72%); animation: amb3 42s ease-in-out infinite alternate; }
@keyframes amb1 { to { transform: translate3d(9vmax, 7vmax, 0) scale(1.1); } }
@keyframes amb2 { to { transform: translate3d(-8vmax, 9vmax, 0) scale(1.06); } }
@keyframes amb3 { to { transform: translate3d(-10vmax, -6vmax, 0) scale(1.12); } }
body[data-vista="paso"] .ambient, body[data-vista="fase"] .ambient, body[data-vista="final"] .ambient { opacity: calc(var(--amb) * 0.62); }
/* Fuera del inicio, la luz se queda quieta: el cristal no tiene que recalcularse en cada fotograma */
body:not([data-vista="inicio"]) .ambient i { animation-play-state: paused; }

/* ====== Tipografía y piezas pequeñas ====== */
.kicker { margin: 0 0 12px; font-size: 14px; font-weight: 600; letter-spacing: -0.01em; color: var(--hc); }
.h2 {
  margin: 0 0 14px; font-size: clamp(32px, 4.2vw, 52px); font-weight: 700; line-height: 1.04;
  letter-spacing: -0.04em; text-wrap: balance;
}
.lead { margin: 0; font-size: 19px; line-height: 1.45; letter-spacing: -0.018em; color: var(--ink-soft); text-wrap: pretty; }
/* La palabra destacada de un título: degradado con el color de su fase */
.h2 em, .paso__t em, .fv__t em, .sheet__t em, .dlg__t em, .fin__t em, .ph__t em { font-style: normal; color: var(--hc); }
.hero__t em {
  font-style: normal; padding-right: 0.04em;
  background: linear-gradient(100deg, #2f6bff 10%, #7c5cff 85%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
:root[data-theme="dark"] .hero__t em { background-image: linear-gradient(100deg, #5b97ff 10%, #a48bff 85%); }
.claude { color: var(--claude); white-space: nowrap; }
.claude-logo { width: 0.82em; height: 0.82em; margin-right: 0.16em; vertical-align: -0.06em; color: var(--claude); fill: currentColor; }
.ic { width: 18px; height: 18px; flex: none; display: inline-block; vertical-align: middle; }
.mono { font-family: var(--font-mono); }
.ok { color: var(--ok); }
.bad { color: var(--danger); }
.link {
  background: none; border: 0; padding: 0; color: var(--brand-ink); cursor: pointer; font-weight: 500;
  text-decoration: none; transition: color .25s var(--ease-soft), opacity .25s;
}
.link:hover { text-decoration: underline; text-underline-offset: 3px; }

.dot { position: relative; width: 7px; height: 7px; border-radius: 50%; flex: none; background: var(--brand); animation: pulse 2.4s ease-in-out infinite; }
.dot--ok { background: var(--ok-fill); }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .4; } }

/* Etiquetas: Obligatorio, Opcional, Recomendado */
.tag {
  display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 10px; border-radius: 999px;
  font-size: 12.5px; font-weight: 600; letter-spacing: -0.005em; white-space: nowrap; vertical-align: middle;
  color: var(--brand-ink); background: var(--brand-soft);
}
.tag--dim { color: var(--ink-soft); background: var(--fill-2); }
.tag--ok { color: var(--ok); background: var(--ok-soft); }
.tag--bad { color: var(--danger-text); background: var(--danger-soft); }

/* ====== Iconos: una baldosa plana del color de su fase con el canto de cristal; el dibujo, siempre blanco ====== */
.gi {
  --s: 40px;
  position: relative; display: inline-grid; place-items: center; flex: none; isolation: isolate;
  width: var(--s); height: var(--s); border-radius: calc(var(--s) * 0.3);
  color: #fff; background: var(--h2);
  box-shadow: 0 1px 1.5px rgba(16, 24, 40, 0.14), 0 5px 12px -7px var(--h2);
}
/* El cristal: un brillo suave arriba y el canto iluminado (más luz arriba a la izquierda) */
.gi::before {
  content: ''; position: absolute; inset: 0; border-radius: inherit; z-index: -1; pointer-events: none;
  background: radial-gradient(130% 80% at 50% -14%, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0) 62%);
}
.gi::after {
  content: ''; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: linear-gradient(170deg, rgba(255, 255, 255, 0.66), rgba(255, 255, 255, 0.07) 42%, rgba(255, 255, 255, 0.04) 70%, rgba(255, 255, 255, 0.3));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude;
}
/* El color del dibujo va en el propio dibujo: ninguna regla de fuera lo vuelve gris */
.gi > svg, .gi > .ic, .gi > .claude-logo { width: 50%; height: 50%; margin: 0; color: #fff !important; }
.gi--sm { --s: 32px; }
.gi--lg { --s: 52px; }
.gi--blue { --h2: #0a7cff; }
.gi--violet { --h2: #7b4dff; }
.gi--pink { --h2: #ef2f6a; }
.gi--green { --h2: #12a15a; }
.gi--orange { --h2: #f2721a; }
.gi--gray { --h2: #8a8a93; }
.gi--ai { --h2: #d9643f; }
/* Logo de una marca de fuera, en su baldosa blanca */
.logo-tile {
  --s: 44px;
  display: inline-grid; place-items: center; flex: none; width: var(--s); height: var(--s); border-radius: calc(var(--s) * 0.28);
  background: #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.07), 0 6px 16px -10px rgba(0, 0, 0, 0.35);
}
.logo-tile > svg { width: 62%; height: 62%; }
.logo-tile > .claude-logo { color: var(--claude); margin: 0; }
.logo-tile--dark { background: #1d1d1f; color: #fff; }

/* Anillo de progreso pequeño (SVG que pinta app.js) */
.ring { flex: none; transform: rotate(-90deg); overflow: visible; }
.ring circle { fill: none; }
.ring__t { stroke: color-mix(in srgb, var(--hc) 18%, transparent); }
.ring__v { stroke: var(--hc); stroke-linecap: round; transition: stroke-dashoffset 1.1s var(--ease-out-quint); }
.ring--ok .ring__v { stroke: var(--ok-fill); }
.ring--ok .ring__t { stroke: color-mix(in srgb, var(--ok-fill) 20%, transparent); }

/* ====== El arte de cada fase: su baldosa grande, plana, con dos pastillas de cristal que la pisan ====== */
.gx { --sz: 120px; position: relative; display: inline-block; vertical-align: middle; width: var(--sz); height: var(--sz); flex: none; }
.gx__glow { display: none; }
.gx__base {
  position: absolute; inset: 15%; border-radius: 28%; background: var(--h2); isolation: isolate;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.12), 0 calc(var(--sz) * 0.12) calc(var(--sz) * 0.22) calc(var(--sz) * -0.12) var(--h2);
  transition: transform .9s var(--ease-spring);
}
.gx__base::before {
  content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(130% 80% at 50% -14%, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0) 62%);
}
.gx__base::after {
  content: ''; position: absolute; inset: 0; border-radius: inherit; padding: 1.5px; pointer-events: none;
  background: linear-gradient(170deg, rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.07) 42%, rgba(255, 255, 255, 0.04) 70%, rgba(255, 255, 255, 0.32));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude;
}
.gx__glass { position: absolute; inset: 15%; display: grid; place-items: center; color: #fff; pointer-events: none; transition: transform .9s var(--ease-spring); }
.gx__glass > .ic { width: 40%; height: 40%; color: #fff !important; }
.gx__chip {
  position: absolute; display: inline-flex; align-items: center; gap: calc(var(--sz) * 0.035);
  height: calc(var(--sz) * 0.2); padding: 0 calc(var(--sz) * 0.075); border-radius: 999px;
  background: rgba(255, 255, 255, 0.6); color: #1d1d1f;
  -webkit-backdrop-filter: blur(10px) saturate(180%); backdrop-filter: blur(10px) saturate(180%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.78), inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 6px 18px -8px rgba(16, 24, 40, 0.32);
  font-size: calc(var(--sz) * 0.1); font-weight: 650; letter-spacing: -0.02em; white-space: nowrap;
  transition: transform .9s var(--ease-spring);
}
:root[data-theme="dark"] .gx__chip { background: rgba(48, 48, 54, 0.62); color: #f5f5f7; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 6px 18px -8px rgba(0, 0, 0, 0.6); }
.gx__chip > .ic, .gx__chip > svg { width: calc(var(--sz) * 0.12); height: calc(var(--sz) * 0.12); color: var(--hc); }
.gx__chip--a { right: -2%; top: 7%; }
.gx__chip--b { left: -4%; bottom: 9%; }
a:hover .gx__base, a:hover .gx__glass { transform: scale(1.05); }
a:hover .gx__chip--a { transform: translate(5%, -8%); }
a:hover .gx__chip--b { transform: translate(-5%, 8%); }
.gx--lg { --sz: 168px; }

/* ====== Botones: un solo paradigma ====== */
.btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px; border-radius: 999px; border: 0;
  font-size: 15px; font-weight: 590; line-height: 1; letter-spacing: -0.014em;
  color: var(--ink); background: var(--fill-2); cursor: pointer; text-decoration: none; white-space: nowrap;
  -webkit-user-select: none; user-select: none;
  transition: transform .45s var(--ease-spring), background-color .25s var(--ease-soft), color .25s var(--ease-soft), box-shadow .35s var(--ease-soft), opacity .25s;
}
.btn .ic { width: 17px; height: 17px; }
.btn:active { transform: scale(0.96); transition-duration: .12s; }
.btn:focus-visible { outline: 3px solid rgba(var(--brand-rgb), 0.45); outline-offset: 2px; }
.btn--primary {
  background: var(--brand); color: var(--on-brand);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 8px 22px -10px rgba(var(--brand-rgb), 0.75);
}
.btn--primary:hover { background: var(--brand-hover); transform: translate3d(0, -1px, 0); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 14px 30px -12px rgba(var(--brand-rgb), 0.85); }
.btn--ghost { background: var(--fill-2); color: var(--ink); }
.btn--ghost:hover { background: var(--fill); transform: translate3d(0, -1px, 0); }
.btn--white { background: #fff; color: #1d1d1f; box-shadow: 0 10px 26px -12px rgba(0, 0, 0, 0.45); }
.btn--white:hover { background: #f5f5f7; transform: translate3d(0, -1px, 0); }
.btn--sm { height: 36px; padding: 0 15px; font-size: 14px; gap: 6px; }
.btn--sm .ic { width: 15px; height: 15px; }
.btn--lg { height: 52px; padding: 0 26px; font-size: 16.5px; }
.btn--block { width: 100%; }
.btn.is-done { background: var(--ok-soft); color: var(--ok); box-shadow: none; }
.btn[disabled] { opacity: 0.4; cursor: not-allowed; transform: none; box-shadow: none; }
.btn.is-wait { pointer-events: none; opacity: 0.75; }
.btn.is-wait::after { content: ''; width: 14px; height: 14px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.iconbtn {
  display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; border: 0; padding: 0;
  background: var(--fill-2); color: var(--ink); cursor: pointer;
  transition: background .25s var(--ease-soft), transform .45s var(--ease-spring);
}
.iconbtn:hover { background: var(--fill); }
.iconbtn:active { transform: scale(0.92); }
.iconbtn .ic { width: 18px; height: 18px; }

/* Lo siguiente que toca: un halo azul que late */
.is-next { animation: nextRing 2.2s var(--ease-out-quint) infinite; }
@keyframes nextRing {
  0% { box-shadow: 0 0 0 0 rgba(var(--brand-rgb), 0.5); }
  70%, 100% { box-shadow: 0 0 0 13px rgba(var(--brand-rgb), 0); }
}
/* Lo que falta, cuando intentas seguir sin hacerlo */
.is-call { animation: callShake .5s var(--ease-soft), nextRing 1.2s var(--ease-out-quint) 2; }
@keyframes callShake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-5px); } 40% { transform: translateX(5px); }
  60% { transform: translateX(-3px); } 80% { transform: translateX(3px); }
}

/* ====== Definiciones: la palabra subrayada y el icono (i) abren el mismo globo ====== */
.term {
  background: none; border: 0; padding: 0; margin: 0; font: inherit; color: inherit; cursor: help; letter-spacing: inherit;
  text-decoration: underline dotted rgba(var(--brand-rgb), 0.75); text-decoration-thickness: 1.5px; text-underline-offset: 3px;
  line-height: inherit; text-align: inherit; transition: color .2s var(--ease-soft);
}
.term:hover, .term:focus-visible, .term.is-on { color: var(--brand-ink); outline: none; }
.info {
  display: inline-grid; place-items: center; width: 18px; height: 18px; padding: 0; margin: 0 0 0 2px; border: 0;
  background: none; color: var(--ink-muted); cursor: help; vertical-align: -3px; border-radius: 50%;
  transition: color .2s var(--ease-soft), transform .3s var(--ease-spring);
}
.info .ic { width: 17px; height: 17px; }
.info:hover, .info:focus-visible, .info.is-on { color: var(--brand-ink); outline: none; transform: scale(1.1); }
.tip {
  position: fixed; z-index: 200; max-width: 300px; padding: 12px 14px 13px; border-radius: 16px;
  background: var(--tip-bg); border: 1px solid var(--tip-line); box-shadow: var(--shadow-lg);
  -webkit-backdrop-filter: blur(26px) saturate(180%); backdrop-filter: blur(26px) saturate(180%);
  pointer-events: none; opacity: 0; transform: translate3d(0, 4px, 0) scale(0.98); transform-origin: var(--ax, 50%) 100%;
  transition: opacity .18s var(--ease-soft), transform .3s var(--ease-spring);
}
.tip.is-on { opacity: 1; transform: none; }
.tip__k { margin: 0 0 3px; font-size: 12.5px; font-weight: 650; letter-spacing: -0.005em; color: var(--brand-ink); }
.tip__d { margin: 0; font-size: 14px; line-height: 1.45; color: var(--tip-ink); }

/* ====== Campos ====== */
.fld { display: grid; gap: 7px; align-content: start; min-width: 0; }
.fld__l { display: flex; align-items: center; gap: 4px; font-size: 13.5px; font-weight: 550; color: var(--ink-soft); }
.fld__opt { color: var(--ink-muted); font-weight: 400; }
.fld__box {
  position: relative; display: flex; align-items: center; gap: 8px; height: 50px; padding: 0 15px; min-width: 0;
  border: 1px solid transparent; border-radius: var(--radius-sm); background: var(--fill-2);
  transition: border-color .2s var(--ease-soft), box-shadow .25s var(--ease-soft), background .2s var(--ease-soft);
}
.fld__box:hover { background: var(--fill); }
.fld__box:focus-within { background: var(--card); border-color: var(--brand); box-shadow: 0 0 0 4px rgba(var(--brand-rgb), 0.16); }
.fld__box input, .fld__box select, .fld__box textarea {
  flex: 1; min-width: 0; height: 100%; padding: 0; border: 0; outline: 0; background: none; color: var(--ink);
  font-size: 16px; font-weight: 550; font-variant-numeric: tabular-nums;
}
.fld__box input::placeholder, .fld__box textarea::placeholder { color: var(--ink-muted); font-weight: 400; }
.fld__box select { appearance: none; cursor: pointer; padding-right: 22px; width: 100%; text-overflow: ellipsis; }
.fld__box select option { background: var(--card); color: var(--ink); }
.fld__box--sel::after {
  content: ''; position: absolute; right: 17px; top: 50%; width: 7px; height: 7px; margin-top: -5px;
  border-right: 1.7px solid var(--ink-soft); border-bottom: 1.7px solid var(--ink-soft); transform: rotate(45deg); pointer-events: none;
}
.fld__pre { color: var(--ink-muted); font-size: 16px; font-weight: 500; }
.fld__ico { width: 17px; height: 17px; color: var(--ink-muted); flex: none; }
.fld__help { margin: 0; font-size: 13px; color: var(--ink-muted); line-height: 1.45; }
/* Fijo: sale de tus datos (con candado) */
.fld__box.is-lock { background: transparent; border: 1px dashed var(--line-strong); cursor: help; }
.fld__box.is-lock input { color: var(--ink-soft); pointer-events: none; }
/* Editable destacado: lo que puedes cambiar (con lápiz) */
.fld__box.is-edit { background: var(--card); border-color: rgba(var(--brand-rgb), 0.55); box-shadow: 0 0 0 4px rgba(var(--brand-rgb), 0.1); }
.fld__box.is-edit .fld__ico { color: var(--brand-ink); }
.fld__box.is-bad { border-color: rgba(255, 59, 48, 0.6); }
/* − / + */
.stp { display: flex; align-items: stretch; height: 50px; border-radius: var(--radius-sm); overflow: hidden; background: var(--fill-2); border: 1px solid transparent; transition: border-color .2s, box-shadow .25s; }
.stp:focus-within { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(var(--brand-rgb), 0.16); background: var(--card); }
.stp button { width: 50px; flex: none; border: 0; background: none; color: var(--brand-ink); cursor: pointer; display: grid; place-items: center; transition: background .2s, transform .3s var(--ease-spring); }
.stp button:hover { background: var(--fill-2); }
.stp button:active { transform: scale(0.9); }
.stp button .ic { width: 18px; height: 18px; }
.stp input { flex: 1; min-width: 0; text-align: center; border: 0; outline: 0; background: none; color: var(--ink); font-size: 19px; font-weight: 650; font-variant-numeric: tabular-nums; }

/* ====== Casilla: la misma para confirmar un paso y para marcar un punto (redonda) ====== */
.ck { position: relative; display: inline-flex; align-items: center; gap: 12px; cursor: pointer; user-select: none; -webkit-user-select: none; }
.ck input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.ck__box {
  position: relative; display: grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: 50%;
  border: 1.75px solid rgba(var(--c), 0.28); background: var(--card);
  transition: background .25s var(--ease-soft), border-color .25s var(--ease-soft), transform .45s var(--ease-spring);
}
.ck__box .ic { width: 14px; height: 14px; color: #fff; opacity: 0; transform: scale(0.4); transition: opacity .2s, transform .45s var(--ease-spring); }
.ck:hover .ck__box { border-color: var(--brand); }
.ck input:checked + .ck__box { background: var(--ok-fill); border-color: var(--ok-fill); transform: scale(1.06); }
.ck input:checked + .ck__box .ic { opacity: 1; transform: scale(1); }
.ck input:focus-visible + .ck__box { outline: 3px solid rgba(var(--brand-rgb), 0.45); outline-offset: 2px; }
.ck__t { font-size: 15.5px; font-weight: 550; line-height: 1.35; letter-spacing: -0.015em; }
.ck--big .ck__box { width: 26px; height: 26px; }
.ck--big .ck__box .ic { width: 15px; height: 15px; }
.ck.is-locked { cursor: not-allowed; }
.ck.is-locked .ck__box { border-style: dashed; border-color: rgba(var(--c), 0.22); background: transparent; }
.ck.is-locked .ck__t { color: var(--ink-muted); }
.ck.is-skip .ck__t { color: var(--ink-muted); text-decoration: line-through; text-decoration-color: rgba(var(--c), 0.25); }

/* ====== Tarjetas ====== */
.card {
  position: relative; border: 1px solid var(--line-2); border-radius: var(--radius); padding: 22px;
  background: var(--card); box-shadow: var(--shadow-sm);
}
:root[data-theme="dark"] .card { border-color: var(--line); box-shadow: none; }
.card__k { margin: 0 0 10px; font-size: 13.5px; font-weight: 600; letter-spacing: -0.01em; color: var(--ink-soft); }

/* ====== Cabecera: una cápsula de cristal que flota ====== */
.top { position: sticky; top: 0; z-index: 50; height: var(--top-h); padding: 10px var(--gut) 0; pointer-events: none; }
.top__in {
  pointer-events: auto; position: relative; height: 56px; max-width: var(--maxw); margin: 0 auto; padding: 0 9px 0 16px;
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 24px; border-radius: 999px;
  background: var(--glass); border: 1px solid var(--glass-rim);
  -webkit-backdrop-filter: blur(26px) saturate(180%); backdrop-filter: blur(26px) saturate(180%);
  box-shadow: 0 0 0 1px var(--glass-edge), inset 0 1px 0 rgba(255, 255, 255, 0.55), var(--shadow-sm);
  transition: box-shadow .4s var(--ease-soft), background .4s var(--ease-soft);
}
:root[data-theme="dark"] .top__in { box-shadow: 0 0 0 1px var(--glass-edge), inset 0 1px 0 rgba(255, 255, 255, 0.08), var(--shadow-sm); }
.top.is-scrolled .top__in { box-shadow: 0 0 0 1px var(--glass-edge), inset 0 1px 0 rgba(255, 255, 255, 0.55), var(--shadow-md); }
.logo { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; color: var(--ink); }
.logo__mark { width: 30px; height: 30px; flex: none; transition: transform .7s var(--ease-spring); filter: drop-shadow(0 4px 8px rgba(47, 107, 255, 0.35)); }
.logo:hover .logo__mark { transform: rotate(-10deg) scale(1.08); }
.logo__word { font-size: 19px; font-weight: 700; letter-spacing: -0.045em; line-height: 1; }
.logo__word em { font-style: normal; background: var(--grad-brand); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.top__nav { display: flex; align-items: center; gap: 6px; }
.top__btn { height: 38px; padding: 0 14px; font-size: 14px; }
body:not([data-vista="inicio"]) .top__cta { display: none; }

/* La barra de progreso: siete tramos, uno por fase y con su color */
.prog { justify-self: center; width: 100%; max-width: 520px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 14px; transition: opacity .4s var(--ease-soft); }
body[data-started="0"][data-vista="inicio"] .prog { opacity: 0; pointer-events: none; }
.prog__track { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.prog__seg {
  position: relative; height: 7px; border-radius: 999px; background: var(--fill); overflow: hidden;
  border: 0; padding: 0; cursor: pointer; transition: background .25s, transform .35s var(--ease-spring);
}
.prog__seg::after { content: ''; position: absolute; inset: -10px 0; }
.prog__seg:hover { transform: scaleY(1.35); }
.prog__seg i { position: absolute; inset: 0 auto 0 0; width: 0; border-radius: inherit; background: var(--h2); transition: width 1s var(--ease-out-quint); }
.prog__seg.is-bump i::after { content: ''; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.75), transparent); background-size: 50% 100%; background-repeat: no-repeat; animation: glint 1s var(--ease-soft) .25s both; }
@keyframes glint { from { background-position: -60% 0; } to { background-position: 160% 0; } }
.prog__seg.is-here { box-shadow: 0 0 0 1.5px var(--hc); }
.prog__seg.is-locked { cursor: not-allowed; }
.prog__meta { grid-column: 1; margin: 0; display: flex; align-items: baseline; gap: 8px; font-size: 12.5px; color: var(--ink-soft); line-height: 1; white-space: nowrap; overflow: hidden; }
.prog__meta b { font-size: 13px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.prog__meta span { overflow: hidden; text-overflow: ellipsis; }

/* ====== Vistas ====== */
.app { position: relative; z-index: 2; min-height: calc(100vh - var(--top-h)); }
.vista { display: none; }
body[data-vista="inicio"] .vista--inicio,
body[data-vista="fase"] .vista--fase,
body[data-vista="paso"] .vista--paso,
body[data-vista="final"] .vista--final { display: block; animation: vistaIn .6s var(--ease-out-quint) both; }
@keyframes vistaIn { from { opacity: 0; transform: translate3d(0, 14px, 0); } to { opacity: 1; transform: none; } }

/* Aparecer al entrar en pantalla (lo marca app.js) */
html.js .rv { opacity: 0; transform: translate3d(0, 22px, 0); transition: opacity .8s var(--ease-out-quint), transform .9s var(--ease-out-quint); transition-delay: calc(var(--i, 0) * 70ms); }
html.js .rv.is-in { opacity: 1; transform: none; }

/* ====== Inicio ====== */
.hero {
  max-width: var(--maxw); margin: 0 auto; padding: 40px var(--gut) 32px;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr); gap: 44px; align-items: center;
  min-height: calc(100vh - var(--top-h)); min-height: calc(100svh - var(--top-h));
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 9px; height: 36px; margin: 0; padding: 0 15px 0 6px; border-radius: 999px;
  background: var(--glass-strong); border: 1px solid var(--glass-edge); box-shadow: var(--shadow-sm);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  font-size: 14px; font-weight: 560; color: var(--ink-2); letter-spacing: -0.015em;
}
.eyebrow .gi { --s: 26px; border-radius: 50%; }
.hero__t { margin: 22px 0 18px; font-size: clamp(42px, 4.7vw, 70px); font-weight: 750; line-height: 0.99; letter-spacing: -0.052em; text-wrap: balance; }
.hero__d { margin: 0; max-width: 29em; font-size: 19.5px; line-height: 1.45; letter-spacing: -0.02em; color: var(--ink-soft); text-wrap: pretty; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 30px 0 0; }
.hero__chips { list-style: none; margin: 24px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 20px; }
.hero__chips li { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 520; color: var(--ink-soft); }
.hero__chips .gi { --s: 22px; border-radius: 7px; }
.hero__resume { display: flex; align-items: center; gap: 14px; margin: 26px 0 0; padding: 12px 18px 12px 12px; border-radius: 20px; width: fit-content; max-width: 100%; background: var(--card); border: 1px solid var(--line-2); box-shadow: var(--shadow-sm); }
.hero__resume .ring { width: 46px; height: 46px; }
.hero__resume p { margin: 0; font-size: 14px; color: var(--ink-soft); line-height: 1.4; }
.hero__resume b { display: block; font-size: 16px; color: var(--ink); font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.hero__resume .link { font-size: 13.5px; }

/* La composición del inicio: tu tienda (montada aquí, no capturada) en el portátil y su ficha en el móvil, que se
   solapan solo por el canto; dos cristales con lo que hace Claude, siempre dentro del marco para que nada se corte.
   Las entradas animan translate/scale/rotate: el transform queda libre para el paralaje del ratón */
.hero__vis { position: relative; aspect-ratio: 1 / 0.74; width: 100%; max-width: 660px; justify-self: end; }
.hero__vis > .hero__dev { position: absolute; left: 0; top: 10%; width: 82%; transition: transform 1.2s var(--ease-out-quint); animation: devIn 1.2s var(--ease-out-quint) .1s both; }
@keyframes devIn { from { opacity: 0; translate: 0 28px; scale: 0.97; } to { opacity: 1; translate: none; scale: none; } }
.hero__vis > .hero__phone { position: absolute; right: 0; bottom: 3%; width: 24%; z-index: 2; transition: transform 1.2s var(--ease-out-quint); animation: phoneIn 1.15s var(--ease-spring) .5s both; }
@keyframes phoneIn { from { opacity: 0; translate: 34px 44px; rotate: 5deg; } to { opacity: 1; translate: none; rotate: none; } }
.hv {
  position: absolute; border-radius: 20px; background: var(--glass-strong); border: 1px solid var(--glass-rim);
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  box-shadow: 0 0 0 1px var(--glass-edge), inset 0 1px 0 rgba(255, 255, 255, 0.6), var(--shadow-lg);
  transition: transform 1.2s var(--ease-out-quint);
  animation: hvIn 1s var(--ease-spring) both, hvFloat 9s ease-in-out infinite alternate;
}
:root[data-theme="dark"] .hv { box-shadow: 0 0 0 1px var(--glass-edge), inset 0 1px 0 rgba(255, 255, 255, 0.08), var(--shadow-lg); }
@keyframes hvIn { from { opacity: 0; scale: 0.9; } to { opacity: 1; scale: 1; } }
@keyframes hvFloat { from { translate: 0 -2px; } to { translate: 0 2px; } }
.hv--auto { right: 7%; top: 3%; display: inline-flex; align-items: center; gap: 10px; padding: 7px 16px 7px 7px; border-radius: 999px; animation-delay: .9s, -3s; z-index: 3; }
.hv--report { left: 0; bottom: 0; width: 44%; padding: 12px 14px 8px; animation-delay: 1.1s, -4.5s; z-index: 3; }
.hv__k { margin: 0 0 6px; display: flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 600; color: var(--ink-soft); letter-spacing: -0.01em; }
.hv__k .gi { --s: 20px; border-radius: 6px; }
.hv--auto .gi { --s: 30px; border-radius: 50%; }
.hv--auto b { display: block; font-size: 13.5px; font-weight: 650; letter-spacing: -0.02em; line-height: 1.2; }
.hv--auto small { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--ink-soft); line-height: 1.2; }
.hv--auto small::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--ok-fill); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok-fill) 22%, transparent); animation: pulse 1.8s ease-in-out infinite; }
.typing { display: inline-flex; gap: 3px; }
.typing i { width: 4px; height: 4px; border-radius: 50%; background: currentColor; animation: typing 1.2s ease-in-out infinite; }
.typing i:nth-child(2) { animation-delay: .15s; }
.typing i:nth-child(3) { animation-delay: .3s; }
@keyframes typing { 0%, 60%, 100% { opacity: .25; transform: none; } 30% { opacity: 1; transform: translateY(-2px); } }
.hvr { list-style: none; margin: 0; padding: 0; display: grid; }
.hvr li { display: grid; grid-template-columns: 16px minmax(0, 1fr) auto; align-items: center; gap: 8px; padding: 7px 0; font-size: 12.5px; font-weight: 520; letter-spacing: -0.015em; }
.hvr li + li { border-top: 1px solid var(--line-2); }
.hvr__n { font-size: 11.5px; font-weight: 600; color: var(--ink-muted); }
.hvr__t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hvr__s { min-width: 30px; text-align: center; font-size: 11.5px; font-weight: 700; color: #fff; border-radius: 999px; padding: 3px 8px; background: #2f6bff; font-variant-numeric: tabular-nums; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22); }
/* La entrada del titular: cada línea sube con un desenfoque que se va */
.vista--inicio .hero__txt > * { animation: heroIn .9s var(--ease-out-quint) both; }
.vista--inicio .hero__txt > :nth-child(2) { animation-delay: .07s; }
.vista--inicio .hero__txt > :nth-child(3) { animation-delay: .14s; }
.vista--inicio .hero__txt > :nth-child(4) { animation-delay: .21s; }
.vista--inicio .hero__txt > :nth-child(5) { animation-delay: .28s; }
.vista--inicio .hero__txt > :nth-child(6) { animation-delay: .35s; }
@keyframes heroIn { from { opacity: 0; transform: translate3d(0, 16px, 0); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
/* Ventana de navegador clara (la tienda y otras webs) */
.bw__bar { height: 30px; display: flex; align-items: center; gap: 12px; padding: 0 12px; background: #f3f3f5; border-bottom: 1px solid #e6e6ea; }
.bw__dots { display: inline-flex; gap: 6px; }
.bw__dots i { width: 9px; height: 9px; border-radius: 50%; background: #d4d4d8; }
.bw__dots i:nth-child(1) { background: #ff5f57; } .bw__dots i:nth-child(2) { background: #febc2e; } .bw__dots i:nth-child(3) { background: #28c840; }
.bw__url { flex: 1; max-width: 260px; margin: 0 auto; height: 20px; border-radius: 7px; background: #fff; border: 1px solid #e6e6ea; color: #555; font-size: 10.5px; display: inline-flex; align-items: center; justify-content: center; gap: 5px; }
.bw__url .ic { width: 10px; height: 10px; }

/* Secciones del inicio */
.sec { max-width: var(--maxw); margin: 0 auto; padding: 104px var(--gut) 0; }
.sec__head { max-width: 760px; margin: 0 auto 44px; text-align: center; }
.sec__head .kicker { margin-bottom: 10px; }
.sec__head .lead { margin: 0 auto; max-width: 34em; }

/* Cómo funciona: tú → Claude con la skill → tu tienda */
.dia { display: grid; grid-template-columns: minmax(0, 1fr) 76px minmax(0, 1.25fr) 76px minmax(0, 1fr); align-items: center; max-width: 1020px; margin: 0 auto; }
.dia__n {
  position: relative; display: grid; justify-items: center; gap: 10px; text-align: center; padding: 28px 20px 24px; border-radius: 30px;
  background: var(--card); border: 1px solid var(--line-2); box-shadow: var(--shadow-sm);
}
:root[data-theme="dark"] .dia__n { border-color: var(--line); }
.dia__n b { font-size: 18px; font-weight: 680; letter-spacing: -0.03em; line-height: 1.15; }
.dia__n small { font-size: 14.5px; color: var(--ink-soft); line-height: 1.4; }
.dia__n--ai { padding: 32px 22px 26px; box-shadow: 0 0 0 1.5px var(--brand), var(--shadow-md); }
.dia__does { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 4px; }
.dia__does > span { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px 0 5px; border-radius: 999px; background: var(--fill-2); font-size: 13px; font-weight: 600; letter-spacing: -0.01em; }
.dia__does .gi { --s: 21px; border-radius: 50%; }
.dia__l { position: relative; height: 2px; margin: 0 6px; background-image: radial-gradient(circle, var(--line-strong) 1.2px, transparent 1.6px); background-size: 8px 2px; background-repeat: repeat-x; background-position: center; }
.dia__l i { position: absolute; top: 50%; left: 0; width: 9px; height: 9px; margin-top: -4.5px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 4px rgba(var(--brand-rgb), 0.15), 0 0 14px rgba(var(--brand-rgb), 0.8); animation: diaDot 2.6s var(--ease-soft) infinite; }
.dia__l:nth-of-type(4) i { animation-delay: 1.3s; }
@keyframes diaDot { 0% { left: 0; opacity: 0; } 15%, 85% { opacity: 1; } 100% { left: calc(100% - 9px); opacity: 0; } }

/* Las siete fases: tarjeta blanca con su cabecera de color plano y el arte encima */
.phases { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.phases > li { display: grid; }
.ph {
  position: relative; display: flex; flex-direction: column; border-radius: 28px; text-decoration: none; color: inherit; overflow: hidden;
  background: var(--card); border: 1px solid var(--line-2); box-shadow: var(--shadow-sm);
  transition: transform .6s var(--ease-out-quint), box-shadow .5s var(--ease-soft);
}
:root[data-theme="dark"] .ph { border-color: var(--line); }
.ph:hover { transform: translate3d(0, -5px, 0); box-shadow: var(--shadow-md); }
.ph:active { transform: scale(0.985); transition-duration: .15s; }
.ph:focus-visible { outline: 3px solid rgba(var(--brand-rgb), 0.45); outline-offset: 3px; }
.ph__art { display: grid; place-items: center; height: 148px; background: color-mix(in srgb, var(--h2) 9%, var(--bg-soft)); }
:root[data-theme="dark"] .ph__art { background: color-mix(in srgb, var(--h2) 17%, #141416); }
.ph__body { display: flex; flex-direction: column; gap: 5px; flex: 1; padding: 18px 20px 18px; }
.ph__n { font-size: 13px; font-weight: 650; color: var(--hc); letter-spacing: -0.005em; }
.ph__t { margin: 0; font-size: 20px; font-weight: 700; line-height: 1.15; letter-spacing: -0.035em; }
.ph__d { margin: 2px 0 0; font-size: 14.5px; color: var(--ink-soft); line-height: 1.42; letter-spacing: -0.012em; }
.ph__st { margin-top: auto; padding-top: 14px; display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.ph__st .ring { width: 22px; height: 22px; }
.ph__st .st { width: 22px; height: 22px; }
.ph__st .st .ic { width: 12px; height: 12px; }
.ph.is-done .ph__st { color: var(--ok); }
.ph__go { margin-left: auto; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--fill-2); color: var(--ink); transition: background .3s, color .3s, transform .5s var(--ease-spring); }
.ph__go .ic { width: 16px; height: 16px; }
.ph:hover .ph__go { background: var(--h2); color: #fff; transform: translateX(3px); }
.ph--final { background: var(--brand); color: #fff; border-color: transparent; box-shadow: 0 24px 50px -28px rgba(var(--brand-rgb), 0.9); }
.ph--final .ph__art { background: rgba(255, 255, 255, 0.1); }
.ph--final .ph__n { color: rgba(255, 255, 255, 0.82); }
.ph--final .ph__d { color: rgba(255, 255, 255, 0.86); }
.ph--final .ph__t em { color: #fff; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.ph--final .ph__art .gi { --s: 72px; --h2: rgba(255, 255, 255, 0.18); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.4); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.ph--final .ph__go, .ph--final:hover .ph__go { background: #fff; color: var(--brand); }

/* Lo que necesitas */
.need__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.need__i { display: grid; gap: 14px; align-content: start; padding: 22px; border-radius: 28px; background: var(--card); border: 1px solid var(--line-2); box-shadow: var(--shadow-sm); }
:root[data-theme="dark"] .need__i { border-color: var(--line); }
.need__i b { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 17px; font-weight: 680; letter-spacing: -0.025em; }
.need__i p { margin: 4px 0 0; font-size: 14.5px; color: var(--ink-soft); line-height: 1.42; }
.need__i .tag { justify-self: start; }
.need__price { display: inline-flex; align-items: baseline; gap: 4px; margin-top: 2px; font-size: 13.5px; color: var(--ink-soft); }
.need__price strong { font-size: 22px; font-weight: 720; letter-spacing: -0.04em; color: var(--ink); font-variant-numeric: tabular-nums; }

/* El cierre: una banda con el color de la marca */
.close { max-width: var(--maxw); margin: 0 auto; padding: 104px var(--gut) 0; }
.close__in {
  position: relative; overflow: hidden; display: grid; justify-items: center; gap: 22px; text-align: center; padding: 64px 28px;
  border-radius: 40px; background: #1d1d1f; color: #fff; box-shadow: var(--shadow-lg);
}
:root[data-theme="dark"] .close__in { background: #141416; border: 1px solid var(--line); }
.close__in > * { position: relative; }
.close__in .h2 { margin: 0; color: #fff; max-width: 15em; }
.close__in .h2 em { color: #7aa5ff; }
.close__in .lead { color: rgba(255, 255, 255, 0.78); }
.close__icons { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.close__icons .gi { --s: 44px; box-shadow: none; }
.close__icons .gi:nth-child(odd) { translate: 0 -6px; }

.site-footer { position: relative; z-index: 2; margin-top: 80px; border-top: 1px solid var(--line); padding: 30px var(--gut) 40px; }
.footer__inner { max-width: var(--maxw); margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 28px; }
.footer__logo img { height: 20px; width: auto; filter: var(--logo-filter); opacity: 0.75; display: block; transition: opacity .3s, transform .4s var(--ease-out-quint); }
.footer__logo:hover img { opacity: 1; transform: translate3d(0, -2px, 0); }
.footer__nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer__nav a { font-size: 13px; color: var(--ink-soft); text-decoration: none; transition: color .3s; }
.footer__nav a:hover { color: var(--ink); }
.footer__credit { margin: 0; font-size: 13px; color: var(--ink-muted); }

/* ====== Resumen de una fase ====== */
.vista--fase { padding: 18px var(--gut) 96px; }
.fv { max-width: 1120px; margin: 0 auto; }
.fv__hero { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 36px; align-items: center; padding: 6px 0 26px; }
.fv__art { display: grid; place-items: center; width: 200px; height: 200px; border-radius: 44px; background: color-mix(in srgb, var(--h2) 9%, var(--bg-soft)); }
:root[data-theme="dark"] .fv__art { background: color-mix(in srgb, var(--h2) 17%, #141416); }
.fv__t { margin: 0 0 12px; font-size: clamp(36px, 4.6vw, 58px); font-weight: 750; line-height: 1; letter-spacing: -0.05em; text-wrap: balance; }
.fv__lead { margin: 0; font-size: 18.5px; color: var(--ink-soft); max-width: 36em; line-height: 1.45; letter-spacing: -0.018em; }
.fv__lead b { color: var(--ink); font-weight: 600; }
.fv__prog { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 0 6px; font-size: 14px; font-weight: 550; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.fv__prog .ring { width: 30px; height: 30px; }
.fv__prog b { color: var(--ink); }
.fv__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 24px 0 0; }
/* Los pasos, en baldosas: icono, número y título. Lo que hace cada uno sale al pasar el ratón (data-tip) */
.fv__steps { list-style: none; margin: 6px 0 0; padding: 0; display: grid; grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); gap: 12px; }
.fv__step {
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto 1fr auto; grid-template-areas: "ic st" "n n" "name name";
  min-height: 172px; padding: 18px 18px 20px; border-radius: 26px; background: var(--card); border: 1px solid var(--line-2); box-shadow: var(--shadow-sm); cursor: pointer;
  transition: transform .55s var(--ease-spring), box-shadow .35s var(--ease-soft), border-color .35s var(--ease-soft);
}
:root[data-theme="dark"] .fv__step { border-color: var(--line); box-shadow: none; }
.fv__step:hover, .fv__step:focus-visible, .fv__step.is-on { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: color-mix(in srgb, var(--h2) 34%, var(--line-2)); outline: none; }
.fv__step > .gi { grid-area: ic; --s: 46px; }
.fv__step > .st { grid-area: st; }
.fv__step[data-st="is-here"] { border-color: transparent; box-shadow: 0 0 0 2px var(--h2), var(--shadow-md); }
.fv__step.is-locked { cursor: not-allowed; box-shadow: none; background: transparent; border-style: dashed; }
.fv__step.is-locked:hover { transform: none; box-shadow: none; }
.fv__step.is-locked .gi { filter: grayscale(1); opacity: 0.45; }
.fv__step.is-locked .fv__name { color: var(--ink-muted); }
.fv__n { grid-area: n; align-self: end; margin: 22px 0 3px; font-size: 12.5px; font-weight: 650; color: var(--hc); font-variant-numeric: tabular-nums; letter-spacing: -0.005em; }
.fv__name { grid-area: name; min-width: 0; font-size: 17px; font-weight: 650; letter-spacing: -0.025em; line-height: 1.25; text-wrap: balance; }
/* El error típico y qué hacer si algo sale mal: una píldora cada uno; el texto, al pasar el ratón o al tocarla */
.fv__tips { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0 0; }
.fv__tip {
  display: inline-flex; align-items: center; gap: 9px; height: 40px; padding: 0 16px 0 7px; border-radius: 999px; cursor: help;
  border: 1px solid var(--line-2); background: var(--card); color: var(--ink-soft); font: inherit; font-size: 14px; font-weight: 600; letter-spacing: -0.012em;
  transition: color .25s var(--ease-soft), box-shadow .3s var(--ease-soft), transform .45s var(--ease-spring);
}
.fv__tip:hover, .fv__tip:focus-visible, .fv__tip.is-on { color: var(--ink); box-shadow: var(--shadow-sm); transform: translateY(-1px); outline: none; }
.fv__tip .gi { --s: 26px; border-radius: 50%; }
.chips { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.chips li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; align-items: start; font-size: 14.5px; font-weight: 520; letter-spacing: -0.015em; line-height: 1.35; }
.chips li > .ic { width: 22px; height: 22px; padding: 4px; border-radius: 50%; background: color-mix(in srgb, var(--hc) 14%, transparent); color: var(--hc); }
.fv__choice { margin: 18px 0 0; padding: 24px; border-radius: 30px; background: var(--card); border: 1px solid var(--line-2); box-shadow: var(--shadow-sm); }
.fv__choice > p { margin: 0 0 14px; font-size: 16px; color: var(--ink-soft); }
.fv__choice > p b { color: var(--ink); }
.fv__lock { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; color: var(--ink-muted); }
.fv__lock .ic { width: 15px; height: 15px; }

/* Estado de un paso: vacío, hecho (verde), lo siguiente (azul) o cerrado (candado) */
.st { position: relative; display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; border: 1.75px solid rgba(var(--c), 0.18); color: var(--ink-muted); flex: none; }
.st .ic { width: 14px; height: 14px; }
.st.is-done { background: var(--ok-fill); border-color: var(--ok-fill); color: #fff; }
.st.is-here { border-color: var(--brand); }
.st.is-here::after { content: ''; width: 10px; height: 10px; border-radius: 50%; background: var(--brand); animation: pulse 1.8s ease-in-out infinite; }
.st.is-locked { border-color: transparent; background: var(--fill-2); }
.st.is-skip { border-style: dashed; }
.st.is-skip::after { content: ''; width: 9px; height: 1.75px; border-radius: 2px; background: var(--ink-muted); }

/* ====== Un paso ====== */
.vista--paso { padding: 20px var(--gut) calc(var(--pie-h) + 36px); max-width: var(--maxw); margin: 0 auto; }
.paso { display: none; }
.paso.is-on { display: block; animation: pasoIn .6s var(--ease-out-quint) both; }
@keyframes pasoIn { from { opacity: 0; transform: translate3d(0, 10px, 0); } to { opacity: 1; transform: none; } }
.paso__head { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 18px; align-items: center; margin: 0 0 28px; max-width: 980px; }
.paso__ic { grid-row: 1 / span 3; align-self: start; margin-top: 2px; }
.paso__ic.gi { --s: 58px; }
.paso.is-done .paso__ic::after { content: none; }
.paso__ok { display: none; position: absolute; right: -6px; bottom: -6px; width: 24px; height: 24px; border-radius: 50%; background: var(--ok-fill); border: 2.5px solid var(--bg); place-items: center; }
.paso__ok .ic { width: 13px; height: 13px; color: #fff; filter: none; }
.paso.is-done .paso__ok { display: grid; animation: okPop .5s var(--ease-spring) both; }
@keyframes okPop { from { transform: scale(0); } to { transform: scale(1); } }
.paso__k { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 0 0 6px; font-size: 14px; font-weight: 600; color: var(--hc); letter-spacing: -0.01em; }
.paso__k a { color: inherit; text-decoration: none; }
.paso__k a:hover { text-decoration: underline; text-underline-offset: 3px; }
.paso__k > i { width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: 0.5; }
.paso__pos { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-soft); font-weight: 550; font-variant-numeric: tabular-nums; }
.paso__dots { display: inline-flex; align-items: center; gap: 4px; }
.paso__dots i { width: 6px; height: 6px; border-radius: 999px; background: var(--fill); transition: width .5s var(--ease-out-quint), background .3s; }
.paso__dots i.is-done { background: color-mix(in srgb, var(--hc) 45%, transparent); }
.paso__dots i.is-on { width: 18px; background: var(--hc); }
.paso__row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.paso__t { margin: 0; font-size: clamp(30px, 3.4vw, 46px); font-weight: 740; line-height: 1.04; letter-spacing: -0.045em; text-wrap: balance; }
.paso__d { margin: 10px 0 0; font-size: 18px; line-height: 1.45; letter-spacing: -0.018em; color: var(--ink-soft); max-width: 62ch; text-wrap: pretty; }
.paso__d b { color: var(--ink); font-weight: 600; }

/* Composiciones */
.lay { display: grid; gap: 28px; align-items: start; }
.lay--split { grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr); }
.lay--even { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.lay--center { max-width: 820px; }
.lay__col { display: grid; gap: 18px; align-content: start; min-width: 0; }

/* Instrucciones numeradas (cortas): el número en el color de la fase */
.do { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; counter-reset: do; }
.do > li { position: relative; display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; align-items: start; counter-increment: do; font-size: 15.5px; line-height: 1.45; letter-spacing: -0.015em; color: var(--ink-2); }
.do > li::before {
  content: counter(do); display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  font-size: 13.5px; font-weight: 700; color: var(--hc); background: color-mix(in srgb, var(--hc) 13%, transparent);
  font-variant-numeric: tabular-nums; transition: background .3s, color .3s, transform .45s var(--ease-spring);
}
.do > li > div { padding-top: 4px; min-width: 0; }
.do > li b { color: var(--ink); font-weight: 650; }
.do > li.is-done::before { content: ''; color: #fff; background: var(--ok-fill) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5' fill='none' stroke='%23fff' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 15px no-repeat; }
.do__act { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }

/* Nota corta con su icono en una baldosa pálida */
.note { display: flex; gap: 12px; align-items: flex-start; margin: 0; padding: 14px 16px 14px 14px; border-radius: 20px; background: var(--fill-2); font-size: 14.5px; color: var(--ink-soft); line-height: 1.45; letter-spacing: -0.012em; }
.note > .ic { width: 30px; height: 30px; padding: 6.5px; margin-top: -3px; border-radius: 10px; color: var(--hc); background: color-mix(in srgb, var(--hc) 14%, transparent); }
.note b { color: var(--ink); font-weight: 620; }
.note--bad { background: var(--danger-soft); }
.note--bad > .ic { color: var(--danger); background: color-mix(in srgb, var(--danger-fill) 16%, transparent); }

/* ====== Pie de cada paso: una cápsula de cristal ====== */
.pie {
  position: fixed; left: 50%; bottom: 16px; z-index: 40; width: min(1000px, calc(100% - 2 * var(--gut))); height: 68px;
  transform: translate3d(-50%, 150%, 0); transition: transform .7s var(--ease-out-quint);
}
body[data-vista="paso"] .pie { transform: translate3d(-50%, 0, 0); }
.pie__in {
  height: 100%; padding: 0 10px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 16px;
  border-radius: 999px; background: var(--glass); border: 1px solid var(--glass-rim);
  -webkit-backdrop-filter: blur(28px) saturate(180%); backdrop-filter: blur(28px) saturate(180%);
  box-shadow: 0 0 0 1px var(--glass-edge), inset 0 1px 0 rgba(255, 255, 255, 0.55), var(--shadow-lg);
}
:root[data-theme="dark"] .pie__in { box-shadow: 0 0 0 1px var(--glass-edge), inset 0 1px 0 rgba(255, 255, 255, 0.08), var(--shadow-lg); }
.pie__in > .btn { height: 48px; }
.pie__mid { display: flex; align-items: center; justify-content: center; gap: 14px; min-width: 0; }
.pie .ck--big { height: 48px; padding: 0 20px 0 12px; border-radius: 999px; background: var(--fill-2); transition: background .25s, transform .45s var(--ease-spring); min-width: 0; }
.pie .ck--big:hover { background: var(--fill); }
.pie .ck--big:has(input:checked) { background: var(--ok-soft); }
.pie .ck--big .ck__t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pie__hint { display: flex; align-items: center; gap: 7px; margin: 0; font-size: 13.5px; color: var(--ink-soft); line-height: 1.35; min-width: 0; }
.pie__hint .ic { width: 16px; height: 16px; flex: none; }
.pie__hint b { color: var(--ink); font-weight: 600; }
.pie__hint.is-ok { color: var(--ok); font-weight: 550; }
.pie__next:not(.is-ready) { background: var(--fill-2); color: var(--ink); box-shadow: none; }
.pie__next:not(.is-ready):hover { background: var(--fill); }
.pie[data-mode="auto"] #pie-ck { display: none; }
.pie[data-mode="tool"] .pie__mid { visibility: hidden; }

/* ====== Capas: lista de pasos, herramientas, diálogos, hoja, avisos ====== */
.drawer { position: fixed; inset: 0; z-index: 120; }
.drawer__bg, .dlg__bg { position: absolute; inset: 0; background: var(--overlay); animation: fadeIn .35s var(--ease-soft); }
.drawer__panel {
  position: absolute; top: 10px; right: 10px; bottom: 10px; width: min(420px, calc(100% - 20px)); display: flex; flex-direction: column; overflow: hidden;
  border-radius: 32px; background: var(--glass-strong); border: 1px solid var(--glass-rim);
  -webkit-backdrop-filter: blur(30px) saturate(180%); backdrop-filter: blur(30px) saturate(180%);
  box-shadow: 0 0 0 1px var(--glass-edge), var(--shadow-lg);
  animation: drawerIn .55s var(--ease-out-quint);
}
@keyframes drawerIn { from { transform: translate3d(48px, 0, 0); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.drawer__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 22px 16px; }
.drawer__head .kicker { margin-bottom: 4px; color: var(--ink-soft); }
.drawer__t { margin: 0; font-size: 26px; font-weight: 720; letter-spacing: -0.04em; }
.drawer__t b { font-weight: 720; color: var(--brand-ink); font-variant-numeric: tabular-nums; }
.drawer__list { flex: 1; overflow-y: auto; padding: 4px 12px 20px; overscroll-behavior: contain; }
.drawer__foot { padding: 12px 22px 16px; border-top: 1px solid var(--line); }
.dfase { padding: 6px 0; }
.dfase + .dfase { border-top: 1px solid var(--line-2); }
.dfase__h { width: 100%; display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 10px; border: 0; background: none; text-align: left; cursor: pointer; border-radius: 16px; transition: background .2s; }
.dfase__h:hover { background: var(--fill-2); }
.dfase__h .gi { --s: 32px; }
.dfase__t { font-size: 15.5px; font-weight: 680; letter-spacing: -0.025em; }
.dfase__c { font-size: 12.5px; font-weight: 600; color: var(--ink-muted); font-variant-numeric: tabular-nums; }
.dfase.is-done .dfase__c { color: var(--ok); }
.dstep { width: 100%; display: grid; grid-template-columns: 32px 36px minmax(0, 1fr); align-items: center; gap: 10px; padding: 8px 10px; border: 0; background: none; text-align: left; cursor: pointer; border-radius: 14px; color: var(--ink-2); font-size: 14.5px; letter-spacing: -0.015em; transition: background .2s; }
.dstep .st { width: 22px; height: 22px; justify-self: center; }
.dstep .st .ic { width: 12px; height: 12px; }
.dstep:hover { background: var(--fill-2); color: var(--ink); }
.dstep.is-current { background: var(--brand-soft); color: var(--ink); font-weight: 600; }
.dstep.is-locked { cursor: not-allowed; color: var(--ink-muted); }
.dstep__n { font-size: 12.5px; font-weight: 650; color: var(--hc); font-variant-numeric: tabular-nums; }

.pop {
  position: fixed; z-index: 110; width: 330px; padding: 10px; border-radius: 26px;
  background: var(--glass-strong); border: 1px solid var(--glass-rim);
  -webkit-backdrop-filter: blur(30px) saturate(180%); backdrop-filter: blur(30px) saturate(180%);
  box-shadow: 0 0 0 1px var(--glass-edge), var(--shadow-lg);
  transform-origin: 90% 0; animation: popIn .45s var(--ease-spring);
}
@keyframes popIn { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: none; } }
.pop__k { margin: 6px 12px 8px; font-size: 13px; font-weight: 650; color: var(--ink-soft); }
.pop__i { width: 100%; display: grid; grid-template-columns: 36px minmax(0, 1fr); align-items: center; gap: 12px; padding: 8px 10px; border: 0; border-radius: 16px; background: none; text-align: left; cursor: pointer; transition: background .2s; }
.pop__i:hover, .pop__i:focus-visible { background: var(--fill-2); outline: none; }
.pop__i .gi { --s: 36px; }
.pop__i b { display: block; font-size: 15px; font-weight: 620; letter-spacing: -0.02em; }
.pop__i small { display: block; font-size: 12.5px; color: var(--ink-muted); }
.pop__foot { margin: 6px 12px 4px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 13px; }

.dlg { position: fixed; inset: 0; z-index: 130; display: grid; place-items: center; padding: 20px; }
.dlg__win {
  position: relative; width: min(560px, 100%); max-height: calc(100vh - 40px); overflow-y: auto; border-radius: 34px;
  background: var(--glass-strong); border: 1px solid var(--glass-rim);
  -webkit-backdrop-filter: blur(34px) saturate(180%); backdrop-filter: blur(34px) saturate(180%);
  box-shadow: 0 0 0 1px var(--glass-edge), var(--shadow-lg);
  animation: dlgIn .55s var(--ease-spring);
}
.dlg.is-wide .dlg__win { width: min(1080px, 100%); }
@keyframes dlgIn { from { opacity: 0; transform: translate3d(0, 18px, 0) scale(0.96); } to { opacity: 1; transform: none; } }
.dlg__x { position: absolute; top: 16px; right: 16px; z-index: 2; }
.dlg__body { padding: 34px 34px 30px; }
.dlg__t { margin: 0 0 10px; font-size: 32px; font-weight: 740; line-height: 1.06; letter-spacing: -0.045em; padding-right: 40px; }
.dlg__d { margin: 0; font-size: 16px; color: var(--ink-soft); line-height: 1.5; letter-spacing: -0.015em; }
.dlg__btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.dlg__badge { display: inline-grid; place-items: center; width: 58px; height: 58px; border-radius: 18px; margin-bottom: 18px; color: #fff; background: #12a15a; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25), 0 12px 24px -14px #12a15a; animation: okPop .6s var(--ease-spring) both; }
.dlg__badge .ic { width: 28px; height: 28px; }
.dlg__badge--warn { background: #ec3b31; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25), 0 12px 24px -14px #ec3b31; }
.dlg__art { display: grid; place-items: center; width: 132px; height: 132px; margin: -4px 0 16px; border-radius: 32px; background: color-mix(in srgb, var(--h2) 9%, var(--bg-soft)); }
:root[data-theme="dark"] .dlg__art { background: color-mix(in srgb, var(--h2) 17%, #141416); }
.dlg__art .gx { --sz: 116px; animation: okPop .7s var(--ease-spring) .1s both; }
.dlg__list li { animation: liIn .5s var(--ease-out-quint) both; }
.dlg__list li:nth-child(2) { animation-delay: .07s; }
.dlg__list li:nth-child(3) { animation-delay: .14s; }
.dlg__list li:nth-child(4) { animation-delay: .21s; }
@keyframes liIn { from { opacity: 0; transform: translate3d(0, 8px, 0); } }
.dlg__list { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 9px; }
.dlg__list li { display: flex; gap: 10px; align-items: center; font-size: 15px; color: var(--ink-2); letter-spacing: -0.015em; }
.dlg__list li .ic { width: 22px; height: 22px; padding: 4px; border-radius: 50%; color: #fff; background: var(--ok-fill); }
.credits p { font-size: 14.5px; color: var(--ink-soft); line-height: 1.6; margin: 0 0 12px; }
.credits a { color: var(--brand-ink); }

.sheet { position: fixed; inset: 0; z-index: 125; display: grid; place-items: center; padding: 20px; background: var(--overlay); animation: fadeIn .3s var(--ease-soft); }
.sheet__win {
  width: min(1120px, 100%); height: min(92vh, 900px); display: flex; flex-direction: column; border-radius: 34px; overflow: hidden;
  background: var(--bg); border: 1px solid var(--line); box-shadow: var(--shadow-lg); animation: dlgIn .55s var(--ease-spring);
}
.sheet__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 26px 16px; border-bottom: 1px solid var(--line); }
.sheet__head .kicker { margin-bottom: 4px; }
.sheet__t { margin: 0; font-size: 30px; font-weight: 740; letter-spacing: -0.045em; line-height: 1.08; }
.sheet__body { flex: 1; overflow-y: auto; padding: 24px 26px 30px; overscroll-behavior: contain; }

/* Avisos: una cápsula negra que crece bajo la cabecera */
.toasts { position: fixed; left: 50%; top: calc(var(--top-h) + 6px); z-index: 150; transform: translateX(-50%); display: grid; gap: 8px; justify-items: center; pointer-events: none; width: max-content; max-width: calc(100vw - 32px); }
.toast {
  display: inline-flex; align-items: center; gap: 10px; padding: 9px 18px 9px 9px; border-radius: 999px; max-width: 100%;
  background: #0b0b0d; color: #a1a1a6; font-size: 14px; letter-spacing: -0.012em;
  box-shadow: 0 18px 44px -16px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.06);
  transform-origin: 50% 0; animation: islandIn .6s var(--ease-spring) both;
}
.toast b { color: #fff; font-weight: 620; }
.toast .dot { width: 24px; height: 24px; animation: none; background: var(--ok-fill) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4L18 8' fill='none' stroke='%23fff' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 15px no-repeat; }
.toast--bad .dot { background: var(--warn-fill) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 6.5v7' stroke='%23fff' stroke-width='2.8' stroke-linecap='round'/%3E%3Ccircle cx='12' cy='17.6' r='1.6' fill='%23fff'/%3E%3C/svg%3E") center / 15px no-repeat; }
.toast.is-out { animation: islandOut .4s var(--ease-soft) both; }
@keyframes islandIn { from { opacity: 0; transform: scale(0.55, 0.4); } 55% { opacity: 1; } to { opacity: 1; transform: none; } }
@keyframes islandOut { to { opacity: 0; transform: scale(0.8, 0.6); } }

/* El interruptor de tema: el sol lleva al claro; la luna, al oscuro */
.top__theme .ic { width: 18px; height: 18px; transition: transform .6s var(--ease-spring); }
.top__theme:hover .ic { transform: rotate(-25deg); }
.top__theme .ic--moon { display: none; }
:root[data-theme="dark"] .top__theme .ic--sun { display: inline-block; }
:root:not([data-theme="dark"]) .top__theme .ic--sun { display: none; }
:root:not([data-theme="dark"]) .top__theme .ic--moon { display: inline-block; }

/* ====== Un portátil minimalista para enmarcar capturas y maquetas ====== */
.dev { position: relative; width: 100%; }
.dev--laptop { padding: 0 6.5%; }
.dev__screen {
  position: relative; padding: 2.4% 2.4% 3.3%; border-radius: 18px 18px 6px 6px; background: #0b0b0d;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.09), 0 0 0 1px rgba(0, 0, 0, 0.16), 0 44px 70px -42px rgba(16, 24, 64, 0.5);
}
.dev__screen::before { content: ''; position: absolute; top: 0.9%; left: 50%; width: 6px; height: 6px; margin-left: -3px; border-radius: 50%; background: #26262a; }
.dev__view { position: relative; border-radius: 6px; overflow: hidden; background: #fff; }
.dev__base {
  position: relative; height: 13px; margin: 0 -6.5%; border-radius: 3px 3px 16px 16px / 3px 3px 11px 11px;
  background: linear-gradient(180deg, #ededef 0%, #d5d6d9 55%, #babbbe 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85), 0 16px 24px -16px rgba(16, 24, 40, 0.5);
}
.dev__base::before { content: ''; position: absolute; top: 0; left: 50%; width: 15%; height: 5px; margin-left: -7.5%; border-radius: 0 0 9px 9px; background: #c4c5c9; box-shadow: inset 0 1px 1.5px rgba(0, 0, 0, 0.14); }
:root[data-theme="dark"] .dev__screen { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12), 0 0 0 1px rgba(255, 255, 255, 0.05), 0 44px 70px -42px rgba(0, 0, 0, 0.85); }
:root[data-theme="dark"] .dev__base { background: linear-gradient(180deg, #5a5a5f 0%, #3b3b3f 55%, #2b2b2e 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 16px 24px -16px rgba(0, 0, 0, 0.85); }
:root[data-theme="dark"] .dev__base::before { background: #424246; }
/* Dentro del portátil, la maqueta pierde su marco propio */
.dev__view > .mk, .dev__view > .slides__view { border: 0; border-radius: 0; box-shadow: none; }
.dev__view > .slides__view { background: #fff; }
/* Un móvil minimalista (marco negro, isla y esquinas redondas) para la ficha de la tienda */
.dev--phone .dev__screen { padding: 3.8%; border-radius: 19% / 8.8%; box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.14), 0 0 0 1px rgba(0, 0, 0, 0.18), 0 34px 54px -26px rgba(16, 24, 64, 0.55); }
.dev--phone .dev__screen::before { top: 2.9%; width: 30%; height: 3.4%; margin-left: -15%; border-radius: 999px; background: #000; z-index: 2; }
.dev--phone .dev__view { border-radius: 15% / 7%; background: #0b0b0c; }
:root[data-theme="dark"] .dev--phone .dev__screen { box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.16), 0 0 0 1px rgba(255, 255, 255, 0.06), 0 34px 54px -26px rgba(0, 0, 0, 0.9); }

/* ====== Transiciones entre pantallas: la cabecera y el pie se quedan quietos; el contenido se desliza
   hacia donde vas (adelante, a la izquierda; atrás, a la derecha) y lo que se repite viaja de un sitio al otro ====== */
/* El nombre va en la cápsula de cristal, no en su envoltorio: un view-transition-name aísla lo que lleva dentro
   («backdrop root») y el cristal de la cabecera y del pie dejaba de difuminar lo que pasa por debajo (se leía a través) */
.top__in { view-transition-name: top; }
.pie__in { view-transition-name: pie; }
.app { view-transition-name: main; }
/* Mientras se cambia de pantalla el navegador no difumina las capturas: la cápsula, más opaca ese medio segundo */
html.is-vt .top__in, html.is-vt .pie__in { background: var(--glass-strong); transition: none; }
::view-transition-group(*) { animation-duration: .62s; animation-timing-function: cubic-bezier(.22, 1, .36, 1); }
::view-transition-old(main) { animation: vtOut .28s cubic-bezier(.4, 0, 1, 1) both; }
::view-transition-new(main) { animation: vtIn .62s cubic-bezier(.22, 1, .36, 1) .04s both; }
html[data-nav="fwd"]::view-transition-old(main) { animation-name: vtOutL; }
html[data-nav="fwd"]::view-transition-new(main) { animation-name: vtInR; }
html[data-nav="back"]::view-transition-old(main) { animation-name: vtOutR; }
html[data-nav="back"]::view-transition-new(main) { animation-name: vtInL; }
@keyframes vtOut { to { opacity: 0; transform: scale(.985); } }
@keyframes vtIn { from { opacity: 0; transform: scale(1.012); } }
@keyframes vtOutL { to { opacity: 0; transform: translate3d(-36px, 0, 0); } }
@keyframes vtInR { from { opacity: 0; transform: translate3d(44px, 0, 0); } }
@keyframes vtOutR { to { opacity: 0; transform: translate3d(36px, 0, 0); } }
@keyframes vtInL { from { opacity: 0; transform: translate3d(-44px, 0, 0); } }
/* Lo que viaja (el arte de la fase, el icono del paso) se escala sin fundirse raro */
::view-transition-old(art), ::view-transition-new(art), ::view-transition-old(pic), ::view-transition-new(pic) { animation-duration: .62s; height: 100%; object-fit: contain; }
/* Con transiciones de pantalla, la vista ya no hace su propio fundido (lo de dentro, sí: entra en capas) */
@supports (view-transition-name: none) {
  body[data-vista] .vista, .paso.is-on { animation: none; }
}
/* El cambio de tema: el nuevo se abre en círculo desde el botón */
html.is-theme-vt .top__in, html.is-theme-vt .pie__in, html.is-theme-vt .app, html.is-theme-vt [style*="view-transition-name"] { view-transition-name: none !important; }
html.is-theme-vt::view-transition-old(root), html.is-theme-vt::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
html.is-theme-vt::view-transition-new(root) { z-index: 2; }

/* Al entrar en un paso, la cabecera y luego cada columna */
.paso.is-on > .paso__head { animation: riseIn .55s var(--ease-out-quint) both; }
.paso.is-on > :not(.paso__head) { animation: riseIn .6s var(--ease-out-quint) .08s both; }
.paso.is-on .lay > :nth-child(2) { animation: riseIn .65s var(--ease-out-quint) .14s both; }
@keyframes riseIn { from { opacity: 0; transform: translate3d(0, 12px, 0); } to { opacity: 1; transform: none; } }
/* La casilla que se marca deja una onda */
.ck input:checked + .ck__box::after { content: ''; position: absolute; inset: -2px; border-radius: 50%; border: 2px solid var(--ok-fill); pointer-events: none; animation: ckRing .7s var(--ease-out-quint) both; }
@keyframes ckRing { from { opacity: .85; transform: scale(1); } to { opacity: 0; transform: scale(2.2); } }
/* El cajón: cada fase entra un poco después de la anterior */
.drawer:not([hidden]) .dfase { animation: liIn .5s var(--ease-out-quint) both; animation-delay: calc(var(--i, 0) * 45ms + 80ms); }
/* Micro movimientos: la flecha de un botón empuja un poco; el icono de una fila crece al pasar */
.btn > .ic:last-child { transition: transform .45s var(--ease-spring); }
.btn:hover > .ic:last-child { transform: translateX(2px); }
.btn:hover > .ic:first-child:not(:last-child) { transform: none; }
.fv__step .gi, .pop__i .gi, .dfase__h .gi { transition: transform .5s var(--ease-spring); }
.fv__step:hover .gi, .pop__i:hover .gi, .dfase__h:hover .gi { transform: scale(1.07); }
.opt:active, .pill:active, .fv__step:active { transform: scale(.98); transition-duration: .12s; }
/* El icono del tema gira al cambiar */
.top__theme.is-spin .ic { animation: themeSpin .7s var(--ease-spring); }
@keyframes themeSpin { from { transform: rotate(-120deg) scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }

/* ====== Pantalla intermedia ====== */
@media (max-width: 1180px) {
  .hero { grid-template-columns: minmax(0, 1fr); min-height: 0; padding-top: 44px; gap: 52px; }
  .hero__vis { justify-self: center; max-width: 620px; }
  .phases { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .need__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .top__in { gap: 16px; }
}
@media (max-width: 980px) {
  :root { --gut: 22px; }
  .lay--split, .lay--even { grid-template-columns: minmax(0, 1fr); }
  .top__btn span { display: none; }
  .top__btn { width: 38px; padding: 0; }
  .dia { grid-template-columns: minmax(0, 1fr); gap: 0; max-width: 460px; }
  .dia__l { width: 2px; height: 40px; margin: 0 auto; background-image: radial-gradient(circle, var(--line-strong) 1.2px, transparent 1.6px); background-size: 2px 8px; background-repeat: repeat-y; }
  .dia__l i { left: 50%; top: 0; margin: 0 0 0 -4.5px; animation-name: diaDotV; }
  .fv__hero { grid-template-columns: minmax(0, 1fr); gap: 18px; padding: 0 0 22px; }
  .fv__steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fv__art { width: 140px; height: 140px; border-radius: 34px; }
  .fv__art .gx { --sz: 120px; }
}
@keyframes diaDotV { 0% { top: 0; opacity: 0; } 15%, 85% { opacity: 1; } 100% { top: calc(100% - 9px); opacity: 0; } }
/* ====== Móvil ====== */
@media (max-width: 680px) {
  :root { --gut: 16px; --top-h: 66px; --pie-h: 84px; }
  .top { padding-top: 8px; }
  .top__in { height: 50px; padding: 0 6px 0 12px; gap: 10px; border-radius: 22px; }
  .logo__word { font-size: 17px; }
  .logo__mark { width: 26px; height: 26px; }
  .prog { gap: 4px 8px; }
  .prog__meta span { display: none; }
  .top__cta span { display: none; }
  .top__cta { width: 38px; padding: 0; }
  .top__nav { gap: 4px; }
  .iconbtn, .top__btn { width: 36px; height: 36px; }
  .hero { padding-top: 28px; gap: 44px; }
  .hero__t { font-size: clamp(38px, 11vw, 50px); margin-top: 18px; }
  .hero__d { font-size: 17px; }
  .hero__cta .btn { flex: 1 1 auto; }
  .hero__vis { aspect-ratio: 1 / 0.92; }
  .hero__vis > .hero__dev { top: 13%; width: 84%; }
  .hero__vis > .hero__phone { width: 27%; bottom: 7%; }
  .hv--auto { right: 0; top: 0; gap: 8px; padding: 5px 12px 5px 5px; }
  .hv--auto .gi { --s: 24px; }
  .hv--auto b { font-size: 12px; }
  .hv--auto small { font-size: 11px; }
  .hv--report { width: 63%; padding: 10px 12px 6px; }
  .hvr li { padding: 6px 0; font-size: 12px; }
  .phases, .need__list { grid-template-columns: minmax(0, 1fr); }
  .ph { flex-direction: row; border-radius: 24px; }
  .ph__art { flex: none; width: 104px; height: auto; min-height: 120px; }
  .ph__art .gx { --sz: 86px; }
  .ph__art .gx__chip { display: none; }
  .ph__body { padding: 14px 16px 14px 14px; }
  .ph__t { font-size: 18px; }
  .ph__d { font-size: 14px; }
  .ph__st { padding-top: 8px; }
  .ph--final .ph__art .gi { --s: 56px; }
  .sec, .close { padding-top: 72px; }
  .close__in { padding: 44px 20px; border-radius: 32px; }
  .vista--paso { padding-top: 14px; }
  .paso__head { column-gap: 14px; }
  .paso__ic.gi { --s: 46px; }
  .paso__t { font-size: clamp(27px, 8vw, 34px); }
  .paso__d { font-size: 16px; }
  .pie { bottom: 10px; width: calc(100% - 20px); height: 62px; }
  .pie__in { gap: 8px; padding: 0 7px; border-radius: 26px; }
  .pie__in > .btn { height: 48px; }
  .pie__prev span, .pie__next span { display: none; }
  .pie__prev, .pie__next { width: 48px; padding: 0; }
  .pie__mid { justify-content: flex-start; }
  .pie .ck--big { padding: 0 14px 0 10px; height: 48px; }
  .pie__hint { font-size: 12.5px; }
  .ck__t { font-size: 14.5px; }
  .pie .ck--big .ck__t { font-size: 13.5px; line-height: 1.2; white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .dlg__body { padding: 28px 22px 24px; }
  .dlg__t { font-size: 27px; }
  .sheet { padding: 0; }
  .sheet__win { height: 100%; border-radius: 0; }
  .sheet__head, .sheet__body { padding-left: 18px; padding-right: 18px; }
  .fv__steps { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .fv__step { grid-template-columns: 40px minmax(0, 1fr) auto; grid-template-rows: auto auto; grid-template-areas: "ic n st" "ic name st"; column-gap: 12px; align-items: center; min-height: 0; padding: 12px 14px 12px 12px; border-radius: 22px; }
  .fv__step > .gi { --s: 40px; }
  .fv__n { margin: 0; align-self: end; }
  .fv__name { font-size: 16px; align-self: start; }
  .fv__hero { padding: 0 0 18px; }
  .vista--fase { padding-top: 12px; }
  .pop { left: 12px !important; right: 12px; width: auto; }
}

/* Con «reducir transparencia» del sistema, el cristal pasa a ser opaco */
@media (prefers-reduced-transparency: reduce) {
  :root { --glass: var(--card); --glass-strong: var(--card); --tip-bg: var(--card); }
  .top__in, .pie__in, .pop, .dlg__win, .drawer__panel, .tip, .hv, .eyebrow, .gx__glass, .dia__n--ai { -webkit-backdrop-filter: none; backdrop-filter: none; }
  .ambient { display: none; }
}
@media (hover: none) {
  .btn--primary:hover, .btn--ghost:hover, .ph:hover { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  /* Todo quieto MENOS las demos (.demo), que son el contenido y se mueven también
     con los efectos de animación de Windows apagados (ver DEMO_RM en js/demos.js). */
  *:not(.demo):not(.demo *), *:not(.demo):not(.demo *)::before, *:not(.demo):not(.demo *)::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
  html.js .rv { opacity: 1; transform: none; }
}
