/* OpoMaster, landing. Mismos tokens que la app ("expediente premium").
   Sistema de radios: tarjetas y paneles 22px; botones, campos y FAQ 16px;
   chips y etiquetas 10px. El marco del teléfono (44/34) es la única excepción. */

@font-face {
  font-family: 'Inter Variable';
  src: url('fonts/inter-latin-wght-normal.woff2') format('woff2-variations');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'Inter Tight Variable';
  src: url('fonts/inter-tight-latin-wght-normal.woff2') format('woff2-variations');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --papel: #F6F4EE;
  --superficie: #FFFFFF;
  --mate: #FBFAF6;
  --linea: #E3DED3;
  --tinta: #171A18;
  --tinta-suave: #5F655F;
  --tinta-tenue: #676D67; /* AA 4.5:1 sobre --papel incluso en 12px */
  --verde: #2F6B3F;
  --verde-oscuro: #1F3F2B;
  --verde-suave: #E6F1DE;
  --carbon: #181A1B;
  --carbon-texto: #B2B8B0;
  --granate: #7A2637;
  --oro: #B89B5E;
  --sombra: 0 1px 2px rgba(20, 22, 20, 0.03), 0 8px 22px -14px rgba(20, 22, 20, 0.10);
  --sombra-alta: 0 1px 3px rgba(20, 22, 20, 0.05), 0 14px 30px -16px rgba(20, 22, 20, 0.16);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--papel);
  color: var(--tinta);
  font: 400 17px/26px 'Inter Variable', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .cifra { font-family: 'Inter Tight Variable', 'Inter Variable', system-ui, sans-serif; }

.contenedor { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

.eyebrow {
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--tinta-tenue);
}

/* ─── Navegación ─── */
nav {
  position: sticky; top: 0; z-index: 10;
  background: rgba(246, 244, 238, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--linea);
}
nav .contenedor { display: flex; align-items: center; gap: 28px; height: 68px; }
.marca { display: flex; align-items: center; gap: 10px; font-family: 'Inter Tight Variable', sans-serif; font-size: 20px; font-weight: 700; color: var(--tinta); text-decoration: none; }
.marca img { width: 34px; height: 34px; }
.marca b { color: var(--verde); font-weight: 700; }
nav .enlaces { display: flex; gap: 22px; margin-left: auto; }
nav .enlaces a { font-size: 15px; font-weight: 550; color: var(--tinta-suave); text-decoration: none; }
nav .enlaces a:hover { color: var(--tinta); }

/* ─── Botones ─── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: 16px; padding: 17px 26px;
  font-family: 'Inter Tight Variable', sans-serif; font-size: 16px; font-weight: 650; line-height: 20px;
  text-decoration: none; transition: background 0.12s, border-color 0.12s;
}
.btn-primario { background: var(--verde); color: #fff; }
.btn-primario:hover { background: #2A5F38; }
.btn-secundario { background: var(--superficie); color: var(--tinta); border: 1px solid var(--linea); }
.btn-secundario:hover { border-color: var(--tinta-tenue); }
.btn-compacto { padding: 11px 20px; font-size: 15px; }
.btn:active { transform: translateY(1px); }
.btn:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--oro);
  outline-offset: 2px;
  border-radius: 6px;
}
.btn:focus-visible { border-radius: 16px; }

/* ─── Héroe ─── */
.heroe { padding: 72px 0 40px; }
.heroe .contenedor { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 56px; align-items: center; }
h1 { margin: 14px 0 0; font-size: 52px; line-height: 56px; font-weight: 700; letter-spacing: -0.015em; }
h1 em { font-style: normal; color: var(--verde); }
.heroe p.sub { margin: 20px 0 0; max-width: 30em; font-size: 19px; line-height: 30px; color: var(--tinta-suave); }
.heroe .acciones { margin-top: 30px; display: flex; flex-wrap: wrap; gap: 12px; }

/* Teléfono */
.telefono {
  width: 320px; margin: 0 auto; border-radius: 44px; padding: 12px;
  background: var(--carbon); box-shadow: var(--sombra-alta);
}
.telefono img { display: block; width: 100%; border-radius: 34px; }

/* ─── Franja de confianza ─── */
.franja { border-top: 1px solid var(--linea); border-bottom: 1px solid var(--linea); background: var(--mate); }
.franja .contenedor { display: flex; flex-wrap: wrap; gap: 10px 26px; padding: 16px 24px; justify-content: center; }
.franja span { font-size: 13px; font-weight: 600; color: var(--tinta-suave); }
.franja span::before { content: '✓ '; color: var(--verde); }

