Improved loading script and styles