/* =============================================================
   Proshop — Landing "suiza"
   Papel claro, retícula visible, hairlines, tipografía grande.
   El morado de marca se usa SOLO como acento.
   ============================================================= */

:root {
  /* Papel y tinta */
  --paper:      #f4f3ef;
  --paper-2:    #eceae4;   /* franja alterna */
  --card:       #ffffff;
  --ink:        #14140f;
  --ink-2:      #56554e;
  --ink-3:      #8b8a82;

  /* Reglas / hairlines */
  --rule:       rgba(20, 20, 15, 0.14);
  --rule-soft:  rgba(20, 20, 15, 0.07);

  /* Acentos de marca */
  --accent:     #6d28d9;
  --accent-ink: #4c1d95;
  --mint:       #12a97a;   /* verde marca, oscurecido para contraste sobre papel */

  /* Tipografía */
  --sans:  'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --disp:  'Inter Tight', 'Inter', system-ui, sans-serif;
  --mono:  'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;

  /* Métricas */
  --shell:   1240px;
  --gutter:  clamp(20px, 4vw, 56px);
  --sec-y:   clamp(72px, 9vw, 140px);
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: var(--disp);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.02;
  margin: 0;
  text-wrap: balance;
}

p  { margin: 0; }
ul, ol, dl { margin: 0; padding: 0; list-style: none; }
a  { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

::selection { background: var(--accent); color: #fff; }

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

/* ---------- Contenedor ---------- */
.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---------- Retícula de fondo: 12 columnas hairline ---------- */
.grid-lines {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: grid;
  grid-template-columns: repeat(12, 1fr);
}
.grid-lines span { border-left: 1px solid var(--rule-soft); }
.grid-lines span:last-child { border-right: 1px solid var(--rule-soft); }

@media (max-width: 900px) {
  .grid-lines span:nth-child(n + 5) { display: none; }
}

/* Todo el contenido va por encima de la retícula */
.nav, main, .foot { position: relative; z-index: 1; }

/* =============================================================
   Elementos compartidos
   ============================================================= */

/* Etiqueta monoespaciada: el detalle "técnico" del estilo suizo */
.tag, .idx, .who, .cl-lbl, .foot-lbl, .step-n, .feat-n,
.pk-lbl, .pk-unit, .stamp, .once, .nav-links a, .nav-login,
.spec dt, .p-cell[data-label]::before, .plan-labels .p-cell {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* ---------- Botones ---------- */
.btn {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  --btn-bd: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.005em;
  color: var(--btn-fg);
  background: var(--btn-bg);
  border: 1px solid var(--btn-bd);
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: background .18s ease, color .18s ease,
              border-color .18s ease, transform .18s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-solid { --btn-bg: var(--ink); --btn-fg: var(--paper); --btn-bd: var(--ink); }
.btn-solid:hover { --btn-bg: var(--accent); --btn-bd: var(--accent); }

.btn-line { --btn-bd: var(--rule); }
.btn-line:hover { --btn-bd: var(--ink); }

.btn-lg    { padding: 15px 30px; font-size: 15px; }
.btn-block { display: flex; width: 100%; }

/* ---------- Cabecera de sección ---------- */
.head {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr);
  gap: 0 24px;
  padding-bottom: clamp(36px, 5vw, 64px);
  border-top: 1px solid var(--ink);
  padding-top: 20px;
}
.head .idx {
  color: var(--accent);
  padding-top: 8px;
}
.head h2 {
  font-size: clamp(30px, 5vw, 58px);
  max-width: 17ch;
}
.head p {
  grid-column: 2;
  margin-top: 18px;
  max-width: 54ch;
  color: var(--ink-2);
  font-size: clamp(15px, 1.5vw, 18px);
}
.head p b { color: var(--ink); font-weight: 500; }

@media (max-width: 720px) {
  .head { grid-template-columns: 1fr; gap: 12px; }
  .head p { grid-column: 1; }
}

/* ---------- Secciones ---------- */
.section { padding-block: var(--sec-y); }
.section-tint { background: var(--paper-2); }

/* =============================================================
   Navegación
   ============================================================= */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--rule);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 68px;
}

.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo { height: 24px; width: auto; display: block; }
.brand-logo-sm { height: 18px; }

.nav-links { display: flex; gap: 28px; }
.nav-links a { color: var(--ink-2); transition: color .16s ease; }
.nav-links a:hover { color: var(--ink); }

.nav-actions { display: flex; align-items: center; gap: 16px; }
.nav-login { color: var(--ink-2); transition: color .16s ease; }
.nav-login:hover { color: var(--ink); }

.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  padding: 0;
  background: none;
  border: 1px solid var(--rule);
  border-radius: 999px;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.nav-toggle span {
  display: block;
  width: 15px; height: 1.5px;
  background: var(--ink);
  transition: transform .2s ease, opacity .2s ease;
}
.nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(3px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:last-child  { transform: translateY(-3px) rotate(-45deg); }

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .nav-login  { display: none; }
  .nav-links {
    position: absolute;
    inset: 68px 0 auto 0;
    flex-direction: column;
    gap: 0;
    padding: 8px var(--gutter) 20px;
    background: var(--paper);
    border-bottom: 1px solid var(--rule);
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 14px 0; border-bottom: 1px solid var(--rule-soft); }
}
@media (max-width: 480px) {
  .nav-actions .btn { padding: 10px 16px; font-size: 13px; }
}

/* =============================================================
   Hero
   ============================================================= */
.hero { padding-top: clamp(56px, 8vw, 104px); padding-bottom: clamp(48px, 6vw, 88px); }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--ink-2);
  margin-bottom: clamp(28px, 4vw, 48px);
}
.tag-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--mint);
  flex: none;
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1;   transform: scale(1); }
  50%      { opacity: .35; transform: scale(.8); }
}

