Concept:
The required area is obtained by splitting the region at the point of intersection of
\[
y=\cos x
\]
and
\[
y=\tan x.
\]
Step 1: Find the point of intersection.
\[
\cos x=\tan x.
\]
\[
\cos x=\frac{\sin x}{\cos x}.
\]
\[
\cos^2x=\sin x.
\]
Using
\[
\cos^2x=1-\sin^2x,
\]
\[
1-\sin^2x=\sin x.
\]
\[
\sin^2x+\sin x-1=0.
\]
Let
\[
\sin x=t.
\]
Then
\[
t^2+t-1=0.
\]
\[
t=\frac{\sqrt5-1}{2}.
\]
Hence
\[
\sin\alpha=\frac{\sqrt5-1}{2},
\]
where \(\alpha\) is the point of intersection.
Step 2: Write the area integral.
For
\[
0\le x\le \alpha,
\]
\[
\tan x\le \cos x.
\]
For
\[
\alpha\le x\le \frac{\pi}{2},
\]
\[
\cos x\le \tan x.
\]
Hence,
\[
A
=
\int_0^\alpha \tan x\,dx
+
\int_\alpha^{\pi/2}\cos x\,dx.
\]
Step 3: Evaluate the integrals.
\[
A
=
\left[-\log(\cos x)\right]_0^\alpha
+
\left[\sin x\right]_\alpha^{\pi/2}.
\]
\[
=
-\log(\cos\alpha)
+
1-\sin\alpha.
\]
Since
\[
\sin\alpha=\frac{\sqrt5-1}{2},
\]
\[
1-\sin\alpha
=
1-\frac{\sqrt5-1}{2}
=
\frac{3-\sqrt5}{2}.
\]
Also,
\[
\cos^2\alpha
=
1-\sin^2\alpha.
\]
Using
\[
\sin\alpha=\frac{\sqrt5-1}{2},
\]
\[
\cos^2\alpha
=
\frac{\sqrt5-1}{2}.
\]
Therefore,
\[
\cos\alpha
=
\sqrt{\frac{\sqrt5-1}{2}}.
\]
Hence,
\[
-\log(\cos\alpha)
=
-\frac12
\log\left(\frac{\sqrt5-1}{2}\right).
\]
Using
\[
\frac{2}{\sqrt5-1}
=
\frac{\sqrt5+1}{2},
\]
\[
-\frac12
\log\left(\frac{\sqrt5-1}{2}\right)
=
\frac12
\log\left(\frac{\sqrt5+1}{2}\right).
\]
Thus,
\[
A
=
\frac{3-\sqrt5}{2}
+
\frac12
\log\left(\frac{\sqrt5+1}{2}\right).
\]
Therefore,
\[
\boxed{
A=
\frac{3-\sqrt5}{2}
+
\frac12
\log\left(\frac{\sqrt5+1}{2}\right)
}
\]
\[
\boxed{\text{Answer = (D)}}
\]