Let the angles that the line makes with the positive X, Y, and Z axes be $\alpha, \beta, \gamma$ respectively.
We are given $\alpha = 60^\circ$, $\beta = 45^\circ$, and $\gamma = \theta$.
The direction cosines of the line are $l = \cos\alpha$, $m = \cos\beta$, and $n = \cos\gamma$.
The fundamental identity for direction cosines states that the sum of their squares is equal to 1:
$l^2+m^2+n^2=1$, which is equivalent to $\cos^2\alpha + \cos^2\beta + \cos^2\gamma = 1$.
Substitute the given angles into this identity:
$\cos^2(60^\circ) + \cos^2(45^\circ) + \cos^2\theta = 1$.
We know the values of the cosine function for these angles:
$\cos(60^\circ) = \frac{1}{2}$ and $\cos(45^\circ) = \frac{1}{\sqrt{2}}$.
Substitute these values into the equation:
$\left(\frac{1}{2}\right)^2 + \left(\frac{1}{\sqrt{2}}\right)^2 + \cos^2\theta = 1$.
$\frac{1}{4} + \frac{1}{2} + \cos^2\theta = 1$.
$\frac{1+2}{4} + \cos^2\theta = 1 \implies \frac{3}{4} + \cos^2\theta = 1$.
$\cos^2\theta = 1 - \frac{3}{4} = \frac{1}{4}$.
Taking the square root, we get $\cos\theta = \pm\sqrt{\frac{1}{4}} = \pm\frac{1}{2}$.
The problem states that $\theta$ is an acute angle, which means $0^\circ<\theta<90^\circ$. In this quadrant, the cosine function is positive.
Therefore, we must take the positive value: $\cos\theta = \frac{1}{2}$.
The acute angle $\theta$ for which $\cos\theta = \frac{1}{2}$ is $\theta = 60^\circ$.
The question asks for the value of $\tan\theta$.
$\tan\theta = \tan(60^\circ) = \sqrt{3}$.