<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        Schema::table('system_settings', function (Blueprint $table) {
            $table->string('logo_path')->nullable()->after('id');
            $table->string('company_name')->nullable()->after('logo_path');
            $table->string('company_email')->nullable()->after('company_name');
            $table->string('company_phone')->nullable()->after('company_email');
            $table->text('company_address')->nullable()->after('company_phone');
            $table->string('footer_phone')->nullable()->after('company_address');
            $table->string('footer_email')->nullable()->after('footer_phone');
            $table->text('footer_address')->nullable()->after('footer_email');
            $table->string('social_facebook')->nullable()->after('footer_address');
            $table->string('social_twitter')->nullable()->after('social_facebook');
            $table->string('social_instagram')->nullable()->after('social_twitter');
            $table->string('social_linkedin')->nullable()->after('social_instagram');
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::table('system_settings', function (Blueprint $table) {
            $table->dropColumn([
                'logo_path',
                'company_name',
                'company_email',
                'company_phone',
                'company_address',
                'footer_phone',
                'footer_email',
                'footer_address',
                'social_facebook',
                'social_twitter',
                'social_instagram',
                'social_linkedin',
            ]);
        });
    }
};
