Created
May 16, 2012 08:15
-
-
Save christianhanvey/2708623 to your computer and use it in GitHub Desktop.
Page Curl Boxes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Matt Hamm's Page Curl Boxes · CodePen</title> | |
<link rel="stylesheet" href="http://codepen.io/stylesheets/css/reset.css"> | |
<style> | |
ul.box { | |
position: relative; | |
z-index: 1; | |
overflow: hidden; | |
list-style: none; | |
} | |
ul.box li { | |
position: relative; | |
float: left; | |
width: 250px; | |
height: 150px; | |
padding: 0; | |
border: 1px solid #efefef; | |
margin: 0 30px 30px 0; | |
background: #fff; | |
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset; | |
} | |
ul.box li:before, ul.box li:after { | |
content: ''; | |
z-index: -1; | |
position: absolute; | |
left: 10px; | |
bottom: 10px; | |
width: 70%; | |
max-width: 300px; | |
max-height: 100px; | |
height: 55%; | |
box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3); | |
transform: skew(-15deg) rotate(-6deg); | |
} | |
ul.box li:after { | |
left: auto; | |
right: 10px; | |
transform: skew(15deg) rotate(6deg); | |
} | |
body { | |
background: url(http://matthamm.com/images/noise.png); | |
padding: 20px; | |
} | |
h1 { | |
font: normal 36px Georgia, Serif; | |
margin: 0 0 20px 0; | |
text-shadow: 0 1px 0 rgba(255, 255, 255, 0.2); | |
} | |
</style> | |
<script src="http://codepen.io/javascripts/libs/prefixfree.min.js"></script> | |
</head> | |
<body> | |
<h1>Matt Hamm's Page Curl Boxes</h1> | |
<ul class="box" markdown="1"> | |
<li></li> | |
<li></li> | |
<li></li> | |
<li></li> | |
<li></li> | |
<li></li> | |
</ul> | |
</body> | |
</html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import "compass"; | |
ul.box { | |
position: relative; | |
z-index: 1; | |
overflow: hidden; | |
list-style: none; | |
li { | |
position: relative; | |
float: left; | |
width: 250px; | |
height: 150px; | |
padding: 0; | |
border: 1px solid #efefef; | |
margin: 0 30px 30px 0; | |
background: #fff; | |
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset; | |
&:before, | |
&:after { | |
content: ''; | |
z-index: -1; | |
position: absolute; | |
left: 10px; | |
bottom: 10px; | |
width: 70%; | |
max-width: 300px; | |
max-height: 100px; | |
height: 55%; | |
box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3); | |
transform: skew(-15deg) rotate(-6deg); | |
} | |
&:after { | |
left: auto; | |
right: 10px; | |
transform: skew(15deg) rotate(6deg); | |
} | |
} | |
} | |
body { | |
background: url(http://matthamm.com/images/noise.png); | |
padding: 20px; | |
} | |
h1 { | |
font: normal 36px Georgia, Serif; | |
margin: 0 0 20px 0; | |
text-shadow: 0 1px 0 rgba(255,255,255,0.2); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment