[guided]The construction is designed so that the graph coordinate becomes a flat coordinate. Define
\begin{align*}
\Psi: C \to \Psi(C)
\end{align*}
by
\begin{align*}
\Psi(z',z_n)=(z',\sigma(z_n-\gamma(z'))).
\end{align*}
The first $n-1$ coordinates are unchanged, and the last coordinate is the signed vertical distance from the graph $z_n=\gamma(z')$. Since $\gamma \in C^k(O)$ and affine coordinate functions are smooth, each component of $\Psi$ is of class $C^k$ on $C$.
To prove that this map is a diffeomorphism onto its image, we explicitly construct its inverse. Define
\begin{align*}
\Theta: \Psi(C) \to C
\end{align*}
by
\begin{align*}
\Theta(y',y_n)=(y',\gamma(y')+\sigma y_n).
\end{align*}
This formula reverses the flattening operation: after the signed height $y_n$ is known, adding the graph height $\gamma(y')$ restores the original final coordinate.
For every $(z',z_n) \in C$, substituting $\Psi(z',z_n)$ into $\Theta$ gives
\begin{align*}
\Theta(\Psi(z',z_n))=(z',\gamma(z')+\sigma^2(z_n-\gamma(z')))=(z',z_n),
\end{align*}
because $\sigma \in \{1,-1\}$ implies $\sigma^2=1$. Conversely, for every $(y',y_n) \in \Psi(C)$,
\begin{align*}
\Psi(\Theta(y',y_n))=(y',\sigma(\gamma(y')+\sigma y_n-\gamma(y')))=(y',y_n).
\end{align*}
Thus $\Theta=\Psi^{-1}$ on $\Psi(C)$.
It remains to check that the target is open, because a diffeomorphism is a map between open sets. From the inverse formula, a point $(y',y_n)$ belongs to $\Psi(C)$ exactly when $y' \in O$ and the reconstructed coordinate $\gamma(y')+\sigma y_n$ lies in $(-\rho,\rho)$. Hence
\begin{align*}
\Psi(C)=\{(y',y_n) \in \mathbb{R}^n : y' \in O \text{ and } |\gamma(y')+\sigma y_n|<\rho\}.
\end{align*}
The set $O$ is open, the map $(y',y_n) \mapsto \gamma(y')+\sigma y_n$ is continuous, and $(-\rho,\rho)$ is open. Therefore $\Psi(C)$ is open in $\mathbb{R}^n$. Since both $\Psi$ and its inverse $\Theta$ are of class $C^k$, $\Psi$ is a $C^k$ diffeomorphism from $C$ onto $\Psi(C)$.[/guided]