Strange vertical line appears on MacBook Pro Screen
I've been using my 2021 MacBook Pro without issues for nearly 2 years now. But since today, there appears to be a strange vertical black line (one pixel thick) that crosses the entire screen. It isn't present when I turn on the Mac and appears after a while of usage. And the strange part is that it disappears if I move the cursor or scroll and also disappears for a long while before reappearing. Any thoughts would be much appreciated.
Also, it does not appear in any screenshots I take.
MacBook Pro 14″