.hero-title {
  font-size: clamp(42px, 9.2vw, 122px);
  font-weight: 600;
  letter-spacing: -0.05em;
  line-height: 0.94;
}
.hero-title em {
  font-style: normal;
  color: var(--accent);
}

.hero-foot {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: end;
  margin-top: clamp(36px, 5vw, 64px);
  padding-top: clamp(28px, 4vw, 44px);
  border-top: 1px solid var(--rule);
}
.hero-lead {
  font-size: clamp(16px, 1.7vw, 20px);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 52ch;
}
.hero-lead strong { color: var(--ink); font-weight: 500; }

.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.cta-note {
  flex-basis: 100%;
  font-size: 13px;
  color: var(--ink-3);
  margin-top: 2px;
}

@media (max-width: 860px) {
  .hero-foot { grid-template-columns: 1fr; align-items: start; }
}

/* ---------- Ficha técnica ---------- */
.specs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--ink);
  margin-top: clamp(48px, 7vw, 96px);
}
.spec {
  padding: 22px 22px 24px 0;
  border-right: 1px solid var(--rule);
  /* Referencia para las unidades cqi del valor (ver .spec dd). */
  container-type: inline-size;
}
.spec:last-child { border-right: 0; }
.spec dt { color: var(--ink-3); }
.spec dd {
  margin: 10px 0 6px;
  font-family: var(--disp);
  /* Un valor de una sola palabra ("Latinoamerica") no puede partirse en dos
     lineas, asi que a tamaño fijo se desborda sobre la columna vecina. El tope
     en cqi (1cqi = 1% del ancho de la columna) lo achica solo lo necesario
     para que quepa, sea cual sea el ancho de pantalla. */
  font-size: min(clamp(30px, 4.2vw, 52px), 16.5cqi);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 1;
  /* Ultima defensa: si algun dia entra una palabra aun mas larga, se parte
     dentro de su casilla en vez de invadir la de al lado. */
  overflow-wrap: break-word;
}
.spec p { font-size: 13px; color: var(--ink-2); max-width: 22ch; }

