  The solar photospheric magnetic field is highly structured owing to its
interaction with the convective flows. Its local structure has a strong
influence on the profiles of spectral lines not only by virtue of the Zeeman
effect, but also through the modification of the thermodynamical structure
(e.g. line weakening in hot small-scale magnetic structures). Many stars harbor
surface magnetic fields comparable to or larger than the Sun at solar maximum.
Therefore, a strong influence of the field on the surface convection and on
spectral line profiles can be expected. We carried out 3D local-box MHD
simulations of unipolar magnetized regions (average fields of 20, 100, and
500G) with parameters corresponding to six main-sequence stars (spectral types
F3V to M2V). The influence of the magnetic field on the convection and the
local thermodynamical structure were analyzed in detail. For three spectral
lines, we determined the impact of the magnetic field on the disc-integrated
Stokes-I profiles. Line weakening has in many cases a stronger impact on the
spectral line profiles than the Zeeman effect. Moreover, for some stars, the
correlation between the magnetic field and the vertical velocity strongly
influences the line shapes. These effects can impair determinations of stellar
magnetic fields since currently used methods neglect the local structure of the
magnetic field and its interaction with the convective flows. The MHD
simulations presented can be used to quantify these effects and thus help to
improve magnetic field measurements of cool main-sequence stars.
