added blue border for dirty and red border for invalid