[step:Use lower semicontinuity of the cost to prove optimality of the limiting plan]
Define the cost function $c:X \times X \to [0,\infty)$ by $c(x,y)=d(x,y)^p$. The metric $d$ is continuous on $X \times X$, hence $c$ is continuous and nonnegative. By lower semicontinuity of integrals of nonnegative lower semicontinuous functions under narrow convergence, applied on the Polish space $X \times X$ to the narrowly convergent sequence $(\pi_{N_j})_{j \in \mathbb{N}}$ and to the function $c$, we obtain
\begin{align*}
\int_{X \times X} d(x,y)^p \, d\pi(x,y) \leq \liminf_{j \to \infty} \int_{X \times X} d(x,y)^p \, d\pi_{N_j}(x,y)
\end{align*}
Since $\pi_{N_j}$ is optimal for the cost $d^p$ between $\mu_{N_j}$ and $\nu_{N_j}$, we have
\begin{align*}
\int_{X \times X} d(x,y)^p \, d\pi_{N_j}(x,y)=W_p(\mu_{N_j},\nu_{N_j})^p
\end{align*}
The convergence already proved gives
\begin{align*}
W_p(\mu_{N_j},\nu_{N_j})^p \to W_p(\mu,\nu)^p
\end{align*}
Therefore
\begin{align*}
\int_{X \times X} d(x,y)^p \, d\pi(x,y) \leq W_p(\mu,\nu)^p
\end{align*}
On the other hand, the previous step proved $\pi \in \Pi(\mu,\nu)$, so by the definition of $W_p$ as the infimum over all couplings,
\begin{align*}
W_p(\mu,\nu)^p \leq \int_{X \times X} d(x,y)^p \, d\pi(x,y)
\end{align*}
The two inequalities imply
\begin{align*}
\int_{X \times X} d(x,y)^p \, d\pi(x,y)=W_p(\mu,\nu)^p
\end{align*}
Thus $\pi$ is an optimal transport plan from $\mu$ to $\nu$ for the cost $d^p$.
[/step]