/* ---------- Movimiento: cómo aparece cada cosa y cómo responde al tocarla ---------- */

@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: scale(0.85); } to { opacity: 1; transform: none; } }
@keyframes fade-in { from { opacity: 0; } }

/* Cada pantalla entra deslizándose de abajo, una parte detrás de otra */
#app > * { animation: rise 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) backwards; }
#app > *:nth-child(2) { animation-delay: 0.05s; }
#app > *:nth-child(3) { animation-delay: 0.1s; }
#app > *:nth-child(4) { animation-delay: 0.15s; }
#app > *:nth-child(n + 5) { animation-delay: 0.2s; }

/* Listas: partidas, cambios del parche, jugadores, análisis... entran escalonadas */
.match, .patch-card, .lp, .coach, .smurf-alert, .mini-option, .rank-card, .card.side-card { animation: rise 0.42s cubic-bezier(0.2, 0.8, 0.2, 1) backwards; }
.match:nth-child(2), .patch-card:nth-child(2), .lp:nth-child(4) { animation-delay: 0.04s; }
.match:nth-child(3), .patch-card:nth-child(3), .lp:nth-child(5) { animation-delay: 0.08s; }
.match:nth-child(4), .patch-card:nth-child(4), .lp:nth-child(6) { animation-delay: 0.12s; }
.match:nth-child(5), .patch-card:nth-child(5), .lp:nth-child(7) { animation-delay: 0.16s; }
.match:nth-child(6), .patch-card:nth-child(6), .lp:nth-child(8) { animation-delay: 0.2s; }
.match:nth-child(7), .patch-card:nth-child(7), .lp:nth-child(9) { animation-delay: 0.24s; }
.match:nth-child(n + 8), .patch-card:nth-child(n + 8), .lp:nth-child(n + 10) { animation-delay: 0.28s; }
.mini-option:nth-child(3) { animation-delay: 0.06s; }
.mini-option:nth-child(4) { animation-delay: 0.12s; }

/* Etiquetas que aparecen con un "pop" (no en lo que se actualiza solo durante la partida) */
.badge { animation: pop 0.28s cubic-bezier(0.2, 0.8, 0.2, 1) backwards; }
.game-panel .badge, .mini .badge { animation: none; }

/* Botones: se levantan al pasar el mouse y se hunden al tocarlos */
.btn { transition: transform 0.15s ease, background 0.2s, box-shadow 0.2s, border-color 0.2s, color 0.2s; }
.btn:hover:not(:disabled) { transform: translateY(-1px); }
.btn:active:not(:disabled) { transform: translateY(0) scale(0.96); }
.btn-ghost:hover:not(:disabled) { box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3); }
.nav a, .nav-search-toggle { transition: color 0.15s, background 0.15s, transform 0.15s; }
.nav a:active, .nav-search-toggle:active { transform: scale(0.95); }
.patch-chip { transition: border-color 0.18s, background 0.18s, color 0.18s, transform 0.15s; }
.patch-chip:hover { border-color: var(--brand-line); color: var(--fg); }
.patch-chip:active { transform: scale(0.94); }

/* Tarjetas que se levantan al pasar el mouse */
.patch-card, .lp, .cs-pick, .rank-card { transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s, background 0.2s; }
.patch-card:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35); }
.lp:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(0, 0, 0, 0.3); }
.cs-pick { border-radius: 8px; }
.cs-pick:hover { background: rgba(255, 255, 255, 0.04); transform: translateX(3px); }

/* Imágenes de campeones y objetos: un pequeño zoom al pasar el mouse */
.champ-lg, .item-lg, .patch-icon, .mini-champ { transition: transform 0.18s ease, box-shadow 0.18s ease; }
.lp-champ:hover .champ-lg, .item-lg:hover, .patch-card:hover .patch-icon { transform: scale(1.08); }

/* Menús y avisos que aparecen */
.update-pill { animation: pop 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) backwards; }
.ai-box, .matchup-tip { animation: fade-in 0.4s ease backwards; }
