/* Piezas vivas: "Para cualquier negocio" (pestañas con un presupuesto de ejemplo) y la mini-demo de "La IA propone. Tú decides." */

/* ── Negocios ── */
.js .oficios { display: none; }
.neg { margin-top: 40px; --acento: #cba51e; }
.neg-tabs { display: flex; gap: 8px; overflow-x: auto; padding: 4px 2px 10px; scrollbar-width: none; }
.neg-tabs::-webkit-scrollbar { display: none; }
.neg-tab {
  flex: none; font: inherit; font-size: 0.95rem; padding: 10px 16px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--linea); background: #fff; color: var(--texto); transition: background .3s, color .3s, border-color .3s;
}
.neg-tab[aria-selected="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.neg-otro { margin-top: 14px; color: var(--suave); font-size: 0.95rem; }
.neg-papel {
  margin-top: 8px; background: #fff; border: 1px solid #e7e2d7; border-radius: 16px; overflow: hidden; max-width: 640px;
  box-shadow: 0 30px 60px -36px rgb(40 30 5 / 0.45);
}
.neg-cab { background: var(--acento); color: #fff; padding: 16px 20px; display: flex; justify-content: space-between; gap: 12px; align-items: baseline; transition: background .6s var(--ease); }
.neg-cab b { font-family: var(--display); font-weight: 400; font-size: 1.25rem; letter-spacing: .02em; }
.neg-cab span { font-size: .85rem; opacity: .9; }
.neg-cuerpo { padding: 6px 20px 4px; }
.neg-fila { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; border-bottom: 1px solid #eee9de; font-size: .98rem; animation: neg-entra .5s var(--ease) both; animation-delay: calc(var(--i) * 90ms); }
.neg-fila small { color: var(--suave); }
.neg-fila span:last-child { font-variant-numeric: tabular-nums; white-space: nowrap; }
.neg-total { display: flex; justify-content: space-between; padding: 14px 20px 18px; font-weight: 600; }
.neg-total b { color: var(--acento); font-size: 1.2rem; transition: color .6s; font-variant-numeric: tabular-nums; }
@keyframes neg-entra { from { opacity: 0; translate: 0 8px; } }
@media (prefers-reduced-motion: reduce) { .neg-fila { animation: none; } }

/* ── Mini-demo del precio ── */
.demo-precio {
  margin: 28px 0 8px; max-width: 640px; background: #fff; border: 1px solid #e7e2d7; border-radius: 16px; padding: 16px 20px 18px;
  box-shadow: 0 30px 60px -36px rgb(40 30 5 / 0.45); position: relative;
}
.dp-cab { display: flex; justify-content: space-between; font-size: .85rem; color: var(--suave); padding-bottom: 10px; border-bottom: 1px solid #eee9de; }
.dp-chip { background: #f6ecc4; color: #7a6209; border-radius: 999px; padding: 2px 10px; font-size: .78rem; transition: opacity .4s; }
.dp-fila { display: grid; grid-template-columns: 1fr auto auto; gap: 14px; padding: 12px 0; border-bottom: 1px solid #eee9de; align-items: center; }
.dp-cant { color: var(--suave); font-size: .9rem; }
.dp-precio { position: relative; min-width: 76px; text-align: right; font-variant-numeric: tabular-nums; display: grid; }
.dp-precio > * { grid-area: 1 / 1; text-decoration: none; font-weight: 500; transition: opacity .4s, translate .4s var(--ease); }
.dp-viejo { color: #9a7b10; background: #fbf4d8; border-radius: 6px; padding: 0 6px; font-weight: 500; }
.dp-nuevo { opacity: 0; translate: 0 6px; color: #3d6a2a; }
.dp-aviso { position: relative; margin-top: 14px; min-height: 48px; font-size: .95rem; }
.dp-aviso > span { position: absolute; inset: 0; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; opacity: 0; translate: 0 8px; transition: opacity .45s, translate .45s var(--ease); }
.dp-boton { font-style: normal; background: var(--ink); color: #fff; border-radius: 999px; padding: 6px 16px; font-size: .88rem; transition: transform .2s, background .2s; }
.dp-t3 { color: #3d6a2a; font-weight: 500; }
.demo-precio .dp-t1 { opacity: 1; translate: 0 0; }
.demo-precio.s1 .dp-viejo { opacity: 0; translate: 0 -6px; } .demo-precio.s1 .dp-nuevo, .demo-precio.s2 .dp-nuevo, .demo-precio.s3 .dp-nuevo { opacity: 1; translate: 0 0; }
.demo-precio.s2 .dp-viejo, .demo-precio.s3 .dp-viejo { opacity: 0; }
.demo-precio.s1 .dp-t1, .demo-precio.s2 .dp-t1, .demo-precio.s3 .dp-t1 { opacity: 0; translate: 0 -8px; }
.demo-precio.s2 .dp-t2 { opacity: 1; translate: 0 0; }
.demo-precio.s2.pulsa .dp-boton { transform: scale(.92); background: #4a3c05; }
.demo-precio.s3 .dp-t3 { opacity: 1; translate: 0 0; }
.demo-precio.s1 .dp-chip, .demo-precio.s2 .dp-chip, .demo-precio.s3 .dp-chip { opacity: 0; }
.demo-precio:not(.js-vivo) .dp-t1 { opacity: 0; } .demo-precio:not(.js-vivo) .dp-t3 { opacity: 1; translate: 0 0; }
.demo-precio:not(.js-vivo) .dp-viejo { opacity: 0; } .demo-precio:not(.js-vivo) .dp-nuevo { opacity: 1; translate: 0 0; }

/* ── Del manifiesto: de la voz al cliente, con el reloj corriendo ── */
.flujo { position: relative; margin-top: 56px; display: grid; gap: 14px; grid-template-columns: repeat(3, 1fr); padding-top: 4px; }
.flujo::before { content: ""; position: absolute; left: 16%; right: 16%; top: 38px; height: 2px; background: linear-gradient(90deg, #cba51e, #dcc36e); transform-origin: left; transform: scaleX(0); transition: transform 2.4s var(--ease) .3s; }
.flujo.visto::before { transform: none; }
.flujo-paso { position: relative; display: grid; justify-items: center; text-align: center; gap: 4px; }
.flujo-ico { width: 68px; height: 68px; border-radius: 50%; display: grid; place-items: center; background: #fff; border: 2px solid #e0dbd0; color: #8a6f0f; box-shadow: 0 16px 30px -18px rgb(40 30 5 / .5); transition: background .5s, color .5s, border-color .5s, scale .5s var(--ease); }
.flujo-ico .ico { width: 28px; height: 28px; }
.flujo-paso b { margin-top: 8px; font-family: var(--display); font-weight: 400; font-size: 1.25rem; }
.flujo-paso small { color: var(--suave); }
.flujo.visto .flujo-paso .flujo-ico { background: #cba51e; color: #0c0c0c; border-color: #cba51e; scale: 1.06; }
.flujo.visto .flujo-paso:nth-child(2) .flujo-ico { transition-delay: 1.1s; } .flujo.visto .flujo-paso:nth-child(3) .flujo-ico { transition-delay: 2.2s; }
.js .flujo:not(.visto) .flujo-ico { background: #fff; }
.flujo-reloj { grid-column: 1 / -1; justify-self: center; margin-top: 18px; padding: 10px 22px; border-radius: 999px; background: #0c0c0c; color: #f2eee3; font-variant-numeric: tabular-nums; font-size: 1.1rem; }
.flujo-reloj span { color: #dcc36e; font-weight: 500; display: inline-block; min-width: 2.4ch; text-align: right; }
.flujo-reloj em { white-space: nowrap; font-style: normal; margin-left: 10px; opacity: 0; transition: opacity .4s; color: #dcc36e; }
.flujo-reloj.fin em { opacity: 1; }
@media (max-width: 520px) { .flujo-ico { width: 56px; height: 56px; } .flujo::before { top: 32px; } .flujo-paso b { font-size: 1.05rem; } .flujo-paso small { font-size: .85rem; } }

/* ── Llamadas a la acción: nota de precio y botón tras la escena ── */
.precio-nota { margin-top: 14px; font-size: .92rem; color: var(--suave); }
.cta-medio { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 28px; margin-bottom: 44px; padding: 22px 26px; border-radius: 18px; background: #0c0c0c; color: #f2eee3; box-shadow: 0 30px 60px -34px rgb(0 0 0 / .6); }
.cta-medio p { font-family: var(--display); font-weight: 300; font-size: clamp(1.3rem, 3vw, 1.7rem); }

/* ── Historia del autor ── */
.autor-rejilla { max-width: 760px; }
.autor-etiqueta { text-transform: uppercase; letter-spacing: .18em; font-size: .8rem; color: #8a6f0f; margin-bottom: 14px; }
.autor-texto { margin-top: 28px; display: grid; gap: 18px; font-size: clamp(1.1rem, 2.2vw, 1.3rem); line-height: 1.6; color: #2b2924; padding-left: 22px; border-left: 3px solid #cba51e; }
.autor-texto strong { font-weight: 500; color: #0c0c0c; }

/* ── Formulario de invitación por WhatsApp ── */
.form-inv { width: min(440px, 100%); display: grid; gap: 14px; text-align: left; }
.form-inv label { display: grid; gap: 6px; font-size: .9rem; color: var(--suave); }
.form-inv input { height: 52px; padding: 0 16px; border-radius: 12px; border: 1px solid rgb(255 255 255 / .18); background: rgb(255 255 255 / .06); color: var(--texto); font: inherit; font-size: 1rem; }
.form-inv input:focus-visible { outline: 2px solid #dcc36e; outline-offset: 2px; }
.form-inv input[aria-invalid="true"] { border-color: #e0846a; }
.form-inv .boton { width: 100%; gap: 10px; padding-inline: 14px; font-size: .78rem; letter-spacing: .1em; }
.form-inv .boton .ico { width: 22px; height: 22px; }
.form-inv small { color: var(--suave); text-align: center; }
.form-aviso { min-height: 1.3em; color: #e0846a; text-align: center; font-size: .95rem; }
.invitacion-cuerpo > .form-inv { margin-top: 16px; }

/* ── Portada en el móvil: el teléfono y el PDF asoman ya en la primera pantalla ── */
@media (max-width: 899px) {
  .portada-rejilla { gap: 12px; padding-block: 18px 36px; }
  .portada-sub { margin-top: 14px; }
  .portada-botones { margin-top: 22px; }
  .precio-nota { margin-top: 10px; font-size: .86rem; }
  .portada-visual { padding-top: 0; }
  .tel-grande { width: min(212px, 55vw); margin-right: min(30px, 6vw); }
  .hoja-hero { display: block; position: absolute; z-index: 2; width: 43vw; max-width: 190px; right: 0; top: 34px; transform: rotate(6deg); }
  .hoja-hero img { display: block; width: 100%; height: auto; border-radius: 4px; background: #fff; box-shadow: 0 30px 50px -24px rgb(0 0 0 / .9), 0 0 0 1px rgb(255 255 255 / .14); }
  .portada-visual figcaption { margin-top: 14px; }
}

/* ── Tarjetas "Todo el presupuesto": quedan 4 (voz y PDF ya los cuentan la escena y el libro) ── */
@media (min-width: 760px) {
  .papel .celda-precios { grid-column: span 3; min-height: 0; }
  .papel .celda-clientes { grid-column: span 3; }
  .papel .celda-enlace { grid-column: span 4; }
  .papel .celda-instalar { grid-column: span 2; }
}
.curva-arriba { color: var(--papel); }
.papel-2 > .curva-arriba { color: var(--papel-2); }

/* ── Foto del autor (se oculta sola si no existe el archivo) ── */
.autor-foto { width: 112px; height: 112px; margin: 22px 0 0; border-radius: 50%; overflow: hidden; border: 3px solid #cba51e; box-shadow: 0 18px 36px -20px rgb(40 30 5 / .6); }
.autor-foto img { display: block; width: 100%; height: 100%; object-fit: cover; }
.autor-foto[hidden] { display: none; }

/* ── Precios ── */
.precios-rejilla { margin-top: 40px; display: grid; gap: 18px; align-items: stretch; }
@media (min-width: 860px) { .precios-rejilla { grid-template-columns: repeat(3, 1fr); } .tarifa-fundador { translate: 0 -10px; } }
.tarifa { position: relative; display: grid; gap: 10px; align-content: start; padding: 30px 26px 28px; border-radius: 24px; background: #fff; border: 1px solid #e7e2d7; box-shadow: 0 24px 50px -34px rgb(40 30 5 / .4); }
.tarifa h3 { font-family: var(--display); font-weight: 400; font-size: 1.4rem; }
.tarifa-precio { font-family: var(--display); font-weight: 300; font-size: 3.2rem; line-height: 1; color: #0c0c0c; }
.tarifa-precio small { font-family: var(--sans); font-size: .95rem; color: var(--suave); }
.tarifa-nota { color: var(--suave); }
.tarifa ul { display: grid; gap: 8px; margin: 10px 0 14px; padding: 0; list-style: none; }
.tarifa li { padding-left: 24px; position: relative; }
.tarifa li::before { content: "✓"; position: absolute; left: 0; color: #8a6f0f; font-weight: 600; }
.tarifa .boton { width: 100%; }
.boton-claro { background: transparent; color: #0c0c0c; border: 1.5px solid #0c0c0c; }
.tarifa-fundador { background: #0c0c0c; color: #f2eee3; border-color: #cba51e; box-shadow: 0 40px 70px -34px rgb(203 165 30 / .55); }
.tarifa-fundador .tarifa-precio { color: #dcc36e; }
.tarifa-fundador .tarifa-precio small, .tarifa-fundador .tarifa-nota { color: #a9a496; }
.tarifa-fundador li::before { color: #dcc36e; }
.tarifa-cinta { position: absolute; top: -13px; right: 22px; background: #cba51e; color: #0c0c0c; border-radius: 999px; padding: 4px 14px; font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; font-weight: 600; }

.autor-foto { display: none; }
.autor-foto.ok { display: block; }

.autor-firma { margin-top: 6px; color: var(--suave); font-size: 1rem; line-height: 1.4; }
.autor-firma strong { color: #0c0c0c; font-weight: 500; font-size: 1.1rem; }

@media (max-width: 520px) { .dp-aviso { min-height: 104px; } .dp-aviso > span { align-items: flex-start; } }

/* La demo del precio no empuja ni mueve nada de lo que tiene alrededor mientras cambia */
.demo-precio { contain: layout style; }

/* Barra de progreso del móvil (la pinta vivo.js) */
.progreso.js-barra {
  display: block; position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 70; pointer-events: none;
  background: linear-gradient(90deg, var(--oro), var(--oro-claro)); transform: scaleX(0); transform-origin: left;
}
