Equivalence relation induced by a group action is an analytic set

We say that $$X$$ is a standard Borel space iff it is a Polish space equipped with the Borel $$\sigma$$-algebra. Similarly, a standard Borel group is a Polish group s.t. multiplication and inversion are both Borel maps. These concepts are very common in Classical Descriptive Set Theory and in order to justify these definitions, Kechris (pp. $$92$$, row $$-3$$) provides the following example:

Let $$X$$ be a standard Borel space and $$G$$ a standard Borel group acting on it as a Borel map. If $$E_G$$ denotes the equivalence relation induced by this action $$x E_G y \iff \exists g\in G(g.x=y),$$ it is easy to verify that $$E$$ is analytic in $$X^2$$.

How should a proof look like?

Recall that a subset $$A$$ of a standard Borel space $$X$$ is analytic iff there exists $$Y$$ Polish space and $$f$$ Borel bijection from $$X$$ to $$Y$$ s.t. $$f(A)$$ is analytic in $$Y$$.

I apologize for this low-level question, but looking at this I don't see how to put together these informations to get a proof. Thank you in advance for your help.

The definition of an analytic subset $$A$$ of a standard Borel space $$X$$ is probably better understood in view of Kechris's Exercise 14.6: there is a standard Borel space $$Z$$ and a Borel function $$f : Z \to X$$ such that $$A = f(Z)$$.
Here, note that $$X^2$$ and $$G \times X^2$$ are standard Borel spaces. Consider the map $$f : G \times X^2 \to X^2$$ defined by $$f(g,x,y) = (g \cdot x, y)$$, which is a Borel function because the group action is Borel, and let $$D = \{(x,x) : x \in X\} \subset X^2$$ be the diagonal of $$X^2$$. Note that $$D$$ is a Borel set in $$X^2$$ and so $$B = f^{-1}(D)$$ is a Borel set in $$G \times X^2$$.
Now let $$\pi : G \times X^2 \to X^2$$ be the projection $$\pi(g,x,y) = (x,y)$$. This also is a Borel function, and it should be straightforward to verify that $$\pi(B) = E$$. Since a Borel subset of a standard Borel space is itself a standard Borel space, this shows that $$E$$ is analytic.