attribute, spacepval, dash-val, value

Select based on attributes or list of attributes or value of an attribute.


class

.big {color:blue }

Type selectors target every instance of an element, class selectors select any HTML element that has a class attribute.


descendant

div > em, "p em"


following

h2 + h3 {margin: -1em; }

Select all occurrences of h3 which are places after h2.


#navigation { width: 12em; color: #333; }#navigation

Select any HTML element that has an ID attribute, regardless of their position in the document tree


p ~ ul

Selects every UL element that are preceded by a P element.


active, first-child, focus, hover, lang, link, visited


after, before, first-letter, first-line


type

em {color: blue; }

Type selectors will select any HTML element on a page that matches the selector, regardless of their position in the document tree. For example:

em {color: blue; }

This rule will select any <em> element on the page and color it blue.


universal

* {color: blue; }

Universal selector.