<?php

namespace Database\Seeders;

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

class CreateHeaderAdSenseSeeder extends Seeder
{
    public function run(): void
    {
        $headerCode = '<div style="text-align:center;padding:12px;background:#f0f9ff;border:2px dashed #bfdbfe;border-radius:8px;margin:8px 0;"><span style="font-size:13px;color:#1e40af;font-weight:600;">&#128308; Header Reklam Alanı (728x90)</span></div>';

        // Create header zone if it doesn't exist
        AdSenseZone::firstOrCreate(
            ['location' => 'header'],
            [
                'name' => 'Header Reklam Alanı',
                'code' => $headerCode,
                'is_active' => 1,
            ]
        );

        $this->command->info('✅ Header AdSense zone oluşturuldu.');
    }
}
