Disabling subscribe button on mobile devices

Hello!
I am trying to set up my website so the floating “Subscribe button” is shown on the desktop but not on mobile devices. Currently, there is no option to do this from Ghost(Pro) settings.

I am trying to inject a code to the header, but it isn’t working. Could someone give me a hand?
The code:

@media screen and (max-width: 480px) { .ghost-portal-root { display: none; } }

Thank you in advance!