The rapid expansion of gay rights and LGBT acceptance in the United States is a remarkable story, and one that's still unfolding. If you think you know how it ends, you don't. As federal courts and state and local governments have opened the door to same-sex marriage, for example, state legislatures in Republican-controlled capitals have been responding with measures to limit gay rights, quash same-sex marriage, and take away local control over LGBT anti-discrimination policies.

The "religious freedom" laws in Indiana and Arkansas are the most famous of the recent state measures to curb gay rights. But Indianapolis and Little Rock are hardly alone. In Texas, for example, Republican state legislators have introduced at least 20 anti-LGBT bills in the current session — more than any other state, according to The Texas Observer.

As gay rights march forward in America, religious conservatives are taking a stand (principled or bigoted, depending on your point of view). Big Business, a second pillar of the Republican coalition, is taking a stand, too, however, and that's where things get interesting.

More than 45 years after the Stonewall Riots in New York City's Greenwich Village heralded the dawn of the modern gay-rights movement, the biggest and most effective champion of equal treatment of gays and lesbians is probably the business community. That's not to say that gay-rights groups aren't organizing and advocating and applying pressure where they can, but their efforts are a tough sell in the parts of the country waging the counteroffensive against gay rights.

In Indiana, for example, Gov. Mike Pence (R) probably wasn't too concerned about objections from the Human Rights Campaign to the "religious freedom" law he signed earlier this month. But when giant corporations like Apple and Subaru, sports franchises like the NCAA and NASCAR, and the Indiana Chamber of Commerce criticized the law, other states and large municipalities enacted travel bans, and several large employers threatened to cancel expansion plans in Indiana, Pence and the GOP-controled legislature took note, amending the law to include protections against LGBT discrimination.

Arkansas Gov. Asa Hutchinson (R) forced similar LGBT-friendly changes to a religious freedom law in his state after Walmart and other large employers said the original bill would hurt business in Arkansas. (One of the governor's sons also signed a petition urging him to veto the law, he noted.)

Earlier this month, Texas businesses took their own stand against LGBT discrimination: More than 100 businesses signed the founding pledge of a new group called Texas Competes, affirming that "in order for Texas businesses to compete for top talent, we must have workplaces and communities that are diverse and welcoming for lesbian, gay, bisexual, and transgender people."

The signatories include Texas companies like Dell, Whole Foods, Texas Instruments, and HomeAway, but also large local employers in the tech, hospitality, travel, and entertainment industries. The Texas Association of Business — the powerful state chamber of commerce — and several local Chambers are also on board.

Texas Competes isn't going to lobby against specific legislation, but the Texas Association of Business is fighting two measures that would take away local governments' rights to enact LGBT anti-discrimination measures. "We are a very conservative business association as the state chamber, and it's not our typical partners we have at the table with us," said TAB President Chris Wallace, noting that his group is aligned in this effort with the ACLU and Equality Texas. "But we're proud we have these partners at the table with us because we're all working together to make sure we keep Texas open for business."

Dallas Mavericks owner Mark Cuban has also launched a big campaign, Texas Wins, with a similar goal of fighting the "alarming efforts to openly promote — and expand — discrimination in the Lone Star State." The chairman of Texas Wins is Mark McKinnon, a former top aide to George W. Bush.

If the business community — or, shall we say, the job creators — have decided that fighting for gay rights is good for business, that puts the Republican Party in a tough spot: Do you alienate the social conservative part of your party that's fighting for what they believe to be their religious freedoms, or do you pick a fight with the free-enterprise faction that believes discriminating against gay and transgender people hurts their recruitment efforts, their brand, and their bottom line? Do you side with the church or the chamber?

While the GOP figures that out, supporters of gay rights can marvel at the direction their battle is taking. The Chamber of Commerce and GLAAD won't always be allies, but when it comes to stemming the conservative counteroffensive against gay rights, it's the business community leading the fight.

In politics, as in business and life, money talks. Sometimes, maybe, that isn't a bad thing.