Two things I'd say to that.
Firstly, you've got to keep in mind that statistics about who wins election are obviously controlled by who runs. It's relatively rare that anyone who isn't already a familiar face gets the leadership position, let alone holds it through to an election, so it doesn't necessarily mean a lot that most people are well known. It is true however that many PMs lose an election before they win one, and it is certainly more difficult for a less known person to win, as you say. It is also more difficult for a long-term leader to keep winning though, so it works both ways.
Also, there's never been a candidate like Gillard before in a federal election, so you can't really say that she won't win because she's not an old, safe male. Personally, I think Australia's political climate is very well attuned to a female candidate atm, and she would almost certainly do well, particularly against someone who is seen as smarmy and heartless like Costello.
Secondly, the political situation in any country changes over time. It was assumed in the US that a non-protestant would never be elected to Presidential office, and for good reasons at the time, but it didn't stop Kennedy from being incredibly popular, and I doubt it would have any significant bearing on any Presidential campaign these days. Similar things apply to Australia. Elections are a very different business to 50 years ago, and I don't think the same rules apply at all.
I know a place where a royal flush
Can never beat a pair