We provide a new collection of spectra of 35 carbon stars obtained with the ESO/VLT X-shooter instrument as part of the X-shooter Spectral Library project. The spectra extend from 0.3um to 2.4um with a resolving power above ~8000. The sample contains stars with a broad range of (J-K) color and pulsation properties located in the Milky Way and the Magellanic Clouds. We show that the distribution of spectral properties of carbon stars at a given (J-K) color becomes bimodal (in our sample) when (J-K) is larger than about 1.5. We describe the two families of spectra that emerge, characterized by the presence or absence of the absorption feature at 1.53um, generally associated with HCN and C_2_H_2_. This feature appears essentially only in large-amplitude variables, though not in all observations. Associated spectral signatures that we interpret as the result of veiling by circumstellar matter, indicate that the 1.53um feature might point to episodes of dust production in carbon-rich Miras.