For law school GPA and LSAT are the most important. If you are going outside of the big prestige law schools, there is significant benefit in attending law school in the state where you would like to practice law, in terms of bar preparation, law firm on-campus interviewing and networking, etc.
That said, it doesn’t really matter where you do undergrad, as long as you do well there, but even if cost were not an issue, law school is incredibly expensive, so spending less on undergrad may make some sense.
(I am a lawyer that majored in History and it prepared me very well. As a History major all of my exams were essay and my upper level classes all had paper requirements. I ended up writing more than my English major friends. It was very good preparation for what I do now.)