It's a leftover from a time when they wanted to prevent interracial marriage. That's it. It has no religious basis.
Case in point: A black man and a white woman appear before an elected official for a marriage license. The elected official refuses to write the license based on the First Amendment.
Why does the government get involved saying who can and cannot marry on an individual case-by-case basis?
Because.every individual must qualify.
Are people ever denied for any reason other than invented ones like this idiots imaginary sky friend not liking it?
Yes.