Skip to content

CSS3 Introduction

CSS (Cascading Style Sheets) is the language used to describe the presentation of web pages. What was once referred to as "CSS3" is now simply considered modern CSS, as the language evolves continuously.
Modern CSS is designed to be backwards-compatible, meaning newer features generally don't break styles written for older CSS versions.
This section introduces key concepts and capabilities of contemporary CSS.

Instead of large version numbers like CSS3, CSS development is now organized into modules. Each module focuses on a specific feature set (e.g., colors, backgrounds, layout) and evolves independently.

This modular approach allows CSS to grow incrementally, with new features being added regularly.

Some foundational and important CSS modules include:

  • Selectors: Advanced ways to target HTML elements.
  • Box Model: Controlling element size, padding, border, and margin.
  • Backgrounds and Borders: Styling element backgrounds and borders.
  • Colors and Values: Defining colors (including transparency), units, etc.
  • Text Effects: Typography, text alignment, spacing, shadows.
  • Layout: Techniques for arranging elements on the page, notably:
    • Flexbox (Flexible Box Layout): For one-dimensional layouts (rows or columns).
    • Grid Layout: For two-dimensional layouts (rows and columns).
  • Transforms: Applying 2D and 3D rotations, scaling, skewing, and translations.
  • Transitions & Animations: Creating smooth visual changes and complex animations.
  • User Interface: Styling form elements and UI components.
  • Media Queries: Applying different styles based on device characteristics (like screen size).

Most features defined in CSS Levels 3 and beyond are well-supported across modern, evergreen browsers (like Chrome, Firefox, Safari, Edge).

Newer CSS features might have varying levels of support initially. Developers often use resources like:

  • MDN Web Docs (Mozilla Developer Network): Comprehensive documentation on CSS properties and browser compatibility.
  • Can I use…: A website dedicated to tracking browser support for web technologies.

CSS is standardized by the World Wide Web Consortium (W3C). As modules mature, they become official W3C Recommendations, signaling stability and wide implementation.

The continuous evolution of CSS provides web developers with powerful tools to create sophisticated, responsive, and visually appealing user interfaces.