In Hollingsworth v. Perry and United States v. Windsor, or perhaps in some more clearly justiciable case a few years hence, the Supreme Court will decide whether states can prohibit same-sex marriages. The Becket Fund for Religious Liberty argued in both pending cases that protecting religious liberty is a rational basis for banning same-sex marriage.
The conflict between religious liberty and gay rights is bad for both sides and dangerous for the American tradition of individual liberty. The Court can protect the rights of both sides.