CSS Guide
CSS - Cascading Style Sheets
CSS defines how HTML elements are displayed.
CSS describes the visual style (appearance, layout, color, font) of HTML elements.
CSS is a separately designed file (which greatly improves HTML flexibility and reduces HTML complexity).
CSS is simple and easy to learn. You can treat an HTML element as a selector and list style properties within curly braces.
CSS example
body
{
background-color
:
#d0e4fe
;
}
h1
{
color
:
orange
;
text-align
:
center
;
}
p
{
font-family
:
"Times New Roman"
;
font-size
:
20px
;
}
Try it »
Click the "Try it yourself" button to view the online example.
Stylesheets greatly improve work efficiency.
Stylesheets define how HTML elements are displayed; font tags and color attributes in HTML 3.2 styles are typically stored in external .css files.
By editing just a simple CSS document, external stylesheets let you change the appearance of all page layouts across the site at once.
By allowing simultaneous control of the style and layout of multiple pages, CSS is a breakthrough in web design. As a web developer, you can define styles for each HTML element and apply them to as many pages as you wish. For a global change, simply change the style and all elements on the site are updated automatically.
How to learn CSS?
Study our Complete CSS tutorial
Study our Complete CSS reference manual