I finally found a solution that worked for me on the forum:
I just had to run the following command:
wpctl settings --save bluetooth.autoswitch-to-headset-profile false
I’m glad to see that’s much simpler than most ideas suggested in the other threads. Thanks to @nikgnomic for this answer.