/* Movimiento e interacción (publicado el 18-oct-2026): título animado, historias, «¿Verdad o mentira?» y microanimaciones. */

/* ---------- Portada: fondo vivo y título que cambia de tema ---------- */
.m-hero { position: relative; isolation: isolate; }
.v-fondo { position: absolute; inset: -40px -16px -10px; z-index: -1; overflow: hidden; pointer-events: none; }
.v-fondo i { position: absolute; width: 260px; height: 260px; border-radius: 50%; filter: blur(48px); opacity: .32; background: var(--kraft); animation: v-flota 14s ease-in-out infinite alternate; }
.v-fondo i:nth-child(1) { top: -40px; left: -60px; }
.v-fondo i:nth-child(2) { top: 40px; right: -90px; width: 220px; height: 220px; background: #d9c6a3; animation-duration: 18s; animation-delay: -6s; }
.v-fondo i:nth-child(3) { bottom: -80px; left: 30%; width: 200px; height: 200px; background: #e8dcc6; animation-duration: 16s; animation-delay: -3s; }
@keyframes v-flota { 0% { transform: translate(0, 0) scale(1); } 50% { transform: translate(30px, 20px) scale(1.15); } 100% { transform: translate(-20px, 35px) scale(.95); } }

.v-titulo .v-fijo { display: block; }
.v-rota { position: relative; display: block; height: 1.12em; overflow: hidden; }
.v-rota a { position: absolute; left: 0; top: 0; color: inherit; text-decoration: none; white-space: nowrap; transition: transform .55s cubic-bezier(.2,.9,.25,1), opacity .4s, filter .4s; }
.v-rota a::after { content: ''; position: absolute; left: 0; right: 0; bottom: .06em; height: .14em; border-radius: 4px; background: var(--kraft); transform-origin: left; animation: v-subraya 2.6s ease-out infinite; }
.v-rota a.entra { transform: translateY(110%); opacity: 0; filter: blur(4px); }
.v-rota a.sale { transform: translateY(-110%); opacity: 0; filter: blur(4px); }
@keyframes v-subraya { 0% { transform: scaleX(0); } 25%, 85% { transform: scaleX(1); } 100% { transform: scaleX(1); opacity: .9; } }

.m-punto { animation: v-latido 1.6s ease-out infinite; }
@keyframes v-latido { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--kraft) 55%, transparent); } 100% { box-shadow: 0 0 0 9px transparent; } }

