Lesson 2, Topic 1
In Progress

CSS Basics

John May 20, 2019
Lesson Progress
0% Complete

Cascading Style Sheets, fondly referred to as CSS, is a simply designed language intended to simplify the process of making web pages presentable. CSS allows you to apply styles to web pages. More importantly, CSS enables you to do this independent of the HTML that makes up each web page.

A CSS comprises of style rules that are interpreted by the browser and then applied to the corresponding elements in your document.
A style rule set consists of a selector and declaration block.

  • The selector points to the HTML element you want to style.
  • The declaration block contains one or more declarations separated by semicolons.
  • Each declaration includes a CSS property name and a value, separated by a colon.For Example:
    -> color is property and blue is value.
    -> font size is property and 12px is value.
  • A CSS declaration always ends with a semicolon, and declaration blocks are surrounded by curly braces.