/* ─────────────────────────────────────────────────────────────────────────────
   Hosanna — sitio público (HTML vanilla, sin build).

   La paleta y las fuentes son las mismas que las de la app: los tokens salen
   de app/constants/theme.ts (índigo profundo del look 2.0 + Open Sans / Prata).
   Si allá cambian, cambian acá a mano — no hay nada que los sincronice.

   El sitio va en oscuro fijo, no sigue al sistema: la app se ve así en su
   material de marca y una landing que cambia de piel según el visitante deja
   de parecerse a la app que está vendiendo.
   ───────────────────────────────────────────────────────────────────────── */

@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/OpenSans-Regular.ttf') format('truetype');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/OpenSans-Semibold.ttf') format('truetype');
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: 'Open Sans';
  src: url('../fonts/OpenSans-Bold.ttf') format('truetype');
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: 'Prata';
  src: url('../fonts/Prata-Regular.ttf') format('truetype');
  font-weight: 400;
  font-display: swap;
}

:root {
  --bg: #141226;
  --bg-soft: #1d1a38;
  --card: #242045;
  --border: #332e55;
  --separator: #3d3860;

  --text: #f5f3fb;
  --text-2: #a5a1c2;
  --text-3: #6e6a8e;

  --accent: #9d8cff;
  --purple: #9b4bfd;
  --purple-deep: #522f7e;
  --purple-light: #db74ec;

  --warn: #ff9f0a;

  --sans: 'Open Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --serif: 'Prata', Georgia, 'Times New Roman', serif;

  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 22px;
  --r-full: 9999px;

  --measure: 46rem; /* columna de lectura para las páginas de texto */
}

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

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration-color: color-mix(in srgb, var(--accent) 40%, transparent);
  text-underline-offset: 3px;
}
a:hover {
  text-decoration-color: var(--accent);
}

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

/* Salto al contenido: la barra superior es la misma en todas las páginas y
   con teclado es lo primero que se tabula una y otra vez. */
.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--card);
  color: var(--text);
  padding: 12px 18px;
  border-radius: 0 0 var(--r-md) 0;
  z-index: 100;
}
.skip:focus {
  left: 0;
}

.wrap {
  width: 100%;
  max-width: 68rem;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Barra superior ─────────────────────────────────────────────────────── */

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.topbar .wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-family: var(--serif);
  font-size: 1.3rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.01em;
}
.brand img {
  width: 34px;
  height: 34px;
  border-radius: 9px;
}

.topbar nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 26px;
  font-size: 0.95rem;
}
.topbar nav a {
  color: var(--text-2);
  text-decoration: none;
}
.topbar nav a:hover {
  color: var(--text);
}

@media (max-width: 640px) {
  .topbar nav {
    gap: 18px;
    font-size: 0.9rem;
  }
  .topbar nav .hide-sm {
    display: none;
  }
}

/* ── Hero ───────────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  overflow: hidden;
  padding: 84px 0 92px;
}

/* Dos resplandores en vez de un degradado lineal: la app usa glows radiales
   por detrás del contenido y un degradado plano se le nota lo plano. */
.hero::before,
.hero::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(90px);
  opacity: 0.5;
}
.hero::before {
  width: 640px;
  height: 640px;
  top: -280px;
  left: -160px;
  background: var(--purple-deep);
}
.hero::after {
  width: 520px;
  height: 520px;
  top: -120px;
  right: -140px;
  background: color-mix(in srgb, var(--purple) 55%, transparent);
}

.hero .wrap {
  position: relative;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
}

.hero h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.3rem, 5.2vw, 3.5rem);
  line-height: 1.14;
  margin: 0 0 20px;
  letter-spacing: -0.01em;
}

.hero .lede {
  font-size: 1.15rem;
  color: var(--text-2);
  margin: 0 0 32px;
  max-width: 34rem;
}

.hero-art {
  justify-self: center;
  width: min(340px, 100%);
  filter: drop-shadow(0 26px 50px rgba(20, 18, 38, 0.75));
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-14px);
  }
}

