Deck Swiper
X-ray · layers
Parameters
How this effect works
The whole interaction hangs on one number: how far you've dragged sideways. That single distance drives everything you see. The card moves by it, of course — but it also rotates in proportion to it (angle = dx / halfWidth × TILT), and the badge that says LIKE or NOPE fades in on the same ratio. Nothing is animated separately; turn tilt off and you'll see the card slide flat, which is exactly how cheap it looks without that one extra line.
Let go and there are only two outcomes. Past THRESHOLD the card keeps the direction it was already going and flies off screen; under it, a spring pulls it home (x += (0 - x) * SPRING). The stack behind isn't a second animation either — each card sits a little lower and a little smaller by its depth, so when the top one leaves, every card simply moves up one step and the deck appears to advance.
touch-action: none on the card stops the page scrolling under your thumb · cards are recycled to the back, so the deck never runs out · the copied snippet is self-contained HTML + CSS + JS.