Prevent child elements covering up inset shadow - HTML CSS CSS Property

HTML CSS examples for CSS Property:box-shadow

Description

Prevent child elements covering up inset shadow

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
.optn {<!--from   w  w w  . j av  a  2 s .c om-->
   font-family:Tahoma;
}

.optn-group {
   width:281px;
   margin:11px auto 11px;
   -webkit-border-radius:6px;
   -moz-border-radius:6px;
   border-radius:6px;
   background-color:Chartreuse;
   -webkit-box-shadow:inset 0px 3px 11px 0px yellow;
   -moz-box-shadow:inset 0px 3px 11px 0px blue;
   box-shadow:inset 0px 3px 11px 0px pink;
   overflow:auto;
}

.optn-group .optn {
   height:18px;
   padding:10px 11px;
   cursor:pointer;
   border-top:2px solid OrangeRed;
   border-bottom:2px solid grey;
}

.optn-group .optn:first-child {
   border-top:none;
}

.optn-group .optn:last-child {
   border-bottom:none;
}

.optn-group .optn:active {
   background:BlueViolet;
   color:Chartreuse;
}
</style> 
 </head> 
 <body> 
  <div class="optn-group"> 
   <div class="optn">
     Lorem ipsum 
   </div> 
   <div class="optn">
     Lorem ipsum dolo 
   </div> 
  </div>  
 </body>
</html>

Related Tutorials