{"inline_daily":{"smooth-box-shadow-generator":{"layers":"Number of layers","final_distance":"Final distance","final_blur":"Final blur","total_opacity":"Total opacity","shadow_color":"Shadow color","progression_curve":"Progression curve","curve_linear":"Linear","curve_ease_in":"Ease-in (slow start)","curve_ease_out":"Ease-out (fast start)","dark_background":"Dark background","preview_card":"Card preview","copy_code":"Copy"}},"docs_daily":{"tools":{"smooth-box-shadow-generator":{"content":{"title":"Smooth CSS shadows: why stack several layers","intro":"A single CSS shadow looks flat and harsh. Stacking 3 to 8 shadows whose offset and blur grow along a curve mimics how real light diffuses. Each layer carries a fraction of the total opacity.","details":"

Formula

For layer i out of N, with f = i / N and p = curve(f): vertical offset = distance × p, blur = final blur × p, opacity = total opacity / N. The curve is f (linear), f² (ease-in) or 1 − (1 − f)² (ease-out).

Example

5 layers, distance 32 px, blur 64 px, opacity 40%, ease-out curve: the offsets are 12, 20, 27, 31 and 32 px, the blurs 23, 41, 54, 61 and 64 px, and each layer has an opacity of 0.08.

Limits

Many layers with a large blur cost rendering time on mobile: stay at 5 layers for card-heavy pages. The shadow is generated downwards only; a side shadow needs a horizontal offset added by hand.

Sources and dates: the CSS box-shadow property accepts several comma-separated shadows, which is the basis of the effect. The split of offsets, blurs and opacity across layers follows the tool's own method (linear, ease-in, ease-out curves), not a standard: it is an indicative aesthetic setting, not a sourced value. The Tailwind shadow-[…] syntax with underscores in place of spaces is Tailwind CSS's arbitrary-value notation (checked on 14/10/2026)

"},"faqs":[{"question":"How do I make a smooth, realistic CSS shadow?","answer":"Stack 4 to 6 box-shadows whose offset and blur roughly double with each layer, using a low opacity (0.04 to 0.1 per layer). The total opacity stays around 0.2 to 0.4."},{"question":"How many shadow layers should I use?","answer":"3 to 6 layers are enough in most cases. Beyond 8, the visual gain is almost nil and rendering costs more on mobile."},{"question":"How do I use this shadow with Tailwind CSS?","answer":"Use the arbitrary value syntax shadow-[…] with every space replaced by an underscore (_). The generator outputs the class ready to paste into your HTML."}]}}}}