fixed .remove() replace with .detach() for after element