Advanced Protection locks key Android 16 security settings. Blocks sideloading, spam, unsafe links, and insecure networks.
Userscripts are no longer in vogue, but they're well worth using on your Android phone. Here's how I do it through Violentmonkey.