# input()
# int(input())
# map(int, input().split())
# list(map(int, input().split()))
# list(map(int, list(input()))) # スペースがない数字リストを読み込み
import math
import fractions
import sys
import bisect
import heapq  # 優先度付きキュー(最小値取り出し)
import collections
from collections import Counter
from collections import deque
import pprint
import itertools

sr = lambda: input()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

"""nを素因数分解"""
"""2以上の整数n => [[素因数, 指数], ...]の2次元リスト"""


def factorization(n):
    arr = []
    temp = n
    if n == 1:
        return arr

    for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr.append([i, cnt])

    if temp != 1:
        arr.append([temp, 1])

    if arr == []:
        arr.append([n, 1])

    return arr


# a^n
def power(a, n, mod):
    x = 1
    while n:
        if n & 1:
            x *= a % mod
        n >>= 1
        a *= a % mod
    return x % mod


# n*(n-1)*...*(l+1)*l
def kaijo(n, l, mod):
    if n == 0:
        return 1
    a = n
    tmp = n - 1
    while (tmp >= l):
        a = a * tmp % mod
        tmp -= 1
    return a


inf = 10 ** 18
mod = 10 ** 9 + 7

h,w = lr()
s = [input() for i in range(h)]
dicw = [[0 for j in range(w)] for i in range(h)]
dich = [[0 for j in range(w)] for i in range(h)]
# まずは横方向の情報を格納
for i in range(h):
    ind = 0
    now = 0
    while ind < w:
        now = 0
        while ind < w and s[i][ind] == '.':
            now+=1
            ind+=1
        for j in range(now):
            dicw[i][ind-1-j] = now
        ind+=1
for i in range(w):
    ind = 0
    now = 0
    while ind < h:
        now = 0
        while ind < h and s[ind][i] == '.':
            now+=1
            ind+=1
        for j in range(now):
            dich[ind-1-j][i] = now
        ind+=1

ans = 0
for i in range(h):
    for j in range(w):
        if s[i][j] == '.':
            ans = max(ans, dich[i][j]+dicw[i][j]-1)
print(ans) import math math import fractions fractions import sys sys import bisect bisect import heapq heapq import collections collections from collections import Counter from collections import deque import pprint pprint import itertools itertools sr = lambda: input() sr lambda: input() input() input ir = lambda: int(sr()) ir lambda: int(sr()) int(sr()) int sr() sr lr = lambda: list(map(int, sr().split())) lr lambda: list(map(int, sr().split())) list(map(int, sr().split())) list map(int, sr().split()) map int sr().split() ().split () sr split """nを素因数分解""" """2以上の整数n => [[素因数, 指数], ...]の2次元リスト""" def factorization(n):
    arr = []
    temp = n
    if n == 1:
        return arr

    for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr.append([i, cnt])

    if temp != 1:
        arr.append([temp, 1])

    if arr == []:
        arr.append([n, 1])

    return arr


