CSS is used to style and beautify HTML elements. CSS references HTML elements by their name, id, or class and allows assigning visual attributes like colors, backgrounds, borders, positioning and more. There are three main types of CSS references: elements, classes, and ids. CSS declarations specify visual attributes and behaviors for referenced HTML elements.