The earliest reference to Mary was at the beginning of humanity.
Gen 3:15 I will put enmities between thee and the woman, and thy seed and her seed: she shall crush thy head, and thou shalt lie in wait for her heel.
Notice that Jesus called Mary Woman at Cana which defines her as the New Eve. This is something the old wise guy misses.
This early reference does indeed seem to be about Mary in what I have read in the past from people of various denominations.
The part you may take a bit of care with is the translation using the he or she pronouns. How you choose to look at the translations may depend on what denomination you are following or are a part of.
Whatever the case, the point is that the verse seems to be about Mary and Jesus.
Most translations I have seen read something like the following in that they do not imply that the woman is doing the battling but her offspring (Jesus) is. Here the offspring is the focus it seems.
Genesis 3:15
(NRSV) I will put enmity between you and the woman, and between your offspring and hers; he will strike your head, and you will strike his heel."
(ESV) I will put enmity between you and the woman, and between your offspring and her offspring; he shall bruise your head, and you shall bruise his heel.”
(NET) And I will put hostility between you and the woman and between your offspring and her offspring; her offspring will attack your head, and you will attack her offspring’s heel.”
Note that the DRB (more Catholic friendly from what I know) translation reads like this.
Genesis 3:15
(DRB) I will put enmities between thee and the woman, and thy seed and her seed: she shall crush thy head, and thou shalt lie in wait for her heel.
Here its somewhat ambiguous whether or not the focus is on her or her offspring. Note that she doing the crushing may (or may not) mean that her offspring (i.e her lineage) is being discussed, not her specifically. This is similar to referring to Israel as a nation since they are followers or the lineage of Israel the person. Here it is also implied that a lineage of people who follow a being that is not God will or do exist. These offspring are an enemy it seems.
Also consider that the wording in all cases is referring to her seed (i.e not the seed of a male human she had children with). This seems to imply that she is the only human source of the lineage. Therefore, from a Christian point of view, the passage is likely about Mary and Jesus and the virgin birth in all of these translations.