[guided]We want to prove that the first marginal of $\gamma$ is $\mu$. The definition of equality of marginals is a statement about measures on $X$, so we test against an arbitrary bounded continuous function
\begin{align*}
f: X &\to \mathbb{R}.
\end{align*}
The only convergence hypothesis we have concerns measures on $X \times Y$, so we convert $f$ into a function on the product. Define
\begin{align*}
F: X \times Y &\to \mathbb{R}
\end{align*}
by $F(x,y)=f(x)$. Equivalently, $F=f\circ p_X$, where $p_X:X\times Y\to X$ is the first coordinate projection. Since $p_X$ is continuous and $f$ is bounded and continuous, the composition $F$ is bounded and continuous on $X\times Y$.
Now the definition of weak convergence applies to this particular test function $F$:
\begin{align*}
\lim_{n \to \infty} \int_{X \times Y} F(x,y)\, d\gamma_n(x,y)
=
\int_{X \times Y} F(x,y)\, d\gamma(x,y).
\end{align*}
For every $n$, the assumption $\gamma_n\in\Pi(\mu,\nu)$ means precisely that the first pushforward marginal of $\gamma_n$ is $\mu$. Therefore integrating $f$ against that first marginal is the same as integrating $f\circ p_X$ against $\gamma_n$:
\begin{align*}
\int_{X \times Y} F(x,y)\, d\gamma_n(x,y)
=
\int_X f(x)\, d\mu(x).
\end{align*}
The right-hand side does not depend on $n$, so passing to the limit gives
\begin{align*}
\int_{X \times Y} F(x,y)\, d\gamma(x,y)
=
\int_X f(x)\, d\mu(x).
\end{align*}
By definition of the first marginal $\gamma_X=(p_X)_{\#}\gamma$, the left-hand side is
\begin{align*}
\int_{X \times Y} F(x,y)\, d\gamma(x,y)
=
\int_X f(x)\, d\gamma_X(x).
\end{align*}
Thus
\begin{align*}
\int_X f(x)\, d\gamma_X(x)
=
\int_X f(x)\, d\mu(x)
\end{align*}
for every bounded continuous function $f:X\to\mathbb{R}$. On a Polish space, Borel probability measures are uniquely determined by all bounded continuous real-valued test functions. Applying this uniqueness principle gives $\gamma_X=\mu$.[/guided]