Red and green are strongly associated with "error" and "confirmation" so I was wondering wheither it is okay to use those colors for elements which are not neccessarily notification/feedback items, like headlines, buttons etc. Is there any best practise when to avoid those colours?
As long as they are used consistently and fit within the visual design of whatever you are working on then it shouldn't be a problem. But use your judgement, if it looks wrong it probably is. Be aware if you have used a lot of red/green then it will be hard to use these colours to distinguish error messages, primary calls to action etc.
Personally I wouldn't overuse either of the colours as there are a lot of people who have issues with red green colour blindness: http://www.colour-blindness.com/variations/red-green/
Also its important to note, that for accessibility reasons, you should avoid using colour as the sole method to communicate. WCAG 2.0 - 1.4.1