@media (max-width: 860px) {
  .hero {
    padding: 56px 0 64px;
  }
  .hero .wrap {
    grid-template-columns: 1fr;
    gap: 32px;
    text-align: center;
  }
  .hero .lede {
    margin-inline: auto;
  }
  .hero-art {
    order: -1;
    width: min(240px, 70%);
  }
}

/* ── Botones de tienda ──────────────────────────────────────────────────── */

.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
@media (max-width: 860px) {
  .stores {
    justify-content: center;
  }
}

.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 13px 22px 13px 18px;
  border-radius: var(--r-full);
  background: var(--text);
  color: #17142c;
  text-decoration: none;
  font-weight: 600;
  line-height: 1.15;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.35);
}
.store-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.45);
}
.store-btn svg {
  width: 24px;
  height: 24px;
  flex: none;
}
.store-btn small {
  display: block;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  opacity: 0.6;
}
.store-btn span {
  font-size: 1.02rem;
}

/* Sin link cargado el botón no lleva a ninguna parte: se muestra apagado y
   sin foco en vez de ofrecer una descarga que todavía no existe. */
.store-btn[data-pending] {
  background: transparent;
  color: var(--text-2);
  border: 1px dashed var(--separator);
  box-shadow: none;
  cursor: default;
  pointer-events: none;
}
.store-btn[data-pending]:hover {
  transform: none;
}

.stores-note {
  margin: 18px 0 0;
  font-size: 0.9rem;
  color: var(--text-3);
}

/* ── Secciones ──────────────────────────────────────────────────────────── */

section {
  padding: 76px 0;
}

.section-head {
  max-width: 40rem;
  margin: 0 0 44px;
}
.section-head.center {
  margin-inline: auto;
  text-align: center;
}

h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.75rem, 3.4vw, 2.35rem);
  line-height: 1.2;
  margin: 0 0 14px;
  letter-spacing: -0.005em;
}

.section-head p {
  color: var(--text-2);
  margin: 0;
  font-size: 1.05rem;
}

.eyebrow {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 14px;
}

/* ── Grilla de funciones ────────────────────────────────────────────────── */

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(258px, 1fr));
  gap: 18px;
}

.feature {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 28px 26px;
}

.feature .ico {
  width: 46px;
  height: 46px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  background: linear-gradient(140deg, var(--purple), var(--purple-deep));
}
.feature .ico svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: #fff;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feature h3 {
  font-size: 1.12rem;
  font-weight: 700;
  margin: 0 0 8px;
}

.feature p {
  margin: 0;
  color: var(--text-2);
  font-size: 0.98rem;
  line-height: 1.6;
}

/* ── Bloque de planes ───────────────────────────────────────────────────── */

.plans {
  background: var(--bg-soft);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.plan-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  overflow: hidden;
}

.plan-table th,
.plan-table td {
  padding: 15px 20px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  font-size: 0.97rem;
}
.plan-table tr:last-child th,
.plan-table tr:last-child td {
  border-bottom: 0;
}
.plan-table thead th {
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-3);
  font-weight: 700;
}
.plan-table thead th:last-child {
  color: var(--accent);
}
.plan-table tbody th {
  font-weight: 600;
  color: var(--text);
}
.plan-table td {
  color: var(--text-2);
}
.plan-table td:last-child {
  color: var(--text);
  font-weight: 600;
}

.plan-note {
  margin: 20px 0 0;
  color: var(--text-3);
  font-size: 0.92rem;
  max-width: var(--measure);
}

/* La comparativa es de tres columnas angostas: apilarla no sirve, se deja
   deslizar en horizontal y el body nunca scrollea de costado. */
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* ── Cierre / CTA final ─────────────────────────────────────────────────── */

