The court ruled 5-4 that the Constitution’s guarantees of due process and equal protection under the law mean that states cannot ban same-sex marriages. flag flies in front of San Francisco's iconic Castro Theater during a street celebration following the United States Supreme Court's landmark decision that legalized same-sex marriage throughout the country in San Francisco, California June 26, 2015.