12. Let the parabola $y=x^{2}+(2 a+1) x+2 a+$ $\frac{5}{4}$ intersect the $x$-axis at only one point.
(1) Find the value of $a$;
(2) Find the value of $a^{18}+32 a^{-6}$.
12. (1) Since the parabola intersects the $x$-axis at only one point, the quadratic equation $x^{2}+(2 a+1) x+2 a+\frac{5}{4}=0$ has two equal real roots. Therefore,
$$
\Delta=(2 a+1)^{2}-4\left(2 a+\frac{5}{4}\right)=0,
$$

which simplifies to $a^{2} \cdots a-1=0$.
$$
\ldots a=\frac{1 \pm \sqrt{5}}{2} \text {. }
$$
(2) From (1), we know that $a^{2}=a+1$. Repeatedly using this identity, we get
$$
\begin{aligned}
a^{4} & =(a+1)^{2}=a^{2}+2 a+1=3 a+2, \\
a^{8} & =(3 a+2)^{2}=9 a^{2}+12 a+4=21 a+13, \\
a^{16} & =(21 a+13)^{2}=441 a^{2}+546 a+169 \\
& =987 a+610, \\
a^{18} & =(987 a+610)(a+1) \\
& =987 a^{2}+1597 a+610=2584 a+1597 .
\end{aligned}
$$
$$
\begin{array}{l}
\text { Also, } a^{-6}=\frac{1}{a^{6}}=\frac{1}{a^{4} \cdot a^{2}}=\frac{1}{(3 a+2)(a+1)} \\
\quad=\frac{1}{8 a+5} . \\
\because a^{2}-a-1=0, \\
\therefore 64 a^{2}-64 a-65=-1,
\end{array}
$$

which means
$$
\begin{array}{l}
(8 a+5)(8 a-13)=-1 . \\
\therefore a^{-6}=\frac{1}{8 a+5}=-8 a+13 . \\
\therefore a^{18}+323 a^{-6} \\
\quad=2584 a+1597+323(-8 a+13) \\
\quad=5796 .
\end{array}
$$