But expert advice, even if material, is not the same as insider information.
If you go to a random lawyer in Wyoming and ask them to write "expert opinion" then what you'll get would probably be something standard, written by a junior associate, or maybe even produced by ChatGPT.
If the White House orders "expert opinion" on potential Supreme Court ruling then the chances are that the expert asked to prepare it is someone who plays golf with some of the SCOTUS judges.
So those two "expert opinions" might not bear the same weight.
It's a public arena on things like this. I don't think even the justices themselves have "material inside information" until a little ways through the hearing, and people are trying to predict the outcome well before that. On the surface that might sound absurd, but it isn't.
Why not?
(Hint: it creates a perverse incentive to see your side lose the legal argument for your own personal gain.)
And in this case, it's the actual secretary doing it. Who has significant influence on the outcome of the case (largely in the negative - nothing he can do can make the government more likely to win it, but stuff he did has the capacity to make the government more likely to lose it.)