/* ---------- Historias ---------- */
.v-historias { list-style: none; display: flex; gap: 14px; margin: 16px -16px 0; padding: 4px 16px 6px; overflow-x: auto; scrollbar-width: none; }
.v-historias::-webkit-scrollbar { display: none; }
.v-historias button { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 0; border: 0; background: none; font: 600 .75rem/1.2 system-ui, sans-serif; color: var(--tinta); cursor: pointer; -webkit-tap-highlight-color: transparent; }
.v-aro { position: relative; display: grid; place-items: center; width: 66px; height: 66px; border-radius: 50%; }
.v-aro::before { content: ''; position: absolute; inset: 0; border-radius: 50%; padding: 3px; background: conic-gradient(from var(--g, 0deg), #A8814A, #f1d7a6, #7a5a2c, #A8814A); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: v-gira 3s linear infinite; }
.v-aro span { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: var(--superficie); border: 2px solid var(--papel); font-size: 1.6rem; transition: transform .2s; }
.v-historias button:active .v-aro span { transform: scale(.9); }
.v-historias .visto .v-aro::before { background: var(--linea); animation: none; }
@property --g { syntax: '<angle>'; inherits: false; initial-value: 0deg; }
@keyframes v-gira { to { --g: 360deg; } }

.v-visor { position: fixed; inset: 0; z-index: 200; display: flex; flex-direction: column; color: #fff; background: #111; touch-action: none; user-select: none; -webkit-user-select: none; animation: v-abre .28s cubic-bezier(.2,.9,.25,1); }
.v-visor[hidden] { display: none; }
@keyframes v-abre { from { transform: scale(.92); opacity: 0; } }
.v-visor.cierra { animation: v-cierra .22s ease-in forwards; }
@keyframes v-cierra { to { transform: translateY(40px) scale(.94); opacity: 0; } }
.v-barras { display: flex; gap: 4px; padding: calc(10px + env(safe-area-inset-top)) 12px 0; }
.v-barras i { flex: 1; height: 3px; border-radius: 3px; background: rgba(255,255,255,.3); overflow: hidden; }
.v-barras i b { display: block; height: 100%; width: 0; background: #fff; }
.v-barras i.hecha b { width: 100%; }
.v-cab { display: flex; align-items: center; gap: 10px; padding: 10px 12px; font: 700 .9rem system-ui, sans-serif; }
.v-cab .v-mini { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,.15); font-size: 1rem; }
.v-cab button { margin-left: auto; width: 40px; height: 40px; border: 0; border-radius: 50%; background: rgba(255,255,255,.12); color: #fff; font-size: 1.3rem; cursor: pointer; }
.v-lamina { position: relative; flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 24px 26px 60px; overflow: hidden; }
.v-lamina > * { animation: v-sube .5s cubic-bezier(.2,.9,.25,1) both; }
.v-lamina > *:nth-child(2) { animation-delay: .08s; }
.v-lamina > *:nth-child(3) { animation-delay: .16s; }
.v-lamina > *:nth-child(4) { animation-delay: .24s; }
@keyframes v-sube { from { transform: translateY(24px); opacity: 0; } }
.v-emoji { font-size: 3.4rem; margin-bottom: 14px; }
.v-kick { font: 700 .8rem system-ui, sans-serif; letter-spacing: .12em; text-transform: uppercase; color: #f1d7a6; margin-bottom: 8px; }
.v-grande { font: 700 clamp(2.1rem, 10vw, 3.4rem)/1.05 var(--serif); margin: 0 0 14px; }
.v-texto { font-size: 1.15rem; line-height: 1.45; color: rgba(255,255,255,.88); margin: 0; }
.v-sello { align-self: flex-start; margin-top: 18px; padding: 6px 16px; border: 3px solid currentColor; border-radius: 8px; font: 800 1.5rem system-ui, sans-serif; letter-spacing: .08em; transform: rotate(-6deg); animation: v-sella .45s cubic-bezier(.3,1.6,.5,1) both !important; animation-delay: 1.1s !important; }
.v-sello.falso { color: #ff7a6b; }
.v-sello.verdad { color: #7be0a0; }
@keyframes v-sella { from { transform: rotate(-6deg) scale(2.2); opacity: 0; } }
.v-cta { align-self: flex-start; margin-top: 22px; padding: 14px 22px; border-radius: 999px; background: #fff; color: #111; font-weight: 800; text-decoration: none; position: relative; z-index: 3; }
.v-fuente { position: absolute; left: 26px; right: 26px; bottom: calc(18px + env(safe-area-inset-bottom)); font-size: .72rem; color: rgba(255,255,255,.6); }
.v-fuente a { color: inherit; position: relative; z-index: 3; }
.v-toque { position: absolute; top: 0; bottom: 0; width: 34%; z-index: 2; }
.v-toque.atras { left: 0; }
.v-toque.alante { right: 0; width: 66%; }
.v-visor[data-g="0"] { background: radial-gradient(120% 80% at 20% 10%, #3a2c18, #111 60%); }
.v-visor[data-g="1"] { background: radial-gradient(120% 80% at 80% 10%, #2a2f3a, #111 60%); }
.v-visor[data-g="2"] { background: radial-gradient(120% 80% at 20% 90%, #3a1f1f, #111 60%); }
.v-visor[data-g="3"] { background: radial-gradient(120% 80% at 80% 90%, #1f3a2c, #111 60%); }
.v-visor[data-g="4"] { background: radial-gradient(120% 80% at 50% 0%, #3a2c18, #111 65%); }

/* ---------- ¿Verdad o mentira? ---------- */
.v-juego .m-cab { align-items: center; }
.v-racha { display: inline-flex; align-items: center; gap: 4px; padding: 5px 12px; border-radius: 999px; background: var(--superficie); border: 1px solid var(--linea); font-weight: 800; font-size: .9rem; transition: transform .2s; }
.v-racha.sube { animation: v-pop .4s cubic-bezier(.3,1.6,.5,1); }
@keyframes v-pop { 50% { transform: scale(1.35); } }
.v-mazo { position: relative; height: 270px; margin: 6px 0 12px; perspective: 1200px; }
.v-carta { position: absolute; inset: 0; touch-action: pan-y; cursor: grab; transition: transform .45s cubic-bezier(.2,.9,.25,1), opacity .3s; }
.v-carta.atras-del-todo { transform: translateY(10px) scale(.95); opacity: .6; pointer-events: none; }
.v-carta.arrastra { transition: none; cursor: grabbing; }
.v-giro { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .6s cubic-bezier(.2,.9,.25,1); }
.v-carta.girada .v-giro { transform: rotateY(180deg); }
.v-cara { position: absolute; inset: 0; display: flex; flex-direction: column; padding: 20px; border-radius: 20px; background: var(--superficie); border: 1px solid var(--linea); box-shadow: 0 14px 34px rgba(0,0,0,.1); backface-visibility: hidden; -webkit-backface-visibility: hidden; overflow: hidden; }
.v-cara.dorso { transform: rotateY(180deg); overflow-y: auto; }
.v-num { font-size: .75rem; font-weight: 700; color: var(--suave); text-transform: uppercase; letter-spacing: .08em; }
.v-frase { margin: auto 0; font: 700 1.45rem/1.25 var(--serif); }
.v-pista { font-size: .78rem; color: var(--suave); display: flex; justify-content: space-between; }
.v-marca { position: absolute; top: 18px; padding: 4px 12px; border: 3px solid; border-radius: 8px; font: 800 1.1rem system-ui, sans-serif; letter-spacing: .06em; opacity: 0; pointer-events: none; }
.v-marca.si { right: 16px; color: #2e9b5b; transform: rotate(8deg); }
.v-marca.no { left: 16px; color: #d0493b; transform: rotate(-8deg); }
.v-resultado { font: 800 1.35rem system-ui, sans-serif; margin: 0 0 4px; }
.v-resultado.bien { color: #2e9b5b; }
.v-resultado.mal { color: #d0493b; }
.v-dorso-es { font-size: .9rem; margin: 0 0 8px; }
.v-dorso-t { font-size: .92rem; line-height: 1.45; margin: 0 0 8px; }
.v-dorso .fuente { margin-top: auto; }
.v-botones { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.v-botones button { height: 54px; border-radius: 16px; border: 0; font: 800 1rem system-ui, sans-serif; cursor: pointer; transition: transform .12s; -webkit-tap-highlight-color: transparent; }
.v-botones button:active { transform: scale(.95); }
.v-botones [data-r="falso"] { background: #fde5e2; color: #a33224; }
.v-botones [data-r="verdad"] { background: #dff3e7; color: #1f6e41; }
.v-botones .v-sig { grid-column: 1 / -1; background: var(--tinta); color: var(--papel); }
.v-botones .v-otra { background: var(--superficie); color: var(--tinta); border: 1px solid var(--linea); }
.v-botones .v-ver { display: grid; place-items: center; height: 54px; border-radius: 16px; background: var(--tinta); color: var(--papel); font: 800 1rem system-ui, sans-serif; text-decoration: none; }
.v-chispa { position: fixed; z-index: 150; pointer-events: none; font-size: 1.4rem; animation: v-chispa .9s ease-out forwards; }
@keyframes v-chispa { to { transform: translate(var(--x), var(--y)) rotate(var(--r)); opacity: 0; } }
@media (prefers-color-scheme: dark) {
  .v-botones [data-r="falso"] { background: #4a2420; color: #ffb4aa; }
  .v-botones [data-r="verdad"] { background: #1f3d2b; color: #a6e8bf; }
}

/* ---------- Microanimaciones ---------- */
.m-accion.principal { position: relative; overflow: hidden; }
.m-accion.principal::after { content: ''; position: absolute; top: 0; bottom: 0; width: 60%; left: -70%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.18), transparent); transform: skewX(-18deg); animation: v-brillo 4.5s ease-in-out infinite 1.2s; }
@keyframes v-brillo { 0%, 60% { left: -70%; } 100% { left: 130%; } }
.m-accion.principal .m-ico { animation: v-brujula 4.5s ease-in-out infinite; }
@keyframes v-brujula { 0%, 70%, 100% { transform: rotate(0); } 78% { transform: rotate(-14deg); } 86% { transform: rotate(10deg); } 93% { transform: rotate(-4deg); } }
[data-v-entra] > * { opacity: 0; transform: translateY(14px) scale(.97); }
[data-v-entra].v-in > * { opacity: 1; transform: none; transition: opacity .45s ease-out, transform .5s cubic-bezier(.2,.9,.25,1); transition-delay: calc(var(--i, 0) * 45ms); }

@media (min-width: 761px) { .v-juego { max-width: 620px; } }

@media (prefers-reduced-motion: reduce) {
  .v-fondo i, .v-aro::before, .m-punto, .m-accion.principal::after, .m-accion.principal .m-ico, .v-rota a::after { animation: none !important; }
  [data-v-entra] > * { opacity: 1; transform: none; }
  .v-lamina > *, .v-sello { animation: none !important; }
}
