The p-filter: multi-layer FDR control for grouped hypotheses