Atmospheric carbon dioxide dissolves in seawater to form carbonic acid.
\[
\mathrm{CO_2 + H_2O \rightarrow H_2CO_3}
\]
This lowers the pH of seawater, causing ocean acidification.
Hence,
\[
\boxed{\mathrm{CO_2}}
\]
is the correct answer.
Therefore,
\[
\boxed{(B)}
\]