One of the use-cases that you mention (headings should not be at the end of a page) is surprisingly difficult to pull off with CSS alone.
I am currently experimenting with some ways to achieve this in my "Ad Hominem" template, but this is still in development versions only, and it still needs some fine-tuning.
Short of using my template, the best you can probably do is assign some special CSS classes and manually mark the headings that should go to the next page with those. That's a lot of manual tinkering, though...