.treeview ul { padding: 0; margin: 0; } .treeview li { padding: 0; margin: 0; list-style-type: none; list-style-image: none; } .treeview li li { background: url("https://dinonews.net/wiki/images/Treeview-grey-line.png") no-repeat 0 -2981px; padding-left: 20px; text-indent: 0.3em; } .treeview li .lastline { background-position: 0 -5971px; } .treeview li.emptyline > ul { margin-left: -1px; } .treeview li.emptyline > ul > .mw-empty-elt:first-child + .emptyline, .treeview li.emptyline > ul > li:first-child { background-position: 0 9px; }