I've been there. It sucks, but there are things you can do. It is a song you're really familiar with or is it relatively new to you? I've found that if I've played a song enough times on the guitar, that initially playing it and singing it can be difficult, but I soon manage to put my hands on auto-pilot - I've played the song so much, that my hands just do what they do and I almost don't even have to think about it. It's like someone in the back of the room has a little remote control that's making my hands move. This way I can focus on the vocals better.
Write both the vocal melody and the guitar riff out together. Write them out one above the other, so that they line up the way they would when you perform them. The idea here is that you want to be able to visualize on paper just what exactly it is that you are asking of yourself. Analyze it. Analyze each line separately AND together. Look at where long notes in one line or the other may overlap a sustained rhythm in the other line. Things like that. Then slow it all down. If you have to cut the tempo in half or more. Play and sing the line however slow you have to to get it right. Use a metronome (
https://www.seventhstring.com/metronome/metronome.html - type in the desired tempo, then click on the metronome). Once you can get it right several times, up the tempo. You'll get there.
Out of curiosity, what is the song?