# Layered Color Shadow

> Bold text with four stacked colored shadows that fold back into the letters on hover.

- Category: [CSS Text Effects](https://copy-css.com/category/text)
- Tags: text-shadow, stacked, rainbow, offset, hover
- Live preview: https://copy-css.com/snippets/layered-shadow-text
- License: Free for personal and commercial use. No signup, no attribution required.

## HTML

```html
<h2 class="text-layers">Layers</h2>
```

## CSS

```css
.text-layers {
  margin: 0;
  color: #1e1b4b;
  font: 900 52px/1 system-ui, sans-serif;
  text-shadow:
    3px 3px 0 #f472b6,
    6px 6px 0 #a78bfa,
    9px 9px 0 #60a5fa,
    12px 12px 0 #34d399;
  transition: text-shadow 0.3s ease;
}

.text-layers:hover {
  text-shadow:
    0 0 0 #f472b6,
    0 0 0 #a78bfa,
    0 0 0 #60a5fa,
    0 0 0 #34d399;
}
```

## Notes

- This CSS Layered Color Shadow is 19 lines of pure CSS (0.3 KB) with no JavaScript and no dependencies. It uses transitions and text shadows.
- In JSX use `className` instead of `class`. In Tailwind projects put the CSS in the global stylesheet.
