<?php

namespace Database\Seeders;

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

class ServiceCategorySeeder extends Seeder
{
    public function run(): void
    {
        $categories = [
            ['name' => 'Hair', 'code' => 'HAIR', 'description' => 'Hair cutting, styling, coloring', 'status' => 'active', 'sort_order' => 1],
            ['name' => 'Skin', 'code' => 'SKIN', 'description' => 'Facials, cleanups, treatments', 'status' => 'active', 'sort_order' => 2],
            ['name' => 'Nails', 'code' => 'NAILS', 'description' => 'Manicure, pedicure', 'status' => 'active', 'sort_order' => 3],
            ['name' => 'Spa', 'code' => 'SPA', 'description' => 'Massage and body treatments', 'status' => 'active', 'sort_order' => 4],
        ];

        foreach ($categories as $data) {
            ServiceCategory::firstOrCreate(['code' => $data['code']], $data);
        }
    }
}
