We show that for every $\varepsilon >0$, there exists $X$ such that $f(x) \le \varepsilon$ when $x>X$. This statement implies that $\limsup_{x\to\infty} f(x) \le 0$; then replacing $f(x)$ by $-f(x)$ immediately shows that $\liminf_{x\to\infty} f(x) \ge 0$, which finishes the proof that $\lim_{x\to\infty} f(x) = 0$.
By hypothesis, we can choose $W$ such that $f(x) + f'(x) < \frac\varepsilon2$ for all $x\ge W$. We claim there must be a point $X\ge W$ for which $f(X) \le \varepsilon$. Indeed, if $f(W) \le \varepsilon$ then set $X=W$; otherwise, note that $f'(x) < -f(x) + \frac\varepsilon2 < -\frac\varepsilon2$ for all $x\ge W$ for which $f(x) \ge \varepsilon$. In particular, $f(x) \le f(W) - \frac\varepsilon2(x-W)$ for all $x\ge W$ until $f(x) \le \varepsilon$; therefore there must be such an $X$ in the interval $[W,W+\frac2\varepsilon(f(W)-\varepsilon)]$.
Now we show that $f(x)\le\varepsilon$ for all $x\ge X$. Suppose not: choose $z>X$ such that $f(z) > \varepsilon$. The continuous function $f$ has a maximum on the interval $[X,z]$; it's not at $X$ since $f(z)>f(X)$, and it's not at $z$ because $f'(z) < -f(z) + \frac\varepsilon2 < -\frac\varepsilon2$ and so the values of $f$ just to the left of $z$ are larger than $f(z)$. Therefore there exists $y\in(X,z)$ that is a local maximum of $f$. Consequently $f'(y)=0$ and $f(y)\ge f(z) > \varepsilon$, so that $f(y)+f'(y) > \varepsilon$; but this $y>X\ge W$, contradicting the choice of $W$.