Book sales aren't going to go away. There have been some trends that have affected it, but to be honest it's partially the publishers' faults. Libraries have a tough job balancing budget, what people want to read, keeping stuff for reference, limited space etc. Academic libraries especially. But the publishers approached them with the option to have much of their collection be digital. No more re-shelving books, no stolen items, very easy for students and professors to find what they want! But the schools then have to pay a subscription for the books...and if they ever stop, those titles go away. Once a physical book is owned by someone, it can never go away. Most of the time you're paying for a license for a digital item (games and software, too) and the publisher has the right to change it or take it away from you. Personally I think that's really gross and predatory and takes advantages of libraries.
There's also a ton of books that aren't digital and probably never will be. Every time a celebrity or musician dies there's a run on their works or biographies, and you can buy a used copy for a few bucks or buy it new digitally for $15-20. Not everyone can afford to pay that much (and not everyone wants to give Amazon their money). You can't buy used digitally, and if there's works you want to enjoy and not give the author your money (such as JKR or Orson Scott Card), then used is the best way to do that.
Source: day job is eCommerce for books