# a^n factorization arr = [] arr [] temp = n temp n if n == 1:
        return arr

     n == 1 n 1 return arr arr for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr.append([i, cnt])

     i range(2, int(-(-n ** 0.5 // 1)) + 1) range 2 int(-(-n ** 0.5 // 1)) + 1 int(-(-n ** 0.5 // 1)) int -(-n ** 0.5 // 1) -n ** 0.5 // 1 -n ** 0.5 n ** 0.5 n 0.5 1 1 if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr.append([i, cnt])

     temp % i == 0 temp % i temp i 0 cnt = 0 cnt 0 while temp % i == 0:
                cnt += 1
                temp //= i
             temp % i == 0 temp % i temp i 0 cnt += 1 cnt 1 temp //= i temp i arr.append([i, cnt]) arr.append arr append [i, cnt] i cnt if temp != 1:
        arr.append([temp, 1])

     temp != 1 temp 1 arr.append([temp, 1]) arr.append arr append [temp, 1] temp 1 if arr == []:
        arr.append([n, 1])

     arr == [] arr [] arr.append([n, 1]) arr.append arr append [n, 1] n 1 return arr arr n n def power(a, n, mod):
    x = 1
    while n:
        if n & 1:
            x *= a % mod
        n >>= 1
        a *= a % mod
    return x % mod


# n*(n-1)*...*(l+1)*l power x = 1 x 1 while n:
        if n & 1:
            x *= a % mod
        n >>= 1
        a *= a % mod
     n if n & 1:
            x *= a % mod
         n & 1 n 1 x *= a % mod x a % mod a mod n >>= 1 n 1 a *= a % mod a a % mod a mod return x % mod x % mod x mod a a n n mod mod def kaijo(n, l, mod):
    if n == 0:
        return 1
    a = n
    tmp = n - 1
    while (tmp >= l):
        a = a * tmp % mod
        tmp -= 1
    return a kaijo if n == 0:
        return 1
     n == 0 n 0 return 1 1 a = n a n tmp = n - 1 tmp n - 1 n 1 while (tmp >= l):
        a = a * tmp % mod
        tmp -= 1
     tmp >= l tmp l a = a * tmp % mod a a * tmp % mod a * tmp a tmp mod tmp -= 1 tmp 1 return a a n n l l mod mod inf = 10 ** 18 inf 10 ** 18 10 18 mod = 10 ** 9 + 7 mod 10 ** 9 + 7 10 ** 9 10 9 7 h,w = lr() h lr() lr w input() for i in range(h) for i in range(h) i range(h) range h for i in range(h) input() input s = [input() for i in range(h)] s [input() for i in range(h)] [0 for j in range(w)] for i in range(h) for i in range(h) i range(h) range h for i in range(h) [0 for j in range(w)] dicw = [[0 for j in range(w)] for i in range(h)] dicw [[0 for j in range(w)] for i in range(h)] [0 for j in range(w)] for i in range(h) for i in range(h) i range(h) range h for i in range(h) [0 for j in range(w)] dich = [[0 for j in range(w)] for i in range(h)] dich [[0 for j in range(w)] for i in range(h)] for i in range(h):
    ind = 0
    now = 0
    while ind < w:
        now = 0
        while ind < w and s[i][ind] == '.':
            now+=1
            ind+=1
        for j in range(now):
            dicw[i][ind-1-j] = now
        ind+=1 i range(h) range h ind = 0 ind 0 now = 0 now 0 while ind < w:
        now = 0
        while ind < w and s[i][ind] == '.':
            now+=1
            ind+=1
        for j in range(now):
            dicw[i][ind-1-j] = now
        ind+=1 ind < w ind w now = 0 now 0 while ind < w and s[i][ind] == '.':
            now+=1
            ind+=1
         ind < w and s[i][ind] == '.' ind < w ind w s[i][ind] == '.' s[i][ind] [i] s i ind '.' now+=1 now 1 ind+=1 ind 1 for j in range(now):
            dicw[i][ind-1-j] = now
         j range(now) range now dicw[i][ind-1-j] = now dicw[i][ind-1-j] [i] dicw i ind-1-j ind-1 ind 1 j now ind+=1 ind 1 for i in range(w):
    ind = 0
    now = 0
    while ind < h:
        now = 0
        while ind < h and s[ind][i] == '.':
            now+=1
            ind+=1
        for j in range(now):
            dich[ind-1-j][i] = now
        ind+=1 i range(w) range w ind = 0 ind 0 now = 0 now 0 while ind < h:
        now = 0
        while ind < h and s[ind][i] == '.':
            now+=1
            ind+=1
        for j in range(now):
            dich[ind-1-j][i] = now
        ind+=1 ind < h ind h now = 0 now 0 while ind < h and s[ind][i] == '.':
            now+=1
            ind+=1
         ind < h and s[ind][i] == '.' ind < h ind h s[ind][i] == '.' s[ind][i] [ind] s ind i '.' now+=1 now 1 ind+=1 ind 1 for j in range(now):
            dich[ind-1-j][i] = now
         j range(now) range now dich[ind-1-j][i] = now dich[ind-1-j][i] [ind-1-j] dich ind-1-j ind-1 ind 1 j i now ind+=1 ind 1 ans = 0 ans 0 for i in range(h):
    for j in range(w):
        if s[i][j] == '.':
            ans = max(ans, dich[i][j]+dicw[i][j]-1) i range(h) range h for j in range(w):
        if s[i][j] == '.':
            ans = max(ans, dich[i][j]+dicw[i][j]-1) j range(w) range w if s[i][j] == '.':
            ans = max(ans, dich[i][j]+dicw[i][j]-1) s[i][j] == '.' s[i][j] [i] s i j '.' ans = max(ans, dich[i][j]+dicw[i][j]-1) ans max(ans, dich[i][j]+dicw[i][j]-1) max ans dich[i][j]+dicw[i][j]-1 dich[i][j]+dicw[i][j] dich[i][j] [i] dich i j dicw[i][j] [i] dicw i j 1 print(ans) print ans w = lr() lr() w h,w = lr() lr() h ind+=1 1 ind ans = max(ans, dich[i][j]+dicw[i][j]-1) max(ans, dich[i][j]+dicw[i][j]-1) ans ind+=1 1 ind lr = lambda: list(map(int, sr().split())) lambda: list(map(int, sr().split())) lr now = 0 0 now ans = 0 0 ans mod = 10 ** 9 + 7 10 ** 9 + 7 mod now = 0 0 now now = 0 0 now now = 0 0 now ir = lambda: int(sr()) lambda: int(sr()) ir ind = 0 0 ind dich = [[0 for j in range(w)] for i in range(h)] [[0 for j in range(w)] for i in range(h)] dich def kaijo(n, l, mod):
    if n == 0:
        return 1
    a = n
    tmp = n - 1
    while (tmp >= l):
        a = a * tmp % mod
        tmp -= 1
    return a def kaijo(n, l, mod):
    if n == 0:
        return 1
    a = n
    tmp = n - 1
    while (tmp >= l):
        a = a * tmp % mod
        tmp -= 1
    return a kaijo dicw = [[0 for j in range(w)] for i in range(h)] [[0 for j in range(w)] for i in range(h)] dicw sr = lambda: input() lambda: input() sr now+=1 1 now now+=1 1 now def power(a, n, mod):
    x = 1
    while n:
        if n & 1:
            x *= a % mod
        n >>= 1
        a *= a % mod
    return x % mod


# n*(n-1)*...*(l+1)*l def power(a, n, mod):
    x = 1
    while n:
        if n & 1:
            x *= a % mod
        n >>= 1
        a *= a % mod
    return x % mod


# n*(n-1)*...*(l+1)*l power inf = 10 ** 18 10 ** 18 inf def factorization(n):
    arr = []
    temp = n
    if n == 1:
        return arr

    for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr.append([i, cnt])

    if temp != 1:
        arr.append([temp, 1])

    if arr == []:
        arr.append([n, 1])

    return arr


# a^n def factorization(n):
    arr = []
    temp = n
    if n == 1:
        return arr

    for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr.append([i, cnt])

    if temp != 1:
        arr.append([temp, 1])

    if arr == []:
        arr.append([n, 1])

    return arr


# a^n factorization ind = 0 0 ind ind+=1 1 ind ind+=1 1 ind s = [input() for i in range(h)] [input() for i in range(h)] s
# input()
# int(input())
# map(int, input().split())
# list(map(int, input().split()))
# list(map(int, list(input()))) # スペースがない数字リストを読み込み
import math
import fractions
import sys
import bisect
import heapq  # 優先度付きキュー(最小値取り出し)
import collections
from collections import Counter
from collections import deque
import pprint
import itertools

sr = lambda: input()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

"""nを素因数分解"""
"""2以上の整数n => [[素因数, 指数], ...]の2次元リスト"""


def factorization(n):
    arr = []
    temp = n
    if n == 1:
        return arr

    for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr.append([i, cnt])

    if temp != 1:
        arr.append([temp, 1])

    if arr == []:
        arr.append([n, 1])

    return arr


# a^n
def power(a, n, mod):
    x = 1
    while n:
        if n & 1:
            x *= a % mod
        n >>= 1
        a *= a % mod
    return x % mod


# n*(n-1)*...*(l+1)*l
def kaijo(n, l, mod):
    if n == 0:
        return 1
    a = n
    tmp = n - 1
    while (tmp >= l):
        a = a * tmp % mod
        tmp -= 1
    return a


inf = 10 ** 18
mod = 10 ** 9 + 7

h,w = lr()
s = [input() for i in range(h)]
dicw = [[0 for j in range(w)] for i in range(h)]
dich = [[0 for j in range(w)] for i in range(h)]
# まずは横方向の情報を格納
for i in range(h):
    ind = 0
    now = 0
    while ind < w:
        now = 0
        while ind < w and s[i][ind] == '.':
            now+=1
            ind+=1
        for j in range(now):
            dicw[i][ind-1-j] = now
        ind+=1
for i in range(w):
    ind = 0
    now = 0
    while ind < h:
        now = 0
        while ind < h and s[ind][i] == '.':
            now+=1
            ind+=1
        for j in range(now):
            dich[ind-1-j][i] = now
        ind+=1

ans = 0
for i in range(h):
    for j in range(w):
        if s[i][j] == '.':
            ans = max(ans, dich[i][j]+dicw[i][j]-1)
print(ans)