@media (max-width: 860px) {
  .specs { grid-template-columns: repeat(2, 1fr); }
  .spec { border-bottom: 1px solid var(--rule); padding-right: 16px; }
  .spec:nth-child(2n) { border-right: 0; }
  .spec:nth-last-child(-n + 2) { border-bottom: 0; }
}
@media (max-width: 460px) {
  .specs { grid-template-columns: 1fr; }
  .spec { border-right: 0; }
  .spec:nth-last-child(-n + 2) { border-bottom: 1px solid var(--rule); }
  .spec:last-child { border-bottom: 0; }
}

/* =============================================================
   Proyectos — paneles interactivos (pestañas verticales)
   ============================================================= */
.proj {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.6fr);
  gap: clamp(24px, 3vw, 48px);
  align-items: start;
}

/* ---------- Lista de proyectos ---------- */
.proj-tabs {
  display: grid;
  align-content: start;
  border-top: 1px solid var(--ink);
  position: sticky;
  top: 88px;
}

.proj-tab {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 20px;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 20px 16px 20px 0;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--rule);
  border-left: 2px solid transparent;
  font-family: var(--sans);
  text-align: left;
  cursor: pointer;
  transition: background .2s ease, border-color .2s ease, padding-left .2s ease;
}
.proj-tab:hover { background: color-mix(in srgb, var(--card) 60%, transparent); }

.proj-tab.is-active {
  background: var(--card);
  border-left-color: var(--accent);
  padding-left: 16px;
}

.proj-n {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  align-self: start;
  padding-top: 3px;
}
.proj-tab.is-active .proj-n { color: var(--accent); }

.proj-tab-body { display: grid; gap: 3px; min-width: 0; }
.proj-tab-name {
  font-family: var(--disp);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.proj-tab-type { font-size: 13px; color: var(--ink-2); line-height: 1.35; }

.proj-arrow {
  color: var(--ink-3);
  font-size: 15px;
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity .2s ease, transform .2s ease;
}
.proj-tab.is-active .proj-arrow { opacity: 1; transform: none; color: var(--accent); }

/* ---------- Panel del proyecto ---------- */
.proj-panels { min-width: 0; }

.proj-panel {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: clamp(22px, 3vw, 38px);
}
.proj-panel[hidden] { display: none; }
.proj-panel.is-active { animation: fadeSwap .32s ease both; }

@keyframes fadeSwap {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

.pp-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--rule);
}
.pp-head h3 { font-size: clamp(24px, 3vw, 36px); }
.pp-type { margin-top: 7px; font-size: 14px; color: var(--ink-2); }

.pp-state {
  flex: none;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid currentColor;
  white-space: nowrap;
}
.pp-state-produccion { color: var(--mint); }
.pp-state-desarrollo { color: var(--accent); }

.pp-resumen {
  margin-top: 20px;
  font-size: clamp(15px, 1.5vw, 17px);
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 58ch;
}

/* ---------- Boceto (wireframe SVG) ---------- */
.pp-boceto { margin: 26px 0 0; }

.pp-boceto .bo {
  display: block;
  width: 100%;
  height: auto;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 10px;
}
.pp-boceto figcaption {
  margin-top: 11px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink-3);
  max-width: 56ch;
}
/* Guioncito al costado, como pie de figura de revista */
.pp-boceto figcaption::before {
  content: "";
  display: inline-block;
  width: 14px;
  height: 1px;
  margin: 0 8px 4px 0;
  background: var(--accent);
}

/* Trazos del dibujo. Todo se pinta desde aca, el SVG solo lleva clases. */
.bo-s   { fill: none; stroke: var(--ink);   stroke-width: 1.5; }
.bo-s2  { fill: none; stroke: var(--ink-3); stroke-width: 1; }
.bo-a   { fill: none; stroke: var(--accent); stroke-width: 1.5; stroke-linecap: round; }
.bo-af  { fill: var(--accent); }
.bo-mf  { fill: var(--mint); }
.bo-f   { fill: var(--ink); }
.bo-f2  { fill: var(--rule); }
.bo-pf  { fill: var(--card); }
.bo-abg { fill: color-mix(in srgb, var(--accent) 7%, var(--card)); }
.bo-t {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  fill: var(--ink-3);
}
.bo-tb {
  font-family: var(--disp);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.03em;
  fill: var(--ink);
}

