In literature, if foreshadowing is reference to future events, what would it be called if it is referencing a past event which the reader does not know?
Foreshadowing is not necessarily reference to future events.
A foreshadowing is a reference to events which will be revealed later in the story. They're in the future from the point of view of the reader, but not necessarily events which are in the future "in-universe".
Foreshadowing is a literary device in which a writer gives an advance hint of what is to come later in the story.
(It should be noted that neither of the sources linked above are very good. I'm not sure what's a better dictionary of literary devices, but would be very happy to be directed to one.)
In this context, "later in the story" means later in the physical book or otherwise in the telling of the narrative - not necessarily events which actually occurred later within the world of the story. For some examples of foreshadowing of earlier events, in a somewhat famous work of modern literature, see this Q&A:
"I wouldn’t mind knowing how Riddle got an award for special services to Hogwarts either."
"Could’ve been anything," said Ron. "Maybe he got thirty O.W.L.s or saved a teacher from the giant squid. Maybe he murdered Myrtle; that would’ve done everyone a favour..."
-- Harry Potter, book 2, chapter 13
It's revealed later in this book that Riddle did in fact murder Myrtle, several decades earlier. The event being foreshadowed is well in the past, and only the revelation of it is in the future.
"Dumbledore believed Snape was sorry James was dead? Snape hated James..."
"And he didn't think my mother was worth a damn either," said Harry, "because she was Muggle-born...'Mudblood,' he called her..."
-- Harry Potter, book 6, chapter 29
It's revealed in the next book that Snape's "Mudblood" outburst was out of character, and in fact he not only didn't hate Lily (Harry's mother) but had in fact been in love with her since childhood. Here Snape's love for Lily is a continuing state through the past, present, and future ("After all this time?" "Always."), but there's foreshadowing because the revelation of it is in the future.
So to answer your question:
what would it be called if it is referencing a past event which the reader does not know?
This is still foreshadowing. If the reader doesn't know but will find out later, then the revelation is in the future and it's foreshadowing, regardless of whether the event being referenced is in the future or the past.