Eds: Adds new quotes and reaction, links photos and minor edits. AP Video. With AP Photos. Fixes typo in Brewer quote.
PHOENIX - Gov. Jan Brewer on Wednesday vetoed a Republican bill that set off a national debate over gay rights, religion and discrimination and subjected Arizona to blistering criticism from major corporations and political leaders from both parties.
Loud cheers erupted outside the Capitol building immediately after Brewer made her announcement.
"My agenda is to sign into law legislation that advances Arizona," Brewer said at a news conference. "I call them like I see them despite the tears or the boos from the crowd. After weighing all the arguments, I have vetoed Senate Bill 1062 moments ago."
The Republican governor said she gave the legislation careful deliberation in talking to her lawyers, citizens, businesses and lawmakers on both sides of the debate. Her office said it received more than 40,000 calls and emails on the legislation, with most of them urging a veto.
Brewer said the bill "could divide Arizona in ways we could not even imagine and no one would ever want." The bill was broadly worded and could result in unintended negative consequences, she added.
The bill backed by Republicans in the Legislature was designed to give added protection from lawsuits to people who assert their religious beliefs in refusing service to gays. But opponents called it an open attack on gays that invited discrimination.
The bill thrust Arizona into the national spotlight last week after both chambers of the state legislature approved it. As the days passed, more and more groups, politicians and average citizens weighed in against Senate Bill 1062. Many took to social media to criticize the bill.
Prominent business groups said it would be another black eye for the state that saw a national backlash over its 2010 immigration-crackdown law, SB1070, and warned that businesses looking to expand into the state may not do so if bill became law.
Companies such as Apple Inc. and American Airlines and politicians including GOP Sen. John McCain and former Republican presidential nominee Mitt Romney were among those who urged Brewer to veto the legislation. The Arizona Super Bowl Host Committee, which is overseeing preparations for the 2015 Super Bowl in Glendale, Ariz., came out with a statement against the legislation. The Hispanic National Bar Association on Wednesday said it cancelled its 2015 convention in Phoenix over the legislation.
In addition, three Republicans who had voted for the bill reversed course and said it was a mistake. They said in a letter to Brewer that while the intent of their vote "was to create a shield for all citizens' religious liberties, the bill has been mischaracterized by its opponents as a sword for religious intolerance."
SB 1062 allows people to claim their religious beliefs as a defense against claims of discrimination. Backers cite a New Mexico Supreme Court decision that allowed a gay couple to sue a photographer who refused to document their wedding, even though the law that allowed that suit doesn't exist in Arizona.
Sen. Al Melvin, a Republican who is running for governor and voted for the bill, said he is disappointed by the veto.
"I am sorry to hear that Governor Brewer has vetoed this bill. I'm sure it was a difficult choice for her, but it is a sad day when protecting liberty is considered controversial," Melvin said.
Democrats said it was a veiled attempt to legally discriminate against gay people and could allow people to break nearly any law and cite religious freedom as a defense.
Rep. Ruben Gallego, D-Phoenix, said would remain vigilant of other legislation that could also target gays.
"The effect is that again we got a black eye," Gallego said. "But it also shows that Arizona can stand united"
Democratic leaders in the legislature thanked the governor for vetoing the bill. But they said it should not have ever made it to her desk.
"It's time to move Arizona forward and make sure that something like Senate Bill 1062 never happens again," Senate Minority Leader Anna Tovar said. "It's time to show the nation and the world what Arizona is truly about."
The Center for Arizona Policy helped write the bill and argued it was needed to protect against increasingly activist federal courts and simply clarifies existing state law.
"It is truly a disappointing day in our state and nation when lies and personal attacks can over shadow the truth," said Cathi Herrod, the leader of the group.
Similar religious-protection legislation has been introduced in Ohio, Mississippi, Idaho, South Dakota, Tennessee and Oklahoma, but Arizona's plan is the only one that has been passed by a state legislature. The legislation was withdrawn in Ohio on Wednesday, and similar bills are stalled in Idaho and Kansas.
The push in Arizona comes as an increasing number of conservative states grapple with ways to counter the growing legality of gay marriage. Arizona has a ban on gay marriage.
Federal judges have recently struck down those bans in Utah, Oklahoma and Virginia, but those decisions are under appeal.
On Wednesday, a federal judge declared Texas' ban on gay marriage unconstitutional, but he left it in place until an appeals court can rule on the case.