/* El dibujo se traza solo al entrar en pantalla */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .proj-panel.is-active .bo > * {
      animation: boceto .5s ease both;
      animation-delay: calc(var(--i, 0) * 6ms);
    }
  }
}
@keyframes boceto {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Métricas del proyecto */
.pp-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin-top: 26px;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.pp-metrics > div { padding: 18px 16px 18px 0; border-right: 1px solid var(--rule-soft); }
.pp-metrics > div:last-child { border-right: 0; }
.pp-metrics dd {
  margin: 0;
  font-family: var(--disp);
  font-size: clamp(22px, 2.6vw, 30px);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1;
}
.pp-metrics dt {
  margin-top: 7px;
  font-size: 12px;
  color: var(--ink-3);
  line-height: 1.35;
}

/* Dos columnas: qué hace / con qué */
.pp-cols {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: clamp(22px, 3vw, 44px);
  margin-top: 26px;
}
.pp-col h4 {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 14px;
}

.pp-feats { display: grid; gap: 9px; }
.pp-feats li {
  position: relative;
  padding-left: 17px;
  font-size: 14.5px;
  line-height: 1.45;
  color: var(--ink-2);
}
.pp-feats li::before {
  content: "";
  position: absolute;
  left: 0; top: 9px;
  width: 7px; height: 1px;
  background: var(--accent);
}

/* Llamada a la acción del panel de proyecto */
.pp-cta {
  padding: 20px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 4px;
  position: sticky;
  top: 96px;
}
.pp-cta h4 {
  font-family: var(--disp);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.025em;
  text-transform: none;
  color: var(--ink);
  margin: 0 0 8px;
}
.pp-cta > p {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink-2);
  margin-bottom: 18px;
}

.btn-wa { gap: 9px; }
.ico-wa { width: 17px; height: 17px; fill: currentColor; flex: none; }

/* Flechita de "se abre en otra pestaña" */
.btn-ext { gap: 9px; }
.ico-ext {
  width: 14px;
  height: 14px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pp-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.pp-links .btn { padding: 9px 14px; font-size: 12.5px; }

@media (max-width: 940px) {
  .pp-cta { position: static; }
}

.proj-foot {
  margin-top: clamp(28px, 4vw, 44px);
  padding-top: 22px;
  border-top: 1px solid var(--rule);
  font-size: 15px;
  color: var(--ink-2);
}
.proj-foot a { color: var(--accent); border-bottom: 1px solid currentColor; }

@media (max-width: 940px) {
  .proj { grid-template-columns: 1fr; }
  .proj-tabs { position: static; }
  .pp-cols { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .pp-head { flex-direction: column; }
  .pp-metrics { grid-template-columns: 1fr; }
  .pp-metrics > div {
    border-right: 0;
    border-bottom: 1px solid var(--rule-soft);
    padding-bottom: 14px;
  }
  .pp-metrics > div:last-child { border-bottom: 0; }
}

/* =============================================================
   Agente IA — intro + transcripción
   ============================================================= */
.agente-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: start;
  padding-bottom: clamp(44px, 6vw, 76px);
}
.ai-copy p {
  font-size: clamp(15px, 1.6vw, 18px);
  line-height: 1.6;
  color: var(--ink-2);
  margin-bottom: 24px;
  max-width: 44ch;
}
@media (max-width: 900px) { .agente-intro { grid-template-columns: 1fr; } }

.transcript {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 0 clamp(18px, 2.4vw, 30px) clamp(18px, 2.4vw, 26px);
}
.transcript-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 0;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--ink-3);
}
.live { display: inline-flex; align-items: center; gap: 6px; color: var(--mint); }
.live i {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
  animation: pulse 2.4s ease-in-out infinite;
}

.line {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--rule-soft);
}
.line:last-of-type { border-bottom: 0; }
.line .who { color: var(--ink-3); padding-top: 4px; }
.line p { font-size: 15px; line-height: 1.5; }
.line-us .who { color: var(--accent); }
.line-us p  { color: var(--ink); }
.line-them p { color: var(--ink-2); }
.line-us b { font-weight: 600; }

