While is not an adverb; it is the entire phrase headed by while which acts as an adverb.
In traditional grammar while is classified as a subordinating conjunction, because it joins a full declarative subordinate clause (you sleep in your example) to the main clause.
But the widely-followed Cambridge Grammar of the English Language (Huddleston and Pullum, 2002) disputes this classification, arguing that it makes no sense to classify terms on the basis of the sort of complements they take. We do not reclassify verbs when they take clausal complements instead of nominal complements, or no complement at all. CGEL classifies while as a preposition:
We therefore include in the preposition category all of the subordinating conjunctions of traditional grammar, with three exceptions. The exceptions are, first, whether; second, those occurrences of if that are equivalent to whether [...]; and, third, that when it introduces a subordinate clause. (CGEL, 600)