scanning chinese media and english and chinese wikipedia the tldr seems to be: there were state incentives for having just one child wrt healthcare, retirement, etc. After first child it’s mandated that the woman has an IUD or one of the partners is sterilized. After the second child, sterilization is mandatory, and there is a hefty fee (multiple years of rural income) for the second child for the state to support them.
There were a decent number of exceptions: rural populations could have 2 if the first was a girl, and in sparsely populated provinces, rural populations could have 2 no matter what. Critically, ethnic minorities were exempt, so it only applied to Han people. The enforcement was primarily in urban areas. There were other exceptions too and they changed throughout the course of the law.
lol