using Meezi.Core.Enums;

namespace Meezi.Core.Constants;

public static class PlanLimits
{
    public static int MaxOrdersPerDay(PlanTier tier) => tier switch
    {
        PlanTier.Free => 50,
        _ => int.MaxValue
    };

    public static int MaxTerminals(PlanTier tier) => tier switch
    {
        PlanTier.Free => 1,
        PlanTier.Pro => 3,
        _ => int.MaxValue
    };

    public static int MaxCustomers(PlanTier tier) => tier switch
    {
        PlanTier.Free => 50,
        _ => int.MaxValue
    };

    public static int MaxSmsPerMonth(PlanTier tier) => tier switch
    {
        PlanTier.Free => 0,
        PlanTier.Pro => 50,
        PlanTier.Business => 200,
        _ => int.MaxValue
    };

    public static int MaxBranches(PlanTier tier) => tier switch
    {
        PlanTier.Free => 1,
        PlanTier.Pro => 3,
        PlanTier.Business => int.MaxValue,
        _ => int.MaxValue
    };

    /// <summary>How far back daily report snapshots may be queried (inclusive of today).</summary>
    public static int MaxReportHistoryDays(PlanTier tier) => tier switch
    {
        PlanTier.Free => 8,
        PlanTier.Pro => 90,
        _ => int.MaxValue
    };

    /// <summary>AI image-to-3D generations per calendar month (UTC).</summary>
    public static int MaxMenuAi3dPerMonth(PlanTier tier) => tier switch
    {
        PlanTier.Business => 100,
        PlanTier.Enterprise => 100,
        _ => 0
    };
}
