THE Affordable Care Act, better known as Obamacare, has been battered again and again since its enactment in 2010. On June 30th it got its latest beating, this time from the Supreme Court. The justices ruled that a company can, indeed, bring religious objections against Obamacare. In the case, Burwell v Hobby Lobby Stores, Inc, the court ruled that closely held companies can refuse to offer workers coverage of contraception without facing fines. The case was brought by two Christian families and their businesses: the Greens own Hobby Lobby, a chain of craft shops, and Mardel, a Christian bookstore; the Hahns own Conestoga Wood Specialties, a cabinet company.

Obamacare requires firms to offer their workers health coverage, including coverage of contraception at no extra cost to the employee. The Greens and Hahns believe that some of those contraceptives, which may keep a fertilised egg from implanting in the uterine wall, amount to abortion. Federal law defines pregnancy from implantation, not fertilisation. Nevertheless, the issue before the court wasnot whether the Greens’ religious beliefs were valid. Rather, the question was whether a company can be exempt from federal law because its owners have religious objections.

The First Amendment protects the right to the “free exercise” of religion. A law passed in 1993, the Religious Freedom Restoration Act, further requires that the government “shall not substantially burden a person’s exercise of religion” unless doing so is the least restrictive way to advance a compelling government interest. The plaintiffs in this case argued that Obamacare’s mandate violated their rights under the 1993 law. If Hobby Lobby did not provide coverage, the company’s lawyers claimed, it might face fines of nearly $475ma year, unquestionably a substantial burden. The mandate was surely not the least restrictive way to give workers birth control—after all, the government had already given exemptions to religious groups, such as churches, and provided an “accommodation” for religious non-profits, such as Catholic universities. The distinction between for-profit and non-profits was immaterial, the lawyers argued. They insisted that “Corporations frequently engage in religious exercise”.

The government countered that this was ridiculous. “While the Greens are persons who exercise religion, there is a critical separation between the Greens and the corporation they have elected to create.” The Greens do not personally employ their workers; Hobby Lobby does. A company has both rights and obligations that differ from those of its owners. That includes being subject to federal law, such as the Americans with Disabilities Actand, in this case, Obamacare.

The Supreme Court disagreed, ruling five to four against the government. Writing for the majority, Justice Samuel Alito explained that the mandate to cover contraception violates the 1993 law. “Protecting the free-exercise rights of closely held corporations,” he wrote, “protects the religious liberty of the humans who own and control them.”Just because the 1993 law applied only to a “person”, the government cannot claim that this excludes for-profit companies: “no conceivable definition of a ‘person’ includes natural persons and non-profit corporations, but not for-profit corporations.”

The conservative justices argued that their ruling would have limited effect. “Our decision in these cases is concerned solely with the contraceptive mandate”, not all requirements for company insurance. Furthermore, the ruling applied only to “closely held corporations”.

However the case is sure to have a wide impact. It directly affects women who work for religious employers. “Today, the Supreme Court ruled against American women and families, giving bosses the right to discriminate against women and deny their employees access to birth control coverage,” fumed Cecile Richards, the head of Planned Parenthood, a leading reproductive health-care provider. But the ruling also brings new problems for Obamacare. Republicans will seize the decision as yet another sign that the law is doomed. The ruling will also make it much harder to enforce the mandate that employers offer coverage, which has already been delayed.

More broadly, the decision may make it harder for Congress to enforce the laws it passes. The Supreme Court’s left-leaning justices called the decision one of “startling breadth”. Companies, wrote Ruth Bader Ginsburg, “can opt out of any law (saving only tax laws) they judge incompatible with their sincerely held religious beliefs.” If her prediction proves true, this ruling is bad news not just for Obamacare, but for acts of Congress in general.