Created
April 30, 2014 19:53
-
-
Save markleyland/11436637 to your computer and use it in GitHub Desktop.
CSS:multi-coloured-borders
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
body{ | |
background: #d2d1d0; /* Change this to suite project*/ | |
} | |
#box{ | |
background: #f4f4f4; | |
border: 1px solid #bbbbbb; | |
width: 200px; | |
height: 200px; | |
margin: 60px auto; | |
position: relative; | |
} | |
#box:before{ | |
border: 1px solid #ffffff; | |
content: ''; | |
width: 198px; | |
height: 198px; | |
position: absolute; | |
} | |
/* Optional third border */ | |
#box:after{ | |
border: 1px solid #bbbbbb; | |
content: ''; | |
width: 196px; | |
height: 196px; | |
position: absolute; | |
left: 1px; | |
top:1px; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment