From the point of view of graph theory, it is well known that median graphs (i.e. one-skeleta of CAT(0) cube complexes) embeds isometrically in Hamming cubes. An approach I like uses *restricted quotients*, which have other nice applications.

**Restricted quotients.** Given a CAT(0) cube complex $X$ and a collection of hyperplanes $\mathcal{J}$, define the pseudo-metric $d_\mathcal{J} : X^{(0)} \times X^{(0)} \to \mathbb{N}$ as
$$(x,y) \mapsto \text{number of hyperplanes in $\mathcal{J}$ separating $x,y$.}$$
The restricted quotient $X_\mathcal{J}$ is the cube complex obtained by *cubulating* the wallspace $(X, \mathcal{J})$. Such a cube complex can be defined in many different ways, but the key point to keep in mind is that its vertex-set is the quotient of $X^{(0)}$ by the equivalence relation: $x \sim_\mathcal{J} y$ if $d_\mathcal{J}(x,y)=0$.

For instance, start from the dual graph $\Gamma$ of $X \backslash \bigcup_{J\in \mathcal{J}} J$, i.e. the graph whose vertices are the connected components of $X \backslash \bigcup_{J\in \mathcal{J}} J$ and whose edges link two components if they are separated by a unique hyperplane. Then $X_\Gamma$ coincides with the cube complex obtained from $\Gamma$ by filling in all the subgraphs isomorphic to one-skeleta of $k$-cubes with $k$-cubes for every $k \geq 2$.

There is clearly a surjective map $\pi_\mathcal{J} : X \twoheadrightarrow X_\mathcal{J}$ (obtained by sending each vertex of $X$ to the vertex of $X_\mathcal{J}$ corresponding to the component that contains $x$). Moreover,
$$d_{X_\mathcal{J}}(\pi_\mathcal{J}(x),\pi_\mathcal{J}(y)) = d_\mathcal{J}(x,y) \text{ for all vertices $x,y \in X$.}$$
(Here, my cube complexes are endowed with $\ell^1$-metrics.)

**Constructing embeddings.** Because the distance in $X$ between any two vertices coincides with the number of hyperplanes that separate them, it follows that, for every partition $\{ \mathcal{J}_i, \ i \in I\}$ of the hyperplanes of $X$, then
$$\bigoplus\limits_{i \in I} \pi_{\mathcal{J}_i} : X \to \bigoplus\limits_{i \in I} X_{\mathcal{J}_i}$$
is an isometric embedding of $X$ into a product of CAT(0) cube complexes (namely, the restricted quotients).

**Application 1:** If our partition is $\{ \{J\}, \text{ $J$ hyperplane}\}$, then each restricted quotient is a single edge and one obtains an isometric embedding of $X$ into an infinite-dimensional cube $[0,1]^I$.

**Application 2:** Let $\Delta X$ denote the *crossing graph* of $X$, i.e. the graph whose vertices are the hyperplanes of $X$ and whose edges link two hyperplanes if they are transverse. Let $\chi$ denote the chromatic graph of $\Delta X$. By considering the partition of the hyperplanes of $X$ induced by a coloring of $\Delta X$ with $\chi$ colors, one obtains an isometric embedding of $X$ into a product of $\chi$ simplicial trees.