Skip to content

Instantly share code, notes, and snippets.

@Ricardo-Diaz
Created November 5, 2012 04:07
Show Gist options
  • Save Ricardo-Diaz/4015261 to your computer and use it in GitHub Desktop.
Save Ricardo-Diaz/4015261 to your computer and use it in GitHub Desktop.
CSS: Box Shadow Right Lifted Corner
Effect 4 will lift the corner on the bottom right of the box.
The HTML
<div class="box effect4">
<h3>Effect 4</h3>
</div>
The CSS
.box h3{
text-align:center;
position:relative;
top:80px;
}
.box {
width:70%;
height:200px;
background:#FFF;
margin:40px auto;
}
/*==================================================
* Effect 4
* ===============================================*/
.effect4
{
position: relative;
}
.effect4:after
{
z-index: -1;
position: absolute;
content: "";
bottom: 15px;
right: 10px;
left: auto;
width: 50%;
top: 80%;
max-width:300px;
background: #777;
-webkit-box-shadow: 0 15px 10px #777;
-moz-box-shadow: 0 15px 10px #777;
box-shadow: 0 15px 10px #777;
-webkit-transform: rotate(3deg);
-moz-transform: rotate(3deg);
-o-transform: rotate(3deg);
-ms-transform: rotate(3deg);
transform: rotate(3deg);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment