I went to law school knowing that I would not practice law but was interested in academia, hence the reason why I am currently in a PhD program. Like you, my undergrad grades were good but my law school grades were not. I was accepted by a number of schools, so it does not seem to weaken one's application. However, your statement of purpose needs to be extremely strong because you need to prove that you are interested in scholarship/research and not someone who realized that the practice of law is not desirable. Furthermore, graduate school is "more costly" than a non-traditional legal career (more costly, meaning you either are unfunded or you are funded and receive a small stipend but forego gainful employment for a number of years).