The max-width property defines largest width that an element should have.
max-width: <length> | <percentage> | none | inherit
- <length>
The width is defined by a fixed measure. - <percentage>
The width is defined by a percentage of the containing block's width. - none
No limit on the width of the box. - inherit
The element should have the same max-width setting as the parent.
none
All elements but non-replaced inline elements, table rows, and row groups.
This property is not inherited.
- Visual
A paragraph with a max-width
<p style="max-width: 100px;">
This paragraph will not be more than 100 pixels wide.
</p>
- Internet Explorer 6 does not support this property.
- Make sure you define the overflow property if you want the contents to be clipped from an element that is larger than expected.
- Also remember that setting limits on the size of elements can cause accessibility problems.

