You are right about the assumption that every moment is determined by planetary positions. To extend further, planetary positions themselves are also predetermined within universe. So all we do & experience is destiny. Hence, there is no existence of free will.
One suffers in hell or enjoys in heaven due to those planetary positions or destiny.
Q: How is such suffering justified?
A: The philosophical reason is: We(our consciousness) want the suffering [& enjoyment].
BG 13.22 - Purusha being seated(situated) in Prakruti, experiences the [sattva, rajas, tamas] modes born of Prakruti. Contact with the these modes, is the cause of its births in good and evil wombs.
Let's take an Example:
- Consider, audience as "Purusha" (enjoyer/witness/consumer). Consider movie as "Prakruti" and all the emotional aspects in a movie as 3 modes of "Prakruti".
- Why do we see a horror movie -- to get horrified, tragic movie -- to get pained, comic movie -- for amusement. Similarly, the so called punishment in hell or rewards in heaven are all categorised under "enjoyment" (or "consumption") for the Purusha.
- The movie playing in front of the audience is already shoot in reels & hence predetermined. Similarly one's births and actions are also destined.
- The movie won't change its course depending on audience's mood. Same as Prakruti won't change its destiny depending on Purusha.
When audience gets "bored" of movie regardless of its sad/funny/romantic emotions, they leave theatre in between. Exactly same, when Purusha becomes indifferent to the Prakruti, it gets realised & then liberated. In either cases, there is no purpose left, to continue.
When the movie gets over, everyone has to leave the theatre. Exactly same, when the Prakruti's cycle finishes, all are liberated (see the combined meaning of BG 9.7 & BG 14.2).