Is Nibbana a state of mind or an element (dhamma)?
Nibbana is asankhata dhatu (unconditioned element or unconditioned dhamma) therefore it is not a state of mind (MN 115).

Insight wisdom (vipassana) into the three characteristics uproots craving (SN 22.59).  

Nibbana is a sense object (ayatana) of mind consciousness (Ud 8.1) but it is not a type of consciousness. This is why 'mind-objects' are called 'dhamme'; because they also include Nibbana. 

It is because Nibbana is not a state of mind that a stream winner can taste the peace of Nibbana; even though their mind is not completely pure. This can be compared to feeling a cool breeze on a warm sunny day. Because the breeze is one thing &amp; the sun is another thing, both the cool breeze &amp; warm sun can be experienced together. Similarly, the cool peace of Nibbana (experienced from non-attachment) can be experienced by the stream-winner, even though the mind is not completely pure &amp; cooled. 

This said, when a stream-winner is in the stream, their mind is without asava (MN 117). In other words, it is inaccurate to say a stream-winner has craving; as though they always have craving. A stream-winner only has craving when their mindfulness has lapsed. 

In conclusion, the mind attains Nibbana by using Path concentration &amp; insight wisdom to uproot craving. The suttas say the Path (of concentration &amp; insight) is conditioned. Therefore, the mind does not uproot craving by attaining Nibbana. First craving is uprooted using wisdom and what remains leftover is experiencing the peaceful element of Nibbana. SN 22.59 says: 


  Seeing thus [with insight wisdom], the well-instructed disciple of the noble ones grows disenchanted with form, disenchanted with feeling, disenchanted with
  perception, disenchanted with fabrications, disenchanted with
  consciousness. Disenchanted, he becomes dispassionate [uproots craving]. Through
  dispassion, he is fully released [Nibbana]. With full release, there is the
  knowledge, 'Fully released.' He discerns that 'Birth is ended, the
  holy life fulfilled, the task done. There is nothing further for this
  world.'