How do I get the width of this inner content div to be equal to the width of the scrollable area?
-
You can't if you're going to set the outer div to be width 300px. It's the unbroken text breaking the bounding box. You can, however, wrap the word by adding this to the content CSS:
word-wrap: break-word;
However, if that 300px doesn't matter to you, you can move the overflow: auto from the scrollable class to the content one, and that, too, should fix the background issue.