(I'm a goy, for context. Specifically raised Norwegian Lutheran, not American. Also this went into a big nerdy ramble, which is probably fitting for the topic.)
I think it also comes down to what the purpose of the law is, whether or not "loopholes" are okay. Loopholes are morally neutral.
For secular, societal law (be it a country's legal system or the rules of a forum), the law is supposed to have a specific purpose to prevent something bad. Traffic laws prevent injuries, for example. In this case, finding a loophole is bad because it endangers people.
Of course, laws can be badly written or ineffective, and they can also be created for other purposes, to give power to a certain group. In that case, loopholes are seen as bad by the people in power, the people who benefit from that law.
However, we'd generally agree that finding loopholes in an unjust law is a good thing, right?
For an extreme example, say there's a law saying you are legally obligated to murder your neighbour if they paint their house on a Sunday. So you find a loophole that says, no, they have to paint their whole house, or it doesn't count. Even the most law-abiding person would probably agree to that loophole, because otherwise that would be really awful, and they'd find ways to justify it. This is a law most people agree is unjust.
Meanwhile, people who hate their neighbour and really wanted to murder them would be happy to have an excuse. Some people who dislike their neighbour and are scared to break the law might also end up murdering their neighbour, even if they don't agree with the law, and they'll justify to themselves saying they just followed the law.
Anyway I clearly got off on a tangent about fascist regimes here which wasn't my original point.
Now, religious law is a different matter, because its purpose is different.
In Christianity, the origins of the laws probably aren't that different from societal law, as explained above. But the purpose of Christian laws as presented to us is often much more focused on obedience - though not always.
Now, I'm raised Lutheran, so I was raised that I can technically sin as much as I want and still go to heaven if I believe in Jesus. Which always seemed really dumb to me, because 1) then what's the point in the laws? And 2) you can't CHOOSE to believe something, you either do or you don't. Or at least I can't. (This depends on your definition of belief, but as a kid I always understood it as "what you understand to be true based on evidence", rather than a choice to have faith.)
So then laws to me have always been presented more as guidelines on how to be a good person, rather than hard rules. Like OP mentions, how loopholes are fine if you follow the SPIRIT of the law. Because the spirit is "be a good person".
In fact, the main repeated prayer, the "Lord's Prayer" (Matthew 6:10-13), which is the only part of the Bible I remember, has only one directive: forgive sinners, and you too shall be forgiven. I heard this FAR more times than I ever heard the commandments or other rules.
Other corners of Christianity though, it's about obedience to an authority. You follow the rules or you get punished, that's the way it is. Loopholes are always bad because it's you trying to outwit your parents, er, I mean god. Loopholes show disobedience.
What OP is talking about, about suffering being virtuous, that's also only a specific brand of Christianity - not my personal experience. But it's connected to the authoritarian view, because it requires you to "trust in god's plan". You follow the rules even if they don't make sense to you. It's the "daddy knows best" idea of faith.
The interesting thing about how Judaism is described by OP though is "the law's purpose is to be followed." Which also implies obedience, but in a different way. There's no "daddy" to punish you if you do it "wrong".
If all ways of following the law are equal, then it's about showing respect to the words themselves - right? Not by blindly following - that's obedience, not respect. Respect is about paying attention to it, giving it due consideration, and accepting it as much as you can without harm.
(Interested to hear input on this btw.)
In that way, I think my experience with Lutheranism has a lot in common with Judaism. There's no punishment for doing it wrong - you follow the rules because you find meaning in it.
Of course, one of the things I missed in my childhood experience with Christianity is that it wasn't nearly as academic and thoughtful as my later (secondhand) experience with Judaism. For me, religion had about the same weight as any storybook with a moral. If I could debate the stories, maybe I would have cared more.
Also sidenote - in Norwegian fairy tales, the devil shows up relatively frequently in the form of a satyr, sometimes with bat wings. Probably a Christian adaptation of trickster figures, which are common here. The hero of the story beats him specifically through outwitting him. (There's two ways to victory in Norwegian fairy tales. Being clever, or being kind.)
There's one in particular where a kid traps the devil inside a nut just by challenging him to do if, then has a smith crack the nut open. Nothing else to the story, zero morality, just funny. Another one has the taxman try to talk his way out of being taken by the devil, but ends up thwarted because people hate the taxman.
Anyway the point of this aside is that loopholes and tricks against authorities or enemies are often seen as positives in Norwegian culture, probably because of quiet rebellion against 400 years of foreign rule. This probably colours our Christianity as well.