The United States rarely looks to Mexico for an example of how to do things, but sometimes it should. For example, because of Mexico's history with its dominant and dominating religion, Mexico has long had strong laws that emphasize separation of church and state.
In marriage, that means the state only recognizes civil (not religious) marriages, which are performed by the Registro Civil. Religious officials are not empowered to legally marry couples (they may officiate in a separate religious ceremony).
That approach would help solve some of our brouhaha over same-sex marriage. Require that everyone, gay and straight, who wants their marriage to be legal (for tax purposes, custody, etc.) go to the courthouse and get married. Before or after, they may have whatever religious ceremony they choose.