一、在样式表开头添加一个注释块
代码如下:


Example Source Code:
/*
---------------------------------
Site: Site name
Author: 52CSS.com
Updated: Date and time
Updated by: Name
---------------------------------
*/

二、包括公用颜色标记
代码如下:


Example Source Code:
/*
---------------------------------
COLORS
Body background: #def455
Container background: #fff
Main Text: #333
Links: #00600f
Visited links: #098761
Hover links: #aaf433
H1, H2, H3: #960
H4, H5, H6: #000
---------------------------------
*/

三、给ID和Class进行有意义的命名
代码如下:


.green-box { ... }
# big - text {... }

it is recommended to use the naming convention:
Example Source Code:

  Code is as follows:  


pullquote {... # the introduction {...}
}

4, will be the associated style rules to combine
code is as follows:


# header {... }
# header h1 {... }
# header h1 img {... }
# header of the form {... }
# header # skip {... }
# navigation {... # navigation ul {...}
}
# navigation ul li {... }
# navigation ul li a {... # navigation ul li}
a: hover {... }
# content {... # the content h2 {...}
# the content p {...}
# the content ul {...}
}
# content ul li {... }

5, add clear comments to style
code is as follows:


/* -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
header styles
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -/

* # header {... }
# header h1 {... }
# header h1 img {... }
# header of the form {... }

/* -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
navigation styles
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -/

* # navigation {... }


This concludes the body part