/* ============================================================
   Portada pública (/) — estilo «Luz» de la casa, en azul y turquesa.
   Base: repos/ventas/css/lux.css. Sólo la usa index.html; las pantallas
   de la app siguen con app.css.
   ============================================================ */

:root {
  --azul: #2563eb;
  --azul-fuerte: #1d4ed8;
  --turquesa: #14b8a6;
  --tinta: #0f172a;
  --tinta-suave: #475569;
  --linea: #dbe4f0;

  --vidrio: rgba(255, 255, 255, .72);
  --vidrio-fuerte: rgba(255, 255, 255, .88);
  --vidrio-borde: rgba(255, 255, 255, .8);

  /* Sombras teñidas de azul tinta, nunca grises */
  --sombra-1: 0 2px 8px rgba(15, 35, 90, .06);
  --sombra-2: 0 12px 30px rgba(15, 35, 90, .11);
  --sombra-3: 0 28px 70px rgba(15, 35, 90, .20);
  --brillo: 0 10px 30px rgba(37, 99, 235, .34);

  --r-sm: 12px;
  --r-md: 18px;
  --r-lg: 26px;
  --r-xl: 34px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; }
body {
  font: 16px/1.55 "Plus Jakarta Sans", ui-sans-serif, system-ui, "Segoe UI", sans-serif;
  letter-spacing: -.011em;
  color: var(--tinta);
  background: #f6f9fe;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { letter-spacing: -.03em; font-weight: 800; margin: 0; }
p { margin: 0; }
[id] { scroll-margin-top: 96px; }

/* Con sesión guardada esperamos a confirmarla antes de pintar la portada
   (si no, se ve un parpadeo antes de mandarla a /inicio). La clase la pone
   un script de una línea y portada.js la quita; además se quita sola a los 2 s. */
html.comprobando body { visibility: hidden; }

/* ---------- Fondo: luz ambiental + grano ---------- */
.luz {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(900px 620px at 88% -6%, rgba(253, 230, 190, .55), transparent 62%),
    radial-gradient(760px 560px at 6% -4%, rgba(191, 219, 254, .70), transparent 60%),
    radial-gradient(1100px 700px at 50% 108%, rgba(153, 246, 228, .45), transparent 62%),
    #f6f9fe;
}
.luz::after {
  content: ""; position: absolute; inset: 0; opacity: .35; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='.055'/%3E%3C/svg%3E");
}

.ancho { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }

/* ---------- Barra superior de vidrio ---------- */
.barra {
  position: sticky; top: 14px; z-index: 20;
  display: flex; align-items: center; gap: 12px;
  margin-top: 14px; padding: 8px 8px 8px 14px;
  border: 1px solid var(--vidrio-borde); border-radius: 999px;
  background: var(--vidrio);
  backdrop-filter: blur(20px) saturate(150%); -webkit-backdrop-filter: blur(20px) saturate(150%);
  box-shadow: var(--sombra-2);
}
.marca { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 17px; letter-spacing: -.02em; }
.marca img { width: 34px; height: 34px; border-radius: 10px; box-shadow: var(--brillo); }
.barra nav { display: flex; gap: 4px; margin-left: auto; }
.barra nav a { text-decoration: none; color: var(--tinta-suave); font-weight: 600; font-size: 15px; padding: 8px 12px; border-radius: 999px; }
.barra nav a:hover { color: var(--tinta); background: rgba(255, 255, 255, .7); }
.barra .acciones { display: flex; gap: 8px; }

/* ---------- Botones en pastilla ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid transparent; border-radius: 999px; padding: 13px 22px;
  font: inherit; font-weight: 700; letter-spacing: -.01em; text-decoration: none; cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.btn-primario { color: #fff; background: linear-gradient(145deg, var(--azul), var(--azul-fuerte)); box-shadow: var(--brillo); }
.btn-primario:hover { transform: translateY(-2px); box-shadow: 0 16px 38px rgba(37, 99, 235, .42); }
.btn-vidrio { color: var(--tinta); background: var(--vidrio-fuerte); border-color: var(--vidrio-borde); box-shadow: var(--sombra-1); }
.btn-vidrio:hover { background: #fff; }
.btn-claro { color: var(--azul-fuerte); background: #fff; box-shadow: var(--sombra-2); }
.btn-claro:hover { transform: translateY(-2px); }
.btn-chico { padding: 9px 16px; font-size: 15px; }

/* ---------- Héroe ---------- */
.heroe {
  position: relative; isolation: isolate; overflow: hidden;
  margin-top: 22px; border-radius: var(--r-xl);
  padding: clamp(28px, 5vw, 64px) clamp(22px, 5vw, 64px) clamp(110px, 12vw, 140px);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(24px, 4vw, 56px); align-items: center;
  color: #fff;
  background: linear-gradient(140deg, #0b1a4a 0%, #1d4ed8 48%, #0ea5b7 100%);
  box-shadow: var(--sombra-3);
}
/* Brillos suaves dentro del héroe */
.heroe::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(600px 400px at 85% 10%, rgba(45, 212, 191, .35), transparent 65%),
    radial-gradient(500px 380px at 0% 100%, rgba(96, 165, 250, .35), transparent 65%);
}
.antetitulo {
  display: inline-block; margin-bottom: 14px; font-size: 12px; font-weight: 800;
  letter-spacing: .14em; text-transform: uppercase; color: var(--azul);
}
.heroe .antetitulo { color: #99f6e4; }
.heroe h1 { font-size: clamp(38px, 5.6vw, 70px); line-height: .98; letter-spacing: -.035em; }
.heroe h1 em { font-style: normal; background: linear-gradient(90deg, #99f6e4, #bfdbfe); -webkit-background-clip: text; background-clip: text; color: transparent; }
.heroe .bajada { margin-top: 18px; font-size: clamp(17px, 1.6vw, 20px); color: rgba(255, 255, 255, .86); max-width: 40ch; }
.heroe .botones { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.heroe .nota { margin-top: 14px; font-size: 14px; color: rgba(255, 255, 255, .7); }
.heroe .nota a { color: #fff; font-weight: 700; }

/* Escena: la PC proyectando y la tableta escribiendo, una sobre otra */
.escena { position: relative; }
.escena .pc {
  border-radius: 16px; overflow: hidden; border: 6px solid #0b1430;
  box-shadow: 0 30px 60px rgba(3, 10, 40, .45);
  transform: perspective(1400px) rotateY(-8deg) rotateX(3deg);
}
.escena .tableta {
  position: absolute; width: 46%; left: -8%; bottom: -14%;
  border-radius: 18px; overflow: hidden; border: 7px solid #111827;
  box-shadow: 0 24px 50px rgba(3, 10, 40, .5);
}
.escena .chip-vivo {
  position: absolute; right: 4%; top: -14px; z-index: 2;
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px;
  border-radius: 999px; background: var(--vidrio-fuerte); color: var(--tinta);
  font-size: 13px; font-weight: 700; box-shadow: var(--sombra-2);
}
.punto { width: 9px; height: 9px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 4px rgba(22, 163, 74, .18); }

/* ---------- «¿Te pasaron un código?» — vidrio montado sobre el borde del héroe ---------- */
.codigo-flotante {
  position: relative; z-index: 2;
  width: min(760px, calc(100% - 32px)); margin: -70px auto 0;
  padding: 18px 18px 16px; border-radius: var(--r-lg);
  border: 1px solid var(--vidrio-borde); background: var(--vidrio-fuerte);
  backdrop-filter: blur(20px) saturate(150%); -webkit-backdrop-filter: blur(20px) saturate(150%);
  box-shadow: var(--sombra-3);
}
.codigo-flotante h2 { font-size: 18px; letter-spacing: -.02em; }
.codigo-flotante p { color: var(--tinta-suave); font-size: 14px; margin-top: 4px; }
.codigo-flotante form { display: flex; gap: 8px; margin-top: 12px; }
.codigo-flotante input {
  flex: 1; min-width: 0; font: inherit; font-size: 16px; padding: 12px 18px;
  border-radius: 999px; border: 1px solid var(--linea); background: #fff; color: var(--tinta);
}
.codigo-flotante input:focus { outline: 2px solid var(--azul); outline-offset: 0; border-color: var(--azul); }

/* ---------- Secciones ---------- */
.seccion { padding: clamp(56px, 8vw, 96px) 0 0; }
.cabeza { max-width: 680px; margin-bottom: 30px; }
.cabeza.centro { margin-inline: auto; text-align: center; }
.cabeza h2 { font-size: clamp(28px, 3.6vw, 42px); line-height: 1.05; }
.cabeza p { margin-top: 12px; font-size: 17px; color: var(--tinta-suave); }

/* Herramienta: texto y capturas lado a lado, alternando */
.herramienta {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: clamp(24px, 4vw, 56px); align-items: center;
  padding: clamp(22px, 3vw, 36px); margin-bottom: 22px;
  border-radius: var(--r-xl); border: 1px solid var(--vidrio-borde);
  background: var(--vidrio); box-shadow: var(--sombra-2);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.herramienta.invertida .texto { order: 2; }
.herramienta h3 { font-size: clamp(24px, 2.6vw, 32px); line-height: 1.1; }
.herramienta .texto > p { margin-top: 12px; color: var(--tinta-suave); font-size: 17px; }
.etiqueta {
  display: inline-flex; align-items: center; gap: 6px; margin-bottom: 12px;
  padding: 5px 12px; border-radius: 999px; font-size: 13px; font-weight: 800;
}
.etiqueta.gratis { background: #dcfce7; color: #166534; }
.etiqueta.plan { background: #dbeafe; color: #1e40af; }
.puntos { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 10px; }
.puntos li { position: relative; padding-left: 30px; }
.puntos li::before {
  content: ""; position: absolute; left: 0; top: 3px; width: 20px; height: 20px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='10' r='10' fill='%232563eb'/%3E%3Cpath d='M6 10.5l2.6 2.5L14 7.5' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* Capturas: dos pantallas encimadas (la grande y la del celular/tableta) */
.capturas { position: relative; padding-bottom: 8%; }
.capturas .grande {
  border-radius: 16px; overflow: hidden; border: 1px solid rgba(15, 23, 42, .08);
  box-shadow: var(--sombra-3);
}
.capturas .chica {
  position: absolute; right: -2%; bottom: 0; width: 34%;
  border-radius: 18px; overflow: hidden; border: 6px solid #111827;
  box-shadow: 0 24px 50px rgba(15, 35, 90, .35);
}
.capturas .chica.cel { width: 24%; border-radius: 24px; }
.capturas .grande img, .capturas .chica img { width: 100%; }

/* ---------- Pasos ---------- */
.pasos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.paso {
  padding: 26px; border-radius: var(--r-lg); background: var(--vidrio-fuerte);
  border: 1px solid var(--vidrio-borde); box-shadow: var(--sombra-2);
}
.paso .num {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; margin-bottom: 14px;
  color: #fff; font-weight: 800; font-size: 18px;
  background: linear-gradient(145deg, var(--azul), var(--turquesa)); box-shadow: var(--brillo);
}
.paso h3 { font-size: 20px; }
.paso p { margin-top: 8px; color: var(--tinta-suave); }

/* ---------- Precios ---------- */
.precios { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
.precio {
  display: flex; flex-direction: column; gap: 10px;
  padding: 24px; border-radius: var(--r-lg); background: var(--vidrio-fuerte);
  border: 1px solid var(--vidrio-borde); box-shadow: var(--sombra-2);
}
.precio.destacado { background: linear-gradient(160deg, #1d4ed8, #0e7490); color: #fff; box-shadow: var(--sombra-3); }
.precio h3 { font-size: 20px; }
.precio .monto { font-size: 38px; font-weight: 800; letter-spacing: -.04em; line-height: 1; }
.precio .monto small { font-size: 15px; font-weight: 600; letter-spacing: 0; opacity: .7; }
.precio .desc { color: var(--tinta-suave); font-size: 15px; }
.precio.destacado .desc { color: rgba(255, 255, 255, .82); }
.precio ul { list-style: none; padding: 0; margin: 4px 0 8px; display: grid; gap: 6px; font-size: 15px; }
.precio li::before { content: "✓  "; font-weight: 800; color: var(--turquesa); }
.precio.destacado li::before { color: #99f6e4; }
.precio .btn { margin-top: auto; }
.precio .insignia {
  align-self: flex-start; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 800;
  background: rgba(255, 255, 255, .18); color: #fff;
}
.aclaracion { margin-top: 16px; text-align: center; color: var(--tinta-suave); font-size: 14px; }

/* ---------- Cierre ---------- */
.cierre {
  margin-top: clamp(56px, 8vw, 96px); padding: clamp(36px, 6vw, 64px);
  border-radius: var(--r-xl); text-align: center; color: #fff;
  background: linear-gradient(140deg, #0b1a4a, #1d4ed8 55%, #0ea5b7);
  box-shadow: var(--sombra-3);
}
.cierre h2 { font-size: clamp(28px, 4vw, 46px); line-height: 1.05; }
.cierre p { margin: 14px auto 0; max-width: 46ch; color: rgba(255, 255, 255, .85); font-size: 17px; }
.cierre .botones { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 24px; }

.pie { padding: 36px 0 120px; text-align: center; color: var(--tinta-suave); font-size: 14px; }
.pie a { color: var(--tinta-suave); }

/* ---------- Barra fija del celular ---------- */
.barra-cel { display: none; }

/* ---------- Entrada suave al bajar (la pone el JS; si falla, todo se ve) ---------- */
.js-revelar .revelar { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.js-revelar .revelar.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js-revelar .revelar { opacity: 1; transform: none; transition: none; }
  .btn:hover { transform: none; }
}

/* ---------- Tableta ---------- */
@media (max-width: 960px) {
  .barra nav { display: none; }
  .barra .acciones { margin-left: auto; }
  .heroe { grid-template-columns: 1fr; }
  .escena { margin: 10px 4% 30px 12%; }
  .herramienta, .herramienta.invertida { grid-template-columns: 1fr; }
  .herramienta.invertida .texto { order: 0; }
  .precios { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Celular ---------- */
@media (max-width: 640px) {
  .barra { padding-left: 10px; }
  .barra .acciones .btn-primario { display: none; }   /* va en la barra fija de abajo */
  .heroe { padding-bottom: 100px; border-radius: var(--r-lg); }
  .heroe .botones .btn { flex: 1; }
  .heroe .botones .btn-claro { display: none; }        /* un solo botón principal: el de abajo */
  .escena { margin: 6px 0 24px 14%; }
  .escena .chip-vivo { top: -12px; font-size: 12px; }
  .codigo-flotante form { flex-direction: column; }
  .pasos { grid-template-columns: 1fr; }
  .precios { grid-template-columns: 1fr; }
  .capturas .chica { width: 38%; }
  .capturas .chica.cel { width: 30%; }
  .barra-cel {
    display: flex; gap: 8px; position: fixed; z-index: 30; left: 12px; right: 12px; bottom: 12px;
    padding: 8px; border-radius: 999px; border: 1px solid var(--vidrio-borde);
    background: var(--vidrio-fuerte); backdrop-filter: blur(20px) saturate(150%); -webkit-backdrop-filter: blur(20px) saturate(150%);
    box-shadow: var(--sombra-3);
  }
  .barra-cel .btn { flex: 1; padding: 12px 14px; }
}