.transcript-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
}
.stamp {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border: 1px solid color-mix(in srgb, var(--mint) 35%, transparent);
  border-radius: 999px;
  color: var(--mint);
  font-size: 10px;
}
.stamp::before { content: "✓"; font-size: 10px; }

@media (max-width: 520px) {
  .line { grid-template-columns: 1fr; gap: 4px; }
  .line .who { padding-top: 0; }
}

/* =============================================================
   Qué hacemos
   ============================================================= */
.feats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}
.feat {
  padding: clamp(24px, 3vw, 40px);
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: transparent;
  transition: background .22s ease;
}
.feat:hover { background: var(--card); }
.feat-n { color: var(--accent); display: block; margin-bottom: 26px; }
.feat h3 {
  font-size: clamp(18px, 1.9vw, 22px);
  margin-bottom: 10px;
  max-width: 18ch;
}
.feat p { font-size: 14.5px; color: var(--ink-2); max-width: 34ch; }

@media (max-width: 900px) { .feats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .feats { grid-template-columns: 1fr; } }

/* =============================================================
   Proceso
   ============================================================= */
.steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--ink);
}
.step {
  padding: 28px 28px 40px 0;
  border-right: 1px solid var(--rule);
  position: relative;
}
.step:last-child { border-right: 0; }
.step-n {
  display: block;
  color: var(--ink-3);
  margin-bottom: 40px;
}
.step h3 { font-size: clamp(18px, 2vw, 23px); margin-bottom: 10px; max-width: 15ch; }
.step p  { font-size: 14.5px; color: var(--ink-2); max-width: 30ch; }

/* Marca de progreso sobre la regla superior */
.step::before {
  content: "";
  position: absolute;
  top: -1px; left: 0;
  width: 28px; height: 3px;
  background: var(--accent);
}

@media (max-width: 900px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step { border-bottom: 1px solid var(--rule); padding-right: 20px; }
  .step:nth-child(2n) { border-right: 0; }
}
@media (max-width: 520px) {
  .steps { grid-template-columns: 1fr; }
  .step { border-right: 0; padding-bottom: 30px; }
  .step-n { margin-bottom: 20px; }
}

/* =============================================================
   Planes (tabla)
   ============================================================= */
.plans-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.plans {
  display: grid;
  grid-template-columns: 190px repeat(var(--cols, 4), minmax(200px, 1fr));
  min-width: 100%;
  border-top: 1px solid var(--ink);
}

.plan {
  display: grid;
  grid-template-rows: auto auto repeat(4, auto) auto;
  border-right: 1px solid var(--rule);
  position: relative;
  background: transparent;
  transition: background .22s ease;
}
.plan:last-child { border-right: 0; }
.plan:hover { background: var(--card); }

.plan.is-reco {
  background: var(--card);
  border-inline: 1px solid var(--accent);
  border-bottom: 1px solid var(--accent);
  box-shadow: 0 0 0 1px var(--accent) inset;
  z-index: 2;
}
.reco {
  position: absolute;
  top: 0; left: 0; right: 0;
  background: var(--accent);
  color: #fff;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  padding: 5px 0;
}
.plan.is-reco .p-name { padding-top: 46px; }

.p-cell {
  padding: 16px 20px;
  border-bottom: 1px solid var(--rule-soft);
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 62px;
  font-size: 15px;
}
.p-cell b { font-weight: 600; font-family: var(--disp); font-size: 17px; letter-spacing: -0.02em; }
.once { color: var(--ink-3); font-size: 10px; margin-top: 3px; }

.p-name { padding-top: 26px; border-bottom: 0; }
.p-name h3 { font-size: clamp(20px, 2.2vw, 26px); }

.p-price { padding-top: 4px; padding-bottom: 24px; border-bottom: 1px solid var(--rule); }
.p-price .cur { font-family: var(--mono); font-size: 12px; color: var(--ink-3); }
.p-price .num {
  font-family: var(--disp);
  font-size: clamp(32px, 3.6vw, 46px);
  font-weight: 600;
  letter-spacing: -0.05em;
  line-height: 1;
}
.p-price .per { font-size: 13px; color: var(--ink-3); }

