<?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::create('header_footer_settings', function (Blueprint $table) {
            $table->id();
            $table->string('section')->unique(); // header, footer
            $table->string('label')->nullable();
            $table->boolean('is_enabled')->default(true);
            
            // Header Settings
            $table->boolean('show_logo')->nullable()->default(true);
            $table->boolean('show_search')->nullable()->default(true);
            $table->boolean('show_navigation')->nullable()->default(true);
            $table->boolean('show_auth_buttons')->nullable()->default(true);
            $table->string('logo_url')->nullable();
            $table->text('custom_css')->nullable();
            
            // Footer Settings
            $table->text('brand_description')->nullable();
            $table->boolean('show_social_links')->nullable()->default(true);
            $table->boolean('show_platform_links')->nullable()->default(true);
            $table->boolean('show_tools_links')->nullable()->default(true);
            $table->boolean('show_corporate_links')->nullable()->default(true);
            $table->text('custom_html')->nullable();
            $table->string('copyright_text')->nullable();
            
            $table->integer('sort_order')->default(0);
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::dropIfExists('header_footer_settings');
    }
};
