# Depth Card

> A card that tilts toward the cursor while its layers float at different depths, so each moves at its own speed.

Category: Cards · Free with an account · Updated 2026-10-20 · Live demo: https://www.motionkitui.com/components/depth-card

## When to use it

Hero product cards, game or event tickets and showcase tiles where layered artwork (a background, a product, a label) should separate as the card moves.

## How it works

The card tilts like the Tilt Card, but keeps transform-style: preserve-3d so its children live in real 3D space. Each DepthLayer is pushed forward with translateZ by its depth prop, so as the card rotates, nearer layers shift further than deeper ones. That difference is parallax, and it is what reads as depth. The card skips overflow: hidden on purpose, because clipping would flatten the layers.

## Installation

Free with a MotionKit account: sign up at https://www.motionkitui.com/components/depth-card to copy the source. Subscribers can also install it with `npx shadcn@latest add @motionkit/depth-card`.

## Props

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `maxTilt` | `number` | `12` | Maximum rotation in degrees. |
| `glare` | `boolean` | `true` | Show a light reflection that follows the pointer. |
| `<DepthLayer depth>` | `number` | `30` | How far a layer floats above the card, in pixels. Higher layers move more. |

## Accessibility

- **Keyboard: Not applicable.** A static container. The tilt is a pointer-only flourish and hides nothing.
- **Screen readers: Pass.** Layers keep their normal reading order. The glare is hidden from assistive tech.
- **Reduced motion: Pass.** With reduced motion on, the card does not tilt, so the layers sit still.
- **Colour contrast: Pass.** Default text on the card face measures 7.7:1. Check any colours you add to layers.
