Ok, on the .paragraph
you want to add the following css:
display: block;
overflow: auto;
That tells the browser to make the element(s) block level so they fit within their parent, and to let the browser figure out what to do with anything that overflows the container. You will also need to remove the height
parameter if you want the browser to figure out the correct height with and without the scroll-bar.
To have the text wrap instead of overflowing you either need to remove the whitespace: no-wrap from the #wrap container since style cascade down through children or add:
white-space: normal;
and in both cases remove the:
overflow: auto;
from the .paragraph
selector
Here is a working jsFiddle: http://jsfiddle.net/D7suu/1/
Here is the updated jsFiddle: http://jsfiddle.net/D7suu/2/