A new Bernoulli–Euler beam model incorporating microstructure and surface energy effects