Use shadows to explain elevation
Box shadows help separate a card, popover, or modal from the surface behind it. A useful shadow communicates hierarchy: a floating dialog needs more separation than a static list item. Start with a restrained shadow and increase it only when the interface needs another elevation level.
How to use this tool
- Set horizontal and vertical offsets to establish the direction of the light. A small downward offset usually feels natural.
- Increase blur for a softer edge and adjust spread to change the size of the shadow. Keep opacity low on a light background.
- Add a second layer when you need a crisp contact shadow plus a wider ambient shadow. Copy the complete comma-separated declaration.
The first layer gives the card a close edge. The second adds softer depth while the negative spread keeps the shadow from covering too much surrounding space. Shadow does not reserve layout space, so leave enough gap between adjacent cards.
Read the reference documentation ↗