.p-cta { padding: 22px 20px; border-bottom: 0; }
.first-pay {
  font-size: 11.5px;
  color: var(--ink-3);
  text-align: center;
  margin-top: 9px;
}

.p-feats {
  padding: 0 20px 26px;
  display: grid;
  gap: 8px;
}
.p-feats li {
  position: relative;
  padding-left: 16px;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.45;
}
.p-feats li::before {
  content: "";
  position: absolute;
  left: 0; top: 8px;
  width: 6px; height: 1px;
  background: var(--accent);
}

/* Columna de etiquetas (solo escritorio) */
.plan-labels { border-right: 1px solid var(--rule); }
.plan-labels .p-cell {
  color: var(--ink-3);
  padding-left: 0;
  align-items: flex-start;
  text-align: left;
}
.plan-labels .p-name,
.plan-labels .p-price,
.plan-labels .p-cta { border-bottom-color: transparent; }
.plan-labels .p-price { border-bottom: 1px solid var(--rule); }

/* En pantallas medianas/chicas: sin columna de etiquetas, cada celda lleva la suya */
@media (max-width: 1080px) {
  .plans { grid-template-columns: repeat(var(--cols, 4), minmax(240px, 1fr)); }
  .plan-labels { display: none; }
  .p-cell[data-label] { display: block; }
  .p-cell[data-label]::before {
    content: attr(data-label);
    display: block;
    color: var(--ink-3);
    margin-bottom: 5px;
  }
}
@media (max-width: 780px) {
  .plans { grid-template-columns: repeat(var(--cols, 4), 82vw); }
  .plans-scroll {
    margin-inline: calc(var(--gutter) * -1);
    padding-inline: var(--gutter);
    scroll-snap-type: x mandatory;
  }
  .plan { scroll-snap-align: start; border: 1px solid var(--rule); border-radius: 4px; }
  .plan + .plan { margin-left: -1px; }
}

/* =============================================================
   La plataforma — recorrido por el panel real
   ============================================================= */
.plat-wrap { padding-bottom: clamp(56px, 7vw, 96px); }

.eyebrow {
  display: block;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.plat-head {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) auto;
  gap: clamp(20px, 3vw, 48px);
  align-items: end;
  padding-bottom: clamp(24px, 3vw, 36px);
  border-bottom: 1px solid var(--ink);
}
.plat-head h3 { font-size: clamp(22px, 2.8vw, 34px); max-width: 20ch; }
.plat-head > div > p { margin-top: 12px; font-size: 15px; color: var(--ink-2); max-width: 46ch; }
.plat-cta { display: flex; flex-wrap: wrap; gap: 10px; }

@media (max-width: 820px) {
  .plat-head { grid-template-columns: 1fr; align-items: start; }
}

/* ---------- Maqueta del panel ---------- */
.plat {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  background: var(--card);
  border: 1px solid var(--rule);
  border-top: 0;
  border-radius: 0 0 4px 4px;
  overflow: hidden;
}

/* Barra lateral, igual que la del panel de verdad */
.plat-side {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 20px 12px 18px;
  background: var(--paper-2);
  border-right: 1px solid var(--rule);
}

.plat-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px 16px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--rule);
}

.plat-group {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 14px 8px 6px;
}

.plat-item {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 9px 10px;
  background: transparent;
  border: 0;
  border-radius: 4px;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ink-2);
  text-align: left;
  cursor: pointer;
  transition: background .16s ease, color .16s ease;
}
.plat-item .si { font-size: 14px; line-height: 1; }
.plat-item:hover { background: color-mix(in srgb, var(--card) 70%, transparent); color: var(--ink); }
.plat-item.is-active {
  background: var(--accent);
  color: #fff;
  font-weight: 500;
}

.plat-more {
  margin-top: auto;
  padding: 16px 8px 0;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--ink-3);
  border-top: 1px solid var(--rule);
}

