CSS Tutorial
The language we use to style and lay out web pages. Learn it step by step with 67 short lessons, live code examples and 335 quiz questions.
67
lessons
335
quiz questions
5
sections
What you'll learn in this CSS tutorial
Every topic ends with a short quiz — score 70% to unlock the next one.
CSS Tutorial · 41 lessons
- 1. CSS Introduction What CSS is and why we use it.
- 2. CSS Syntax Selectors, properties and values.
- 3. CSS Selectors Element, id, class, universal and grouping selectors.
- 4. CSS How To External, internal and inline CSS, and cascading order.
- 5. CSS Comments Explain your CSS with comments.
- 6. CSS Colors Text, background and border colors.
- 7. CSS Backgrounds Background colors, images, repeat, position and attachment.
- 8. CSS Borders Border style, width, color and radius.
- 9. CSS Margins Space outside an element's border.
- 10. CSS Padding Space inside an element's border.
- 11. CSS Height / Width Set element size, with min and max limits.
- 12. CSS Box Model Content, padding, border and margin.
- 13. CSS Outline A line drawn outside the border.
- 14. CSS Text Alignment, decoration, transformation and spacing.
- 15. CSS Fonts Font families, sizes, weights and Google Fonts.
- 16. CSS Icons Add icons with icon fonts or inline SVG.
- 17. CSS Links Style links in their different states.
- 18. CSS Lists List markers, images and positions.
- 19. CSS Tables Borders, collapse, striped and hoverable tables.
- 20. CSS Display block, inline, inline-block and none.
- 21. CSS Max-width Use max-width for flexible layouts.
- 22. CSS Position static, relative, fixed, absolute and sticky.
- 23. CSS Z-index Control the stacking order of elements.
- 24. CSS Overflow What happens when content is too big.
- 25. CSS Float float and clear.
- 26. CSS Inline-block Inline elements that accept width and height.
- 27. CSS Align Center elements horizontally and vertically.
- 28. CSS Combinators Descendant, child, adjacent and general sibling selectors.
- 29. CSS Pseudo-classes :hover, :focus, :first-child, :nth-child and more.
- 30. CSS Pseudo-elements ::before, ::after, ::first-letter and more.
- 31. CSS Opacity Transparency of elements.
- 32. CSS Navigation Bar Build vertical and horizontal nav bars from lists.
- 33. CSS Dropdowns Hoverable dropdown menus with pure CSS.
- 34. CSS Attribute Selectors Select elements by attributes and values.
- 35. CSS Forms Style inputs, textareas, selects and buttons.
- 36. CSS Counters Automatic numbering with CSS variables-like counters.
- 37. CSS Website Layout Header, navigation, content and footer.
- 38. CSS Units Absolute and relative lengths: px, em, rem, %, vw, vh.
- 39. CSS Specificity Which rule wins when several match.
- 40. CSS !important Override all previous styling rules.
- 41. CSS Math Functions calc(), min(), max() and clamp().
CSS Advanced · 17 lessons
- 42. CSS Rounded Corners border-radius for rounded boxes and circles.
- 43. CSS Gradients Linear, radial and conic gradients.
- 44. CSS Shadows text-shadow and box-shadow.
- 45. CSS Text Effects text-overflow, word-wrap and writing-mode.
- 46. CSS Web Fonts @font-face and Google Fonts.
- 47. CSS 2D Transforms translate, rotate, scale and skew.
- 48. CSS 3D Transforms rotateX, rotateY and perspective.
- 49. CSS Transitions Change property values smoothly.
- 50. CSS Animations @keyframes and animation properties.
- 51. CSS Tooltips Show extra information on hover.
- 52. CSS Object-fit Fit images and videos into their box.
- 53. CSS Buttons Style button colors, sizes, borders and hover effects.
- 54. CSS Pagination Style page number links.
- 55. CSS Multiple Columns Newspaper-style text columns.
- 56. CSS Variables Custom properties with var().
- 57. CSS Box Sizing content-box vs border-box.
- 58. CSS Media Queries Apply styles for different devices and sizes.
CSS Flexbox · 3 lessons
CSS Grid · 3 lessons
Ready to learn CSS?
Create your account, unlock every lesson and quiz, earn points on the leaderboard and join our in-person classes.
Create free account