CSS Basics

$150.00 50% OFF Buy for $75.00
Difficulty: Beginner 17 lessons

The CSS fundamentals that make everything else make sense: selectors, specificity, the box model, and positioning, taught interactively.

Most people learn CSS backwards. They copy a snippet, it almost works, they add another rule, it fights the first one, and eventually they slap !important on everything and hope. I have watched that cycle for years, in students and in working developers who never got the fundamentals, and the fix is always the same: go back and actually learn how CSS decides which styles apply.

That is why this course spends a whole section on selectors and the cascade. Element, class, and ID selectors, then combinators and grouping, then specificity: the scoring system that settles every conflict between rules. It is 17 lessons total, and the specificity lesson is the one that pays rent forever, because once you can predict which rule wins, CSS stops feeling random. It starts feeling like a system, which is what it always was.

You write the code, the lesson checks it

This course is interactive. Each lesson has you writing CSS and checking your work, not passively watching. For this material specifically, that matters. Nobody learns the box model by hearing about it; you learn it by setting padding, watching the element grow, and figuring out why box-sizing changes the math. The course is structured so you hit those small realizations yourself, in order.

There is a second benefit to the format that I did not appreciate until I watched students use it: you cannot fake your way through. A video lets you nod along and believe you understood. An exercise that checks your selector tells you the truth immediately, and the truth arriving early is what keeps small gaps from becoming big ones.

From first rule to positioned elements

The path is deliberate. You start with what CSS is, the anatomy of a rule, and the three ways to add CSS to a page. Then selectors and the cascade. Then the visual layer: colors, backgrounds and gradients, text and fonts. Then the box model gets four lessons, including sizing, box-sizing, borders, radius, and shadows, because spacing is where beginner layouts quietly fall apart.

The last section covers the concepts that unlock real layouts: display values (block, inline, inline-block), the units that actually matter (px, %, em, rem, vw, vh), and positioning with relative, absolute, and fixed. The units lesson alone will save you future pain; knowing when rem beats px is one of those small decisions that quietly separates maintainable stylesheets from brittle ones.

It ends with a project: a profile card you build yourself. Spacing from the box model, borders and shadows, styled text, positioned elements, all pulled together into one component you could actually show someone.

Where this fits in the bigger picture

An honest note: this course stops before flexbox and grid, on purpose. Modern layout deserves more than a rushed lesson at the end of a basics course, so it gets its own course in Advanced CSS with Flexbox and CSS Grid. Take this one first; flexbox makes far more sense when display and the box model are already solid.

If you have not done the markup side yet, HTML Basics is the natural companion, and the two together cover the true entry point into front-end work. And when you want your styles to move, CSS Animation for Developers picks up right where this leaves off.

What you'll learn

  • Understand what CSS is and the anatomy of a CSS rule
  • Know the three ways to add CSS to a page and when each one is right
  • Use element, class, and ID selectors, plus combinators and grouping
  • Predict which styles win using specificity and the cascade
  • Style colors, backgrounds, gradients, text, and fonts
  • Control layout spacing with the box model, padding, border, margin, and box-sizing
  • Choose the right CSS units among px, %, em, rem, vw, and vh
  • Position elements with relative, absolute, and fixed, and build a profile card project
Curriculum

Course Curriculum

5 sections · 17 lessons

1

Getting Started with CSS

3 lessons
  1. What Is CSS?
  2. Anatomy of a CSS Rule
  3. Three Ways to Add CSS
2

Selectors and the Cascade

3 lessons
  1. Element, Class, and ID Selectors
  2. Combinators and Grouping
  3. Specificity and the Cascade
3

Colors, Backgrounds, and Text

3 lessons
  1. Colors in CSS
  2. Backgrounds and Gradients
  3. Styling Text and Fonts
4

The Box Model

4 lessons
  1. The Box Model
  2. Padding, Border, and Margin
  3. Sizing and box-sizing
  4. Borders, Radius, and Shadows
5

Display, Units, and Positioning

4 lessons
  1. Display: block, inline, inline-block
  2. CSS Units: px, %, em, rem, vw, vh
  3. Positioning: relative, absolute, fixed
  4. Project: Build a Profile Card

Before you start

  • Basic HTML. You should be able to read simple markup before styling it
  • Nothing else. The first lesson starts at what CSS actually is

Frequently asked questions

Do I need to know HTML first? +
Yes, at least the basics. CSS styles HTML, so you should be able to read simple markup before starting. If you are not there yet, the HTML Basics course gets you ready and pairs directly with this one.
What does interactive mean here? +
You write code in the lesson itself and your work gets checked, instead of only watching someone else type. For fundamentals like selectors and the box model, doing it yourself is the difference between recognizing CSS and being able to write it.
Why so much emphasis on specificity and the cascade? +
Because that is what actually confuses people. Most CSS frustration is a style not applying and not knowing why. Once you can predict which rule wins, debugging CSS stops feeling like luck.
What do I build? +
The course closes with a profile card project that uses what you learned: box model spacing, borders and shadows, text styling, and positioning, combined into one finished component.
Does this course cover flexbox and grid? +
No, on purpose. Those are modern layout systems and they deserve real treatment, so they live in the Advanced CSS with Flexbox and CSS Grid course. This course builds the foundation those systems sit on.
Is it included in Diamond, and is there a certificate? +
Yes to both. The course is included with the Diamond membership or available on its own, and you get a certificate of completion when you finish.
$365/y$182.50/yr · 50% off
Start your path →