It was supposed to be a tax cut for manufacturers. Then it got out of control.
World Wrestling Entertainment took it for producing wrestling videos. Regional gas stations claimed it because they mix ethanol with base fuel. Grocery stores asked for it because they spray their fruit so that it ripens. Pharmacies could take it because they have booths that print photos.
Republicans in Congress passed that deduction more than a decade ago, and they repealed it in the tax bill signed on Friday by President Trump. It is a lesson in the abundant creativity of American business in interpreting the tax code.
The latest overhaul could play out the same way. Already, lawyers and accountants are eyeing several provisions that investors and companies could potentially exploit.
The bill, for example, lowers the taxes on so-called pass-through income, which is earned by partnerships and other types of businesses. Congress sold the provision as a way to help smaller companies. But lawmakers added language that allowed big real estate developers to benefit. The result could be a tax break for any company that buys and operates a building for its business. .
The new law is also supposed to encourage companies to make investments in the United States. But the rules were written in such a way that they could give businesses an incentive to keep their money in foreign countries and build factories abroad.
The wildly popular manufacturing break, passed in 2004, is a case study in the unforeseen consequences of changing the tax code — how companies take advantage of gaping holes and force the government to play catch-up.
The provision, known as the domestic production activities deduction, gave companies a tax break on income they earned from making things in the United States. It was intended to help American manufacturers, which were struggling to hold their own against competition from overseas.
Then a raft of other industries heard about the rule as it was being devised and fired up their lobbying machines. Suddenly, everyone became a manufacturer.
Movie studios got the break because they produced films, and tech giants won it, too, for making computer software. Construction companies got it for making buildings, and so did engineers and architects for designing them.
Starbucks hired lobbyists to make the case that it, too, was a producer, because the company roasts coffee beans. Congress added language that allowed coffee shops to deduct a percentage of every cup sold if it was made with beans they roasted off site. It became known as the Starbucks footnote.
“This has been a boondoggle tax expenditure,” said Robert J. Shapiro, a former Commerce Department official who founded the economic advisory firm Sonecon. “It is a political lesson. You are always liable to create tax loopholes that grow.”
The government initially estimated that the 2004 law would cost a net $27.3 billion from 2005 through 2014. It ended up costing over $90 billion during that period, according to a congressional report.
The Internal Revenue Service had to warn retailers that cutting keys doesn’t make you a manufacturer. Neither does mixing paint, putting plants in the sun to grow or writing “Happy birthday” on a cake you didn’t bake.
But in more than a decade of battling with companies about the rule, the government gave up more ground than it won. One of its most epic losses came at the hands of a David-size challenger in Fullerton, Calif.
It all started in tax class. Dan Maguire, an accountant by trade, was sitting in a seminar about the new features of the tax code in 2005 when he first heard about the manufacturing deduction. He became obsessed.
“I’m thinking, ‘Gosh, as crazy as it is, this is a good deduction for Houdini,’” he said. Houdini Inc., better known as Wine Country Gift Baskets, is a plucky maker of assortments for special occasions that employs Mr. Maguire as its chief financial officer.
Mr. Maguire filed for the deduction in amended returns for 2005 and 2006. The I.R.S. gave Houdini a refund of close to $300,000. Then, when it realized what had happened, it doubled back and audited the company, demanding that Houdini return the money.
“It’s the government — what do you expect?” Mr. Maguire said. “They aren’t exactly an efficiently run organization.”
When Houdini refused to give the refund back, the government sued the company in 2011.
At issue was a straightforward question: Does putting wine and chocolate into a basket amount to manufacturing? Federal lawyers sputtered at the thought.
“I can make a gift basket at home,” pleaded one government lawyer, according to a transcript in the case. “I can go to the store, and I can purchase these items and put them into a basket which I have purchased and put cellophane wrap around it, but in the process, I have not altered anything in it.”
The problem, for the government, was that its lawyers didn’t have much to stand on. The deduction’s regulations explicitly defined manufacturing as “combining or assembling two or more articles.”
Just putting two things together wouldn’t count, but Houdini argued that it had all the elements of a traditional manufacturing system going in its warehouses. There are assembly lines, conveyor belts, forklifts, “just like Henry Ford,” Mr. Maguire said.
In the end, a federal judge ruled against the government. Mr. Maguire has been claiming the deduction ever since. It has saved the company over $5 million. “This was a fun lesson to teach the I.R.S.,” he said, with conviction.
The government took it on the chin once more over the deduction when a medicine packaging company sued the I.R.S. in 2012. The company, Precision Dose, said it deserved the deduction, which had been denied. It did not make the liquid medicine or the cups that the medicine went into. But it did design the cups and the lids on them. The government said the company was just repackaging drugs.
Judge Philip G. Reinhard, in federal court in Illinois, took the company’s side.
That will all be moot with the latest tax bill. Congressional Republicans said the deduction was no longer necessary with the overall reduction of the corporate tax rate. So the hunt for unintended gold mines will go down new paths.
“If the bar has been set low by the regulation, you can understand why taxpayers are claiming it,” said Connie Cheng, a tax managing director at the accounting firm BDO USA. It took longer to write the law that included the manufacturing deduction in 2004 than it did to shape the entire tax bill this time around. The haste is sure to create countless new adventures for accountants like Ms. Cheng.
“That’s the nature of tax in general,” she said. “Every time you write a rule, there are people out there who think about ‘How do we get creative with it, and how do we get around it?’”