Web

HTML & CSS

HTML describes the structure of a page; CSS controls how it looks. Together they are the foundation every website is built on.

HTML elements

An element is a tag with content. Tags nest to form a tree.

<article>
  <h1>Title</h1>
  <p>A paragraph of text.</p>
</article>

CSS basics

A CSS rule selects elements and sets properties.

p {
  color: #333;
  line-height: 1.6;
}

Layout

Modern layouts use Flexbox and Grid to arrange elements responsively, so the page adapts from phones to desktops.