4. As shown in Figure 1, in the right triangle $\triangle ABC$, $AC=4, BC=3$, $\angle ACB=90^{\circ}$. Quadrilaterals $DEFG$ and $GHIJ$ are both squares, point $E$ is on $AC$, point $I$ is on $BC$, and $J$ is the midpoint of side $DG$. Then the length of $GH$ is ( ).
(A) $\frac{19}{21}$
(B) 1
(C) $\frac{60}{77}$
(D) $\frac{180}{259}$
4. C.

Let $G H=x$. Then
$$
\begin{array}{l}
H B=\frac{3}{4} x, F G=2 x, A F=\frac{4}{3} F G=\frac{8}{3} x . \\
\text { So } 5=A B=A F+F G+G H+H B \\
=\frac{8}{3} x+2 x+x+\frac{3}{4} x=\frac{77}{12} x \\
\Rightarrow x=\frac{60}{77} .
\end{array}
$$