I say this as a dad: having a kid, especially the first few years, is like having the world's worst second job.
You get paid? No, you pay to have the job! Set hours? No, you're always on call! You might get an occasional break for a few hours, if you pay up for it! Decent working conditions? How does constantly cleaning up shit and piss sound? Ah, but you could get out of it if you change your mind, right? Sure...after your 18 year long contract is up.
Obviously I'm glossing over the emotional angle, but yeah, from a material perspective having kids is fucking dumb, and for all you know spending that time and money with existing friends and family would've actually left you happier overall. It's a big irrational gamble in a lot of ways.
Anyway, you can't fix all of that, but it would be possible for society, via the government, to fix some of it. For example, you could implement subsidies to the point where having kids had a net zero impact on your finances, so that you wouldn't be looking at lowered standard of living or reduced retirement savings from having children.
Of course many would object to this, because culturally we believe that parents should be people who accept a worse standard of living with a smile on their face. That's stupid, of course, which is exactly why birth rates are below replacement in pretty much all the developed world, and beyond. People may be okay with the emotional effort involved in raising children, but telling them to throw away going out as a couple, abandon most of their nicer vacations, blah blah blah isn't gonna sell the idea.