March 2004
Intermediate to advanced
528 pages
16h 33m
English
margin
This shorthand property sets the width of the overall margin for an element or sets the widths of each individual side margin. Vertically adjacent margins of block-level elements are collapsed, whereas inline elements effectively do not take top and bottom margins. The left and right margins of inline elements do not collapse, nor do margins on floated elements. Negative margin values are permitted, but caution is warranted.
[ <length> | <percentage> | auto
]{1,4} | inherit
not defined
all elements
no
refer to the width of the containing block
see individual properties