<?php

namespace App\Support;

/**
 * Ugandan reference data used by applicant forms and reporting.
 *
 * Kept here rather than in the database because it is national reference
 * data, not institutional configuration — it does not change per university.
 */
class Uganda
{
    /** @return array<string, string> district => district */
    public static function districts(): array
    {
        return collect(self::DISTRICTS)
            ->mapWithKeys(fn (string $d) => [$d => $d])
            ->all();
    }

    /** UACE principal-subject grades, best first. */
    public static function uaceGrades(): array
    {
        return ['A' => 'A', 'B' => 'B', 'C' => 'C', 'D' => 'D', 'E' => 'E', 'O' => 'O', 'F' => 'F'];
    }

    /** UCE grades, best first. */
    public static function uceGrades(): array
    {
        return collect(['D1', 'D2', 'C3', 'C4', 'C5', 'C6', 'P7', 'P8', 'F9'])
            ->mapWithKeys(fn (string $g) => [$g => $g])
            ->all();
    }

    /** Commonly examined subjects, used to prompt rather than restrict input. */
    public static function subjects(): array
    {
        return [
            'Mathematics', 'English', 'Physics', 'Chemistry', 'Biology', 'Geography',
            'History', 'Economics', 'Entrepreneurship', 'Literature in English',
            'Computer Studies', 'Agriculture', 'Fine Art', 'Christian Religious Education',
            'Islamic Religious Education', 'Luganda', 'Kiswahili', 'Technical Drawing',
            'Commerce', 'Accounts', 'Divinity', 'General Paper', 'Subsidiary ICT',
            'Subsidiary Mathematics', 'Food and Nutrition', 'Physical Education',
        ];
    }

    private const DISTRICTS = [
        'Abim', 'Adjumani', 'Agago', 'Alebtong', 'Amolatar', 'Amudat', 'Amuria', 'Amuru',
        'Apac', 'Arua', 'Budaka', 'Bududa', 'Bugiri', 'Bugweri', 'Buhweju', 'Buikwe',
        'Bukedea', 'Bukomansimbi', 'Bukwo', 'Bulambuli', 'Buliisa', 'Bundibugyo', 'Bunyangabu',
        'Bushenyi', 'Busia', 'Butaleja', 'Butambala', 'Butebo', 'Buvuma', 'Buyende',
        'Dokolo', 'Gomba', 'Gulu', 'Hoima', 'Ibanda', 'Iganga', 'Isingiro', 'Jinja',
        'Kaabong', 'Kabale', 'Kabarole', 'Kaberamaido', 'Kagadi', 'Kakumiro', 'Kalaki',
        'Kalangala', 'Kaliro', 'Kalungu', 'Kampala', 'Kamuli', 'Kamwenge', 'Kanungu',
        'Kapchorwa', 'Kapelebyong', 'Karenga', 'Kasanda', 'Kasese', 'Katakwi', 'Kayunga',
        'Kazo', 'Kibaale', 'Kiboga', 'Kibuku', 'Kikuube', 'Kiruhura', 'Kiryandongo',
        'Kisoro', 'Kitagwenda', 'Kitgum', 'Koboko', 'Kole', 'Kotido', 'Kumi', 'Kwania',
        'Kween', 'Kyankwanzi', 'Kyegegwa', 'Kyenjojo', 'Kyotera', 'Lamwo', 'Lira',
        'Luuka', 'Luwero', 'Lwengo', 'Lyantonde', 'Madi-Okollo', 'Manafwa', 'Maracha',
        'Masaka', 'Masindi', 'Mayuge', 'Mbale', 'Mbarara', 'Mitooma', 'Mityana',
        'Moroto', 'Moyo', 'Mpigi', 'Mubende', 'Mukono', 'Nabilatuk', 'Nakapiripirit',
        'Nakaseke', 'Nakasongola', 'Namayingo', 'Namisindwa', 'Namutumba', 'Napak',
        'Nebbi', 'Ngora', 'Ntoroko', 'Ntungamo', 'Nwoya', 'Obongi', 'Omoro', 'Otuke',
        'Oyam', 'Pader', 'Pakwach', 'Pallisa', 'Rakai', 'Rubanda', 'Rubirizi',
        'Rukiga', 'Rukungiri', 'Rwampara', 'Sembabule', 'Serere', 'Sheema', 'Sironko',
        'Soroti', 'Terego', 'Tororo', 'Wakiso', 'Yumbe', 'Zombo',
    ];
}
