Home › CSS Tutorial › CSS shadows
CSS shadows
Shadows for boxes and text.
box-shadow: x y blur spread color and text-shadow: x y blur color. Add inset for inner shadows.
Example code
<style>
.b{width:160px;padding:20px;margin:20px;box-shadow:6px 8px 14px rgba(0,0,0,.35)}
h2{text-shadow:2px 2px 4px #888}
</style>
<div class='b'>Box shadow</div><h2>Text shadow</h2>