/* Portada de venta: movimiento y secciones nuevas (2026-11-22). Un celular que enseña cómo agenda un cliente (sólo CSS),
   fichas que flotan, entradas al bajar, tira de giros, preguntas frecuentes, cierre y barra fija en el celular.
   Nada se queda escondido: sin JavaScript o con «reducir movimiento» todo se ve quieto y completo. */

/* ── Hero: la computadora con la agenda y el celular que agenda solo ── */
.po-imagen .po-cel { display: none; }
.po-demo { position: absolute; right: -8px; bottom: -6px; width: 29%; min-width: 190px; aspect-ratio: 9 / 18.5; border-radius: 26px; border: 6px solid var(--marino);
  background: #fff; box-shadow: 0 22px 46px rgba(16, 34, 58, .28); overflow: hidden; animation: po-flota 8s ease-in-out infinite; }
.po-demo-barra { background: var(--azul); color: #fff; font-size: 10.5px; font-weight: 700; padding: 9px 10px; text-align: center; }
.po-demo-cuerpo { position: relative; height: calc(100% - 31px); }
.po-p { position: absolute; inset: 0; padding: 12px 10px; opacity: 0; animation: po-paso 9s infinite; }
.po-p2 { animation-delay: 3s; }
.po-p3 { animation-delay: 6s; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 4px; }
.po-p h4 { margin: 0 0 8px; font-size: 11.5px; color: var(--marino); }
.po-op { display: flex; justify-content: space-between; gap: 6px; padding: 8px 9px; margin-bottom: 6px; border: 1px solid var(--borde); border-radius: 9px; font-size: 10.5px; font-weight: 600; color: var(--texto); }
.po-op i { font-style: normal; color: var(--suave); }
.po-p1 .po-op:first-of-type { animation: po-toca 9s infinite; }
.po-horas { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.po-horas span { text-align: center; padding: 8px 0; border: 1px solid var(--borde); border-radius: 8px; font-size: 10.5px; font-weight: 700; color: var(--azul); }
.po-horas .po-sel { animation: po-toca-h 9s infinite; }
.po-ok { width: 44px; height: 44px; border-radius: 50%; background: var(--bien-solido); color: #fff; display: grid; place-items: center; font-size: 24px; animation: po-pop 9s infinite; }
.po-p3 h4 { margin: 4px 0 0; font-size: 13px; }
.po-p3 p { margin: 0; font-size: 11px; font-weight: 700; color: var(--marino); }
.po-p3 small { font-size: 9.5px; color: var(--suave); line-height: 1.3; padding: 0 6px; }
.po-ejemplo { position: absolute; left: 0; right: 0; bottom: 6px; text-align: center; font-size: 8px; font-weight: 800; letter-spacing: .08em; color: var(--peligro); }
@keyframes po-paso { 0% { opacity: 0; translate: 14px 0; } 4%, 29% { opacity: 1; translate: 0 0; } 33%, 100% { opacity: 0; translate: -14px 0; } }
@keyframes po-toca { 0%, 12% { background: #fff; border-color: var(--borde); } 16%, 30% { background: var(--activo); border-color: var(--azul); color: var(--azul); } 33%, 100% { background: #fff; border-color: var(--borde); } }
@keyframes po-toca-h { 0%, 45% { background: #fff; border-color: var(--borde); } 49%, 63% { background: var(--acento); border-color: var(--acento); color: #fff; } 66%, 100% { background: #fff; border-color: var(--borde); color: var(--azul); } }
@keyframes po-pop { 0%, 66% { scale: .5; } 72% { scale: 1.15; } 76%, 100% { scale: 1; } }
@keyframes po-flota { 50% { translate: 0 -10px; } }

.po-ficha { position: absolute; display: flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 12px; background: #fff; border: 1px solid var(--borde); font-size: 13px; font-weight: 700;
  color: var(--marino); box-shadow: 0 14px 30px rgba(16, 34, 58, .16); white-space: nowrap; }
.po-ficha b { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--bien-solido); color: #fff; font-size: 12px; }
.po-ficha.f1 { left: -14px; bottom: 28px; animation: po-flota 6s ease-in-out -1s infinite; }
.po-ficha.f2 { left: 34%; top: -14px; animation: po-flota 7s ease-in-out -3s infinite; }
.po-ficha.f2 b { background: var(--acento); }

/* ── Giros ── */
.po-giros-sec { padding: 8px 0 56px; }
.po-giros-sec > h2 { text-align: center; font-size: clamp(24px, 3vw, 32px); letter-spacing: -.02em; margin-bottom: 8px; }
.po-giros-sec > p { text-align: center; color: var(--suave); margin: 0 auto 26px; max-width: 46ch; }
.po-tira { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.po-giro { position: relative; display: block; aspect-ratio: 3 / 4; border-radius: 16px; overflow: hidden; background: var(--marino); isolation: isolate; text-decoration: none; transition: transform .4s cubic-bezier(.2, .8, .2, 1); }
.po-giro:nth-child(even) { margin-top: 24px; }
.po-giro:hover { transform: translateY(-8px); }
.po-giro img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform 1.2s; }
.po-giro:hover img { transform: scale(1.08); }
.po-giro::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, transparent 38%, rgba(10, 18, 38, .88)); }
.po-giro span { position: absolute; left: 12px; right: 12px; bottom: 12px; color: #fff; }
.po-giro b { display: block; font-size: 16px; line-height: 1.15; }
.po-giro small { display: block; font-size: 12px; opacity: .85; margin-top: 2px; }
.po-giro em { display: inline-block; margin-top: 8px; padding: 4px 10px; border-radius: 99px; background: var(--acento); color: #fff; font-size: 11.5px; font-weight: 700; font-style: normal; }

/* ── Preguntas frecuentes ── */
.po-faq { max-width: 780px; margin: 0 auto; display: grid; gap: 10px; }
.po-faq details { background: #fff; border: 1px solid var(--borde); border-radius: 12px; padding: 0 18px; transition: box-shadow .2s; }
.po-faq details[open] { box-shadow: 0 10px 26px rgba(16, 34, 58, .08); border-color: var(--borde-activo); }
.po-faq summary { cursor: pointer; padding: 15px 0; font-weight: 700; color: var(--marino); list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.po-faq summary::-webkit-details-marker { display: none; }
.po-faq summary::after { content: "+"; font-size: 22px; line-height: 1; color: var(--acento); transition: rotate .25s; }
.po-faq details[open] summary::after { rotate: 45deg; }
.po-faq p { margin: 0 0 16px; color: var(--suave); }

/* ── Cierre ── */
.po-cierre { margin: 8px 0 64px; padding: 54px 24px; border-radius: 24px; text-align: center; color: #fff; position: relative; overflow: hidden;
  background: var(--marino); }
.po-cierre::before { content: ""; position: absolute; inset: -40% 25% auto; height: 380px; border-radius: 50%; background: radial-gradient(circle, rgba(232, 93, 28, .35), transparent 65%); }
.po-cierre > * { position: relative; }
.po-cierre h2 { font-size: clamp(26px, 3.6vw, 40px); letter-spacing: -.03em; margin: 0 auto 12px; max-width: 18ch; color: #fff; }
.po-cierre p { margin: 0 auto 24px; max-width: 44ch; color: #c5d1e3; }
.po-cierre .po-botones { justify-content: center; }
.po-cierre .btn-plano { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .4); }

/* ── Entradas al bajar ── */
.po-rv { transition: opacity .7s ease var(--d, 0ms), translate .7s cubic-bezier(.2, .8, .2, 1) var(--d, 0ms); }
.js-po .po-rv:not(.po-in) { opacity: 0; translate: 0 26px; }

/* ── Barra fija en el celular ── */
.po-fijo { display: none; }
@media (max-width: 760px) {
  .po-fijo { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 12; gap: 10px; padding: 10px max(16px, env(safe-area-inset-right, 0px)) calc(10px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
    background: rgba(255, 255, 255, .94); backdrop-filter: blur(12px); border-top: 1px solid var(--borde); transition: translate .3s; }
  .po-fijo .btn { flex: 1; text-align: center; }
  .po-fijo.oculto { translate: 0 110%; }
  body.portada { padding-bottom: 76px; }
}
@media (max-width: 900px) {
  .po-tira { grid-template-columns: repeat(2, 1fr); }
  .po-giro:nth-child(even) { margin-top: 0; }
  .po-giro:last-child { grid-column: span 2; aspect-ratio: 16 / 9; }
  .po-demo { right: 0; }
  .po-imagen { padding-top: 40px; }
}
@media (max-width: 520px) { .po-imagen { padding-top: 70px; } .po-demo { width: 40%; min-width: 0; } .po-ficha.f2 { display: none; } .po-ficha.f1 { left: 0; } }

@media (prefers-reduced-motion: reduce) {
  .po-demo, .po-ficha, .po-ok { animation: none; }
  .po-p { animation: none; opacity: 0; }
  .po-p3 { opacity: 1; }
  .po-p1 .po-op:first-of-type, .po-horas .po-sel { animation: none; }
  .js-po .po-rv:not(.po-in) { opacity: 1; translate: none; }
  .po-giro, .po-giro img { transition: none; }
  .po-giro:hover, .po-giro:hover img { transform: none; }
}

/* ── Imagen de gancho de fondo en el hero (Juan, 2026-11-22) ──
   Cinco fotos de los giros se funden una tras otra, con un zoom lento, a todo lo ancho de la pantalla. Un velo blanco
   cubre el lado del texto (se lee igual) y se aclara hacia la derecha, donde está la app; abajo se funde con la página. */
body.portada { overflow-x: clip; }
.po-heroe { position: relative; isolation: isolate; }
.po-hero-fondo { position: absolute; z-index: -1; top: 0; bottom: 0; left: 50%; width: 100vw; margin-left: -50vw; overflow: hidden; background: #fff; }
.po-hero-fondo i { position: absolute; inset: 0; background-size: cover; background-position: 60% 40%; opacity: 0; animation: po-fondo 30s infinite; }
.po-hero-fondo i:nth-child(1) { background-image: url("/img/hero/hero-1.webp"); }
.po-hero-fondo i:nth-child(2) { background-image: url("/img/hero/hero-2.webp"); animation-delay: 6s; }
.po-hero-fondo i:nth-child(3) { background-image: url("/img/hero/hero-3.webp"); animation-delay: 12s; }
.po-hero-fondo i:nth-child(4) { background-image: url("/img/hero/hero-4.webp"); animation-delay: 18s; }
.po-hero-fondo i:nth-child(5) { background-image: url("/img/hero/hero-5.webp"); animation-delay: 24s; }
.po-hero-fondo::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, .97) 0%, rgba(255, 255, 255, .92) 36%, rgba(255, 255, 255, .5) 66%, rgba(255, 255, 255, .22) 100%),
              linear-gradient(180deg, rgba(255, 255, 255, 0) 72%, #fff 100%); }
@keyframes po-fondo { 0% { opacity: 0; scale: 1; } 4% { opacity: 1; } 20% { opacity: 1; } 25% { opacity: 0; scale: 1.1; } 100% { opacity: 0; scale: 1.1; } }
@media (max-width: 900px) {
  /* En el celular la foto ocupa sólo la parte de arriba, limpia, y se funde a blanco justo donde empieza el texto. */
  .po-heroe { padding-top: 230px; }
  .po-hero-fondo { bottom: auto; height: 380px; }
  .po-hero-fondo i { background-position: 50% 30%; }
  .po-hero-fondo::after { background: linear-gradient(180deg, rgba(255, 255, 255, .04) 0, rgba(255, 255, 255, .08) 140px, rgba(255, 255, 255, .88) 250px, #fff 350px); }
}
@media (prefers-reduced-motion: reduce) {
  .po-hero-fondo i { animation: none; }
  .po-hero-fondo i:nth-child(1) { opacity: 1; }
}
