I also made plenty of bad choices when younger and life ended up taking a different path than anyone could have envisioned for me. Not to blow my own trumpet, but up to GCSE level I was in the top 5% of the school, was destined to go to a decent university, do whatever I wanted as a career etc.
Some family events happened around that time and my mental health wasnt great. I dropped out of 6th form and subsequently college the year after. I'd hoped to be able to give it a third go after getting myself in order, but Mum simply couldn't afford to keep me after 18, so I got a job in a warehouse. I never thought of going back to education later as I thought that ship had sailed. 14 years later I'm a long distance truck driver who doesn't have the ability or time to do say, the Open University, and I'm not at home with enough assured regularity to do some kind of evening education. I have a mortgage and my partner is now pregnant with our first child, so I cant afford to change to even another driving job that has me home more. I'm trapped.
In your specific case though, it seems your desire for a family outweighs your need for a career. For some people, career is everything and fair play to them if that is how they measure success, but not everyone does. My mum had one desire in life, and that was to be a Mum before anything else.
This is just my opinion, but, you don't NEED the career or the better job to be able to have kids. It's a bonus and would help for sure, but it's not an absolute necessity, or else how on earth do the majority of people earning less than £40k combined manage?
One thing I'm learning as time goes on is just how fleeting life actually is, how quickly it passes us by. You may have reached that cross roads where the choice is either career or a family, but don't think you NEED the first to be able to have the latter. Think on which will give you greatest sense of satisfaction and personal achievement, and do what will make you happiest.
Life is short, but it still gives us plenty of time to regret the paths not taken when the door closes on them.