MEXICO CITY (AP) — Mexico’s Gulf coast state of Veracruz became the fourth of the country’s 32 states to legalize abortion Tuesday.

The Veracruz state legislature voted 25-13 to allow abortions in the first 12 weeks of a pregnancy.

Those who perform abortions on women after the first three months can be punished by 15 to 60 days in prison, which can be substituted by a fine and 50 to 100 of community work.

Women who get an abortion after 12 weeks could be sentenced to up to two months of “integrated” health treatment.

Mexico City, Hidalgo and Oaxaca have also legalized abortion. Laws in other states vary, but all allow abortions in cases of rape.