After reading the question What is the impact of showing the amount of unattended notifications to the user, it occurred to me that many notifications (certainly not all) are red, two examples being inbox messages here (SE) and any notification on Facebook. Whereas, some notifications on StackExchange are in light blue (eg for badges and edits). Green is often associated with check-mark notifications (such as on my AVG virus scan and as the accepted answer here).
(Anecdotal side note: I sometimes get the feeling "oh what have I done this time" when the red notification shows here and a "oh goody!" when the blue shows up).
There are many examples of different colours being used for different types of notifications. What is the psychological basis of these notification colours?