Today is a historic day for gay rights in the USA. Section 3 of the Defense of Marriage Act has been deemed by the Supreme Court of the United States to be unconstitutional, which means that the federal government will now respect same-sex marriages. This does not, however, mean that the federal government will now force all states to perform same-sex marriages, nor does it mean that one state must now honor another state's same-sex marriages, although gay rights advocates certainly hope for these things as well. Without taking sides, I'd like to simply clarify what SCOTUS said by supplying relevant context.
Here is the key sentence from the SCOTUS ruling:
(in all quotes, all emphasis is mine)
DOMA is unconstitutional as a deprivation of the equal liberty of persons that is protected by the Fifth Amendment
This specifically refers to Section 3 of DOMA:
In determining the meaning of any Act of Congress, or of any ruling, regulation, or interpretation of the various administrative bureaus and agencies of the United States, the word 'marriage' means only a legal union between one man and one woman as husband and wife, and the word 'spouse' refers only to a person of the opposite sex who is a husband or a wife.
Gay rights advocates often appeal to the 14th Amendment of the United States Constitution:
No State shall make or enforce any law which shall abridge the privileges or immunities of citizens of the United States; nor shall any State deprive any person of life, liberty, or property, without due process of law; nor deny to any person within its jurisdiction the equal protection of the laws.
Why, then, did SCOTUS appeal to the 5th?
No person shall be... deprived of life, liberty, or property, without due process of law; nor shall private property be taken for public use, without just compensation.
This has to do with liberties, and where they come from. Merriam-Webster says that a liberty is:
a right or immunity enjoyed by prescription or by grant
According to the SCOTUS ruling, we are to understand that marriage is a liberty that is granted by states, and not by the federal government.
This explains why they appealed to the 5th, because Section 3 of DOMA says that the federal government can deprive people of their state-granted liberty. This also explains why they didn't appeal to the 14th, because the 14th is all about the states not depriving liberties granted at the federal level. Therefore, SCOTUS did not strike down Section 2 of DOMA:
No State, territory, or possession of the United States, or Indian tribe, shall be required to give effect to any public act, record, or judicial proceeding of any other State, territory, possession, or tribe respecting a relationship between persons of the same sex that is treated as a marriage under the laws of such other State, territory, possession, or tribe, or a right or claim arising from such relationship.
The SCOTUS ruling is a clear win for gay rights, but hopefully I've helped to illustrate that the ruling only goes so far, and gay rights advocates still have about three dozen states to convince before same-sex marriages are universally recognized across the USA.
The class to which DOMA directs its restrictions and restraints are those persons who are joined in same-sex marriages made lawful by the State. DOMA singles out a class of persons deemed by a State entitled to recognition and protection to enhance their own liberty. It imposes a disability on the class by refusing to acknowledge a status the State finds to be dignified and proper. DOMA instructs all federal officials, and indeed all persons with whom same-sex couples interact, including their own children, that their marriage is less worthy than the marriages of others. The federal statute is invalid, for no legitimate purpose overcomes the purpose and effect to disparage and to injure those whom the State, by its marriage laws, sought to protect in personhood and dignity. By seeking to displace this protection and treating those persons as living in marriages less respected than others, the federal statute is in violation of the Fifth Amendment. This opinion and its holding are confined to those lawful marriages.
You can read the whole court opinion for yourself; it's available online: http://www.supremecourt.gov/opinions/12pdf/12-307_g2bh.pdf