Bancroft's History of Utah:
There is a difference between marriage and sealing; the former is secular, and the latter both secular and celestial, as it may be either for time or for eternity, in person or by proxy, and with the living or with the dead.
And now some excerpts from the exceedingly long footnote for the paragraph from which that line comes (follow the link and read the whole thing---interesting stuff, but offtopic today):
Gentile marriage and divorce are not recognized as valid in the Mormon church. In its early days, the church had no marriage ordinances of its own, and the requirements, conditions, and ceremonies incident to the rite were similar to those of the various protestant sects. Nor had it officials legally qualified to marry, other, perhaps, than a few such men as Sidney Rigdon, wire, having been duly appointed to preside over churches of other denominations, were still competent to join in legal marriage. In 1836, when the church was three years old and the Kirtland temple about to be dedicated, we find Joseph petitioning the court of Medina county, Ohio, for licenses permitting his elders to perform marriage ceremonies, which authority had been refused them by the Geauga county court.
Later, when the church had gained power, the result of more complete organization, Joseph announced, as its belief respecting marriage, that it 'should be solemnized in a public meeting, or feast, prepared for that purpose,' and that the celebrant should be 'a presiding high-priest, bishop, elder, or priest.' But no prohibition was issued against marriage by any other authority. Neither were church-members forbidden to marry out of the church, though any so doing would be considered weak in the faith.
In some European countries (and, I hear, most places outside the US), the Church still has no power to legally marry couples. That's done by civic authority with sealing to follow.
Perhaps it's time to step away from our American assimilation and follow this template---and stop performing legally binding marriages. Then the question of what is or isn't marriage won't matter. The Church can seal as it pleases and we can take our time figuring out just what the eternal implications of sexuality are.
Clearly there's historical precedent.
The great thing is we don't have to wait for legislation to decide A or B or Z, we can just act.