<?php

namespace App\Notifications;

class ApplicationSubmitted extends ApplicationNotification
{
    protected function subject(): string
    {
        return 'Application received - '.$this->application->application_number;
    }

    protected function heading(): string
    {
        return 'Thank you, '.$this->application->applicant->first_name.'.';
    }

    protected function lines(): array
    {
        $programme = $this->application->programme()?->name ?? 'your selected programme';

        return [
            "We have received your application for {$programme}.",
            "Your application number is {$this->application->application_number}. Please quote it in all correspondence.",
            'Our admissions team will review your application and update you as it progresses. You can track its status at any time from your portal.',
        ];
    }

    public function toSms(): ?string
    {
        return sprintf(
            'KCU: Application %s received. Track it at %s',
            $this->application->application_number,
            route('applicant.dashboard'),
        );
    }
}
