I had a similar issue where the grey content inside my scroll view was coming from a button view.
The simple fix is applying a .buttonStyle(.plain) modifier to the button.
It took forever to realize what was applying a grey background to my content (I am using the multiplatform template for my xcode project, and this only occurred on macOS). This page is the first thing that comes up when searching my issue. I thought it’d be appropriate to leave a quick solution for it. This is in Xcode 16 for macOS 15.