main page bg image resize routine