I'm not certain I can explain this in words completely clearly, however…
As you reach the point at which you start to lose control over your moving grip, either stop your cut halfway through & use your knife hand to let you re-grip, with pressure against the 'locked' knife, or once you get the feel for it, re-adjust your grip during the cut, when you have the knife to push against.
That should get you to at least the 3/4 mark or further, after which you can flip your onion over & in effect trim the rest round the root [which you don't want anyway].
For diced tomato, I use a different technique altogether. More 'straddling' than the traditional claw grip. I posted a long explanation of it here. [Now with pictures.]
BTW, don't use your fingernail as a guide. A sharp knife can go right through a fingernail & half the finger behind it with very little effort [I know, I've done it.] Use your first knuckle instead. That way the blade's edge never rises above it, meaning it can never be in the way of the cut.
See pic -
very hard photo to take, even with my camera on a tripod… I still needed one hand to fire the remote, so the knife is actually just resting halfway through the cut. Camera had to be behind me because of kitchen layout, with me contorting to not be in the way. Red onion, 'cos that's for dinner tonight ;)

Notice how that also forces your grip further back down the body of the onion, so until you get nearly 3/4 of the way through you don't have to change grip at all, just keep curling that forefinger more. The curl at this early point is exaggerated, so it's easier to see.
Also, in this position the finger on top can be used as additional downward pressure as you move the rest of your hand backwards, meaning everything is less likely to slip. Note fingers not actually gripping are providing additional stability on the board.