I want to figure out how to rotate the Y axis of surfaceCF to be the towardsCF Y axis

local towardsCF = CFrame.new(tP,tP+dir)
local surfaceCF = CFrame.new(tP,tP+dir2) -- I want the y of this cframe to be the y of the cframe above

-- MY ATTEMPTED SOLUTION ( DOES NOT WORK PROPERLY )
-- It kind of half way works but it is really wonky and I need a new solution!
local x,y,z = towardsCF:toObjectSpace(surfaceCF):toEulerAnglesXYZ()
surfaceCF = surfaceCF * CFrame.Angles(0,y,0)