Quantifying habitat complexity in aquatic ecosystems