The shift shaft, from the top of the LU interface to the bottom end has 2 splines, one on the top end and the other on the bottom. The front of the LU casting has a U shaped bracket (cast in) and a hole is drilled through it which is where the shaft fits and is retained.
Inside the U (and it's a U on it's side....horizontal not vertical like the one I typed) fits the shift cam which has 3 detents that are different distances from the center of the pivot....aka the center of the shift shaft. To shift gears (gear to gear) it twists a few degrees.....10-20ish, don't remember. The first detent, nearest the pivot point , is F gear having the least pressure against the "cam follower" which is a slightly pointed cylinder, within the prop shaft that is spring loaded by a spring that's inside the front end of the prop shaft also right behind it. Some pressure is always on the to keep the clutch dog against the rear of the F gear, center area if in F gear.
There are 2 more positions which are farther from the pivot point and each corresponds to a position to operate N and R gears.
The clutch dog encircles the prop shaft and runs back and forth on it held in place with a pin through it and the follower so as the follower moves along the detents in the cam the follower moves the dog, thus doing the shifting. Side note here, as long as the engine is running the pinion on the bottom end of the DRIVE shaft keeps F and R gears rotating....they just aren't connected to the prop shaft unless the dog is engaged in that respective gear.
On the front of the dog are saw toothed gears that allow for overrunning (overrun clutch) when the prop is turning faster than the engine.......allows your engine to slow down and the prop follows as the slowing boat slows the water pressure across it. Center position of the clutch has the dog centered where it's not touching either gear (N) and the farthest position (out from the pivot point) is R which presses the cogs of the dog into the slots in the rear of the R gear putting you in Reverse.
Since it is of little access and the cam has pressure on it from the cam follower spring when it's where you want to use it, trying to get the splines lined up from the hole in the top is a real bear. As I recall the cam is about ⅜" thick give or take. If you could peer down the hole and see some of the spline of the cam, you may be able to move the spline over to the center of the hole.
You can look on the bottom spline on the shift shaft and see where the U bracket touches the shaft and where the cam is located. If there is some material on the bottom of the shaft, below the bottom of the lower half of the U bracket then I'd be tempted to grind the bottom of the shaft to somewhat of a point (cone) and with that done wiggle and tap and twist and see if you can't sneak the cam back into position so that you can push the shaft back in place.
If that doesn't worn the only thing I know to do is to pull the prop shaft and the F gear and bearings and spacers....keeping accurate count of what spacer is where and all and reach in and hold the cam in place while you restab the shaft.
I have done that and you don't have to remove the pinion gear on the DRIVE shaft. The F gear and all will slide out from under it.
Good luck. It's bed time and I don't want to read through this again. If I confused you, specify where and tomorrow am I'll respond.
Mark