Part II: CSS

.pagination {

display: inline-block;

}


.pagination a {

color: black;

float: left;

padding: 8px 16px;

text-decoration: none;

}


.pagination a.active {

background-color: #4CAF50;

color: white;

}


.pagination a:hover:not(.active) {background-color: #ddd;}


.pagination a {

border-radius: 5px;

}


.pagination a.active {

border-radius: 5px;

}


.pagination a {

transition: background-color .3s;

}

.pagination a {

border: 1px solid #ddd; /* Gray */

}

.pagination a:first-child {

border-top-left-radius: 5px;

border-bottom-left-radius: 5px;

}


.pagination a:last-child {

border-top-right-radius: 5px;

border-bottom-right-radius: 5px;

}

.pagination a {

margin: 0 4px; /* 0 is for top and bottom. Feel free to change it */

}

.pagination a {

font-size: 22px;

}

ul.breadcrumb {

padding: 8px 16px;

list-style: none;

background-color: #eee;

}


ul.breadcrumb li {display: inline;}


ul.breadcrumb li+li:before {

padding: 8px;

color: black;

content: "/\00a0";

}

Syntax

<!DOCTYPE html>

<html>

<head>

<style>

p {

color: red;

text-align: center;

}

</style>

</head>

<body>


<p>Hello World!</p>

<p>These paragraphs are styled with CSS.</p>


</body>

</html>

Element Selector

<!DOCTYPE html>

<html>

<head>

<style>

p {

text-align: center;

color: red;

}

</style>

</head>

<body>


<p>Every paragraph will be affected by the style.</p>

<p id="para1">Me too!</p>

<p>And me!</p>


</body>

</html>

Class Seletor for only <p> element

<!DOCTYPE html>

<html>

<head>

<style>

p.center {

text-align: center;

color: red;

}

</style>

</head>

<body>


<h1 class="center">This heading will not be affected</h1>

<p class="center">This paragraph will be red and center-aligned.</p>


</body>

</html>


Class Selector for all element

<!DOCTYPE html>

<html>

<head>

<style>

.center {

text-align: center;

color: red;

}

</style>

</head>

<body>


<h1 class="center">Red and center-aligned heading</h1>

<p class="center">Red and center-aligned paragraph.</p>


</body>

</html>

HTML Refer to 2 classes

<!DOCTYPE html>

<html>

<head>

<style>

p.center {

text-align: center;

color: red;

}


p.large {

font-size: 300%;

}

</style>

</head>

<body>


<h1 class="center">This heading will not be affected</h1>

<p class="center">This paragraph will be red and center-aligned.</p>

<p class="center large">This paragraph will be red, center-aligned, and in a large font-size.</p>


</body>

</html>

Universal Selector

<!DOCTYPE html>

<html>

<head>

<style>

* {

text-align: center;

color: blue;

}

</style>

</head>

<body>


<h1>Hello world!</h1>


<p>Every element on the page will be affected by the style.</p>

<p id="para1">Me too!</p>

<p>And me!</p>


</body>

</html>


Group Selector

<!DOCTYPE html>

<html>

<head>

<style>

h1, h2, p {

text-align: center;

color: red;

}

</style>

</head>

<body>


<h1>Hello World!</h1>

<h2>Smaller heading!</h2>

<p>This is a paragraph.</p>


</body>

</html>