#include <bits/stdc++.h>
using namespace std;

struct init_ { init_(){ cin.tie(nullptr); ios::sync_with_stdio(false); cout << fixed << setprecision(10); } } init_;

template<class C> using iodef_rng_t = typename enable_if<decltype(declval<C>().begin(), true_type{})::value && !is_same<C, string>::value>::type;
template<class C, class = iodef_rng_t<C>> istream& operator>>(istream& in, C& c) { for (auto& v : c) { in >> v; } return in; }
template<class C, class = iodef_rng_t<C>> ostream& operator<<(ostream& out, const C& c) { int i = 0; for (const auto& v : c) { if (i++) { out << ' '; } out << v; } return out; }
template<size_t N, class T, class R> using when_last = typename enable_if<N == tuple_size<remove_reference_t<T>>::value - 1, R>::type;
template<size_t N, class T, class R> using when_init = typename enable_if<N != tuple_size<remove_reference_t<T>>::value - 1, R>::type;
template<size_t N = 0, class T> auto operator>>(istream& in, T&& t) -> when_last<N, T, istream&> { return in >> get<N>(t); }
template<size_t N = 0, class T> auto operator>>(istream& in, T&& t) -> when_init<N, T, istream&> { return operator>><N + 1>(in >> get<N>(t), forward<T>(t)); }
template<size_t N = 0, class T> auto operator<<(ostream& out, const T& t) -> when_last<N, T, ostream&> { return out << get<N>(t); }
template<size_t N = 0, class T> auto operator<<(ostream& out, const T& t) -> when_init<N, T, ostream&> { return operator<<<N + 1>(out << get<N>(t) << ' ', t); }

#ifdef LOCAL
template<class T> void trace_(const char* s, const T& v) { cerr << s << "=" << v; }
template<class T, class... Ts> void trace_(const char* s, const T& v, const Ts&... vs) { for (; *s != ','; ++s) { cerr << *s; } cerr << "=" << v << ","; trace_(++s, vs...); }
#define TRACE(...) (cerr << "\033[2m\033[33m", trace_(#__VA_ARGS__, __VA_ARGS__), cerr << "\033[0m\n")
#else
#define TRACE(...)
#endif

template<class T> struct Grid {
    vector<T> data;
    const size_t h, w;
    Grid(size_t h, size_t w, T v = T()) : data(h * w, v), h(h), w(w) {}
    T& operator()(size_t i, size_t j) { return data[i * w + j]; }
    auto adjacent_indexes(size_t i, size_t j) const {
        vector<pair<size_t, size_t>> vs;
        if (i > 0) vs.emplace_back(i - 1, j);
        if (j > 0) vs.emplace_back(i, j - 1);
        if (i + 1 < h) vs.emplace_back(i + 1, j);
        if (j + 1 < w) vs.emplace_back(i, j + 1);
        return vs;
    }
    friend istream& operator>>(istream& in, Grid& g) {
        for (auto& v : g.data) in >> v;
        return in;
    }
    friend ostream& operator<<(ostream& out, const Grid& g) {
        for (size_t i = 0; i < g.h; ++i) {
            cout << g.data[i * g.w];
            for (size_t j = 1; j < g.w; ++j) {
                out << " " << g.data[i * g.w + j];
            }
            out << "\n";
        }
        return out;
    }
};

int main() {
    int H, W;
    cin >> H >> W;
    Grid<char> S(H, W);
    cin >> S;
    Grid<int> F(H, W);
    for (int i = 0; i < H; i++) {
        int n = 0;
        for (int j = 0; j < W; j++) {
            if (S(i, j) == '#') n = 0;
            else {
                F(i, j) += n;
                n++;
            }
        }
        n = 0;
        for (int j = W - 1; j >= 0; j--) {
            if (S(i, j) == '#') n = 0;
            else {
                F(i, j) += n;
                n++;
            }
        }
    }
    for (int j = 0; j < W; j++) {
        int n = 0;
        for (int i = 0; i < H; i++) {
            if (S(i, j) == '#') n = 0;
            else {
                F(i, j) += n;
                n++;
            }
        }
        n = 0;
        for (int i = H - 1; i >= 0; i--) {
            if (S(i, j) == '#') n = 0;
            else {
                F(i, j) += n;
                n++;
            }
        }
    }
    int ans = *max_element(F.data.begin(), F.data.end()) + 1;
    cout << ans << '\n';
}


Measured memory_bytes: 19968