code: def realign_seqs(block, gap_char='.', align_indels=False):
      all_chars = [list(sq['seq']) for sq in block['sequences']]
      nrows = len(all_chars)
      i = 0
      while i < len(all_chars[0]):
          rows_need_gaps = [r for r in all_chars if not r[i].islower()]
          if len(rows_need_gaps) != nrows:
              for row in rows_need_gaps:
                  row.insert(i, gap_char)
          i += 1
      return [''.join(row) for row in all_chars]