In an embedded or linked style sheet, a selector is the markup you are altering the appearance of. There are several different selection methods, the simplest of which are shown below:

CSS Selector Syntax, CSS Levels 1 and 2
Universal or “wildcard” selector
* { margin: 0; }
For selecting every element in a document (or site-wide, if used in a linked style sheet). Commonly used for CSS resets to set all elements to the same default properties.
Single selector
p { color: green; }
To select a single tag.
Grouped selectors
h1, h2, h3 { color: red; }
To have multiple elements share the same style rule(s).
Descendant selector
ul li { font-weight: bold; }
Applies the style declaration that applies only to the last element if it is a descendant of the selector sequence. For the example shown, list items will be bold, but only if they are in the context of (i.e. descend from) a unordered list element. (list items elements in ordered lists will be unaffected)
Sibling selector
h2 ~ p { font-color: red; }
Selects all matching elements that follow at the level of the leading element
Adjacent selector
h2 + p { font-style: italic; }
Selects the element if it comes immediately after the one before it. In the example shown, the first paragraph immediately after an h2 element will be italicized. Other paragraphs outside of this context will be unaffected.
id selector
ul#nav { background: blue; }
Selects elements that have an id that matches the word following the pound sign. Note that this id must be unique to the page. (The same id can be used on multiple pages, but only once per page).
Class selector
p.special { color: red; }
Selects elements that have a class attribute with a value matching the word following the period in the selector. Classes may be used multiple times on a page, but should not be the majority of content associated with that element.
Attribute value selector
Applies only to tags in which an attribute has a particular value.

Enjoy this piece? I invite you to follow me at to learn more.