This paper analyzes optimal media planning strategies in a pricing-advertising competition model where firms can use mass and specialized advertising. We find that although targeted advertising avoids the wasting of ads, firms might find it optimal to mix specialized advertising with the mass media. We also show that the characteristics of the specialized media available crucially affect the outcome of price competition between firms, which can range from a full fragmentation of the market into local monopolies to lower average prices (compared to the case where firms had only mass advertising available). Regarding welfare, we prove that although the use of specialized advertising can lower consumer surplus and drive a fragment of consumers out of the market, this advertising technology is welfare-improving, and can be Pareto superior.