Effective field theory of hairy black holes and their flat and de Sitter limits