using Microsoft.AspNetCore.Mvc.RazorPages;

namespace Nalu.Web.Pages.En.Validators;

public class EnValidatorsModel : PageModel
{
    public record ComingSoonItem(string Icon, string Slug, string Description);

    // Universal first in EN
    public IReadOnlyList<ValidatorCard> Universal { get; } =
    [
        new("✉️", "validate_email",         "Extracts email and fixes domain typos (gmail→gmail.com).",          3),
        new("🌍", "validate_postal_code",   "International postal code (non-BR).",                               3),
        new("🔤", "validate_full_name",     "Extracts full name, ignores greetings and titles.",                  3),
        new("☑️", "validate_yes_no",        "Detects yes/no in any language and indirect phrasing.",              3),
        new("🎂", "validate_birthdate",     "Date of birth in any format. Detects minors.",                      3),
        new("🤝", "validate_handoff",       "Detects intent to speak with a human. Classifies urgency.",          3),
        new("🚫", "validate_cancel_intent", "Differentiates service cancellation vs. current operation.",         3),
        new("🏢", "validate_company_name",  "Extracts company name. Detects legal suffixes.",                     3),
        new("🧠", "validate_reply",         "Analyzes conversational context. Detects counteroffers, handoffs, cancellations.", 5, IsNew: true),
    ];

    public IReadOnlyList<ValidatorCard> Brazilian { get; } =
    [
        new("🆔", "validate_cpf",      "Validates CPF with mod 11. Formats XXX.XXX.XXX-XX.",           3),
        new("📮", "validate_cep",      "Extracts ZIP code and returns enriched address.",               3),
        new("📱", "validate_phone_br", "Extracts phone with area code. Validates ANATEL DDDs.",         3),
        new("🏢", "validate_cnpj",     "Validates CNPJ with mod 11. Formats XX.XXX.XXX/XXXX-XX.",      3),
        new("🚗", "validate_plate_br", "Mercosul and legacy plate format. Accepts written-out form.",   3),
    ];

    public IReadOnlyList<ComingSoonItem> ComingSoonUniversal { get; } =
    [
        new("📅", "date-relative",             "\"tomorrow\", \"next week\", \"the 15th\""),
        new("🕐", "time",                       "\"around 3pm\", \"after lunch\", \"early evening\""),
        new("📍", "address-full",              "Full address extracted and structured"),
        new("💰", "currency-amount",           "Monetary values in any currency"),
        new("🔢", "number-in-context",         "Numbers that change meaning by context"),
        new("👥", "count-people",              "\"me and my wife\" → 2 people"),
        new("⭐", "rating",                     "\"around a 7 I'd say\" → score 7"),
        new("😤", "sentiment",                  "Detects dissatisfaction before handoff"),
        new("🎯", "preference",                 "\"the middle one\" → extracts option B"),
        new("✅", "confirmation-with-changes", "\"yes but it's 200\" → partial confirm"),
    ];

    public IReadOnlyList<ComingSoonItem> ComingSoonBrazilian { get; } =
    [
        new("💰", "amount-brl",  "Values in R$ with context"),
        new("🔑", "pix-key",     "Pix key (CPF, email, phone, random)"),
        new("📋", "renavam",      "Brazilian vehicle RENAVAM"),
        new("📋", "ie-by-state", "State registration (Inscrição Estadual) by UF"),
        new("📋", "pis-nis",     "PIS/NIS/PASEP"),
    ];

    public void OnGet() { }
}
