A dot (.) always precedes declration of a style-class. It helps to define any style which in turn can be applied to HTML5 content. These concepts are shown in detail in the next example.
Any style defined by the author takes precedence over styles defined by the user, and also user over user agent.
Styles declared for parent elements are inherited by child elemenet.
See for example, the child em inherits from its parent.
The rendered code on the browser is viewed as shown below:
===========================================================
The code is here to try out
===========================================================<html>==========================================================================================================
<head>
<title> CSS3 </title>
<style type = "text/css">
body {font-family: arial, sans-serif;} a:hover {background-color: red; } li {font-weight: bold;} h2, em {font-family: arial, sans-serif; text-decoration: underline;} p {font-family: calibri; sans-serif; font-size: 20px;} ol {font-size: 14px;} </style>
</head>
<body>
<h2> List of Courses offered online are: </h2>
<ol>
<li>HTML</li>
<li>JavaScript</li>
<li>CSS</li>
</ol>
<p> <a class = "hover" href = "http://www.google.com">
Online Course </a>
</p>
</body>
</html>