/* ---------- Vista ---------- */
.plat-view { padding: clamp(22px, 3vw, 34px); min-width: 0; }
.plat-panel[hidden] { display: none; }
.plat-panel.is-active { animation: fadeSwap .28s ease both; }

.plat-panel h4 {
  font-family: var(--disp);
  font-size: clamp(19px, 2.2vw, 26px);
  font-weight: 600;
  letter-spacing: -0.03em;
  margin: 0;
}
.plat-desc { margin-top: 8px; font-size: 15px; color: var(--ink-2); max-width: 52ch; }
.plat-note {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--rule-soft);
  font-size: 13px;
  color: var(--ink-3);
  max-width: 56ch;
}

/* KPIs */
.kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin-top: 22px;
  background: var(--rule);
  border: 1px solid var(--rule);
  border-radius: 3px;
  overflow: hidden;
}
.kpis > div { background: var(--card); padding: 16px 14px; }
.kpis b {
  display: block;
  font-family: var(--disp);
  font-size: clamp(20px, 2.4vw, 28px);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1;
}
.kpis span { display: block; margin-top: 7px; font-size: 12px; color: var(--ink-3); line-height: 1.35; }

/* Filas tipo tabla */
.rows { margin-top: 20px; border-top: 1px solid var(--rule); }
.rows li {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.3fr) auto;
  align-items: center;
  gap: 14px;
  padding: 13px 0;
  border-bottom: 1px solid var(--rule-soft);
}
.rows-plain li { grid-template-columns: 130px minmax(0, 1fr); }
.r-main { font-size: 14.5px; font-weight: 500; }
.r-sub  { font-size: 13.5px; color: var(--ink-2); }

.chip {
  justify-self: end;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 9px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  color: var(--ink-2);
  white-space: nowrap;
}
.chip-ok   { color: var(--mint);   border-color: color-mix(in srgb, var(--mint) 40%, transparent); }
.chip-warn { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 40%, transparent); }

/* Mini grafico de barras */
.mini-bars {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 110px;
  margin-top: 24px;
  padding-bottom: 2px;
  border-bottom: 1px solid var(--rule);
}
.mini-bars span {
  flex: 1;
  height: var(--h);
  background: color-mix(in srgb, var(--accent) 22%, transparent);
  border-top: 2px solid var(--accent);
  border-radius: 2px 2px 0 0;
}

/* Medidor de consumo */
.meter {
  height: 10px;
  margin-top: 24px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: 999px;
  overflow: hidden;
}
.meter span {
  display: block;
  width: var(--p);
  height: 100%;
  background: var(--accent);
}

.plat-foot {
  margin-top: 20px;
  font-size: 13.5px;
  color: var(--ink-3);
}
.plat-foot a { color: var(--accent); border-bottom: 1px solid currentColor; }

@media (max-width: 820px) {
  .plat { grid-template-columns: 1fr; }
  .plat-side {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    border-right: 0;
    border-bottom: 1px solid var(--rule);
    padding: 14px;
  }
  .plat-brand, .plat-group, .plat-more { display: none; }
  .plat-item { width: auto; padding: 8px 12px; font-size: 13px; }
}
@media (max-width: 620px) {
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .rows li { grid-template-columns: 1fr auto; gap: 6px 12px; }
  .rows .r-sub { grid-column: 1 / -1; }
  .rows-plain li { grid-template-columns: 1fr; }
}

/* ---------- Paquetes ---------- */
.packs {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.6fr);
  gap: clamp(28px, 4vw, 64px);
  margin-top: clamp(56px, 7vw, 96px);
  padding-top: clamp(32px, 4vw, 48px);
  border-top: 1px solid var(--ink);
}
.packs-copy h3 { font-size: clamp(20px, 2.3vw, 28px); margin-bottom: 14px; max-width: 16ch; }
.packs-copy p  { font-size: 15px; color: var(--ink-2); max-width: 38ch; }
.packs-copy b  { color: var(--ink); font-weight: 500; }

