GUIDE深度 · Deep dive
box-shadow Syntax
box-shadow: x y blur spread color. x/y are required, blur/spread optional, inset goes first; multiple layers are comma-separated, earlier ones on top.
Parameters
x: horizontal offset, positive right.
y: vertical offset, positive down.
blur: blur radius, non-negative.
spread: expansion, can be negative.
inset
inset draws the shadow inside the element.
Common for inset inputs and cards.
FAQ
Does a shadow affect layout?
No; it does not change box dimensions.
Can I put it on one side only?
Use offset plus negative spread, or a pseudo-element.