CSS stands for Cascading Style Sheets and are one of the 3 main components of a modern web page (HTML and JavaScript being the others). CSS is used to specify colors, positions, fonts, and other visual design of a web page.
CSS can be included in HTML in 3 different ways:
<div style="color: red; font-size: 100px">Big Red</div>
<style> div { color: red; font-size: 100px } </style>
<link rel="stylesheet" href="style.css" type="text/css">
Styles can apply to entire tags such as all "div" tags:
<style> div { color: red; font-size: 100px } </style> <div>Hi</div>or only to tags with a specific "class":
<style> .bigred { color: red; font-size: 100px } </style> <div class="bigred">Hi</div>or to only a tag with a specific ID:
<style> #bigred { color: red; font-size: 100px } </style> <div id="bigred">Hi</div>
CSS has a rich support for type or text formatting. Here are a few of the capabilities:
font-family: Times, serif; - Web Safe Fonts
Elements can be positioned in a number of ways in CSS.
A class of CSS layouts has appeared called grids. These are starting points for grid based layouts and easier to use that building from scratch. One of the most well known is the 960 Grid which is a 960 pixel wide grid based layout.
To use it, you download and included it on your page:
<link rel="stylesheet" type="text/css" href="960_12_col.css" />The above version is the 12 column version.
You specify in your block elements how many columns they should occupy in any given row:
<div class="container_12 clearfix"> <div class="grid_12">All 12 Columns</div> <div class="grid_4">4 Columns</div> <div class="grid_3">3 Columns</div> </div>
HTML & CSS by Jon Duckett is a fantastic book that takes you through a lot of how to work with HTML and CSS to make sites look the way you want. I highly recommend it.