Escolar Documentos
Profissional Documentos
Cultura Documentos
- Wikipedia
Inline Styles Styles fall from one level of the document hierarchy
Linked Styles
Default browser style sheet
h3 { margin-bottom: 10px; }
1
Contextual Selectors IDs and Classes
Use more than one tag name in the selector to target Only a single instance of an ID may be used per
p { color: red; }
Selectors with IDs win over selectors with body { font-family: verdana, arial, helvetica, sans-
If the same property for the same tag is defined in h1 { font-family: serif; }
cascade hierarchy
body { font-family: verdana, arial, helvetica, sans- h1 { font-family: serif; font-size: 0.9em; font-style:
2
Text Properties Styling Links (Pseudo-Classes)
text-indent a:link
letter-spacing a:visited
word-spacing a:hover
text-decoration
a:active
text-align
line-height
text-transform
vertical-align
body { margin: 0; padding: 0; } p { margin: 10px; padding: 10px; border: 1px solid
3
Positioning Float Property
Relative Positioning
p.relative { position: relative; top: 20px; left: 30px; } #left { margin: 0; width: 200px; float: left; }
.clear { clear: both; } Stylin' with CSS: A Designer's Guide - Charles Wyke-Smith