5. Let $f(x)=x^{3}+\log _{2}\left(x+\sqrt{x^{2}+1}\right)$. Then for any real numbers $a, b, a+b \geqslant 0$ is a ( ) for $f(a)+f(b) \geqslant 0$.
(A) sufficient and necessary condition
(B) sufficient but not necessary condition
(C) necessary but not sufficient condition
(D) neither sufficient nor necessary condition
5.A.

Obviously, $f(x)=x^{3}+\log _{2}\left(x+\sqrt{x^{2}+1}\right)$ is an odd function and monotonically increasing. Therefore, if $a+b \geqslant 0$, then $a \geqslant-b$, so $f(a) \geqslant f(-b)$, which means $f(a) \geqslant-f(b)$. Thus, $f(a)+f(b) \geqslant 0$.

Conversely, if $f(a)+f(b) \geqslant 0$, then $f(a) \geqslant-f(b)=$ $f(-b)$, which implies $a \geqslant-b$, i.e., $a+b \geqslant 0$.