Topic

CSS

CSS describes the presentation of documents such as HTML pages. Rules select elements and assign visual properties, including layout, spacing, color, and typography.

At a glance

Expansion
Cascading Style Sheets
Rule components
Selector and declarations

Overview

CSS describes the presentation of documents such as HTML pages. Rules select elements and assign visual properties, including layout, spacing, color, and typography. The cascade determines how applicable declarations combine when more than one rule targets an element.

Rules and the cascade

Selectors identify which elements a rule affects. Declarations assign property values, and the cascade resolves competing declarations using defined precedence. Understanding that process helps explain why an expected style is not applied.

Responsive presentation

Layout systems and conditional rules let presentation adapt to available space and user preferences. The underlying content still needs meaningful structure so that visual changes do not remove the page's essential information.

Sources and review

MOOR's explanatory text is supported by the following source links.

  1. CSS reference — MDN Web Docs
  2. Cascading Style Sheets overview — W3C

Browse MOOR Knowledge