Back to CSS Tips
Preview: what the working site looks like.










Valid HTML 5.0 Valid CSS!
The markup
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Untitled Document</title>
</head>
<body>  
    <div id="container">
		<hr class="zero" />
		<hr class="one" />
		<hr class="two" />
		<hr class="three" />
		<hr class="four" />
		<hr class="five" />
		<hr class="six" />
		<hr class="seven" />
		<hr class="eight" /> 
		<hr class="nine" />
    <!--container--></div>  
</body>
</html>
        
The CSS
html, body {
	margin: 0;
	font: 100% "Trebuchet MS", Arial, Helvetica, sans-serif;
	color: #000;
	background: #fc6;
}
#container {
	width: 800px;
	margin: 0 auto;
	padding: 75px 10px;
	background: #f63;
}
hr { margin: 25px auto 0; }
hr.zero {
	width: 400px;
	border-top-width: 4px;
	border-top-style: groove;
	border-top-color: #FF0000;
}
hr.one {
	height: 12px;
	width: 75%;
	border-top: solid 6px #ffffff;
	border-bottom: solid 6px #888888;
	border-left: solid 5px #888888;
	border-right: solid 5px #333333;
}
hr.two {
	height: 4px;
	width: 70%;
	background: #ffffff;
	border-top-width: 1px;
	border-right-width: 2px;
	border-bottom-width: 3px;
	border-left-width: 1px;
	border-top-style: solid;
	border-right-style: solid;
	border-bottom-style: solid;
	border-left-style: solid;
	border-top-color: #00FF00;
	border-right-color: #333333;
	border-bottom-color: #666666;
	border-left-color: #00ff00;
	color: #ffffff;
}
hr.three {
	height: 8px;
	width: 90%;
	color: #FF0000;
	background: green;
	border-top: solid 2px #cccccc;
	border-bottom: solid 2px #000000;
	border-left: solid 2px #888888;
	border-right: solid 2px #333333;
}
hr.four {
	height: 4px;
	width: 100%;
	border-top-width: 2px;
	border-bottom-width: 2px;
	border-top-style: dashed;
	border-bottom-style: dotted;
	border-top-color: #000099;
	border-bottom-color: #FF0000;
}
hr.five {
	height: 50px;
	width: 80%;
	text-align: center;
	color: #ff0000;
	background: red;
	border-top-width: 24px;
	border-right-width: 10px;
	border-bottom-width: 24px;
	border-left-width: 10px;
	border-top-style: solid;
	border-right-style: solid;
	border-bottom-style: solid;
	border-left-style: solid;
	border-top-color: #ffffff;
	border-right-color: #ff0000;
	border-bottom-color: #999999;
	border-left-color: #ff0000;
}
hr.six {
	height: 20px;
	width: 80%;
	color: #ff0000;
	background: red;
	border-top-width: 8px;
	border-right-width: 80px;
	border-bottom-width: 8px;
	border-left-width: 80px;
	border-top-style: solid;
	border-right-style: solid;
	border-bottom-style: solid;
	border-left-style: solid;
	border-top-color: #999999;
	border-right-color: #ff0000;
	border-bottom-color: #ffffff;
	border-left-color: #ff0000;
}
hr.seven {
	height: 50px;
	width: 70px;
	border-top-width: 20px;
	border-right-width: 35px;
	border-bottom-width: 30px;
	border-left-width: 35px;
	border-top-style: solid;
	border-right-style: solid;
	border-bottom-style: solid;
	border-left-style: solid;
	border-top-color: #ff0000;
	border-right-color: #ffff00;
	border-bottom-color: #00ffff;
	border-left-color: #00ff00;
}
hr.eight {
	height: 12px;
	width: 80%;
	border-top: solid 6px #99d2ef;
	border-bottom: solid 6px #0e6d9e;
	border-left: solid 5px #1885be;
	border-right: solid 5px #1885be;
}
hr.nine {
	width: 90%;
	border-top: 1px solid #000;
	border-bottom: none;
}