<?php

namespace Database\Seeders;

use App\Models\ManualPaymentMethod;
use Illuminate\Database\Seeder;

class ManualPaymentMethodSeeder extends Seeder
{
    public function run(): void
    {
        $methods = [
            [
                'name' => 'Instapay',
                'type' => 'instapay',
                'instructions' => 'Send payment to the Instapay address below and upload your receipt.',
                'account_name' => 'ALGA ARENA',
                'account_identifier' => 'algaarena@instapay',
                'sort_order' => 1,
            ],
            [
                'name' => 'Vodafone Cash',
                'type' => 'vodafone_cash',
                'instructions' => 'Transfer via Vodafone Cash and include your transfer reference.',
                'account_name' => 'ALGA ARENA',
                'account_identifier' => '01000000000',
                'sort_order' => 2,
            ],
            [
                'name' => 'Bank Transfer',
                'type' => 'bank_transfer',
                'instructions' => 'Transfer to the bank account below. Upload a screenshot or PDF of the transfer.',
                'account_name' => 'ALGA ARENA LLC',
                'account_identifier' => 'EG123456789012345678901234',
                'sort_order' => 3,
            ],
            [
                'name' => 'Payment at Venue',
                'type' => 'payment_at_venue',
                'instructions' => 'Pay in cash at the event venue during check-in. Bring exact change.',
                'account_name' => null,
                'account_identifier' => null,
                'sort_order' => 4,
            ],
            [
                'name' => 'WhatsApp Contact',
                'type' => 'whatsapp_contact',
                'instructions' => 'Contact our team on WhatsApp to arrange payment and receive confirmation.',
                'account_name' => 'ALGA Events',
                'account_identifier' => '+201000000000',
                'sort_order' => 5,
            ],
        ];

        foreach ($methods as $method) {
            ManualPaymentMethod::updateOrCreate(
                ['type' => $method['type']],
                array_merge($method, ['is_active' => true]),
            );
        }
    }
}
