Stormy was working blue, and the judge was seeing red.

Justice Juan Merchan chided Donald Trump’s lawyer Susan Necheles, saying he didn’t understand why she hadn’t objected to seamy details about the President and the Porn Star spilling out.

“Why on earth she wouldn’t object to the mention of a condom I don’t understand,” Merchan complained about Necheles.

But I wanted to hear about the condom — or lack thereof. The New York trial involves an abstruse legal strategy and illusory crime. It’s the weakest of the cases against Trump. It’s certainly not putting him on trial for the attempted coup d’état he incited or for treating top secret documents as dinner conversation fodder at his golf clubs. But it now seems almost certain that none of the other cases will be resolved before the election.

So we’re left with a two-bit case that has devolved into dirty bits, filled with salacious details — a spanking, a missionary position and ping-ponging insults like “horse face” and “orange turd.”

Yet, even if it plays like a cheesy old Cinemax “After Dark” show, it’s still illuminating. The case doesn’t hinge on Stormy Daniels’s story about her liaison with Trump, or even if the former president is lying when he says they didn’t have sex. (He would say that, wouldn’t he?)

It’s instructive about the moral values — or lack thereof — of our once and perhaps future president.