From calculus 3, the gradient of $f(x,y,z)=x^2+y^2+z^2$ evaluated at any $(x,y,z)$ satisfying $f(x,y,z)=a$ is a vector that is perpendicular to the surface $f(x,y,z)=a$. Similarly for $g(x,y,z)=x+y^2+2z$, its gradient, and the surface $g=1$.
Note that $X_a$ and $Y$ are surfaces and, generically, they will be transverse. So it will be easier to find where they are _not_ transverse. If this happens, the tangent space of their intersection will fail to span 3-space. So, their tangent spaces will be the same. this happens whenever the normals are parallel, hence Jason's comment.
This is a long-winded way of saying use the method of lagrange multipliers: $$\
abla f=\lambda\
abla g$$ And, as usual in this situation, careful with your case analysis!