Rewrite docs for context locals, request contexts, and app contexts

Closes #1151.

The following is an incomplete draft. However, I wanted to request comments immediately, in case anything was severely wrong.

The doc should be updated to include:

- [ ] How context-local objects in Flask are implemented

Will squash commits later.
That is not strictly true (you can create appctx manually), but I am not sure whether the intro should be changed because of this -- currently it's a good intro which is leaving out some details for the sake of easier understanding.