Introduction to CSS

Introduction to CSS and Colors

Adding life and style to your webpages

Learning Objectives

What is CSS?

CSS (Cascading Style Sheets) is a language used to control the look and feel of a webpage. While HTML defines the content, CSS is responsible for how that content is presented—such as colors, spacing, fonts, and layout.

Watch the video below for a basic introduction to CSS created just for you:

How to Apply CSS

CSS can be applied in three main ways:

The video below explains CSS basics and how to apply styles using these methods:

CSS and Colors

Colors help communicate emotion, emphasis, and branding. CSS lets you control colors in several ways:

Watch the video below for a simple yet effective explanation of CSS colors:

Deep Dive: Hexadecimal Colors

HEX codes are six-digit codes that represent colors using hexadecimal values. They're commonly used in modern web design because they're compact and widely supported.

Watch this helpful video that explains how hexadecimal color codes work in CSS:

Try It Yourself: CSS Colors

Create a simple HTML file and add CSS (inline or internal) to:

Save and preview your work in a browser.

Further Reading

References