<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;

class FiscalIncentive extends Model
{
    use HasFactory, SoftDeletes;

    protected $fillable = [
        'name', 'description', 'type', 'benefit_percentage',
        'duration_years', 'min_investment', 'eligible_sectors',
        'eligible_provinces', 'is_active', 'sort_order',
    ];

    protected function casts(): array
    {
        return [
            'eligible_sectors' => 'array',
            'eligible_provinces' => 'array',
            'is_active' => 'boolean',
            'benefit_percentage' => 'decimal:2',
            'min_investment' => 'decimal:2',
        ];
    }
}
