updated opacity logic