bugl
bugl
HomeLearnPatternsSearch
HomeLearnPatternsSearch

Loading lesson path

Learn/CSS

CSS

CSS Foundations Practice

Exercises, quizzes, examples, and short drills that reinforce css foundations.

Lesson 1

CSS Grouping Selectors

The CSS Universal Selector The universal selector (*) selects all HTML elements on the page. Example The CSS rule below will affect every HTML element on the page: * { text-align: center; color: blue…

2 min
Read lesson →
Lesson 2visual

CSS Selectors Code Challenge

Challenge: Group Headings and Paragraphs Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 3visual

How To Add Internal CSS

Internal CSS An internal style sheet may be used if one single HTML page has a unique style. The internal style is defined inside the <style> element, inside the head section. Example Internal styles…

2 min
Read lesson →
Lesson 4

CSS How To Code Challenge

Challenge: How To Add CSS Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 5

CSS Colors Code Challenge

Challenge: Colors Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 6

CSS Background Image

CSS background-image The background-image property specifies an image to use as the background of an element. By default, the image is repeated so it covers the entire element. Example Set the backgr…

2 min
Read lesson →
Lesson 7

CSS Background Attachment

CSS background-attachment The background-attachment property specifies whether the background image should scroll or be fixed (will not scroll with the rest of the page): Example Specify that the bac…

2 min
Read lesson →
Lesson 8

CSS Backgrounds Code Challenge

Challenge: Backgrounds Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 9

CSS Border Sides

CSS Border - Individual Sides From the examples on the previous pages, you have seen that it is possible to specify a different border for each side. In CSS, there are also properties for specifying…

2 min
Read lesson →
Lesson 10

CSS Rounded Borders

CSS Rounded Borders The border-radius property is used to add rounded borders to an element: Normal border Round border Rounder border Roundest border Example p { border: 2px solid red; border-radius…

2 min
Read lesson →
Lesson 11

CSS Borders Code Challenge

Challenge: Borders Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 12

CSS Margins Code Challenge

Challenge: Margins Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 13

CSS Padding Code Challenge

Challenge: Padding Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 14

CSS Height and Width Code Challenge

Challenge: Height/Width Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 15

CSS Box Model Code Challenge

Challenge: Box Model Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 16visual

CSS Outline Offset

CSS Outline Offset The outline-offset property adds a space between an outline and the edge/border of an element. The space between an element and its outline is transparent. The following example sp…

2 min
Read lesson →
Lesson 17

CSS Outline Code Challenge

Challenge: Outline Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 18

CSS Text Code Challenge

Challenge: Text Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 19

CSS Fonts Code Challenge

Challenge: Fonts Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 20

CSS Icons Code Challenge

Challenge: Icons Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 21visual

CSS Links

CSS Styling Links HTML links can be styled with many CSS properties, like color, text-decoration, background-color, font-size, font-weight, font-family, etc.). Example Style a link with a color, back…

2 min
Read lesson →
Lesson 22

CSS Link Buttons

CSS Link Buttons CSS can be used to create HTML link buttons: Link Button Link Button Example Combine several CSS properties to display links as boxes/buttons a:link, a:visited { background-color: #f…

2 min
Read lesson →
Lesson 23

CSS Links Code Challenge

Challenge: Links Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 24

CSS Lists Code Challenge

Challenge: Lists Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 25

CSS Tables Code Challenge

Challenge: Tables Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 26

CSS Display Code Challenge

Challenge: Display Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 27

CSS Max-width Code Challenge

Challenge: Max-width Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 28

CSS Position Code Challenge

Challenge: Position Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 29

CSS Position Offsets Code Challenge

Challenge: Position Offsets Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 30

CSS Z-index Code Challenge

Challenge: Z-index Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 31

CSS Overflow Code Challenge

Challenge: Overflow Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 32

CSS Float Examples

CSS Float Examples

3 min
Read lesson →
Lesson 33

CSS Float Code Challenge

Challenge: Float Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 34

CSS Inline-block Code Challenge

Challenge: Inline-block Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 35

CSS Align Code Challenge

Challenge: Align Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 36

CSS Combinators Code Challenge

Challenge: Combinators Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 37

CSS Pseudo-classes Code Challenge

Challenge: Pseudo-classes Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 38

CSS Pseudo-elements Code Challenge

Challenge: Pseudo-elements Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 39

CSS Opacity Code Challenge

Challenge: Opacity Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 40

CSS Navbar Code Challenge

Challenge: Navbar Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 41

CSS Dropdowns Code Challenge

Challenge: Dropdowns Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 42

CSS Image Gallery Code Challenge

Challenge: Image Gallery Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 43

CSS Image Sprites Code Challenge

Challenge: Image Sprites Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 44

CSS Attribute Selectors Code Challenge

Challenge: Attribute Selectors Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 45

CSS Form Styling Code Challenge

Challenge: Form Styling Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 46

CSS Nested Counters

CSS Using Two Counters You can create multiple counters for different levels of numbering. The following example creates one counter for the page (named "section") and one counter for each <h1> eleme…

2 min
Read lesson →
Lesson 47

CSS Counters Code Challenge

Challenge: Counters Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 48

CSS Units Code Challenge

Challenge: Units Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 49

CSS Inheritance Code Challenge

Challenge: Inheritance Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 50

CSS Specificity Hierarchy

Specificity Hierarchy Each type of CSS selector has a position in the specificity hierarchy, and the selector types carry different "weights". Selector Example Description Weight Inline styles <h1 st…

2 min
Read lesson →
Lesson 51

CSS Specificity Code Challenge

Challenge: Specificity Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 52

CSS !important Code Challenge

Challenge: !important Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 53

CSS Math Functions Code Challenge

Challenge: Math Functions Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 54

CSS Optimization Code Challenge

Challenge: Optimization Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 55

CSS Accessibility Code Challenge

Challenge: Accessibility Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →
Lesson 56

CSS Website Layout Code Challenge

Challenge: Website Layout Test your understanding of CSS by completing a small coding challenge.

2 min
Read lesson →