Marriage, housing,buy cakes!Etc
Marriage is the only one of your examples that the U. S. Constitution applies. Housing is based on federal housing legislation based on the regulation of interstate commerce. The buying cake thing is not protected by the Constitution or federal civil rights laws but various state and local legislation. Those laws contain factors such as the number of employees in the bakery, whether decorating a cake involves a "creative" activity, etc.
In the Masterpiece Cakeshop case the Supreme Court ruled in favor of the bakery.