HTML CSS examples for CSS Property:box-shadow
Use CSS to code a 3-sided box with rounded corners and a shadow
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> .box {<!-- www . ja v a2 s .c o m--> width:191px; height:91px; display:inline-block; padding:6px; margin:21px; } #box4sides { -webkit-border-radius:6px; -moz-border-radius:6px; border-radius:6px; -moz-box-shadow:0 0 2px 2px Chartreuse; -webkit-box-shadow:0 0 2px 2px yellow; box-shadow:0 0 2px 2px blue; background:white; border:2px solid pink; } #box3sides { background:white; left:-8px; height:91px; box-shadow:2px 2px 2px 0px OrangeRed, 2px -2px 2px 0px grey; -webkit-border-top-right-radius:6px; -webkit-border-bottom-right-radius:6px; -moz-border-radius-topright:6px; -moz-border-radius-bottomright:6px; border-top-right-radius:6px; border-bottom-right-radius:6px; border-top:2px solid BlueViolet; border-right:2px solid Chartreuse; border-bottom:2px solid yellow; } body { background:lightYellow; padding:11px; } </style> </head> <body> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi ullamcorper molestie lacus sed fermentum. Aliqu <br>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi ullamcorper molestie lacus sed fermentum. Aliquam erat volutpat. Vestibul <br> <div id="box4sides" class="box"> Lorem ipsu </div> <div class="box"> <div id="box3sides"> Lorem ipsum dolor sit amet, consectetur adipiscing </div> </div> </body> </html>