In other words, margin is basically for the whole thing. Now it's just a matter of figuring out which one's more appropriate, but I guess in the end they're both valid and essentially do the same thing, so it doesn't really matter. Please correct me if I'm wrong, though.
Edit: Thanks, Brogan! I'll be sure to look at that.
Mr. Lucky, that's a good way of remembering it since I assume you're referring to a literal border. Use margin if targeting outside the border and padding if targeting within the border. Although I can see that potentially being tricky sometimes since what you think may be outside of the border could actually be within the border and vice-versa.