open Printf
open Scanf

let (h,w) = sscanf (read_line ()) "%d %d" (fun x y -> (x,y));;
let array = Array.make h "";;
let _ =
for i = 0 to h-1 do
  let str = sscanf (read_line ()) "%s" (fun x -> x) in
  array.(i) <- str
done;;

let left = Array.init h (fun _ -> Array.make w 0);;
let right = Array.init h (fun _ -> Array.make w 0);;
let up = Array.init h (fun _ -> Array.make w 0);;
let down = Array.init h (fun _ -> Array.make w 0);;

let _  =
  for i = 0 to h-1 do
    for j = 0 to w-1 do

      if (array.(i).[j] = '#') then
        left.(i).(j) <- 0
      else if (j = 0) then
        left.(i).(j) <- 1
      else
        left.(i).(j) <- left.(i).(j-1) + 1;

      if (array.(i).[j] = '#') then
        up.(i).(j) <- 0
      else if (i = 0) then
        up.(i).(j) <- 1
      else
        up.(i).(j) <- up.(i-1).(j) + 1;

      let rj = w-1-j in
      if (array.(i).[rj] = '#') then
        right.(i).(rj) <- 0
      else if (rj = w-1) then
        right.(i).(rj) <- 1
      else
        right.(i).(rj) <- right.(i).(rj+1) + 1;

      let di = h-1-i in
      if (array.(di).[j] = '#') then
        down.(di).(j) <- 0
      else if (di = h-1) then
        down.(di).(j) <- 1
      else
        down.(di).(j) <- down.(di+1).(j) + 1
    done
  done;;

let ans = ref 0;;
let _  =
  for i = 0 to h-1 do
    for j = 0 to w-1 do
    let tmp = left.(i).(j) + right.(i).(j) + up.(i).(j) + down.(i).(j) - 3 in
    ans := max !ans (tmp)
  done
done;;
printf ("%d\n") !ans
