A bifurcation analysis of gender equality and fertility