That's so weird. And you weren't using URP or shaders? You're using Unity right?
One "gotcha" that I've learned in this process is with "quality levels." The Unity Editor will choose a different quality level by default than what it will build for web. This change can have broad reaching implications on performance, functionality and graphic quality, and basically make it so you're not editing the same game you're building on publish.
I think what I'm going to do going forward is just delete all of the quality settings except one to make sure there aren't any surprises when I build.
I also noticed your game expanding to the whole screen, if you wanted to make sure you're publishing on the same resolution you tested on, you need to set that both in the "Player" settings and in the itch page editor.