<?php

namespace App\Mail;

use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable;
use Illuminate\Mail\Mailables\Content;
use Illuminate\Mail\Mailables\Envelope;
use Illuminate\Queue\SerializesModels;

class EmployerOtpMail extends Mailable
{
    use Queueable, SerializesModels;

    public $otp;
    public $companyName;
    public $employerName;

    /**
     * Create a new message instance.
     */
    public function __construct($otp, $companyName, $employerName)
    {
        $this->otp = $otp;
        $this->companyName = $companyName;
        $this->employerName = $employerName;
    }

    /**
     * Get the message envelope.
     */
    public function envelope(): Envelope
    {
        return new Envelope(
            subject: 'Verification Code for Marketplace Registration: ' . $this->otp,
        );
    }

    /**
     * Get the message content definition.
     */
    public function content(): Content
    {
        return new Content(
            view: 'emails.employer-otp',
        );
    }
}
