refactory 2nd floating window layout and animation