8.
已知向量\( \overset{⇀}{m}=(\cos \dfrac{x}{2}, \dfrac{1}{2}\cos \dfrac{x}{2}) \),\( \overset{⇀}{n}=( \dfrac{1}{2}\sin \dfrac{x}{2}, \sqrt{3}\cos \dfrac{x}{2}) \),\(x\in [0,\pi ]\).
\((1)\)设函数\(f(x)=\overrightarrow{m}\cdot \overrightarrow{n}\),求函数\(f(x)\)的最大值和最小值以及对应的\(x\)值;
\((2)\)若\(\overrightarrow{m}/\!/\overrightarrow{n}\),求\(\tan x\)的值.