Prove that Two Angles Are Congruent in a Right Triangle In a right triangle $ABC$ with $\angle ACB$ the right angle, point $D$ is on the side $\overline{AB}$. Segment $\overline{BE}$ is perpendicular to $\overline{CD}$ and intersects $\overline{CD}$ at point $E$. Point $F$ is on $\overline{DE}$ such that $CE=EF$. Segment $\overline{FG}$ is perpendicular to $\overline{CD}$ and intersects $\overline{BD}$ at $G$.
Prove that $m\angle AFD=m\angle BCG$.

I am not familiar with results beyond geometry taught in high school. Maybe some ingenious auxiliary line can be drawn to solve the problem beautifully, but I cannot come up with any good idea.
 A: Set $X$ as the reflection of $F$ over the line $AB$. By Thales' theorem, we see that the quadrilateral $DFGX$ is cyclic. We can also see that $\overline{BC}=\overline{BF}=\overline{BX}$. It follows that $B$ is the circumcentre of the triangle $CFX$. Because $AC\perp BC$, the line $AC$ is tangent to this circle.
Now we see that $$\angle XGA=\angle XFD=\angle XCA,$$ where the second equality follows from $AC$ being tangent to the circle $CFX$. This means that the quadrilateral $ACGX$ is cyclic.
We finish the proof by noting that $$\angle GCB=\frac{\pi}{2}-\angle ACG=\frac{\pi}{2}-\pi+\angle GXA=\angle AFG-\frac{\pi}{2}=\angle AFD.$$
Remark: $ACGX$ being cyclic is a special case of Miquel's theorem for triangle $ADC$ and points $G$, $F$ and $C$.

A: 
Note that $\angle ACD = \angle CBE = 90- \angle ECB = \theta$. Apply the sine rule to the triangles ACF and BCG, respectively,
$$\frac{\sin(\alpha - \theta)}{\sin\alpha} = \frac{2a\sin\theta}b=2\cot\beta\sin\theta \\
\frac{\sin(\gamma + \beta)}{\sin\gamma} = \frac a{\frac{a\sin\theta}{\sin(\beta-\theta)}}
=\frac{\sin(\beta-\theta)}{\sin\theta}
$$
Simplify the two equations to get
\begin{align}
& \cos\theta -\cot\alpha \sin\theta = 2\cot\beta\sin\theta \\
& \cos\beta+\cot\gamma\sin\beta= \sin\beta \cot \theta-\cos\beta
\end{align}
which lead to
$$\cot\alpha = \cot\gamma = \cot\theta - 2\cot\beta$$
i.e, $\angle AFD= \angle BCG$.
