OK. Listen to the song, and you will hear its repetition. Learn the melody, then set your “score” aside and play the line in any key, every key. Imagine that you sit in on a group that plays the song, and the singer asks the guitar player to add a capo on the third fret (common enough). What to do?
You’ve spent enough time on this to start to internalize the tune - at least I hope that it is soaking in. Are you playing the notes as you write them, or just making this an annotation exercise? I suggest the former, as it will help you hear the melody unfold note by note.
Above all, make the path musical.
Enjoy.