Identifying Selectors

A selector is the element, or group of elements, to which a style will be applied. Selectors can be individual elements, lists of like elements, or specific instances of elements identified by class or ID attributes. In this next section, we'll look at selectors of each type.

Elements as Selectors

Using an element as a selector is pretty straightforward. The style rule is written by giving the element (selector), followed by the property or properties and values bound within braces: