Finer control of styling provided by the class and id attributes
- class
-
- Style rules can have a class selector
-
class selector is full stop followed by class name
- More than one class selector is allowed
- Can style each class individually
- id
-
- Style rules can have an id selector
-
id selector is # followed by the id value
- Allows unique styling of an element
<style type="text/css">
.classname {color: red}
p.classname {font-size: 16pt}
p#c1 {color: blue}
#c2 {color: green}
</style>