.closing {
  text-align: center;
  position: relative;
  overflow: hidden;
}
.closing::before {
  content: '';
  position: absolute;
  inset: auto 50% -320px;
  width: 700px;
  height: 520px;
  transform: translateX(50%);
  background: var(--purple-deep);
  filter: blur(100px);
  opacity: 0.45;
  border-radius: 50%;
  pointer-events: none;
}
.closing .wrap {
  position: relative;
}
.closing .stores {
  justify-content: center;
  margin-top: 30px;
}
.closing img {
  width: 132px;
  margin: 0 auto 26px;
}

/* ── Páginas de texto (privacidad, términos, soporte, borrado) ──────────── */

.doc {
  padding: 60px 0 88px;
}
.doc .wrap {
  max-width: calc(var(--measure) + 48px);
}

.doc h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2rem, 4.4vw, 2.7rem);
  line-height: 1.18;
  margin: 0 0 10px;
}

.doc .updated {
  color: var(--text-3);
  font-size: 0.9rem;
  margin: 0 0 44px;
}

.doc h2 {
  font-family: var(--sans);
  font-size: 1.28rem;
  font-weight: 700;
  margin: 46px 0 14px;
  padding-top: 26px;
  border-top: 1px solid var(--border);
  letter-spacing: 0;
}
.doc h2:first-of-type {
  border-top: 0;
  padding-top: 0;
  margin-top: 36px;
}

.doc h3 {
  font-size: 1.04rem;
  font-weight: 700;
  margin: 30px 0 10px;
}

.doc p,
.doc li {
  color: var(--text-2);
}
.doc p {
  margin: 0 0 18px;
}
.doc ul,
.doc ol {
  margin: 0 0 18px;
  padding-left: 22px;
}
.doc li {
  margin-bottom: 9px;
}
.doc li::marker {
  color: var(--text-3);
}
.doc strong {
  color: var(--text);
  font-weight: 600;
}

.doc .toc {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 22px 26px;
  margin-bottom: 44px;
}
.doc .toc p {
  margin: 0 0 10px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-3);
}
.doc .toc ol {
  margin: 0;
  columns: 2;
  column-gap: 32px;
  font-size: 0.95rem;
}
@media (max-width: 620px) {
  .doc .toc ol {
    columns: 1;
  }
}

.doc table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 22px;
  font-size: 0.95rem;
}
.doc table th,
.doc table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
  color: var(--text-2);
}
.doc table th {
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
}
.doc table thead th {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}

/* Aviso destacado dentro de un documento (ej: cómo borrar la cuenta). */
.callout {
  background: var(--card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--r-md);
  padding: 20px 24px;
  margin: 0 0 26px;
}
.callout p:last-child {
  margin-bottom: 0;
}
.callout h3 {
  margin-top: 0;
}

/* Dato que falta completar antes de publicar. Se ve fuerte a propósito: un
   marcador discreto se publica sin que nadie lo note. */
.todo {
  background: color-mix(in srgb, var(--warn) 18%, transparent);
  border: 1px dashed var(--warn);
  border-radius: 5px;
  padding: 1px 7px;
  color: var(--warn);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.87em;
  white-space: nowrap;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 0 0 22px;
}
.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 44px;
  margin-bottom: 16px;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 1px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(140deg, var(--purple), var(--purple-deep));
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
}

/* ── Pie ────────────────────────────────────────────────────────────────── */

footer {
  border-top: 1px solid var(--border);
  padding: 46px 0 56px;
  background: var(--bg-soft);
}

.foot-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 28px 48px;
  align-items: flex-start;
}

.foot-brand {
  max-width: 20rem;
}
.foot-brand p {
  color: var(--text-3);
  font-size: 0.9rem;
  margin: 14px 0 0;
}

.foot-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 30px;
  margin-left: auto;
  font-size: 0.95rem;
}
.foot-links a {
  color: var(--text-2);
  text-decoration: none;
}
.foot-links a:hover {
  color: var(--text);
}

.foot-legal {
  margin: 38px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  color: var(--text-3);
  font-size: 0.86rem;
}
.foot-legal p {
  margin: 0 0 6px;
}
