Target-a-browser 1.2

Attribute (to be used in this order)Moz/KHTMLIE5/MacIE5/WinIE6/WinOP5OP6OP7
p { color: blue; }blueblueblueblueblueblueblue
@media not foo { html p { color: green; } } ¹bluebluebluebluebluebluegreen
p { color: purple; }purplepurplepurplepurplepurplebluegreen
* html p { color: maroon; }purplemaroonmaroonmaroonpurplebluegreen
* html p { co\lor: red; }purpleredmaroonredpurplebluegreen
html > body p { color: orange; } ²orangeorangemaroonredpurplebluegreen
* html > body p { color: yellow; }orangeyellowmaroonredpurplebluegreen

→ If you see this text, and many others below, you're probably running IE 4 or Netscape 4 and this text is black

→ If this works, you're running Opera 7 and this text is green

→ If this works, you're running Opera 6 and this text is blue

→ If this works, you're running Opera 5 and this text is purple

→ If this works, you're running IE 6 and this text is red

→ If this works, you're running IE 5 and this text is maroon

→ If this works, you're running IE 5/Mac and this text is yellow

→ If this works, you're running Mozilla, Firebird, Netscape 6+, Camino, Safari or Konqueror and this text is orange

¹ Below this, all rules will be ignored by Opera 6+.
² Note the spaces surrounding the child selector (>) making it "Opera-unfriendly".

Please report typos or corrections, or just send a comment.
Many kudos to helpful members of css-discuss, you know who you are.