The trajectory of same-sex marriage today is often compared to interracial marriage in the 1960s. Both were legalized one by one in the states before a Supreme Court ruling led the way to nationwide legalization. But one way same-sex and interracial marriages greatly differ is the timing of popular opinion and court rulings, as XKCD notes:
(XKCD)
It took nearly three decades after the Supreme Court legalized interracial marriage across the country for it to reach majority approval in the US. But same-sex marriage has maintained popular support, according to Gallup, since 2012 — before the Supreme Court struck down the federal ban on same-sex marriages and effectively enabled court rulings that have ended more than a dozen states' marriage bans.
To keep track of the recent court rulings on same-sex marriage, check out Vox's list.