Use visibility instead of display.