H, W = gets.split.map(&:to_i)
map = []
pos = []
H.times do |i|
  map << gets.chomp.chars
  pos << []
  W.times do
    pos[i] << [0, 0] # [Hight,  Width]
  end
end

ans = 0

H.times do |y|
  W.times do |x|
    if map[y][x] == '.'
      # 上
      if y != 0
        if pos[y-1][x][0] != 0
          pos[y][x][0] = pos[y-1][x][0]
        end
      end

      # 左
      if x != 0
        if pos[y][x-1][1] != 0
          pos[y][x][1] = pos[y][x-1][1]
        end
      end

      if pos[y][x][0] == 0
        # 下見る
        under = 0
        (y).upto(H-1) do |i|
          if map[i][x] == '.'
            under += 1
          else
            break
          end
        end
        pos[y][x][0] = under
      end

      if pos[y][x][1] == 0
        # 右見る
        right = 0
        (x).upto(W-1) do |i|
          if map[y][i] == '.'
            right += 1
          else
            break
          end
        end
        pos[y][x][1] = right
      end

      tmp = pos[y][x][0] + pos[y][x][1] - 1
      ans = tmp if ans < tmp
      if ans == W + H - 1
        puts ans
        exit
      end
    end
  end
end

puts ans