God may be a "just in time" God, but obviously is never taken by surprise. Pope Francis recently quoted Scripture and said that “a Christian is a chosen one, one who has been chosen in God's heart before the creation of the world.”
It's a really mind-blowing thought that God thought about us before we were born and even more so before the creation of the world. This is the sort of stuff that deserves to be “pondered in our heart” like Mary did in hers.
Elsewhere, a neat find - a reference in the Vatican II documents to Daniel 3:57-90, famous from Morning Prayer (“fire and ice…praise the Lord!”):
The call to grandeur and the depths of misery, both of which are a part of human experience, find their ultimate and simultaneous explanation in the light of this revelation.* [* footnote reference is to Daniel 3]This was always my sense of Daniel 3, i.e. to praise Him in good times and bad, and here it is so explicated.