optimize some styles