To me, Galaxy 1 is the one that has the best focus all around.
Not too much free roaming (there was too much of that in 64, even though it was fun at first, it became repetitive quite fast, and there was not enough in galaxy 2), a really good focus on actual platforming and reflexes through really good level design. Just think about the secret levels from Sunshine. Galaxy's prime inspiration seems to have been taken from those, and they are a godsend to me. The abilities were fun and varied, and the gravity really added depth to the already stellar platforming elements. All the while having one of the best setting in any Mario games (space).
All in all, Galaxy is my favorite Mario game ever. Galaxy 2 comes really close though. Like... 0.1 point behind.