to measure the mast correctly side by side, take a long metal tape and raise it using the main halyard. Then go to one side of the boat just forward of the shroud chain plate and then measure in the same spot on the other side of the boat. Then adjust sideways by loosening or tightening the upper shrouds to get the top of the mast in the middle of the boat with the lowers loose of course.
The go and look up the back side of the mast along the sail track and straighten the sail track with the lowers. From there, always tighten in have turns equally for the uppers and of course for the lowers.
What you want with the mast rake backwards, I would have equal adjustments in the forestay and upper shrouds turnbuckles within the turnbuckle bodies. I would then take the main halyard and add some weight so I could see with the mast up of course 4-5 inches of distance from that line to the back of the mast where the boom attaches. Using the lower, I would tighten to bring the mast back. You want some minor bend in the mast.
With the upper shrouds when I could pull inward with two fingers 1-2 inches, that was pretty close and then adjusted the lowers which generally the lowers are tighter. Take the boat out and see if the mast bends sideways and readjust. If you have a little weather helm, that is good. If too much, then move the mast forward.
There is more but this should help.