If your concern is unwanted pregnancies and saving the children:
- mandatory vasectomies for every penis out there (those are reversible)
- free birth control
- free healthcare for pregnant people
- free healthcare for all children
- a child stipend that starts with a positive pregnancy test
Pregnancy is not a punishment for having sex.
If pregnancy were punishment for bad behavior, it follows that children are likewise a punishment. That gets really theologically complicated really quickly. Especially if your religion calls god Father.