.packs-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}
.packs-list li {
  padding: 18px;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  transition: background .2s ease;
}
.packs-list li:hover { background: var(--card); }
.pk-qty {
  display: block;
  font-family: var(--disp);
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1;
}
.pk-lbl   { display: block; color: var(--ink-3); margin-top: 5px; }
.pk-price { display: block; margin-top: 14px; font-size: 15px; font-weight: 500; }
.pk-unit  { display: block; color: var(--mint); margin-top: 3px; letter-spacing: 0.06em; }

@media (max-width: 860px) { .packs { grid-template-columns: 1fr; } }

/* =============================================================
   Contacto
   ============================================================= */
.contact {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(32px, 5vw, 88px);
  align-items: start;
}
@media (max-width: 860px) { .contact { grid-template-columns: 1fr; } }

.contact-list { border-top: 1px solid var(--ink); }
.contact-list li {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 12px;
  align-items: baseline;
  padding: 18px 0;
  border-bottom: 1px solid var(--rule);
}
.cl-lbl { color: var(--ink-3); }
.contact-list a { border-bottom: 1px solid var(--rule); transition: border-color .16s ease; }
.contact-list a:hover { border-color: var(--accent); color: var(--accent); }
.contact-note { margin-top: 22px; font-size: 13.5px; color: var(--ink-3); max-width: 34ch; }

@media (max-width: 460px) {
  .contact-list li { grid-template-columns: 1fr; gap: 4px; }
}

/* ---------- Formulario ---------- */
.form { display: grid; gap: 22px; }
.field { display: grid; gap: 8px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
@media (max-width: 560px) { .field-row { grid-template-columns: 1fr; } }

.field label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.field label i { color: var(--accent); font-style: normal; }

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 2px;
  font-family: var(--sans);
  font-size: 16px;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--rule);
  border-radius: 0;
  transition: border-color .18s ease;
}
.field textarea { resize: vertical; min-height: 100px; line-height: 1.55; }
.field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%),
                    linear-gradient(135deg, var(--ink-2) 50%, transparent 50%);
  background-position: right 10px center, right 5px center;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 26px;
  cursor: pointer;
}
.field :is(input, select, textarea):focus {
  outline: none;
  border-bottom-color: var(--accent);
}
.field ::placeholder { color: var(--ink-3); }
.field :is(input, textarea):user-invalid { border-bottom-color: #c0392b; }

.form-note { font-size: 13.5px; min-height: 20px; }
.form-note.ok  { color: var(--mint); }
.form-note.err { color: #c0392b; }
.form-note a { color: var(--accent); border-bottom: 1px solid currentColor; }

/* =============================================================
   Pie
   ============================================================= */
.foot {
  border-top: 1px solid var(--ink);
  padding-block: clamp(44px, 5vw, 72px);
}
.foot-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) repeat(2, minmax(0, 1fr));
  gap: clamp(28px, 4vw, 56px);
}
.foot-brand { display: grid; gap: 8px; align-content: start; }
.foot-brand .brand-logo { height: 22px; margin-bottom: 4px; }
.foot-brand p { font-size: 14px; color: var(--ink-2); max-width: 30ch; }

.foot-nav { display: grid; gap: 10px; align-content: start; }
.foot-lbl { color: var(--ink-3); margin-bottom: 4px; }
.foot-nav a { font-size: 14.5px; color: var(--ink-2); transition: color .16s ease; }
.foot-nav a:hover { color: var(--accent); }

.foot-end {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding-top: 26px;
  margin-top: 12px;
  border-top: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--ink-3);
  text-transform: uppercase;
}

@media (max-width: 720px) {
  .foot-inner { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
}

/* =============================================================
   Entrada al hacer scroll — CSS puro (scroll-driven animations).
   Sin JS: si el navegador no lo soporta, el contenido ya es visible.
   ============================================================= */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .head, .specs, .feat, .step, .proj > *, .agente-intro > *,
    .plat-head, .plat, .plan, .packs > *, .contact > *, .hero-foot > * {
      animation: rise both linear;
      animation-timeline: view();
      animation-range: entry 0% cover 22%;
    }
  }
}
@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: none; }
}

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