For detective to go bad repelled The Guardian (9)
I believe the answer is:
'the guardian' is the definition.
'for detective to go bad repelled' is the wordplay.
'for' becomes 'pro' (as in being 'pro' something).
'detective' becomes 'tec' (synonyms).
'to go bad' becomes 'rot' (I've seen this before).
'repelled' is a reversal indicator.
'rot' back-to-front is 'tor'.
(Other definitions for protector that I've seen before include "Box at Lord's say" , "Patron" , "Guardian; regent" , "Defender" .)