you have no right to deny a business transaction to someone because of their sexual orientation
Correct, you don't. But you also don't have the right to force someone into a business transaction either.
your understanding of contracts is completely ignorant
if some guy is buying a cake from you, and you deny him the cake because he's gay, you are destroying someone else's rights, you are not exercising your rights
You cannot force someone to enter into a contract. And a simple reason of "I don't like the person" is sufficient and not discriminatory in any way.
There is a difference in service between someone coming in a picking a cake off the shelf, and a cake that is being pre-ordered to certain specifications for a specific date and time, possibly (though not necessarily) including delivery.
In the first, the cake is on the shelf and the buyer walks in, picks it up, and pays for it. No contract has been entered. For a bakery or restaurant this falls under public service as long as the doors are open to the public. If the doors are not open to the public then there is no public service and this service is hence not available. It has a different burden under the law than private services do.
In the second, a contract is used to ensure that both parties understand what is being provided, by whom, when, and how. This is a private service provided by the business, and the business is allowed to have a greater choice with whom it provides private services to since they are contracted services. If they for any reason (of which there are many legal reasons, and some illegal reasons) choose not to enter the contract then they do not have to provide the private service. Illegal reasons are the discriminatory reasons - race, sex, etc - while legal reasons are pretty much anything else, including "I don't like you".
You cannot force someone to enter into a contract, and a simple thing of "I don't like the other person" is sufficient and non-discriminatory. No reason must be provided for why you don't want to enter into the contract either.
And since you mentioned a bakery, I'll assume you mean the one in Oregon that went through this in the courts. Their failure was to try to argue religious reasons; they should have just stuck to basic contract law and avoided that whole part of the issue, even if the other side pushed. They never stated a reason when they denied the contract; nor were they required to. They went a step further and actually provided references of other bakeries in the area. They could have used any number of legal reasons to not enter the contract, and they should have. Because the case was really much simpler than what it was made out to be.
And honestly, the outcome is not one I find favourable either simply because of that - you cannot force someone into a contract. Doing so is trying to eviscerate someone else's rights for your own - which is just as wrong.