I’ve heard it’s the first but not really sure. Anyway, the overseas version linked in the post is particularly cute since the singer is obviously not a professional and it feels like the main character herself is singing as the voice actor is probably the same as the singer. I was like “what the hell is happening?” when I heard it first time on my SNK Anniversary collection.
Not sure if it is the first one, but seems a good candidate.
I know it’s a lot later, but I was amazed the first time I heard the in-game opening theme with lyrics in Tales of Phantasia (Super Famicom, 1995). I had no idea it existed when I tried the fan-translated ROM, and I was like, wait, you can do that in a SNES game?
Sure it’s probably the main reason they needed a (comparatively) high capacity cartridge (6 whole megabytes!), but still, wow.