Optimal orthogonal drawings of planar 3-graphs in linear time