/* ─── Secciones ─── */
section { padding: 76px 0 0; }
.cabecera-seccion h2 { margin: 10px 0 0; font-size: 34px; line-height: 38px; font-weight: 700; letter-spacing: -0.01em; }
.cabecera-seccion p { margin: 12px 0 0; max-width: 36em; color: var(--tinta-suave); }

/* Método: rail vertical de pasos (sin tarjetas; hairlines y espacio) */
.pasos { list-style: none; margin: 40px 0 0; padding: 0; max-width: 760px; }
.paso { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 22px; padding: 28px 0; }
.paso + .paso { border-top: 1px solid var(--linea); }
.paso .numero { display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 10px; background: var(--verde-suave); color: var(--verde-oscuro); font-family: 'Inter Tight Variable', sans-serif; font-size: 18px; font-weight: 700; }
.paso h3 { margin: 7px 0 0; font-size: 20px; font-weight: 650; }
.paso p { margin: 8px 0 0; font-size: 15px; line-height: 24px; color: var(--tinta-suave); }

/* Qué incluye: bento con ritmo (2 anchas / 3 medianas / 1 completa) */
.rejilla { display: grid; grid-template-columns: repeat(6, 1fr); gap: 18px; margin-top: 36px; }
.celda { grid-column: span 2; background: var(--superficie); border: 1px solid var(--linea); border-radius: 22px; padding: 24px; }
.celda:nth-child(-n + 2) { grid-column: span 3; }
.celda h3 { margin: 0; font-size: 16px; font-weight: 650; }
.celda p { margin: 7px 0 0; font-size: 14px; line-height: 22px; color: var(--tinta-suave); }
.celda-verde { background: var(--verde-suave); border-color: #D3E4C6; }
.celda-verde h3 { color: var(--verde-oscuro); }
.celda-ancha {
  grid-column: 1 / -1;
  background: var(--mate);
  background-image: radial-gradient(var(--linea) 1px, transparent 1px);
  background-size: 22px 22px;
  padding: 30px;
}
.celda-ancha h3 { font-size: 19px; }
.celda-ancha p { max-width: 52em; font-size: 15px; line-height: 24px; }

/* Panel carbón */
.panel-carbon {
  margin-top: 76px; background: var(--carbon); border-radius: 22px; color: #fff;
  padding: 44px; display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 44px; align-items: center;
  box-shadow: var(--sombra-alta);
}
.panel-carbon .eyebrow { color: var(--carbon-texto); }
.panel-carbon h2 { margin: 12px 0 0; font-size: 30px; line-height: 36px; font-weight: 700; letter-spacing: -0.01em; }
.panel-carbon p { margin: 14px 0 0; color: var(--carbon-texto); }
.panel-carbon .filas { background: rgba(255, 255, 255, 0.04); border: 1px solid rgba(255, 255, 255, 0.09); border-radius: 18px; padding: 20px 22px; }
.panel-carbon .fila { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; font-size: 14px; color: var(--carbon-texto); }
.panel-carbon .fila + .fila { border-top: 1px solid rgba(255, 255, 255, 0.08); }
.panel-carbon .fila b { color: #fff; font-weight: 650; white-space: nowrap; }
.panel-carbon .fila b.alerta { color: #BC8090; }

/* ─── Precios ─── */
.precios { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 36px; align-items: stretch; }
.precio { background: var(--superficie); border: 1px solid var(--linea); border-radius: 22px; padding: 28px; display: flex; flex-direction: column; box-shadow: var(--sombra); }
.precio.destacado { border: 2px solid var(--verde); position: relative; }
.precio .etiqueta { position: absolute; top: -13px; left: 24px; background: var(--verde); color: #fff; font-size: 12px; font-weight: 650; letter-spacing: 0.05em; text-transform: uppercase; border-radius: 10px; padding: 4px 10px; }
.precio h3 { margin: 0; font-size: 17px; font-weight: 650; }
.precio .cifra { margin: 14px 0 0; font-size: 44px; line-height: 1; font-weight: 750; letter-spacing: -0.01em; font-variant-numeric: tabular-nums; }
.precio .cifra small { font-size: 15px; font-weight: 550; color: var(--tinta-tenue); letter-spacing: 0; white-space: nowrap; }
.precio .detalle { margin: 10px 0 18px; font-size: 14px; line-height: 22px; color: var(--tinta-suave); }
.precio ul { margin: 0 0 24px; padding: 0; list-style: none; }
.precio li { font-size: 14px; line-height: 26px; color: var(--tinta-suave); }
.precio li::before { content: '✓'; margin-right: 9px; color: var(--verde); font-weight: 650; }
.precio .btn { margin-top: auto; }
.nota-gratis { margin-top: 22px; text-align: center; font-size: 14px; color: var(--tinta-suave); }
.nota-gratis a { color: var(--verde); font-weight: 600; }

/* ─── FAQ ─── */
.faq { max-width: 720px; margin: 36px auto 0; }
details { background: var(--superficie); border: 1px solid var(--linea); border-radius: 16px; padding: 4px 22px; margin-bottom: 10px; }
summary { cursor: pointer; padding: 16px 0; font-family: 'Inter Tight Variable', sans-serif; font-size: 16px; font-weight: 650; list-style: none; display: flex; justify-content: space-between; align-items: center; }
summary::after { content: '+'; font-size: 22px; font-weight: 400; color: var(--tinta-tenue); }
details[open] summary::after { content: '−'; }
details p { margin: 0 0 18px; font-size: 15px; line-height: 25px; color: var(--tinta-suave); }

/* ─── Cierre y pie ─── */
.cierre { margin: 76px 0 0; background: var(--verde-oscuro); border-radius: 22px; color: #fff; text-align: center; padding: 60px 32px; }
.cierre h2 { margin: 0; font-size: 34px; line-height: 40px; font-weight: 700; letter-spacing: -0.01em; }
.cierre p { margin: 14px auto 0; max-width: 34em; color: rgba(255, 255, 255, 0.75); }
.cierre .btn-primario { margin-top: 28px; background: #fff; color: var(--verde-oscuro); }
.cierre .btn-primario:hover { background: var(--verde-suave); }

footer { margin-top: 76px; border-top: 1px solid var(--linea); padding: 30px 0 44px; }
footer .contenedor { display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: center; font-size: 13px; color: var(--tinta-tenue); }
footer a { color: var(--tinta-suave); text-decoration: none; font-weight: 550; }
footer a:hover { color: var(--tinta); }
footer .marca { font-size: 16px; }
footer .marca img { width: 26px; height: 26px; }
footer .derechos { margin-left: auto; }

/* ─── Páginas legales ─── */
.legal { max-width: 720px; margin: 0 auto; padding: 64px 24px; }
.legal h1 { font-size: 34px; line-height: 38px; }
.legal h2 { margin-top: 40px; font-size: 22px; line-height: 28px; font-weight: 650; }
.legal p, .legal li { font-size: 16px; line-height: 26px; color: var(--tinta-suave); }
.legal .fecha { font-size: 13px; color: var(--tinta-tenue); }

/* ─── Motion (solo si el sistema no pide movimiento reducido) ─── */
@media (prefers-reduced-motion: no-preference) {
  /* Entrada del héroe al cargar: jerarquía, de arriba abajo */
  .heroe .eyebrow, .heroe h1, .heroe .sub, .heroe .acciones, .telefono {
    animation: entrada 0.7s cubic-bezier(0.16, 1, 0.3, 1) backwards;
  }
  .heroe h1 { animation-delay: 0.06s; }
  .heroe .sub { animation-delay: 0.12s; }
  .heroe .acciones { animation-delay: 0.18s; }
  .telefono { animation-delay: 0.15s; }
  @keyframes entrada {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: none; }
  }

  /* Revelado al hacer scroll: la clase .con-motion la añade el script
     (así sin JavaScript el contenido nunca queda oculto) */
  .con-motion .revelar { opacity: 0; transform: translateY(18px); transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
  .con-motion .revelar.visible { opacity: 1; transform: none; }
}

/* ─── Móvil ─── */
@media (max-width: 900px) {
  nav .enlaces { display: none; }
  .heroe { padding-top: 44px; }
  .heroe .contenedor { grid-template-columns: 1fr; gap: 44px; }
  h1 { font-size: 38px; line-height: 42px; }
  .rejilla, .precios { grid-template-columns: 1fr; }
  .celda, .celda:nth-child(-n + 2), .celda-ancha { grid-column: auto; }
  .panel-carbon { grid-template-columns: 1fr; padding: 30px 24px; }
  .precio.destacado { order: -1; }
  section { padding-top: 56px; }
}
