<?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::dropIfExists('home_page_settings');
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::create('home_page_settings', function (Blueprint $table) {
            $table->id();
            $table->string('section')->unique();
            $table->text('title_en')->nullable();
            $table->text('title_km')->nullable();
            $table->longText('description_en')->nullable();
            $table->longText('description_km')->nullable();
            $table->string('image')->nullable();
            $table->json('highlights')->nullable();
            $table->integer('display_limit')->nullable();
            $table->string('status')->default('active');
            $table->integer('order')->default(0);
            $table->timestamps();
        });
    }
};
