My Reset CSS

by Michael Plant ~ July 26th, 2008. Filed under: CSS Snippets.

This is an adapted version of Eric Meyer’s reset without going overboard. It includes miscellaneous conveniences to give a good start on any website. I use this code snippet to begin all of my main screen css files for any new build. Take a look here is the whole reset.

/* I know.. but heres the reset: way better than an asterisk: */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, font, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td {
	margin: 0;
	padding: 0;
	border: 0;
	outline: 0;
	font-weight: inherit;
	font-style: inherit;
	font-size: 100%;
	font-family: inherit;
	vertical-align: baseline;
}
body {
	font:68% Georgia,serif;
	color:#464646;
}
a img {
	border:0;
}
/* Standardize styling:
   Elements with a vertical margin: */
h1, h2, h3, h4, h5, h6, p, pre,
blockquote, ul, ol, dl, address {
        margin:1em 0;
        padding: 0;
}

/* Apply left margin:
   Only to the few elements that need it: */
li, dd, blockquote {
        margin-left: 1em;
}
/* Miscellaneous conveniences: */
form label {
        cursor: pointer;
}
fieldset {
        border: none;
}
input, select, textarea {
        font-size: 100%;
		font-family: inherit;
}
em {
	font-style:italic;
}
strong {
	font-weight:bold;
}
/* Custom styles:
	ordered by syntax hierarchy */

2 Responses to My Reset CSS

  1. Alex

    Your blog is interesting!

    Keep up the good work!

  2. Michael Plant

    Thanks Alex,

    I actually have an updated version if you intend to use it. I found some inconsistencies with some of the inherited attributes.

    If you tried it out let me how it worked for you?

Leave a Reply