I would give H1 and p CSS properties instead of div, as shown below. You can create a class only for borders and apply them to the corresponding element.
http://jsfiddle.net/QSp2W/7/
CSS
div h1 { padding: 2px; background-color: #ff0000; border-top: 2px solid #000000; border-left: 2px solid #000000; border-right: 2px solid #000000; border-top-left-radius: 10px; border-top-right-radius: 10px; } div p { padding: 10px; border-left: 2px solid #000000; border-right: 2px solid #000000; border-bottom: 2px solid #000000; border-bottom-left-radius: 10px; border-bottom-right-radius: 10px; }
This is with a separate border class: http://jsfiddle.net/QSp2W/9/
source share