The day had already been defined when light had been created and separated from darkness.
The length of a day is not determined by the existence of light, it's determined by the duration of a rotation of the Earth about its axis and the subsequent exposure to the Sun.
For the record, the common approach is to see two main actions in Genesis 1: forming and filling.
But in Genesis 1:2 there are three problems that need solving: formlessness, emptiness and darkness. Hence the two triad approach is a bit of a red herring.
For the record, the common approach is to see Genesis as, at best, a metaphor. It's not a literal record, it's a story, regardless of whether you believe in God or not.
O.