Reassurance first, and then the call back
Look at the structure, because it is unusual and it is deliberate.
The first verse is addressed to people who have already gone badly past the line. Not to people who are thinking about it. It tells them not to lose hope, and it does not attach a size limit to the sins it is talking about. Then, and only then, the next verse says to turn back.
So it is not a licence, which is what its critics worry about, and it is not a standalone comfort, which is what it usually gets used as. It is the door being held open first, so that walking back through it is possible at all.
And notice what the Qur'an names as the danger in the other verses. It is not the sin. It is despair.
That structure, reassurance before demand, is the structure of this lesson, and we did not invent it.