This course will be retired on July 12, 2021. We recommend "CSS Basics" for up-to-date content.
Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
Start a free Courses trial
to watch this video
With the box-sizing property, we can alter the way the browser calculates an element's total width and height. We're also able to set the maximum width of an element with the max-width property.
Quick Reference
box-sizing
Alters the default CSS box model used to calculate widths and heights of elements.
max-width
Sets the maximum width of an element. It prevents the used value of the width property from becoming larger than the value set for max-width.
Related Articles
You need to sign up for Treehouse in order to download course files.
Sign up