refined footnote functionality - still rough